@xwiki/cristal-dsvuetify 0.11.0 → 0.13.0
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 +29 -0
- package/dist/components/vuetifyDesignSystemLoader.d.ts +1 -1
- package/dist/{index-BMliq0dk.js → index-UP1o6s9t.js} +4151 -4114
- package/dist/index-UP1o6s9t.js.map +1 -0
- package/dist/index.es.js +5 -4
- package/dist/index.umd.js +9 -8
- package/dist/index.umd.js.map +1 -1
- package/dist/vue/x-alert.vue.d.ts +15 -1
- package/dist/vue/x-dialog.vue.d.ts +1 -0
- package/dist/vue/x-navigation-tree.vue.d.ts +1 -3
- package/dist/x-alert-Bmt4mXHQ.js +45 -0
- package/dist/x-alert-Bmt4mXHQ.js.map +1 -0
- package/dist/x-avatar-But_Z7ic.js.map +1 -1
- package/dist/x-breadcrumb-C2iUd4Sf.js.map +1 -1
- package/dist/x-btn-DNlhiqjD.js.map +1 -1
- package/dist/x-card-CRM9KUby.js.map +1 -1
- package/dist/x-dialog-C-dMkFJk.js +49 -0
- package/dist/x-dialog-C-dMkFJk.js.map +1 -0
- package/dist/{x-file-input-8euR7G64.js → x-file-input-BsaodA0p.js} +10 -9
- package/dist/x-file-input-BsaodA0p.js.map +1 -0
- package/dist/{x-form-UiBYkCKP.js → x-form-iQFXj1PW.js} +2 -2
- package/dist/{x-form-UiBYkCKP.js.map → x-form-iQFXj1PW.js.map} +1 -1
- package/dist/x-img-BYgs_O1F.js.map +1 -1
- package/dist/x-navigation-tree-DN2Qz7Sm.js +501 -0
- package/dist/x-navigation-tree-DN2Qz7Sm.js.map +1 -0
- package/dist/x-tab-group-ngNByee3.js.map +1 -1
- package/dist/x-text-field-CTsLZhLE.js +31 -0
- package/dist/x-text-field-CTsLZhLE.js.map +1 -0
- package/langs/translation-de.json +4 -0
- package/package.json +18 -10
- package/src/components/componentsInit.ts +1 -1
- package/src/components/vuetifyDesignSystemLoader.ts +12 -9
- package/src/vue/__tests__/utils/vuetify.ts +1 -0
- package/src/vue/__tests__/x-btn.test.ts +4 -3
- package/src/vue/css/style.css +12 -4
- package/src/vue/form/x-file-input.vue +3 -4
- package/src/vue/form/x-text-field.vue +9 -4
- package/src/vue/x-alert.vue +4 -1
- package/src/vue/x-btn.vue +1 -1
- package/src/vue/x-dialog.vue +14 -1
- package/src/vue/x-navigation-tree.vue +136 -46
- package/tsconfig.json +14 -8
- package/vitest.config.ts +1 -1
- package/dist/index-BMliq0dk.js.map +0 -1
- package/dist/x-alert-D8oy1BPL.js +0 -40
- package/dist/x-alert-D8oy1BPL.js.map +0 -1
- package/dist/x-dialog-Ce8KWptm.js +0 -38
- package/dist/x-dialog-Ce8KWptm.js.map +0 -1
- package/dist/x-file-input-8euR7G64.js.map +0 -1
- package/dist/x-navigation-tree-DkVWsvlI.js +0 -449
- package/dist/x-navigation-tree-DkVWsvlI.js.map +0 -1
- package/dist/x-text-field-uL1ePP_x.js +0 -29
- package/dist/x-text-field-uL1ePP_x.js.map +0 -1
|
@@ -1,3 +1,17 @@
|
|
|
1
1
|
import { AlertProps } from '@xwiki/cristal-dsapi';
|
|
2
|
-
declare
|
|
2
|
+
declare function __VLS_template(): {
|
|
3
|
+
slots: {
|
|
4
|
+
default?(_: {}): any;
|
|
5
|
+
};
|
|
6
|
+
refs: {};
|
|
7
|
+
attrs: Partial<{}>;
|
|
8
|
+
};
|
|
9
|
+
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
10
|
+
declare const __VLS_component: import('vue').DefineComponent<AlertProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<AlertProps> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
11
|
+
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|
|
3
12
|
export default _default;
|
|
13
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
14
|
+
new (): {
|
|
15
|
+
$slots: S;
|
|
16
|
+
};
|
|
17
|
+
};
|
|
@@ -1,12 +1,10 @@
|
|
|
1
1
|
import { PageData } from '@xwiki/cristal-api';
|
|
2
|
-
import {
|
|
2
|
+
import { NavigationTreeNode } from '@xwiki/cristal-navigation-tree-api';
|
|
3
3
|
type OnClickAction = (node: NavigationTreeNode) => void;
|
|
4
4
|
declare const _default: import('vue').DefineComponent<{
|
|
5
|
-
treeSource: NavigationTreeSource;
|
|
6
5
|
clickAction?: OnClickAction;
|
|
7
6
|
currentPage?: PageData;
|
|
8
7
|
}, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<{
|
|
9
|
-
treeSource: NavigationTreeSource;
|
|
10
8
|
clickAction?: OnClickAction;
|
|
11
9
|
currentPage?: PageData;
|
|
12
10
|
}> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import { defineComponent as d, resolveComponent as n, openBlock as t, createBlock as a, withCtx as r, createElementBlock as o, Fragment as m, renderList as u, createTextVNode as _, toDisplayString as s, createCommentVNode as i, renderSlot as k } from "vue";
|
|
2
|
+
const y = { key: 0 }, b = { key: 1 }, v = /* @__PURE__ */ d({
|
|
3
|
+
__name: "x-alert",
|
|
4
|
+
props: {
|
|
5
|
+
title: {},
|
|
6
|
+
type: {},
|
|
7
|
+
description: {},
|
|
8
|
+
actions: {},
|
|
9
|
+
closable: { type: Boolean },
|
|
10
|
+
details: {}
|
|
11
|
+
},
|
|
12
|
+
setup(f) {
|
|
13
|
+
return (e, C) => {
|
|
14
|
+
const p = n("x-btn"), c = n("v-alert");
|
|
15
|
+
return t(), a(c, {
|
|
16
|
+
closable: e.closable,
|
|
17
|
+
title: e.title,
|
|
18
|
+
type: e.type,
|
|
19
|
+
text: e.description
|
|
20
|
+
}, {
|
|
21
|
+
default: r(() => [
|
|
22
|
+
(t(!0), o(m, null, u(e.actions, (l) => (t(), a(p, {
|
|
23
|
+
key: l.name,
|
|
24
|
+
size: "small",
|
|
25
|
+
variant: "text",
|
|
26
|
+
onClick: l.callback
|
|
27
|
+
}, {
|
|
28
|
+
default: r(() => [
|
|
29
|
+
_(s(l.name), 1)
|
|
30
|
+
]),
|
|
31
|
+
_: 2
|
|
32
|
+
}, 1032, ["onClick"]))), 128)),
|
|
33
|
+
e.details ? (t(), o("br", y)) : i("", !0),
|
|
34
|
+
e.details ? (t(), o("small", b, s(e.details), 1)) : i("", !0),
|
|
35
|
+
k(e.$slots, "default")
|
|
36
|
+
]),
|
|
37
|
+
_: 3
|
|
38
|
+
}, 8, ["closable", "title", "type", "text"]);
|
|
39
|
+
};
|
|
40
|
+
}
|
|
41
|
+
});
|
|
42
|
+
export {
|
|
43
|
+
v as default
|
|
44
|
+
};
|
|
45
|
+
//# sourceMappingURL=x-alert-Bmt4mXHQ.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"x-alert-Bmt4mXHQ.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"x-avatar-But_Z7ic.js","sources":["../src/vue/x-avatar.vue"],"sourcesContent":["<!--\nSee the LICENSE file distributed with this work for additional\ninformation regarding copyright ownership.\n\nThis is free software; you can redistribute it and/or modify it\nunder the terms of the GNU Lesser General Public License as\npublished by the Free Software Foundation; either version 2.1 of\nthe License, or (at your option) any later version.\n\nThis software is distributed in the hope that it will be useful,\nbut WITHOUT ANY WARRANTY; without even the implied warranty of\nMERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU\nLesser General Public License for more details.\n\nYou should have received a copy of the GNU Lesser General Public\nLicense along with this software; if not, write to the Free\nSoftware Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA\n02110-1301 USA, or see the FSF site: http://www.fsf.org.\n-->\n<template>\n <v-avatar :image=\"image\" :size=\"size\"></v-avatar>\n</template>\n<script lang=\"ts\">\nexport default {\n props: {\n image: { type: String, required: true },\n size: { type: String, required: true },\n },\n};\n</script>\n"],"names":["_sfc_main","_resolveComponent","_openBlock","_createBlock","_component_v_avatar","$props"],"mappings":";;AAuBA,MAAeA,IAAA;AAAA,EACb,OAAO;AAAA,IACL,OAAO,EAAE,MAAM,QAAQ,UAAU,GAAK;AAAA,IACtC,MAAM,EAAE,MAAM,QAAQ,UAAU,GAAK;AAAA,
|
|
1
|
+
{"version":3,"file":"x-avatar-But_Z7ic.js","sources":["../src/vue/x-avatar.vue"],"sourcesContent":["<!--\nSee the LICENSE file distributed with this work for additional\ninformation regarding copyright ownership.\n\nThis is free software; you can redistribute it and/or modify it\nunder the terms of the GNU Lesser General Public License as\npublished by the Free Software Foundation; either version 2.1 of\nthe License, or (at your option) any later version.\n\nThis software is distributed in the hope that it will be useful,\nbut WITHOUT ANY WARRANTY; without even the implied warranty of\nMERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU\nLesser General Public License for more details.\n\nYou should have received a copy of the GNU Lesser General Public\nLicense along with this software; if not, write to the Free\nSoftware Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA\n02110-1301 USA, or see the FSF site: http://www.fsf.org.\n-->\n<template>\n <v-avatar :image=\"image\" :size=\"size\"></v-avatar>\n</template>\n<script lang=\"ts\">\nexport default {\n props: {\n image: { type: String, required: true },\n size: { type: String, required: true },\n },\n};\n</script>\n"],"names":["_sfc_main","_resolveComponent","_openBlock","_createBlock","_component_v_avatar","$props"],"mappings":";;AAuBA,MAAeA,IAAA;AAAA,EACb,OAAO;AAAA,IACL,OAAO,EAAE,MAAM,QAAQ,UAAU,GAAK;AAAA,IACtC,MAAM,EAAE,MAAM,QAAQ,UAAU,GAAK;AAAA,EAAA;AAEzC;;YAREC,EAAiD,UAAA;SAAjBC,EAAI,GAAAC,EAAAC,GAAA;AAAA,IAAA,OAAAC,EAAA;AAAA;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"x-breadcrumb-C2iUd4Sf.js","sources":["../src/vue/x-breadcrumb.vue"],"sourcesContent":["<!--\nSee the LICENSE file distributed with this work for additional\ninformation regarding copyright ownership.\n\nThis is free software; you can redistribute it and/or modify it\nunder the terms of the GNU Lesser General Public License as\npublished by the Free Software Foundation; either version 2.1 of\nthe License, or (at your option) any later version.\n\nThis software is distributed in the hope that it will be useful,\nbut WITHOUT ANY WARRANTY; without even the implied warranty of\nMERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU\nLesser General Public License for more details.\n\nYou should have received a copy of the GNU Lesser General Public\nLicense along with this software; if not, write to the Free\nSoftware Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA\n02110-1301 USA, or see the FSF site: http://www.fsf.org.\n-->\n<script setup lang=\"ts\">\nimport { BreadcrumbProps } from \"@xwiki/cristal-dsapi\";\nimport { computed } from \"vue\";\n\nconst props = defineProps<BreadcrumbProps>();\n// Converts props items to the format expected by v-breadcrumbs\nconst items = computed(() => {\n return props.items.map(({ label, url }) => {\n return {\n title: label,\n href: url,\n };\n });\n});\n</script>\n\n<template>\n <v-breadcrumbs :items=\"items\"></v-breadcrumbs>\n</template>\n\n<style scoped>\n.v-breadcrumbs {\n padding: 0;\n}\n</style>\n"],"names":["props","__props","items","computed","label","url"],"mappings":";;;;;;;;AAuBA,UAAMA,IAAQC,GAERC,IAAQC,EAAS,MACdH,EAAM,MAAM,IAAI,CAAC,EAAE,OAAAI,GAAO,KAAAC,SACxB;AAAA,MACL,OAAOD;AAAA,MACP,MAAMC;AAAA,
|
|
1
|
+
{"version":3,"file":"x-breadcrumb-C2iUd4Sf.js","sources":["../src/vue/x-breadcrumb.vue"],"sourcesContent":["<!--\nSee the LICENSE file distributed with this work for additional\ninformation regarding copyright ownership.\n\nThis is free software; you can redistribute it and/or modify it\nunder the terms of the GNU Lesser General Public License as\npublished by the Free Software Foundation; either version 2.1 of\nthe License, or (at your option) any later version.\n\nThis software is distributed in the hope that it will be useful,\nbut WITHOUT ANY WARRANTY; without even the implied warranty of\nMERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU\nLesser General Public License for more details.\n\nYou should have received a copy of the GNU Lesser General Public\nLicense along with this software; if not, write to the Free\nSoftware Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA\n02110-1301 USA, or see the FSF site: http://www.fsf.org.\n-->\n<script setup lang=\"ts\">\nimport { BreadcrumbProps } from \"@xwiki/cristal-dsapi\";\nimport { computed } from \"vue\";\n\nconst props = defineProps<BreadcrumbProps>();\n// Converts props items to the format expected by v-breadcrumbs\nconst items = computed(() => {\n return props.items.map(({ label, url }) => {\n return {\n title: label,\n href: url,\n };\n });\n});\n</script>\n\n<template>\n <v-breadcrumbs :items=\"items\"></v-breadcrumbs>\n</template>\n\n<style scoped>\n.v-breadcrumbs {\n padding: 0;\n}\n</style>\n"],"names":["props","__props","items","computed","label","url"],"mappings":";;;;;;;;AAuBA,UAAMA,IAAQC,GAERC,IAAQC,EAAS,MACdH,EAAM,MAAM,IAAI,CAAC,EAAE,OAAAI,GAAO,KAAAC,SACxB;AAAA,MACL,OAAOD;AAAA,MACP,MAAMC;AAAA,IACR,EACD,CACF;;;;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"x-btn-DNlhiqjD.js","sources":["../src/vue/x-btn.vue"],"sourcesContent":["<!--\nSee the LICENSE file distributed with this work for additional\ninformation regarding copyright ownership.\n\nThis is free software; you can redistribute it and/or modify it\nunder the terms of the GNU Lesser General Public License as\npublished by the Free Software Foundation; either version 2.1 of\nthe License, or (at your option) any later version.\n\nThis software is distributed in the hope that it will be useful,\nbut WITHOUT ANY WARRANTY; without even the implied warranty of\nMERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU\nLesser General Public License for more details.\n\nYou should have received a copy of the GNU Lesser General Public\nLicense along with this software; if not, write to the Free\nSoftware Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA\n02110-1301 USA, or see the FSF site: http://www.fsf.org.\n-->\n<script lang=\"ts\" setup>\nimport { computed } from \"vue\";\nimport {
|
|
1
|
+
{"version":3,"file":"x-btn-DNlhiqjD.js","sources":["../src/vue/x-btn.vue"],"sourcesContent":["<!--\nSee the LICENSE file distributed with this work for additional\ninformation regarding copyright ownership.\n\nThis is free software; you can redistribute it and/or modify it\nunder the terms of the GNU Lesser General Public License as\npublished by the Free Software Foundation; either version 2.1 of\nthe License, or (at your option) any later version.\n\nThis software is distributed in the hope that it will be useful,\nbut WITHOUT ANY WARRANTY; without even the implied warranty of\nMERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU\nLesser General Public License for more details.\n\nYou should have received a copy of the GNU Lesser General Public\nLicense along with this software; if not, write to the Free\nSoftware Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA\n02110-1301 USA, or see the FSF site: http://www.fsf.org.\n-->\n<script lang=\"ts\" setup>\nimport { computed } from \"vue\";\nimport type { BtnProps } from \"@xwiki/cristal-dsapi\";\n\nconst { variant } = defineProps<BtnProps>();\n\n// Map the variants to corresponding vuetify colors.\nconst color = computed(() => {\n let color = undefined;\n switch (variant) {\n case \"default\":\n break;\n case \"primary\":\n color = \"primary\";\n break;\n case \"success\":\n color = \"success\";\n break;\n case \"neutral\":\n color = \"secondary\";\n break;\n case \"warning\":\n color = \"warning\";\n break;\n case \"danger\":\n color = \"error\";\n break;\n }\n return color;\n});\n\nconst vVariant = computed(() => (variant == \"text\" ? \"text\" : \"tonal\"));\n</script>\n<template>\n <v-btn :color=\"color\" :variant=\"vVariant\">\n <slot />\n </v-btn>\n</template>\n"],"names":["color","computed","__props","vVariant"],"mappings":";;;;;;;AA0BM,UAAAA,IAAQC,EAAS,MAAM;AAC3B,UAAID;AACJ,cAAQE,EAAO,SAAE;AAAA,QACf,KAAK;AACH;AAAA,QACF,KAAK;AACHF,UAAAA,IAAQ;AACR;AAAA,QACF,KAAK;AACHA,UAAAA,IAAQ;AACR;AAAA,QACF,KAAK;AACHA,UAAAA,IAAQ;AACR;AAAA,QACF,KAAK;AACHA,UAAAA,IAAQ;AACR;AAAA,QACF,KAAK;AACHA,UAAAA,IAAQ;AACR;AAAA,MAAA;AAEGA,aAAAA;AAAAA,IAAA,CACR,GAEKG,IAAWF,EAAS,MAAOC,EAAA,WAAW,SAAS,SAAS,OAAQ;;;;;;;;;;;;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"x-card-CRM9KUby.js","sources":["../src/vue/x-card.vue"],"sourcesContent":["<!--\nSee the LICENSE file distributed with this work for additional\ninformation regarding copyright ownership.\n\nThis is free software; you can redistribute it and/or modify it\nunder the terms of the GNU Lesser General Public License as\npublished by the Free Software Foundation; either version 2.1 of\nthe License, or (at your option) any later version.\n\nThis software is distributed in the hope that it will be useful,\nbut WITHOUT ANY WARRANTY; without even the implied warranty of\nMERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU\nLesser General Public License for more details.\n\nYou should have received a copy of the GNU Lesser General Public\nLicense along with this software; if not, write to the Free\nSoftware Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA\n02110-1301 USA, or see the FSF site: http://www.fsf.org.\n-->\n<template>\n <v-card :title=\"title\" variant=\"outlined\">\n <slot />\n </v-card>\n</template>\n<script lang=\"ts\">\nexport default {\n props: { title: { type: String, required: true } },\n};\n</script>\n"],"names":["_sfc_main","_resolveComponent","_openBlock","_createBlock","_component_v_card","$props","_renderSlot","_ctx"],"mappings":";;AAyBA,MAAeA,IAAA;AAAA,EACb,OAAO,EAAE,OAAO,EAAE,MAAM,QAAQ,UAAU,
|
|
1
|
+
{"version":3,"file":"x-card-CRM9KUby.js","sources":["../src/vue/x-card.vue"],"sourcesContent":["<!--\nSee the LICENSE file distributed with this work for additional\ninformation regarding copyright ownership.\n\nThis is free software; you can redistribute it and/or modify it\nunder the terms of the GNU Lesser General Public License as\npublished by the Free Software Foundation; either version 2.1 of\nthe License, or (at your option) any later version.\n\nThis software is distributed in the hope that it will be useful,\nbut WITHOUT ANY WARRANTY; without even the implied warranty of\nMERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU\nLesser General Public License for more details.\n\nYou should have received a copy of the GNU Lesser General Public\nLicense along with this software; if not, write to the Free\nSoftware Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA\n02110-1301 USA, or see the FSF site: http://www.fsf.org.\n-->\n<template>\n <v-card :title=\"title\" variant=\"outlined\">\n <slot />\n </v-card>\n</template>\n<script lang=\"ts\">\nexport default {\n props: { title: { type: String, required: true } },\n};\n</script>\n"],"names":["_sfc_main","_resolveComponent","_openBlock","_createBlock","_component_v_card","$props","_renderSlot","_ctx"],"mappings":";;AAyBA,MAAeA,IAAA;AAAA,EACb,OAAO,EAAE,OAAO,EAAE,MAAM,QAAQ,UAAU,GAAO,EAAA;AACnD;;YAPEC,EAES,QAAA;AAFc,SAAAC,EAAA,GAAkBC,EAAAC,GAAA;AAAA,IAAA,OAAAC,EAAA;AAAA,IApB3C,SAAA;AAAA,EAAA,GAAA;AAAA;MAAAC,EAAAC,EAAA,QAAA,SAAA;AAAA,IAAA,CAAA;AAAA;;;;"}
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import { defineComponent as u, useSlots as m, resolveComponent as o, openBlock as a, createBlock as n, withCtx as e, createElementVNode as v, normalizeProps as f, guardReactiveProps as h, renderSlot as r, createVNode as s, unref as g, createCommentVNode as w } from "vue";
|
|
2
|
+
import { _ as C } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
3
|
+
const k = /* @__PURE__ */ u({
|
|
4
|
+
__name: "x-dialog",
|
|
5
|
+
props: {
|
|
6
|
+
title: {},
|
|
7
|
+
width: {}
|
|
8
|
+
},
|
|
9
|
+
setup(x) {
|
|
10
|
+
const d = m();
|
|
11
|
+
return (t, N) => {
|
|
12
|
+
const c = o("v-card-text"), l = o("v-card-actions"), i = o("v-card"), _ = o("v-dialog");
|
|
13
|
+
return a(), n(_, {
|
|
14
|
+
width: t.width,
|
|
15
|
+
scrollable: ""
|
|
16
|
+
}, {
|
|
17
|
+
activator: e(({ props: p }) => [
|
|
18
|
+
v("span", f(h(p)), [
|
|
19
|
+
r(t.$slots, "activator", {}, void 0, !0)
|
|
20
|
+
], 16)
|
|
21
|
+
]),
|
|
22
|
+
default: e(() => [
|
|
23
|
+
s(i, { title: t.title }, {
|
|
24
|
+
default: e(() => [
|
|
25
|
+
s(c, null, {
|
|
26
|
+
default: e(() => [
|
|
27
|
+
r(t.$slots, "default", {}, void 0, !0)
|
|
28
|
+
]),
|
|
29
|
+
_: 3
|
|
30
|
+
}),
|
|
31
|
+
g(d).footer ? (a(), n(l, { key: 0 }, {
|
|
32
|
+
default: e(() => [
|
|
33
|
+
r(t.$slots, "footer", {}, void 0, !0)
|
|
34
|
+
]),
|
|
35
|
+
_: 3
|
|
36
|
+
})) : w("", !0)
|
|
37
|
+
]),
|
|
38
|
+
_: 3
|
|
39
|
+
}, 8, ["title"])
|
|
40
|
+
]),
|
|
41
|
+
_: 3
|
|
42
|
+
}, 8, ["width"]);
|
|
43
|
+
};
|
|
44
|
+
}
|
|
45
|
+
}), B = /* @__PURE__ */ C(k, [["__scopeId", "data-v-4640de4f"]]);
|
|
46
|
+
export {
|
|
47
|
+
B as default
|
|
48
|
+
};
|
|
49
|
+
//# sourceMappingURL=x-dialog-C-dMkFJk.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"x-dialog-C-dMkFJk.js","sources":["../src/vue/x-dialog.vue"],"sourcesContent":["<!--\nSee the LICENSE file distributed with this work for additional\ninformation regarding copyright ownership.\n\nThis is free software; you can redistribute it and/or modify it\nunder the terms of the GNU Lesser General Public License as\npublished by the Free Software Foundation; either version 2.1 of\nthe License, or (at your option) any later version.\n\nThis software is distributed in the hope that it will be useful,\nbut WITHOUT ANY WARRANTY; without even the implied warranty of\nMERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU\nLesser General Public License for more details.\n\nYou should have received a copy of the GNU Lesser General Public\nLicense along with this software; if not, write to the Free\nSoftware Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA\n02110-1301 USA, or see the FSF site: http://www.fsf.org.\n-->\n<script lang=\"ts\" setup>\nimport { useSlots } from \"vue\";\n\ndefineProps<{\n title: string;\n width: string | number | undefined;\n}>();\n\nconst slots = useSlots();\n\n// const innerIsActive = ref(props.isActive);\n</script>\n\n<template>\n <v-dialog :width=\"width\" scrollable>\n <template #activator=\"{ props }\">\n <span v-bind=\"props\">\n <slot name=\"activator\" />\n </span>\n </template>\n <template #default>\n <v-card :title=\"title\">\n <v-card-text>\n <slot name=\"default\" />\n </v-card-text>\n <v-card-actions v-if=\"slots.footer\">\n <slot name=\"footer\" />\n </v-card-actions>\n </v-card>\n </template>\n </v-dialog>\n</template>\n\n<style scoped>\n:deep(.v-card-actions) {\n padding: var(--cr-spacing-large);\n}\n</style>\n"],"names":["slots","useSlots"],"mappings":";;;;;;;;;AA2BA,UAAMA,IAAQC,EAAS;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -1,35 +1,36 @@
|
|
|
1
1
|
import { defineComponent as s, mergeModels as m, useModel as i, computed as d, openBlock as p, createBlock as f, unref as c } from "vue";
|
|
2
2
|
import { t as V } from "./translations-BNEIsfPR.js";
|
|
3
3
|
import { useI18n as b } from "vue-i18n";
|
|
4
|
-
import { b as v } from "./index-
|
|
4
|
+
import { b as v } from "./index-UP1o6s9t.js";
|
|
5
5
|
const k = /* @__PURE__ */ s({
|
|
6
6
|
__name: "x-file-input",
|
|
7
7
|
props: /* @__PURE__ */ m({
|
|
8
8
|
name: {},
|
|
9
9
|
label: {},
|
|
10
|
-
required: { type: Boolean }
|
|
10
|
+
required: { type: Boolean },
|
|
11
|
+
autofocus: { type: Boolean }
|
|
11
12
|
}, {
|
|
12
13
|
modelValue: {},
|
|
13
14
|
modelModifiers: {}
|
|
14
15
|
}),
|
|
15
16
|
emits: ["update:modelValue"],
|
|
16
17
|
setup(o) {
|
|
17
|
-
const { t } = b({
|
|
18
|
+
const { t: u } = b({
|
|
18
19
|
messages: V
|
|
19
|
-
}),
|
|
20
|
+
}), t = i(o, "modelValue"), r = o, a = d(() => {
|
|
20
21
|
const e = [];
|
|
21
|
-
return
|
|
22
|
+
return r.required && e.push((l) => l ? !0 : u("vuetify.file.input.mandatory")), e;
|
|
22
23
|
});
|
|
23
24
|
return (e, l) => (p(), f(c(v), {
|
|
24
|
-
modelValue:
|
|
25
|
-
"onUpdate:modelValue": l[0] || (l[0] = (
|
|
25
|
+
modelValue: t.value,
|
|
26
|
+
"onUpdate:modelValue": l[0] || (l[0] = (n) => t.value = n),
|
|
26
27
|
label: e.label,
|
|
27
28
|
name: e.name,
|
|
28
|
-
rules:
|
|
29
|
+
rules: a.value
|
|
29
30
|
}, null, 8, ["modelValue", "label", "name", "rules"]));
|
|
30
31
|
}
|
|
31
32
|
});
|
|
32
33
|
export {
|
|
33
34
|
k as default
|
|
34
35
|
};
|
|
35
|
-
//# sourceMappingURL=x-file-input-
|
|
36
|
+
//# sourceMappingURL=x-file-input-BsaodA0p.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"x-file-input-BsaodA0p.js","sources":["../src/vue/form/x-file-input.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport messages from \"../../translations\";\nimport { computed, defineModel } from \"vue\";\nimport { useI18n } from \"vue-i18n\";\nimport { VFileInput } from \"vuetify/components/VFileInput\";\nimport type { TextFieldModel, TextFieldProps } from \"@xwiki/cristal-dsapi\";\n\nconst { t } = useI18n({\n messages,\n});\n\nconst model = defineModel<TextFieldModel>();\nconst props = defineProps<TextFieldProps>();\n\nconst rules = computed(() => {\n const rulesList = [];\n if (props.required) {\n rulesList.push((value: unknown) => {\n if (value) {\n return true;\n } else {\n return t(\"vuetify.file.input.mandatory\");\n }\n });\n }\n return rulesList;\n});\n</script>\n\n<template>\n <v-file-input\n v-model=\"model\"\n :label=\"label\"\n :name=\"name\"\n :rules=\"rules\"\n ></v-file-input>\n</template>\n\n<style scoped></style>\n"],"names":["t","useI18n","messages","model","_useModel","props","__props","rules","computed","rulesList","value"],"mappings":";;;;;;;;;;;;;;;;;AAOM,UAAA,EAAE,GAAAA,EAAE,IAAIC,EAAQ;AAAA,MACpBC,UAAAA;AAAAA,IAAA,CACD,GAEKC,IAAQC,iBAA4B,GACpCC,IAAQC,GAERC,IAAQC,EAAS,MAAM;AAC3B,YAAMC,IAAY,CAAC;AACnB,aAAIJ,EAAM,YACEI,EAAA,KAAK,CAACC,MACVA,IACK,KAEAV,EAAE,8BAA8B,CAE1C,GAEIS;AAAA,IAAA,CACR;;;;;;;;;;"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { defineComponent as i, resolveComponent as s, openBlock as c, createBlock as f, unref as u, withModifiers as a, withCtx as e, createVNode as _, renderSlot as l } from "vue";
|
|
2
|
-
import { V as p } from "./index-
|
|
2
|
+
import { V as p } from "./index-UP1o6s9t.js";
|
|
3
3
|
const h = /* @__PURE__ */ i({
|
|
4
4
|
__name: "x-form",
|
|
5
5
|
emits: ["formSubmit"],
|
|
@@ -29,4 +29,4 @@ const h = /* @__PURE__ */ i({
|
|
|
29
29
|
export {
|
|
30
30
|
h as default
|
|
31
31
|
};
|
|
32
|
-
//# sourceMappingURL=x-form-
|
|
32
|
+
//# sourceMappingURL=x-form-iQFXj1PW.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"x-form-
|
|
1
|
+
{"version":3,"file":"x-form-iQFXj1PW.js","sources":["../src/vue/form/x-form.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport { VForm } from \"vuetify/components/VForm\";\nconst emits = defineEmits([\"formSubmit\"]);\nfunction submit() {\n emits(\"formSubmit\");\n}\n</script>\n\n<template>\n <v-form @submit.prevent=\"submit\">\n <v-container>\n <slot></slot>\n </v-container>\n </v-form>\n</template>\n\n<style scoped></style>\n"],"names":["emits","__emit","submit"],"mappings":";;;;;;AAEA,UAAMA,IAAQC;AACd,aAASC,IAAS;AAChB,MAAAF,EAAM,YAAY;AAAA,IAAA;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"x-img-BYgs_O1F.js","sources":["../src/vue/x-img.vue"],"sourcesContent":["<!--\nSee the LICENSE file distributed with this work for additional\ninformation regarding copyright ownership.\n\nThis is free software; you can redistribute it and/or modify it\nunder the terms of the GNU Lesser General Public License as\npublished by the Free Software Foundation; either version 2.1 of\nthe License, or (at your option) any later version.\n\nThis software is distributed in the hope that it will be useful,\nbut WITHOUT ANY WARRANTY; without even the implied warranty of\nMERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU\nLesser General Public License for more details.\n\nYou should have received a copy of the GNU Lesser General Public\nLicense along with this software; if not, write to the Free\nSoftware Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA\n02110-1301 USA, or see the FSF site: http://www.fsf.org.\n-->\n<template>\n <!-- TODO: add an alt attribute for accessibility -->\n <img :src=\"src\" />\n</template>\n<script lang=\"ts\">\nexport default {\n props: { src: { type: String, required: true } },\n};\n</script>\n"],"names":["_sfc_main"],"mappings":";;AAwBA,MAAeA,IAAA;AAAA,EACb,OAAO,EAAE,KAAK,EAAE,MAAM,QAAQ,UAAU,
|
|
1
|
+
{"version":3,"file":"x-img-BYgs_O1F.js","sources":["../src/vue/x-img.vue"],"sourcesContent":["<!--\nSee the LICENSE file distributed with this work for additional\ninformation regarding copyright ownership.\n\nThis is free software; you can redistribute it and/or modify it\nunder the terms of the GNU Lesser General Public License as\npublished by the Free Software Foundation; either version 2.1 of\nthe License, or (at your option) any later version.\n\nThis software is distributed in the hope that it will be useful,\nbut WITHOUT ANY WARRANTY; without even the implied warranty of\nMERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU\nLesser General Public License for more details.\n\nYou should have received a copy of the GNU Lesser General Public\nLicense along with this software; if not, write to the Free\nSoftware Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA\n02110-1301 USA, or see the FSF site: http://www.fsf.org.\n-->\n<template>\n <!-- TODO: add an alt attribute for accessibility -->\n <img :src=\"src\" />\n</template>\n<script lang=\"ts\">\nexport default {\n props: { src: { type: String, required: true } },\n};\n</script>\n"],"names":["_sfc_main"],"mappings":";;AAwBA,MAAeA,IAAA;AAAA,EACb,OAAO,EAAE,KAAK,EAAE,MAAM,QAAQ,UAAU,GAAO,EAAA;AACjD;;;;;"}
|