@still-forest/canopy 0.30.0 → 0.31.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.
@@ -1,9 +1,9 @@
1
- import { j as u } from "./jsx-runtime-B0GD0xBr.js";
2
- import g from "react";
3
- import { c as m } from "./index-CRiPKpXj.js";
4
- const w = g.forwardRef(
1
+ import { j as m } from "./jsx-runtime-B0GD0xBr.js";
2
+ import y from "react";
3
+ import { c as f } from "./index-CRiPKpXj.js";
4
+ const i = y.forwardRef(
5
5
  ({
6
- className: c,
6
+ className: a,
7
7
  as: t = "div",
8
8
  variant: n,
9
9
  size: r,
@@ -12,15 +12,15 @@ const w = g.forwardRef(
12
12
  display: l,
13
13
  sizing: s,
14
14
  position: x,
15
- overflow: a,
15
+ overflow: c,
16
16
  overflowX: b,
17
17
  overflowY: d,
18
- rounded: f,
18
+ rounded: u,
19
19
  ...p
20
- }, v) => /* @__PURE__ */ u.jsx(
20
+ }, v) => /* @__PURE__ */ m.jsx(
21
21
  t,
22
22
  {
23
- className: m(
23
+ className: f(
24
24
  // Variant
25
25
  {
26
26
  "bg-primary text-primary-foreground": n === "primary",
@@ -202,11 +202,11 @@ const w = g.forwardRef(
202
202
  },
203
203
  // Overflow
204
204
  {
205
- "overflow-auto": a === "auto",
206
- "overflow-hidden": a === "hidden",
207
- "overflow-clip": a === "clip",
208
- "overflow-visible": a === "visible",
209
- "overflow-scroll": a === "scroll"
205
+ "overflow-auto": c === "auto",
206
+ "overflow-hidden": c === "hidden",
207
+ "overflow-clip": c === "clip",
208
+ "overflow-visible": c === "visible",
209
+ "overflow-scroll": c === "scroll"
210
210
  },
211
211
  // Overflow X
212
212
  {
@@ -226,39 +226,46 @@ const w = g.forwardRef(
226
226
  },
227
227
  // Rounded
228
228
  {
229
- rounded: f === !0,
230
- "rounded-none": f === "none",
231
- "rounded-xs": f === "xs",
232
- "rounded-sm": f === "sm",
233
- "rounded-md": f === "md",
234
- "rounded-lg": f === "lg",
235
- "rounded-xl": f === "xl",
236
- "rounded-2xl": f === "2xl",
237
- "rounded-3xl": f === "3xl",
238
- "rounded-full": f === "full"
229
+ rounded: u === !0,
230
+ "rounded-none": u === "none",
231
+ "rounded-xs": u === "xs",
232
+ "rounded-sm": u === "sm",
233
+ "rounded-md": u === "md",
234
+ "rounded-lg": u === "lg",
235
+ "rounded-xl": u === "xl",
236
+ "rounded-2xl": u === "2xl",
237
+ "rounded-3xl": u === "3xl",
238
+ "rounded-full": u === "full"
239
239
  },
240
- c
240
+ a
241
241
  ),
242
242
  ref: v,
243
243
  ...p
244
244
  }
245
245
  )
246
246
  );
247
- w.displayName = "Box";
248
- const y = ({ children: c, className: t, direction: n = "col", ...r }) => {
249
- const { display: e = "flex", ...o } = r, l = m("w-full px-4 py-2 md:px-8 md:py-4 lg:px-12 lg:py-6", t);
250
- return e === "block" ? /* @__PURE__ */ u.jsx(w, { className: l, ...o, children: c }) : /* @__PURE__ */ u.jsx(i, { className: l, direction: n, ...o, children: c });
251
- }, j = ({ flex: c, className: t, as: n, children: r, ...e }) => {
247
+ i.displayName = "Box";
248
+ const g = ({ children: a, className: t, direction: n = "col", separation: r = "md", ...e }) => {
249
+ const { display: o = "flex", ...l } = e, s = f("w-full px-4 md:px-8 lg:px-12", t, {
250
+ "py-0": r === "none",
251
+ "py-0.5 md:py-1": r === "xs",
252
+ "py-1 md:py-2 ": r === "sm",
253
+ "py-2 md:py-4": r === "md",
254
+ "py-4 md:py-6": r === "lg",
255
+ "py-6 md:py-8": r === "xl"
256
+ });
257
+ return o === "block" ? /* @__PURE__ */ m.jsx(i, { className: s, ...l, children: a }) : /* @__PURE__ */ m.jsx(w, { className: s, direction: n, ...l, children: a });
258
+ }, j = ({ flex: a, className: t, as: n, children: r, ...e }) => {
252
259
  const o = n || "div";
253
- return /* @__PURE__ */ u.jsx(
260
+ return /* @__PURE__ */ m.jsx(
254
261
  o,
255
262
  {
256
- className: m(
263
+ className: f(
257
264
  {
258
- "flex-1": c === "1",
259
- "flex-auto": c === "auto",
260
- "flex-initial": c === "initial",
261
- "flex-none": c === "none"
265
+ "flex-1": a === "1",
266
+ "flex-auto": a === "auto",
267
+ "flex-initial": a === "initial",
268
+ "flex-none": a === "none"
262
269
  },
263
270
  t
264
271
  ),
@@ -266,11 +273,11 @@ const y = ({ children: c, className: t, direction: n = "col", ...r }) => {
266
273
  children: r
267
274
  }
268
275
  );
269
- }, N = g.forwardRef(
270
- ({ className: c, as: t = "div", direction: n, align: r, justify: e, grow: o, wrap: l, gap: s, gapX: x, gapY: a, ...b }, d) => /* @__PURE__ */ u.jsx(
276
+ }, N = y.forwardRef(
277
+ ({ className: a, as: t = "div", direction: n, align: r, justify: e, grow: o, wrap: l, gap: s, gapX: x, gapY: c, ...b }, d) => /* @__PURE__ */ m.jsx(
271
278
  t,
272
279
  {
273
- className: m(
280
+ className: f(
274
281
  "flex",
275
282
  // Flex direction
276
283
  {
@@ -361,35 +368,35 @@ const y = ({ children: c, className: t, direction: n = "col", ...r }) => {
361
368
  "gap-x-16": x === "16"
362
369
  },
363
370
  {
364
- "gap-y-0": a === "0",
365
- "gap-y-1": a === "1",
366
- "gap-y-2": a === "2",
367
- "gap-y-3": a === "3",
368
- "gap-y-4": a === "4",
369
- "gap-y-5": a === "5",
370
- "gap-y-6": a === "6",
371
- "gap-y-7": a === "7",
372
- "gap-y-8": a === "8",
373
- "gap-y-9": a === "9",
374
- "gap-y-10": a === "10",
375
- "gap-y-11": a === "11",
376
- "gap-y-12": a === "12",
377
- "gap-y-13": a === "13",
378
- "gap-y-14": a === "14",
379
- "gap-y-15": a === "15",
380
- "gap-y-16": a === "16"
371
+ "gap-y-0": c === "0",
372
+ "gap-y-1": c === "1",
373
+ "gap-y-2": c === "2",
374
+ "gap-y-3": c === "3",
375
+ "gap-y-4": c === "4",
376
+ "gap-y-5": c === "5",
377
+ "gap-y-6": c === "6",
378
+ "gap-y-7": c === "7",
379
+ "gap-y-8": c === "8",
380
+ "gap-y-9": c === "9",
381
+ "gap-y-10": c === "10",
382
+ "gap-y-11": c === "11",
383
+ "gap-y-12": c === "12",
384
+ "gap-y-13": c === "13",
385
+ "gap-y-14": c === "14",
386
+ "gap-y-15": c === "15",
387
+ "gap-y-16": c === "16"
381
388
  },
382
- c
389
+ a
383
390
  ),
384
391
  ref: d,
385
392
  ...b
386
393
  }
387
394
  )
388
- ), i = Object.assign(N, { Item: j }), k = ({ children: c, className: t, ...n }) => /* @__PURE__ */ u.jsx(y, { as: "footer", className: m("bottom-0 mt-auto pb-2", t), justify: "between", ...n, children: c }), R = g.forwardRef(
389
- ({ className: c, as: t = "div", cols: n, rows: r, gap: e, gapX: o, gapY: l, flow: s, ...x }, a) => /* @__PURE__ */ u.jsx(
395
+ ), w = Object.assign(N, { Item: j }), k = ({ children: a, className: t, ...n }) => /* @__PURE__ */ m.jsx(g, { as: "footer", className: f("bottom-0 mt-auto pb-2", t), justify: "between", ...n, children: a }), R = y.forwardRef(
396
+ ({ className: a, as: t = "div", cols: n, rows: r, gap: e, gapX: o, gapY: l, flow: s, ...x }, c) => /* @__PURE__ */ m.jsx(
390
397
  t,
391
398
  {
392
- className: m(
399
+ className: f(
393
400
  "grid",
394
401
  {
395
402
  "grid-cols-1": n === "1",
@@ -498,31 +505,31 @@ const y = ({ children: c, className: t, direction: n = "col", ...r }) => {
498
505
  "grid-flow-row-dense": s === "row-dense",
499
506
  "grid-flow-col-dense": s === "col-dense"
500
507
  },
501
- c
508
+ a
502
509
  ),
503
- ref: a,
510
+ ref: c,
504
511
  ...x
505
512
  }
506
513
  )
507
514
  );
508
515
  R.displayName = "Grid";
509
- const C = ({ children: c, sticky: t = !1, className: n, ...r }) => /* @__PURE__ */ u.jsx(y, { as: "header", className: m("top-0 ", t && "z-50 sticky", n), justify: "between", ...r, children: c }), F = ({ children: c, className: t, withContainer: n = !1, ...r }) => {
510
- const e = m("flex-1 grow", t);
511
- return n ? /* @__PURE__ */ u.jsx(y, { as: "main", className: e, display: "block", ...r, children: c }) : /* @__PURE__ */ u.jsx(i.Item, { as: "main", className: e, ...r, children: c });
512
- }, B = g.forwardRef(({ children: c, className: t, ...n }, r) => /* @__PURE__ */ u.jsx(
513
- i,
516
+ const C = ({ children: a, sticky: t = !1, className: n, ...r }) => /* @__PURE__ */ m.jsx(g, { as: "header", className: f("top-0 ", t && "z-50 sticky", n), justify: "between", ...r, children: a }), F = ({ children: a, className: t, withContainer: n = !1, ...r }) => {
517
+ const e = f("flex-1 grow", t);
518
+ return n ? /* @__PURE__ */ m.jsx(g, { as: "main", className: e, display: "block", ...r, children: a }) : /* @__PURE__ */ m.jsx(w.Item, { as: "main", className: e, ...r, children: a });
519
+ }, B = y.forwardRef(({ children: a, className: t, ...n }, r) => /* @__PURE__ */ m.jsx(
520
+ w,
514
521
  {
515
- className: m("mx-auto w-full max-w-screen-xl h-screen flex-1", t),
522
+ className: f("mx-auto w-full max-w-screen-xl h-screen flex-1", t),
516
523
  direction: "col",
517
524
  ref: r,
518
525
  ...n,
519
- children: c
526
+ children: a
520
527
  }
521
528
  )), H = Object.assign(B, { Header: C, Body: F, Footer: k });
522
529
  export {
523
- w as B,
524
- y as C,
525
- i as F,
530
+ i as B,
531
+ g as C,
532
+ w as F,
526
533
  R as G,
527
534
  C as H,
528
535
  H as L,
@@ -1,7 +1,7 @@
1
1
  import { j as e } from "./jsx-runtime-B0GD0xBr.js";
2
- import { c, B as l } from "./calendar-D21xByT8.js";
2
+ import { c, B as l } from "./calendar-DfVsywp-.js";
3
3
  import "react";
4
- import { F as o, B as d } from "./Layout-DAdzkAxW.js";
4
+ import { F as o, B as d } from "./Layout-CjE5bQn7.js";
5
5
  import { C as m } from "./Code-DSfz_jrJ.js";
6
6
  import { H as h } from "./Heading-Bpvbpnw2.js";
7
7
  import { c as x } from "./index-CRiPKpXj.js";