@storybook/addon-a11y 10.5.0-alpha.5 → 10.5.0-alpha.7
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/_browser-chunks/{chunk-ZXL7I4W4.js → chunk-P5J2FJ2Z.js} +2 -10
- package/dist/_browser-chunks/{matchers-5TDFFDYO.js → matchers-JIUQ3HVY.js} +5 -5
- package/dist/index.js +1 -1
- package/dist/manager.js +4 -2
- package/dist/postinstall.js +6 -6
- package/dist/preset.js +6 -6
- package/dist/preview.js +1 -1
- package/package.json +2 -2
|
@@ -146,15 +146,7 @@ var vitestMatchersExtended = !1, decorators = [withVisionSimulator], afterEach =
|
|
|
146
146
|
globals,
|
|
147
147
|
viewMode
|
|
148
148
|
}) => {
|
|
149
|
-
let a11yParameter = parameters2.a11y, a11yGlobals = globals.a11y, shouldRunEnvironmentIndependent = !!!globals.ghostStories && a11yParameter?.disable !== !0 && a11yParameter?.test !== "off" && a11yGlobals?.manual !== !0, getMode = () =>
|
|
150
|
-
switch (a11yParameter?.test) {
|
|
151
|
-
case "todo":
|
|
152
|
-
return "warning";
|
|
153
|
-
case "error":
|
|
154
|
-
default:
|
|
155
|
-
return "failed";
|
|
156
|
-
}
|
|
157
|
-
};
|
|
149
|
+
let a11yParameter = parameters2.a11y, a11yGlobals = globals.a11y, shouldRunEnvironmentIndependent = !!!globals.ghostStories && a11yParameter?.disable !== !0 && a11yParameter?.test !== "off" && a11yGlobals?.manual !== !0, getMode = () => a11yParameter?.test === "todo" ? "warning" : "failed";
|
|
158
150
|
if (shouldRunEnvironmentIndependent && viewMode === "story")
|
|
159
151
|
try {
|
|
160
152
|
let result = await run(a11yParameter, storyId);
|
|
@@ -167,7 +159,7 @@ var vitestMatchersExtended = !1, decorators = [withVisionSimulator], afterEach =
|
|
|
167
159
|
status: hasViolations ? getMode() : "passed"
|
|
168
160
|
}), getIsVitestStandaloneRun() && hasViolations && getMode() === "failed") {
|
|
169
161
|
if (!vitestMatchersExtended) {
|
|
170
|
-
let { toHaveNoViolations } = await import("./matchers-
|
|
162
|
+
let { toHaveNoViolations } = await import("./matchers-JIUQ3HVY.js");
|
|
171
163
|
expect.extend({ toHaveNoViolations }), vitestMatchersExtended = !0;
|
|
172
164
|
}
|
|
173
165
|
expect(result).toHaveNoViolations();
|
|
@@ -184,7 +184,7 @@ function stringEncaseCRLFWithFirstIndex(string, prefix, postfix, index) {
|
|
|
184
184
|
}
|
|
185
185
|
|
|
186
186
|
// ../../../node_modules/vitest-axe/node_modules/chalk/source/index.js
|
|
187
|
-
var { stdout: stdoutColor, stderr: stderrColor } = browser_default, GENERATOR = Symbol("GENERATOR"), STYLER = Symbol("STYLER"), IS_EMPTY = Symbol("IS_EMPTY"), levelMapping = [
|
|
187
|
+
var { stdout: stdoutColor, stderr: stderrColor } = browser_default, GENERATOR = /* @__PURE__ */ Symbol("GENERATOR"), STYLER = /* @__PURE__ */ Symbol("STYLER"), IS_EMPTY = /* @__PURE__ */ Symbol("IS_EMPTY"), levelMapping = [
|
|
188
188
|
"ansi",
|
|
189
189
|
"ansi",
|
|
190
190
|
"ansi256",
|
|
@@ -725,8 +725,8 @@ var __create = Object.create, __defProp = Object.defineProperty, __getOwnPropDes
|
|
|
725
725
|
}), require_react_is_production_min = __commonJS({
|
|
726
726
|
"node_modules/react-is/cjs/react-is.production.min.js"(exports) {
|
|
727
727
|
"use strict";
|
|
728
|
-
var b = Symbol.for("react.element"), c = Symbol.for("react.portal"), d = Symbol.for("react.fragment"), e = Symbol.for("react.strict_mode"), f = Symbol.for("react.profiler"), g = Symbol.for("react.provider"), h = Symbol.for("react.context"), k = Symbol.for("react.server_context"), l = Symbol.for("react.forward_ref"), m = Symbol.for("react.suspense"), n = Symbol.for("react.suspense_list"), p = Symbol.for("react.memo"), q = Symbol.for("react.lazy"), t = Symbol.for("react.offscreen"), u;
|
|
729
|
-
u = Symbol.for("react.module.reference");
|
|
728
|
+
var b = /* @__PURE__ */ Symbol.for("react.element"), c = /* @__PURE__ */ Symbol.for("react.portal"), d = /* @__PURE__ */ Symbol.for("react.fragment"), e = /* @__PURE__ */ Symbol.for("react.strict_mode"), f = /* @__PURE__ */ Symbol.for("react.profiler"), g = /* @__PURE__ */ Symbol.for("react.provider"), h = /* @__PURE__ */ Symbol.for("react.context"), k = /* @__PURE__ */ Symbol.for("react.server_context"), l = /* @__PURE__ */ Symbol.for("react.forward_ref"), m = /* @__PURE__ */ Symbol.for("react.suspense"), n = /* @__PURE__ */ Symbol.for("react.suspense_list"), p = /* @__PURE__ */ Symbol.for("react.memo"), q = /* @__PURE__ */ Symbol.for("react.lazy"), t = /* @__PURE__ */ Symbol.for("react.offscreen"), u;
|
|
729
|
+
u = /* @__PURE__ */ Symbol.for("react.module.reference");
|
|
730
730
|
function v(a) {
|
|
731
731
|
if (typeof a == "object" && a !== null) {
|
|
732
732
|
var r = a.$$typeof;
|
|
@@ -794,8 +794,8 @@ var __create = Object.create, __defProp = Object.defineProperty, __getOwnPropDes
|
|
|
794
794
|
"use strict";
|
|
795
795
|
process.env.NODE_ENV !== "production" && (function() {
|
|
796
796
|
"use strict";
|
|
797
|
-
var REACT_ELEMENT_TYPE = Symbol.for("react.element"), REACT_PORTAL_TYPE = Symbol.for("react.portal"), REACT_FRAGMENT_TYPE = Symbol.for("react.fragment"), REACT_STRICT_MODE_TYPE = Symbol.for("react.strict_mode"), REACT_PROFILER_TYPE = Symbol.for("react.profiler"), REACT_PROVIDER_TYPE = Symbol.for("react.provider"), REACT_CONTEXT_TYPE = Symbol.for("react.context"), REACT_SERVER_CONTEXT_TYPE = Symbol.for("react.server_context"), REACT_FORWARD_REF_TYPE = Symbol.for("react.forward_ref"), REACT_SUSPENSE_TYPE = Symbol.for("react.suspense"), REACT_SUSPENSE_LIST_TYPE = Symbol.for("react.suspense_list"), REACT_MEMO_TYPE = Symbol.for("react.memo"), REACT_LAZY_TYPE = Symbol.for("react.lazy"), REACT_OFFSCREEN_TYPE = Symbol.for("react.offscreen"), enableScopeAPI = !1, enableCacheElement = !1, enableTransitionTracing = !1, enableLegacyHidden = !1, enableDebugTracing = !1, REACT_MODULE_REFERENCE;
|
|
798
|
-
REACT_MODULE_REFERENCE = Symbol.for("react.module.reference");
|
|
797
|
+
var REACT_ELEMENT_TYPE = /* @__PURE__ */ Symbol.for("react.element"), REACT_PORTAL_TYPE = /* @__PURE__ */ Symbol.for("react.portal"), REACT_FRAGMENT_TYPE = /* @__PURE__ */ Symbol.for("react.fragment"), REACT_STRICT_MODE_TYPE = /* @__PURE__ */ Symbol.for("react.strict_mode"), REACT_PROFILER_TYPE = /* @__PURE__ */ Symbol.for("react.profiler"), REACT_PROVIDER_TYPE = /* @__PURE__ */ Symbol.for("react.provider"), REACT_CONTEXT_TYPE = /* @__PURE__ */ Symbol.for("react.context"), REACT_SERVER_CONTEXT_TYPE = /* @__PURE__ */ Symbol.for("react.server_context"), REACT_FORWARD_REF_TYPE = /* @__PURE__ */ Symbol.for("react.forward_ref"), REACT_SUSPENSE_TYPE = /* @__PURE__ */ Symbol.for("react.suspense"), REACT_SUSPENSE_LIST_TYPE = /* @__PURE__ */ Symbol.for("react.suspense_list"), REACT_MEMO_TYPE = /* @__PURE__ */ Symbol.for("react.memo"), REACT_LAZY_TYPE = /* @__PURE__ */ Symbol.for("react.lazy"), REACT_OFFSCREEN_TYPE = /* @__PURE__ */ Symbol.for("react.offscreen"), enableScopeAPI = !1, enableCacheElement = !1, enableTransitionTracing = !1, enableLegacyHidden = !1, enableDebugTracing = !1, REACT_MODULE_REFERENCE;
|
|
798
|
+
REACT_MODULE_REFERENCE = /* @__PURE__ */ Symbol.for("react.module.reference");
|
|
799
799
|
function isValidElementType(type) {
|
|
800
800
|
return !!(typeof type == "string" || typeof type == "function" || type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing || typeof type == "object" && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== void 0));
|
|
801
801
|
}
|
package/dist/index.js
CHANGED
package/dist/manager.js
CHANGED
|
@@ -1095,7 +1095,9 @@ function $e02a7d9cb1dc128c$export$c74125a8e3af6bb2(name) {
|
|
|
1095
1095
|
return $6vYhU$react.useEffect(() => (context.itemMap.set(ref, {
|
|
1096
1096
|
ref,
|
|
1097
1097
|
...itemData
|
|
1098
|
-
}), () =>
|
|
1098
|
+
}), () => {
|
|
1099
|
+
context.itemMap.delete(ref);
|
|
1100
|
+
})), $6vYhU$react.createElement($5e63c961fc1ce211$export$8c6ed5c666ac1360, {
|
|
1099
1101
|
[ITEM_DATA_ATTR]: "",
|
|
1100
1102
|
ref: composedRefs
|
|
1101
1103
|
}, children);
|
|
@@ -1225,7 +1227,7 @@ var $8927f6f2acc4f386$var$NODES = [
|
|
|
1225
1227
|
let Node = $4q5Fq$forwardRef((props, forwardedRef) => {
|
|
1226
1228
|
let { asChild, ...primitiveProps } = props, Comp = asChild ? $5e63c961fc1ce211$export$8c6ed5c666ac13602 : node;
|
|
1227
1229
|
return $4q5Fq$useEffect(() => {
|
|
1228
|
-
window[Symbol.for("radix-ui")] = !0;
|
|
1230
|
+
window[/* @__PURE__ */ Symbol.for("radix-ui")] = !0;
|
|
1229
1231
|
}, []), $4q5Fq$createElement(Comp, _extends({}, primitiveProps, {
|
|
1230
1232
|
ref: forwardedRef
|
|
1231
1233
|
}));
|
package/dist/postinstall.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_b7vc3au7c9 from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_b7vc3au7c9 from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_b7vc3au7c9 from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_b7vc3au7c9.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_b7vc3au7c9.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_b7vc3au7c9.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
package/dist/preset.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import CJS_COMPAT_NODE_URL_b7vc3au7c9 from 'node:url';
|
|
2
|
+
import CJS_COMPAT_NODE_PATH_b7vc3au7c9 from 'node:path';
|
|
3
|
+
import CJS_COMPAT_NODE_MODULE_b7vc3au7c9 from "node:module";
|
|
4
4
|
|
|
5
|
-
var __filename =
|
|
6
|
-
var __dirname =
|
|
7
|
-
var require =
|
|
5
|
+
var __filename = CJS_COMPAT_NODE_URL_b7vc3au7c9.fileURLToPath(import.meta.url);
|
|
6
|
+
var __dirname = CJS_COMPAT_NODE_PATH_b7vc3au7c9.dirname(__filename);
|
|
7
|
+
var require = CJS_COMPAT_NODE_MODULE_b7vc3au7c9.createRequire(import.meta.url);
|
|
8
8
|
|
|
9
9
|
// ------------------------------------------------------------
|
|
10
10
|
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
|
package/dist/preview.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@storybook/addon-a11y",
|
|
3
|
-
"version": "10.5.0-alpha.
|
|
3
|
+
"version": "10.5.0-alpha.7",
|
|
4
4
|
"description": "Storybook Addon A11y: Test UI component compliance with WCAG web accessibility standards",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"a11y",
|
|
@@ -73,7 +73,7 @@
|
|
|
73
73
|
"vitest-axe": "^0.1.0"
|
|
74
74
|
},
|
|
75
75
|
"peerDependencies": {
|
|
76
|
-
"storybook": "^10.5.0-alpha.
|
|
76
|
+
"storybook": "^10.5.0-alpha.7"
|
|
77
77
|
},
|
|
78
78
|
"publishConfig": {
|
|
79
79
|
"access": "public"
|