@gears-frontx/ui-kit 0.4.9 → 0.5.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/switch.js CHANGED
@@ -1,12 +1,12 @@
1
1
  import { jsx as s } from "react/jsx-runtime";
2
2
  import { Switch as e } from "@base-ui/react/switch";
3
- import { cva as m } from "class-variance-authority";
4
- import './chunks/switch.D3_ZyuVP.css';const o = "_sizeDefault_1cp3e_10", u = "_sizeSm_1cp3e_10", h = "_thumb_1cp3e_87", t = {
5
- switch: "_switch_1cp3e_6",
6
- sizeDefault: o,
7
- sizeSm: u,
8
- thumb: h
9
- }, r = m(t.switch, {
3
+ import { cva as c } from "class-variance-authority";
4
+ import './chunks/switch.BYqd9jlJ.css';const h = "_sizeDefault_1l0he_10", l = "_sizeSm_1l0he_10", o = "_thumb_1l0he_87", t = {
5
+ switch: "_switch_1l0he_6",
6
+ sizeDefault: h,
7
+ sizeSm: l,
8
+ thumb: o
9
+ }, u = c(t.switch, {
10
10
  variants: {
11
11
  size: {
12
12
  default: t.sizeDefault,
@@ -17,10 +17,10 @@ import './chunks/switch.D3_ZyuVP.css';const o = "_sizeDefault_1cp3e_10", u = "_s
17
17
  size: "default"
18
18
  }
19
19
  });
20
- function l({ className: i, size: c, ...a }) {
21
- return /* @__PURE__ */ s(e.Root, { className: r({ size: c, className: i }), ...a, children: /* @__PURE__ */ s(e.Thumb, { className: t.thumb }) });
20
+ function f({ className: i, size: a, ...m }) {
21
+ return /* @__PURE__ */ s(e.Root, { className: u({ size: a, className: i }), ...m, children: /* @__PURE__ */ s(e.Thumb, { className: t.thumb }) });
22
22
  }
23
23
  export {
24
- l as Switch
24
+ f as Switch
25
25
  };
26
26
  //# sourceMappingURL=switch.js.map
package/llms.txt CHANGED
@@ -284,6 +284,15 @@ Rules for generated code:
284
284
  htmlFor/aria-describedby wiring — wire `FieldLabel`'s `htmlFor` to the
285
285
  control's `id` yourself, same as upstream shadcn; `data-invalid`/
286
286
  `data-disabled` are plain attributes you set, not derived state.
287
+ - [Grid](dist/docs/grid.md): ordered block layout on 12 columns that
288
+ reacts to its own container width (Grid/GridItem); items declare a size
289
+ class small|medium|large (by default every span is 3, 6 or 12
290
+ columns) and a height low|high (one or two fixed row tracks), never a
291
+ span, plus a `layoutId` unique within the Grid. `flexible` on a Grid
292
+ lets spans move inside their ranges to fill rows. Direct GridItem
293
+ children only. A custom config starts from the shipped
294
+ `grid-default-config.json` and needs its CSS from the
295
+ `frontx-ui-grid-css` command, imported once.
287
296
  - [Heading](dist/docs/heading.md): a heading on the type ramp;
288
297
  typography display|heading-1|heading-2 picks the role, `render` picks
289
298
  the element (default `h2`), so the outline level and the look stay
package/package.json CHANGED
@@ -1,9 +1,10 @@
1
1
  {
2
2
  "name": "@gears-frontx/ui-kit",
3
- "version": "0.4.9",
3
+ "version": "0.5.0",
4
4
  "description": "Standard React component base for FrontX templates - Base UI behavior, CSS Modules styling on semantic tokens, CVA variants",
5
5
  "type": "module",
6
6
  "types": "./dist/index.d.ts",
7
+ "bin": { "frontx-ui-grid-css": "./dist/frontx-ui-grid-css.mjs" },
7
8
  "exports": {
8
9
  ".": {
9
10
  "types": "./dist/index.d.ts",
@@ -19,7 +20,8 @@
19
20
  },
20
21
  "./theme.css": "./dist/theme.css",
21
22
  "./utilities.css": "./dist/utilities.css",
22
- "./typeset.css": "./dist/typeset.css"
23
+ "./typeset.css": "./dist/typeset.css",
24
+ "./grid-default-config.json": "./dist/grid-default-config.json"
23
25
  },
24
26
  "files": [
25
27
  "dist",
@@ -39,7 +41,8 @@
39
41
  "test:consumer": "bash scripts/verify-consumer.sh",
40
42
  "contracts:compile": "tsx scripts/contracts/compile.ts",
41
43
  "contracts:check": "tsx scripts/contracts/check.ts",
42
- "contracts:enrollment": "tsx scripts/contracts/check.ts enrollment"
44
+ "contracts:enrollment": "tsx scripts/contracts/check.ts enrollment",
45
+ "grid:css": "node scripts/frontx-ui-grid-css.mjs --kit-default src/components/grid/grid-default-config.json src/components/grid/grid-steps.css"
43
46
  },
44
47
  "dependencies": {
45
48
  "@atlaskit/pragmatic-drag-and-drop": "1.7.7",
@@ -1 +0,0 @@
1
- ._switch_1cp3e_6{box-sizing:border-box;position:relative;display:inline-flex;align-items:center;flex-shrink:0;padding:0;border:var(--border-width) solid transparent;border-radius:var(--radius-full);outline:none;transition:background-color .15s ease,border-color .15s ease,box-shadow .15s ease}._switch_1cp3e_6:after{content:"";position:absolute;inset:calc(-1 * var(--space-2)) calc(-1 * var(--space-3))}._switch_1cp3e_6[data-checked]{background-color:var(--primary)}._switch_1cp3e_6[data-unchecked]{background-color:var(--input)}._switch_1cp3e_6:focus-visible{outline:var(--border-width-focus) solid var(--ring);outline-offset:2px}@media(forced-colors:active){._switch_1cp3e_6:focus-visible{outline:2px solid Highlight;outline-offset:2px}}._switch_1cp3e_6[data-disabled]{cursor:not-allowed;opacity:var(--opacity-disabled)}._switch_1cp3e_6[aria-invalid=true]{border-color:var(--destructive)}._sizeDefault_1cp3e_10{height:1.375rem;width:2.375rem}._sizeSm_1cp3e_10{height:.875rem;width:1.5rem}._thumb_1cp3e_87{pointer-events:none;display:block;border-radius:var(--radius-full);background-color:var(--primary-foreground);transition:transform .15s ease}@media(prefers-reduced-motion:reduce){._thumb_1cp3e_87{transition:none}}._sizeDefault_1cp3e_10 ._thumb_1cp3e_87{width:1rem;height:1rem;margin-inline-start:2px}._sizeDefault_1cp3e_10 ._thumb_1cp3e_87[data-checked]{transform:translate(100%)}._sizeSm_1cp3e_10 ._thumb_1cp3e_87{width:.75rem;height:.75rem}._thumb_1cp3e_87[data-checked]{transform:translate(calc(100% - 2px))}._thumb_1cp3e_87[data-unchecked]{transform:translate(0)}