@wandelbots/wandelbots-js-react-components 2.49.0 → 2.50.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/components/AppHeader.d.ts +2 -0
- package/dist/components/AppHeader.d.ts.map +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +47 -54
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
- package/src/components/AppHeader.tsx +30 -32
package/dist/index.js
CHANGED
|
@@ -744,12 +744,19 @@ const z0 = ({
|
|
|
744
744
|
}
|
|
745
745
|
) }), qk = Ge(
|
|
746
746
|
Ce((e) => {
|
|
747
|
-
const {
|
|
748
|
-
|
|
749
|
-
|
|
750
|
-
|
|
751
|
-
|
|
752
|
-
|
|
747
|
+
const {
|
|
748
|
+
appIcon: t,
|
|
749
|
+
appName: r,
|
|
750
|
+
apps: n = [],
|
|
751
|
+
onAppSelect: a,
|
|
752
|
+
disabled: o = !1,
|
|
753
|
+
sx: s
|
|
754
|
+
} = e, [i, l] = De(null), c = !!i, u = (p) => {
|
|
755
|
+
l(p.currentTarget);
|
|
756
|
+
}, d = () => {
|
|
757
|
+
l(null);
|
|
758
|
+
}, h = (p) => {
|
|
759
|
+
d(), p.onClick ? p.onClick() : p.href && (window.location.href = p.href), a == null || a(p);
|
|
753
760
|
};
|
|
754
761
|
return /* @__PURE__ */ g.jsxs(g.Fragment, { children: [
|
|
755
762
|
/* @__PURE__ */ g.jsx(
|
|
@@ -758,26 +765,25 @@ const z0 = ({
|
|
|
758
765
|
position: "static",
|
|
759
766
|
sx: {
|
|
760
767
|
boxShadow: "none",
|
|
761
|
-
|
|
762
|
-
|
|
763
|
-
|
|
764
|
-
|
|
768
|
+
background: (p) => {
|
|
769
|
+
var f;
|
|
770
|
+
return (f = p.palette.backgroundPaperElevation) == null ? void 0 : f[1];
|
|
771
|
+
},
|
|
772
|
+
"& label, a, span": {
|
|
773
|
+
textWrap: "nowrap"
|
|
765
774
|
},
|
|
766
|
-
...
|
|
775
|
+
...s
|
|
767
776
|
},
|
|
768
777
|
children: /* @__PURE__ */ g.jsxs($g, { sx: { minHeight: "62px !important" }, children: [
|
|
769
|
-
/* @__PURE__ */ g.jsx(re, { sx: { mr:
|
|
778
|
+
/* @__PURE__ */ g.jsx(re, { sx: { mr: 1, display: "flex", alignItems: "center" }, children: t }),
|
|
770
779
|
/* @__PURE__ */ g.jsxs(re, { sx: { display: "flex", alignItems: "center", flexGrow: 1 }, children: [
|
|
771
780
|
/* @__PURE__ */ g.jsx(
|
|
772
781
|
he,
|
|
773
782
|
{
|
|
774
|
-
|
|
775
|
-
component: "div",
|
|
783
|
+
component: "h1",
|
|
776
784
|
sx: {
|
|
777
|
-
fontWeight:
|
|
778
|
-
fontSize: "
|
|
779
|
-
lineHeight: "24px",
|
|
780
|
-
letterSpacing: 0
|
|
785
|
+
fontWeight: "bold",
|
|
786
|
+
fontSize: "1rem"
|
|
781
787
|
},
|
|
782
788
|
children: r
|
|
783
789
|
}
|
|
@@ -789,22 +795,23 @@ const z0 = ({
|
|
|
789
795
|
"aria-label": "switch app",
|
|
790
796
|
"aria-controls": "app-menu",
|
|
791
797
|
"aria-haspopup": "true",
|
|
792
|
-
onClick:
|
|
798
|
+
onClick: u,
|
|
799
|
+
disabled: o,
|
|
793
800
|
sx: {
|
|
794
|
-
ml:
|
|
795
|
-
width:
|
|
796
|
-
height:
|
|
797
|
-
borderRadius: "
|
|
798
|
-
padding:
|
|
799
|
-
backgroundColor: (
|
|
801
|
+
ml: 1,
|
|
802
|
+
width: 28,
|
|
803
|
+
height: 28,
|
|
804
|
+
borderRadius: "6px",
|
|
805
|
+
padding: 0,
|
|
806
|
+
backgroundColor: (p) => zc(p.palette.common.white, 0.1),
|
|
800
807
|
opacity: 1,
|
|
801
808
|
"&:hover": {
|
|
802
|
-
backgroundColor: (
|
|
809
|
+
backgroundColor: (p) => zc(p.palette.common.white, 0.16)
|
|
803
810
|
},
|
|
804
811
|
"& .MuiSvgIcon-root": {
|
|
805
|
-
fontSize: "
|
|
806
|
-
width: "
|
|
807
|
-
height: "
|
|
812
|
+
fontSize: "8px",
|
|
813
|
+
width: "8px",
|
|
814
|
+
height: "6px"
|
|
808
815
|
}
|
|
809
816
|
},
|
|
810
817
|
children: /* @__PURE__ */ g.jsx(G0, {})
|
|
@@ -817,12 +824,12 @@ const z0 = ({
|
|
|
817
824
|
/* @__PURE__ */ g.jsx(
|
|
818
825
|
Ug,
|
|
819
826
|
{
|
|
820
|
-
open:
|
|
821
|
-
onClick:
|
|
827
|
+
open: c,
|
|
828
|
+
onClick: d,
|
|
822
829
|
sx: {
|
|
823
830
|
backdropFilter: "blur(4px)",
|
|
824
831
|
backgroundColor: "rgba(0, 0, 0, 0.3)",
|
|
825
|
-
zIndex: (
|
|
832
|
+
zIndex: (p) => p.zIndex.modal - 1
|
|
826
833
|
}
|
|
827
834
|
}
|
|
828
835
|
),
|
|
@@ -830,9 +837,9 @@ const z0 = ({
|
|
|
830
837
|
Dg,
|
|
831
838
|
{
|
|
832
839
|
id: "app-menu",
|
|
833
|
-
anchorEl:
|
|
834
|
-
open:
|
|
835
|
-
onClose:
|
|
840
|
+
anchorEl: i,
|
|
841
|
+
open: c,
|
|
842
|
+
onClose: d,
|
|
836
843
|
anchorOrigin: {
|
|
837
844
|
vertical: "bottom",
|
|
838
845
|
horizontal: "left"
|
|
@@ -842,30 +849,16 @@ const z0 = ({
|
|
|
842
849
|
horizontal: "left"
|
|
843
850
|
},
|
|
844
851
|
sx: {
|
|
845
|
-
zIndex: (
|
|
852
|
+
zIndex: (p) => p.zIndex.modal,
|
|
846
853
|
"& .MuiPaper-root": {
|
|
847
854
|
minWidth: 200,
|
|
848
855
|
mt: 1
|
|
849
856
|
}
|
|
850
857
|
},
|
|
851
|
-
children: n.map((
|
|
852
|
-
|
|
853
|
-
{
|
|
854
|
-
|
|
855
|
-
sx: {
|
|
856
|
-
display: "flex",
|
|
857
|
-
alignItems: "center",
|
|
858
|
-
gap: 2,
|
|
859
|
-
py: 1.5,
|
|
860
|
-
px: 2
|
|
861
|
-
},
|
|
862
|
-
children: [
|
|
863
|
-
/* @__PURE__ */ g.jsx(re, { sx: { display: "flex", alignItems: "center" }, children: h.icon }),
|
|
864
|
-
/* @__PURE__ */ g.jsx(he, { variant: "body1", children: h.name })
|
|
865
|
-
]
|
|
866
|
-
},
|
|
867
|
-
h.id
|
|
868
|
-
))
|
|
858
|
+
children: n.map((p) => /* @__PURE__ */ g.jsxs(gn, { onClick: () => h(p), children: [
|
|
859
|
+
/* @__PURE__ */ g.jsx(re, { sx: { display: "flex", alignItems: "center" }, children: p.icon }),
|
|
860
|
+
/* @__PURE__ */ g.jsx(he, { variant: "body1", sx: { ml: 2 }, children: p.name })
|
|
861
|
+
] }, p.id))
|
|
869
862
|
}
|
|
870
863
|
)
|
|
871
864
|
] });
|