@elliemae/ds-utilities 3.5.0-rc.7 → 3.5.1-next.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.
@@ -29,14 +29,16 @@ __export(getComponentFromProps_exports, {
29
29
  });
30
30
  module.exports = __toCommonJS(getComponentFromProps_exports);
31
31
  var React = __toESM(require("react"));
32
+ var import_jsx_runtime = require("react/jsx-runtime");
32
33
  var import_react = __toESM(require("react"));
33
34
  const getComponentFromProps = (Component, props, children = []) => {
34
35
  if (!Component)
35
36
  return null;
36
37
  const componentChildren = typeof Component !== "function" && Component.props ? Array.isArray(Component.props.children) ? Component.props.children : [Component.props.children] : null;
37
- return typeof Component === "function" ? /* @__PURE__ */ import_react.default.createElement(Component, {
38
- ...props
39
- }, children) : import_react.default.cloneElement(
38
+ return typeof Component === "function" ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Component, {
39
+ ...props,
40
+ children
41
+ }) : import_react.default.cloneElement(
40
42
  Component,
41
43
  {
42
44
  ...Component.props,
@@ -2,6 +2,6 @@
2
2
  "version": 3,
3
3
  "sources": ["../../src/getComponentFromProps.tsx", "../../../../scripts/build/transpile/react-shim.js"],
4
4
  "sourcesContent": ["/* eslint-disable no-nested-ternary, @typescript-eslint/ban-ts-comment */\n// @ts-nocheck\nimport React, { PropsWithChildren } from 'react';\n\nexport const getComponentFromProps = (\n Component: React.ReactElement<PropsWithChildren<unknown>> | React.ComponentType<unknown>,\n props: Record<string, unknown>,\n children = [],\n) => {\n if (!Component) return null;\n const componentChildren =\n typeof Component !== 'function' && Component.props\n ? Array.isArray(Component.props.children)\n ? Component.props.children\n : [Component.props.children]\n : null;\n return typeof Component === 'function' ? (\n <Component {...props}>{children}</Component>\n ) : (\n React.cloneElement(\n Component,\n {\n ...Component.props,\n ...props,\n },\n // eslint-disable-next-line @typescript-eslint/no-unsafe-assignment\n componentChildren ? [...componentChildren, ...children] : [...children],\n )\n );\n};\n\nexport default getComponentFromProps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GAAG,QAAQ;AAAA,EACxE;AAEJ;AAEA,IAAO,gCAAQ;",
6
6
  "names": ["React"]
7
7
  }
@@ -28,12 +28,14 @@ __export(TestComponent_exports, {
28
28
  });
29
29
  module.exports = __toCommonJS(TestComponent_exports);
30
30
  var React = __toESM(require("react"));
31
+ var import_jsx_runtime = require("react/jsx-runtime");
31
32
  var import_react = __toESM(require("react"));
32
33
  var import_globalProps = require("../../globalProps");
33
34
  const TestComponent = (props) => {
34
35
  const globalAttributes = (0, import_globalProps.useGetGlobalAttributes)(props);
35
- return /* @__PURE__ */ import_react.default.createElement("div", {
36
- ...globalAttributes
37
- }, "Some random div");
36
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
37
+ ...globalAttributes,
38
+ children: "Some random div"
39
+ });
38
40
  };
39
41
  //# sourceMappingURL=TestComponent.js.map
@@ -2,6 +2,6 @@
2
2
  "version": 3,
3
3
  "sources": ["../../../../../src/props-helpers/tests/globalProps/TestComponent.js", "../../../../../../../scripts/build/transpile/react-shim.js"],
4
4
  "sourcesContent": ["import React from 'react';\nimport { useGetGlobalAttributes } from '../../globalProps';\n\nexport const TestComponent = (props) => {\n const globalAttributes = useGetGlobalAttributes(props);\n\n return <div {...globalAttributes}>Some random div</div>;\n};\n", "import * as React from 'react';\nexport { React };\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,mBAAkB;AAClB,yBAAuC;AAEhC,MAAM,gBAAgB,CAAC,UAAU;AACtC,QAAM,uBAAmB,2CAAuB,KAAK;AAErD,SAAO,6BAAAA,QAAA,cAAC;AAAA,IAAK,GAAG;AAAA,KAAkB,iBAAe;AACnD;",
6
- "names": ["React"]
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB;AAAA,mBAAkB;AAClB,yBAAuC;AAEhC,MAAM,gBAAgB,CAAC,UAAU;AACtC,QAAM,uBAAmB,2CAAuB,KAAK;AAErD,SAAO,4CAAC;AAAA,IAAK,GAAG;AAAA,IAAkB;AAAA,GAAe;AACnD;",
6
+ "names": []
7
7
  }
@@ -28,14 +28,16 @@ __export(TestComponent_exports, {
28
28
  });
29
29
  module.exports = __toCommonJS(TestComponent_exports);
30
30
  var React = __toESM(require("react"));
31
+ var import_jsx_runtime = require("react/jsx-runtime");
31
32
  var import_react = __toESM(require("react"));
32
33
  var import_xstyledProps = require("../../xstyledProps");
33
34
  const TestComponent = (props) => {
34
35
  const xstyledProps = (0, import_xstyledProps.useGetXstyledProps)(props);
35
36
  props.signal(xstyledProps);
36
- return /* @__PURE__ */ import_react.default.createElement("div", {
37
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
37
38
  ...xstyledProps,
38
- "data-testid": "xstyled-div"
39
- }, "Some random div");
39
+ "data-testid": "xstyled-div",
40
+ children: "Some random div"
41
+ });
40
42
  };
41
43
  //# sourceMappingURL=TestComponent.js.map
@@ -2,6 +2,6 @@
2
2
  "version": 3,
3
3
  "sources": ["../../../../../src/props-helpers/tests/xstyledProps/TestComponent.js", "../../../../../../../scripts/build/transpile/react-shim.js"],
4
4
  "sourcesContent": ["/* eslint-disable react/prop-types */\nimport React from 'react';\nimport { useGetXstyledProps } from '../../xstyledProps';\n\nexport const TestComponent = (props) => {\n const xstyledProps = useGetXstyledProps(props);\n\n props.signal(xstyledProps);\n\n return (\n <div {...xstyledProps} data-testid=\"xstyled-div\">\n Some random div\n </div>\n );\n};\n", "import * as React from 'react';\nexport { React };\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADCvB,mBAAkB;AAClB,0BAAmC;AAE5B,MAAM,gBAAgB,CAAC,UAAU;AACtC,QAAM,mBAAe,wCAAmB,KAAK;AAE7C,QAAM,OAAO,YAAY;AAEzB,SACE,6BAAAA,QAAA,cAAC;AAAA,IAAK,GAAG;AAAA,IAAc,eAAY;AAAA,KAAc,iBAEjD;AAEJ;",
6
- "names": ["React"]
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB;AACA,mBAAkB;AAClB,0BAAmC;AAE5B,MAAM,gBAAgB,CAAC,UAAU;AACtC,QAAM,mBAAe,wCAAmB,KAAK;AAE7C,QAAM,OAAO,YAAY;AAEzB,SACE,4CAAC;AAAA,IAAK,GAAG;AAAA,IAAc,eAAY;AAAA,IAAc;AAAA,GAEjD;AAEJ;",
6
+ "names": []
7
7
  }
@@ -1,12 +1,14 @@
1
1
  import * as React from "react";
2
+ import { jsx } from "react/jsx-runtime";
2
3
  import React2 from "react";
3
4
  const getComponentFromProps = (Component, props, children = []) => {
4
5
  if (!Component)
5
6
  return null;
6
7
  const componentChildren = typeof Component !== "function" && Component.props ? Array.isArray(Component.props.children) ? Component.props.children : [Component.props.children] : null;
7
- return typeof Component === "function" ? /* @__PURE__ */ React2.createElement(Component, {
8
- ...props
9
- }, children) : React2.cloneElement(
8
+ return typeof Component === "function" ? /* @__PURE__ */ jsx(Component, {
9
+ ...props,
10
+ children
11
+ }) : React2.cloneElement(
10
12
  Component,
11
13
  {
12
14
  ...Component.props,
@@ -2,6 +2,6 @@
2
2
  "version": 3,
3
3
  "sources": ["../../../../scripts/build/transpile/react-shim.js", "../../src/getComponentFromProps.tsx"],
4
4
  "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable no-nested-ternary, @typescript-eslint/ban-ts-comment */\n// @ts-nocheck\nimport React, { PropsWithChildren } from 'react';\n\nexport const getComponentFromProps = (\n Component: React.ReactElement<PropsWithChildren<unknown>> | React.ComponentType<unknown>,\n props: Record<string, unknown>,\n children = [],\n) => {\n if (!Component) return null;\n const componentChildren =\n typeof Component !== 'function' && Component.props\n ? Array.isArray(Component.props.children)\n ? Component.props.children\n : [Component.props.children]\n : null;\n return typeof Component === 'function' ? (\n <Component {...props}>{children}</Component>\n ) : (\n React.cloneElement(\n Component,\n {\n ...Component.props,\n ...props,\n },\n // eslint-disable-next-line @typescript-eslint/no-unsafe-assignment\n componentChildren ? [...componentChildren, ...children] : [...children],\n )\n );\n};\n\nexport default getComponentFromProps;\n"],
5
- "mappings": "AAAA,YAAY,WAAW;ACEvB,OAAOA,YAAkC;AAElC,MAAM,wBAAwB,CACnC,WACA,OACA,WAAW,CAAC,MACT;AACH,MAAI,CAAC;AAAW,WAAO;AACvB,QAAM,oBACJ,OAAO,cAAc,cAAc,UAAU,QACzC,MAAM,QAAQ,UAAU,MAAM,QAAQ,IACpC,UAAU,MAAM,WAChB,CAAC,UAAU,MAAM,QAAQ,IAC3B;AACN,SAAO,OAAO,cAAc,aAC1B,gBAAAA,OAAA,cAAC;AAAA,IAAW,GAAG;AAAA,KAAQ,QAAS,IAEhCA,OAAM;AAAA,IACJ;AAAA,IACA;AAAA,MACE,GAAG,UAAU;AAAA,MACb,GAAG;AAAA,IACL;AAAA,IAEA,oBAAoB,CAAC,GAAG,mBAAmB,GAAG,QAAQ,IAAI,CAAC,GAAG,QAAQ;AAAA,EACxE;AAEJ;AAEA,IAAO,gCAAQ;",
5
+ "mappings": "AAAA,YAAY,WAAW;ACAvB;AAEA,OAAOA,YAAkC;AAElC,MAAM,wBAAwB,CACnC,WACA,OACA,WAAW,CAAC,MACT;AACH,MAAI,CAAC;AAAW,WAAO;AACvB,QAAM,oBACJ,OAAO,cAAc,cAAc,UAAU,QACzC,MAAM,QAAQ,UAAU,MAAM,QAAQ,IACpC,UAAU,MAAM,WAChB,CAAC,UAAU,MAAM,QAAQ,IAC3B;AACN,SAAO,OAAO,cAAc,aAC1B,oBAAC;AAAA,IAAW,GAAG;AAAA,IAAQ;AAAA,GAAS,IAEhCA,OAAM;AAAA,IACJ;AAAA,IACA;AAAA,MACE,GAAG,UAAU;AAAA,MACb,GAAG;AAAA,IACL;AAAA,IAEA,oBAAoB,CAAC,GAAG,mBAAmB,GAAG,QAAQ,IAAI,CAAC,GAAG,QAAQ;AAAA,EACxE;AAEJ;AAEA,IAAO,gCAAQ;",
6
6
  "names": ["React"]
7
7
  }
@@ -1,11 +1,13 @@
1
1
  import * as React from "react";
2
+ import { jsx } from "react/jsx-runtime";
2
3
  import React2 from "react";
3
4
  import { useGetGlobalAttributes } from "../../globalProps";
4
5
  const TestComponent = (props) => {
5
6
  const globalAttributes = useGetGlobalAttributes(props);
6
- return /* @__PURE__ */ React2.createElement("div", {
7
- ...globalAttributes
8
- }, "Some random div");
7
+ return /* @__PURE__ */ jsx("div", {
8
+ ...globalAttributes,
9
+ children: "Some random div"
10
+ });
9
11
  };
10
12
  export {
11
13
  TestComponent
@@ -2,6 +2,6 @@
2
2
  "version": 3,
3
3
  "sources": ["../../../../../../../scripts/build/transpile/react-shim.js", "../../../../../src/props-helpers/tests/globalProps/TestComponent.js"],
4
4
  "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import React from 'react';\nimport { useGetGlobalAttributes } from '../../globalProps';\n\nexport const TestComponent = (props) => {\n const globalAttributes = useGetGlobalAttributes(props);\n\n return <div {...globalAttributes}>Some random div</div>;\n};\n"],
5
- "mappings": "AAAA,YAAY,WAAW;ACAvB,OAAOA,YAAW;AAClB,SAAS,8BAA8B;AAEhC,MAAM,gBAAgB,CAAC,UAAU;AACtC,QAAM,mBAAmB,uBAAuB,KAAK;AAErD,SAAO,gBAAAA,OAAA,cAAC;AAAA,IAAK,GAAG;AAAA,KAAkB,iBAAe;AACnD;",
5
+ "mappings": "AAAA,YAAY,WAAW;ACAvB;AAAA,OAAOA,YAAW;AAClB,SAAS,8BAA8B;AAEhC,MAAM,gBAAgB,CAAC,UAAU;AACtC,QAAM,mBAAmB,uBAAuB,KAAK;AAErD,SAAO,oBAAC;AAAA,IAAK,GAAG;AAAA,IAAkB;AAAA,GAAe;AACnD;",
6
6
  "names": ["React"]
7
7
  }
@@ -1,13 +1,15 @@
1
1
  import * as React from "react";
2
+ import { jsx } from "react/jsx-runtime";
2
3
  import React2 from "react";
3
4
  import { useGetXstyledProps } from "../../xstyledProps";
4
5
  const TestComponent = (props) => {
5
6
  const xstyledProps = useGetXstyledProps(props);
6
7
  props.signal(xstyledProps);
7
- return /* @__PURE__ */ React2.createElement("div", {
8
+ return /* @__PURE__ */ jsx("div", {
8
9
  ...xstyledProps,
9
- "data-testid": "xstyled-div"
10
- }, "Some random div");
10
+ "data-testid": "xstyled-div",
11
+ children: "Some random div"
12
+ });
11
13
  };
12
14
  export {
13
15
  TestComponent
@@ -2,6 +2,6 @@
2
2
  "version": 3,
3
3
  "sources": ["../../../../../../../scripts/build/transpile/react-shim.js", "../../../../../src/props-helpers/tests/xstyledProps/TestComponent.js"],
4
4
  "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable react/prop-types */\nimport React from 'react';\nimport { useGetXstyledProps } from '../../xstyledProps';\n\nexport const TestComponent = (props) => {\n const xstyledProps = useGetXstyledProps(props);\n\n props.signal(xstyledProps);\n\n return (\n <div {...xstyledProps} data-testid=\"xstyled-div\">\n Some random div\n </div>\n );\n};\n"],
5
- "mappings": "AAAA,YAAY,WAAW;ACCvB,OAAOA,YAAW;AAClB,SAAS,0BAA0B;AAE5B,MAAM,gBAAgB,CAAC,UAAU;AACtC,QAAM,eAAe,mBAAmB,KAAK;AAE7C,QAAM,OAAO,YAAY;AAEzB,SACE,gBAAAA,OAAA,cAAC;AAAA,IAAK,GAAG;AAAA,IAAc,eAAY;AAAA,KAAc,iBAEjD;AAEJ;",
5
+ "mappings": "AAAA,YAAY,WAAW;ACAvB;AACA,OAAOA,YAAW;AAClB,SAAS,0BAA0B;AAE5B,MAAM,gBAAgB,CAAC,UAAU;AACtC,QAAM,eAAe,mBAAmB,KAAK;AAE7C,QAAM,OAAO,YAAY;AAEzB,SACE,oBAAC;AAAA,IAAK,GAAG;AAAA,IAAc,eAAY;AAAA,IAAc;AAAA,GAEjD;AAEJ;",
6
6
  "names": ["React"]
7
7
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@elliemae/ds-utilities",
3
- "version": "3.5.0-rc.7",
3
+ "version": "3.5.1-next.0",
4
4
  "license": "MIT",
5
5
  "description": "ICE MT - Dimsum - Utilities",
6
6
  "files": [
@@ -151,7 +151,7 @@
151
151
  "typeSafety": true
152
152
  },
153
153
  "dependencies": {
154
- "@elliemae/ds-system": "3.5.0-rc.7",
154
+ "@elliemae/ds-system": "3.5.1-next.0",
155
155
  "@elliemae/pui-theme": "~2.6.0",
156
156
  "fast-deep-equal": "~3.1.3",
157
157
  "hotkeys-js": "~3.9.3",