Opened 11 years ago

Closed 10 years ago

#11583 closed New Feature (fixed)

Add support for HTML5 "required" attribute in form input elements

Reported by: Urs Wolfer Owned by: Olek Nowodziński
Priority: Normal Milestone: CKEditor 4.5.0 Beta
Component: UI : Dialogs Version: 3.6.6
Keywords: Cc:

Description

It would be nice to have a checkbox for setting the required attribute for form elements.

Change History (10)

comment:1 Changed 11 years ago by Jakub Ś

Keywords: forms required validation removed
Status: newconfirmed
Summary: Add support for HTML5 "required" tag in form elementsAdd support for HTML5 "required" attribute in form input elements

We have done it for base textarea that classic CKEditor is using (#8031) so it would be nice to add such field to input form elements CKEditor handles.

comment:2 Changed 11 years ago by Urs Wolfer

Just to make it more clear: I'm talking about a checkbox in the forms plugin for each input field to enable / disable the required flag.

comment:4 Changed 11 years ago by Matti Järvinen

Nice... optional placeholder while you're at it?

comment:5 in reply to:  4 Changed 11 years ago by Urs Wolfer

Replying to matti:

Nice... optional placeholder while you're at it?

I'd like to get this merged first. Please open a new feature request for placeholder tests (if there does not exist one yet).

comment:6 Changed 10 years ago by Olek Nowodziński

Owner: set to Olek Nowodziński
Status: confirmedassigned

comment:7 Changed 10 years ago by Olek Nowodziński

Status: assignedreview

I extracted the code from https://github.com/ckeditor/ckeditor-dev/pull/100 to branch:t/11583 and thoroughly reviewed it. Changes include:

  • Tests separated from dev code.
  • Improved code style.
  • Some new and improved tests.
  • A different accessKey for "required" field. I decided that it got to correspond with our naming pattern, so it's "R". I also checked whether it collides with browser keystrokes but it seems to be fine.

comment:8 Changed 10 years ago by Piotrek Koszuliński

I pushed branch:t/11583 rebased on major (since it's a feature).

I agree with this comment that in this case 'Q' may be a choice.

I made just a brief check and I'm ok with the changes.

comment:9 Changed 10 years ago by Olek Nowodziński

Component: GeneralUI : Dialogs
Milestone: CKEditor 4.5.0
Status: reviewreview_passed
Version: 3.6.6

Fixed in git:a067471.

comment:10 Changed 10 years ago by Olek Nowodziński

Resolution: fixed
Status: review_passedclosed
Note: See TracTickets for help on using tickets.
© 2003 – 2022, CKSource sp. z o.o. sp.k. All rights reserved. | Terms of use | Privacy policy