rsuite 5.38.0 → 5.39.0
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 +14 -0
- package/Nav/styles/index.less +10 -11
- package/SelectPicker/styles/index.less +8 -4
- package/cjs/SelectPicker/Listbox.d.ts +34 -0
- package/cjs/SelectPicker/Listbox.js +263 -0
- package/cjs/SelectPicker/ListboxOption.d.ts +11 -0
- package/cjs/SelectPicker/ListboxOption.js +50 -0
- package/cjs/SelectPicker/ListboxOptionGroup.d.ts +9 -0
- package/cjs/SelectPicker/ListboxOptionGroup.js +69 -0
- package/cjs/SelectPicker/SelectPicker.js +33 -36
- package/cjs/Windowing/List.d.ts +2 -2
- package/cjs/locales/index.d.ts +1 -0
- package/cjs/locales/index.js +6 -2
- package/cjs/locales/ne_NP.d.ts +117 -0
- package/cjs/locales/ne_NP.js +89 -0
- package/cjs/utils/getDataGroupBy.d.ts +23 -0
- package/cjs/utils/getDataGroupBy.js +33 -0
- package/dist/rsuite-no-reset-rtl.css +22 -11
- package/dist/rsuite-no-reset-rtl.min.css +1 -1
- package/dist/rsuite-no-reset-rtl.min.css.map +1 -1
- package/dist/rsuite-no-reset.css +22 -11
- package/dist/rsuite-no-reset.min.css +1 -1
- package/dist/rsuite-no-reset.min.css.map +1 -1
- package/dist/rsuite-rtl.css +22 -11
- package/dist/rsuite-rtl.min.css +1 -1
- package/dist/rsuite-rtl.min.css.map +1 -1
- package/dist/rsuite.css +22 -11
- package/dist/rsuite.js +36 -3
- package/dist/rsuite.js.map +1 -1
- package/dist/rsuite.min.css +1 -1
- package/dist/rsuite.min.css.map +1 -1
- package/dist/rsuite.min.js +1 -1
- package/dist/rsuite.min.js.map +1 -1
- package/esm/SelectPicker/Listbox.d.ts +34 -0
- package/esm/SelectPicker/Listbox.js +240 -0
- package/esm/SelectPicker/ListboxOption.d.ts +11 -0
- package/esm/SelectPicker/ListboxOption.js +37 -0
- package/esm/SelectPicker/ListboxOptionGroup.d.ts +9 -0
- package/esm/SelectPicker/ListboxOptionGroup.js +53 -0
- package/esm/SelectPicker/SelectPicker.js +33 -36
- package/esm/Windowing/List.d.ts +2 -2
- package/esm/locales/index.d.ts +1 -0
- package/esm/locales/index.js +2 -1
- package/esm/locales/ne_NP.d.ts +117 -0
- package/esm/locales/ne_NP.js +79 -0
- package/esm/utils/getDataGroupBy.d.ts +23 -0
- package/esm/utils/getDataGroupBy.js +32 -0
- package/locales/ne_NP/package.json +7 -0
- package/package.json +1 -1
- package/styles/mixins/listbox.less +2 -0
|
@@ -0,0 +1,117 @@
|
|
|
1
|
+
declare const _default: {
|
|
2
|
+
common: {
|
|
3
|
+
loading: string;
|
|
4
|
+
emptyMessage: string;
|
|
5
|
+
};
|
|
6
|
+
Plaintext: {
|
|
7
|
+
unfilled: string;
|
|
8
|
+
notSelected: string;
|
|
9
|
+
notUploaded: string;
|
|
10
|
+
};
|
|
11
|
+
Pagination: {
|
|
12
|
+
more: string;
|
|
13
|
+
prev: string;
|
|
14
|
+
next: string;
|
|
15
|
+
first: string;
|
|
16
|
+
last: string;
|
|
17
|
+
limit: string;
|
|
18
|
+
total: string;
|
|
19
|
+
skip: string;
|
|
20
|
+
};
|
|
21
|
+
Calendar: {
|
|
22
|
+
sunday: string;
|
|
23
|
+
monday: string;
|
|
24
|
+
tuesday: string;
|
|
25
|
+
wednesday: string;
|
|
26
|
+
thursday: string;
|
|
27
|
+
friday: string;
|
|
28
|
+
saturday: string;
|
|
29
|
+
ok: string;
|
|
30
|
+
today: string;
|
|
31
|
+
yesterday: string;
|
|
32
|
+
hours: string;
|
|
33
|
+
minutes: string;
|
|
34
|
+
seconds: string;
|
|
35
|
+
/**
|
|
36
|
+
* Format of the string is based on Unicode Technical Standard #35:
|
|
37
|
+
* https://www.unicode.org/reports/tr35/tr35-dates.html#Date_Field_Symbol_Table
|
|
38
|
+
**/
|
|
39
|
+
formattedMonthPattern: string;
|
|
40
|
+
formattedDayPattern: string;
|
|
41
|
+
dateLocale: any;
|
|
42
|
+
};
|
|
43
|
+
DatePicker: {
|
|
44
|
+
sunday: string;
|
|
45
|
+
monday: string;
|
|
46
|
+
tuesday: string;
|
|
47
|
+
wednesday: string;
|
|
48
|
+
thursday: string;
|
|
49
|
+
friday: string;
|
|
50
|
+
saturday: string;
|
|
51
|
+
ok: string;
|
|
52
|
+
today: string;
|
|
53
|
+
yesterday: string;
|
|
54
|
+
hours: string;
|
|
55
|
+
minutes: string;
|
|
56
|
+
seconds: string;
|
|
57
|
+
/**
|
|
58
|
+
* Format of the string is based on Unicode Technical Standard #35:
|
|
59
|
+
* https://www.unicode.org/reports/tr35/tr35-dates.html#Date_Field_Symbol_Table
|
|
60
|
+
**/
|
|
61
|
+
formattedMonthPattern: string;
|
|
62
|
+
formattedDayPattern: string;
|
|
63
|
+
dateLocale: any;
|
|
64
|
+
};
|
|
65
|
+
DateRangePicker: {
|
|
66
|
+
last7Days: string;
|
|
67
|
+
sunday: string;
|
|
68
|
+
monday: string;
|
|
69
|
+
tuesday: string;
|
|
70
|
+
wednesday: string;
|
|
71
|
+
thursday: string;
|
|
72
|
+
friday: string;
|
|
73
|
+
saturday: string;
|
|
74
|
+
ok: string;
|
|
75
|
+
today: string;
|
|
76
|
+
yesterday: string;
|
|
77
|
+
hours: string;
|
|
78
|
+
minutes: string;
|
|
79
|
+
seconds: string;
|
|
80
|
+
/**
|
|
81
|
+
* Format of the string is based on Unicode Technical Standard #35:
|
|
82
|
+
* https://www.unicode.org/reports/tr35/tr35-dates.html#Date_Field_Symbol_Table
|
|
83
|
+
**/
|
|
84
|
+
formattedMonthPattern: string;
|
|
85
|
+
formattedDayPattern: string;
|
|
86
|
+
dateLocale: any;
|
|
87
|
+
};
|
|
88
|
+
Picker: {
|
|
89
|
+
noResultsText: string;
|
|
90
|
+
placeholder: string;
|
|
91
|
+
searchPlaceholder: string;
|
|
92
|
+
checkAll: string;
|
|
93
|
+
};
|
|
94
|
+
InputPicker: {
|
|
95
|
+
newItem: string;
|
|
96
|
+
createOption: string;
|
|
97
|
+
};
|
|
98
|
+
Uploader: {
|
|
99
|
+
inited: string;
|
|
100
|
+
progress: string;
|
|
101
|
+
error: string;
|
|
102
|
+
complete: string;
|
|
103
|
+
emptyFile: string;
|
|
104
|
+
upload: string;
|
|
105
|
+
};
|
|
106
|
+
CloseButton: {
|
|
107
|
+
closeLabel: string;
|
|
108
|
+
};
|
|
109
|
+
Breadcrumb: {
|
|
110
|
+
expandText: string;
|
|
111
|
+
};
|
|
112
|
+
Toggle: {
|
|
113
|
+
on: string;
|
|
114
|
+
off: string;
|
|
115
|
+
};
|
|
116
|
+
};
|
|
117
|
+
export default _default;
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
+
|
|
5
|
+
exports.__esModule = true;
|
|
6
|
+
exports.default = void 0;
|
|
7
|
+
|
|
8
|
+
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
|
|
9
|
+
|
|
10
|
+
var _enGB = _interopRequireDefault(require("date-fns/locale/en-GB"));
|
|
11
|
+
|
|
12
|
+
var Calendar = {
|
|
13
|
+
sunday: 'आ',
|
|
14
|
+
monday: 'सो',
|
|
15
|
+
tuesday: 'म',
|
|
16
|
+
wednesday: 'बु',
|
|
17
|
+
thursday: 'बि',
|
|
18
|
+
friday: 'शु',
|
|
19
|
+
saturday: 'श',
|
|
20
|
+
ok: 'हुन्छ',
|
|
21
|
+
today: 'आज',
|
|
22
|
+
yesterday: 'हिजो',
|
|
23
|
+
hours: 'घण्टा',
|
|
24
|
+
minutes: 'मिनेट',
|
|
25
|
+
seconds: 'सेकेन्ड',
|
|
26
|
+
|
|
27
|
+
/**
|
|
28
|
+
* Format of the string is based on Unicode Technical Standard #35:
|
|
29
|
+
* https://www.unicode.org/reports/tr35/tr35-dates.html#Date_Field_Symbol_Table
|
|
30
|
+
**/
|
|
31
|
+
formattedMonthPattern: 'MMM yyyy',
|
|
32
|
+
formattedDayPattern: 'dd MMM yyyy',
|
|
33
|
+
dateLocale: _enGB.default
|
|
34
|
+
};
|
|
35
|
+
var _default = {
|
|
36
|
+
common: {
|
|
37
|
+
loading: 'लोड हुँदैछ...',
|
|
38
|
+
emptyMessage: 'कुनै डाटा छैन'
|
|
39
|
+
},
|
|
40
|
+
Plaintext: {
|
|
41
|
+
unfilled: 'भरिएको छैन',
|
|
42
|
+
notSelected: 'चयन गरिएको छैन',
|
|
43
|
+
notUploaded: 'अपलोड गरिएको छैन'
|
|
44
|
+
},
|
|
45
|
+
Pagination: {
|
|
46
|
+
more: 'थप',
|
|
47
|
+
prev: 'अघिल्लो',
|
|
48
|
+
next: 'अर्को',
|
|
49
|
+
first: 'पहिलो',
|
|
50
|
+
last: 'अन्तिम',
|
|
51
|
+
limit: '{0} / पृष्ठ',
|
|
52
|
+
total: 'कुल पङ्क्तिहरू: {0}',
|
|
53
|
+
skip: '{0} पृष्ठमा जानुहोस्'
|
|
54
|
+
},
|
|
55
|
+
Calendar: Calendar,
|
|
56
|
+
DatePicker: (0, _extends2.default)({}, Calendar),
|
|
57
|
+
DateRangePicker: (0, _extends2.default)({}, Calendar, {
|
|
58
|
+
last7Days: 'पछिल्लो ७ दिन'
|
|
59
|
+
}),
|
|
60
|
+
Picker: {
|
|
61
|
+
noResultsText: 'कुनै परिणाम फेला परेन',
|
|
62
|
+
placeholder: 'चयन गर्नुहोस्',
|
|
63
|
+
searchPlaceholder: 'खोजी गर्नुहोस्',
|
|
64
|
+
checkAll: 'सबै'
|
|
65
|
+
},
|
|
66
|
+
InputPicker: {
|
|
67
|
+
newItem: 'नयाँ थप्नुहोस्',
|
|
68
|
+
createOption: 'विकल्प सिर्जना गर्नुहोस् "{0}"'
|
|
69
|
+
},
|
|
70
|
+
Uploader: {
|
|
71
|
+
inited: 'प्रारम्भिक',
|
|
72
|
+
progress: 'अपलोड गर्दै',
|
|
73
|
+
error: 'त्रुटि भयो',
|
|
74
|
+
complete: 'समाप्त',
|
|
75
|
+
emptyFile: 'खाली',
|
|
76
|
+
upload: 'अपलोड गर्नुहोस्'
|
|
77
|
+
},
|
|
78
|
+
CloseButton: {
|
|
79
|
+
closeLabel: 'बन्द गर्नुहोस्'
|
|
80
|
+
},
|
|
81
|
+
Breadcrumb: {
|
|
82
|
+
expandText: 'स्थान देखाउनुहोस्'
|
|
83
|
+
},
|
|
84
|
+
Toggle: {
|
|
85
|
+
on: 'खोल्नुहोस्',
|
|
86
|
+
off: 'बन्द गर्नुहोस्'
|
|
87
|
+
}
|
|
88
|
+
};
|
|
89
|
+
exports.default = _default;
|
|
@@ -1,6 +1,29 @@
|
|
|
1
1
|
export declare const KEY_GROUP: string | symbol;
|
|
2
2
|
export declare const KEY_GROUP_TITLE = "groupTitle";
|
|
3
|
+
/**
|
|
4
|
+
* Chunk data into groups
|
|
5
|
+
* @returns [group, child, child, group, child, child]
|
|
6
|
+
*/
|
|
3
7
|
export declare function getDataGroupBy<T>(data: readonly T[], key: string, sort?: (isGroup: boolean) => <T>(a: T, b: T) => number): (T | {
|
|
4
8
|
groupTitle: string;
|
|
5
9
|
children: T[];
|
|
6
10
|
})[];
|
|
11
|
+
/**
|
|
12
|
+
* Chunk options into groups
|
|
13
|
+
* @returns [
|
|
14
|
+
* group {
|
|
15
|
+
* key
|
|
16
|
+
* options
|
|
17
|
+
* }
|
|
18
|
+
* group {
|
|
19
|
+
* key
|
|
20
|
+
* options
|
|
21
|
+
* }
|
|
22
|
+
* ]
|
|
23
|
+
*/
|
|
24
|
+
export declare type Group<T> = {
|
|
25
|
+
key: string;
|
|
26
|
+
options: T[];
|
|
27
|
+
};
|
|
28
|
+
export declare type CompareFn<T> = (a: T, b: T) => number;
|
|
29
|
+
export declare function groupOptions<T>(options: readonly T[], groupKey: string, compareOptions?: CompareFn<T>, compareGroups?: CompareFn<Group<T>>): Group<T>[];
|
|
@@ -4,6 +4,7 @@ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefau
|
|
|
4
4
|
|
|
5
5
|
exports.__esModule = true;
|
|
6
6
|
exports.getDataGroupBy = getDataGroupBy;
|
|
7
|
+
exports.groupOptions = groupOptions;
|
|
7
8
|
exports.KEY_GROUP_TITLE = exports.KEY_GROUP = void 0;
|
|
8
9
|
|
|
9
10
|
var _groupBy2 = _interopRequireDefault(require("lodash/groupBy"));
|
|
@@ -14,6 +15,11 @@ var hasSymbol = typeof Symbol === 'function';
|
|
|
14
15
|
var KEY_GROUP = hasSymbol ? Symbol('_$grouped') : '_$grouped';
|
|
15
16
|
exports.KEY_GROUP = KEY_GROUP;
|
|
16
17
|
var KEY_GROUP_TITLE = 'groupTitle';
|
|
18
|
+
/**
|
|
19
|
+
* Chunk data into groups
|
|
20
|
+
* @returns [group, child, child, group, child, child]
|
|
21
|
+
*/
|
|
22
|
+
|
|
17
23
|
exports.KEY_GROUP_TITLE = KEY_GROUP_TITLE;
|
|
18
24
|
|
|
19
25
|
function getDataGroupBy(data, key, sort) {
|
|
@@ -39,4 +45,31 @@ function getDataGroupBy(data, key, sort) {
|
|
|
39
45
|
return (0, _treeUtils.flattenTree)(groups, function (group) {
|
|
40
46
|
return group.children;
|
|
41
47
|
}, _treeUtils.WalkTreeStrategy.DFS);
|
|
48
|
+
}
|
|
49
|
+
/**
|
|
50
|
+
* Chunk options into groups
|
|
51
|
+
* @returns [
|
|
52
|
+
* group {
|
|
53
|
+
* key
|
|
54
|
+
* options
|
|
55
|
+
* }
|
|
56
|
+
* group {
|
|
57
|
+
* key
|
|
58
|
+
* options
|
|
59
|
+
* }
|
|
60
|
+
* ]
|
|
61
|
+
*/
|
|
62
|
+
|
|
63
|
+
|
|
64
|
+
function groupOptions(options, groupKey, compareOptions, compareGroups) {
|
|
65
|
+
var groupMap = (0, _groupBy2.default)(options, groupKey);
|
|
66
|
+
var groups = Object.entries(groupMap).map(function (_ref3) {
|
|
67
|
+
var key = _ref3[0],
|
|
68
|
+
options = _ref3[1];
|
|
69
|
+
return {
|
|
70
|
+
key: key,
|
|
71
|
+
options: typeof compareOptions === 'function' ? options.sort(compareOptions) : options
|
|
72
|
+
};
|
|
73
|
+
});
|
|
74
|
+
return typeof compareGroups === 'function' ? groups.sort(compareGroups) : groups;
|
|
42
75
|
}
|
|
@@ -9605,6 +9605,15 @@ textarea.rs-picker-search-input {
|
|
|
9605
9605
|
.rs-nav-horizontal {
|
|
9606
9606
|
white-space: nowrap;
|
|
9607
9607
|
}
|
|
9608
|
+
.rs-nav-horizontal > .rs-nav-item {
|
|
9609
|
+
display: -webkit-inline-box;
|
|
9610
|
+
display: -ms-inline-flexbox;
|
|
9611
|
+
display: inline-flex;
|
|
9612
|
+
-webkit-box-align: center;
|
|
9613
|
+
-ms-flex-align: center;
|
|
9614
|
+
align-items: center;
|
|
9615
|
+
vertical-align: top;
|
|
9616
|
+
}
|
|
9608
9617
|
.rs-nav-horizontal .rs-nav-bar {
|
|
9609
9618
|
position: absolute;
|
|
9610
9619
|
bottom: 0;
|
|
@@ -9614,14 +9623,13 @@ textarea.rs-picker-search-input {
|
|
|
9614
9623
|
bottom: auto;
|
|
9615
9624
|
top: 0;
|
|
9616
9625
|
}
|
|
9617
|
-
.rs-nav-
|
|
9618
|
-
|
|
9619
|
-
display:
|
|
9620
|
-
|
|
9621
|
-
|
|
9622
|
-
|
|
9623
|
-
|
|
9624
|
-
display: block;
|
|
9626
|
+
.rs-nav-vertical > .rs-nav-item {
|
|
9627
|
+
display: -webkit-box;
|
|
9628
|
+
display: -ms-flexbox;
|
|
9629
|
+
display: flex;
|
|
9630
|
+
-webkit-box-align: center;
|
|
9631
|
+
-ms-flex-align: center;
|
|
9632
|
+
align-items: center;
|
|
9625
9633
|
}
|
|
9626
9634
|
.rs-nav-vertical > .rs-dropdown {
|
|
9627
9635
|
width: 100%;
|
|
@@ -12895,9 +12903,6 @@ textarea.rs-picker-menu .rs-picker-search-bar .rs-picker-search-bar-input {
|
|
|
12895
12903
|
-webkit-transform: rotate(-90deg);
|
|
12896
12904
|
transform: rotate(-90deg);
|
|
12897
12905
|
}
|
|
12898
|
-
.rs-picker-select-menu-items .rs-picker-menu-group ~ [role='option'] > .rs-picker-select-menu-item {
|
|
12899
|
-
padding-right: 26px;
|
|
12900
|
-
}
|
|
12901
12906
|
.rs-picker-select-menu-item {
|
|
12902
12907
|
display: block;
|
|
12903
12908
|
padding: 8px 12px;
|
|
@@ -12951,6 +12956,12 @@ textarea.rs-picker-menu .rs-picker-search-bar .rs-picker-search-bar-input {
|
|
|
12951
12956
|
.rs-picker-select-menu-group-children .rs-picker-select-menu-item {
|
|
12952
12957
|
padding-right: 26px;
|
|
12953
12958
|
}
|
|
12959
|
+
.rs-picker-menu-group .rs-picker-select-menu-item {
|
|
12960
|
+
padding-right: 26px;
|
|
12961
|
+
}
|
|
12962
|
+
.rs-picker-menu-group.folded [role='option'] {
|
|
12963
|
+
display: none;
|
|
12964
|
+
}
|
|
12954
12965
|
.rs-sidebar-collapse {
|
|
12955
12966
|
-webkit-transition: width 0.15s ease-in, -webkit-box-flex 0.15s ease-in;
|
|
12956
12967
|
transition: width 0.15s ease-in, -webkit-box-flex 0.15s ease-in;
|