@storybook/addon-a11y 10.1.0-alpha.0 → 10.1.0-alpha.10
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/manager.js +129 -933
- package/dist/postinstall.js +6 -6
- package/package.json +3 -3
package/dist/manager.js
CHANGED
|
@@ -12,13 +12,13 @@ import {
|
|
|
12
12
|
} from "./_browser-chunks/chunk-JFJ5UJ7Q.js";
|
|
13
13
|
|
|
14
14
|
// src/manager.tsx
|
|
15
|
-
import
|
|
15
|
+
import React9 from "react";
|
|
16
16
|
import { Badge as Badge3 } from "storybook/internal/components";
|
|
17
17
|
import { addons, types, useAddonState as useAddonState2, useStorybookApi as useStorybookApi3 } from "storybook/manager-api";
|
|
18
18
|
|
|
19
19
|
// src/components/A11YPanel.tsx
|
|
20
|
-
import
|
|
21
|
-
import { Badge as Badge2, Button as
|
|
20
|
+
import React6, { useMemo as useMemo3 } from "react";
|
|
21
|
+
import { Badge as Badge2, Button as Button4 } from "storybook/internal/components";
|
|
22
22
|
import { SyncIcon as SyncIcon2 } from "@storybook/icons";
|
|
23
23
|
import { styled as styled5 } from "storybook/theming";
|
|
24
24
|
|
|
@@ -958,7 +958,7 @@ var useA11yContext = /* @__PURE__ */ __name(() => useContext(A11yContext), "useA
|
|
|
958
958
|
|
|
959
959
|
// src/components/Report/Report.tsx
|
|
960
960
|
import React3 from "react";
|
|
961
|
-
import { Badge,
|
|
961
|
+
import { Badge, Button as Button2, EmptyTabContent } from "storybook/internal/components";
|
|
962
962
|
import { ChevronSmallDownIcon } from "@storybook/icons";
|
|
963
963
|
import { styled as styled2 } from "storybook/theming";
|
|
964
964
|
|
|
@@ -1096,7 +1096,7 @@ import { forwardRef as $98Iye$forwardRef, createElement as $98Iye$createElement,
|
|
|
1096
1096
|
// ../../node_modules/@radix-ui/react-collection/dist/index.mjs
|
|
1097
1097
|
import $6vYhU$react from "react";
|
|
1098
1098
|
|
|
1099
|
-
// ../../node_modules/@radix-ui/react-
|
|
1099
|
+
// ../../node_modules/@radix-ui/react-compose-refs/dist/index.mjs
|
|
1100
1100
|
import { useCallback as $3vqmr$useCallback } from "react";
|
|
1101
1101
|
function $6ed0406888f73fc4$var$setRef(ref, value) {
|
|
1102
1102
|
if (typeof ref === "function") ref(value);
|
|
@@ -1270,28 +1270,10 @@ function $e02a7d9cb1dc128c$export$c74125a8e3af6bb2(name) {
|
|
|
1270
1270
|
}
|
|
1271
1271
|
__name($e02a7d9cb1dc128c$export$c74125a8e3af6bb2, "$e02a7d9cb1dc128c$export$c74125a8e3af6bb2");
|
|
1272
1272
|
|
|
1273
|
-
// ../../node_modules/@radix-ui/react-roving-focus/node_modules/@radix-ui/react-compose-refs/dist/index.mjs
|
|
1274
|
-
import { useCallback as $3vqmr$useCallback2 } from "react";
|
|
1275
|
-
function $6ed0406888f73fc4$var$setRef2(ref, value) {
|
|
1276
|
-
if (typeof ref === "function") ref(value);
|
|
1277
|
-
else if (ref !== null && ref !== void 0) ref.current = value;
|
|
1278
|
-
}
|
|
1279
|
-
__name($6ed0406888f73fc4$var$setRef2, "$6ed0406888f73fc4$var$setRef");
|
|
1280
|
-
function $6ed0406888f73fc4$export$43e446d32b3d21af2(...refs) {
|
|
1281
|
-
return (node) => refs.forEach(
|
|
1282
|
-
(ref) => $6ed0406888f73fc4$var$setRef2(ref, node)
|
|
1283
|
-
);
|
|
1284
|
-
}
|
|
1285
|
-
__name($6ed0406888f73fc4$export$43e446d32b3d21af2, "$6ed0406888f73fc4$export$43e446d32b3d21af");
|
|
1286
|
-
function $6ed0406888f73fc4$export$c7b2cbe3552a0d052(...refs) {
|
|
1287
|
-
return $3vqmr$useCallback2($6ed0406888f73fc4$export$43e446d32b3d21af2(...refs), refs);
|
|
1288
|
-
}
|
|
1289
|
-
__name($6ed0406888f73fc4$export$c7b2cbe3552a0d052, "$6ed0406888f73fc4$export$c7b2cbe3552a0d05");
|
|
1290
|
-
|
|
1291
1273
|
// ../../node_modules/@radix-ui/react-id/dist/index.mjs
|
|
1292
1274
|
import * as $2AODx$react from "react";
|
|
1293
1275
|
|
|
1294
|
-
// ../../node_modules/@radix-ui/react-
|
|
1276
|
+
// ../../node_modules/@radix-ui/react-use-layout-effect/dist/index.mjs
|
|
1295
1277
|
import { useLayoutEffect as $dxlwH$useLayoutEffect } from "react";
|
|
1296
1278
|
var $9f79659886946c16$export$e5c5a5f917a5871c = Boolean(globalThis === null || globalThis === void 0 ? void 0 : globalThis.document) ? $dxlwH$useLayoutEffect : () => {
|
|
1297
1279
|
};
|
|
@@ -1312,11 +1294,11 @@ function $1746a345f3d73bb7$export$f680877a34711e37(deterministicId) {
|
|
|
1312
1294
|
}
|
|
1313
1295
|
__name($1746a345f3d73bb7$export$f680877a34711e37, "$1746a345f3d73bb7$export$f680877a34711e37");
|
|
1314
1296
|
|
|
1315
|
-
// ../../node_modules/@radix-ui/react-
|
|
1297
|
+
// ../../node_modules/@radix-ui/react-primitive/dist/index.mjs
|
|
1316
1298
|
import { forwardRef as $4q5Fq$forwardRef, useEffect as $4q5Fq$useEffect, createElement as $4q5Fq$createElement } from "react";
|
|
1317
1299
|
import { flushSync as $4q5Fq$flushSync } from "react-dom";
|
|
1318
1300
|
|
|
1319
|
-
// ../../node_modules/@radix-ui/react-
|
|
1301
|
+
// ../../node_modules/@radix-ui/react-primitive/node_modules/@radix-ui/react-slot/dist/index.mjs
|
|
1320
1302
|
import { forwardRef as $9IrjX$forwardRef2, Children as $9IrjX$Children2, isValidElement as $9IrjX$isValidElement2, createElement as $9IrjX$createElement2, cloneElement as $9IrjX$cloneElement2, Fragment as $9IrjX$Fragment2 } from "react";
|
|
1321
1303
|
var $5e63c961fc1ce211$export$8c6ed5c666ac13602 = $9IrjX$forwardRef2((props, forwardedRef) => {
|
|
1322
1304
|
const { children, ...slotProps } = props;
|
|
@@ -1343,7 +1325,7 @@ var $5e63c961fc1ce211$var$SlotClone2 = $9IrjX$forwardRef2((props, forwardedRef)
|
|
|
1343
1325
|
const { children, ...slotProps } = props;
|
|
1344
1326
|
if ($9IrjX$isValidElement2(children)) return $9IrjX$cloneElement2(children, {
|
|
1345
1327
|
...$5e63c961fc1ce211$var$mergeProps2(slotProps, children.props),
|
|
1346
|
-
ref: forwardedRef ? $6ed0406888f73fc4$export$
|
|
1328
|
+
ref: forwardedRef ? $6ed0406888f73fc4$export$43e446d32b3d21af(forwardedRef, children.ref) : children.ref
|
|
1347
1329
|
});
|
|
1348
1330
|
return $9IrjX$Children2.count(children) > 1 ? $9IrjX$Children2.only(null) : null;
|
|
1349
1331
|
});
|
|
@@ -1385,7 +1367,7 @@ function $5e63c961fc1ce211$var$mergeProps2(slotProps, childProps) {
|
|
|
1385
1367
|
}
|
|
1386
1368
|
__name($5e63c961fc1ce211$var$mergeProps2, "$5e63c961fc1ce211$var$mergeProps");
|
|
1387
1369
|
|
|
1388
|
-
// ../../node_modules/@radix-ui/react-
|
|
1370
|
+
// ../../node_modules/@radix-ui/react-primitive/dist/index.mjs
|
|
1389
1371
|
var $8927f6f2acc4f386$var$NODES = [
|
|
1390
1372
|
"a",
|
|
1391
1373
|
"button",
|
|
@@ -1422,7 +1404,7 @@ var $8927f6f2acc4f386$export$250ffa63cdc0d034 = $8927f6f2acc4f386$var$NODES.redu
|
|
|
1422
1404
|
};
|
|
1423
1405
|
}, {});
|
|
1424
1406
|
|
|
1425
|
-
// ../../node_modules/@radix-ui/react-
|
|
1407
|
+
// ../../node_modules/@radix-ui/react-use-callback-ref/dist/index.mjs
|
|
1426
1408
|
import { useRef as $lwiWj$useRef, useEffect as $lwiWj$useEffect, useMemo as $lwiWj$useMemo } from "react";
|
|
1427
1409
|
function $b1b2314f5f9a1d84$export$25bec8c6f54ee79a(callback) {
|
|
1428
1410
|
const callbackRef = $lwiWj$useRef(callback);
|
|
@@ -1441,25 +1423,6 @@ __name($b1b2314f5f9a1d84$export$25bec8c6f54ee79a, "$b1b2314f5f9a1d84$export$25be
|
|
|
1441
1423
|
|
|
1442
1424
|
// ../../node_modules/@radix-ui/react-use-controllable-state/dist/index.mjs
|
|
1443
1425
|
import { useCallback as $bnPw9$useCallback, useState as $bnPw9$useState, useRef as $bnPw9$useRef, useEffect as $bnPw9$useEffect } from "react";
|
|
1444
|
-
|
|
1445
|
-
// ../../node_modules/@radix-ui/react-use-controllable-state/node_modules/@radix-ui/react-use-callback-ref/dist/index.mjs
|
|
1446
|
-
import { useRef as $lwiWj$useRef2, useEffect as $lwiWj$useEffect2, useMemo as $lwiWj$useMemo2 } from "react";
|
|
1447
|
-
function $b1b2314f5f9a1d84$export$25bec8c6f54ee79a2(callback) {
|
|
1448
|
-
const callbackRef = $lwiWj$useRef2(callback);
|
|
1449
|
-
$lwiWj$useEffect2(() => {
|
|
1450
|
-
callbackRef.current = callback;
|
|
1451
|
-
});
|
|
1452
|
-
return $lwiWj$useMemo2(
|
|
1453
|
-
() => (...args) => {
|
|
1454
|
-
var _callbackRef$current;
|
|
1455
|
-
return (_callbackRef$current = callbackRef.current) === null || _callbackRef$current === void 0 ? void 0 : _callbackRef$current.call(callbackRef, ...args);
|
|
1456
|
-
},
|
|
1457
|
-
[]
|
|
1458
|
-
);
|
|
1459
|
-
}
|
|
1460
|
-
__name($b1b2314f5f9a1d84$export$25bec8c6f54ee79a2, "$b1b2314f5f9a1d84$export$25bec8c6f54ee79a");
|
|
1461
|
-
|
|
1462
|
-
// ../../node_modules/@radix-ui/react-use-controllable-state/dist/index.mjs
|
|
1463
1426
|
function $71cd76cc60e0454e$export$6f32135080cb4c3({ prop, defaultProp, onChange = /* @__PURE__ */ __name(() => {
|
|
1464
1427
|
}, "onChange") }) {
|
|
1465
1428
|
const [uncontrolledProp, setUncontrolledProp] = $71cd76cc60e0454e$var$useUncontrolledState({
|
|
@@ -1468,7 +1431,7 @@ function $71cd76cc60e0454e$export$6f32135080cb4c3({ prop, defaultProp, onChange
|
|
|
1468
1431
|
});
|
|
1469
1432
|
const isControlled = prop !== void 0;
|
|
1470
1433
|
const value1 = isControlled ? prop : uncontrolledProp;
|
|
1471
|
-
const handleChange = $b1b2314f5f9a1d84$export$
|
|
1434
|
+
const handleChange = $b1b2314f5f9a1d84$export$25bec8c6f54ee79a(onChange);
|
|
1472
1435
|
const setValue = $bnPw9$useCallback((nextValue) => {
|
|
1473
1436
|
if (isControlled) {
|
|
1474
1437
|
const setter = nextValue;
|
|
@@ -1491,7 +1454,7 @@ function $71cd76cc60e0454e$var$useUncontrolledState({ defaultProp, onChange }) {
|
|
|
1491
1454
|
const uncontrolledState = $bnPw9$useState(defaultProp);
|
|
1492
1455
|
const [value] = uncontrolledState;
|
|
1493
1456
|
const prevValueRef = $bnPw9$useRef(value);
|
|
1494
|
-
const handleChange = $b1b2314f5f9a1d84$export$
|
|
1457
|
+
const handleChange = $b1b2314f5f9a1d84$export$25bec8c6f54ee79a(onChange);
|
|
1495
1458
|
$bnPw9$useEffect(() => {
|
|
1496
1459
|
if (prevValueRef.current !== value) {
|
|
1497
1460
|
handleChange(value);
|
|
@@ -1542,7 +1505,7 @@ Object.assign($d7bdfb9eb0fdf311$export$8699f7c8af148338, {
|
|
|
1542
1505
|
var $d7bdfb9eb0fdf311$var$RovingFocusGroupImpl = $98Iye$forwardRef((props, forwardedRef) => {
|
|
1543
1506
|
const { __scopeRovingFocusGroup, orientation, loop = false, dir, currentTabStopId: currentTabStopIdProp, defaultCurrentTabStopId, onCurrentTabStopIdChange, onEntryFocus, ...groupProps } = props;
|
|
1544
1507
|
const ref = $98Iye$useRef(null);
|
|
1545
|
-
const composedRefs = $6ed0406888f73fc4$export$
|
|
1508
|
+
const composedRefs = $6ed0406888f73fc4$export$c7b2cbe3552a0d05(forwardedRef, ref);
|
|
1546
1509
|
const direction = $f631663db3294ace$export$b39126d51d94e6f3(dir);
|
|
1547
1510
|
const [currentTabStopId = null, setCurrentTabStopId] = $71cd76cc60e0454e$export$6f32135080cb4c3({
|
|
1548
1511
|
prop: currentTabStopIdProp,
|
|
@@ -1754,31 +1717,6 @@ var $d7bdfb9eb0fdf311$export$6d08773d2e66f8f2 = $d7bdfb9eb0fdf311$export$ab9df7c
|
|
|
1754
1717
|
// ../../node_modules/@radix-ui/react-presence/dist/index.mjs
|
|
1755
1718
|
import { Children as $iqq3r$Children, cloneElement as $iqq3r$cloneElement, useState as $iqq3r$useState, useRef as $iqq3r$useRef, useEffect as $iqq3r$useEffect, useCallback as $iqq3r$useCallback, useReducer as $iqq3r$useReducer } from "react";
|
|
1756
1719
|
import { flushSync as $iqq3r$flushSync } from "react-dom";
|
|
1757
|
-
|
|
1758
|
-
// ../../node_modules/@radix-ui/react-presence/node_modules/@radix-ui/react-compose-refs/dist/index.mjs
|
|
1759
|
-
import { useCallback as $3vqmr$useCallback3 } from "react";
|
|
1760
|
-
function $6ed0406888f73fc4$var$setRef3(ref, value) {
|
|
1761
|
-
if (typeof ref === "function") ref(value);
|
|
1762
|
-
else if (ref !== null && ref !== void 0) ref.current = value;
|
|
1763
|
-
}
|
|
1764
|
-
__name($6ed0406888f73fc4$var$setRef3, "$6ed0406888f73fc4$var$setRef");
|
|
1765
|
-
function $6ed0406888f73fc4$export$43e446d32b3d21af3(...refs) {
|
|
1766
|
-
return (node) => refs.forEach(
|
|
1767
|
-
(ref) => $6ed0406888f73fc4$var$setRef3(ref, node)
|
|
1768
|
-
);
|
|
1769
|
-
}
|
|
1770
|
-
__name($6ed0406888f73fc4$export$43e446d32b3d21af3, "$6ed0406888f73fc4$export$43e446d32b3d21af");
|
|
1771
|
-
function $6ed0406888f73fc4$export$c7b2cbe3552a0d053(...refs) {
|
|
1772
|
-
return $3vqmr$useCallback3($6ed0406888f73fc4$export$43e446d32b3d21af3(...refs), refs);
|
|
1773
|
-
}
|
|
1774
|
-
__name($6ed0406888f73fc4$export$c7b2cbe3552a0d053, "$6ed0406888f73fc4$export$c7b2cbe3552a0d05");
|
|
1775
|
-
|
|
1776
|
-
// ../../node_modules/@radix-ui/react-presence/node_modules/@radix-ui/react-use-layout-effect/dist/index.mjs
|
|
1777
|
-
import { useLayoutEffect as $dxlwH$useLayoutEffect2 } from "react";
|
|
1778
|
-
var $9f79659886946c16$export$e5c5a5f917a5871c2 = Boolean(globalThis === null || globalThis === void 0 ? void 0 : globalThis.document) ? $dxlwH$useLayoutEffect2 : () => {
|
|
1779
|
-
};
|
|
1780
|
-
|
|
1781
|
-
// ../../node_modules/@radix-ui/react-presence/dist/index.mjs
|
|
1782
1720
|
function $fe963b355347cc68$export$3e6543de14f8614f(initialState, machine) {
|
|
1783
1721
|
return $iqq3r$useReducer((state, event) => {
|
|
1784
1722
|
const nextState = machine[state][event];
|
|
@@ -1792,7 +1730,7 @@ var $921a889cee6df7e8$export$99c2b779aa4e8b8b = /* @__PURE__ */ __name((props) =
|
|
|
1792
1730
|
const child = typeof children === "function" ? children({
|
|
1793
1731
|
present: presence.isPresent
|
|
1794
1732
|
}) : $iqq3r$Children.only(children);
|
|
1795
|
-
const ref = $6ed0406888f73fc4$export$
|
|
1733
|
+
const ref = $6ed0406888f73fc4$export$c7b2cbe3552a0d05(presence.ref, child.ref);
|
|
1796
1734
|
const forceMount = typeof children === "function";
|
|
1797
1735
|
return forceMount || presence.isPresent ? $iqq3r$cloneElement(child, {
|
|
1798
1736
|
ref
|
|
@@ -1824,7 +1762,7 @@ function $921a889cee6df7e8$var$usePresence(present) {
|
|
|
1824
1762
|
}, [
|
|
1825
1763
|
state
|
|
1826
1764
|
]);
|
|
1827
|
-
$9f79659886946c16$export$
|
|
1765
|
+
$9f79659886946c16$export$e5c5a5f917a5871c(() => {
|
|
1828
1766
|
const styles = stylesRef.current;
|
|
1829
1767
|
const wasPresent = prevPresentRef.current;
|
|
1830
1768
|
const hasPresentChanged = wasPresent !== present;
|
|
@@ -1845,7 +1783,7 @@ function $921a889cee6df7e8$var$usePresence(present) {
|
|
|
1845
1783
|
present,
|
|
1846
1784
|
send
|
|
1847
1785
|
]);
|
|
1848
|
-
$9f79659886946c16$export$
|
|
1786
|
+
$9f79659886946c16$export$e5c5a5f917a5871c(() => {
|
|
1849
1787
|
if (node1) {
|
|
1850
1788
|
const handleAnimationEnd = /* @__PURE__ */ __name((event) => {
|
|
1851
1789
|
const currentAnimationName = $921a889cee6df7e8$var$getAnimationName(stylesRef.current);
|
|
@@ -1890,132 +1828,6 @@ function $921a889cee6df7e8$var$getAnimationName(styles) {
|
|
|
1890
1828
|
}
|
|
1891
1829
|
__name($921a889cee6df7e8$var$getAnimationName, "$921a889cee6df7e8$var$getAnimationName");
|
|
1892
1830
|
|
|
1893
|
-
// ../../node_modules/@radix-ui/react-tabs/node_modules/@radix-ui/react-primitive/dist/index.mjs
|
|
1894
|
-
import { forwardRef as $4q5Fq$forwardRef2, useEffect as $4q5Fq$useEffect2, createElement as $4q5Fq$createElement2 } from "react";
|
|
1895
|
-
import { flushSync as $4q5Fq$flushSync2 } from "react-dom";
|
|
1896
|
-
|
|
1897
|
-
// ../../node_modules/@radix-ui/react-tabs/node_modules/@radix-ui/react-slot/dist/index.mjs
|
|
1898
|
-
import { forwardRef as $9IrjX$forwardRef3, Children as $9IrjX$Children3, isValidElement as $9IrjX$isValidElement3, createElement as $9IrjX$createElement3, cloneElement as $9IrjX$cloneElement3, Fragment as $9IrjX$Fragment3 } from "react";
|
|
1899
|
-
|
|
1900
|
-
// ../../node_modules/@radix-ui/react-tabs/node_modules/@radix-ui/react-compose-refs/dist/index.mjs
|
|
1901
|
-
import { useCallback as $3vqmr$useCallback4 } from "react";
|
|
1902
|
-
function $6ed0406888f73fc4$var$setRef4(ref, value) {
|
|
1903
|
-
if (typeof ref === "function") ref(value);
|
|
1904
|
-
else if (ref !== null && ref !== void 0) ref.current = value;
|
|
1905
|
-
}
|
|
1906
|
-
__name($6ed0406888f73fc4$var$setRef4, "$6ed0406888f73fc4$var$setRef");
|
|
1907
|
-
function $6ed0406888f73fc4$export$43e446d32b3d21af4(...refs) {
|
|
1908
|
-
return (node) => refs.forEach(
|
|
1909
|
-
(ref) => $6ed0406888f73fc4$var$setRef4(ref, node)
|
|
1910
|
-
);
|
|
1911
|
-
}
|
|
1912
|
-
__name($6ed0406888f73fc4$export$43e446d32b3d21af4, "$6ed0406888f73fc4$export$43e446d32b3d21af");
|
|
1913
|
-
|
|
1914
|
-
// ../../node_modules/@radix-ui/react-tabs/node_modules/@radix-ui/react-slot/dist/index.mjs
|
|
1915
|
-
var $5e63c961fc1ce211$export$8c6ed5c666ac13603 = $9IrjX$forwardRef3((props, forwardedRef) => {
|
|
1916
|
-
const { children, ...slotProps } = props;
|
|
1917
|
-
const childrenArray = $9IrjX$Children3.toArray(children);
|
|
1918
|
-
const slottable = childrenArray.find($5e63c961fc1ce211$var$isSlottable3);
|
|
1919
|
-
if (slottable) {
|
|
1920
|
-
const newElement = slottable.props.children;
|
|
1921
|
-
const newChildren = childrenArray.map((child) => {
|
|
1922
|
-
if (child === slottable) {
|
|
1923
|
-
if ($9IrjX$Children3.count(newElement) > 1) return $9IrjX$Children3.only(null);
|
|
1924
|
-
return $9IrjX$isValidElement3(newElement) ? newElement.props.children : null;
|
|
1925
|
-
} else return child;
|
|
1926
|
-
});
|
|
1927
|
-
return $9IrjX$createElement3($5e63c961fc1ce211$var$SlotClone3, _extends({}, slotProps, {
|
|
1928
|
-
ref: forwardedRef
|
|
1929
|
-
}), $9IrjX$isValidElement3(newElement) ? $9IrjX$cloneElement3(newElement, void 0, newChildren) : null);
|
|
1930
|
-
}
|
|
1931
|
-
return $9IrjX$createElement3($5e63c961fc1ce211$var$SlotClone3, _extends({}, slotProps, {
|
|
1932
|
-
ref: forwardedRef
|
|
1933
|
-
}), children);
|
|
1934
|
-
});
|
|
1935
|
-
$5e63c961fc1ce211$export$8c6ed5c666ac13603.displayName = "Slot";
|
|
1936
|
-
var $5e63c961fc1ce211$var$SlotClone3 = $9IrjX$forwardRef3((props, forwardedRef) => {
|
|
1937
|
-
const { children, ...slotProps } = props;
|
|
1938
|
-
if ($9IrjX$isValidElement3(children)) return $9IrjX$cloneElement3(children, {
|
|
1939
|
-
...$5e63c961fc1ce211$var$mergeProps3(slotProps, children.props),
|
|
1940
|
-
ref: forwardedRef ? $6ed0406888f73fc4$export$43e446d32b3d21af4(forwardedRef, children.ref) : children.ref
|
|
1941
|
-
});
|
|
1942
|
-
return $9IrjX$Children3.count(children) > 1 ? $9IrjX$Children3.only(null) : null;
|
|
1943
|
-
});
|
|
1944
|
-
$5e63c961fc1ce211$var$SlotClone3.displayName = "SlotClone";
|
|
1945
|
-
var $5e63c961fc1ce211$export$d9f1ccf0bdb05d453 = /* @__PURE__ */ __name(({ children }) => {
|
|
1946
|
-
return $9IrjX$createElement3($9IrjX$Fragment3, null, children);
|
|
1947
|
-
}, "$5e63c961fc1ce211$export$d9f1ccf0bdb05d45");
|
|
1948
|
-
function $5e63c961fc1ce211$var$isSlottable3(child) {
|
|
1949
|
-
return $9IrjX$isValidElement3(child) && child.type === $5e63c961fc1ce211$export$d9f1ccf0bdb05d453;
|
|
1950
|
-
}
|
|
1951
|
-
__name($5e63c961fc1ce211$var$isSlottable3, "$5e63c961fc1ce211$var$isSlottable");
|
|
1952
|
-
function $5e63c961fc1ce211$var$mergeProps3(slotProps, childProps) {
|
|
1953
|
-
const overrideProps = {
|
|
1954
|
-
...childProps
|
|
1955
|
-
};
|
|
1956
|
-
for (const propName in childProps) {
|
|
1957
|
-
const slotPropValue = slotProps[propName];
|
|
1958
|
-
const childPropValue = childProps[propName];
|
|
1959
|
-
const isHandler = /^on[A-Z]/.test(propName);
|
|
1960
|
-
if (isHandler) {
|
|
1961
|
-
if (slotPropValue && childPropValue) overrideProps[propName] = (...args) => {
|
|
1962
|
-
childPropValue(...args);
|
|
1963
|
-
slotPropValue(...args);
|
|
1964
|
-
};
|
|
1965
|
-
else if (slotPropValue) overrideProps[propName] = slotPropValue;
|
|
1966
|
-
} else if (propName === "style") overrideProps[propName] = {
|
|
1967
|
-
...slotPropValue,
|
|
1968
|
-
...childPropValue
|
|
1969
|
-
};
|
|
1970
|
-
else if (propName === "className") overrideProps[propName] = [
|
|
1971
|
-
slotPropValue,
|
|
1972
|
-
childPropValue
|
|
1973
|
-
].filter(Boolean).join(" ");
|
|
1974
|
-
}
|
|
1975
|
-
return {
|
|
1976
|
-
...slotProps,
|
|
1977
|
-
...overrideProps
|
|
1978
|
-
};
|
|
1979
|
-
}
|
|
1980
|
-
__name($5e63c961fc1ce211$var$mergeProps3, "$5e63c961fc1ce211$var$mergeProps");
|
|
1981
|
-
|
|
1982
|
-
// ../../node_modules/@radix-ui/react-tabs/node_modules/@radix-ui/react-primitive/dist/index.mjs
|
|
1983
|
-
var $8927f6f2acc4f386$var$NODES2 = [
|
|
1984
|
-
"a",
|
|
1985
|
-
"button",
|
|
1986
|
-
"div",
|
|
1987
|
-
"form",
|
|
1988
|
-
"h2",
|
|
1989
|
-
"h3",
|
|
1990
|
-
"img",
|
|
1991
|
-
"input",
|
|
1992
|
-
"label",
|
|
1993
|
-
"li",
|
|
1994
|
-
"nav",
|
|
1995
|
-
"ol",
|
|
1996
|
-
"p",
|
|
1997
|
-
"span",
|
|
1998
|
-
"svg",
|
|
1999
|
-
"ul"
|
|
2000
|
-
];
|
|
2001
|
-
var $8927f6f2acc4f386$export$250ffa63cdc0d0342 = $8927f6f2acc4f386$var$NODES2.reduce((primitive, node) => {
|
|
2002
|
-
const Node = $4q5Fq$forwardRef2((props, forwardedRef) => {
|
|
2003
|
-
const { asChild, ...primitiveProps } = props;
|
|
2004
|
-
const Comp = asChild ? $5e63c961fc1ce211$export$8c6ed5c666ac13603 : node;
|
|
2005
|
-
$4q5Fq$useEffect2(() => {
|
|
2006
|
-
window[Symbol.for("radix-ui")] = true;
|
|
2007
|
-
}, []);
|
|
2008
|
-
return $4q5Fq$createElement2(Comp, _extends({}, primitiveProps, {
|
|
2009
|
-
ref: forwardedRef
|
|
2010
|
-
}));
|
|
2011
|
-
});
|
|
2012
|
-
Node.displayName = `Primitive.${node}`;
|
|
2013
|
-
return {
|
|
2014
|
-
...primitive,
|
|
2015
|
-
[node]: Node
|
|
2016
|
-
};
|
|
2017
|
-
}, {});
|
|
2018
|
-
|
|
2019
1831
|
// ../../node_modules/@radix-ui/react-tabs/dist/index.mjs
|
|
2020
1832
|
var $69cb30bb0017df05$var$TABS_NAME = "Tabs";
|
|
2021
1833
|
var [$69cb30bb0017df05$var$createTabsContext, $69cb30bb0017df05$export$355f5bd209d7b13a] = $c512c27ab02ef895$export$50c7b4e9d9f19c1($69cb30bb0017df05$var$TABS_NAME, [
|
|
@@ -2039,7 +1851,7 @@ var $69cb30bb0017df05$export$b2539bed5023c21c = $1IHzk$forwardRef((props, forwar
|
|
|
2039
1851
|
orientation,
|
|
2040
1852
|
dir: direction,
|
|
2041
1853
|
activationMode
|
|
2042
|
-
}, $1IHzk$createElement($8927f6f2acc4f386$export$
|
|
1854
|
+
}, $1IHzk$createElement($8927f6f2acc4f386$export$250ffa63cdc0d034.div, _extends({
|
|
2043
1855
|
dir: direction,
|
|
2044
1856
|
"data-orientation": orientation
|
|
2045
1857
|
}, tabsProps, {
|
|
@@ -2060,7 +1872,7 @@ var $69cb30bb0017df05$export$9712d22edc0d78c1 = $1IHzk$forwardRef((props, forwar
|
|
|
2060
1872
|
orientation: context.orientation,
|
|
2061
1873
|
dir: context.dir,
|
|
2062
1874
|
loop
|
|
2063
|
-
}), $1IHzk$createElement($8927f6f2acc4f386$export$
|
|
1875
|
+
}), $1IHzk$createElement($8927f6f2acc4f386$export$250ffa63cdc0d034.div, _extends({
|
|
2064
1876
|
role: "tablist",
|
|
2065
1877
|
"aria-orientation": context.orientation
|
|
2066
1878
|
}, listProps, {
|
|
@@ -2083,7 +1895,7 @@ var $69cb30bb0017df05$export$8114b9fdfdf9f3ba = $1IHzk$forwardRef((props, forwar
|
|
|
2083
1895
|
}, rovingFocusGroupScope, {
|
|
2084
1896
|
focusable: !disabled,
|
|
2085
1897
|
active: isSelected
|
|
2086
|
-
}), $1IHzk$createElement($8927f6f2acc4f386$export$
|
|
1898
|
+
}), $1IHzk$createElement($8927f6f2acc4f386$export$250ffa63cdc0d034.button, _extends({
|
|
2087
1899
|
type: "button",
|
|
2088
1900
|
role: "tab",
|
|
2089
1901
|
"aria-selected": isSelected,
|
|
@@ -2133,7 +1945,7 @@ var $69cb30bb0017df05$export$bd905d70e8fd2ebb = $1IHzk$forwardRef((props, forwar
|
|
|
2133
1945
|
{
|
|
2134
1946
|
present: forceMount || isSelected
|
|
2135
1947
|
},
|
|
2136
|
-
({ present }) => $1IHzk$createElement($8927f6f2acc4f386$export$
|
|
1948
|
+
({ present }) => $1IHzk$createElement($8927f6f2acc4f386$export$250ffa63cdc0d034.div, _extends({
|
|
2137
1949
|
"data-state": isSelected ? "active" : "inactive",
|
|
2138
1950
|
"data-orientation": context.orientation,
|
|
2139
1951
|
role: "tabpanel",
|
|
@@ -2264,7 +2076,7 @@ var CopyButton = /* @__PURE__ */ __name(({ onClick }) => {
|
|
|
2264
2076
|
const timeout = setTimeout(() => setCopied(false), 2e3);
|
|
2265
2077
|
return () => clearTimeout(timeout);
|
|
2266
2078
|
}, [onClick]);
|
|
2267
|
-
return React2.createElement(Button, { onClick: handleClick }, copied ? React2.createElement(CheckIcon, null) : React2.createElement(CopyIcon, null), " ", copied ? "Copied" : "Copy link");
|
|
2079
|
+
return React2.createElement(Button, { ariaLabel: false, onClick: handleClick }, copied ? React2.createElement(CheckIcon, null) : React2.createElement(CopyIcon, null), " ", copied ? "Copied" : "Copy link");
|
|
2268
2080
|
}, "CopyButton");
|
|
2269
2081
|
var Details = /* @__PURE__ */ __name(({ id, item, type, selection, handleSelectionChange }) => React2.createElement(Wrapper, { id }, React2.createElement(Info, null, React2.createElement(RuleId, null, item.id), React2.createElement(Description, null, getFriendlySummaryForAxeResult(item), " ", React2.createElement(Link, { href: item.helpUrl, target: "_blank", rel: "noopener noreferrer", withArrow: true }, "Learn how to resolve this violation"))), React2.createElement(
|
|
2270
2082
|
$69cb30bb0017df05$export$be92b6f5f03c0fe9,
|
|
@@ -2277,7 +2089,7 @@ var Details = /* @__PURE__ */ __name(({ id, item, type, selection, handleSelecti
|
|
|
2277
2089
|
},
|
|
2278
2090
|
React2.createElement(Columns, null, React2.createElement($69cb30bb0017df05$export$54c2e3dc7acea9f5, { "aria-label": type }, item.nodes.map((node, index) => {
|
|
2279
2091
|
const key = `${type}.${item.id}.${index + 1}`;
|
|
2280
|
-
return React2.createElement(Fragment, { key }, React2.createElement($69cb30bb0017df05$export$41fb9f06171c75f4, { value: key, asChild: true }, React2.createElement(Item, { variant: "ghost", size: "medium", id: key }, index + 1, ". ", node.html)), React2.createElement($69cb30bb0017df05$export$7c6e2c02157bb7d2, { value: key, asChild: true }, React2.createElement(Content, { side: "left" }, getContent(node))));
|
|
2092
|
+
return React2.createElement(Fragment, { key }, React2.createElement($69cb30bb0017df05$export$41fb9f06171c75f4, { value: key, asChild: true }, React2.createElement(Item, { ariaLabel: false, variant: "ghost", size: "medium", id: key }, index + 1, ". ", node.html)), React2.createElement($69cb30bb0017df05$export$7c6e2c02157bb7d2, { value: key, asChild: true }, React2.createElement(Content, { side: "left" }, getContent(node))));
|
|
2281
2093
|
})), item.nodes.map((node, index) => {
|
|
2282
2094
|
const key = `${type}.${item.id}.${index + 1}`;
|
|
2283
2095
|
return React2.createElement($69cb30bb0017df05$export$7c6e2c02157bb7d2, { key, value: key, asChild: true }, React2.createElement(Content, { side: "right" }, getContent(node)));
|
|
@@ -2287,7 +2099,7 @@ function getContent(node) {
|
|
|
2287
2099
|
const { handleCopyLink, handleJumpToElement } = useA11yContext();
|
|
2288
2100
|
const { any, all, none, html, target } = node;
|
|
2289
2101
|
const rules = [...any, ...all, ...none];
|
|
2290
|
-
return React2.createElement(React2.Fragment, null, React2.createElement(Messages, null, rules.map((rule) => React2.createElement("div", { key: rule.id }, `${rule.message}${/(\.|: [^.]+\.*)$/.test(rule.message) ? "" : "."}`))), React2.createElement(Actions, null, React2.createElement(Button, { onClick: () => handleJumpToElement(node.target.toString()) }, React2.createElement(LocationIcon, null), " Jump to element"), React2.createElement(CopyButton, { onClick: () => handleCopyLink(node.linkPath) })), React2.createElement(
|
|
2102
|
+
return React2.createElement(React2.Fragment, null, React2.createElement(Messages, null, rules.map((rule) => React2.createElement("div", { key: rule.id }, `${rule.message}${/(\.|: [^.]+\.*)$/.test(rule.message) ? "" : "."}`))), React2.createElement(Actions, null, React2.createElement(Button, { ariaLabel: false, onClick: () => handleJumpToElement(node.target.toString()) }, React2.createElement(LocationIcon, null), " Jump to element"), React2.createElement(CopyButton, { onClick: () => handleCopyLink(node.linkPath) })), React2.createElement(
|
|
2291
2103
|
StyledSyntaxHighlighter,
|
|
2292
2104
|
{
|
|
2293
2105
|
language: "jsx",
|
|
@@ -2384,12 +2196,14 @@ var Report = /* @__PURE__ */ __name(({
|
|
|
2384
2196
|
const selection = selectedItems.get(id);
|
|
2385
2197
|
const title = getTitleForAxeResult(item);
|
|
2386
2198
|
return React3.createElement(Wrapper2, { key: id }, React3.createElement(HeaderBar, { onClick: (event) => toggleOpen(event, type, item), "data-active": !!selection }, React3.createElement(Title, null, React3.createElement("strong", null, title), React3.createElement(RuleId2, null, item.id)), item.impact && React3.createElement(Badge, { status: type === RuleType.PASS ? "neutral" : impactStatus[item.impact] }, impactLabels[item.impact]), React3.createElement(Count, null, item.nodes.length), React3.createElement(
|
|
2387
|
-
|
|
2199
|
+
Button2,
|
|
2388
2200
|
{
|
|
2389
2201
|
onClick: (event) => toggleOpen(event, type, item),
|
|
2390
|
-
|
|
2202
|
+
ariaLabel: `${selection ? "Collapse" : "Expand"} details for: ${title}`,
|
|
2391
2203
|
"aria-expanded": !!selection,
|
|
2392
|
-
"aria-controls": detailsId
|
|
2204
|
+
"aria-controls": detailsId,
|
|
2205
|
+
variant: "ghost",
|
|
2206
|
+
padding: "small"
|
|
2393
2207
|
},
|
|
2394
2208
|
React3.createElement(Icon, { style: { transform: `rotate(${selection ? -180 : 0}deg)` } })
|
|
2395
2209
|
)), selection ? React3.createElement(
|
|
@@ -2405,601 +2219,26 @@ var Report = /* @__PURE__ */ __name(({
|
|
|
2405
2219
|
}) : React3.createElement(EmptyTabContent, { title: empty })), "Report");
|
|
2406
2220
|
|
|
2407
2221
|
// src/components/Tabs.tsx
|
|
2408
|
-
import * as React5 from "react";
|
|
2409
|
-
import { IconButton as IconButton2, ScrollArea, TooltipNote, WithTooltip } from "storybook/internal/components";
|
|
2410
|
-
import { CollapseIcon, ExpandAltIcon, EyeCloseIcon, EyeIcon, SyncIcon } from "@storybook/icons";
|
|
2411
|
-
|
|
2412
|
-
// ../../node_modules/react-resize-detector/build/index.esm.js
|
|
2413
2222
|
import * as React4 from "react";
|
|
2414
|
-
import {
|
|
2415
|
-
import {
|
|
2416
|
-
|
|
2417
|
-
extendStatics = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(d2, b2) {
|
|
2418
|
-
d2.__proto__ = b2;
|
|
2419
|
-
} || function(d2, b2) {
|
|
2420
|
-
for (var p in b2) if (Object.prototype.hasOwnProperty.call(b2, p)) d2[p] = b2[p];
|
|
2421
|
-
};
|
|
2422
|
-
return extendStatics(d, b);
|
|
2423
|
-
}, "extendStatics");
|
|
2424
|
-
function __extends(d, b) {
|
|
2425
|
-
if (typeof b !== "function" && b !== null)
|
|
2426
|
-
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
2427
|
-
extendStatics(d, b);
|
|
2428
|
-
function __() {
|
|
2429
|
-
this.constructor = d;
|
|
2430
|
-
}
|
|
2431
|
-
__name(__, "__");
|
|
2432
|
-
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
2433
|
-
}
|
|
2434
|
-
__name(__extends, "__extends");
|
|
2435
|
-
var __assign = /* @__PURE__ */ __name(function() {
|
|
2436
|
-
__assign = Object.assign || /* @__PURE__ */ __name(function __assign2(t) {
|
|
2437
|
-
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
2438
|
-
s = arguments[i];
|
|
2439
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];
|
|
2440
|
-
}
|
|
2441
|
-
return t;
|
|
2442
|
-
}, "__assign");
|
|
2443
|
-
return __assign.apply(this, arguments);
|
|
2444
|
-
}, "__assign");
|
|
2445
|
-
function __rest(s, e) {
|
|
2446
|
-
var t = {};
|
|
2447
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
2448
|
-
t[p] = s[p];
|
|
2449
|
-
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
2450
|
-
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
2451
|
-
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
2452
|
-
t[p[i]] = s[p[i]];
|
|
2453
|
-
}
|
|
2454
|
-
return t;
|
|
2455
|
-
}
|
|
2456
|
-
__name(__rest, "__rest");
|
|
2457
|
-
var commonjsGlobal = typeof globalThis !== "undefined" ? globalThis : typeof window !== "undefined" ? window : typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : {};
|
|
2458
|
-
function isObject$3(value) {
|
|
2459
|
-
var type = typeof value;
|
|
2460
|
-
return value != null && (type == "object" || type == "function");
|
|
2461
|
-
}
|
|
2462
|
-
__name(isObject$3, "isObject$3");
|
|
2463
|
-
var isObject_1 = isObject$3;
|
|
2464
|
-
var freeGlobal$1 = typeof commonjsGlobal == "object" && commonjsGlobal && commonjsGlobal.Object === Object && commonjsGlobal;
|
|
2465
|
-
var _freeGlobal = freeGlobal$1;
|
|
2466
|
-
var freeGlobal = _freeGlobal;
|
|
2467
|
-
var freeSelf = typeof self == "object" && self && self.Object === Object && self;
|
|
2468
|
-
var root$2 = freeGlobal || freeSelf || Function("return this")();
|
|
2469
|
-
var _root = root$2;
|
|
2470
|
-
var root$1 = _root;
|
|
2471
|
-
var now$1 = /* @__PURE__ */ __name(function() {
|
|
2472
|
-
return root$1.Date.now();
|
|
2473
|
-
}, "now$1");
|
|
2474
|
-
var now_1 = now$1;
|
|
2475
|
-
var reWhitespace = /\s/;
|
|
2476
|
-
function trimmedEndIndex$1(string) {
|
|
2477
|
-
var index = string.length;
|
|
2478
|
-
while (index-- && reWhitespace.test(string.charAt(index))) {
|
|
2479
|
-
}
|
|
2480
|
-
return index;
|
|
2481
|
-
}
|
|
2482
|
-
__name(trimmedEndIndex$1, "trimmedEndIndex$1");
|
|
2483
|
-
var _trimmedEndIndex = trimmedEndIndex$1;
|
|
2484
|
-
var trimmedEndIndex = _trimmedEndIndex;
|
|
2485
|
-
var reTrimStart = /^\s+/;
|
|
2486
|
-
function baseTrim$1(string) {
|
|
2487
|
-
return string ? string.slice(0, trimmedEndIndex(string) + 1).replace(reTrimStart, "") : string;
|
|
2488
|
-
}
|
|
2489
|
-
__name(baseTrim$1, "baseTrim$1");
|
|
2490
|
-
var _baseTrim = baseTrim$1;
|
|
2491
|
-
var root = _root;
|
|
2492
|
-
var Symbol$2 = root.Symbol;
|
|
2493
|
-
var _Symbol = Symbol$2;
|
|
2494
|
-
var Symbol$1 = _Symbol;
|
|
2495
|
-
var objectProto$1 = Object.prototype;
|
|
2496
|
-
var hasOwnProperty = objectProto$1.hasOwnProperty;
|
|
2497
|
-
var nativeObjectToString$1 = objectProto$1.toString;
|
|
2498
|
-
var symToStringTag$1 = Symbol$1 ? Symbol$1.toStringTag : void 0;
|
|
2499
|
-
function getRawTag$1(value) {
|
|
2500
|
-
var isOwn = hasOwnProperty.call(value, symToStringTag$1), tag = value[symToStringTag$1];
|
|
2501
|
-
try {
|
|
2502
|
-
value[symToStringTag$1] = void 0;
|
|
2503
|
-
var unmasked = true;
|
|
2504
|
-
} catch (e) {
|
|
2505
|
-
}
|
|
2506
|
-
var result = nativeObjectToString$1.call(value);
|
|
2507
|
-
if (unmasked) {
|
|
2508
|
-
if (isOwn) {
|
|
2509
|
-
value[symToStringTag$1] = tag;
|
|
2510
|
-
} else {
|
|
2511
|
-
delete value[symToStringTag$1];
|
|
2512
|
-
}
|
|
2513
|
-
}
|
|
2514
|
-
return result;
|
|
2515
|
-
}
|
|
2516
|
-
__name(getRawTag$1, "getRawTag$1");
|
|
2517
|
-
var _getRawTag = getRawTag$1;
|
|
2518
|
-
var objectProto = Object.prototype;
|
|
2519
|
-
var nativeObjectToString = objectProto.toString;
|
|
2520
|
-
function objectToString$1(value) {
|
|
2521
|
-
return nativeObjectToString.call(value);
|
|
2522
|
-
}
|
|
2523
|
-
__name(objectToString$1, "objectToString$1");
|
|
2524
|
-
var _objectToString = objectToString$1;
|
|
2525
|
-
var Symbol2 = _Symbol;
|
|
2526
|
-
var getRawTag = _getRawTag;
|
|
2527
|
-
var objectToString = _objectToString;
|
|
2528
|
-
var nullTag = "[object Null]";
|
|
2529
|
-
var undefinedTag = "[object Undefined]";
|
|
2530
|
-
var symToStringTag = Symbol2 ? Symbol2.toStringTag : void 0;
|
|
2531
|
-
function baseGetTag$1(value) {
|
|
2532
|
-
if (value == null) {
|
|
2533
|
-
return value === void 0 ? undefinedTag : nullTag;
|
|
2534
|
-
}
|
|
2535
|
-
return symToStringTag && symToStringTag in Object(value) ? getRawTag(value) : objectToString(value);
|
|
2536
|
-
}
|
|
2537
|
-
__name(baseGetTag$1, "baseGetTag$1");
|
|
2538
|
-
var _baseGetTag = baseGetTag$1;
|
|
2539
|
-
function isObjectLike$1(value) {
|
|
2540
|
-
return value != null && typeof value == "object";
|
|
2541
|
-
}
|
|
2542
|
-
__name(isObjectLike$1, "isObjectLike$1");
|
|
2543
|
-
var isObjectLike_1 = isObjectLike$1;
|
|
2544
|
-
var baseGetTag = _baseGetTag;
|
|
2545
|
-
var isObjectLike = isObjectLike_1;
|
|
2546
|
-
var symbolTag = "[object Symbol]";
|
|
2547
|
-
function isSymbol$1(value) {
|
|
2548
|
-
return typeof value == "symbol" || isObjectLike(value) && baseGetTag(value) == symbolTag;
|
|
2549
|
-
}
|
|
2550
|
-
__name(isSymbol$1, "isSymbol$1");
|
|
2551
|
-
var isSymbol_1 = isSymbol$1;
|
|
2552
|
-
var baseTrim = _baseTrim;
|
|
2553
|
-
var isObject$2 = isObject_1;
|
|
2554
|
-
var isSymbol = isSymbol_1;
|
|
2555
|
-
var NAN = 0 / 0;
|
|
2556
|
-
var reIsBadHex = /^[-+]0x[0-9a-f]+$/i;
|
|
2557
|
-
var reIsBinary = /^0b[01]+$/i;
|
|
2558
|
-
var reIsOctal = /^0o[0-7]+$/i;
|
|
2559
|
-
var freeParseInt = parseInt;
|
|
2560
|
-
function toNumber$1(value) {
|
|
2561
|
-
if (typeof value == "number") {
|
|
2562
|
-
return value;
|
|
2563
|
-
}
|
|
2564
|
-
if (isSymbol(value)) {
|
|
2565
|
-
return NAN;
|
|
2566
|
-
}
|
|
2567
|
-
if (isObject$2(value)) {
|
|
2568
|
-
var other = typeof value.valueOf == "function" ? value.valueOf() : value;
|
|
2569
|
-
value = isObject$2(other) ? other + "" : other;
|
|
2570
|
-
}
|
|
2571
|
-
if (typeof value != "string") {
|
|
2572
|
-
return value === 0 ? value : +value;
|
|
2573
|
-
}
|
|
2574
|
-
value = baseTrim(value);
|
|
2575
|
-
var isBinary = reIsBinary.test(value);
|
|
2576
|
-
return isBinary || reIsOctal.test(value) ? freeParseInt(value.slice(2), isBinary ? 2 : 8) : reIsBadHex.test(value) ? NAN : +value;
|
|
2577
|
-
}
|
|
2578
|
-
__name(toNumber$1, "toNumber$1");
|
|
2579
|
-
var toNumber_1 = toNumber$1;
|
|
2580
|
-
var isObject$1 = isObject_1;
|
|
2581
|
-
var now = now_1;
|
|
2582
|
-
var toNumber = toNumber_1;
|
|
2583
|
-
var FUNC_ERROR_TEXT$1 = "Expected a function";
|
|
2584
|
-
var nativeMax = Math.max;
|
|
2585
|
-
var nativeMin = Math.min;
|
|
2586
|
-
function debounce$1(func, wait, options) {
|
|
2587
|
-
var lastArgs, lastThis, maxWait, result, timerId, lastCallTime, lastInvokeTime = 0, leading = false, maxing = false, trailing = true;
|
|
2588
|
-
if (typeof func != "function") {
|
|
2589
|
-
throw new TypeError(FUNC_ERROR_TEXT$1);
|
|
2590
|
-
}
|
|
2591
|
-
wait = toNumber(wait) || 0;
|
|
2592
|
-
if (isObject$1(options)) {
|
|
2593
|
-
leading = !!options.leading;
|
|
2594
|
-
maxing = "maxWait" in options;
|
|
2595
|
-
maxWait = maxing ? nativeMax(toNumber(options.maxWait) || 0, wait) : maxWait;
|
|
2596
|
-
trailing = "trailing" in options ? !!options.trailing : trailing;
|
|
2597
|
-
}
|
|
2598
|
-
function invokeFunc(time) {
|
|
2599
|
-
var args = lastArgs, thisArg = lastThis;
|
|
2600
|
-
lastArgs = lastThis = void 0;
|
|
2601
|
-
lastInvokeTime = time;
|
|
2602
|
-
result = func.apply(thisArg, args);
|
|
2603
|
-
return result;
|
|
2604
|
-
}
|
|
2605
|
-
__name(invokeFunc, "invokeFunc");
|
|
2606
|
-
function leadingEdge(time) {
|
|
2607
|
-
lastInvokeTime = time;
|
|
2608
|
-
timerId = setTimeout(timerExpired, wait);
|
|
2609
|
-
return leading ? invokeFunc(time) : result;
|
|
2610
|
-
}
|
|
2611
|
-
__name(leadingEdge, "leadingEdge");
|
|
2612
|
-
function remainingWait(time) {
|
|
2613
|
-
var timeSinceLastCall = time - lastCallTime, timeSinceLastInvoke = time - lastInvokeTime, timeWaiting = wait - timeSinceLastCall;
|
|
2614
|
-
return maxing ? nativeMin(timeWaiting, maxWait - timeSinceLastInvoke) : timeWaiting;
|
|
2615
|
-
}
|
|
2616
|
-
__name(remainingWait, "remainingWait");
|
|
2617
|
-
function shouldInvoke(time) {
|
|
2618
|
-
var timeSinceLastCall = time - lastCallTime, timeSinceLastInvoke = time - lastInvokeTime;
|
|
2619
|
-
return lastCallTime === void 0 || timeSinceLastCall >= wait || timeSinceLastCall < 0 || maxing && timeSinceLastInvoke >= maxWait;
|
|
2620
|
-
}
|
|
2621
|
-
__name(shouldInvoke, "shouldInvoke");
|
|
2622
|
-
function timerExpired() {
|
|
2623
|
-
var time = now();
|
|
2624
|
-
if (shouldInvoke(time)) {
|
|
2625
|
-
return trailingEdge(time);
|
|
2626
|
-
}
|
|
2627
|
-
timerId = setTimeout(timerExpired, remainingWait(time));
|
|
2628
|
-
}
|
|
2629
|
-
__name(timerExpired, "timerExpired");
|
|
2630
|
-
function trailingEdge(time) {
|
|
2631
|
-
timerId = void 0;
|
|
2632
|
-
if (trailing && lastArgs) {
|
|
2633
|
-
return invokeFunc(time);
|
|
2634
|
-
}
|
|
2635
|
-
lastArgs = lastThis = void 0;
|
|
2636
|
-
return result;
|
|
2637
|
-
}
|
|
2638
|
-
__name(trailingEdge, "trailingEdge");
|
|
2639
|
-
function cancel() {
|
|
2640
|
-
if (timerId !== void 0) {
|
|
2641
|
-
clearTimeout(timerId);
|
|
2642
|
-
}
|
|
2643
|
-
lastInvokeTime = 0;
|
|
2644
|
-
lastArgs = lastCallTime = lastThis = timerId = void 0;
|
|
2645
|
-
}
|
|
2646
|
-
__name(cancel, "cancel");
|
|
2647
|
-
function flush() {
|
|
2648
|
-
return timerId === void 0 ? result : trailingEdge(now());
|
|
2649
|
-
}
|
|
2650
|
-
__name(flush, "flush");
|
|
2651
|
-
function debounced() {
|
|
2652
|
-
var time = now(), isInvoking = shouldInvoke(time);
|
|
2653
|
-
lastArgs = arguments;
|
|
2654
|
-
lastThis = this;
|
|
2655
|
-
lastCallTime = time;
|
|
2656
|
-
if (isInvoking) {
|
|
2657
|
-
if (timerId === void 0) {
|
|
2658
|
-
return leadingEdge(lastCallTime);
|
|
2659
|
-
}
|
|
2660
|
-
if (maxing) {
|
|
2661
|
-
clearTimeout(timerId);
|
|
2662
|
-
timerId = setTimeout(timerExpired, wait);
|
|
2663
|
-
return invokeFunc(lastCallTime);
|
|
2664
|
-
}
|
|
2665
|
-
}
|
|
2666
|
-
if (timerId === void 0) {
|
|
2667
|
-
timerId = setTimeout(timerExpired, wait);
|
|
2668
|
-
}
|
|
2669
|
-
return result;
|
|
2670
|
-
}
|
|
2671
|
-
__name(debounced, "debounced");
|
|
2672
|
-
debounced.cancel = cancel;
|
|
2673
|
-
debounced.flush = flush;
|
|
2674
|
-
return debounced;
|
|
2675
|
-
}
|
|
2676
|
-
__name(debounce$1, "debounce$1");
|
|
2677
|
-
var debounce_1 = debounce$1;
|
|
2678
|
-
var debounce = debounce_1;
|
|
2679
|
-
var isObject = isObject_1;
|
|
2680
|
-
var FUNC_ERROR_TEXT = "Expected a function";
|
|
2681
|
-
function throttle(func, wait, options) {
|
|
2682
|
-
var leading = true, trailing = true;
|
|
2683
|
-
if (typeof func != "function") {
|
|
2684
|
-
throw new TypeError(FUNC_ERROR_TEXT);
|
|
2685
|
-
}
|
|
2686
|
-
if (isObject(options)) {
|
|
2687
|
-
leading = "leading" in options ? !!options.leading : leading;
|
|
2688
|
-
trailing = "trailing" in options ? !!options.trailing : trailing;
|
|
2689
|
-
}
|
|
2690
|
-
return debounce(func, wait, {
|
|
2691
|
-
"leading": leading,
|
|
2692
|
-
"maxWait": wait,
|
|
2693
|
-
"trailing": trailing
|
|
2694
|
-
});
|
|
2695
|
-
}
|
|
2696
|
-
__name(throttle, "throttle");
|
|
2697
|
-
var throttle_1 = throttle;
|
|
2698
|
-
var patchResizeHandler = /* @__PURE__ */ __name(function(resizeCallback, refreshMode, refreshRate, refreshOptions) {
|
|
2699
|
-
switch (refreshMode) {
|
|
2700
|
-
case "debounce":
|
|
2701
|
-
return debounce_1(resizeCallback, refreshRate, refreshOptions);
|
|
2702
|
-
case "throttle":
|
|
2703
|
-
return throttle_1(resizeCallback, refreshRate, refreshOptions);
|
|
2704
|
-
default:
|
|
2705
|
-
return resizeCallback;
|
|
2706
|
-
}
|
|
2707
|
-
}, "patchResizeHandler");
|
|
2708
|
-
var isFunction = /* @__PURE__ */ __name(function(fn) {
|
|
2709
|
-
return typeof fn === "function";
|
|
2710
|
-
}, "isFunction");
|
|
2711
|
-
var isSSR = /* @__PURE__ */ __name(function() {
|
|
2712
|
-
return typeof window === "undefined";
|
|
2713
|
-
}, "isSSR");
|
|
2714
|
-
var isDOMElement = /* @__PURE__ */ __name(function(element) {
|
|
2715
|
-
return element instanceof Element || element instanceof HTMLDocument;
|
|
2716
|
-
}, "isDOMElement");
|
|
2717
|
-
var createNotifier = /* @__PURE__ */ __name(function(onResize, setSize, handleWidth, handleHeight) {
|
|
2718
|
-
return function(_a) {
|
|
2719
|
-
var width = _a.width, height = _a.height;
|
|
2720
|
-
setSize(function(prev) {
|
|
2721
|
-
if (prev.width === width && prev.height === height) {
|
|
2722
|
-
return prev;
|
|
2723
|
-
}
|
|
2724
|
-
if (prev.width === width && !handleHeight || prev.height === height && !handleWidth) {
|
|
2725
|
-
return prev;
|
|
2726
|
-
}
|
|
2727
|
-
if (onResize && isFunction(onResize)) {
|
|
2728
|
-
onResize(width, height);
|
|
2729
|
-
}
|
|
2730
|
-
return { width, height };
|
|
2731
|
-
});
|
|
2732
|
-
};
|
|
2733
|
-
}, "createNotifier");
|
|
2734
|
-
var ResizeDetector = (
|
|
2735
|
-
/** @class */
|
|
2736
|
-
function(_super) {
|
|
2737
|
-
__extends(ResizeDetector2, _super);
|
|
2738
|
-
function ResizeDetector2(props) {
|
|
2739
|
-
var _this = _super.call(this, props) || this;
|
|
2740
|
-
_this.cancelHandler = function() {
|
|
2741
|
-
if (_this.resizeHandler && _this.resizeHandler.cancel) {
|
|
2742
|
-
_this.resizeHandler.cancel();
|
|
2743
|
-
_this.resizeHandler = null;
|
|
2744
|
-
}
|
|
2745
|
-
};
|
|
2746
|
-
_this.attachObserver = function() {
|
|
2747
|
-
var _a2 = _this.props, targetRef = _a2.targetRef, observerOptions = _a2.observerOptions;
|
|
2748
|
-
if (isSSR()) {
|
|
2749
|
-
return;
|
|
2750
|
-
}
|
|
2751
|
-
if (targetRef && targetRef.current) {
|
|
2752
|
-
_this.targetRef.current = targetRef.current;
|
|
2753
|
-
}
|
|
2754
|
-
var element = _this.getElement();
|
|
2755
|
-
if (!element) {
|
|
2756
|
-
return;
|
|
2757
|
-
}
|
|
2758
|
-
if (_this.observableElement && _this.observableElement === element) {
|
|
2759
|
-
return;
|
|
2760
|
-
}
|
|
2761
|
-
_this.observableElement = element;
|
|
2762
|
-
_this.resizeObserver.observe(element, observerOptions);
|
|
2763
|
-
};
|
|
2764
|
-
_this.getElement = function() {
|
|
2765
|
-
var _a2 = _this.props, querySelector = _a2.querySelector, targetDomEl = _a2.targetDomEl;
|
|
2766
|
-
if (isSSR())
|
|
2767
|
-
return null;
|
|
2768
|
-
if (querySelector)
|
|
2769
|
-
return document.querySelector(querySelector);
|
|
2770
|
-
if (targetDomEl && isDOMElement(targetDomEl))
|
|
2771
|
-
return targetDomEl;
|
|
2772
|
-
if (_this.targetRef && isDOMElement(_this.targetRef.current))
|
|
2773
|
-
return _this.targetRef.current;
|
|
2774
|
-
var currentElement = findDOMNode(_this);
|
|
2775
|
-
if (!currentElement)
|
|
2776
|
-
return null;
|
|
2777
|
-
var renderType = _this.getRenderType();
|
|
2778
|
-
switch (renderType) {
|
|
2779
|
-
case "renderProp":
|
|
2780
|
-
return currentElement;
|
|
2781
|
-
case "childFunction":
|
|
2782
|
-
return currentElement;
|
|
2783
|
-
case "child":
|
|
2784
|
-
return currentElement;
|
|
2785
|
-
case "childArray":
|
|
2786
|
-
return currentElement;
|
|
2787
|
-
default:
|
|
2788
|
-
return currentElement.parentElement;
|
|
2789
|
-
}
|
|
2790
|
-
};
|
|
2791
|
-
_this.createResizeHandler = function(entries) {
|
|
2792
|
-
var _a2 = _this.props, _b = _a2.handleWidth, handleWidth = _b === void 0 ? true : _b, _c = _a2.handleHeight, handleHeight = _c === void 0 ? true : _c, onResize = _a2.onResize;
|
|
2793
|
-
if (!handleWidth && !handleHeight)
|
|
2794
|
-
return;
|
|
2795
|
-
var notifyResize = createNotifier(onResize, _this.setState.bind(_this), handleWidth, handleHeight);
|
|
2796
|
-
entries.forEach(function(entry) {
|
|
2797
|
-
var _a3 = entry && entry.contentRect || {}, width = _a3.width, height = _a3.height;
|
|
2798
|
-
var shouldSetSize = !_this.skipOnMount && !isSSR();
|
|
2799
|
-
if (shouldSetSize) {
|
|
2800
|
-
notifyResize({ width, height });
|
|
2801
|
-
}
|
|
2802
|
-
_this.skipOnMount = false;
|
|
2803
|
-
});
|
|
2804
|
-
};
|
|
2805
|
-
_this.getRenderType = function() {
|
|
2806
|
-
var _a2 = _this.props, render = _a2.render, children = _a2.children;
|
|
2807
|
-
if (isFunction(render)) {
|
|
2808
|
-
return "renderProp";
|
|
2809
|
-
}
|
|
2810
|
-
if (isFunction(children)) {
|
|
2811
|
-
return "childFunction";
|
|
2812
|
-
}
|
|
2813
|
-
if (isValidElement(children)) {
|
|
2814
|
-
return "child";
|
|
2815
|
-
}
|
|
2816
|
-
if (Array.isArray(children)) {
|
|
2817
|
-
return "childArray";
|
|
2818
|
-
}
|
|
2819
|
-
return "parent";
|
|
2820
|
-
};
|
|
2821
|
-
var skipOnMount = props.skipOnMount, refreshMode = props.refreshMode, _a = props.refreshRate, refreshRate = _a === void 0 ? 1e3 : _a, refreshOptions = props.refreshOptions;
|
|
2822
|
-
_this.state = {
|
|
2823
|
-
width: void 0,
|
|
2824
|
-
height: void 0
|
|
2825
|
-
};
|
|
2826
|
-
_this.skipOnMount = skipOnMount;
|
|
2827
|
-
_this.targetRef = createRef();
|
|
2828
|
-
_this.observableElement = null;
|
|
2829
|
-
if (isSSR()) {
|
|
2830
|
-
return _this;
|
|
2831
|
-
}
|
|
2832
|
-
_this.resizeHandler = patchResizeHandler(_this.createResizeHandler, refreshMode, refreshRate, refreshOptions);
|
|
2833
|
-
_this.resizeObserver = new window.ResizeObserver(_this.resizeHandler);
|
|
2834
|
-
return _this;
|
|
2835
|
-
}
|
|
2836
|
-
__name(ResizeDetector2, "ResizeDetector");
|
|
2837
|
-
ResizeDetector2.prototype.componentDidMount = function() {
|
|
2838
|
-
this.attachObserver();
|
|
2839
|
-
};
|
|
2840
|
-
ResizeDetector2.prototype.componentDidUpdate = function() {
|
|
2841
|
-
this.attachObserver();
|
|
2842
|
-
};
|
|
2843
|
-
ResizeDetector2.prototype.componentWillUnmount = function() {
|
|
2844
|
-
if (isSSR()) {
|
|
2845
|
-
return;
|
|
2846
|
-
}
|
|
2847
|
-
this.observableElement = null;
|
|
2848
|
-
this.resizeObserver.disconnect();
|
|
2849
|
-
this.cancelHandler();
|
|
2850
|
-
};
|
|
2851
|
-
ResizeDetector2.prototype.render = function() {
|
|
2852
|
-
var _a = this.props, render = _a.render, children = _a.children, _b = _a.nodeType, WrapperTag = _b === void 0 ? "div" : _b;
|
|
2853
|
-
var _c = this.state, width = _c.width, height = _c.height;
|
|
2854
|
-
var childProps = { width, height, targetRef: this.targetRef };
|
|
2855
|
-
var renderType = this.getRenderType();
|
|
2856
|
-
var typedChildren;
|
|
2857
|
-
switch (renderType) {
|
|
2858
|
-
case "renderProp":
|
|
2859
|
-
return render && render(childProps);
|
|
2860
|
-
case "childFunction":
|
|
2861
|
-
typedChildren = children;
|
|
2862
|
-
return typedChildren(childProps);
|
|
2863
|
-
case "child":
|
|
2864
|
-
typedChildren = children;
|
|
2865
|
-
if (typedChildren.type && typeof typedChildren.type === "string") {
|
|
2866
|
-
childProps.targetRef;
|
|
2867
|
-
var nativeProps = __rest(childProps, ["targetRef"]);
|
|
2868
|
-
return cloneElement(typedChildren, nativeProps);
|
|
2869
|
-
}
|
|
2870
|
-
return cloneElement(typedChildren, childProps);
|
|
2871
|
-
case "childArray":
|
|
2872
|
-
typedChildren = children;
|
|
2873
|
-
return typedChildren.map(function(el) {
|
|
2874
|
-
return !!el && cloneElement(el, childProps);
|
|
2875
|
-
});
|
|
2876
|
-
default:
|
|
2877
|
-
return React4.createElement(WrapperTag, null);
|
|
2878
|
-
}
|
|
2879
|
-
};
|
|
2880
|
-
return ResizeDetector2;
|
|
2881
|
-
}(PureComponent)
|
|
2882
|
-
);
|
|
2883
|
-
var useEnhancedEffect = isSSR() ? useEffect2 : useLayoutEffect;
|
|
2884
|
-
function useResizeDetector(props) {
|
|
2885
|
-
if (props === void 0) {
|
|
2886
|
-
props = {};
|
|
2887
|
-
}
|
|
2888
|
-
var _a = props.skipOnMount, skipOnMount = _a === void 0 ? false : _a, refreshMode = props.refreshMode, _b = props.refreshRate, refreshRate = _b === void 0 ? 1e3 : _b, refreshOptions = props.refreshOptions, _c = props.handleWidth, handleWidth = _c === void 0 ? true : _c, _d = props.handleHeight, handleHeight = _d === void 0 ? true : _d, targetRef = props.targetRef, observerOptions = props.observerOptions, onResize = props.onResize;
|
|
2889
|
-
var skipResize = useRef(skipOnMount);
|
|
2890
|
-
var localRef = useRef(null);
|
|
2891
|
-
var ref = targetRef !== null && targetRef !== void 0 ? targetRef : localRef;
|
|
2892
|
-
var resizeHandler = useRef();
|
|
2893
|
-
var _e = useState4({
|
|
2894
|
-
width: void 0,
|
|
2895
|
-
height: void 0
|
|
2896
|
-
}), size = _e[0], setSize = _e[1];
|
|
2897
|
-
useEnhancedEffect(function() {
|
|
2898
|
-
if (isSSR()) {
|
|
2899
|
-
return;
|
|
2900
|
-
}
|
|
2901
|
-
var notifyResize = createNotifier(onResize, setSize, handleWidth, handleHeight);
|
|
2902
|
-
var resizeCallback = /* @__PURE__ */ __name(function(entries) {
|
|
2903
|
-
if (!handleWidth && !handleHeight)
|
|
2904
|
-
return;
|
|
2905
|
-
entries.forEach(function(entry) {
|
|
2906
|
-
var _a2 = entry && entry.contentRect || {}, width = _a2.width, height = _a2.height;
|
|
2907
|
-
var shouldSetSize = !skipResize.current && !isSSR();
|
|
2908
|
-
if (shouldSetSize) {
|
|
2909
|
-
notifyResize({ width, height });
|
|
2910
|
-
}
|
|
2911
|
-
skipResize.current = false;
|
|
2912
|
-
});
|
|
2913
|
-
}, "resizeCallback");
|
|
2914
|
-
resizeHandler.current = patchResizeHandler(resizeCallback, refreshMode, refreshRate, refreshOptions);
|
|
2915
|
-
var resizeObserver = new window.ResizeObserver(resizeHandler.current);
|
|
2916
|
-
if (ref.current) {
|
|
2917
|
-
resizeObserver.observe(ref.current, observerOptions);
|
|
2918
|
-
}
|
|
2919
|
-
return function() {
|
|
2920
|
-
resizeObserver.disconnect();
|
|
2921
|
-
var patchedResizeHandler = resizeHandler.current;
|
|
2922
|
-
if (patchedResizeHandler && patchedResizeHandler.cancel) {
|
|
2923
|
-
patchedResizeHandler.cancel();
|
|
2924
|
-
}
|
|
2925
|
-
};
|
|
2926
|
-
}, [refreshMode, refreshRate, refreshOptions, handleWidth, handleHeight, onResize, observerOptions, ref.current]);
|
|
2927
|
-
return __assign({ ref }, size);
|
|
2928
|
-
}
|
|
2929
|
-
__name(useResizeDetector, "useResizeDetector");
|
|
2930
|
-
|
|
2931
|
-
// src/components/Tabs.tsx
|
|
2932
|
-
import { styled as styled3 } from "storybook/theming";
|
|
2223
|
+
import { Button as Button3, TabsView } from "storybook/internal/components";
|
|
2224
|
+
import { CollapseIcon, ExpandAltIcon, EyeCloseIcon, EyeIcon, SyncIcon } from "@storybook/icons";
|
|
2225
|
+
import { styled as styled3, useTheme } from "storybook/theming";
|
|
2933
2226
|
var Container = styled3.div({
|
|
2934
2227
|
width: "100%",
|
|
2935
2228
|
position: "relative",
|
|
2936
|
-
|
|
2937
|
-
|
|
2938
|
-
var Item2 = styled3.button(
|
|
2939
|
-
({ theme: theme2 }) => ({
|
|
2940
|
-
textDecoration: "none",
|
|
2941
|
-
padding: "10px 15px",
|
|
2942
|
-
cursor: "pointer",
|
|
2943
|
-
color: theme2.textMutedColor,
|
|
2944
|
-
fontWeight: theme2.typography.weight.bold,
|
|
2945
|
-
fontSize: theme2.typography.size.s2 - 1,
|
|
2946
|
-
lineHeight: 1,
|
|
2947
|
-
height: 40,
|
|
2948
|
-
border: "none",
|
|
2949
|
-
borderBottom: "3px solid transparent",
|
|
2950
|
-
background: "transparent",
|
|
2951
|
-
"&:focus": {
|
|
2952
|
-
outline: "0 none",
|
|
2953
|
-
borderColor: theme2.color.secondary
|
|
2954
|
-
}
|
|
2955
|
-
}),
|
|
2956
|
-
({ active, theme: theme2 }) => active ? {
|
|
2957
|
-
opacity: 1,
|
|
2958
|
-
color: theme2.color.secondary,
|
|
2959
|
-
borderColor: theme2.color.secondary
|
|
2960
|
-
} : {}
|
|
2961
|
-
);
|
|
2962
|
-
var Subnav = styled3.div(({ theme: theme2 }) => ({
|
|
2963
|
-
boxShadow: `${theme2.appBorderColor} 0 -1px 0 0 inset`,
|
|
2964
|
-
background: theme2.background.app,
|
|
2965
|
-
position: "sticky",
|
|
2966
|
-
top: 0,
|
|
2967
|
-
zIndex: 1,
|
|
2229
|
+
height: "100%",
|
|
2230
|
+
overflow: "hidden",
|
|
2968
2231
|
display: "flex",
|
|
2969
|
-
|
|
2970
|
-
|
|
2971
|
-
overflow: "auto",
|
|
2972
|
-
paddingRight: 10,
|
|
2973
|
-
gap: 6,
|
|
2974
|
-
scrollbarColor: `${theme2.barTextColor} ${theme2.background.app}`,
|
|
2975
|
-
scrollbarWidth: "thin"
|
|
2976
|
-
}));
|
|
2977
|
-
var TabsWrapper = styled3.div({});
|
|
2232
|
+
flexDirection: "column"
|
|
2233
|
+
});
|
|
2978
2234
|
var ActionsWrapper = styled3.div({
|
|
2979
2235
|
display: "flex",
|
|
2980
|
-
flexBasis: "100%",
|
|
2981
2236
|
justifyContent: "flex-end",
|
|
2982
|
-
containerType: "inline-size",
|
|
2983
|
-
// 96px is the total width of the buttons without labels
|
|
2984
|
-
minWidth: 96,
|
|
2985
2237
|
gap: 6
|
|
2986
2238
|
});
|
|
2987
|
-
var ToggleButton = styled3(IconButton2)({
|
|
2988
|
-
// 193px is the total width of the action buttons when the label is visible
|
|
2989
|
-
"@container (max-width: 193px)": {
|
|
2990
|
-
span: {
|
|
2991
|
-
display: "none"
|
|
2992
|
-
}
|
|
2993
|
-
}
|
|
2994
|
-
});
|
|
2995
2239
|
var Tabs = /* @__PURE__ */ __name(({ tabs }) => {
|
|
2996
|
-
const { ref } = useResizeDetector({
|
|
2997
|
-
refreshMode: "debounce",
|
|
2998
|
-
handleHeight: false,
|
|
2999
|
-
handleWidth: true
|
|
3000
|
-
});
|
|
3001
2240
|
const {
|
|
3002
|
-
tab
|
|
2241
|
+
tab,
|
|
3003
2242
|
setTab,
|
|
3004
2243
|
toggleHighlight,
|
|
3005
2244
|
highlighted,
|
|
@@ -3008,66 +2247,54 @@ var Tabs = /* @__PURE__ */ __name(({ tabs }) => {
|
|
|
3008
2247
|
handleCollapseAll,
|
|
3009
2248
|
handleExpandAll
|
|
3010
2249
|
} = useA11yContext();
|
|
3011
|
-
const
|
|
3012
|
-
|
|
3013
|
-
|
|
3014
|
-
},
|
|
3015
|
-
[setTab]
|
|
3016
|
-
);
|
|
3017
|
-
return React5.createElement(Container, { ref }, React5.createElement(Subnav, null, React5.createElement(TabsWrapper, { role: "tablist" }, tabs.map((tab, index) => React5.createElement(
|
|
3018
|
-
Item2,
|
|
2250
|
+
const theme2 = useTheme();
|
|
2251
|
+
return React4.createElement(Container, null, React4.createElement(
|
|
2252
|
+
TabsView,
|
|
3019
2253
|
{
|
|
3020
|
-
|
|
3021
|
-
|
|
3022
|
-
|
|
3023
|
-
|
|
3024
|
-
|
|
3025
|
-
|
|
3026
|
-
|
|
3027
|
-
|
|
3028
|
-
|
|
3029
|
-
|
|
3030
|
-
|
|
3031
|
-
|
|
3032
|
-
|
|
3033
|
-
|
|
3034
|
-
|
|
3035
|
-
|
|
3036
|
-
|
|
3037
|
-
|
|
3038
|
-
|
|
3039
|
-
|
|
3040
|
-
|
|
3041
|
-
|
|
3042
|
-
|
|
3043
|
-
|
|
3044
|
-
|
|
3045
|
-
|
|
3046
|
-
|
|
3047
|
-
|
|
3048
|
-
|
|
3049
|
-
|
|
3050
|
-
|
|
3051
|
-
|
|
3052
|
-
|
|
3053
|
-
|
|
3054
|
-
|
|
3055
|
-
|
|
3056
|
-
|
|
3057
|
-
|
|
3058
|
-
|
|
3059
|
-
|
|
3060
|
-
hasChrome: false,
|
|
3061
|
-
placement: "top",
|
|
3062
|
-
tooltip: React5.createElement(TooltipNote, { note: "Rerun the accessibility scan" }),
|
|
3063
|
-
trigger: "hover"
|
|
3064
|
-
},
|
|
3065
|
-
React5.createElement(IconButton2, { onClick: handleManual, "aria-label": "Rerun accessibility scan" }, React5.createElement(SyncIcon, null))
|
|
3066
|
-
))), React5.createElement(ScrollArea, { vertical: true, horizontal: true }, tabs.find((t) => t.type === activeTab)?.panel));
|
|
2254
|
+
backgroundColor: theme2.background.app,
|
|
2255
|
+
panelProps: { hasScrollbar: true },
|
|
2256
|
+
tabs: tabs.map((tab2) => ({
|
|
2257
|
+
id: tab2.type,
|
|
2258
|
+
title: tab2.label,
|
|
2259
|
+
children: tab2.panel
|
|
2260
|
+
})),
|
|
2261
|
+
selected: tab,
|
|
2262
|
+
onSelectionChange: (key) => setTab(key),
|
|
2263
|
+
tools: React4.createElement(ActionsWrapper, null, React4.createElement(
|
|
2264
|
+
Button3,
|
|
2265
|
+
{
|
|
2266
|
+
variant: "ghost",
|
|
2267
|
+
padding: "small",
|
|
2268
|
+
onClick: toggleHighlight,
|
|
2269
|
+
ariaLabel: highlighted ? "Hide accessibility test result highlights" : "Highlight elements with accessibility test results"
|
|
2270
|
+
},
|
|
2271
|
+
highlighted ? React4.createElement(EyeCloseIcon, null) : React4.createElement(EyeIcon, null)
|
|
2272
|
+
), React4.createElement(
|
|
2273
|
+
Button3,
|
|
2274
|
+
{
|
|
2275
|
+
variant: "ghost",
|
|
2276
|
+
padding: "small",
|
|
2277
|
+
onClick: allExpanded ? handleCollapseAll : handleExpandAll,
|
|
2278
|
+
ariaLabel: allExpanded ? "Collapse all results" : "Expand all results",
|
|
2279
|
+
"aria-expanded": allExpanded
|
|
2280
|
+
},
|
|
2281
|
+
allExpanded ? React4.createElement(CollapseIcon, null) : React4.createElement(ExpandAltIcon, null)
|
|
2282
|
+
), React4.createElement(
|
|
2283
|
+
Button3,
|
|
2284
|
+
{
|
|
2285
|
+
variant: "ghost",
|
|
2286
|
+
padding: "small",
|
|
2287
|
+
onClick: handleManual,
|
|
2288
|
+
ariaLabel: "Rerun accessibility scan"
|
|
2289
|
+
},
|
|
2290
|
+
React4.createElement(SyncIcon, null)
|
|
2291
|
+
))
|
|
2292
|
+
}
|
|
2293
|
+
));
|
|
3067
2294
|
}, "Tabs");
|
|
3068
2295
|
|
|
3069
2296
|
// src/components/TestDiscrepancyMessage.tsx
|
|
3070
|
-
import
|
|
2297
|
+
import React5, { useMemo as useMemo2 } from "react";
|
|
3071
2298
|
import { Link as Link2 } from "storybook/internal/components";
|
|
3072
2299
|
import { useStorybookApi as useStorybookApi2 } from "storybook/manager-api";
|
|
3073
2300
|
import { styled as styled4 } from "storybook/theming";
|
|
@@ -3114,7 +2341,7 @@ var TestDiscrepancyMessage = /* @__PURE__ */ __name(({ discrepancy }) => {
|
|
|
3114
2341
|
if (!message) {
|
|
3115
2342
|
return null;
|
|
3116
2343
|
}
|
|
3117
|
-
return
|
|
2344
|
+
return React5.createElement(Wrapper3, null, message, " ", React5.createElement(Link2, { href: docsUrl, target: "_blank", withArrow: true }, "Learn what could cause this"));
|
|
3118
2345
|
}, "TestDiscrepancyMessage");
|
|
3119
2346
|
|
|
3120
2347
|
// src/components/A11YPanel.tsx
|
|
@@ -3176,8 +2403,8 @@ var A11YPanel = /* @__PURE__ */ __name(() => {
|
|
|
3176
2403
|
};
|
|
3177
2404
|
return [
|
|
3178
2405
|
{
|
|
3179
|
-
label:
|
|
3180
|
-
panel:
|
|
2406
|
+
label: React6.createElement(Tab, null, "Violations", React6.createElement(Badge2, { compact: true, status: tab === "violations" ? "active" : "neutral" }, violations.length)),
|
|
2407
|
+
panel: React6.createElement(
|
|
3181
2408
|
Report,
|
|
3182
2409
|
{
|
|
3183
2410
|
items: violations,
|
|
@@ -3192,8 +2419,8 @@ var A11YPanel = /* @__PURE__ */ __name(() => {
|
|
|
3192
2419
|
type: RuleType.VIOLATION
|
|
3193
2420
|
},
|
|
3194
2421
|
{
|
|
3195
|
-
label:
|
|
3196
|
-
panel:
|
|
2422
|
+
label: React6.createElement(Tab, null, "Passes", React6.createElement(Badge2, { compact: true, status: tab === "passes" ? "active" : "neutral" }, passes.length)),
|
|
2423
|
+
panel: React6.createElement(
|
|
3197
2424
|
Report,
|
|
3198
2425
|
{
|
|
3199
2426
|
items: passes,
|
|
@@ -3208,8 +2435,8 @@ var A11YPanel = /* @__PURE__ */ __name(() => {
|
|
|
3208
2435
|
type: RuleType.PASS
|
|
3209
2436
|
},
|
|
3210
2437
|
{
|
|
3211
|
-
label:
|
|
3212
|
-
panel:
|
|
2438
|
+
label: React6.createElement(Tab, null, "Inconclusive", React6.createElement(Badge2, { compact: true, status: tab === "incomplete" ? "active" : "neutral" }, incomplete.length)),
|
|
2439
|
+
panel: React6.createElement(
|
|
3213
2440
|
Report,
|
|
3214
2441
|
{
|
|
3215
2442
|
items: incomplete,
|
|
@@ -3226,62 +2453,62 @@ var A11YPanel = /* @__PURE__ */ __name(() => {
|
|
|
3226
2453
|
];
|
|
3227
2454
|
}, [tab, results, handleSelectionChange, selectedItems, toggleOpen]);
|
|
3228
2455
|
if (parameters.disable || parameters.test === "off") {
|
|
3229
|
-
return
|
|
2456
|
+
return React6.createElement(Centered, null, React6.createElement("div", null, React6.createElement("strong", null, "Accessibility tests are disabled for this story"), React6.createElement("p", null, "Update", " ", React6.createElement("code", null, parameters.disable ? "parameters.a11y.disable" : "parameters.a11y.test"), " ", "to enable accessibility tests.")));
|
|
3230
2457
|
}
|
|
3231
|
-
return
|
|
2458
|
+
return React6.createElement(React6.Fragment, null, discrepancy && React6.createElement(TestDiscrepancyMessage, { discrepancy }), status === "ready" || status === "ran" ? React6.createElement(Tabs, { key: "tabs", tabs }) : React6.createElement(Centered, { style: { marginTop: discrepancy ? "1em" : 0 } }, status === "initial" && React6.createElement("div", null, React6.createElement(RotatingIcon, { size: 12 }), React6.createElement("strong", null, "Preparing accessibility scan"), React6.createElement("p", null, "Please wait while the addon is initializing...")), status === "manual" && React6.createElement(React6.Fragment, null, React6.createElement("div", null, React6.createElement("strong", null, "Accessibility tests run manually for this story"), React6.createElement("p", null, "Results will not show when using the testing module. You can still run accessibility tests manually.")), React6.createElement(Button4, { ariaLabel: false, size: "medium", onClick: handleManual }, "Run accessibility scan"), React6.createElement("p", null, "Update ", React6.createElement("code", null, "globals.a11y.manual"), " to disable manual mode.")), status === "running" && React6.createElement("div", null, React6.createElement(RotatingIcon, { size: 12 }), React6.createElement("strong", null, "Accessibility scan in progress"), React6.createElement("p", null, "Please wait while the accessibility scan is running...")), status === "error" && React6.createElement(React6.Fragment, null, React6.createElement("div", null, React6.createElement("strong", null, "The accessibility scan encountered an error"), React6.createElement("p", null, typeof error === "string" ? error : error instanceof Error ? error.toString() : JSON.stringify(error, null, 2))), React6.createElement(Button4, { ariaLabel: false, size: "medium", onClick: handleManual }, "Rerun accessibility scan")), status === "component-test-error" && React6.createElement(React6.Fragment, null, React6.createElement("div", null, React6.createElement("strong", null, "This story's component tests failed"), React6.createElement("p", null, "Automated accessibility tests will not run until this is resolved. You can still test manually.")), React6.createElement(Button4, { ariaLabel: false, size: "medium", onClick: handleManual }, "Run accessibility scan"))));
|
|
3232
2459
|
}, "A11YPanel");
|
|
3233
2460
|
|
|
3234
2461
|
// src/components/VisionSimulator.tsx
|
|
3235
|
-
import
|
|
3236
|
-
import {
|
|
2462
|
+
import React8, { useState as useState4 } from "react";
|
|
2463
|
+
import { Select } from "storybook/internal/components";
|
|
3237
2464
|
import { AccessibilityIcon } from "@storybook/icons";
|
|
3238
2465
|
import { Global, styled as styled6 } from "storybook/theming";
|
|
3239
2466
|
|
|
3240
2467
|
// src/components/ColorFilters.tsx
|
|
3241
|
-
import * as
|
|
3242
|
-
var Filters = /* @__PURE__ */ __name((props) =>
|
|
2468
|
+
import * as React7 from "react";
|
|
2469
|
+
var Filters = /* @__PURE__ */ __name((props) => React7.createElement("svg", { ...props }, React7.createElement("defs", null, React7.createElement("filter", { id: "protanopia" }, React7.createElement(
|
|
3243
2470
|
"feColorMatrix",
|
|
3244
2471
|
{
|
|
3245
2472
|
in: "SourceGraphic",
|
|
3246
2473
|
type: "matrix",
|
|
3247
2474
|
values: "0.567, 0.433, 0, 0, 0 0.558, 0.442, 0, 0, 0 0, 0.242, 0.758, 0, 0 0, 0, 0, 1, 0"
|
|
3248
2475
|
}
|
|
3249
|
-
)),
|
|
2476
|
+
)), React7.createElement("filter", { id: "protanomaly" }, React7.createElement(
|
|
3250
2477
|
"feColorMatrix",
|
|
3251
2478
|
{
|
|
3252
2479
|
in: "SourceGraphic",
|
|
3253
2480
|
type: "matrix",
|
|
3254
2481
|
values: "0.817, 0.183, 0, 0, 0 0.333, 0.667, 0, 0, 0 0, 0.125, 0.875, 0, 0 0, 0, 0, 1, 0"
|
|
3255
2482
|
}
|
|
3256
|
-
)),
|
|
2483
|
+
)), React7.createElement("filter", { id: "deuteranopia" }, React7.createElement(
|
|
3257
2484
|
"feColorMatrix",
|
|
3258
2485
|
{
|
|
3259
2486
|
in: "SourceGraphic",
|
|
3260
2487
|
type: "matrix",
|
|
3261
2488
|
values: "0.625, 0.375, 0, 0, 0 0.7, 0.3, 0, 0, 0 0, 0.3, 0.7, 0, 0 0, 0, 0, 1, 0"
|
|
3262
2489
|
}
|
|
3263
|
-
)),
|
|
2490
|
+
)), React7.createElement("filter", { id: "deuteranomaly" }, React7.createElement(
|
|
3264
2491
|
"feColorMatrix",
|
|
3265
2492
|
{
|
|
3266
2493
|
in: "SourceGraphic",
|
|
3267
2494
|
type: "matrix",
|
|
3268
2495
|
values: "0.8, 0.2, 0, 0, 0 0.258, 0.742, 0, 0, 0 0, 0.142, 0.858, 0, 0 0, 0, 0, 1, 0"
|
|
3269
2496
|
}
|
|
3270
|
-
)),
|
|
2497
|
+
)), React7.createElement("filter", { id: "tritanopia" }, React7.createElement(
|
|
3271
2498
|
"feColorMatrix",
|
|
3272
2499
|
{
|
|
3273
2500
|
in: "SourceGraphic",
|
|
3274
2501
|
type: "matrix",
|
|
3275
2502
|
values: "0.95, 0.05, 0, 0, 0 0, 0.433, 0.567, 0, 0 0, 0.475, 0.525, 0, 0 0, 0, 0, 1, 0"
|
|
3276
2503
|
}
|
|
3277
|
-
)),
|
|
2504
|
+
)), React7.createElement("filter", { id: "tritanomaly" }, React7.createElement(
|
|
3278
2505
|
"feColorMatrix",
|
|
3279
2506
|
{
|
|
3280
2507
|
in: "SourceGraphic",
|
|
3281
2508
|
type: "matrix",
|
|
3282
2509
|
values: "0.967, 0.033, 0, 0, 0 0, 0.733, 0.267, 0, 0 0, 0.183, 0.817, 0, 0 0, 0, 0, 1, 0"
|
|
3283
2510
|
}
|
|
3284
|
-
)),
|
|
2511
|
+
)), React7.createElement("filter", { id: "achromatopsia" }, React7.createElement(
|
|
3285
2512
|
"feColorMatrix",
|
|
3286
2513
|
{
|
|
3287
2514
|
in: "SourceGraphic",
|
|
@@ -3330,52 +2557,25 @@ var ColorIcon = styled6.span(
|
|
|
3330
2557
|
height: "1rem",
|
|
3331
2558
|
width: "1rem"
|
|
3332
2559
|
},
|
|
3333
|
-
({ filter }) => ({
|
|
3334
|
-
filter: getFilter(filter)
|
|
2560
|
+
({ $filter }) => ({
|
|
2561
|
+
filter: getFilter($filter)
|
|
3335
2562
|
}),
|
|
3336
2563
|
({ theme: theme2 }) => ({
|
|
3337
2564
|
boxShadow: `${theme2.appBorderColor} 0 0 0 1px inset`
|
|
3338
2565
|
})
|
|
3339
2566
|
);
|
|
3340
|
-
var
|
|
3341
|
-
|
|
3342
|
-
|
|
3343
|
-
}
|
|
3344
|
-
var Title2 = styled6.span({
|
|
3345
|
-
textTransform: "capitalize"
|
|
3346
|
-
});
|
|
3347
|
-
var Description2 = styled6.span(({ theme: theme2 }) => ({
|
|
3348
|
-
fontSize: 11,
|
|
3349
|
-
color: theme2.textMutedColor
|
|
3350
|
-
}));
|
|
3351
|
-
var getColorList = /* @__PURE__ */ __name((active, set) => [
|
|
3352
|
-
...active !== null ? [
|
|
3353
|
-
{
|
|
3354
|
-
id: "reset",
|
|
3355
|
-
title: "Reset color filter",
|
|
3356
|
-
onClick: /* @__PURE__ */ __name(() => {
|
|
3357
|
-
set(null);
|
|
3358
|
-
}, "onClick"),
|
|
3359
|
-
right: void 0,
|
|
3360
|
-
active: false
|
|
3361
|
-
}
|
|
3362
|
-
] : [],
|
|
3363
|
-
...baseList.map((i) => {
|
|
3364
|
-
const description = i.percentage !== void 0 ? `${i.percentage}% of users` : void 0;
|
|
2567
|
+
var VisionSimulator = /* @__PURE__ */ __name(() => {
|
|
2568
|
+
const [filter, setFilter] = useState4(null);
|
|
2569
|
+
const options = baseList.map(({ name, percentage }) => {
|
|
2570
|
+
const description = percentage !== void 0 ? `${percentage}% of users` : void 0;
|
|
3365
2571
|
return {
|
|
3366
|
-
|
|
3367
|
-
|
|
3368
|
-
|
|
3369
|
-
|
|
3370
|
-
}, "onClick"),
|
|
3371
|
-
right: React9.createElement(ColorIcon, { filter: i.name }),
|
|
3372
|
-
active: active === i
|
|
2572
|
+
title: name,
|
|
2573
|
+
description,
|
|
2574
|
+
icon: React8.createElement(ColorIcon, { $filter: name }),
|
|
2575
|
+
value: name
|
|
3373
2576
|
};
|
|
3374
|
-
})
|
|
3375
|
-
|
|
3376
|
-
var VisionSimulator = /* @__PURE__ */ __name(() => {
|
|
3377
|
-
const [filter, setFilter] = useState5(null);
|
|
3378
|
-
return React9.createElement(React9.Fragment, null, filter && React9.createElement(
|
|
2577
|
+
});
|
|
2578
|
+
return React8.createElement(React8.Fragment, null, filter && React8.createElement(
|
|
3379
2579
|
Global,
|
|
3380
2580
|
{
|
|
3381
2581
|
styles: {
|
|
@@ -3384,26 +2584,22 @@ var VisionSimulator = /* @__PURE__ */ __name(() => {
|
|
|
3384
2584
|
}
|
|
3385
2585
|
}
|
|
3386
2586
|
}
|
|
3387
|
-
),
|
|
3388
|
-
|
|
2587
|
+
), React8.createElement(
|
|
2588
|
+
Select,
|
|
3389
2589
|
{
|
|
3390
|
-
|
|
3391
|
-
|
|
3392
|
-
|
|
3393
|
-
|
|
3394
|
-
|
|
3395
|
-
|
|
3396
|
-
|
|
3397
|
-
|
|
3398
|
-
|
|
3399
|
-
onDoubleClick: () => setFilter(null)
|
|
3400
|
-
},
|
|
3401
|
-
React9.createElement(IconButton3, { key: "filter", active: !!filter, title: "Vision simulator" }, React9.createElement(AccessibilityIcon, null))
|
|
3402
|
-
), React9.createElement(Hidden, null, React9.createElement(Filters, null)));
|
|
2590
|
+
resetLabel: "Reset color filter",
|
|
2591
|
+
onReset: () => setFilter(null),
|
|
2592
|
+
icon: React8.createElement(AccessibilityIcon, null),
|
|
2593
|
+
ariaLabel: "Vision simulator",
|
|
2594
|
+
defaultOptions: filter?.name,
|
|
2595
|
+
options,
|
|
2596
|
+
onSelect: (selected) => setFilter(() => ({ name: selected }))
|
|
2597
|
+
}
|
|
2598
|
+
), React8.createElement(Hidden, null, React8.createElement(Filters, null)));
|
|
3403
2599
|
}, "VisionSimulator");
|
|
3404
2600
|
|
|
3405
2601
|
// src/manager.tsx
|
|
3406
|
-
var
|
|
2602
|
+
var Title2 = /* @__PURE__ */ __name(() => {
|
|
3407
2603
|
const api = useStorybookApi3();
|
|
3408
2604
|
const selectedPanel = api.getSelectedPanel();
|
|
3409
2605
|
const [{ results }] = useAddonState2(ADDON_ID, {
|
|
@@ -3418,20 +2614,20 @@ var Title3 = /* @__PURE__ */ __name(() => {
|
|
|
3418
2614
|
const violationsNb = results?.violations?.length ?? 0;
|
|
3419
2615
|
const incompleteNb = results?.incomplete?.length ?? 0;
|
|
3420
2616
|
const count = violationsNb + incompleteNb;
|
|
3421
|
-
const suffix = count === 0 ? null :
|
|
3422
|
-
return
|
|
2617
|
+
const suffix = count === 0 ? null : React9.createElement(Badge3, { compact: true, status: selectedPanel === PANEL_ID ? "active" : "neutral" }, count);
|
|
2618
|
+
return React9.createElement("div", { style: { display: "flex", alignItems: "center", gap: 6 } }, React9.createElement("span", null, "Accessibility"), suffix);
|
|
3423
2619
|
}, "Title");
|
|
3424
2620
|
addons.register(ADDON_ID, (api) => {
|
|
3425
2621
|
addons.add(PANEL_ID, {
|
|
3426
2622
|
title: "",
|
|
3427
2623
|
type: types.TOOL,
|
|
3428
2624
|
match: /* @__PURE__ */ __name(({ viewMode, tabId }) => viewMode === "story" && !tabId, "match"),
|
|
3429
|
-
render: /* @__PURE__ */ __name(() =>
|
|
2625
|
+
render: /* @__PURE__ */ __name(() => React9.createElement(VisionSimulator, null), "render")
|
|
3430
2626
|
});
|
|
3431
2627
|
addons.add(PANEL_ID, {
|
|
3432
|
-
title:
|
|
2628
|
+
title: Title2,
|
|
3433
2629
|
type: types.PANEL,
|
|
3434
|
-
render: /* @__PURE__ */ __name(({ active = true }) =>
|
|
2630
|
+
render: /* @__PURE__ */ __name(({ active = true }) => React9.createElement(A11yContextProvider, null, active ? React9.createElement(A11YPanel, null) : null), "render"),
|
|
3435
2631
|
paramKey: PARAM_KEY
|
|
3436
2632
|
});
|
|
3437
2633
|
});
|