@king-one/antdv 1.0.34 → 1.0.35
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/CHANGELOG.md +6 -0
- package/dist/es/components/index.mjs +8 -8
- package/dist/es/components/pro-modal/hooks/useProModal.mjs +34 -0
- package/dist/es/components/pro-modal/index.mjs +14 -0
- package/dist/es/components/pro-modal/src/ProModal.vue.mjs +4 -0
- package/dist/es/components/pro-modal/src/ProModal.vue2.mjs +39 -0
- package/dist/es/components/{pro-dialog → pro-modal}/src/types.mjs +2 -2
- package/dist/es/components/pro-modal/style/index.mjs +2 -0
- package/dist/es/index.mjs +18 -18
- package/dist/lib/components/index.js +1 -1
- package/dist/lib/components/pro-modal/hooks/useProModal.js +1 -0
- package/dist/lib/components/pro-modal/index.js +1 -0
- package/dist/lib/components/{pro-dialog/src/ProDialog.vue.js → pro-modal/src/ProModal.vue.js} +1 -1
- package/dist/lib/components/pro-modal/src/ProModal.vue2.js +1 -0
- package/dist/lib/components/pro-modal/src/types.js +1 -0
- package/dist/lib/components/{pro-dialog → pro-modal}/style/index.js +1 -1
- package/dist/lib/index.js +1 -1
- package/dist/theme-chalk/index.css +1 -1
- package/dist/theme-chalk/pro-modal.css +1 -0
- package/dist/types/components/index.d.ts +1 -1
- package/dist/types/components/pro-modal/hooks/useProModal.d.ts +14 -0
- package/dist/types/components/pro-modal/index.d.ts +5 -0
- package/dist/types/components/{pro-dialog/src/ProDialog.vue.d.ts → pro-modal/src/ProModal.vue.d.ts} +17 -3
- package/dist/types/components/{pro-dialog → pro-modal}/src/types.d.ts +2 -2
- package/package.json +1 -1
- package/dist/es/components/pro-dialog/hooks/useProDialog.mjs +0 -34
- package/dist/es/components/pro-dialog/index.mjs +0 -13
- package/dist/es/components/pro-dialog/src/ProDialog.vue.mjs +0 -4
- package/dist/es/components/pro-dialog/src/ProDialog.vue2.mjs +0 -33
- package/dist/es/components/pro-dialog/style/index.mjs +0 -2
- package/dist/lib/components/pro-dialog/hooks/useProDialog.js +0 -1
- package/dist/lib/components/pro-dialog/index.js +0 -1
- package/dist/lib/components/pro-dialog/src/ProDialog.vue2.js +0 -1
- package/dist/lib/components/pro-dialog/src/types.js +0 -1
- package/dist/theme-chalk/pro-dialog.css +0 -1
- package/dist/types/components/pro-dialog/hooks/useProDialog.d.ts +0 -14
- package/dist/types/components/pro-dialog/index.d.ts +0 -30
package/CHANGELOG.md
CHANGED
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
import { KForm as e } from "./form/index.mjs";
|
|
2
2
|
import { KCollapseTranstion as m } from "./collapse-transtion/index.mjs";
|
|
3
|
-
import {
|
|
3
|
+
import { KProModal as f } from "./pro-modal/index.mjs";
|
|
4
4
|
import { KProTitle as K } from "./pro-title/index.mjs";
|
|
5
5
|
import { KScrollBar as l } from "./scroll-bar/index.mjs";
|
|
6
|
-
import { KScaleVirtualList as
|
|
6
|
+
import { KScaleVirtualList as i } from "./scale-virtual-list/index.mjs";
|
|
7
7
|
import { KProTag as s } from "./pro-tag/index.mjs";
|
|
8
|
-
import { KProPicker as
|
|
9
|
-
import { KProArea as
|
|
8
|
+
import { KProPicker as n } from "./pro-picker/index.mjs";
|
|
9
|
+
import { KProArea as d } from "./pro-area/index.mjs";
|
|
10
10
|
export {
|
|
11
11
|
m as KCollapseTranstion,
|
|
12
12
|
e as KForm,
|
|
13
|
-
|
|
14
|
-
f as
|
|
15
|
-
|
|
13
|
+
d as KProArea,
|
|
14
|
+
f as KProModal,
|
|
15
|
+
n as KProPicker,
|
|
16
16
|
s as KProTag,
|
|
17
17
|
K as KProTitle,
|
|
18
|
-
|
|
18
|
+
i as KScaleVirtualList,
|
|
19
19
|
l as KScrollBar
|
|
20
20
|
};
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { ref as l, getCurrentInstance as a, unref as i } from "vue";
|
|
2
|
+
function d() {
|
|
3
|
+
const e = l(!1), n = () => {
|
|
4
|
+
e.value = !0;
|
|
5
|
+
}, t = () => {
|
|
6
|
+
e.value = !1;
|
|
7
|
+
}, s = {
|
|
8
|
+
openModal: n,
|
|
9
|
+
closeModal: t
|
|
10
|
+
}, o = a();
|
|
11
|
+
return o && o.emit("init", s), { dialogVisible: e, openModal: n, closeModal: t };
|
|
12
|
+
}
|
|
13
|
+
function r() {
|
|
14
|
+
const e = l(null), n = () => {
|
|
15
|
+
const o = i(e.value);
|
|
16
|
+
return o || console.error("useModal instance is undefined!"), o;
|
|
17
|
+
};
|
|
18
|
+
return [(o) => {
|
|
19
|
+
e.value = o;
|
|
20
|
+
}, {
|
|
21
|
+
openModal: () => {
|
|
22
|
+
var o;
|
|
23
|
+
(o = n()) == null || o.openModal();
|
|
24
|
+
},
|
|
25
|
+
closeModal: () => {
|
|
26
|
+
var o;
|
|
27
|
+
return (o = n()) == null ? void 0 : o.closeModal();
|
|
28
|
+
}
|
|
29
|
+
}];
|
|
30
|
+
}
|
|
31
|
+
export {
|
|
32
|
+
d as useProModal,
|
|
33
|
+
r as usePromodalInit
|
|
34
|
+
};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { withInstall as o } from "../utils/install.mjs";
|
|
2
|
+
import "./src/ProModal.vue.mjs";
|
|
3
|
+
import "./style/index.mjs";
|
|
4
|
+
import { useProModal as e, usePromodalInit as f } from "./hooks/useProModal.mjs";
|
|
5
|
+
import { ProModalProps as P } from "./src/types.mjs";
|
|
6
|
+
import r from "./src/ProModal.vue2.mjs";
|
|
7
|
+
const i = o(r);
|
|
8
|
+
export {
|
|
9
|
+
i as KProModal,
|
|
10
|
+
P as ProModalProps,
|
|
11
|
+
i as default,
|
|
12
|
+
e as useProModal,
|
|
13
|
+
f as usePromodalInit
|
|
14
|
+
};
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { defineComponent as c, mergeModels as a, useModel as i, computed as f, openBlock as C, createBlock as M, unref as P, mergeProps as k, withCtx as v, renderSlot as w } from "vue";
|
|
2
|
+
import { Modal as B } from "ant-design-vue";
|
|
3
|
+
import { useNamespace as V } from "../../../hooks/use-namespace/index.mjs";
|
|
4
|
+
import { ProModalProps as _ } from "./types.mjs";
|
|
5
|
+
const x = /* @__PURE__ */ c({
|
|
6
|
+
name: "ProModal",
|
|
7
|
+
__name: "ProModal",
|
|
8
|
+
props: /* @__PURE__ */ a(_, {
|
|
9
|
+
modelValue: { required: !0, type: Boolean },
|
|
10
|
+
modelModifiers: {}
|
|
11
|
+
}),
|
|
12
|
+
emits: /* @__PURE__ */ a(["onConfirm", "onCancel"], ["update:modelValue"]),
|
|
13
|
+
setup(l, { emit: t }) {
|
|
14
|
+
const e = t, o = i(l, "modelValue"), { b: m } = V("pro-modal"), p = f(() => m());
|
|
15
|
+
function d() {
|
|
16
|
+
e("onConfirm");
|
|
17
|
+
}
|
|
18
|
+
function s() {
|
|
19
|
+
e("onCancel");
|
|
20
|
+
}
|
|
21
|
+
return (n, r) => (C(), M(P(B), k({
|
|
22
|
+
open: o.value,
|
|
23
|
+
"onUpdate:open": r[0] || (r[0] = (u) => o.value = u)
|
|
24
|
+
}, n.modalProps, {
|
|
25
|
+
"wrap-class-name": p.value,
|
|
26
|
+
onOk: d,
|
|
27
|
+
onCancel: s
|
|
28
|
+
}), {
|
|
29
|
+
default: v(() => [
|
|
30
|
+
w(n.$slots, "default")
|
|
31
|
+
]),
|
|
32
|
+
_: 3
|
|
33
|
+
/* FORWARDED */
|
|
34
|
+
}, 16, ["open", "wrap-class-name"]));
|
|
35
|
+
}
|
|
36
|
+
});
|
|
37
|
+
export {
|
|
38
|
+
x as default
|
|
39
|
+
};
|
package/dist/es/index.mjs
CHANGED
|
@@ -2,47 +2,47 @@ import o from "./installer.mjs";
|
|
|
2
2
|
import "./components/index.mjs";
|
|
3
3
|
import "./hooks/index.mjs";
|
|
4
4
|
import { formType as f } from "./components/form/component/form.mjs";
|
|
5
|
-
import { KForm as
|
|
5
|
+
import { KForm as x } from "./components/form/index.mjs";
|
|
6
6
|
import { collapseProps as l } from "./components/collapse-transtion/src/types.mjs";
|
|
7
7
|
import { KCollapseTranstion as i } from "./components/collapse-transtion/index.mjs";
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
8
|
+
import { useProModal as u, usePromodalInit as c } from "./components/pro-modal/hooks/useProModal.mjs";
|
|
9
|
+
import { ProModalProps as d } from "./components/pro-modal/src/types.mjs";
|
|
10
|
+
import { KProModal as A } from "./components/pro-modal/index.mjs";
|
|
11
11
|
import { TitleProps as F } from "./components/pro-title/src/types.mjs";
|
|
12
|
-
import { KProTitle as
|
|
13
|
-
import { scrollbarProps as
|
|
12
|
+
import { KProTitle as k } from "./components/pro-title/index.mjs";
|
|
13
|
+
import { scrollbarProps as S } from "./components/scroll-bar/src/types.mjs";
|
|
14
14
|
import { KScrollBar as y } from "./components/scroll-bar/index.mjs";
|
|
15
15
|
import { KScaleVirtualList as C } from "./components/scale-virtual-list/index.mjs";
|
|
16
16
|
import { proTagProps as V } from "./components/pro-tag/src/types.mjs";
|
|
17
17
|
import { KProTag as j } from "./components/pro-tag/index.mjs";
|
|
18
18
|
import { ProPickerProps as v } from "./components/pro-picker/src/types.mjs";
|
|
19
19
|
import { KProPicker as z } from "./components/pro-picker/index.mjs";
|
|
20
|
-
import { ProAreaProps as
|
|
21
|
-
import { useAreaProArea as
|
|
20
|
+
import { ProAreaProps as E } from "./components/pro-area/src/types.mjs";
|
|
21
|
+
import { useAreaProArea as H } from "./components/pro-area/hooks/use-pro-area.mjs";
|
|
22
22
|
import { KProArea as N } from "./components/pro-area/index.mjs";
|
|
23
23
|
import { useProForm as Q, useProFormInit as R } from "./hooks/useProForm.mjs";
|
|
24
24
|
export {
|
|
25
25
|
i as KCollapseTranstion,
|
|
26
|
-
|
|
26
|
+
x as KForm,
|
|
27
27
|
N as KProArea,
|
|
28
|
-
A as
|
|
28
|
+
A as KProModal,
|
|
29
29
|
z as KProPicker,
|
|
30
30
|
j as KProTag,
|
|
31
|
-
|
|
31
|
+
k as KProTitle,
|
|
32
32
|
C as KScaleVirtualList,
|
|
33
33
|
y as KScrollBar,
|
|
34
|
-
|
|
34
|
+
E as ProAreaProps,
|
|
35
|
+
d as ProModalProps,
|
|
35
36
|
v as ProPickerProps,
|
|
36
37
|
F as TitleProps,
|
|
37
38
|
l as collapseProps,
|
|
38
39
|
o as default,
|
|
39
40
|
f as formType,
|
|
40
|
-
T as proDialogProps,
|
|
41
41
|
V as proTagProps,
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
u as useProDialog,
|
|
45
|
-
g as useProDialogInit,
|
|
42
|
+
S as scrollbarProps,
|
|
43
|
+
H as useAreaProArea,
|
|
46
44
|
Q as useProForm,
|
|
47
|
-
R as useProFormInit
|
|
45
|
+
R as useProFormInit,
|
|
46
|
+
u as useProModal,
|
|
47
|
+
c as usePromodalInit
|
|
48
48
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("./form/index.js"),e=require("./collapse-transtion/index.js"),
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("./form/index.js"),e=require("./collapse-transtion/index.js"),o=require("./pro-modal/index.js"),i=require("./pro-title/index.js"),n=require("./scroll-bar/index.js"),t=require("./scale-virtual-list/index.js"),l=require("./pro-tag/index.js"),a=require("./pro-picker/index.js"),K=require("./pro-area/index.js");exports.KForm=r.KForm;exports.KCollapseTranstion=e.KCollapseTranstion;exports.KProModal=o.KProModal;exports.KProTitle=i.KProTitle;exports.KScrollBar=n.KScrollBar;exports.KScaleVirtualList=t.KScaleVirtualList;exports.KProTag=l.KProTag;exports.KProPicker=a.KProPicker;exports.KProArea=K.KProArea;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("vue");function a(){const o=t.ref(!1),n=()=>{o.value=!0},s=()=>{o.value=!1},l={openModal:n,closeModal:s},e=t.getCurrentInstance();return e&&e.emit("init",l),{dialogVisible:o,openModal:n,closeModal:s}}function i(){const o=t.ref(null),n=()=>{const e=t.unref(o.value);return e||console.error("useModal instance is undefined!"),e};return[e=>{o.value=e},{openModal:()=>{var e;(e=n())==null||e.openModal()},closeModal:()=>{var e;return(e=n())==null?void 0:e.closeModal()}}]}exports.useProModal=a;exports.usePromodalInit=i;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const r=require("../utils/install.js");require("./src/ProModal.vue.js");require("./style/index.js");const e=require("./hooks/useProModal.js"),t=require("./src/types.js"),u=require("./src/ProModal.vue2.js"),o=r.withInstall(u.default);exports.useProModal=e.useProModal;exports.usePromodalInit=e.usePromodalInit;exports.ProModalProps=t.ProModalProps;exports.KProModal=o;exports.default=o;
|
package/dist/lib/components/{pro-dialog/src/ProDialog.vue.js → pro-modal/src/ProModal.vue.js}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("./
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("./ProModal.vue2.js");exports.default=e.default;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),m=require("ant-design-vue"),p=require("../../../hooks/use-namespace/index.js"),f=require("./types.js"),M=e.defineComponent({name:"ProModal",__name:"ProModal",props:e.mergeModels(f.ProModalProps,{modelValue:{required:!0,type:Boolean},modelModifiers:{}}),emits:e.mergeModels(["onConfirm","onCancel"],["update:modelValue"]),setup(t,{emit:a}){const o=a,n=e.useModel(t,"modelValue"),{b:s}=p.useNamespace("pro-modal"),u=e.computed(()=>s());function d(){o("onConfirm")}function c(){o("onCancel")}return(r,l)=>(e.openBlock(),e.createBlock(e.unref(m.Modal),e.mergeProps({open:n.value,"onUpdate:open":l[0]||(l[0]=i=>n.value=i)},r.modalProps,{"wrap-class-name":u.value,onOk:d,onCancel:c}),{default:e.withCtx(()=>[e.renderSlot(r.$slots,"default")]),_:3},16,["open","wrap-class-name"]))}});exports.default=M;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o={modalProps:{type:Object}};exports.ProModalProps=o;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";require("../../base/style/index.js");require("@king-one/antdv/dist/theme-chalk/pro-
|
|
1
|
+
"use strict";require("../../base/style/index.js");require("@king-one/antdv/dist/theme-chalk/pro-modal.css");
|
package/dist/lib/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const o=require("./installer.js");require("./components/index.js");require("./hooks/index.js");const s=require("./components/form/component/form.js"),i=require("./components/form/index.js"),t=require("./components/collapse-transtion/src/types.js"),
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const o=require("./installer.js");require("./components/index.js");require("./hooks/index.js");const s=require("./components/form/component/form.js"),i=require("./components/form/index.js"),t=require("./components/collapse-transtion/src/types.js"),P=require("./components/collapse-transtion/index.js"),r=require("./components/pro-modal/hooks/useProModal.js"),u=require("./components/pro-modal/src/types.js"),a=require("./components/pro-modal/index.js"),l=require("./components/pro-title/src/types.js"),n=require("./components/pro-title/index.js"),c=require("./components/scroll-bar/src/types.js"),p=require("./components/scroll-bar/index.js"),d=require("./components/scale-virtual-list/index.js"),q=require("./components/pro-tag/src/types.js"),K=require("./components/pro-tag/index.js"),$=require("./components/pro-picker/src/types.js"),m=require("./components/pro-picker/index.js"),T=require("./components/pro-area/src/types.js"),y=require("./components/pro-area/hooks/use-pro-area.js"),x=require("./components/pro-area/index.js"),e=require("./hooks/useProForm.js");exports.default=o.default;exports.formType=s.formType;exports.KForm=i.KForm;exports.collapseProps=t.collapseProps;exports.KCollapseTranstion=P.KCollapseTranstion;exports.useProModal=r.useProModal;exports.usePromodalInit=r.usePromodalInit;exports.ProModalProps=u.ProModalProps;exports.KProModal=a.KProModal;exports.TitleProps=l.TitleProps;exports.KProTitle=n.KProTitle;exports.scrollbarProps=c.scrollbarProps;exports.KScrollBar=p.KScrollBar;exports.KScaleVirtualList=d.KScaleVirtualList;exports.proTagProps=q.proTagProps;exports.KProTag=K.KProTag;exports.ProPickerProps=$.ProPickerProps;exports.KProPicker=m.KProPicker;exports.ProAreaProps=T.ProAreaProps;exports.useAreaProArea=y.useAreaProArea;exports.KProArea=x.KProArea;exports.useProForm=e.useProForm;exports.useProFormInit=e.useProFormInit;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
:root{--king-color-white:#ffffff;--king-color-primary:#409eff;--king-color-success:#67c23a;--king-color-warning:#e6a23c;--king-color-danger:#f56c6c;--king-color-error:#f56c6c;--king-color-info:#909399;--king-transition-duration:0.3s}.king-button--primary{--king-button-text-color:var(--king-color-primary)}.king-button--success{--king-button-text-color:var(--king-color-success)}.king-button--warning{--king-button-text-color:var(--king-color-warning)}.king-button--danger{--king-button-text-color:var(--king-color-danger)}.king-button--error{--king-button-text-color:var(--king-color-error)}.king-button--info{--king-button-text-color:var(--king-color-info)}.king-button{color:var(--king-button-text-color)}.king-scrollbar{overflow:hidden;position:relative;z-index:auto;height:100%;width:100%}.king-scrollbar .king-scrollbar-container{width:100%;overflow:scroll;height:100%;min-height:inherit;max-height:inherit;scrollbar-width:none}.king-scrollbar .king-scrollbar-content{width:-moz-fit-content;width:fit-content}.king-scrollbar .king-scrollbar-rail{position:absolute}.king-scrollbar .king-scrollbar-rail--vertical{right:0;width:5px;top:2px;bottom:2px;right:4px}.king-scrollbar .king-scrollbar-rail--horizontal{bottom:2px;height:5px;left:2px;right:2px}.king-scrollbar .king-scrollbar-rail__scrollbar--vertical{background:rgba(0,0,0,.25);position:absolute;border-radius:5px;width:100%;cursor:pointer}.king-scrollbar .king-scrollbar-rail__scrollbar--horizontal{background:rgba(0,0,0,.25);position:absolute;border-radius:5px;height:100%;cursor:pointer}.v-vl-items{width:-moz-fit-content;width:fit-content}.king-scale-virtual-list{width:100%;height:100%}.king-scale-virtual-list .king-scale-vittual-wrapper{width:-moz-fit-content;width:fit-content;margin:0 auto}.king-pro-title{border-bottom:1px solid #ccc;position:relative;padding-left:10px}.king-pro-title::before{content:"";position:absolute;width:3px;height:16px;background:#517cfc;left:0;top:3px}.king-pro-title--unborder{border:none}.king-pro-
|
|
1
|
+
:root{--king-color-white:#ffffff;--king-color-primary:#409eff;--king-color-success:#67c23a;--king-color-warning:#e6a23c;--king-color-danger:#f56c6c;--king-color-error:#f56c6c;--king-color-info:#909399;--king-transition-duration:0.3s}.king-button--primary{--king-button-text-color:var(--king-color-primary)}.king-button--success{--king-button-text-color:var(--king-color-success)}.king-button--warning{--king-button-text-color:var(--king-color-warning)}.king-button--danger{--king-button-text-color:var(--king-color-danger)}.king-button--error{--king-button-text-color:var(--king-color-error)}.king-button--info{--king-button-text-color:var(--king-color-info)}.king-button{color:var(--king-button-text-color)}.king-scrollbar{overflow:hidden;position:relative;z-index:auto;height:100%;width:100%}.king-scrollbar .king-scrollbar-container{width:100%;overflow:scroll;height:100%;min-height:inherit;max-height:inherit;scrollbar-width:none}.king-scrollbar .king-scrollbar-content{width:-moz-fit-content;width:fit-content}.king-scrollbar .king-scrollbar-rail{position:absolute}.king-scrollbar .king-scrollbar-rail--vertical{right:0;width:5px;top:2px;bottom:2px;right:4px}.king-scrollbar .king-scrollbar-rail--horizontal{bottom:2px;height:5px;left:2px;right:2px}.king-scrollbar .king-scrollbar-rail__scrollbar--vertical{background:rgba(0,0,0,.25);position:absolute;border-radius:5px;width:100%;cursor:pointer}.king-scrollbar .king-scrollbar-rail__scrollbar--horizontal{background:rgba(0,0,0,.25);position:absolute;border-radius:5px;height:100%;cursor:pointer}.v-vl-items{width:-moz-fit-content;width:fit-content}.king-scale-virtual-list{width:100%;height:100%}.king-scale-virtual-list .king-scale-vittual-wrapper{width:-moz-fit-content;width:fit-content;margin:0 auto}.king-pro-title{border-bottom:1px solid #ccc;position:relative;padding-left:10px}.king-pro-title::before{content:"";position:absolute;width:3px;height:16px;background:#517cfc;left:0;top:3px}.king-pro-title--unborder{border:none}.king-pro-modal .ant-modal-content{padding:0}.king-pro-modal .ant-modal-header{height:56px;padding-left:32px;padding-right:24px;display:flex;justify-content:space-between;align-items:center;background:#f1f7ff;border-bottom:1px solid #e6e8ea}.king-pro-modal .ant-modal-body{padding:10px 20px;max-height:65vh;overflow:auto}.king-pro-modal .ant-modal-footer{height:56px;display:flex;padding:0 16px;justify-content:flex-end;align-items:center;border-top:1px solid #e6e8ea}.king-pro-area-select{width:100%}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.king-pro-modal .ant-modal-content{padding:0}.king-pro-modal .ant-modal-header{height:56px;padding-left:32px;padding-right:24px;display:flex;justify-content:space-between;align-items:center;background:#f1f7ff;border-bottom:1px solid #e6e8ea}.king-pro-modal .ant-modal-body{padding:10px 20px;max-height:65vh;overflow:auto}.king-pro-modal .ant-modal-footer{height:56px;display:flex;padding:0 16px;justify-content:flex-end;align-items:center;border-top:1px solid #e6e8ea}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { Ref } from 'vue';
|
|
2
|
+
export interface modalMethods {
|
|
3
|
+
openModal: () => void;
|
|
4
|
+
closeModal: () => void;
|
|
5
|
+
}
|
|
6
|
+
export declare function useProModal(): {
|
|
7
|
+
dialogVisible: Ref<boolean>;
|
|
8
|
+
openModal: () => void;
|
|
9
|
+
closeModal: () => void;
|
|
10
|
+
};
|
|
11
|
+
export declare function usePromodalInit(): [
|
|
12
|
+
(methods: modalMethods) => void,
|
|
13
|
+
modalMethods
|
|
14
|
+
];
|
package/dist/types/components/{pro-dialog/src/ProDialog.vue.d.ts → pro-modal/src/ProModal.vue.d.ts}
RENAMED
|
@@ -1,7 +1,15 @@
|
|
|
1
1
|
import { DefineComponent, PropType, ComponentOptionsMixin, PublicProps, ExtractPropTypes } from 'vue';
|
|
2
2
|
import { ModalProps } from 'ant-design-vue';
|
|
3
|
-
declare
|
|
4
|
-
|
|
3
|
+
declare function __VLS_template(): {
|
|
4
|
+
slots: {
|
|
5
|
+
default?(_: {}): any;
|
|
6
|
+
};
|
|
7
|
+
refs: {};
|
|
8
|
+
attrs: Partial<{}>;
|
|
9
|
+
};
|
|
10
|
+
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
11
|
+
declare const __VLS_component: DefineComponent<{
|
|
12
|
+
modalProps: {
|
|
5
13
|
readonly type: PropType<Omit< ModalProps, "open">>;
|
|
6
14
|
};
|
|
7
15
|
modelValue: {
|
|
@@ -13,7 +21,7 @@ declare const _default: DefineComponent<{
|
|
|
13
21
|
onConfirm: (...args: any[]) => void;
|
|
14
22
|
"update:modelValue": (modelValue: boolean) => void;
|
|
15
23
|
}, string, PublicProps, Readonly< ExtractPropTypes<{
|
|
16
|
-
|
|
24
|
+
modalProps: {
|
|
17
25
|
readonly type: PropType<Omit< ModalProps, "open">>;
|
|
18
26
|
};
|
|
19
27
|
modelValue: {
|
|
@@ -25,4 +33,10 @@ declare const _default: DefineComponent<{
|
|
|
25
33
|
onOnConfirm?: ((...args: any[]) => any) | undefined;
|
|
26
34
|
"onUpdate:modelValue"?: ((modelValue: boolean) => any) | undefined;
|
|
27
35
|
}, {}, {}>;
|
|
36
|
+
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|
|
28
37
|
export default _default;
|
|
38
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
39
|
+
new (): {
|
|
40
|
+
$slots: S;
|
|
41
|
+
};
|
|
42
|
+
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { ModalProps } from 'ant-design-vue';
|
|
2
2
|
import { PropType } from 'vue';
|
|
3
|
-
export declare const
|
|
4
|
-
readonly
|
|
3
|
+
export declare const ProModalProps: {
|
|
4
|
+
readonly modalProps: {
|
|
5
5
|
readonly type: PropType<Omit<ModalProps, "open">>;
|
|
6
6
|
};
|
|
7
7
|
};
|
package/package.json
CHANGED
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
import { ref as s, getCurrentInstance as l, unref as a } from "vue";
|
|
2
|
-
function r() {
|
|
3
|
-
const e = s(!1), n = () => {
|
|
4
|
-
e.value = !0;
|
|
5
|
-
}, t = () => {
|
|
6
|
-
e.value = !1;
|
|
7
|
-
}, i = {
|
|
8
|
-
openDialog: n,
|
|
9
|
-
closeDialog: t
|
|
10
|
-
}, o = l();
|
|
11
|
-
return o && o.emit("init", i), { dialogVisible: e, openDialog: n, closeDialog: t };
|
|
12
|
-
}
|
|
13
|
-
function u() {
|
|
14
|
-
const e = s(null), n = () => {
|
|
15
|
-
const o = a(e.value);
|
|
16
|
-
return o || console.error("useModal instance is undefined!"), o;
|
|
17
|
-
};
|
|
18
|
-
return [(o) => {
|
|
19
|
-
e.value = o;
|
|
20
|
-
}, {
|
|
21
|
-
openDialog: () => {
|
|
22
|
-
var o;
|
|
23
|
-
(o = n()) == null || o.openDialog();
|
|
24
|
-
},
|
|
25
|
-
closeDialog: () => {
|
|
26
|
-
var o;
|
|
27
|
-
return (o = n()) == null ? void 0 : o.closeDialog();
|
|
28
|
-
}
|
|
29
|
-
}];
|
|
30
|
-
}
|
|
31
|
-
export {
|
|
32
|
-
r as useProDialog,
|
|
33
|
-
u as useProDialogInit
|
|
34
|
-
};
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { withInstall as o } from "../utils/install.mjs";
|
|
2
|
-
import "./src/ProDialog.vue.mjs";
|
|
3
|
-
import "./style/index.mjs";
|
|
4
|
-
import { useProDialog as e, useProDialogInit as f } from "./hooks/useProDialog.mjs";
|
|
5
|
-
import { proDialogProps as n } from "./src/types.mjs";
|
|
6
|
-
import r from "./src/ProDialog.vue2.mjs";
|
|
7
|
-
const a = o(r);
|
|
8
|
-
export {
|
|
9
|
-
a as KProDialog,
|
|
10
|
-
n as proDialogProps,
|
|
11
|
-
e as useProDialog,
|
|
12
|
-
f as useProDialogInit
|
|
13
|
-
};
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
import { defineComponent as c, mergeModels as r, useModel as d, computed as f, openBlock as C, createBlock as g, unref as P, mergeProps as k } from "vue";
|
|
2
|
-
import { Modal as M } from "ant-design-vue";
|
|
3
|
-
import { useNamespace as v } from "../../../hooks/use-namespace/index.mjs";
|
|
4
|
-
import { proDialogProps as B } from "./types.mjs";
|
|
5
|
-
const b = /* @__PURE__ */ c({
|
|
6
|
-
name: "ProDialog",
|
|
7
|
-
__name: "ProDialog",
|
|
8
|
-
props: /* @__PURE__ */ r(B, {
|
|
9
|
-
modelValue: { required: !0, type: Boolean },
|
|
10
|
-
modelModifiers: {}
|
|
11
|
-
}),
|
|
12
|
-
emits: /* @__PURE__ */ r(["onConfirm", "onCancel"], ["update:modelValue"]),
|
|
13
|
-
setup(a, { emit: l }) {
|
|
14
|
-
const e = l, o = d(a, "modelValue"), { b: m } = v("pro-dialog"), t = f(() => m());
|
|
15
|
-
function p() {
|
|
16
|
-
e("onConfirm");
|
|
17
|
-
}
|
|
18
|
-
function i() {
|
|
19
|
-
e("onCancel");
|
|
20
|
-
}
|
|
21
|
-
return (s, n) => (C(), g(P(M), k({
|
|
22
|
-
open: o.value,
|
|
23
|
-
"onUpdate:open": n[0] || (n[0] = (u) => o.value = u)
|
|
24
|
-
}, s.dialogProps, {
|
|
25
|
-
"wrap-class-name": t.value,
|
|
26
|
-
onOk: p,
|
|
27
|
-
onCancel: i
|
|
28
|
-
}), null, 16, ["open", "wrap-class-name"]));
|
|
29
|
-
}
|
|
30
|
-
});
|
|
31
|
-
export {
|
|
32
|
-
b as default
|
|
33
|
-
};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("vue");function l(){const o=t.ref(!1),n=()=>{o.value=!0},i=()=>{o.value=!1},s={openDialog:n,closeDialog:i},e=t.getCurrentInstance();return e&&e.emit("init",s),{dialogVisible:o,openDialog:n,closeDialog:i}}function a(){const o=t.ref(null),n=()=>{const e=t.unref(o.value);return e||console.error("useModal instance is undefined!"),e};return[e=>{o.value=e},{openDialog:()=>{var e;(e=n())==null||e.openDialog()},closeDialog:()=>{var e;return(e=n())==null?void 0:e.closeDialog()}}]}exports.useProDialog=l;exports.useProDialogInit=a;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("../utils/install.js");require("./src/ProDialog.vue.js");require("./style/index.js");const e=require("./hooks/useProDialog.js"),r=require("./src/types.js"),i=require("./src/ProDialog.vue2.js"),t=o.withInstall(i.default);exports.useProDialog=e.useProDialog;exports.useProDialogInit=e.useProDialogInit;exports.proDialogProps=r.proDialogProps;exports.KProDialog=t;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),p=require("ant-design-vue"),m=require("../../../hooks/use-namespace/index.js"),g=require("./types.js"),f=e.defineComponent({name:"ProDialog",__name:"ProDialog",props:e.mergeModels(g.proDialogProps,{modelValue:{required:!0,type:Boolean},modelModifiers:{}}),emits:e.mergeModels(["onConfirm","onCancel"],["update:modelValue"]),setup(l,{emit:a}){const o=a,n=e.useModel(l,"modelValue"),{b:t}=m.useNamespace("pro-dialog"),u=e.computed(()=>t());function s(){o("onConfirm")}function i(){o("onCancel")}return(c,r)=>(e.openBlock(),e.createBlock(e.unref(p.Modal),e.mergeProps({open:n.value,"onUpdate:open":r[0]||(r[0]=d=>n.value=d)},c.dialogProps,{"wrap-class-name":u.value,onOk:s,onCancel:i}),null,16,["open","wrap-class-name"]))}});exports.default=f;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o={dialogProps:{type:Object}};exports.proDialogProps=o;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
.king-pro-dialog .ant-modal-content{padding:0}.king-pro-dialog .ant-modal-header{height:56px;padding-left:32px;padding-right:24px;display:flex;justify-content:space-between;align-items:center;background:#f1f7ff;border-bottom:1px solid #e6e8ea}.king-pro-dialog .ant-modal-body{padding:10px 20px;max-height:65vh;overflow:auto}.king-pro-dialog .ant-modal-footer{height:56px;display:flex;padding:0 16px;justify-content:flex-end;align-items:center;border-top:1px solid #e6e8ea}
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import { Ref } from 'vue';
|
|
2
|
-
export interface DialogMethods {
|
|
3
|
-
openDialog: () => void;
|
|
4
|
-
closeDialog: () => void;
|
|
5
|
-
}
|
|
6
|
-
export declare function useProDialog(): {
|
|
7
|
-
dialogVisible: Ref<boolean>;
|
|
8
|
-
openDialog: () => void;
|
|
9
|
-
closeDialog: () => void;
|
|
10
|
-
};
|
|
11
|
-
export declare function useProDialogInit(): [
|
|
12
|
-
(methods: DialogMethods) => void,
|
|
13
|
-
DialogMethods
|
|
14
|
-
];
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
import { SFCWithInstall } from '../utils/install';
|
|
2
|
-
import { DefineComponent, PropType, ComponentOptionsMixin, PublicProps, ExtractPropTypes } from 'vue';
|
|
3
|
-
import { ModalProps } from 'ant-design-vue';
|
|
4
|
-
export * from './hooks/useProDialog';
|
|
5
|
-
export * from './src/types';
|
|
6
|
-
export declare const KProDialog: SFCWithInstall<DefineComponent<{
|
|
7
|
-
dialogProps: {
|
|
8
|
-
readonly type: PropType<Omit< ModalProps, "open">>;
|
|
9
|
-
};
|
|
10
|
-
modelValue: {
|
|
11
|
-
type: PropType<boolean>;
|
|
12
|
-
required: true;
|
|
13
|
-
};
|
|
14
|
-
}, {}, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
|
|
15
|
-
onCancel: (...args: any[]) => void;
|
|
16
|
-
onConfirm: (...args: any[]) => void;
|
|
17
|
-
"update:modelValue": (modelValue: boolean) => void;
|
|
18
|
-
}, string, PublicProps, Readonly< ExtractPropTypes<{
|
|
19
|
-
dialogProps: {
|
|
20
|
-
readonly type: PropType<Omit< ModalProps, "open">>;
|
|
21
|
-
};
|
|
22
|
-
modelValue: {
|
|
23
|
-
type: PropType<boolean>;
|
|
24
|
-
required: true;
|
|
25
|
-
};
|
|
26
|
-
}>> & {
|
|
27
|
-
onOnCancel?: ((...args: any[]) => any) | undefined;
|
|
28
|
-
onOnConfirm?: ((...args: any[]) => any) | undefined;
|
|
29
|
-
"onUpdate:modelValue"?: ((modelValue: boolean) => any) | undefined;
|
|
30
|
-
}, {}, {}>>;
|