@jirawatpyk/aura-react 5.23.0 → 5.24.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 +4 -0
- package/dist/index.d.cts +11 -9
- package/dist/index.d.ts +11 -9
- package/dist/server/index.d.cts +3 -2
- package/dist/server/index.d.ts +3 -2
- package/dist/styles.css +4 -2
- package/dist/styles.layer.css +4 -2
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -186,6 +186,10 @@ DataTable with sort and page in the URL (4.17): `onStateChange={({ sort, page })
|
|
|
186
186
|
- **Time zone**: `timeZone` on AuraProvider, DatePicker, DateRangePicker and Calendar decides "today" (the marker, `min`/`max="today"`, the first month shown); or pass `today` as an ISO date. `todayIn('Asia/Bangkok')` is exported from the root and `/server`.
|
|
187
187
|
- **Toasts** queue past three instead of dropping: six in a row all show, in order, three at a time.
|
|
188
188
|
|
|
189
|
+
## 5.24 — Chamber-OS addendum 26
|
|
190
|
+
|
|
191
|
+
- **`touchHeight` follows the pointer, not only the width** (item 123): Button, IconButton and the ActionBar Clear are 44px wherever the primary pointer is coarse — a tablet in portrait (768px) or landscape (1024–1366px) — as well as below 640px. With a mouse (`pointer: fine`) from 640px up nothing changes. Visible on tablets for every control that already passes `touchHeight`. A touch laptop reports its trackpad as the primary pointer (`pointer: fine`), so it keeps the compact size, as AURA's other touch rules do.
|
|
192
|
+
|
|
189
193
|
## 5.23 — Chamber-OS addenda 23–25
|
|
190
194
|
|
|
191
195
|
- **DataTable `card: 'wide'`** (item 120): in a stacked card the column is a field on a line of its own at the card's full inner width, after the half-width fields (and before a `footer`), its label above and its text wrapping — a reason with its evidence line. The grid is unchanged (an ordinary column at its `width`).
|
package/dist/index.d.cts
CHANGED
|
@@ -20,8 +20,9 @@ export interface ButtonProps extends React$1.ButtonHTMLAttributes<HTMLButtonElem
|
|
|
20
20
|
fullWidth?: boolean | undefined;
|
|
21
21
|
/** `sm` is 32px with tighter padding, for toolbars, table rows and card footers. Default `md` (44px). */
|
|
22
22
|
size?: ButtonSize | undefined;
|
|
23
|
-
/** 44px tall below 640px (the viewport's)
|
|
24
|
-
* (5.15, Chamber-OS 100).
|
|
23
|
+
/** 44px tall below 640px (the viewport's) or wherever the primary pointer is coarse (a tablet, 5.24), whatever
|
|
24
|
+
* `size` — a small button that touch screens get at full touch height (5.15, Chamber-OS 100). With a mouse from
|
|
25
|
+
* 640px up it keeps its size. */
|
|
25
26
|
touchHeight?: boolean | undefined;
|
|
26
27
|
}
|
|
27
28
|
/** A link that looks like a Button: give `Button` an `href` and it renders an `<a>` (navigation, not actions). */
|
|
@@ -41,8 +42,9 @@ export interface ButtonLinkProps extends Omit<React$1.AnchorHTMLAttributes<HTMLA
|
|
|
41
42
|
fullWidth?: boolean | undefined;
|
|
42
43
|
/** `sm` is 32px with tighter padding. Default `md` (44px). */
|
|
43
44
|
size?: ButtonSize | undefined;
|
|
44
|
-
/** 44px tall below 640px (the viewport's)
|
|
45
|
-
* (5.15, Chamber-OS 100).
|
|
45
|
+
/** 44px tall below 640px (the viewport's) or wherever the primary pointer is coarse (a tablet, 5.24), whatever
|
|
46
|
+
* `size` — a small button that touch screens get at full touch height (5.15, Chamber-OS 100). With a mouse from
|
|
47
|
+
* 640px up it keeps its size. */
|
|
46
48
|
touchHeight?: boolean | undefined;
|
|
47
49
|
/** A router's link to render instead of `<a>`, e.g. `Link` from `next/link` (client-side navigation). It gets `href`, `className`, the children and the ref. */
|
|
48
50
|
linkComponent?: React$1.ElementType | undefined;
|
|
@@ -321,8 +323,8 @@ export interface IconButtonProps extends React$1.ButtonHTMLAttributes<HTMLButton
|
|
|
321
323
|
label: string;
|
|
322
324
|
/** Icon size. Default `sm` (16). */
|
|
323
325
|
size?: "sm" | "md" | undefined;
|
|
324
|
-
/** 44×44 below 640px (the viewport's)
|
|
325
|
-
* (5.15, Chamber-OS 100). */
|
|
326
|
+
/** 44×44 instead of 32×32 below 640px (the viewport's) or wherever the primary pointer is coarse (a tablet, 5.24) —
|
|
327
|
+
* a phone sheet's close button, a card's ⋯ trigger (5.15, Chamber-OS 100). */
|
|
326
328
|
touchHeight?: boolean | undefined;
|
|
327
329
|
}
|
|
328
330
|
export interface MenuItem {
|
|
@@ -1074,7 +1076,7 @@ export interface DrawerProps extends Pick<React$1.HTMLAttributes<HTMLDivElement>
|
|
|
1074
1076
|
* built-in "Close" in the provider's language. (5.9) */
|
|
1075
1077
|
closeLabel?: string | undefined;
|
|
1076
1078
|
/** Attributes for the close button, e.g. `{ 'data-testid': 'pay-sheet-close' }` (5.9), or `touchHeight: true` for a
|
|
1077
|
-
* 44px close button on phones (5.15). */
|
|
1079
|
+
* 44px close button on phones and tablets (5.15, 5.24). */
|
|
1078
1080
|
closeProps?: (ButtonAttributes & {
|
|
1079
1081
|
touchHeight?: boolean | undefined;
|
|
1080
1082
|
}) | undefined;
|
|
@@ -1203,8 +1205,8 @@ export interface ActionBarProps {
|
|
|
1203
1205
|
selected?: number | undefined;
|
|
1204
1206
|
/** Adds a "Clear" button next to the count. */
|
|
1205
1207
|
onClearSelection?: (() => void) | undefined;
|
|
1206
|
-
/** 5.23 (Chamber-OS 122): the bar's own Clear button takes Button's `touchHeight` — 44px below 640px
|
|
1207
|
-
* action buttons that use it. */
|
|
1208
|
+
/** 5.23 (Chamber-OS 122): the bar's own Clear button takes Button's `touchHeight` — 44px below 640px or on a
|
|
1209
|
+
* coarse pointer — to match action buttons that use it. */
|
|
1208
1210
|
touchHeight?: boolean | undefined;
|
|
1209
1211
|
/** Name of the region. Default "Actions". */
|
|
1210
1212
|
label?: string | undefined;
|
package/dist/index.d.ts
CHANGED
|
@@ -20,8 +20,9 @@ export interface ButtonProps extends React$1.ButtonHTMLAttributes<HTMLButtonElem
|
|
|
20
20
|
fullWidth?: boolean | undefined;
|
|
21
21
|
/** `sm` is 32px with tighter padding, for toolbars, table rows and card footers. Default `md` (44px). */
|
|
22
22
|
size?: ButtonSize | undefined;
|
|
23
|
-
/** 44px tall below 640px (the viewport's)
|
|
24
|
-
* (5.15, Chamber-OS 100).
|
|
23
|
+
/** 44px tall below 640px (the viewport's) or wherever the primary pointer is coarse (a tablet, 5.24), whatever
|
|
24
|
+
* `size` — a small button that touch screens get at full touch height (5.15, Chamber-OS 100). With a mouse from
|
|
25
|
+
* 640px up it keeps its size. */
|
|
25
26
|
touchHeight?: boolean | undefined;
|
|
26
27
|
}
|
|
27
28
|
/** A link that looks like a Button: give `Button` an `href` and it renders an `<a>` (navigation, not actions). */
|
|
@@ -41,8 +42,9 @@ export interface ButtonLinkProps extends Omit<React$1.AnchorHTMLAttributes<HTMLA
|
|
|
41
42
|
fullWidth?: boolean | undefined;
|
|
42
43
|
/** `sm` is 32px with tighter padding. Default `md` (44px). */
|
|
43
44
|
size?: ButtonSize | undefined;
|
|
44
|
-
/** 44px tall below 640px (the viewport's)
|
|
45
|
-
* (5.15, Chamber-OS 100).
|
|
45
|
+
/** 44px tall below 640px (the viewport's) or wherever the primary pointer is coarse (a tablet, 5.24), whatever
|
|
46
|
+
* `size` — a small button that touch screens get at full touch height (5.15, Chamber-OS 100). With a mouse from
|
|
47
|
+
* 640px up it keeps its size. */
|
|
46
48
|
touchHeight?: boolean | undefined;
|
|
47
49
|
/** A router's link to render instead of `<a>`, e.g. `Link` from `next/link` (client-side navigation). It gets `href`, `className`, the children and the ref. */
|
|
48
50
|
linkComponent?: React$1.ElementType | undefined;
|
|
@@ -321,8 +323,8 @@ export interface IconButtonProps extends React$1.ButtonHTMLAttributes<HTMLButton
|
|
|
321
323
|
label: string;
|
|
322
324
|
/** Icon size. Default `sm` (16). */
|
|
323
325
|
size?: "sm" | "md" | undefined;
|
|
324
|
-
/** 44×44 below 640px (the viewport's)
|
|
325
|
-
* (5.15, Chamber-OS 100). */
|
|
326
|
+
/** 44×44 instead of 32×32 below 640px (the viewport's) or wherever the primary pointer is coarse (a tablet, 5.24) —
|
|
327
|
+
* a phone sheet's close button, a card's ⋯ trigger (5.15, Chamber-OS 100). */
|
|
326
328
|
touchHeight?: boolean | undefined;
|
|
327
329
|
}
|
|
328
330
|
export interface MenuItem {
|
|
@@ -1074,7 +1076,7 @@ export interface DrawerProps extends Pick<React$1.HTMLAttributes<HTMLDivElement>
|
|
|
1074
1076
|
* built-in "Close" in the provider's language. (5.9) */
|
|
1075
1077
|
closeLabel?: string | undefined;
|
|
1076
1078
|
/** Attributes for the close button, e.g. `{ 'data-testid': 'pay-sheet-close' }` (5.9), or `touchHeight: true` for a
|
|
1077
|
-
* 44px close button on phones (5.15). */
|
|
1079
|
+
* 44px close button on phones and tablets (5.15, 5.24). */
|
|
1078
1080
|
closeProps?: (ButtonAttributes & {
|
|
1079
1081
|
touchHeight?: boolean | undefined;
|
|
1080
1082
|
}) | undefined;
|
|
@@ -1203,8 +1205,8 @@ export interface ActionBarProps {
|
|
|
1203
1205
|
selected?: number | undefined;
|
|
1204
1206
|
/** Adds a "Clear" button next to the count. */
|
|
1205
1207
|
onClearSelection?: (() => void) | undefined;
|
|
1206
|
-
/** 5.23 (Chamber-OS 122): the bar's own Clear button takes Button's `touchHeight` — 44px below 640px
|
|
1207
|
-
* action buttons that use it. */
|
|
1208
|
+
/** 5.23 (Chamber-OS 122): the bar's own Clear button takes Button's `touchHeight` — 44px below 640px or on a
|
|
1209
|
+
* coarse pointer — to match action buttons that use it. */
|
|
1208
1210
|
touchHeight?: boolean | undefined;
|
|
1209
1211
|
/** Name of the region. Default "Actions". */
|
|
1210
1212
|
label?: string | undefined;
|
package/dist/server/index.d.cts
CHANGED
|
@@ -20,8 +20,9 @@ export interface ButtonProps extends React$1.ButtonHTMLAttributes<HTMLButtonElem
|
|
|
20
20
|
fullWidth?: boolean | undefined;
|
|
21
21
|
/** `sm` is 32px with tighter padding, for toolbars, table rows and card footers. Default `md` (44px). */
|
|
22
22
|
size?: ButtonSize | undefined;
|
|
23
|
-
/** 44px tall below 640px (the viewport's)
|
|
24
|
-
* (5.15, Chamber-OS 100).
|
|
23
|
+
/** 44px tall below 640px (the viewport's) or wherever the primary pointer is coarse (a tablet, 5.24), whatever
|
|
24
|
+
* `size` — a small button that touch screens get at full touch height (5.15, Chamber-OS 100). With a mouse from
|
|
25
|
+
* 640px up it keeps its size. */
|
|
25
26
|
touchHeight?: boolean | undefined;
|
|
26
27
|
}
|
|
27
28
|
/** An AURA icon name, or any icon element (e.g. `<Building />` from lucide-react). AURA sizes it and hides it from screen readers. */
|
package/dist/server/index.d.ts
CHANGED
|
@@ -20,8 +20,9 @@ export interface ButtonProps extends React$1.ButtonHTMLAttributes<HTMLButtonElem
|
|
|
20
20
|
fullWidth?: boolean | undefined;
|
|
21
21
|
/** `sm` is 32px with tighter padding, for toolbars, table rows and card footers. Default `md` (44px). */
|
|
22
22
|
size?: ButtonSize | undefined;
|
|
23
|
-
/** 44px tall below 640px (the viewport's)
|
|
24
|
-
* (5.15, Chamber-OS 100).
|
|
23
|
+
/** 44px tall below 640px (the viewport's) or wherever the primary pointer is coarse (a tablet, 5.24), whatever
|
|
24
|
+
* `size` — a small button that touch screens get at full touch height (5.15, Chamber-OS 100). With a mouse from
|
|
25
|
+
* 640px up it keeps its size. */
|
|
25
26
|
touchHeight?: boolean | undefined;
|
|
26
27
|
}
|
|
27
28
|
/** An AURA icon name, or any icon element (e.g. `<Building />` from lucide-react). AURA sizes it and hides it from screen readers. */
|
package/dist/styles.css
CHANGED
|
@@ -312,8 +312,10 @@ a.aura-icon-btn { text-decoration: none; }
|
|
|
312
312
|
.aura-icon-btn--danger:hover { background: var(--aura-alert-danger-bg); }
|
|
313
313
|
.aura-icon-btn:disabled { opacity: var(--aura-disabled-opacity); pointer-events: none; }
|
|
314
314
|
.aura-icon-btn:focus-visible { outline: var(--aura-focus-ring-width) solid var(--aura-focus-ring); outline-offset: var(--aura-focus-ring-offset); }
|
|
315
|
-
/* 5.15 (Chamber-OS 100): touchHeight — visibly 44px on phones, for buttons and icon buttons a phone design wants full size.
|
|
316
|
-
|
|
315
|
+
/* 5.15 (Chamber-OS 100): touchHeight — visibly 44px on phones, for buttons and icon buttons a phone design wants full size.
|
|
316
|
+
* 5.24 (Chamber-OS 123): also wherever the primary pointer is coarse — a tablet at 768–1366px is a finger, not a mouse.
|
|
317
|
+
* A mouse on a wide screen (pointer: fine) keeps the compact size. */
|
|
318
|
+
@media (max-width: 639.98px), (pointer: coarse) {
|
|
317
319
|
.aura-btn.aura-btn--touch { height: var(--aura-touch-target); }
|
|
318
320
|
.aura-btn.aura-btn--touch.aura-btn--full { height: auto; min-height: var(--aura-touch-target); }
|
|
319
321
|
.aura-icon-btn.aura-icon-btn--touch { width: var(--aura-touch-target); height: var(--aura-touch-target); }
|
package/dist/styles.layer.css
CHANGED
|
@@ -314,8 +314,10 @@ a.aura-icon-btn { text-decoration: none; }
|
|
|
314
314
|
.aura-icon-btn--danger:hover { background: var(--aura-alert-danger-bg); }
|
|
315
315
|
.aura-icon-btn:disabled { opacity: var(--aura-disabled-opacity); pointer-events: none; }
|
|
316
316
|
.aura-icon-btn:focus-visible { outline: var(--aura-focus-ring-width) solid var(--aura-focus-ring); outline-offset: var(--aura-focus-ring-offset); }
|
|
317
|
-
/* 5.15 (Chamber-OS 100): touchHeight — visibly 44px on phones, for buttons and icon buttons a phone design wants full size.
|
|
318
|
-
|
|
317
|
+
/* 5.15 (Chamber-OS 100): touchHeight — visibly 44px on phones, for buttons and icon buttons a phone design wants full size.
|
|
318
|
+
* 5.24 (Chamber-OS 123): also wherever the primary pointer is coarse — a tablet at 768–1366px is a finger, not a mouse.
|
|
319
|
+
* A mouse on a wide screen (pointer: fine) keeps the compact size. */
|
|
320
|
+
@media (max-width: 639.98px), (pointer: coarse) {
|
|
319
321
|
.aura-btn.aura-btn--touch { height: var(--aura-touch-target); }
|
|
320
322
|
.aura-btn.aura-btn--touch.aura-btn--full { height: auto; min-height: var(--aura-touch-target); }
|
|
321
323
|
.aura-icon-btn.aura-icon-btn--touch { width: var(--aura-touch-target); height: var(--aura-touch-target); }
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@jirawatpyk/aura-react",
|
|
3
|
-
"version": "5.
|
|
3
|
+
"version": "5.24.0",
|
|
4
4
|
"description": "AURA Design System — React components (Enterprise Standard, Human Creative). Thai-first: Buddhist-era dates, Thai collation.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|