@jirawatpyk/aura-tokens 4.17.0 → 4.18.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/README.md CHANGED
@@ -29,20 +29,12 @@ npm install @aura/tokens@npm:@jirawatpyk/aura-tokens @aura/react@npm:@jirawatpyk
29
29
 
30
30
  ```tsx
31
31
  // app/layout.tsx
32
- import '@aura/tokens/aura-fonts.css'; // Google Fonts (or use the <link> tags below instead)
32
+ import '@aura/tokens/aura-fonts.local.css'; // fonts, self-hosted from the package: works under a font-src 'self' CSP
33
33
  import '@aura/tokens/aura.css'; // tokens
34
34
  import '@aura/react/styles.css'; // component styles (with @aura/react)
35
35
  ```
36
36
 
37
- ```html
38
- <!-- Preferred: load the fonts from <head> instead of aura-fonts.css — faster, and a blocked host fails quietly -->
39
- <link rel="preconnect" href="https://fonts.googleapis.com" />
40
- <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
41
- <link
42
- rel="stylesheet"
43
- href="https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,600&family=Inter:wght@400;500;600&family=JetBrains+Mono:wght@400&family=Noto+Sans+Thai:wght@400;500;600&display=swap"
44
- />
45
- ```
37
+ Next.js can load the same families with `next/font` instead, and a site with no CSP can use Google Fonts (`aura-fonts.css` or `<link>` tags). Both are under Fonts below.
46
38
 
47
39
  ### Fonts
48
40
 
@@ -52,7 +44,17 @@ Pick one of three ways to load Fraunces, Inter, JetBrains Mono and Noto Sans Tha
52
44
  | ------------------ | --------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
53
45
  | Self-hosted (4.16) | Your CSP allows only `font-src 'self'`, or you want no third-party requests | `import '@jirawatpyk/aura-tokens/aura-fonts.local.css'` — woff2 files ship in the package (`fonts/`, OFL-1.1), split by unicode range so a page downloads only what it uses |
54
46
  | `next/font` | Next.js apps that want preloading and zero layout shift | Load the families with `next/font` and point the AURA font variables at them (below) |
55
- | Google Fonts | Anything else | The `<link>` tags below, or `aura-fonts.css` |
47
+ | Google Fonts | No CSP, or one that allows `fonts.googleapis.com` and `fonts.gstatic.com` | `aura-fonts.css`, or the `<link>` tags below (faster; a blocked host fails quietly) |
48
+
49
+ ```html
50
+ <!-- Google Fonts from <head> (only without a strict CSP) -->
51
+ <link rel="preconnect" href="https://fonts.googleapis.com" />
52
+ <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
53
+ <link
54
+ rel="stylesheet"
55
+ href="https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,600&family=Inter:wght@400;500;600&family=JetBrains+Mono:wght@400&family=Noto+Sans+Thai:wght@400;500;600&display=swap"
56
+ />
57
+ ```
56
58
 
57
59
  ```tsx
58
60
  // app/layout.tsx — next/font (downloads at build time and self-hosts, so font-src 'self' is enough)
package/aura-tailwind.css CHANGED
@@ -1,4 +1,4 @@
1
- /* AURA v4.17.0 — Tailwind v4 theme. GENERATED by scripts/build-tokens.js from tokens.json. Do not edit by hand.
1
+ /* AURA v4.18.0 — Tailwind v4 theme. GENERATED by scripts/build-tokens.js from tokens.json. Do not edit by hand.
2
2
  * @import "tailwindcss";
3
3
  * @import "@jirawatpyk/aura-tokens/tailwind.css";
4
4
  * Gives bg-bg-surface, text-fg-primary, border-border-strong, p-aura-6, rounded-aura-xl, shadow-aura-overlay,
@@ -1,4 +1,4 @@
1
- /* AURA v4.17.0 — Tailwind v4 theme with aura- prefixed names. GENERATED by scripts/build-tokens.js. Do not edit by hand.
1
+ /* AURA v4.18.0 — Tailwind v4 theme with aura- prefixed names. GENERATED by scripts/build-tokens.js. Do not edit by hand.
2
2
  * For apps that already have a Tailwind theme (shadcn): nothing here redefines an existing name.
3
3
  * @layer aura-tokens, theme, base, aura, components, utilities;
4
4
  * @import "tailwindcss";
package/aura.css CHANGED
@@ -1,4 +1,4 @@
1
- /* AURA v4.17.0 — GENERATED by scripts/build-tokens.js from tokens.json. Do not edit by hand. */
1
+ /* AURA v4.18.0 — GENERATED by scripts/build-tokens.js from tokens.json. Do not edit by hand. */
2
2
  /* Fonts: load aura-fonts.css (or the <link> tags in README) separately, so a blocked Google Fonts never breaks this file. */
3
3
 
4
4
  :root, [data-theme="light"] {
@@ -2901,8 +2901,8 @@ window.Aura = (() => {
2901
2901
  "data-autofocus": "",
2902
2902
  type: "text",
2903
2903
  role: "combobox",
2904
- "aria-expanded": true,
2905
- "aria-controls": listId,
2904
+ "aria-expanded": flat.length > 0,
2905
+ "aria-controls": flat.length ? listId : void 0,
2906
2906
  "aria-autocomplete": "list",
2907
2907
  "aria-activedescendant": active >= 0 ? optId(active) : void 0,
2908
2908
  "aria-label": props.label || t.commandMenu,
@@ -2918,17 +2918,15 @@ window.Aura = (() => {
2918
2918
  onKeyDown: onKey
2919
2919
  }
2920
2920
  ), /* @__PURE__ */ React25.createElement("kbd", { className: "aura-command__kbd" }, "Esc")),
2921
- /* @__PURE__ */ React25.createElement(
2921
+ /* @__PURE__ */ React25.createElement("div", { className: "aura-command__list", "aria-busy": props.loading || void 0 }, props.loading ? /* @__PURE__ */ React25.createElement("div", { className: "aura-command__loading" }, /* @__PURE__ */ React25.createElement(Icon, { name: "loader-circle", className: "aura-spin" }), t.searching) : null, !flat.length ? props.loading ? null : /* @__PURE__ */ React25.createElement("div", { className: "aura-command__empty" }, props.empty != null ? props.empty : props.emptyText || t.noMatches) : /* @__PURE__ */ React25.createElement(
2922
2922
  "div",
2923
2923
  {
2924
- className: "aura-command__list",
2925
2924
  id: listId,
2926
2925
  role: "listbox",
2927
2926
  "aria-label": props.label || t.commandMenu,
2928
2927
  "aria-busy": props.loading || void 0
2929
2928
  },
2930
- props.loading ? /* @__PURE__ */ React25.createElement("div", { className: "aura-command__loading", role: "presentation" }, /* @__PURE__ */ React25.createElement(Icon, { name: "loader-circle", className: "aura-spin" }), t.searching) : null,
2931
- !flat.length ? props.loading ? null : /* @__PURE__ */ React25.createElement("div", { className: "aura-command__empty", role: "presentation" }, props.empty != null ? props.empty : props.emptyText || t.noMatches) : groups.map(function(g, gi) {
2929
+ groups.map(function(g, gi) {
2932
2930
  const gid = id + "-g" + gi;
2933
2931
  return /* @__PURE__ */ React25.createElement(
2934
2932
  "div",
@@ -2950,7 +2948,11 @@ window.Aura = (() => {
2950
2948
  role: "option",
2951
2949
  "aria-selected": n2 === active,
2952
2950
  "aria-disabled": it.disabled || void 0,
2953
- className: cx("aura-command__item", n2 === active && "is-active", it.disabled && "is-disabled"),
2951
+ className: cx(
2952
+ "aura-command__item",
2953
+ n2 === active && "is-active",
2954
+ it.disabled && "is-disabled"
2955
+ ),
2954
2956
  onPointerDown: function(e) {
2955
2957
  e.preventDefault();
2956
2958
  },
@@ -2968,8 +2970,8 @@ window.Aura = (() => {
2968
2970
  })
2969
2971
  );
2970
2972
  })
2971
- ),
2972
- /* @__PURE__ */ React25.createElement("span", { className: "aura-sr-only", role: "status" }, props.loading ? t.searching : props.loading === false && query ? t.results(flat.length) : ""),
2973
+ )),
2974
+ /* @__PURE__ */ React25.createElement("span", { className: "aura-sr-only", role: "status" }, props.loading ? t.searching : query && !flat.length ? t.noMatches : props.loading === false && query ? t.results(flat.length) : ""),
2973
2975
  /* @__PURE__ */ React25.createElement("div", { className: "aura-command__foot", "aria-hidden": true }, t.commandHint, /* @__PURE__ */ React25.createElement("span", { className: "aura-command__mod" }, isMac() ? "\u2318K" : "Ctrl K"))
2974
2976
  )
2975
2977
  ),
@@ -693,7 +693,8 @@ a.aura-icon-btn { text-decoration: none; }
693
693
  .aura-combo__text { flex: 1; min-width: 0; display: flex; flex-direction: column; }
694
694
  .aura-combo__label { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
695
695
  .aura-combo__desc { font-size: 12px; line-height: 1.5; color: var(--aura-fg-secondary); }
696
- .aura-combo__check { color: var(--aura-fg-accent) !important; }
696
+ /* Same specificity as `.aura-combo__option > .aura-icon` above and later in the file, so it wins by order (4.18). */
697
+ .aura-combo__option > .aura-combo__check { color: var(--aura-fg-accent); }
697
698
  .aura-combo__note { display: flex; align-items: center; gap: var(--aura-space-2); padding: var(--aura-space-3) var(--aura-space-2); font-size: 13px; color: var(--aura-fg-secondary); }
698
699
 
699
700
  /* ---------- DatePicker / Calendar ---------- */
@@ -1174,7 +1175,9 @@ button.aura-stepper__step:hover .aura-stepper__label { text-decoration: underlin
1174
1175
  .aura-stepper--horizontal .aura-stepper__item:not(:last-child)::after { right: 8px; }
1175
1176
  .aura-stepper--horizontal .aura-stepper__compact { display: block; }
1176
1177
  .aura-dialog-layer:not(.aura-drawer-layer) { align-items: flex-end; padding: 0; }
1177
- .aura-dialog { max-width: none !important; max-height: 92vh; max-height: 92dvh; border-radius: var(--aura-radius-2xl) var(--aura-radius-2xl) 0 0; border-bottom: 0;
1178
+ /* The size classes set max-width; naming them here outranks them by specificity (4.18). */
1179
+ .aura-dialog.aura-dialog--sm, .aura-dialog.aura-dialog--md, .aura-dialog.aura-dialog--lg { max-width: none; }
1180
+ .aura-dialog { max-height: 92vh; max-height: 92dvh; border-radius: var(--aura-radius-2xl) var(--aura-radius-2xl) 0 0; border-bottom: 0;
1178
1181
  padding-bottom: calc(var(--aura-space-6) + env(safe-area-inset-bottom)); animation-name: aura-sheet-in; }
1179
1182
  .aura-dialog__foot { flex-direction: column-reverse; }
1180
1183
  .aura-dialog__foot > * { width: 100%; }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jirawatpyk/aura-tokens",
3
- "version": "4.17.0",
3
+ "version": "4.18.0",
4
4
  "description": "AURA Design System — tokens (CSS variables, Tailwind preset, Figma variables), theme contrast checks and token lint.",
5
5
  "main": "tailwind.tokens.cjs",
6
6
  "types": "components/index.d.ts",
package/tokens.json CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "4.17.0",
2
+ "version": "4.18.0",
3
3
  "meta": {
4
4
  "name": "AURA Design System",
5
5
  "tier": "3-tier",