forked from ant-design/ant-design
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
style: add rtl.less of Tree\Tooltip\Timeline
- Loading branch information
Showing
6 changed files
with
189 additions
and
92 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,119 @@ | ||
@import '../../style/themes/index'; | ||
@import '../../style/mixins/index'; | ||
|
||
@timeline-prefix-cls: ~'@{ant-prefix}-timeline'; | ||
|
||
.@{timeline-prefix-cls} { | ||
&-rtl { | ||
direction: rtl; | ||
} | ||
|
||
&-item { | ||
&-tail { | ||
.@{timeline-prefix-cls}-rtl & { | ||
right: 4px; | ||
left: auto; | ||
border-right: @timeline-width solid @timeline-color; | ||
border-left: none; | ||
} | ||
} | ||
|
||
&-head-custom { | ||
.@{timeline-prefix-cls}-rtl & { | ||
right: 5px; | ||
left: auto; | ||
transform: translate(50%, -50%); | ||
} | ||
} | ||
|
||
&-content { | ||
.@{timeline-prefix-cls}-rtl & { | ||
margin: 0 18px 0 0; | ||
} | ||
} | ||
} | ||
|
||
&.@{timeline-prefix-cls}-alternate, | ||
&.@{timeline-prefix-cls}-right, | ||
&.@{timeline-prefix-cls}-label { | ||
.@{timeline-prefix-cls}-item { | ||
&-tail, | ||
&-head, | ||
&-head-custom { | ||
.@{timeline-prefix-cls}-rtl& { | ||
right: 50%; | ||
left: auto; | ||
} | ||
} | ||
|
||
&-head { | ||
.@{timeline-prefix-cls}-rtl& { | ||
margin-right: -4px; | ||
margin-left: 0; | ||
} | ||
|
||
&-custom { | ||
.@{timeline-prefix-cls}-rtl& { | ||
margin-right: 1px; | ||
margin-left: 0; | ||
} | ||
} | ||
} | ||
|
||
&-left { | ||
.@{timeline-prefix-cls}-item-content { | ||
.@{timeline-prefix-cls}-rtl& { | ||
right: calc(50% - 4px); | ||
left: auto; | ||
text-align: right; | ||
} | ||
} | ||
} | ||
|
||
&-right { | ||
.@{timeline-prefix-cls}-item-content { | ||
.@{timeline-prefix-cls}-rtl& { | ||
text-align: left; | ||
} | ||
} | ||
} | ||
} | ||
} | ||
|
||
&.@{timeline-prefix-cls}-right { | ||
.@{timeline-prefix-cls}-item-right { | ||
.@{timeline-prefix-cls}-item-tail, | ||
.@{timeline-prefix-cls}-item-head, | ||
.@{timeline-prefix-cls}-item-head-custom { | ||
.@{timeline-prefix-cls}-rtl& { | ||
right: 0; | ||
left: auto; | ||
} | ||
} | ||
|
||
.@{timeline-prefix-cls}-item-content { | ||
.@{timeline-prefix-cls}-rtl& { | ||
width: 100%; | ||
margin-right: 18px; | ||
text-align: right; | ||
} | ||
} | ||
} | ||
} | ||
|
||
&&-pending &-item-last &-item-tail { | ||
.@{timeline-prefix-cls}-rtl& { | ||
border-right: 2px dotted @timeline-color; | ||
border-left: none; | ||
} | ||
} | ||
|
||
&&-reverse &-item-pending { | ||
.@{timeline-prefix-cls}-item-tail { | ||
.@{timeline-prefix-cls}-rtl& { | ||
border-right: 2px dotted @timeline-color; | ||
border-left: none; | ||
} | ||
} | ||
} | ||
} |
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,14 @@ | ||
@tooltip-prefix-cls: ~'@{ant-prefix}-tooltip'; | ||
|
||
// Base class | ||
.@{tooltip-prefix-cls} { | ||
&-rtl { | ||
direction: rtl; | ||
} | ||
// Wrapper for the tooltip content | ||
&-inner { | ||
.@{tooltip-prefix-cls}-rtl & { | ||
text-align: right; | ||
} | ||
} | ||
} |
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
Oops, something went wrong.