vue-devui 1.6.32 → 1.6.34
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/auto-complete/index.es.js +131 -26
- package/auto-complete/index.umd.js +12 -12
- package/data-grid/index.es.js +131 -26
- package/data-grid/index.umd.js +18 -18
- package/date-picker-pro/index.es.js +131 -26
- package/date-picker-pro/index.umd.js +16 -16
- package/editable-select/index.es.js +131 -26
- package/editable-select/index.umd.js +16 -16
- package/editor-md/index.es.js +6 -2
- package/editor-md/index.umd.js +16 -15
- package/input/index.es.js +136 -31
- package/input/index.umd.js +22 -22
- package/locale/index.es.js +271 -0
- package/locale/index.umd.js +1 -0
- package/locale/package.json +8 -0
- package/nuxt/components/Locale.js +2 -0
- package/package.json +1 -1
- package/pagination/index.es.js +131 -26
- package/pagination/index.umd.js +11 -11
- package/search/index.es.js +136 -31
- package/search/index.umd.js +12 -12
- package/select/index.es.js +131 -26
- package/select/index.umd.js +21 -21
- package/splitter/index.es.js +136 -31
- package/splitter/index.umd.js +14 -14
- package/table/index.es.js +131 -26
- package/table/index.umd.js +10 -10
- package/time-picker/index.es.js +131 -26
- package/time-picker/index.umd.js +15 -15
- package/time-select/index.es.js +131 -26
- package/time-select/index.umd.js +18 -18
- package/tree/index.es.js +131 -26
- package/tree/index.umd.js +26 -26
- package/types/locale/index.d.ts +7 -4
- package/upload/index.es.js +131 -26
- package/upload/index.umd.js +3 -3
- package/vue-devui.es.js +138 -29
- package/vue-devui.umd.js +68 -67
package/select/index.es.js
CHANGED
|
@@ -9093,23 +9093,6 @@ var Tag = defineComponent({
|
|
|
9093
9093
|
};
|
|
9094
9094
|
}
|
|
9095
9095
|
});
|
|
9096
|
-
function deepAssign(...objects) {
|
|
9097
|
-
const isObject2 = (obj) => obj && typeof obj === "object";
|
|
9098
|
-
return objects.reduce((prev, from) => {
|
|
9099
|
-
Object.keys(from).forEach((key) => {
|
|
9100
|
-
const pVal = prev[key];
|
|
9101
|
-
const oVal = from[key];
|
|
9102
|
-
if (Array.isArray(pVal) && Array.isArray(oVal)) {
|
|
9103
|
-
prev[key] = Array.from(/* @__PURE__ */ new Set([...oVal, ...pVal]));
|
|
9104
|
-
} else if (isObject2(pVal) && isObject2(oVal)) {
|
|
9105
|
-
prev[key] = deepAssign(pVal, oVal);
|
|
9106
|
-
} else {
|
|
9107
|
-
prev[key] = oVal;
|
|
9108
|
-
}
|
|
9109
|
-
});
|
|
9110
|
-
return prev;
|
|
9111
|
-
}, {});
|
|
9112
|
-
}
|
|
9113
9096
|
var zhCN = {
|
|
9114
9097
|
pagination: {
|
|
9115
9098
|
totalItemText: "\u6240\u6709\u6761\u76EE",
|
|
@@ -9228,23 +9211,146 @@ var zhCN = {
|
|
|
9228
9211
|
placeholder: "\u8BF7\u9009\u62E9\u65F6\u95F4"
|
|
9229
9212
|
}
|
|
9230
9213
|
};
|
|
9214
|
+
var enUS = {
|
|
9215
|
+
pagination: {
|
|
9216
|
+
totalItemText: "Total",
|
|
9217
|
+
goToText: "Go to"
|
|
9218
|
+
},
|
|
9219
|
+
accordion: {
|
|
9220
|
+
loading: "loading",
|
|
9221
|
+
noData: "No Data"
|
|
9222
|
+
},
|
|
9223
|
+
autoCompleteDropdown: {
|
|
9224
|
+
latestInput: "Latest input"
|
|
9225
|
+
},
|
|
9226
|
+
cascaderList: {
|
|
9227
|
+
noData: "No data"
|
|
9228
|
+
},
|
|
9229
|
+
colorPicker: {
|
|
9230
|
+
foundationPanel: "Foundation panel",
|
|
9231
|
+
advancedPanel: "Advanced panel"
|
|
9232
|
+
},
|
|
9233
|
+
datePickerPro: {
|
|
9234
|
+
ok: "OK",
|
|
9235
|
+
placeholder: "select date",
|
|
9236
|
+
month1: "Jan",
|
|
9237
|
+
month2: "Feb",
|
|
9238
|
+
month3: "Mar",
|
|
9239
|
+
month4: "Apr",
|
|
9240
|
+
month5: "May",
|
|
9241
|
+
month6: "June",
|
|
9242
|
+
month7: "July",
|
|
9243
|
+
month8: "Aug",
|
|
9244
|
+
month9: "Sep",
|
|
9245
|
+
month10: "Oct",
|
|
9246
|
+
month11: "Nov",
|
|
9247
|
+
month12: "Dec",
|
|
9248
|
+
year: "\u5E74",
|
|
9249
|
+
startPlaceholder: "select start date",
|
|
9250
|
+
endPlaceholder: "select end date",
|
|
9251
|
+
getWeekDays() {
|
|
9252
|
+
return ["Sun", "Mon", "Tue", "Wed", "Thur", "Fri", "Sat"];
|
|
9253
|
+
},
|
|
9254
|
+
getTimeArr() {
|
|
9255
|
+
return ["Hr", "Min", "Sec"];
|
|
9256
|
+
},
|
|
9257
|
+
getYearMonthStr(year, month) {
|
|
9258
|
+
return `${year} - ${month}`;
|
|
9259
|
+
}
|
|
9260
|
+
},
|
|
9261
|
+
editableSelect: {
|
|
9262
|
+
noRelatedRecords: "No related records found",
|
|
9263
|
+
noData: "No data"
|
|
9264
|
+
},
|
|
9265
|
+
input: {
|
|
9266
|
+
placeholder: "Please enter"
|
|
9267
|
+
},
|
|
9268
|
+
splitterBar: {
|
|
9269
|
+
collapse: "Collapse",
|
|
9270
|
+
expand: "Expand"
|
|
9271
|
+
},
|
|
9272
|
+
stepsGuide: {
|
|
9273
|
+
previous: "Previous",
|
|
9274
|
+
continue: "Continue",
|
|
9275
|
+
ok: "OK"
|
|
9276
|
+
},
|
|
9277
|
+
table: {
|
|
9278
|
+
selectAll: "Select all",
|
|
9279
|
+
ok: "OK"
|
|
9280
|
+
},
|
|
9281
|
+
dataGrid: {
|
|
9282
|
+
selectAll: "Select all",
|
|
9283
|
+
ok: "OK"
|
|
9284
|
+
},
|
|
9285
|
+
timePopup: {
|
|
9286
|
+
ok: "OK"
|
|
9287
|
+
},
|
|
9288
|
+
transfer: {
|
|
9289
|
+
unit: "",
|
|
9290
|
+
panelUnit: "",
|
|
9291
|
+
headerUnit: "",
|
|
9292
|
+
noData: "No Data",
|
|
9293
|
+
placeholder: "Please enter keywords"
|
|
9294
|
+
},
|
|
9295
|
+
tree: {
|
|
9296
|
+
loading: "Loading",
|
|
9297
|
+
newNode: "New node",
|
|
9298
|
+
selectPlaceholder: "Please select"
|
|
9299
|
+
},
|
|
9300
|
+
upload: {
|
|
9301
|
+
placeholder: "select file",
|
|
9302
|
+
getExistSameNameFilesMsg(sameNames) {
|
|
9303
|
+
return `Duplicate files exist : "${sameNames}" `;
|
|
9304
|
+
},
|
|
9305
|
+
getAllFilesBeyondMaximalFileSizeMsg(maximalSize) {
|
|
9306
|
+
return `Maximum file size (MB): ${maximalSize}. The selected files exceed the maximum value`;
|
|
9307
|
+
},
|
|
9308
|
+
getBeyondMaximalFileSizeMsg(filename, maximalSize) {
|
|
9309
|
+
return `Maximum file size (MB): ${maximalSize}. Files whose size exceeds the maximum value: ${filename}`;
|
|
9310
|
+
},
|
|
9311
|
+
getNotAllowedFileTypeMsg(filename, scope) {
|
|
9312
|
+
return `Files with unsupported types: ${filename}. Supported file types: ${scope}`;
|
|
9313
|
+
}
|
|
9314
|
+
},
|
|
9315
|
+
search: {
|
|
9316
|
+
placeholder: "Enter a keyword"
|
|
9317
|
+
},
|
|
9318
|
+
select: {
|
|
9319
|
+
placeholder: "Please select",
|
|
9320
|
+
noDataText: "No data",
|
|
9321
|
+
noMatchText: "No related records found",
|
|
9322
|
+
loadingText: "Loading..."
|
|
9323
|
+
},
|
|
9324
|
+
tagInput: {
|
|
9325
|
+
maxTagsText: "Maximum number reached: "
|
|
9326
|
+
},
|
|
9327
|
+
timeSelect: {
|
|
9328
|
+
placeholder: "Please select time"
|
|
9329
|
+
}
|
|
9330
|
+
};
|
|
9231
9331
|
const lang = ref("zh-CN");
|
|
9332
|
+
const nowApp = ref();
|
|
9232
9333
|
let langMessages = reactive({
|
|
9233
|
-
[
|
|
9334
|
+
["zh-CN"]: zhCN,
|
|
9335
|
+
["en-US"]: enUS
|
|
9234
9336
|
});
|
|
9235
9337
|
const Locale = {
|
|
9236
|
-
messages() {
|
|
9237
|
-
return langMessages[
|
|
9338
|
+
messages(language = lang.value) {
|
|
9339
|
+
return langMessages[language];
|
|
9238
9340
|
},
|
|
9239
9341
|
lang() {
|
|
9240
9342
|
return lang.value;
|
|
9241
9343
|
},
|
|
9242
|
-
use(newLang
|
|
9344
|
+
use(newLang) {
|
|
9345
|
+
const app = nowApp.value;
|
|
9243
9346
|
lang.value = newLang;
|
|
9244
|
-
|
|
9347
|
+
app.config.globalProperties.langMessages = Locale.messages();
|
|
9245
9348
|
},
|
|
9246
|
-
add(newMessages2
|
|
9247
|
-
langMessages =
|
|
9349
|
+
add(newMessages2) {
|
|
9350
|
+
langMessages = {
|
|
9351
|
+
...langMessages,
|
|
9352
|
+
...newMessages2
|
|
9353
|
+
};
|
|
9248
9354
|
}
|
|
9249
9355
|
};
|
|
9250
9356
|
const camelize = (name) => name.substring(1).replace(/^\S/, (s) => s.toLocaleLowerCase());
|
|
@@ -9260,8 +9366,7 @@ function get(object4, path) {
|
|
|
9260
9366
|
function createI18nTranslate(name, app, newPrefix) {
|
|
9261
9367
|
const prefix = newPrefix || camelize(name) + ".";
|
|
9262
9368
|
return (path) => {
|
|
9263
|
-
|
|
9264
|
-
const messages2 = ((_a = app == null ? void 0 : app.appContext.config.globalProperties.langMessages) == null ? void 0 : _a.value) || Locale.messages();
|
|
9369
|
+
const messages2 = (app == null ? void 0 : app.appContext.config.globalProperties.langMessages) || Locale.messages();
|
|
9265
9370
|
const message = get(messages2, prefix + path) || get(messages2, path);
|
|
9266
9371
|
return message;
|
|
9267
9372
|
};
|