@elliemae/ds-chip 3.17.0-next.9 → 3.17.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/cjs/DSChip.js
CHANGED
|
@@ -39,9 +39,10 @@ var import_useConfig = require("./config/useConfig.js");
|
|
|
39
39
|
var import_styles = require("./styles.js");
|
|
40
40
|
var import_constants = require("./constants.js");
|
|
41
41
|
var import_react_desc_prop_types = require("./react-desc-prop-types.js");
|
|
42
|
+
var import_lodash = require("lodash");
|
|
42
43
|
const DSChip = (props) => {
|
|
43
44
|
const { size, shape, selected, innerRef, icon: Icon, label, globalAttrs, xStyledAttrs } = (0, import_useConfig.useConfig)(props);
|
|
44
|
-
const {
|
|
45
|
+
const { disabled, className, ...restGlobals } = (0, import_lodash.omit)(globalAttrs, ["shape", "type"]);
|
|
45
46
|
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_styles.StyledWrapper, { buttonShape: shape, buttonSize: size, className, ...xStyledAttrs, children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
|
|
46
47
|
import_styles.StyledChip,
|
|
47
48
|
{
|
package/dist/cjs/DSChip.js.map
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/DSChip.tsx", "../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
-
"sourcesContent": ["import React from 'react';\nimport { describe } from '@elliemae/ds-props-helpers';\nimport { useConfig } from './config/useConfig.js';\nimport { StyledChip, StyledChipLabel, StyledWrapper, StyledRoundShape, StyledSpanWithEllipsis } from './styles.js';\nimport { CHIP_SHAPES } from './constants.js';\nimport type { DSChipT } from './react-desc-prop-types.js';\nimport { DSChipPropTypes } from './react-desc-prop-types.js';\n\nconst DSChip: React.ComponentType<DSChipT.Props> = (props) => {\n const { size, shape, selected, innerRef, icon: Icon, label, globalAttrs, xStyledAttrs } = useConfig(props);\n\n const {
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;
|
|
4
|
+
"sourcesContent": ["import React from 'react';\nimport { describe } from '@elliemae/ds-props-helpers';\nimport { useConfig } from './config/useConfig.js';\nimport { StyledChip, StyledChipLabel, StyledWrapper, StyledRoundShape, StyledSpanWithEllipsis } from './styles.js';\nimport { CHIP_SHAPES } from './constants.js';\nimport type { DSChipT } from './react-desc-prop-types.js';\nimport { DSChipPropTypes } from './react-desc-prop-types.js';\nimport { omit } from 'lodash';\n\nconst DSChip: React.ComponentType<DSChipT.Props> = (props) => {\n const { size, shape, selected, innerRef, icon: Icon, label, globalAttrs, xStyledAttrs } = useConfig(props);\n\n const { disabled, className, ...restGlobals } = omit(globalAttrs, ['shape', 'type']);\n\n return (\n <StyledWrapper buttonShape={shape} buttonSize={size} className={className} {...xStyledAttrs}>\n <StyledChip\n buttonShape={shape}\n aria-disabled={disabled}\n disabled={disabled}\n ref={innerRef}\n selected={selected}\n role=\"button\"\n {...restGlobals}\n >\n {shape === CHIP_SHAPES.ROUND ? (\n <StyledRoundShape disabled={disabled} size={size}>\n <Icon />\n </StyledRoundShape>\n ) : (\n <Icon />\n )}\n <StyledChipLabel size={size}>\n <StyledSpanWithEllipsis>{label}</StyledSpanWithEllipsis>\n </StyledChipLabel>\n </StyledChip>\n </StyledWrapper>\n );\n};\n\nDSChip.propTypes = DSChipPropTypes;\nDSChip.displayName = 'DSChip';\nconst DSChipWithSchema = describe(DSChip);\nDSChipWithSchema.propTypes = DSChipPropTypes;\n\nexport { DSChip, DSChipWithSchema };\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADgBjB;AAfN,8BAAyB;AACzB,uBAA0B;AAC1B,oBAAqG;AACrG,uBAA4B;AAE5B,mCAAgC;AAChC,oBAAqB;AAErB,MAAM,SAA6C,CAAC,UAAU;AAC5D,QAAM,EAAE,MAAM,OAAO,UAAU,UAAU,MAAM,MAAM,OAAO,aAAa,aAAa,QAAI,4BAAU,KAAK;AAEzG,QAAM,EAAE,UAAU,WAAW,GAAG,YAAY,QAAI,oBAAK,aAAa,CAAC,SAAS,MAAM,CAAC;AAEnF,SACE,4CAAC,+BAAc,aAAa,OAAO,YAAY,MAAM,WAAuB,GAAG,cAC7E;AAAA,IAAC;AAAA;AAAA,MACC,aAAa;AAAA,MACb,iBAAe;AAAA,MACf;AAAA,MACA,KAAK;AAAA,MACL;AAAA,MACA,MAAK;AAAA,MACJ,GAAG;AAAA,MAEH;AAAA,kBAAU,6BAAY,QACrB,4CAAC,kCAAiB,UAAoB,MACpC,sDAAC,QAAK,GACR,IAEA,4CAAC,QAAK;AAAA,QAER,4CAAC,iCAAgB,MACf,sDAAC,wCAAwB,iBAAM,GACjC;AAAA;AAAA;AAAA,EACF,GACF;AAEJ;AAEA,OAAO,YAAY;AACnB,OAAO,cAAc;AACrB,MAAM,uBAAmB,kCAAS,MAAM;AACxC,iBAAiB,YAAY;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
package/dist/esm/DSChip.js
CHANGED
|
@@ -5,9 +5,10 @@ import { useConfig } from "./config/useConfig.js";
|
|
|
5
5
|
import { StyledChip, StyledChipLabel, StyledWrapper, StyledRoundShape, StyledSpanWithEllipsis } from "./styles.js";
|
|
6
6
|
import { CHIP_SHAPES } from "./constants.js";
|
|
7
7
|
import { DSChipPropTypes } from "./react-desc-prop-types.js";
|
|
8
|
+
import { omit } from "lodash";
|
|
8
9
|
const DSChip = (props) => {
|
|
9
10
|
const { size, shape, selected, innerRef, icon: Icon, label, globalAttrs, xStyledAttrs } = useConfig(props);
|
|
10
|
-
const {
|
|
11
|
+
const { disabled, className, ...restGlobals } = omit(globalAttrs, ["shape", "type"]);
|
|
11
12
|
return /* @__PURE__ */ jsx(StyledWrapper, { buttonShape: shape, buttonSize: size, className, ...xStyledAttrs, children: /* @__PURE__ */ jsxs(
|
|
12
13
|
StyledChip,
|
|
13
14
|
{
|
package/dist/esm/DSChip.js.map
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../scripts/build/transpile/react-shim.js", "../../src/DSChip.tsx"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import React from 'react';\nimport { describe } from '@elliemae/ds-props-helpers';\nimport { useConfig } from './config/useConfig.js';\nimport { StyledChip, StyledChipLabel, StyledWrapper, StyledRoundShape, StyledSpanWithEllipsis } from './styles.js';\nimport { CHIP_SHAPES } from './constants.js';\nimport type { DSChipT } from './react-desc-prop-types.js';\nimport { DSChipPropTypes } from './react-desc-prop-types.js';\n\nconst DSChip: React.ComponentType<DSChipT.Props> = (props) => {\n const { size, shape, selected, innerRef, icon: Icon, label, globalAttrs, xStyledAttrs } = useConfig(props);\n\n const {
|
|
5
|
-
"mappings": "AAAA,YAAY,WAAW;
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import React from 'react';\nimport { describe } from '@elliemae/ds-props-helpers';\nimport { useConfig } from './config/useConfig.js';\nimport { StyledChip, StyledChipLabel, StyledWrapper, StyledRoundShape, StyledSpanWithEllipsis } from './styles.js';\nimport { CHIP_SHAPES } from './constants.js';\nimport type { DSChipT } from './react-desc-prop-types.js';\nimport { DSChipPropTypes } from './react-desc-prop-types.js';\nimport { omit } from 'lodash';\n\nconst DSChip: React.ComponentType<DSChipT.Props> = (props) => {\n const { size, shape, selected, innerRef, icon: Icon, label, globalAttrs, xStyledAttrs } = useConfig(props);\n\n const { disabled, className, ...restGlobals } = omit(globalAttrs, ['shape', 'type']);\n\n return (\n <StyledWrapper buttonShape={shape} buttonSize={size} className={className} {...xStyledAttrs}>\n <StyledChip\n buttonShape={shape}\n aria-disabled={disabled}\n disabled={disabled}\n ref={innerRef}\n selected={selected}\n role=\"button\"\n {...restGlobals}\n >\n {shape === CHIP_SHAPES.ROUND ? (\n <StyledRoundShape disabled={disabled} size={size}>\n <Icon />\n </StyledRoundShape>\n ) : (\n <Icon />\n )}\n <StyledChipLabel size={size}>\n <StyledSpanWithEllipsis>{label}</StyledSpanWithEllipsis>\n </StyledChipLabel>\n </StyledChip>\n </StyledWrapper>\n );\n};\n\nDSChip.propTypes = DSChipPropTypes;\nDSChip.displayName = 'DSChip';\nconst DSChipWithSchema = describe(DSChip);\nDSChipWithSchema.propTypes = DSChipPropTypes;\n\nexport { DSChip, DSChipWithSchema };\n"],
|
|
5
|
+
"mappings": "AAAA,YAAY,WAAW;ACgBjB,SAWM,KAXN;AAfN,SAAS,gBAAgB;AACzB,SAAS,iBAAiB;AAC1B,SAAS,YAAY,iBAAiB,eAAe,kBAAkB,8BAA8B;AACrG,SAAS,mBAAmB;AAE5B,SAAS,uBAAuB;AAChC,SAAS,YAAY;AAErB,MAAM,SAA6C,CAAC,UAAU;AAC5D,QAAM,EAAE,MAAM,OAAO,UAAU,UAAU,MAAM,MAAM,OAAO,aAAa,aAAa,IAAI,UAAU,KAAK;AAEzG,QAAM,EAAE,UAAU,WAAW,GAAG,YAAY,IAAI,KAAK,aAAa,CAAC,SAAS,MAAM,CAAC;AAEnF,SACE,oBAAC,iBAAc,aAAa,OAAO,YAAY,MAAM,WAAuB,GAAG,cAC7E;AAAA,IAAC;AAAA;AAAA,MACC,aAAa;AAAA,MACb,iBAAe;AAAA,MACf;AAAA,MACA,KAAK;AAAA,MACL;AAAA,MACA,MAAK;AAAA,MACJ,GAAG;AAAA,MAEH;AAAA,kBAAU,YAAY,QACrB,oBAAC,oBAAiB,UAAoB,MACpC,8BAAC,QAAK,GACR,IAEA,oBAAC,QAAK;AAAA,QAER,oBAAC,mBAAgB,MACf,8BAAC,0BAAwB,iBAAM,GACjC;AAAA;AAAA;AAAA,EACF,GACF;AAEJ;AAEA,OAAO,YAAY;AACnB,OAAO,cAAc;AACrB,MAAM,mBAAmB,SAAS,MAAM;AACxC,iBAAiB,YAAY;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@elliemae/ds-chip",
|
|
3
|
-
"version": "3.17.0
|
|
3
|
+
"version": "3.17.0",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"description": "ICE MT - Dimsum - Chip",
|
|
6
6
|
"files": [
|
|
@@ -63,17 +63,19 @@
|
|
|
63
63
|
"indent": 4
|
|
64
64
|
},
|
|
65
65
|
"dependencies": {
|
|
66
|
-
"@elliemae/ds-props-helpers": "3.17.0
|
|
67
|
-
"@elliemae/ds-
|
|
68
|
-
"@elliemae/ds-
|
|
66
|
+
"@elliemae/ds-props-helpers": "3.17.0",
|
|
67
|
+
"@elliemae/ds-utilities": "3.17.0",
|
|
68
|
+
"@elliemae/ds-system": "3.17.0"
|
|
69
69
|
},
|
|
70
70
|
"devDependencies": {
|
|
71
71
|
"@testing-library/jest-dom": "~5.16.5",
|
|
72
72
|
"@testing-library/react": "~12.1.3",
|
|
73
|
+
"jest-axe": "^7.0.1",
|
|
73
74
|
"styled-components": "~5.3.9",
|
|
74
|
-
"@elliemae/ds-icons": "3.17.0
|
|
75
|
+
"@elliemae/ds-icons": "3.17.0"
|
|
75
76
|
},
|
|
76
77
|
"peerDependencies": {
|
|
78
|
+
"lodash": "^4.17.21",
|
|
77
79
|
"react": "^17.0.2",
|
|
78
80
|
"react-dom": "^17.0.2",
|
|
79
81
|
"styled-components": "~5.3.6"
|