@carbon/utilities-react 0.5.0 → 0.6.0-rc.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1,5 +1 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
3
|
-
Instead found: ${e.outerHTML}`)})}function s(r,t="interactive child node(s) should have an `aria-describedby` property"){__DEV__&&i(()=>{const e=r.current?n(r.current):!1;if(e&&!e.hasAttribute("aria-describedby"))throw new Error(`Error: ${t}.
|
|
4
|
-
|
|
5
|
-
Instead found: ${e.outerHTML}`)})}function n(r){if(!r||!r.childNodes)return null;if(u(r))return r;for(const t of r.childNodes){const e=n(t);if(e)return e}return null}function o(r){if(!r||!r.childNodes)return null;if(r?.getAttribute?.("role")&&r.getAttribute("role")!=="")return r;for(const t of r.childNodes){const e=o(t);if(e)return e}return null}function u(r){if(r.tabIndex===void 0||r.tabIndex<0||r.disabled)return!1;switch(r.nodeName){case"A":return!!r.href&&r.rel!=="ignore";case"INPUT":return r.type!=="hidden";default:return!0}}export{n as getInteractiveContent,o as getRoleContent,s as useInteractiveChildrenNeedDescription,d as useNoInteractiveChildren};
|
|
1
|
+
import"react";function u(e,t="component should have no interactive child nodes"){}function f(e,t="interactive child node(s) should have an `aria-describedby` property"){}function n(e){if(!e||!e.childNodes)return null;if(i(e))return e;for(const t of e.childNodes){const r=n(t);if(r)return r}return null}function o(e){if(!e||!e.childNodes)return null;if(e?.getAttribute?.("role")&&e.getAttribute("role")!=="")return e;for(const t of e.childNodes){const r=o(t);if(r)return r}return null}function i(e){if(e.tabIndex===void 0||e.tabIndex<0||e.disabled)return!1;switch(e.nodeName){case"A":return!!e.href&&e.rel!=="ignore";case"INPUT":return e.type!=="hidden";default:return!0}}export{n as getInteractiveContent,o as getRoleContent,f as useInteractiveChildrenNeedDescription,u as useNoInteractiveChildren};
|
|
@@ -1,5 +1 @@
|
|
|
1
|
-
"use strict";var o=Object.defineProperty;var
|
|
2
|
-
|
|
3
|
-
Instead found: ${t.outerHTML}`)})}function p(r,e="interactive child node(s) should have an `aria-describedby` property"){__DEV__&&(0,u.useEffect)(()=>{const t=r.current?i(r.current):!1;if(t&&!t.hasAttribute("aria-describedby"))throw new Error(`Error: ${e}.
|
|
4
|
-
|
|
5
|
-
Instead found: ${t.outerHTML}`)})}function i(r){if(!r||!r.childNodes)return null;if(v(r))return r;for(const e of r.childNodes){const t=i(e);if(t)return t}return null}function d(r){if(!r||!r.childNodes)return null;if(r?.getAttribute?.("role")&&r.getAttribute("role")!=="")return r;for(const e of r.childNodes){const t=d(e);if(t)return t}return null}function v(r){if(r.tabIndex===void 0||r.tabIndex<0||r.disabled)return!1;switch(r.nodeName){case"A":return!!r.href&&r.rel!=="ignore";case"INPUT":return r.type!=="hidden";default:return!0}}
|
|
1
|
+
"use strict";var o=Object.defineProperty;var u=Object.getOwnPropertyDescriptor;var f=Object.getOwnPropertyNames;var d=Object.prototype.hasOwnProperty;var a=(e,r)=>{for(var t in r)o(e,t,{get:r[t],enumerable:!0})},l=(e,r,t,i)=>{if(r&&typeof r=="object"||typeof r=="function")for(let n of f(r))!d.call(e,n)&&n!==t&&o(e,n,{get:()=>r[n],enumerable:!(i=u(r,n))||i.enumerable});return e};var h=e=>l(o({},"__esModule",{value:!0}),e);var b={};a(b,{getInteractiveContent:()=>s,getRoleContent:()=>c,useInteractiveChildrenNeedDescription:()=>p,useNoInteractiveChildren:()=>N});module.exports=h(b);var E=require("react");function N(e,r="component should have no interactive child nodes"){}function p(e,r="interactive child node(s) should have an `aria-describedby` property"){}function s(e){if(!e||!e.childNodes)return null;if(v(e))return e;for(const r of e.childNodes){const t=s(r);if(t)return t}return null}function c(e){if(!e||!e.childNodes)return null;if(e?.getAttribute?.("role")&&e.getAttribute("role")!=="")return e;for(const r of e.childNodes){const t=c(r);if(t)return t}return null}function v(e){if(e.tabIndex===void 0||e.tabIndex<0||e.disabled)return!1;switch(e.nodeName){case"A":return!!e.href&&e.rel!=="ignore";case"INPUT":return e.type!=="hidden";default:return!0}}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@carbon/utilities-react",
|
|
3
3
|
"description": "Utilities and helpers to drive consistency across software products using the Carbon Design System with React",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.6.0-rc.0",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"main": "lib/index.js",
|
|
7
7
|
"module": "es/index.js",
|
|
@@ -51,5 +51,5 @@
|
|
|
51
51
|
"@carbon/utilities": "^0.5.0",
|
|
52
52
|
"@ibm/telemetry-js": "^1.6.1"
|
|
53
53
|
},
|
|
54
|
-
"gitHead": "
|
|
54
|
+
"gitHead": "0d87b91846d3b2a877f9f385f4f4b16214388315"
|
|
55
55
|
}
|