@avenirs-esr/avenirs-dsav 0.1.53 → 0.1.54
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/avenirs-dsav.css +3 -1
- package/dist/components/badges/AvBadge/AvBadge.stub.d.ts +29 -17
- package/dist/components/badges/AvTag/AvTag.stories.d.ts +50 -0
- package/dist/components/badges/AvTag/AvTag.stub.d.ts +23 -0
- package/dist/components/badges/AvTag/AvTag.test.d.ts +1 -0
- package/dist/components/badges/AvTag/AvTag.vue.d.ts +216 -0
- package/dist/components/badges/index.d.ts +2 -2
- package/dist/components/base/AvVIcon/AvVIcon.stub.d.ts +9 -5
- package/dist/components/base/index.d.ts +0 -1
- package/dist/components/header/index.d.ts +1 -1
- package/dist/components/interaction/buttons/AvButton/AvButton.stub.d.ts +15 -6
- package/dist/components/interaction/buttons/AvCancelConfirmButtons/AvCancelConfirmButtons.stub.d.ts +22 -6
- package/dist/components/interaction/buttons/index.d.ts +0 -1
- package/dist/components/interaction/lists/AvList/AvList.stub.d.ts +5 -5
- package/dist/components/interaction/lists/AvListItem/AvListItem.stub.d.ts +19 -6
- package/dist/components/interaction/lists/index.d.ts +0 -2
- package/dist/components/interaction/pickers/AvTagPicker/AvTagPicker.stub.d.ts +11 -5
- package/dist/components/interaction/pickers/index.d.ts +0 -1
- package/dist/components/interaction/selects/AvAutocomplete/AvAutocomplete.stub.d.ts +28 -6
- package/dist/components/interaction/selects/AvSelect/AvSelect.stub.d.ts +15 -11
- package/dist/components/interaction/selects/index.d.ts +1 -3
- package/dist/components/interaction/toggles/AvToggle/AvToggle.stub.d.ts +19 -0
- package/dist/components/navigation/AvBreadcrumb/AvBreadcrumb.stories.d.ts +46 -0
- package/dist/components/navigation/AvBreadcrumb/AvBreadcrumb.stub.d.ts +9 -0
- package/dist/components/navigation/AvBreadcrumb/AvBreadcrumb.test.d.ts +1 -0
- package/dist/components/navigation/AvBreadcrumb/AvBreadcrumb.vue.d.ts +24 -0
- package/dist/components/navigation/AvSideNavigation/AvSideNavigation.stub.d.ts +16 -11
- package/dist/components/navigation/AvStepper/AvStepper.stub.d.ts +19 -14
- package/dist/components/navigation/index.d.ts +1 -2
- package/dist/components/overlay/drawers/AvDrawer/AvDrawer.stub.d.ts +11 -6
- package/dist/components/overlay/index.d.ts +0 -1
- package/dist/index.cjs.js +19 -0
- package/dist/index.d.ts +1 -1
- package/dist/index.es.js +9007 -0
- package/dist/test-utils.cjs.js +114 -0
- package/dist/test-utils.es.js +286 -0
- package/dist/tests/index.d.ts +17 -1
- package/dist/tests/stubs.d.ts +94 -39
- package/dist/tests/utils.d.ts +2 -3
- package/dist/types/index.d.ts +2 -0
- package/package.json +34 -4
- package/src/styles/main.scss +7 -1
- package/dist/avenirs-dsav.es.js +0 -5245
- package/dist/avenirs-dsav.umd.js +0 -44
- package/src/styles/breakpoints.scss +0 -32
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue");require("@vue/test-utils");const o=e.defineComponent({name:"AvBadge",template:'<div class="av-badge-stub" />',props:{label:String,small:{type:Boolean,default:!1},ellipsis:{type:Boolean,default:!1},color:String,backgroundColor:String,iconPath:String}}),i=e.defineComponent({name:"AvTag",template:'<div class="av-tag-stub" />',props:["label","link","tagName","icon","disabled","small","iconOnly","selectable","selected","value"]}),a=e.defineComponent({name:"AvVIcon",props:["name","color","size"],template:'<div class="av-vicon-stub" />'}),s=e.defineComponent({name:"AvButton",props:["label","variant","type","disabled","isLoading"],emits:["click"],template:`
|
|
2
|
+
<button
|
|
3
|
+
class="av-button-stub"
|
|
4
|
+
:disabled="disabled"
|
|
5
|
+
@click="$emit('click')"
|
|
6
|
+
>
|
|
7
|
+
{{ label }}
|
|
8
|
+
</button>
|
|
9
|
+
`}),l=e.defineComponent({name:"AvCancelConfirmButtons",props:["cancelLabel","cancelIcon","confirmLabel","cancelDisabled","cancelIsLoading","confirmIcon","confirmDisabled","confirmIsLoading"],emits:["cancel","confirm"],template:`
|
|
10
|
+
<div class="av-cancel-confirmation-buttons-stub" >
|
|
11
|
+
<button
|
|
12
|
+
class="cancel"
|
|
13
|
+
@click="$emit('cancel')"
|
|
14
|
+
>
|
|
15
|
+
{{ cancelLabel }}
|
|
16
|
+
</button>
|
|
17
|
+
<button
|
|
18
|
+
class="confirm"
|
|
19
|
+
@click="$emit('confirm')"
|
|
20
|
+
>
|
|
21
|
+
{{ confirmLabel }}
|
|
22
|
+
</button>
|
|
23
|
+
</div>
|
|
24
|
+
`}),c=e.defineComponent({name:"AvList",props:["size"],template:`
|
|
25
|
+
<div class="av-list-stub">
|
|
26
|
+
<slot />
|
|
27
|
+
</div>`}),d=e.defineComponent({name:"AvListItem",props:["clickable","hoverBackgroundColor","selected","icon","iconSize","iconColor","colorOnHover"],emits:["click"],template:`
|
|
28
|
+
<div
|
|
29
|
+
class="av-list-item-stub"
|
|
30
|
+
@click="$emit('click')"
|
|
31
|
+
>
|
|
32
|
+
<slot />
|
|
33
|
+
</div>`}),p=e.defineComponent({name:"AvTagPicker",props:["label","options","selected","handleSelectChange"],template:`
|
|
34
|
+
<div class="av-tag-picker-stub">
|
|
35
|
+
<button
|
|
36
|
+
v-for="option in options"
|
|
37
|
+
:key="option.value"
|
|
38
|
+
:data-testid="'option-' + option.value"
|
|
39
|
+
@click="handleSelectChange(option)"
|
|
40
|
+
>
|
|
41
|
+
{{ option.label }}
|
|
42
|
+
</button>
|
|
43
|
+
</div>
|
|
44
|
+
`}),u=e.defineComponent({name:"AvAutocomplete",props:["modelValue","options","loading","inputOptions","getOptionLabel","getOptionKey","multiSelect","serverSideFiltering","enableLoadMore","maxDropdownHeight"],emits:["update:modelValue","search","clear","loadMore"],template:`
|
|
45
|
+
<div class="av-autocomplete-stub">
|
|
46
|
+
<slot
|
|
47
|
+
name="item"
|
|
48
|
+
v-for="option in options"
|
|
49
|
+
:key="option.id"
|
|
50
|
+
:option="option"
|
|
51
|
+
:is-selected="false"
|
|
52
|
+
:toggle="() => {}"
|
|
53
|
+
/>
|
|
54
|
+
</div>
|
|
55
|
+
`}),r=e.defineComponent({name:"AvSelect",props:{modelValue:[String,Number],options:Array,defaultUnselectedText:String,dense:Boolean},emits:["update:modelValue"],template:`
|
|
56
|
+
<select
|
|
57
|
+
class="av-select-stub"
|
|
58
|
+
:value="modelValue"
|
|
59
|
+
@change="$emit('update:modelValue', $event.target.value)"
|
|
60
|
+
>
|
|
61
|
+
<option
|
|
62
|
+
v-if="defaultUnselectedText !== undefined"
|
|
63
|
+
value=""
|
|
64
|
+
>
|
|
65
|
+
{{ defaultUnselectedText }}
|
|
66
|
+
</option>
|
|
67
|
+
<option
|
|
68
|
+
v-for="option in options"
|
|
69
|
+
:key="option.value"
|
|
70
|
+
:value="option.value"
|
|
71
|
+
>
|
|
72
|
+
{{ option.text }}
|
|
73
|
+
</option>
|
|
74
|
+
</select>
|
|
75
|
+
`}),v=e.defineComponent({name:"AvToggle",props:["id","name","modelValue","description","activeText","inactiveText","disabled"],emits:["update:modelValue"],template:`
|
|
76
|
+
<div class="av-toggle">
|
|
77
|
+
<input
|
|
78
|
+
type="checkbox"
|
|
79
|
+
:id="id"
|
|
80
|
+
:name="name"
|
|
81
|
+
:checked="modelValue"
|
|
82
|
+
@change="$emit('update:modelValue', $event.target.checked)"
|
|
83
|
+
/>
|
|
84
|
+
<span class="description">
|
|
85
|
+
{{ description }}
|
|
86
|
+
</span>
|
|
87
|
+
<span class="active-text">
|
|
88
|
+
{{ activeText }}
|
|
89
|
+
</span>
|
|
90
|
+
<span class="inactive-text">
|
|
91
|
+
{{ inactiveText }}
|
|
92
|
+
</span>
|
|
93
|
+
</div>`}),m=e.defineComponent({name:"AvBreadcrumb",template:'<div class="av-breadcrumb-stub" />',props:["links","navigationLabel","showBreadcrumbLabel"]}),b=e.defineComponent({name:"AvSideNavigation",props:{items:Array,selectedItem:String,isSideMenuCollapsed:Boolean,collapsedWidth:String},emits:["update:selectedItem","update:isSideMenuCollapsed"],template:`
|
|
94
|
+
<div
|
|
95
|
+
class="av-side-navigation-stub"
|
|
96
|
+
@click="$emit('update:isSideMenuCollapsed', !isSideMenuCollapsed)"
|
|
97
|
+
/>
|
|
98
|
+
`}),S=e.defineComponent({name:"AvStepper",props:{steps:{type:Array,required:!0},currentStep:{type:Number,required:!0}},template:`
|
|
99
|
+
<div class="av-stepper-stub">
|
|
100
|
+
<div
|
|
101
|
+
v-for="(step, index) in steps"
|
|
102
|
+
:key="index"
|
|
103
|
+
class="step"
|
|
104
|
+
:class="{ active: index === currentStep }"
|
|
105
|
+
>
|
|
106
|
+
{{ index + 1 }}. {{ step }}
|
|
107
|
+
</div>
|
|
108
|
+
</div>
|
|
109
|
+
`}),g=e.defineComponent({name:"AvDrawer",props:["show","position","width"],emits:["escape-pressed"],template:`
|
|
110
|
+
<div class="av-drawer-stub">
|
|
111
|
+
<slot />
|
|
112
|
+
<slot name="footer" />
|
|
113
|
+
</div>
|
|
114
|
+
`});function A(){return{given(t,n){return describe(`🔵 GIVEN ${t}`,n),this},when(t,n){return describe(`🔶 WHEN ${t}`,n),this},and(t,n){return describe(`➕ AND ${t}`,n),this},then(t,n){return it(`🟩 THEN ${t}`,n),this}}}exports.AvAutocompleteStub=u;exports.AvBadgeStub=o;exports.AvBreadcrumbStub=m;exports.AvButtonStub=s;exports.AvCancelConfirmButtonsStub=l;exports.AvDrawerStub=g;exports.AvListItemStub=d;exports.AvListStub=c;exports.AvSelectStub=r;exports.AvSideNavigationStub=b;exports.AvStepperStub=S;exports.AvTagPickerStub=p;exports.AvTagStub=i;exports.AvToggleStub=v;exports.AvVIconStub=a;exports.BddTest=A;
|
|
@@ -0,0 +1,286 @@
|
|
|
1
|
+
import { defineComponent as e } from "vue";
|
|
2
|
+
import "@vue/test-utils";
|
|
3
|
+
const n = e({
|
|
4
|
+
name: "AvBadge",
|
|
5
|
+
template: '<div class="av-badge-stub" />',
|
|
6
|
+
props: {
|
|
7
|
+
label: String,
|
|
8
|
+
small: {
|
|
9
|
+
type: Boolean,
|
|
10
|
+
default: !1
|
|
11
|
+
},
|
|
12
|
+
ellipsis: {
|
|
13
|
+
type: Boolean,
|
|
14
|
+
default: !1
|
|
15
|
+
},
|
|
16
|
+
color: String,
|
|
17
|
+
backgroundColor: String,
|
|
18
|
+
iconPath: String
|
|
19
|
+
}
|
|
20
|
+
}), s = e({
|
|
21
|
+
name: "AvTag",
|
|
22
|
+
template: '<div class="av-tag-stub" />',
|
|
23
|
+
props: [
|
|
24
|
+
"label",
|
|
25
|
+
"link",
|
|
26
|
+
"tagName",
|
|
27
|
+
"icon",
|
|
28
|
+
"disabled",
|
|
29
|
+
"small",
|
|
30
|
+
"iconOnly",
|
|
31
|
+
"selectable",
|
|
32
|
+
"selected",
|
|
33
|
+
"value"
|
|
34
|
+
]
|
|
35
|
+
}), l = e({
|
|
36
|
+
name: "AvVIcon",
|
|
37
|
+
props: ["name", "color", "size"],
|
|
38
|
+
template: '<div class="av-vicon-stub" />'
|
|
39
|
+
}), c = e({
|
|
40
|
+
name: "AvButton",
|
|
41
|
+
props: ["label", "variant", "type", "disabled", "isLoading"],
|
|
42
|
+
emits: ["click"],
|
|
43
|
+
template: `
|
|
44
|
+
<button
|
|
45
|
+
class="av-button-stub"
|
|
46
|
+
:disabled="disabled"
|
|
47
|
+
@click="$emit('click')"
|
|
48
|
+
>
|
|
49
|
+
{{ label }}
|
|
50
|
+
</button>
|
|
51
|
+
`
|
|
52
|
+
}), d = e({
|
|
53
|
+
name: "AvCancelConfirmButtons",
|
|
54
|
+
props: [
|
|
55
|
+
"cancelLabel",
|
|
56
|
+
"cancelIcon",
|
|
57
|
+
"confirmLabel",
|
|
58
|
+
"cancelDisabled",
|
|
59
|
+
"cancelIsLoading",
|
|
60
|
+
"confirmIcon",
|
|
61
|
+
"confirmDisabled",
|
|
62
|
+
"confirmIsLoading"
|
|
63
|
+
],
|
|
64
|
+
emits: ["cancel", "confirm"],
|
|
65
|
+
template: `
|
|
66
|
+
<div class="av-cancel-confirmation-buttons-stub" >
|
|
67
|
+
<button
|
|
68
|
+
class="cancel"
|
|
69
|
+
@click="$emit('cancel')"
|
|
70
|
+
>
|
|
71
|
+
{{ cancelLabel }}
|
|
72
|
+
</button>
|
|
73
|
+
<button
|
|
74
|
+
class="confirm"
|
|
75
|
+
@click="$emit('confirm')"
|
|
76
|
+
>
|
|
77
|
+
{{ confirmLabel }}
|
|
78
|
+
</button>
|
|
79
|
+
</div>
|
|
80
|
+
`
|
|
81
|
+
}), p = e({
|
|
82
|
+
name: "AvList",
|
|
83
|
+
props: ["size"],
|
|
84
|
+
template: `
|
|
85
|
+
<div class="av-list-stub">
|
|
86
|
+
<slot />
|
|
87
|
+
</div>`
|
|
88
|
+
}), r = e({
|
|
89
|
+
name: "AvListItem",
|
|
90
|
+
props: ["clickable", "hoverBackgroundColor", "selected", "icon", "iconSize", "iconColor", "colorOnHover"],
|
|
91
|
+
emits: ["click"],
|
|
92
|
+
template: `
|
|
93
|
+
<div
|
|
94
|
+
class="av-list-item-stub"
|
|
95
|
+
@click="$emit('click')"
|
|
96
|
+
>
|
|
97
|
+
<slot />
|
|
98
|
+
</div>`
|
|
99
|
+
}), u = e({
|
|
100
|
+
name: "AvTagPicker",
|
|
101
|
+
props: [
|
|
102
|
+
"label",
|
|
103
|
+
"options",
|
|
104
|
+
"selected",
|
|
105
|
+
"handleSelectChange"
|
|
106
|
+
],
|
|
107
|
+
template: `
|
|
108
|
+
<div class="av-tag-picker-stub">
|
|
109
|
+
<button
|
|
110
|
+
v-for="option in options"
|
|
111
|
+
:key="option.value"
|
|
112
|
+
:data-testid="'option-' + option.value"
|
|
113
|
+
@click="handleSelectChange(option)"
|
|
114
|
+
>
|
|
115
|
+
{{ option.label }}
|
|
116
|
+
</button>
|
|
117
|
+
</div>
|
|
118
|
+
`
|
|
119
|
+
}), v = e({
|
|
120
|
+
name: "AvAutocomplete",
|
|
121
|
+
props: [
|
|
122
|
+
"modelValue",
|
|
123
|
+
"options",
|
|
124
|
+
"loading",
|
|
125
|
+
"inputOptions",
|
|
126
|
+
"getOptionLabel",
|
|
127
|
+
"getOptionKey",
|
|
128
|
+
"multiSelect",
|
|
129
|
+
"serverSideFiltering",
|
|
130
|
+
"enableLoadMore",
|
|
131
|
+
"maxDropdownHeight"
|
|
132
|
+
],
|
|
133
|
+
emits: ["update:modelValue", "search", "clear", "loadMore"],
|
|
134
|
+
template: `
|
|
135
|
+
<div class="av-autocomplete-stub">
|
|
136
|
+
<slot
|
|
137
|
+
name="item"
|
|
138
|
+
v-for="option in options"
|
|
139
|
+
:key="option.id"
|
|
140
|
+
:option="option"
|
|
141
|
+
:is-selected="false"
|
|
142
|
+
:toggle="() => {}"
|
|
143
|
+
/>
|
|
144
|
+
</div>
|
|
145
|
+
`
|
|
146
|
+
}), m = e({
|
|
147
|
+
name: "AvSelect",
|
|
148
|
+
props: {
|
|
149
|
+
modelValue: [String, Number],
|
|
150
|
+
options: Array,
|
|
151
|
+
defaultUnselectedText: String,
|
|
152
|
+
dense: Boolean
|
|
153
|
+
},
|
|
154
|
+
emits: ["update:modelValue"],
|
|
155
|
+
template: `
|
|
156
|
+
<select
|
|
157
|
+
class="av-select-stub"
|
|
158
|
+
:value="modelValue"
|
|
159
|
+
@change="$emit('update:modelValue', $event.target.value)"
|
|
160
|
+
>
|
|
161
|
+
<option
|
|
162
|
+
v-if="defaultUnselectedText !== undefined"
|
|
163
|
+
value=""
|
|
164
|
+
>
|
|
165
|
+
{{ defaultUnselectedText }}
|
|
166
|
+
</option>
|
|
167
|
+
<option
|
|
168
|
+
v-for="option in options"
|
|
169
|
+
:key="option.value"
|
|
170
|
+
:value="option.value"
|
|
171
|
+
>
|
|
172
|
+
{{ option.text }}
|
|
173
|
+
</option>
|
|
174
|
+
</select>
|
|
175
|
+
`
|
|
176
|
+
}), b = e({
|
|
177
|
+
name: "AvToggle",
|
|
178
|
+
props: ["id", "name", "modelValue", "description", "activeText", "inactiveText", "disabled"],
|
|
179
|
+
emits: ["update:modelValue"],
|
|
180
|
+
template: `
|
|
181
|
+
<div class="av-toggle">
|
|
182
|
+
<input
|
|
183
|
+
type="checkbox"
|
|
184
|
+
:id="id"
|
|
185
|
+
:name="name"
|
|
186
|
+
:checked="modelValue"
|
|
187
|
+
@change="$emit('update:modelValue', $event.target.checked)"
|
|
188
|
+
/>
|
|
189
|
+
<span class="description">
|
|
190
|
+
{{ description }}
|
|
191
|
+
</span>
|
|
192
|
+
<span class="active-text">
|
|
193
|
+
{{ activeText }}
|
|
194
|
+
</span>
|
|
195
|
+
<span class="inactive-text">
|
|
196
|
+
{{ inactiveText }}
|
|
197
|
+
</span>
|
|
198
|
+
</div>`
|
|
199
|
+
}), g = e({
|
|
200
|
+
name: "AvBreadcrumb",
|
|
201
|
+
template: '<div class="av-breadcrumb-stub" />',
|
|
202
|
+
props: ["links", "navigationLabel", "showBreadcrumbLabel"]
|
|
203
|
+
}), S = e({
|
|
204
|
+
name: "AvSideNavigation",
|
|
205
|
+
props: {
|
|
206
|
+
items: Array,
|
|
207
|
+
selectedItem: String,
|
|
208
|
+
isSideMenuCollapsed: Boolean,
|
|
209
|
+
collapsedWidth: String
|
|
210
|
+
},
|
|
211
|
+
emits: ["update:selectedItem", "update:isSideMenuCollapsed"],
|
|
212
|
+
template: `
|
|
213
|
+
<div
|
|
214
|
+
class="av-side-navigation-stub"
|
|
215
|
+
@click="$emit('update:isSideMenuCollapsed', !isSideMenuCollapsed)"
|
|
216
|
+
/>
|
|
217
|
+
`
|
|
218
|
+
}), A = e({
|
|
219
|
+
name: "AvStepper",
|
|
220
|
+
props: {
|
|
221
|
+
steps: {
|
|
222
|
+
type: Array,
|
|
223
|
+
required: !0
|
|
224
|
+
},
|
|
225
|
+
currentStep: {
|
|
226
|
+
type: Number,
|
|
227
|
+
required: !0
|
|
228
|
+
}
|
|
229
|
+
},
|
|
230
|
+
template: `
|
|
231
|
+
<div class="av-stepper-stub">
|
|
232
|
+
<div
|
|
233
|
+
v-for="(step, index) in steps"
|
|
234
|
+
:key="index"
|
|
235
|
+
class="step"
|
|
236
|
+
:class="{ active: index === currentStep }"
|
|
237
|
+
>
|
|
238
|
+
{{ index + 1 }}. {{ step }}
|
|
239
|
+
</div>
|
|
240
|
+
</div>
|
|
241
|
+
`
|
|
242
|
+
}), f = e({
|
|
243
|
+
name: "AvDrawer",
|
|
244
|
+
props: ["show", "position", "width"],
|
|
245
|
+
emits: ["escape-pressed"],
|
|
246
|
+
template: `
|
|
247
|
+
<div class="av-drawer-stub">
|
|
248
|
+
<slot />
|
|
249
|
+
<slot name="footer" />
|
|
250
|
+
</div>
|
|
251
|
+
`
|
|
252
|
+
});
|
|
253
|
+
function k() {
|
|
254
|
+
return {
|
|
255
|
+
given(t, a) {
|
|
256
|
+
return describe(`🔵 GIVEN ${t}`, a), this;
|
|
257
|
+
},
|
|
258
|
+
when(t, a) {
|
|
259
|
+
return describe(`🔶 WHEN ${t}`, a), this;
|
|
260
|
+
},
|
|
261
|
+
and(t, a) {
|
|
262
|
+
return describe(`➕ AND ${t}`, a), this;
|
|
263
|
+
},
|
|
264
|
+
then(t, a) {
|
|
265
|
+
return it(`🟩 THEN ${t}`, a), this;
|
|
266
|
+
}
|
|
267
|
+
};
|
|
268
|
+
}
|
|
269
|
+
export {
|
|
270
|
+
v as AvAutocompleteStub,
|
|
271
|
+
n as AvBadgeStub,
|
|
272
|
+
g as AvBreadcrumbStub,
|
|
273
|
+
c as AvButtonStub,
|
|
274
|
+
d as AvCancelConfirmButtonsStub,
|
|
275
|
+
f as AvDrawerStub,
|
|
276
|
+
r as AvListItemStub,
|
|
277
|
+
p as AvListStub,
|
|
278
|
+
m as AvSelectStub,
|
|
279
|
+
S as AvSideNavigationStub,
|
|
280
|
+
A as AvStepperStub,
|
|
281
|
+
u as AvTagPickerStub,
|
|
282
|
+
s as AvTagStub,
|
|
283
|
+
b as AvToggleStub,
|
|
284
|
+
l as AvVIconStub,
|
|
285
|
+
k as BddTest
|
|
286
|
+
};
|
package/dist/tests/index.d.ts
CHANGED
|
@@ -1 +1,17 @@
|
|
|
1
|
-
|
|
1
|
+
import { AvBadgeStub } from '@/components/badges/AvBadge/AvBadge.stub';
|
|
2
|
+
import { AvTagStub } from '@/components/badges/AvTag/AvTag.stub';
|
|
3
|
+
import { AvVIconStub } from '@/components/base/AvVIcon/AvVIcon.stub';
|
|
4
|
+
import { AvButtonStub } from '@/components/interaction/buttons/AvButton/AvButton.stub';
|
|
5
|
+
import { AvCancelConfirmButtonsStub } from '@/components/interaction/buttons/AvCancelConfirmButtons/AvCancelConfirmButtons.stub';
|
|
6
|
+
import { AvListStub } from '@/components/interaction/lists/AvList/AvList.stub';
|
|
7
|
+
import { AvListItemStub } from '@/components/interaction/lists/AvListItem/AvListItem.stub';
|
|
8
|
+
import { AvTagPickerStub } from '@/components/interaction/pickers/AvTagPicker/AvTagPicker.stub';
|
|
9
|
+
import { AvAutocompleteStub } from '@/components/interaction/selects/AvAutocomplete/AvAutocomplete.stub';
|
|
10
|
+
import { AvSelectStub } from '@/components/interaction/selects/AvSelect/AvSelect.stub';
|
|
11
|
+
import { AvToggleStub } from '@/components/interaction/toggles/AvToggle/AvToggle.stub';
|
|
12
|
+
import { AvBreadcrumbStub } from '@/components/navigation/AvBreadcrumb/AvBreadcrumb.stub';
|
|
13
|
+
import { AvSideNavigationStub } from '@/components/navigation/AvSideNavigation/AvSideNavigation.stub';
|
|
14
|
+
import { AvStepperStub } from '@/components/navigation/AvStepper/AvStepper.stub';
|
|
15
|
+
import { AvDrawerStub } from '@/components/overlay/drawers/AvDrawer/AvDrawer.stub';
|
|
16
|
+
import { BddTest } from '@/tests/utils';
|
|
17
|
+
export { AvAutocompleteStub, AvBadgeStub, AvBreadcrumbStub, AvButtonStub, AvCancelConfirmButtonsStub, AvDrawerStub, AvListItemStub, AvListStub, AvSelectStub, AvSideNavigationStub, AvStepperStub, AvTagPickerStub, AvTagStub, AvToggleStub, AvVIconStub, BddTest, };
|
package/dist/tests/stubs.d.ts
CHANGED
|
@@ -1,41 +1,96 @@
|
|
|
1
|
-
export declare const DsfrBadgeStub: {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
1
|
+
export declare const DsfrBadgeStub: import("vue").DefineComponent<{
|
|
2
|
+
label?: any;
|
|
3
|
+
small?: any;
|
|
4
|
+
type?: any;
|
|
5
|
+
ellipsis?: any;
|
|
6
|
+
}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{
|
|
7
|
+
label?: any;
|
|
8
|
+
small?: any;
|
|
9
|
+
type?: any;
|
|
10
|
+
ellipsis?: any;
|
|
11
|
+
}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
12
|
+
export declare const DsfrBreadcrumbStub: import("vue").DefineComponent<{
|
|
13
|
+
links?: any;
|
|
14
|
+
navigationLabel?: any;
|
|
15
|
+
showBreadcrumbLabel?: any;
|
|
16
|
+
}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{
|
|
17
|
+
links?: any;
|
|
18
|
+
navigationLabel?: any;
|
|
19
|
+
showBreadcrumbLabel?: any;
|
|
20
|
+
}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
21
|
+
export declare const DsfrModalStub: import("vue").DefineComponent<{
|
|
22
|
+
title?: any;
|
|
23
|
+
opened?: any;
|
|
24
|
+
}, {}, {}, {}, {
|
|
25
|
+
triggerEscape(this: {
|
|
26
|
+
$emit: (event: string, payload?: any) => void;
|
|
27
|
+
}): void;
|
|
28
|
+
}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, "keydown"[], "keydown", import("vue").PublicProps, Readonly<{
|
|
29
|
+
title?: any;
|
|
30
|
+
opened?: any;
|
|
31
|
+
}> & Readonly<{
|
|
32
|
+
onKeydown?: ((...args: any[]) => any) | undefined;
|
|
33
|
+
}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
34
|
+
export declare const DsfrNavigationStub: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
35
|
+
navItems: {
|
|
36
|
+
(arrayLength: number): (import("@gouvminint/vue-dsfr").DsfrNavigationMenuLinkProps | import("@gouvminint/vue-dsfr").DsfrNavigationMenuProps | import("@gouvminint/vue-dsfr").DsfrNavigationMegaMenuProps)[][];
|
|
37
|
+
(...items: (import("@gouvminint/vue-dsfr").DsfrNavigationMenuLinkProps | import("@gouvminint/vue-dsfr").DsfrNavigationMenuProps | import("@gouvminint/vue-dsfr").DsfrNavigationMegaMenuProps)[][]): (import("@gouvminint/vue-dsfr").DsfrNavigationMenuLinkProps | import("@gouvminint/vue-dsfr").DsfrNavigationMenuProps | import("@gouvminint/vue-dsfr").DsfrNavigationMegaMenuProps)[][];
|
|
38
|
+
new (arrayLength: number): (import("@gouvminint/vue-dsfr").DsfrNavigationMenuLinkProps | import("@gouvminint/vue-dsfr").DsfrNavigationMenuProps | import("@gouvminint/vue-dsfr").DsfrNavigationMegaMenuProps)[][];
|
|
39
|
+
new (...items: (import("@gouvminint/vue-dsfr").DsfrNavigationMenuLinkProps | import("@gouvminint/vue-dsfr").DsfrNavigationMenuProps | import("@gouvminint/vue-dsfr").DsfrNavigationMegaMenuProps)[][]): (import("@gouvminint/vue-dsfr").DsfrNavigationMenuLinkProps | import("@gouvminint/vue-dsfr").DsfrNavigationMenuProps | import("@gouvminint/vue-dsfr").DsfrNavigationMegaMenuProps)[][];
|
|
40
|
+
isArray(arg: any): arg is any[];
|
|
41
|
+
readonly prototype: any[];
|
|
42
|
+
from<T>(arrayLike: ArrayLike<T>): T[];
|
|
43
|
+
from<T_1, U>(arrayLike: ArrayLike<T_1>, mapfn: (v: T_1, k: number) => U, thisArg?: any): U[];
|
|
44
|
+
from<T_2>(iterable: Iterable<T_2> | ArrayLike<T_2>): T_2[];
|
|
45
|
+
from<T_3, U_1>(iterable: Iterable<T_3> | ArrayLike<T_3>, mapfn: (v: T_3, k: number) => U_1, thisArg?: any): U_1[];
|
|
46
|
+
of<T_4>(...items: T_4[]): T_4[];
|
|
47
|
+
readonly [Symbol.species]: ArrayConstructor;
|
|
15
48
|
};
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
from<T_3, U_1>(iterable: Iterable<T_3> | ArrayLike<T_3>, mapfn: (v: T_3, k: number) => U_1, thisArg?: any): U_1[];
|
|
31
|
-
of<T_4>(...items: T_4[]): T_4[];
|
|
32
|
-
readonly [Symbol.species]: ArrayConstructor;
|
|
33
|
-
};
|
|
49
|
+
}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
50
|
+
navItems: {
|
|
51
|
+
(arrayLength: number): (import("@gouvminint/vue-dsfr").DsfrNavigationMenuLinkProps | import("@gouvminint/vue-dsfr").DsfrNavigationMenuProps | import("@gouvminint/vue-dsfr").DsfrNavigationMegaMenuProps)[][];
|
|
52
|
+
(...items: (import("@gouvminint/vue-dsfr").DsfrNavigationMenuLinkProps | import("@gouvminint/vue-dsfr").DsfrNavigationMenuProps | import("@gouvminint/vue-dsfr").DsfrNavigationMegaMenuProps)[][]): (import("@gouvminint/vue-dsfr").DsfrNavigationMenuLinkProps | import("@gouvminint/vue-dsfr").DsfrNavigationMenuProps | import("@gouvminint/vue-dsfr").DsfrNavigationMegaMenuProps)[][];
|
|
53
|
+
new (arrayLength: number): (import("@gouvminint/vue-dsfr").DsfrNavigationMenuLinkProps | import("@gouvminint/vue-dsfr").DsfrNavigationMenuProps | import("@gouvminint/vue-dsfr").DsfrNavigationMegaMenuProps)[][];
|
|
54
|
+
new (...items: (import("@gouvminint/vue-dsfr").DsfrNavigationMenuLinkProps | import("@gouvminint/vue-dsfr").DsfrNavigationMenuProps | import("@gouvminint/vue-dsfr").DsfrNavigationMegaMenuProps)[][]): (import("@gouvminint/vue-dsfr").DsfrNavigationMenuLinkProps | import("@gouvminint/vue-dsfr").DsfrNavigationMenuProps | import("@gouvminint/vue-dsfr").DsfrNavigationMegaMenuProps)[][];
|
|
55
|
+
isArray(arg: any): arg is any[];
|
|
56
|
+
readonly prototype: any[];
|
|
57
|
+
from<T>(arrayLike: ArrayLike<T>): T[];
|
|
58
|
+
from<T_1, U>(arrayLike: ArrayLike<T_1>, mapfn: (v: T_1, k: number) => U, thisArg?: any): U[];
|
|
59
|
+
from<T_2>(iterable: Iterable<T_2> | ArrayLike<T_2>): T_2[];
|
|
60
|
+
from<T_3, U_1>(iterable: Iterable<T_3> | ArrayLike<T_3>, mapfn: (v: T_3, k: number) => U_1, thisArg?: any): U_1[];
|
|
61
|
+
of<T_4>(...items: T_4[]): T_4[];
|
|
62
|
+
readonly [Symbol.species]: ArrayConstructor;
|
|
34
63
|
};
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
64
|
+
}>> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
65
|
+
export declare const DsfrTagStub: import("vue").DefineComponent<{
|
|
66
|
+
label?: any;
|
|
67
|
+
link?: any;
|
|
68
|
+
small?: any;
|
|
69
|
+
icon?: any;
|
|
70
|
+
selected?: any;
|
|
71
|
+
disabled?: any;
|
|
72
|
+
iconOnly?: any;
|
|
73
|
+
value?: any;
|
|
74
|
+
tagName?: any;
|
|
75
|
+
selectable?: any;
|
|
76
|
+
}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{
|
|
77
|
+
label?: any;
|
|
78
|
+
link?: any;
|
|
79
|
+
small?: any;
|
|
80
|
+
icon?: any;
|
|
81
|
+
selected?: any;
|
|
82
|
+
disabled?: any;
|
|
83
|
+
iconOnly?: any;
|
|
84
|
+
value?: any;
|
|
85
|
+
tagName?: any;
|
|
86
|
+
selectable?: any;
|
|
87
|
+
}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
88
|
+
export declare const VIconStub: import("vue").DefineComponent<{
|
|
89
|
+
size?: any;
|
|
90
|
+
name?: any;
|
|
91
|
+
color?: any;
|
|
92
|
+
}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{
|
|
93
|
+
size?: any;
|
|
94
|
+
name?: any;
|
|
95
|
+
color?: any;
|
|
96
|
+
}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
package/dist/tests/utils.d.ts
CHANGED
|
@@ -10,7 +10,7 @@ export declare function BddTest(): {
|
|
|
10
10
|
and(description: string, fn: () => void): any;
|
|
11
11
|
then(description: string, fn: () => void): any;
|
|
12
12
|
};
|
|
13
|
-
declare function mountComposable<T>(fn: () => T): {
|
|
13
|
+
export declare function mountComposable<T>(fn: () => T): {
|
|
14
14
|
result: T;
|
|
15
15
|
unmount: () => void;
|
|
16
16
|
};
|
|
@@ -26,5 +26,4 @@ declare function mountComposable<T>(fn: () => T): {
|
|
|
26
26
|
* @param {ComponentMountingOptions<T>} [options] - Additional options for mounting the component.
|
|
27
27
|
* @returns {Promise<VueWrapper<InstanceType<any>>>} the function return any as type because ts type is too complicated.
|
|
28
28
|
*/
|
|
29
|
-
declare function mountWithRouter<T>(component: Component, options?: ComponentMountingOptions<T>): Promise<VueWrapper<InstanceType<any>>>;
|
|
30
|
-
export { mountComposable, mountWithRouter, };
|
|
29
|
+
export declare function mountWithRouter<T>(component: Component, options?: ComponentMountingOptions<T>): Promise<VueWrapper<InstanceType<any>>>;
|
package/package.json
CHANGED
|
@@ -1,11 +1,31 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@avenirs-esr/avenirs-dsav",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.1.
|
|
4
|
+
"version": "0.1.54",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
7
7
|
"url": "https://github.com/avenirs-esr/avenirs-dsav"
|
|
8
8
|
},
|
|
9
|
+
"sideEffects": [
|
|
10
|
+
"*.css",
|
|
11
|
+
"*.scss",
|
|
12
|
+
"*.vue",
|
|
13
|
+
"dist/*.css"
|
|
14
|
+
],
|
|
15
|
+
"exports": {
|
|
16
|
+
".": {
|
|
17
|
+
"types": "./dist/index.d.ts",
|
|
18
|
+
"import": "./dist/index.es.js",
|
|
19
|
+
"require": "./dist/index.cjs.js"
|
|
20
|
+
},
|
|
21
|
+
"./test-utils": {
|
|
22
|
+
"types": "./dist/test-utils.d.ts",
|
|
23
|
+
"import": "./dist/test-utils.es.js",
|
|
24
|
+
"require": "./dist/test-utils.cjs.js"
|
|
25
|
+
},
|
|
26
|
+
"./style.css": "./dist/avenirs-dsav.css",
|
|
27
|
+
"./src/styles/*": "./src/styles/*"
|
|
28
|
+
},
|
|
9
29
|
"main": "dist/avenirs-dsav.umd.js",
|
|
10
30
|
"module": "dist/avenirs-dsav.es.js",
|
|
11
31
|
"types": "dist/index.d.ts",
|
|
@@ -20,7 +40,7 @@
|
|
|
20
40
|
"build-only:development": "vite build -m development",
|
|
21
41
|
"dev": "vite",
|
|
22
42
|
"build": "run-p type-check type-gen \"build-only {@}\" --",
|
|
23
|
-
"build:watch": "run-p type-check:watch \"build-only:watch {@}\" --",
|
|
43
|
+
"build:watch": "npm run build && run-p type-check:watch \"build-only:watch {@}\" --",
|
|
24
44
|
"build:development": "run-p type-check type-gen \"build-only:development {@}\" --",
|
|
25
45
|
"format": "eslint . --fix",
|
|
26
46
|
"lint": "eslint .",
|
|
@@ -50,9 +70,19 @@
|
|
|
50
70
|
"docs:build": "npm run docs:generate && vitepress build docs"
|
|
51
71
|
},
|
|
52
72
|
"peerDependencies": {
|
|
73
|
+
"@vue/test-utils": "^2.0.0",
|
|
74
|
+
"vitest": "^3.0.0",
|
|
53
75
|
"vue": "^3.5.13",
|
|
54
76
|
"vue-router": "^4.4.3"
|
|
55
77
|
},
|
|
78
|
+
"peerDependenciesMeta": {
|
|
79
|
+
"@vue/test-utils": {
|
|
80
|
+
"optional": true
|
|
81
|
+
},
|
|
82
|
+
"vitest": {
|
|
83
|
+
"optional": true
|
|
84
|
+
}
|
|
85
|
+
},
|
|
56
86
|
"dependencies": {
|
|
57
87
|
"@gouvfr/dsfr": "^1.14.0",
|
|
58
88
|
"@gouvminint/vue-dsfr": "^8.4.0",
|
|
@@ -68,7 +98,7 @@
|
|
|
68
98
|
"@chromatic-com/storybook": "^4.1.1",
|
|
69
99
|
"@commitlint/cli": "^19.8.1",
|
|
70
100
|
"@commitlint/config-conventional": "^19.8.1",
|
|
71
|
-
"@playwright/test": "
|
|
101
|
+
"@playwright/test": "1.56.0",
|
|
72
102
|
"@rushstack/eslint-patch": "^1.10.4",
|
|
73
103
|
"@storybook/addon-a11y": "^9.1.6",
|
|
74
104
|
"@storybook/addon-docs": "^9.1.6",
|
|
@@ -96,7 +126,7 @@
|
|
|
96
126
|
"jsdom": "^25.0.0",
|
|
97
127
|
"lint-staged": "^16.1.6",
|
|
98
128
|
"npm-run-all2": "^6.2.2",
|
|
99
|
-
"playwright": "
|
|
129
|
+
"playwright": "1.56.0",
|
|
100
130
|
"rimraf": "^5.0.10",
|
|
101
131
|
"sass-embedded": "^1.92.1",
|
|
102
132
|
"storybook": "^9.1.6",
|