Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug Report] Inconsistency with left/right icons in rtl/ltr when used within buttons and without buttons #10960

Closed
ibrahimBeladi opened this issue Mar 28, 2020 · 3 comments

Comments

@ibrahimBeladi
Copy link
Contributor

Environment

Vuetify Version: 2.2.19
Vue Version: 2.6.11
Browsers: Waterfox 56.3
OS: Linux x86_64

Steps to reproduce

Use left/right in icon within buttons and without.

Expected Behavior

Consistency with left/right icons in rtl/ltr when used within buttons and without buttons

Actual Behavior

Inconsistency.

Reproduction Link

https://codepen.io/ibrahimbeladi/pen/ZEGVVVe?editors=1000

Other comments

Related to (but not duplicate of) #10619, #8461, and #9211.
I suggested before to add 'end' and 'start' props in addition to (or in place of) left/right;
See #10619 (comment) and #10619 (comment)

@ghost ghost added the S: triage label Mar 28, 2020
@Leespiker Leespiker added rtl T: bug Functionality that does not work as intended/expected and removed S: triage labels Apr 10, 2020
@jacekkarczmarczyk jacekkarczmarczyk added this to the v3.0.0 milestone May 9, 2020
NabeelAhmed314 added a commit to NabeelAhmed314/vuetify that referenced this issue Dec 1, 2020
@johnleider johnleider self-assigned this Dec 3, 2020
@johnleider johnleider modified the milestones: v3.0.0, v2.4.x Dec 3, 2020
@johnleider
Copy link
Member

This is a documentation related issue as v-icon's left and right properties only apply margin inside of v-btn.

@johnleider johnleider removed T: bug Functionality that does not work as intended/expected rtl labels Dec 17, 2020
@ibrahimBeladi
Copy link
Contributor Author

The margins are applied to the opposite side in rtl. And the documentation change does not fix this issue as the margins are applied even if it isn't inside a button.

@ibrahimBeladi
Copy link
Contributor Author

I just updated the codepen, and made it a bit sophisticated.

As you can see for the buttons it looks great in both LTR and RTL because it is direction-oriented; in other words, left and right are the implementations of start and end respectively. In other words, left is left in LTR and right in RTL

While in the examples without a button they look ugly and move closer to the text leaving a padding to the start of the line, and that's due the fact they are truly left and right. In other words, left is left in both LTR and RTL since it is direction-agnostic.

The direction-oriented behavior of icons in buttons is great, but it is super confusing for people writing i18n direction-agnostic websites for both LTR and RTL languages.


Side note: I have always mentioned introducing start and end to avoid the aforementioned problem and to reduce the miscommunication in the community.

@KaelWD KaelWD modified the milestones: v2.4.x, v2.3.x Dec 23, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants