@elliemae/ds-card-navigation 3.0.0-alpha.0 → 3.0.0-alpha.1
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 +57 -24
- package/dist/cjs/DSCardNavigation.js.map +1 -1
- package/dist/esm/DSCardNavigation.js +59 -24
- package/dist/esm/DSCardNavigation.js.map +1 -1
- package/package.json +5 -4
- package/dist/types/DSCardNavigation.d.ts +0 -69
- package/dist/types/components/types.d.ts +0 -7
- package/dist/types/index.d.ts +0 -2
- package/dist/types/style.d.ts +0 -9
- package/dist/types/tests/DSCardNavigation.test.d.ts +0 -1
|
@@ -1,10 +1,39 @@
|
|
|
1
1
|
var __create = Object.create;
|
|
2
2
|
var __defProp = Object.defineProperty;
|
|
3
|
+
var __defProps = Object.defineProperties;
|
|
3
4
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
4
6
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
7
|
+
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
5
8
|
var __getProtoOf = Object.getPrototypeOf;
|
|
6
9
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
10
|
+
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
11
|
+
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
12
|
+
var __spreadValues = (a, b) => {
|
|
13
|
+
for (var prop in b || (b = {}))
|
|
14
|
+
if (__hasOwnProp.call(b, prop))
|
|
15
|
+
__defNormalProp(a, prop, b[prop]);
|
|
16
|
+
if (__getOwnPropSymbols)
|
|
17
|
+
for (var prop of __getOwnPropSymbols(b)) {
|
|
18
|
+
if (__propIsEnum.call(b, prop))
|
|
19
|
+
__defNormalProp(a, prop, b[prop]);
|
|
20
|
+
}
|
|
21
|
+
return a;
|
|
22
|
+
};
|
|
23
|
+
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
7
24
|
var __markAsModule = (target) => __defProp(target, "__esModule", { value: true });
|
|
25
|
+
var __objRest = (source, exclude) => {
|
|
26
|
+
var target = {};
|
|
27
|
+
for (var prop in source)
|
|
28
|
+
if (__hasOwnProp.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
29
|
+
target[prop] = source[prop];
|
|
30
|
+
if (source != null && __getOwnPropSymbols)
|
|
31
|
+
for (var prop of __getOwnPropSymbols(source)) {
|
|
32
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum.call(source, prop))
|
|
33
|
+
target[prop] = source[prop];
|
|
34
|
+
}
|
|
35
|
+
return target;
|
|
36
|
+
};
|
|
8
37
|
var __export = (target, all) => {
|
|
9
38
|
for (var name in all)
|
|
10
39
|
__defProp(target, name, { get: all[name], enumerable: true });
|
|
@@ -40,30 +69,34 @@ var import_ds_icons = require("@elliemae/ds-icons");
|
|
|
40
69
|
var import_ds_button = __toESM(require("@elliemae/ds-button"));
|
|
41
70
|
var import_style = require("./style");
|
|
42
71
|
var import_types = require("./components/types");
|
|
43
|
-
const DSCardNavigation = (
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
}, /* @__PURE__ */ import_react.default.createElement(import_style.StyledCardNavigationIcon, {
|
|
49
|
-
|
|
50
|
-
}, /* @__PURE__ */ import_react.default.createElement(Icon, {
|
|
51
|
-
|
|
52
|
-
})), /* @__PURE__ */ import_react.default.createElement(import_style.StyledCardNavigationCentralContent, null, /* @__PURE__ */ import_react.default.createElement(import_style.StyledCardNavigationContent, null, /* @__PURE__ */ import_react.default.createElement(import_style.StyledCardNavigationContentTitleWrapper, null, /* @__PURE__ */ import_react.default.createElement(import_style.StyledCardNavigationContentTitle, null, /* @__PURE__ */ import_react.default.createElement(import_ds_truncated_tooltip_text.DSTruncatedTooltipText, {
|
|
53
|
-
|
|
54
|
-
})), /* @__PURE__ */ import_react.default.createElement(import_style.StyledCardNavigationContentDescription, null, /* @__PURE__ */ import_react.default.createElement(import_ds_truncated_tooltip_text.DSTruncatedTooltipText, {
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
})))), actions.length > 0 && /* @__PURE__ */ import_react.default.createElement(import_style.StyledCardNavigationActions, null, actions.map((
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
72
|
+
const DSCardNavigation = (_a) => {
|
|
73
|
+
var _b = _a, { containerProps = {}, title = "", description = "", type, Icon, actions = [] } = _b, rest = __objRest(_b, ["containerProps", "title", "description", "type", "Icon", "actions"]);
|
|
74
|
+
return /* @__PURE__ */ import_react.default.createElement(import_ds_truncated_tooltip_text.TooltipTextProvider, null, /* @__PURE__ */ import_react.default.createElement(import_style.StyledCardNavigationBoxWrapper, __spreadValues(__spreadValues({
|
|
75
|
+
role: "button",
|
|
76
|
+
tabIndex: 0
|
|
77
|
+
}, rest), containerProps), /* @__PURE__ */ import_react.default.createElement(import_style.StyledCardNavigationIcon, {
|
|
78
|
+
type
|
|
79
|
+
}, /* @__PURE__ */ import_react.default.createElement(Icon, {
|
|
80
|
+
size: "l"
|
|
81
|
+
})), /* @__PURE__ */ import_react.default.createElement(import_style.StyledCardNavigationCentralContent, null, /* @__PURE__ */ import_react.default.createElement(import_style.StyledCardNavigationContent, null, /* @__PURE__ */ import_react.default.createElement(import_style.StyledCardNavigationContentTitleWrapper, null, /* @__PURE__ */ import_react.default.createElement(import_style.StyledCardNavigationContentTitle, null, /* @__PURE__ */ import_react.default.createElement(import_ds_truncated_tooltip_text.DSTruncatedTooltipText, {
|
|
82
|
+
value: title
|
|
83
|
+
})), /* @__PURE__ */ import_react.default.createElement(import_style.StyledCardNavigationContentDescription, null, /* @__PURE__ */ import_react.default.createElement(import_ds_truncated_tooltip_text.DSTruncatedTooltipText, {
|
|
84
|
+
value: description,
|
|
85
|
+
"data-testid": "ds-card-navigation--description"
|
|
86
|
+
})))), actions.length > 0 && /* @__PURE__ */ import_react.default.createElement(import_style.StyledCardNavigationActions, null, actions.map((_a2, key) => {
|
|
87
|
+
var _b2 = _a2, { icon = /* @__PURE__ */ import_react.default.createElement(import_ds_icons.MoreOptionsVert, {
|
|
88
|
+
"aria-label": "More options"
|
|
89
|
+
}) } = _b2, otherProps = __objRest(_b2, ["icon"]);
|
|
90
|
+
return /* @__PURE__ */ import_react.default.createElement(import_style.StyledCardNavigationAction, {
|
|
91
|
+
key
|
|
92
|
+
}, /* @__PURE__ */ import_react.default.createElement(import_ds_button.default, __spreadProps(__spreadValues({
|
|
93
|
+
icon
|
|
94
|
+
}, otherProps), {
|
|
95
|
+
buttonType: import_ds_button.BUTTON_TYPE.TEXT,
|
|
96
|
+
size: import_ds_button.BUTTON_SIZE.L
|
|
97
|
+
})));
|
|
98
|
+
})))));
|
|
99
|
+
};
|
|
67
100
|
DSCardNavigation.defaultProps = {
|
|
68
101
|
type: import_types.CardNavigationTypes.BORROWER,
|
|
69
102
|
Icon: import_ds_icons.LoanProducts
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/DSCardNavigation.tsx", "../../../../scripts/build/transpile/react-shim.js"],
|
|
4
4
|
"sourcesContent": ["import React from 'react';\nimport { PropTypes, describe } from 'react-desc';\nimport { DSTruncatedTooltipText, TooltipTextProvider } from '@elliemae/ds-truncated-tooltip-text';\nimport { MoreOptionsVert, LoanProducts } from '@elliemae/ds-icons';\nimport DSButton, { BUTTON_SIZE, BUTTON_TYPE } from '@elliemae/ds-button';\nimport {\n StyledCardNavigationContentTitle,\n StyledCardNavigationContentDescription,\n StyledCardNavigationContentTitleWrapper,\n StyledCardNavigationContent,\n StyledCardNavigationCentralContent,\n StyledCardNavigationBoxWrapper,\n StyledCardNavigationIcon,\n StyledCardNavigationAction,\n StyledCardNavigationActions,\n} from './style';\nimport { CardNavigationTypes, CardNavigationTypesValues } from './components/types';\n\nconst DSCardNavigation = ({ containerProps = {}, title = '', description = '', type, Icon, actions = [], ...rest }) => (\n <TooltipTextProvider>\n <StyledCardNavigationBoxWrapper role=\"button\" tabIndex={0} {...rest} {...containerProps}>\n <StyledCardNavigationIcon type={type}>\n <Icon size=\"l\" />\n </StyledCardNavigationIcon>\n <StyledCardNavigationCentralContent>\n <StyledCardNavigationContent>\n <StyledCardNavigationContentTitleWrapper>\n <StyledCardNavigationContentTitle>\n <DSTruncatedTooltipText value={title} />\n </StyledCardNavigationContentTitle>\n <StyledCardNavigationContentDescription>\n <DSTruncatedTooltipText value={description} data-testid=\"ds-card-navigation--description\" />\n </StyledCardNavigationContentDescription>\n </StyledCardNavigationContentTitleWrapper>\n </StyledCardNavigationContent>\n {actions.length > 0 && (\n <StyledCardNavigationActions>\n {actions.map(({ icon = <MoreOptionsVert aria-label=\"More options\" />, ...otherProps }, key) => (\n <StyledCardNavigationAction key={key}>\n <DSButton icon={icon} {...otherProps} buttonType={BUTTON_TYPE.TEXT} size={BUTTON_SIZE.L} />\n </StyledCardNavigationAction>\n ))}\n </StyledCardNavigationActions>\n )}\n </StyledCardNavigationCentralContent>\n </StyledCardNavigationBoxWrapper>\n </TooltipTextProvider>\n);\n\nDSCardNavigation.defaultProps = {\n type: CardNavigationTypes.BORROWER,\n Icon: LoanProducts,\n};\n\nconst props = {\n /** props to inject to card navigation wrapper */\n containerProps: PropTypes.object.description('props to inject to card navigation wrapper'),\n /** card navigation title */\n title: PropTypes.string.description('card navigation title'),\n /** card navigation main icon */\n Icon: PropTypes.node.description('card navigation main icon'),\n /** card navigation description */\n description: PropTypes.string.description('card navigation description'),\n /** card navigation type */\n type: PropTypes.oneOf(CardNavigationTypesValues).description('card navigation type'),\n /** card navigation actions array */\n actions: PropTypes.arrayOf(\n PropTypes.shape({\n icon: PropTypes.element,\n onClick: PropTypes.func,\n }),\n ).description('card navigation actions array'),\n};\n\nDSCardNavigation.propTypes = props;\n\nconst DSCardNavigationWithSchema = describe(DSCardNavigation);\nDSCardNavigationWithSchema.propTypes = props;\n\nexport { CardNavigationTypes, CardNavigationTypesValues, DSCardNavigationWithSchema };\n\nexport default DSCardNavigation;\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,mBAAkB;AAClB,wBAAoC;AACpC,uCAA4D;AAC5D,sBAA8C;AAC9C,uBAAmD;AACnD,mBAUO;AACP,mBAA+D;AAE/D,MAAM,mBAAmB,CAAC,OAA0F;AAA1F,eAAE,mBAAiB,IAAI,QAAQ,IAAI,cAAc,IAAI,MAAM,MAAM,UAAU,OAA3E,IAAkF,iBAAlF,IAAkF,CAAhF,kBAAqB,SAAY,eAAkB,QAAM,QAAM;AACzF,4DAAC,sDAAD,MACE,mDAAC,6CAAD;AAAA,IAAgC,MAAK;AAAA,IAAS,UAAU;AAAA,KAAO,OAAU,iBACvE,mDAAC,uCAAD;AAAA,IAA0B;AAAA,KACxB,mDAAC,MAAD;AAAA,IAAM,MAAK;AAAA,OAEb,mDAAC,iDAAD,MACE,mDAAC,0CAAD,MACE,mDAAC,sDAAD,MACE,mDAAC,+CAAD,MACE,mDAAC,yDAAD;AAAA,IAAwB,OAAO;AAAA,OAEjC,mDAAC,qDAAD,MACE,mDAAC,yDAAD;AAAA,IAAwB,OAAO;AAAA,IAAa,eAAY;AAAA,SAI7D,QAAQ,SAAS,KAChB,mDAAC,0CAAD,MACG,QAAQ,IAAI,CAAC,KAAyE,QAAK;AAA9E,mBAAE,SAAO,mDAAC,iCAAD;AAAA,MAAiB,cAAW;AAAA,WAArC,KAA2D,uBAA3D,KAA2D,CAAzD;AACd,8DAAC,yCAAD;AAAA,MAA4B;AAAA,OAC1B,mDAAC,0BAAD;AAAA,MAAU;AAAA,OAAgB,aAA1B;AAAA,MAAsC,YAAY,6BAAY;AAAA,MAAM,MAAM,6BAAY;AAAA;AAAA;AAAA;AAUtG,iBAAiB,eAAe;AAAA,EAC9B,MAAM,iCAAoB;AAAA,EAC1B,MAAM;AAAA;AAGR,MAAM,QAAQ;AAAA,EAEZ,gBAAgB,4BAAU,OAAO,YAAY;AAAA,EAE7C,OAAO,4BAAU,OAAO,YAAY;AAAA,EAEpC,MAAM,4BAAU,KAAK,YAAY;AAAA,EAEjC,aAAa,4BAAU,OAAO,YAAY;AAAA,EAE1C,MAAM,4BAAU,MAAM,wCAA2B,YAAY;AAAA,EAE7D,SAAS,4BAAU,QACjB,4BAAU,MAAM;AAAA,IACd,MAAM,4BAAU;AAAA,IAChB,SAAS,4BAAU;AAAA,MAErB,YAAY;AAAA;AAGhB,iBAAiB,YAAY;AAE7B,MAAM,6BAA6B,gCAAS;AAC5C,2BAA2B,YAAY;AAIvC,IAAO,2BAAQ;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -1,3 +1,34 @@
|
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __defProps = Object.defineProperties;
|
|
3
|
+
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
4
|
+
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
7
|
+
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
8
|
+
var __spreadValues = (a, b) => {
|
|
9
|
+
for (var prop in b || (b = {}))
|
|
10
|
+
if (__hasOwnProp.call(b, prop))
|
|
11
|
+
__defNormalProp(a, prop, b[prop]);
|
|
12
|
+
if (__getOwnPropSymbols)
|
|
13
|
+
for (var prop of __getOwnPropSymbols(b)) {
|
|
14
|
+
if (__propIsEnum.call(b, prop))
|
|
15
|
+
__defNormalProp(a, prop, b[prop]);
|
|
16
|
+
}
|
|
17
|
+
return a;
|
|
18
|
+
};
|
|
19
|
+
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
20
|
+
var __objRest = (source, exclude) => {
|
|
21
|
+
var target = {};
|
|
22
|
+
for (var prop in source)
|
|
23
|
+
if (__hasOwnProp.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
24
|
+
target[prop] = source[prop];
|
|
25
|
+
if (source != null && __getOwnPropSymbols)
|
|
26
|
+
for (var prop of __getOwnPropSymbols(source)) {
|
|
27
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum.call(source, prop))
|
|
28
|
+
target[prop] = source[prop];
|
|
29
|
+
}
|
|
30
|
+
return target;
|
|
31
|
+
};
|
|
1
32
|
import * as React from "react";
|
|
2
33
|
import React2 from "react";
|
|
3
34
|
import { PropTypes, describe } from "react-desc";
|
|
@@ -16,30 +47,34 @@ import {
|
|
|
16
47
|
StyledCardNavigationActions
|
|
17
48
|
} from "./style";
|
|
18
49
|
import { CardNavigationTypes, CardNavigationTypesValues } from "./components/types";
|
|
19
|
-
const DSCardNavigation = (
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
}, /* @__PURE__ */ React2.createElement(StyledCardNavigationIcon, {
|
|
25
|
-
|
|
26
|
-
}, /* @__PURE__ */ React2.createElement(Icon, {
|
|
27
|
-
|
|
28
|
-
})), /* @__PURE__ */ React2.createElement(StyledCardNavigationCentralContent, null, /* @__PURE__ */ React2.createElement(StyledCardNavigationContent, null, /* @__PURE__ */ React2.createElement(StyledCardNavigationContentTitleWrapper, null, /* @__PURE__ */ React2.createElement(StyledCardNavigationContentTitle, null, /* @__PURE__ */ React2.createElement(DSTruncatedTooltipText, {
|
|
29
|
-
|
|
30
|
-
})), /* @__PURE__ */ React2.createElement(StyledCardNavigationContentDescription, null, /* @__PURE__ */ React2.createElement(DSTruncatedTooltipText, {
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
})))), actions.length > 0 && /* @__PURE__ */ React2.createElement(StyledCardNavigationActions, null, actions.map((
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
50
|
+
const DSCardNavigation = (_a) => {
|
|
51
|
+
var _b = _a, { containerProps = {}, title = "", description = "", type, Icon, actions = [] } = _b, rest = __objRest(_b, ["containerProps", "title", "description", "type", "Icon", "actions"]);
|
|
52
|
+
return /* @__PURE__ */ React2.createElement(TooltipTextProvider, null, /* @__PURE__ */ React2.createElement(StyledCardNavigationBoxWrapper, __spreadValues(__spreadValues({
|
|
53
|
+
role: "button",
|
|
54
|
+
tabIndex: 0
|
|
55
|
+
}, rest), containerProps), /* @__PURE__ */ React2.createElement(StyledCardNavigationIcon, {
|
|
56
|
+
type
|
|
57
|
+
}, /* @__PURE__ */ React2.createElement(Icon, {
|
|
58
|
+
size: "l"
|
|
59
|
+
})), /* @__PURE__ */ React2.createElement(StyledCardNavigationCentralContent, null, /* @__PURE__ */ React2.createElement(StyledCardNavigationContent, null, /* @__PURE__ */ React2.createElement(StyledCardNavigationContentTitleWrapper, null, /* @__PURE__ */ React2.createElement(StyledCardNavigationContentTitle, null, /* @__PURE__ */ React2.createElement(DSTruncatedTooltipText, {
|
|
60
|
+
value: title
|
|
61
|
+
})), /* @__PURE__ */ React2.createElement(StyledCardNavigationContentDescription, null, /* @__PURE__ */ React2.createElement(DSTruncatedTooltipText, {
|
|
62
|
+
value: description,
|
|
63
|
+
"data-testid": "ds-card-navigation--description"
|
|
64
|
+
})))), actions.length > 0 && /* @__PURE__ */ React2.createElement(StyledCardNavigationActions, null, actions.map((_a2, key) => {
|
|
65
|
+
var _b2 = _a2, { icon = /* @__PURE__ */ React2.createElement(MoreOptionsVert, {
|
|
66
|
+
"aria-label": "More options"
|
|
67
|
+
}) } = _b2, otherProps = __objRest(_b2, ["icon"]);
|
|
68
|
+
return /* @__PURE__ */ React2.createElement(StyledCardNavigationAction, {
|
|
69
|
+
key
|
|
70
|
+
}, /* @__PURE__ */ React2.createElement(DSButton, __spreadProps(__spreadValues({
|
|
71
|
+
icon
|
|
72
|
+
}, otherProps), {
|
|
73
|
+
buttonType: BUTTON_TYPE.TEXT,
|
|
74
|
+
size: BUTTON_SIZE.L
|
|
75
|
+
})));
|
|
76
|
+
})))));
|
|
77
|
+
};
|
|
43
78
|
DSCardNavigation.defaultProps = {
|
|
44
79
|
type: CardNavigationTypes.BORROWER,
|
|
45
80
|
Icon: LoanProducts
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../scripts/build/transpile/react-shim.js", "../../src/DSCardNavigation.tsx"],
|
|
4
4
|
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import React from 'react';\nimport { PropTypes, describe } from 'react-desc';\nimport { DSTruncatedTooltipText, TooltipTextProvider } from '@elliemae/ds-truncated-tooltip-text';\nimport { MoreOptionsVert, LoanProducts } from '@elliemae/ds-icons';\nimport DSButton, { BUTTON_SIZE, BUTTON_TYPE } from '@elliemae/ds-button';\nimport {\n StyledCardNavigationContentTitle,\n StyledCardNavigationContentDescription,\n StyledCardNavigationContentTitleWrapper,\n StyledCardNavigationContent,\n StyledCardNavigationCentralContent,\n StyledCardNavigationBoxWrapper,\n StyledCardNavigationIcon,\n StyledCardNavigationAction,\n StyledCardNavigationActions,\n} from './style';\nimport { CardNavigationTypes, CardNavigationTypesValues } from './components/types';\n\nconst DSCardNavigation = ({ containerProps = {}, title = '', description = '', type, Icon, actions = [], ...rest }) => (\n <TooltipTextProvider>\n <StyledCardNavigationBoxWrapper role=\"button\" tabIndex={0} {...rest} {...containerProps}>\n <StyledCardNavigationIcon type={type}>\n <Icon size=\"l\" />\n </StyledCardNavigationIcon>\n <StyledCardNavigationCentralContent>\n <StyledCardNavigationContent>\n <StyledCardNavigationContentTitleWrapper>\n <StyledCardNavigationContentTitle>\n <DSTruncatedTooltipText value={title} />\n </StyledCardNavigationContentTitle>\n <StyledCardNavigationContentDescription>\n <DSTruncatedTooltipText value={description} data-testid=\"ds-card-navigation--description\" />\n </StyledCardNavigationContentDescription>\n </StyledCardNavigationContentTitleWrapper>\n </StyledCardNavigationContent>\n {actions.length > 0 && (\n <StyledCardNavigationActions>\n {actions.map(({ icon = <MoreOptionsVert aria-label=\"More options\" />, ...otherProps }, key) => (\n <StyledCardNavigationAction key={key}>\n <DSButton icon={icon} {...otherProps} buttonType={BUTTON_TYPE.TEXT} size={BUTTON_SIZE.L} />\n </StyledCardNavigationAction>\n ))}\n </StyledCardNavigationActions>\n )}\n </StyledCardNavigationCentralContent>\n </StyledCardNavigationBoxWrapper>\n </TooltipTextProvider>\n);\n\nDSCardNavigation.defaultProps = {\n type: CardNavigationTypes.BORROWER,\n Icon: LoanProducts,\n};\n\nconst props = {\n /** props to inject to card navigation wrapper */\n containerProps: PropTypes.object.description('props to inject to card navigation wrapper'),\n /** card navigation title */\n title: PropTypes.string.description('card navigation title'),\n /** card navigation main icon */\n Icon: PropTypes.node.description('card navigation main icon'),\n /** card navigation description */\n description: PropTypes.string.description('card navigation description'),\n /** card navigation type */\n type: PropTypes.oneOf(CardNavigationTypesValues).description('card navigation type'),\n /** card navigation actions array */\n actions: PropTypes.arrayOf(\n PropTypes.shape({\n icon: PropTypes.element,\n onClick: PropTypes.func,\n }),\n ).description('card navigation actions array'),\n};\n\nDSCardNavigation.propTypes = props;\n\nconst DSCardNavigationWithSchema = describe(DSCardNavigation);\nDSCardNavigationWithSchema.propTypes = props;\n\nexport { CardNavigationTypes, CardNavigationTypesValues, DSCardNavigationWithSchema };\n\nexport default DSCardNavigation;\n"],
|
|
5
|
-
"mappings": "AAAA;ACAA;AACA;AACA;AACA;AACA;AACA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAWA;AAEA,MAAM,mBAAmB,CAAC,
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;ACAA;AACA;AACA;AACA;AACA;AACA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAWA;AAEA,MAAM,mBAAmB,CAAC,OAA0F;AAA1F,eAAE,mBAAiB,IAAI,QAAQ,IAAI,cAAc,IAAI,MAAM,MAAM,UAAU,OAA3E,IAAkF,iBAAlF,IAAkF,CAAhF,kBAAqB,SAAY,eAAkB,QAAM,QAAM;AACzF,8CAAC,qBAAD,MACE,qCAAC,gCAAD;AAAA,IAAgC,MAAK;AAAA,IAAS,UAAU;AAAA,KAAO,OAAU,iBACvE,qCAAC,0BAAD;AAAA,IAA0B;AAAA,KACxB,qCAAC,MAAD;AAAA,IAAM,MAAK;AAAA,OAEb,qCAAC,oCAAD,MACE,qCAAC,6BAAD,MACE,qCAAC,yCAAD,MACE,qCAAC,kCAAD,MACE,qCAAC,wBAAD;AAAA,IAAwB,OAAO;AAAA,OAEjC,qCAAC,wCAAD,MACE,qCAAC,wBAAD;AAAA,IAAwB,OAAO;AAAA,IAAa,eAAY;AAAA,SAI7D,QAAQ,SAAS,KAChB,qCAAC,6BAAD,MACG,QAAQ,IAAI,CAAC,KAAyE,QAAK;AAA9E,mBAAE,SAAO,qCAAC,iBAAD;AAAA,MAAiB,cAAW;AAAA,WAArC,KAA2D,uBAA3D,KAA2D,CAAzD;AACd,gDAAC,4BAAD;AAAA,MAA4B;AAAA,OAC1B,qCAAC,UAAD;AAAA,MAAU;AAAA,OAAgB,aAA1B;AAAA,MAAsC,YAAY,YAAY;AAAA,MAAM,MAAM,YAAY;AAAA;AAAA;AAAA;AAUtG,iBAAiB,eAAe;AAAA,EAC9B,MAAM,oBAAoB;AAAA,EAC1B,MAAM;AAAA;AAGR,MAAM,QAAQ;AAAA,EAEZ,gBAAgB,UAAU,OAAO,YAAY;AAAA,EAE7C,OAAO,UAAU,OAAO,YAAY;AAAA,EAEpC,MAAM,UAAU,KAAK,YAAY;AAAA,EAEjC,aAAa,UAAU,OAAO,YAAY;AAAA,EAE1C,MAAM,UAAU,MAAM,2BAA2B,YAAY;AAAA,EAE7D,SAAS,UAAU,QACjB,UAAU,MAAM;AAAA,IACd,MAAM,UAAU;AAAA,IAChB,SAAS,UAAU;AAAA,MAErB,YAAY;AAAA;AAGhB,iBAAiB,YAAY;AAE7B,MAAM,6BAA6B,SAAS;AAC5C,2BAA2B,YAAY;AAIvC,IAAO,2BAAQ;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@elliemae/ds-card-navigation",
|
|
3
|
-
"version": "3.0.0-alpha.
|
|
3
|
+
"version": "3.0.0-alpha.1",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"description": "ICE MT - Dimsum - Card Navigation",
|
|
6
6
|
"files": [
|
|
@@ -47,9 +47,9 @@
|
|
|
47
47
|
"indent": 4
|
|
48
48
|
},
|
|
49
49
|
"dependencies": {
|
|
50
|
-
"@elliemae/ds-button": "3.0.0-alpha.
|
|
51
|
-
"@elliemae/ds-icons": "3.0.0-alpha.
|
|
52
|
-
"@elliemae/ds-truncated-tooltip-text": "3.0.0-alpha.
|
|
50
|
+
"@elliemae/ds-button": "3.0.0-alpha.1",
|
|
51
|
+
"@elliemae/ds-icons": "3.0.0-alpha.1",
|
|
52
|
+
"@elliemae/ds-truncated-tooltip-text": "3.0.0-alpha.1",
|
|
53
53
|
"react-desc": "~4.1.3"
|
|
54
54
|
},
|
|
55
55
|
"devDependencies": {
|
|
@@ -73,6 +73,7 @@
|
|
|
73
73
|
"dev": "cross-env NODE_ENV=development node ../../scripts/build/build.mjs --watch",
|
|
74
74
|
"test": "node ../../scripts/testing/test.mjs",
|
|
75
75
|
"lint": "node ../../scripts/lint.mjs",
|
|
76
|
+
"dts": "node ../../scripts/dts.mjs",
|
|
76
77
|
"build": "cross-env NODE_ENV=production node ../../scripts/build/build.mjs"
|
|
77
78
|
}
|
|
78
79
|
}
|
|
@@ -1,69 +0,0 @@
|
|
|
1
|
-
/// <reference path="../../../../shared/typings/react-desc.d.ts" />
|
|
2
|
-
/// <reference types="react" />
|
|
3
|
-
import { CardNavigationTypes, CardNavigationTypesValues } from './components/types';
|
|
4
|
-
declare const DSCardNavigation: {
|
|
5
|
-
({ containerProps, title, description, type, Icon, actions, ...rest }: {
|
|
6
|
-
[x: string]: any;
|
|
7
|
-
containerProps?: {} | undefined;
|
|
8
|
-
title?: string | undefined;
|
|
9
|
-
description?: string | undefined;
|
|
10
|
-
type: any;
|
|
11
|
-
Icon: any;
|
|
12
|
-
actions?: never[] | undefined;
|
|
13
|
-
}): JSX.Element;
|
|
14
|
-
defaultProps: {
|
|
15
|
-
type: string;
|
|
16
|
-
Icon: (rest: any) => JSX.Element;
|
|
17
|
-
};
|
|
18
|
-
propTypes: {
|
|
19
|
-
/** props to inject to card navigation wrapper */
|
|
20
|
-
containerProps: {
|
|
21
|
-
defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
|
|
22
|
-
deprecated: import("react-desc").PropTypesDescValidator;
|
|
23
|
-
};
|
|
24
|
-
isRequired: import("react-desc").PropTypesDescValue;
|
|
25
|
-
};
|
|
26
|
-
/** card navigation title */
|
|
27
|
-
title: {
|
|
28
|
-
defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
|
|
29
|
-
deprecated: import("react-desc").PropTypesDescValidator;
|
|
30
|
-
};
|
|
31
|
-
isRequired: import("react-desc").PropTypesDescValue;
|
|
32
|
-
};
|
|
33
|
-
/** card navigation main icon */
|
|
34
|
-
Icon: {
|
|
35
|
-
defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
|
|
36
|
-
deprecated: import("react-desc").PropTypesDescValidator;
|
|
37
|
-
};
|
|
38
|
-
isRequired: import("react-desc").PropTypesDescValue;
|
|
39
|
-
};
|
|
40
|
-
/** card navigation description */
|
|
41
|
-
description: {
|
|
42
|
-
defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
|
|
43
|
-
deprecated: import("react-desc").PropTypesDescValidator;
|
|
44
|
-
};
|
|
45
|
-
isRequired: import("react-desc").PropTypesDescValue;
|
|
46
|
-
};
|
|
47
|
-
/** card navigation type */
|
|
48
|
-
type: {
|
|
49
|
-
defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
|
|
50
|
-
deprecated: import("react-desc").PropTypesDescValidator;
|
|
51
|
-
};
|
|
52
|
-
isRequired: import("react-desc").PropTypesDescValue;
|
|
53
|
-
};
|
|
54
|
-
/** card navigation actions array */
|
|
55
|
-
actions: {
|
|
56
|
-
defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
|
|
57
|
-
deprecated: import("react-desc").PropTypesDescValidator;
|
|
58
|
-
};
|
|
59
|
-
isRequired: import("react-desc").PropTypesDescValue;
|
|
60
|
-
};
|
|
61
|
-
};
|
|
62
|
-
};
|
|
63
|
-
declare const DSCardNavigationWithSchema: {
|
|
64
|
-
(props?: unknown): JSX.Element;
|
|
65
|
-
propTypes: unknown;
|
|
66
|
-
toTypescript: () => import("react-desc").TypescriptSchema;
|
|
67
|
-
};
|
|
68
|
-
export { CardNavigationTypes, CardNavigationTypesValues, DSCardNavigationWithSchema };
|
|
69
|
-
export default DSCardNavigation;
|
package/dist/types/index.d.ts
DELETED
package/dist/types/style.d.ts
DELETED
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
export declare const StyledCardNavigationContentTitle: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
|
|
2
|
-
export declare const StyledCardNavigationContentDescription: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
|
|
3
|
-
export declare const StyledCardNavigationContentTitleWrapper: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
|
|
4
|
-
export declare const StyledCardNavigationContent: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
|
|
5
|
-
export declare const StyledCardNavigationCentralContent: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
|
|
6
|
-
export declare const StyledCardNavigationBoxWrapper: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
|
|
7
|
-
export declare const StyledCardNavigationIcon: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
|
|
8
|
-
export declare const StyledCardNavigationActions: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
|
|
9
|
-
export declare const StyledCardNavigationAction: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|