independer-design-system 1.3.1 → 1.4.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/dist/module.json +1 -1
- package/dist/runtime/components/Expandable/Card.vue +28 -14
- package/dist/runtime/components/Expandable/Filter.vue +24 -13
- package/dist/runtime/components/Form/Checkbox.vue +3 -3
- package/dist/runtime/components/Form/CheckboxProduct.vue +54 -30
- package/dist/runtime/components/Form/Fieldset.vue +60 -35
- package/dist/runtime/components/Form/Input.d.vue.ts +2 -0
- package/dist/runtime/components/Form/Input.vue +4 -1
- package/dist/runtime/components/Form/Input.vue.d.ts +2 -0
- package/dist/runtime/components/Form/RadioProduct.vue +57 -31
- package/dist/runtime/components/Form/Textarea.vue +31 -12
- package/dist/runtime/components/Notification.vue +27 -14
- package/dist/runtime/components/Price.vue +38 -18
- package/dist/runtime/components/PriceQuote.vue +5 -2
- package/dist/runtime/components/USP.vue +11 -7
- package/package.json +2 -1
package/dist/module.json
CHANGED
|
@@ -1,24 +1,38 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
2
|
+
<div class="w-full bg-white shadow-raised rounded-xl transition-all">
|
|
3
|
+
<button
|
|
4
|
+
class="group w-full flex items-center p-4 tablet:p-6"
|
|
5
|
+
:class="{ 'cursor-pointer': expandable }"
|
|
6
|
+
@click.prevent="toggle"
|
|
7
|
+
>
|
|
8
|
+
<h3 class="transition-all group-hover:underline group-hover:decoration-1 group-hover:underline-offset-4">
|
|
9
|
+
{{ title }}
|
|
10
|
+
</h3>
|
|
5
11
|
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
12
|
+
<div class="flex ml-auto rounded-full transition-all duration-300 ring-4 ring-transparent group-hover:bg-purple-200 group-hover:ring-purple/20 group-active:bg-purple/40 group-active:ring-purple/40">
|
|
13
|
+
<Icon
|
|
14
|
+
v-if="expandable"
|
|
15
|
+
name="eva:arrow-ios-downward-outline"
|
|
16
|
+
class="text-purple transition-all duration-300 group-hover:text-purple-dark"
|
|
17
|
+
:class="{ '-rotate-180': expanded }"
|
|
18
|
+
/>
|
|
19
|
+
</div>
|
|
20
|
+
</button>
|
|
10
21
|
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
22
|
+
<Collapse
|
|
23
|
+
:when="expanded"
|
|
24
|
+
class="v-collapse"
|
|
25
|
+
>
|
|
26
|
+
<div class="p-4 pt-0 tablet:p-6 tablet:pt-0">
|
|
27
|
+
<slot />
|
|
28
|
+
</div>
|
|
29
|
+
</Collapse>
|
|
30
|
+
</div>
|
|
17
31
|
</template>
|
|
18
32
|
|
|
19
33
|
<script setup>
|
|
20
34
|
import { Collapse } from "vue-collapsed";
|
|
21
|
-
import { onMounted } from "vue";
|
|
35
|
+
import { onMounted, ref } from "vue";
|
|
22
36
|
const expanded = ref(false);
|
|
23
37
|
const props = defineProps({
|
|
24
38
|
title: String,
|
|
@@ -1,24 +1,35 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
2
|
+
<div class="bg-white shadow-raised rounded-xl">
|
|
3
|
+
<button
|
|
4
|
+
class="group flex items-center w-full pt-4 px-4 tablet:pt-6 tablet:px-6"
|
|
5
|
+
:class="{ 'cursor-pointer': expandable }"
|
|
6
|
+
@click.prevent="toggle"
|
|
7
|
+
>
|
|
8
|
+
<div class="font-serif font-semibold text-purple-dark line-clamp-1 text-left tablet:text-xl transition-all group-hover:underline group-hover:decoration-1 group-hover:underline-offset-4">
|
|
9
|
+
{{ title }}
|
|
10
|
+
</div>
|
|
5
11
|
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
12
|
+
<div class="flex ml-auto rounded-full transition-all duration-300 ring-4 ring-transparent group-hover:bg-purple-200 group-hover:ring-purple/20 group-active:bg-purple/40 group-active:ring-purple/40">
|
|
13
|
+
<Icon
|
|
14
|
+
v-if="expandable"
|
|
15
|
+
name="eva:arrow-ios-downward-outline"
|
|
16
|
+
class="ml-auto text-purple transition-all duration-300 group-hover:text-purple-dark"
|
|
17
|
+
:class="{ '-rotate-180': expanded }"
|
|
18
|
+
/>
|
|
19
|
+
</div>
|
|
20
|
+
</button>
|
|
10
21
|
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
</div>
|
|
22
|
+
<div class="px-4 pb-4 tablet:px-6 tablet:pb-6">
|
|
23
|
+
<Collapse :when="expanded">
|
|
24
|
+
<slot />
|
|
25
|
+
</Collapse>
|
|
16
26
|
</div>
|
|
27
|
+
</div>
|
|
17
28
|
</template>
|
|
18
29
|
|
|
19
30
|
<script setup>
|
|
20
31
|
import { Collapse } from "vue-collapsed";
|
|
21
|
-
import { onMounted } from "vue";
|
|
32
|
+
import { onMounted, ref } from "vue";
|
|
22
33
|
const expanded = ref(false);
|
|
23
34
|
const props = defineProps({
|
|
24
35
|
title: String,
|
|
@@ -1,37 +1,61 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
2
|
+
<label
|
|
3
|
+
class="checkbox group flex flex-col p-4 cursor-pointer border border-grey-light rounded-lg transition-all hover:border-grey"
|
|
4
|
+
:class="{ '!border-green ring-1 ring-green': modelValue }"
|
|
5
|
+
:for="id"
|
|
6
|
+
>
|
|
7
|
+
<div class="flex pb-4">
|
|
8
|
+
<input
|
|
9
|
+
:id="id"
|
|
10
|
+
:ref="name"
|
|
11
|
+
class="sr-only peer"
|
|
12
|
+
type="checkbox"
|
|
13
|
+
:name="name"
|
|
14
|
+
:value="value"
|
|
15
|
+
:checked="modelValue"
|
|
16
|
+
:disabled="disabled"
|
|
17
|
+
@change="emit('update:modelValue', $event.target.checked)"
|
|
18
|
+
@focus="emit('focus', $event)"
|
|
19
|
+
>
|
|
20
|
+
<div class="checkbox-icon " />
|
|
21
21
|
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
22
|
+
<div class="flex flex-col w-full ml-2">
|
|
23
|
+
<div class="flex">
|
|
24
|
+
<span
|
|
25
|
+
class="font-serif text-purple-dark font-bold"
|
|
26
|
+
:class="{ 'text-grey-dark': disabled }"
|
|
27
|
+
>{{ label }}</span>
|
|
28
|
+
|
|
29
|
+
<Icon
|
|
30
|
+
v-if="tooltip"
|
|
31
|
+
name="eva:info-outline"
|
|
32
|
+
class="ml-2 cursor-pointer text-grey-dark"
|
|
33
|
+
/>
|
|
31
34
|
</div>
|
|
32
35
|
|
|
33
|
-
<
|
|
34
|
-
|
|
36
|
+
<p
|
|
37
|
+
v-if="labelSecondary"
|
|
38
|
+
class="text-grey-dark"
|
|
39
|
+
>{{ labelSecondary }}</p>
|
|
40
|
+
|
|
41
|
+
<IndPriceQuote
|
|
42
|
+
v-if="price"
|
|
43
|
+
:price="price"
|
|
44
|
+
:without-symbol="true"
|
|
45
|
+
text-append=" per maand"
|
|
46
|
+
class="font-semibold text-grey-darker"
|
|
47
|
+
/>
|
|
48
|
+
|
|
49
|
+
<IndPill
|
|
50
|
+
v-if="advice"
|
|
51
|
+
class="mt-1 self-start"
|
|
52
|
+
:label="adviceLabel"
|
|
53
|
+
/>
|
|
54
|
+
</div>
|
|
55
|
+
</div>
|
|
56
|
+
|
|
57
|
+
<slot />
|
|
58
|
+
</label>
|
|
35
59
|
</template>
|
|
36
60
|
|
|
37
61
|
<script setup>
|
|
@@ -1,27 +1,52 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
2
|
+
<fieldset
|
|
3
|
+
ref="sectionRef"
|
|
4
|
+
class="card w-full shrink-0 grow-0 mb-4 p-4 bg-white rounded-xl tablet:p-6 transition-all shadow-raised scroll-mt-6 tablet:scroll-mt-8"
|
|
5
|
+
:class="classesCard"
|
|
6
|
+
>
|
|
7
|
+
<header
|
|
8
|
+
v-if="title"
|
|
9
|
+
class="flex items-start border-b-grey-light"
|
|
10
|
+
:class="classesHeader"
|
|
11
|
+
>
|
|
12
|
+
<div
|
|
13
|
+
v-if="step"
|
|
14
|
+
class="hexagon w-7 h-7 tablet:w-8 tablet:h-8 mr-2 tablet:mr-4 z-10"
|
|
15
|
+
:class="classesHexagon"
|
|
16
|
+
/>
|
|
5
17
|
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
18
|
+
<h3
|
|
19
|
+
class="transition-all"
|
|
20
|
+
:class="classesTitle"
|
|
21
|
+
>
|
|
22
|
+
{{ title }}
|
|
23
|
+
</h3>
|
|
9
24
|
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
25
|
+
<button
|
|
26
|
+
v-if="section.state === 'saved' || section.state === 'paused'"
|
|
27
|
+
class="!p-0 text-purple cursor-pointer hover:text-purple-dark ml-auto"
|
|
28
|
+
@click.prevent="emit('edit', $event)"
|
|
29
|
+
>
|
|
30
|
+
<Icon name="eva:edit-outline" />
|
|
31
|
+
</button>
|
|
32
|
+
</header>
|
|
14
33
|
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
34
|
+
<div class="desktop:mx-12">
|
|
35
|
+
<Collapse
|
|
36
|
+
:when="section.state === 'saved' || section.state === 'paused'"
|
|
37
|
+
class="v-collapse"
|
|
38
|
+
>
|
|
39
|
+
<slot name="saved" />
|
|
40
|
+
</Collapse>
|
|
19
41
|
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
42
|
+
<Collapse
|
|
43
|
+
:when="section.state === 'editing'"
|
|
44
|
+
class="v-collapse"
|
|
45
|
+
>
|
|
46
|
+
<slot name="editing" />
|
|
47
|
+
</Collapse>
|
|
48
|
+
</div>
|
|
49
|
+
</fieldset>
|
|
25
50
|
</template>
|
|
26
51
|
|
|
27
52
|
<script setup>
|
|
@@ -41,34 +66,34 @@ const props = defineProps({
|
|
|
41
66
|
const sectionRef = ref(null);
|
|
42
67
|
const classesCard = computed(() => {
|
|
43
68
|
return {
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
69
|
+
editing: "card--editing",
|
|
70
|
+
paused: "card--paused",
|
|
71
|
+
saved: "card--saved",
|
|
72
|
+
closed: "card--closed cursor-not-allowed"
|
|
48
73
|
}[props.section.state];
|
|
49
74
|
});
|
|
50
75
|
const classesHeader = computed(() => {
|
|
51
76
|
return {
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
77
|
+
editing: "pb-4",
|
|
78
|
+
paused: "pb-4",
|
|
79
|
+
saved: "pb-4",
|
|
80
|
+
closed: "!mb-0"
|
|
56
81
|
}[props.section.state];
|
|
57
82
|
});
|
|
58
83
|
const classesTitle = computed(() => {
|
|
59
84
|
return {
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
85
|
+
editing: "text-purple-dark",
|
|
86
|
+
saved: "text-purple-dark",
|
|
87
|
+
paused: "text-purple-dark",
|
|
88
|
+
closed: "!text-grey-dark"
|
|
64
89
|
}[props.section.state];
|
|
65
90
|
});
|
|
66
91
|
const classesHexagon = computed(() => {
|
|
67
92
|
return {
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
93
|
+
editing: "hexagon--editing",
|
|
94
|
+
paused: "hexagon--closed",
|
|
95
|
+
saved: "hexagon--saved",
|
|
96
|
+
closed: "hexagon--closed"
|
|
72
97
|
}[props.section.state];
|
|
73
98
|
});
|
|
74
99
|
watch(() => props.section.state, (value) => {
|
|
@@ -22,6 +22,7 @@ declare const __VLS_export: import("vue").DefineComponent<import("vue").ExtractP
|
|
|
22
22
|
placeholder: StringConstructor;
|
|
23
23
|
labelClasses: StringConstructor;
|
|
24
24
|
error: StringConstructor;
|
|
25
|
+
mask: (StringConstructor | ObjectConstructor)[];
|
|
25
26
|
}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
26
27
|
input: (...args: any[]) => void;
|
|
27
28
|
blur: (...args: any[]) => void;
|
|
@@ -51,6 +52,7 @@ declare const __VLS_export: import("vue").DefineComponent<import("vue").ExtractP
|
|
|
51
52
|
placeholder: StringConstructor;
|
|
52
53
|
labelClasses: StringConstructor;
|
|
53
54
|
error: StringConstructor;
|
|
55
|
+
mask: (StringConstructor | ObjectConstructor)[];
|
|
54
56
|
}>> & Readonly<{
|
|
55
57
|
onInput?: ((...args: any[]) => any) | undefined;
|
|
56
58
|
onBlur?: ((...args: any[]) => any) | undefined;
|
|
@@ -44,6 +44,7 @@
|
|
|
44
44
|
<input
|
|
45
45
|
:id="name"
|
|
46
46
|
:ref="name"
|
|
47
|
+
v-maska="mask"
|
|
47
48
|
class="
|
|
48
49
|
block
|
|
49
50
|
h-12
|
|
@@ -94,6 +95,7 @@
|
|
|
94
95
|
</template>
|
|
95
96
|
|
|
96
97
|
<script setup>
|
|
98
|
+
import { vMaska } from "maska/vue";
|
|
97
99
|
const emit = defineEmits(["update:modelValue", "input", "blur", "focus", "step-up", "step-down"]);
|
|
98
100
|
defineProps({
|
|
99
101
|
name: String,
|
|
@@ -116,7 +118,8 @@ defineProps({
|
|
|
116
118
|
descriptionTop: String,
|
|
117
119
|
placeholder: String,
|
|
118
120
|
labelClasses: String,
|
|
119
|
-
error: String
|
|
121
|
+
error: String,
|
|
122
|
+
mask: [String, Object]
|
|
120
123
|
});
|
|
121
124
|
const stepUp = () => {
|
|
122
125
|
emit("step-up");
|
|
@@ -22,6 +22,7 @@ declare const __VLS_export: import("vue").DefineComponent<import("vue").ExtractP
|
|
|
22
22
|
placeholder: StringConstructor;
|
|
23
23
|
labelClasses: StringConstructor;
|
|
24
24
|
error: StringConstructor;
|
|
25
|
+
mask: (StringConstructor | ObjectConstructor)[];
|
|
25
26
|
}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
26
27
|
input: (...args: any[]) => void;
|
|
27
28
|
blur: (...args: any[]) => void;
|
|
@@ -51,6 +52,7 @@ declare const __VLS_export: import("vue").DefineComponent<import("vue").ExtractP
|
|
|
51
52
|
placeholder: StringConstructor;
|
|
52
53
|
labelClasses: StringConstructor;
|
|
53
54
|
error: StringConstructor;
|
|
55
|
+
mask: (StringConstructor | ObjectConstructor)[];
|
|
54
56
|
}>> & Readonly<{
|
|
55
57
|
onInput?: ((...args: any[]) => any) | undefined;
|
|
56
58
|
onBlur?: ((...args: any[]) => any) | undefined;
|
|
@@ -1,19 +1,24 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
2
|
+
<label
|
|
3
|
+
class="radio group flex flex-col p-4 cursor-pointer bg-white border border-grey-light rounded-lg transition-all"
|
|
4
|
+
:class="{ '!border-green ring-1 ring-green': value === modelValue }"
|
|
5
|
+
:for="id"
|
|
6
|
+
>
|
|
7
|
+
<div class="flex">
|
|
8
|
+
<input
|
|
9
|
+
:id="id"
|
|
10
|
+
:ref="name"
|
|
11
|
+
class="sr-only peer"
|
|
12
|
+
type="radio"
|
|
13
|
+
:name="name"
|
|
14
|
+
:value="value"
|
|
15
|
+
:checked="value === modelValue"
|
|
16
|
+
:disabled="disabled"
|
|
17
|
+
@change="emit('update:modelValue', $event.target.value)"
|
|
18
|
+
@focus="emit('focus', $event)"
|
|
19
|
+
>
|
|
20
|
+
<div
|
|
21
|
+
class="
|
|
17
22
|
radio-icon
|
|
18
23
|
relative
|
|
19
24
|
block
|
|
@@ -44,25 +49,46 @@
|
|
|
44
49
|
peer-checked:after:transition-all
|
|
45
50
|
peer-checked:after:bg-green
|
|
46
51
|
peer-disabled:bg-grey-light
|
|
47
|
-
"
|
|
48
|
-
|
|
49
|
-
<div class="flex flex-col w-full">
|
|
50
|
-
<div class="flex">
|
|
51
|
-
<span class="font-serif text-purple-dark font-bold" :class="{ 'text-grey-dark': disabled }">{{ label }}</span>
|
|
52
|
+
"
|
|
53
|
+
/>
|
|
52
54
|
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
55
|
+
<div class="flex flex-col w-full">
|
|
56
|
+
<div class="flex">
|
|
57
|
+
<span
|
|
58
|
+
class="font-serif text-purple-dark font-bold"
|
|
59
|
+
:class="{ 'text-grey-dark': disabled }"
|
|
60
|
+
>{{ label }}</span>
|
|
59
61
|
|
|
60
|
-
|
|
61
|
-
|
|
62
|
+
<Icon
|
|
63
|
+
v-if="tooltip"
|
|
64
|
+
name="eva:info-outline"
|
|
65
|
+
class="ml-2 cursor-pointer text-grey-dark"
|
|
66
|
+
/>
|
|
62
67
|
</div>
|
|
63
|
-
|
|
64
|
-
<
|
|
65
|
-
|
|
68
|
+
|
|
69
|
+
<p
|
|
70
|
+
v-if="labelSecondary"
|
|
71
|
+
class="text-grey-dark"
|
|
72
|
+
>{{ labelSecondary }}</p>
|
|
73
|
+
|
|
74
|
+
<IndPriceQuote
|
|
75
|
+
v-if="price"
|
|
76
|
+
:price="price"
|
|
77
|
+
:without-symbol="true"
|
|
78
|
+
text-append=" per maand"
|
|
79
|
+
class="font-semibold text-grey-darker"
|
|
80
|
+
/>
|
|
81
|
+
|
|
82
|
+
<IndPill
|
|
83
|
+
v-if="advice"
|
|
84
|
+
class="mt-1 self-start"
|
|
85
|
+
:label="adviceLabel"
|
|
86
|
+
/>
|
|
87
|
+
</div>
|
|
88
|
+
</div>
|
|
89
|
+
|
|
90
|
+
<slot />
|
|
91
|
+
</label>
|
|
66
92
|
</template>
|
|
67
93
|
|
|
68
94
|
<script setup>
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
:label-classes="labelClasses"
|
|
9
9
|
:tooltip="tooltip"
|
|
10
10
|
/>
|
|
11
|
-
|
|
11
|
+
|
|
12
12
|
<div class="relative">
|
|
13
13
|
<Icon
|
|
14
14
|
v-if="leadingIcon"
|
|
@@ -16,23 +16,34 @@
|
|
|
16
16
|
class="absolute ml-3 mt-3"
|
|
17
17
|
/>
|
|
18
18
|
|
|
19
|
-
<Icon
|
|
20
|
-
v-if="trailingIcon"
|
|
21
|
-
:name="trailingIcon"
|
|
19
|
+
<Icon
|
|
20
|
+
v-if="trailingIcon"
|
|
21
|
+
:name="trailingIcon"
|
|
22
22
|
class="absolute right-0 mr-3 mt-3 text-purple"
|
|
23
23
|
/>
|
|
24
24
|
|
|
25
|
-
<div
|
|
26
|
-
|
|
25
|
+
<div
|
|
26
|
+
v-if="steps"
|
|
27
|
+
class="flex gap-2 absolute right-0 mr-3 mt-3"
|
|
28
|
+
>
|
|
29
|
+
<button
|
|
30
|
+
class="text-purple hover:text-purple-dark"
|
|
31
|
+
@click.prevent="stepDown"
|
|
32
|
+
>
|
|
27
33
|
<Icon name="eva:minus-circle-outline" />
|
|
28
34
|
</button>
|
|
29
35
|
|
|
30
|
-
<button
|
|
36
|
+
<button
|
|
37
|
+
class="text-purple hover:text-purple-dark"
|
|
38
|
+
@click.prevent="stepUp"
|
|
39
|
+
>
|
|
31
40
|
<Icon name="eva:plus-circle-outline" />
|
|
32
41
|
</button>
|
|
33
42
|
</div>
|
|
34
43
|
|
|
35
44
|
<textarea
|
|
45
|
+
:id="name"
|
|
46
|
+
:ref="name"
|
|
36
47
|
class="
|
|
37
48
|
block
|
|
38
49
|
min-h-12
|
|
@@ -45,7 +56,7 @@
|
|
|
45
56
|
ease-out
|
|
46
57
|
bg-white
|
|
47
58
|
hover:border-grey-dark
|
|
48
|
-
outline-none
|
|
59
|
+
outline-none
|
|
49
60
|
appearance-none
|
|
50
61
|
disabled:bg-grey-light
|
|
51
62
|
disabled:border-grey
|
|
@@ -53,13 +64,11 @@
|
|
|
53
64
|
"
|
|
54
65
|
:class="{ 'border-red-800': error, 'pl-10': leadingIcon, 'pr-12': trailingIcon, 'pr-20': steps }"
|
|
55
66
|
:type="type"
|
|
56
|
-
:id="name"
|
|
57
67
|
:name="name"
|
|
58
68
|
:value="modelValue"
|
|
59
69
|
:inputmode="inputmode"
|
|
60
70
|
:pattern="pattern"
|
|
61
71
|
:min="min"
|
|
62
|
-
:ref="name"
|
|
63
72
|
:autocomplete="autocomplete"
|
|
64
73
|
:disabled="disabled"
|
|
65
74
|
:placeholder="placeholder"
|
|
@@ -69,8 +78,18 @@
|
|
|
69
78
|
/>
|
|
70
79
|
</div>
|
|
71
80
|
|
|
72
|
-
<div
|
|
73
|
-
|
|
81
|
+
<div
|
|
82
|
+
v-if="error"
|
|
83
|
+
class="mt-1 text-red-800"
|
|
84
|
+
>
|
|
85
|
+
{{ error }}
|
|
86
|
+
</div>
|
|
87
|
+
<div
|
|
88
|
+
v-if="description"
|
|
89
|
+
class="mt-2 text-grey-dark"
|
|
90
|
+
>
|
|
91
|
+
{{ description }}
|
|
92
|
+
</div>
|
|
74
93
|
</div>
|
|
75
94
|
</template>
|
|
76
95
|
|
|
@@ -1,17 +1,30 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
|
|
3
|
-
|
|
2
|
+
<div
|
|
3
|
+
v-if="show"
|
|
4
|
+
class="notification flex gap-2 p-3 border rounded-lg"
|
|
5
|
+
:class="classesBackground"
|
|
6
|
+
>
|
|
7
|
+
<Icon
|
|
8
|
+
v-if="icon"
|
|
9
|
+
:name="icon"
|
|
10
|
+
:class="classesIcon"
|
|
11
|
+
/>
|
|
4
12
|
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
</div>
|
|
8
|
-
|
|
9
|
-
<Icon v-if="closeButton" name="eva:close-outline" class="text-grey-dark cursor-pointer" @click.prevent="close" />
|
|
13
|
+
<div class="w-full">
|
|
14
|
+
<slot />
|
|
10
15
|
</div>
|
|
16
|
+
|
|
17
|
+
<Icon
|
|
18
|
+
v-if="closeButton"
|
|
19
|
+
name="eva:close-outline"
|
|
20
|
+
class="text-grey-dark cursor-pointer"
|
|
21
|
+
@click.prevent="close"
|
|
22
|
+
/>
|
|
23
|
+
</div>
|
|
11
24
|
</template>
|
|
12
25
|
|
|
13
26
|
<script setup>
|
|
14
|
-
import { computed } from "vue";
|
|
27
|
+
import { computed, ref } from "vue";
|
|
15
28
|
const props = defineProps({
|
|
16
29
|
tone: String,
|
|
17
30
|
icon: String,
|
|
@@ -23,16 +36,16 @@ const props = defineProps({
|
|
|
23
36
|
const show = ref(true);
|
|
24
37
|
const classesBackground = computed(() => {
|
|
25
38
|
return {
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
39
|
+
info: "bg-blue-light text-blue-darkest border-blue-400",
|
|
40
|
+
warning: "bg-yellow-100 text-yellow-darkest border-yellow-400",
|
|
41
|
+
error: "bg-red-100 text-red-darkest border-red-400"
|
|
29
42
|
}[props.tone];
|
|
30
43
|
});
|
|
31
44
|
const classesIcon = computed(() => {
|
|
32
45
|
return {
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
46
|
+
info: "text-blue-darkest",
|
|
47
|
+
error: "text-red-darkest",
|
|
48
|
+
warning: "text-yellow-darkest"
|
|
36
49
|
}[props.tone];
|
|
37
50
|
});
|
|
38
51
|
const close = () => {
|
|
@@ -1,28 +1,48 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
2
|
+
<div class="flex items-start justify-end">
|
|
3
|
+
<div class="text-right">
|
|
4
|
+
<div
|
|
5
|
+
v-if="period"
|
|
6
|
+
class="text-text-default"
|
|
7
|
+
>
|
|
8
|
+
{{ period }}
|
|
9
|
+
</div>
|
|
7
10
|
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
11
|
+
<div
|
|
12
|
+
v-if="premium"
|
|
13
|
+
class="flex items-start justify-end font-semibold"
|
|
14
|
+
>
|
|
15
|
+
<div :class="{ 'text-xl leading-6': size === 'small', 'text-[32px] leading-none': size === 'medium', 'text-[48px] leading-none': size === 'large' }">
|
|
16
|
+
{{ premium.euro }}
|
|
17
|
+
</div>
|
|
18
|
+
<div :class="{ 'text-xs leading-5': size === 'small', 'text-[16px] leading-none mt-1': size === 'medium', 'text-[24px] leading-none mt-1': size === 'large' }">
|
|
19
|
+
,{{ formatCent(premium.cent) }}
|
|
20
|
+
</div>
|
|
21
|
+
</div>
|
|
12
22
|
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
23
|
+
<div
|
|
24
|
+
v-if="closable === false"
|
|
25
|
+
class="text-grey-dark"
|
|
26
|
+
>
|
|
27
|
+
Niet bij ons te koop
|
|
28
|
+
</div>
|
|
16
29
|
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
30
|
+
<div v-if="discount">
|
|
31
|
+
<div
|
|
32
|
+
class="text-purple underline underline-offset-4 decoration-1 decoration-dotted cursor-pointer"
|
|
33
|
+
@click.prevent="emit('discount')"
|
|
34
|
+
>
|
|
35
|
+
€ {{ discount.euro }},{{ formatCent(discount.cent) }} korting
|
|
36
|
+
</div>
|
|
37
|
+
</div>
|
|
20
38
|
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
39
|
+
<div v-if="savings">
|
|
40
|
+
<div class="text-green-dark">
|
|
41
|
+
Bespaar € {{ savings.euro }},{{ formatCent(savings.cent) }}/jr
|
|
24
42
|
</div>
|
|
43
|
+
</div>
|
|
25
44
|
</div>
|
|
45
|
+
</div>
|
|
26
46
|
</template>
|
|
27
47
|
|
|
28
48
|
<script setup>
|
|
@@ -1,5 +1,8 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<Transition
|
|
2
|
+
<Transition
|
|
3
|
+
name="price-fade"
|
|
4
|
+
mode="out-in"
|
|
5
|
+
>
|
|
3
6
|
<div :key="price">
|
|
4
7
|
{{ textPrepend }}
|
|
5
8
|
|
|
@@ -16,7 +19,7 @@
|
|
|
16
19
|
</template>
|
|
17
20
|
|
|
18
21
|
<script setup>
|
|
19
|
-
|
|
22
|
+
defineProps({
|
|
20
23
|
price: {
|
|
21
24
|
type: Number,
|
|
22
25
|
required: true
|
|
@@ -1,11 +1,15 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
2
|
+
<li class="flex gap-2">
|
|
3
|
+
<Icon
|
|
4
|
+
v-if="icon"
|
|
5
|
+
:name="icon"
|
|
6
|
+
:class="[iconColor, iconClass]"
|
|
7
|
+
/>
|
|
8
|
+
|
|
9
|
+
{{ label }}
|
|
10
|
+
|
|
11
|
+
<slot />
|
|
12
|
+
</li>
|
|
9
13
|
</template>
|
|
10
14
|
|
|
11
15
|
<script setup>
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "independer-design-system",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.4.0",
|
|
4
4
|
"description": "Vue 3 component library for the Independer Design System (DS2)",
|
|
5
5
|
"repository": "arjanvanrees/independer-design-system",
|
|
6
6
|
"license": "MIT",
|
|
@@ -42,6 +42,7 @@
|
|
|
42
42
|
"@nuxt/kit": "^4.3.1",
|
|
43
43
|
"@nuxtjs/tailwindcss": "^6.14.0",
|
|
44
44
|
"@tailwindcss/vite": "^4.2.1",
|
|
45
|
+
"maska": "^3.2.0",
|
|
45
46
|
"tailwindcss": "^4.2.1",
|
|
46
47
|
"vue-collapsed": "^1.3.5"
|
|
47
48
|
},
|