@react-spectrum/statuslight 3.3.1 → 3.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/main.js +3 -21
- package/dist/main.js.map +1 -1
- package/dist/module.js +0 -3
- package/dist/module.js.map +1 -1
- package/dist/types.d.ts +1 -0
- package/dist/types.d.ts.map +1 -1
- package/package.json +6 -6
- package/src/index.ts +2 -1
package/dist/main.js
CHANGED
|
@@ -4,31 +4,14 @@ var $cYKEG$reactariautils = require("@react-aria/utils");
|
|
|
4
4
|
var $cYKEG$react = require("react");
|
|
5
5
|
var $cYKEG$reactspectrumprovider = require("@react-spectrum/provider");
|
|
6
6
|
|
|
7
|
-
function $parcel$
|
|
8
|
-
Object.
|
|
9
|
-
if (key === 'default' || key === '__esModule' || dest.hasOwnProperty(key)) {
|
|
10
|
-
return;
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
Object.defineProperty(dest, key, {
|
|
14
|
-
enumerable: true,
|
|
15
|
-
get: function get() {
|
|
16
|
-
return source[key];
|
|
17
|
-
}
|
|
18
|
-
});
|
|
19
|
-
});
|
|
20
|
-
|
|
21
|
-
return dest;
|
|
7
|
+
function $parcel$export(e, n, v, s) {
|
|
8
|
+
Object.defineProperty(e, n, {get: v, set: s, enumerable: true, configurable: true});
|
|
22
9
|
}
|
|
23
10
|
function $parcel$interopDefault(a) {
|
|
24
11
|
return a && a.__esModule ? a.default : a;
|
|
25
12
|
}
|
|
26
|
-
function $parcel$export(e, n, v, s) {
|
|
27
|
-
Object.defineProperty(e, n, {get: v, set: s, enumerable: true, configurable: true});
|
|
28
|
-
}
|
|
29
|
-
var $ba01d1490c4da3ea$exports = {};
|
|
30
13
|
|
|
31
|
-
$parcel$export(
|
|
14
|
+
$parcel$export(module.exports, "StatusLight", () => $ba01d1490c4da3ea$export$5f84c37a31c6e41c);
|
|
32
15
|
|
|
33
16
|
|
|
34
17
|
|
|
@@ -109,7 +92,6 @@ function $ba01d1490c4da3ea$var$StatusLight(props, ref) {
|
|
|
109
92
|
*/ let $ba01d1490c4da3ea$export$5f84c37a31c6e41c = /*#__PURE__*/ $cYKEG$react.forwardRef($ba01d1490c4da3ea$var$StatusLight);
|
|
110
93
|
|
|
111
94
|
|
|
112
|
-
$parcel$exportWildcard(module.exports, $ba01d1490c4da3ea$exports);
|
|
113
95
|
|
|
114
96
|
|
|
115
97
|
//# sourceMappingURL=main.js.map
|
package/dist/main.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":"
|
|
1
|
+
{"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AEAA,GAAsC;AACtC,GAA+C;AAC/C,GAA6B;AAC7B,GAAgD;AAChD,GAA8C;AAC9C,GAAgD;AAChD,GAA4C;AAC5C,GAA8C;AAC9C,GAA8C;AAC9C,GAA8C;AAC9C,GAA+C;AAC/C,GAA8C;AAC9C,GAA+C;AAC/C,GAAkD;AAClD,GAA+C;AAC/C,GAA8C;AAf9C,yCAAsC,GAAG,CAA6B;AACtE,yCAA+C,GAAG,CAAsC;AACxF,yCAA6B,GAAG,CAAoB;AACpD,yCAAgD,GAAG,CAAuC;AAC1F,wCAA8C,GAAG,CAAqC;AACtF,yCAAgD,GAAG,CAAuC;AAC1F,yCAA4C,GAAG,CAAmC;AAClF,yCAA8C,GAAG,CAAqC;AACtF,yCAA8C,GAAG,CAAqC;AACtF,wCAA8C,GAAG,CAAqC;AACtF,yCAA+C,GAAG,CAAsC;AACxF,yCAA8C,GAAG,CAAqC;AACtF,yCAA+C,GAAG,CAAsC;AACxF,yCAAkD,GAAG,CAAyC;AAC9F,yCAA+C,GAAG,CAAsC;AACxF,yCAA8C,GAAG,CAAqC;;;;SDK7E,iCAAW,CAAC,KAA+B,EAAE,GAA2B,EAAE,CAAC;IAClF,GAAG,CAAC,CAAC,UACH,OAAO,aACP,QAAQ,eACR,UAAU,SACV,IAAI,MACD,UAAU,CACf,CAAC,GAAG,6CAAgB,CAAC,KAAK;IAC1B,GAAG,CAAC,MAAM,GAAG,mCAAS,CAAC,GAAG;IAC1B,GAAG,CAAC,CAAC,aAAA,UAAU,EAAA,CAAC,GAAG,uCAAa,CAAC,UAAU;IAE3C,EAAE,GAAG,QAAQ,KAAK,KAAK,CAAC,CAAY,cAClC,OAAO,CAAC,IAAI,CAAC,CAA8D;IAG7E,EAAE,GAAG,IAAI,KAAK,KAAK,CAAC,CAAY,gBAAK,KAAK,CAAC,CAAiB,oBAC1D,OAAO,CAAC,IAAI,CAAC,CAA0C;IAGzD,MAAM,oEACH,CAAG;WACE,oCAAc,CAAC,UAAU,EAAE,CAAC;YAAA,SAAS,IAAI,IAAI;QAAA,CAAC;WAC9C,UAAU;QACd,IAAI,EAAE,IAAI;QACV,SAAS,EAAE,oCAAU,CACnB,gEAAM,EACN,CAAsB,wBACrB,sBAAsB,EAAE,OAAO,IAChC,CAAC;YACC,CAAa,cAAE,UAAU;QAC3B,CAAC,EACD,UAAU,CAAC,SAAS;QAEtB,GAAG,EAAE,MAAM;OACV,QAAQ;AAGf,CAAC;AAED,EAGG,AAHH;;;CAGG,AAHH,EAGG,CACH,GAAG,CAAC,yCAAY,iBAAG,uBAAU,CAAC,iCAAW","sources":["packages/@react-spectrum/statuslight/src/index.ts","packages/@react-spectrum/statuslight/src/StatusLight.tsx","packages/@adobe/spectrum-css-temp/components/statuslight/vars.css"],"sourcesContent":["/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\n/// <reference types=\"css-module-types\" />\n\nexport {StatusLight} from './StatusLight';\nexport type {SpectrumStatusLightProps} from '@react-types/statuslight';\n","/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {classNames, useDOMRef, useStyleProps} from '@react-spectrum/utils';\nimport {DOMRef} from '@react-types/shared';\nimport {filterDOMProps} from '@react-aria/utils';\nimport React, {forwardRef} from 'react';\nimport {SpectrumStatusLightProps} from '@react-types/statuslight';\nimport styles from '@adobe/spectrum-css-temp/components/statuslight/vars.css';\nimport {useProviderProps} from '@react-spectrum/provider';\n\nfunction StatusLight(props: SpectrumStatusLightProps, ref: DOMRef<HTMLDivElement>) {\n let {\n variant,\n children,\n isDisabled,\n role,\n ...otherProps\n } = useProviderProps(props);\n let domRef = useDOMRef(ref);\n let {styleProps} = useStyleProps(otherProps);\n\n if (!children && !props['aria-label']) {\n console.warn('If no children are provided, an aria-label must be specified');\n }\n\n if (!role && (props['aria-label'] || props['aria-labelledby'])) {\n console.warn('A labelled StatusLight must have a role.');\n }\n\n return (\n <div\n {...filterDOMProps(otherProps, {labelable: !!role})}\n {...styleProps}\n role={role}\n className={classNames(\n styles,\n 'spectrum-StatusLight',\n `spectrum-StatusLight--${variant}`,\n {\n 'is-disabled': isDisabled\n },\n styleProps.className\n )}\n ref={domRef}>\n {children}\n </div>\n );\n}\n\n/**\n * Status lights are used to color code categories and labels commonly found in data visualization.\n * When status lights have a semantic meaning, they should use semantic variant colors.\n */\nlet _StatusLight = forwardRef(StatusLight);\nexport {_StatusLight as StatusLight};\n","/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\n@import './index.css';\n@import './skin.css';\n"],"names":[],"version":3,"file":"main.js.map"}
|
package/dist/module.js
CHANGED
|
@@ -10,9 +10,6 @@ function $parcel$interopDefault(a) {
|
|
|
10
10
|
function $parcel$export(e, n, v, s) {
|
|
11
11
|
Object.defineProperty(e, n, {get: v, set: s, enumerable: true, configurable: true});
|
|
12
12
|
}
|
|
13
|
-
var $df8f173c8bd4ebc0$exports = {};
|
|
14
|
-
|
|
15
|
-
$parcel$export($df8f173c8bd4ebc0$exports, "StatusLight", () => $df8f173c8bd4ebc0$export$5f84c37a31c6e41c);
|
|
16
13
|
|
|
17
14
|
|
|
18
15
|
|
package/dist/module.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":"
|
|
1
|
+
{"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AEAA,GAAsC;AACtC,GAA+C;AAC/C,GAA6B;AAC7B,GAAgD;AAChD,GAA8C;AAC9C,GAAgD;AAChD,GAA4C;AAC5C,GAA8C;AAC9C,GAA8C;AAC9C,GAA8C;AAC9C,GAA+C;AAC/C,GAA8C;AAC9C,GAA+C;AAC/C,GAAkD;AAClD,GAA+C;AAC/C,GAA8C;AAf9C,yCAAsC,GAAG,CAA6B;AACtE,yCAA+C,GAAG,CAAsC;AACxF,yCAA6B,GAAG,CAAoB;AACpD,yCAAgD,GAAG,CAAuC;AAC1F,wCAA8C,GAAG,CAAqC;AACtF,yCAAgD,GAAG,CAAuC;AAC1F,yCAA4C,GAAG,CAAmC;AAClF,yCAA8C,GAAG,CAAqC;AACtF,yCAA8C,GAAG,CAAqC;AACtF,wCAA8C,GAAG,CAAqC;AACtF,yCAA+C,GAAG,CAAsC;AACxF,yCAA8C,GAAG,CAAqC;AACtF,yCAA+C,GAAG,CAAsC;AACxF,yCAAkD,GAAG,CAAyC;AAC9F,yCAA+C,GAAG,CAAsC;AACxF,yCAA8C,GAAG,CAAqC;;;;SDK7E,iCAAW,CAAC,KAA+B,EAAE,GAA2B,EAAE,CAAC;IAClF,GAAG,CAAC,CAAC,UACH,OAAO,aACP,QAAQ,eACR,UAAU,SACV,IAAI,MACD,UAAU,CACf,CAAC,GAAG,uBAAgB,CAAC,KAAK;IAC1B,GAAG,CAAC,MAAM,GAAG,gBAAS,CAAC,GAAG;IAC1B,GAAG,CAAC,CAAC,aAAA,UAAU,EAAA,CAAC,GAAG,oBAAa,CAAC,UAAU;IAE3C,EAAE,GAAG,QAAQ,KAAK,KAAK,CAAC,CAAY,cAClC,OAAO,CAAC,IAAI,CAAC,CAA8D;IAG7E,EAAE,GAAG,IAAI,KAAK,KAAK,CAAC,CAAY,gBAAK,KAAK,CAAC,CAAiB,oBAC1D,OAAO,CAAC,IAAI,CAAC,CAA0C;IAGzD,MAAM,0CACH,CAAG;WACE,qBAAc,CAAC,UAAU,EAAE,CAAC;YAAA,SAAS,IAAI,IAAI;QAAA,CAAC;WAC9C,UAAU;QACd,IAAI,EAAE,IAAI;QACV,SAAS,EAAE,iBAAU,CACnB,gEAAM,EACN,CAAsB,wBACrB,sBAAsB,EAAE,OAAO,IAChC,CAAC;YACC,CAAa,cAAE,UAAU;QAC3B,CAAC,EACD,UAAU,CAAC,SAAS;QAEtB,GAAG,EAAE,MAAM;OACV,QAAQ;AAGf,CAAC;AAED,EAGG,AAHH;;;CAGG,AAHH,EAGG,CACH,GAAG,CAAC,yCAAY,iBAAG,iBAAU,CAAC,iCAAW","sources":["packages/@react-spectrum/statuslight/src/index.ts","packages/@react-spectrum/statuslight/src/StatusLight.tsx","packages/@adobe/spectrum-css-temp/components/statuslight/vars.css"],"sourcesContent":["/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\n/// <reference types=\"css-module-types\" />\n\nexport {StatusLight} from './StatusLight';\nexport type {SpectrumStatusLightProps} from '@react-types/statuslight';\n","/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {classNames, useDOMRef, useStyleProps} from '@react-spectrum/utils';\nimport {DOMRef} from '@react-types/shared';\nimport {filterDOMProps} from '@react-aria/utils';\nimport React, {forwardRef} from 'react';\nimport {SpectrumStatusLightProps} from '@react-types/statuslight';\nimport styles from '@adobe/spectrum-css-temp/components/statuslight/vars.css';\nimport {useProviderProps} from '@react-spectrum/provider';\n\nfunction StatusLight(props: SpectrumStatusLightProps, ref: DOMRef<HTMLDivElement>) {\n let {\n variant,\n children,\n isDisabled,\n role,\n ...otherProps\n } = useProviderProps(props);\n let domRef = useDOMRef(ref);\n let {styleProps} = useStyleProps(otherProps);\n\n if (!children && !props['aria-label']) {\n console.warn('If no children are provided, an aria-label must be specified');\n }\n\n if (!role && (props['aria-label'] || props['aria-labelledby'])) {\n console.warn('A labelled StatusLight must have a role.');\n }\n\n return (\n <div\n {...filterDOMProps(otherProps, {labelable: !!role})}\n {...styleProps}\n role={role}\n className={classNames(\n styles,\n 'spectrum-StatusLight',\n `spectrum-StatusLight--${variant}`,\n {\n 'is-disabled': isDisabled\n },\n styleProps.className\n )}\n ref={domRef}>\n {children}\n </div>\n );\n}\n\n/**\n * Status lights are used to color code categories and labels commonly found in data visualization.\n * When status lights have a semantic meaning, they should use semantic variant colors.\n */\nlet _StatusLight = forwardRef(StatusLight);\nexport {_StatusLight as StatusLight};\n","/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\n@import './index.css';\n@import './skin.css';\n"],"names":[],"version":3,"file":"module.js.map"}
|
package/dist/types.d.ts
CHANGED
|
@@ -5,5 +5,6 @@ import { SpectrumStatusLightProps } from "@react-types/statuslight";
|
|
|
5
5
|
* When status lights have a semantic meaning, they should use semantic variant colors.
|
|
6
6
|
*/
|
|
7
7
|
export let StatusLight: React.ForwardRefExoticComponent<SpectrumStatusLightProps & React.RefAttributes<import("@react-types/shared").DOMRefValue<HTMLDivElement>>>;
|
|
8
|
+
export type { SpectrumStatusLightProps } from '@react-types/statuslight';
|
|
8
9
|
|
|
9
10
|
//# sourceMappingURL=types.d.ts.map
|
package/dist/types.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":";;AA2DA;;;GAGG;AACH,OAAA,IAAI,uJAAsC,CAAC","sources":["packages/@react-spectrum/statuslight/src/packages/@react-spectrum/statuslight/src/StatusLight.tsx","packages/@react-spectrum/statuslight/src/packages/@react-spectrum/statuslight/src/index.ts","packages/@react-spectrum/statuslight/src/index.ts"],"sourcesContent":[null,null,"/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\n/// <reference types=\"css-module-types\" />\n\nexport
|
|
1
|
+
{"mappings":";;AA2DA;;;GAGG;AACH,OAAA,IAAI,uJAAsC,CAAC;AChD3C,YAAY,EAAC,wBAAwB,EAAC,MAAM,0BAA0B,CAAC","sources":["packages/@react-spectrum/statuslight/src/packages/@react-spectrum/statuslight/src/StatusLight.tsx","packages/@react-spectrum/statuslight/src/packages/@react-spectrum/statuslight/src/index.ts","packages/@react-spectrum/statuslight/src/index.ts"],"sourcesContent":[null,null,"/*\n * Copyright 2020 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\n/// <reference types=\"css-module-types\" />\n\nexport {StatusLight} from './StatusLight';\nexport type {SpectrumStatusLightProps} from '@react-types/statuslight';\n"],"names":[],"version":3,"file":"types.d.ts.map"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@react-spectrum/statuslight",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.4.0",
|
|
4
4
|
"description": "Spectrum UI components in React",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"main": "dist/main.js",
|
|
@@ -32,10 +32,10 @@
|
|
|
32
32
|
},
|
|
33
33
|
"dependencies": {
|
|
34
34
|
"@babel/runtime": "^7.6.2",
|
|
35
|
-
"@react-aria/utils": "^3.13.
|
|
36
|
-
"@react-spectrum/utils": "^3.7.
|
|
37
|
-
"@react-types/shared": "^3.
|
|
38
|
-
"@react-types/statuslight": "^3.2.
|
|
35
|
+
"@react-aria/utils": "^3.13.2",
|
|
36
|
+
"@react-spectrum/utils": "^3.7.2",
|
|
37
|
+
"@react-types/shared": "^3.14.0",
|
|
38
|
+
"@react-types/statuslight": "^3.2.2"
|
|
39
39
|
},
|
|
40
40
|
"devDependencies": {
|
|
41
41
|
"@adobe/spectrum-css-temp": "3.0.0-alpha.1"
|
|
@@ -47,5 +47,5 @@
|
|
|
47
47
|
"publishConfig": {
|
|
48
48
|
"access": "public"
|
|
49
49
|
},
|
|
50
|
-
"gitHead": "
|
|
50
|
+
"gitHead": "cd7c0ec917122c7612f653c22f8ed558f8b66ecd"
|
|
51
51
|
}
|
package/src/index.ts
CHANGED