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

fix(select): RTL fix for select #11352

Closed
wants to merge 7 commits into from
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions src/components/select/select.ios.scss
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,10 @@ $select-ios-placeholder-color: $select-ios-icon-color !default;
padding: $select-ios-padding-top $select-ios-padding-right $select-ios-padding-bottom $select-ios-padding-left;
}

[dir="rtl|] .select-ios {
padding: $select-ios-padding-top $select-ios-padding-left $select-ios-padding-bottom $select-ios-padding-right;
}

.select-ios .select-placeholder {
color: $select-ios-placeholder-color;
}
Expand Down Expand Up @@ -54,3 +58,8 @@ $select-ios-placeholder-color: $select-ios-icon-color !default;

pointer-events: none;
}

[dir="rtl"] .select-ios .select-icon .select-icon-inner {
right: 5px;
left: auto;
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the lint rules for ionic indicate a need for a new line at the end of the file.
You can run it locally, gulp lint.sass, but you need to install ruby for that

9 changes: 9 additions & 0 deletions src/components/select/select.md.scss
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,10 @@ $select-md-placeholder-color: $select-md-icon-color !default;
padding: $select-md-padding-top $select-md-padding-right $select-md-padding-bottom $select-md-padding-left;
}

[dir="rtl"] .select-md {
padding: $select-md-padding-top $select-md-padding-left $select-md-padding-bottom $select-md-padding-right;
}

.select-md .select-placeholder {
color: $select-md-placeholder-color;
}
Expand Down Expand Up @@ -58,3 +62,8 @@ $select-md-placeholder-color: $select-md-icon-color !default;

pointer-events: none;
}

[dir="rtl"] .select-md .select-icon .select-icon-inner {
right: 5px;
left: auto;
}
4 changes: 4 additions & 0 deletions src/components/select/select.scss
Original file line number Diff line number Diff line change
Expand Up @@ -49,3 +49,7 @@ ion-select {
.select-popover ion-list {
margin: $select-popover-list-margin-top $select-popover-list-margin-right $select-popover-list-margin-bottom $select-popover-list-margin-left;
}

[dir="rtl"] .select-popover ion-list {
margin: $select-popover-list-margin-top $select-popover-list-margin-left $select-popover-list-margin-bottom $select-popover-list-margin-right;
}
11 changes: 11 additions & 0 deletions src/components/select/select.wp.scss
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,10 @@ $select-wp-placeholder-color: $select-wp-icon-color !default;
line-height: 3rem;
}

[dir="rtl"] .select-wp {
margin: $select-wp-margin-top $select-wp-margin-left $select-wp-margin-bottom $select-wp-margin-right;
}

.select-wp .select-placeholder {
color: $select-wp-placeholder-color;
}
Expand Down Expand Up @@ -86,6 +90,13 @@ $select-wp-placeholder-color: $select-wp-icon-color !default;
pointer-events: none;
}

[dir="rtl"] .select-wp .select-icon .select-icon-inner {
right: 5px;
left: auto;
border-left: $select-wp-icon-arrow-width solid $select-wp-icon-color;
border-right: none;
}

.select-wp .select-text {
min-height: 3rem;
}