-
Notifications
You must be signed in to change notification settings - Fork 591
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(*): rtl supported in Select/Input/Message
- Loading branch information
潕量
committed
Nov 26, 2018
1 parent
e683677
commit 3bb15c8
Showing
14 changed files
with
160 additions
and
25 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,82 @@ | ||
@charset "UTF-8"; | ||
|
||
#{$input-prefix}[dir="rtl"] { | ||
&.#{$css-prefix}small { | ||
@include input-size-rtl($input-s-label-padding-left, $input-s-icon-padding-right); | ||
} | ||
|
||
&.#{$css-prefix}medium { | ||
@include input-size-rtl($input-m-label-padding-left, $input-m-icon-padding-right); | ||
} | ||
|
||
&.#{$css-prefix}large { | ||
@include input-size-rtl($input-l-label-padding-left, $input-l-icon-padding-right); | ||
} | ||
|
||
&#{$input-prefix}-textarea { | ||
#{$input-prefix}-len { | ||
text-align: left; | ||
} | ||
} | ||
|
||
#{$input-prefix}-control { | ||
> *:not(:first-child) { | ||
padding-right: $s-1; | ||
padding-left: 0; | ||
} | ||
} | ||
} | ||
#{$input-prefix}-group[dir="rtl"] { | ||
#{$input-prefix}-group-addon { | ||
|
||
/* stylelint-disable declaration-no-important */ | ||
&:first-child { | ||
border-bottom-left-radius: 0 !important; | ||
border-top-left-radius: 0 !important; | ||
|
||
&.#{$css-prefix}small { | ||
border-bottom-right-radius: $form-element-small-corner !important; | ||
border-top-right-radius: $form-element-small-corner !important; | ||
} | ||
|
||
&.#{$css-prefix}medium { | ||
border-bottom-right-radius: $form-element-medium-corner !important; | ||
border-top-right-radius: $form-element-medium-corner !important; | ||
} | ||
|
||
&.#{$css-prefix}large { | ||
border-bottom-right-radius: $form-element-large-corner !important; | ||
border-top-right-radius: $form-element-large-corner !important; | ||
} | ||
} | ||
&:last-child { | ||
border-bottom-right-radius: 0 !important; | ||
border-top-right-radius: 0 !important; | ||
|
||
&.#{$css-prefix}small { | ||
border-bottom-left-radius: $form-element-small-corner !important; | ||
border-top-left-radius: $form-element-small-corner !important; | ||
} | ||
|
||
&.#{$css-prefix}medium { | ||
border-bottom-left-radius: $form-element-medium-corner !important; | ||
border-top-left-radius: $form-element-medium-corner !important; | ||
} | ||
|
||
&.#{$css-prefix}large { | ||
border-bottom-left-radius: $form-element-large-corner !important; | ||
border-top-left-radius: $form-element-large-corner !important; | ||
} | ||
} | ||
} | ||
#{$input-prefix}-group-text { | ||
&:first-child { | ||
border-right-width: $input-border-width; | ||
border-left: 0; | ||
} | ||
&:last-child { | ||
border-left-width: $input-border-width; | ||
border-right: 0; | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -328,3 +328,5 @@ | |
} | ||
} | ||
} | ||
|
||
@import "./rtl.scss"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
@charset "UTF-8"; | ||
|
||
.#{$css-prefix}message[dir="rtl"] { | ||
.#{$css-prefix}message-symbol { | ||
float: right; | ||
} | ||
|
||
&.#{$css-prefix}medium { | ||
.#{$css-prefix}message-title { | ||
padding: 0 $message-size-m-title-content-padding-left + $message-size-m-icon 0 $message-size-m-title-content-padding-right; | ||
} | ||
.#{$css-prefix}message-close { | ||
left: $message-size-m-close-right; | ||
right: auto; | ||
} | ||
} | ||
|
||
&.#{$css-prefix}large { | ||
.#{$css-prefix}message-title { | ||
padding: 0 $message-size-l-title-content-padding-left + $message-size-l-icon 0 $message-size-l-title-content-padding-right; | ||
} | ||
.#{$css-prefix}message-close { | ||
left: $message-size-l-close-right; | ||
right: auto; | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters