@obosbbl/grunnmuren-react 1.12.2 → 1.12.3
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/README.md +12 -0
- package/dist/grunnmuren.mjs +21 -21
- package/package.json +2 -2
package/README.md
CHANGED
package/dist/grunnmuren.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
'use client';
|
|
2
|
-
import { jsx as a, jsxs as g, Fragment as
|
|
2
|
+
import { jsx as a, jsxs as g, Fragment as Z } from "react/jsx-runtime";
|
|
3
3
|
import he, { useState as L, useCallback as q, useEffect as pe, useId as ee, createContext as I, useContext as A, forwardRef as b, Children as W, isValidElement as re, cloneElement as K, useRef as M, useMemo as k } from "react";
|
|
4
4
|
import { ChevronDown as te, Warning as ne, InfoCircle as ae, LoadingSpinner as Ae, MenuAlt as ve, Close as xe, ChevronRight as Ne, ChevronLeft as we } from "@obosbbl/grunnmuren-icons";
|
|
5
5
|
import ye from "react-collapsed";
|
|
@@ -184,10 +184,10 @@ const mr = (e) => {
|
|
|
184
184
|
image: s,
|
|
185
185
|
...i
|
|
186
186
|
} = e, c = ie(t);
|
|
187
|
-
return /* @__PURE__ */ a("article", { className: l(r, c, "py-8 px-4 md:py-14"), ...i, children: /* @__PURE__ */ g("div", { className: "container flex gap-4
|
|
187
|
+
return /* @__PURE__ */ a("article", { className: l(r, c, "py-8 px-4 md:py-14"), ...i, children: /* @__PURE__ */ g("div", { className: "container flex flex-col justify-center gap-4 md:flex-row md:gap-12", children: [
|
|
188
188
|
s,
|
|
189
189
|
/* @__PURE__ */ g("div", { className: "w-prose", children: [
|
|
190
|
-
o && /* @__PURE__ */ a("h2", { className: "mb-4", children: o }),
|
|
190
|
+
o && /* @__PURE__ */ a("h2", { className: "h3 mb-4", children: o }),
|
|
191
191
|
n
|
|
192
192
|
] })
|
|
193
193
|
] }) });
|
|
@@ -196,10 +196,10 @@ const mr = (e) => {
|
|
|
196
196
|
{
|
|
197
197
|
loading: "lazy",
|
|
198
198
|
decoding: "async",
|
|
199
|
-
className: "w-
|
|
199
|
+
className: "w-20 flex-none self-center md:w-32 md:self-start",
|
|
200
200
|
...e
|
|
201
201
|
}
|
|
202
|
-
),
|
|
202
|
+
), je = {
|
|
203
203
|
"standard-primary": "bg-green border-green text-white",
|
|
204
204
|
"standard-secondary": "bg-white border-green text-black",
|
|
205
205
|
"light-green-primary": "bg-green-light border-green-light text-black",
|
|
@@ -216,8 +216,8 @@ const mr = (e) => {
|
|
|
216
216
|
type: c = "button",
|
|
217
217
|
variant: u = "primary",
|
|
218
218
|
...d
|
|
219
|
-
} = e, m = A(P), f =
|
|
220
|
-
return /* @__PURE__ */ a(
|
|
219
|
+
} = e, m = A(P), f = je[`${o ?? m}-${u}`], p = l(n, f, "button"), x = i ? /* @__PURE__ */ a(Fe, { children: r }) : r;
|
|
220
|
+
return /* @__PURE__ */ a(Z, { children: s ? /* @__PURE__ */ a(
|
|
221
221
|
"a",
|
|
222
222
|
{
|
|
223
223
|
"aria-busy": i ? !0 : void 0,
|
|
@@ -238,7 +238,7 @@ const mr = (e) => {
|
|
|
238
238
|
children: x
|
|
239
239
|
}
|
|
240
240
|
) });
|
|
241
|
-
}),
|
|
241
|
+
}), Fe = (e) => /* @__PURE__ */ g(Z, { children: [
|
|
242
242
|
de(e.children),
|
|
243
243
|
/* @__PURE__ */ a(
|
|
244
244
|
"span",
|
|
@@ -262,7 +262,7 @@ function de(e) {
|
|
|
262
262
|
return t;
|
|
263
263
|
});
|
|
264
264
|
}
|
|
265
|
-
const P = I("standard"), ce = I(!0),
|
|
265
|
+
const P = I("standard"), ce = I(!0), Ze = (e, t) => {
|
|
266
266
|
const {
|
|
267
267
|
as: r = "div",
|
|
268
268
|
body: n,
|
|
@@ -286,7 +286,7 @@ const P = I("standard"), ce = I(!0), je = (e, t) => {
|
|
|
286
286
|
]
|
|
287
287
|
}
|
|
288
288
|
);
|
|
289
|
-
}, We = b(
|
|
289
|
+
}, We = b(Ze), Ke = b(
|
|
290
290
|
(e, t) => {
|
|
291
291
|
const { className: r, ...n } = e;
|
|
292
292
|
return /* @__PURE__ */ a(
|
|
@@ -607,7 +607,7 @@ const J = I({ bgColor: "white", contentPosition: "below-center", hasImage: !1 })
|
|
|
607
607
|
className: l(
|
|
608
608
|
o,
|
|
609
609
|
// disable padding on small screens so the hero image is flush with the screen edges
|
|
610
|
-
"container
|
|
610
|
+
"container px-0 md:grid lg:px-4",
|
|
611
611
|
{
|
|
612
612
|
"md:grid-cols-[50%,50%]": d === "vertical-split"
|
|
613
613
|
}
|
|
@@ -873,7 +873,7 @@ const kr = (e) => {
|
|
|
873
873
|
);
|
|
874
874
|
}, Or = (e) => {
|
|
875
875
|
const { isExpanded: t } = A(R), r = ze(!1);
|
|
876
|
-
return !t || !r ? null : /* @__PURE__ */ a(
|
|
876
|
+
return !t || !r ? null : /* @__PURE__ */ a(Z, { children: e.children });
|
|
877
877
|
}, w = 2, O = I({ currentPage: 0, pageCount: 0 }), Tr = (e) => {
|
|
878
878
|
const {
|
|
879
879
|
className: t,
|
|
@@ -1001,7 +1001,7 @@ const kr = (e) => {
|
|
|
1001
1001
|
required: !1,
|
|
1002
1002
|
value: void 0,
|
|
1003
1003
|
error: !1
|
|
1004
|
-
}),
|
|
1004
|
+
}), jr = b((e, t) => {
|
|
1005
1005
|
const { children: r, className: n, ...o } = e, { defaultValue: s, isControlled: i, name: c, onChange: u, required: d, value: m, error: h } = A(fe);
|
|
1006
1006
|
return /* @__PURE__ */ g("label", { className: l(n, "flex cursor-pointer gap-2.5"), children: [
|
|
1007
1007
|
/* @__PURE__ */ a(
|
|
@@ -1020,7 +1020,7 @@ const kr = (e) => {
|
|
|
1020
1020
|
),
|
|
1021
1021
|
r
|
|
1022
1022
|
] });
|
|
1023
|
-
}),
|
|
1023
|
+
}), Fr = b(
|
|
1024
1024
|
(e, t) => {
|
|
1025
1025
|
const r = "value" in e, {
|
|
1026
1026
|
className: n,
|
|
@@ -1052,12 +1052,12 @@ const kr = (e) => {
|
|
|
1052
1052
|
error: Boolean(i)
|
|
1053
1053
|
}),
|
|
1054
1054
|
[o, r, m, v, f, p, i]
|
|
1055
|
-
),
|
|
1055
|
+
), j = C(c), U = `${j}:label`, G = `${j}:help`, H = j + "err", F = i;
|
|
1056
1056
|
return /* @__PURE__ */ a(fe.Provider, { value: T, children: /* @__PURE__ */ g(
|
|
1057
1057
|
"div",
|
|
1058
1058
|
{
|
|
1059
1059
|
"aria-describedby": l({
|
|
1060
|
-
[H]:
|
|
1060
|
+
[H]: F,
|
|
1061
1061
|
[G]: s
|
|
1062
1062
|
}) || void 0,
|
|
1063
1063
|
"aria-invalid": !!i,
|
|
@@ -1070,7 +1070,7 @@ const kr = (e) => {
|
|
|
1070
1070
|
d && /* @__PURE__ */ a(V, { id: U, isRequired: f, isInvalid: !!i, children: d }),
|
|
1071
1071
|
s && /* @__PURE__ */ a(S, { id: G, children: s }),
|
|
1072
1072
|
u,
|
|
1073
|
-
|
|
1073
|
+
F && /* @__PURE__ */ a(E, { id: H, children: F })
|
|
1074
1074
|
]
|
|
1075
1075
|
}
|
|
1076
1076
|
) });
|
|
@@ -1104,7 +1104,7 @@ const kr = (e) => {
|
|
|
1104
1104
|
)
|
|
1105
1105
|
] });
|
|
1106
1106
|
}
|
|
1107
|
-
),
|
|
1107
|
+
), Zr = b(
|
|
1108
1108
|
(e, t) => {
|
|
1109
1109
|
const {
|
|
1110
1110
|
description: r,
|
|
@@ -1351,9 +1351,9 @@ export {
|
|
|
1351
1351
|
Sr as NavbarItem,
|
|
1352
1352
|
Pr as NavbarItems,
|
|
1353
1353
|
Tr as Pagination,
|
|
1354
|
-
|
|
1355
|
-
|
|
1356
|
-
|
|
1354
|
+
jr as Radio,
|
|
1355
|
+
Fr as RadioGroup,
|
|
1356
|
+
Zr as Select,
|
|
1357
1357
|
Wr as Snackbar,
|
|
1358
1358
|
$ as SnackbarButton,
|
|
1359
1359
|
Kr as SnackbarContent,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@obosbbl/grunnmuren-react",
|
|
3
|
-
"version": "1.12.
|
|
3
|
+
"version": "1.12.3",
|
|
4
4
|
"description": "OBOS Grunnmuren design system React components",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": {
|
|
@@ -31,7 +31,7 @@
|
|
|
31
31
|
"react": "18.2.0",
|
|
32
32
|
"react-dom": "18.2.0",
|
|
33
33
|
"require-from-string": "2.0.2",
|
|
34
|
-
"rimraf": "4.
|
|
34
|
+
"rimraf": "4.3.0",
|
|
35
35
|
"tailwindcss": "3.2.7",
|
|
36
36
|
"type-fest": "3.6.1",
|
|
37
37
|
"vite": "4.1.4",
|