@jirawatpyk/aura-react 5.4.0 → 5.6.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 +30 -0
- package/dist/aura.bundle.js +183 -40
- package/dist/cjs/index.cjs +183 -40
- package/dist/esm/DataTable.js +37 -14
- package/dist/esm/Toaster.js +148 -28
- package/dist/index.d.cts +62 -26
- package/dist/index.d.ts +62 -26
- package/dist/styles.css +25 -4
- package/dist/styles.layer.css +25 -4
- package/package.json +1 -1
package/dist/styles.layer.css
CHANGED
|
@@ -498,7 +498,9 @@ a.aura-icon-btn { text-decoration: none; }
|
|
|
498
498
|
display: flex; flex-direction: column; gap: var(--aura-space-2); width: min(380px, calc(100vw - 2 * var(--aura-space-4)));
|
|
499
499
|
font-family: var(--font-sans);
|
|
500
500
|
}
|
|
501
|
-
.aura-toaster.is-top { bottom: auto; top: var(--aura-space-6); }
|
|
501
|
+
.aura-toaster.is-top { bottom: auto; top: calc(var(--aura-toaster-offset, var(--aura-space-6)) + env(safe-area-inset-top, 0px)); }
|
|
502
|
+
/* 5.6: top-center / bottom-center; `offset` (or --aura-toaster-offset) clears an app's top bar. */
|
|
503
|
+
.aura-toaster.is-center { right: auto; left: 50%; transform: translateX(-50%); }
|
|
502
504
|
.aura-toast {
|
|
503
505
|
display: flex; align-items: flex-start; gap: var(--aura-space-3); padding: var(--aura-space-3) var(--aura-space-2) var(--aura-space-3) var(--aura-space-4);
|
|
504
506
|
background: var(--aura-bg-surface); color: var(--aura-fg-primary);
|
|
@@ -513,10 +515,27 @@ a.aura-icon-btn { text-decoration: none; }
|
|
|
513
515
|
.aura-toast__body { flex: 1; min-width: 0; padding-top: 1px; }
|
|
514
516
|
.aura-toast__title { margin: 0; font-size: 14px; font-weight: 500; line-height: 20px; }
|
|
515
517
|
.aura-toast__text { margin: 2px 0 0; font-size: 13px; line-height: 1.5; color: var(--aura-fg-secondary); }
|
|
518
|
+
.aura-toast__text > * { margin: 0; }
|
|
519
|
+
.aura-toast__text a { color: var(--aura-fg-accent); text-underline-offset: 2px; }
|
|
520
|
+
.aura-toast__text a:focus-visible { outline: var(--aura-focus-ring-width) solid var(--aura-focus-ring); outline-offset: 1px; border-radius: var(--aura-radius-xs); }
|
|
521
|
+
.aura-toast__actions { flex: none; align-self: center; display: flex; gap: var(--aura-space-1); }
|
|
522
|
+
/* Two actions, or one under a description (5.6): the actions take a row of their own below the text, lined up with it
|
|
523
|
+
* (the action's own padding sits left of the text column), so the text keeps the toast's width. */
|
|
524
|
+
.aura-toast.has-action-row { flex-wrap: wrap; row-gap: var(--aura-space-1); }
|
|
525
|
+
.aura-toast.has-action-row .aura-toast__body { flex-basis: 0; }
|
|
526
|
+
.aura-toast.has-action-row .aura-toast__actions { order: 3; flex-basis: 100%; flex-wrap: wrap; margin-left: calc(16px + var(--aura-space-3) - var(--aura-space-2)); margin-bottom: calc(-1 * var(--aura-space-1)); }
|
|
516
527
|
.aura-toast__action {
|
|
517
528
|
flex: none; align-self: center; height: var(--aura-control-sm); padding: 0 var(--aura-space-2);
|
|
518
529
|
border: 0; border-radius: var(--aura-radius-sm); background: transparent; color: var(--aura-fg-accent);
|
|
519
530
|
font: inherit; font-size: 13px; font-weight: 500; cursor: pointer;
|
|
531
|
+
display: inline-flex; align-items: center; text-decoration: none; white-space: nowrap;
|
|
532
|
+
}
|
|
533
|
+
/* Touch (5.6): the 32px action gets a 44px hit area, as IconButton does. Links in the text only get a little padding —
|
|
534
|
+
* lines sit 20px apart, so a 44px box would overlap the next line's link. */
|
|
535
|
+
@media (pointer: coarse) {
|
|
536
|
+
.aura-toast__action { position: relative; }
|
|
537
|
+
.aura-toast__action::after { content: ''; position: absolute; top: 50%; left: 50%; width: max(100%, var(--aura-touch-target)); height: max(100%, var(--aura-touch-target)); transform: translate(-50%, -50%); }
|
|
538
|
+
.aura-toast__text a { padding-block: 2px; }
|
|
520
539
|
}
|
|
521
540
|
.aura-toast__action:hover { background: var(--aura-bg-surface-hover); }
|
|
522
541
|
.aura-toast__action:focus-visible { outline: var(--aura-focus-ring-width) solid var(--aura-focus-ring); outline-offset: 0; }
|
|
@@ -1205,6 +1224,8 @@ button.aura-stepper__step:hover .aura-stepper__label { text-decoration: underlin
|
|
|
1205
1224
|
.aura-dialog__foot > * { width: 100%; }
|
|
1206
1225
|
.aura-drawer:not(.aura-drawer--nav) { max-width: none; }
|
|
1207
1226
|
.aura-toaster { left: var(--aura-space-4); right: var(--aura-space-4); bottom: var(--aura-space-4); width: auto; }
|
|
1227
|
+
.aura-toaster.is-center { left: var(--aura-space-4); right: var(--aura-space-4); transform: none; }
|
|
1228
|
+
.aura-toaster.is-top { top: calc(var(--aura-toaster-offset, var(--aura-space-4)) + env(safe-area-inset-top, 0px)); }
|
|
1208
1229
|
.aura-card { padding: var(--aura-space-4); }
|
|
1209
1230
|
.aura-stat { padding: var(--aura-space-4); }
|
|
1210
1231
|
.aura-stat__value { font-size: 24px; }
|
|
@@ -1387,9 +1408,9 @@ button.aura-stepper__step:hover .aura-stepper__label { text-decoration: underlin
|
|
|
1387
1408
|
@media (max-width: 767.98px) { :root:has(.aura-bottomnav--below-md) { --aura-bottomnav-offset: calc(var(--aura-bottomnav-height) + env(safe-area-inset-bottom, 0px)); } }
|
|
1388
1409
|
@media (max-width: 1023.98px) { :root:has(.aura-bottomnav--below-lg) { --aura-bottomnav-offset: calc(var(--aura-bottomnav-height) + env(safe-area-inset-bottom, 0px)); } }
|
|
1389
1410
|
@media (max-width: 1279.98px) { :root:has(.aura-bottomnav--below-xl) { --aura-bottomnav-offset: calc(var(--aura-bottomnav-height) + env(safe-area-inset-bottom, 0px)); } }
|
|
1390
|
-
/* Toasts clear a BottomNav wherever it shows (phones and tablets). */
|
|
1391
|
-
.aura-toaster:not(.is-top) { bottom: calc(var(--aura-space-6) + var(--aura-bottomnav-offset, 0px)); }
|
|
1392
|
-
@media (max-width: 639.98px) { .aura-toaster:not(.is-top) { bottom: calc(var(--aura-space-4) + var(--aura-bottomnav-offset, 0px)); } }
|
|
1411
|
+
/* Toasts clear a BottomNav wherever it shows (phones and tablets), else the bottom safe-area inset (5.6). */
|
|
1412
|
+
.aura-toaster:not(.is-top) { bottom: calc(var(--aura-toaster-offset, var(--aura-space-6)) + var(--aura-bottomnav-offset, env(safe-area-inset-bottom, 0px))); }
|
|
1413
|
+
@media (max-width: 639.98px) { .aura-toaster:not(.is-top) { bottom: calc(var(--aura-toaster-offset, var(--aura-space-4)) + var(--aura-bottomnav-offset, env(safe-area-inset-bottom, 0px))); } }
|
|
1393
1414
|
|
|
1394
1415
|
/* ---------- 4.19: ActionBar ---------- */
|
|
1395
1416
|
/* Sticky, not fixed: it keeps its place at the end of its parent, so it never covers the last field. */
|
package/package.json
CHANGED