@ouestfrance/sipa-bms-ui 8.38.2 → 8.39.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/models/menu.model.d.ts +1 -0
- package/dist/sipa-bms-ui.css +19 -17
- package/dist/sipa-bms-ui.es.js +46 -29
- package/dist/sipa-bms-ui.es.js.map +1 -1
- package/dist/sipa-bms-ui.umd.js +46 -29
- package/dist/sipa-bms-ui.umd.js.map +1 -1
- package/package.json +1 -1
- package/src/components/navigation/BmsMenuNav.spec.ts +36 -0
- package/src/components/navigation/BmsMenuNav.stories.js +24 -0
- package/src/components/navigation/BmsMenuNav.vue +23 -5
- package/src/models/menu.model.ts +1 -0
package/dist/sipa-bms-ui.css
CHANGED
|
@@ -2234,7 +2234,7 @@ a svg[data-v-02d02028] {
|
|
|
2234
2234
|
display: flex;
|
|
2235
2235
|
align-items: center;
|
|
2236
2236
|
gap: 4px;
|
|
2237
|
-
}nav[data-v-
|
|
2237
|
+
}nav[data-v-43dce565] {
|
|
2238
2238
|
display: flex;
|
|
2239
2239
|
flex-direction: column;
|
|
2240
2240
|
flex: 1 1 auto;
|
|
@@ -2242,61 +2242,63 @@ a svg[data-v-02d02028] {
|
|
|
2242
2242
|
padding: 6rem 0 2rem;
|
|
2243
2243
|
background-color: var(--bms-white);
|
|
2244
2244
|
}
|
|
2245
|
-
nav ul[data-v-
|
|
2245
|
+
nav ul[data-v-43dce565] {
|
|
2246
2246
|
margin: 0;
|
|
2247
2247
|
padding: 0;
|
|
2248
2248
|
}
|
|
2249
|
-
nav ul li[data-v-
|
|
2249
|
+
nav ul li[data-v-43dce565] {
|
|
2250
2250
|
display: flex;
|
|
2251
2251
|
align-items: center;
|
|
2252
2252
|
list-style-type: none;
|
|
2253
|
-
cursor: pointer;
|
|
2254
2253
|
width: 100%;
|
|
2255
2254
|
}
|
|
2256
|
-
nav ul li .parent-container[data-v-
|
|
2255
|
+
nav ul li .parent-container[data-v-43dce565] {
|
|
2257
2256
|
width: 100%;
|
|
2258
2257
|
}
|
|
2259
|
-
nav ul li .parent-container .parent-item[data-v-
|
|
2258
|
+
nav ul li .parent-container .parent-item[data-v-43dce565] {
|
|
2260
2259
|
display: flex;
|
|
2261
2260
|
justify-content: space-between;
|
|
2262
2261
|
align-items: center;
|
|
2263
2262
|
color: var(--bms-grey-75);
|
|
2264
2263
|
padding: 14px 8px;
|
|
2265
2264
|
}
|
|
2266
|
-
nav ul li .parent-container .parent-item[data-v-
|
|
2265
|
+
nav ul li .parent-container .parent-item[data-v-43dce565] .internal-link {
|
|
2267
2266
|
color: inherit;
|
|
2268
2267
|
}
|
|
2269
|
-
nav ul li .parent-container .parent-item__custom-icon[data-v-
|
|
2268
|
+
nav ul li .parent-container .parent-item__custom-icon[data-v-43dce565] {
|
|
2270
2269
|
width: 1em;
|
|
2271
2270
|
height: 1em;
|
|
2272
2271
|
}
|
|
2273
|
-
nav ul li .parent-container .parent-item[data-v-
|
|
2272
|
+
nav ul li .parent-container .parent-item.is-clickable[data-v-43dce565] {
|
|
2273
|
+
cursor: pointer;
|
|
2274
|
+
}
|
|
2275
|
+
nav ul li .parent-container .parent-item.is-clickable[data-v-43dce565]:hover {
|
|
2274
2276
|
color: var(--bms-main-100);
|
|
2275
2277
|
text-decoration: none;
|
|
2276
2278
|
}
|
|
2277
|
-
nav ul li .parent-container .parent-item .parent-label[data-v-
|
|
2279
|
+
nav ul li .parent-container .parent-item .parent-label[data-v-43dce565] {
|
|
2278
2280
|
line-height: 16px;
|
|
2279
2281
|
font-size: 14px;
|
|
2280
2282
|
text-transform: uppercase;
|
|
2281
2283
|
}
|
|
2282
|
-
nav .additional[data-v-
|
|
2284
|
+
nav .additional[data-v-43dce565] {
|
|
2283
2285
|
display: flex;
|
|
2284
2286
|
flex-direction: column;
|
|
2285
2287
|
flex-grow: 1;
|
|
2286
2288
|
}
|
|
2287
|
-
.open-enter-active[data-v-
|
|
2289
|
+
.open-enter-active[data-v-43dce565] {
|
|
2288
2290
|
transition: all 0.7s ease;
|
|
2289
2291
|
}
|
|
2290
|
-
.open-leave-active[data-v-
|
|
2292
|
+
.open-leave-active[data-v-43dce565] {
|
|
2291
2293
|
transition: all 0.25s linear;
|
|
2292
2294
|
}
|
|
2293
|
-
.open-enter-from[data-v-
|
|
2294
|
-
.open-leave-to[data-v-
|
|
2295
|
+
.open-enter-from[data-v-43dce565],
|
|
2296
|
+
.open-leave-to[data-v-43dce565] {
|
|
2295
2297
|
max-height: 0;
|
|
2296
2298
|
opacity: 0;
|
|
2297
2299
|
}
|
|
2298
|
-
.open-enter-to[data-v-
|
|
2299
|
-
.open-leave-from[data-v-
|
|
2300
|
+
.open-enter-to[data-v-43dce565],
|
|
2301
|
+
.open-leave-from[data-v-43dce565] {
|
|
2300
2302
|
max-height: 500px;
|
|
2301
2303
|
opacity: 1;
|
|
2302
2304
|
}.menu__container[data-v-83979eb0] {
|
package/dist/sipa-bms-ui.es.js
CHANGED
|
@@ -88610,8 +88610,8 @@ const _hoisted_5$7 = {
|
|
|
88610
88610
|
key: 3,
|
|
88611
88611
|
class: "field__input-icon field__input-icon--end"
|
|
88612
88612
|
};
|
|
88613
|
-
const _hoisted_6$
|
|
88614
|
-
const _hoisted_7$
|
|
88613
|
+
const _hoisted_6$7 = { class: "icon-container" };
|
|
88614
|
+
const _hoisted_7$7 = { class: "combobox-option__check" };
|
|
88615
88615
|
const SELECT_ALL_VALUE = "__bms_select_all__";
|
|
88616
88616
|
const _sfc_main$Q = /* @__PURE__ */ defineComponent({
|
|
88617
88617
|
__name: "BmsCombobox",
|
|
@@ -88954,7 +88954,7 @@ const _sfc_main$Q = /* @__PURE__ */ defineComponent({
|
|
|
88954
88954
|
renderSlot(_ctx.$slots, "icon-end", {}, void 0, true)
|
|
88955
88955
|
])) : createCommentVNode("", true)
|
|
88956
88956
|
], true),
|
|
88957
|
-
createElementVNode("span", _hoisted_6$
|
|
88957
|
+
createElementVNode("span", _hoisted_6$7, [
|
|
88958
88958
|
canClear.value ? (openBlock(), createBlock(unref(X), {
|
|
88959
88959
|
key: 0,
|
|
88960
88960
|
class: "combobox-clear-icon icon-button",
|
|
@@ -88992,7 +88992,7 @@ const _sfc_main$Q = /* @__PURE__ */ defineComponent({
|
|
|
88992
88992
|
"combobox-option--select-all": option.value === SELECT_ALL_VALUE
|
|
88993
88993
|
}])
|
|
88994
88994
|
}, [
|
|
88995
|
-
createElementVNode("div", _hoisted_7$
|
|
88995
|
+
createElementVNode("div", _hoisted_7$7, [
|
|
88996
88996
|
isOptionSelected(option) ? (openBlock(), createBlock(unref(Check), {
|
|
88997
88997
|
key: 0,
|
|
88998
88998
|
size: 12
|
|
@@ -92524,11 +92524,11 @@ const _hoisted_5$6 = {
|
|
|
92524
92524
|
key: 1,
|
|
92525
92525
|
class: "bms-header__title__after-title"
|
|
92526
92526
|
};
|
|
92527
|
-
const _hoisted_6$
|
|
92527
|
+
const _hoisted_6$6 = {
|
|
92528
92528
|
key: 2,
|
|
92529
92529
|
class: "bms-header__title__actions"
|
|
92530
92530
|
};
|
|
92531
|
-
const _hoisted_7$
|
|
92531
|
+
const _hoisted_7$6 = {
|
|
92532
92532
|
key: 0,
|
|
92533
92533
|
class: "bms-header__subtitle"
|
|
92534
92534
|
};
|
|
@@ -92562,11 +92562,11 @@ const _sfc_main$F = /* @__PURE__ */ defineComponent({
|
|
|
92562
92562
|
_ctx.$slots.afterTitle ? (openBlock(), createElementBlock("span", _hoisted_5$6, [
|
|
92563
92563
|
renderSlot(_ctx.$slots, "afterTitle", {}, void 0, true)
|
|
92564
92564
|
])) : createCommentVNode("", true),
|
|
92565
|
-
_ctx.$slots.actions ? (openBlock(), createElementBlock("span", _hoisted_6$
|
|
92565
|
+
_ctx.$slots.actions ? (openBlock(), createElementBlock("span", _hoisted_6$6, [
|
|
92566
92566
|
renderSlot(_ctx.$slots, "actions", {}, void 0, true)
|
|
92567
92567
|
])) : createCommentVNode("", true)
|
|
92568
92568
|
]),
|
|
92569
|
-
_ctx.$slots.subtitle ? (openBlock(), createElementBlock("span", _hoisted_7$
|
|
92569
|
+
_ctx.$slots.subtitle ? (openBlock(), createElementBlock("span", _hoisted_7$6, [
|
|
92570
92570
|
renderSlot(_ctx.$slots, "subtitle", {}, void 0, true)
|
|
92571
92571
|
])) : createCommentVNode("", true)
|
|
92572
92572
|
]);
|
|
@@ -92601,8 +92601,8 @@ const _hoisted_2$l = { class: "ui-modal__header" };
|
|
|
92601
92601
|
const _hoisted_3$c = { class: "ui-modal__header-inner" };
|
|
92602
92602
|
const _hoisted_4$7 = { class: "ui-modal__title" };
|
|
92603
92603
|
const _hoisted_5$5 = { class: "ui-modal__content" };
|
|
92604
|
-
const _hoisted_6$
|
|
92605
|
-
const _hoisted_7$
|
|
92604
|
+
const _hoisted_6$5 = { class: "ui-modal__footer" };
|
|
92605
|
+
const _hoisted_7$5 = { class: "ui-modal__buttons" };
|
|
92606
92606
|
const _hoisted_8$3 = {
|
|
92607
92607
|
key: 0,
|
|
92608
92608
|
class: "ui-modal__loader"
|
|
@@ -92764,11 +92764,11 @@ const _sfc_main$D = /* @__PURE__ */ defineComponent({
|
|
|
92764
92764
|
modalData: props.modelValue
|
|
92765
92765
|
}, void 0, true)
|
|
92766
92766
|
]),
|
|
92767
|
-
createElementVNode("footer", _hoisted_6$
|
|
92767
|
+
createElementVNode("footer", _hoisted_6$5, [
|
|
92768
92768
|
renderSlot(_ctx.$slots, "footer", {
|
|
92769
92769
|
modalData: props.modelValue
|
|
92770
92770
|
}, () => [
|
|
92771
|
-
createElementVNode("div", _hoisted_7$
|
|
92771
|
+
createElementVNode("div", _hoisted_7$5, [
|
|
92772
92772
|
renderSlot(_ctx.$slots, "buttons", {
|
|
92773
92773
|
close: dismissModal,
|
|
92774
92774
|
modalData: props.modelValue
|
|
@@ -93089,11 +93089,11 @@ const _hoisted_2$i = { class: "stepper-header" };
|
|
|
93089
93089
|
const _hoisted_3$a = ["onClick"];
|
|
93090
93090
|
const _hoisted_4$6 = { key: 1 };
|
|
93091
93091
|
const _hoisted_5$4 = ["onClick"];
|
|
93092
|
-
const _hoisted_6$
|
|
93092
|
+
const _hoisted_6$4 = {
|
|
93093
93093
|
key: 0,
|
|
93094
93094
|
class: "stepper-header--separator"
|
|
93095
93095
|
};
|
|
93096
|
-
const _hoisted_7$
|
|
93096
|
+
const _hoisted_7$4 = { class: "stepper-body" };
|
|
93097
93097
|
const _sfc_main$z = /* @__PURE__ */ defineComponent({
|
|
93098
93098
|
__name: "BmsStepper",
|
|
93099
93099
|
props: {
|
|
@@ -93156,11 +93156,11 @@ const _sfc_main$z = /* @__PURE__ */ defineComponent({
|
|
|
93156
93156
|
createElementVNode("div", {
|
|
93157
93157
|
onClick: ($event) => onStepClick(index)
|
|
93158
93158
|
}, toDisplayString(step.stepLabel), 9, _hoisted_5$4),
|
|
93159
|
-
index < steps.value.length - 1 ? (openBlock(), createElementBlock("hr", _hoisted_6$
|
|
93159
|
+
index < steps.value.length - 1 ? (openBlock(), createElementBlock("hr", _hoisted_6$4)) : createCommentVNode("", true)
|
|
93160
93160
|
], 2);
|
|
93161
93161
|
}), 128))
|
|
93162
93162
|
]),
|
|
93163
|
-
createElementVNode("div", _hoisted_7$
|
|
93163
|
+
createElementVNode("div", _hoisted_7$4, [
|
|
93164
93164
|
currentStepObject.value ? (openBlock(), createBlock(resolveDynamicComponent(currentStepObject.value?.stepNode), { key: __props.currentStep })) : createCommentVNode("", true)
|
|
93165
93165
|
])
|
|
93166
93166
|
]);
|
|
@@ -93387,7 +93387,12 @@ const _hoisted_1$p = {
|
|
|
93387
93387
|
const _hoisted_2$g = { class: "parent-label" };
|
|
93388
93388
|
const _hoisted_3$9 = ["onClick"];
|
|
93389
93389
|
const _hoisted_4$5 = { class: "parent-label" };
|
|
93390
|
-
const _hoisted_5$3 = {
|
|
93390
|
+
const _hoisted_5$3 = {
|
|
93391
|
+
key: 1,
|
|
93392
|
+
class: "parent-item"
|
|
93393
|
+
};
|
|
93394
|
+
const _hoisted_6$3 = { class: "parent-label" };
|
|
93395
|
+
const _hoisted_7$3 = { class: "additional" };
|
|
93391
93396
|
const _sfc_main$u = /* @__PURE__ */ defineComponent({
|
|
93392
93397
|
__name: "BmsMenuNav",
|
|
93393
93398
|
props: {
|
|
@@ -93401,6 +93406,7 @@ const _sfc_main$u = /* @__PURE__ */ defineComponent({
|
|
|
93401
93406
|
const hasSubItems = (item) => {
|
|
93402
93407
|
return item.hasOwnProperty("items");
|
|
93403
93408
|
};
|
|
93409
|
+
const isCollapsible = (item) => item.collapsible !== false;
|
|
93404
93410
|
const currentItems = ref([]);
|
|
93405
93411
|
const isLinkRecognized = (link) => {
|
|
93406
93412
|
if (link.name) {
|
|
@@ -93426,6 +93432,10 @@ const _sfc_main$u = /* @__PURE__ */ defineComponent({
|
|
|
93426
93432
|
return item;
|
|
93427
93433
|
}
|
|
93428
93434
|
const parentItem = item;
|
|
93435
|
+
if (!isCollapsible(parentItem)) {
|
|
93436
|
+
parentItem.open = true;
|
|
93437
|
+
return parentItem;
|
|
93438
|
+
}
|
|
93429
93439
|
if (parentItem.open) {
|
|
93430
93440
|
return parentItem;
|
|
93431
93441
|
}
|
|
@@ -93454,7 +93464,7 @@ const _sfc_main$u = /* @__PURE__ */ defineComponent({
|
|
|
93454
93464
|
item.link ? (openBlock(), createBlock(_sfc_main$1w, {
|
|
93455
93465
|
key: 0,
|
|
93456
93466
|
to: item.link,
|
|
93457
|
-
class: normalizeClass(`parent-item ${isItemActive(item) ? "active" : ""}`)
|
|
93467
|
+
class: normalizeClass(`parent-item is-clickable ${isItemActive(item) ? "active" : ""}`)
|
|
93458
93468
|
}, {
|
|
93459
93469
|
default: withCtx(() => [
|
|
93460
93470
|
createElementVNode("span", _hoisted_2$g, toDisplayString(item.label), 1),
|
|
@@ -93464,14 +93474,18 @@ const _sfc_main$u = /* @__PURE__ */ defineComponent({
|
|
|
93464
93474
|
})) : createCommentVNode("", true)
|
|
93465
93475
|
]),
|
|
93466
93476
|
_: 2
|
|
93467
|
-
}, 1032, ["to", "class"])) : (openBlock(), createElementBlock(
|
|
93468
|
-
|
|
93469
|
-
|
|
93470
|
-
|
|
93471
|
-
|
|
93472
|
-
|
|
93473
|
-
|
|
93474
|
-
|
|
93477
|
+
}, 1032, ["to", "class"])) : (openBlock(), createElementBlock(Fragment, { key: 1 }, [
|
|
93478
|
+
isCollapsible(item) ? (openBlock(), createElementBlock("div", {
|
|
93479
|
+
key: 0,
|
|
93480
|
+
class: "parent-item is-clickable",
|
|
93481
|
+
onClick: ($event) => toggleParentItem(item)
|
|
93482
|
+
}, [
|
|
93483
|
+
createElementVNode("span", _hoisted_4$5, toDisplayString(item.label), 1),
|
|
93484
|
+
!item.open ? (openBlock(), createBlock(unref(ChevronDown), { key: 0 })) : (openBlock(), createBlock(unref(ChevronUp), { key: 1 }))
|
|
93485
|
+
], 8, _hoisted_3$9)) : (openBlock(), createElementBlock("div", _hoisted_5$3, [
|
|
93486
|
+
createElementVNode("span", _hoisted_6$3, toDisplayString(item.label), 1)
|
|
93487
|
+
]))
|
|
93488
|
+
], 64)),
|
|
93475
93489
|
createVNode(Transition, { name: "open" }, {
|
|
93476
93490
|
default: withCtx(() => [
|
|
93477
93491
|
withDirectives(createElementVNode("ul", null, [
|
|
@@ -93492,7 +93506,10 @@ const _sfc_main$u = /* @__PURE__ */ defineComponent({
|
|
|
93492
93506
|
]);
|
|
93493
93507
|
}), 128))
|
|
93494
93508
|
], 512), [
|
|
93495
|
-
[
|
|
93509
|
+
[
|
|
93510
|
+
vShow,
|
|
93511
|
+
!isCollapsible(item) || item.open
|
|
93512
|
+
]
|
|
93496
93513
|
])
|
|
93497
93514
|
]),
|
|
93498
93515
|
_: 2
|
|
@@ -93511,7 +93528,7 @@ const _sfc_main$u = /* @__PURE__ */ defineComponent({
|
|
|
93511
93528
|
]);
|
|
93512
93529
|
}), 128))
|
|
93513
93530
|
]),
|
|
93514
|
-
createElementVNode("div",
|
|
93531
|
+
createElementVNode("div", _hoisted_7$3, [
|
|
93515
93532
|
renderSlot(_ctx.$slots, "additional", { closeMenu }, void 0, true)
|
|
93516
93533
|
])
|
|
93517
93534
|
]);
|
|
@@ -93519,7 +93536,7 @@ const _sfc_main$u = /* @__PURE__ */ defineComponent({
|
|
|
93519
93536
|
}
|
|
93520
93537
|
});
|
|
93521
93538
|
|
|
93522
|
-
const BmsMenuNav = /* @__PURE__ */ _export_sfc(_sfc_main$u, [["__scopeId", "data-v-
|
|
93539
|
+
const BmsMenuNav = /* @__PURE__ */ _export_sfc(_sfc_main$u, [["__scopeId", "data-v-43dce565"]]);
|
|
93523
93540
|
|
|
93524
93541
|
const _hoisted_1$o = { class: "menu__container" };
|
|
93525
93542
|
const _hoisted_2$f = { class: "menu__top" };
|