@web-utils/component 5.0.0-beta01 → 5.0.0-beta03
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/awesome-button/index.mjs +25 -31
- package/{utils/style.css → base.css} +1 -1
- package/chat/index.mjs +3 -12
- package/chunks/{EditableTree.C_IJBL5b.mjs → EditableTree.CV8b95tW.mjs} +130 -139
- package/chunks/{ElementBaseInfo.DyuFR6fE.mjs → ElementBaseInfo.lW0iwU10.mjs} +2 -3
- package/chunks/ElementDialog.DWhAJsUn.mjs +520 -0
- package/chunks/{ElementForm.ButuYDPA.mjs → ElementForm.C7yebHWH.mjs} +12 -39
- package/chunks/{ElementListeners.Dg3e_dmp.mjs → ElementListeners.B_SjC8dp.mjs} +10 -31
- package/chunks/{ElementMultiInstance.Dmi79FqA.mjs → ElementMultiInstance.Xw27Z5mm.mjs} +2 -3
- package/chunks/{ElementOtherConfig.C2AddGTp.mjs → ElementOtherConfig.DnNmAhKn.mjs} +0 -1
- package/chunks/{ElementProperties.CfV8UF7L.mjs → ElementProperties.DKr9JE_O.mjs} +3 -12
- package/chunks/{ElementTaskConfig.Bn7ycGGn.mjs → ElementTaskConfig.CPjsXlpS.mjs} +6 -10
- package/chunks/{FlowCondition.C6PdqOAW.mjs → FlowCondition.BA7GF34X.mjs} +4 -5
- package/chunks/{FlowDesigner.uJYFfKpR.mjs → FlowDesigner.DH1ypcUw.mjs} +17 -18
- package/chunks/{FormBlock.BEENc22F.mjs → FormBlock.D6kZl7sm.mjs} +8 -8
- package/chunks/FormCascader.BXL8lKww.mjs +1229 -0
- package/chunks/{FormInputTime.Bg3UIP8H.mjs → FormInputTime.DzTPiDNh.mjs} +339 -337
- package/chunks/{FormItem.H9OOvNzT.mjs → FormItem.B8iPLduv.mjs} +12 -13
- package/chunks/{FormItemGroup.D9eRy-cZ.mjs → FormItemGroup.CCGqEapT.mjs} +38 -31
- package/chunks/{FormSelect.CanodoAI.mjs → FormSelect.t0jbTL_K.mjs} +470 -467
- package/chunks/{FormSwitch.DTqdaFjv.mjs → FormSwitch.uoFQ-xp_.mjs} +53 -51
- package/chunks/{FormTemp.DiI5EfgK.mjs → FormTemp.CeHtEZQe.mjs} +11 -6
- package/chunks/{FyCurd.DMj1dMK9.mjs → FyCurd.DqJuCLNW.mjs} +22 -25
- package/chunks/{FyForm.vgR8ujEF.mjs → FyForm.CgyGhetD.mjs} +25 -21
- package/chunks/{FyFormDesign.DEWT6LsX.mjs → FyFormDesign.DIIK7mXK.mjs} +49 -128
- package/chunks/{FyUpload.B2QKfTxF.mjs → FyUpload.DoBEuYcC.mjs} +2 -2
- package/chunks/ImagePreview.DDFrZgo5.mjs +649 -0
- package/chunks/{Keyboard.ItiRy7Gb.mjs → Keyboard.DBspwbYo.mjs} +2 -2
- package/chunks/{MonacoEditor.Bd5Kui-Y.mjs → MonacoEditor.Bq9d6JSz.mjs} +65 -64
- package/chunks/{PageableTable.Bujb0NUx.mjs → PageableTable.DR-REJN5.mjs} +84 -83
- package/chunks/{SignalAndMessage.CYVzlFuL.mjs → SignalAndMessage.CL2u19it.mjs} +1 -10
- package/chunks/{TableColumn.DJYkznbJ.mjs → TableColumn.Cq9Bvevm.mjs} +34 -28
- package/chunks/{TableView.DyIdIxAg.mjs → TableView.DMWMaGLA.mjs} +26 -33
- package/chunks/ToolbarButton.AlTszc53.mjs +107 -0
- package/chunks/{UserTaskListeners.Bp-2qkHs.mjs → UserTaskListeners.Qfm8hKWP.mjs} +9 -27
- package/chunks/{VueCron.GfjodnyM.mjs → VueCron.BmPnLuu3.mjs} +163 -142
- package/chunks/{VueTreeSelect.9Ywl-I8e.mjs → VueTreeSelect.GHx4Z2lG.mjs} +48 -43
- package/chunks/button.gVyl7Y__.mjs +927 -0
- package/chunks/checkbox.AmhCpaBZ.mjs +438 -0
- package/chunks/chunk.A6TnG60p.mjs +13 -0
- package/chunks/confirmable-mixin.BZtxXY0h.mjs +273 -0
- package/chunks/constants.Dw7hXt67.mjs +4 -0
- package/chunks/{dictionary.DxZxP0ej.mjs → dictionary.BqVLM7Lf.mjs} +1 -1
- package/chunks/{event.eJ-c1Z3a.mjs → event.CmOTnori.mjs} +4 -7
- package/chunks/event.ZRs4J5TN.mjs +4 -0
- package/chunks/{focus-trap.DT4GnqQI.mjs → focus-trap.CuUc8N2C.mjs} +26 -26
- package/chunks/{form-input.D25eDRMq.mjs → form-input.DdSb45Tz.mjs} +3 -3
- package/chunks/{form-item.CgmUuw_n.mjs → form-item.fYYCXvCs.mjs} +77 -75
- package/chunks/icon.AJYLfX1m.mjs +26 -0
- package/chunks/{icon.CbS8-322.mjs → icon.niAg1zTC.mjs} +31 -39
- package/chunks/{init.DwpukyOB.mjs → init.CtUEiRbU.mjs} +6 -6
- package/chunks/{input.PejnqwSH.mjs → input.B_wW4aF-.mjs} +107 -106
- package/chunks/install.BJl2MN77.mjs +73 -0
- package/chunks/message-box.wGWcYSSd.mjs +463 -0
- package/chunks/{message.BCmee5N0.mjs → message.DnTACuzV.mjs} +76 -75
- package/chunks/{overlay.DubSnqma.mjs → overlay.Rhu_rfhx.mjs} +5 -5
- package/chunks/{radio.BotKXqJr.mjs → radio.BMkZBhl5.mjs} +45 -45
- package/chunks/{scroll.CzORc5Zk.mjs → scroll.BJIpzi2Q.mjs} +2 -2
- package/chunks/{scrollbar.CAmrlKi9.mjs → scrollbar.CvxOszy3.mjs} +4 -4
- package/chunks/{style.BmlGmjpO.mjs → style.CraPDfJA.mjs} +3 -3
- package/chunks/{tag.DPi-PLbb.mjs → tag.B6yUaGj-.mjs} +25 -25
- package/chunks/{teleport._VGEzK4d.mjs → teleport.87mkIv8m.mjs} +3 -3
- package/chunks/{tooltip.D50x7Rva.mjs → tooltip.Dzjs7LZ8.mjs} +108 -108
- package/chunks/typescript.D0a40c7B.mjs +4 -0
- package/chunks/{use-aria.BW7nWOl1.mjs → use-aria.B9uqqWAE.mjs} +2 -2
- package/chunks/{use-composition.mUaomyno.mjs → use-composition.BMPJBvYs.mjs} +4 -4
- package/chunks/{use-deprecated.BfDSbZS9.mjs → use-deprecated.vx6LTDA_.mjs} +2 -2
- package/chunks/use-empty-values.CxYKjLV9.mjs +81 -0
- package/chunks/use-form-item.DMDTkMq9.mjs +48 -0
- package/chunks/use-global-config.Dkt91Ob3.mjs +57 -0
- package/chunks/{use-id.CFO5NeoV.mjs → use-id.CyzdvfQn.mjs} +3 -3
- package/chunks/{use-empty-values.Dy_r78F6.mjs → use-locale.CBoQRFjH.mjs} +12 -87
- package/chunks/{use-size.DxrwTUwf.mjs → use-size.CoorvF12.mjs} +2 -2
- package/chunks/validator.Drv0r2Nb.mjs +5 -0
- package/chunks/{vnode.D_SioRnx.mjs → vnode.raM3wMJz.mjs} +2 -2
- package/confirm-button/index.mjs +1 -1
- package/confirmable/index.mjs +1 -1
- package/context-menu/index.mjs +39 -38
- package/data-box/style.css +1 -1
- package/data-card/style.css +1 -1
- package/data-display/style.css +1 -1
- package/data-icons/style.css +1 -1
- package/data-imgtext/style.css +1 -1
- package/data-operatext/style.css +1 -1
- package/data-panel/style.css +1 -1
- package/data-pay/style.css +1 -1
- package/data-price/style.css +1 -1
- package/data-progress/style.css +1 -1
- package/data-rotate/style.css +1 -1
- package/data-table-picker/index.mjs +2 -6
- package/data-tabs/style.css +1 -1
- package/dialog-form/index.mjs +7 -3
- package/dynamic-table/index.mjs +1 -2
- package/editable-tree/index.mjs +1 -1
- package/element-dialog/index.mjs +1 -1
- package/element-dialog/style.css +1 -1
- package/empty-view/index.mjs +18 -20
- package/error-view/index.mjs +17 -19
- package/flex-column/index.mjs +11 -9
- package/flex-item/index.mjs +22 -16
- package/flex-row/index.mjs +11 -10
- package/flow/index.mjs +1 -1
- package/flow-designer/index.mjs +1 -1
- package/form-block/index.mjs +1 -1
- package/form-cascader/index.mjs +1 -1
- package/form-checkbox/index.mjs +4 -4
- package/form-checkbox-group/index.mjs +6 -6
- package/form-date-picker/index.mjs +3 -3
- package/form-holder/index.mjs +2 -5
- package/form-input/index.mjs +4 -4
- package/form-input-cron-expression/index.mjs +4 -4
- package/form-input-email/index.mjs +10 -9
- package/form-input-id-card/index.mjs +10 -9
- package/form-input-phone-number/index.mjs +11 -10
- package/form-input-tag/index.mjs +2 -2
- package/form-input-time/index.mjs +1 -1
- package/form-item/index.mjs +1 -1
- package/form-item-group/index.mjs +1 -1
- package/form-radio-group/index.mjs +6 -6
- package/form-select/index.mjs +1 -1
- package/form-switch/index.mjs +1 -1
- package/form-table/index.mjs +2 -2
- package/form-table-plus/index.mjs +4 -4
- package/form-textarea/index.mjs +4 -4
- package/form-tree-select/index.mjs +3 -3
- package/form-tree-select-multiple/index.mjs +3 -3
- package/form-view/index.mjs +13 -8
- package/fy-array/index.mjs +1 -1
- package/fy-cascader/index.mjs +1 -1
- package/fy-checkbox/index.mjs +1 -1
- package/fy-code/index.mjs +2 -2
- package/fy-curd/index.mjs +1 -1
- package/fy-date/index.mjs +1 -1
- package/fy-dynamic/index.mjs +3 -7
- package/fy-form/index.mjs +1 -1
- package/fy-form/style.css +1 -1
- package/fy-form-design/index.mjs +1 -1
- package/fy-form-design/style.css +1 -1
- package/fy-input/index.mjs +1 -1
- package/fy-input-color/index.mjs +1 -2
- package/fy-input-icon/index.mjs +37 -32
- package/fy-input-map/index.mjs +1 -1
- package/fy-input-number/index.mjs +1 -1
- package/fy-input-table/index.mjs +1 -1
- package/fy-input-tree/index.mjs +3 -3
- package/fy-input-tree/style.css +1 -1
- package/fy-radio/index.mjs +2 -2
- package/fy-rate/index.mjs +2 -2
- package/fy-select/index.mjs +5 -5
- package/fy-slider/index.mjs +1 -1
- package/fy-switch/index.mjs +2 -2
- package/fy-time/index.mjs +1 -1
- package/fy-title/index.mjs +1 -1
- package/fy-tree/index.mjs +1 -1
- package/fy-u-editor/index.mjs +1 -1
- package/fy-upload/index.mjs +1 -1
- package/guide-steps/index.mjs +1 -1
- package/helper-function.d.ts +3 -3
- package/helper-function.mjs +36 -20
- package/iframe-window/index.mjs +30 -29
- package/image-cropper/index.mjs +144 -163
- package/image-cropper/style.css +1 -1
- package/image-preview/index.mjs +2 -187
- package/index.d.ts +1 -2
- package/index.mjs +153 -154
- package/input-number-range/index.mjs +0 -2
- package/keyboard/index.mjs +1 -1
- package/license/index.mjs +1 -1
- package/monaco-editor/index.mjs +1 -1
- package/nav-bar/index.mjs +1 -1
- package/notice/index.mjs +1 -4
- package/package.json +12 -14
- package/pageable-table/index.mjs +1 -1
- package/pageable-view/index.mjs +2 -2
- package/photo-swipe/index.mjs +1 -1
- package/picker-table-view/index.mjs +4 -8
- package/present-view/index.mjs +18 -13
- package/record-video/index.mjs +1 -1
- package/resize-observer/index.mjs +1 -1
- package/search/index.mjs +2 -2
- package/split-pane/index.mjs +1 -1
- package/stateful/index.mjs +18 -17
- package/static-pageable-table/index.mjs +1 -4
- package/sub-table/index.mjs +2 -5
- package/sub-table-plus/index.mjs +3 -6
- package/tab/index.mjs +1 -1
- package/tab-item/index.mjs +1 -1
- package/table-column/index.mjs +1 -1
- package/table-view/index.mjs +1 -1
- package/tag-render/index.mjs +28 -24
- package/toolbar/index.mjs +1 -1
- package/toolbar-button/index.mjs +2 -146
- package/vue-cron/index.mjs +1 -1
- package/vue-qr-code/index.mjs +7 -6
- package/vue-tags-input/index.mjs +1 -1
- package/vue-tree-select/index.mjs +1 -1
- package/watermark/index.mjs +13 -13
- package/web-types.json +265 -363
- package/x-input-tag/index.mjs +0 -3
- package/chunks/ElementDialog.C0IjriTW.mjs +0 -681
- package/chunks/FormCascader.CaM-oEhv.mjs +0 -1226
- package/chunks/checkbox.emIuFmnt.mjs +0 -437
- package/chunks/confirmable-mixin.BBil7dto.mjs +0 -1646
- package/chunks/event.B4iwtUNO.mjs +0 -4
- package/chunks/install.yLcn5MLL.mjs +0 -84
- package/chunks/typescript.DiWBU4nj.mjs +0 -4
- package/chunks/use-form-item.wsRjehHp.mjs +0 -47
- package/chunks/use-global-config.C9hs-O_x.mjs +0 -56
- package/chunks/validator.C4-z_t9p.mjs +0 -5
- package/login/index.mjs +0 -252
- package/login/style.css +0 -1
- /package/chunks/{FyUEditor.D_rEYfll.mjs → FyUEditor.uvZS8UgS.mjs} +0 -0
- /package/chunks/{RecordVideo.B35_dLty.mjs → RecordVideo.CKTY-gk9.mjs} +0 -0
- /package/chunks/{SplitPane.Dw96M0Yf.mjs → SplitPane.DNNid7WB.mjs} +0 -0
- /package/chunks/{Toolbar.DHuXJAoG.mjs → Toolbar.DytZ6fO0.mjs} +0 -0
- /package/chunks/{core.DJv6Qrae.mjs → core.Blrh_Fjl.mjs} +0 -0
- /package/chunks/{dataformat.Bfr4nOcA.mjs → dataformat.F7GtAoiN.mjs} +0 -0
- /package/chunks/{dic.DgDfnovD.mjs → dic.NZCGhtA7.mjs} +0 -0
- /package/chunks/{dictionary.5eKjWeAp.mjs → dictionary.DXYdZefs.mjs} +0 -0
- /package/chunks/{form-pick.Axem0gOO.mjs → form-pick.BEC7lrNH.mjs} +0 -0
- /package/chunks/{form-validate.B1KPCHqN.mjs → form-validate.JFOV_f-C.mjs} +0 -0
- /package/chunks/{packages.BGjydzjm.mjs → packages.CONbEH13.mjs} +0 -0
- /package/chunks/{permission.DgEVNWlh.mjs → permission.8WDtOmzA.mjs} +0 -0
- /package/chunks/{photo-swipe.BB0SJZg9.mjs → photo-swipe.BvBJGc5x.mjs} +0 -0
- /package/chunks/{slot.C6Ozd2e7.mjs → slot.CZCo32Cw.mjs} +0 -0
- /package/chunks/{sub-table-plus-props.B_lLth3j.mjs → sub-table-plus-props.DvS8aKT4.mjs} +0 -0
- /package/chunks/{tab-mixin.u0EZpx3j.mjs → tab-mixin.C9DSz8xu.mjs} +0 -0
- /package/chunks/{util.B3sjVZoZ.mjs → util.fjuzrmWz.mjs} +0 -0
- /package/chunks/{utilSelf.ZED4DmCU.mjs → utilSelf.Bv7FtUNb.mjs} +0 -0
- /package/chunks/{utils.Cs2fYBrT.mjs → utils.C37EhJ-u.mjs} +0 -0
- /package/chunks/{utils.DsGhtCIO.mjs → utils.C8RvIGLM.mjs} +0 -0
package/helper-function.mjs
CHANGED
|
@@ -1,24 +1,27 @@
|
|
|
1
1
|
import { configComponents as e } from "./configComponents.mjs";
|
|
2
|
-
import t from "./
|
|
2
|
+
import { t } from "./chunks/ImagePreview.DDFrZgo5.mjs";
|
|
3
3
|
import n from "./image-cropper/index.mjs";
|
|
4
|
-
import { t as r } from "./chunks/photo-swipe.
|
|
5
|
-
import i from "vue";
|
|
4
|
+
import { t as r } from "./chunks/photo-swipe.BvBJGc5x.mjs";
|
|
5
|
+
import { createApp as i, h as a, ref as o } from "vue";
|
|
6
6
|
//#region src/components/helper-function.ts
|
|
7
|
-
var
|
|
8
|
-
let
|
|
9
|
-
|
|
10
|
-
index: n,
|
|
11
|
-
ops: {
|
|
12
|
-
closeOnClickModal: !1,
|
|
13
|
-
beforeClose: null,
|
|
14
|
-
click: null,
|
|
7
|
+
var s = (e = [], n = 0, r = {}) => {
|
|
8
|
+
let o = i({ setup() {
|
|
9
|
+
return () => a(t, {
|
|
15
10
|
modal: !0,
|
|
16
|
-
...r
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
11
|
+
...r,
|
|
12
|
+
datas: e,
|
|
13
|
+
beginIndex: n,
|
|
14
|
+
visible: !0,
|
|
15
|
+
onClose() {
|
|
16
|
+
o.unmount();
|
|
17
|
+
}
|
|
18
|
+
});
|
|
19
|
+
} }), s = document.createElement("div");
|
|
20
|
+
return document.body.appendChild(s), o.mount(s), o.onUnmount(() => {
|
|
21
|
+
document.body.removeChild(s);
|
|
22
|
+
}), o.unmount;
|
|
23
|
+
}, c = (e = {}) => {
|
|
24
|
+
let t = {
|
|
22
25
|
outputSize: 1,
|
|
23
26
|
outputType: "jpeg",
|
|
24
27
|
info: !0,
|
|
@@ -35,8 +38,21 @@ var a = (e = [], n = 0, r = {}) => {
|
|
|
35
38
|
infoTrue: !1,
|
|
36
39
|
enlarge: 1,
|
|
37
40
|
...e
|
|
38
|
-
}
|
|
39
|
-
|
|
41
|
+
}, r = document.createElement("div");
|
|
42
|
+
document.body.appendChild(r);
|
|
43
|
+
let s = i({ setup() {
|
|
44
|
+
let e = o(!0);
|
|
45
|
+
return () => a(n, {
|
|
46
|
+
option: t,
|
|
47
|
+
modelValue: e,
|
|
48
|
+
"onUpdate:modelValue"(t) {
|
|
49
|
+
e.value = t, s.unmount();
|
|
50
|
+
}
|
|
51
|
+
});
|
|
52
|
+
} });
|
|
53
|
+
return s.mount(r), s.onUnmount(() => {
|
|
54
|
+
document.body.removeChild(r);
|
|
55
|
+
}), s.unmount;
|
|
40
56
|
};
|
|
41
57
|
//#endregion
|
|
42
|
-
export { e as configComponents,
|
|
58
|
+
export { e as configComponents, c as imageCropper, s as imagePreview, r as photoswipe };
|
package/iframe-window/index.mjs
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { t as e } from "../chunks/
|
|
2
|
-
import { createBlock as t, createElementVNode as n,
|
|
1
|
+
import { t as e } from "../chunks/ElementDialog.DWhAJsUn.mjs";
|
|
2
|
+
import { createBlock as t, createElementVNode as n, mergeModels as r, mergeProps as i, openBlock as a, useModel as o, withCtx as s } from "vue";
|
|
3
3
|
//#region src/components/IframeWindow.vue
|
|
4
|
-
var c = {
|
|
5
|
-
|
|
6
|
-
props: {
|
|
4
|
+
var c = ["src"], l = /* @__PURE__ */ Object.assign({ name: "IframeWindow" }, {
|
|
5
|
+
__name: "IframeWindow",
|
|
6
|
+
props: /* @__PURE__ */ r({
|
|
7
7
|
title: {
|
|
8
8
|
type: String,
|
|
9
9
|
default: "iframe窗口"
|
|
@@ -11,29 +11,30 @@ var c = {
|
|
|
11
11
|
url: {
|
|
12
12
|
type: String,
|
|
13
13
|
default: "http://192.168.0.107:31221/wallboard"
|
|
14
|
-
}
|
|
15
|
-
|
|
14
|
+
}
|
|
15
|
+
}, {
|
|
16
|
+
modelValue: { type: Boolean },
|
|
17
|
+
modelModifiers: {}
|
|
18
|
+
}),
|
|
19
|
+
emits: ["update:modelValue"],
|
|
20
|
+
setup(r) {
|
|
21
|
+
let l = o(r, "modelValue");
|
|
22
|
+
return (o, u) => (a(), t(e, i(o.$attrs, {
|
|
23
|
+
modelValue: l.value,
|
|
24
|
+
"onUpdate:modelValue": u[0] || (u[0] = (e) => l.value = e),
|
|
25
|
+
"custom-class": "iframe-window",
|
|
26
|
+
height: "60vh",
|
|
27
|
+
title: r.title,
|
|
28
|
+
"show-full-screen": ""
|
|
29
|
+
}), {
|
|
30
|
+
default: s(() => [n("iframe", {
|
|
31
|
+
src: r.url,
|
|
32
|
+
frameborder: "0",
|
|
33
|
+
class: "iframe-window-iframe"
|
|
34
|
+
}, null, 8, c)]),
|
|
35
|
+
_: 1
|
|
36
|
+
}, 16, ["modelValue", "title"]));
|
|
16
37
|
}
|
|
17
|
-
}
|
|
18
|
-
function u(e, c, u, d, f, p) {
|
|
19
|
-
let m = a("ElementDialog");
|
|
20
|
-
return i(), t(m, r({
|
|
21
|
-
"custom-class": "iframe-window",
|
|
22
|
-
embed: "",
|
|
23
|
-
height: "60vh"
|
|
24
|
-
}, e.$attrs, {
|
|
25
|
-
title: u.title,
|
|
26
|
-
"show-full-screen": "",
|
|
27
|
-
visible: u.visible
|
|
28
|
-
}, o(e.$listeners)), {
|
|
29
|
-
default: s(() => [n("iframe", {
|
|
30
|
-
src: u.url,
|
|
31
|
-
frameborder: "0",
|
|
32
|
-
class: "iframe-window-iframe"
|
|
33
|
-
}, null, 8, l)]),
|
|
34
|
-
_: 1
|
|
35
|
-
}, 16, ["title", "visible"]);
|
|
36
|
-
}
|
|
37
|
-
var d = /* @__PURE__ */ e(c, [["render", u]]);
|
|
38
|
+
});
|
|
38
39
|
//#endregion
|
|
39
|
-
export {
|
|
40
|
+
export { l as default };
|
package/image-cropper/index.mjs
CHANGED
|
@@ -1,171 +1,152 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { i as
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
1
|
+
import "../chunks/chunk.A6TnG60p.mjs";
|
|
2
|
+
import { i as e } from "../chunks/util.g-WQEec9.mjs";
|
|
3
|
+
import { t } from "../chunks/button.gVyl7Y__.mjs";
|
|
4
|
+
import { t as n } from "../chunks/ElementDialog.DWhAJsUn.mjs";
|
|
5
|
+
import { createBlock as r, createCommentVNode as i, createElementVNode as a, createTextVNode as o, createVNode as s, mergeModels as c, normalizeStyle as l, openBlock as u, ref as d, unref as f, useModel as p, useTemplateRef as m, withCtx as h } from "vue";
|
|
6
|
+
import { VueCropper as g } from "vue-cropper";
|
|
5
7
|
//#region src/components/image-cropper/ImageCropper.vue
|
|
6
|
-
var
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
},
|
|
16
|
-
methods: {
|
|
17
|
-
show() {
|
|
18
|
-
this.visible = !0;
|
|
19
|
-
},
|
|
20
|
-
changeScale(e) {
|
|
21
|
-
e = e || 1, this.$refs.cropper.changeScale(e);
|
|
22
|
-
},
|
|
23
|
-
rotateLeft() {
|
|
24
|
-
this.$refs.cropper.rotateLeft();
|
|
25
|
-
},
|
|
26
|
-
rotateRight() {
|
|
27
|
-
this.$refs.cropper.rotateRight();
|
|
28
|
-
},
|
|
29
|
-
realTime(e) {
|
|
30
|
-
this.previews = e;
|
|
8
|
+
var _ = { class: "cropper-content" }, v = { class: "cropper-box" }, y = { class: "cropper" }, b = { class: "footer-btn" }, x = { class: "show-preview" }, S = ["src"], C = /* @__PURE__ */ Object.assign({ name: "ImageCropper" }, {
|
|
9
|
+
__name: "ImageCropper",
|
|
10
|
+
props: /* @__PURE__ */ c({
|
|
11
|
+
appendToBody: Boolean,
|
|
12
|
+
option: Object
|
|
13
|
+
}, {
|
|
14
|
+
modelValue: {
|
|
15
|
+
type: Boolean,
|
|
16
|
+
default: !1
|
|
31
17
|
},
|
|
32
|
-
|
|
33
|
-
|
|
18
|
+
modelModifiers: {}
|
|
19
|
+
}),
|
|
20
|
+
emits: ["update:modelValue"],
|
|
21
|
+
setup(c) {
|
|
22
|
+
let C = p(c, "modelValue"), w = c, T = m("cropper"), E = m("dialog"), D = d({}), O = (e) => {
|
|
23
|
+
e = e || 1, T.value.changeScale(e);
|
|
24
|
+
}, k = () => {
|
|
25
|
+
T.value.rotateLeft();
|
|
26
|
+
}, A = () => {
|
|
27
|
+
T.value.rotateRight();
|
|
28
|
+
}, j = (e) => {
|
|
29
|
+
D.value = e;
|
|
30
|
+
}, M = () => {
|
|
31
|
+
E.value.close(), T.value.getCropData((t) => {
|
|
34
32
|
var n, r;
|
|
35
|
-
let i =
|
|
36
|
-
|
|
33
|
+
let i = t;
|
|
34
|
+
w.option.type === "file" && (i = e(t, `${(/* @__PURE__ */ new Date()).getTime()}.${w.option.outputType}`)), (n = (r = w.option).callback) == null || n.call(r, i);
|
|
37
35
|
});
|
|
38
|
-
},
|
|
39
|
-
cancel(e) {
|
|
36
|
+
}, N = (e) => {
|
|
40
37
|
var t, n;
|
|
41
|
-
e == null || e(),
|
|
42
|
-
}
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
"modal-append-to-body": e.$AVUE.modalAppendToBody,
|
|
56
|
-
"append-to-body": e.$AVUE.appendToBody,
|
|
57
|
-
width: "1000px"
|
|
58
|
-
}, {
|
|
59
|
-
footer: u(() => [o(S, {
|
|
60
|
-
size: "small",
|
|
61
|
-
type: "primary",
|
|
62
|
-
onClick: b.submit
|
|
63
|
-
}, {
|
|
64
|
-
default: u(() => [...t[4] || (t[4] = [a(" 确 定 ", -1)])]),
|
|
65
|
-
_: 1
|
|
66
|
-
}, 8, ["onClick"]), o(S, {
|
|
67
|
-
size: "small",
|
|
68
|
-
onClick: t[2] || (t[2] = (e) => b.cancel())
|
|
38
|
+
e == null || e(), (t = (n = w.option).cancel) == null || t.call(n), typeof w.option.beforeClose == "function" && w.option.beforeClose();
|
|
39
|
+
};
|
|
40
|
+
return (e, d) => (u(), r(n, {
|
|
41
|
+
ref_key: "dialog",
|
|
42
|
+
ref: E,
|
|
43
|
+
modelValue: C.value,
|
|
44
|
+
"onUpdate:modelValue": d[3] || (d[3] = (e) => C.value = e),
|
|
45
|
+
class: "avue-cropper",
|
|
46
|
+
"before-close": N,
|
|
47
|
+
title: "图片剪裁",
|
|
48
|
+
"close-on-press-escape": !1,
|
|
49
|
+
"close-on-click-modal": !1,
|
|
50
|
+
"append-to-body": c.appendToBody,
|
|
51
|
+
width: "1000px"
|
|
69
52
|
}, {
|
|
70
|
-
|
|
53
|
+
footer: h(() => [s(f(t), {
|
|
54
|
+
type: "primary",
|
|
55
|
+
onClick: M
|
|
56
|
+
}, {
|
|
57
|
+
default: h(() => [...d[4] || (d[4] = [o(" 确 定 ", -1)])]),
|
|
58
|
+
_: 1
|
|
59
|
+
}), s(f(t), { onClick: d[2] || (d[2] = (e) => N()) }, {
|
|
60
|
+
default: h(() => [...d[5] || (d[5] = [o(" 取 消 ", -1)])]),
|
|
61
|
+
_: 1
|
|
62
|
+
})]),
|
|
63
|
+
default: h(() => [a("div", _, [
|
|
64
|
+
a("div", v, [
|
|
65
|
+
a("div", y, [s(f(g), {
|
|
66
|
+
ref_key: "cropper",
|
|
67
|
+
ref: T,
|
|
68
|
+
img: c.option.img,
|
|
69
|
+
"output-size": c.option.outputSize,
|
|
70
|
+
"output-type": c.option.outputType,
|
|
71
|
+
info: c.option.info,
|
|
72
|
+
"can-scale": c.option.canScale,
|
|
73
|
+
"auto-crop": c.option.autoCrop,
|
|
74
|
+
"auto-crop-width": c.option.autoCropWidth,
|
|
75
|
+
"auto-crop-height": c.option.autoCropHeight,
|
|
76
|
+
fixed: c.option.fixed,
|
|
77
|
+
"fixed-number": c.option.fixedNumber,
|
|
78
|
+
full: c.option.full,
|
|
79
|
+
"fixed-box": c.option.fixedBox,
|
|
80
|
+
"can-move": c.option.canMove,
|
|
81
|
+
"can-move-box": c.option.canMoveBox,
|
|
82
|
+
original: c.option.original,
|
|
83
|
+
"center-box": c.option.centerBox,
|
|
84
|
+
height: c.option.height,
|
|
85
|
+
"info-true": c.option.infoTrue,
|
|
86
|
+
"max-img-size": c.option.maxImgSize,
|
|
87
|
+
enlarge: c.option.enlarge,
|
|
88
|
+
mode: c.option.mode,
|
|
89
|
+
onRealTime: j
|
|
90
|
+
}, null, 8, [
|
|
91
|
+
"img",
|
|
92
|
+
"output-size",
|
|
93
|
+
"output-type",
|
|
94
|
+
"info",
|
|
95
|
+
"can-scale",
|
|
96
|
+
"auto-crop",
|
|
97
|
+
"auto-crop-width",
|
|
98
|
+
"auto-crop-height",
|
|
99
|
+
"fixed",
|
|
100
|
+
"fixed-number",
|
|
101
|
+
"full",
|
|
102
|
+
"fixed-box",
|
|
103
|
+
"can-move",
|
|
104
|
+
"can-move-box",
|
|
105
|
+
"original",
|
|
106
|
+
"center-box",
|
|
107
|
+
"height",
|
|
108
|
+
"info-true",
|
|
109
|
+
"max-img-size",
|
|
110
|
+
"enlarge",
|
|
111
|
+
"mode"
|
|
112
|
+
])]),
|
|
113
|
+
i("底部操作工具按钮"),
|
|
114
|
+
a("div", b, [
|
|
115
|
+
s(f(t), {
|
|
116
|
+
type: "primary",
|
|
117
|
+
icon: "el-icon-zoom-in",
|
|
118
|
+
onClick: d[0] || (d[0] = (e) => O(1))
|
|
119
|
+
}),
|
|
120
|
+
s(f(t), {
|
|
121
|
+
type: "primary",
|
|
122
|
+
icon: "el-icon-zoom-out",
|
|
123
|
+
onClick: d[1] || (d[1] = (e) => O(-1))
|
|
124
|
+
}),
|
|
125
|
+
s(f(t), {
|
|
126
|
+
type: "primary",
|
|
127
|
+
icon: "el-icon-refresh-left",
|
|
128
|
+
onClick: k
|
|
129
|
+
}),
|
|
130
|
+
s(f(t), {
|
|
131
|
+
type: "primary",
|
|
132
|
+
icon: "el-icon-refresh-right",
|
|
133
|
+
onClick: A
|
|
134
|
+
})
|
|
135
|
+
])
|
|
136
|
+
]),
|
|
137
|
+
i("预览效果图"),
|
|
138
|
+
a("div", x, [a("div", {
|
|
139
|
+
style: l(D.value.div),
|
|
140
|
+
class: "preview"
|
|
141
|
+
}, [a("img", {
|
|
142
|
+
src: D.value.url,
|
|
143
|
+
style: l(D.value.img),
|
|
144
|
+
alt: ""
|
|
145
|
+
}, null, 12, S)], 4)])
|
|
146
|
+
])]),
|
|
71
147
|
_: 1
|
|
72
|
-
}
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
i("div", h, [o(x, {
|
|
76
|
-
ref: "cropper",
|
|
77
|
-
img: y.option.img,
|
|
78
|
-
"output-size": y.option.outputSize,
|
|
79
|
-
"output-type": y.option.outputType,
|
|
80
|
-
info: y.option.info,
|
|
81
|
-
"can-scale": y.option.canScale,
|
|
82
|
-
"auto-crop": y.option.autoCrop,
|
|
83
|
-
"auto-crop-width": y.option.autoCropWidth,
|
|
84
|
-
"auto-crop-height": y.option.autoCropHeight,
|
|
85
|
-
fixed: y.option.fixed,
|
|
86
|
-
"fixed-number": y.option.fixedNumber,
|
|
87
|
-
full: y.option.full,
|
|
88
|
-
"fixed-box": y.option.fixedBox,
|
|
89
|
-
"can-move": y.option.canMove,
|
|
90
|
-
"can-move-box": y.option.canMoveBox,
|
|
91
|
-
original: y.option.original,
|
|
92
|
-
"center-box": y.option.centerBox,
|
|
93
|
-
height: y.option.height,
|
|
94
|
-
"info-true": y.option.infoTrue,
|
|
95
|
-
"max-img-size": y.option.maxImgSize,
|
|
96
|
-
enlarge: y.option.enlarge,
|
|
97
|
-
mode: y.option.mode,
|
|
98
|
-
onRealTime: b.realTime
|
|
99
|
-
}, null, 8, [
|
|
100
|
-
"img",
|
|
101
|
-
"output-size",
|
|
102
|
-
"output-type",
|
|
103
|
-
"info",
|
|
104
|
-
"can-scale",
|
|
105
|
-
"auto-crop",
|
|
106
|
-
"auto-crop-width",
|
|
107
|
-
"auto-crop-height",
|
|
108
|
-
"fixed",
|
|
109
|
-
"fixed-number",
|
|
110
|
-
"full",
|
|
111
|
-
"fixed-box",
|
|
112
|
-
"can-move",
|
|
113
|
-
"can-move-box",
|
|
114
|
-
"original",
|
|
115
|
-
"center-box",
|
|
116
|
-
"height",
|
|
117
|
-
"info-true",
|
|
118
|
-
"max-img-size",
|
|
119
|
-
"enlarge",
|
|
120
|
-
"mode",
|
|
121
|
-
"onRealTime"
|
|
122
|
-
])]),
|
|
123
|
-
r("底部操作工具按钮"),
|
|
124
|
-
i("div", g, [
|
|
125
|
-
o(S, {
|
|
126
|
-
size: "mini",
|
|
127
|
-
type: "primary",
|
|
128
|
-
icon: "el-icon-zoom-in",
|
|
129
|
-
onClick: t[0] || (t[0] = (e) => b.changeScale(1))
|
|
130
|
-
}),
|
|
131
|
-
o(S, {
|
|
132
|
-
size: "mini",
|
|
133
|
-
type: "primary",
|
|
134
|
-
icon: "el-icon-zoom-out",
|
|
135
|
-
onClick: t[1] || (t[1] = (e) => b.changeScale(-1))
|
|
136
|
-
}),
|
|
137
|
-
o(S, {
|
|
138
|
-
size: "mini",
|
|
139
|
-
type: "primary",
|
|
140
|
-
icon: "el-icon-refresh-left",
|
|
141
|
-
onClick: b.rotateLeft
|
|
142
|
-
}, null, 8, ["onClick"]),
|
|
143
|
-
o(S, {
|
|
144
|
-
size: "mini",
|
|
145
|
-
type: "primary",
|
|
146
|
-
icon: "el-icon-refresh-right",
|
|
147
|
-
onClick: b.rotateRight
|
|
148
|
-
}, null, 8, ["onClick"])
|
|
149
|
-
])
|
|
150
|
-
]),
|
|
151
|
-
r("预览效果图"),
|
|
152
|
-
i("div", _, [i("div", {
|
|
153
|
-
style: s(y.previews.div),
|
|
154
|
-
class: "preview"
|
|
155
|
-
}, [i("img", {
|
|
156
|
-
src: y.previews.url,
|
|
157
|
-
style: s(y.previews.img),
|
|
158
|
-
alt: ""
|
|
159
|
-
}, null, 12, v)], 4)])
|
|
160
|
-
])]),
|
|
161
|
-
_: 1
|
|
162
|
-
}, 8, [
|
|
163
|
-
"visible",
|
|
164
|
-
"before-close",
|
|
165
|
-
"modal-append-to-body",
|
|
166
|
-
"append-to-body"
|
|
167
|
-
]);
|
|
168
|
-
}
|
|
169
|
-
var b = /* @__PURE__ */ e(f, [["render", y]]);
|
|
148
|
+
}, 8, ["modelValue", "append-to-body"]));
|
|
149
|
+
}
|
|
150
|
+
});
|
|
170
151
|
//#endregion
|
|
171
|
-
export {
|
|
152
|
+
export { C as default };
|
package/image-cropper/style.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
.avue-cropper .cropper-content{justify-content:flex-end;display:flex}.avue-cropper .cropper-content .cropper-box{flex:1;width:100%}.avue-cropper .cropper-content .cropper-box .cropper{width:auto;height:300px}.avue-cropper .cropper-content .show-preview{flex:1;justify-content:center;display:flex}.avue-cropper .cropper-content .show-preview .preview{background:#ccc;border:1px solid #67c23a;overflow:hidden}.avue-cropper .cropper-content .footer-btn{justify-content:center;margin-top:30px;padding-right:10px;display:flex}
|
|
1
|
+
.vue-cropper[data-v-a742df44]{box-sizing:border-box;-webkit-user-select:none;user-select:none;touch-action:none;text-align:left;direction:ltr;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQAQMAAAAlPW0iAAAAA3NCSVQICAjb4U/gAAAABlBMVEXMzMz////TjRV2AAAACXBIWXMAAArrAAAK6wGCiw1aAAAAHHRFWHRTb2Z0d2FyZQBBZG9iZSBGaXJld29ya3MgQ1M26LyyjAAAABFJREFUCJlj+M/AgBVhF/0PAH6/D/HkDxOGAAAAAElFTkSuQmCC);width:100%;height:100%;position:relative}.cropper-box[data-v-a742df44],.cropper-box-canvas[data-v-a742df44],.cropper-drag-box[data-v-a742df44],.cropper-crop-box[data-v-a742df44],.cropper-face[data-v-a742df44]{-webkit-user-select:none;user-select:none;position:absolute;top:0;bottom:0;left:0;right:0}.cropper-box-canvas img[data-v-a742df44]{text-align:left;-webkit-user-select:none;user-select:none;max-width:none;max-height:none;position:relative;transform:none}.cropper-box[data-v-a742df44]{overflow:hidden}.cropper-move[data-v-a742df44]{cursor:move}.cropper-crop[data-v-a742df44]{cursor:crosshair}.cropper-modal[data-v-a742df44]{background:#00000080}.cropper-view-box[data-v-a742df44]{-webkit-user-select:none;user-select:none;outline:1px solid #3399ffbf;width:100%;height:100%;display:block;overflow:hidden}.cropper-view-box img[data-v-a742df44]{-webkit-user-select:none;user-select:none;text-align:left;max-width:none;max-height:none}.cropper-face[data-v-a742df44]{opacity:.1;background-color:#fff;top:0;left:0}.crop-info[data-v-a742df44]{text-align:center;color:#fff;background-color:#000c;min-width:65px;font-size:12px;line-height:20px;position:absolute;left:0}.crop-line[data-v-a742df44]{opacity:.1;width:100%;height:100%;display:block;position:absolute}.line-w[data-v-a742df44]{cursor:n-resize;height:5px;top:-3px;left:0}.line-a[data-v-a742df44]{cursor:w-resize;width:5px;top:0;left:-3px}.line-s[data-v-a742df44]{cursor:s-resize;height:5px;bottom:-3px;left:0}.line-d[data-v-a742df44]{cursor:e-resize;width:5px;top:0;right:-3px}.crop-point[data-v-a742df44]{opacity:.75;background-color:#39f;border-radius:100%;width:8px;height:8px;position:absolute}.point1[data-v-a742df44]{cursor:nw-resize;top:-4px;left:-4px}.point2[data-v-a742df44]{cursor:n-resize;margin-left:-3px;top:-5px;left:50%}.point3[data-v-a742df44]{cursor:ne-resize;top:-4px;right:-4px}.point4[data-v-a742df44]{cursor:w-resize;margin-top:-3px;top:50%;left:-4px}.point5[data-v-a742df44]{cursor:e-resize;margin-top:-3px;top:50%;right:-4px}.point6[data-v-a742df44]{cursor:sw-resize;bottom:-5px;left:-4px}.point7[data-v-a742df44]{cursor:s-resize;margin-left:-3px;bottom:-5px;left:50%}.point8[data-v-a742df44]{cursor:se-resize;bottom:-5px;right:-4px}@media screen and (max-width:500px){.crop-point[data-v-a742df44]{opacity:.45;background-color:#39f;border-radius:100%;width:20px;height:20px;position:absolute}.point1[data-v-a742df44]{top:-10px;left:-10px}.point2[data-v-a742df44],.point4[data-v-a742df44],.point5[data-v-a742df44],.point7[data-v-a742df44]{display:none}.point3[data-v-a742df44]{top:-10px;right:-10px}.point4[data-v-a742df44]{top:0;left:0}.point6[data-v-a742df44]{bottom:-10px;left:-10px}.point8[data-v-a742df44]{bottom:-10px;right:-10px}}.avue-cropper .cropper-content{justify-content:flex-end;display:flex}.avue-cropper .cropper-content .cropper-box{flex:1;width:100%}.avue-cropper .cropper-content .cropper-box .cropper{width:auto;height:300px}.avue-cropper .cropper-content .show-preview{flex:1;justify-content:center;display:flex}.avue-cropper .cropper-content .show-preview .preview{background:#ccc;border:1px solid #67c23a;overflow:hidden}.avue-cropper .cropper-content .footer-btn{justify-content:center;margin-top:30px;padding-right:10px;display:flex}
|
package/image-preview/index.mjs
CHANGED
|
@@ -1,187 +1,2 @@
|
|
|
1
|
-
import { t as e } from "../chunks/
|
|
2
|
-
|
|
3
|
-
import { Fragment as n, createBlock as r, createCommentVNode as i, createElementBlock as a, createElementVNode as o, createVNode as s, normalizeStyle as c, openBlock as l, renderList as u, resolveComponent as d, resolveDynamicComponent as f, toDisplayString as p, withCtx as m, withModifiers as h } from "vue";
|
|
4
|
-
import { setPx as g } from "@web-utils/core";
|
|
5
|
-
//#region src/components/image-preview/ImagePreview.vue
|
|
6
|
-
var _ = {
|
|
7
|
-
name: "ImagePreview",
|
|
8
|
-
data() {
|
|
9
|
-
return {
|
|
10
|
-
left: 0,
|
|
11
|
-
top: 0,
|
|
12
|
-
scale: 1,
|
|
13
|
-
datas: [],
|
|
14
|
-
rotate: 0,
|
|
15
|
-
isShow: !1,
|
|
16
|
-
index: 0,
|
|
17
|
-
ops: {}
|
|
18
|
-
};
|
|
19
|
-
},
|
|
20
|
-
computed: {
|
|
21
|
-
styleBoxName() {
|
|
22
|
-
return {
|
|
23
|
-
marginLeft: g(this.left),
|
|
24
|
-
marginTop: g(this.top)
|
|
25
|
-
};
|
|
26
|
-
},
|
|
27
|
-
styleName() {
|
|
28
|
-
return {
|
|
29
|
-
transform: `scale(${this.scale}) rotate(${this.rotate}deg)`,
|
|
30
|
-
maxWidth: "100%",
|
|
31
|
-
maxHeight: "100%"
|
|
32
|
-
};
|
|
33
|
-
},
|
|
34
|
-
isRrrow() {
|
|
35
|
-
return this.datas.length > 1;
|
|
36
|
-
}
|
|
37
|
-
},
|
|
38
|
-
methods: {
|
|
39
|
-
getName(e) {
|
|
40
|
-
return e.substring(e.lastIndexOf("/") + 1);
|
|
41
|
-
},
|
|
42
|
-
handlePrint() {
|
|
43
|
-
this.$Print(`#avue-image-preview__${this.index}`);
|
|
44
|
-
},
|
|
45
|
-
handlePrev() {
|
|
46
|
-
this.$refs.carousel.prev(), this.index = this.$refs.carousel.activeIndex, this.stopItem();
|
|
47
|
-
},
|
|
48
|
-
handleNext() {
|
|
49
|
-
this.$refs.carousel.next(), this.index = this.$refs.carousel.activeIndex, this.stopItem();
|
|
50
|
-
},
|
|
51
|
-
stopItem() {
|
|
52
|
-
this.left = 0, this.top = 0, this.$refs.item.forEach((e) => {
|
|
53
|
-
var t;
|
|
54
|
-
(t = e.pause) == null || t.call(e);
|
|
55
|
-
});
|
|
56
|
-
},
|
|
57
|
-
isMediaType(e) {
|
|
58
|
-
return t(e.url, e.type);
|
|
59
|
-
},
|
|
60
|
-
subScale() {
|
|
61
|
-
this.scale !== .2 && (this.scale = parseFloat((this.scale - .2).toFixed(2)));
|
|
62
|
-
},
|
|
63
|
-
addScale() {
|
|
64
|
-
this.scale = parseFloat((this.scale + .2).toFixed(2));
|
|
65
|
-
},
|
|
66
|
-
handleChange() {
|
|
67
|
-
this.scale = 1, this.rotate = 0;
|
|
68
|
-
},
|
|
69
|
-
move(e) {
|
|
70
|
-
let t = e.clientX, n = e.clientY;
|
|
71
|
-
document.onmousemove = (e) => {
|
|
72
|
-
let r = e.clientX - t, i = e.clientY - n;
|
|
73
|
-
t = e.clientX, n = e.clientY, this.left += r * 2, this.top += i * 2;
|
|
74
|
-
}, document.onmouseup = () => {
|
|
75
|
-
document.onmousemove = null, document.onmouseup = null;
|
|
76
|
-
};
|
|
77
|
-
},
|
|
78
|
-
handleClick(e, t, n = !1) {
|
|
79
|
-
typeof this.ops.click == "function" ? this.ops.click(e, t) : n && window.open(e.url);
|
|
80
|
-
},
|
|
81
|
-
close() {
|
|
82
|
-
this.isShow = !1, typeof this.ops.beforeClose == "function" && this.ops.beforeClose(this.datas, this.index), this.$destroy(), this.$el.remove();
|
|
83
|
-
}
|
|
84
|
-
}
|
|
85
|
-
}, v = {
|
|
86
|
-
key: 0,
|
|
87
|
-
class: "avue-image-preview"
|
|
88
|
-
}, y = {
|
|
89
|
-
ref: "box",
|
|
90
|
-
class: "avue-image-preview__box"
|
|
91
|
-
}, b = ["id", "onClick"], x = { class: "el-image-viewer__btn el-image-viewer__actions" }, S = { class: "el-image-viewer__actions__inner" };
|
|
92
|
-
function C(e, t, g, _, C, w) {
|
|
93
|
-
let T = d("ElCarouselItem"), E = d("ElCarousel");
|
|
94
|
-
return C.isShow ? (l(), a("div", v, [
|
|
95
|
-
C.ops.modal ? (l(), a("div", {
|
|
96
|
-
key: 0,
|
|
97
|
-
class: "avue-image-preview__mask",
|
|
98
|
-
onClick: t[0] || (t[0] = (...e) => w.close && w.close(...e))
|
|
99
|
-
})) : i("v-if", !0),
|
|
100
|
-
o("span", {
|
|
101
|
-
class: "el-image-viewer__btn el-image-viewer__close",
|
|
102
|
-
onClick: t[1] || (t[1] = (...e) => w.close && w.close(...e))
|
|
103
|
-
}, [...t[10] || (t[10] = [o("i", { class: "el-icon-circle-close" }, null, -1)])]),
|
|
104
|
-
w.isRrrow ? (l(), a("span", {
|
|
105
|
-
key: 1,
|
|
106
|
-
class: "el-image-viewer__btn el-image-viewer__prev",
|
|
107
|
-
onClick: t[2] || (t[2] = (e) => w.handlePrev())
|
|
108
|
-
}, [...t[11] || (t[11] = [o("i", { class: "el-icon-arrow-left" }, null, -1)])])) : i("v-if", !0),
|
|
109
|
-
w.isRrrow ? (l(), a("span", {
|
|
110
|
-
key: 2,
|
|
111
|
-
class: "el-image-viewer__btn el-image-viewer__next",
|
|
112
|
-
onClick: t[3] || (t[3] = (e) => w.handleNext())
|
|
113
|
-
}, [...t[12] || (t[12] = [o("i", { class: "el-icon-arrow-right" }, null, -1)])])) : i("v-if", !0),
|
|
114
|
-
o("div", y, [s(E, {
|
|
115
|
-
ref: "carousel",
|
|
116
|
-
"show-indicators": !1,
|
|
117
|
-
"initial-index": C.index,
|
|
118
|
-
"initial-swipe": C.index,
|
|
119
|
-
interval: 0,
|
|
120
|
-
arrow: "never",
|
|
121
|
-
"indicator-position": "none",
|
|
122
|
-
onChange: w.handleChange
|
|
123
|
-
}, {
|
|
124
|
-
default: m(() => [(l(!0), a(n, null, u(C.datas, (e, n) => (l(), r(T, {
|
|
125
|
-
key: n,
|
|
126
|
-
onClick: t[4] || (t[4] = h((e) => C.ops.closeOnClickModal ? w.close() : "", ["self"]))
|
|
127
|
-
}, {
|
|
128
|
-
default: m(() => [w.isMediaType(e) ? (l(), r(f(w.isMediaType(e)), {
|
|
129
|
-
key: 0,
|
|
130
|
-
id: `avue-image-preview__${n}`,
|
|
131
|
-
ref_for: !0,
|
|
132
|
-
ref: "item",
|
|
133
|
-
src: e.url,
|
|
134
|
-
style: c([w.styleName, w.styleBoxName]),
|
|
135
|
-
controls: "controls",
|
|
136
|
-
ondragstart: "return false",
|
|
137
|
-
onClick: (t) => w.handleClick(e, n),
|
|
138
|
-
onMousedown: w.move
|
|
139
|
-
}, null, 40, [
|
|
140
|
-
"id",
|
|
141
|
-
"src",
|
|
142
|
-
"style",
|
|
143
|
-
"onClick",
|
|
144
|
-
"onMousedown"
|
|
145
|
-
])) : (l(), a("div", {
|
|
146
|
-
key: 1,
|
|
147
|
-
id: `avue-image-preview__${n}`,
|
|
148
|
-
class: "avue-image-preview__file",
|
|
149
|
-
onClick: (t) => w.handleClick(e, n, !0)
|
|
150
|
-
}, [o("span", null, [t[13] || (t[13] = o("i", { class: "el-icon-document" }, null, -1)), o("p", null, p(e.name || w.getName(e.url)), 1)])], 8, b))]),
|
|
151
|
-
_: 2
|
|
152
|
-
}, 1024))), 128))]),
|
|
153
|
-
_: 1
|
|
154
|
-
}, 8, [
|
|
155
|
-
"initial-index",
|
|
156
|
-
"initial-swipe",
|
|
157
|
-
"onChange"
|
|
158
|
-
])], 512),
|
|
159
|
-
o("div", x, [o("div", S, [
|
|
160
|
-
o("i", {
|
|
161
|
-
class: "el-icon-zoom-out",
|
|
162
|
-
onClick: t[5] || (t[5] = (...e) => w.subScale && w.subScale(...e))
|
|
163
|
-
}),
|
|
164
|
-
o("i", {
|
|
165
|
-
class: "el-icon-zoom-in",
|
|
166
|
-
onClick: t[6] || (t[6] = (...e) => w.addScale && w.addScale(...e))
|
|
167
|
-
}),
|
|
168
|
-
t[14] || (t[14] = o("i", { class: "el-image-viewer__actions__divider" }, null, -1)),
|
|
169
|
-
o("i", {
|
|
170
|
-
class: "el-icon-printer",
|
|
171
|
-
onClick: t[7] || (t[7] = (...e) => w.handlePrint && w.handlePrint(...e))
|
|
172
|
-
}),
|
|
173
|
-
t[15] || (t[15] = o("i", { class: "el-image-viewer__actions__divider" }, null, -1)),
|
|
174
|
-
o("i", {
|
|
175
|
-
class: "el-icon-refresh-left",
|
|
176
|
-
onClick: t[8] || (t[8] = (e) => C.rotate -= 90)
|
|
177
|
-
}),
|
|
178
|
-
o("i", {
|
|
179
|
-
class: "el-icon-refresh-right",
|
|
180
|
-
onClick: t[9] || (t[9] = (e) => C.rotate += 90)
|
|
181
|
-
})
|
|
182
|
-
])])
|
|
183
|
-
])) : i("v-if", !0);
|
|
184
|
-
}
|
|
185
|
-
var w = /* @__PURE__ */ e(_, [["render", C]]);
|
|
186
|
-
//#endregion
|
|
187
|
-
export { w as default };
|
|
1
|
+
import { t as e } from "../chunks/ImagePreview.DDFrZgo5.mjs";
|
|
2
|
+
export { e as default };
|
package/index.d.ts
CHANGED
|
@@ -119,7 +119,6 @@ import { default as JSXComponent } from '../../../../../src/components/jsx-compo
|
|
|
119
119
|
import { default as Keyboard } from '../../../../../src/components/keyboard/Keyboard.vue';
|
|
120
120
|
import { default as License } from '../../../../../src/components/license/License.vue';
|
|
121
121
|
import { default as LoadingView } from '../../../../../src/components/LoadingView.vue';
|
|
122
|
-
import { default as Login } from '../../../../../src/components/login/Login.vue';
|
|
123
122
|
import { default as MonacoEditor } from '../../../../../src/components/monaco-editor/MonacoEditor.vue';
|
|
124
123
|
import { default as NameAvatar } from '../../../../../src/components/NameAvatar.vue';
|
|
125
124
|
import { default as NavBar } from '../../../../../src/components/NavBar.vue';
|
|
@@ -168,7 +167,7 @@ import { default as VueTreeSelect } from '../../../../../src/components/tree-sel
|
|
|
168
167
|
import { default as VueVideoPlayer } from '../../../../../src/components/vue-video-player/VueVideoPlayer.vue';
|
|
169
168
|
import { default as Watermark } from '../../../../../src/components/Watermark.vue';
|
|
170
169
|
import { default as XInputTag } from '../../../../../src/components/XInputTag.vue';
|
|
171
|
-
export { AddressInput, Affix, AsideMenu, Avatar, AwesomeButton, CapsuleTab, Card, Carousel, Chat, ChunkFileUploader, CodeMirrorEditor, Comment, Confirmable, ConfirmButton, ContextMenu, CountUp, CustomScrollbar, DataBox, DataCard, DataCardText, DataDisplay, DataIcons, DataImgtext, DataOperatext, DataPanel, DataPay, DataPrice, DataProgress, DataRotate, DataTablePicker, DataTabs, DialogForm, DynamicTable, EasyPopup, ECharts, EditableProgress, EditableTree, ElementDialog, Ellipsis, EmptyView, ErrorView, FlexColumn, FlexItem, FlexRow, FlexScroller, Flow, FlowDesigner, FlowNode, FlowViewer, FormBlock, FormButton, FormCard, FormCascader, FormCheckbox, FormCheckboxGroup, FormDatePicker, FormHolder, FormInput, FormInputCronExpression, FormInputEmail, FormInputIdCard, FormInputPhoneNumber, FormInputTag, FormInputTime, FormItem, FormItemConfigProvider, FormItemGroup, FormRadioGroup, FormSelect, FormSwitch, FormTable, FormTablePlus, FormTextarea, FormTreeSelect, FormTreeSelectMultiple, FormView, FyArray, FyArticle, FyCascader, FyCheckbox, FyCode, FyCurd, FyDate, FyDraggable, FyDynamic, FyEmpty, FyForm, FyFormDesign, FyInput, FyInputColor, FyInputIcon, FyInputMap, FyInputNumber, FyInputTable, FyInputTree, FyProgress, FyRadio, FyRate, FySelect, FySlider, FySwitch, FyTabs, FyTime, FyTitle, FyTree, FyUEditor, FyUpload, GuideSteps, HighlightJS, IconCard, IconTemp, IframeWindow, ImageCropper, ImagePreview, ImageViewer, InputNumberRange, JSXComponent, Keyboard, License, LoadingView,
|
|
170
|
+
export { AddressInput, Affix, AsideMenu, Avatar, AwesomeButton, CapsuleTab, Card, Carousel, Chat, ChunkFileUploader, CodeMirrorEditor, Comment, Confirmable, ConfirmButton, ContextMenu, CountUp, CustomScrollbar, DataBox, DataCard, DataCardText, DataDisplay, DataIcons, DataImgtext, DataOperatext, DataPanel, DataPay, DataPrice, DataProgress, DataRotate, DataTablePicker, DataTabs, DialogForm, DynamicTable, EasyPopup, ECharts, EditableProgress, EditableTree, ElementDialog, Ellipsis, EmptyView, ErrorView, FlexColumn, FlexItem, FlexRow, FlexScroller, Flow, FlowDesigner, FlowNode, FlowViewer, FormBlock, FormButton, FormCard, FormCascader, FormCheckbox, FormCheckboxGroup, FormDatePicker, FormHolder, FormInput, FormInputCronExpression, FormInputEmail, FormInputIdCard, FormInputPhoneNumber, FormInputTag, FormInputTime, FormItem, FormItemConfigProvider, FormItemGroup, FormRadioGroup, FormSelect, FormSwitch, FormTable, FormTablePlus, FormTextarea, FormTreeSelect, FormTreeSelectMultiple, FormView, FyArray, FyArticle, FyCascader, FyCheckbox, FyCode, FyCurd, FyDate, FyDraggable, FyDynamic, FyEmpty, FyForm, FyFormDesign, FyInput, FyInputColor, FyInputIcon, FyInputMap, FyInputNumber, FyInputTable, FyInputTree, FyProgress, FyRadio, FyRate, FySelect, FySlider, FySwitch, FyTabs, FyTime, FyTitle, FyTree, FyUEditor, FyUpload, GuideSteps, HighlightJS, IconCard, IconTemp, IframeWindow, ImageCropper, ImagePreview, ImageViewer, InputNumberRange, JSXComponent, Keyboard, License, LoadingView, MonacoEditor, NameAvatar, NavBar, Notice, NotImplement, Page, PageableTable, PageableView, PageHeader, PageIndex, PageIndexTop, PageSkeleton, PageSkeletonNew, PhotoSwipe, PickerTableView, PresentView, Queue, RecordVideo, ResizeObserver, Search, Sign, SignPanel, Skeleton, SkeletonPanel, SplitPane, Stateful, StaticPageableTable, SubTable, SubTablePlus, Swiper, Tab, TabItem, TableColumn, TableView, TabsView, TagRender, TextEllipsis, Toolbar, ToolbarButton, Verify, VueCron, VueQrCode, VueQuillEditor, VueTagsInput, VueTreeSelect, VueVideoPlayer, Watermark, XInputTag };
|
|
172
171
|
export declare const componentNames: string[];
|
|
173
172
|
export * from './helper-function';
|
|
174
173
|
export default function (app: App): void;
|