@altinn/altinn-components 0.42.3 → 0.42.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.
@@ -1 +1 @@
1
- ._button_234vz_1{flex-shrink:0;position:relative;z-index:2;display:inline-flex;align-items:center;column-gap:.625rem;padding:.625rem;border:none;border-radius:4px}._label_234vz_13{font-size:1.125rem;font-weight:500;padding:.25rem}._loginIcon_234vz_19,._closeIcon_234vz_20,._avatar_234vz_21{font-size:1.5rem;width:2.25rem;height:2.25rem;border-radius:2px}._loginIcon_234vz_19{background-color:#fff;color:#000}._closeIcon_234vz_20{outline:1px solid white}._badge_234vz_37{position:absolute;top:0;right:0;margin-top:-.75rem;margin-right:-.75rem}@supports (-webkit-hyphens: none){._loginIcon_234vz_19,._closeIcon_234vz_20,._avatar_234vz_21{font-size:unset}._loginIcon_234vz_19 svg,._loginIcon_234vz_19 img,._closeIcon_234vz_20 svg,._closeIcon_234vz_20 img{width:1.5rem;height:1.5rem}}
1
+ ._button_1uh95_1{flex-shrink:0;position:relative;z-index:2;display:inline-flex;align-items:center;column-gap:.625rem;padding:.625rem;border:none;border-radius:4px}._label_1uh95_13{font-size:1.125rem;font-weight:500;padding:.25rem}._avatarIcon_1uh95_19,._loginIcon_1uh95_20,._closeIcon_1uh95_21{width:2.25rem;height:2.25rem;border-radius:2px;font-size:unset}._closeIcon_1uh95_21{outline:1px solid white}._loginIcon_1uh95_20{background-color:#fff;color:#000;outline:1px solid white}._avatar_1uh95_19{font-size:2.25rem;width:2.25rem;height:2.25rem}._icon_1uh95_44{font-size:1.5rem;width:1.5rem;height:1.5rem}._badge_1uh95_50{position:absolute;top:0;right:0;margin-top:-.75rem;margin-right:-.75rem}
@@ -1,49 +1,58 @@
1
- import { jsxs as r, jsx as o } from "react/jsx-runtime";
1
+ import { jsxs as l, jsx as o } from "react/jsx-runtime";
2
2
  import { c as _ } from "../../index-L8X2o7IH.js";
3
3
  import "react";
4
- import { Badge as d } from "../Badge/Badge.js";
5
- import { ButtonBase as I } from "../Button/ButtonBase.js";
6
- import { ButtonLabel as f } from "../Button/ButtonLabel.js";
7
- import { ButtonIcon as p } from "../Button/ButtonIcon.js";
4
+ import { Avatar as u } from "../Avatar/Avatar.js";
5
+ import { Badge as I } from "../Badge/Badge.js";
6
+ import { ButtonBase as h } from "../Button/ButtonBase.js";
7
+ import { ButtonLabel as d } from "../Button/ButtonLabel.js";
8
+ import { ButtonIcon as f } from "../Button/ButtonIcon.js";
8
9
  import "../RootProvider/RootProvider.js";
9
10
  import "../Snackbar/useSnackbar.js";
10
- import { S as v } from "../../XMark-tKk6aExO.js";
11
- import { S as N } from "../../PadlockLocked-XL1IB5Ae.js";
12
- import '../../assets/GlobalMenuButton.css';const b = "_button_234vz_1", h = "_loginIcon_234vz_19", B = "_closeIcon_234vz_20", z = "_avatar_234vz_21", u = "_badge_234vz_37", a = {
13
- button: b,
14
- loginIcon: h,
15
- closeIcon: B,
16
- avatar: z,
17
- badge: u
18
- }, w = ({
11
+ import { S as N } from "../../XMark-tKk6aExO.js";
12
+ import { S as g } from "../../PadlockLocked-XL1IB5Ae.js";
13
+ import '../../assets/GlobalMenuButton.css';const v = "_button_1uh95_1", b = "_avatarIcon_1uh95_19", B = "_loginIcon_1uh95_20", x = "_closeIcon_1uh95_21", S = "_avatar_1uh95_19", k = "_icon_1uh95_44", L = "_badge_1uh95_50", a = {
14
+ button: v,
15
+ avatarIcon: b,
16
+ loginIcon: B,
17
+ closeIcon: x,
18
+ avatar: S,
19
+ icon: k,
20
+ badge: L
21
+ }, H = ({
19
22
  className: t,
20
- as: c = "button",
23
+ as: s = "button",
21
24
  color: i = "accent",
22
- variant: e = "solid",
23
- currentAccount: s,
24
- expanded: g,
25
- label: l = "Menu",
25
+ variant: m = "solid",
26
+ currentAccount: c,
27
+ expanded: p,
28
+ label: r = "Menu",
26
29
  badge: n,
27
- ...m
28
- }) => g ? /* @__PURE__ */ r(I, { ...m, as: c, variant: e, color: i, className: _(a.button, t), children: [
29
- /* @__PURE__ */ o(f, { children: l }),
30
- /* @__PURE__ */ o(p, { className: a.closeIcon, icon: /* @__PURE__ */ o(v, { className: a.icon, "aria-label": "Close Icon" }) }),
31
- n && /* @__PURE__ */ o(d, { ...n, className: a.badge })
32
- ] }) : s ? /* @__PURE__ */ r(I, { ...m, as: c, variant: e, color: i, className: _(a.button, t), children: [
33
- /* @__PURE__ */ o(f, { children: l }),
34
- /* @__PURE__ */ o(p, { className: a.avatar, icon: s == null ? void 0 : s.icon }),
35
- n && /* @__PURE__ */ o(d, { ...n, className: a.badge })
36
- ] }) : /* @__PURE__ */ r(I, { ...m, as: c, variant: e, color: i, className: _(a.button, t), children: [
37
- /* @__PURE__ */ o(f, { children: l }),
30
+ ...e
31
+ }) => p ? /* @__PURE__ */ l(h, { ...e, as: s, variant: m, color: i, className: _(a.button, t), children: [
32
+ /* @__PURE__ */ o(d, { children: r }),
33
+ /* @__PURE__ */ o(f, { className: a.closeIcon, icon: /* @__PURE__ */ o(N, { className: a.icon, "aria-label": "Close Icon" }) }),
34
+ n && /* @__PURE__ */ o(I, { ...n, className: a.badge })
35
+ ] }) : c ? /* @__PURE__ */ l(h, { ...e, as: s, variant: m, color: i, className: _(a.button, t), children: [
36
+ /* @__PURE__ */ o(d, { children: r }),
38
37
  /* @__PURE__ */ o(
39
- p,
38
+ f,
39
+ {
40
+ className: a.avatarIcon,
41
+ icon: /* @__PURE__ */ o(u, { ...c == null ? void 0 : c.icon, className: a.avatar })
42
+ }
43
+ ),
44
+ n && /* @__PURE__ */ o(I, { ...n, className: a.badge })
45
+ ] }) : /* @__PURE__ */ l(h, { ...e, as: s, variant: m, color: i, className: _(a.button, t), children: [
46
+ /* @__PURE__ */ o(d, { children: r }),
47
+ /* @__PURE__ */ o(
48
+ f,
40
49
  {
41
50
  className: a.loginIcon,
42
- icon: /* @__PURE__ */ o(N, { className: a.icon, "aria-label": "Login Icon" })
51
+ icon: /* @__PURE__ */ o(g, { className: a.icon, "aria-label": "Login Icon" })
43
52
  }
44
53
  ),
45
- n && /* @__PURE__ */ o(d, { ...n, className: a.badge })
54
+ n && /* @__PURE__ */ o(I, { ...n, className: a.badge })
46
55
  ] });
47
56
  export {
48
- w as GlobalMenuButton
57
+ H as GlobalMenuButton
49
58
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@altinn/altinn-components",
3
- "version": "0.42.3",
3
+ "version": "0.42.4",
4
4
  "main": "dist/index.js",
5
5
  "files": [
6
6
  "dist/",