magento-lts icon indicating copy to clipboard operation
magento-lts copied to clipboard

Grid range filter replaced span with placeholder

Open Sekiphp opened this issue 4 years ago • 11 comments

Description (*)

Design improvment for adminhtml grid - replaced span to placeholder.

Before changes

image

After changes

image

Contribution checklist (*)

  • [ ] Pull request has a meaningful description of its purpose
  • [ ] All commits are accompanied by meaningful commit messages
  • [ ] All automated tests passed successfully (all builds are green)

Sekiphp avatar May 26 '21 13:05 Sekiphp

Good idea! But in the original theme v20 (client still prefer original theme), this is the after-look that I have: image

It'll look better if the date-range can be made into placeholder as well and the width of the number-range can be widen to fill the gap.

kiatng avatar May 26 '21 15:05 kiatng

Even I appreciate the efforts for the OM Backend theme in all my stores the content editors want to use the Magento default theme. As I see I am not the only one who confronts with such of request.

I am sorry to say but I do not agree this change. If this will be merged all Magento Backend sections must be changed according. At least for Orders section not only G.T. (Base) and G.T. (Purchased) columns should be changed but also Purchased On. Removing the text in front of the input text boxes creates a new issue the blue empty space which is not good looking at all. Unfortunately it is a change in the core file (Range.php) not in a template which could be related to the new Backend theme.

orders

addison74 avatar May 26 '21 15:05 addison74

I agree that the blue gap is ugly.

midlan avatar May 26 '21 16:05 midlan

About the screen readers I contacted my friend who is optimizing pages for accessibility. He told me that aria-label is needed in this case to help readers properly read it.

@Flyingmana I read that article: https://www.nngroup.com/articles/form-design-placeholders/ I would say that none of them apply to this case. In this case it is only two fields, you won't forgot which one is which. The other filter fields in Magento grids have no placeholder or label at all and everybody knows how to use them.

midlan avatar May 27 '21 10:05 midlan

I found this document from w3c: https://www.w3.org/TR/html-aria/

Sekiphp avatar May 27 '21 10:05 Sekiphp

I repeat the observation that if this change is merged, it must be made at the level of the entire interface, not only in one place. Also not without prior testing before by those who can still do it and leaving an opinion here what benefits brings.

As for me, I will retain this change and if it is merged I will remove it in the new OM versions to avoid discussions with those who have been using the default Magento interface for a long time. Maybe if I was the only user I would have been more flexible about this change.

addison74 avatar May 27 '21 11:05 addison74

I added same behaviour to all filter classes which have more than 1 field. I used placeholder & aria-label

Sekiphp avatar May 27 '21 22:05 Sekiphp

@Sekiphp What about the blank space that @kiatng mentioned above?

midlan avatar May 28 '21 06:05 midlan

This branch has conflicts that must be resolved

sreichel avatar Sep 06 '22 03:09 sreichel

I would close this PR. Using placeholders can reduce the width of the column, but input boxes with that text will look very ugly. We have already done the modification to keep outside From, To, In and I think it looks very good.

addison74 avatar Sep 06 '22 08:09 addison74

Just asked to resolve conflicts.

Having placeholders and aria-label is not wrong.

sreichel avatar Sep 06 '22 20:09 sreichel