@almadar/ui 5.122.0 → 5.122.2

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.
@@ -5140,6 +5140,7 @@ var init_Modal = __esm({
5140
5140
  isOpen = true,
5141
5141
  onClose = () => {
5142
5142
  },
5143
+ onExited,
5143
5144
  title,
5144
5145
  children = null,
5145
5146
  footer,
@@ -5166,7 +5167,10 @@ var init_Modal = __esm({
5166
5167
  wasOpenRef.current = isOpen;
5167
5168
  }, [isOpen]);
5168
5169
  const handleAnimEnd = (e) => {
5169
- if (closing && e.target === e.currentTarget) setClosing(false);
5170
+ if (closing && e.target === e.currentTarget) {
5171
+ setClosing(false);
5172
+ onExited?.();
5173
+ }
5170
5174
  };
5171
5175
  React91.useEffect(() => {
5172
5176
  if (isOpen) {
package/dist/avl/index.js CHANGED
@@ -5094,6 +5094,7 @@ var init_Modal = __esm({
5094
5094
  isOpen = true,
5095
5095
  onClose = () => {
5096
5096
  },
5097
+ onExited,
5097
5098
  title,
5098
5099
  children = null,
5099
5100
  footer,
@@ -5120,7 +5121,10 @@ var init_Modal = __esm({
5120
5121
  wasOpenRef.current = isOpen;
5121
5122
  }, [isOpen]);
5122
5123
  const handleAnimEnd = (e) => {
5123
- if (closing && e.target === e.currentTarget) setClosing(false);
5124
+ if (closing && e.target === e.currentTarget) {
5125
+ setClosing(false);
5126
+ onExited?.();
5127
+ }
5124
5128
  };
5125
5129
  useEffect(() => {
5126
5130
  if (isOpen) {
@@ -6146,6 +6146,7 @@ var init_Modal = __esm({
6146
6146
  isOpen = true,
6147
6147
  onClose = () => {
6148
6148
  },
6149
+ onExited,
6149
6150
  title,
6150
6151
  children = null,
6151
6152
  footer,
@@ -6172,7 +6173,10 @@ var init_Modal = __esm({
6172
6173
  wasOpenRef.current = isOpen;
6173
6174
  }, [isOpen]);
6174
6175
  const handleAnimEnd = (e) => {
6175
- if (closing && e.target === e.currentTarget) setClosing(false);
6176
+ if (closing && e.target === e.currentTarget) {
6177
+ setClosing(false);
6178
+ onExited?.();
6179
+ }
6176
6180
  };
6177
6181
  React74.useEffect(() => {
6178
6182
  if (isOpen) {
@@ -4362,6 +4362,8 @@ interface ModalProps {
4362
4362
  isOpen?: boolean;
4363
4363
  /** Callback when modal should close (injected by slot wrapper) */
4364
4364
  onClose?: () => void;
4365
+ /** Fires after the exit animation completes (the modal is about to unmount). */
4366
+ onExited?: () => void;
4365
4367
  title?: string;
4366
4368
  /** Modal content (can be empty if using slot content) */
4367
4369
  children?: React__default.ReactNode;
@@ -4362,6 +4362,8 @@ interface ModalProps {
4362
4362
  isOpen?: boolean;
4363
4363
  /** Callback when modal should close (injected by slot wrapper) */
4364
4364
  onClose?: () => void;
4365
+ /** Fires after the exit animation completes (the modal is about to unmount). */
4366
+ onExited?: () => void;
4365
4367
  title?: string;
4366
4368
  /** Modal content (can be empty if using slot content) */
4367
4369
  children?: React__default.ReactNode;
@@ -6101,6 +6101,7 @@ var init_Modal = __esm({
6101
6101
  isOpen = true,
6102
6102
  onClose = () => {
6103
6103
  },
6104
+ onExited,
6104
6105
  title,
6105
6106
  children = null,
6106
6107
  footer,
@@ -6127,7 +6128,10 @@ var init_Modal = __esm({
6127
6128
  wasOpenRef.current = isOpen;
6128
6129
  }, [isOpen]);
6129
6130
  const handleAnimEnd = (e) => {
6130
- if (closing && e.target === e.currentTarget) setClosing(false);
6131
+ if (closing && e.target === e.currentTarget) {
6132
+ setClosing(false);
6133
+ onExited?.();
6134
+ }
6131
6135
  };
6132
6136
  useEffect(() => {
6133
6137
  if (isOpen) {
@@ -1311,6 +1311,7 @@ var init_Modal = __esm({
1311
1311
  isOpen = true,
1312
1312
  onClose = () => {
1313
1313
  },
1314
+ onExited,
1314
1315
  title,
1315
1316
  children = null,
1316
1317
  footer,
@@ -1337,7 +1338,10 @@ var init_Modal = __esm({
1337
1338
  wasOpenRef.current = isOpen;
1338
1339
  }, [isOpen]);
1339
1340
  const handleAnimEnd = (e) => {
1340
- if (closing && e.target === e.currentTarget) setClosing(false);
1341
+ if (closing && e.target === e.currentTarget) {
1342
+ setClosing(false);
1343
+ onExited?.();
1344
+ }
1341
1345
  };
1342
1346
  React84.useEffect(() => {
1343
1347
  if (isOpen) {
@@ -1266,6 +1266,7 @@ var init_Modal = __esm({
1266
1266
  isOpen = true,
1267
1267
  onClose = () => {
1268
1268
  },
1269
+ onExited,
1269
1270
  title,
1270
1271
  children = null,
1271
1272
  footer,
@@ -1292,7 +1293,10 @@ var init_Modal = __esm({
1292
1293
  wasOpenRef.current = isOpen;
1293
1294
  }, [isOpen]);
1294
1295
  const handleAnimEnd = (e) => {
1295
- if (closing && e.target === e.currentTarget) setClosing(false);
1296
+ if (closing && e.target === e.currentTarget) {
1297
+ setClosing(false);
1298
+ onExited?.();
1299
+ }
1296
1300
  };
1297
1301
  useEffect(() => {
1298
1302
  if (isOpen) {
@@ -1789,6 +1789,7 @@ var init_Modal = __esm({
1789
1789
  isOpen = true,
1790
1790
  onClose = () => {
1791
1791
  },
1792
+ onExited,
1792
1793
  title,
1793
1794
  children = null,
1794
1795
  footer,
@@ -1815,7 +1816,10 @@ var init_Modal = __esm({
1815
1816
  wasOpenRef.current = isOpen;
1816
1817
  }, [isOpen]);
1817
1818
  const handleAnimEnd = (e) => {
1818
- if (closing && e.target === e.currentTarget) setClosing(false);
1819
+ if (closing && e.target === e.currentTarget) {
1820
+ setClosing(false);
1821
+ onExited?.();
1822
+ }
1819
1823
  };
1820
1824
  React82.useEffect(() => {
1821
1825
  if (isOpen) {
@@ -1745,6 +1745,7 @@ var init_Modal = __esm({
1745
1745
  isOpen = true,
1746
1746
  onClose = () => {
1747
1747
  },
1748
+ onExited,
1748
1749
  title,
1749
1750
  children = null,
1750
1751
  footer,
@@ -1771,7 +1772,10 @@ var init_Modal = __esm({
1771
1772
  wasOpenRef.current = isOpen;
1772
1773
  }, [isOpen]);
1773
1774
  const handleAnimEnd = (e) => {
1774
- if (closing && e.target === e.currentTarget) setClosing(false);
1775
+ if (closing && e.target === e.currentTarget) {
1776
+ setClosing(false);
1777
+ onExited?.();
1778
+ }
1775
1779
  };
1776
1780
  useEffect(() => {
1777
1781
  if (isOpen) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@almadar/ui",
3
- "version": "5.122.0",
3
+ "version": "5.122.2",
4
4
  "description": "React UI components, hooks, and providers for Almadar",
5
5
  "type": "module",
6
6
  "sideEffects": [
@@ -353,9 +353,11 @@ module.exports = {
353
353
  bold: 'var(--font-weight-bold, 600)',
354
354
  },
355
355
  transitionDuration: {
356
- // Existing aliases retained; resolve through the Motion-axis tokens
357
- // with the previous `--transition-*` values as fallback so themes that
358
- // don't define `--duration-*` keep their pre-Layer-1 motion.
356
+ // DEFAULT drives every bare `transition-*` utility (transition-all /
357
+ // transition-colors / ...) so its duration is theme-token-driven too
358
+ // not Tailwind's hardcoded 150ms. Existing aliases resolve through the
359
+ // Motion-axis tokens with the legacy `--transition-*` as fallback.
360
+ DEFAULT: 'var(--duration-fast, var(--transition-fast, 150ms))',
359
361
  fast: 'var(--duration-fast, var(--transition-fast, 150ms))',
360
362
  normal: 'var(--duration-normal, var(--transition-normal, 250ms))',
361
363
  slow: 'var(--duration-slow, var(--transition-slow, 400ms))',
@@ -363,8 +365,10 @@ module.exports = {
363
365
  dramatic: 'var(--duration-dramatic, 600ms)',
364
366
  },
365
367
  transitionTimingFunction: {
366
- // Motion-axis easing palette. `standard` falls back to the existing
367
- // `--transition-timing` so backward compat is preserved.
368
+ // DEFAULT drives every bare `transition-*` utility so its easing is
369
+ // theme-token-driven not Tailwind's hardcoded cubic-bezier. `standard`
370
+ // falls back to legacy `--transition-timing` for backward compat.
371
+ DEFAULT: 'var(--easing-standard, var(--transition-timing, cubic-bezier(0.4, 0, 0.2, 1)))',
368
372
  linear: 'var(--easing-linear, linear)',
369
373
  standard: 'var(--easing-standard, var(--transition-timing, cubic-bezier(0.4, 0, 0.2, 1)))',
370
374
  emphasized: 'var(--easing-emphasized, cubic-bezier(0.2, 0, 0, 1))',