@dative-gpi/foundation-shared-components 0.0.68 → 0.0.70
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/components/FSBreadcrumbs.vue +5 -1
- package/components/FSClickable.vue +1 -2
- package/components/FSLink.vue +1 -2
- package/components/fields/FSColorField.vue +2 -0
- package/components/tiles/FSDeviceOrganisationTileUI.vue +7 -6
- package/components/tiles/FSGroupTileUI.vue +9 -10
- package/components/tiles/FSTile.vue +45 -2
- package/components/tiles/FSUserOrganisationTileUI.vue +130 -0
- package/package.json +4 -4
- package/styles/components/fs_breadcrumbs.scss +8 -0
|
@@ -82,7 +82,7 @@
|
|
|
82
82
|
|
|
83
83
|
<script lang="ts">
|
|
84
84
|
import { computed, defineComponent, PropType } from "vue";
|
|
85
|
-
import { RouteLocation
|
|
85
|
+
import { RouteLocation } from "vue-router";
|
|
86
86
|
|
|
87
87
|
import { ColorBase, ColorEnum } from "@dative-gpi/foundation-shared-components/models";
|
|
88
88
|
import { useColors } from "@dative-gpi/foundation-shared-components/composables";
|
|
@@ -155,7 +155,6 @@ export default defineComponent({
|
|
|
155
155
|
emits: ["click"],
|
|
156
156
|
setup(props, { emit }) {
|
|
157
157
|
const { getColors } = useColors();
|
|
158
|
-
const router = useRouter();
|
|
159
158
|
|
|
160
159
|
const colors = computed(() => getColors(props.color));
|
|
161
160
|
const backgrounds = getColors(ColorEnum.Background);
|
package/components/FSLink.vue
CHANGED
|
@@ -24,7 +24,7 @@
|
|
|
24
24
|
|
|
25
25
|
<script lang="ts">
|
|
26
26
|
import { computed, defineComponent, PropType } from "vue";
|
|
27
|
-
import { RouteLocation
|
|
27
|
+
import { RouteLocation } from "vue-router";
|
|
28
28
|
|
|
29
29
|
import { useColors, useSlots } from "@dative-gpi/foundation-shared-components/composables";
|
|
30
30
|
import { ColorBase, ColorEnum } from "@dative-gpi/foundation-shared-components/models";
|
|
@@ -76,7 +76,6 @@ export default defineComponent({
|
|
|
76
76
|
setup(props) {
|
|
77
77
|
const { getColors } = useColors();
|
|
78
78
|
const { slots } = useSlots();
|
|
79
|
-
const router = useRouter();
|
|
80
79
|
|
|
81
80
|
const colors = computed(() => getColors(props.color));
|
|
82
81
|
|
|
@@ -34,6 +34,7 @@
|
|
|
34
34
|
prependIcon="mdi-pencil"
|
|
35
35
|
variant="full"
|
|
36
36
|
:editable="$props.editable"
|
|
37
|
+
v-bind="props"
|
|
37
38
|
/>
|
|
38
39
|
</template>
|
|
39
40
|
</FSTextField>
|
|
@@ -64,6 +65,7 @@
|
|
|
64
65
|
prependIcon="mdi-pencil"
|
|
65
66
|
variant="full"
|
|
66
67
|
:editable="$props.editable"
|
|
68
|
+
v-bind="props"
|
|
67
69
|
/>
|
|
68
70
|
</template>
|
|
69
71
|
</FSTextField>
|
|
@@ -22,17 +22,18 @@
|
|
|
22
22
|
gap="6px"
|
|
23
23
|
:width="infoWidth"
|
|
24
24
|
>
|
|
25
|
-
<
|
|
25
|
+
<FSText
|
|
26
26
|
font="text-button"
|
|
27
27
|
:lineClamp="2"
|
|
28
28
|
>
|
|
29
29
|
{{ $props.label }}
|
|
30
|
-
</
|
|
31
|
-
<
|
|
30
|
+
</FSText>
|
|
31
|
+
<FSText
|
|
32
32
|
font="text-overline"
|
|
33
|
+
variant="light"
|
|
33
34
|
>
|
|
34
35
|
{{ $props.code }}
|
|
35
|
-
</
|
|
36
|
+
</FSText>
|
|
36
37
|
</FSCol>
|
|
37
38
|
<FSRow
|
|
38
39
|
gap="4px"
|
|
@@ -82,7 +83,7 @@ import FSStatusesRow from "../deviceOrganisations/FSStatusesRow.vue";
|
|
|
82
83
|
import FSWorstAlert from "../deviceOrganisations/FSWorstAlert.vue";
|
|
83
84
|
import FSDivider from "../FSDivider.vue";
|
|
84
85
|
import FSImage from "../FSImage.vue";
|
|
85
|
-
import
|
|
86
|
+
import FSText from "../FSText.vue";
|
|
86
87
|
import FSTile from "./FSTile.vue";
|
|
87
88
|
import FSCol from "../FSCol.vue";
|
|
88
89
|
import FSRow from "../FSRow.vue";
|
|
@@ -96,8 +97,8 @@ export default defineComponent({
|
|
|
96
97
|
FSWorstAlert,
|
|
97
98
|
FSDivider,
|
|
98
99
|
FSImage,
|
|
100
|
+
FSText,
|
|
99
101
|
FSTile,
|
|
100
|
-
FSSpan,
|
|
101
102
|
FSCol,
|
|
102
103
|
FSRow
|
|
103
104
|
},
|
|
@@ -22,16 +22,17 @@
|
|
|
22
22
|
gap="6px"
|
|
23
23
|
:width="infoWidth"
|
|
24
24
|
>
|
|
25
|
-
<
|
|
25
|
+
<FSText
|
|
26
26
|
font="text-button"
|
|
27
27
|
>
|
|
28
28
|
{{ $props.label }}
|
|
29
|
-
</
|
|
30
|
-
<
|
|
29
|
+
</FSText>
|
|
30
|
+
<FSText
|
|
31
31
|
font="text-overline"
|
|
32
|
+
variant="light"
|
|
32
33
|
>
|
|
33
34
|
{{ $props.code }}
|
|
34
|
-
</
|
|
35
|
+
</FSText>
|
|
35
36
|
</FSCol>
|
|
36
37
|
<FSCol
|
|
37
38
|
gap="6px"
|
|
@@ -55,11 +56,11 @@
|
|
|
55
56
|
</FSText>
|
|
56
57
|
</FSRow>
|
|
57
58
|
</FSColor>
|
|
58
|
-
<
|
|
59
|
+
<FSText
|
|
59
60
|
font="text-overline"
|
|
60
61
|
>
|
|
61
62
|
{{ $tr("ui.group-tile.group(s)", "Group(s)") }}
|
|
62
|
-
</
|
|
63
|
+
</FSText>
|
|
63
64
|
</FSRow>
|
|
64
65
|
<FSRow
|
|
65
66
|
align="center-left"
|
|
@@ -80,11 +81,11 @@
|
|
|
80
81
|
</FSText>
|
|
81
82
|
</FSRow>
|
|
82
83
|
</FSColor>
|
|
83
|
-
<
|
|
84
|
+
<FSText
|
|
84
85
|
font="text-overline"
|
|
85
86
|
>
|
|
86
87
|
{{ $tr("ui.group-tile.device(s)", "Device(s)") }}
|
|
87
|
-
</
|
|
88
|
+
</FSText>
|
|
88
89
|
</FSRow>
|
|
89
90
|
</FSCol>
|
|
90
91
|
</FSCol>
|
|
@@ -106,7 +107,6 @@ import { ColorEnum } from "@dative-gpi/foundation-shared-components/models";
|
|
|
106
107
|
|
|
107
108
|
import FSImage from "../FSImage.vue";
|
|
108
109
|
import FSColor from "../FSColor.vue";
|
|
109
|
-
import FSSpan from "../FSSpan.vue";
|
|
110
110
|
import FSText from "../FSText.vue";
|
|
111
111
|
import FSTile from "./FSTile.vue";
|
|
112
112
|
import FSCol from "../FSCol.vue";
|
|
@@ -117,7 +117,6 @@ export default defineComponent({
|
|
|
117
117
|
components: {
|
|
118
118
|
FSImage,
|
|
119
119
|
FSColor,
|
|
120
|
-
FSSpan,
|
|
121
120
|
FSText,
|
|
122
121
|
FSTile,
|
|
123
122
|
FSCol,
|
|
@@ -1,5 +1,34 @@
|
|
|
1
1
|
<template>
|
|
2
|
+
<FSClickable
|
|
3
|
+
v-if="$props.href || $props.to || $attrs.onClick"
|
|
4
|
+
class="fs-tile"
|
|
5
|
+
padding="12px"
|
|
6
|
+
:height="height"
|
|
7
|
+
:width="width"
|
|
8
|
+
:style="style"
|
|
9
|
+
:href="$props.href"
|
|
10
|
+
:to="$props.to"
|
|
11
|
+
v-bind="$attrs"
|
|
12
|
+
>
|
|
13
|
+
<slot />
|
|
14
|
+
<FSCard
|
|
15
|
+
v-if="$props.editable"
|
|
16
|
+
class="fs-tile-checkbox"
|
|
17
|
+
:border="false"
|
|
18
|
+
>
|
|
19
|
+
<FSCheckbox
|
|
20
|
+
:color="ColorEnum.Dark"
|
|
21
|
+
:modelValue="$props.modelValue"
|
|
22
|
+
@update:modelValue="() => $emit('update:modelValue', !$props.modelValue)"
|
|
23
|
+
/>
|
|
24
|
+
</FSCard>
|
|
25
|
+
<div
|
|
26
|
+
class="fs-tile-bottom"
|
|
27
|
+
:style="style"
|
|
28
|
+
/>
|
|
29
|
+
</FSClickable>
|
|
2
30
|
<FSCard
|
|
31
|
+
v-else
|
|
3
32
|
class="fs-tile"
|
|
4
33
|
padding="12px"
|
|
5
34
|
:style="style"
|
|
@@ -19,6 +48,7 @@
|
|
|
19
48
|
/>
|
|
20
49
|
</FSCard>
|
|
21
50
|
<div
|
|
51
|
+
v-if="$props.bottomColor"
|
|
22
52
|
class="fs-tile-bottom"
|
|
23
53
|
:style="style"
|
|
24
54
|
/>
|
|
@@ -27,29 +57,42 @@
|
|
|
27
57
|
|
|
28
58
|
<script lang="ts">
|
|
29
59
|
import { computed, defineComponent, PropType } from "vue";
|
|
60
|
+
import { RouteLocation } from "vue-router";
|
|
30
61
|
|
|
31
62
|
import { useBreakpoints, useColors } from "@dative-gpi/foundation-shared-components/composables";
|
|
32
63
|
import { ColorBase, ColorEnum } from "@dative-gpi/foundation-shared-components/models";
|
|
33
64
|
|
|
65
|
+
import FSClickable from "../FSClickable.vue";
|
|
34
66
|
import FSCheckbox from "../FSCheckbox.vue";
|
|
35
67
|
import FSCard from "../FSCard.vue";
|
|
36
68
|
|
|
37
69
|
export default defineComponent({
|
|
38
70
|
name: "FSTile",
|
|
39
71
|
components: {
|
|
72
|
+
FSClickable,
|
|
40
73
|
FSCheckbox,
|
|
41
74
|
FSCard
|
|
42
75
|
},
|
|
43
76
|
props: {
|
|
77
|
+
to: {
|
|
78
|
+
type: [String, Object] as PropType<string | RouteLocation | null>,
|
|
79
|
+
required: false,
|
|
80
|
+
default: null
|
|
81
|
+
},
|
|
82
|
+
href: {
|
|
83
|
+
type: String as PropType<string | null>,
|
|
84
|
+
required: false,
|
|
85
|
+
default: null
|
|
86
|
+
},
|
|
44
87
|
modelValue: {
|
|
45
88
|
type: Boolean,
|
|
46
89
|
required: false,
|
|
47
90
|
default: false
|
|
48
91
|
},
|
|
49
92
|
bottomColor: {
|
|
50
|
-
type: [Array, String] as PropType<ColorBase[] | ColorBase>,
|
|
93
|
+
type: [Array, String] as PropType<ColorBase[] | ColorBase | null>,
|
|
51
94
|
required: false,
|
|
52
|
-
default:
|
|
95
|
+
default: null
|
|
53
96
|
},
|
|
54
97
|
editable: {
|
|
55
98
|
type: Boolean,
|
|
@@ -0,0 +1,130 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<FSTile
|
|
3
|
+
:editable="$props.editable"
|
|
4
|
+
:modelValue="$props.modelValue"
|
|
5
|
+
v-bind="$attrs"
|
|
6
|
+
>
|
|
7
|
+
<FSCol
|
|
8
|
+
align="center-center"
|
|
9
|
+
width="fill"
|
|
10
|
+
>
|
|
11
|
+
<FSRow
|
|
12
|
+
align="center-center"
|
|
13
|
+
gap="24px"
|
|
14
|
+
:wrap="false"
|
|
15
|
+
:height="imageSize"
|
|
16
|
+
>
|
|
17
|
+
<FSCol
|
|
18
|
+
gap="4px"
|
|
19
|
+
:width="infoWidth"
|
|
20
|
+
>
|
|
21
|
+
<FSText
|
|
22
|
+
font="text-button"
|
|
23
|
+
:lineClamp="2"
|
|
24
|
+
>
|
|
25
|
+
{{ $props.name }}
|
|
26
|
+
</FSText>
|
|
27
|
+
<FSRow
|
|
28
|
+
align="center-left"
|
|
29
|
+
gap="4px"
|
|
30
|
+
>
|
|
31
|
+
<FSIcon
|
|
32
|
+
variant="light"
|
|
33
|
+
:color="ColorEnum.Dark"
|
|
34
|
+
>
|
|
35
|
+
{{ $props.roleIcon }}
|
|
36
|
+
</FSIcon>
|
|
37
|
+
<FSText
|
|
38
|
+
font="text-overline"
|
|
39
|
+
variant="light"
|
|
40
|
+
>
|
|
41
|
+
{{ $props.roleLabel }}
|
|
42
|
+
</FSText>
|
|
43
|
+
</FSRow>
|
|
44
|
+
</FSCol>
|
|
45
|
+
<FSImage
|
|
46
|
+
v-if="$props.imageId"
|
|
47
|
+
:imageId="$props.imageId"
|
|
48
|
+
:width="imageSize"
|
|
49
|
+
/>
|
|
50
|
+
</FSRow>
|
|
51
|
+
</FSCol>
|
|
52
|
+
</FSTile>
|
|
53
|
+
</template>
|
|
54
|
+
|
|
55
|
+
<script lang="ts">
|
|
56
|
+
import { computed, defineComponent, PropType } from "vue";
|
|
57
|
+
|
|
58
|
+
import { useBreakpoints } from "@dative-gpi/foundation-shared-components/composables";
|
|
59
|
+
import { ColorEnum } from "@dative-gpi/foundation-shared-components/models";
|
|
60
|
+
|
|
61
|
+
import FSImage from "../FSImage.vue";
|
|
62
|
+
import FSText from "../FSText.vue";
|
|
63
|
+
import FSTile from "./FSTile.vue";
|
|
64
|
+
import FSCol from "../FSCol.vue";
|
|
65
|
+
import FSRow from "../FSRow.vue";
|
|
66
|
+
|
|
67
|
+
export default defineComponent({
|
|
68
|
+
name: "FSUserOrganisationTileUI",
|
|
69
|
+
components: {
|
|
70
|
+
FSImage,
|
|
71
|
+
FSText,
|
|
72
|
+
FSTile,
|
|
73
|
+
FSCol,
|
|
74
|
+
FSRow
|
|
75
|
+
},
|
|
76
|
+
props: {
|
|
77
|
+
imageId: {
|
|
78
|
+
type: String as PropType<string | null>,
|
|
79
|
+
required: false,
|
|
80
|
+
default: null
|
|
81
|
+
},
|
|
82
|
+
name: {
|
|
83
|
+
type: String as PropType<string | null>,
|
|
84
|
+
required: false,
|
|
85
|
+
default: null
|
|
86
|
+
},
|
|
87
|
+
roleIcon: {
|
|
88
|
+
type: String as PropType<string | null>,
|
|
89
|
+
required: false,
|
|
90
|
+
default: null
|
|
91
|
+
},
|
|
92
|
+
roleLabel: {
|
|
93
|
+
type: String as PropType<string | null>,
|
|
94
|
+
required: false,
|
|
95
|
+
default: null
|
|
96
|
+
},
|
|
97
|
+
modelValue: {
|
|
98
|
+
type: Boolean,
|
|
99
|
+
required: false,
|
|
100
|
+
default: false
|
|
101
|
+
},
|
|
102
|
+
editable: {
|
|
103
|
+
type: Boolean,
|
|
104
|
+
required: false,
|
|
105
|
+
default: true
|
|
106
|
+
}
|
|
107
|
+
},
|
|
108
|
+
setup(props) {
|
|
109
|
+
const { isMobileSized } = useBreakpoints();
|
|
110
|
+
|
|
111
|
+
const imageSize = computed((): number => {
|
|
112
|
+
return isMobileSized.value ? 90 : 100;
|
|
113
|
+
});
|
|
114
|
+
|
|
115
|
+
const infoWidth = computed((): number => {
|
|
116
|
+
let width = isMobileSized.value ? 288 : 304;
|
|
117
|
+
if (props.imageId) {
|
|
118
|
+
width -= imageSize.value;
|
|
119
|
+
}
|
|
120
|
+
return width;
|
|
121
|
+
});
|
|
122
|
+
|
|
123
|
+
return {
|
|
124
|
+
imageSize,
|
|
125
|
+
infoWidth,
|
|
126
|
+
ColorEnum
|
|
127
|
+
};
|
|
128
|
+
}
|
|
129
|
+
});
|
|
130
|
+
</script>
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dative-gpi/foundation-shared-components",
|
|
3
3
|
"sideEffects": false,
|
|
4
|
-
"version": "0.0.
|
|
4
|
+
"version": "0.0.70",
|
|
5
5
|
"description": "",
|
|
6
6
|
"publishConfig": {
|
|
7
7
|
"access": "public"
|
|
@@ -10,8 +10,8 @@
|
|
|
10
10
|
"author": "",
|
|
11
11
|
"license": "ISC",
|
|
12
12
|
"dependencies": {
|
|
13
|
-
"@dative-gpi/foundation-shared-domain": "0.0.
|
|
14
|
-
"@dative-gpi/foundation-shared-services": "0.0.
|
|
13
|
+
"@dative-gpi/foundation-shared-domain": "0.0.70",
|
|
14
|
+
"@dative-gpi/foundation-shared-services": "0.0.70",
|
|
15
15
|
"@fontsource/montserrat": "^5.0.16",
|
|
16
16
|
"@lexical/clipboard": "^0.12.5",
|
|
17
17
|
"@lexical/history": "^0.12.5",
|
|
@@ -32,5 +32,5 @@
|
|
|
32
32
|
"sass": "^1.69.5",
|
|
33
33
|
"sass-loader": "^13.3.2"
|
|
34
34
|
},
|
|
35
|
-
"gitHead": "
|
|
35
|
+
"gitHead": "e280ffdb9ee5d27727cc01325689b792168febcd"
|
|
36
36
|
}
|