rsuite 5.37.4 → 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.
Files changed (63) hide show
  1. package/CHANGELOG.md +25 -0
  2. package/Dropdown/styles/mixin.less +0 -1
  3. package/Nav/styles/index.less +10 -11
  4. package/SelectPicker/styles/index.less +8 -4
  5. package/cjs/Calendar/Calendar.d.ts +6 -1
  6. package/cjs/Calendar/Calendar.js +12 -13
  7. package/cjs/Calendar/CalendarContainer.d.ts +2 -0
  8. package/cjs/Calendar/CalendarContainer.js +4 -2
  9. package/cjs/Calendar/TableRow.js +6 -3
  10. package/cjs/Calendar/types.d.ts +1 -0
  11. package/cjs/SelectPicker/Listbox.d.ts +34 -0
  12. package/cjs/SelectPicker/Listbox.js +263 -0
  13. package/cjs/SelectPicker/ListboxOption.d.ts +11 -0
  14. package/cjs/SelectPicker/ListboxOption.js +50 -0
  15. package/cjs/SelectPicker/ListboxOptionGroup.d.ts +9 -0
  16. package/cjs/SelectPicker/ListboxOptionGroup.js +69 -0
  17. package/cjs/SelectPicker/SelectPicker.js +33 -36
  18. package/cjs/Windowing/List.d.ts +2 -2
  19. package/cjs/locales/index.d.ts +1 -0
  20. package/cjs/locales/index.js +6 -2
  21. package/cjs/locales/ne_NP.d.ts +117 -0
  22. package/cjs/locales/ne_NP.js +89 -0
  23. package/cjs/utils/getDataGroupBy.d.ts +23 -0
  24. package/cjs/utils/getDataGroupBy.js +33 -0
  25. package/dist/rsuite-no-reset-rtl.css +22 -15
  26. package/dist/rsuite-no-reset-rtl.min.css +1 -1
  27. package/dist/rsuite-no-reset-rtl.min.css.map +1 -1
  28. package/dist/rsuite-no-reset.css +22 -15
  29. package/dist/rsuite-no-reset.min.css +1 -1
  30. package/dist/rsuite-no-reset.min.css.map +1 -1
  31. package/dist/rsuite-rtl.css +22 -15
  32. package/dist/rsuite-rtl.min.css +1 -1
  33. package/dist/rsuite-rtl.min.css.map +1 -1
  34. package/dist/rsuite.css +22 -15
  35. package/dist/rsuite.js +39 -6
  36. package/dist/rsuite.js.map +1 -1
  37. package/dist/rsuite.min.css +1 -1
  38. package/dist/rsuite.min.css.map +1 -1
  39. package/dist/rsuite.min.js +1 -1
  40. package/dist/rsuite.min.js.map +1 -1
  41. package/esm/Calendar/Calendar.d.ts +6 -1
  42. package/esm/Calendar/Calendar.js +12 -13
  43. package/esm/Calendar/CalendarContainer.d.ts +2 -0
  44. package/esm/Calendar/CalendarContainer.js +4 -2
  45. package/esm/Calendar/TableRow.js +6 -3
  46. package/esm/Calendar/types.d.ts +1 -0
  47. package/esm/SelectPicker/Listbox.d.ts +34 -0
  48. package/esm/SelectPicker/Listbox.js +240 -0
  49. package/esm/SelectPicker/ListboxOption.d.ts +11 -0
  50. package/esm/SelectPicker/ListboxOption.js +37 -0
  51. package/esm/SelectPicker/ListboxOptionGroup.d.ts +9 -0
  52. package/esm/SelectPicker/ListboxOptionGroup.js +53 -0
  53. package/esm/SelectPicker/SelectPicker.js +33 -36
  54. package/esm/Windowing/List.d.ts +2 -2
  55. package/esm/locales/index.d.ts +1 -0
  56. package/esm/locales/index.js +2 -1
  57. package/esm/locales/ne_NP.d.ts +117 -0
  58. package/esm/locales/ne_NP.js +79 -0
  59. package/esm/utils/getDataGroupBy.d.ts +23 -0
  60. package/esm/utils/getDataGroupBy.js +32 -0
  61. package/locales/ne_NP/package.json +7 -0
  62. package/package.json +1 -1
  63. package/styles/mixins/listbox.less +2 -0
@@ -21,6 +21,7 @@ export { default as zhTW } from './zh_TW';
21
21
  export { default as faIR } from './fa_IR';
22
22
  export { default as frFR } from './fr_FR';
23
23
  export { default as jaJP } from './ja_JP';
24
+ export { default as neNP } from './ne_NP';
24
25
  declare type PickKeys<T> = {
25
26
  [keys in keyof T]?: T[keys];
26
27
  };
@@ -19,4 +19,5 @@ export { default as zhCN } from './zh_CN';
19
19
  export { default as zhTW } from './zh_TW';
20
20
  export { default as faIR } from './fa_IR';
21
21
  export { default as frFR } from './fr_FR';
22
- export { default as jaJP } from './ja_JP';
22
+ export { default as jaJP } from './ja_JP';
23
+ export { default as neNP } from './ne_NP';
@@ -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,79 @@
1
+ import _extends from "@babel/runtime/helpers/esm/extends";
2
+ import enGB from 'date-fns/locale/en-GB';
3
+ var Calendar = {
4
+ sunday: 'आ',
5
+ monday: 'सो',
6
+ tuesday: 'म',
7
+ wednesday: 'बु',
8
+ thursday: 'बि',
9
+ friday: 'शु',
10
+ saturday: 'श',
11
+ ok: 'हुन्छ',
12
+ today: 'आज',
13
+ yesterday: 'हिजो',
14
+ hours: 'घण्टा',
15
+ minutes: 'मिनेट',
16
+ seconds: 'सेकेन्ड',
17
+
18
+ /**
19
+ * Format of the string is based on Unicode Technical Standard #35:
20
+ * https://www.unicode.org/reports/tr35/tr35-dates.html#Date_Field_Symbol_Table
21
+ **/
22
+ formattedMonthPattern: 'MMM yyyy',
23
+ formattedDayPattern: 'dd MMM yyyy',
24
+ dateLocale: enGB
25
+ };
26
+ export default {
27
+ common: {
28
+ loading: 'लोड हुँदैछ...',
29
+ emptyMessage: 'कुनै डाटा छैन'
30
+ },
31
+ Plaintext: {
32
+ unfilled: 'भरिएको छैन',
33
+ notSelected: 'चयन गरिएको छैन',
34
+ notUploaded: 'अपलोड गरिएको छैन'
35
+ },
36
+ Pagination: {
37
+ more: 'थप',
38
+ prev: 'अघिल्लो',
39
+ next: 'अर्को',
40
+ first: 'पहिलो',
41
+ last: 'अन्तिम',
42
+ limit: '{0} / पृष्ठ',
43
+ total: 'कुल पङ्क्तिहरू: {0}',
44
+ skip: '{0} पृष्ठमा जानुहोस्'
45
+ },
46
+ Calendar: Calendar,
47
+ DatePicker: _extends({}, Calendar),
48
+ DateRangePicker: _extends({}, Calendar, {
49
+ last7Days: 'पछिल्लो ७ दिन'
50
+ }),
51
+ Picker: {
52
+ noResultsText: 'कुनै परिणाम फेला परेन',
53
+ placeholder: 'चयन गर्नुहोस्',
54
+ searchPlaceholder: 'खोजी गर्नुहोस्',
55
+ checkAll: 'सबै'
56
+ },
57
+ InputPicker: {
58
+ newItem: 'नयाँ थप्नुहोस्',
59
+ createOption: 'विकल्प सिर्जना गर्नुहोस् "{0}"'
60
+ },
61
+ Uploader: {
62
+ inited: 'प्रारम्भिक',
63
+ progress: 'अपलोड गर्दै',
64
+ error: 'त्रुटि भयो',
65
+ complete: 'समाप्त',
66
+ emptyFile: 'खाली',
67
+ upload: 'अपलोड गर्नुहोस्'
68
+ },
69
+ CloseButton: {
70
+ closeLabel: 'बन्द गर्नुहोस्'
71
+ },
72
+ Breadcrumb: {
73
+ expandText: 'स्थान देखाउनुहोस्'
74
+ },
75
+ Toggle: {
76
+ on: 'खोल्नुहोस्',
77
+ off: 'बन्द गर्नुहोस्'
78
+ }
79
+ };
@@ -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>[];
@@ -3,6 +3,11 @@ import { WalkTreeStrategy, flattenTree } from '../utils/treeUtils';
3
3
  var hasSymbol = typeof Symbol === 'function';
4
4
  export var KEY_GROUP = hasSymbol ? Symbol('_$grouped') : '_$grouped';
5
5
  export var KEY_GROUP_TITLE = 'groupTitle';
6
+ /**
7
+ * Chunk data into groups
8
+ * @returns [group, child, child, group, child, child]
9
+ */
10
+
6
11
  export function getDataGroupBy(data, key, sort) {
7
12
  var groupMap = _groupBy(data, key);
8
13
 
@@ -27,4 +32,31 @@ export function getDataGroupBy(data, key, sort) {
27
32
  return flattenTree(groups, function (group) {
28
33
  return group.children;
29
34
  }, WalkTreeStrategy.DFS);
35
+ }
36
+ /**
37
+ * Chunk options into groups
38
+ * @returns [
39
+ * group {
40
+ * key
41
+ * options
42
+ * }
43
+ * group {
44
+ * key
45
+ * options
46
+ * }
47
+ * ]
48
+ */
49
+
50
+ export function groupOptions(options, groupKey, compareOptions, compareGroups) {
51
+ var groupMap = _groupBy(options, groupKey);
52
+
53
+ var groups = Object.entries(groupMap).map(function (_ref3) {
54
+ var key = _ref3[0],
55
+ options = _ref3[1];
56
+ return {
57
+ key: key,
58
+ options: typeof compareOptions === 'function' ? options.sort(compareOptions) : options
59
+ };
60
+ });
61
+ return typeof compareGroups === 'function' ? groups.sort(compareGroups) : groups;
30
62
  }
@@ -0,0 +1,7 @@
1
+ {
2
+ "name": "rsuite/locales/ne_NP",
3
+ "private": true,
4
+ "main": "../../cjs/locales/ne_NP.js",
5
+ "module": "../../esm/locales/ne_NP.js",
6
+ "types": "../../esm/locales/ne_NP.d.ts"
7
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "rsuite",
3
- "version": "5.37.4",
3
+ "version": "5.39.0",
4
4
  "description": "A suite of react components",
5
5
  "main": "cjs/index.js",
6
6
  "module": "esm/index.js",
@@ -32,6 +32,8 @@
32
32
  font-weight: normal;
33
33
  line-height: @line-height-base;
34
34
  color: var(--rs-text-primary);
35
+ // FIXME-Doma
36
+ // No need to use pointer, just use default
35
37
  cursor: pointer;
36
38
  text-decoration: none;
37
39
  width: 100%;