@elliemae/ds-side-panel-header 3.22.0-next.22 → 3.22.0-next.24

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.
@@ -36,7 +36,6 @@ var React = __toESM(require("react"));
36
36
  var import_jsx_runtime = require("react/jsx-runtime");
37
37
  var import_react = require("react");
38
38
  var import_ds_props_helpers = require("@elliemae/ds-props-helpers");
39
- var import_ds_system = require("@elliemae/ds-system");
40
39
  var import_lodash = require("lodash");
41
40
  var import_ds_icons = require("@elliemae/ds-icons");
42
41
  var import_ds_grid = require("@elliemae/ds-grid");
@@ -44,53 +43,42 @@ var import_react_desc_prop_types = require("./react-desc-prop-types.js");
44
43
  var import_styled = require("./styled.js");
45
44
  const SidePanelHeader = (props) => {
46
45
  const propsWithDefaults = (0, import_ds_props_helpers.useMemoMergePropsWithDefault)(props, import_react_desc_prop_types.defaultProps);
46
+ const globalAttributes = (0, import_lodash.omit)((0, import_ds_props_helpers.useGetGlobalAttributes)(propsWithDefaults), "cols", "wrap", "rows");
47
+ const xStyledProps = (0, import_ds_props_helpers.useGetXstyledProps)(propsWithDefaults);
47
48
  const getOwnerProps = (0, import_react.useCallback)(() => propsWithDefaults, [propsWithDefaults]);
48
49
  const getOwnerPropsArguments = (0, import_react.useCallback)(() => ({}), []);
49
50
  const { title, additionalAction, onClose = import_lodash.noop, showClose = true, closeButtonRef = void 0 } = propsWithDefaults;
50
- const theme = (0, import_ds_system.useTheme)();
51
51
  const separator = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_ds_grid.Grid, { height: "24px", children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_styled.StyledSeparator, { getOwnerProps, getOwnerPropsArguments }) });
52
52
  const cols = ["1fr", "auto", "auto"];
53
- const cols2 = ["auto"];
54
- return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
55
- import_styled.Wrapper,
56
- {
57
- cols,
58
- height: theme.space.m,
59
- pl: theme.space.xs,
60
- pr: theme.space.xs,
61
- alignItems: "center",
62
- width: "100%",
63
- children: [
64
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_ds_grid.Grid, { alignItems: "center", justifyContent: "flex-start", cols: cols2, pr: theme.space.xs, children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
65
- import_styled.StyledTitle,
66
- {
67
- maxWidth: "100%",
68
- alignItems: "center",
69
- getOwnerProps,
70
- getOwnerPropsArguments,
71
- children: title
72
- }
73
- ) }),
74
- /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_ds_grid.Grid, { ml: "xxs", alignItems: "center", cols: additionalAction ? ["auto", "auto", "auto"] : ["auto"], children: [
75
- additionalAction && /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_ds_grid.Grid, { children: additionalAction }),
76
- additionalAction && showClose && separator,
77
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_ds_grid.Grid, { children: showClose && /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
78
- import_styled.StyledCloseButton,
79
- {
80
- buttonType: "icon",
81
- innerRef: closeButtonRef,
82
- size: "m",
83
- onClick: onClose,
84
- "data-testid": "btn-close-slide-panel",
85
- getOwnerProps,
86
- getOwnerPropsArguments,
87
- children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_ds_icons.CloseSmall, {})
88
- }
89
- ) })
90
- ] })
91
- ]
92
- }
93
- );
53
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_styled.Wrapper, { cols, alignItems: "center", width: "100%", ...globalAttributes, ...xStyledProps, children: [
54
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
55
+ import_styled.StyledTitle,
56
+ {
57
+ maxWidth: "100%",
58
+ alignItems: "center",
59
+ getOwnerProps,
60
+ getOwnerPropsArguments,
61
+ children: title
62
+ }
63
+ ),
64
+ /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_ds_grid.Grid, { ml: "xxs", alignItems: "center", cols: additionalAction ? ["auto", "auto", "auto"] : ["auto"], children: [
65
+ additionalAction && /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_ds_grid.Grid, { children: additionalAction }),
66
+ additionalAction && showClose && separator,
67
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_ds_grid.Grid, { children: showClose && /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
68
+ import_styled.StyledCloseButton,
69
+ {
70
+ buttonType: "icon",
71
+ innerRef: closeButtonRef,
72
+ size: "m",
73
+ onClick: onClose,
74
+ "data-testid": "btn-close-slide-panel",
75
+ getOwnerProps,
76
+ getOwnerPropsArguments,
77
+ children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_ds_icons.CloseSmall, {})
78
+ }
79
+ ) })
80
+ ] })
81
+ ] });
94
82
  };
95
83
  SidePanelHeader.propTypes = import_react_desc_prop_types.propTypes;
96
84
  SidePanelHeader.displayName = "SidePanelHeader";
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../src/SidePanelHeader.tsx", "../../../../scripts/build/transpile/react-shim.js"],
4
- "sourcesContent": ["import React, { useCallback } from 'react';\nimport { describe, useMemoMergePropsWithDefault } from '@elliemae/ds-props-helpers';\nimport { useTheme } from '@elliemae/ds-system';\nimport { noop } from 'lodash';\nimport { CloseSmall } from '@elliemae/ds-icons';\nimport { Grid } from '@elliemae/ds-grid';\nimport { type DSSidePanelHeaderT, defaultProps, propTypes } from './react-desc-prop-types.js';\n\nimport { StyledSeparator, StyledTitle, Wrapper, StyledCloseButton } from './styled.js';\nconst SidePanelHeader = (props: DSSidePanelHeaderT.Props) => {\n const propsWithDefaults = useMemoMergePropsWithDefault<DSSidePanelHeaderT.InternalProps>(props, defaultProps);\n\n const getOwnerProps = useCallback(() => propsWithDefaults, [propsWithDefaults]);\n const getOwnerPropsArguments = useCallback(() => ({}), []);\n const { title, additionalAction, onClose = noop, showClose = true, closeButtonRef = undefined } = propsWithDefaults;\n const theme = useTheme();\n const separator = (\n <Grid height=\"24px\">\n <StyledSeparator getOwnerProps={getOwnerProps} getOwnerPropsArguments={getOwnerPropsArguments} />\n </Grid>\n );\n const cols = ['1fr', 'auto', 'auto'];\n const cols2 = ['auto'];\n return (\n <Wrapper\n cols={cols}\n height={theme.space.m}\n pl={theme.space.xs}\n pr={theme.space.xs}\n alignItems=\"center\"\n width=\"100%\"\n >\n <Grid alignItems=\"center\" justifyContent=\"flex-start\" cols={cols2} pr={theme.space.xs}>\n <StyledTitle\n maxWidth=\"100%\"\n alignItems=\"center\"\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n {title}\n </StyledTitle>\n </Grid>\n <Grid ml=\"xxs\" alignItems=\"center\" cols={additionalAction ? ['auto', 'auto', 'auto'] : ['auto']}>\n {additionalAction && <Grid>{additionalAction}</Grid>}\n {additionalAction && showClose && separator}\n <Grid>\n {showClose && (\n <StyledCloseButton\n buttonType=\"icon\"\n innerRef={closeButtonRef}\n size=\"m\"\n onClick={onClose}\n data-testid=\"btn-close-slide-panel\"\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <CloseSmall />\n </StyledCloseButton>\n )}\n </Grid>\n </Grid>\n </Wrapper>\n );\n};\n\nSidePanelHeader.propTypes = propTypes;\nSidePanelHeader.displayName = 'SidePanelHeader';\nconst DSSidePanelHeaderWithSchema = describe(SidePanelHeader);\n\nDSSidePanelHeaderWithSchema.propTypes = propTypes;\n\nexport { SidePanelHeader, DSSidePanelHeaderWithSchema };\n", "import * as React from 'react';\nexport { React };\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADkBjB;AAlBN,mBAAmC;AACnC,8BAAuD;AACvD,uBAAyB;AACzB,oBAAqB;AACrB,sBAA2B;AAC3B,qBAAqB;AACrB,mCAAiE;AAEjE,oBAAyE;AACzE,MAAM,kBAAkB,CAAC,UAAoC;AAC3D,QAAM,wBAAoB,sDAA+D,OAAO,yCAAY;AAE5G,QAAM,oBAAgB,0BAAY,MAAM,mBAAmB,CAAC,iBAAiB,CAAC;AAC9E,QAAM,6BAAyB,0BAAY,OAAO,CAAC,IAAI,CAAC,CAAC;AACzD,QAAM,EAAE,OAAO,kBAAkB,UAAU,oBAAM,YAAY,MAAM,iBAAiB,OAAU,IAAI;AAClG,QAAM,YAAQ,2BAAS;AACvB,QAAM,YACJ,4CAAC,uBAAK,QAAO,QACX,sDAAC,iCAAgB,eAA8B,wBAAgD,GACjG;AAEF,QAAM,OAAO,CAAC,OAAO,QAAQ,MAAM;AACnC,QAAM,QAAQ,CAAC,MAAM;AACrB,SACE;AAAA,IAAC;AAAA;AAAA,MACC;AAAA,MACA,QAAQ,MAAM,MAAM;AAAA,MACpB,IAAI,MAAM,MAAM;AAAA,MAChB,IAAI,MAAM,MAAM;AAAA,MAChB,YAAW;AAAA,MACX,OAAM;AAAA,MAEN;AAAA,oDAAC,uBAAK,YAAW,UAAS,gBAAe,cAAa,MAAM,OAAO,IAAI,MAAM,MAAM,IACjF;AAAA,UAAC;AAAA;AAAA,YACC,UAAS;AAAA,YACT,YAAW;AAAA,YACX;AAAA,YACA;AAAA,YAEC;AAAA;AAAA,QACH,GACF;AAAA,QACA,6CAAC,uBAAK,IAAG,OAAM,YAAW,UAAS,MAAM,mBAAmB,CAAC,QAAQ,QAAQ,MAAM,IAAI,CAAC,MAAM,GAC3F;AAAA,8BAAoB,4CAAC,uBAAM,4BAAiB;AAAA,UAC5C,oBAAoB,aAAa;AAAA,UAClC,4CAAC,uBACE,uBACC;AAAA,YAAC;AAAA;AAAA,cACC,YAAW;AAAA,cACX,UAAU;AAAA,cACV,MAAK;AAAA,cACL,SAAS;AAAA,cACT,eAAY;AAAA,cACZ;AAAA,cACA;AAAA,cAEA,sDAAC,8BAAW;AAAA;AAAA,UACd,GAEJ;AAAA,WACF;AAAA;AAAA;AAAA,EACF;AAEJ;AAEA,gBAAgB,YAAY;AAC5B,gBAAgB,cAAc;AAC9B,MAAM,kCAA8B,kCAAS,eAAe;AAE5D,4BAA4B,YAAY;",
4
+ "sourcesContent": ["import React, { useCallback } from 'react';\nimport {\n describe,\n useMemoMergePropsWithDefault,\n useGetGlobalAttributes,\n useGetXstyledProps,\n} from '@elliemae/ds-props-helpers';\nimport { noop, omit } from 'lodash';\nimport { CloseSmall } from '@elliemae/ds-icons';\nimport { Grid } from '@elliemae/ds-grid';\nimport { type DSSidePanelHeaderT, defaultProps, propTypes } from './react-desc-prop-types.js';\n\nimport { StyledSeparator, StyledTitle, Wrapper, StyledCloseButton } from './styled.js';\nconst SidePanelHeader = (props: DSSidePanelHeaderT.Props) => {\n const propsWithDefaults = useMemoMergePropsWithDefault<DSSidePanelHeaderT.InternalProps>(props, defaultProps);\n\n const globalAttributes = omit(useGetGlobalAttributes(propsWithDefaults), 'cols', 'wrap', 'rows');\n const xStyledProps = useGetXstyledProps(propsWithDefaults);\n\n const getOwnerProps = useCallback(() => propsWithDefaults, [propsWithDefaults]);\n const getOwnerPropsArguments = useCallback(() => ({}), []);\n const { title, additionalAction, onClose = noop, showClose = true, closeButtonRef = undefined } = propsWithDefaults;\n const separator = (\n <Grid height=\"24px\">\n <StyledSeparator getOwnerProps={getOwnerProps} getOwnerPropsArguments={getOwnerPropsArguments} />\n </Grid>\n );\n const cols = ['1fr', 'auto', 'auto'];\n return (\n <Wrapper cols={cols} alignItems=\"center\" width=\"100%\" {...globalAttributes} {...xStyledProps}>\n <StyledTitle\n maxWidth=\"100%\"\n alignItems=\"center\"\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n {title}\n </StyledTitle>\n <Grid ml=\"xxs\" alignItems=\"center\" cols={additionalAction ? ['auto', 'auto', 'auto'] : ['auto']}>\n {additionalAction && <Grid>{additionalAction}</Grid>}\n {additionalAction && showClose && separator}\n <Grid>\n {showClose && (\n <StyledCloseButton\n buttonType=\"icon\"\n innerRef={closeButtonRef}\n size=\"m\"\n onClick={onClose}\n data-testid=\"btn-close-slide-panel\"\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <CloseSmall />\n </StyledCloseButton>\n )}\n </Grid>\n </Grid>\n </Wrapper>\n );\n};\n\nSidePanelHeader.propTypes = propTypes;\nSidePanelHeader.displayName = 'SidePanelHeader';\nconst DSSidePanelHeaderWithSchema = describe(SidePanelHeader);\n\nDSSidePanelHeaderWithSchema.propTypes = propTypes;\n\nexport { SidePanelHeader, DSSidePanelHeaderWithSchema };\n", "import * as React from 'react';\nexport { React };\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADwBjB;AAxBN,mBAAmC;AACnC,8BAKO;AACP,oBAA2B;AAC3B,sBAA2B;AAC3B,qBAAqB;AACrB,mCAAiE;AAEjE,oBAAyE;AACzE,MAAM,kBAAkB,CAAC,UAAoC;AAC3D,QAAM,wBAAoB,sDAA+D,OAAO,yCAAY;AAE5G,QAAM,uBAAmB,wBAAK,gDAAuB,iBAAiB,GAAG,QAAQ,QAAQ,MAAM;AAC/F,QAAM,mBAAe,4CAAmB,iBAAiB;AAEzD,QAAM,oBAAgB,0BAAY,MAAM,mBAAmB,CAAC,iBAAiB,CAAC;AAC9E,QAAM,6BAAyB,0BAAY,OAAO,CAAC,IAAI,CAAC,CAAC;AACzD,QAAM,EAAE,OAAO,kBAAkB,UAAU,oBAAM,YAAY,MAAM,iBAAiB,OAAU,IAAI;AAClG,QAAM,YACJ,4CAAC,uBAAK,QAAO,QACX,sDAAC,iCAAgB,eAA8B,wBAAgD,GACjG;AAEF,QAAM,OAAO,CAAC,OAAO,QAAQ,MAAM;AACnC,SACE,6CAAC,yBAAQ,MAAY,YAAW,UAAS,OAAM,QAAQ,GAAG,kBAAmB,GAAG,cAC9E;AAAA;AAAA,MAAC;AAAA;AAAA,QACC,UAAS;AAAA,QACT,YAAW;AAAA,QACX;AAAA,QACA;AAAA,QAEC;AAAA;AAAA,IACH;AAAA,IACA,6CAAC,uBAAK,IAAG,OAAM,YAAW,UAAS,MAAM,mBAAmB,CAAC,QAAQ,QAAQ,MAAM,IAAI,CAAC,MAAM,GAC3F;AAAA,0BAAoB,4CAAC,uBAAM,4BAAiB;AAAA,MAC5C,oBAAoB,aAAa;AAAA,MAClC,4CAAC,uBACE,uBACC;AAAA,QAAC;AAAA;AAAA,UACC,YAAW;AAAA,UACX,UAAU;AAAA,UACV,MAAK;AAAA,UACL,SAAS;AAAA,UACT,eAAY;AAAA,UACZ;AAAA,UACA;AAAA,UAEA,sDAAC,8BAAW;AAAA;AAAA,MACd,GAEJ;AAAA,OACF;AAAA,KACF;AAEJ;AAEA,gBAAgB,YAAY;AAC5B,gBAAgB,cAAc;AAC9B,MAAM,kCAA8B,kCAAS,eAAe;AAE5D,4BAA4B,YAAY;",
6
6
  "names": []
7
7
  }
@@ -39,6 +39,7 @@ const DSSidePanelHeaderName = "DSSidePanelHeader";
39
39
  const DSSidePanelHeaderSlots = {
40
40
  CLOSE_BUTTON: "close-button",
41
41
  TITLE: "title",
42
+ WRAPPER: "wrapper",
42
43
  SEPARATOR: "separator"
43
44
  };
44
45
  const DSSidePanelHeaderDataTestIds = {
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../src/SidePanelHeaderDefinitions.ts", "../../../../scripts/build/transpile/react-shim.js"],
4
- "sourcesContent": ["import { slotObjectToDataTestIds } from '@elliemae/ds-system';\n\nexport const DSSidePanelHeaderName = 'DSSidePanelHeader' as const;\nexport const DSSidePanelHeaderSlots = {\n CLOSE_BUTTON: 'close-button',\n TITLE: 'title',\n SEPARATOR: 'separator',\n};\n\nexport const DSSidePanelHeaderDataTestIds = {\n ...slotObjectToDataTestIds(DSSidePanelHeaderName, DSSidePanelHeaderSlots),\n CLOSE_BUTTON: 'btn-close-slide-panel',\n};\n", "import * as React from 'react';\nexport { React };\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,uBAAwC;AAEjC,MAAM,wBAAwB;AAC9B,MAAM,yBAAyB;AAAA,EACpC,cAAc;AAAA,EACd,OAAO;AAAA,EACP,WAAW;AACb;AAEO,MAAM,+BAA+B;AAAA,EAC1C,OAAG,0CAAwB,uBAAuB,sBAAsB;AAAA,EACxE,cAAc;AAChB;",
4
+ "sourcesContent": ["import { slotObjectToDataTestIds } from '@elliemae/ds-system';\n\nexport const DSSidePanelHeaderName = 'DSSidePanelHeader' as const;\nexport const DSSidePanelHeaderSlots = {\n CLOSE_BUTTON: 'close-button',\n TITLE: 'title',\n WRAPPER: 'wrapper',\n SEPARATOR: 'separator',\n};\n\nexport const DSSidePanelHeaderDataTestIds = {\n ...slotObjectToDataTestIds(DSSidePanelHeaderName, DSSidePanelHeaderSlots),\n CLOSE_BUTTON: 'btn-close-slide-panel',\n};\n", "import * as React from 'react';\nexport { React };\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,uBAAwC;AAEjC,MAAM,wBAAwB;AAC9B,MAAM,yBAAyB;AAAA,EACpC,cAAc;AAAA,EACd,OAAO;AAAA,EACP,SAAS;AAAA,EACT,WAAW;AACb;AAEO,MAAM,+BAA+B;AAAA,EAC1C,OAAG,0CAAwB,uBAAuB,sBAAsB;AAAA,EACxE,cAAc;AAChB;",
6
6
  "names": []
7
7
  }
@@ -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 './SidePanelHeader.js';\nexport * from './react-desc-prop-types.js';\nexport * from './SidePanelHeaderDefinitions.js';\n", "import * as React from 'react';\nexport { React };\n"],
4
+ "sourcesContent": ["export * from './SidePanelHeader.js';\nexport * from './react-desc-prop-types.js';\nexport * from './SidePanelHeaderDefinitions.js';\nimport {} from '@xstyled/system';\nimport {} from '@xstyled/util';\n", "import * as React from 'react';\nexport { React };\n"],
5
5
  "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;ACAA,YAAuB;ADAvB,wBAAc,iCAAd;AACA,wBAAc,uCADd;AAEA,wBAAc,4CAFd;",
6
6
  "names": []
7
7
  }
@@ -34,21 +34,24 @@ __export(react_desc_prop_types_exports, {
34
34
  module.exports = __toCommonJS(react_desc_prop_types_exports);
35
35
  var React = __toESM(require("react"));
36
36
  var import_ds_props_helpers = require("@elliemae/ds-props-helpers");
37
+ var import_ds_props_helpers2 = require("@elliemae/ds-props-helpers");
37
38
  const defaultProps = {
38
39
  onClose: () => {
39
40
  },
40
41
  showClose: true
41
42
  };
42
43
  const propTypes = {
44
+ ...import_ds_props_helpers.globalAttributesPropTypes,
45
+ ...import_ds_props_helpers.xstyledPropTypes,
43
46
  /** Page title */
44
- title: import_ds_props_helpers.PropTypes.string.description("Page title"),
47
+ title: import_ds_props_helpers2.PropTypes.string.description("Page title"),
45
48
  /** Action button */
46
- additionalAction: import_ds_props_helpers.PropTypes.element.description("Action button"),
49
+ additionalAction: import_ds_props_helpers2.PropTypes.element.description("Action button"),
47
50
  /** Called when the slide collapse */
48
- onClose: import_ds_props_helpers.PropTypes.func.description("Called when the slide collapse").defaultValue(defaultProps.onClose),
51
+ onClose: import_ds_props_helpers2.PropTypes.func.description("Called when the slide collapse").defaultValue(defaultProps.onClose),
49
52
  /** Show/Hide close button */
50
- showClose: import_ds_props_helpers.PropTypes.bool.description("Show/Hide close button").defaultValue(defaultProps.showClose),
53
+ showClose: import_ds_props_helpers2.PropTypes.bool.description("Show/Hide close button").defaultValue(defaultProps.showClose),
51
54
  /** Ref for close button */
52
- closeButtonRef: import_ds_props_helpers.PropTypes.object.description("Ref for close button")
55
+ closeButtonRef: import_ds_props_helpers2.PropTypes.object.description("Ref for close button")
53
56
  };
54
57
  //# sourceMappingURL=react-desc-prop-types.js.map
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../src/react-desc-prop-types.ts", "../../../../scripts/build/transpile/react-shim.js"],
4
- "sourcesContent": ["import type { WeakValidationMap } from 'react';\nimport type React from 'react';\nimport type {} from '@elliemae/ds-utilities';\nimport type { GlobalAttributesT, XstyledProps } from '@elliemae/ds-props-helpers';\nimport { PropTypes } from '@elliemae/ds-props-helpers';\n\nexport declare namespace DSSidePanelHeaderT {\n export interface DefaultProps {\n onClose: () => void;\n showClose: boolean;\n }\n\n export interface OptionalProps {\n title?: string;\n additionalAction?: React.ReactNode;\n closeButtonRef?: React.RefObject<HTMLButtonElement>;\n }\n\n export interface Props\n extends Partial<DefaultProps>,\n OptionalProps,\n Omit<GlobalAttributesT<HTMLButtonElement>, keyof DefaultProps | keyof OptionalProps>,\n XstyledProps {}\n export interface InternalProps\n extends DefaultProps,\n OptionalProps,\n Omit<GlobalAttributesT<HTMLButtonElement>, keyof DefaultProps | keyof OptionalProps>,\n XstyledProps {}\n}\n\nexport const defaultProps: DSSidePanelHeaderT.DefaultProps = {\n onClose: () => {},\n showClose: true,\n};\n\nexport const propTypes = {\n /** Page title */\n title: PropTypes.string.description('Page title'),\n /** Action button */\n additionalAction: PropTypes.element.description('Action button'),\n /** Called when the slide collapse */\n onClose: PropTypes.func.description('Called when the slide collapse').defaultValue(defaultProps.onClose),\n /** Show/Hide close button */\n showClose: PropTypes.bool.description('Show/Hide close button').defaultValue(defaultProps.showClose),\n /** Ref for close button */\n closeButtonRef: PropTypes.object.description('Ref for close button'),\n} as unknown as WeakValidationMap<DSSidePanelHeaderT.Props>;\n", "import * as React from 'react';\nexport { React };\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADIvB,8BAA0B;AA0BnB,MAAM,eAAgD;AAAA,EAC3D,SAAS,MAAM;AAAA,EAAC;AAAA,EAChB,WAAW;AACb;AAEO,MAAM,YAAY;AAAA;AAAA,EAEvB,OAAO,kCAAU,OAAO,YAAY,YAAY;AAAA;AAAA,EAEhD,kBAAkB,kCAAU,QAAQ,YAAY,eAAe;AAAA;AAAA,EAE/D,SAAS,kCAAU,KAAK,YAAY,gCAAgC,EAAE,aAAa,aAAa,OAAO;AAAA;AAAA,EAEvG,WAAW,kCAAU,KAAK,YAAY,wBAAwB,EAAE,aAAa,aAAa,SAAS;AAAA;AAAA,EAEnG,gBAAgB,kCAAU,OAAO,YAAY,sBAAsB;AACrE;",
6
- "names": []
4
+ "sourcesContent": ["import type { WeakValidationMap } from 'react';\nimport type React from 'react';\nimport type {} from '@elliemae/ds-utilities';\nimport {\n type GlobalAttributesT,\n type XstyledProps,\n globalAttributesPropTypes,\n xstyledPropTypes,\n} from '@elliemae/ds-props-helpers';\nimport { PropTypes } from '@elliemae/ds-props-helpers';\n\nexport declare namespace DSSidePanelHeaderT {\n export interface DefaultProps {\n onClose: () => void;\n showClose: boolean;\n }\n\n export interface OptionalProps {\n title?: string;\n additionalAction?: React.ReactNode;\n closeButtonRef?: React.RefObject<HTMLButtonElement>;\n }\n\n export interface Props\n extends Partial<DefaultProps>,\n OptionalProps,\n Omit<GlobalAttributesT<HTMLButtonElement>, keyof DefaultProps | keyof OptionalProps>,\n XstyledProps {}\n export interface InternalProps\n extends DefaultProps,\n OptionalProps,\n Omit<GlobalAttributesT<HTMLButtonElement>, keyof DefaultProps | keyof OptionalProps>,\n XstyledProps {}\n}\n\nexport const defaultProps: DSSidePanelHeaderT.DefaultProps = {\n onClose: () => {},\n showClose: true,\n};\n\nexport const propTypes = {\n ...globalAttributesPropTypes,\n ...xstyledPropTypes,\n /** Page title */\n title: PropTypes.string.description('Page title'),\n /** Action button */\n additionalAction: PropTypes.element.description('Action button'),\n /** Called when the slide collapse */\n onClose: PropTypes.func.description('Called when the slide collapse').defaultValue(defaultProps.onClose),\n /** Show/Hide close button */\n showClose: PropTypes.bool.description('Show/Hide close button').defaultValue(defaultProps.showClose),\n /** Ref for close button */\n closeButtonRef: PropTypes.object.description('Ref for close button'),\n} as unknown as WeakValidationMap<DSSidePanelHeaderT.Props>;\n", "import * as React from 'react';\nexport { React };\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADGvB,8BAKO;AACP,IAAAA,2BAA0B;AA0BnB,MAAM,eAAgD;AAAA,EAC3D,SAAS,MAAM;AAAA,EAAC;AAAA,EAChB,WAAW;AACb;AAEO,MAAM,YAAY;AAAA,EACvB,GAAG;AAAA,EACH,GAAG;AAAA;AAAA,EAEH,OAAO,mCAAU,OAAO,YAAY,YAAY;AAAA;AAAA,EAEhD,kBAAkB,mCAAU,QAAQ,YAAY,eAAe;AAAA;AAAA,EAE/D,SAAS,mCAAU,KAAK,YAAY,gCAAgC,EAAE,aAAa,aAAa,OAAO;AAAA;AAAA,EAEvG,WAAW,mCAAU,KAAK,YAAY,wBAAwB,EAAE,aAAa,aAAa,SAAS;AAAA;AAAA,EAEnG,gBAAgB,mCAAU,OAAO,YAAY,sBAAsB;AACrE;",
6
+ "names": ["import_ds_props_helpers"]
7
7
  }
@@ -43,22 +43,34 @@ const StyledTitle = (0, import_ds_system.styled)(import_ds_grid.Grid, {
43
43
  name: import_SidePanelHeaderDefinitions.DSSidePanelHeaderName,
44
44
  slot: import_SidePanelHeaderDefinitions.DSSidePanelHeaderSlots.TITLE
45
45
  })`
46
+ margin-right: ${(props) => props.theme.space.xs};
46
47
  font-size: 18px;
47
48
  font-weight: ${(props) => props.theme.fontWeights.regular};
48
49
  color: ${(props) => props.theme.colors.neutral["700"]};
49
50
  ${(0, import_ds_system.truncate)()}
51
+ ${import_ds_system.xStyledCommonProps}
50
52
  `;
51
- const Wrapper = (0, import_ds_system.styled)(import_ds_grid.Grid)`
53
+ const Wrapper = (0, import_ds_system.styled)(import_ds_grid.Grid, {
54
+ name: import_SidePanelHeaderDefinitions.DSSidePanelHeaderName,
55
+ slot: import_SidePanelHeaderDefinitions.DSSidePanelHeaderSlots.WRAPPER
56
+ })`
57
+ padding-right: ${(props) => props.theme.space.xs};
58
+ padding-left: ${(props) => props.theme.space.xs};
59
+ height: ${(props) => props.theme.space.m};
52
60
  border-bottom: ${(props) => (0, import_ds_system.border)(props.theme.colors.neutral["300"])};
61
+ ${import_ds_system.xStyledCommonProps}
53
62
  `;
54
63
  const StyledCloseButton = (0, import_ds_system.styled)(import_ds_button_v2.DSButtonV2, {
55
64
  name: import_SidePanelHeaderDefinitions.DSSidePanelHeaderName,
56
65
  slot: import_SidePanelHeaderDefinitions.DSSidePanelHeaderSlots.CLOSE_BUTTON
57
- })``;
66
+ })`
67
+ ${import_ds_system.xStyledCommonProps}
68
+ `;
58
69
  const StyledSeparator = import_ds_system.styled.div`
59
70
  width: 0;
60
71
  height: 100%;
61
72
  margin: 0 ${(props) => props.theme.space.xxs};
62
73
  border-left: ${(props) => `${props.theme.colors.neutral[300]} 1px solid`};
74
+ ${import_ds_system.xStyledCommonProps}
63
75
  `;
64
76
  //# sourceMappingURL=styled.js.map
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../src/styled.tsx", "../../../../scripts/build/transpile/react-shim.js"],
4
- "sourcesContent": ["import { styled, border, truncate } from '@elliemae/ds-system';\nimport { DSButtonV2 } from '@elliemae/ds-button-v2';\nimport { Grid } from '@elliemae/ds-grid';\nimport { DSSidePanelHeaderName, DSSidePanelHeaderSlots } from './SidePanelHeaderDefinitions.js';\nexport const StyledTitle = styled(Grid, {\n name: DSSidePanelHeaderName,\n slot: DSSidePanelHeaderSlots.TITLE,\n})`\n font-size: 18px;\n font-weight: ${(props) => props.theme.fontWeights.regular};\n color: ${(props) => props.theme.colors.neutral['700']};\n ${truncate()}\n`;\n\nexport const Wrapper = styled(Grid)`\n border-bottom: ${(props) => border(props.theme.colors.neutral['300'])};\n`;\n\nexport const StyledCloseButton = styled(DSButtonV2, {\n name: DSSidePanelHeaderName,\n slot: DSSidePanelHeaderSlots.CLOSE_BUTTON,\n})``;\n\nexport const StyledSeparator = styled.div`\n width: 0;\n height: 100%;\n margin: 0 ${(props) => props.theme.space.xxs};\n border-left: ${(props) => `${props.theme.colors.neutral[300]} 1px solid`};\n`;\n", "import * as React from 'react';\nexport { React };\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,uBAAyC;AACzC,0BAA2B;AAC3B,qBAAqB;AACrB,wCAA8D;AACvD,MAAM,kBAAc,yBAAO,qBAAM;AAAA,EACtC,MAAM;AAAA,EACN,MAAM,yDAAuB;AAC/B,CAAC;AAAA;AAAA,iBAEgB,CAAC,UAAU,MAAM,MAAM,YAAY;AAAA,WACzC,CAAC,UAAU,MAAM,MAAM,OAAO,QAAQ,KAAK;AAAA,QAClD,2BAAS;AAAA;AAGN,MAAM,cAAU,yBAAO,mBAAI;AAAA,mBACf,CAAC,cAAU,yBAAO,MAAM,MAAM,OAAO,QAAQ,KAAK,CAAC;AAAA;AAG/D,MAAM,wBAAoB,yBAAO,gCAAY;AAAA,EAClD,MAAM;AAAA,EACN,MAAM,yDAAuB;AAC/B,CAAC;AAEM,MAAM,kBAAkB,wBAAO;AAAA;AAAA;AAAA,cAGxB,CAAC,UAAU,MAAM,MAAM,MAAM;AAAA,iBAC1B,CAAC,UAAU,GAAG,MAAM,MAAM,OAAO,QAAQ,GAAG;AAAA;",
4
+ "sourcesContent": ["import { styled, border, truncate, xStyledCommonProps } from '@elliemae/ds-system';\nimport { DSButtonV2 } from '@elliemae/ds-button-v2';\nimport { Grid } from '@elliemae/ds-grid';\nimport { DSSidePanelHeaderName, DSSidePanelHeaderSlots } from './SidePanelHeaderDefinitions.js';\nexport const StyledTitle = styled(Grid, {\n name: DSSidePanelHeaderName,\n slot: DSSidePanelHeaderSlots.TITLE,\n})`\n margin-right: ${(props) => props.theme.space.xs};\n font-size: 18px;\n font-weight: ${(props) => props.theme.fontWeights.regular};\n color: ${(props) => props.theme.colors.neutral['700']};\n ${truncate()}\n ${xStyledCommonProps}\n`;\n\nexport const Wrapper = styled(Grid, {\n name: DSSidePanelHeaderName,\n slot: DSSidePanelHeaderSlots.WRAPPER,\n})`\n padding-right: ${(props) => props.theme.space.xs};\n padding-left: ${(props) => props.theme.space.xs};\n height: ${(props) => props.theme.space.m};\n border-bottom: ${(props) => border(props.theme.colors.neutral['300'])};\n ${xStyledCommonProps}\n`;\n\nexport const StyledCloseButton = styled(DSButtonV2, {\n name: DSSidePanelHeaderName,\n slot: DSSidePanelHeaderSlots.CLOSE_BUTTON,\n})`\n ${xStyledCommonProps}\n`;\n\nexport const StyledSeparator = styled.div`\n width: 0;\n height: 100%;\n margin: 0 ${(props) => props.theme.space.xxs};\n border-left: ${(props) => `${props.theme.colors.neutral[300]} 1px solid`};\n ${xStyledCommonProps}\n`;\n", "import * as React from 'react';\nexport { React };\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,uBAA6D;AAC7D,0BAA2B;AAC3B,qBAAqB;AACrB,wCAA8D;AACvD,MAAM,kBAAc,yBAAO,qBAAM;AAAA,EACtC,MAAM;AAAA,EACN,MAAM,yDAAuB;AAC/B,CAAC;AAAA,kBACiB,CAAC,UAAU,MAAM,MAAM,MAAM;AAAA;AAAA,iBAE9B,CAAC,UAAU,MAAM,MAAM,YAAY;AAAA,WACzC,CAAC,UAAU,MAAM,MAAM,OAAO,QAAQ,KAAK;AAAA,QAClD,2BAAS;AAAA,IACT;AAAA;AAGG,MAAM,cAAU,yBAAO,qBAAM;AAAA,EAClC,MAAM;AAAA,EACN,MAAM,yDAAuB;AAC/B,CAAC;AAAA,mBACkB,CAAC,UAAU,MAAM,MAAM,MAAM;AAAA,kBAC9B,CAAC,UAAU,MAAM,MAAM,MAAM;AAAA,YACnC,CAAC,UAAU,MAAM,MAAM,MAAM;AAAA,mBACtB,CAAC,cAAU,yBAAO,MAAM,MAAM,OAAO,QAAQ,KAAK,CAAC;AAAA,IAClE;AAAA;AAGG,MAAM,wBAAoB,yBAAO,gCAAY;AAAA,EAClD,MAAM;AAAA,EACN,MAAM,yDAAuB;AAC/B,CAAC;AAAA,IACG;AAAA;AAGG,MAAM,kBAAkB,wBAAO;AAAA;AAAA;AAAA,cAGxB,CAAC,UAAU,MAAM,MAAM,MAAM;AAAA,iBAC1B,CAAC,UAAU,GAAG,MAAM,MAAM,OAAO,QAAQ,GAAG;AAAA,IACzD;AAAA;",
6
6
  "names": []
7
7
  }
@@ -1,62 +1,55 @@
1
1
  import * as React from "react";
2
2
  import { jsx, jsxs } from "react/jsx-runtime";
3
3
  import { useCallback } from "react";
4
- import { describe, useMemoMergePropsWithDefault } from "@elliemae/ds-props-helpers";
5
- import { useTheme } from "@elliemae/ds-system";
6
- import { noop } from "lodash";
4
+ import {
5
+ describe,
6
+ useMemoMergePropsWithDefault,
7
+ useGetGlobalAttributes,
8
+ useGetXstyledProps
9
+ } from "@elliemae/ds-props-helpers";
10
+ import { noop, omit } from "lodash";
7
11
  import { CloseSmall } from "@elliemae/ds-icons";
8
12
  import { Grid } from "@elliemae/ds-grid";
9
13
  import { defaultProps, propTypes } from "./react-desc-prop-types.js";
10
14
  import { StyledSeparator, StyledTitle, Wrapper, StyledCloseButton } from "./styled.js";
11
15
  const SidePanelHeader = (props) => {
12
16
  const propsWithDefaults = useMemoMergePropsWithDefault(props, defaultProps);
17
+ const globalAttributes = omit(useGetGlobalAttributes(propsWithDefaults), "cols", "wrap", "rows");
18
+ const xStyledProps = useGetXstyledProps(propsWithDefaults);
13
19
  const getOwnerProps = useCallback(() => propsWithDefaults, [propsWithDefaults]);
14
20
  const getOwnerPropsArguments = useCallback(() => ({}), []);
15
21
  const { title, additionalAction, onClose = noop, showClose = true, closeButtonRef = void 0 } = propsWithDefaults;
16
- const theme = useTheme();
17
22
  const separator = /* @__PURE__ */ jsx(Grid, { height: "24px", children: /* @__PURE__ */ jsx(StyledSeparator, { getOwnerProps, getOwnerPropsArguments }) });
18
23
  const cols = ["1fr", "auto", "auto"];
19
- const cols2 = ["auto"];
20
- return /* @__PURE__ */ jsxs(
21
- Wrapper,
22
- {
23
- cols,
24
- height: theme.space.m,
25
- pl: theme.space.xs,
26
- pr: theme.space.xs,
27
- alignItems: "center",
28
- width: "100%",
29
- children: [
30
- /* @__PURE__ */ jsx(Grid, { alignItems: "center", justifyContent: "flex-start", cols: cols2, pr: theme.space.xs, children: /* @__PURE__ */ jsx(
31
- StyledTitle,
32
- {
33
- maxWidth: "100%",
34
- alignItems: "center",
35
- getOwnerProps,
36
- getOwnerPropsArguments,
37
- children: title
38
- }
39
- ) }),
40
- /* @__PURE__ */ jsxs(Grid, { ml: "xxs", alignItems: "center", cols: additionalAction ? ["auto", "auto", "auto"] : ["auto"], children: [
41
- additionalAction && /* @__PURE__ */ jsx(Grid, { children: additionalAction }),
42
- additionalAction && showClose && separator,
43
- /* @__PURE__ */ jsx(Grid, { children: showClose && /* @__PURE__ */ jsx(
44
- StyledCloseButton,
45
- {
46
- buttonType: "icon",
47
- innerRef: closeButtonRef,
48
- size: "m",
49
- onClick: onClose,
50
- "data-testid": "btn-close-slide-panel",
51
- getOwnerProps,
52
- getOwnerPropsArguments,
53
- children: /* @__PURE__ */ jsx(CloseSmall, {})
54
- }
55
- ) })
56
- ] })
57
- ]
58
- }
59
- );
24
+ return /* @__PURE__ */ jsxs(Wrapper, { cols, alignItems: "center", width: "100%", ...globalAttributes, ...xStyledProps, children: [
25
+ /* @__PURE__ */ jsx(
26
+ StyledTitle,
27
+ {
28
+ maxWidth: "100%",
29
+ alignItems: "center",
30
+ getOwnerProps,
31
+ getOwnerPropsArguments,
32
+ children: title
33
+ }
34
+ ),
35
+ /* @__PURE__ */ jsxs(Grid, { ml: "xxs", alignItems: "center", cols: additionalAction ? ["auto", "auto", "auto"] : ["auto"], children: [
36
+ additionalAction && /* @__PURE__ */ jsx(Grid, { children: additionalAction }),
37
+ additionalAction && showClose && separator,
38
+ /* @__PURE__ */ jsx(Grid, { children: showClose && /* @__PURE__ */ jsx(
39
+ StyledCloseButton,
40
+ {
41
+ buttonType: "icon",
42
+ innerRef: closeButtonRef,
43
+ size: "m",
44
+ onClick: onClose,
45
+ "data-testid": "btn-close-slide-panel",
46
+ getOwnerProps,
47
+ getOwnerPropsArguments,
48
+ children: /* @__PURE__ */ jsx(CloseSmall, {})
49
+ }
50
+ ) })
51
+ ] })
52
+ ] });
60
53
  };
61
54
  SidePanelHeader.propTypes = propTypes;
62
55
  SidePanelHeader.displayName = "SidePanelHeader";
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../scripts/build/transpile/react-shim.js", "../../src/SidePanelHeader.tsx"],
4
- "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import React, { useCallback } from 'react';\nimport { describe, useMemoMergePropsWithDefault } from '@elliemae/ds-props-helpers';\nimport { useTheme } from '@elliemae/ds-system';\nimport { noop } from 'lodash';\nimport { CloseSmall } from '@elliemae/ds-icons';\nimport { Grid } from '@elliemae/ds-grid';\nimport { type DSSidePanelHeaderT, defaultProps, propTypes } from './react-desc-prop-types.js';\n\nimport { StyledSeparator, StyledTitle, Wrapper, StyledCloseButton } from './styled.js';\nconst SidePanelHeader = (props: DSSidePanelHeaderT.Props) => {\n const propsWithDefaults = useMemoMergePropsWithDefault<DSSidePanelHeaderT.InternalProps>(props, defaultProps);\n\n const getOwnerProps = useCallback(() => propsWithDefaults, [propsWithDefaults]);\n const getOwnerPropsArguments = useCallback(() => ({}), []);\n const { title, additionalAction, onClose = noop, showClose = true, closeButtonRef = undefined } = propsWithDefaults;\n const theme = useTheme();\n const separator = (\n <Grid height=\"24px\">\n <StyledSeparator getOwnerProps={getOwnerProps} getOwnerPropsArguments={getOwnerPropsArguments} />\n </Grid>\n );\n const cols = ['1fr', 'auto', 'auto'];\n const cols2 = ['auto'];\n return (\n <Wrapper\n cols={cols}\n height={theme.space.m}\n pl={theme.space.xs}\n pr={theme.space.xs}\n alignItems=\"center\"\n width=\"100%\"\n >\n <Grid alignItems=\"center\" justifyContent=\"flex-start\" cols={cols2} pr={theme.space.xs}>\n <StyledTitle\n maxWidth=\"100%\"\n alignItems=\"center\"\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n {title}\n </StyledTitle>\n </Grid>\n <Grid ml=\"xxs\" alignItems=\"center\" cols={additionalAction ? ['auto', 'auto', 'auto'] : ['auto']}>\n {additionalAction && <Grid>{additionalAction}</Grid>}\n {additionalAction && showClose && separator}\n <Grid>\n {showClose && (\n <StyledCloseButton\n buttonType=\"icon\"\n innerRef={closeButtonRef}\n size=\"m\"\n onClick={onClose}\n data-testid=\"btn-close-slide-panel\"\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <CloseSmall />\n </StyledCloseButton>\n )}\n </Grid>\n </Grid>\n </Wrapper>\n );\n};\n\nSidePanelHeader.propTypes = propTypes;\nSidePanelHeader.displayName = 'SidePanelHeader';\nconst DSSidePanelHeaderWithSchema = describe(SidePanelHeader);\n\nDSSidePanelHeaderWithSchema.propTypes = propTypes;\n\nexport { SidePanelHeader, DSSidePanelHeaderWithSchema };\n"],
5
- "mappings": "AAAA,YAAY,WAAW;ACkBjB,cAwBA,YAxBA;AAlBN,SAAgB,mBAAmB;AACnC,SAAS,UAAU,oCAAoC;AACvD,SAAS,gBAAgB;AACzB,SAAS,YAAY;AACrB,SAAS,kBAAkB;AAC3B,SAAS,YAAY;AACrB,SAAkC,cAAc,iBAAiB;AAEjE,SAAS,iBAAiB,aAAa,SAAS,yBAAyB;AACzE,MAAM,kBAAkB,CAAC,UAAoC;AAC3D,QAAM,oBAAoB,6BAA+D,OAAO,YAAY;AAE5G,QAAM,gBAAgB,YAAY,MAAM,mBAAmB,CAAC,iBAAiB,CAAC;AAC9E,QAAM,yBAAyB,YAAY,OAAO,CAAC,IAAI,CAAC,CAAC;AACzD,QAAM,EAAE,OAAO,kBAAkB,UAAU,MAAM,YAAY,MAAM,iBAAiB,OAAU,IAAI;AAClG,QAAM,QAAQ,SAAS;AACvB,QAAM,YACJ,oBAAC,QAAK,QAAO,QACX,8BAAC,mBAAgB,eAA8B,wBAAgD,GACjG;AAEF,QAAM,OAAO,CAAC,OAAO,QAAQ,MAAM;AACnC,QAAM,QAAQ,CAAC,MAAM;AACrB,SACE;AAAA,IAAC;AAAA;AAAA,MACC;AAAA,MACA,QAAQ,MAAM,MAAM;AAAA,MACpB,IAAI,MAAM,MAAM;AAAA,MAChB,IAAI,MAAM,MAAM;AAAA,MAChB,YAAW;AAAA,MACX,OAAM;AAAA,MAEN;AAAA,4BAAC,QAAK,YAAW,UAAS,gBAAe,cAAa,MAAM,OAAO,IAAI,MAAM,MAAM,IACjF;AAAA,UAAC;AAAA;AAAA,YACC,UAAS;AAAA,YACT,YAAW;AAAA,YACX;AAAA,YACA;AAAA,YAEC;AAAA;AAAA,QACH,GACF;AAAA,QACA,qBAAC,QAAK,IAAG,OAAM,YAAW,UAAS,MAAM,mBAAmB,CAAC,QAAQ,QAAQ,MAAM,IAAI,CAAC,MAAM,GAC3F;AAAA,8BAAoB,oBAAC,QAAM,4BAAiB;AAAA,UAC5C,oBAAoB,aAAa;AAAA,UAClC,oBAAC,QACE,uBACC;AAAA,YAAC;AAAA;AAAA,cACC,YAAW;AAAA,cACX,UAAU;AAAA,cACV,MAAK;AAAA,cACL,SAAS;AAAA,cACT,eAAY;AAAA,cACZ;AAAA,cACA;AAAA,cAEA,8BAAC,cAAW;AAAA;AAAA,UACd,GAEJ;AAAA,WACF;AAAA;AAAA;AAAA,EACF;AAEJ;AAEA,gBAAgB,YAAY;AAC5B,gBAAgB,cAAc;AAC9B,MAAM,8BAA8B,SAAS,eAAe;AAE5D,4BAA4B,YAAY;",
4
+ "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import React, { useCallback } from 'react';\nimport {\n describe,\n useMemoMergePropsWithDefault,\n useGetGlobalAttributes,\n useGetXstyledProps,\n} from '@elliemae/ds-props-helpers';\nimport { noop, omit } from 'lodash';\nimport { CloseSmall } from '@elliemae/ds-icons';\nimport { Grid } from '@elliemae/ds-grid';\nimport { type DSSidePanelHeaderT, defaultProps, propTypes } from './react-desc-prop-types.js';\n\nimport { StyledSeparator, StyledTitle, Wrapper, StyledCloseButton } from './styled.js';\nconst SidePanelHeader = (props: DSSidePanelHeaderT.Props) => {\n const propsWithDefaults = useMemoMergePropsWithDefault<DSSidePanelHeaderT.InternalProps>(props, defaultProps);\n\n const globalAttributes = omit(useGetGlobalAttributes(propsWithDefaults), 'cols', 'wrap', 'rows');\n const xStyledProps = useGetXstyledProps(propsWithDefaults);\n\n const getOwnerProps = useCallback(() => propsWithDefaults, [propsWithDefaults]);\n const getOwnerPropsArguments = useCallback(() => ({}), []);\n const { title, additionalAction, onClose = noop, showClose = true, closeButtonRef = undefined } = propsWithDefaults;\n const separator = (\n <Grid height=\"24px\">\n <StyledSeparator getOwnerProps={getOwnerProps} getOwnerPropsArguments={getOwnerPropsArguments} />\n </Grid>\n );\n const cols = ['1fr', 'auto', 'auto'];\n return (\n <Wrapper cols={cols} alignItems=\"center\" width=\"100%\" {...globalAttributes} {...xStyledProps}>\n <StyledTitle\n maxWidth=\"100%\"\n alignItems=\"center\"\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n {title}\n </StyledTitle>\n <Grid ml=\"xxs\" alignItems=\"center\" cols={additionalAction ? ['auto', 'auto', 'auto'] : ['auto']}>\n {additionalAction && <Grid>{additionalAction}</Grid>}\n {additionalAction && showClose && separator}\n <Grid>\n {showClose && (\n <StyledCloseButton\n buttonType=\"icon\"\n innerRef={closeButtonRef}\n size=\"m\"\n onClick={onClose}\n data-testid=\"btn-close-slide-panel\"\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <CloseSmall />\n </StyledCloseButton>\n )}\n </Grid>\n </Grid>\n </Wrapper>\n );\n};\n\nSidePanelHeader.propTypes = propTypes;\nSidePanelHeader.displayName = 'SidePanelHeader';\nconst DSSidePanelHeaderWithSchema = describe(SidePanelHeader);\n\nDSSidePanelHeaderWithSchema.propTypes = propTypes;\n\nexport { SidePanelHeader, DSSidePanelHeaderWithSchema };\n"],
5
+ "mappings": "AAAA,YAAY,WAAW;ACwBjB,cAcA,YAdA;AAxBN,SAAgB,mBAAmB;AACnC;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACK;AACP,SAAS,MAAM,YAAY;AAC3B,SAAS,kBAAkB;AAC3B,SAAS,YAAY;AACrB,SAAkC,cAAc,iBAAiB;AAEjE,SAAS,iBAAiB,aAAa,SAAS,yBAAyB;AACzE,MAAM,kBAAkB,CAAC,UAAoC;AAC3D,QAAM,oBAAoB,6BAA+D,OAAO,YAAY;AAE5G,QAAM,mBAAmB,KAAK,uBAAuB,iBAAiB,GAAG,QAAQ,QAAQ,MAAM;AAC/F,QAAM,eAAe,mBAAmB,iBAAiB;AAEzD,QAAM,gBAAgB,YAAY,MAAM,mBAAmB,CAAC,iBAAiB,CAAC;AAC9E,QAAM,yBAAyB,YAAY,OAAO,CAAC,IAAI,CAAC,CAAC;AACzD,QAAM,EAAE,OAAO,kBAAkB,UAAU,MAAM,YAAY,MAAM,iBAAiB,OAAU,IAAI;AAClG,QAAM,YACJ,oBAAC,QAAK,QAAO,QACX,8BAAC,mBAAgB,eAA8B,wBAAgD,GACjG;AAEF,QAAM,OAAO,CAAC,OAAO,QAAQ,MAAM;AACnC,SACE,qBAAC,WAAQ,MAAY,YAAW,UAAS,OAAM,QAAQ,GAAG,kBAAmB,GAAG,cAC9E;AAAA;AAAA,MAAC;AAAA;AAAA,QACC,UAAS;AAAA,QACT,YAAW;AAAA,QACX;AAAA,QACA;AAAA,QAEC;AAAA;AAAA,IACH;AAAA,IACA,qBAAC,QAAK,IAAG,OAAM,YAAW,UAAS,MAAM,mBAAmB,CAAC,QAAQ,QAAQ,MAAM,IAAI,CAAC,MAAM,GAC3F;AAAA,0BAAoB,oBAAC,QAAM,4BAAiB;AAAA,MAC5C,oBAAoB,aAAa;AAAA,MAClC,oBAAC,QACE,uBACC;AAAA,QAAC;AAAA;AAAA,UACC,YAAW;AAAA,UACX,UAAU;AAAA,UACV,MAAK;AAAA,UACL,SAAS;AAAA,UACT,eAAY;AAAA,UACZ;AAAA,UACA;AAAA,UAEA,8BAAC,cAAW;AAAA;AAAA,MACd,GAEJ;AAAA,OACF;AAAA,KACF;AAEJ;AAEA,gBAAgB,YAAY;AAC5B,gBAAgB,cAAc;AAC9B,MAAM,8BAA8B,SAAS,eAAe;AAE5D,4BAA4B,YAAY;",
6
6
  "names": []
7
7
  }
@@ -4,6 +4,7 @@ const DSSidePanelHeaderName = "DSSidePanelHeader";
4
4
  const DSSidePanelHeaderSlots = {
5
5
  CLOSE_BUTTON: "close-button",
6
6
  TITLE: "title",
7
+ WRAPPER: "wrapper",
7
8
  SEPARATOR: "separator"
8
9
  };
9
10
  const DSSidePanelHeaderDataTestIds = {
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../scripts/build/transpile/react-shim.js", "../../src/SidePanelHeaderDefinitions.ts"],
4
- "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { slotObjectToDataTestIds } from '@elliemae/ds-system';\n\nexport const DSSidePanelHeaderName = 'DSSidePanelHeader' as const;\nexport const DSSidePanelHeaderSlots = {\n CLOSE_BUTTON: 'close-button',\n TITLE: 'title',\n SEPARATOR: 'separator',\n};\n\nexport const DSSidePanelHeaderDataTestIds = {\n ...slotObjectToDataTestIds(DSSidePanelHeaderName, DSSidePanelHeaderSlots),\n CLOSE_BUTTON: 'btn-close-slide-panel',\n};\n"],
5
- "mappings": "AAAA,YAAY,WAAW;ACAvB,SAAS,+BAA+B;AAEjC,MAAM,wBAAwB;AAC9B,MAAM,yBAAyB;AAAA,EACpC,cAAc;AAAA,EACd,OAAO;AAAA,EACP,WAAW;AACb;AAEO,MAAM,+BAA+B;AAAA,EAC1C,GAAG,wBAAwB,uBAAuB,sBAAsB;AAAA,EACxE,cAAc;AAChB;",
4
+ "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { slotObjectToDataTestIds } from '@elliemae/ds-system';\n\nexport const DSSidePanelHeaderName = 'DSSidePanelHeader' as const;\nexport const DSSidePanelHeaderSlots = {\n CLOSE_BUTTON: 'close-button',\n TITLE: 'title',\n WRAPPER: 'wrapper',\n SEPARATOR: 'separator',\n};\n\nexport const DSSidePanelHeaderDataTestIds = {\n ...slotObjectToDataTestIds(DSSidePanelHeaderName, DSSidePanelHeaderSlots),\n CLOSE_BUTTON: 'btn-close-slide-panel',\n};\n"],
5
+ "mappings": "AAAA,YAAY,WAAW;ACAvB,SAAS,+BAA+B;AAEjC,MAAM,wBAAwB;AAC9B,MAAM,yBAAyB;AAAA,EACpC,cAAc;AAAA,EACd,OAAO;AAAA,EACP,SAAS;AAAA,EACT,WAAW;AACb;AAEO,MAAM,+BAA+B;AAAA,EAC1C,GAAG,wBAAwB,uBAAuB,sBAAsB;AAAA,EACxE,cAAc;AAChB;",
6
6
  "names": []
7
7
  }
@@ -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 './SidePanelHeader.js';\nexport * from './react-desc-prop-types.js';\nexport * from './SidePanelHeaderDefinitions.js';\n"],
4
+ "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "export * from './SidePanelHeader.js';\nexport * from './react-desc-prop-types.js';\nexport * from './SidePanelHeaderDefinitions.js';\nimport {} from '@xstyled/system';\nimport {} from '@xstyled/util';\n"],
5
5
  "mappings": "AAAA,YAAY,WAAW;ACAvB,cAAc;AACd,cAAc;AACd,cAAc;",
6
6
  "names": []
7
7
  }
@@ -1,4 +1,8 @@
1
1
  import * as React from "react";
2
+ import {
3
+ globalAttributesPropTypes,
4
+ xstyledPropTypes
5
+ } from "@elliemae/ds-props-helpers";
2
6
  import { PropTypes } from "@elliemae/ds-props-helpers";
3
7
  const defaultProps = {
4
8
  onClose: () => {
@@ -6,6 +10,8 @@ const defaultProps = {
6
10
  showClose: true
7
11
  };
8
12
  const propTypes = {
13
+ ...globalAttributesPropTypes,
14
+ ...xstyledPropTypes,
9
15
  /** Page title */
10
16
  title: PropTypes.string.description("Page title"),
11
17
  /** Action button */
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../scripts/build/transpile/react-shim.js", "../../src/react-desc-prop-types.ts"],
4
- "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import type { WeakValidationMap } from 'react';\nimport type React from 'react';\nimport type {} from '@elliemae/ds-utilities';\nimport type { GlobalAttributesT, XstyledProps } from '@elliemae/ds-props-helpers';\nimport { PropTypes } from '@elliemae/ds-props-helpers';\n\nexport declare namespace DSSidePanelHeaderT {\n export interface DefaultProps {\n onClose: () => void;\n showClose: boolean;\n }\n\n export interface OptionalProps {\n title?: string;\n additionalAction?: React.ReactNode;\n closeButtonRef?: React.RefObject<HTMLButtonElement>;\n }\n\n export interface Props\n extends Partial<DefaultProps>,\n OptionalProps,\n Omit<GlobalAttributesT<HTMLButtonElement>, keyof DefaultProps | keyof OptionalProps>,\n XstyledProps {}\n export interface InternalProps\n extends DefaultProps,\n OptionalProps,\n Omit<GlobalAttributesT<HTMLButtonElement>, keyof DefaultProps | keyof OptionalProps>,\n XstyledProps {}\n}\n\nexport const defaultProps: DSSidePanelHeaderT.DefaultProps = {\n onClose: () => {},\n showClose: true,\n};\n\nexport const propTypes = {\n /** Page title */\n title: PropTypes.string.description('Page title'),\n /** Action button */\n additionalAction: PropTypes.element.description('Action button'),\n /** Called when the slide collapse */\n onClose: PropTypes.func.description('Called when the slide collapse').defaultValue(defaultProps.onClose),\n /** Show/Hide close button */\n showClose: PropTypes.bool.description('Show/Hide close button').defaultValue(defaultProps.showClose),\n /** Ref for close button */\n closeButtonRef: PropTypes.object.description('Ref for close button'),\n} as unknown as WeakValidationMap<DSSidePanelHeaderT.Props>;\n"],
5
- "mappings": "AAAA,YAAY,WAAW;ACIvB,SAAS,iBAAiB;AA0BnB,MAAM,eAAgD;AAAA,EAC3D,SAAS,MAAM;AAAA,EAAC;AAAA,EAChB,WAAW;AACb;AAEO,MAAM,YAAY;AAAA;AAAA,EAEvB,OAAO,UAAU,OAAO,YAAY,YAAY;AAAA;AAAA,EAEhD,kBAAkB,UAAU,QAAQ,YAAY,eAAe;AAAA;AAAA,EAE/D,SAAS,UAAU,KAAK,YAAY,gCAAgC,EAAE,aAAa,aAAa,OAAO;AAAA;AAAA,EAEvG,WAAW,UAAU,KAAK,YAAY,wBAAwB,EAAE,aAAa,aAAa,SAAS;AAAA;AAAA,EAEnG,gBAAgB,UAAU,OAAO,YAAY,sBAAsB;AACrE;",
4
+ "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import type { WeakValidationMap } from 'react';\nimport type React from 'react';\nimport type {} from '@elliemae/ds-utilities';\nimport {\n type GlobalAttributesT,\n type XstyledProps,\n globalAttributesPropTypes,\n xstyledPropTypes,\n} from '@elliemae/ds-props-helpers';\nimport { PropTypes } from '@elliemae/ds-props-helpers';\n\nexport declare namespace DSSidePanelHeaderT {\n export interface DefaultProps {\n onClose: () => void;\n showClose: boolean;\n }\n\n export interface OptionalProps {\n title?: string;\n additionalAction?: React.ReactNode;\n closeButtonRef?: React.RefObject<HTMLButtonElement>;\n }\n\n export interface Props\n extends Partial<DefaultProps>,\n OptionalProps,\n Omit<GlobalAttributesT<HTMLButtonElement>, keyof DefaultProps | keyof OptionalProps>,\n XstyledProps {}\n export interface InternalProps\n extends DefaultProps,\n OptionalProps,\n Omit<GlobalAttributesT<HTMLButtonElement>, keyof DefaultProps | keyof OptionalProps>,\n XstyledProps {}\n}\n\nexport const defaultProps: DSSidePanelHeaderT.DefaultProps = {\n onClose: () => {},\n showClose: true,\n};\n\nexport const propTypes = {\n ...globalAttributesPropTypes,\n ...xstyledPropTypes,\n /** Page title */\n title: PropTypes.string.description('Page title'),\n /** Action button */\n additionalAction: PropTypes.element.description('Action button'),\n /** Called when the slide collapse */\n onClose: PropTypes.func.description('Called when the slide collapse').defaultValue(defaultProps.onClose),\n /** Show/Hide close button */\n showClose: PropTypes.bool.description('Show/Hide close button').defaultValue(defaultProps.showClose),\n /** Ref for close button */\n closeButtonRef: PropTypes.object.description('Ref for close button'),\n} as unknown as WeakValidationMap<DSSidePanelHeaderT.Props>;\n"],
5
+ "mappings": "AAAA,YAAY,WAAW;ACGvB;AAAA,EAGE;AAAA,EACA;AAAA,OACK;AACP,SAAS,iBAAiB;AA0BnB,MAAM,eAAgD;AAAA,EAC3D,SAAS,MAAM;AAAA,EAAC;AAAA,EAChB,WAAW;AACb;AAEO,MAAM,YAAY;AAAA,EACvB,GAAG;AAAA,EACH,GAAG;AAAA;AAAA,EAEH,OAAO,UAAU,OAAO,YAAY,YAAY;AAAA;AAAA,EAEhD,kBAAkB,UAAU,QAAQ,YAAY,eAAe;AAAA;AAAA,EAE/D,SAAS,UAAU,KAAK,YAAY,gCAAgC,EAAE,aAAa,aAAa,OAAO;AAAA;AAAA,EAEvG,WAAW,UAAU,KAAK,YAAY,wBAAwB,EAAE,aAAa,aAAa,SAAS;AAAA;AAAA,EAEnG,gBAAgB,UAAU,OAAO,YAAY,sBAAsB;AACrE;",
6
6
  "names": []
7
7
  }
@@ -1,5 +1,5 @@
1
1
  import * as React from "react";
2
- import { styled, border, truncate } from "@elliemae/ds-system";
2
+ import { styled, border, truncate, xStyledCommonProps } from "@elliemae/ds-system";
3
3
  import { DSButtonV2 } from "@elliemae/ds-button-v2";
4
4
  import { Grid } from "@elliemae/ds-grid";
5
5
  import { DSSidePanelHeaderName, DSSidePanelHeaderSlots } from "./SidePanelHeaderDefinitions.js";
@@ -7,23 +7,35 @@ const StyledTitle = styled(Grid, {
7
7
  name: DSSidePanelHeaderName,
8
8
  slot: DSSidePanelHeaderSlots.TITLE
9
9
  })`
10
+ margin-right: ${(props) => props.theme.space.xs};
10
11
  font-size: 18px;
11
12
  font-weight: ${(props) => props.theme.fontWeights.regular};
12
13
  color: ${(props) => props.theme.colors.neutral["700"]};
13
14
  ${truncate()}
15
+ ${xStyledCommonProps}
14
16
  `;
15
- const Wrapper = styled(Grid)`
17
+ const Wrapper = styled(Grid, {
18
+ name: DSSidePanelHeaderName,
19
+ slot: DSSidePanelHeaderSlots.WRAPPER
20
+ })`
21
+ padding-right: ${(props) => props.theme.space.xs};
22
+ padding-left: ${(props) => props.theme.space.xs};
23
+ height: ${(props) => props.theme.space.m};
16
24
  border-bottom: ${(props) => border(props.theme.colors.neutral["300"])};
25
+ ${xStyledCommonProps}
17
26
  `;
18
27
  const StyledCloseButton = styled(DSButtonV2, {
19
28
  name: DSSidePanelHeaderName,
20
29
  slot: DSSidePanelHeaderSlots.CLOSE_BUTTON
21
- })``;
30
+ })`
31
+ ${xStyledCommonProps}
32
+ `;
22
33
  const StyledSeparator = styled.div`
23
34
  width: 0;
24
35
  height: 100%;
25
36
  margin: 0 ${(props) => props.theme.space.xxs};
26
37
  border-left: ${(props) => `${props.theme.colors.neutral[300]} 1px solid`};
38
+ ${xStyledCommonProps}
27
39
  `;
28
40
  export {
29
41
  StyledCloseButton,
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../scripts/build/transpile/react-shim.js", "../../src/styled.tsx"],
4
- "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { styled, border, truncate } from '@elliemae/ds-system';\nimport { DSButtonV2 } from '@elliemae/ds-button-v2';\nimport { Grid } from '@elliemae/ds-grid';\nimport { DSSidePanelHeaderName, DSSidePanelHeaderSlots } from './SidePanelHeaderDefinitions.js';\nexport const StyledTitle = styled(Grid, {\n name: DSSidePanelHeaderName,\n slot: DSSidePanelHeaderSlots.TITLE,\n})`\n font-size: 18px;\n font-weight: ${(props) => props.theme.fontWeights.regular};\n color: ${(props) => props.theme.colors.neutral['700']};\n ${truncate()}\n`;\n\nexport const Wrapper = styled(Grid)`\n border-bottom: ${(props) => border(props.theme.colors.neutral['300'])};\n`;\n\nexport const StyledCloseButton = styled(DSButtonV2, {\n name: DSSidePanelHeaderName,\n slot: DSSidePanelHeaderSlots.CLOSE_BUTTON,\n})``;\n\nexport const StyledSeparator = styled.div`\n width: 0;\n height: 100%;\n margin: 0 ${(props) => props.theme.space.xxs};\n border-left: ${(props) => `${props.theme.colors.neutral[300]} 1px solid`};\n`;\n"],
5
- "mappings": "AAAA,YAAY,WAAW;ACAvB,SAAS,QAAQ,QAAQ,gBAAgB;AACzC,SAAS,kBAAkB;AAC3B,SAAS,YAAY;AACrB,SAAS,uBAAuB,8BAA8B;AACvD,MAAM,cAAc,OAAO,MAAM;AAAA,EACtC,MAAM;AAAA,EACN,MAAM,uBAAuB;AAC/B,CAAC;AAAA;AAAA,iBAEgB,CAAC,UAAU,MAAM,MAAM,YAAY;AAAA,WACzC,CAAC,UAAU,MAAM,MAAM,OAAO,QAAQ,KAAK;AAAA,IAClD,SAAS;AAAA;AAGN,MAAM,UAAU,OAAO,IAAI;AAAA,mBACf,CAAC,UAAU,OAAO,MAAM,MAAM,OAAO,QAAQ,KAAK,CAAC;AAAA;AAG/D,MAAM,oBAAoB,OAAO,YAAY;AAAA,EAClD,MAAM;AAAA,EACN,MAAM,uBAAuB;AAC/B,CAAC;AAEM,MAAM,kBAAkB,OAAO;AAAA;AAAA;AAAA,cAGxB,CAAC,UAAU,MAAM,MAAM,MAAM;AAAA,iBAC1B,CAAC,UAAU,GAAG,MAAM,MAAM,OAAO,QAAQ,GAAG;AAAA;",
4
+ "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { styled, border, truncate, xStyledCommonProps } from '@elliemae/ds-system';\nimport { DSButtonV2 } from '@elliemae/ds-button-v2';\nimport { Grid } from '@elliemae/ds-grid';\nimport { DSSidePanelHeaderName, DSSidePanelHeaderSlots } from './SidePanelHeaderDefinitions.js';\nexport const StyledTitle = styled(Grid, {\n name: DSSidePanelHeaderName,\n slot: DSSidePanelHeaderSlots.TITLE,\n})`\n margin-right: ${(props) => props.theme.space.xs};\n font-size: 18px;\n font-weight: ${(props) => props.theme.fontWeights.regular};\n color: ${(props) => props.theme.colors.neutral['700']};\n ${truncate()}\n ${xStyledCommonProps}\n`;\n\nexport const Wrapper = styled(Grid, {\n name: DSSidePanelHeaderName,\n slot: DSSidePanelHeaderSlots.WRAPPER,\n})`\n padding-right: ${(props) => props.theme.space.xs};\n padding-left: ${(props) => props.theme.space.xs};\n height: ${(props) => props.theme.space.m};\n border-bottom: ${(props) => border(props.theme.colors.neutral['300'])};\n ${xStyledCommonProps}\n`;\n\nexport const StyledCloseButton = styled(DSButtonV2, {\n name: DSSidePanelHeaderName,\n slot: DSSidePanelHeaderSlots.CLOSE_BUTTON,\n})`\n ${xStyledCommonProps}\n`;\n\nexport const StyledSeparator = styled.div`\n width: 0;\n height: 100%;\n margin: 0 ${(props) => props.theme.space.xxs};\n border-left: ${(props) => `${props.theme.colors.neutral[300]} 1px solid`};\n ${xStyledCommonProps}\n`;\n"],
5
+ "mappings": "AAAA,YAAY,WAAW;ACAvB,SAAS,QAAQ,QAAQ,UAAU,0BAA0B;AAC7D,SAAS,kBAAkB;AAC3B,SAAS,YAAY;AACrB,SAAS,uBAAuB,8BAA8B;AACvD,MAAM,cAAc,OAAO,MAAM;AAAA,EACtC,MAAM;AAAA,EACN,MAAM,uBAAuB;AAC/B,CAAC;AAAA,kBACiB,CAAC,UAAU,MAAM,MAAM,MAAM;AAAA;AAAA,iBAE9B,CAAC,UAAU,MAAM,MAAM,YAAY;AAAA,WACzC,CAAC,UAAU,MAAM,MAAM,OAAO,QAAQ,KAAK;AAAA,IAClD,SAAS;AAAA,IACT;AAAA;AAGG,MAAM,UAAU,OAAO,MAAM;AAAA,EAClC,MAAM;AAAA,EACN,MAAM,uBAAuB;AAC/B,CAAC;AAAA,mBACkB,CAAC,UAAU,MAAM,MAAM,MAAM;AAAA,kBAC9B,CAAC,UAAU,MAAM,MAAM,MAAM;AAAA,YACnC,CAAC,UAAU,MAAM,MAAM,MAAM;AAAA,mBACtB,CAAC,UAAU,OAAO,MAAM,MAAM,OAAO,QAAQ,KAAK,CAAC;AAAA,IAClE;AAAA;AAGG,MAAM,oBAAoB,OAAO,YAAY;AAAA,EAClD,MAAM;AAAA,EACN,MAAM,uBAAuB;AAC/B,CAAC;AAAA,IACG;AAAA;AAGG,MAAM,kBAAkB,OAAO;AAAA;AAAA;AAAA,cAGxB,CAAC,UAAU,MAAM,MAAM,MAAM;AAAA,iBAC1B,CAAC,UAAU,GAAG,MAAM,MAAM,OAAO,QAAQ,GAAG;AAAA,IACzD;AAAA;",
6
6
  "names": []
7
7
  }
@@ -2,6 +2,7 @@ export declare const DSSidePanelHeaderName: "DSSidePanelHeader";
2
2
  export declare const DSSidePanelHeaderSlots: {
3
3
  CLOSE_BUTTON: string;
4
4
  TITLE: string;
5
+ WRAPPER: string;
5
6
  SEPARATOR: string;
6
7
  };
7
8
  export declare const DSSidePanelHeaderDataTestIds: {
@@ -1,6 +1,6 @@
1
1
  import type { WeakValidationMap } from 'react';
2
2
  import type React from 'react';
3
- import type { GlobalAttributesT, XstyledProps } from '@elliemae/ds-props-helpers';
3
+ import { type GlobalAttributesT, type XstyledProps } from '@elliemae/ds-props-helpers';
4
4
  export declare namespace DSSidePanelHeaderT {
5
5
  interface DefaultProps {
6
6
  onClose: () => void;
@@ -4,6 +4,6 @@ export declare const StyledTitle: import("styled-components").StyledComponent<im
4
4
  } & {
5
5
  theme: import("@elliemae/pui-theme").Theme;
6
6
  } & import("@elliemae/ds-system").OwnerInterface, never>;
7
- export declare const Wrapper: import("styled-components").StyledComponent<import("react").ForwardRefExoticComponent<import("@elliemae/ds-grid/dist/types/react-desc-prop-types.js").DSGridT.Props & import("react").RefAttributes<HTMLDivElement>>, import("@elliemae/ds-system").Theme, object & import("@elliemae/ds-system").OwnerInterface, never>;
8
- export declare const StyledCloseButton: import("styled-components").StyledComponent<import("react").ComponentType<import("@elliemae/ds-button-v2").DSButtonT.Props>, import("@elliemae/ds-system").Theme, object & import("@elliemae/ds-system").OwnerInterface, never>;
9
- export declare const StyledSeparator: import("styled-components").StyledComponent<"div", import("@elliemae/ds-system").Theme, object & import("@elliemae/ds-system").OwnerInterface, never>;
7
+ export declare const Wrapper: import("styled-components").StyledComponent<import("react").ForwardRefExoticComponent<import("@elliemae/ds-grid/dist/types/react-desc-prop-types.js").DSGridT.Props & import("react").RefAttributes<HTMLDivElement>>, import("@elliemae/ds-system").Theme, import("@xstyled/util").Props<import("@xstyled/system").Theme> & import("@xstyled/system").TypographyProps<import("@xstyled/system").Theme> & import("@elliemae/ds-system").BackgroundProps & import("@elliemae/ds-system").SpaceProps & import("@xstyled/system").BoxShadowProps<import("@xstyled/system").Theme> & import("@xstyled/system").FlexboxesProps<import("@xstyled/system").Theme> & import("@xstyled/system").LayoutProps<import("@xstyled/system").Theme> & import("@elliemae/ds-system").ColorProps & import("@elliemae/ds-system").OwnerInterface, never>;
8
+ export declare const StyledCloseButton: import("styled-components").StyledComponent<import("react").ComponentType<import("@elliemae/ds-button-v2").DSButtonT.Props>, import("@elliemae/ds-system").Theme, import("@xstyled/util").Props<import("@xstyled/system").Theme> & import("@xstyled/system").TypographyProps<import("@xstyled/system").Theme> & import("@elliemae/ds-system").BackgroundProps & import("@elliemae/ds-system").SpaceProps & import("@xstyled/system").BoxShadowProps<import("@xstyled/system").Theme> & import("@xstyled/system").FlexboxesProps<import("@xstyled/system").Theme> & import("@xstyled/system").LayoutProps<import("@xstyled/system").Theme> & import("@elliemae/ds-system").ColorProps & import("@elliemae/ds-system").OwnerInterface, never>;
9
+ export declare const StyledSeparator: import("styled-components").StyledComponent<"div", import("@elliemae/ds-system").Theme, import("@xstyled/util").Props<import("@xstyled/system").Theme> & import("@xstyled/system").TypographyProps<import("@xstyled/system").Theme> & import("@elliemae/ds-system").BackgroundProps & import("@elliemae/ds-system").SpaceProps & import("@xstyled/system").BoxShadowProps<import("@xstyled/system").Theme> & import("@xstyled/system").FlexboxesProps<import("@xstyled/system").Theme> & import("@xstyled/system").LayoutProps<import("@xstyled/system").Theme> & import("@elliemae/ds-system").ColorProps & import("@elliemae/ds-system").OwnerInterface, never>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@elliemae/ds-side-panel-header",
3
- "version": "3.22.0-next.22",
3
+ "version": "3.22.0-next.24",
4
4
  "license": "MIT",
5
5
  "description": "ICE MT - Dimsum - Side Panel Header",
6
6
  "files": [
@@ -57,17 +57,17 @@
57
57
  "dependencies": {
58
58
  "@elliemae/pui-theme": "~2.7.0",
59
59
  "jest-axe": "^7.0.1",
60
- "@elliemae/ds-button-v2": "3.22.0-next.22",
61
- "@elliemae/ds-icons": "3.22.0-next.22",
62
- "@elliemae/ds-grid": "3.22.0-next.22",
63
- "@elliemae/ds-props-helpers": "3.22.0-next.22",
64
- "@elliemae/ds-system": "3.22.0-next.22",
65
- "@elliemae/ds-utilities": "3.22.0-next.22"
60
+ "@elliemae/ds-button-v2": "3.22.0-next.24",
61
+ "@elliemae/ds-grid": "3.22.0-next.24",
62
+ "@elliemae/ds-props-helpers": "3.22.0-next.24",
63
+ "@elliemae/ds-system": "3.22.0-next.24",
64
+ "@elliemae/ds-icons": "3.22.0-next.24",
65
+ "@elliemae/ds-utilities": "3.22.0-next.24"
66
66
  },
67
67
  "devDependencies": {
68
68
  "@elliemae/pui-cli": "~9.0.0-next.22",
69
69
  "styled-components": "~5.3.9",
70
- "@elliemae/ds-monorepo-devops": "3.22.0-next.22"
70
+ "@elliemae/ds-monorepo-devops": "3.22.0-next.24"
71
71
  },
72
72
  "peerDependencies": {
73
73
  "lodash": "^4.17.21",