@elliemae/ds-button-group 3.27.0-next.1 → 3.27.0-next.2

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/index.js CHANGED
@@ -29,10 +29,10 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
29
29
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
30
30
  var src_exports = {};
31
31
  __export(src_exports, {
32
- default: () => import_DSButtonGroup.default
32
+ default: () => import_ds_legacy_button_group.default
33
33
  });
34
34
  module.exports = __toCommonJS(src_exports);
35
35
  var React = __toESM(require("react"));
36
- __reExport(src_exports, require("./DSButtonGroup.js"), module.exports);
37
- var import_DSButtonGroup = __toESM(require("./DSButtonGroup.js"));
36
+ __reExport(src_exports, require("@elliemae/ds-legacy-button-group"), module.exports);
37
+ var import_ds_legacy_button_group = __toESM(require("@elliemae/ds-legacy-button-group"));
38
38
  //# sourceMappingURL=index.js.map
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../src/index.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
4
- "sourcesContent": ["export * from './DSButtonGroup.js';\nexport { default } from './DSButtonGroup.js';\n", "import * as React from 'react';\nexport { React };\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,wBAAc,+BAAd;AACA,2BAAwB;",
4
+ "sourcesContent": ["export * from '@elliemae/ds-legacy-button-group';\nexport { default } from '@elliemae/ds-legacy-button-group';\n", "import * as React from 'react';\nexport { React };\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,wBAAc,6CAAd;AACA,oCAAwB;",
6
6
  "names": []
7
7
  }
package/dist/esm/index.js CHANGED
@@ -1,6 +1,6 @@
1
1
  import * as React from "react";
2
- export * from "./DSButtonGroup.js";
3
- import { default as default2 } from "./DSButtonGroup.js";
2
+ export * from "@elliemae/ds-legacy-button-group";
3
+ import { default as default2 } from "@elliemae/ds-legacy-button-group";
4
4
  export {
5
5
  default2 as default
6
6
  };
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../src/index.tsx"],
4
- "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "export * from './DSButtonGroup.js';\nexport { default } from './DSButtonGroup.js';\n"],
4
+ "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "export * from '@elliemae/ds-legacy-button-group';\nexport { default } from '@elliemae/ds-legacy-button-group';\n"],
5
5
  "mappings": "AAAA,YAAY,WAAW;ACAvB,cAAc;AACd,SAAS,WAAAA,gBAAe;",
6
6
  "names": ["default"]
7
7
  }
@@ -1,2 +1,2 @@
1
- export * from './DSButtonGroup.js';
2
- export { default } from './DSButtonGroup.js';
1
+ export * from '@elliemae/ds-legacy-button-group';
2
+ export { default } from '@elliemae/ds-legacy-button-group';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@elliemae/ds-button-group",
3
- "version": "3.27.0-next.1",
3
+ "version": "3.27.0-next.2",
4
4
  "license": "MIT",
5
5
  "description": "ICE MT - Dimsum - Button Group",
6
6
  "files": [
@@ -13,14 +13,6 @@
13
13
  ".": {
14
14
  "import": "./dist/esm/index.js",
15
15
  "require": "./dist/cjs/index.js"
16
- },
17
- "./DSButtonGroup": {
18
- "import": "./dist/esm/DSButtonGroup.js",
19
- "require": "./dist/cjs/DSButtonGroup.js"
20
- },
21
- "./defaultProps": {
22
- "import": "./dist/esm/defaultProps.js",
23
- "require": "./dist/cjs/defaultProps.js"
24
16
  }
25
17
  },
26
18
  "sideEffects": [
@@ -43,14 +35,11 @@
43
35
  "indent": 4
44
36
  },
45
37
  "dependencies": {
46
- "@elliemae/ds-button": "3.27.0-next.1",
47
- "@elliemae/ds-classnames": "3.27.0-next.1",
48
- "@elliemae/ds-props-helpers": "3.27.0-next.1",
49
- "@elliemae/ds-shared": "3.27.0-next.1"
38
+ "@elliemae/ds-legacy-button-group": "1.0.1"
50
39
  },
51
40
  "devDependencies": {
52
41
  "@elliemae/pui-cli": "~9.0.0-next.31",
53
- "@elliemae/ds-monorepo-devops": "3.27.0-next.1"
42
+ "@elliemae/ds-monorepo-devops": "3.27.0-next.2"
54
43
  },
55
44
  "peerDependencies": {
56
45
  "react": "^17.0.2",
@@ -62,13 +51,13 @@
62
51
  },
63
52
  "scripts": {
64
53
  "dev": "cross-env NODE_ENV=development node ../../../scripts/build/build.mjs --watch",
65
- "test": "pui-cli test --passWithNoTests",
66
- "lint": "node ../../../scripts/lint.mjs",
54
+ "test": "exit 0 | echo",
55
+ "lint": "exit 0 | echo",
67
56
  "eslint:fix": "exit 0 | echo",
68
57
  "dts": "exit 0 | echo",
69
58
  "build": "cross-env NODE_ENV=production node ../../../scripts/build/build.mjs",
70
59
  "dev:build": "pnpm --filter {.}... build",
71
60
  "dev:install": "pnpm --filter {.}... i --no-lockfile && pnpm run dev:build",
72
- "checkDeps": "npm exec ../../util/ds-codemods -- check-missing-packages --projectFolderPath=\"./\" --ignorePackagesGlobPattern=\"\" --ignoreFilesGlobPattern=\"**/test-ables/*,**/tests/*\""
61
+ "checkDeps": "exit 0 | echo"
73
62
  }
74
63
  }
@@ -1,110 +0,0 @@
1
- "use strict";
2
- var __create = Object.create;
3
- var __defProp = Object.defineProperty;
4
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
5
- var __getOwnPropNames = Object.getOwnPropertyNames;
6
- var __getProtoOf = Object.getPrototypeOf;
7
- var __hasOwnProp = Object.prototype.hasOwnProperty;
8
- var __export = (target, all) => {
9
- for (var name in all)
10
- __defProp(target, name, { get: all[name], enumerable: true });
11
- };
12
- var __copyProps = (to, from, except, desc) => {
13
- if (from && typeof from === "object" || typeof from === "function") {
14
- for (let key of __getOwnPropNames(from))
15
- if (!__hasOwnProp.call(to, key) && key !== except)
16
- __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
17
- }
18
- return to;
19
- };
20
- var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
21
- // If the importer is in node compatibility mode or this is not an ESM
22
- // file that has been converted to a CommonJS file using a Babel-
23
- // compatible transform (i.e. "__esModule" has not been set), then set
24
- // "default" to the CommonJS "module.exports" for node compatibility.
25
- isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
26
- mod
27
- ));
28
- var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
29
- var DSButtonGroup_exports = {};
30
- __export(DSButtonGroup_exports, {
31
- DSButtonGroup: () => DSButtonGroup,
32
- DSButtonGroupWithSchema: () => DSButtonGroupWithSchema,
33
- default: () => DSButtonGroup_default
34
- });
35
- module.exports = __toCommonJS(DSButtonGroup_exports);
36
- var React = __toESM(require("react"));
37
- var import_jsx_runtime = require("react/jsx-runtime");
38
- var import_react = __toESM(require("react"));
39
- var import_ds_props_helpers = require("@elliemae/ds-props-helpers");
40
- var import_ds_classnames = require("@elliemae/ds-classnames");
41
- var import_ds_button = __toESM(require("@elliemae/ds-button"));
42
- var import_ds_shared = require("@elliemae/ds-shared");
43
- var import_defaultProps = require("./defaultProps.js");
44
- const blockName = "button-group";
45
- const GroupContainer = (0, import_ds_classnames.aggregatedClasses)("div")(blockName, null, ({ vertical, horizontal, spacing }) => ({
46
- vertical,
47
- horizontal,
48
- [spacing]: spacing
49
- }));
50
- const DSButtonGroup = ({ size, buttonType, orientation, spacing, children: buttons, containerProps }) => {
51
- (0, import_ds_props_helpers.useDeprecateComponent)({ componentName: "ds-button-group", version: "3.x" });
52
- return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
53
- GroupContainer,
54
- {
55
- classProps: {
56
- vertical: orientation === "vertical",
57
- horizontal: orientation !== "vertical",
58
- spacing
59
- },
60
- ...containerProps,
61
- children: import_react.default.Children.map(
62
- buttons,
63
- (button) => import_react.default.cloneElement(button, {
64
- buttonType,
65
- size,
66
- // Keeping it this way to allow individual Buttons to override group props
67
- // [buttonType | size]
68
- ...button.props
69
- }),
70
- null
71
- )
72
- }
73
- );
74
- };
75
- DSButtonGroup.defaultProps = {
76
- size: "m",
77
- buttonType: "secondary",
78
- orientation: "horizontal"
79
- };
80
- const props = {
81
- /** props injected to wrapper of page header */
82
- containerProps: import_ds_props_helpers.PropTypes.shape({}).description("props injected to wrapper of page header"),
83
- /**
84
- * ['s', 'm', 'l']
85
- */
86
- size: import_ds_props_helpers.PropTypes.oneOf(import_ds_shared.dsBasicSizes).description("['s', 'm', 'l']"),
87
- /**
88
- * ['primary', 'secondary', 'text', 'link']
89
- */
90
- buttonType: import_ds_props_helpers.PropTypes.oneOf(import_ds_button.buttonTypes).description("['primary', 'secondary', 'text', 'link']"),
91
- /**
92
- * ['horizontal', 'vertical']
93
- */
94
- orientation: import_ds_props_helpers.PropTypes.oneOf(import_ds_shared.orientation).description("['horizontal', 'vertical']"),
95
- /**
96
- * ['s', 'm', 'l']
97
- */
98
- spacing: import_ds_props_helpers.PropTypes.oneOf(import_ds_shared.dsBasicSizes).description("['s', 'm', 'l']"),
99
- /**
100
- * Button group items to show of type DSButton
101
- */
102
- children: import_ds_props_helpers.PropTypes.arrayOf(import_ds_props_helpers.PropTypes.oneOf([import_ds_button.default])).description("Button group items to show of type DSButton")
103
- };
104
- DSButtonGroup.defaultProps = import_defaultProps.defaultProps;
105
- DSButtonGroup.propTypes = props;
106
- DSButtonGroup.displayName = "DSButtonGroup";
107
- const DSButtonGroupWithSchema = (0, import_ds_props_helpers.describe)(DSButtonGroup);
108
- DSButtonGroupWithSchema.propTypes = props;
109
- var DSButtonGroup_default = DSButtonGroup;
110
- //# sourceMappingURL=DSButtonGroup.js.map
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../src/DSButtonGroup.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
4
- "sourcesContent": ["import React from 'react';\nimport { PropTypes, describe, useDeprecateComponent } from '@elliemae/ds-props-helpers';\nimport { aggregatedClasses } from '@elliemae/ds-classnames';\nimport DSButton, { buttonTypes } from '@elliemae/ds-button';\nimport { dsBasicSizes, orientation as buttonGroupOrientation } from '@elliemae/ds-shared';\nimport { defaultProps } from './defaultProps.js';\n\nconst blockName = 'button-group';\n\nconst GroupContainer = aggregatedClasses('div')(blockName, null, ({ vertical, horizontal, spacing }) => ({\n vertical,\n horizontal,\n [spacing]: spacing,\n}));\n\nconst DSButtonGroup = ({ size, buttonType, orientation, spacing, children: buttons, containerProps }) => {\n useDeprecateComponent({ componentName: 'ds-button-group', version: '3.x' });\n\n return (\n <GroupContainer\n classProps={{\n vertical: orientation === 'vertical',\n horizontal: orientation !== 'vertical',\n spacing,\n }}\n {...containerProps}\n >\n {React.Children.map(\n buttons,\n (button) =>\n React.cloneElement(button, {\n buttonType,\n size,\n // Keeping it this way to allow individual Buttons to override group props\n // [buttonType | size]\n ...button.props,\n }),\n null,\n )}\n </GroupContainer>\n );\n};\n\nDSButtonGroup.defaultProps = {\n size: 'm',\n buttonType: 'secondary',\n orientation: 'horizontal',\n};\n\nconst props = {\n /** props injected to wrapper of page header */\n containerProps: PropTypes.shape({}).description('props injected to wrapper of page header'),\n /**\n * ['s', 'm', 'l']\n */\n size: PropTypes.oneOf(dsBasicSizes).description(\"['s', 'm', 'l']\"),\n /**\n * ['primary', 'secondary', 'text', 'link']\n */\n buttonType: PropTypes.oneOf(buttonTypes).description(\"['primary', 'secondary', 'text', 'link']\"),\n /**\n * ['horizontal', 'vertical']\n */\n orientation: PropTypes.oneOf(buttonGroupOrientation).description(\"['horizontal', 'vertical']\"),\n /**\n * ['s', 'm', 'l']\n */\n spacing: PropTypes.oneOf(dsBasicSizes).description(\"['s', 'm', 'l']\"),\n /**\n * Button group items to show of type DSButton\n */\n children: PropTypes.arrayOf(PropTypes.oneOf([DSButton])).description('Button group items to show of type DSButton'),\n};\n\nDSButtonGroup.defaultProps = defaultProps;\nDSButtonGroup.propTypes = props;\nDSButtonGroup.displayName = 'DSButtonGroup';\n\nconst DSButtonGroupWithSchema = describe(DSButtonGroup);\n\nDSButtonGroupWithSchema.propTypes = props;\n\nexport { DSButtonGroup, DSButtonGroupWithSchema };\nexport default DSButtonGroup;\n", "import * as React from 'react';\nexport { React };\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADmBnB;AAnBJ,mBAAkB;AAClB,8BAA2D;AAC3D,2BAAkC;AAClC,uBAAsC;AACtC,uBAAoE;AACpE,0BAA6B;AAE7B,MAAM,YAAY;AAElB,MAAM,qBAAiB,wCAAkB,KAAK,EAAE,WAAW,MAAM,CAAC,EAAE,UAAU,YAAY,QAAQ,OAAO;AAAA,EACvG;AAAA,EACA;AAAA,EACA,CAAC,OAAO,GAAG;AACb,EAAE;AAEF,MAAM,gBAAgB,CAAC,EAAE,MAAM,YAAY,aAAa,SAAS,UAAU,SAAS,eAAe,MAAM;AACvG,qDAAsB,EAAE,eAAe,mBAAmB,SAAS,MAAM,CAAC;AAE1E,SACE;AAAA,IAAC;AAAA;AAAA,MACC,YAAY;AAAA,QACV,UAAU,gBAAgB;AAAA,QAC1B,YAAY,gBAAgB;AAAA,QAC5B;AAAA,MACF;AAAA,MACC,GAAG;AAAA,MAEH,uBAAAA,QAAM,SAAS;AAAA,QACd;AAAA,QACA,CAAC,WACC,aAAAA,QAAM,aAAa,QAAQ;AAAA,UACzB;AAAA,UACA;AAAA;AAAA;AAAA,UAGA,GAAG,OAAO;AAAA,QACZ,CAAC;AAAA,QACH;AAAA,MACF;AAAA;AAAA,EACF;AAEJ;AAEA,cAAc,eAAe;AAAA,EAC3B,MAAM;AAAA,EACN,YAAY;AAAA,EACZ,aAAa;AACf;AAEA,MAAM,QAAQ;AAAA;AAAA,EAEZ,gBAAgB,kCAAU,MAAM,CAAC,CAAC,EAAE,YAAY,0CAA0C;AAAA;AAAA;AAAA;AAAA,EAI1F,MAAM,kCAAU,MAAM,6BAAY,EAAE,YAAY,iBAAiB;AAAA;AAAA;AAAA;AAAA,EAIjE,YAAY,kCAAU,MAAM,4BAAW,EAAE,YAAY,0CAA0C;AAAA;AAAA;AAAA;AAAA,EAI/F,aAAa,kCAAU,MAAM,iBAAAC,WAAsB,EAAE,YAAY,4BAA4B;AAAA;AAAA;AAAA;AAAA,EAI7F,SAAS,kCAAU,MAAM,6BAAY,EAAE,YAAY,iBAAiB;AAAA;AAAA;AAAA;AAAA,EAIpE,UAAU,kCAAU,QAAQ,kCAAU,MAAM,CAAC,iBAAAC,OAAQ,CAAC,CAAC,EAAE,YAAY,6CAA6C;AACpH;AAEA,cAAc,eAAe;AAC7B,cAAc,YAAY;AAC1B,cAAc,cAAc;AAE5B,MAAM,8BAA0B,kCAAS,aAAa;AAEtD,wBAAwB,YAAY;AAGpC,IAAO,wBAAQ;",
6
- "names": ["React", "buttonGroupOrientation", "DSButton"]
7
- }
@@ -1,40 +0,0 @@
1
- "use strict";
2
- var __create = Object.create;
3
- var __defProp = Object.defineProperty;
4
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
5
- var __getOwnPropNames = Object.getOwnPropertyNames;
6
- var __getProtoOf = Object.getPrototypeOf;
7
- var __hasOwnProp = Object.prototype.hasOwnProperty;
8
- var __export = (target, all) => {
9
- for (var name in all)
10
- __defProp(target, name, { get: all[name], enumerable: true });
11
- };
12
- var __copyProps = (to, from, except, desc) => {
13
- if (from && typeof from === "object" || typeof from === "function") {
14
- for (let key of __getOwnPropNames(from))
15
- if (!__hasOwnProp.call(to, key) && key !== except)
16
- __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
17
- }
18
- return to;
19
- };
20
- var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
21
- // If the importer is in node compatibility mode or this is not an ESM
22
- // file that has been converted to a CommonJS file using a Babel-
23
- // compatible transform (i.e. "__esModule" has not been set), then set
24
- // "default" to the CommonJS "module.exports" for node compatibility.
25
- isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
26
- mod
27
- ));
28
- var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
29
- var defaultProps_exports = {};
30
- __export(defaultProps_exports, {
31
- defaultProps: () => defaultProps
32
- });
33
- module.exports = __toCommonJS(defaultProps_exports);
34
- var React = __toESM(require("react"));
35
- const defaultProps = {
36
- spacing: null,
37
- children: [],
38
- containerProps: {}
39
- };
40
- //# sourceMappingURL=defaultProps.js.map
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../src/defaultProps.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
4
- "sourcesContent": ["export const defaultProps = {\n spacing: null,\n children: [],\n containerProps: {},\n};\n", "import * as React from 'react';\nexport { React };\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAhB,MAAM,eAAe;AAAA,EAC1B,SAAS;AAAA,EACT,UAAU,CAAC;AAAA,EACX,gBAAgB,CAAC;AACnB;",
6
- "names": []
7
- }
@@ -1,80 +0,0 @@
1
- import * as React from "react";
2
- import { jsx } from "react/jsx-runtime";
3
- import React2 from "react";
4
- import { PropTypes, describe, useDeprecateComponent } from "@elliemae/ds-props-helpers";
5
- import { aggregatedClasses } from "@elliemae/ds-classnames";
6
- import DSButton, { buttonTypes } from "@elliemae/ds-button";
7
- import { dsBasicSizes, orientation as buttonGroupOrientation } from "@elliemae/ds-shared";
8
- import { defaultProps } from "./defaultProps.js";
9
- const blockName = "button-group";
10
- const GroupContainer = aggregatedClasses("div")(blockName, null, ({ vertical, horizontal, spacing }) => ({
11
- vertical,
12
- horizontal,
13
- [spacing]: spacing
14
- }));
15
- const DSButtonGroup = ({ size, buttonType, orientation, spacing, children: buttons, containerProps }) => {
16
- useDeprecateComponent({ componentName: "ds-button-group", version: "3.x" });
17
- return /* @__PURE__ */ jsx(
18
- GroupContainer,
19
- {
20
- classProps: {
21
- vertical: orientation === "vertical",
22
- horizontal: orientation !== "vertical",
23
- spacing
24
- },
25
- ...containerProps,
26
- children: React2.Children.map(
27
- buttons,
28
- (button) => React2.cloneElement(button, {
29
- buttonType,
30
- size,
31
- // Keeping it this way to allow individual Buttons to override group props
32
- // [buttonType | size]
33
- ...button.props
34
- }),
35
- null
36
- )
37
- }
38
- );
39
- };
40
- DSButtonGroup.defaultProps = {
41
- size: "m",
42
- buttonType: "secondary",
43
- orientation: "horizontal"
44
- };
45
- const props = {
46
- /** props injected to wrapper of page header */
47
- containerProps: PropTypes.shape({}).description("props injected to wrapper of page header"),
48
- /**
49
- * ['s', 'm', 'l']
50
- */
51
- size: PropTypes.oneOf(dsBasicSizes).description("['s', 'm', 'l']"),
52
- /**
53
- * ['primary', 'secondary', 'text', 'link']
54
- */
55
- buttonType: PropTypes.oneOf(buttonTypes).description("['primary', 'secondary', 'text', 'link']"),
56
- /**
57
- * ['horizontal', 'vertical']
58
- */
59
- orientation: PropTypes.oneOf(buttonGroupOrientation).description("['horizontal', 'vertical']"),
60
- /**
61
- * ['s', 'm', 'l']
62
- */
63
- spacing: PropTypes.oneOf(dsBasicSizes).description("['s', 'm', 'l']"),
64
- /**
65
- * Button group items to show of type DSButton
66
- */
67
- children: PropTypes.arrayOf(PropTypes.oneOf([DSButton])).description("Button group items to show of type DSButton")
68
- };
69
- DSButtonGroup.defaultProps = defaultProps;
70
- DSButtonGroup.propTypes = props;
71
- DSButtonGroup.displayName = "DSButtonGroup";
72
- const DSButtonGroupWithSchema = describe(DSButtonGroup);
73
- DSButtonGroupWithSchema.propTypes = props;
74
- var DSButtonGroup_default = DSButtonGroup;
75
- export {
76
- DSButtonGroup,
77
- DSButtonGroupWithSchema,
78
- DSButtonGroup_default as default
79
- };
80
- //# sourceMappingURL=DSButtonGroup.js.map
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../src/DSButtonGroup.tsx"],
4
- "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import React from 'react';\nimport { PropTypes, describe, useDeprecateComponent } from '@elliemae/ds-props-helpers';\nimport { aggregatedClasses } from '@elliemae/ds-classnames';\nimport DSButton, { buttonTypes } from '@elliemae/ds-button';\nimport { dsBasicSizes, orientation as buttonGroupOrientation } from '@elliemae/ds-shared';\nimport { defaultProps } from './defaultProps.js';\n\nconst blockName = 'button-group';\n\nconst GroupContainer = aggregatedClasses('div')(blockName, null, ({ vertical, horizontal, spacing }) => ({\n vertical,\n horizontal,\n [spacing]: spacing,\n}));\n\nconst DSButtonGroup = ({ size, buttonType, orientation, spacing, children: buttons, containerProps }) => {\n useDeprecateComponent({ componentName: 'ds-button-group', version: '3.x' });\n\n return (\n <GroupContainer\n classProps={{\n vertical: orientation === 'vertical',\n horizontal: orientation !== 'vertical',\n spacing,\n }}\n {...containerProps}\n >\n {React.Children.map(\n buttons,\n (button) =>\n React.cloneElement(button, {\n buttonType,\n size,\n // Keeping it this way to allow individual Buttons to override group props\n // [buttonType | size]\n ...button.props,\n }),\n null,\n )}\n </GroupContainer>\n );\n};\n\nDSButtonGroup.defaultProps = {\n size: 'm',\n buttonType: 'secondary',\n orientation: 'horizontal',\n};\n\nconst props = {\n /** props injected to wrapper of page header */\n containerProps: PropTypes.shape({}).description('props injected to wrapper of page header'),\n /**\n * ['s', 'm', 'l']\n */\n size: PropTypes.oneOf(dsBasicSizes).description(\"['s', 'm', 'l']\"),\n /**\n * ['primary', 'secondary', 'text', 'link']\n */\n buttonType: PropTypes.oneOf(buttonTypes).description(\"['primary', 'secondary', 'text', 'link']\"),\n /**\n * ['horizontal', 'vertical']\n */\n orientation: PropTypes.oneOf(buttonGroupOrientation).description(\"['horizontal', 'vertical']\"),\n /**\n * ['s', 'm', 'l']\n */\n spacing: PropTypes.oneOf(dsBasicSizes).description(\"['s', 'm', 'l']\"),\n /**\n * Button group items to show of type DSButton\n */\n children: PropTypes.arrayOf(PropTypes.oneOf([DSButton])).description('Button group items to show of type DSButton'),\n};\n\nDSButtonGroup.defaultProps = defaultProps;\nDSButtonGroup.propTypes = props;\nDSButtonGroup.displayName = 'DSButtonGroup';\n\nconst DSButtonGroupWithSchema = describe(DSButtonGroup);\n\nDSButtonGroupWithSchema.propTypes = props;\n\nexport { DSButtonGroup, DSButtonGroupWithSchema };\nexport default DSButtonGroup;\n"],
5
- "mappings": "AAAA,YAAY,WAAW;ACmBnB;AAnBJ,OAAOA,YAAW;AAClB,SAAS,WAAW,UAAU,6BAA6B;AAC3D,SAAS,yBAAyB;AAClC,OAAO,YAAY,mBAAmB;AACtC,SAAS,cAAc,eAAe,8BAA8B;AACpE,SAAS,oBAAoB;AAE7B,MAAM,YAAY;AAElB,MAAM,iBAAiB,kBAAkB,KAAK,EAAE,WAAW,MAAM,CAAC,EAAE,UAAU,YAAY,QAAQ,OAAO;AAAA,EACvG;AAAA,EACA;AAAA,EACA,CAAC,OAAO,GAAG;AACb,EAAE;AAEF,MAAM,gBAAgB,CAAC,EAAE,MAAM,YAAY,aAAa,SAAS,UAAU,SAAS,eAAe,MAAM;AACvG,wBAAsB,EAAE,eAAe,mBAAmB,SAAS,MAAM,CAAC;AAE1E,SACE;AAAA,IAAC;AAAA;AAAA,MACC,YAAY;AAAA,QACV,UAAU,gBAAgB;AAAA,QAC1B,YAAY,gBAAgB;AAAA,QAC5B;AAAA,MACF;AAAA,MACC,GAAG;AAAA,MAEH,UAAAA,OAAM,SAAS;AAAA,QACd;AAAA,QACA,CAAC,WACCA,OAAM,aAAa,QAAQ;AAAA,UACzB;AAAA,UACA;AAAA;AAAA;AAAA,UAGA,GAAG,OAAO;AAAA,QACZ,CAAC;AAAA,QACH;AAAA,MACF;AAAA;AAAA,EACF;AAEJ;AAEA,cAAc,eAAe;AAAA,EAC3B,MAAM;AAAA,EACN,YAAY;AAAA,EACZ,aAAa;AACf;AAEA,MAAM,QAAQ;AAAA;AAAA,EAEZ,gBAAgB,UAAU,MAAM,CAAC,CAAC,EAAE,YAAY,0CAA0C;AAAA;AAAA;AAAA;AAAA,EAI1F,MAAM,UAAU,MAAM,YAAY,EAAE,YAAY,iBAAiB;AAAA;AAAA;AAAA;AAAA,EAIjE,YAAY,UAAU,MAAM,WAAW,EAAE,YAAY,0CAA0C;AAAA;AAAA;AAAA;AAAA,EAI/F,aAAa,UAAU,MAAM,sBAAsB,EAAE,YAAY,4BAA4B;AAAA;AAAA;AAAA;AAAA,EAI7F,SAAS,UAAU,MAAM,YAAY,EAAE,YAAY,iBAAiB;AAAA;AAAA;AAAA;AAAA,EAIpE,UAAU,UAAU,QAAQ,UAAU,MAAM,CAAC,QAAQ,CAAC,CAAC,EAAE,YAAY,6CAA6C;AACpH;AAEA,cAAc,eAAe;AAC7B,cAAc,YAAY;AAC1B,cAAc,cAAc;AAE5B,MAAM,0BAA0B,SAAS,aAAa;AAEtD,wBAAwB,YAAY;AAGpC,IAAO,wBAAQ;",
6
- "names": ["React"]
7
- }
@@ -1,10 +0,0 @@
1
- import * as React from "react";
2
- const defaultProps = {
3
- spacing: null,
4
- children: [],
5
- containerProps: {}
6
- };
7
- export {
8
- defaultProps
9
- };
10
- //# sourceMappingURL=defaultProps.js.map
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../src/defaultProps.tsx"],
4
- "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "export const defaultProps = {\n spacing: null,\n children: [],\n containerProps: {},\n};\n"],
5
- "mappings": "AAAA,YAAY,WAAW;ACAhB,MAAM,eAAe;AAAA,EAC1B,SAAS;AAAA,EACT,UAAU,CAAC;AAAA,EACX,gBAAgB,CAAC;AACnB;",
6
- "names": []
7
- }
@@ -1,54 +0,0 @@
1
- declare const DSButtonGroup: {
2
- ({ size, buttonType, orientation, spacing, children: buttons, containerProps }: {
3
- size: any;
4
- buttonType: any;
5
- orientation: any;
6
- spacing: any;
7
- children: any;
8
- containerProps: any;
9
- }): import("react/jsx-runtime.js").JSX.Element;
10
- defaultProps: {
11
- spacing: null;
12
- children: never[];
13
- containerProps: {};
14
- } | {
15
- size: string;
16
- buttonType: string;
17
- orientation: string;
18
- };
19
- propTypes: {
20
- /** props injected to wrapper of page header */
21
- containerProps: import("@elliemae/ds-props-helpers/dist/types/propTypes/types.js").ReactDescT;
22
- /**
23
- * ['s', 'm', 'l']
24
- */
25
- size: import("@elliemae/ds-props-helpers/dist/types/propTypes/types.js").ReactDescT;
26
- /**
27
- * ['primary', 'secondary', 'text', 'link']
28
- */
29
- buttonType: import("@elliemae/ds-props-helpers/dist/types/propTypes/types.js").ReactDescT;
30
- /**
31
- * ['horizontal', 'vertical']
32
- */
33
- orientation: import("@elliemae/ds-props-helpers/dist/types/propTypes/types.js").ReactDescT;
34
- /**
35
- * ['s', 'm', 'l']
36
- */
37
- spacing: import("@elliemae/ds-props-helpers/dist/types/propTypes/types.js").ReactDescT;
38
- /**
39
- * Button group items to show of type DSButton
40
- */
41
- children: import("@elliemae/ds-props-helpers/dist/types/propTypes/types.js").ReactDescT;
42
- };
43
- displayName: string;
44
- };
45
- declare const DSButtonGroupWithSchema: import("@elliemae/ds-props-helpers/dist/types/propTypes/types.js").DocumentedReactComponent<{
46
- size: any;
47
- buttonType: any;
48
- orientation: any;
49
- spacing: any;
50
- children: any;
51
- containerProps: any;
52
- }>;
53
- export { DSButtonGroup, DSButtonGroupWithSchema };
54
- export default DSButtonGroup;
@@ -1,5 +0,0 @@
1
- export declare const defaultProps: {
2
- spacing: null;
3
- children: never[];
4
- containerProps: {};
5
- };
@@ -1 +0,0 @@
1
- export {};