@touchtech/web-navigation-menu 0.0.18-alpha.3 → 0.0.18-alpha.4
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/components/Navigation/NavigationButton.d.ts +2 -1
- package/dist/index.js +5 -5
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +102 -100
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -23,15 +23,15 @@ var Je;
|
|
|
23
23
|
function Ht() {
|
|
24
24
|
if (Je) return Q;
|
|
25
25
|
Je = 1;
|
|
26
|
-
var
|
|
27
|
-
function
|
|
26
|
+
var o = be, s = Symbol.for("react.element"), p = Symbol.for("react.fragment"), d = Object.prototype.hasOwnProperty, f = o.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, c = { key: !0, ref: !0, __self: !0, __source: !0 };
|
|
27
|
+
function b(i, m, x) {
|
|
28
28
|
var g, S = {}, R = null, j = null;
|
|
29
29
|
x !== void 0 && (R = "" + x), m.key !== void 0 && (R = "" + m.key), m.ref !== void 0 && (j = m.ref);
|
|
30
30
|
for (g in m) d.call(m, g) && !c.hasOwnProperty(g) && (S[g] = m[g]);
|
|
31
|
-
if (
|
|
32
|
-
return { $$typeof: s, type:
|
|
31
|
+
if (i && i.defaultProps) for (g in m = i.defaultProps, m) S[g] === void 0 && (S[g] = m[g]);
|
|
32
|
+
return { $$typeof: s, type: i, key: R, ref: j, props: S, _owner: f.current };
|
|
33
33
|
}
|
|
34
|
-
return Q.Fragment = p, Q.jsx =
|
|
34
|
+
return Q.Fragment = p, Q.jsx = b, Q.jsxs = b, Q;
|
|
35
35
|
}
|
|
36
36
|
var ee = {};
|
|
37
37
|
/**
|
|
@@ -46,14 +46,14 @@ var ee = {};
|
|
|
46
46
|
var Ze;
|
|
47
47
|
function $t() {
|
|
48
48
|
return Ze || (Ze = 1, process.env.NODE_ENV !== "production" && function() {
|
|
49
|
-
var
|
|
49
|
+
var o = be, s = Symbol.for("react.element"), p = Symbol.for("react.portal"), d = Symbol.for("react.fragment"), f = Symbol.for("react.strict_mode"), c = Symbol.for("react.profiler"), b = Symbol.for("react.provider"), i = Symbol.for("react.context"), m = Symbol.for("react.forward_ref"), x = Symbol.for("react.suspense"), g = Symbol.for("react.suspense_list"), S = Symbol.for("react.memo"), R = Symbol.for("react.lazy"), j = Symbol.for("react.offscreen"), D = Symbol.iterator, L = "@@iterator";
|
|
50
50
|
function U(e) {
|
|
51
51
|
if (e === null || typeof e != "object")
|
|
52
52
|
return null;
|
|
53
53
|
var t = D && e[D] || e[L];
|
|
54
54
|
return typeof t == "function" ? t : null;
|
|
55
55
|
}
|
|
56
|
-
var C =
|
|
56
|
+
var C = o.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
|
|
57
57
|
function h(e) {
|
|
58
58
|
{
|
|
59
59
|
for (var t = arguments.length, n = new Array(t > 1 ? t - 1 : 0), a = 1; a < t; a++)
|
|
@@ -74,7 +74,7 @@ function $t() {
|
|
|
74
74
|
var Y = !1, J = !1, B = !1, ue = !1, at = !1, Ne;
|
|
75
75
|
Ne = Symbol.for("react.module.reference");
|
|
76
76
|
function st(e) {
|
|
77
|
-
return !!(typeof e == "string" || typeof e == "function" || e === d || e === c || at || e === f || e === x || e === g || ue || e === j || Y || J || B || typeof e == "object" && e !== null && (e.$$typeof === R || e.$$typeof === S || e.$$typeof ===
|
|
77
|
+
return !!(typeof e == "string" || typeof e == "function" || e === d || e === c || at || e === f || e === x || e === g || ue || e === j || Y || J || B || typeof e == "object" && e !== null && (e.$$typeof === R || e.$$typeof === S || e.$$typeof === b || e.$$typeof === i || e.$$typeof === m || // This needs to include all possible module reference object
|
|
78
78
|
// types supported by any Flight configuration anywhere since
|
|
79
79
|
// we don't know which Flight build this will end up being used
|
|
80
80
|
// with.
|
|
@@ -113,10 +113,10 @@ function $t() {
|
|
|
113
113
|
}
|
|
114
114
|
if (typeof e == "object")
|
|
115
115
|
switch (e.$$typeof) {
|
|
116
|
-
case
|
|
116
|
+
case i:
|
|
117
117
|
var t = e;
|
|
118
118
|
return Ce(t) + ".Consumer";
|
|
119
|
-
case
|
|
119
|
+
case b:
|
|
120
120
|
var n = e;
|
|
121
121
|
return Ce(n._context) + ".Provider";
|
|
122
122
|
case m:
|
|
@@ -266,18 +266,18 @@ function $t() {
|
|
|
266
266
|
if (A && a && typeof A.stack == "string") {
|
|
267
267
|
for (var l = A.stack.split(`
|
|
268
268
|
`), N = a.stack.split(`
|
|
269
|
-
`), E = l.length - 1,
|
|
270
|
-
|
|
271
|
-
for (; E >= 1 &&
|
|
272
|
-
if (l[E] !== N[
|
|
273
|
-
if (E !== 1 ||
|
|
269
|
+
`), E = l.length - 1, w = N.length - 1; E >= 1 && w >= 0 && l[E] !== N[w]; )
|
|
270
|
+
w--;
|
|
271
|
+
for (; E >= 1 && w >= 0; E--, w--)
|
|
272
|
+
if (l[E] !== N[w]) {
|
|
273
|
+
if (E !== 1 || w !== 1)
|
|
274
274
|
do
|
|
275
|
-
if (E--,
|
|
275
|
+
if (E--, w--, w < 0 || l[E] !== N[w]) {
|
|
276
276
|
var I = `
|
|
277
277
|
` + l[E].replace(" at new ", " at ");
|
|
278
278
|
return e.displayName && I.includes("<anonymous>") && (I = I.replace("<anonymous>", e.displayName)), typeof e == "function" && se.set(e, I), I;
|
|
279
279
|
}
|
|
280
|
-
while (E >= 1 &&
|
|
280
|
+
while (E >= 1 && w >= 0);
|
|
281
281
|
break;
|
|
282
282
|
}
|
|
283
283
|
}
|
|
@@ -462,8 +462,8 @@ function $t() {
|
|
|
462
462
|
u[_] === void 0 && (u[_] = E[_]);
|
|
463
463
|
}
|
|
464
464
|
if (l || N) {
|
|
465
|
-
var
|
|
466
|
-
l && wt(u,
|
|
465
|
+
var w = typeof e == "function" ? e.displayName || e.name || "Unknown" : e;
|
|
466
|
+
l && wt(u, w), N && bt(u, w);
|
|
467
467
|
}
|
|
468
468
|
return Tt(e, l, N, v, a, He.current, u);
|
|
469
469
|
}
|
|
@@ -589,9 +589,9 @@ Check the top-level render call using <` + n + ">.");
|
|
|
589
589
|
var E;
|
|
590
590
|
e === null ? E = "null" : ve(e) ? E = "array" : e !== void 0 && e.$$typeof === s ? (E = "<" + (H(e.type) || "Unknown") + " />", l = " Did you accidentally export a JSX literal instead of a component?") : E = typeof e, h("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", E, l);
|
|
591
591
|
}
|
|
592
|
-
var
|
|
593
|
-
if (
|
|
594
|
-
return
|
|
592
|
+
var w = St(e, t, n, v, _);
|
|
593
|
+
if (w == null)
|
|
594
|
+
return w;
|
|
595
595
|
if (u) {
|
|
596
596
|
var I = t.children;
|
|
597
597
|
if (I !== void 0)
|
|
@@ -605,7 +605,7 @@ Check the top-level render call using <` + n + ">.");
|
|
|
605
605
|
else
|
|
606
606
|
ze(I, e);
|
|
607
607
|
}
|
|
608
|
-
return e === d ? Ct(
|
|
608
|
+
return e === d ? Ct(w) : Nt(w), w;
|
|
609
609
|
}
|
|
610
610
|
}
|
|
611
611
|
function It(e, t, n) {
|
|
@@ -635,7 +635,7 @@ const O = {
|
|
|
635
635
|
SUPERADMIN: "/superadmin",
|
|
636
636
|
CMS: "/cms"
|
|
637
637
|
}, Wt = 300, qt = 300;
|
|
638
|
-
var F = /* @__PURE__ */ ((
|
|
638
|
+
var F = /* @__PURE__ */ ((o) => (o.OPEN = "OPEN", o.HIDDEN = "HIDDEN", o.EXPANDED = "EXPANDED", o))(F || {});
|
|
639
639
|
const xe = be.createContext(
|
|
640
640
|
{}
|
|
641
641
|
);
|
|
@@ -643,20 +643,20 @@ function q() {
|
|
|
643
643
|
return X(xe);
|
|
644
644
|
}
|
|
645
645
|
function Vt({
|
|
646
|
-
children:
|
|
646
|
+
children: o,
|
|
647
647
|
isOpen: s,
|
|
648
648
|
tenantServiceUrl: p,
|
|
649
649
|
onNavigationClose: d = () => {
|
|
650
650
|
}
|
|
651
651
|
}) {
|
|
652
|
-
const [f] = X(Te), [c,
|
|
652
|
+
const [f] = X(Te), [c, b] = le({
|
|
653
653
|
selectedTenantId: f,
|
|
654
654
|
currentPosition: "HIDDEN"
|
|
655
655
|
/* HIDDEN */
|
|
656
|
-
}), { user:
|
|
656
|
+
}), { user: i, authService: m, canSignOut: x } = X(tt);
|
|
657
657
|
Ee(() => {
|
|
658
658
|
if (s) {
|
|
659
|
-
|
|
659
|
+
b((B) => ({
|
|
660
660
|
...B,
|
|
661
661
|
selectedTenantId: f,
|
|
662
662
|
currentPosition: "OPEN"
|
|
@@ -664,68 +664,68 @@ function Vt({
|
|
|
664
664
|
}));
|
|
665
665
|
return;
|
|
666
666
|
}
|
|
667
|
-
|
|
667
|
+
b((B) => ({
|
|
668
668
|
...B,
|
|
669
669
|
currentPosition: "HIDDEN"
|
|
670
670
|
/* HIDDEN */
|
|
671
671
|
}));
|
|
672
|
-
}, [f, s,
|
|
672
|
+
}, [f, s, b]), Ee(() => {
|
|
673
673
|
s && m.refreshUser(300);
|
|
674
674
|
}, [m, s]);
|
|
675
675
|
const g = y(
|
|
676
|
-
() =>
|
|
677
|
-
|
|
676
|
+
() => i ? M(
|
|
677
|
+
i,
|
|
678
678
|
c.selectedTenantId,
|
|
679
679
|
W.MARKETING_ENGINE_APP
|
|
680
680
|
) : !1,
|
|
681
|
-
[c.selectedTenantId,
|
|
681
|
+
[c.selectedTenantId, i]
|
|
682
682
|
), S = y(
|
|
683
|
-
() =>
|
|
684
|
-
|
|
683
|
+
() => i ? M(
|
|
684
|
+
i,
|
|
685
685
|
c.selectedTenantId,
|
|
686
686
|
W.SHOWROOM_APP
|
|
687
687
|
) : !1,
|
|
688
|
-
[c.selectedTenantId,
|
|
688
|
+
[c.selectedTenantId, i]
|
|
689
689
|
), R = y(
|
|
690
|
-
() =>
|
|
691
|
-
|
|
690
|
+
() => i ? M(
|
|
691
|
+
i,
|
|
692
692
|
c.selectedTenantId,
|
|
693
693
|
W.SENDOUTS_APP
|
|
694
694
|
) : !1,
|
|
695
|
-
[c.selectedTenantId,
|
|
695
|
+
[c.selectedTenantId, i]
|
|
696
696
|
), j = y(
|
|
697
|
-
() =>
|
|
698
|
-
|
|
697
|
+
() => i ? M(
|
|
698
|
+
i,
|
|
699
699
|
c.selectedTenantId,
|
|
700
700
|
W.SENDOUTS_CMS_APP
|
|
701
701
|
) : !1,
|
|
702
|
-
[c.selectedTenantId,
|
|
702
|
+
[c.selectedTenantId, i]
|
|
703
703
|
), D = y(
|
|
704
|
-
() =>
|
|
705
|
-
|
|
704
|
+
() => i ? M(
|
|
705
|
+
i,
|
|
706
706
|
c.selectedTenantId,
|
|
707
707
|
W.USER_MANAGEMENT_APP
|
|
708
708
|
) : !1,
|
|
709
|
-
[c.selectedTenantId,
|
|
709
|
+
[c.selectedTenantId, i]
|
|
710
710
|
), L = y(
|
|
711
|
-
() =>
|
|
712
|
-
|
|
711
|
+
() => i ? M(
|
|
712
|
+
i,
|
|
713
713
|
c.selectedTenantId,
|
|
714
714
|
W.UNIVERSAL
|
|
715
715
|
) : !1,
|
|
716
|
-
[c.selectedTenantId,
|
|
716
|
+
[c.selectedTenantId, i]
|
|
717
717
|
), U = y(
|
|
718
|
-
() =>
|
|
719
|
-
[c.selectedTenantId,
|
|
718
|
+
() => i ? M(i, c.selectedTenantId, "settings-app") : !1,
|
|
719
|
+
[c.selectedTenantId, i]
|
|
720
720
|
), C = y(
|
|
721
|
-
() =>
|
|
722
|
-
|
|
721
|
+
() => i ? M(
|
|
722
|
+
i,
|
|
723
723
|
c.selectedTenantId,
|
|
724
724
|
W.INSTORE_ADMIN_APP
|
|
725
725
|
) : !1,
|
|
726
|
-
[c.selectedTenantId,
|
|
726
|
+
[c.selectedTenantId, i]
|
|
727
727
|
), h = K(
|
|
728
|
-
(B) =>
|
|
728
|
+
(B) => b((ue) => ({
|
|
729
729
|
...ue,
|
|
730
730
|
...B
|
|
731
731
|
})),
|
|
@@ -781,25 +781,25 @@ function Vt({
|
|
|
781
781
|
p
|
|
782
782
|
]
|
|
783
783
|
);
|
|
784
|
-
return /* @__PURE__ */ r.jsx(xe.Provider, { value: J, children:
|
|
784
|
+
return /* @__PURE__ */ r.jsx(xe.Provider, { value: J, children: o });
|
|
785
785
|
}
|
|
786
786
|
const Yt = "_navigation_1esaw_1", Gt = {
|
|
787
787
|
navigation: Yt
|
|
788
|
-
}, zt = "data:image/svg+xml,%3csvg%20width='20'%20height='20'%20viewBox='0%200%2020%2020'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M0.398438%200.399902L19.5984%2019.5999M0.398438%2019.5999L19.5984%200.399902'%20stroke='black'/%3e%3c/svg%3e", Kt = "data:image/svg+xml,%3csvg%20width='14'%20height='15'%20viewBox='0%200%2014%2015'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M7%201.5999L10.4667%204.7999M7%201.5999L3.8%204.7999M7%201.5999L7%2011.7332M13.4%207.46657L13.4%2014.3999L0.600002%2014.3999L0.600002%207.46657'%20stroke='%232D2D33'/%3e%3c/svg%3e", Xt = "data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'%20standalone='no'?%3e%3c!DOCTYPE%20svg%20PUBLIC%20'-//W3C//DTD%20SVG%201.1//EN'%20'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3e%3csvg%20width='100%25'%20height='100%25'%20viewBox='0%200%2046%2046'%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20xml:space='preserve'%20xmlns:serif='http://www.serif.com/'%20style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2;'%3e%3cg%20transform='matrix(1,0,0,1,-27,-27)'%3e%3cpath%20d='M73,50C73,37.3%2062.7,27%2050,27C37.3,27%2027,37.3%2027,50M30.9,50C30.9,39.5%2039.4,30.9%2050,30.9C60.6,30.9%2069.1,39.5%2069.1,50'%20style='fill-rule:nonzero;'%3e%3canimateTransform%20attributeName='transform'%20attributeType='XML'%20type='rotate'%20dur='1s'%20from='0%2050%2050'%20to='360%2050%2050'%20repeatCount='indefinite'%20/%3e%3c/path%3e%3c/g%3e%3c/svg%3e", Jt = (
|
|
788
|
+
}, zt = "data:image/svg+xml,%3csvg%20width='20'%20height='20'%20viewBox='0%200%2020%2020'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M0.398438%200.399902L19.5984%2019.5999M0.398438%2019.5999L19.5984%200.399902'%20stroke='black'/%3e%3c/svg%3e", Kt = "data:image/svg+xml,%3csvg%20width='14'%20height='15'%20viewBox='0%200%2014%2015'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M7%201.5999L10.4667%204.7999M7%201.5999L3.8%204.7999M7%201.5999L7%2011.7332M13.4%207.46657L13.4%2014.3999L0.600002%2014.3999L0.600002%207.46657'%20stroke='%232D2D33'/%3e%3c/svg%3e", Xt = "data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'%20standalone='no'?%3e%3c!DOCTYPE%20svg%20PUBLIC%20'-//W3C//DTD%20SVG%201.1//EN'%20'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3e%3csvg%20width='100%25'%20height='100%25'%20viewBox='0%200%2046%2046'%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20xml:space='preserve'%20xmlns:serif='http://www.serif.com/'%20style='fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2;'%3e%3cg%20transform='matrix(1,0,0,1,-27,-27)'%3e%3cpath%20d='M73,50C73,37.3%2062.7,27%2050,27C37.3,27%2027,37.3%2027,50M30.9,50C30.9,39.5%2039.4,30.9%2050,30.9C60.6,30.9%2069.1,39.5%2069.1,50'%20style='fill-rule:nonzero;'%3e%3canimateTransform%20attributeName='transform'%20attributeType='XML'%20type='rotate'%20dur='1s'%20from='0%2050%2050'%20to='360%2050%2050'%20repeatCount='indefinite'%20/%3e%3c/path%3e%3c/g%3e%3c/svg%3e", Jt = (o) => {
|
|
789
789
|
throw new Error(
|
|
790
790
|
"TENANTS_SERVICE_URL or REACT_APP_TENANTS_SERVICE_URL must be set"
|
|
791
791
|
);
|
|
792
792
|
};
|
|
793
|
-
function Zt(
|
|
793
|
+
function Zt(o) {
|
|
794
794
|
const s = nt(), p = Jt(), { viewState: d } = q(), [f] = X(Te);
|
|
795
795
|
return K(
|
|
796
|
-
async (
|
|
797
|
-
const
|
|
796
|
+
async (b) => {
|
|
797
|
+
const i = b.replace(/^\//, "");
|
|
798
798
|
s.setHeader("tenant-id", d.selectedTenantId);
|
|
799
799
|
try {
|
|
800
800
|
return await s.post(
|
|
801
801
|
p,
|
|
802
|
-
|
|
802
|
+
i
|
|
803
803
|
);
|
|
804
804
|
} finally {
|
|
805
805
|
f && s.setHeader("tenant-id", f);
|
|
@@ -808,12 +808,12 @@ function Zt(i) {
|
|
|
808
808
|
[s, p, d, f]
|
|
809
809
|
);
|
|
810
810
|
}
|
|
811
|
-
function Qt(
|
|
811
|
+
function Qt(o) {
|
|
812
812
|
throw new Error(
|
|
813
813
|
"TENANTS_SERVICE_URL or REACT_APP_TENANTS_SERVICE_URL must be set"
|
|
814
814
|
);
|
|
815
815
|
}
|
|
816
|
-
function Re(
|
|
816
|
+
function Re(o) {
|
|
817
817
|
const s = nt(), p = Qt(), { data: d, error: f } = Lt(p, s.get);
|
|
818
818
|
return {
|
|
819
819
|
tenants: d ?? [],
|
|
@@ -823,18 +823,18 @@ function Re(i) {
|
|
|
823
823
|
}
|
|
824
824
|
function en() {
|
|
825
825
|
const {
|
|
826
|
-
viewState: { selectedTenantId:
|
|
826
|
+
viewState: { selectedTenantId: o }
|
|
827
827
|
} = q(), { tenants: s } = Re();
|
|
828
|
-
return y(() => s.find((d) => d.id ===
|
|
828
|
+
return y(() => s.find((d) => d.id === o), [s, o]);
|
|
829
829
|
}
|
|
830
|
-
function tn({ layout:
|
|
830
|
+
function tn({ layout: o }) {
|
|
831
831
|
const {
|
|
832
832
|
viewState: { selectedTenantId: s }
|
|
833
833
|
} = q(), { tenants: p } = Re(), d = y(
|
|
834
834
|
() => p.find((f) => f.id === s),
|
|
835
835
|
[s, p]
|
|
836
836
|
);
|
|
837
|
-
return d ? /* @__PURE__ */ r.jsx(kt, { src: d.logoUrl, layout:
|
|
837
|
+
return d ? /* @__PURE__ */ r.jsx(kt, { src: d.logoUrl, layout: o }) : null;
|
|
838
838
|
}
|
|
839
839
|
const nn = "_tier_1cqnw_1", rn = "_tier-header_1cqnw_12", an = "_border_1cqnw_17", sn = "_tier-main_1cqnw_21", on = "_tier-footer_1cqnw_26", te = {
|
|
840
840
|
tier: nn,
|
|
@@ -844,7 +844,7 @@ const nn = "_tier_1cqnw_1", rn = "_tier-header_1cqnw_12", an = "_border_1cqnw_17
|
|
|
844
844
|
tierFooter: on
|
|
845
845
|
};
|
|
846
846
|
function rt({
|
|
847
|
-
children:
|
|
847
|
+
children: o,
|
|
848
848
|
header: s,
|
|
849
849
|
footer: p,
|
|
850
850
|
className: d,
|
|
@@ -862,7 +862,7 @@ function rt({
|
|
|
862
862
|
children: s
|
|
863
863
|
}
|
|
864
864
|
),
|
|
865
|
-
/* @__PURE__ */ r.jsx("div", { className: te.tierMain, children:
|
|
865
|
+
/* @__PURE__ */ r.jsx("div", { className: te.tierMain, children: o }),
|
|
866
866
|
!!p && /* @__PURE__ */ r.jsx("div", { className: te.tierFooter, children: p })
|
|
867
867
|
] });
|
|
868
868
|
}
|
|
@@ -871,23 +871,23 @@ const cn = "_navigation-button_1ckcy_1", ln = "_active_1ckcy_15", Qe = {
|
|
|
871
871
|
active: ln
|
|
872
872
|
};
|
|
873
873
|
function P({
|
|
874
|
-
children:
|
|
874
|
+
children: o,
|
|
875
875
|
to: s,
|
|
876
876
|
hidden: p,
|
|
877
877
|
disabled: d,
|
|
878
878
|
onClick: f
|
|
879
879
|
}) {
|
|
880
|
-
const [c,
|
|
880
|
+
const [c, b] = X(Te), [i, m] = le(!1), {
|
|
881
881
|
viewState: { selectedTenantId: x }
|
|
882
882
|
} = q();
|
|
883
883
|
Ee(() => {
|
|
884
884
|
const R = () => {
|
|
885
|
-
c !== x &&
|
|
885
|
+
c !== x && i && b(x);
|
|
886
886
|
};
|
|
887
887
|
return window.addEventListener("unload", R), () => {
|
|
888
888
|
window.removeEventListener("unload", R);
|
|
889
889
|
};
|
|
890
|
-
}, [
|
|
890
|
+
}, [b, c, x, i]);
|
|
891
891
|
const g = K(() => {
|
|
892
892
|
if (f) {
|
|
893
893
|
f(m);
|
|
@@ -904,7 +904,7 @@ function P({
|
|
|
904
904
|
noShadow: !0,
|
|
905
905
|
disabled: S || d,
|
|
906
906
|
onClick: g,
|
|
907
|
-
children:
|
|
907
|
+
children: o
|
|
908
908
|
}
|
|
909
909
|
);
|
|
910
910
|
}
|
|
@@ -927,16 +927,16 @@ const un = "_applications_1pwbq_1", dn = "_applications-header_1pwbq_7", fn = "_
|
|
|
927
927
|
applicationsFooterSignOutLabel: Rn,
|
|
928
928
|
errorAnim: Nn,
|
|
929
929
|
errorText: Cn
|
|
930
|
-
}, In = (
|
|
930
|
+
}, In = (o) => new Promise((s) => setTimeout(s, o));
|
|
931
931
|
function yn() {
|
|
932
|
-
const { user:
|
|
932
|
+
const { user: o } = X(tt), {
|
|
933
933
|
signOut: s,
|
|
934
934
|
onNavigationClose: p,
|
|
935
935
|
toggleTenants: d,
|
|
936
936
|
hasShowroomAccess: f,
|
|
937
937
|
hasMarketingEngineAccess: c,
|
|
938
|
-
hasSendoutsAccess:
|
|
939
|
-
hasCmsAccess:
|
|
938
|
+
hasSendoutsAccess: b,
|
|
939
|
+
hasCmsAccess: i,
|
|
940
940
|
hasUserManagementAccess: m,
|
|
941
941
|
hasSettingsAccess: x,
|
|
942
942
|
hasUniversalAccess: g,
|
|
@@ -991,7 +991,7 @@ function yn() {
|
|
|
991
991
|
/* @__PURE__ */ r.jsxs("div", { className: T.applicationsMainList, children: [
|
|
992
992
|
/* @__PURE__ */ r.jsx(P, { to: O.DASHBOARD, children: "Dashboard" }),
|
|
993
993
|
/* @__PURE__ */ r.jsx(P, { hidden: !f, to: O.SHOWROOM, children: "Presentations (Showroom)" }),
|
|
994
|
-
/* @__PURE__ */ r.jsx(P, { hidden: !
|
|
994
|
+
/* @__PURE__ */ r.jsx(P, { hidden: !b, to: O.SENDOUTS, children: "Sendouts" }),
|
|
995
995
|
/* @__PURE__ */ r.jsx(
|
|
996
996
|
P,
|
|
997
997
|
{
|
|
@@ -1008,7 +1008,7 @@ function yn() {
|
|
|
1008
1008
|
children: "Stores"
|
|
1009
1009
|
}
|
|
1010
1010
|
),
|
|
1011
|
-
/* @__PURE__ */ r.jsx(P, { hidden: !
|
|
1011
|
+
/* @__PURE__ */ r.jsx(P, { hidden: !i, to: O.CMS, children: "Content Manager" }),
|
|
1012
1012
|
/* @__PURE__ */ r.jsx(
|
|
1013
1013
|
P,
|
|
1014
1014
|
{
|
|
@@ -1048,13 +1048,13 @@ function yn() {
|
|
|
1048
1048
|
),
|
|
1049
1049
|
D ? /* @__PURE__ */ r.jsx("p", { className: T.errorText, children: "Unable to access subscription page" }) : null
|
|
1050
1050
|
] }),
|
|
1051
|
-
|
|
1051
|
+
o && /* @__PURE__ */ r.jsxs("div", { className: T.applicationsMainUser, children: [
|
|
1052
1052
|
/* @__PURE__ */ r.jsxs("div", { className: T.applicationsMainUserName, children: [
|
|
1053
|
-
|
|
1053
|
+
o.firstName,
|
|
1054
1054
|
" ",
|
|
1055
|
-
|
|
1055
|
+
o.lastName
|
|
1056
1056
|
] }),
|
|
1057
|
-
/* @__PURE__ */ r.jsx("div", { className: T.applicationsMainUserEmail, children:
|
|
1057
|
+
/* @__PURE__ */ r.jsx("div", { className: T.applicationsMainUserEmail, children: o.email })
|
|
1058
1058
|
] })
|
|
1059
1059
|
] }) })
|
|
1060
1060
|
}
|
|
@@ -1064,11 +1064,11 @@ const jn = "data:image/svg+xml,%3csvg%20width='14'%20height='14'%20viewBox='0%20
|
|
|
1064
1064
|
tenantButton: Pn,
|
|
1065
1065
|
active: On
|
|
1066
1066
|
};
|
|
1067
|
-
function Dn({ tenant:
|
|
1067
|
+
function Dn({ tenant: o }) {
|
|
1068
1068
|
const {
|
|
1069
1069
|
viewState: { selectedTenantId: s },
|
|
1070
1070
|
updateViewState: p
|
|
1071
|
-
} = q(), d = s ===
|
|
1071
|
+
} = q(), d = s === o.id;
|
|
1072
1072
|
return /* @__PURE__ */ r.jsx(
|
|
1073
1073
|
Se,
|
|
1074
1074
|
{
|
|
@@ -1079,13 +1079,13 @@ function Dn({ tenant: i }) {
|
|
|
1079
1079
|
disabled: d,
|
|
1080
1080
|
onClick: () => {
|
|
1081
1081
|
p({
|
|
1082
|
-
selectedTenantId:
|
|
1082
|
+
selectedTenantId: o.id,
|
|
1083
1083
|
currentPosition: F.OPEN
|
|
1084
1084
|
});
|
|
1085
1085
|
},
|
|
1086
|
-
children:
|
|
1086
|
+
children: o.label
|
|
1087
1087
|
},
|
|
1088
|
-
|
|
1088
|
+
o.id
|
|
1089
1089
|
);
|
|
1090
1090
|
}
|
|
1091
1091
|
const Mn = "_tenants_6vjyd_1", kn = "_tenants-header_6vjyd_7", Fn = "_tenants-header-arrow-icon_6vjyd_11", Ln = "_tenants-main_6vjyd_24", Un = "_tenants-footer_6vjyd_42", Bn = "_tenants-footer-create-brand_6vjyd_50", Hn = "_tenants-footer-create-brand-icon_6vjyd_56", $n = "_tenants-footer-create-brand-label_6vjyd_60", k = {
|
|
@@ -1099,12 +1099,12 @@ const Mn = "_tenants_6vjyd_1", kn = "_tenants-header_6vjyd_7", Fn = "_tenants-he
|
|
|
1099
1099
|
tenantsFooterCreateBrandLabel: $n
|
|
1100
1100
|
};
|
|
1101
1101
|
function Wn() {
|
|
1102
|
-
const { toggleTenants:
|
|
1102
|
+
const { toggleTenants: o } = q(), { tenants: s } = Re();
|
|
1103
1103
|
return /* @__PURE__ */ r.jsx("div", { className: k.tenants, children: /* @__PURE__ */ r.jsx(
|
|
1104
1104
|
rt,
|
|
1105
1105
|
{
|
|
1106
1106
|
width: Wt,
|
|
1107
|
-
header: /* @__PURE__ */ r.jsx("div", { className: k.tenantsHeader, children: /* @__PURE__ */ r.jsx("div", { className: k.tenantsHeaderArrowIcon, onClick:
|
|
1107
|
+
header: /* @__PURE__ */ r.jsx("div", { className: k.tenantsHeader, children: /* @__PURE__ */ r.jsx("div", { className: k.tenantsHeaderArrowIcon, onClick: o, children: /* @__PURE__ */ r.jsx(ne, { src: An, size: "large" }) }) }),
|
|
1108
1108
|
footer: /* @__PURE__ */ r.jsx(
|
|
1109
1109
|
"div",
|
|
1110
1110
|
{
|
|
@@ -1141,7 +1141,7 @@ const ge = { ease: "easeOut", duration: 0.3 }, Gn = {
|
|
|
1141
1141
|
[F.EXPANDED]: { left: 0, transition: ge }
|
|
1142
1142
|
};
|
|
1143
1143
|
function zn({
|
|
1144
|
-
isOpen:
|
|
1144
|
+
isOpen: o,
|
|
1145
1145
|
portalContainer: s = document.body,
|
|
1146
1146
|
onClose: p,
|
|
1147
1147
|
tenantServiceUrl: d
|
|
@@ -1153,7 +1153,7 @@ function zn({
|
|
|
1153
1153
|
Vt,
|
|
1154
1154
|
{
|
|
1155
1155
|
onNavigationClose: p,
|
|
1156
|
-
isOpen:
|
|
1156
|
+
isOpen: o,
|
|
1157
1157
|
tenantServiceUrl: d,
|
|
1158
1158
|
children: /* @__PURE__ */ r.jsx(xe.Consumer, { children: ({ viewState: { currentPosition: f } }) => Mt(
|
|
1159
1159
|
/* @__PURE__ */ r.jsx(Ot, { children: f !== F.HIDDEN && /* @__PURE__ */ r.jsx(
|
|
@@ -1175,30 +1175,32 @@ function zn({
|
|
|
1175
1175
|
}
|
|
1176
1176
|
const Kn = "data:image/svg+xml,%3csvg%20width='14'%20height='15'%20viewBox='0%200%2014%2011'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M0%201.5H14M0%205.5H14M0%209.5H14M0'%20stroke='black'/%3e%3c/svg%3e";
|
|
1177
1177
|
function or({
|
|
1178
|
-
size:
|
|
1178
|
+
size: o = "medium",
|
|
1179
1179
|
alt: s = "Toggle navigation menu",
|
|
1180
1180
|
src: p = Kn,
|
|
1181
1181
|
portalContainer: d = document.body,
|
|
1182
|
-
|
|
1182
|
+
tenantServiceUrl: f,
|
|
1183
|
+
...c
|
|
1183
1184
|
}) {
|
|
1184
|
-
const [
|
|
1185
|
+
const [b, i] = Bt(!1);
|
|
1185
1186
|
return /* @__PURE__ */ r.jsxs(Pt, { children: [
|
|
1186
1187
|
/* @__PURE__ */ r.jsx(
|
|
1187
1188
|
Ft,
|
|
1188
1189
|
{
|
|
1189
|
-
size:
|
|
1190
|
+
size: o,
|
|
1190
1191
|
alt: s,
|
|
1191
1192
|
src: p,
|
|
1192
|
-
onClick: () =>
|
|
1193
|
-
...
|
|
1193
|
+
onClick: () => i(),
|
|
1194
|
+
...c
|
|
1194
1195
|
}
|
|
1195
1196
|
),
|
|
1196
1197
|
/* @__PURE__ */ r.jsx(
|
|
1197
1198
|
zn,
|
|
1198
1199
|
{
|
|
1199
|
-
isOpen:
|
|
1200
|
+
isOpen: b,
|
|
1200
1201
|
portalContainer: d,
|
|
1201
|
-
onClose: () =>
|
|
1202
|
+
onClose: () => i(),
|
|
1203
|
+
tenantServiceUrl: f
|
|
1202
1204
|
}
|
|
1203
1205
|
)
|
|
1204
1206
|
] });
|