@xwiki/cristal-dsvuetify 0.8.0 → 0.9.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.
Files changed (76) hide show
  1. package/CHANGELOG.md +12 -0
  2. package/dist/index-CkW0K4NP.js +20803 -0
  3. package/dist/index-CkW0K4NP.js.map +1 -0
  4. package/dist/index.es.js +8 -20955
  5. package/dist/index.es.js.map +1 -1
  6. package/dist/index.umd.js +13 -25
  7. package/dist/index.umd.js.map +1 -1
  8. package/dist/translations-CFfpgNrx.js +10 -0
  9. package/dist/translations-CFfpgNrx.js.map +1 -0
  10. package/dist/translations.d.ts +2 -0
  11. package/dist/vue/form/x-file-input.vue.d.ts +32 -0
  12. package/dist/vue/form/x-form.vue.d.ts +15 -0
  13. package/dist/vue/form/x-text-field.vue.d.ts +13 -0
  14. package/dist/vue/x-alert.vue.d.ts +3 -2
  15. package/dist/vue/x-btn.vue.d.ts +4 -2
  16. package/dist/vue/x-dialog.vue.d.ts +7 -5
  17. package/dist/vue/x-menu-item.vue.d.ts +6 -4
  18. package/dist/vue/x-menu.vue.d.ts +7 -5
  19. package/dist/vue/x-tab-group.vue.d.ts +16 -0
  20. package/dist/vue/x-tab-panel.vue.d.ts +22 -0
  21. package/dist/vue/x-tab.vue.d.ts +22 -0
  22. package/dist/x-alert-Cm6mzRpR.js.map +1 -1
  23. package/dist/x-avatar-But_Z7ic.js.map +1 -1
  24. package/dist/x-breadcrumb-DBZVExfF.js +21 -0
  25. package/dist/x-breadcrumb-DBZVExfF.js.map +1 -0
  26. package/dist/x-btn-DsACLwMY.js.map +1 -1
  27. package/dist/x-card-CRM9KUby.js.map +1 -1
  28. package/dist/x-divider-7cmRuxTV.js.map +1 -1
  29. package/dist/x-file-input-COSLRt5u.js +35 -0
  30. package/dist/x-file-input-COSLRt5u.js.map +1 -0
  31. package/dist/x-form-B5rljfJA.js +32 -0
  32. package/dist/x-form-B5rljfJA.js.map +1 -0
  33. package/dist/x-img-BYgs_O1F.js.map +1 -1
  34. package/dist/{x-load-CDyapJH_.js → x-load-DipiCmNY.js} +1 -1
  35. package/dist/x-load-DipiCmNY.js.map +1 -0
  36. package/dist/x-search-C4yZLrSp.js.map +1 -1
  37. package/dist/x-tab-OWsxC4de.js +22 -0
  38. package/dist/x-tab-OWsxC4de.js.map +1 -0
  39. package/dist/x-tab-group-DTR-H8Sn.js +49 -0
  40. package/dist/x-tab-group-DTR-H8Sn.js.map +1 -0
  41. package/dist/x-tab-panel-YsSPuuLL.js +22 -0
  42. package/dist/x-tab-panel-YsSPuuLL.js.map +1 -0
  43. package/dist/x-text-field-Ccv2SH00.js +29 -0
  44. package/dist/x-text-field-Ccv2SH00.js.map +1 -0
  45. package/langs/translation-en.json +4 -0
  46. package/package.json +8 -9
  47. package/src/components/componentsInit.ts +4 -9
  48. package/src/components/vuetifyDesignSystemLoader.ts +30 -9
  49. package/src/index.ts +4 -9
  50. package/src/translations.ts +26 -0
  51. package/src/vue/css/style.css +28 -10
  52. package/src/vue/form/x-file-input.vue +40 -0
  53. package/src/vue/form/x-form.vue +17 -0
  54. package/src/vue/form/x-text-field.vue +32 -0
  55. package/src/vue/x-alert.vue +17 -23
  56. package/src/vue/x-avatar.vue +17 -23
  57. package/src/vue/x-breadcrumb.vue +28 -24
  58. package/src/vue/x-btn.vue +17 -23
  59. package/src/vue/x-card.vue +17 -23
  60. package/src/vue/x-dialog.vue +17 -23
  61. package/src/vue/x-divider.vue +17 -23
  62. package/src/vue/x-img.vue +17 -23
  63. package/src/vue/x-load.vue +17 -23
  64. package/src/vue/x-menu-item.vue +17 -23
  65. package/src/vue/x-menu.vue +17 -23
  66. package/src/vue/x-search.vue +17 -23
  67. package/src/vue/x-tab-group.vue +44 -0
  68. package/src/vue/x-tab-panel.vue +30 -0
  69. package/src/vue/x-tab.vue +30 -0
  70. package/src/vue.d.ts +4 -9
  71. package/tsconfig.json +1 -0
  72. package/vite.config.ts +4 -9
  73. package/dist/style.css +0 -5
  74. package/dist/x-breadcrumb-DKUFjeVQ.js +0 -17
  75. package/dist/x-breadcrumb-DKUFjeVQ.js.map +0 -1
  76. package/dist/x-load-CDyapJH_.js.map +0 -1
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@xwiki/cristal-dsvuetify",
3
- "version": "0.8.0",
4
- "license": "AGPL-3.0",
3
+ "version": "0.9.0",
4
+ "license": "LGPL 2.1",
5
5
  "author": "XWiki Org Community <contact@xwiki.org>",
6
6
  "homepage": "https://cristal.xwiki.org/",
7
7
  "repository": {
@@ -23,21 +23,20 @@
23
23
  "main": "./dist/index.es.js",
24
24
  "dependencies": {
25
25
  "inversify": "6.0.2",
26
- "vue": "3.4.27",
26
+ "vue": "3.4.29",
27
27
  "vue-i18n": "9.13.1",
28
- "vuetify": "3.6.7",
29
- "@xwiki/cristal-api": "0.8.0",
30
- "@xwiki/cristal-dsapi": "0.8.0"
28
+ "vuetify": "3.6.10",
29
+ "@xwiki/cristal-api": "0.9.0",
30
+ "@xwiki/cristal-dsapi": "0.9.0"
31
31
  },
32
32
  "devDependencies": {
33
33
  "rimraf": "5.0.7",
34
- "vite": "5.2.11",
35
- "vue-tsc": "2.0.19"
34
+ "vue-tsc": "2.0.21"
36
35
  },
37
36
  "scripts": {
38
37
  "build": "pnpm compile",
39
38
  "clean": "rimraf dist",
40
- "compile": "vue-tsc --project tsconfig.json --noEmit && vite build",
39
+ "compile": "vue-tsc --project tsconfig.json && vite build",
41
40
  "lint": "eslint \"./src/**/*.{ts,tsx,vue}\" --max-warnings=0",
42
41
  "test": "echo 'no test'"
43
42
  },
@@ -1,9 +1,9 @@
1
- /**
1
+ /*
2
2
  * See the LICENSE file distributed with this work for additional
3
3
  * information regarding copyright ownership.
4
4
  *
5
5
  * This is free software; you can redistribute it and/or modify it
6
- * under the terms of the GNU Affero General Public License as
6
+ * under the terms of the GNU Lesser General Public License as
7
7
  * published by the Free Software Foundation; either version 2.1 of
8
8
  * the License, or (at your option) any later version.
9
9
  *
@@ -12,16 +12,11 @@
12
12
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13
13
  * Lesser General Public License for more details.
14
14
  *
15
- * You should have received a copy of the GNU Affero General Public
15
+ * You should have received a copy of the GNU Lesser General Public
16
16
  * License along with this software; if not, write to the Free
17
17
  * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
18
18
  * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
19
- *
20
- * This file is part of the Cristal Wiki software prototype
21
- * @copyright Copyright (c) 2023 XWiki SAS
22
- * @license http://opensource.org/licenses/AGPL-3.0 AGPL-3.0
23
- *
24
- **/
19
+ */
25
20
 
26
21
  import type { DesignSystemLoader } from "@xwiki/cristal-api";
27
22
  import type { Container } from "inversify";
@@ -1,9 +1,9 @@
1
- /**
1
+ /*
2
2
  * See the LICENSE file distributed with this work for additional
3
3
  * information regarding copyright ownership.
4
4
  *
5
5
  * This is free software; you can redistribute it and/or modify it
6
- * under the terms of the GNU Affero General Public License as
6
+ * under the terms of the GNU Lesser General Public License as
7
7
  * published by the Free Software Foundation; either version 2.1 of
8
8
  * the License, or (at your option) any later version.
9
9
  *
@@ -12,16 +12,11 @@
12
12
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13
13
  * Lesser General Public License for more details.
14
14
  *
15
- * You should have received a copy of the GNU Affero General Public
15
+ * You should have received a copy of the GNU Lesser General Public
16
16
  * License along with this software; if not, write to the Free
17
17
  * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
18
18
  * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
19
- *
20
- * This file is part of the Cristal Wiki software prototype
21
- * @copyright Copyright (c) 2023 XWiki SAS
22
- * @license http://opensource.org/licenses/AGPL-3.0 AGPL-3.0
23
- *
24
- **/
19
+ */
25
20
 
26
21
  import type { App } from "vue";
27
22
  import * as components from "vuetify/components";
@@ -94,5 +89,31 @@ export class VuetifyDesignSystemLoader implements DesignSystemLoader {
94
89
  () => import("../vue/x-breadcrumb.vue"),
95
90
  );
96
91
  registerAsyncComponent(app, "XSearch", () => import("../vue/x-search.vue"));
92
+ registerAsyncComponent(app, "XTab", () => import("../vue/x-tab.vue"));
93
+ registerAsyncComponent(
94
+ app,
95
+ "XTabGroup",
96
+ () => import("../vue/x-tab-group.vue"),
97
+ );
98
+ registerAsyncComponent(
99
+ app,
100
+ "XTabPanel",
101
+ () => import("../vue/x-tab-panel.vue"),
102
+ );
103
+ registerAsyncComponent(
104
+ app,
105
+ "XForm",
106
+ () => import("../vue/form/x-form.vue"),
107
+ );
108
+ registerAsyncComponent(
109
+ app,
110
+ "XTextField",
111
+ () => import("../vue/form/x-text-field.vue"),
112
+ );
113
+ registerAsyncComponent(
114
+ app,
115
+ "XFileInput",
116
+ () => import("../vue/form/x-file-input.vue"),
117
+ );
97
118
  }
98
119
  }
package/src/index.ts CHANGED
@@ -1,9 +1,9 @@
1
- /**
1
+ /*
2
2
  * See the LICENSE file distributed with this work for additional
3
3
  * information regarding copyright ownership.
4
4
  *
5
5
  * This is free software; you can redistribute it and/or modify it
6
- * under the terms of the GNU Affero General Public License as
6
+ * under the terms of the GNU Lesser General Public License as
7
7
  * published by the Free Software Foundation; either version 2.1 of
8
8
  * the License, or (at your option) any later version.
9
9
  *
@@ -12,16 +12,11 @@
12
12
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13
13
  * Lesser General Public License for more details.
14
14
  *
15
- * You should have received a copy of the GNU Affero General Public
15
+ * You should have received a copy of the GNU Lesser General Public
16
16
  * License along with this software; if not, write to the Free
17
17
  * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
18
18
  * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
19
- *
20
- * This file is part of the Cristal Wiki software prototype
21
- * @copyright Copyright (c) 2023 XWiki SAS
22
- * @license http://opensource.org/licenses/AGPL-3.0 AGPL-3.0
23
- *
24
- **/
19
+ */
25
20
 
26
21
  import ComponentInit from "./components/componentsInit.js";
27
22
 
@@ -0,0 +1,26 @@
1
+ /*
2
+ * See the LICENSE file distributed with this work for additional
3
+ * information regarding copyright ownership.
4
+ *
5
+ * This is free software; you can redistribute it and/or modify it
6
+ * under the terms of the GNU Lesser General Public License as
7
+ * published by the Free Software Foundation; either version 2.1 of
8
+ * the License, or (at your option) any later version.
9
+ *
10
+ * This software is distributed in the hope that it will be useful,
11
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
12
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13
+ * Lesser General Public License for more details.
14
+ *
15
+ * You should have received a copy of the GNU Lesser General Public
16
+ * License along with this software; if not, write to the Free
17
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
18
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
19
+ */
20
+
21
+ import en from "../langs/translation-en.json";
22
+
23
+ const translations: Record<string, Record<string, string>> = {
24
+ en,
25
+ };
26
+ export default translations;
@@ -1,9 +1,28 @@
1
+ /*
2
+ * See the LICENSE file distributed with this work for additional
3
+ * information regarding copyright ownership.
4
+ *
5
+ * This is free software; you can redistribute it and/or modify it
6
+ * under the terms of the GNU Lesser General Public License as
7
+ * published by the Free Software Foundation; either version 2.1 of
8
+ * the License, or (at your option) any later version.
9
+ *
10
+ * This software is distributed in the hope that it will be useful,
11
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
12
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13
+ * Lesser General Public License for more details.
14
+ *
15
+ * You should have received a copy of the GNU Lesser General Public
16
+ * License along with this software; if not, write to the Free
17
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
18
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
19
+ */
1
20
  .load-spinner {
2
- background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 200 200"><circle fill="%23B9B9B9" stroke="%23B9B9B9" stroke-width="6" r="15" cx="40" cy="100"><animate attributeName="opacity" calcMode="spline" dur="2" values="1;0;1;" keySplines=".5 0 .5 1;.5 0 .5 1" repeatCount="indefinite" begin="-.4"></animate></circle><circle fill="%23B9B9B9" stroke="%23B9B9B9" stroke-width="6" r="15" cx="100" cy="100"><animate attributeName="opacity" calcMode="spline" dur="2" values="1;0;1;" keySplines=".5 0 .5 1;.5 0 .5 1" repeatCount="indefinite" begin="-.2"></animate></circle><circle fill="%23B9B9B9" stroke="%23B9B9B9" stroke-width="6" r="15" cx="160" cy="100"><animate attributeName="opacity" calcMode="spline" dur="2" values="1;0;1;" keySplines=".5 0 .5 1;.5 0 .5 1" repeatCount="indefinite" begin="0"></animate></circle></svg>') ;
3
- background-size: cover;
4
- width: 64px;
5
- height: 64px;
6
- }
21
+ background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 200 200"><circle fill="%23B9B9B9" stroke="%23B9B9B9" stroke-width="6" r="15" cx="40" cy="100"><animate attributeName="opacity" calcMode="spline" dur="2" values="1;0;1;" keySplines=".5 0 .5 1;.5 0 .5 1" repeatCount="indefinite" begin="-.4"></animate></circle><circle fill="%23B9B9B9" stroke="%23B9B9B9" stroke-width="6" r="15" cx="100" cy="100"><animate attributeName="opacity" calcMode="spline" dur="2" values="1;0;1;" keySplines=".5 0 .5 1;.5 0 .5 1" repeatCount="indefinite" begin="-.2"></animate></circle><circle fill="%23B9B9B9" stroke="%23B9B9B9" stroke-width="6" r="15" cx="160" cy="100"><animate attributeName="opacity" calcMode="spline" dur="2" values="1;0;1;" keySplines=".5 0 .5 1;.5 0 .5 1" repeatCount="indefinite" begin="0"></animate></circle></svg>');
22
+ background-size: cover;
23
+ width: 64px;
24
+ height: 64px;
25
+ }
7
26
 
8
27
  :root {
9
28
  --cr-sizes-max-page-width: 960px; /*This value controls the width of the main content. It should be 100% for spanning text along the whole width or an arbitraty value*/
@@ -11,7 +30,6 @@
11
30
  --cr-sizes-left-sidebar-min-width: 250px; /*The minimum width of the sidebar*/
12
31
  --cr-sizes-collapsed-sidebar-width: 32px; /*The width of the bar that gets shown containing the menu button to reopen the standard left sidebar*/
13
32
  --cr-base-font-size: 16px;
14
-
15
33
 
16
34
 
17
35
  /*
@@ -21,7 +39,7 @@
21
39
  /* Fonts */
22
40
  --cr-font-mono: SFMono-Regular, Consolas, 'Liberation Mono', Menlo, monospace;
23
41
  --cr-font-sans: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif,
24
- 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol';
42
+ 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol';
25
43
  --cr-font-serif: Georgia, 'Times New Roman', serif;
26
44
 
27
45
  /* Font sizes */
@@ -62,9 +80,9 @@
62
80
  --cr-focus-ring: var(--cr-focus-ring-style) var(--cr-focus-ring-width) var(--cr-focus-ring-color);
63
81
  --cr-focus-ring-offset: 1px;
64
82
 
65
- /*
66
- * Color Primitives
67
- */
83
+ /*
84
+ * Color Primitives
85
+ */
68
86
 
69
87
  /* Gray */
70
88
  --cr-color-gray-50: hsl(0 0% 97.5%);
@@ -0,0 +1,40 @@
1
+ <script setup lang="ts">
2
+ import type { TextFieldModel, TextFieldProps } from "@xwiki/cristal-dsapi";
3
+ import { computed } from "vue";
4
+ import { VFileInput } from "vuetify/components/VFileInput";
5
+ import messages from "../../translations";
6
+ import { useI18n } from "vue-i18n";
7
+ import { defineModel } from "vue";
8
+
9
+ const { t } = useI18n({
10
+ messages,
11
+ });
12
+
13
+ const model = defineModel<TextFieldModel>();
14
+ const props = defineProps<TextFieldProps>();
15
+
16
+ const rules = computed(() => {
17
+ const rulesList = [];
18
+ if (props.required) {
19
+ rulesList.push((value: unknown) => {
20
+ if (value) {
21
+ return true;
22
+ } else {
23
+ return t("vuetify.file.input.mandatory");
24
+ }
25
+ });
26
+ }
27
+ return rulesList;
28
+ });
29
+ </script>
30
+
31
+ <template>
32
+ <v-file-input
33
+ v-model="model"
34
+ :label="label"
35
+ :name="name"
36
+ :rules="rules"
37
+ ></v-file-input>
38
+ </template>
39
+
40
+ <style scoped></style>
@@ -0,0 +1,17 @@
1
+ <script setup lang="ts">
2
+ import { VForm } from "vuetify/components/VForm";
3
+ const emits = defineEmits(["formSubmit"]);
4
+ function submit() {
5
+ emits("formSubmit");
6
+ }
7
+ </script>
8
+
9
+ <template>
10
+ <v-form @submit.prevent="submit">
11
+ <v-container>
12
+ <slot></slot>
13
+ </v-container>
14
+ </v-form>
15
+ </template>
16
+
17
+ <style scoped></style>
@@ -0,0 +1,32 @@
1
+ <script setup lang="ts">
2
+ import { type TextFieldProps } from "@xwiki/cristal-dsapi";
3
+ import { computed } from "vue";
4
+ import { VTextField } from "vuetify/components/VTextField";
5
+ import messages from "../../translations";
6
+ import { useI18n } from "vue-i18n";
7
+
8
+ const { t } = useI18n({
9
+ messages,
10
+ });
11
+ const props = defineProps<TextFieldProps>();
12
+
13
+ const rules = computed(() => {
14
+ const rulesList = [];
15
+ if (props.required) {
16
+ rulesList.push((value: unknown) => {
17
+ if (value) {
18
+ return true;
19
+ } else {
20
+ return t("vuetify.text.input.mandatory");
21
+ }
22
+ });
23
+ }
24
+ return rulesList;
25
+ });
26
+ </script>
27
+
28
+ <template>
29
+ <v-text-field :label="label" :name="name" :rules="rules"></v-text-field>
30
+ </template>
31
+
32
+ <style scoped></style>
@@ -1,27 +1,21 @@
1
1
  <!--
2
- * See the LICENSE file distributed with this work for additional
3
- * information regarding copyright ownership.
4
- *
5
- * This is free software; you can redistribute it and/or modify it
6
- * under the terms of the GNU Affero General Public License as
7
- * published by the Free Software Foundation; either version 2.1 of
8
- * the License, or (at your option) any later version.
9
- *
10
- * This software is distributed in the hope that it will be useful,
11
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
12
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13
- * Lesser General Public License for more details.
14
- *
15
- * You should have received a copy of the GNU Affero General Public
16
- * License along with this software; if not, write to the Free
17
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
18
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
19
- *
20
- * This file is part of the Cristal Wiki software prototype
21
- * @copyright Copyright (c) 2023 XWiki SAS
22
- * @license http://opensource.org/licenses/AGPL-3.0 AGPL-3.0
23
- *
24
- **/
2
+ See the LICENSE file distributed with this work for additional
3
+ information regarding copyright ownership.
4
+
5
+ This is free software; you can redistribute it and/or modify it
6
+ under the terms of the GNU Lesser General Public License as
7
+ published by the Free Software Foundation; either version 2.1 of
8
+ the License, or (at your option) any later version.
9
+
10
+ This software is distributed in the hope that it will be useful,
11
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
12
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13
+ Lesser General Public License for more details.
14
+
15
+ You should have received a copy of the GNU Lesser General Public
16
+ License along with this software; if not, write to the Free
17
+ Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
18
+ 02110-1301 USA, or see the FSF site: http://www.fsf.org.
25
19
  -->
26
20
  <template>
27
21
  <v-alert :title="title" :type="type">
@@ -1,27 +1,21 @@
1
1
  <!--
2
- * See the LICENSE file distributed with this work for additional
3
- * information regarding copyright ownership.
4
- *
5
- * This is free software; you can redistribute it and/or modify it
6
- * under the terms of the GNU Affero General Public License as
7
- * published by the Free Software Foundation; either version 2.1 of
8
- * the License, or (at your option) any later version.
9
- *
10
- * This software is distributed in the hope that it will be useful,
11
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
12
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13
- * Lesser General Public License for more details.
14
- *
15
- * You should have received a copy of the GNU Affero General Public
16
- * License along with this software; if not, write to the Free
17
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
18
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
19
- *
20
- * This file is part of the Cristal Wiki software prototype
21
- * @copyright Copyright (c) 2023 XWiki SAS
22
- * @license http://opensource.org/licenses/AGPL-3.0 AGPL-3.0
23
- *
24
- **/
2
+ See the LICENSE file distributed with this work for additional
3
+ information regarding copyright ownership.
4
+
5
+ This is free software; you can redistribute it and/or modify it
6
+ under the terms of the GNU Lesser General Public License as
7
+ published by the Free Software Foundation; either version 2.1 of
8
+ the License, or (at your option) any later version.
9
+
10
+ This software is distributed in the hope that it will be useful,
11
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
12
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13
+ Lesser General Public License for more details.
14
+
15
+ You should have received a copy of the GNU Lesser General Public
16
+ License along with this software; if not, write to the Free
17
+ Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
18
+ 02110-1301 USA, or see the FSF site: http://www.fsf.org.
25
19
  -->
26
20
  <template>
27
21
  <v-avatar :image="image" :size="size"></v-avatar>
@@ -1,32 +1,36 @@
1
1
  <!--
2
- * See the LICENSE file distributed with this work for additional
3
- * information regarding copyright ownership.
4
- *
5
- * This is free software; you can redistribute it and/or modify it
6
- * under the terms of the GNU Affero General Public License as
7
- * published by the Free Software Foundation; either version 2.1 of
8
- * the License, or (at your option) any later version.
9
- *
10
- * This software is distributed in the hope that it will be useful,
11
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
12
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13
- * Lesser General Public License for more details.
14
- *
15
- * You should have received a copy of the GNU Affero General Public
16
- * License along with this software; if not, write to the Free
17
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
18
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
19
- *
20
- * This file is part of the Cristal Wiki software prototype
21
- * @copyright Copyright (c) 2023 XWiki SAS
22
- * @license http://opensource.org/licenses/AGPL-3.0 AGPL-3.0
23
- *
24
- **/
2
+ See the LICENSE file distributed with this work for additional
3
+ information regarding copyright ownership.
4
+
5
+ This is free software; you can redistribute it and/or modify it
6
+ under the terms of the GNU Lesser General Public License as
7
+ published by the Free Software Foundation; either version 2.1 of
8
+ the License, or (at your option) any later version.
9
+
10
+ This software is distributed in the hope that it will be useful,
11
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
12
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13
+ Lesser General Public License for more details.
14
+
15
+ You should have received a copy of the GNU Lesser General Public
16
+ License along with this software; if not, write to the Free
17
+ Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
18
+ 02110-1301 USA, or see the FSF site: http://www.fsf.org.
25
19
  -->
26
20
  <script setup lang="ts">
27
21
  import { BreadcrumbProps } from "@xwiki/cristal-dsapi";
22
+ import { computed } from "vue";
28
23
 
29
- defineProps<BreadcrumbProps>();
24
+ const props = defineProps<BreadcrumbProps>();
25
+ // Converts props items to the format expected by v-breadcrumbs
26
+ const items = computed(() => {
27
+ return props.items.map(({ label, url }) => {
28
+ return {
29
+ title: label,
30
+ href: url,
31
+ };
32
+ });
33
+ });
30
34
  </script>
31
35
 
32
36
  <template>
package/src/vue/x-btn.vue CHANGED
@@ -1,27 +1,21 @@
1
1
  <!--
2
- * See the LICENSE file distributed with this work for additional
3
- * information regarding copyright ownership.
4
- *
5
- * This is free software; you can redistribute it and/or modify it
6
- * under the terms of the GNU Affero General Public License as
7
- * published by the Free Software Foundation; either version 2.1 of
8
- * the License, or (at your option) any later version.
9
- *
10
- * This software is distributed in the hope that it will be useful,
11
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
12
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13
- * Lesser General Public License for more details.
14
- *
15
- * You should have received a copy of the GNU Affero General Public
16
- * License along with this software; if not, write to the Free
17
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
18
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
19
- *
20
- * This file is part of the Cristal Wiki software prototype
21
- * @copyright Copyright (c) 2023 XWiki SAS
22
- * @license http://opensource.org/licenses/AGPL-3.0 AGPL-3.0
23
- *
24
- **/
2
+ See the LICENSE file distributed with this work for additional
3
+ information regarding copyright ownership.
4
+
5
+ This is free software; you can redistribute it and/or modify it
6
+ under the terms of the GNU Lesser General Public License as
7
+ published by the Free Software Foundation; either version 2.1 of
8
+ the License, or (at your option) any later version.
9
+
10
+ This software is distributed in the hope that it will be useful,
11
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
12
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13
+ Lesser General Public License for more details.
14
+
15
+ You should have received a copy of the GNU Lesser General Public
16
+ License along with this software; if not, write to the Free
17
+ Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
18
+ 02110-1301 USA, or see the FSF site: http://www.fsf.org.
25
19
  -->
26
20
  <template>
27
21
  <v-btn>
@@ -1,27 +1,21 @@
1
1
  <!--
2
- * See the LICENSE file distributed with this work for additional
3
- * information regarding copyright ownership.
4
- *
5
- * This is free software; you can redistribute it and/or modify it
6
- * under the terms of the GNU Affero General Public License as
7
- * published by the Free Software Foundation; either version 2.1 of
8
- * the License, or (at your option) any later version.
9
- *
10
- * This software is distributed in the hope that it will be useful,
11
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
12
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13
- * Lesser General Public License for more details.
14
- *
15
- * You should have received a copy of the GNU Affero General Public
16
- * License along with this software; if not, write to the Free
17
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
18
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
19
- *
20
- * This file is part of the Cristal Wiki software prototype
21
- * @copyright Copyright (c) 2023 XWiki SAS
22
- * @license http://opensource.org/licenses/AGPL-3.0 AGPL-3.0
23
- *
24
- **/
2
+ See the LICENSE file distributed with this work for additional
3
+ information regarding copyright ownership.
4
+
5
+ This is free software; you can redistribute it and/or modify it
6
+ under the terms of the GNU Lesser General Public License as
7
+ published by the Free Software Foundation; either version 2.1 of
8
+ the License, or (at your option) any later version.
9
+
10
+ This software is distributed in the hope that it will be useful,
11
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
12
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13
+ Lesser General Public License for more details.
14
+
15
+ You should have received a copy of the GNU Lesser General Public
16
+ License along with this software; if not, write to the Free
17
+ Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
18
+ 02110-1301 USA, or see the FSF site: http://www.fsf.org.
25
19
  -->
26
20
  <template>
27
21
  <v-card :title="title" variant="outlined">
@@ -1,27 +1,21 @@
1
1
  <!--
2
- * See the LICENSE file distributed with this work for additional
3
- * information regarding copyright ownership.
4
- *
5
- * This is free software; you can redistribute it and/or modify it
6
- * under the terms of the GNU Affero General Public License as
7
- * published by the Free Software Foundation; either version 2.1 of
8
- * the License, or (at your option) any later version.
9
- *
10
- * This software is distributed in the hope that it will be useful,
11
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
12
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13
- * Lesser General Public License for more details.
14
- *
15
- * You should have received a copy of the GNU Affero General Public
16
- * License along with this software; if not, write to the Free
17
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
18
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
19
- *
20
- * This file is part of the Cristal Wiki software prototype
21
- * @copyright Copyright (c) 2023 XWiki SAS
22
- * @license http://opensource.org/licenses/AGPL-3.0 AGPL-3.0
23
- *
24
- **/
2
+ See the LICENSE file distributed with this work for additional
3
+ information regarding copyright ownership.
4
+
5
+ This is free software; you can redistribute it and/or modify it
6
+ under the terms of the GNU Lesser General Public License as
7
+ published by the Free Software Foundation; either version 2.1 of
8
+ the License, or (at your option) any later version.
9
+
10
+ This software is distributed in the hope that it will be useful,
11
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
12
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13
+ Lesser General Public License for more details.
14
+
15
+ You should have received a copy of the GNU Lesser General Public
16
+ License along with this software; if not, write to the Free
17
+ Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
18
+ 02110-1301 USA, or see the FSF site: http://www.fsf.org.
25
19
  -->
26
20
  <script lang="ts" setup>
27
21
  defineProps<{