@nocobase/client 0.9.0-alpha.1 → 0.9.0-alpha.2
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/es/antd-config-provider/index.d.ts +3 -1
- package/es/antd-config-provider/index.js +25 -6
- package/es/antd-config-provider/loadConstrueLocale.d.ts +1 -0
- package/es/antd-config-provider/loadConstrueLocale.js +293 -0
- package/es/i18n/i18n.js +7 -12
- package/es/index.d.ts +1 -1
- package/es/index.js +2 -2
- package/es/locale/en_US.d.ts +104 -28
- package/es/locale/en_US.js +104 -28
- package/es/locale/index.d.ts +201 -4
- package/es/locale/index.js +191 -58
- package/es/schema-component/antd/association-filter/AssociationFilter.Item.js +12 -3
- package/es/schema-component/antd/cron/Cron.d.ts +0 -1
- package/es/schema-component/antd/cron/Cron.js +16 -19
- package/es/schema-component/antd/cron/locale/index.d.ts +37 -0
- package/es/schema-component/antd/cron/locale/index.js +6 -0
- package/es/schema-component/antd/filter/useFilterActionProps.js +10 -6
- package/es/schema-component/antd/table-v2/TableBlockDesigner.js +24 -8
- package/es/system-settings/SystemSettingsShortcut.js +1 -1
- package/lib/antd-config-provider/index.d.ts +3 -1
- package/lib/antd-config-provider/index.js +40 -6
- package/lib/antd-config-provider/loadConstrueLocale.d.ts +1 -0
- package/lib/antd-config-provider/loadConstrueLocale.js +304 -0
- package/lib/i18n/i18n.js +7 -14
- package/lib/index.d.ts +1 -1
- package/lib/index.js +13 -13
- package/lib/locale/en_US.d.ts +104 -28
- package/lib/locale/en_US.js +104 -28
- package/lib/locale/index.d.ts +201 -4
- package/lib/locale/index.js +197 -67
- package/lib/schema-component/antd/association-filter/AssociationFilter.Item.js +12 -3
- package/lib/schema-component/antd/cron/Cron.d.ts +0 -1
- package/lib/schema-component/antd/cron/Cron.js +19 -24
- package/lib/schema-component/antd/cron/locale/index.d.ts +37 -0
- package/lib/schema-component/antd/cron/locale/index.js +18 -0
- package/lib/schema-component/antd/filter/useFilterActionProps.js +10 -6
- package/lib/schema-component/antd/table-v2/TableBlockDesigner.js +25 -8
- package/lib/system-settings/SystemSettingsShortcut.js +1 -1
- package/package.json +6 -5
package/lib/locale/index.d.ts
CHANGED
|
@@ -1,8 +1,205 @@
|
|
|
1
1
|
export declare type LocaleOptions = {
|
|
2
2
|
label: string;
|
|
3
|
-
moment: string;
|
|
4
|
-
antd: any;
|
|
5
|
-
resources?: any;
|
|
6
3
|
};
|
|
7
|
-
|
|
4
|
+
export { default as cron } from '../schema-component/antd/cron/locale';
|
|
5
|
+
declare const _default: {
|
|
6
|
+
'ar-EG': {
|
|
7
|
+
label: string;
|
|
8
|
+
};
|
|
9
|
+
'az-AZ': {
|
|
10
|
+
label: string;
|
|
11
|
+
};
|
|
12
|
+
'bg-BG': {
|
|
13
|
+
label: string;
|
|
14
|
+
};
|
|
15
|
+
'bn-BD': {
|
|
16
|
+
label: string;
|
|
17
|
+
};
|
|
18
|
+
'by-BY': {
|
|
19
|
+
label: string;
|
|
20
|
+
};
|
|
21
|
+
'ca-ES': {
|
|
22
|
+
label: string;
|
|
23
|
+
};
|
|
24
|
+
'cs-CZ': {
|
|
25
|
+
label: string;
|
|
26
|
+
};
|
|
27
|
+
'da-DK': {
|
|
28
|
+
label: string;
|
|
29
|
+
};
|
|
30
|
+
'de-DE': {
|
|
31
|
+
label: string;
|
|
32
|
+
};
|
|
33
|
+
'el-GR': {
|
|
34
|
+
label: string;
|
|
35
|
+
};
|
|
36
|
+
'en-GB': {
|
|
37
|
+
label: string;
|
|
38
|
+
};
|
|
39
|
+
'en-US': {
|
|
40
|
+
label: string;
|
|
41
|
+
};
|
|
42
|
+
'es-ES': {
|
|
43
|
+
label: string;
|
|
44
|
+
};
|
|
45
|
+
'et-EE': {
|
|
46
|
+
label: string;
|
|
47
|
+
};
|
|
48
|
+
'fa-IR': {
|
|
49
|
+
label: string;
|
|
50
|
+
};
|
|
51
|
+
'fi-FI': {
|
|
52
|
+
label: string;
|
|
53
|
+
};
|
|
54
|
+
'fr-BE': {
|
|
55
|
+
label: string;
|
|
56
|
+
};
|
|
57
|
+
'fr-CA': {
|
|
58
|
+
label: string;
|
|
59
|
+
};
|
|
60
|
+
'fr-FR': {
|
|
61
|
+
label: string;
|
|
62
|
+
};
|
|
63
|
+
'ga-IE': {
|
|
64
|
+
label: string;
|
|
65
|
+
};
|
|
66
|
+
'gl-ES': {
|
|
67
|
+
label: string;
|
|
68
|
+
};
|
|
69
|
+
'he-IL': {
|
|
70
|
+
label: string;
|
|
71
|
+
};
|
|
72
|
+
'hi-IN': {
|
|
73
|
+
label: string;
|
|
74
|
+
};
|
|
75
|
+
'hr-HR': {
|
|
76
|
+
label: string;
|
|
77
|
+
};
|
|
78
|
+
'hu-HU': {
|
|
79
|
+
label: string;
|
|
80
|
+
};
|
|
81
|
+
'hy-AM': {
|
|
82
|
+
label: string;
|
|
83
|
+
};
|
|
84
|
+
'id-ID': {
|
|
85
|
+
label: string;
|
|
86
|
+
};
|
|
87
|
+
'is-IS': {
|
|
88
|
+
label: string;
|
|
89
|
+
};
|
|
90
|
+
'it-IT': {
|
|
91
|
+
label: string;
|
|
92
|
+
};
|
|
93
|
+
'ja-JP': {
|
|
94
|
+
label: string;
|
|
95
|
+
};
|
|
96
|
+
'ka-GE': {
|
|
97
|
+
label: string;
|
|
98
|
+
};
|
|
99
|
+
'kk-KZ': {
|
|
100
|
+
label: string;
|
|
101
|
+
};
|
|
102
|
+
'km-KH': {
|
|
103
|
+
label: string;
|
|
104
|
+
};
|
|
105
|
+
'kn-IN': {
|
|
106
|
+
label: string;
|
|
107
|
+
};
|
|
108
|
+
'ko-KR': {
|
|
109
|
+
label: string;
|
|
110
|
+
};
|
|
111
|
+
'ku-IQ': {
|
|
112
|
+
label: string;
|
|
113
|
+
};
|
|
114
|
+
'lt-LT': {
|
|
115
|
+
label: string;
|
|
116
|
+
};
|
|
117
|
+
'lv-LV': {
|
|
118
|
+
label: string;
|
|
119
|
+
};
|
|
120
|
+
'mk-MK': {
|
|
121
|
+
label: string;
|
|
122
|
+
};
|
|
123
|
+
'ml-IN': {
|
|
124
|
+
label: string;
|
|
125
|
+
};
|
|
126
|
+
'mn-MN': {
|
|
127
|
+
label: string;
|
|
128
|
+
};
|
|
129
|
+
'ms-MY': {
|
|
130
|
+
label: string;
|
|
131
|
+
};
|
|
132
|
+
'nb-NO': {
|
|
133
|
+
label: string;
|
|
134
|
+
};
|
|
135
|
+
'ne-NP': {
|
|
136
|
+
label: string;
|
|
137
|
+
};
|
|
138
|
+
'nl-BE': {
|
|
139
|
+
label: string;
|
|
140
|
+
};
|
|
141
|
+
'nl-NL': {
|
|
142
|
+
label: string;
|
|
143
|
+
};
|
|
144
|
+
'pl-PL': {
|
|
145
|
+
label: string;
|
|
146
|
+
};
|
|
147
|
+
'pt-BR': {
|
|
148
|
+
label: string;
|
|
149
|
+
};
|
|
150
|
+
'pt-PT': {
|
|
151
|
+
label: string;
|
|
152
|
+
};
|
|
153
|
+
'ro-RO': {
|
|
154
|
+
label: string;
|
|
155
|
+
};
|
|
156
|
+
'ru-RU': {
|
|
157
|
+
label: string;
|
|
158
|
+
};
|
|
159
|
+
'si-LK': {
|
|
160
|
+
label: string;
|
|
161
|
+
};
|
|
162
|
+
'sk-SK': {
|
|
163
|
+
label: string;
|
|
164
|
+
};
|
|
165
|
+
'sl-SI': {
|
|
166
|
+
label: string;
|
|
167
|
+
};
|
|
168
|
+
'sr-RS': {
|
|
169
|
+
label: string;
|
|
170
|
+
};
|
|
171
|
+
'sv-SE': {
|
|
172
|
+
label: string;
|
|
173
|
+
};
|
|
174
|
+
'ta-IN': {
|
|
175
|
+
label: string;
|
|
176
|
+
};
|
|
177
|
+
'th-TH': {
|
|
178
|
+
label: string;
|
|
179
|
+
};
|
|
180
|
+
'tk-TK': {
|
|
181
|
+
label: string;
|
|
182
|
+
};
|
|
183
|
+
'tr-TR': {
|
|
184
|
+
label: string;
|
|
185
|
+
};
|
|
186
|
+
'uk-UA': {
|
|
187
|
+
label: string;
|
|
188
|
+
};
|
|
189
|
+
'ur-PK': {
|
|
190
|
+
label: string;
|
|
191
|
+
};
|
|
192
|
+
'vi-VN': {
|
|
193
|
+
label: string;
|
|
194
|
+
};
|
|
195
|
+
'zh-CN': {
|
|
196
|
+
label: string;
|
|
197
|
+
};
|
|
198
|
+
'zh-HK': {
|
|
199
|
+
label: string;
|
|
200
|
+
};
|
|
201
|
+
'zh-TW': {
|
|
202
|
+
label: string;
|
|
203
|
+
};
|
|
204
|
+
};
|
|
8
205
|
export default _default;
|
package/lib/locale/index.js
CHANGED
|
@@ -3,87 +3,217 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
+
Object.defineProperty(exports, "cron", {
|
|
7
|
+
enumerable: true,
|
|
8
|
+
get: function get() {
|
|
9
|
+
return _locale.default;
|
|
10
|
+
}
|
|
11
|
+
});
|
|
6
12
|
exports.default = void 0;
|
|
7
13
|
|
|
8
|
-
var
|
|
9
|
-
|
|
10
|
-
var _ja_JP = _interopRequireDefault(require("antd/lib/locale/ja_JP"));
|
|
11
|
-
|
|
12
|
-
var _ru_RU = _interopRequireDefault(require("antd/lib/locale/ru_RU"));
|
|
13
|
-
|
|
14
|
-
var _tr_TR = _interopRequireDefault(require("antd/lib/locale/tr_TR"));
|
|
15
|
-
|
|
16
|
-
var _zh_CN = _interopRequireDefault(require("antd/lib/locale/zh_CN"));
|
|
17
|
-
|
|
18
|
-
var _en_US2 = _interopRequireDefault(require("./en_US"));
|
|
19
|
-
|
|
20
|
-
var _ja_JP2 = _interopRequireDefault(require("./ja_JP"));
|
|
21
|
-
|
|
22
|
-
var _ru_RU2 = _interopRequireDefault(require("./ru_RU"));
|
|
23
|
-
|
|
24
|
-
var _tr_TR2 = _interopRequireDefault(require("./tr_TR"));
|
|
25
|
-
|
|
26
|
-
var _zh_CN2 = _interopRequireDefault(require("./zh_CN"));
|
|
14
|
+
var _locale = _interopRequireDefault(require("../schema-component/antd/cron/locale"));
|
|
27
15
|
|
|
28
16
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
29
17
|
|
|
30
|
-
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
31
|
-
|
|
32
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
33
|
-
|
|
34
|
-
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
35
|
-
|
|
36
18
|
var _default = {
|
|
19
|
+
'ar-EG': {
|
|
20
|
+
label: 'العربية'
|
|
21
|
+
},
|
|
22
|
+
'az-AZ': {
|
|
23
|
+
label: 'Azərbaycan dili'
|
|
24
|
+
},
|
|
25
|
+
'bg-BG': {
|
|
26
|
+
label: 'Български'
|
|
27
|
+
},
|
|
28
|
+
'bn-BD': {
|
|
29
|
+
label: 'Bengali'
|
|
30
|
+
},
|
|
31
|
+
'by-BY': {
|
|
32
|
+
label: 'Беларускі'
|
|
33
|
+
},
|
|
34
|
+
'ca-ES': {
|
|
35
|
+
label: 'Сatalà/Espanya'
|
|
36
|
+
},
|
|
37
|
+
'cs-CZ': {
|
|
38
|
+
label: 'Česky'
|
|
39
|
+
},
|
|
40
|
+
'da-DK': {
|
|
41
|
+
label: 'Dansk'
|
|
42
|
+
},
|
|
43
|
+
'de-DE': {
|
|
44
|
+
label: 'Deutsch'
|
|
45
|
+
},
|
|
46
|
+
'el-GR': {
|
|
47
|
+
label: 'Ελληνικά'
|
|
48
|
+
},
|
|
49
|
+
'en-GB': {
|
|
50
|
+
label: 'English(GB)'
|
|
51
|
+
},
|
|
37
52
|
'en-US': {
|
|
38
|
-
label: 'English'
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
53
|
+
label: 'English'
|
|
54
|
+
},
|
|
55
|
+
'es-ES': {
|
|
56
|
+
label: 'Español'
|
|
57
|
+
},
|
|
58
|
+
'et-EE': {
|
|
59
|
+
label: 'Estonian (Eesti)'
|
|
60
|
+
},
|
|
61
|
+
'fa-IR': {
|
|
62
|
+
label: 'فارسی'
|
|
63
|
+
},
|
|
64
|
+
'fi-FI': {
|
|
65
|
+
label: 'Suomi'
|
|
66
|
+
},
|
|
67
|
+
'fr-BE': {
|
|
68
|
+
label: 'Français(BE)'
|
|
69
|
+
},
|
|
70
|
+
'fr-CA': {
|
|
71
|
+
label: 'Français(CA)'
|
|
72
|
+
},
|
|
73
|
+
'fr-FR': {
|
|
74
|
+
label: 'Français'
|
|
75
|
+
},
|
|
76
|
+
'ga-IE': {
|
|
77
|
+
label: 'Gaeilge'
|
|
78
|
+
},
|
|
79
|
+
'gl-ES': {
|
|
80
|
+
label: 'Galego'
|
|
81
|
+
},
|
|
82
|
+
'he-IL': {
|
|
83
|
+
label: 'עברית'
|
|
84
|
+
},
|
|
85
|
+
'hi-IN': {
|
|
86
|
+
label: 'हिन्दी'
|
|
87
|
+
},
|
|
88
|
+
'hr-HR': {
|
|
89
|
+
label: 'Hrvatski jezik'
|
|
90
|
+
},
|
|
91
|
+
'hu-HU': {
|
|
92
|
+
label: 'Magyar'
|
|
93
|
+
},
|
|
94
|
+
'hy-AM': {
|
|
95
|
+
label: 'Հայերեն'
|
|
96
|
+
},
|
|
97
|
+
'id-ID': {
|
|
98
|
+
label: 'Bahasa Indonesia'
|
|
99
|
+
},
|
|
100
|
+
'is-IS': {
|
|
101
|
+
label: 'Íslenska'
|
|
102
|
+
},
|
|
103
|
+
'it-IT': {
|
|
104
|
+
label: 'Italiano'
|
|
46
105
|
},
|
|
47
106
|
'ja-JP': {
|
|
48
|
-
label: '日本語'
|
|
49
|
-
// https://github.com/moment/moment/blob/develop/locale/ja.js
|
|
50
|
-
moment: 'ja',
|
|
51
|
-
// https://github.com/ant-design/ant-design/tree/master/components/locale/ja_JP
|
|
52
|
-
antd: _ja_JP.default,
|
|
53
|
-
resources: {
|
|
54
|
-
client: _objectSpread({}, _ja_JP2.default)
|
|
55
|
-
}
|
|
107
|
+
label: '日本語'
|
|
56
108
|
},
|
|
57
|
-
'
|
|
58
|
-
label: '
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
109
|
+
'ka-GE': {
|
|
110
|
+
label: 'ქართული'
|
|
111
|
+
},
|
|
112
|
+
'kk-KZ': {
|
|
113
|
+
label: 'Қазақ тілі'
|
|
114
|
+
},
|
|
115
|
+
'km-KH': {
|
|
116
|
+
label: 'ភាសាខ្មែរ'
|
|
117
|
+
},
|
|
118
|
+
// 'kmr-IQ': { label: 'kmr_IQ' },
|
|
119
|
+
'kn-IN': {
|
|
120
|
+
label: 'ಕನ್ನಡ'
|
|
121
|
+
},
|
|
122
|
+
'ko-KR': {
|
|
123
|
+
label: '한국어'
|
|
124
|
+
},
|
|
125
|
+
'ku-IQ': {
|
|
126
|
+
label: 'کوردی'
|
|
127
|
+
},
|
|
128
|
+
'lt-LT': {
|
|
129
|
+
label: 'lietuvių'
|
|
130
|
+
},
|
|
131
|
+
'lv-LV': {
|
|
132
|
+
label: 'Latviešu valoda'
|
|
133
|
+
},
|
|
134
|
+
'mk-MK': {
|
|
135
|
+
label: 'македонски јазик'
|
|
136
|
+
},
|
|
137
|
+
'ml-IN': {
|
|
138
|
+
label: 'മലയാളം'
|
|
139
|
+
},
|
|
140
|
+
'mn-MN': {
|
|
141
|
+
label: 'Монгол хэл'
|
|
142
|
+
},
|
|
143
|
+
'ms-MY': {
|
|
144
|
+
label: 'بهاس ملايو'
|
|
145
|
+
},
|
|
146
|
+
'nb-NO': {
|
|
147
|
+
label: 'Norsk bokmål'
|
|
148
|
+
},
|
|
149
|
+
'ne-NP': {
|
|
150
|
+
label: 'नेपाली'
|
|
151
|
+
},
|
|
152
|
+
'nl-BE': {
|
|
153
|
+
label: 'Vlaams'
|
|
154
|
+
},
|
|
155
|
+
'nl-NL': {
|
|
156
|
+
label: 'Nederlands'
|
|
157
|
+
},
|
|
158
|
+
'pl-PL': {
|
|
159
|
+
label: 'Polski'
|
|
160
|
+
},
|
|
161
|
+
'pt-BR': {
|
|
162
|
+
label: 'Português brasileiro'
|
|
163
|
+
},
|
|
164
|
+
'pt-PT': {
|
|
165
|
+
label: 'Português'
|
|
166
|
+
},
|
|
167
|
+
'ro-RO': {
|
|
168
|
+
label: 'România'
|
|
67
169
|
},
|
|
68
170
|
'ru-RU': {
|
|
69
|
-
label: 'Русский'
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
171
|
+
label: 'Русский'
|
|
172
|
+
},
|
|
173
|
+
'si-LK': {
|
|
174
|
+
label: 'සිංහල'
|
|
175
|
+
},
|
|
176
|
+
'sk-SK': {
|
|
177
|
+
label: 'Slovenčina'
|
|
178
|
+
},
|
|
179
|
+
'sl-SI': {
|
|
180
|
+
label: 'Slovenščina'
|
|
181
|
+
},
|
|
182
|
+
'sr-RS': {
|
|
183
|
+
label: 'српски језик'
|
|
184
|
+
},
|
|
185
|
+
'sv-SE': {
|
|
186
|
+
label: 'Svenska'
|
|
187
|
+
},
|
|
188
|
+
'ta-IN': {
|
|
189
|
+
label: 'Tamil'
|
|
190
|
+
},
|
|
191
|
+
'th-TH': {
|
|
192
|
+
label: 'ภาษาไทย'
|
|
193
|
+
},
|
|
194
|
+
'tk-TK': {
|
|
195
|
+
label: 'Turkmen'
|
|
77
196
|
},
|
|
78
197
|
'tr-TR': {
|
|
79
|
-
label: 'Türkçe'
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
198
|
+
label: 'Türkçe'
|
|
199
|
+
},
|
|
200
|
+
'uk-UA': {
|
|
201
|
+
label: 'Українська'
|
|
202
|
+
},
|
|
203
|
+
'ur-PK': {
|
|
204
|
+
label: 'Oʻzbekcha'
|
|
205
|
+
},
|
|
206
|
+
'vi-VN': {
|
|
207
|
+
label: 'Tiếng Việt'
|
|
208
|
+
},
|
|
209
|
+
'zh-CN': {
|
|
210
|
+
label: '简体中文'
|
|
211
|
+
},
|
|
212
|
+
'zh-HK': {
|
|
213
|
+
label: '繁體中文(香港)'
|
|
214
|
+
},
|
|
215
|
+
'zh-TW': {
|
|
216
|
+
label: '繁體中文(台湾)'
|
|
87
217
|
}
|
|
88
218
|
};
|
|
89
219
|
exports.default = _default;
|
|
@@ -41,6 +41,14 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
|
|
|
41
41
|
|
|
42
42
|
function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
|
|
43
43
|
|
|
44
|
+
function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread(); }
|
|
45
|
+
|
|
46
|
+
function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
47
|
+
|
|
48
|
+
function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
|
|
49
|
+
|
|
50
|
+
function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); }
|
|
51
|
+
|
|
44
52
|
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
45
53
|
|
|
46
54
|
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
@@ -75,7 +83,8 @@ var AssociationFilterItem = function AssociationFilterItem(props) {
|
|
|
75
83
|
var compile = (0, _hooks.useCompile)();
|
|
76
84
|
|
|
77
85
|
var _useBlockRequestConte = (0, _blockProvider.useBlockRequestContext)(),
|
|
78
|
-
service = _useBlockRequestConte.service
|
|
86
|
+
service = _useBlockRequestConte.service,
|
|
87
|
+
blockProps = _useBlockRequestConte.props;
|
|
79
88
|
|
|
80
89
|
var _useState = (0, _react2.useState)(false),
|
|
81
90
|
_useState2 = _slicedToArray(_useState, 2),
|
|
@@ -130,7 +139,7 @@ var AssociationFilterItem = function AssociationFilterItem(props) {
|
|
|
130
139
|
};
|
|
131
140
|
|
|
132
141
|
var onSelect = function onSelect(selectedKeysValue) {
|
|
133
|
-
var _service$params, _service$params$, _service$params2;
|
|
142
|
+
var _service$params, _service$params$, _service$params2, _blockProps$params;
|
|
134
143
|
|
|
135
144
|
setSelectedKeys(selectedKeysValue);
|
|
136
145
|
var filters = ((_service$params = service.params) === null || _service$params === void 0 ? void 0 : (_service$params$ = _service$params[1]) === null || _service$params$ === void 0 ? void 0 : _service$params$.filters) || {};
|
|
@@ -144,7 +153,7 @@ var AssociationFilterItem = function AssociationFilterItem(props) {
|
|
|
144
153
|
service.run(_objectSpread(_objectSpread({}, (_service$params2 = service.params) === null || _service$params2 === void 0 ? void 0 : _service$params2[0]), {}, {
|
|
145
154
|
pageSize: 200,
|
|
146
155
|
page: 1,
|
|
147
|
-
filter: (0, _SharedFilterProvider.mergeFilter)(Object.values(filters))
|
|
156
|
+
filter: (0, _SharedFilterProvider.mergeFilter)([].concat(_toConsumableArray(Object.values(filters)), [blockProps === null || blockProps === void 0 ? void 0 : (_blockProps$params = blockProps.params) === null || _blockProps$params === void 0 ? void 0 : _blockProps$params.filter]))
|
|
148
157
|
}), {
|
|
149
158
|
filters: filters
|
|
150
159
|
});
|
|
@@ -5,19 +5,17 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports.default = exports.Cron = void 0;
|
|
7
7
|
|
|
8
|
-
var
|
|
9
|
-
|
|
10
|
-
var _react2 = require("@formily/react");
|
|
8
|
+
var _css = require("@emotion/css");
|
|
11
9
|
|
|
12
|
-
var
|
|
10
|
+
var _react = require("@formily/react");
|
|
13
11
|
|
|
14
12
|
var _cronstrue = _interopRequireDefault(require("cronstrue"));
|
|
15
13
|
|
|
16
|
-
require("
|
|
14
|
+
var _react2 = _interopRequireDefault(require("react"));
|
|
17
15
|
|
|
18
|
-
var
|
|
16
|
+
var _reactJsCron = require("react-js-cron");
|
|
19
17
|
|
|
20
|
-
var
|
|
18
|
+
var _apiClient = require("../../../api-client");
|
|
21
19
|
|
|
22
20
|
var _templateObject;
|
|
23
21
|
|
|
@@ -37,31 +35,28 @@ function _objectWithoutProperties(source, excluded) { if (source == null) return
|
|
|
37
35
|
|
|
38
36
|
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
39
37
|
|
|
40
|
-
var
|
|
41
|
-
'zh-CN': _zhCN.default
|
|
42
|
-
};
|
|
43
|
-
var ReadPrettyLocales = {
|
|
44
|
-
'en-US': 'en',
|
|
45
|
-
'zh-CN': 'zh_CN'
|
|
46
|
-
};
|
|
47
|
-
var Cron = (0, _react2.connect)(function (props) {
|
|
38
|
+
var Input = function Input(props) {
|
|
48
39
|
var onChange = props.onChange,
|
|
49
40
|
rest = _objectWithoutProperties(props, _excluded);
|
|
50
41
|
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
}, /*#__PURE__*/_react.default.createElement(_reactJsCron.Cron, _objectSpread({
|
|
42
|
+
return /*#__PURE__*/_react2.default.createElement("fieldset", {
|
|
43
|
+
className: (0, _css.css)(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n .react-js-cron {\n padding: 0.5em 0.5em 0 0.5em;\n border: 1px dashed #ccc;\n .react-js-cron-field {\n flex-shrink: 0;\n margin-bottom: 0.5em;\n\n > span {\n flex-shrink: 0;\n margin: 0 0.5em 0 0;\n }\n\n > .react-js-cron-select {\n margin: 0 0.5em 0 0;\n }\n }\n }\n "])))
|
|
44
|
+
}, /*#__PURE__*/_react2.default.createElement(_reactJsCron.Cron, _objectSpread({
|
|
55
45
|
setValue: onChange,
|
|
56
|
-
locale:
|
|
46
|
+
locale: window['cronLocale']
|
|
57
47
|
}, rest)));
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
|
|
48
|
+
};
|
|
49
|
+
|
|
50
|
+
var ReadPretty = function ReadPretty(props) {
|
|
51
|
+
var api = (0, _apiClient.useAPIClient)();
|
|
52
|
+
var locale = api.auth.getLocale();
|
|
53
|
+
return props.value ? /*#__PURE__*/_react2.default.createElement("span", null, _cronstrue.default.toString(props.value, {
|
|
61
54
|
locale: locale,
|
|
62
55
|
use24HourTimeFormat: true
|
|
63
56
|
})) : null;
|
|
64
|
-
}
|
|
57
|
+
};
|
|
58
|
+
|
|
59
|
+
var Cron = (0, _react.connect)(Input, (0, _react.mapReadPretty)(ReadPretty));
|
|
65
60
|
exports.Cron = Cron;
|
|
66
61
|
var _default = Cron;
|
|
67
62
|
exports.default = _default;
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
declare const _default: {
|
|
2
|
+
'zh-CN': {
|
|
3
|
+
everyText: string;
|
|
4
|
+
emptyMonths: string;
|
|
5
|
+
emptyMonthDays: string;
|
|
6
|
+
emptyMonthDaysShort: string;
|
|
7
|
+
emptyWeekDays: string;
|
|
8
|
+
emptyWeekDaysShort: string;
|
|
9
|
+
emptyHours: string;
|
|
10
|
+
emptyMinutes: string;
|
|
11
|
+
emptyMinutesForHourPeriod: string;
|
|
12
|
+
yearOption: string;
|
|
13
|
+
monthOption: string;
|
|
14
|
+
weekOption: string;
|
|
15
|
+
dayOption: string;
|
|
16
|
+
hourOption: string;
|
|
17
|
+
minuteOption: string;
|
|
18
|
+
rebootOption: string;
|
|
19
|
+
prefixPeriod: string;
|
|
20
|
+
prefixMonths: string;
|
|
21
|
+
prefixMonthDays: string;
|
|
22
|
+
prefixWeekDays: string;
|
|
23
|
+
prefixWeekDaysForMonthAndYearPeriod: string;
|
|
24
|
+
prefixHours: string;
|
|
25
|
+
prefixMinutes: string;
|
|
26
|
+
prefixMinutesForHourPeriod: string;
|
|
27
|
+
suffixMinutesForHourPeriod: string;
|
|
28
|
+
errorInvalidCron: string;
|
|
29
|
+
clearButtonText: string;
|
|
30
|
+
weekDays: string[];
|
|
31
|
+
months: string[];
|
|
32
|
+
altWeekDays: string[];
|
|
33
|
+
altMonths: string[];
|
|
34
|
+
};
|
|
35
|
+
'en-US': import("react-js-cron").DefaultLocale;
|
|
36
|
+
};
|
|
37
|
+
export default _default;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.default = void 0;
|
|
7
|
+
|
|
8
|
+
var _locale = require("react-js-cron/dist/cjs/locale");
|
|
9
|
+
|
|
10
|
+
var _zhCN = _interopRequireDefault(require("./zh-CN"));
|
|
11
|
+
|
|
12
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
13
|
+
|
|
14
|
+
var _default = {
|
|
15
|
+
'zh-CN': _zhCN.default,
|
|
16
|
+
'en-US': _locale.DEFAULT_LOCALE_EN
|
|
17
|
+
};
|
|
18
|
+
exports.default = _default;
|