@elliemae/ds-toolbar 3.0.0-next.43 → 3.0.0-next.46
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.
|
@@ -62,18 +62,17 @@ var React = __toESM(require("react"));
|
|
|
62
62
|
var import_react = __toESM(require("react"));
|
|
63
63
|
var import_prop_types = __toESM(require("prop-types"));
|
|
64
64
|
var import_ds_shared = require("@elliemae/ds-shared");
|
|
65
|
-
var import_ds_button =
|
|
65
|
+
var import_ds_button = require("@elliemae/ds-button");
|
|
66
66
|
var import_ds_popper = require("@elliemae/ds-popper");
|
|
67
67
|
const ToolbarItem = (_a) => {
|
|
68
68
|
var _b = _a, { icon, labelText, menu = void 0 } = _b, otherProps = __objRest(_b, ["icon", "labelText", "menu"]);
|
|
69
69
|
const [ref, setRef] = (0, import_react.useState)(null);
|
|
70
70
|
(0, import_ds_shared.useFocusGroupWithState)(ref);
|
|
71
|
-
const btn = /* @__PURE__ */ import_react.default.createElement(import_ds_button.
|
|
72
|
-
buttonType: "
|
|
73
|
-
icon,
|
|
71
|
+
const btn = /* @__PURE__ */ import_react.default.createElement(import_ds_button.DSButtonV2, __spreadProps(__spreadValues({}, otherProps), {
|
|
72
|
+
buttonType: "icon",
|
|
74
73
|
innerRef: (r) => setRef(r),
|
|
75
74
|
labelText
|
|
76
|
-
}));
|
|
75
|
+
}), icon);
|
|
77
76
|
if (menu) {
|
|
78
77
|
return import_react.default.cloneElement(menu, __spreadProps(__spreadValues({}, menu.props), {
|
|
79
78
|
placement: import_ds_popper.PopperPositions.BOTTOM_END,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../src/deprecated/ToolbarItem.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
-
"sourcesContent": ["import React, { useState } from 'react';\nimport PropTypes from 'prop-types';\nimport { useFocusGroupWithState } from '@elliemae/ds-shared';\nimport
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,mBAAgC;AAChC,wBAAsB;AACtB,uBAAuC;AACvC,
|
|
4
|
+
"sourcesContent": ["import React, { useState } from 'react';\nimport PropTypes from 'prop-types';\nimport { useFocusGroupWithState } from '@elliemae/ds-shared';\nimport { DSButtonV2 } from '@elliemae/ds-button';\nimport { PopperPositions as Position } from '@elliemae/ds-popper';\n\nconst ToolbarItem = ({ icon, labelText, menu = undefined, ...otherProps }) => {\n const [ref, setRef] = useState(null);\n\n useFocusGroupWithState(ref);\n const btn = (\n <DSButtonV2 {...otherProps} buttonType=\"icon\" innerRef={(r) => setRef(r)} labelText={labelText}>\n {icon}\n </DSButtonV2>\n );\n if (menu) {\n return React.cloneElement(menu, {\n ...menu.props,\n placement: Position.BOTTOM_END,\n triggerComponent: btn,\n });\n }\n return btn;\n};\n\nToolbarItem.displayName = 'ToolbarItem';\n\nToolbarItem.propTypes = {\n icon: PropTypes.element,\n labelText: PropTypes.string,\n};\n\nexport default ToolbarItem;\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,mBAAgC;AAChC,wBAAsB;AACtB,uBAAuC;AACvC,uBAA2B;AAC3B,uBAA4C;AAE5C,MAAM,cAAc,CAAC,OAAyD;AAAzD,eAAE,QAAM,WAAW,OAAO,WAA1B,IAAwC,uBAAxC,IAAwC,CAAtC,QAAM,aAAW;AACtC,QAAM,CAAC,KAAK,UAAU,2BAAS,IAAI;AAEnC,+CAAuB,GAAG;AAC1B,QAAM,MACJ,mDAAC,8DAAe,aAAf;AAAA,IAA2B,YAAW;AAAA,IAAO,UAAU,CAAC,MAAM,OAAO,CAAC;AAAA,IAAG;AAAA,MACvE,IACH;AAEF,MAAI,MAAM;AACR,WAAO,qBAAM,aAAa,MAAM,iCAC3B,KAAK,QADsB;AAAA,MAE9B,WAAW,iCAAS;AAAA,MACpB,kBAAkB;AAAA,IACpB,EAAC;AAAA,EACH;AACA,SAAO;AACT;AAEA,YAAY,cAAc;AAE1B,YAAY,YAAY;AAAA,EACtB,MAAM,0BAAU;AAAA,EAChB,WAAW,0BAAU;AACvB;AAEA,IAAO,sBAAQ;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -33,18 +33,17 @@ import * as React from "react";
|
|
|
33
33
|
import React2, { useState } from "react";
|
|
34
34
|
import PropTypes from "prop-types";
|
|
35
35
|
import { useFocusGroupWithState } from "@elliemae/ds-shared";
|
|
36
|
-
import
|
|
36
|
+
import { DSButtonV2 } from "@elliemae/ds-button";
|
|
37
37
|
import { PopperPositions as Position } from "@elliemae/ds-popper";
|
|
38
38
|
const ToolbarItem = (_a) => {
|
|
39
39
|
var _b = _a, { icon, labelText, menu = void 0 } = _b, otherProps = __objRest(_b, ["icon", "labelText", "menu"]);
|
|
40
40
|
const [ref, setRef] = useState(null);
|
|
41
41
|
useFocusGroupWithState(ref);
|
|
42
|
-
const btn = /* @__PURE__ */ React2.createElement(
|
|
43
|
-
buttonType: "
|
|
44
|
-
icon,
|
|
42
|
+
const btn = /* @__PURE__ */ React2.createElement(DSButtonV2, __spreadProps(__spreadValues({}, otherProps), {
|
|
43
|
+
buttonType: "icon",
|
|
45
44
|
innerRef: (r) => setRef(r),
|
|
46
45
|
labelText
|
|
47
|
-
}));
|
|
46
|
+
}), icon);
|
|
48
47
|
if (menu) {
|
|
49
48
|
return React2.cloneElement(menu, __spreadProps(__spreadValues({}, menu.props), {
|
|
50
49
|
placement: Position.BOTTOM_END,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../../src/deprecated/ToolbarItem.tsx"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import React, { useState } from 'react';\nimport PropTypes from 'prop-types';\nimport { useFocusGroupWithState } from '@elliemae/ds-shared';\nimport
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;ACAA;AACA;AACA;AACA;AACA;AAEA,MAAM,cAAc,CAAC,OAAyD;AAAzD,eAAE,QAAM,WAAW,OAAO,WAA1B,IAAwC,uBAAxC,IAAwC,CAAtC,QAAM,aAAW;AACtC,QAAM,CAAC,KAAK,UAAU,SAAS,IAAI;AAEnC,yBAAuB,GAAG;AAC1B,QAAM,MACJ,qCAAC,
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import React, { useState } from 'react';\nimport PropTypes from 'prop-types';\nimport { useFocusGroupWithState } from '@elliemae/ds-shared';\nimport { DSButtonV2 } from '@elliemae/ds-button';\nimport { PopperPositions as Position } from '@elliemae/ds-popper';\n\nconst ToolbarItem = ({ icon, labelText, menu = undefined, ...otherProps }) => {\n const [ref, setRef] = useState(null);\n\n useFocusGroupWithState(ref);\n const btn = (\n <DSButtonV2 {...otherProps} buttonType=\"icon\" innerRef={(r) => setRef(r)} labelText={labelText}>\n {icon}\n </DSButtonV2>\n );\n if (menu) {\n return React.cloneElement(menu, {\n ...menu.props,\n placement: Position.BOTTOM_END,\n triggerComponent: btn,\n });\n }\n return btn;\n};\n\nToolbarItem.displayName = 'ToolbarItem';\n\nToolbarItem.propTypes = {\n icon: PropTypes.element,\n labelText: PropTypes.string,\n};\n\nexport default ToolbarItem;\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;ACAA;AACA;AACA;AACA;AACA;AAEA,MAAM,cAAc,CAAC,OAAyD;AAAzD,eAAE,QAAM,WAAW,OAAO,WAA1B,IAAwC,uBAAxC,IAAwC,CAAtC,QAAM,aAAW;AACtC,QAAM,CAAC,KAAK,UAAU,SAAS,IAAI;AAEnC,yBAAuB,GAAG;AAC1B,QAAM,MACJ,qCAAC,6CAAe,aAAf;AAAA,IAA2B,YAAW;AAAA,IAAO,UAAU,CAAC,MAAM,OAAO,CAAC;AAAA,IAAG;AAAA,MACvE,IACH;AAEF,MAAI,MAAM;AACR,WAAO,OAAM,aAAa,MAAM,iCAC3B,KAAK,QADsB;AAAA,MAE9B,WAAW,SAAS;AAAA,MACpB,kBAAkB;AAAA,IACpB,EAAC;AAAA,EACH;AACA,SAAO;AACT;AAEA,YAAY,cAAc;AAE1B,YAAY,YAAY;AAAA,EACtB,MAAM,UAAU;AAAA,EAChB,WAAW,UAAU;AACvB;AAEA,IAAO,sBAAQ;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@elliemae/ds-toolbar",
|
|
3
|
-
"version": "3.0.0-next.
|
|
3
|
+
"version": "3.0.0-next.46",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"description": "ICE MT - Dimsum - Toolbar",
|
|
6
6
|
"files": [
|
|
@@ -87,14 +87,14 @@
|
|
|
87
87
|
"indent": 4
|
|
88
88
|
},
|
|
89
89
|
"dependencies": {
|
|
90
|
-
"@elliemae/ds-button": "3.0.0-next.
|
|
90
|
+
"@elliemae/ds-button": "3.0.0-next.46",
|
|
91
91
|
"@elliemae/ds-classnames": "3.0.0-next.29",
|
|
92
|
-
"@elliemae/ds-grid": "3.0.0-next.
|
|
93
|
-
"@elliemae/ds-icons": "3.0.0-next.
|
|
92
|
+
"@elliemae/ds-grid": "3.0.0-next.46",
|
|
93
|
+
"@elliemae/ds-icons": "3.0.0-next.46",
|
|
94
94
|
"@elliemae/ds-popper": "3.0.0-next.29",
|
|
95
95
|
"@elliemae/ds-shared": "3.0.0-next.29",
|
|
96
96
|
"@elliemae/ds-system": "3.0.0-next.29",
|
|
97
|
-
"@elliemae/ds-utilities": "3.0.0-next.
|
|
97
|
+
"@elliemae/ds-utilities": "3.0.0-next.46",
|
|
98
98
|
"prop-types": "~15.8.1",
|
|
99
99
|
"react-desc": "~4.1.3",
|
|
100
100
|
"uid": "2.0.0"
|