@bifrostui/react 1.1.1 → 1.1.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/ActionSheet/ActionSheet.less +31 -0
- package/dist/ActionSheet/ActionSheetItem.less +62 -0
- package/dist/Alert/index.less +112 -0
- package/dist/Avatar/Avatar.less +52 -0
- package/dist/Avatar/AvatarGroup.less +39 -0
- package/dist/Backdrop/{Backdrop.css → Backdrop.less} +4 -3
- package/dist/Badge/Badge.less +118 -0
- package/dist/Button/Button.less +244 -0
- package/dist/Calendar/Calendar.less +126 -0
- package/{es/Card/Card.css → dist/Card/Card.less} +1 -0
- package/dist/Card/CardHeader.less +53 -0
- package/dist/Checkbox/Checkbox.less +55 -0
- package/dist/CitySelector/CitySelector.less +122 -0
- package/dist/CitySelector/CitySelectorCore.js +1 -2
- package/{es/CitySelector/Selector/index.css → dist/CitySelector/Selector/index.less} +2 -0
- package/dist/Countdown/Countdown.less +39 -0
- package/dist/Divider/Divider.less +50 -0
- package/dist/Drawer/Drawer.less +40 -0
- package/dist/IconButton/IconButton.less +167 -0
- package/dist/Image/index.less +40 -0
- package/dist/Input/Input.less +72 -0
- package/dist/List/{List.css → List.less} +1 -0
- package/dist/List/{ListItem.css → ListItem.less} +17 -6
- package/dist/List/{ListItemContent.css → ListItemContent.less} +7 -2
- package/dist/List/{ListItemFooter.css → ListItemFooter.less} +4 -3
- package/dist/Loading/Loading.less +40 -0
- package/dist/Modal/{Modal.css → Modal.less} +8 -6
- package/dist/Modal/Modal.miniapp.d.ts +1 -1
- package/dist/NavBar/NavBar.less +67 -0
- package/dist/Picker/Picker.less +62 -0
- package/dist/Picker/PickerPanel.less +67 -0
- package/dist/Picker/utils.d.ts +1 -1
- package/dist/Progress/Progress.less +24 -0
- package/dist/Radio/Radio.less +81 -0
- package/dist/Rating/Rating.less +64 -0
- package/dist/ScrollView/{ScrollView.css → ScrollView.less} +4 -0
- package/dist/Select/Select.less +105 -0
- package/dist/Skeleton/Skeleton.less +72 -0
- package/dist/Slider/Slider.less +108 -0
- package/dist/Stack/demo/index.less +27 -0
- package/dist/Steps/Step.less +228 -0
- package/{es/Steps/Steps.css → dist/Steps/Steps.less} +5 -3
- package/dist/Swiper/Swiper.less +25 -0
- package/dist/Switch/Switch.less +177 -0
- package/dist/TabBar/TabBarItem.less +54 -0
- package/dist/Tabs/Tab.js +1 -1
- package/dist/Tabs/Tab.less +60 -0
- package/dist/Tabs/TabPanel.less +11 -0
- package/dist/Tabs/Tabs.less +77 -0
- package/dist/Tag/Tag.less +119 -0
- package/dist/Tag/TagGroup.less +52 -0
- package/dist/TextArea/{TextArea.css → TextArea.less} +27 -19
- package/es/ActionSheet/ActionSheet.less +31 -0
- package/es/ActionSheet/ActionSheetItem.less +62 -0
- package/es/Alert/index.less +112 -0
- package/es/Avatar/Avatar.less +52 -0
- package/es/Avatar/AvatarGroup.less +39 -0
- package/es/Backdrop/{Backdrop.css → Backdrop.less} +4 -3
- package/es/Badge/Badge.less +118 -0
- package/es/Button/Button.less +244 -0
- package/es/Calendar/Calendar.less +126 -0
- package/{dist/Card/Card.css → es/Card/Card.less} +1 -0
- package/es/Card/CardHeader.less +53 -0
- package/es/Checkbox/Checkbox.less +55 -0
- package/es/CitySelector/CitySelector.less +122 -0
- package/es/CitySelector/CitySelectorCore.js +2 -3
- package/{dist/CitySelector/Selector/index.css → es/CitySelector/Selector/index.less} +2 -0
- package/es/Countdown/Countdown.less +39 -0
- package/es/Divider/Divider.less +50 -0
- package/es/Drawer/Drawer.less +40 -0
- package/es/IconButton/IconButton.less +167 -0
- package/es/Image/index.less +40 -0
- package/es/Input/Input.less +72 -0
- package/es/List/{List.css → List.less} +1 -0
- package/es/List/{ListItem.css → ListItem.less} +17 -6
- package/es/List/{ListItemContent.css → ListItemContent.less} +7 -2
- package/es/List/{ListItemFooter.css → ListItemFooter.less} +4 -3
- package/es/Loading/Loading.less +40 -0
- package/es/Modal/{Modal.css → Modal.less} +8 -6
- package/es/Modal/Modal.miniapp.d.ts +1 -1
- package/es/NavBar/NavBar.less +67 -0
- package/es/Picker/Picker.less +62 -0
- package/es/Picker/PickerPanel.less +67 -0
- package/es/Picker/utils.d.ts +1 -1
- package/es/Progress/Progress.less +24 -0
- package/es/Radio/Radio.less +81 -0
- package/es/Rating/Rating.less +64 -0
- package/es/ScrollView/{ScrollView.css → ScrollView.less} +4 -0
- package/es/Select/Select.less +105 -0
- package/es/Skeleton/Skeleton.less +72 -0
- package/es/Slider/Slider.less +108 -0
- package/es/Stack/demo/index.less +27 -0
- package/es/Steps/Step.less +228 -0
- package/{dist/Steps/Steps.css → es/Steps/Steps.less} +5 -3
- package/es/Swiper/Swiper.less +25 -0
- package/es/Switch/Switch.less +177 -0
- package/es/TabBar/TabBarItem.less +54 -0
- package/es/Tabs/Tab.js +1 -1
- package/es/Tabs/Tab.less +60 -0
- package/es/Tabs/TabPanel.less +11 -0
- package/es/Tabs/Tabs.less +77 -0
- package/es/Tag/Tag.less +119 -0
- package/es/Tag/TagGroup.less +52 -0
- package/es/TextArea/{TextArea.css → TextArea.less} +27 -19
- package/package.json +6 -6
- package/dist/ActionSheet/ActionSheet.css +0 -27
- package/dist/ActionSheet/ActionSheetItem.css +0 -51
- package/dist/Alert/index.css +0 -89
- package/dist/Avatar/Avatar.css +0 -43
- package/dist/Avatar/AvatarGroup.css +0 -31
- package/dist/Badge/Badge.css +0 -95
- package/dist/Button/Button.css +0 -200
- package/dist/Calendar/Calendar.css +0 -105
- package/dist/Card/CardHeader.css +0 -45
- package/dist/Checkbox/Checkbox.css +0 -45
- package/dist/CitySelector/CitySelector.css +0 -102
- package/dist/Countdown/Countdown.css +0 -28
- package/dist/Divider/Divider.css +0 -41
- package/dist/Drawer/Drawer.css +0 -35
- package/dist/IconButton/IconButton.css +0 -130
- package/dist/Image/index.css +0 -35
- package/dist/Input/Input.css +0 -59
- package/dist/Loading/Loading.css +0 -31
- package/dist/NavBar/NavBar.css +0 -57
- package/dist/Picker/Picker.css +0 -53
- package/dist/Picker/PickerPanel.css +0 -54
- package/dist/Progress/Progress.css +0 -22
- package/dist/Radio/Radio.css +0 -65
- package/dist/Rating/Rating.css +0 -52
- package/dist/Select/Select.css +0 -89
- package/dist/Skeleton/Skeleton.css +0 -54
- package/dist/Slider/Slider.css +0 -95
- package/dist/Stack/demo/index.css +0 -23
- package/dist/Steps/Step.css +0 -174
- package/dist/Swiper/Swiper.css +0 -20
- package/dist/Switch/Switch.css +0 -127
- package/dist/TabBar/TabBarItem.css +0 -38
- package/dist/Tabs/Tab.css +0 -52
- package/dist/Tabs/TabPanel.css +0 -9
- package/dist/Tabs/Tabs.css +0 -56
- package/dist/Tag/Tag.css +0 -97
- package/dist/Tag/TagGroup.css +0 -43
- package/es/ActionSheet/ActionSheet.css +0 -27
- package/es/ActionSheet/ActionSheetItem.css +0 -51
- package/es/Alert/index.css +0 -89
- package/es/Avatar/Avatar.css +0 -43
- package/es/Avatar/AvatarGroup.css +0 -31
- package/es/Badge/Badge.css +0 -95
- package/es/Button/Button.css +0 -200
- package/es/Calendar/Calendar.css +0 -105
- package/es/Card/CardHeader.css +0 -45
- package/es/Checkbox/Checkbox.css +0 -45
- package/es/CitySelector/CitySelector.css +0 -102
- package/es/Countdown/Countdown.css +0 -28
- package/es/Divider/Divider.css +0 -41
- package/es/Drawer/Drawer.css +0 -35
- package/es/IconButton/IconButton.css +0 -130
- package/es/Image/index.css +0 -35
- package/es/Input/Input.css +0 -59
- package/es/Loading/Loading.css +0 -31
- package/es/NavBar/NavBar.css +0 -57
- package/es/Picker/Picker.css +0 -53
- package/es/Picker/PickerPanel.css +0 -54
- package/es/Progress/Progress.css +0 -22
- package/es/Radio/Radio.css +0 -65
- package/es/Rating/Rating.css +0 -52
- package/es/Select/Select.css +0 -89
- package/es/Skeleton/Skeleton.css +0 -54
- package/es/Slider/Slider.css +0 -95
- package/es/Stack/demo/index.css +0 -23
- package/es/Steps/Step.css +0 -174
- package/es/Swiper/Swiper.css +0 -20
- package/es/Switch/Switch.css +0 -127
- package/es/TabBar/TabBarItem.css +0 -38
- package/es/Tabs/Tab.css +0 -52
- package/es/Tabs/TabPanel.css +0 -9
- package/es/Tabs/Tabs.css +0 -56
- package/es/Tag/Tag.css +0 -97
- package/es/Tag/TagGroup.css +0 -43
- /package/dist/Card/{CardContent.css → CardContent.less} +0 -0
- /package/dist/Card/{CardFooter.css → CardFooter.less} +0 -0
- /package/dist/CitySelector/{miniapp.css → miniapp.less} +0 -0
- /package/dist/List/{ListItemExtra.css → ListItemExtra.less} +0 -0
- /package/dist/List/{ListItemHeader.css → ListItemHeader.less} +0 -0
- /package/dist/Stack/{Stack.css → Stack.less} +0 -0
- /package/dist/TabBar/{TabBar.css → TabBar.less} +0 -0
- /package/es/Card/{CardContent.css → CardContent.less} +0 -0
- /package/es/Card/{CardFooter.css → CardFooter.less} +0 -0
- /package/es/CitySelector/{miniapp.css → miniapp.less} +0 -0
- /package/es/List/{ListItemExtra.css → ListItemExtra.less} +0 -0
- /package/es/List/{ListItemHeader.css → ListItemHeader.less} +0 -0
- /package/es/Stack/{Stack.css → Stack.less} +0 -0
- /package/es/TabBar/{TabBar.css → TabBar.less} +0 -0
|
@@ -0,0 +1,108 @@
|
|
|
1
|
+
@import '~@bifrostui/styles/mixins/index.less';
|
|
2
|
+
|
|
3
|
+
.bui-slider {
|
|
4
|
+
--line-color: var(--bui-color-primary);
|
|
5
|
+
--line-bg-color: var(--bui-color-border-default);
|
|
6
|
+
--tooltip-font-size: var(--bui-text-size-3);
|
|
7
|
+
--tooltip-color: var(--bui-color-white);
|
|
8
|
+
--tooltip-bg-color: var(--line-color);
|
|
9
|
+
position: relative;
|
|
10
|
+
width: 100%;
|
|
11
|
+
height: 2px;
|
|
12
|
+
padding: 19px 0;
|
|
13
|
+
box-sizing: border-box;
|
|
14
|
+
font-family: var(--bui-font-family);
|
|
15
|
+
|
|
16
|
+
&-disabled {
|
|
17
|
+
pointer-events: none;
|
|
18
|
+
opacity: 0.5;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
&-line {
|
|
22
|
+
position: absolute;
|
|
23
|
+
top: 50%;
|
|
24
|
+
left: 0;
|
|
25
|
+
height: 2px;
|
|
26
|
+
transform: translateY(-50%);
|
|
27
|
+
background-color: var(--line-color);
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
&-rail {
|
|
31
|
+
position: absolute;
|
|
32
|
+
top: 50%;
|
|
33
|
+
left: 0;
|
|
34
|
+
width: 100%;
|
|
35
|
+
height: 2px;
|
|
36
|
+
transform: translateY(-50%);
|
|
37
|
+
background-color: var(--line-bg-color);
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
&-button {
|
|
41
|
+
display: flex;
|
|
42
|
+
position: absolute;
|
|
43
|
+
justify-content: center;
|
|
44
|
+
align-items: center;
|
|
45
|
+
width: 26px;
|
|
46
|
+
height: 26px;
|
|
47
|
+
background-color: #fff;
|
|
48
|
+
box-shadow: #ddd 0 0 10px;
|
|
49
|
+
border-radius: 50%;
|
|
50
|
+
transform: translate(-50%, -50%);
|
|
51
|
+
font-size: var(--bui-title-size-3);
|
|
52
|
+
cursor: grab;
|
|
53
|
+
|
|
54
|
+
// 增加点击热区大小
|
|
55
|
+
&::after {
|
|
56
|
+
position: absolute;
|
|
57
|
+
content: '';
|
|
58
|
+
top: -10px;
|
|
59
|
+
bottom: -10px;
|
|
60
|
+
left: -10px;
|
|
61
|
+
right: -10px;
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
&-0 {
|
|
65
|
+
left: 0%;
|
|
66
|
+
top: 50%;
|
|
67
|
+
z-index: var(--bui-z-index-affix);
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
&-1 {
|
|
71
|
+
left: 0%;
|
|
72
|
+
top: 50%;
|
|
73
|
+
z-index: var(--bui-z-index-affix);
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
&-tooltip {
|
|
78
|
+
position: absolute;
|
|
79
|
+
top: -14px;
|
|
80
|
+
width: 46px;
|
|
81
|
+
height: 24px;
|
|
82
|
+
line-height: 24px;
|
|
83
|
+
font-size: var(--tooltip-font-size);
|
|
84
|
+
border-radius: 24px;
|
|
85
|
+
color: var(--tooltip-color);
|
|
86
|
+
text-align: center;
|
|
87
|
+
background-color: var(--tooltip-bg-color);
|
|
88
|
+
transform: translate(-50%, -50%);
|
|
89
|
+
z-index: var(--bui-z-index-popover);
|
|
90
|
+
|
|
91
|
+
&::after {
|
|
92
|
+
position: absolute;
|
|
93
|
+
bottom: -10px;
|
|
94
|
+
left: 0;
|
|
95
|
+
right: 0;
|
|
96
|
+
margin: 0 auto;
|
|
97
|
+
content: '';
|
|
98
|
+
width: 0;
|
|
99
|
+
height: 0;
|
|
100
|
+
border: 6px solid transparent;
|
|
101
|
+
border-top: 6px solid var(--tooltip-bg-color);
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
&-hidden {
|
|
105
|
+
display: none;
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
.bui-stack-demo-options {
|
|
2
|
+
display: flex;
|
|
3
|
+
column-gap: 30px;
|
|
4
|
+
|
|
5
|
+
&-title {
|
|
6
|
+
font-weight: 500;
|
|
7
|
+
}
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
@media all and (max-width: 570px) {
|
|
11
|
+
.bui-stack-demo-options {
|
|
12
|
+
display: flex;
|
|
13
|
+
flex-direction: column;
|
|
14
|
+
row-gap: 15px;
|
|
15
|
+
|
|
16
|
+
&-title {
|
|
17
|
+
width: 100%;
|
|
18
|
+
font-size: 16px;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
.bui-radio-group {
|
|
22
|
+
display: flex;
|
|
23
|
+
flex-wrap: wrap;
|
|
24
|
+
align-items: center;
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
}
|
|
@@ -0,0 +1,228 @@
|
|
|
1
|
+
@import '~@bifrostui/styles/mixins/index.less';
|
|
2
|
+
|
|
3
|
+
.bui-step {
|
|
4
|
+
display: flex;
|
|
5
|
+
position: relative;
|
|
6
|
+
line-height: var(--bui-line-height);
|
|
7
|
+
font-family: var(--bui-font-family);
|
|
8
|
+
|
|
9
|
+
&-label-horizontal {
|
|
10
|
+
line-height: 1.8;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
&:last-child {
|
|
14
|
+
.bui-step-line::after {
|
|
15
|
+
display: none;
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
.bui-step-line {
|
|
21
|
+
position: absolute;
|
|
22
|
+
top: 0;
|
|
23
|
+
width: 1px;
|
|
24
|
+
height: 100%;
|
|
25
|
+
box-sizing: border-box;
|
|
26
|
+
left: 13px;
|
|
27
|
+
padding: var(--step-line-padding);
|
|
28
|
+
|
|
29
|
+
&::after {
|
|
30
|
+
display: inline-block;
|
|
31
|
+
content: '';
|
|
32
|
+
width: 1px;
|
|
33
|
+
border-left-width: 1px;
|
|
34
|
+
border-left-style: dotted;
|
|
35
|
+
height: calc(100% + 11px);
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
&-active {
|
|
39
|
+
&::after {
|
|
40
|
+
border-left-color: var(--bui-color-primary);
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
&-wait {
|
|
45
|
+
&::after {
|
|
46
|
+
border-left-color: var(--bui-color-fg-disabled);
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
&-finish {
|
|
51
|
+
&::after {
|
|
52
|
+
border-left-color: var(--bui-color-primary);
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
&-error {
|
|
57
|
+
&::after {
|
|
58
|
+
border-left-color: var(--bui-color-primary);
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
.bui-step-icon {
|
|
64
|
+
flex-shrink: 0;
|
|
65
|
+
width: 28px;
|
|
66
|
+
text-align: center;
|
|
67
|
+
margin: var(--step-icon-margin);
|
|
68
|
+
font-size: var(--bui-title-size-4);
|
|
69
|
+
|
|
70
|
+
&-active {
|
|
71
|
+
width: 12px;
|
|
72
|
+
height: 12px;
|
|
73
|
+
position: relative;
|
|
74
|
+
background-color: var(--bui-color-primary);
|
|
75
|
+
border-radius: 50%;
|
|
76
|
+
margin-top: 2px;
|
|
77
|
+
display: inline-block;
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
.bui-step-content {
|
|
82
|
+
padding: 3px 0;
|
|
83
|
+
box-sizing: border-box;
|
|
84
|
+
flex: 1 0 0;
|
|
85
|
+
overflow: hidden;
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
.bui-step-title-wrapper {
|
|
89
|
+
width: 100%;
|
|
90
|
+
display: flex;
|
|
91
|
+
align-items: center;
|
|
92
|
+
|
|
93
|
+
&-vertical {
|
|
94
|
+
flex-direction: column;
|
|
95
|
+
align-items: flex-start;
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
.bui-step-title {
|
|
100
|
+
font-size: var(--title-font-size);
|
|
101
|
+
font-weight: var(--title-font-weight);
|
|
102
|
+
.ellipsis();
|
|
103
|
+
|
|
104
|
+
&-active {
|
|
105
|
+
color: var(--bui-color-primary);
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
&-wait {
|
|
109
|
+
color: var(--bui-color-fg-subtle);
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
&-finish {
|
|
113
|
+
color: var(--bui-color-primary);
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
&-error {
|
|
117
|
+
color: var(--bui-color-primary);
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
&-horizontal {
|
|
121
|
+
margin-right: 4px;
|
|
122
|
+
max-width: 64%;
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
&-vertical {
|
|
126
|
+
width: 100%;
|
|
127
|
+
}
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
.bui-step-subtitle {
|
|
131
|
+
font-size: var(--subtitle-font-size);
|
|
132
|
+
color: var(--bui-color-fg-subtle);
|
|
133
|
+
.ellipsis();
|
|
134
|
+
|
|
135
|
+
&-horizontal {
|
|
136
|
+
flex: 1;
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
&-vertical {
|
|
140
|
+
width: 100%;
|
|
141
|
+
}
|
|
142
|
+
}
|
|
143
|
+
|
|
144
|
+
.bui-step-desc {
|
|
145
|
+
font-size: var(--bui-text-size-3);
|
|
146
|
+
color: var(--bui-color-fg-subtle);
|
|
147
|
+
margin-right: var(--bui-spacing-lg);
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
.bui-step-horizontal {
|
|
151
|
+
flex: 1;
|
|
152
|
+
padding-left: var(--bui-spacing-sm);
|
|
153
|
+
|
|
154
|
+
&:first-child {
|
|
155
|
+
padding-left: 0;
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
&:last-child {
|
|
159
|
+
.bui-step-title-wrapper::after {
|
|
160
|
+
display: none;
|
|
161
|
+
}
|
|
162
|
+
}
|
|
163
|
+
|
|
164
|
+
.bui-step-line {
|
|
165
|
+
display: none;
|
|
166
|
+
padding: 28px 0 6px;
|
|
167
|
+
}
|
|
168
|
+
|
|
169
|
+
.bui-step-icon {
|
|
170
|
+
margin-right: 0;
|
|
171
|
+
}
|
|
172
|
+
|
|
173
|
+
.bui-step-title-wrapper {
|
|
174
|
+
width: fit-content;
|
|
175
|
+
position: relative;
|
|
176
|
+
|
|
177
|
+
&::after {
|
|
178
|
+
position: absolute;
|
|
179
|
+
width: 9999px;
|
|
180
|
+
height: 1px;
|
|
181
|
+
content: '';
|
|
182
|
+
left: 100%;
|
|
183
|
+
top: 0;
|
|
184
|
+
bottom: 0;
|
|
185
|
+
margin: auto 0;
|
|
186
|
+
}
|
|
187
|
+
|
|
188
|
+
&-line-active {
|
|
189
|
+
&::after {
|
|
190
|
+
background: var(--bui-color-fg-disabled);
|
|
191
|
+
}
|
|
192
|
+
}
|
|
193
|
+
|
|
194
|
+
&-line-wait {
|
|
195
|
+
&::after {
|
|
196
|
+
background: var(--bui-color-fg-disabled);
|
|
197
|
+
}
|
|
198
|
+
}
|
|
199
|
+
|
|
200
|
+
&-line-finish {
|
|
201
|
+
&::after {
|
|
202
|
+
background: var(--bui-color-primary);
|
|
203
|
+
}
|
|
204
|
+
}
|
|
205
|
+
|
|
206
|
+
&-line-error {
|
|
207
|
+
&::after {
|
|
208
|
+
background: var(--bui-color-primary);
|
|
209
|
+
}
|
|
210
|
+
}
|
|
211
|
+
}
|
|
212
|
+
|
|
213
|
+
.bui-step-title {
|
|
214
|
+
padding-right: var(--bui-spacing-sm);
|
|
215
|
+
margin-right: 0;
|
|
216
|
+
max-width: unset;
|
|
217
|
+
}
|
|
218
|
+
|
|
219
|
+
.bui-step-subtitle {
|
|
220
|
+
padding-right: var(--bui-spacing-sm);
|
|
221
|
+
margin-right: 0;
|
|
222
|
+
}
|
|
223
|
+
}
|
|
224
|
+
|
|
225
|
+
.bui-step-disabled {
|
|
226
|
+
opacity: 0.5;
|
|
227
|
+
pointer-events: none;
|
|
228
|
+
}
|
|
@@ -5,10 +5,12 @@
|
|
|
5
5
|
--description-font-size: var(--bui-text-size-3);
|
|
6
6
|
--step-icon-margin: var(--bui-spacing-xs) var(--bui-spacing-xs) 0 0;
|
|
7
7
|
--step-line-padding: 20px 0 3px 0;
|
|
8
|
+
|
|
8
9
|
display: flex;
|
|
9
10
|
font-size: var(--bui-title-size-3);
|
|
10
11
|
font-family: var(--bui-font-family);
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
12
|
+
|
|
13
|
+
&-vertical {
|
|
14
|
+
flex-direction: column;
|
|
15
|
+
}
|
|
14
16
|
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
.bui-swiper {
|
|
2
|
+
font-family: var(--bui-font-family);
|
|
3
|
+
|
|
4
|
+
.swiper-container-wrapper {
|
|
5
|
+
height: 150px;
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
.swiper-container {
|
|
9
|
+
height: 100%;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
.swiper-pagination {
|
|
13
|
+
font-size: 0;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
.swiper-pagination-bullet {
|
|
17
|
+
opacity: 1;
|
|
18
|
+
background: var(--indicator-color);
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
.swiper-pagination-bullet-active {
|
|
22
|
+
opacity: 1;
|
|
23
|
+
background: var(--indicator-color-active);
|
|
24
|
+
}
|
|
25
|
+
}
|
|
@@ -0,0 +1,177 @@
|
|
|
1
|
+
@duration: 0.3s;
|
|
2
|
+
|
|
3
|
+
.switch-bg(@color) {
|
|
4
|
+
background-color: var(~'--bui-color-@{color}');
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
.bui-switch {
|
|
8
|
+
--bg-color: #ccc;
|
|
9
|
+
position: relative;
|
|
10
|
+
display: inline-block;
|
|
11
|
+
box-sizing: border-box;
|
|
12
|
+
padding: 0;
|
|
13
|
+
vertical-align: middle;
|
|
14
|
+
border-radius: 15px;
|
|
15
|
+
background-color: var(--bg-color);
|
|
16
|
+
transition: all @duration cubic-bezier(0.35, 0, 0.25, 1);
|
|
17
|
+
font-family: var(--bui-font-family);
|
|
18
|
+
|
|
19
|
+
&::after {
|
|
20
|
+
position: absolute;
|
|
21
|
+
left: 2px;
|
|
22
|
+
top: 2px;
|
|
23
|
+
border-radius: 50%;
|
|
24
|
+
background-color: #fff;
|
|
25
|
+
content: ' ';
|
|
26
|
+
cursor: pointer;
|
|
27
|
+
box-shadow: 0 2px 5px rgba(0, 0, 0, 0.26);
|
|
28
|
+
transition: left @duration cubic-bezier(0.35, 0, 0.25, 1);
|
|
29
|
+
animation-timing-function: cubic-bezier(0.35, 0, 0.25, 1);
|
|
30
|
+
animation-duration: @duration;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
&:focus {
|
|
34
|
+
outline: none;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
// 尺寸
|
|
38
|
+
&-small {
|
|
39
|
+
width: 24px;
|
|
40
|
+
height: 16px;
|
|
41
|
+
|
|
42
|
+
.bui-switch-inner {
|
|
43
|
+
left: calc(100% - 10px);
|
|
44
|
+
font-size: 9px;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
&::after {
|
|
48
|
+
width: 12px;
|
|
49
|
+
height: 12px;
|
|
50
|
+
left: 2px;
|
|
51
|
+
top: 2px;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
&.bui-switch-checked {
|
|
55
|
+
&::after {
|
|
56
|
+
left: calc(100% - 14px);
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
.bui-switch-inner {
|
|
60
|
+
left: 2px;
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
&-medium {
|
|
66
|
+
width: 44px;
|
|
67
|
+
height: 22px;
|
|
68
|
+
|
|
69
|
+
&::after {
|
|
70
|
+
width: 18px;
|
|
71
|
+
height: 18px;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
&.bui-switch-checked {
|
|
75
|
+
&::after {
|
|
76
|
+
left: calc(100% - 20px);
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
.bui-switch-inner {
|
|
80
|
+
left: var(--bui-spacing-sm);
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
&-large {
|
|
86
|
+
width: 51px;
|
|
87
|
+
height: 30px;
|
|
88
|
+
|
|
89
|
+
.bui-switch-inner {
|
|
90
|
+
left: calc(100% - 22px);
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
&::after {
|
|
94
|
+
width: 24px;
|
|
95
|
+
height: 24px;
|
|
96
|
+
left: 3px;
|
|
97
|
+
top: 3px;
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
&.bui-switch-checked {
|
|
101
|
+
&::after {
|
|
102
|
+
left: calc(100% - 27px);
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
.bui-switch-inner {
|
|
106
|
+
left: var(--bui-spacing-sm);
|
|
107
|
+
}
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
// 颜色
|
|
112
|
+
&-primary {
|
|
113
|
+
&.bui-switch-checked {
|
|
114
|
+
.switch-bg(primary);
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
&-info {
|
|
119
|
+
&.bui-switch-checked {
|
|
120
|
+
.switch-bg(info);
|
|
121
|
+
}
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
&-success {
|
|
125
|
+
&.bui-switch-checked {
|
|
126
|
+
.switch-bg(success);
|
|
127
|
+
}
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
&-warning {
|
|
131
|
+
&.bui-switch-checked {
|
|
132
|
+
.switch-bg(warning);
|
|
133
|
+
}
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
&-danger {
|
|
137
|
+
&.bui-switch-checked {
|
|
138
|
+
.switch-bg(danger);
|
|
139
|
+
}
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
&-inner {
|
|
143
|
+
position: absolute;
|
|
144
|
+
left: calc(100% - 20px);
|
|
145
|
+
color: var(--bui-color-white);
|
|
146
|
+
font-size: var(--bui-text-size-3);
|
|
147
|
+
height: 100%;
|
|
148
|
+
display: flex;
|
|
149
|
+
align-items: center;
|
|
150
|
+
|
|
151
|
+
.bui-svg-icon {
|
|
152
|
+
position: absolute;
|
|
153
|
+
top: 50%;
|
|
154
|
+
transform: translateY(-50%);
|
|
155
|
+
}
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
&-disabled {
|
|
159
|
+
pointer-events: none;
|
|
160
|
+
opacity: 0.5;
|
|
161
|
+
|
|
162
|
+
&::after {
|
|
163
|
+
animation-name: none;
|
|
164
|
+
cursor: not-allowed;
|
|
165
|
+
}
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
&-input {
|
|
169
|
+
opacity: 0;
|
|
170
|
+
width: 100%;
|
|
171
|
+
height: 100%;
|
|
172
|
+
margin: 0;
|
|
173
|
+
position: absolute;
|
|
174
|
+
z-index: 1;
|
|
175
|
+
cursor: pointer;
|
|
176
|
+
}
|
|
177
|
+
}
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
.bui-tab-bar-color(@color) {
|
|
2
|
+
color: var(~'--bui-color-@{color}');
|
|
3
|
+
}
|
|
4
|
+
|
|
5
|
+
.bui-tab-bar-item {
|
|
6
|
+
--bui-tab-bar-color: var(
|
|
7
|
+
--bui-tab-bar-default-color,
|
|
8
|
+
var(--bui-color-fg-default)
|
|
9
|
+
);
|
|
10
|
+
|
|
11
|
+
display: flex;
|
|
12
|
+
align-items: center;
|
|
13
|
+
justify-content: center;
|
|
14
|
+
flex-direction: column;
|
|
15
|
+
flex: 1;
|
|
16
|
+
color: var(--bui-tab-bar-color);
|
|
17
|
+
font-family: var(--bui-font-family);
|
|
18
|
+
|
|
19
|
+
&-primary {
|
|
20
|
+
.bui-tab-bar-color(primary);
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
&-success {
|
|
24
|
+
.bui-tab-bar-color(success);
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
&-info {
|
|
28
|
+
.bui-tab-bar-color(info);
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
&-warning {
|
|
32
|
+
.bui-tab-bar-color(warning);
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
&-danger {
|
|
36
|
+
.bui-tab-bar-color(danger);
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
&-vip {
|
|
40
|
+
.bui-tab-bar-color(vip);
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
.bui-badge {
|
|
44
|
+
display: flex;
|
|
45
|
+
flex-direction: column;
|
|
46
|
+
align-items: center;
|
|
47
|
+
justify-content: center;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
.bui-badge-position .bui-badge-contained,
|
|
51
|
+
.bui-badge-position .bui-badge-outlined {
|
|
52
|
+
top: 0;
|
|
53
|
+
}
|
|
54
|
+
}
|
package/es/Tabs/Tab.js
CHANGED
|
@@ -25,7 +25,7 @@ var Tab = /*#__PURE__*/React.forwardRef(function (props, ref) {
|
|
|
25
25
|
triggerChange = tabsContext.triggerChange;
|
|
26
26
|
return /*#__PURE__*/React.createElement("div", _extends({
|
|
27
27
|
ref: ref,
|
|
28
|
-
className: clsx(prefixCls, "".concat(prefixCls, "-").concat(align), _defineProperty(_defineProperty(_defineProperty({}, "".concat(prefixCls, "-active"), !isMini && index === value), "".concat(prefixCls, "-miniapp-active"), isMini && index === value), "".concat(prefixCls, "-disabled"), disabled), className)
|
|
28
|
+
className: clsx(prefixCls, align !== 'start' && "".concat(prefixCls, "-").concat(align), _defineProperty(_defineProperty(_defineProperty({}, "".concat(prefixCls, "-active"), !isMini && index === value), "".concat(prefixCls, "-miniapp-active"), isMini && index === value), "".concat(prefixCls, "-disabled"), disabled), className)
|
|
29
29
|
}, others, {
|
|
30
30
|
onClick: function onClick(e) {
|
|
31
31
|
if (disabled) return;
|
package/es/Tabs/Tab.less
ADDED
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
@holderWidth: 12px;
|
|
2
|
+
|
|
3
|
+
.bui-tab {
|
|
4
|
+
display: flex;
|
|
5
|
+
align-items: center;
|
|
6
|
+
justify-content: center;
|
|
7
|
+
white-space: nowrap;
|
|
8
|
+
width: min-content;
|
|
9
|
+
height: 100%;
|
|
10
|
+
box-sizing: border-box;
|
|
11
|
+
position: relative;
|
|
12
|
+
cursor: pointer;
|
|
13
|
+
font-size: var(--font-size);
|
|
14
|
+
line-height: var(--bui-line-height);
|
|
15
|
+
color: var(--color);
|
|
16
|
+
padding: var(--bui-spacing-lg) var(--bui-spacing-lg) 10px;
|
|
17
|
+
font-family: var(--bui-font-family);
|
|
18
|
+
|
|
19
|
+
&-center {
|
|
20
|
+
flex: 1 0 auto;
|
|
21
|
+
margin: 0 auto;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
&-active {
|
|
25
|
+
font-size: var(--font-size);
|
|
26
|
+
line-height: var(--bui-line-height);
|
|
27
|
+
font-weight: var(--bui-font-weight-medium);
|
|
28
|
+
color: var(--active-color);
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
&-miniapp-active {
|
|
32
|
+
font-size: var(--font-size);
|
|
33
|
+
line-height: 1.5;
|
|
34
|
+
font-weight: var(--bui-font-weight-medium);
|
|
35
|
+
color: var(--active-color);
|
|
36
|
+
position: relative;
|
|
37
|
+
|
|
38
|
+
&-line {
|
|
39
|
+
position: absolute;
|
|
40
|
+
bottom: 0;
|
|
41
|
+
left: -@holderWidth;
|
|
42
|
+
right: -@holderWidth;
|
|
43
|
+
margin: 0 auto !important;
|
|
44
|
+
width: 18px;
|
|
45
|
+
height: 2px;
|
|
46
|
+
transition: all 100ms cubic-bezier(0.4, 0, 0.2, 1) 0ms;
|
|
47
|
+
background-color: var(--line-color);
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
&-disabled {
|
|
52
|
+
opacity: 0.5;
|
|
53
|
+
pointer-events: none;
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
.bui-tabline-invisible {
|
|
58
|
+
visibility: hidden;
|
|
59
|
+
background-color: transparent;
|
|
60
|
+
}
|