bmp-layout 0.0.10 → 0.0.11
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/bmp-layout.es.js +104 -4
- package/bmp-layout.umd.js +2 -2
- package/package.json +1 -1
- package/style.css +1 -1
package/bmp-layout.es.js
CHANGED
|
@@ -3583,7 +3583,7 @@ const getKey = (namespace2, key) => {
|
|
|
3583
3583
|
}
|
|
3584
3584
|
return `${namespace2}.${key}`;
|
|
3585
3585
|
};
|
|
3586
|
-
const useI18n
|
|
3586
|
+
const useI18n = (namespace2) => {
|
|
3587
3587
|
const normalFn = {
|
|
3588
3588
|
t: (key) => {
|
|
3589
3589
|
return getKey(namespace2, key);
|
|
@@ -3615,7 +3615,7 @@ const useRenderMenuTitle = () => {
|
|
|
3615
3615
|
const renderMenuTitle2 = (meta, level, mode) => {
|
|
3616
3616
|
const {
|
|
3617
3617
|
t: t2
|
|
3618
|
-
} = useI18n
|
|
3618
|
+
} = useI18n();
|
|
3619
3619
|
const {
|
|
3620
3620
|
title = "Please set title",
|
|
3621
3621
|
icon
|
|
@@ -3852,7 +3852,7 @@ const _sfc_main$s = /* @__PURE__ */ Object.assign({ name: "ProductServicePanel"
|
|
|
3852
3852
|
setup(__props, { emit: __emit }) {
|
|
3853
3853
|
const { getPrefixCls: getPrefixCls2 } = useDesign();
|
|
3854
3854
|
const prefixCls2 = getPrefixCls2("product-service-panel");
|
|
3855
|
-
const { t: t2 } = useI18n
|
|
3855
|
+
const { t: t2 } = useI18n("layout");
|
|
3856
3856
|
const props = __props;
|
|
3857
3857
|
const emit = __emit;
|
|
3858
3858
|
const router = useRouter();
|
|
@@ -9487,7 +9487,7 @@ const _sfc_main$b = /* @__PURE__ */ Object.assign({ name: "PageHeader" }, {
|
|
|
9487
9487
|
emits: ["back"],
|
|
9488
9488
|
setup(__props, { emit: __emit }) {
|
|
9489
9489
|
const route = useRoute();
|
|
9490
|
-
const { t: t2 } = useI18n
|
|
9490
|
+
const { t: t2 } = useI18n();
|
|
9491
9491
|
const { getPrefixCls: getPrefixCls2 } = useDesign();
|
|
9492
9492
|
const prefixCls2 = getPrefixCls2("page-header");
|
|
9493
9493
|
const emit = __emit;
|
|
@@ -9611,6 +9611,106 @@ function createImageViewer(options) {
|
|
|
9611
9611
|
instance = createVNode(_sfc_main$a, propsData);
|
|
9612
9612
|
render(instance, container);
|
|
9613
9613
|
}
|
|
9614
|
+
const useMessage = () => {
|
|
9615
|
+
const { t: t2 } = useI18n("layout");
|
|
9616
|
+
const scssVariables = variables$1;
|
|
9617
|
+
return {
|
|
9618
|
+
// 消息提示
|
|
9619
|
+
info(content) {
|
|
9620
|
+
ElMessage.info(content);
|
|
9621
|
+
},
|
|
9622
|
+
// 错误消息
|
|
9623
|
+
error(content) {
|
|
9624
|
+
ElMessage.error(content);
|
|
9625
|
+
},
|
|
9626
|
+
// 成功消息
|
|
9627
|
+
success(content) {
|
|
9628
|
+
ElMessage.success(content);
|
|
9629
|
+
},
|
|
9630
|
+
// 警告消息
|
|
9631
|
+
warning(content) {
|
|
9632
|
+
ElMessage.warning(content);
|
|
9633
|
+
},
|
|
9634
|
+
// 弹出提示
|
|
9635
|
+
alert(content) {
|
|
9636
|
+
ElMessageBox.alert(content, t2("common.confirmTitle"));
|
|
9637
|
+
},
|
|
9638
|
+
// 错误提示
|
|
9639
|
+
alertError(content) {
|
|
9640
|
+
ElMessageBox.alert(content, t2("common.confirmTitle"), { type: "error" });
|
|
9641
|
+
},
|
|
9642
|
+
// 成功提示
|
|
9643
|
+
alertSuccess(content) {
|
|
9644
|
+
ElMessageBox.alert(content, t2("common.confirmTitle"), { type: "success" });
|
|
9645
|
+
},
|
|
9646
|
+
// 警告提示
|
|
9647
|
+
alertWarning(content) {
|
|
9648
|
+
ElMessageBox.alert(content, t2("common.confirmTitle"), { type: "warning" });
|
|
9649
|
+
},
|
|
9650
|
+
// 通知提示
|
|
9651
|
+
notify(content) {
|
|
9652
|
+
ElNotification.info(content);
|
|
9653
|
+
},
|
|
9654
|
+
// 错误通知
|
|
9655
|
+
notifyError(content) {
|
|
9656
|
+
ElNotification.error(content);
|
|
9657
|
+
},
|
|
9658
|
+
// 成功通知
|
|
9659
|
+
notifySuccess(content) {
|
|
9660
|
+
ElNotification.success(content);
|
|
9661
|
+
},
|
|
9662
|
+
// 警告通知
|
|
9663
|
+
notifyWarning(content) {
|
|
9664
|
+
ElNotification.warning(content);
|
|
9665
|
+
},
|
|
9666
|
+
// 确认窗体
|
|
9667
|
+
confirm(content, tip, options = {}) {
|
|
9668
|
+
return ElMessageBox.confirm(content, tip ? tip : t2("common.confirmTitle"), {
|
|
9669
|
+
...options,
|
|
9670
|
+
customClass: `${options.customClass} ${scssVariables.namespace}-message-box`,
|
|
9671
|
+
confirmButtonText: options.confirmButtonText ?? t2("common.ok"),
|
|
9672
|
+
cancelButtonText: options.cancelButtonText ?? t2("common.cancel"),
|
|
9673
|
+
buttonSize: "default",
|
|
9674
|
+
center: true
|
|
9675
|
+
});
|
|
9676
|
+
},
|
|
9677
|
+
// 删除窗体
|
|
9678
|
+
delConfirm(content, tip) {
|
|
9679
|
+
return ElMessageBox.confirm(
|
|
9680
|
+
content ? content : t2("common.delMessage"),
|
|
9681
|
+
tip ? tip : t2("common.confirmTitle"),
|
|
9682
|
+
{
|
|
9683
|
+
customClass: `${scssVariables.namespace}-message-box`,
|
|
9684
|
+
confirmButtonText: t2("common.ok"),
|
|
9685
|
+
cancelButtonText: t2("common.cancel"),
|
|
9686
|
+
buttonSize: "default",
|
|
9687
|
+
center: true,
|
|
9688
|
+
type: "warning"
|
|
9689
|
+
}
|
|
9690
|
+
);
|
|
9691
|
+
},
|
|
9692
|
+
// 导出窗体
|
|
9693
|
+
exportConfirm(content, tip) {
|
|
9694
|
+
return ElMessageBox.confirm(
|
|
9695
|
+
content ? content : t2("common.exportMessage"),
|
|
9696
|
+
tip ? tip : t2("common.confirmTitle"),
|
|
9697
|
+
{
|
|
9698
|
+
confirmButtonText: t2("common.ok"),
|
|
9699
|
+
cancelButtonText: t2("common.cancel"),
|
|
9700
|
+
type: "warning"
|
|
9701
|
+
}
|
|
9702
|
+
);
|
|
9703
|
+
},
|
|
9704
|
+
// 提交内容
|
|
9705
|
+
prompt(content, tip, options = {}) {
|
|
9706
|
+
return ElMessageBox.prompt(content, tip, {
|
|
9707
|
+
confirmButtonText: t2("common.ok"),
|
|
9708
|
+
cancelButtonText: t2("common.cancel"),
|
|
9709
|
+
...options
|
|
9710
|
+
});
|
|
9711
|
+
}
|
|
9712
|
+
};
|
|
9713
|
+
};
|
|
9614
9714
|
const _hoisted_1$4 = { class: "upload-box" };
|
|
9615
9715
|
const _hoisted_2$4 = ["src"];
|
|
9616
9716
|
const _hoisted_3$4 = { key: 0 };
|