rsuite 4.8.5 → 4.8.9
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/CHANGELOG.md +49 -0
- package/dist/rsuite.js +21 -21
- package/dist/rsuite.min.js +1 -1
- package/dist/rsuite.min.js.map +1 -1
- package/dist/styles/rsuite-dark-rtl.css +46 -52
- package/dist/styles/rsuite-dark-rtl.min.css +1 -1
- package/dist/styles/rsuite-dark-rtl.min.css.map +1 -1
- package/dist/styles/rsuite-dark.css +46 -52
- package/dist/styles/rsuite-dark.min.css +1 -1
- package/dist/styles/rsuite-dark.min.css.map +1 -1
- package/dist/styles/rsuite-default-rtl.css +46 -52
- package/dist/styles/rsuite-default-rtl.min.css +1 -1
- package/dist/styles/rsuite-default-rtl.min.css.map +1 -1
- package/dist/styles/rsuite-default.css +46 -52
- package/dist/styles/rsuite-default.min.css +1 -1
- package/dist/styles/rsuite-default.min.css.map +1 -1
- package/es/Alert/styles/common.less +1 -1
- package/es/AutoComplete/styles/common.less +3 -3
- package/es/Avatar/styles/common.less +5 -5
- package/es/Avatar/styles/mixin.less +1 -1
- package/es/Button/styles/common.less +6 -6
- package/es/Button/styles/mixin.less +17 -17
- package/es/ButtonGroup/styles/common.less +5 -5
- package/es/Calendar/styles/common.less +14 -14
- package/es/Carousel/styles/common.less +1 -1
- package/es/Cascader/Cascader.js +2 -1
- package/es/Cascader/styles/common.less +4 -4
- package/es/CheckPicker/CheckPicker.js +2 -1
- package/es/CheckPicker/styles/common.less +2 -2
- package/es/CheckTreePicker/CheckTreePicker.js +2 -1
- package/es/CheckTreePicker/styles/common.less +5 -5
- package/es/Checkbox/styles/common.less +3 -3
- package/es/Checkbox/styles/mixin.less +1 -1
- package/es/DatePicker/DatePicker.js +2 -1
- package/es/DatePicker/styles/common.less +1 -1
- package/es/DateRangePicker/DateRangePicker.js +2 -1
- package/es/Drawer/styles/common.less +5 -5
- package/es/Dropdown/Dropdown.js +13 -4
- package/es/Dropdown/styles/common.less +3 -3
- package/es/FlexboxGrid/styles/common.less +1 -1
- package/es/Form/styles/common.less +2 -1
- package/es/Form/styles/mixin.less +4 -4
- package/es/FormControl/styles/common.less +0 -1
- package/es/FormGroup/styles/common.less +1 -1
- package/es/Grid/styles/common.less +1 -1
- package/es/Grid/styles/mixin.less +2 -2
- package/es/HelpBlock/styles/common.less +1 -1
- package/es/IconButton/styles/common.less +16 -14
- package/es/Input/styles/common.less +6 -10
- package/es/InputGroup/styles/common.less +1 -1
- package/es/InputNumber/styles/mixin.less +2 -2
- package/es/InputPicker/InputAutosize.js +11 -6
- package/es/InputPicker/styles/common.less +4 -4
- package/es/Loader/styles/common.less +3 -3
- package/es/Loader/styles/mixin.less +2 -2
- package/es/Message/styles/common.less +3 -3
- package/es/Modal/BaseModal.js +1 -1
- package/es/Modal/Modal.js +5 -5
- package/es/Modal/ModalDialog.js +3 -1
- package/es/Modal/styles/common.less +5 -5
- package/es/MultiCascader/MultiCascader.js +2 -1
- package/es/MultiCascader/styles/common.less +1 -1
- package/es/Nav/styles/common.less +2 -2
- package/es/Navbar/styles/common.less +2 -2
- package/es/Notification/styles/common.less +4 -4
- package/es/Overlay/Overlay.js +1 -1
- package/es/Pagination/styles/common.less +2 -2
- package/es/Pagination/styles/mixin.less +6 -7
- package/es/Panel/Panel.js +0 -1
- package/es/Panel/styles/common.less +1 -1
- package/es/Picker/DropdownMenu.js +3 -1
- package/es/Picker/propTypes.js +1 -1
- package/es/Picker/styles/common.less +28 -28
- package/es/Picker/styles/mixin.less +3 -3
- package/es/Popover/styles/common.less +4 -4
- package/es/Progress/styles/common.less +5 -5
- package/es/Radio/styles/common.less +5 -5
- package/es/Rate/styles/common.less +2 -2
- package/es/SelectPicker/SelectPicker.js +2 -1
- package/es/SelectPicker/styles/common.less +4 -4
- package/es/Sidenav/styles/common.less +3 -3
- package/es/Slider/styles/common.less +9 -9
- package/es/Steps/styles/common.less +13 -13
- package/es/Table/styles/common.less +6 -10
- package/es/Tag/styles/common.less +2 -2
- package/es/TagPicker/styles/common.less +4 -4
- package/es/Timeline/styles/common.less +5 -5
- package/es/Timeline/styles/mixin.less +1 -1
- package/es/Toggle/styles/mixin.less +5 -5
- package/es/Tooltip/styles/common.less +4 -4
- package/es/TreePicker/TreePicker.js +2 -1
- package/es/TreePicker/styles/common.less +3 -3
- package/es/Uploader/styles/common.less +17 -17
- package/es/styles/mixins/utilities.less +1 -1
- package/es/styles/variables.less +58 -48
- package/es/utils/index.js +2 -1
- package/lib/Alert/styles/common.less +1 -1
- package/lib/AutoComplete/styles/common.less +3 -3
- package/lib/Avatar/styles/common.less +5 -5
- package/lib/Avatar/styles/mixin.less +1 -1
- package/lib/Button/styles/common.less +6 -6
- package/lib/Button/styles/mixin.less +17 -17
- package/lib/ButtonGroup/styles/common.less +5 -5
- package/lib/Calendar/styles/common.less +14 -14
- package/lib/Carousel/styles/common.less +1 -1
- package/lib/Cascader/Cascader.js +2 -1
- package/lib/Cascader/styles/common.less +4 -4
- package/lib/CheckPicker/CheckPicker.js +2 -1
- package/lib/CheckPicker/styles/common.less +2 -2
- package/lib/CheckTreePicker/CheckTreePicker.js +2 -1
- package/lib/CheckTreePicker/styles/common.less +5 -5
- package/lib/Checkbox/styles/common.less +3 -3
- package/lib/Checkbox/styles/mixin.less +1 -1
- package/lib/DatePicker/DatePicker.js +2 -1
- package/lib/DatePicker/styles/common.less +1 -1
- package/lib/DateRangePicker/DateRangePicker.js +2 -1
- package/lib/Drawer/styles/common.less +5 -5
- package/lib/Dropdown/Dropdown.js +13 -3
- package/lib/Dropdown/styles/common.less +3 -3
- package/lib/FlexboxGrid/styles/common.less +1 -1
- package/lib/Form/styles/common.less +2 -1
- package/lib/Form/styles/mixin.less +4 -4
- package/lib/FormControl/styles/common.less +0 -1
- package/lib/FormGroup/styles/common.less +1 -1
- package/lib/Grid/styles/common.less +1 -1
- package/lib/Grid/styles/mixin.less +2 -2
- package/lib/HelpBlock/styles/common.less +1 -1
- package/lib/IconButton/styles/common.less +16 -14
- package/lib/Input/styles/common.less +6 -10
- package/lib/InputGroup/styles/common.less +1 -1
- package/lib/InputNumber/styles/mixin.less +2 -2
- package/lib/InputPicker/InputAutosize.js +11 -6
- package/lib/InputPicker/styles/common.less +4 -4
- package/lib/Loader/styles/common.less +3 -3
- package/lib/Loader/styles/mixin.less +2 -2
- package/lib/Message/styles/common.less +3 -3
- package/lib/Modal/BaseModal.js +1 -1
- package/lib/Modal/Modal.js +5 -5
- package/lib/Modal/ModalDialog.js +3 -1
- package/lib/Modal/styles/common.less +5 -5
- package/lib/MultiCascader/MultiCascader.js +2 -1
- package/lib/MultiCascader/styles/common.less +1 -1
- package/lib/Nav/styles/common.less +2 -2
- package/lib/Navbar/styles/common.less +2 -2
- package/lib/Notification/styles/common.less +4 -4
- package/lib/Overlay/Overlay.js +1 -1
- package/lib/Pagination/styles/common.less +2 -2
- package/lib/Pagination/styles/mixin.less +6 -7
- package/lib/Panel/Panel.js +0 -1
- package/lib/Panel/styles/common.less +1 -1
- package/lib/Picker/DropdownMenu.js +3 -1
- package/lib/Picker/propTypes.js +1 -1
- package/lib/Picker/styles/common.less +28 -28
- package/lib/Picker/styles/mixin.less +3 -3
- package/lib/Popover/styles/common.less +4 -4
- package/lib/Progress/styles/common.less +5 -5
- package/lib/Radio/styles/common.less +5 -5
- package/lib/Rate/styles/common.less +2 -2
- package/lib/SelectPicker/SelectPicker.js +2 -1
- package/lib/SelectPicker/styles/common.less +4 -4
- package/lib/Sidenav/styles/common.less +3 -3
- package/lib/Slider/styles/common.less +9 -9
- package/lib/Steps/styles/common.less +13 -13
- package/lib/Table/styles/common.less +6 -10
- package/lib/Tag/styles/common.less +2 -2
- package/lib/TagPicker/styles/common.less +4 -4
- package/lib/Timeline/styles/common.less +5 -5
- package/lib/Timeline/styles/mixin.less +1 -1
- package/lib/Toggle/styles/mixin.less +5 -5
- package/lib/Tooltip/styles/common.less +4 -4
- package/lib/TreePicker/TreePicker.js +2 -1
- package/lib/TreePicker/styles/common.less +3 -3
- package/lib/Uploader/styles/common.less +17 -17
- package/lib/styles/mixins/utilities.less +1 -1
- package/lib/styles/variables.less +58 -48
- package/lib/utils/index.js +7 -2
- package/package.json +7 -5
- package/src/Alert/styles/common.less +1 -1
- package/src/AutoComplete/styles/common.less +3 -3
- package/src/Avatar/styles/common.less +5 -5
- package/src/Avatar/styles/mixin.less +1 -1
- package/src/Button/styles/common.less +6 -6
- package/src/Button/styles/mixin.less +17 -17
- package/src/ButtonGroup/styles/common.less +5 -5
- package/src/Calendar/styles/common.less +14 -14
- package/src/Carousel/styles/common.less +1 -1
- package/src/Cascader/Cascader.tsx +1 -0
- package/src/Cascader/styles/common.less +4 -4
- package/src/Cascader/test/CascaderSpec.js +1 -0
- package/src/CheckPicker/CheckPicker.tsx +1 -0
- package/src/CheckPicker/styles/common.less +2 -2
- package/src/CheckPicker/test/CheckPickerSpec.js +1 -0
- package/src/CheckTreePicker/CheckTreePicker.tsx +1 -0
- package/src/CheckTreePicker/styles/common.less +5 -5
- package/src/CheckTreePicker/test/CheckTreePickerSpec.js +1 -0
- package/src/Checkbox/styles/common.less +3 -3
- package/src/Checkbox/styles/mixin.less +1 -1
- package/src/DatePicker/DatePicker.tsx +1 -0
- package/src/DatePicker/styles/common.less +1 -1
- package/src/DatePicker/test/DatePickerSpec.js +1 -0
- package/src/DateRangePicker/DateRangePicker.tsx +1 -0
- package/src/DateRangePicker/test/DateRangePickerSpec.js +1 -0
- package/src/Drawer/styles/common.less +5 -5
- package/src/Drawer/test/DrawerSpec.js +14 -0
- package/src/Dropdown/Dropdown.tsx +20 -6
- package/src/Dropdown/styles/common.less +3 -3
- package/src/FlexboxGrid/styles/common.less +1 -1
- package/src/Form/styles/common.less +2 -1
- package/src/Form/styles/mixin.less +4 -4
- package/src/FormControl/styles/common.less +0 -1
- package/src/FormGroup/styles/common.less +1 -1
- package/src/Grid/styles/common.less +1 -1
- package/src/Grid/styles/mixin.less +2 -2
- package/src/HelpBlock/styles/common.less +1 -1
- package/src/IconButton/styles/common.less +16 -14
- package/src/Input/styles/common.less +6 -10
- package/src/Input/test/InputStylesSpec.js +0 -8
- package/src/InputGroup/styles/common.less +1 -1
- package/src/InputNumber/styles/mixin.less +2 -2
- package/src/InputPicker/InputAutosize.tsx +15 -10
- package/src/InputPicker/styles/common.less +4 -4
- package/src/Loader/styles/common.less +3 -3
- package/src/Loader/styles/mixin.less +2 -2
- package/src/Message/styles/common.less +3 -3
- package/src/Modal/BaseModal.tsx +1 -6
- package/src/Modal/Modal.tsx +5 -5
- package/src/Modal/ModalDialog.tsx +3 -1
- package/src/Modal/styles/common.less +5 -5
- package/src/Modal/test/ModalSpec.js +13 -0
- package/src/MultiCascader/MultiCascader.tsx +1 -0
- package/src/MultiCascader/styles/common.less +1 -1
- package/src/MultiCascader/test/MultiCascaderSpec.js +1 -0
- package/src/Nav/styles/common.less +2 -2
- package/src/Navbar/styles/common.less +2 -2
- package/src/Notification/styles/common.less +4 -4
- package/src/Overlay/Overlay.tsx +1 -1
- package/src/Pagination/styles/common.less +2 -2
- package/src/Pagination/styles/mixin.less +6 -7
- package/src/Panel/Panel.tsx +0 -1
- package/src/Panel/styles/common.less +1 -1
- package/src/Picker/DropdownMenu.tsx +3 -1
- package/src/Picker/propTypes.ts +1 -1
- package/src/Picker/styles/common.less +28 -28
- package/src/Picker/styles/mixin.less +3 -3
- package/src/Picker/test/DropdownMenuSpec.js +21 -0
- package/src/Popover/styles/common.less +4 -4
- package/src/Popover/test/PopoverStylesSpec.js +1 -1
- package/src/Progress/styles/common.less +5 -5
- package/src/Radio/styles/common.less +5 -5
- package/src/Rate/styles/common.less +2 -2
- package/src/SelectPicker/SelectPicker.tsx +1 -0
- package/src/SelectPicker/styles/common.less +4 -4
- package/src/SelectPicker/test/SelectPickerSpec.js +1 -0
- package/src/Sidenav/styles/common.less +3 -3
- package/src/Slider/styles/common.less +9 -9
- package/src/Steps/styles/common.less +13 -13
- package/src/Table/styles/common.less +6 -10
- package/src/Tag/styles/common.less +2 -2
- package/src/TagPicker/styles/common.less +4 -4
- package/src/Timeline/styles/common.less +5 -5
- package/src/Timeline/styles/mixin.less +1 -1
- package/src/Toggle/styles/mixin.less +5 -5
- package/src/Tooltip/styles/common.less +4 -4
- package/src/TreePicker/TreePicker.tsx +1 -0
- package/src/TreePicker/styles/common.less +3 -3
- package/src/TreePicker/test/TreePickerSpec.js +1 -0
- package/src/Uploader/styles/common.less +17 -17
- package/src/styles/mixins/utilities.less +1 -1
- package/src/styles/variables.less +58 -48
- package/src/utils/index.ts +1 -0
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
border: none;
|
|
13
13
|
user-select: none;
|
|
14
14
|
|
|
15
|
-
.btn-md;
|
|
15
|
+
.btn-md();
|
|
16
16
|
|
|
17
17
|
&:hover,
|
|
18
18
|
&:focus {
|
|
@@ -57,7 +57,7 @@
|
|
|
57
57
|
|
|
58
58
|
// Subtle button style
|
|
59
59
|
.btn-subtle() {
|
|
60
|
-
.btn-transition;
|
|
60
|
+
.btn-transition();
|
|
61
61
|
.btn-subtle-variant(@btn-subtle-hover-bg);
|
|
62
62
|
.btn-loading-reset(@btn-subtle-color);
|
|
63
63
|
|
|
@@ -155,8 +155,8 @@
|
|
|
155
155
|
|
|
156
156
|
// Full button size
|
|
157
157
|
.button-size(@padding-vertical; @padding-horizontal; @font-size; @line-height; @border-radius) {
|
|
158
|
-
@icon-side-length: @padding-vertical*2 + floor(@font-size* @line-height);
|
|
159
|
-
@ghost-icon-side-length: @icon-side-length - @btn-ghost-border-width*2;
|
|
158
|
+
@icon-side-length: ((@padding-vertical*2) + floor(@font-size* @line-height));
|
|
159
|
+
@ghost-icon-side-length: (@icon-side-length - @btn-ghost-border-width*2);
|
|
160
160
|
@svg-icon-height: @font-size;
|
|
161
161
|
|
|
162
162
|
.button-size(
|
|
@@ -171,23 +171,23 @@
|
|
|
171
171
|
|
|
172
172
|
// Button icon
|
|
173
173
|
&.@{ns}btn-icon {
|
|
174
|
-
padding-left: @icon-side-length - @padding-horizontal;
|
|
174
|
+
padding-left: (@icon-side-length - @padding-horizontal);
|
|
175
175
|
height: @icon-side-length;
|
|
176
176
|
position: relative;
|
|
177
177
|
|
|
178
178
|
// Ghost button need minus border-width.
|
|
179
179
|
.@{ns}btn-ghost& {
|
|
180
|
-
padding-left: @icon-side-length - @padding-horizontal - @btn-ghost-border-width*2;
|
|
180
|
+
padding-left: (@icon-side-length - @padding-horizontal - @btn-ghost-border-width * 2);
|
|
181
181
|
}
|
|
182
182
|
|
|
183
183
|
&.@{ns}btn-icon-with-text {
|
|
184
184
|
&.@{ns}btn-icon-placement-left {
|
|
185
|
-
padding-left: @icon-side-length + @padding-vertical;
|
|
185
|
+
padding-left: (@icon-side-length + @padding-vertical);
|
|
186
186
|
}
|
|
187
187
|
|
|
188
188
|
&.@{ns}btn-icon-placement-right {
|
|
189
189
|
padding-left: @padding-base-input-horizontal;
|
|
190
|
-
padding-right: @icon-side-length + @padding-vertical;
|
|
190
|
+
padding-right: (@icon-side-length + @padding-vertical);
|
|
191
191
|
|
|
192
192
|
> .@{ns}icon {
|
|
193
193
|
left: auto;
|
|
@@ -231,7 +231,7 @@
|
|
|
231
231
|
/* stylelint-disable */ //Formatted by prettier
|
|
232
232
|
.button-size(
|
|
233
233
|
base; @padding-small-vertical; @padding-small-horizontal; @font-size-base; @line-height-base;
|
|
234
|
-
|
|
234
|
+
@btn-border-radius-small
|
|
235
235
|
);
|
|
236
236
|
/* stylelint-enable */
|
|
237
237
|
}
|
|
@@ -240,7 +240,7 @@
|
|
|
240
240
|
/* stylelint-disable */ //Formatted by prettier
|
|
241
241
|
.button-size(
|
|
242
242
|
base; @padding-base-vertical; @padding-base-horizontal; @font-size-base; @line-height-base;
|
|
243
|
-
|
|
243
|
+
@btn-border-radius-base
|
|
244
244
|
);
|
|
245
245
|
/* stylelint-enable */
|
|
246
246
|
}
|
|
@@ -249,7 +249,7 @@
|
|
|
249
249
|
/* stylelint-disable */ //Formatted by prettier
|
|
250
250
|
.button-size(
|
|
251
251
|
base; @padding-extra-small-vertical; @padding-extra-small-horizontal; @font-size-small;
|
|
252
|
-
|
|
252
|
+
@line-height-small; @btn-border-radius-small
|
|
253
253
|
);
|
|
254
254
|
/* stylelint-enable */
|
|
255
255
|
}
|
|
@@ -258,7 +258,7 @@
|
|
|
258
258
|
/* stylelint-disable */ //Formatted by prettier
|
|
259
259
|
.button-size(
|
|
260
260
|
base; @padding-large-vertical; @padding-large-horizontal; @font-size-large; @line-height-large;
|
|
261
|
-
|
|
261
|
+
@btn-border-radius-large
|
|
262
262
|
);
|
|
263
263
|
/* stylelint-enable */
|
|
264
264
|
}
|
|
@@ -268,7 +268,7 @@
|
|
|
268
268
|
/* stylelint-disable */ //Formatted by prettier
|
|
269
269
|
.button-size(
|
|
270
270
|
@padding-small-vertical; @padding-small-horizontal; @font-size-base; @line-height-base;
|
|
271
|
-
|
|
271
|
+
@btn-border-radius-small
|
|
272
272
|
);
|
|
273
273
|
/* stylelint-enable */
|
|
274
274
|
}
|
|
@@ -277,7 +277,7 @@
|
|
|
277
277
|
/* stylelint-disable */ //Formatted by prettier
|
|
278
278
|
.button-size(
|
|
279
279
|
@padding-base-vertical; @padding-base-horizontal; @font-size-base; @line-height-base;
|
|
280
|
-
|
|
280
|
+
@btn-border-radius-base
|
|
281
281
|
);
|
|
282
282
|
/* stylelint-enable */
|
|
283
283
|
}
|
|
@@ -286,7 +286,7 @@
|
|
|
286
286
|
/* stylelint-disable */ //Formatted by prettier
|
|
287
287
|
.button-size(
|
|
288
288
|
@padding-extra-small-vertical; @padding-extra-small-horizontal; @font-size-small;
|
|
289
|
-
|
|
289
|
+
@line-height-small; @btn-border-radius-small
|
|
290
290
|
);
|
|
291
291
|
/* stylelint-enable */
|
|
292
292
|
}
|
|
@@ -295,7 +295,7 @@
|
|
|
295
295
|
/* stylelint-disable */ //Formatted by prettier
|
|
296
296
|
.button-size(
|
|
297
297
|
@padding-large-vertical; @padding-large-horizontal; @font-size-large; @line-height-large;
|
|
298
|
-
|
|
298
|
+
@btn-border-radius-large
|
|
299
299
|
);
|
|
300
300
|
/* stylelint-enable */
|
|
301
301
|
}
|
|
@@ -305,7 +305,7 @@
|
|
|
305
305
|
overflow: hidden;
|
|
306
306
|
position: relative;
|
|
307
307
|
|
|
308
|
-
.safari-border-radius-overflow-hidden;
|
|
308
|
+
.safari-border-radius-overflow-hidden();
|
|
309
309
|
|
|
310
310
|
&:not(.@{prefix}disabled) {
|
|
311
311
|
.@{ns}ripple {
|
|
@@ -29,15 +29,15 @@
|
|
|
29
29
|
// Force change the size of the button in the button group.
|
|
30
30
|
.@{ns}btn {
|
|
31
31
|
.@{ns}btn-group-lg & {
|
|
32
|
-
.btn-lg;
|
|
32
|
+
.btn-lg();
|
|
33
33
|
}
|
|
34
34
|
|
|
35
35
|
.@{ns}btn-group-sm & {
|
|
36
|
-
.btn-sm;
|
|
36
|
+
.btn-sm();
|
|
37
37
|
}
|
|
38
38
|
|
|
39
39
|
.@{ns}btn-group-xs & {
|
|
40
|
-
.btn-xs;
|
|
40
|
+
.btn-xs();
|
|
41
41
|
}
|
|
42
42
|
}
|
|
43
43
|
|
|
@@ -241,7 +241,7 @@
|
|
|
241
241
|
|
|
242
242
|
// Clear floats so dropdown menus can be properly placed
|
|
243
243
|
> .@{ns}btn-group {
|
|
244
|
-
.clearfix;
|
|
244
|
+
.clearfix();
|
|
245
245
|
|
|
246
246
|
> .@{ns}btn {
|
|
247
247
|
float: none;
|
|
@@ -267,7 +267,7 @@
|
|
|
267
267
|
> .@{ns}btn,
|
|
268
268
|
> .@{ns}btn-group {
|
|
269
269
|
flex: 1 1 1%;
|
|
270
|
-
.ellipsis-basic;
|
|
270
|
+
.ellipsis-basic();
|
|
271
271
|
}
|
|
272
272
|
|
|
273
273
|
> .@{ns}btn-group .@{ns}btn {
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
&-panel &-header {
|
|
31
31
|
width: 100%;
|
|
32
32
|
padding-bottom: 6px;
|
|
33
|
-
.clearfix;
|
|
33
|
+
.clearfix();
|
|
34
34
|
}
|
|
35
35
|
|
|
36
36
|
&-panel &-header &-btn-today {
|
|
@@ -40,7 +40,7 @@
|
|
|
40
40
|
&-panel &-header-forward,
|
|
41
41
|
&-panel &-header-title,
|
|
42
42
|
&-panel &-header-backward {
|
|
43
|
-
.btn-md;
|
|
43
|
+
.btn-md();
|
|
44
44
|
}
|
|
45
45
|
|
|
46
46
|
&-panel &-header-forward,
|
|
@@ -167,7 +167,7 @@
|
|
|
167
167
|
}
|
|
168
168
|
|
|
169
169
|
.@{clpns}-header-title-date {
|
|
170
|
-
.picker-calendar-title-show;
|
|
170
|
+
.picker-calendar-title-show();
|
|
171
171
|
|
|
172
172
|
&.@{clpns}-header-error {
|
|
173
173
|
color: @error-color;
|
|
@@ -183,7 +183,7 @@
|
|
|
183
183
|
// Show time dropdown
|
|
184
184
|
.@{clpns}-show-time-dropdown {
|
|
185
185
|
.@{clpns}-header-title-time {
|
|
186
|
-
.picker-calendar-title-show;
|
|
186
|
+
.picker-calendar-title-show();
|
|
187
187
|
|
|
188
188
|
&.@{clpns}-header-error {
|
|
189
189
|
color: @error-color;
|
|
@@ -230,7 +230,7 @@
|
|
|
230
230
|
width: @calendar-header-width;
|
|
231
231
|
padding-left: @calendar-picker-padding;
|
|
232
232
|
padding-right: @calendar-picker-padding;
|
|
233
|
-
.clearfix;
|
|
233
|
+
.clearfix();
|
|
234
234
|
|
|
235
235
|
// Month toolbar && Time toolbar
|
|
236
236
|
&-month-toolbar,
|
|
@@ -252,7 +252,7 @@
|
|
|
252
252
|
&-backward,
|
|
253
253
|
&-forward {
|
|
254
254
|
.btn(base);
|
|
255
|
-
.btn-subtle;
|
|
255
|
+
.btn-subtle();
|
|
256
256
|
.btn-xs(base);
|
|
257
257
|
|
|
258
258
|
padding: 2px 2px;
|
|
@@ -303,7 +303,7 @@
|
|
|
303
303
|
&-backward,
|
|
304
304
|
&-forward {
|
|
305
305
|
font-size: 0;
|
|
306
|
-
width: @padding-extra-small-vertical * 2 + @font-size-small * @line-height-small;
|
|
306
|
+
width: (@padding-extra-small-vertical * 2 + @font-size-small * @line-height-small);
|
|
307
307
|
|
|
308
308
|
&::before {
|
|
309
309
|
font-family: @font-family-icon;
|
|
@@ -331,7 +331,7 @@
|
|
|
331
331
|
display: block;
|
|
332
332
|
text-align: center;
|
|
333
333
|
width: 100%;
|
|
334
|
-
.clearfix;
|
|
334
|
+
.clearfix();
|
|
335
335
|
}
|
|
336
336
|
|
|
337
337
|
&-has-month:not(&-has-time) &-backward {
|
|
@@ -425,7 +425,7 @@
|
|
|
425
425
|
|
|
426
426
|
&-disabled&-is-today&-selected &-content {
|
|
427
427
|
&:hover {
|
|
428
|
-
.picker-calendar-cell-content-selected;
|
|
428
|
+
.picker-calendar-cell-content-selected();
|
|
429
429
|
}
|
|
430
430
|
}
|
|
431
431
|
|
|
@@ -436,7 +436,7 @@
|
|
|
436
436
|
}
|
|
437
437
|
|
|
438
438
|
.@{clpns}-table-cell-content {
|
|
439
|
-
.picker-calendar-cell-content;
|
|
439
|
+
.picker-calendar-cell-content();
|
|
440
440
|
|
|
441
441
|
.@{clpns}-table-cell-is-today & {
|
|
442
442
|
border: @calendar-table-cell-content-today-border-width solid
|
|
@@ -445,7 +445,7 @@
|
|
|
445
445
|
}
|
|
446
446
|
|
|
447
447
|
.@{clpns}-table-cell-selected & {
|
|
448
|
-
.picker-calendar-cell-content-selected;
|
|
448
|
+
.picker-calendar-cell-content-selected();
|
|
449
449
|
}
|
|
450
450
|
}
|
|
451
451
|
|
|
@@ -527,7 +527,7 @@
|
|
|
527
527
|
|
|
528
528
|
&-list {
|
|
529
529
|
display: block;
|
|
530
|
-
.clearfix;
|
|
530
|
+
.clearfix();
|
|
531
531
|
}
|
|
532
532
|
|
|
533
533
|
&-cell {
|
|
@@ -545,7 +545,7 @@
|
|
|
545
545
|
}
|
|
546
546
|
|
|
547
547
|
&-cell-content {
|
|
548
|
-
.picker-calendar-cell-content;
|
|
548
|
+
.picker-calendar-cell-content();
|
|
549
549
|
}
|
|
550
550
|
|
|
551
551
|
&-cell:not(&-cell-active).disabled &-cell-content {
|
|
@@ -561,7 +561,7 @@
|
|
|
561
561
|
}
|
|
562
562
|
|
|
563
563
|
&-cell-active &-cell-content {
|
|
564
|
-
.picker-calendar-cell-content-selected;
|
|
564
|
+
.picker-calendar-cell-content-selected();
|
|
565
565
|
}
|
|
566
566
|
}
|
|
567
567
|
|
package/lib/Cascader/Cascader.js
CHANGED
|
@@ -557,7 +557,8 @@ function (_React$Component) {
|
|
|
557
557
|
onClean: (0, _utils2.createChainedFunction)(this.handleClean, onClean),
|
|
558
558
|
cleanable: cleanable && !disabled,
|
|
559
559
|
hasValue: hasValue,
|
|
560
|
-
active: active
|
|
560
|
+
active: active,
|
|
561
|
+
"aria-disabled": disabled
|
|
561
562
|
}), activeItemLabel || React.createElement(_FormattedMessage.default, {
|
|
562
563
|
id: "placeholder"
|
|
563
564
|
})))));
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
@cspns: ~'@{ns}@{cascader-picker-prefix}';
|
|
10
10
|
|
|
11
11
|
.@{cspns}-menu-items > div {
|
|
12
|
-
.clearfix;
|
|
12
|
+
.clearfix();
|
|
13
13
|
}
|
|
14
14
|
|
|
15
15
|
// Search panel
|
|
@@ -99,14 +99,14 @@
|
|
|
99
99
|
&:not(&-disabled):hover,
|
|
100
100
|
&:not(&-disabled):focus,
|
|
101
101
|
&.@{ns}picker-select-menu-item-focus {
|
|
102
|
-
.picker-item-hover;
|
|
102
|
+
.picker-item-hover();
|
|
103
103
|
|
|
104
104
|
text-decoration: none;
|
|
105
105
|
}
|
|
106
106
|
|
|
107
107
|
&&-focus,
|
|
108
108
|
&&-active {
|
|
109
|
-
.picker-item-active;
|
|
109
|
+
.picker-item-active();
|
|
110
110
|
|
|
111
111
|
&,
|
|
112
112
|
&:hover,
|
|
@@ -144,7 +144,7 @@
|
|
|
144
144
|
}
|
|
145
145
|
|
|
146
146
|
.@{cspns}-menu-caret {
|
|
147
|
-
.dropdown-toggle-caret-common;
|
|
147
|
+
.dropdown-toggle-caret-common();
|
|
148
148
|
|
|
149
149
|
&::before {
|
|
150
150
|
content: @drop-right-caret-content ~'/* rtl: "@{drop-left-caret-content}" */';
|
|
@@ -557,7 +557,8 @@ function (_React$Component) {
|
|
|
557
557
|
componentClass: toggleComponentClass,
|
|
558
558
|
cleanable: cleanable && !disabled,
|
|
559
559
|
hasValue: hasValue,
|
|
560
|
-
active: this.state.active
|
|
560
|
+
active: this.state.active,
|
|
561
|
+
"aria-disabled": disabled
|
|
561
562
|
}), selectedElement || React.createElement(_FormattedMessage.default, {
|
|
562
563
|
id: "placeholder"
|
|
563
564
|
})))));
|
|
@@ -5,12 +5,12 @@
|
|
|
5
5
|
|
|
6
6
|
// Menu Items
|
|
7
7
|
.@{ckpns}-menu-items {
|
|
8
|
-
.picker-menu-items-reset;
|
|
8
|
+
.picker-menu-items-reset();
|
|
9
9
|
.picker-menu-group-common(@check-picker-prefix);
|
|
10
10
|
.picker-menu-group-title(@check-picker-prefix);
|
|
11
11
|
.picker-menu-group-closed(@check-picker-prefix);
|
|
12
12
|
|
|
13
13
|
.@{ns}check-item.@{ns}checkbox-checked .@{ns}checkbox-checker > label {
|
|
14
|
-
.picker-item-active;
|
|
14
|
+
.picker-item-active();
|
|
15
15
|
}
|
|
16
16
|
}
|
|
@@ -1368,7 +1368,8 @@ function (_React$Component) {
|
|
|
1368
1368
|
componentClass: toggleComponentClass,
|
|
1369
1369
|
cleanable: cleanable && !disabled,
|
|
1370
1370
|
hasValue: hasValidValue,
|
|
1371
|
-
active: this.state.active
|
|
1371
|
+
active: this.state.active,
|
|
1372
|
+
"aria-disabled": disabled
|
|
1372
1373
|
}), selectedElement || locale.placeholder)));
|
|
1373
1374
|
};
|
|
1374
1375
|
|
|
@@ -35,11 +35,11 @@
|
|
|
35
35
|
}
|
|
36
36
|
|
|
37
37
|
&:focus .@{ns}check-item .@{ns}checkbox-checker > label {
|
|
38
|
-
.picker-item-hover;
|
|
38
|
+
.picker-item-hover();
|
|
39
39
|
}
|
|
40
40
|
|
|
41
41
|
.@{ns}check-item.@{ns}checkbox-checked .@{ns}checkbox-checker > label {
|
|
42
|
-
.picker-item-active;
|
|
42
|
+
.picker-item-active();
|
|
43
43
|
}
|
|
44
44
|
|
|
45
45
|
.@{ns}check-item .@{ns}checkbox-checker > label {
|
|
@@ -54,7 +54,7 @@
|
|
|
54
54
|
&::before {
|
|
55
55
|
content: '';
|
|
56
56
|
position: absolute;
|
|
57
|
-
width: @picker-tree-arrow-down-width+ @picker-tree-arrow-down-gap + 30px; // checkbox-spacing = 30
|
|
57
|
+
width: (@picker-tree-arrow-down-width+ @picker-tree-arrow-down-gap + 30px); // checkbox-spacing = 30
|
|
58
58
|
height: 100%;
|
|
59
59
|
background-color: @picker-tree-bg;
|
|
60
60
|
top: 0;
|
|
@@ -136,7 +136,7 @@
|
|
|
136
136
|
}
|
|
137
137
|
|
|
138
138
|
> .@{ctpns}-node-custom-icon {
|
|
139
|
-
.node-item-prepend-icon;
|
|
139
|
+
.node-item-prepend-icon();
|
|
140
140
|
}
|
|
141
141
|
}
|
|
142
142
|
|
|
@@ -164,7 +164,7 @@
|
|
|
164
164
|
padding: 0 @picker-menu-padding @picker-menu-padding 0;
|
|
165
165
|
|
|
166
166
|
&-node > .@{ctpns}-node-label .@{ctpns}-node-text-wrapper {
|
|
167
|
-
.ellipsis;
|
|
167
|
+
.ellipsis();
|
|
168
168
|
|
|
169
169
|
display: inline-block;
|
|
170
170
|
vertical-align: top;
|
|
@@ -2,14 +2,14 @@
|
|
|
2
2
|
@import 'mixin';
|
|
3
3
|
|
|
4
4
|
.@{ns}checkbox {
|
|
5
|
-
.radio-checkbox-common;
|
|
5
|
+
.radio-checkbox-common();
|
|
6
6
|
}
|
|
7
7
|
|
|
8
8
|
.@{ns}checkbox-checker {
|
|
9
9
|
padding-top: 10px;
|
|
10
10
|
padding-bottom: 10px;
|
|
11
|
-
padding-left: @checkbox-sense-width*2 + @checkbox-width-height;
|
|
12
|
-
min-height: @checkbox-sense-width*2 + @checkbox-width-height;
|
|
11
|
+
padding-left: (@checkbox-sense-width*2 + @checkbox-width-height);
|
|
12
|
+
min-height: (@checkbox-sense-width*2 + @checkbox-width-height);
|
|
13
13
|
line-height: 1;
|
|
14
14
|
position: relative;
|
|
15
15
|
}
|
|
@@ -474,7 +474,8 @@ function (_React$Component) {
|
|
|
474
474
|
onClean: (0, _utils.createChainedFunction)(this.handleClean, onClean),
|
|
475
475
|
cleanable: cleanable && !disabled,
|
|
476
476
|
hasValue: hasValue,
|
|
477
|
-
active: this.state.active
|
|
477
|
+
active: this.state.active,
|
|
478
|
+
"aria-disabled": disabled
|
|
478
479
|
}), this.getDateString()))));
|
|
479
480
|
};
|
|
480
481
|
|
|
@@ -584,7 +584,8 @@ function (_React$Component) {
|
|
|
584
584
|
onClean: (0, _utils2.createChainedFunction)(this.handleClean, onClean),
|
|
585
585
|
cleanable: cleanable && !disabled,
|
|
586
586
|
hasValue: hasValue,
|
|
587
|
-
active: this.state.active
|
|
587
|
+
active: this.state.active,
|
|
588
|
+
"aria-disabled": disabled
|
|
588
589
|
}), this.getDateString()))));
|
|
589
590
|
};
|
|
590
591
|
|
|
@@ -164,7 +164,7 @@
|
|
|
164
164
|
// Drawer header
|
|
165
165
|
// Top section of the modal title.
|
|
166
166
|
.@{ns}drawer-header {
|
|
167
|
-
.clearfix;
|
|
167
|
+
.clearfix();
|
|
168
168
|
|
|
169
169
|
padding-right: @line-height-computed;
|
|
170
170
|
position: relative;
|
|
@@ -172,12 +172,12 @@
|
|
|
172
172
|
|
|
173
173
|
.@{ns}drawer-title {
|
|
174
174
|
font-size: @drawer-title-font-size;
|
|
175
|
-
line-height: unit(@line-height-computed / @drawer-title-font-size);
|
|
175
|
+
line-height: unit((@line-height-computed / @drawer-title-font-size));
|
|
176
176
|
width: 100%;
|
|
177
177
|
display: block;
|
|
178
178
|
color: @drawer-title-color;
|
|
179
179
|
margin: 0;
|
|
180
|
-
.ellipsis;
|
|
180
|
+
.ellipsis();
|
|
181
181
|
}
|
|
182
182
|
}
|
|
183
183
|
|
|
@@ -200,7 +200,7 @@
|
|
|
200
200
|
border-style: none;
|
|
201
201
|
|
|
202
202
|
&::before {
|
|
203
|
-
.icon-font;
|
|
203
|
+
.icon-font();
|
|
204
204
|
|
|
205
205
|
content: @default-close-btn-content;
|
|
206
206
|
}
|
|
@@ -220,7 +220,7 @@
|
|
|
220
220
|
|
|
221
221
|
// Footer (for actions)
|
|
222
222
|
.@{ns}drawer-footer {
|
|
223
|
-
.clearfix; // clear it in case folks use .pull-* classes on buttons
|
|
223
|
+
.clearfix(); // clear it in case folks use .pull-* classes on buttons
|
|
224
224
|
|
|
225
225
|
text-align: right; // right align buttons
|
|
226
226
|
border-top: none;
|
package/lib/Dropdown/Dropdown.js
CHANGED
|
@@ -25,6 +25,8 @@ var _classnames = _interopRequireDefault(require("classnames"));
|
|
|
25
25
|
|
|
26
26
|
var _recompose = require("recompose");
|
|
27
27
|
|
|
28
|
+
var _domLib = require("dom-lib");
|
|
29
|
+
|
|
28
30
|
var _RootCloseWrapper = _interopRequireDefault(require("../Overlay/RootCloseWrapper"));
|
|
29
31
|
|
|
30
32
|
var _shallowEqual = _interopRequireDefault(require("../utils/shallowEqual"));
|
|
@@ -50,6 +52,7 @@ function (_React$Component) {
|
|
|
50
52
|
var _this;
|
|
51
53
|
|
|
52
54
|
_this = _React$Component.call(this, props) || this;
|
|
55
|
+
_this.rootRef = void 0;
|
|
53
56
|
|
|
54
57
|
_this.toggle = function (isOpen) {
|
|
55
58
|
var _this$props = _this.props,
|
|
@@ -70,8 +73,12 @@ function (_React$Component) {
|
|
|
70
73
|
_this.handleRootClose = function (event) {
|
|
71
74
|
var _this$props$onToggle, _this$props2, _this$props$onClose, _this$props3;
|
|
72
75
|
|
|
73
|
-
event.
|
|
74
|
-
|
|
76
|
+
// Prevent the event from bubbling when closing the overlay is triggered by its own element.
|
|
77
|
+
// fix#1435
|
|
78
|
+
if ((0, _domLib.contains)((0, _utils.getDOMNode)(_this.rootRef.current), event.target)) {
|
|
79
|
+
event.preventDefault();
|
|
80
|
+
event.stopPropagation();
|
|
81
|
+
}
|
|
75
82
|
|
|
76
83
|
_this.setState({
|
|
77
84
|
open: false
|
|
@@ -127,6 +134,7 @@ function (_React$Component) {
|
|
|
127
134
|
_this.state = {
|
|
128
135
|
open: props.open
|
|
129
136
|
};
|
|
137
|
+
_this.rootRef = React.createRef();
|
|
130
138
|
return _this;
|
|
131
139
|
}
|
|
132
140
|
|
|
@@ -244,7 +252,9 @@ function (_React$Component) {
|
|
|
244
252
|
componentClass: toggleComponentClass
|
|
245
253
|
}), title);
|
|
246
254
|
var classes = (0, _classnames.default)(classPrefix, className, (_classNames = {}, _classNames[addPrefix("placement-" + (0, _kebabCase2.default)((0, _utils.placementPolyfill)(placement)))] = placement, _classNames[addPrefix('disabled')] = disabled, _classNames[addPrefix('no-caret')] = noCaret, _classNames[addPrefix('open')] = open, _classNames[addPrefix(menuExpanded ? 'expand' : 'collapse')] = sidenav, _classNames));
|
|
247
|
-
return React.createElement(Component, (0, _extends2.default)({
|
|
255
|
+
return React.createElement(Component, (0, _extends2.default)({
|
|
256
|
+
ref: this.rootRef
|
|
257
|
+
}, dropdownProps, {
|
|
248
258
|
style: style,
|
|
249
259
|
className: classes,
|
|
250
260
|
role: "menu"
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
// --------------------------------------------------
|
|
7
7
|
|
|
8
8
|
.@{ns}dropdown-toggle-caret {
|
|
9
|
-
.dropdown-toggle-caret-common;
|
|
9
|
+
.dropdown-toggle-caret-common();
|
|
10
10
|
.set-dropdown-caret(~'@{ns}dropdown');
|
|
11
11
|
}
|
|
12
12
|
|
|
@@ -86,12 +86,12 @@
|
|
|
86
86
|
}
|
|
87
87
|
|
|
88
88
|
.@{ns}dropdown-toggle {
|
|
89
|
-
.dropdown-toggle-size;
|
|
89
|
+
.dropdown-toggle-size();
|
|
90
90
|
|
|
91
91
|
&,
|
|
92
92
|
&.@{ns}btn {
|
|
93
93
|
// Force set style even if has `.btn`.
|
|
94
|
-
.dropdown-toggle;
|
|
94
|
+
.dropdown-toggle();
|
|
95
95
|
}
|
|
96
96
|
}
|
|
97
97
|
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
.@{ns}form-inline {
|
|
7
7
|
> *,
|
|
8
8
|
> .@{ns}btn {
|
|
9
|
-
margin-right:
|
|
9
|
+
margin-right: 20px;
|
|
10
10
|
margin-bottom: 24px;
|
|
11
11
|
vertical-align: top;
|
|
12
12
|
}
|
|
@@ -14,6 +14,7 @@
|
|
|
14
14
|
.rs-control-label {
|
|
15
15
|
vertical-align: top;
|
|
16
16
|
margin-bottom: auto;
|
|
17
|
+
margin-right: @control-label-margin-right;
|
|
17
18
|
margin-top: @padding-base-vertical;
|
|
18
19
|
display: inline-block;
|
|
19
20
|
}
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
border: @input-border-width solid @input-border;
|
|
8
8
|
transition: @input-transition;
|
|
9
9
|
border-radius: @border-radius-base;
|
|
10
|
-
.input-base;
|
|
10
|
+
.input-base();
|
|
11
11
|
|
|
12
12
|
// Placeholder
|
|
13
13
|
&::placeholder {
|
|
@@ -81,7 +81,7 @@
|
|
|
81
81
|
}
|
|
82
82
|
|
|
83
83
|
.input-base() {
|
|
84
|
-
.input-md;
|
|
84
|
+
.input-md();
|
|
85
85
|
}
|
|
86
86
|
|
|
87
87
|
.reset-input-group-addon-size(@size-name) {
|
|
@@ -90,7 +90,7 @@
|
|
|
90
90
|
@width: @@padding-horizontal-name * 2 - @input-border-width*2 + @font-size-base;
|
|
91
91
|
@padding-horizontal: (@width - @font-size-base)/2;
|
|
92
92
|
|
|
93
|
-
width: @width;
|
|
93
|
+
min-width: @width;
|
|
94
94
|
padding-left: @padding-horizontal;
|
|
95
95
|
padding-right: @padding-horizontal;
|
|
96
96
|
}
|
|
@@ -123,7 +123,7 @@
|
|
|
123
123
|
padding-right: @@add-on-padding;
|
|
124
124
|
}
|
|
125
125
|
|
|
126
|
-
&.@{ns}input-group
|
|
126
|
+
&.@{ns}input-group {
|
|
127
127
|
> .@{ns}input {
|
|
128
128
|
height: @useable-height;
|
|
129
129
|
}
|