[ 
https://issues.apache.org/jira/browse/WICKET-7191?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18106385#comment-18106385
 ] 

Laurent Almeras commented on WICKET-7191:
-----------------------------------------

I checked `HTML5Attributes.java` and PR to see what are the new behavior 
proposed as defaults by this modification. Here are my feedbacks :
 * HTML5 required if AbstractTextComponent is required : this change may cause 
usability or consistency concerns, as feedback will be performed by browser and 
not by wicket. No additional feedback can be provided. This MDN page provides 
an interactive exemple of required field feedback, and feedback is not really 
fancy
 * HTML5 placeholder populated with form label : this change may cause 
usability concerns by overloading form display when it is empty if labels are 
already displayed next to field.
 * HTML5 pattern populated if a PatternValidator is used : like required, the 
browser feedback is really poor. I think it may also trigger issues when 
java-only feature are used for regexp pattern, with browser rejecting a valid 
java match

So the PR matches the issue, but I have concern with the HTML5 attributes 
browser implementation, the UI/UX implementation, and the consistency with 
server-side wicket feedback. I think this change needs an opt-out option.

Maybe it should be implemented as a `IOnComponentTagListener`, registered at 
application-level, so it allows developer to remove the feature (or customize 
it) if needed.

> Deprecate HTML5Attributes and move its logic to FormComponet hierarchy  
> ------------------------------------------------------------------------
>
>                 Key: WICKET-7191
>                 URL: https://issues.apache.org/jira/browse/WICKET-7191
>             Project: Wicket
>          Issue Type: Improvement
>            Reporter: Andrea Del Bene
>            Assignee: Andrea Del Bene
>            Priority: Major
>             Fix For: 11.0.0
>
>
> Tag attributes applied by  class behavior HTML5Attributes should now be 
> applied by default. We should deprecate this class and move its logic to 
> FromComponent#onComponentTag  



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to