@elliemae/ds-card-navigation 3.55.0-next.24 → 3.55.0-next.26
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/DSCardNavigation.js +11 -1
- package/dist/cjs/DSCardNavigation.js.map +2 -2
- package/dist/cjs/constants/index.js +10 -2
- package/dist/cjs/constants/index.js.map +2 -2
- package/dist/cjs/index.js +1 -0
- package/dist/cjs/index.js.map +2 -2
- package/dist/cjs/parts/ActionsRegion.js +13 -4
- package/dist/cjs/parts/ActionsRegion.js.map +2 -2
- package/dist/cjs/parts/style.js +30 -6
- package/dist/cjs/parts/style.js.map +2 -2
- package/dist/cjs/parts/text-region/IconAndTextsRegion.js +9 -3
- package/dist/cjs/parts/text-region/IconAndTextsRegion.js.map +2 -2
- package/dist/cjs/parts/text-region/IconAndTextsRegionContent.js +62 -23
- package/dist/cjs/parts/text-region/IconAndTextsRegionContent.js.map +2 -2
- package/dist/esm/DSCardNavigation.js +11 -1
- package/dist/esm/DSCardNavigation.js.map +2 -2
- package/dist/esm/constants/index.js +10 -2
- package/dist/esm/constants/index.js.map +2 -2
- package/dist/esm/index.js +3 -1
- package/dist/esm/index.js.map +2 -2
- package/dist/esm/parts/ActionsRegion.js +19 -6
- package/dist/esm/parts/ActionsRegion.js.map +2 -2
- package/dist/esm/parts/style.js +30 -6
- package/dist/esm/parts/style.js.map +2 -2
- package/dist/esm/parts/text-region/IconAndTextsRegion.js +9 -3
- package/dist/esm/parts/text-region/IconAndTextsRegion.js.map +2 -2
- package/dist/esm/parts/text-region/IconAndTextsRegionContent.js +62 -23
- package/dist/esm/parts/text-region/IconAndTextsRegionContent.js.map +2 -2
- package/dist/types/constants/index.d.ts +11 -0
- package/dist/types/index.d.ts +1 -1
- package/dist/types/parts/ActionsRegion.d.ts +2 -0
- package/dist/types/parts/style.d.ts +2 -1
- package/dist/types/parts/text-region/IconAndTextsRegion.d.ts +2 -0
- package/dist/types/parts/text-region/IconAndTextsRegionContent.d.ts +2 -0
- package/package.json +16 -11
|
@@ -67,6 +67,8 @@ const DSCardNavigation = (props) => {
|
|
|
67
67
|
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
68
68
|
import_IconAndTextsRegion.IconAndTextsRegion,
|
|
69
69
|
{
|
|
70
|
+
getOwnerProps,
|
|
71
|
+
getOwnerPropsArguments,
|
|
70
72
|
title,
|
|
71
73
|
description,
|
|
72
74
|
wrapText,
|
|
@@ -76,7 +78,15 @@ const DSCardNavigation = (props) => {
|
|
|
76
78
|
hideFocusRingAroundAll
|
|
77
79
|
}
|
|
78
80
|
),
|
|
79
|
-
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
81
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
82
|
+
import_ActionsRegion.ActionsRegion,
|
|
83
|
+
{
|
|
84
|
+
getOwnerProps,
|
|
85
|
+
getOwnerPropsArguments,
|
|
86
|
+
actions,
|
|
87
|
+
instanceUid
|
|
88
|
+
}
|
|
89
|
+
)
|
|
80
90
|
]
|
|
81
91
|
}
|
|
82
92
|
);
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/DSCardNavigation.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
-
"sourcesContent": ["import { describe, useOwnerProps } from '@elliemae/ds-props-helpers';\nimport React from 'react';\nimport { useCardNavigation } from './config/useCardNavigation.js';\nimport { DSCardNavigationName } from './constants/index.js';\nimport { type DSCardNavigationT, DSCardNavigationPropTypesSchema } from './react-desc-prop-types.js';\nimport { StyledCardNavigationBoxWrapper } from './parts/style.js';\nimport { IconAndTextsRegion } from './parts/text-region/IconAndTextsRegion.js';\nimport { ActionsRegion } from './parts/ActionsRegion.js';\n\nconst DSCardNavigation: React.ComponentType<DSCardNavigationT.Props> = (props) => {\n const cardNavigationConfig = useCardNavigation(props);\n const {\n propsWithDefault,\n xstyledProps,\n globalProps,\n iconAndTextsRegionIsFocused,\n showFocusRingAroundAll,\n hideFocusRingAroundAll,\n instanceUid,\n } = cardNavigationConfig;\n const { containerProps, title, description, type, Icon, actions, wrapText } = propsWithDefault;\n\n const { getOwnerProps, getOwnerPropsArguments } = useOwnerProps<DSCardNavigationT.Props>(propsWithDefault);\n\n return (\n <StyledCardNavigationBoxWrapper\n {...globalProps}\n {...xstyledProps}\n {...containerProps}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n $isIconAndTextsRegionFocused={iconAndTextsRegionIsFocused}\n >\n <IconAndTextsRegion\n title={title}\n description={description}\n wrapText={wrapText}\n type={type}\n Icon={Icon}\n showFocusRingAroundAll={showFocusRingAroundAll}\n hideFocusRingAroundAll={hideFocusRingAroundAll}\n />\n <ActionsRegion
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADyBnB;AAzBJ,8BAAwC;AAExC,+BAAkC;AAClC,uBAAqC;AACrC,mCAAwE;AACxE,mBAA+C;AAC/C,gCAAmC;AACnC,2BAA8B;AAE9B,MAAM,mBAAiE,CAAC,UAAU;AAChF,QAAM,2BAAuB,4CAAkB,KAAK;AACpD,QAAM;AAAA,IACJ;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EACF,IAAI;AACJ,QAAM,EAAE,gBAAgB,OAAO,aAAa,MAAM,MAAM,SAAS,SAAS,IAAI;AAE9E,QAAM,EAAE,eAAe,uBAAuB,QAAI,uCAAuC,gBAAgB;AAEzG,SACE;AAAA,IAAC;AAAA;AAAA,MACE,GAAG;AAAA,MACH,GAAG;AAAA,MACH,GAAG;AAAA,MACJ;AAAA,MACA;AAAA,MACA,8BAA8B;AAAA,MAE9B;AAAA;AAAA,UAAC;AAAA;AAAA,YACC;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA;AAAA,QACF;AAAA,QACA,
|
|
4
|
+
"sourcesContent": ["import { describe, useOwnerProps } from '@elliemae/ds-props-helpers';\nimport React from 'react';\nimport { useCardNavigation } from './config/useCardNavigation.js';\nimport { DSCardNavigationName } from './constants/index.js';\nimport { type DSCardNavigationT, DSCardNavigationPropTypesSchema } from './react-desc-prop-types.js';\nimport { StyledCardNavigationBoxWrapper } from './parts/style.js';\nimport { IconAndTextsRegion } from './parts/text-region/IconAndTextsRegion.js';\nimport { ActionsRegion } from './parts/ActionsRegion.js';\n\nconst DSCardNavigation: React.ComponentType<DSCardNavigationT.Props> = (props) => {\n const cardNavigationConfig = useCardNavigation(props);\n const {\n propsWithDefault,\n xstyledProps,\n globalProps,\n iconAndTextsRegionIsFocused,\n showFocusRingAroundAll,\n hideFocusRingAroundAll,\n instanceUid,\n } = cardNavigationConfig;\n const { containerProps, title, description, type, Icon, actions, wrapText } = propsWithDefault;\n\n const { getOwnerProps, getOwnerPropsArguments } = useOwnerProps<DSCardNavigationT.Props>(propsWithDefault);\n\n return (\n <StyledCardNavigationBoxWrapper\n {...globalProps}\n {...xstyledProps}\n {...containerProps}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n $isIconAndTextsRegionFocused={iconAndTextsRegionIsFocused}\n >\n <IconAndTextsRegion\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n title={title}\n description={description}\n wrapText={wrapText}\n type={type}\n Icon={Icon}\n showFocusRingAroundAll={showFocusRingAroundAll}\n hideFocusRingAroundAll={hideFocusRingAroundAll}\n />\n <ActionsRegion\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n actions={actions}\n instanceUid={instanceUid}\n />\n </StyledCardNavigationBoxWrapper>\n );\n};\n\nDSCardNavigation.displayName = DSCardNavigationName;\nconst DSCardNavigationWithSchema = describe(DSCardNavigation);\nDSCardNavigationWithSchema.propTypes = DSCardNavigationPropTypesSchema;\n\nexport { DSCardNavigation, DSCardNavigationWithSchema };\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADyBnB;AAzBJ,8BAAwC;AAExC,+BAAkC;AAClC,uBAAqC;AACrC,mCAAwE;AACxE,mBAA+C;AAC/C,gCAAmC;AACnC,2BAA8B;AAE9B,MAAM,mBAAiE,CAAC,UAAU;AAChF,QAAM,2BAAuB,4CAAkB,KAAK;AACpD,QAAM;AAAA,IACJ;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EACF,IAAI;AACJ,QAAM,EAAE,gBAAgB,OAAO,aAAa,MAAM,MAAM,SAAS,SAAS,IAAI;AAE9E,QAAM,EAAE,eAAe,uBAAuB,QAAI,uCAAuC,gBAAgB;AAEzG,SACE;AAAA,IAAC;AAAA;AAAA,MACE,GAAG;AAAA,MACH,GAAG;AAAA,MACH,GAAG;AAAA,MACJ;AAAA,MACA;AAAA,MACA,8BAA8B;AAAA,MAE9B;AAAA;AAAA,UAAC;AAAA;AAAA,YACC;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA;AAAA,QACF;AAAA,QACA;AAAA,UAAC;AAAA;AAAA,YACC;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA;AAAA,QACF;AAAA;AAAA;AAAA,EACF;AAEJ;AAEA,iBAAiB,cAAc;AAC/B,MAAM,iCAA6B,kCAAS,gBAAgB;AAC5D,2BAA2B,YAAY;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -44,11 +44,19 @@ const CARD_NAVIGATION_SLOTS = {
|
|
|
44
44
|
ACTIONS: "actions",
|
|
45
45
|
TYPE: "type",
|
|
46
46
|
CENTRAL_CONTENT: "central-content",
|
|
47
|
-
INTERACTIVE_ELEMENT_REGION: "interactive-element-region"
|
|
47
|
+
INTERACTIVE_ELEMENT_REGION: "interactive-element-region",
|
|
48
|
+
DESCRIPTION_TEXT: "description-text",
|
|
49
|
+
TITLE_TYPOGRAPHY: "title-typography",
|
|
50
|
+
TITLE_WRAPPER: "title-wrapper",
|
|
51
|
+
CONTENT: "content",
|
|
52
|
+
BUTTON_WRAPPER: "button-wrapper",
|
|
53
|
+
ACTION_BUTTON: "action-button"
|
|
48
54
|
};
|
|
49
55
|
const CARD_NAVIGATION_DATA_TESTID = {
|
|
50
56
|
...(0, import_ds_system.slotObjectToDataTestIds)(DSCardNavigationName, CARD_NAVIGATION_SLOTS),
|
|
51
|
-
DESCRIPTION_TEXT: "ds-card-navigation--description"
|
|
57
|
+
DESCRIPTION_TEXT: "ds-card-navigation--description",
|
|
58
|
+
TITLE_TYPOGRAPHY: "ds-typography-element",
|
|
59
|
+
ACTION_BUTTON: "ds-button"
|
|
52
60
|
};
|
|
53
61
|
const CardNavigationTypes = {
|
|
54
62
|
BORROWER: "borrower",
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../src/constants/index.ts", "../../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
-
"sourcesContent": ["import { slotObjectToDataTestIds } from '@elliemae/ds-system';\n\nexport const DSCardNavigationName = 'DSCardnavigation';\n\n// we are naming this with the ${component_name}_slots convention to namespace & avoid errors on duplicate exports variables in aggregators\nexport const CARD_NAVIGATION_SLOTS = {\n ROOT: 'root',\n TITLE: 'title',\n ACTIONS: 'actions',\n TYPE: 'type',\n CENTRAL_CONTENT: 'central-content',\n INTERACTIVE_ELEMENT_REGION: 'interactive-element-region',\n} as const;\n\n// we are naming this with the ${component_name}_data_testid convention to namespace & avoid errors on duplicate exports variables in aggregators\nexport const CARD_NAVIGATION_DATA_TESTID = {\n ...slotObjectToDataTestIds(DSCardNavigationName, CARD_NAVIGATION_SLOTS),\n DESCRIPTION_TEXT: 'ds-card-navigation--description',\n};\n\nexport const CardNavigationTypes = {\n BORROWER: 'borrower',\n FINANCIAL: 'financial',\n LOAN: 'loan',\n REGULATORY: 'regulatory',\n} as const;\n\nexport const CardNavigationTypesValues = Object.values(CardNavigationTypes);\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,uBAAwC;AAEjC,MAAM,uBAAuB;AAG7B,MAAM,wBAAwB;AAAA,EACnC,MAAM;AAAA,EACN,OAAO;AAAA,EACP,SAAS;AAAA,EACT,MAAM;AAAA,EACN,iBAAiB;AAAA,EACjB,4BAA4B;
|
|
4
|
+
"sourcesContent": ["import { slotObjectToDataTestIds } from '@elliemae/ds-system';\n\nexport const DSCardNavigationName = 'DSCardnavigation';\n\n// we are naming this with the ${component_name}_slots convention to namespace & avoid errors on duplicate exports variables in aggregators\nexport const CARD_NAVIGATION_SLOTS = {\n ROOT: 'root',\n TITLE: 'title',\n ACTIONS: 'actions',\n TYPE: 'type',\n CENTRAL_CONTENT: 'central-content',\n INTERACTIVE_ELEMENT_REGION: 'interactive-element-region',\n DESCRIPTION_TEXT: 'description-text',\n TITLE_TYPOGRAPHY: 'title-typography',\n TITLE_WRAPPER: 'title-wrapper',\n CONTENT: 'content',\n BUTTON_WRAPPER: 'button-wrapper',\n ACTION_BUTTON: 'action-button',\n} as const;\n\n// we are naming this with the ${component_name}_data_testid convention to namespace & avoid errors on duplicate exports variables in aggregators\nexport const CARD_NAVIGATION_DATA_TESTID = {\n ...slotObjectToDataTestIds(DSCardNavigationName, CARD_NAVIGATION_SLOTS),\n DESCRIPTION_TEXT: 'ds-card-navigation--description',\n TITLE_TYPOGRAPHY: 'ds-typography-element',\n ACTION_BUTTON: 'ds-button',\n};\n\nexport const CardNavigationTypes = {\n BORROWER: 'borrower',\n FINANCIAL: 'financial',\n LOAN: 'loan',\n REGULATORY: 'regulatory',\n} as const;\n\nexport const CardNavigationTypesValues = Object.values(CardNavigationTypes);\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,uBAAwC;AAEjC,MAAM,uBAAuB;AAG7B,MAAM,wBAAwB;AAAA,EACnC,MAAM;AAAA,EACN,OAAO;AAAA,EACP,SAAS;AAAA,EACT,MAAM;AAAA,EACN,iBAAiB;AAAA,EACjB,4BAA4B;AAAA,EAC5B,kBAAkB;AAAA,EAClB,kBAAkB;AAAA,EAClB,eAAe;AAAA,EACf,SAAS;AAAA,EACT,gBAAgB;AAAA,EAChB,eAAe;AACjB;AAGO,MAAM,8BAA8B;AAAA,EACzC,OAAG,0CAAwB,sBAAsB,qBAAqB;AAAA,EACtE,kBAAkB;AAAA,EAClB,kBAAkB;AAAA,EAClB,eAAe;AACjB;AAEO,MAAM,sBAAsB;AAAA,EACjC,UAAU;AAAA,EACV,WAAW;AAAA,EACX,MAAM;AAAA,EACN,YAAY;AACd;AAEO,MAAM,4BAA4B,OAAO,OAAO,mBAAmB;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
package/dist/cjs/index.js
CHANGED
|
@@ -33,6 +33,7 @@ __export(index_exports, {
|
|
|
33
33
|
CardNavigationTypes: () => import_constants.CardNavigationTypes,
|
|
34
34
|
CardNavigationTypesValues: () => import_constants.CardNavigationTypesValues,
|
|
35
35
|
DSCardNavigation: () => import_DSCardNavigation2.DSCardNavigation,
|
|
36
|
+
DSCardNavigationName: () => import_constants.DSCardNavigationName,
|
|
36
37
|
DSCardNavigationWithSchema: () => import_DSCardNavigation2.DSCardNavigationWithSchema,
|
|
37
38
|
default: () => index_default
|
|
38
39
|
});
|
package/dist/cjs/index.js.map
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/index.ts", "../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
-
"sourcesContent": ["// this is a workaround to typescript error TS2742\n// https://github.com/microsoft/TypeScript/issues/47663\nimport { DSCardNavigation } from './DSCardNavigation.js';\nimport type {} from '@xstyled/system';\nexport { DSCardNavigation, DSCardNavigationWithSchema } from './DSCardNavigation.js';\nexport { type DSCardNavigationT } from './react-desc-prop-types.js';\nexport {\n CARD_NAVIGATION_SLOTS,\n CARD_NAVIGATION_DATA_TESTID,\n CardNavigationTypesValues,\n CardNavigationTypes,\n} from './constants/index.js';\n\nexport default DSCardNavigation;\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADEvB,8BAAiC;AAEjC,IAAAA,2BAA6D;AAE7D,
|
|
4
|
+
"sourcesContent": ["// this is a workaround to typescript error TS2742\n// https://github.com/microsoft/TypeScript/issues/47663\nimport { DSCardNavigation } from './DSCardNavigation.js';\nimport type {} from '@xstyled/system';\nexport { DSCardNavigation, DSCardNavigationWithSchema } from './DSCardNavigation.js';\nexport { type DSCardNavigationT } from './react-desc-prop-types.js';\nexport {\n CARD_NAVIGATION_SLOTS,\n CARD_NAVIGATION_DATA_TESTID,\n CardNavigationTypesValues,\n CardNavigationTypes,\n DSCardNavigationName,\n} from './constants/index.js';\n\nexport default DSCardNavigation;\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADEvB,8BAAiC;AAEjC,IAAAA,2BAA6D;AAE7D,uBAMO;AAEP,IAAO,gBAAQ;",
|
|
6
6
|
"names": ["import_DSCardNavigation"]
|
|
7
7
|
}
|
|
@@ -36,22 +36,31 @@ var import_jsx_runtime = require("react/jsx-runtime");
|
|
|
36
36
|
var import_ds_button_v2 = require("@elliemae/ds-button-v2");
|
|
37
37
|
var import_ds_icons = require("@elliemae/ds-icons");
|
|
38
38
|
var import_style = require("./style.js");
|
|
39
|
-
const ActionsRegion = ({
|
|
39
|
+
const ActionsRegion = ({
|
|
40
|
+
actions,
|
|
41
|
+
instanceUid,
|
|
42
|
+
getOwnerProps,
|
|
43
|
+
getOwnerPropsArguments
|
|
44
|
+
}) => {
|
|
40
45
|
if (actions.length === 0) return null;
|
|
41
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_style.StyledCardNavigationActions, { children: actions.map(({ icon, Icon, onClick, ...unexpectedButPreviouslySupportedOtherProps }, index) => {
|
|
46
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_style.StyledCardNavigationActions, { getOwnerProps, getOwnerPropsArguments, children: actions.map(({ icon, Icon, onClick, ...unexpectedButPreviouslySupportedOtherProps }, index) => {
|
|
42
47
|
const defaultIconJSX = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_ds_icons.MoreOptionsVert, { "aria-label": "More options" });
|
|
43
48
|
const iconJSX = icon ?? defaultIconJSX;
|
|
44
49
|
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
45
|
-
import_style.
|
|
50
|
+
import_style.StyledCardNavigationButtonWrapper,
|
|
46
51
|
{
|
|
52
|
+
getOwnerProps,
|
|
53
|
+
getOwnerPropsArguments,
|
|
47
54
|
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
48
|
-
|
|
55
|
+
import_style.StyledCardNavigationActionButton,
|
|
49
56
|
{
|
|
50
57
|
onClick,
|
|
51
58
|
"aria-label": "More options",
|
|
52
59
|
...unexpectedButPreviouslySupportedOtherProps,
|
|
53
60
|
buttonType: import_ds_button_v2.BUTTON_TYPES.ICON,
|
|
54
61
|
size: import_ds_button_v2.BUTTON_SIZES.L,
|
|
62
|
+
getOwnerProps,
|
|
63
|
+
getOwnerPropsArguments,
|
|
55
64
|
children: Icon ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Icon, {}) : iconJSX
|
|
56
65
|
}
|
|
57
66
|
)
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../src/parts/ActionsRegion.tsx", "../../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
-
"sourcesContent": ["import { BUTTON_SIZES, BUTTON_TYPES
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;
|
|
4
|
+
"sourcesContent": ["import { BUTTON_SIZES, BUTTON_TYPES } from '@elliemae/ds-button-v2';\nimport { MoreOptionsVert } from '@elliemae/ds-icons';\nimport React from 'react';\nimport type { DSCardNavigationT } from '../react-desc-prop-types.js';\nimport {\n StyledCardNavigationButtonWrapper,\n StyledCardNavigationActions,\n StyledCardNavigationActionButton,\n} from './style.js';\n\ninterface ActionRegionProps {\n actions: DSCardNavigationT.InternalProps['actions'];\n instanceUid: string;\n getOwnerProps?: () => object;\n getOwnerPropsArguments?: () => object;\n}\n\nexport const ActionsRegion: React.ComponentType<ActionRegionProps> = ({\n actions,\n instanceUid,\n getOwnerProps,\n getOwnerPropsArguments,\n}) => {\n if (actions.length === 0) return null;\n return (\n <StyledCardNavigationActions getOwnerProps={getOwnerProps} getOwnerPropsArguments={getOwnerPropsArguments}>\n {actions.map(({ icon, Icon, onClick, ...unexpectedButPreviouslySupportedOtherProps }, index) => {\n const defaultIconJSX = <MoreOptionsVert aria-label=\"More options\" />;\n const iconJSX = icon ?? defaultIconJSX;\n return (\n <StyledCardNavigationButtonWrapper\n // eslint-disable-next-line react/no-array-index-key\n key={`${instanceUid}-${index}`}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <StyledCardNavigationActionButton\n onClick={onClick}\n aria-label=\"More options\"\n {...unexpectedButPreviouslySupportedOtherProps}\n buttonType={BUTTON_TYPES.ICON}\n size={BUTTON_SIZES.L}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n {Icon ? <Icon /> : iconJSX}\n </StyledCardNavigationActionButton>\n </StyledCardNavigationButtonWrapper>\n );\n })}\n </StyledCardNavigationActions>\n );\n};\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;AD2BQ;AA3B/B,0BAA2C;AAC3C,sBAAgC;AAGhC,mBAIO;AASA,MAAM,gBAAwD,CAAC;AAAA,EACpE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,MAAM;AACJ,MAAI,QAAQ,WAAW,EAAG,QAAO;AACjC,SACE,4CAAC,4CAA4B,eAA8B,wBACxD,kBAAQ,IAAI,CAAC,EAAE,MAAM,MAAM,SAAS,GAAG,2CAA2C,GAAG,UAAU;AAC9F,UAAM,iBAAiB,4CAAC,mCAAgB,cAAW,gBAAe;AAClE,UAAM,UAAU,QAAQ;AACxB,WACE;AAAA,MAAC;AAAA;AAAA,QAGC;AAAA,QACA;AAAA,QAEA;AAAA,UAAC;AAAA;AAAA,YACC;AAAA,YACA,cAAW;AAAA,YACV,GAAG;AAAA,YACJ,YAAY,iCAAa;AAAA,YACzB,MAAM,iCAAa;AAAA,YACnB;AAAA,YACA;AAAA,YAEC,iBAAO,4CAAC,QAAK,IAAK;AAAA;AAAA,QACrB;AAAA;AAAA,MAdK,GAAG,WAAW,IAAI,KAAK;AAAA,IAe9B;AAAA,EAEJ,CAAC,GACH;AAEJ;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
package/dist/cjs/parts/style.js
CHANGED
|
@@ -28,9 +28,10 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
|
|
|
28
28
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
29
|
var style_exports = {};
|
|
30
30
|
__export(style_exports, {
|
|
31
|
-
|
|
31
|
+
StyledCardNavigationActionButton: () => StyledCardNavigationActionButton,
|
|
32
32
|
StyledCardNavigationActions: () => StyledCardNavigationActions,
|
|
33
33
|
StyledCardNavigationBoxWrapper: () => StyledCardNavigationBoxWrapper,
|
|
34
|
+
StyledCardNavigationButtonWrapper: () => StyledCardNavigationButtonWrapper,
|
|
34
35
|
StyledCardNavigationCentralContent: () => StyledCardNavigationCentralContent,
|
|
35
36
|
StyledCardNavigationContent: () => StyledCardNavigationContent,
|
|
36
37
|
StyledCardNavigationContentTitle: () => StyledCardNavigationContentTitle,
|
|
@@ -45,12 +46,17 @@ var React = __toESM(require("react"));
|
|
|
45
46
|
var import_ds_grid = require("@elliemae/ds-grid");
|
|
46
47
|
var import_ds_system = require("@elliemae/ds-system");
|
|
47
48
|
var import_ds_typography = require("@elliemae/ds-typography");
|
|
49
|
+
var import_ds_button_v2 = require("@elliemae/ds-button-v2");
|
|
48
50
|
var import_constants = require("../constants/index.js");
|
|
49
51
|
const StyledCardNavigationContentTitle = (0, import_ds_system.styled)("div", {
|
|
50
52
|
name: import_constants.DSCardNavigationName,
|
|
51
53
|
slot: import_constants.CARD_NAVIGATION_SLOTS.TITLE
|
|
52
54
|
})``;
|
|
53
|
-
const StyledTitleTypography = (0, import_ds_system.styled)(import_ds_typography.DSTypography
|
|
55
|
+
const StyledTitleTypography = (0, import_ds_system.styled)(import_ds_typography.DSTypography, {
|
|
56
|
+
name: import_constants.DSCardNavigationName,
|
|
57
|
+
slot: import_constants.CARD_NAVIGATION_SLOTS.TITLE_TYPOGRAPHY,
|
|
58
|
+
preserveLegacyDataTestId: true
|
|
59
|
+
})`
|
|
54
60
|
color: ${(props) => props.theme.colors.neutral["700"]};
|
|
55
61
|
font-weight: ${(props) => props.theme.fontWeights.semibold};
|
|
56
62
|
font-size: 1.3846rem; // 18px -> 18/13 = 1.3846rem
|
|
@@ -59,7 +65,11 @@ const StyledTitleTypography = (0, import_ds_system.styled)(import_ds_typography.
|
|
|
59
65
|
font-size: 1.125rem; // 18px -> 18/16 = 1.125rem
|
|
60
66
|
}
|
|
61
67
|
`;
|
|
62
|
-
const StyledDescriptionTypography = (0, import_ds_system.styled)(import_ds_typography.DSTypography
|
|
68
|
+
const StyledDescriptionTypography = (0, import_ds_system.styled)(import_ds_typography.DSTypography, {
|
|
69
|
+
name: import_constants.DSCardNavigationName,
|
|
70
|
+
slot: import_constants.CARD_NAVIGATION_SLOTS.DESCRIPTION_TEXT,
|
|
71
|
+
preserveLegacyDataTestId: true
|
|
72
|
+
})`
|
|
63
73
|
color: ${(props) => props.theme.colors.neutral["500"]};
|
|
64
74
|
font-size: 0.923rem; // 12px -> 12/13 = 0.923rem
|
|
65
75
|
|
|
@@ -67,10 +77,16 @@ const StyledDescriptionTypography = (0, import_ds_system.styled)(import_ds_typog
|
|
|
67
77
|
font-size: 0.8775rem; // 12px -> 10.5/12 = 0.8775rem
|
|
68
78
|
}
|
|
69
79
|
`;
|
|
70
|
-
const StyledCardNavigationContentTitleWrapper = import_ds_system.styled
|
|
80
|
+
const StyledCardNavigationContentTitleWrapper = (0, import_ds_system.styled)("div", {
|
|
81
|
+
name: import_constants.DSCardNavigationName,
|
|
82
|
+
slot: import_constants.CARD_NAVIGATION_SLOTS.TITLE_WRAPPER
|
|
83
|
+
})`
|
|
71
84
|
width: 100%;
|
|
72
85
|
`;
|
|
73
|
-
const StyledCardNavigationContent = import_ds_system.styled
|
|
86
|
+
const StyledCardNavigationContent = (0, import_ds_system.styled)("div", {
|
|
87
|
+
name: import_constants.DSCardNavigationName,
|
|
88
|
+
slot: import_constants.CARD_NAVIGATION_SLOTS.CONTENT
|
|
89
|
+
})`
|
|
74
90
|
display: flex;
|
|
75
91
|
align-items: center;
|
|
76
92
|
flex: 1;
|
|
@@ -150,7 +166,10 @@ const StyledCardNavigationActions = (0, import_ds_system.styled)("div", {
|
|
|
150
166
|
align-items: center;
|
|
151
167
|
gap: ${(props) => props.theme.space.xs};
|
|
152
168
|
`;
|
|
153
|
-
const
|
|
169
|
+
const StyledCardNavigationButtonWrapper = (0, import_ds_system.styled)("div", {
|
|
170
|
+
name: import_constants.DSCardNavigationName,
|
|
171
|
+
slot: import_constants.CARD_NAVIGATION_SLOTS.BUTTON_WRAPPER
|
|
172
|
+
})`
|
|
154
173
|
span,
|
|
155
174
|
svg {
|
|
156
175
|
height: ${({ theme }) => theme.space.s};
|
|
@@ -173,4 +192,9 @@ const StyledGridTextContainer = (0, import_ds_system.styled)("div", {
|
|
|
173
192
|
}
|
|
174
193
|
cursor: pointer;
|
|
175
194
|
`;
|
|
195
|
+
const StyledCardNavigationActionButton = (0, import_ds_system.styled)(import_ds_button_v2.DSButtonV3, {
|
|
196
|
+
name: import_constants.DSCardNavigationName,
|
|
197
|
+
slot: import_constants.CARD_NAVIGATION_SLOTS.ACTION_BUTTON,
|
|
198
|
+
preserveLegacyDataTestId: true
|
|
199
|
+
})``;
|
|
176
200
|
//# sourceMappingURL=style.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../src/parts/style.tsx", "../../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
-
"sourcesContent": ["import { Grid } from '@elliemae/ds-grid';\nimport { css, styled } from '@elliemae/ds-system';\nimport { DSTypography } from '@elliemae/ds-typography';\nimport { CARD_NAVIGATION_SLOTS, CardNavigationTypes, DSCardNavigationName } from '../constants/index.js';\n\nexport const StyledCardNavigationContentTitle = styled('div', {\n name: DSCardNavigationName,\n slot: CARD_NAVIGATION_SLOTS.TITLE,\n})``;\n\nexport const StyledTitleTypography = styled(DSTypography)`\n color: ${(props) => props.theme.colors.neutral['700']};\n font-weight: ${(props) => props.theme.fontWeights.semibold};\n font-size: 1.3846rem; // 18px -> 18/13 = 1.3846rem\n\n @media (max-width: ${({ theme }) => theme.breakpoints.small}) {\n font-size: 1.125rem; // 18px -> 18/16 = 1.125rem\n }\n`;\n\nexport const StyledDescriptionTypography = styled(DSTypography)`\n color: ${(props) => props.theme.colors.neutral['500']};\n font-size: 0.923rem; // 12px -> 12/13 = 0.923rem\n\n @media (max-width: ${({ theme }) => theme.breakpoints.small}) {\n font-size: 0.8775rem; // 12px -> 10.5/12 = 0.8775rem\n }\n`;\n\nexport const StyledCardNavigationContentTitleWrapper = styled.
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,qBAAqB;AACrB,uBAA4B;AAC5B,2BAA6B;AAC7B,uBAAiF;AAE1E,MAAM,uCAAmC,yBAAO,OAAO;AAAA,EAC5D,MAAM;AAAA,EACN,MAAM,uCAAsB;AAC9B,CAAC;AAEM,MAAM,4BAAwB,yBAAO,
|
|
4
|
+
"sourcesContent": ["import { Grid } from '@elliemae/ds-grid';\nimport { css, styled } from '@elliemae/ds-system';\nimport { DSTypography } from '@elliemae/ds-typography';\nimport { DSButtonV3 } from '@elliemae/ds-button-v2';\nimport { CARD_NAVIGATION_SLOTS, CardNavigationTypes, DSCardNavigationName } from '../constants/index.js';\n\nexport const StyledCardNavigationContentTitle = styled('div', {\n name: DSCardNavigationName,\n slot: CARD_NAVIGATION_SLOTS.TITLE,\n})``;\n\nexport const StyledTitleTypography = styled(DSTypography, {\n name: DSCardNavigationName,\n slot: CARD_NAVIGATION_SLOTS.TITLE_TYPOGRAPHY,\n preserveLegacyDataTestId: true,\n})`\n color: ${(props) => props.theme.colors.neutral['700']};\n font-weight: ${(props) => props.theme.fontWeights.semibold};\n font-size: 1.3846rem; // 18px -> 18/13 = 1.3846rem\n\n @media (max-width: ${({ theme }) => theme.breakpoints.small}) {\n font-size: 1.125rem; // 18px -> 18/16 = 1.125rem\n }\n`;\n\nexport const StyledDescriptionTypography = styled(DSTypography, {\n name: DSCardNavigationName,\n slot: CARD_NAVIGATION_SLOTS.DESCRIPTION_TEXT,\n preserveLegacyDataTestId: true,\n})`\n color: ${(props) => props.theme.colors.neutral['500']};\n font-size: 0.923rem; // 12px -> 12/13 = 0.923rem\n\n @media (max-width: ${({ theme }) => theme.breakpoints.small}) {\n font-size: 0.8775rem; // 12px -> 10.5/12 = 0.8775rem\n }\n`;\n\nexport const StyledCardNavigationContentTitleWrapper = styled('div', {\n name: DSCardNavigationName,\n slot: CARD_NAVIGATION_SLOTS.TITLE_WRAPPER,\n})`\n width: 100%;\n`;\n\nexport const StyledCardNavigationContent = styled('div', {\n name: DSCardNavigationName,\n slot: CARD_NAVIGATION_SLOTS.CONTENT,\n})<{ wrapText?: boolean }>`\n display: flex;\n align-items: center;\n flex: 1;\n width: 100%;\n`;\n\nexport const StyledCardNavigationCentralContent = styled(Grid, {\n slot: CARD_NAVIGATION_SLOTS.CENTRAL_CONTENT,\n name: DSCardNavigationName,\n})<{ wrapText?: boolean; AnyOverFlow?: boolean }>`\n padding: 0 ${(props) => props.theme.space.xs};\n`;\ninterface StyledCardNavigationBoxWrapperProps {\n fluid?: boolean;\n}\n\nexport const StyledCardNavigationBoxWrapper = styled('div', {\n name: DSCardNavigationName,\n slot: CARD_NAVIGATION_SLOTS.ROOT,\n})<StyledCardNavigationBoxWrapperProps & { $isIconAndTextsRegionFocused?: boolean }>`\n min-width: 240px;\n min-height: 64px;\n width: 337px;\n display: flex;\n flex-direction: row;\n flex-wrap: nowrap;\n box-shadow: 0 1px 4px 0px rgba(37, 41, 47, 0.5);\n border-radius: 2px;\n position: relative;\n outline: none;\n\n ${(props) => (props.fluid ? 'width: 100%' : '')};\n @media (max-width: ${(props) => props.theme.breakpoints.small}) {\n width: ${(props) => (props.fluid ? 'width: 100%' : '414px')};\n }\n\n :after {\n display: block;\n content: '';\n position: absolute;\n height: 100%;\n width: 100%;\n top: 0;\n left: 0;\n border: solid ${(props) => props.theme.space.xxs} transparent;\n border-radius: 2px;\n pointer-events: none;\n }\n &:hover {\n box-shadow: 0 3px 8px 0px rgba(37, 41, 47, 0.4);\n outline-offset: 2px;\n }\n\n ${(props) =>\n props.$isIconAndTextsRegionFocused\n ? css`\n outline: 2px solid ${props.theme.colors.brand['700']};\n outline-offset: 2px;\n `\n : css``}\n`;\n\ninterface StyledCardNavigationIconProps {\n $type: (typeof CardNavigationTypes)[keyof typeof CardNavigationTypes];\n}\n\nexport const StyledCardNavigationIcon = styled('div', {\n name: DSCardNavigationName,\n slot: CARD_NAVIGATION_SLOTS.TYPE,\n})<StyledCardNavigationIconProps>`\n min-width: 64px;\n min-height: 64px;\n height: 100%;\n border-top-left-radius: 2px;\n border-bottom-left-radius: 2px;\n padding: 0 ${(props) => props.theme.space.xs};\n display: flex;\n align-items: center;\n justify-content: center;\n fill: #ffffff;\n background-color: ${({ $type }) =>\n ($type === CardNavigationTypes.BORROWER && '#32aad1') ||\n ($type === CardNavigationTypes.FINANCIAL && '#1ba88d') ||\n ($type === CardNavigationTypes.LOAN && '#8e49b2') ||\n ($type === CardNavigationTypes.REGULATORY && '#db5575') ||\n '#32aad1'};\n`;\n\nexport const StyledCardNavigationActions = styled('div', {\n name: DSCardNavigationName,\n slot: CARD_NAVIGATION_SLOTS.ACTIONS,\n})`\n padding: 0 ${(props) => props.theme.space.xs};\n display: flex;\n flex-direction: row;\n align-items: center;\n gap: ${(props) => props.theme.space.xs};\n`;\n\nexport const StyledCardNavigationButtonWrapper = styled('div', {\n name: DSCardNavigationName,\n slot: CARD_NAVIGATION_SLOTS.BUTTON_WRAPPER,\n})`\n span,\n svg {\n height: ${({ theme }) => theme.space.s};\n width: ${({ theme }) => theme.space.s};\n fill: ${({ theme }) => theme.colors.neutral[500]};\n }\n`;\n\nexport const StyledGridTextContainer = styled('div', {\n name: DSCardNavigationName,\n slot: CARD_NAVIGATION_SLOTS.INTERACTIVE_ELEMENT_REGION,\n})`\n display: grid;\n grid-template-columns: max-content auto;\n align-items: center;\n min-width: 0;\n width: 100%;\n overflow: hidden;\n &:focus {\n outline: none;\n }\n cursor: pointer;\n`;\n\nexport const StyledCardNavigationActionButton = styled(DSButtonV3, {\n name: DSCardNavigationName,\n slot: CARD_NAVIGATION_SLOTS.ACTION_BUTTON,\n preserveLegacyDataTestId: true,\n})``;\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,qBAAqB;AACrB,uBAA4B;AAC5B,2BAA6B;AAC7B,0BAA2B;AAC3B,uBAAiF;AAE1E,MAAM,uCAAmC,yBAAO,OAAO;AAAA,EAC5D,MAAM;AAAA,EACN,MAAM,uCAAsB;AAC9B,CAAC;AAEM,MAAM,4BAAwB,yBAAO,mCAAc;AAAA,EACxD,MAAM;AAAA,EACN,MAAM,uCAAsB;AAAA,EAC5B,0BAA0B;AAC5B,CAAC;AAAA,WACU,CAAC,UAAU,MAAM,MAAM,OAAO,QAAQ,KAAK,CAAC;AAAA,iBACtC,CAAC,UAAU,MAAM,MAAM,YAAY,QAAQ;AAAA;AAAA;AAAA,uBAGrC,CAAC,EAAE,MAAM,MAAM,MAAM,YAAY,KAAK;AAAA;AAAA;AAAA;AAKtD,MAAM,kCAA8B,yBAAO,mCAAc;AAAA,EAC9D,MAAM;AAAA,EACN,MAAM,uCAAsB;AAAA,EAC5B,0BAA0B;AAC5B,CAAC;AAAA,WACU,CAAC,UAAU,MAAM,MAAM,OAAO,QAAQ,KAAK,CAAC;AAAA;AAAA;AAAA,uBAGhC,CAAC,EAAE,MAAM,MAAM,MAAM,YAAY,KAAK;AAAA;AAAA;AAAA;AAKtD,MAAM,8CAA0C,yBAAO,OAAO;AAAA,EACnE,MAAM;AAAA,EACN,MAAM,uCAAsB;AAC9B,CAAC;AAAA;AAAA;AAIM,MAAM,kCAA8B,yBAAO,OAAO;AAAA,EACvD,MAAM;AAAA,EACN,MAAM,uCAAsB;AAC9B,CAAC;AAAA;AAAA;AAAA;AAAA;AAAA;AAOM,MAAM,yCAAqC,yBAAO,qBAAM;AAAA,EAC7D,MAAM,uCAAsB;AAAA,EAC5B,MAAM;AACR,CAAC;AAAA,eACc,CAAC,UAAU,MAAM,MAAM,MAAM,EAAE;AAAA;AAMvC,MAAM,qCAAiC,yBAAO,OAAO;AAAA,EAC1D,MAAM;AAAA,EACN,MAAM,uCAAsB;AAC9B,CAAC;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAYG,CAAC,UAAW,MAAM,QAAQ,gBAAgB,EAAG;AAAA,uBAC1B,CAAC,UAAU,MAAM,MAAM,YAAY,KAAK;AAAA,aAClD,CAAC,UAAW,MAAM,QAAQ,gBAAgB,OAAQ;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,oBAW3C,CAAC,UAAU,MAAM,MAAM,MAAM,GAAG;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAShD,CAAC,UACD,MAAM,+BACF;AAAA,+BACuB,MAAM,MAAM,OAAO,MAAM,KAAK,CAAC;AAAA;AAAA,YAGtD,sBAAK;AAAA;AAON,MAAM,+BAA2B,yBAAO,OAAO;AAAA,EACpD,MAAM;AAAA,EACN,MAAM,uCAAsB;AAC9B,CAAC;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,eAMc,CAAC,UAAU,MAAM,MAAM,MAAM,EAAE;AAAA;AAAA;AAAA;AAAA;AAAA,sBAKxB,CAAC,EAAE,MAAM,MAC1B,UAAU,qCAAoB,YAAY,aAC1C,UAAU,qCAAoB,aAAa,aAC3C,UAAU,qCAAoB,QAAQ,aACtC,UAAU,qCAAoB,cAAc,aAC7C,SAAS;AAAA;AAGN,MAAM,kCAA8B,yBAAO,OAAO;AAAA,EACvD,MAAM;AAAA,EACN,MAAM,uCAAsB;AAC9B,CAAC;AAAA,eACc,CAAC,UAAU,MAAM,MAAM,MAAM,EAAE;AAAA;AAAA;AAAA;AAAA,SAIrC,CAAC,UAAU,MAAM,MAAM,MAAM,EAAE;AAAA;AAGjC,MAAM,wCAAoC,yBAAO,OAAO;AAAA,EAC7D,MAAM;AAAA,EACN,MAAM,uCAAsB;AAC9B,CAAC;AAAA;AAAA;AAAA,cAGa,CAAC,EAAE,MAAM,MAAM,MAAM,MAAM,CAAC;AAAA,aAC7B,CAAC,EAAE,MAAM,MAAM,MAAM,MAAM,CAAC;AAAA,YAC7B,CAAC,EAAE,MAAM,MAAM,MAAM,OAAO,QAAQ,GAAG,CAAC;AAAA;AAAA;AAI7C,MAAM,8BAA0B,yBAAO,OAAO;AAAA,EACnD,MAAM;AAAA,EACN,MAAM,uCAAsB;AAC9B,CAAC;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAaM,MAAM,uCAAmC,yBAAO,gCAAY;AAAA,EACjE,MAAM;AAAA,EACN,MAAM,uCAAsB;AAAA,EAC5B,0BAA0B;AAC5B,CAAC;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -50,7 +50,9 @@ const IconAndTextsRegion = ({
|
|
|
50
50
|
type,
|
|
51
51
|
Icon,
|
|
52
52
|
showFocusRingAroundAll,
|
|
53
|
-
hideFocusRingAroundAll
|
|
53
|
+
hideFocusRingAroundAll,
|
|
54
|
+
getOwnerProps,
|
|
55
|
+
getOwnerPropsArguments
|
|
54
56
|
}) => {
|
|
55
57
|
const [isTitleTruncating, setIsTitleTruncating] = import_react.default.useState(false);
|
|
56
58
|
const [isDescriptionTruncating, setIsDescriptionTruncating] = import_react.default.useState(false);
|
|
@@ -80,7 +82,9 @@ const IconAndTextsRegion = ({
|
|
|
80
82
|
titleHandleRef,
|
|
81
83
|
descriptionHandleRef,
|
|
82
84
|
showFocusRingAroundAll,
|
|
83
|
-
hideFocusRingAroundAll
|
|
85
|
+
hideFocusRingAroundAll,
|
|
86
|
+
getOwnerProps,
|
|
87
|
+
getOwnerPropsArguments
|
|
84
88
|
}
|
|
85
89
|
) });
|
|
86
90
|
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
@@ -94,7 +98,9 @@ const IconAndTextsRegion = ({
|
|
|
94
98
|
titleHandleRef,
|
|
95
99
|
descriptionHandleRef,
|
|
96
100
|
showFocusRingAroundAll,
|
|
97
|
-
hideFocusRingAroundAll
|
|
101
|
+
hideFocusRingAroundAll,
|
|
102
|
+
getOwnerProps,
|
|
103
|
+
getOwnerPropsArguments
|
|
98
104
|
}
|
|
99
105
|
);
|
|
100
106
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../src/parts/text-region/IconAndTextsRegion.tsx", "../../../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
-
"sourcesContent": ["import { Grid } from '@elliemae/ds-grid';\nimport { useOnOverflowChange } from '@elliemae/ds-hooks-on-overflow-change';\nimport type { DSTooltipV3T } from '@elliemae/ds-tooltip-v3';\nimport { DSTooltipV3 } from '@elliemae/ds-tooltip-v3';\nimport { DSTypography, TYPOGRAPHY_VARIANTS } from '@elliemae/ds-typography';\nimport React from 'react';\nimport type { DSCardNavigationT } from '../../react-desc-prop-types.js';\nimport { IconAndTextsRegionContent } from './IconAndTextsRegionContent.js';\n\ntype TooltipTextProps = DSTooltipV3T.CustomInterface<{\n title: string;\n description: string;\n}>;\n\nconst TooltipText: React.ComponentType<TooltipTextProps> = ({ title, description }) => (\n <Grid>\n <DSTypography variant={TYPOGRAPHY_VARIANTS.H5_ARTICLE}>{title}</DSTypography>\n <DSTypography variant={TYPOGRAPHY_VARIANTS.B1}>{description}</DSTypography>\n </Grid>\n);\n\ninterface IconAndTextsRegionProps {\n title: DSCardNavigationT.InternalProps['title'];\n description: DSCardNavigationT.InternalProps['description'];\n wrapText: DSCardNavigationT.InternalProps['wrapText'];\n type: DSCardNavigationT.InternalProps['type'];\n Icon: DSCardNavigationT.InternalProps['Icon'];\n showFocusRingAroundAll: React.FocusEventHandler<HTMLDivElement>;\n hideFocusRingAroundAll: React.FocusEventHandler<HTMLDivElement>;\n}\n\nexport const IconAndTextsRegion: React.ComponentType<IconAndTextsRegionProps> = ({\n title,\n description,\n wrapText,\n type,\n Icon,\n showFocusRingAroundAll,\n hideFocusRingAroundAll,\n}) => {\n const [isTitleTruncating, setIsTitleTruncating] = React.useState(false);\n const [isDescriptionTruncating, setIsDescriptionTruncating] = React.useState(false);\n\n const AnyOverFlow = isTitleTruncating || isDescriptionTruncating;\n\n const { handleRef: titleHandleRef } = useOnOverflowChange({\n onOverflowStateChange: setIsTitleTruncating,\n });\n\n const { handleRef: descriptionHandleRef } = useOnOverflowChange({\n onOverflowStateChange: setIsDescriptionTruncating,\n });\n const TooltipTextProps = React.useMemo(\n () => ({\n title,\n description,\n }),\n [title, description],\n );\n\n if (AnyOverFlow)\n return (\n <DSTooltipV3<TooltipTextProps> Text={TooltipText} textProps={TooltipTextProps}>\n <IconAndTextsRegionContent\n title={title}\n description={description}\n wrapText={wrapText}\n type={type}\n Icon={Icon}\n titleHandleRef={titleHandleRef}\n descriptionHandleRef={descriptionHandleRef}\n showFocusRingAroundAll={showFocusRingAroundAll}\n hideFocusRingAroundAll={hideFocusRingAroundAll}\n />\n </DSTooltipV3>\n );\n return (\n <IconAndTextsRegionContent\n title={title}\n description={description}\n wrapText={wrapText}\n type={type}\n Icon={Icon}\n titleHandleRef={titleHandleRef}\n descriptionHandleRef={descriptionHandleRef}\n showFocusRingAroundAll={showFocusRingAroundAll}\n hideFocusRingAroundAll={hideFocusRingAroundAll}\n />\n );\n};\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADerB;AAfF,qBAAqB;AACrB,yCAAoC;AAEpC,2BAA4B;AAC5B,2BAAkD;AAClD,mBAAkB;AAElB,uCAA0C;AAO1C,MAAM,cAAqD,CAAC,EAAE,OAAO,YAAY,MAC/E,6CAAC,uBACC;AAAA,8CAAC,qCAAa,SAAS,yCAAoB,YAAa,iBAAM;AAAA,EAC9D,4CAAC,qCAAa,SAAS,yCAAoB,IAAK,uBAAY;AAAA,GAC9D;
|
|
4
|
+
"sourcesContent": ["import { Grid } from '@elliemae/ds-grid';\nimport { useOnOverflowChange } from '@elliemae/ds-hooks-on-overflow-change';\nimport type { DSTooltipV3T } from '@elliemae/ds-tooltip-v3';\nimport { DSTooltipV3 } from '@elliemae/ds-tooltip-v3';\nimport { DSTypography, TYPOGRAPHY_VARIANTS } from '@elliemae/ds-typography';\nimport React from 'react';\nimport type { DSCardNavigationT } from '../../react-desc-prop-types.js';\nimport { IconAndTextsRegionContent } from './IconAndTextsRegionContent.js';\n\ntype TooltipTextProps = DSTooltipV3T.CustomInterface<{\n title: string;\n description: string;\n}>;\n\nconst TooltipText: React.ComponentType<TooltipTextProps> = ({ title, description }) => (\n <Grid>\n <DSTypography variant={TYPOGRAPHY_VARIANTS.H5_ARTICLE}>{title}</DSTypography>\n <DSTypography variant={TYPOGRAPHY_VARIANTS.B1}>{description}</DSTypography>\n </Grid>\n);\n\ninterface IconAndTextsRegionProps {\n title: DSCardNavigationT.InternalProps['title'];\n description: DSCardNavigationT.InternalProps['description'];\n wrapText: DSCardNavigationT.InternalProps['wrapText'];\n type: DSCardNavigationT.InternalProps['type'];\n Icon: DSCardNavigationT.InternalProps['Icon'];\n showFocusRingAroundAll: React.FocusEventHandler<HTMLDivElement>;\n hideFocusRingAroundAll: React.FocusEventHandler<HTMLDivElement>;\n getOwnerProps?: () => object;\n getOwnerPropsArguments?: () => object;\n}\n\nexport const IconAndTextsRegion: React.ComponentType<IconAndTextsRegionProps> = ({\n title,\n description,\n wrapText,\n type,\n Icon,\n showFocusRingAroundAll,\n hideFocusRingAroundAll,\n getOwnerProps,\n getOwnerPropsArguments,\n}) => {\n const [isTitleTruncating, setIsTitleTruncating] = React.useState(false);\n const [isDescriptionTruncating, setIsDescriptionTruncating] = React.useState(false);\n\n const AnyOverFlow = isTitleTruncating || isDescriptionTruncating;\n\n const { handleRef: titleHandleRef } = useOnOverflowChange({\n onOverflowStateChange: setIsTitleTruncating,\n });\n\n const { handleRef: descriptionHandleRef } = useOnOverflowChange({\n onOverflowStateChange: setIsDescriptionTruncating,\n });\n const TooltipTextProps = React.useMemo(\n () => ({\n title,\n description,\n }),\n [title, description],\n );\n\n if (AnyOverFlow)\n return (\n <DSTooltipV3<TooltipTextProps> Text={TooltipText} textProps={TooltipTextProps}>\n <IconAndTextsRegionContent\n title={title}\n description={description}\n wrapText={wrapText}\n type={type}\n Icon={Icon}\n titleHandleRef={titleHandleRef}\n descriptionHandleRef={descriptionHandleRef}\n showFocusRingAroundAll={showFocusRingAroundAll}\n hideFocusRingAroundAll={hideFocusRingAroundAll}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n />\n </DSTooltipV3>\n );\n return (\n <IconAndTextsRegionContent\n title={title}\n description={description}\n wrapText={wrapText}\n type={type}\n Icon={Icon}\n titleHandleRef={titleHandleRef}\n descriptionHandleRef={descriptionHandleRef}\n showFocusRingAroundAll={showFocusRingAroundAll}\n hideFocusRingAroundAll={hideFocusRingAroundAll}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n />\n );\n};\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADerB;AAfF,qBAAqB;AACrB,yCAAoC;AAEpC,2BAA4B;AAC5B,2BAAkD;AAClD,mBAAkB;AAElB,uCAA0C;AAO1C,MAAM,cAAqD,CAAC,EAAE,OAAO,YAAY,MAC/E,6CAAC,uBACC;AAAA,8CAAC,qCAAa,SAAS,yCAAoB,YAAa,iBAAM;AAAA,EAC9D,4CAAC,qCAAa,SAAS,yCAAoB,IAAK,uBAAY;AAAA,GAC9D;AAeK,MAAM,qBAAmE,CAAC;AAAA,EAC/E;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,MAAM;AACJ,QAAM,CAAC,mBAAmB,oBAAoB,IAAI,aAAAA,QAAM,SAAS,KAAK;AACtE,QAAM,CAAC,yBAAyB,0BAA0B,IAAI,aAAAA,QAAM,SAAS,KAAK;AAElF,QAAM,cAAc,qBAAqB;AAEzC,QAAM,EAAE,WAAW,eAAe,QAAI,wDAAoB;AAAA,IACxD,uBAAuB;AAAA,EACzB,CAAC;AAED,QAAM,EAAE,WAAW,qBAAqB,QAAI,wDAAoB;AAAA,IAC9D,uBAAuB;AAAA,EACzB,CAAC;AACD,QAAM,mBAAmB,aAAAA,QAAM;AAAA,IAC7B,OAAO;AAAA,MACL;AAAA,MACA;AAAA,IACF;AAAA,IACA,CAAC,OAAO,WAAW;AAAA,EACrB;AAEA,MAAI;AACF,WACE,4CAAC,oCAA8B,MAAM,aAAa,WAAW,kBAC3D;AAAA,MAAC;AAAA;AAAA,QACC;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA;AAAA,IACF,GACF;AAEJ,SACE;AAAA,IAAC;AAAA;AAAA,MACC;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA;AAAA,EACF;AAEJ;",
|
|
6
6
|
"names": ["React"]
|
|
7
7
|
}
|
|
@@ -49,7 +49,9 @@ const IconAndTextsRegionContent = import_react.default.memo((props) => {
|
|
|
49
49
|
type,
|
|
50
50
|
Icon,
|
|
51
51
|
showFocusRingAroundAll,
|
|
52
|
-
hideFocusRingAroundAll
|
|
52
|
+
hideFocusRingAroundAll,
|
|
53
|
+
getOwnerProps,
|
|
54
|
+
getOwnerPropsArguments
|
|
53
55
|
} = props;
|
|
54
56
|
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
|
|
55
57
|
import_style.StyledGridTextContainer,
|
|
@@ -59,29 +61,66 @@ const IconAndTextsRegionContent = import_react.default.memo((props) => {
|
|
|
59
61
|
tabIndex: 0,
|
|
60
62
|
onFocus: showFocusRingAroundAll,
|
|
61
63
|
onBlur: hideFocusRingAroundAll,
|
|
64
|
+
getOwnerProps,
|
|
65
|
+
getOwnerPropsArguments,
|
|
62
66
|
children: [
|
|
63
|
-
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
67
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
68
|
+
import_style.StyledCardNavigationIcon,
|
|
69
|
+
{
|
|
70
|
+
$type: type,
|
|
71
|
+
role: "presentation",
|
|
72
|
+
getOwnerProps,
|
|
73
|
+
getOwnerPropsArguments,
|
|
74
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Icon, { size: "l", color: mainIconColor })
|
|
75
|
+
}
|
|
76
|
+
),
|
|
77
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
78
|
+
import_style.StyledCardNavigationCentralContent,
|
|
79
|
+
{
|
|
80
|
+
cols,
|
|
81
|
+
getOwnerProps,
|
|
82
|
+
getOwnerPropsArguments,
|
|
83
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_style.StyledCardNavigationContent, { getOwnerProps, getOwnerPropsArguments, children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
|
|
84
|
+
import_style.StyledCardNavigationContentTitleWrapper,
|
|
85
|
+
{
|
|
86
|
+
getOwnerProps,
|
|
87
|
+
getOwnerPropsArguments,
|
|
88
|
+
children: [
|
|
89
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
90
|
+
import_style.StyledCardNavigationContentTitle,
|
|
91
|
+
{
|
|
92
|
+
getOwnerProps,
|
|
93
|
+
getOwnerPropsArguments,
|
|
94
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
95
|
+
import_style.StyledTitleTypography,
|
|
96
|
+
{
|
|
97
|
+
innerRef: titleHandleRef,
|
|
98
|
+
truncateWithEllipsis: !wrapText,
|
|
99
|
+
variant: import_ds_typography.TYPOGRAPHY_VARIANTS.B1,
|
|
100
|
+
getOwnerProps,
|
|
101
|
+
getOwnerPropsArguments,
|
|
102
|
+
children: title
|
|
103
|
+
}
|
|
104
|
+
)
|
|
105
|
+
}
|
|
106
|
+
),
|
|
107
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
108
|
+
import_style.StyledDescriptionTypography,
|
|
109
|
+
{
|
|
110
|
+
innerRef: descriptionHandleRef,
|
|
111
|
+
truncateWithEllipsis: !wrapText,
|
|
112
|
+
variant: import_ds_typography.TYPOGRAPHY_VARIANTS.B1,
|
|
113
|
+
"data-testid": import_constants.CARD_NAVIGATION_DATA_TESTID.DESCRIPTION_TEXT,
|
|
114
|
+
getOwnerProps,
|
|
115
|
+
getOwnerPropsArguments,
|
|
116
|
+
children: description
|
|
117
|
+
}
|
|
118
|
+
) })
|
|
119
|
+
]
|
|
120
|
+
}
|
|
121
|
+
) })
|
|
122
|
+
}
|
|
123
|
+
)
|
|
85
124
|
]
|
|
86
125
|
}
|
|
87
126
|
);
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../src/parts/text-region/IconAndTextsRegionContent.tsx", "../../../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
-
"sourcesContent": ["import type { SvgIconT } from '@elliemae/ds-icons';\nimport { TYPOGRAPHY_VARIANTS } from '@elliemae/ds-typography';\nimport React from 'react';\nimport { CARD_NAVIGATION_DATA_TESTID } from '../../constants/index.js';\nimport type { DSCardNavigationT } from '../../react-desc-prop-types.js';\nimport {\n StyledCardNavigationCentralContent,\n StyledCardNavigationContent,\n StyledCardNavigationContentTitle,\n StyledCardNavigationContentTitleWrapper,\n StyledCardNavigationIcon,\n StyledDescriptionTypography,\n StyledGridTextContainer,\n StyledTitleTypography,\n} from '../style.js';\n\nconst mainIconColor = ['neutral', '0'] as SvgIconT.ColorType;\nconst cols = ['1fr'];\n\ninterface IconAndTextsRegionContentProps {\n title: DSCardNavigationT.InternalProps['title'];\n description: DSCardNavigationT.InternalProps['description'];\n wrapText: DSCardNavigationT.InternalProps['wrapText'];\n type: DSCardNavigationT.InternalProps['type'];\n Icon: DSCardNavigationT.InternalProps['Icon'];\n\n titleHandleRef: (node: HTMLElement | null) => void;\n descriptionHandleRef: (node: HTMLElement | null) => void;\n showFocusRingAroundAll: React.FocusEventHandler<HTMLDivElement>;\n hideFocusRingAroundAll: React.FocusEventHandler<HTMLDivElement>;\n}\n\nexport const IconAndTextsRegionContent = React.memo((props: IconAndTextsRegionContentProps) => {\n const {\n title,\n description,\n wrapText,\n titleHandleRef,\n descriptionHandleRef,\n type,\n Icon,\n showFocusRingAroundAll,\n hideFocusRingAroundAll,\n } = props;\n\n return (\n <StyledGridTextContainer\n data-type={type}\n role=\"button\"\n tabIndex={0}\n onFocus={showFocusRingAroundAll}\n onBlur={hideFocusRingAroundAll}\n >\n <StyledCardNavigationIcon
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;
|
|
4
|
+
"sourcesContent": ["import type { SvgIconT } from '@elliemae/ds-icons';\nimport { TYPOGRAPHY_VARIANTS } from '@elliemae/ds-typography';\nimport React from 'react';\nimport { CARD_NAVIGATION_DATA_TESTID } from '../../constants/index.js';\nimport type { DSCardNavigationT } from '../../react-desc-prop-types.js';\nimport {\n StyledCardNavigationCentralContent,\n StyledCardNavigationContent,\n StyledCardNavigationContentTitle,\n StyledCardNavigationContentTitleWrapper,\n StyledCardNavigationIcon,\n StyledDescriptionTypography,\n StyledGridTextContainer,\n StyledTitleTypography,\n} from '../style.js';\n\nconst mainIconColor = ['neutral', '0'] as SvgIconT.ColorType;\nconst cols = ['1fr'];\n\ninterface IconAndTextsRegionContentProps {\n title: DSCardNavigationT.InternalProps['title'];\n description: DSCardNavigationT.InternalProps['description'];\n wrapText: DSCardNavigationT.InternalProps['wrapText'];\n type: DSCardNavigationT.InternalProps['type'];\n Icon: DSCardNavigationT.InternalProps['Icon'];\n\n titleHandleRef: (node: HTMLElement | null) => void;\n descriptionHandleRef: (node: HTMLElement | null) => void;\n showFocusRingAroundAll: React.FocusEventHandler<HTMLDivElement>;\n hideFocusRingAroundAll: React.FocusEventHandler<HTMLDivElement>;\n getOwnerProps?: () => object;\n getOwnerPropsArguments?: () => object;\n}\n\nexport const IconAndTextsRegionContent = React.memo((props: IconAndTextsRegionContentProps) => {\n const {\n title,\n description,\n wrapText,\n titleHandleRef,\n descriptionHandleRef,\n type,\n Icon,\n showFocusRingAroundAll,\n hideFocusRingAroundAll,\n getOwnerProps,\n getOwnerPropsArguments,\n } = props;\n\n return (\n <StyledGridTextContainer\n data-type={type}\n role=\"button\"\n tabIndex={0}\n onFocus={showFocusRingAroundAll}\n onBlur={hideFocusRingAroundAll}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <StyledCardNavigationIcon\n $type={type}\n role=\"presentation\"\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <Icon size=\"l\" color={mainIconColor} />\n </StyledCardNavigationIcon>\n\n <StyledCardNavigationCentralContent\n cols={cols}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <StyledCardNavigationContent getOwnerProps={getOwnerProps} getOwnerPropsArguments={getOwnerPropsArguments}>\n <StyledCardNavigationContentTitleWrapper\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <StyledCardNavigationContentTitle\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <StyledTitleTypography\n innerRef={titleHandleRef}\n truncateWithEllipsis={!wrapText}\n variant={TYPOGRAPHY_VARIANTS.B1}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n {title}\n </StyledTitleTypography>\n </StyledCardNavigationContentTitle>\n <div>\n <StyledDescriptionTypography\n innerRef={descriptionHandleRef}\n truncateWithEllipsis={!wrapText}\n variant={TYPOGRAPHY_VARIANTS.B1}\n data-testid={CARD_NAVIGATION_DATA_TESTID.DESCRIPTION_TEXT}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n {description}\n </StyledDescriptionTypography>\n </div>\n </StyledCardNavigationContentTitleWrapper>\n </StyledCardNavigationContent>\n </StyledCardNavigationCentralContent>\n </StyledGridTextContainer>\n );\n});\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADiEf;AAhER,2BAAoC;AACpC,mBAAkB;AAClB,uBAA4C;AAE5C,mBASO;AAEP,MAAM,gBAAgB,CAAC,WAAW,GAAG;AACrC,MAAM,OAAO,CAAC,KAAK;AAiBZ,MAAM,4BAA4B,aAAAA,QAAM,KAAK,CAAC,UAA0C;AAC7F,QAAM;AAAA,IACJ;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EACF,IAAI;AAEJ,SACE;AAAA,IAAC;AAAA;AAAA,MACC,aAAW;AAAA,MACX,MAAK;AAAA,MACL,UAAU;AAAA,MACV,SAAS;AAAA,MACT,QAAQ;AAAA,MACR;AAAA,MACA;AAAA,MAEA;AAAA;AAAA,UAAC;AAAA;AAAA,YACC,OAAO;AAAA,YACP,MAAK;AAAA,YACL;AAAA,YACA;AAAA,YAEA,sDAAC,QAAK,MAAK,KAAI,OAAO,eAAe;AAAA;AAAA,QACvC;AAAA,QAEA;AAAA,UAAC;AAAA;AAAA,YACC;AAAA,YACA;AAAA,YACA;AAAA,YAEA,sDAAC,4CAA4B,eAA8B,wBACzD;AAAA,cAAC;AAAA;AAAA,gBACC;AAAA,gBACA;AAAA,gBAEA;AAAA;AAAA,oBAAC;AAAA;AAAA,sBACC;AAAA,sBACA;AAAA,sBAEA;AAAA,wBAAC;AAAA;AAAA,0BACC,UAAU;AAAA,0BACV,sBAAsB,CAAC;AAAA,0BACvB,SAAS,yCAAoB;AAAA,0BAC7B;AAAA,0BACA;AAAA,0BAEC;AAAA;AAAA,sBACH;AAAA;AAAA,kBACF;AAAA,kBACA,4CAAC,SACC;AAAA,oBAAC;AAAA;AAAA,sBACC,UAAU;AAAA,sBACV,sBAAsB,CAAC;AAAA,sBACvB,SAAS,yCAAoB;AAAA,sBAC7B,eAAa,6CAA4B;AAAA,sBACzC;AAAA,sBACA;AAAA,sBAEC;AAAA;AAAA,kBACH,GACF;AAAA;AAAA;AAAA,YACF,GACF;AAAA;AAAA,QACF;AAAA;AAAA;AAAA,EACF;AAEJ,CAAC;",
|
|
6
6
|
"names": ["React"]
|
|
7
7
|
}
|
|
@@ -33,6 +33,8 @@ const DSCardNavigation = (props) => {
|
|
|
33
33
|
/* @__PURE__ */ jsx(
|
|
34
34
|
IconAndTextsRegion,
|
|
35
35
|
{
|
|
36
|
+
getOwnerProps,
|
|
37
|
+
getOwnerPropsArguments,
|
|
36
38
|
title,
|
|
37
39
|
description,
|
|
38
40
|
wrapText,
|
|
@@ -42,7 +44,15 @@ const DSCardNavigation = (props) => {
|
|
|
42
44
|
hideFocusRingAroundAll
|
|
43
45
|
}
|
|
44
46
|
),
|
|
45
|
-
/* @__PURE__ */ jsx(
|
|
47
|
+
/* @__PURE__ */ jsx(
|
|
48
|
+
ActionsRegion,
|
|
49
|
+
{
|
|
50
|
+
getOwnerProps,
|
|
51
|
+
getOwnerPropsArguments,
|
|
52
|
+
actions,
|
|
53
|
+
instanceUid
|
|
54
|
+
}
|
|
55
|
+
)
|
|
46
56
|
]
|
|
47
57
|
}
|
|
48
58
|
);
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../src/DSCardNavigation.tsx"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { describe, useOwnerProps } from '@elliemae/ds-props-helpers';\nimport React from 'react';\nimport { useCardNavigation } from './config/useCardNavigation.js';\nimport { DSCardNavigationName } from './constants/index.js';\nimport { type DSCardNavigationT, DSCardNavigationPropTypesSchema } from './react-desc-prop-types.js';\nimport { StyledCardNavigationBoxWrapper } from './parts/style.js';\nimport { IconAndTextsRegion } from './parts/text-region/IconAndTextsRegion.js';\nimport { ActionsRegion } from './parts/ActionsRegion.js';\n\nconst DSCardNavigation: React.ComponentType<DSCardNavigationT.Props> = (props) => {\n const cardNavigationConfig = useCardNavigation(props);\n const {\n propsWithDefault,\n xstyledProps,\n globalProps,\n iconAndTextsRegionIsFocused,\n showFocusRingAroundAll,\n hideFocusRingAroundAll,\n instanceUid,\n } = cardNavigationConfig;\n const { containerProps, title, description, type, Icon, actions, wrapText } = propsWithDefault;\n\n const { getOwnerProps, getOwnerPropsArguments } = useOwnerProps<DSCardNavigationT.Props>(propsWithDefault);\n\n return (\n <StyledCardNavigationBoxWrapper\n {...globalProps}\n {...xstyledProps}\n {...containerProps}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n $isIconAndTextsRegionFocused={iconAndTextsRegionIsFocused}\n >\n <IconAndTextsRegion\n title={title}\n description={description}\n wrapText={wrapText}\n type={type}\n Icon={Icon}\n showFocusRingAroundAll={showFocusRingAroundAll}\n hideFocusRingAroundAll={hideFocusRingAroundAll}\n />\n <ActionsRegion
|
|
5
|
-
"mappings": "AAAA,YAAY,WAAW;ACyBnB,SAQE,KARF;AAzBJ,SAAS,UAAU,qBAAqB;AAExC,SAAS,yBAAyB;AAClC,SAAS,4BAA4B;AACrC,SAAiC,uCAAuC;AACxE,SAAS,sCAAsC;AAC/C,SAAS,0BAA0B;AACnC,SAAS,qBAAqB;AAE9B,MAAM,mBAAiE,CAAC,UAAU;AAChF,QAAM,uBAAuB,kBAAkB,KAAK;AACpD,QAAM;AAAA,IACJ;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EACF,IAAI;AACJ,QAAM,EAAE,gBAAgB,OAAO,aAAa,MAAM,MAAM,SAAS,SAAS,IAAI;AAE9E,QAAM,EAAE,eAAe,uBAAuB,IAAI,cAAuC,gBAAgB;AAEzG,SACE;AAAA,IAAC;AAAA;AAAA,MACE,GAAG;AAAA,MACH,GAAG;AAAA,MACH,GAAG;AAAA,MACJ;AAAA,MACA;AAAA,MACA,8BAA8B;AAAA,MAE9B;AAAA;AAAA,UAAC;AAAA;AAAA,YACC;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA;AAAA,QACF;AAAA,QACA,
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { describe, useOwnerProps } from '@elliemae/ds-props-helpers';\nimport React from 'react';\nimport { useCardNavigation } from './config/useCardNavigation.js';\nimport { DSCardNavigationName } from './constants/index.js';\nimport { type DSCardNavigationT, DSCardNavigationPropTypesSchema } from './react-desc-prop-types.js';\nimport { StyledCardNavigationBoxWrapper } from './parts/style.js';\nimport { IconAndTextsRegion } from './parts/text-region/IconAndTextsRegion.js';\nimport { ActionsRegion } from './parts/ActionsRegion.js';\n\nconst DSCardNavigation: React.ComponentType<DSCardNavigationT.Props> = (props) => {\n const cardNavigationConfig = useCardNavigation(props);\n const {\n propsWithDefault,\n xstyledProps,\n globalProps,\n iconAndTextsRegionIsFocused,\n showFocusRingAroundAll,\n hideFocusRingAroundAll,\n instanceUid,\n } = cardNavigationConfig;\n const { containerProps, title, description, type, Icon, actions, wrapText } = propsWithDefault;\n\n const { getOwnerProps, getOwnerPropsArguments } = useOwnerProps<DSCardNavigationT.Props>(propsWithDefault);\n\n return (\n <StyledCardNavigationBoxWrapper\n {...globalProps}\n {...xstyledProps}\n {...containerProps}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n $isIconAndTextsRegionFocused={iconAndTextsRegionIsFocused}\n >\n <IconAndTextsRegion\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n title={title}\n description={description}\n wrapText={wrapText}\n type={type}\n Icon={Icon}\n showFocusRingAroundAll={showFocusRingAroundAll}\n hideFocusRingAroundAll={hideFocusRingAroundAll}\n />\n <ActionsRegion\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n actions={actions}\n instanceUid={instanceUid}\n />\n </StyledCardNavigationBoxWrapper>\n );\n};\n\nDSCardNavigation.displayName = DSCardNavigationName;\nconst DSCardNavigationWithSchema = describe(DSCardNavigation);\nDSCardNavigationWithSchema.propTypes = DSCardNavigationPropTypesSchema;\n\nexport { DSCardNavigation, DSCardNavigationWithSchema };\n"],
|
|
5
|
+
"mappings": "AAAA,YAAY,WAAW;ACyBnB,SAQE,KARF;AAzBJ,SAAS,UAAU,qBAAqB;AAExC,SAAS,yBAAyB;AAClC,SAAS,4BAA4B;AACrC,SAAiC,uCAAuC;AACxE,SAAS,sCAAsC;AAC/C,SAAS,0BAA0B;AACnC,SAAS,qBAAqB;AAE9B,MAAM,mBAAiE,CAAC,UAAU;AAChF,QAAM,uBAAuB,kBAAkB,KAAK;AACpD,QAAM;AAAA,IACJ;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EACF,IAAI;AACJ,QAAM,EAAE,gBAAgB,OAAO,aAAa,MAAM,MAAM,SAAS,SAAS,IAAI;AAE9E,QAAM,EAAE,eAAe,uBAAuB,IAAI,cAAuC,gBAAgB;AAEzG,SACE;AAAA,IAAC;AAAA;AAAA,MACE,GAAG;AAAA,MACH,GAAG;AAAA,MACH,GAAG;AAAA,MACJ;AAAA,MACA;AAAA,MACA,8BAA8B;AAAA,MAE9B;AAAA;AAAA,UAAC;AAAA;AAAA,YACC;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA;AAAA,QACF;AAAA,QACA;AAAA,UAAC;AAAA;AAAA,YACC;AAAA,YACA;AAAA,YACA;AAAA,YACA;AAAA;AAAA,QACF;AAAA;AAAA;AAAA,EACF;AAEJ;AAEA,iBAAiB,cAAc;AAC/B,MAAM,6BAA6B,SAAS,gBAAgB;AAC5D,2BAA2B,YAAY;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -7,11 +7,19 @@ const CARD_NAVIGATION_SLOTS = {
|
|
|
7
7
|
ACTIONS: "actions",
|
|
8
8
|
TYPE: "type",
|
|
9
9
|
CENTRAL_CONTENT: "central-content",
|
|
10
|
-
INTERACTIVE_ELEMENT_REGION: "interactive-element-region"
|
|
10
|
+
INTERACTIVE_ELEMENT_REGION: "interactive-element-region",
|
|
11
|
+
DESCRIPTION_TEXT: "description-text",
|
|
12
|
+
TITLE_TYPOGRAPHY: "title-typography",
|
|
13
|
+
TITLE_WRAPPER: "title-wrapper",
|
|
14
|
+
CONTENT: "content",
|
|
15
|
+
BUTTON_WRAPPER: "button-wrapper",
|
|
16
|
+
ACTION_BUTTON: "action-button"
|
|
11
17
|
};
|
|
12
18
|
const CARD_NAVIGATION_DATA_TESTID = {
|
|
13
19
|
...slotObjectToDataTestIds(DSCardNavigationName, CARD_NAVIGATION_SLOTS),
|
|
14
|
-
DESCRIPTION_TEXT: "ds-card-navigation--description"
|
|
20
|
+
DESCRIPTION_TEXT: "ds-card-navigation--description",
|
|
21
|
+
TITLE_TYPOGRAPHY: "ds-typography-element",
|
|
22
|
+
ACTION_BUTTON: "ds-button"
|
|
15
23
|
};
|
|
16
24
|
const CardNavigationTypes = {
|
|
17
25
|
BORROWER: "borrower",
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../../scripts/build/transpile/react-shim.js", "../../../src/constants/index.ts"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { slotObjectToDataTestIds } from '@elliemae/ds-system';\n\nexport const DSCardNavigationName = 'DSCardnavigation';\n\n// we are naming this with the ${component_name}_slots convention to namespace & avoid errors on duplicate exports variables in aggregators\nexport const CARD_NAVIGATION_SLOTS = {\n ROOT: 'root',\n TITLE: 'title',\n ACTIONS: 'actions',\n TYPE: 'type',\n CENTRAL_CONTENT: 'central-content',\n INTERACTIVE_ELEMENT_REGION: 'interactive-element-region',\n} as const;\n\n// we are naming this with the ${component_name}_data_testid convention to namespace & avoid errors on duplicate exports variables in aggregators\nexport const CARD_NAVIGATION_DATA_TESTID = {\n ...slotObjectToDataTestIds(DSCardNavigationName, CARD_NAVIGATION_SLOTS),\n DESCRIPTION_TEXT: 'ds-card-navigation--description',\n};\n\nexport const CardNavigationTypes = {\n BORROWER: 'borrower',\n FINANCIAL: 'financial',\n LOAN: 'loan',\n REGULATORY: 'regulatory',\n} as const;\n\nexport const CardNavigationTypesValues = Object.values(CardNavigationTypes);\n"],
|
|
5
|
-
"mappings": "AAAA,YAAY,WAAW;ACAvB,SAAS,+BAA+B;AAEjC,MAAM,uBAAuB;AAG7B,MAAM,wBAAwB;AAAA,EACnC,MAAM;AAAA,EACN,OAAO;AAAA,EACP,SAAS;AAAA,EACT,MAAM;AAAA,EACN,iBAAiB;AAAA,EACjB,4BAA4B;
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { slotObjectToDataTestIds } from '@elliemae/ds-system';\n\nexport const DSCardNavigationName = 'DSCardnavigation';\n\n// we are naming this with the ${component_name}_slots convention to namespace & avoid errors on duplicate exports variables in aggregators\nexport const CARD_NAVIGATION_SLOTS = {\n ROOT: 'root',\n TITLE: 'title',\n ACTIONS: 'actions',\n TYPE: 'type',\n CENTRAL_CONTENT: 'central-content',\n INTERACTIVE_ELEMENT_REGION: 'interactive-element-region',\n DESCRIPTION_TEXT: 'description-text',\n TITLE_TYPOGRAPHY: 'title-typography',\n TITLE_WRAPPER: 'title-wrapper',\n CONTENT: 'content',\n BUTTON_WRAPPER: 'button-wrapper',\n ACTION_BUTTON: 'action-button',\n} as const;\n\n// we are naming this with the ${component_name}_data_testid convention to namespace & avoid errors on duplicate exports variables in aggregators\nexport const CARD_NAVIGATION_DATA_TESTID = {\n ...slotObjectToDataTestIds(DSCardNavigationName, CARD_NAVIGATION_SLOTS),\n DESCRIPTION_TEXT: 'ds-card-navigation--description',\n TITLE_TYPOGRAPHY: 'ds-typography-element',\n ACTION_BUTTON: 'ds-button',\n};\n\nexport const CardNavigationTypes = {\n BORROWER: 'borrower',\n FINANCIAL: 'financial',\n LOAN: 'loan',\n REGULATORY: 'regulatory',\n} as const;\n\nexport const CardNavigationTypesValues = Object.values(CardNavigationTypes);\n"],
|
|
5
|
+
"mappings": "AAAA,YAAY,WAAW;ACAvB,SAAS,+BAA+B;AAEjC,MAAM,uBAAuB;AAG7B,MAAM,wBAAwB;AAAA,EACnC,MAAM;AAAA,EACN,OAAO;AAAA,EACP,SAAS;AAAA,EACT,MAAM;AAAA,EACN,iBAAiB;AAAA,EACjB,4BAA4B;AAAA,EAC5B,kBAAkB;AAAA,EAClB,kBAAkB;AAAA,EAClB,eAAe;AAAA,EACf,SAAS;AAAA,EACT,gBAAgB;AAAA,EAChB,eAAe;AACjB;AAGO,MAAM,8BAA8B;AAAA,EACzC,GAAG,wBAAwB,sBAAsB,qBAAqB;AAAA,EACtE,kBAAkB;AAAA,EAClB,kBAAkB;AAAA,EAClB,eAAe;AACjB;AAEO,MAAM,sBAAsB;AAAA,EACjC,UAAU;AAAA,EACV,WAAW;AAAA,EACX,MAAM;AAAA,EACN,YAAY;AACd;AAEO,MAAM,4BAA4B,OAAO,OAAO,mBAAmB;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
package/dist/esm/index.js
CHANGED
|
@@ -5,7 +5,8 @@ import {
|
|
|
5
5
|
CARD_NAVIGATION_SLOTS,
|
|
6
6
|
CARD_NAVIGATION_DATA_TESTID,
|
|
7
7
|
CardNavigationTypesValues,
|
|
8
|
-
CardNavigationTypes
|
|
8
|
+
CardNavigationTypes,
|
|
9
|
+
DSCardNavigationName
|
|
9
10
|
} from "./constants/index.js";
|
|
10
11
|
var index_default = DSCardNavigation;
|
|
11
12
|
export {
|
|
@@ -14,6 +15,7 @@ export {
|
|
|
14
15
|
CardNavigationTypes,
|
|
15
16
|
CardNavigationTypesValues,
|
|
16
17
|
DSCardNavigation2 as DSCardNavigation,
|
|
18
|
+
DSCardNavigationName,
|
|
17
19
|
DSCardNavigationWithSchema,
|
|
18
20
|
index_default as default
|
|
19
21
|
};
|
package/dist/esm/index.js.map
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../src/index.ts"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "// this is a workaround to typescript error TS2742\n// https://github.com/microsoft/TypeScript/issues/47663\nimport { DSCardNavigation } from './DSCardNavigation.js';\nimport type {} from '@xstyled/system';\nexport { DSCardNavigation, DSCardNavigationWithSchema } from './DSCardNavigation.js';\nexport { type DSCardNavigationT } from './react-desc-prop-types.js';\nexport {\n CARD_NAVIGATION_SLOTS,\n CARD_NAVIGATION_DATA_TESTID,\n CardNavigationTypesValues,\n CardNavigationTypes,\n} from './constants/index.js';\n\nexport default DSCardNavigation;\n"],
|
|
5
|
-
"mappings": "AAAA,YAAY,WAAW;ACEvB,SAAS,wBAAwB;AAEjC,SAAS,oBAAAA,mBAAkB,kCAAkC;AAE7D;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACK;AAEP,IAAO,gBAAQ;",
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "// this is a workaround to typescript error TS2742\n// https://github.com/microsoft/TypeScript/issues/47663\nimport { DSCardNavigation } from './DSCardNavigation.js';\nimport type {} from '@xstyled/system';\nexport { DSCardNavigation, DSCardNavigationWithSchema } from './DSCardNavigation.js';\nexport { type DSCardNavigationT } from './react-desc-prop-types.js';\nexport {\n CARD_NAVIGATION_SLOTS,\n CARD_NAVIGATION_DATA_TESTID,\n CardNavigationTypesValues,\n CardNavigationTypes,\n DSCardNavigationName,\n} from './constants/index.js';\n\nexport default DSCardNavigation;\n"],
|
|
5
|
+
"mappings": "AAAA,YAAY,WAAW;ACEvB,SAAS,wBAAwB;AAEjC,SAAS,oBAAAA,mBAAkB,kCAAkC;AAE7D;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACK;AAEP,IAAO,gBAAQ;",
|
|
6
6
|
"names": ["DSCardNavigation"]
|
|
7
7
|
}
|
|
@@ -1,24 +1,37 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
2
|
import { jsx } from "react/jsx-runtime";
|
|
3
|
-
import { BUTTON_SIZES, BUTTON_TYPES
|
|
3
|
+
import { BUTTON_SIZES, BUTTON_TYPES } from "@elliemae/ds-button-v2";
|
|
4
4
|
import { MoreOptionsVert } from "@elliemae/ds-icons";
|
|
5
|
-
import {
|
|
6
|
-
|
|
5
|
+
import {
|
|
6
|
+
StyledCardNavigationButtonWrapper,
|
|
7
|
+
StyledCardNavigationActions,
|
|
8
|
+
StyledCardNavigationActionButton
|
|
9
|
+
} from "./style.js";
|
|
10
|
+
const ActionsRegion = ({
|
|
11
|
+
actions,
|
|
12
|
+
instanceUid,
|
|
13
|
+
getOwnerProps,
|
|
14
|
+
getOwnerPropsArguments
|
|
15
|
+
}) => {
|
|
7
16
|
if (actions.length === 0) return null;
|
|
8
|
-
return /* @__PURE__ */ jsx(StyledCardNavigationActions, { children: actions.map(({ icon, Icon, onClick, ...unexpectedButPreviouslySupportedOtherProps }, index) => {
|
|
17
|
+
return /* @__PURE__ */ jsx(StyledCardNavigationActions, { getOwnerProps, getOwnerPropsArguments, children: actions.map(({ icon, Icon, onClick, ...unexpectedButPreviouslySupportedOtherProps }, index) => {
|
|
9
18
|
const defaultIconJSX = /* @__PURE__ */ jsx(MoreOptionsVert, { "aria-label": "More options" });
|
|
10
19
|
const iconJSX = icon ?? defaultIconJSX;
|
|
11
20
|
return /* @__PURE__ */ jsx(
|
|
12
|
-
|
|
21
|
+
StyledCardNavigationButtonWrapper,
|
|
13
22
|
{
|
|
23
|
+
getOwnerProps,
|
|
24
|
+
getOwnerPropsArguments,
|
|
14
25
|
children: /* @__PURE__ */ jsx(
|
|
15
|
-
|
|
26
|
+
StyledCardNavigationActionButton,
|
|
16
27
|
{
|
|
17
28
|
onClick,
|
|
18
29
|
"aria-label": "More options",
|
|
19
30
|
...unexpectedButPreviouslySupportedOtherProps,
|
|
20
31
|
buttonType: BUTTON_TYPES.ICON,
|
|
21
32
|
size: BUTTON_SIZES.L,
|
|
33
|
+
getOwnerProps,
|
|
34
|
+
getOwnerPropsArguments,
|
|
22
35
|
children: Icon ? /* @__PURE__ */ jsx(Icon, {}) : iconJSX
|
|
23
36
|
}
|
|
24
37
|
)
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../../scripts/build/transpile/react-shim.js", "../../../src/parts/ActionsRegion.tsx"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { BUTTON_SIZES, BUTTON_TYPES
|
|
5
|
-
"mappings": "AAAA,YAAY,WAAW;
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { BUTTON_SIZES, BUTTON_TYPES } from '@elliemae/ds-button-v2';\nimport { MoreOptionsVert } from '@elliemae/ds-icons';\nimport React from 'react';\nimport type { DSCardNavigationT } from '../react-desc-prop-types.js';\nimport {\n StyledCardNavigationButtonWrapper,\n StyledCardNavigationActions,\n StyledCardNavigationActionButton,\n} from './style.js';\n\ninterface ActionRegionProps {\n actions: DSCardNavigationT.InternalProps['actions'];\n instanceUid: string;\n getOwnerProps?: () => object;\n getOwnerPropsArguments?: () => object;\n}\n\nexport const ActionsRegion: React.ComponentType<ActionRegionProps> = ({\n actions,\n instanceUid,\n getOwnerProps,\n getOwnerPropsArguments,\n}) => {\n if (actions.length === 0) return null;\n return (\n <StyledCardNavigationActions getOwnerProps={getOwnerProps} getOwnerPropsArguments={getOwnerPropsArguments}>\n {actions.map(({ icon, Icon, onClick, ...unexpectedButPreviouslySupportedOtherProps }, index) => {\n const defaultIconJSX = <MoreOptionsVert aria-label=\"More options\" />;\n const iconJSX = icon ?? defaultIconJSX;\n return (\n <StyledCardNavigationButtonWrapper\n // eslint-disable-next-line react/no-array-index-key\n key={`${instanceUid}-${index}`}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <StyledCardNavigationActionButton\n onClick={onClick}\n aria-label=\"More options\"\n {...unexpectedButPreviouslySupportedOtherProps}\n buttonType={BUTTON_TYPES.ICON}\n size={BUTTON_SIZES.L}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n {Icon ? <Icon /> : iconJSX}\n </StyledCardNavigationActionButton>\n </StyledCardNavigationButtonWrapper>\n );\n })}\n </StyledCardNavigationActions>\n );\n};\n"],
|
|
5
|
+
"mappings": "AAAA,YAAY,WAAW;AC2BQ;AA3B/B,SAAS,cAAc,oBAAoB;AAC3C,SAAS,uBAAuB;AAGhC;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,OACK;AASA,MAAM,gBAAwD,CAAC;AAAA,EACpE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,MAAM;AACJ,MAAI,QAAQ,WAAW,EAAG,QAAO;AACjC,SACE,oBAAC,+BAA4B,eAA8B,wBACxD,kBAAQ,IAAI,CAAC,EAAE,MAAM,MAAM,SAAS,GAAG,2CAA2C,GAAG,UAAU;AAC9F,UAAM,iBAAiB,oBAAC,mBAAgB,cAAW,gBAAe;AAClE,UAAM,UAAU,QAAQ;AACxB,WACE;AAAA,MAAC;AAAA;AAAA,QAGC;AAAA,QACA;AAAA,QAEA;AAAA,UAAC;AAAA;AAAA,YACC;AAAA,YACA,cAAW;AAAA,YACV,GAAG;AAAA,YACJ,YAAY,aAAa;AAAA,YACzB,MAAM,aAAa;AAAA,YACnB;AAAA,YACA;AAAA,YAEC,iBAAO,oBAAC,QAAK,IAAK;AAAA;AAAA,QACrB;AAAA;AAAA,MAdK,GAAG,WAAW,IAAI,KAAK;AAAA,IAe9B;AAAA,EAEJ,CAAC,GACH;AAEJ;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
package/dist/esm/parts/style.js
CHANGED
|
@@ -2,12 +2,17 @@ import * as React from "react";
|
|
|
2
2
|
import { Grid } from "@elliemae/ds-grid";
|
|
3
3
|
import { css, styled } from "@elliemae/ds-system";
|
|
4
4
|
import { DSTypography } from "@elliemae/ds-typography";
|
|
5
|
+
import { DSButtonV3 } from "@elliemae/ds-button-v2";
|
|
5
6
|
import { CARD_NAVIGATION_SLOTS, CardNavigationTypes, DSCardNavigationName } from "../constants/index.js";
|
|
6
7
|
const StyledCardNavigationContentTitle = styled("div", {
|
|
7
8
|
name: DSCardNavigationName,
|
|
8
9
|
slot: CARD_NAVIGATION_SLOTS.TITLE
|
|
9
10
|
})``;
|
|
10
|
-
const StyledTitleTypography = styled(DSTypography
|
|
11
|
+
const StyledTitleTypography = styled(DSTypography, {
|
|
12
|
+
name: DSCardNavigationName,
|
|
13
|
+
slot: CARD_NAVIGATION_SLOTS.TITLE_TYPOGRAPHY,
|
|
14
|
+
preserveLegacyDataTestId: true
|
|
15
|
+
})`
|
|
11
16
|
color: ${(props) => props.theme.colors.neutral["700"]};
|
|
12
17
|
font-weight: ${(props) => props.theme.fontWeights.semibold};
|
|
13
18
|
font-size: 1.3846rem; // 18px -> 18/13 = 1.3846rem
|
|
@@ -16,7 +21,11 @@ const StyledTitleTypography = styled(DSTypography)`
|
|
|
16
21
|
font-size: 1.125rem; // 18px -> 18/16 = 1.125rem
|
|
17
22
|
}
|
|
18
23
|
`;
|
|
19
|
-
const StyledDescriptionTypography = styled(DSTypography
|
|
24
|
+
const StyledDescriptionTypography = styled(DSTypography, {
|
|
25
|
+
name: DSCardNavigationName,
|
|
26
|
+
slot: CARD_NAVIGATION_SLOTS.DESCRIPTION_TEXT,
|
|
27
|
+
preserveLegacyDataTestId: true
|
|
28
|
+
})`
|
|
20
29
|
color: ${(props) => props.theme.colors.neutral["500"]};
|
|
21
30
|
font-size: 0.923rem; // 12px -> 12/13 = 0.923rem
|
|
22
31
|
|
|
@@ -24,10 +33,16 @@ const StyledDescriptionTypography = styled(DSTypography)`
|
|
|
24
33
|
font-size: 0.8775rem; // 12px -> 10.5/12 = 0.8775rem
|
|
25
34
|
}
|
|
26
35
|
`;
|
|
27
|
-
const StyledCardNavigationContentTitleWrapper = styled
|
|
36
|
+
const StyledCardNavigationContentTitleWrapper = styled("div", {
|
|
37
|
+
name: DSCardNavigationName,
|
|
38
|
+
slot: CARD_NAVIGATION_SLOTS.TITLE_WRAPPER
|
|
39
|
+
})`
|
|
28
40
|
width: 100%;
|
|
29
41
|
`;
|
|
30
|
-
const StyledCardNavigationContent = styled
|
|
42
|
+
const StyledCardNavigationContent = styled("div", {
|
|
43
|
+
name: DSCardNavigationName,
|
|
44
|
+
slot: CARD_NAVIGATION_SLOTS.CONTENT
|
|
45
|
+
})`
|
|
31
46
|
display: flex;
|
|
32
47
|
align-items: center;
|
|
33
48
|
flex: 1;
|
|
@@ -107,7 +122,10 @@ const StyledCardNavigationActions = styled("div", {
|
|
|
107
122
|
align-items: center;
|
|
108
123
|
gap: ${(props) => props.theme.space.xs};
|
|
109
124
|
`;
|
|
110
|
-
const
|
|
125
|
+
const StyledCardNavigationButtonWrapper = styled("div", {
|
|
126
|
+
name: DSCardNavigationName,
|
|
127
|
+
slot: CARD_NAVIGATION_SLOTS.BUTTON_WRAPPER
|
|
128
|
+
})`
|
|
111
129
|
span,
|
|
112
130
|
svg {
|
|
113
131
|
height: ${({ theme }) => theme.space.s};
|
|
@@ -130,10 +148,16 @@ const StyledGridTextContainer = styled("div", {
|
|
|
130
148
|
}
|
|
131
149
|
cursor: pointer;
|
|
132
150
|
`;
|
|
151
|
+
const StyledCardNavigationActionButton = styled(DSButtonV3, {
|
|
152
|
+
name: DSCardNavigationName,
|
|
153
|
+
slot: CARD_NAVIGATION_SLOTS.ACTION_BUTTON,
|
|
154
|
+
preserveLegacyDataTestId: true
|
|
155
|
+
})``;
|
|
133
156
|
export {
|
|
134
|
-
|
|
157
|
+
StyledCardNavigationActionButton,
|
|
135
158
|
StyledCardNavigationActions,
|
|
136
159
|
StyledCardNavigationBoxWrapper,
|
|
160
|
+
StyledCardNavigationButtonWrapper,
|
|
137
161
|
StyledCardNavigationCentralContent,
|
|
138
162
|
StyledCardNavigationContent,
|
|
139
163
|
StyledCardNavigationContentTitle,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../../scripts/build/transpile/react-shim.js", "../../../src/parts/style.tsx"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { Grid } from '@elliemae/ds-grid';\nimport { css, styled } from '@elliemae/ds-system';\nimport { DSTypography } from '@elliemae/ds-typography';\nimport { CARD_NAVIGATION_SLOTS, CardNavigationTypes, DSCardNavigationName } from '../constants/index.js';\n\nexport const StyledCardNavigationContentTitle = styled('div', {\n name: DSCardNavigationName,\n slot: CARD_NAVIGATION_SLOTS.TITLE,\n})``;\n\nexport const StyledTitleTypography = styled(DSTypography)`\n color: ${(props) => props.theme.colors.neutral['700']};\n font-weight: ${(props) => props.theme.fontWeights.semibold};\n font-size: 1.3846rem; // 18px -> 18/13 = 1.3846rem\n\n @media (max-width: ${({ theme }) => theme.breakpoints.small}) {\n font-size: 1.125rem; // 18px -> 18/16 = 1.125rem\n }\n`;\n\nexport const StyledDescriptionTypography = styled(DSTypography)`\n color: ${(props) => props.theme.colors.neutral['500']};\n font-size: 0.923rem; // 12px -> 12/13 = 0.923rem\n\n @media (max-width: ${({ theme }) => theme.breakpoints.small}) {\n font-size: 0.8775rem; // 12px -> 10.5/12 = 0.8775rem\n }\n`;\n\nexport const StyledCardNavigationContentTitleWrapper = styled.
|
|
5
|
-
"mappings": "AAAA,YAAY,WAAW;ACAvB,SAAS,YAAY;AACrB,SAAS,KAAK,cAAc;AAC5B,SAAS,oBAAoB;AAC7B,SAAS,uBAAuB,qBAAqB,4BAA4B;AAE1E,MAAM,mCAAmC,OAAO,OAAO;AAAA,EAC5D,MAAM;AAAA,EACN,MAAM,sBAAsB;AAC9B,CAAC;AAEM,MAAM,wBAAwB,OAAO,
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { Grid } from '@elliemae/ds-grid';\nimport { css, styled } from '@elliemae/ds-system';\nimport { DSTypography } from '@elliemae/ds-typography';\nimport { DSButtonV3 } from '@elliemae/ds-button-v2';\nimport { CARD_NAVIGATION_SLOTS, CardNavigationTypes, DSCardNavigationName } from '../constants/index.js';\n\nexport const StyledCardNavigationContentTitle = styled('div', {\n name: DSCardNavigationName,\n slot: CARD_NAVIGATION_SLOTS.TITLE,\n})``;\n\nexport const StyledTitleTypography = styled(DSTypography, {\n name: DSCardNavigationName,\n slot: CARD_NAVIGATION_SLOTS.TITLE_TYPOGRAPHY,\n preserveLegacyDataTestId: true,\n})`\n color: ${(props) => props.theme.colors.neutral['700']};\n font-weight: ${(props) => props.theme.fontWeights.semibold};\n font-size: 1.3846rem; // 18px -> 18/13 = 1.3846rem\n\n @media (max-width: ${({ theme }) => theme.breakpoints.small}) {\n font-size: 1.125rem; // 18px -> 18/16 = 1.125rem\n }\n`;\n\nexport const StyledDescriptionTypography = styled(DSTypography, {\n name: DSCardNavigationName,\n slot: CARD_NAVIGATION_SLOTS.DESCRIPTION_TEXT,\n preserveLegacyDataTestId: true,\n})`\n color: ${(props) => props.theme.colors.neutral['500']};\n font-size: 0.923rem; // 12px -> 12/13 = 0.923rem\n\n @media (max-width: ${({ theme }) => theme.breakpoints.small}) {\n font-size: 0.8775rem; // 12px -> 10.5/12 = 0.8775rem\n }\n`;\n\nexport const StyledCardNavigationContentTitleWrapper = styled('div', {\n name: DSCardNavigationName,\n slot: CARD_NAVIGATION_SLOTS.TITLE_WRAPPER,\n})`\n width: 100%;\n`;\n\nexport const StyledCardNavigationContent = styled('div', {\n name: DSCardNavigationName,\n slot: CARD_NAVIGATION_SLOTS.CONTENT,\n})<{ wrapText?: boolean }>`\n display: flex;\n align-items: center;\n flex: 1;\n width: 100%;\n`;\n\nexport const StyledCardNavigationCentralContent = styled(Grid, {\n slot: CARD_NAVIGATION_SLOTS.CENTRAL_CONTENT,\n name: DSCardNavigationName,\n})<{ wrapText?: boolean; AnyOverFlow?: boolean }>`\n padding: 0 ${(props) => props.theme.space.xs};\n`;\ninterface StyledCardNavigationBoxWrapperProps {\n fluid?: boolean;\n}\n\nexport const StyledCardNavigationBoxWrapper = styled('div', {\n name: DSCardNavigationName,\n slot: CARD_NAVIGATION_SLOTS.ROOT,\n})<StyledCardNavigationBoxWrapperProps & { $isIconAndTextsRegionFocused?: boolean }>`\n min-width: 240px;\n min-height: 64px;\n width: 337px;\n display: flex;\n flex-direction: row;\n flex-wrap: nowrap;\n box-shadow: 0 1px 4px 0px rgba(37, 41, 47, 0.5);\n border-radius: 2px;\n position: relative;\n outline: none;\n\n ${(props) => (props.fluid ? 'width: 100%' : '')};\n @media (max-width: ${(props) => props.theme.breakpoints.small}) {\n width: ${(props) => (props.fluid ? 'width: 100%' : '414px')};\n }\n\n :after {\n display: block;\n content: '';\n position: absolute;\n height: 100%;\n width: 100%;\n top: 0;\n left: 0;\n border: solid ${(props) => props.theme.space.xxs} transparent;\n border-radius: 2px;\n pointer-events: none;\n }\n &:hover {\n box-shadow: 0 3px 8px 0px rgba(37, 41, 47, 0.4);\n outline-offset: 2px;\n }\n\n ${(props) =>\n props.$isIconAndTextsRegionFocused\n ? css`\n outline: 2px solid ${props.theme.colors.brand['700']};\n outline-offset: 2px;\n `\n : css``}\n`;\n\ninterface StyledCardNavigationIconProps {\n $type: (typeof CardNavigationTypes)[keyof typeof CardNavigationTypes];\n}\n\nexport const StyledCardNavigationIcon = styled('div', {\n name: DSCardNavigationName,\n slot: CARD_NAVIGATION_SLOTS.TYPE,\n})<StyledCardNavigationIconProps>`\n min-width: 64px;\n min-height: 64px;\n height: 100%;\n border-top-left-radius: 2px;\n border-bottom-left-radius: 2px;\n padding: 0 ${(props) => props.theme.space.xs};\n display: flex;\n align-items: center;\n justify-content: center;\n fill: #ffffff;\n background-color: ${({ $type }) =>\n ($type === CardNavigationTypes.BORROWER && '#32aad1') ||\n ($type === CardNavigationTypes.FINANCIAL && '#1ba88d') ||\n ($type === CardNavigationTypes.LOAN && '#8e49b2') ||\n ($type === CardNavigationTypes.REGULATORY && '#db5575') ||\n '#32aad1'};\n`;\n\nexport const StyledCardNavigationActions = styled('div', {\n name: DSCardNavigationName,\n slot: CARD_NAVIGATION_SLOTS.ACTIONS,\n})`\n padding: 0 ${(props) => props.theme.space.xs};\n display: flex;\n flex-direction: row;\n align-items: center;\n gap: ${(props) => props.theme.space.xs};\n`;\n\nexport const StyledCardNavigationButtonWrapper = styled('div', {\n name: DSCardNavigationName,\n slot: CARD_NAVIGATION_SLOTS.BUTTON_WRAPPER,\n})`\n span,\n svg {\n height: ${({ theme }) => theme.space.s};\n width: ${({ theme }) => theme.space.s};\n fill: ${({ theme }) => theme.colors.neutral[500]};\n }\n`;\n\nexport const StyledGridTextContainer = styled('div', {\n name: DSCardNavigationName,\n slot: CARD_NAVIGATION_SLOTS.INTERACTIVE_ELEMENT_REGION,\n})`\n display: grid;\n grid-template-columns: max-content auto;\n align-items: center;\n min-width: 0;\n width: 100%;\n overflow: hidden;\n &:focus {\n outline: none;\n }\n cursor: pointer;\n`;\n\nexport const StyledCardNavigationActionButton = styled(DSButtonV3, {\n name: DSCardNavigationName,\n slot: CARD_NAVIGATION_SLOTS.ACTION_BUTTON,\n preserveLegacyDataTestId: true,\n})``;\n"],
|
|
5
|
+
"mappings": "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",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -17,7 +17,9 @@ const IconAndTextsRegion = ({
|
|
|
17
17
|
type,
|
|
18
18
|
Icon,
|
|
19
19
|
showFocusRingAroundAll,
|
|
20
|
-
hideFocusRingAroundAll
|
|
20
|
+
hideFocusRingAroundAll,
|
|
21
|
+
getOwnerProps,
|
|
22
|
+
getOwnerPropsArguments
|
|
21
23
|
}) => {
|
|
22
24
|
const [isTitleTruncating, setIsTitleTruncating] = React2.useState(false);
|
|
23
25
|
const [isDescriptionTruncating, setIsDescriptionTruncating] = React2.useState(false);
|
|
@@ -47,7 +49,9 @@ const IconAndTextsRegion = ({
|
|
|
47
49
|
titleHandleRef,
|
|
48
50
|
descriptionHandleRef,
|
|
49
51
|
showFocusRingAroundAll,
|
|
50
|
-
hideFocusRingAroundAll
|
|
52
|
+
hideFocusRingAroundAll,
|
|
53
|
+
getOwnerProps,
|
|
54
|
+
getOwnerPropsArguments
|
|
51
55
|
}
|
|
52
56
|
) });
|
|
53
57
|
return /* @__PURE__ */ jsx(
|
|
@@ -61,7 +65,9 @@ const IconAndTextsRegion = ({
|
|
|
61
65
|
titleHandleRef,
|
|
62
66
|
descriptionHandleRef,
|
|
63
67
|
showFocusRingAroundAll,
|
|
64
|
-
hideFocusRingAroundAll
|
|
68
|
+
hideFocusRingAroundAll,
|
|
69
|
+
getOwnerProps,
|
|
70
|
+
getOwnerPropsArguments
|
|
65
71
|
}
|
|
66
72
|
);
|
|
67
73
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../../../scripts/build/transpile/react-shim.js", "../../../../src/parts/text-region/IconAndTextsRegion.tsx"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { Grid } from '@elliemae/ds-grid';\nimport { useOnOverflowChange } from '@elliemae/ds-hooks-on-overflow-change';\nimport type { DSTooltipV3T } from '@elliemae/ds-tooltip-v3';\nimport { DSTooltipV3 } from '@elliemae/ds-tooltip-v3';\nimport { DSTypography, TYPOGRAPHY_VARIANTS } from '@elliemae/ds-typography';\nimport React from 'react';\nimport type { DSCardNavigationT } from '../../react-desc-prop-types.js';\nimport { IconAndTextsRegionContent } from './IconAndTextsRegionContent.js';\n\ntype TooltipTextProps = DSTooltipV3T.CustomInterface<{\n title: string;\n description: string;\n}>;\n\nconst TooltipText: React.ComponentType<TooltipTextProps> = ({ title, description }) => (\n <Grid>\n <DSTypography variant={TYPOGRAPHY_VARIANTS.H5_ARTICLE}>{title}</DSTypography>\n <DSTypography variant={TYPOGRAPHY_VARIANTS.B1}>{description}</DSTypography>\n </Grid>\n);\n\ninterface IconAndTextsRegionProps {\n title: DSCardNavigationT.InternalProps['title'];\n description: DSCardNavigationT.InternalProps['description'];\n wrapText: DSCardNavigationT.InternalProps['wrapText'];\n type: DSCardNavigationT.InternalProps['type'];\n Icon: DSCardNavigationT.InternalProps['Icon'];\n showFocusRingAroundAll: React.FocusEventHandler<HTMLDivElement>;\n hideFocusRingAroundAll: React.FocusEventHandler<HTMLDivElement>;\n}\n\nexport const IconAndTextsRegion: React.ComponentType<IconAndTextsRegionProps> = ({\n title,\n description,\n wrapText,\n type,\n Icon,\n showFocusRingAroundAll,\n hideFocusRingAroundAll,\n}) => {\n const [isTitleTruncating, setIsTitleTruncating] = React.useState(false);\n const [isDescriptionTruncating, setIsDescriptionTruncating] = React.useState(false);\n\n const AnyOverFlow = isTitleTruncating || isDescriptionTruncating;\n\n const { handleRef: titleHandleRef } = useOnOverflowChange({\n onOverflowStateChange: setIsTitleTruncating,\n });\n\n const { handleRef: descriptionHandleRef } = useOnOverflowChange({\n onOverflowStateChange: setIsDescriptionTruncating,\n });\n const TooltipTextProps = React.useMemo(\n () => ({\n title,\n description,\n }),\n [title, description],\n );\n\n if (AnyOverFlow)\n return (\n <DSTooltipV3<TooltipTextProps> Text={TooltipText} textProps={TooltipTextProps}>\n <IconAndTextsRegionContent\n title={title}\n description={description}\n wrapText={wrapText}\n type={type}\n Icon={Icon}\n titleHandleRef={titleHandleRef}\n descriptionHandleRef={descriptionHandleRef}\n showFocusRingAroundAll={showFocusRingAroundAll}\n hideFocusRingAroundAll={hideFocusRingAroundAll}\n />\n </DSTooltipV3>\n );\n return (\n <IconAndTextsRegionContent\n title={title}\n description={description}\n wrapText={wrapText}\n type={type}\n Icon={Icon}\n titleHandleRef={titleHandleRef}\n descriptionHandleRef={descriptionHandleRef}\n showFocusRingAroundAll={showFocusRingAroundAll}\n hideFocusRingAroundAll={hideFocusRingAroundAll}\n />\n );\n};\n"],
|
|
5
|
-
"mappings": "AAAA,YAAY,WAAW;ACerB,SACE,KADF;AAfF,SAAS,YAAY;AACrB,SAAS,2BAA2B;AAEpC,SAAS,mBAAmB;AAC5B,SAAS,cAAc,2BAA2B;AAClD,OAAOA,YAAW;AAElB,SAAS,iCAAiC;AAO1C,MAAM,cAAqD,CAAC,EAAE,OAAO,YAAY,MAC/E,qBAAC,QACC;AAAA,sBAAC,gBAAa,SAAS,oBAAoB,YAAa,iBAAM;AAAA,EAC9D,oBAAC,gBAAa,SAAS,oBAAoB,IAAK,uBAAY;AAAA,GAC9D;
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { Grid } from '@elliemae/ds-grid';\nimport { useOnOverflowChange } from '@elliemae/ds-hooks-on-overflow-change';\nimport type { DSTooltipV3T } from '@elliemae/ds-tooltip-v3';\nimport { DSTooltipV3 } from '@elliemae/ds-tooltip-v3';\nimport { DSTypography, TYPOGRAPHY_VARIANTS } from '@elliemae/ds-typography';\nimport React from 'react';\nimport type { DSCardNavigationT } from '../../react-desc-prop-types.js';\nimport { IconAndTextsRegionContent } from './IconAndTextsRegionContent.js';\n\ntype TooltipTextProps = DSTooltipV3T.CustomInterface<{\n title: string;\n description: string;\n}>;\n\nconst TooltipText: React.ComponentType<TooltipTextProps> = ({ title, description }) => (\n <Grid>\n <DSTypography variant={TYPOGRAPHY_VARIANTS.H5_ARTICLE}>{title}</DSTypography>\n <DSTypography variant={TYPOGRAPHY_VARIANTS.B1}>{description}</DSTypography>\n </Grid>\n);\n\ninterface IconAndTextsRegionProps {\n title: DSCardNavigationT.InternalProps['title'];\n description: DSCardNavigationT.InternalProps['description'];\n wrapText: DSCardNavigationT.InternalProps['wrapText'];\n type: DSCardNavigationT.InternalProps['type'];\n Icon: DSCardNavigationT.InternalProps['Icon'];\n showFocusRingAroundAll: React.FocusEventHandler<HTMLDivElement>;\n hideFocusRingAroundAll: React.FocusEventHandler<HTMLDivElement>;\n getOwnerProps?: () => object;\n getOwnerPropsArguments?: () => object;\n}\n\nexport const IconAndTextsRegion: React.ComponentType<IconAndTextsRegionProps> = ({\n title,\n description,\n wrapText,\n type,\n Icon,\n showFocusRingAroundAll,\n hideFocusRingAroundAll,\n getOwnerProps,\n getOwnerPropsArguments,\n}) => {\n const [isTitleTruncating, setIsTitleTruncating] = React.useState(false);\n const [isDescriptionTruncating, setIsDescriptionTruncating] = React.useState(false);\n\n const AnyOverFlow = isTitleTruncating || isDescriptionTruncating;\n\n const { handleRef: titleHandleRef } = useOnOverflowChange({\n onOverflowStateChange: setIsTitleTruncating,\n });\n\n const { handleRef: descriptionHandleRef } = useOnOverflowChange({\n onOverflowStateChange: setIsDescriptionTruncating,\n });\n const TooltipTextProps = React.useMemo(\n () => ({\n title,\n description,\n }),\n [title, description],\n );\n\n if (AnyOverFlow)\n return (\n <DSTooltipV3<TooltipTextProps> Text={TooltipText} textProps={TooltipTextProps}>\n <IconAndTextsRegionContent\n title={title}\n description={description}\n wrapText={wrapText}\n type={type}\n Icon={Icon}\n titleHandleRef={titleHandleRef}\n descriptionHandleRef={descriptionHandleRef}\n showFocusRingAroundAll={showFocusRingAroundAll}\n hideFocusRingAroundAll={hideFocusRingAroundAll}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n />\n </DSTooltipV3>\n );\n return (\n <IconAndTextsRegionContent\n title={title}\n description={description}\n wrapText={wrapText}\n type={type}\n Icon={Icon}\n titleHandleRef={titleHandleRef}\n descriptionHandleRef={descriptionHandleRef}\n showFocusRingAroundAll={showFocusRingAroundAll}\n hideFocusRingAroundAll={hideFocusRingAroundAll}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n />\n );\n};\n"],
|
|
5
|
+
"mappings": "AAAA,YAAY,WAAW;ACerB,SACE,KADF;AAfF,SAAS,YAAY;AACrB,SAAS,2BAA2B;AAEpC,SAAS,mBAAmB;AAC5B,SAAS,cAAc,2BAA2B;AAClD,OAAOA,YAAW;AAElB,SAAS,iCAAiC;AAO1C,MAAM,cAAqD,CAAC,EAAE,OAAO,YAAY,MAC/E,qBAAC,QACC;AAAA,sBAAC,gBAAa,SAAS,oBAAoB,YAAa,iBAAM;AAAA,EAC9D,oBAAC,gBAAa,SAAS,oBAAoB,IAAK,uBAAY;AAAA,GAC9D;AAeK,MAAM,qBAAmE,CAAC;AAAA,EAC/E;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,MAAM;AACJ,QAAM,CAAC,mBAAmB,oBAAoB,IAAIA,OAAM,SAAS,KAAK;AACtE,QAAM,CAAC,yBAAyB,0BAA0B,IAAIA,OAAM,SAAS,KAAK;AAElF,QAAM,cAAc,qBAAqB;AAEzC,QAAM,EAAE,WAAW,eAAe,IAAI,oBAAoB;AAAA,IACxD,uBAAuB;AAAA,EACzB,CAAC;AAED,QAAM,EAAE,WAAW,qBAAqB,IAAI,oBAAoB;AAAA,IAC9D,uBAAuB;AAAA,EACzB,CAAC;AACD,QAAM,mBAAmBA,OAAM;AAAA,IAC7B,OAAO;AAAA,MACL;AAAA,MACA;AAAA,IACF;AAAA,IACA,CAAC,OAAO,WAAW;AAAA,EACrB;AAEA,MAAI;AACF,WACE,oBAAC,eAA8B,MAAM,aAAa,WAAW,kBAC3D;AAAA,MAAC;AAAA;AAAA,QACC;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA;AAAA,IACF,GACF;AAEJ,SACE;AAAA,IAAC;AAAA;AAAA,MACC;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA;AAAA,EACF;AAEJ;",
|
|
6
6
|
"names": ["React"]
|
|
7
7
|
}
|
|
@@ -25,7 +25,9 @@ const IconAndTextsRegionContent = React2.memo((props) => {
|
|
|
25
25
|
type,
|
|
26
26
|
Icon,
|
|
27
27
|
showFocusRingAroundAll,
|
|
28
|
-
hideFocusRingAroundAll
|
|
28
|
+
hideFocusRingAroundAll,
|
|
29
|
+
getOwnerProps,
|
|
30
|
+
getOwnerPropsArguments
|
|
29
31
|
} = props;
|
|
30
32
|
return /* @__PURE__ */ jsxs(
|
|
31
33
|
StyledGridTextContainer,
|
|
@@ -35,29 +37,66 @@ const IconAndTextsRegionContent = React2.memo((props) => {
|
|
|
35
37
|
tabIndex: 0,
|
|
36
38
|
onFocus: showFocusRingAroundAll,
|
|
37
39
|
onBlur: hideFocusRingAroundAll,
|
|
40
|
+
getOwnerProps,
|
|
41
|
+
getOwnerPropsArguments,
|
|
38
42
|
children: [
|
|
39
|
-
/* @__PURE__ */ jsx(
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
43
|
+
/* @__PURE__ */ jsx(
|
|
44
|
+
StyledCardNavigationIcon,
|
|
45
|
+
{
|
|
46
|
+
$type: type,
|
|
47
|
+
role: "presentation",
|
|
48
|
+
getOwnerProps,
|
|
49
|
+
getOwnerPropsArguments,
|
|
50
|
+
children: /* @__PURE__ */ jsx(Icon, { size: "l", color: mainIconColor })
|
|
51
|
+
}
|
|
52
|
+
),
|
|
53
|
+
/* @__PURE__ */ jsx(
|
|
54
|
+
StyledCardNavigationCentralContent,
|
|
55
|
+
{
|
|
56
|
+
cols,
|
|
57
|
+
getOwnerProps,
|
|
58
|
+
getOwnerPropsArguments,
|
|
59
|
+
children: /* @__PURE__ */ jsx(StyledCardNavigationContent, { getOwnerProps, getOwnerPropsArguments, children: /* @__PURE__ */ jsxs(
|
|
60
|
+
StyledCardNavigationContentTitleWrapper,
|
|
61
|
+
{
|
|
62
|
+
getOwnerProps,
|
|
63
|
+
getOwnerPropsArguments,
|
|
64
|
+
children: [
|
|
65
|
+
/* @__PURE__ */ jsx(
|
|
66
|
+
StyledCardNavigationContentTitle,
|
|
67
|
+
{
|
|
68
|
+
getOwnerProps,
|
|
69
|
+
getOwnerPropsArguments,
|
|
70
|
+
children: /* @__PURE__ */ jsx(
|
|
71
|
+
StyledTitleTypography,
|
|
72
|
+
{
|
|
73
|
+
innerRef: titleHandleRef,
|
|
74
|
+
truncateWithEllipsis: !wrapText,
|
|
75
|
+
variant: TYPOGRAPHY_VARIANTS.B1,
|
|
76
|
+
getOwnerProps,
|
|
77
|
+
getOwnerPropsArguments,
|
|
78
|
+
children: title
|
|
79
|
+
}
|
|
80
|
+
)
|
|
81
|
+
}
|
|
82
|
+
),
|
|
83
|
+
/* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsx(
|
|
84
|
+
StyledDescriptionTypography,
|
|
85
|
+
{
|
|
86
|
+
innerRef: descriptionHandleRef,
|
|
87
|
+
truncateWithEllipsis: !wrapText,
|
|
88
|
+
variant: TYPOGRAPHY_VARIANTS.B1,
|
|
89
|
+
"data-testid": CARD_NAVIGATION_DATA_TESTID.DESCRIPTION_TEXT,
|
|
90
|
+
getOwnerProps,
|
|
91
|
+
getOwnerPropsArguments,
|
|
92
|
+
children: description
|
|
93
|
+
}
|
|
94
|
+
) })
|
|
95
|
+
]
|
|
96
|
+
}
|
|
97
|
+
) })
|
|
98
|
+
}
|
|
99
|
+
)
|
|
61
100
|
]
|
|
62
101
|
}
|
|
63
102
|
);
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../../../scripts/build/transpile/react-shim.js", "../../../../src/parts/text-region/IconAndTextsRegionContent.tsx"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import type { SvgIconT } from '@elliemae/ds-icons';\nimport { TYPOGRAPHY_VARIANTS } from '@elliemae/ds-typography';\nimport React from 'react';\nimport { CARD_NAVIGATION_DATA_TESTID } from '../../constants/index.js';\nimport type { DSCardNavigationT } from '../../react-desc-prop-types.js';\nimport {\n StyledCardNavigationCentralContent,\n StyledCardNavigationContent,\n StyledCardNavigationContentTitle,\n StyledCardNavigationContentTitleWrapper,\n StyledCardNavigationIcon,\n StyledDescriptionTypography,\n StyledGridTextContainer,\n StyledTitleTypography,\n} from '../style.js';\n\nconst mainIconColor = ['neutral', '0'] as SvgIconT.ColorType;\nconst cols = ['1fr'];\n\ninterface IconAndTextsRegionContentProps {\n title: DSCardNavigationT.InternalProps['title'];\n description: DSCardNavigationT.InternalProps['description'];\n wrapText: DSCardNavigationT.InternalProps['wrapText'];\n type: DSCardNavigationT.InternalProps['type'];\n Icon: DSCardNavigationT.InternalProps['Icon'];\n\n titleHandleRef: (node: HTMLElement | null) => void;\n descriptionHandleRef: (node: HTMLElement | null) => void;\n showFocusRingAroundAll: React.FocusEventHandler<HTMLDivElement>;\n hideFocusRingAroundAll: React.FocusEventHandler<HTMLDivElement>;\n}\n\nexport const IconAndTextsRegionContent = React.memo((props: IconAndTextsRegionContentProps) => {\n const {\n title,\n description,\n wrapText,\n titleHandleRef,\n descriptionHandleRef,\n type,\n Icon,\n showFocusRingAroundAll,\n hideFocusRingAroundAll,\n } = props;\n\n return (\n <StyledGridTextContainer\n data-type={type}\n role=\"button\"\n tabIndex={0}\n onFocus={showFocusRingAroundAll}\n onBlur={hideFocusRingAroundAll}\n >\n <StyledCardNavigationIcon
|
|
5
|
-
"mappings": "AAAA,YAAY,WAAW;
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import type { SvgIconT } from '@elliemae/ds-icons';\nimport { TYPOGRAPHY_VARIANTS } from '@elliemae/ds-typography';\nimport React from 'react';\nimport { CARD_NAVIGATION_DATA_TESTID } from '../../constants/index.js';\nimport type { DSCardNavigationT } from '../../react-desc-prop-types.js';\nimport {\n StyledCardNavigationCentralContent,\n StyledCardNavigationContent,\n StyledCardNavigationContentTitle,\n StyledCardNavigationContentTitleWrapper,\n StyledCardNavigationIcon,\n StyledDescriptionTypography,\n StyledGridTextContainer,\n StyledTitleTypography,\n} from '../style.js';\n\nconst mainIconColor = ['neutral', '0'] as SvgIconT.ColorType;\nconst cols = ['1fr'];\n\ninterface IconAndTextsRegionContentProps {\n title: DSCardNavigationT.InternalProps['title'];\n description: DSCardNavigationT.InternalProps['description'];\n wrapText: DSCardNavigationT.InternalProps['wrapText'];\n type: DSCardNavigationT.InternalProps['type'];\n Icon: DSCardNavigationT.InternalProps['Icon'];\n\n titleHandleRef: (node: HTMLElement | null) => void;\n descriptionHandleRef: (node: HTMLElement | null) => void;\n showFocusRingAroundAll: React.FocusEventHandler<HTMLDivElement>;\n hideFocusRingAroundAll: React.FocusEventHandler<HTMLDivElement>;\n getOwnerProps?: () => object;\n getOwnerPropsArguments?: () => object;\n}\n\nexport const IconAndTextsRegionContent = React.memo((props: IconAndTextsRegionContentProps) => {\n const {\n title,\n description,\n wrapText,\n titleHandleRef,\n descriptionHandleRef,\n type,\n Icon,\n showFocusRingAroundAll,\n hideFocusRingAroundAll,\n getOwnerProps,\n getOwnerPropsArguments,\n } = props;\n\n return (\n <StyledGridTextContainer\n data-type={type}\n role=\"button\"\n tabIndex={0}\n onFocus={showFocusRingAroundAll}\n onBlur={hideFocusRingAroundAll}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <StyledCardNavigationIcon\n $type={type}\n role=\"presentation\"\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <Icon size=\"l\" color={mainIconColor} />\n </StyledCardNavigationIcon>\n\n <StyledCardNavigationCentralContent\n cols={cols}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <StyledCardNavigationContent getOwnerProps={getOwnerProps} getOwnerPropsArguments={getOwnerPropsArguments}>\n <StyledCardNavigationContentTitleWrapper\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <StyledCardNavigationContentTitle\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <StyledTitleTypography\n innerRef={titleHandleRef}\n truncateWithEllipsis={!wrapText}\n variant={TYPOGRAPHY_VARIANTS.B1}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n {title}\n </StyledTitleTypography>\n </StyledCardNavigationContentTitle>\n <div>\n <StyledDescriptionTypography\n innerRef={descriptionHandleRef}\n truncateWithEllipsis={!wrapText}\n variant={TYPOGRAPHY_VARIANTS.B1}\n data-testid={CARD_NAVIGATION_DATA_TESTID.DESCRIPTION_TEXT}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n {description}\n </StyledDescriptionTypography>\n </div>\n </StyledCardNavigationContentTitleWrapper>\n </StyledCardNavigationContent>\n </StyledCardNavigationCentralContent>\n </StyledGridTextContainer>\n );\n});\n"],
|
|
5
|
+
"mappings": "AAAA,YAAY,WAAW;ACiEf,cASE,YATF;AAhER,SAAS,2BAA2B;AACpC,OAAOA,YAAW;AAClB,SAAS,mCAAmC;AAE5C;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACK;AAEP,MAAM,gBAAgB,CAAC,WAAW,GAAG;AACrC,MAAM,OAAO,CAAC,KAAK;AAiBZ,MAAM,4BAA4BA,OAAM,KAAK,CAAC,UAA0C;AAC7F,QAAM;AAAA,IACJ;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EACF,IAAI;AAEJ,SACE;AAAA,IAAC;AAAA;AAAA,MACC,aAAW;AAAA,MACX,MAAK;AAAA,MACL,UAAU;AAAA,MACV,SAAS;AAAA,MACT,QAAQ;AAAA,MACR;AAAA,MACA;AAAA,MAEA;AAAA;AAAA,UAAC;AAAA;AAAA,YACC,OAAO;AAAA,YACP,MAAK;AAAA,YACL;AAAA,YACA;AAAA,YAEA,8BAAC,QAAK,MAAK,KAAI,OAAO,eAAe;AAAA;AAAA,QACvC;AAAA,QAEA;AAAA,UAAC;AAAA;AAAA,YACC;AAAA,YACA;AAAA,YACA;AAAA,YAEA,8BAAC,+BAA4B,eAA8B,wBACzD;AAAA,cAAC;AAAA;AAAA,gBACC;AAAA,gBACA;AAAA,gBAEA;AAAA;AAAA,oBAAC;AAAA;AAAA,sBACC;AAAA,sBACA;AAAA,sBAEA;AAAA,wBAAC;AAAA;AAAA,0BACC,UAAU;AAAA,0BACV,sBAAsB,CAAC;AAAA,0BACvB,SAAS,oBAAoB;AAAA,0BAC7B;AAAA,0BACA;AAAA,0BAEC;AAAA;AAAA,sBACH;AAAA;AAAA,kBACF;AAAA,kBACA,oBAAC,SACC;AAAA,oBAAC;AAAA;AAAA,sBACC,UAAU;AAAA,sBACV,sBAAsB,CAAC;AAAA,sBACvB,SAAS,oBAAoB;AAAA,sBAC7B,eAAa,4BAA4B;AAAA,sBACzC;AAAA,sBACA;AAAA,sBAEC;AAAA;AAAA,kBACH,GACF;AAAA;AAAA;AAAA,YACF,GACF;AAAA;AAAA,QACF;AAAA;AAAA;AAAA,EACF;AAEJ,CAAC;",
|
|
6
6
|
"names": ["React"]
|
|
7
7
|
}
|
|
@@ -6,15 +6,26 @@ export declare const CARD_NAVIGATION_SLOTS: {
|
|
|
6
6
|
readonly TYPE: "type";
|
|
7
7
|
readonly CENTRAL_CONTENT: "central-content";
|
|
8
8
|
readonly INTERACTIVE_ELEMENT_REGION: "interactive-element-region";
|
|
9
|
+
readonly DESCRIPTION_TEXT: "description-text";
|
|
10
|
+
readonly TITLE_TYPOGRAPHY: "title-typography";
|
|
11
|
+
readonly TITLE_WRAPPER: "title-wrapper";
|
|
12
|
+
readonly CONTENT: "content";
|
|
13
|
+
readonly BUTTON_WRAPPER: "button-wrapper";
|
|
14
|
+
readonly ACTION_BUTTON: "action-button";
|
|
9
15
|
};
|
|
10
16
|
export declare const CARD_NAVIGATION_DATA_TESTID: {
|
|
11
17
|
DESCRIPTION_TEXT: string;
|
|
18
|
+
TITLE_TYPOGRAPHY: string;
|
|
19
|
+
ACTION_BUTTON: string;
|
|
12
20
|
ROOT: "ds-cardnavigation-root";
|
|
13
21
|
TITLE: "ds-cardnavigation-title";
|
|
14
22
|
ACTIONS: "ds-cardnavigation-actions";
|
|
15
23
|
TYPE: "ds-cardnavigation-type";
|
|
16
24
|
CENTRAL_CONTENT: "ds-cardnavigation-central-content";
|
|
17
25
|
INTERACTIVE_ELEMENT_REGION: "ds-cardnavigation-interactive-element-region";
|
|
26
|
+
TITLE_WRAPPER: "ds-cardnavigation-title-wrapper";
|
|
27
|
+
CONTENT: "ds-cardnavigation-content";
|
|
28
|
+
BUTTON_WRAPPER: "ds-cardnavigation-button-wrapper";
|
|
18
29
|
};
|
|
19
30
|
export declare const CardNavigationTypes: {
|
|
20
31
|
readonly BORROWER: "borrower";
|
package/dist/types/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { DSCardNavigation } from './DSCardNavigation.js';
|
|
2
2
|
export { DSCardNavigation, DSCardNavigationWithSchema } from './DSCardNavigation.js';
|
|
3
3
|
export { type DSCardNavigationT } from './react-desc-prop-types.js';
|
|
4
|
-
export { CARD_NAVIGATION_SLOTS, CARD_NAVIGATION_DATA_TESTID, CardNavigationTypesValues, CardNavigationTypes, } from './constants/index.js';
|
|
4
|
+
export { CARD_NAVIGATION_SLOTS, CARD_NAVIGATION_DATA_TESTID, CardNavigationTypesValues, CardNavigationTypes, DSCardNavigationName, } from './constants/index.js';
|
|
5
5
|
export default DSCardNavigation;
|
|
@@ -3,6 +3,8 @@ import type { DSCardNavigationT } from '../react-desc-prop-types.js';
|
|
|
3
3
|
interface ActionRegionProps {
|
|
4
4
|
actions: DSCardNavigationT.InternalProps['actions'];
|
|
5
5
|
instanceUid: string;
|
|
6
|
+
getOwnerProps?: () => object;
|
|
7
|
+
getOwnerPropsArguments?: () => object;
|
|
6
8
|
}
|
|
7
9
|
export declare const ActionsRegion: React.ComponentType<ActionRegionProps>;
|
|
8
10
|
export {};
|
|
@@ -21,6 +21,7 @@ interface StyledCardNavigationIconProps {
|
|
|
21
21
|
}
|
|
22
22
|
export declare const StyledCardNavigationIcon: import("styled-components").StyledComponent<"div", import("@elliemae/ds-system").Theme, StyledCardNavigationIconProps & import("@elliemae/ds-system").OwnerInterface & import("@elliemae/ds-system").InnerRefInterface<"div">, never>;
|
|
23
23
|
export declare const StyledCardNavigationActions: import("styled-components").StyledComponent<"div", import("@elliemae/ds-system").Theme, object & import("@elliemae/ds-system").OwnerInterface & import("@elliemae/ds-system").InnerRefInterface<"div">, never>;
|
|
24
|
-
export declare const
|
|
24
|
+
export declare const StyledCardNavigationButtonWrapper: import("styled-components").StyledComponent<"div", import("@elliemae/ds-system").Theme, object & import("@elliemae/ds-system").OwnerInterface & import("@elliemae/ds-system").InnerRefInterface<"div">, never>;
|
|
25
25
|
export declare const StyledGridTextContainer: import("styled-components").StyledComponent<"div", import("@elliemae/ds-system").Theme, object & import("@elliemae/ds-system").OwnerInterface & import("@elliemae/ds-system").InnerRefInterface<"div">, never>;
|
|
26
|
+
export declare const StyledCardNavigationActionButton: import("styled-components").StyledComponent<import("react").ComponentType<import("@elliemae/ds-button-v2").DSButtonV3T.Props>, import("@elliemae/ds-system").Theme, object & import("@elliemae/ds-system").OwnerInterface & import("@elliemae/ds-system").InnerRefInterface<import("react").ComponentType<import("@elliemae/ds-button-v2").DSButtonV3T.Props>>, never>;
|
|
26
27
|
export {};
|
|
@@ -8,6 +8,8 @@ interface IconAndTextsRegionProps {
|
|
|
8
8
|
Icon: DSCardNavigationT.InternalProps['Icon'];
|
|
9
9
|
showFocusRingAroundAll: React.FocusEventHandler<HTMLDivElement>;
|
|
10
10
|
hideFocusRingAroundAll: React.FocusEventHandler<HTMLDivElement>;
|
|
11
|
+
getOwnerProps?: () => object;
|
|
12
|
+
getOwnerPropsArguments?: () => object;
|
|
11
13
|
}
|
|
12
14
|
export declare const IconAndTextsRegion: React.ComponentType<IconAndTextsRegionProps>;
|
|
13
15
|
export {};
|
|
@@ -10,6 +10,8 @@ interface IconAndTextsRegionContentProps {
|
|
|
10
10
|
descriptionHandleRef: (node: HTMLElement | null) => void;
|
|
11
11
|
showFocusRingAroundAll: React.FocusEventHandler<HTMLDivElement>;
|
|
12
12
|
hideFocusRingAroundAll: React.FocusEventHandler<HTMLDivElement>;
|
|
13
|
+
getOwnerProps?: () => object;
|
|
14
|
+
getOwnerPropsArguments?: () => object;
|
|
13
15
|
}
|
|
14
16
|
export declare const IconAndTextsRegionContent: React.MemoExoticComponent<(props: IconAndTextsRegionContentProps) => import("react/jsx-runtime.js").JSX.Element>;
|
|
15
17
|
export {};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@elliemae/ds-card-navigation",
|
|
3
|
-
"version": "3.55.0-next.
|
|
3
|
+
"version": "3.55.0-next.26",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"description": "ICE MT - Dimsum - Card Navigation",
|
|
6
6
|
"files": [
|
|
@@ -37,22 +37,27 @@
|
|
|
37
37
|
},
|
|
38
38
|
"dependencies": {
|
|
39
39
|
"@xstyled/styled-components": "~3.7.3",
|
|
40
|
-
"
|
|
41
|
-
"@elliemae/ds-
|
|
42
|
-
"@elliemae/ds-
|
|
43
|
-
"@elliemae/ds-hooks-on-
|
|
44
|
-
"@elliemae/ds-
|
|
45
|
-
"@elliemae/ds-
|
|
40
|
+
"uid": "^2.0.2",
|
|
41
|
+
"@elliemae/ds-button-v2": "3.55.0-next.26",
|
|
42
|
+
"@elliemae/ds-hooks-on-overflow-change": "3.55.0-next.26",
|
|
43
|
+
"@elliemae/ds-hooks-on-blur-out": "3.55.0-next.26",
|
|
44
|
+
"@elliemae/ds-props-helpers": "3.55.0-next.26",
|
|
45
|
+
"@elliemae/ds-grid": "3.55.0-next.26",
|
|
46
|
+
"@elliemae/ds-icons": "3.55.0-next.26",
|
|
47
|
+
"@elliemae/ds-system": "3.55.0-next.26",
|
|
48
|
+
"@elliemae/ds-tooltip-v3": "3.55.0-next.26",
|
|
49
|
+
"@elliemae/ds-typography": "3.55.0-next.26"
|
|
46
50
|
},
|
|
47
51
|
"devDependencies": {
|
|
48
52
|
"@elliemae/pui-cli": "9.0.0-next.65",
|
|
49
53
|
"@playwright/experimental-ct-react": "^1.51.1",
|
|
54
|
+
"@xstyled/system": "~3.7.3",
|
|
50
55
|
"jest": "~29.7.0",
|
|
51
56
|
"styled-components": "~5.3.9",
|
|
52
|
-
"@elliemae/ds-monorepo-devops": "3.55.0-next.
|
|
53
|
-
"@elliemae/ds-
|
|
54
|
-
"@elliemae/ds-
|
|
55
|
-
"@elliemae/ds-
|
|
57
|
+
"@elliemae/ds-monorepo-devops": "3.55.0-next.26",
|
|
58
|
+
"@elliemae/ds-test-utils": "3.55.0-next.26",
|
|
59
|
+
"@elliemae/ds-typescript-helpers": "3.55.0-next.26",
|
|
60
|
+
"@elliemae/ds-icons": "3.55.0-next.26"
|
|
56
61
|
},
|
|
57
62
|
"peerDependencies": {
|
|
58
63
|
"@testing-library/jest-dom": "^6.6.3",
|