@elliemae/ds-chat-empty-state 3.70.0-next.3 → 3.70.0-next.31
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/ChatEmptyState.js +54 -14
- package/dist/cjs/ChatEmptyState.js.map +2 -2
- package/dist/cjs/{DSChatEmptyStateDefinitions.js → constants/index.js} +18 -4
- package/dist/cjs/constants/index.js.map +7 -0
- package/dist/cjs/index.js +8 -1
- package/dist/cjs/index.js.map +2 -2
- package/dist/cjs/react-desc-prop-types.js +9 -3
- package/dist/cjs/react-desc-prop-types.js.map +2 -2
- package/dist/cjs/styled.js +30 -3
- package/dist/cjs/styled.js.map +2 -2
- package/dist/cjs/typescript-testing/slot-props.js +42 -0
- package/dist/cjs/typescript-testing/slot-props.js.map +7 -0
- package/dist/esm/ChatEmptyState.js +68 -16
- package/dist/esm/ChatEmptyState.js.map +2 -2
- package/dist/esm/constants/index.js +20 -0
- package/dist/esm/constants/index.js.map +7 -0
- package/dist/esm/index.js +8 -1
- package/dist/esm/index.js.map +2 -2
- package/dist/esm/react-desc-prop-types.js +15 -4
- package/dist/esm/react-desc-prop-types.js.map +2 -2
- package/dist/esm/styled.js +30 -3
- package/dist/esm/styled.js.map +2 -2
- package/dist/esm/typescript-testing/slot-props.js +19 -0
- package/dist/esm/typescript-testing/slot-props.js.map +7 -0
- package/dist/types/constants/index.d.ts +17 -0
- package/dist/types/index.d.ts +2 -0
- package/dist/types/react-desc-prop-types.d.ts +18 -7
- package/dist/types/styled.d.ts +4 -0
- package/dist/types/tests/DSChatEmptyState.a11y.test.d.ts +1 -0
- package/dist/types/tests/DSChatEmptyState.api.test.d.ts +1 -0
- package/dist/types/tests/DSChatEmptyState.data-testid.test.d.ts +1 -0
- package/dist/types/tests/DSChatEmptyState.events.test.d.ts +0 -0
- package/dist/types/tests/DSChatEmptyState.exports.test.d.ts +1 -0
- package/dist/types/tests/DSChatEmptyState.get-owner-props-arguments.test.d.ts +1 -0
- package/dist/types/tests/DSChatEmptyState.keyboard.test.d.ts +0 -0
- package/dist/types/tests/DSChatEmptyState.proptype-schema.test.d.ts +1 -0
- package/dist/types/typescript-testing/slot-props.d.ts +1 -0
- package/package.json +7 -7
- package/dist/cjs/DSChatEmptyStateDefinitions.js.map +0 -7
- package/dist/esm/DSChatEmptyStateDefinitions.js +0 -6
- package/dist/esm/DSChatEmptyStateDefinitions.js.map +0 -7
- package/dist/types/DSChatEmptyStateDefinitions.d.ts +0 -1
|
@@ -34,28 +34,68 @@ __export(ChatEmptyState_exports, {
|
|
|
34
34
|
module.exports = __toCommonJS(ChatEmptyState_exports);
|
|
35
35
|
var React = __toESM(require("react"));
|
|
36
36
|
var import_jsx_runtime = require("react/jsx-runtime");
|
|
37
|
-
var import_react = require("react");
|
|
38
37
|
var import_ds_props_helpers = require("@elliemae/ds-props-helpers");
|
|
39
|
-
var import_ds_grid = require("@elliemae/ds-grid");
|
|
40
38
|
var import_ds_icons = require("@elliemae/ds-icons");
|
|
41
39
|
var import_react_desc_prop_types = require("./react-desc-prop-types.js");
|
|
42
40
|
var import_styled = require("./styled.js");
|
|
43
|
-
var
|
|
41
|
+
var import_constants = require("./constants/index.js");
|
|
44
42
|
const ChatEmptyState = (props) => {
|
|
45
43
|
const propsWithDefault = (0, import_ds_props_helpers.useMemoMergePropsWithDefault)(props, import_react_desc_prop_types.defaultProps);
|
|
46
|
-
(0, import_ds_props_helpers.useValidateTypescriptPropTypes)(propsWithDefault, import_react_desc_prop_types.
|
|
44
|
+
(0, import_ds_props_helpers.useValidateTypescriptPropTypes)(propsWithDefault, import_react_desc_prop_types.DSChatEmptyStatePropTypes, import_constants.DSChatEmptyStateName);
|
|
45
|
+
const { getOwnerProps, getOwnerPropsArguments } = (0, import_ds_props_helpers.useOwnerProps)(propsWithDefault);
|
|
47
46
|
const { label, action } = propsWithDefault;
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
47
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
48
|
+
import_styled.ChatEmptyStateWrapper,
|
|
49
|
+
{
|
|
50
|
+
alignItems: "center",
|
|
51
|
+
justifyContent: "center",
|
|
52
|
+
getOwnerProps,
|
|
53
|
+
getOwnerPropsArguments,
|
|
54
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
|
|
55
|
+
import_styled.Content,
|
|
56
|
+
{
|
|
57
|
+
alignItems: "center",
|
|
58
|
+
justifyContent: "center",
|
|
59
|
+
getOwnerProps,
|
|
60
|
+
getOwnerPropsArguments,
|
|
61
|
+
children: [
|
|
62
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
63
|
+
import_styled.IconWrapper,
|
|
64
|
+
{
|
|
65
|
+
alignItems: "center",
|
|
66
|
+
justifyContent: "center",
|
|
67
|
+
getOwnerProps,
|
|
68
|
+
getOwnerPropsArguments,
|
|
69
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_ds_icons.Communications, { size: "xxl", color: ["neutral", "400"] })
|
|
70
|
+
}
|
|
71
|
+
),
|
|
72
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
73
|
+
import_styled.MessageWrapperGrid,
|
|
74
|
+
{
|
|
75
|
+
alignItems: "center",
|
|
76
|
+
justifyContent: "center",
|
|
77
|
+
getOwnerProps,
|
|
78
|
+
getOwnerPropsArguments,
|
|
79
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_styled.MessageWrapper, { getOwnerProps, getOwnerPropsArguments, children: label })
|
|
80
|
+
}
|
|
81
|
+
),
|
|
82
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
83
|
+
import_styled.ActionWrapper,
|
|
84
|
+
{
|
|
85
|
+
alignItems: "center",
|
|
86
|
+
justifyContent: "center",
|
|
87
|
+
getOwnerProps,
|
|
88
|
+
getOwnerPropsArguments,
|
|
89
|
+
children: action
|
|
90
|
+
}
|
|
91
|
+
)
|
|
92
|
+
]
|
|
93
|
+
}
|
|
94
|
+
)
|
|
95
|
+
}
|
|
55
96
|
);
|
|
56
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_styled.ChatEmptyStateWrapper, { alignItems: "center", justifyContent: "center", children: MainContent });
|
|
57
97
|
};
|
|
58
|
-
ChatEmptyState.displayName =
|
|
98
|
+
ChatEmptyState.displayName = import_constants.DSChatEmptyStateName;
|
|
59
99
|
const ChatEmptyStateWithSchema = (0, import_ds_props_helpers.describe)(ChatEmptyState);
|
|
60
|
-
ChatEmptyStateWithSchema.propTypes = import_react_desc_prop_types.
|
|
100
|
+
ChatEmptyStateWithSchema.propTypes = import_react_desc_prop_types.DSChatEmptyStatePropTypes;
|
|
61
101
|
//# sourceMappingURL=ChatEmptyState.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/ChatEmptyState.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
-
"sourcesContent": ["import
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;
|
|
4
|
+
"sourcesContent": ["import React from 'react';\nimport {\n describe,\n useValidateTypescriptPropTypes,\n useMemoMergePropsWithDefault,\n useOwnerProps,\n type ValidationMap,\n} from '@elliemae/ds-props-helpers';\nimport { Communications } from '@elliemae/ds-icons';\nimport type { DSChatEmptyStateT } from './react-desc-prop-types.js';\nimport { DSChatEmptyStatePropTypes, defaultProps } from './react-desc-prop-types.js';\nimport {\n ChatEmptyStateWrapper,\n Content,\n IconWrapper,\n MessageWrapperGrid,\n MessageWrapper,\n ActionWrapper,\n} from './styled.js';\nimport { DSChatEmptyStateName } from './constants/index.js';\n\nconst ChatEmptyState: React.ComponentType<DSChatEmptyStateT.Props> = (props) => {\n const propsWithDefault = useMemoMergePropsWithDefault<DSChatEmptyStateT.InternalProps>(props, defaultProps);\n useValidateTypescriptPropTypes(propsWithDefault, DSChatEmptyStatePropTypes, DSChatEmptyStateName);\n const { getOwnerProps, getOwnerPropsArguments } = useOwnerProps<DSChatEmptyStateT.Props>(propsWithDefault);\n\n const { label, action } = propsWithDefault;\n return (\n <ChatEmptyStateWrapper\n alignItems=\"center\"\n justifyContent=\"center\"\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <Content\n alignItems=\"center\"\n justifyContent=\"center\"\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <IconWrapper\n alignItems=\"center\"\n justifyContent=\"center\"\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <Communications size=\"xxl\" color={['neutral', '400']} />\n </IconWrapper>\n <MessageWrapperGrid\n alignItems=\"center\"\n justifyContent=\"center\"\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <MessageWrapper getOwnerProps={getOwnerProps} getOwnerPropsArguments={getOwnerPropsArguments}>\n {label}\n </MessageWrapper>\n </MessageWrapperGrid>\n <ActionWrapper\n alignItems=\"center\"\n justifyContent=\"center\"\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n {action}\n </ActionWrapper>\n </Content>\n </ChatEmptyStateWrapper>\n );\n};\n\nChatEmptyState.displayName = DSChatEmptyStateName;\nconst ChatEmptyStateWithSchema = describe(ChatEmptyState);\nChatEmptyStateWithSchema.propTypes = DSChatEmptyStatePropTypes as ValidationMap<unknown>;\n\nexport { ChatEmptyState, ChatEmptyStateWithSchema };\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADkCjB;AAjCN,8BAMO;AACP,sBAA+B;AAE/B,mCAAwD;AACxD,oBAOO;AACP,uBAAqC;AAErC,MAAM,iBAA+D,CAAC,UAAU;AAC9E,QAAM,uBAAmB,sDAA8D,OAAO,yCAAY;AAC1G,8DAA+B,kBAAkB,wDAA2B,qCAAoB;AAChG,QAAM,EAAE,eAAe,uBAAuB,QAAI,uCAAuC,gBAAgB;AAEzG,QAAM,EAAE,OAAO,OAAO,IAAI;AAC1B,SACE;AAAA,IAAC;AAAA;AAAA,MACC,YAAW;AAAA,MACX,gBAAe;AAAA,MACf;AAAA,MACA;AAAA,MAEA;AAAA,QAAC;AAAA;AAAA,UACC,YAAW;AAAA,UACX,gBAAe;AAAA,UACf;AAAA,UACA;AAAA,UAEA;AAAA;AAAA,cAAC;AAAA;AAAA,gBACC,YAAW;AAAA,gBACX,gBAAe;AAAA,gBACf;AAAA,gBACA;AAAA,gBAEA,sDAAC,kCAAe,MAAK,OAAM,OAAO,CAAC,WAAW,KAAK,GAAG;AAAA;AAAA,YACxD;AAAA,YACA;AAAA,cAAC;AAAA;AAAA,gBACC,YAAW;AAAA,gBACX,gBAAe;AAAA,gBACf;AAAA,gBACA;AAAA,gBAEA,sDAAC,gCAAe,eAA8B,wBAC3C,iBACH;AAAA;AAAA,YACF;AAAA,YACA;AAAA,cAAC;AAAA;AAAA,gBACC,YAAW;AAAA,gBACX,gBAAe;AAAA,gBACf;AAAA,gBACA;AAAA,gBAEC;AAAA;AAAA,YACH;AAAA;AAAA;AAAA,MACF;AAAA;AAAA,EACF;AAEJ;AAEA,eAAe,cAAc;AAC7B,MAAM,+BAA2B,kCAAS,cAAc;AACxD,yBAAyB,YAAY;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -26,11 +26,25 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
|
|
|
26
26
|
mod
|
|
27
27
|
));
|
|
28
28
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
|
-
var
|
|
30
|
-
__export(
|
|
29
|
+
var constants_exports = {};
|
|
30
|
+
__export(constants_exports, {
|
|
31
|
+
CHAT_EMPTY_STATE_DATA_TESTID: () => CHAT_EMPTY_STATE_DATA_TESTID,
|
|
32
|
+
CHAT_EMPTY_STATE_SLOTS: () => CHAT_EMPTY_STATE_SLOTS,
|
|
31
33
|
DSChatEmptyStateName: () => DSChatEmptyStateName
|
|
32
34
|
});
|
|
33
|
-
module.exports = __toCommonJS(
|
|
35
|
+
module.exports = __toCommonJS(constants_exports);
|
|
34
36
|
var React = __toESM(require("react"));
|
|
37
|
+
var import_ds_system = require("@elliemae/ds-system");
|
|
35
38
|
const DSChatEmptyStateName = "DSChatemptystate";
|
|
36
|
-
|
|
39
|
+
const CHAT_EMPTY_STATE_SLOTS = {
|
|
40
|
+
ROOT: "root",
|
|
41
|
+
CONTENT: "content",
|
|
42
|
+
ICON_WRAPPER: "icon-wrapper",
|
|
43
|
+
MESSAGE_WRAPPER: "message-wrapper",
|
|
44
|
+
MESSAGE: "message",
|
|
45
|
+
ACTION_WRAPPER: "action-wrapper"
|
|
46
|
+
};
|
|
47
|
+
const CHAT_EMPTY_STATE_DATA_TESTID = {
|
|
48
|
+
...(0, import_ds_system.slotObjectToDataTestIds)(DSChatEmptyStateName, CHAT_EMPTY_STATE_SLOTS)
|
|
49
|
+
};
|
|
50
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/constants/index.ts", "../../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
+
"sourcesContent": ["import { slotObjectToDataTestIds } from '@elliemae/ds-system';\n\nexport const DSChatEmptyStateName = 'DSChatemptystate';\n\n// we are naming this with the ${component_name}_slots convention to namespace & avoid errors on duplicate exports variables in aggregators\nexport const CHAT_EMPTY_STATE_SLOTS = {\n ROOT: 'root',\n CONTENT: 'content',\n ICON_WRAPPER: 'icon-wrapper',\n MESSAGE_WRAPPER: 'message-wrapper',\n MESSAGE: 'message',\n ACTION_WRAPPER: 'action-wrapper',\n} as const;\n\nexport const CHAT_EMPTY_STATE_DATA_TESTID = {\n ...slotObjectToDataTestIds(DSChatEmptyStateName, CHAT_EMPTY_STATE_SLOTS),\n};\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,uBAAwC;AAEjC,MAAM,uBAAuB;AAG7B,MAAM,yBAAyB;AAAA,EACpC,MAAM;AAAA,EACN,SAAS;AAAA,EACT,cAAc;AAAA,EACd,iBAAiB;AAAA,EACjB,SAAS;AAAA,EACT,gBAAgB;AAClB;AAEO,MAAM,+BAA+B;AAAA,EAC1C,OAAG,0CAAwB,sBAAsB,sBAAsB;AACzE;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
package/dist/cjs/index.js
CHANGED
|
@@ -28,10 +28,17 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
|
|
|
28
28
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
29
|
var index_exports = {};
|
|
30
30
|
__export(index_exports, {
|
|
31
|
+
CHAT_EMPTY_STATE_DATA_TESTID: () => import_constants.CHAT_EMPTY_STATE_DATA_TESTID,
|
|
32
|
+
CHAT_EMPTY_STATE_SLOTS: () => import_constants.CHAT_EMPTY_STATE_SLOTS,
|
|
31
33
|
ChatEmptyState: () => import_ChatEmptyState.ChatEmptyState,
|
|
32
|
-
ChatEmptyStateWithSchema: () => import_ChatEmptyState.ChatEmptyStateWithSchema
|
|
34
|
+
ChatEmptyStateWithSchema: () => import_ChatEmptyState.ChatEmptyStateWithSchema,
|
|
35
|
+
DSChatEmptyStateName: () => import_constants.DSChatEmptyStateName,
|
|
36
|
+
DSChatEmptyStatePropTypes: () => import_react_desc_prop_types.DSChatEmptyStatePropTypes,
|
|
37
|
+
DSChatEmptyStatePropTypesSchema: () => import_react_desc_prop_types.DSChatEmptyStatePropTypesSchema
|
|
33
38
|
});
|
|
34
39
|
module.exports = __toCommonJS(index_exports);
|
|
35
40
|
var React = __toESM(require("react"));
|
|
36
41
|
var import_ChatEmptyState = require("./ChatEmptyState.js");
|
|
42
|
+
var import_react_desc_prop_types = require("./react-desc-prop-types.js");
|
|
43
|
+
var import_constants = require("./constants/index.js");
|
|
37
44
|
//# sourceMappingURL=index.js.map
|
package/dist/cjs/index.js.map
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/index.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
-
"sourcesContent": ["import type {} from '@elliemae/ds-props-helpers';\nexport { ChatEmptyState, ChatEmptyStateWithSchema } from './ChatEmptyState.js';\nexport type { DSChatEmptyStateT } from './react-desc-prop-types.js';\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;
|
|
4
|
+
"sourcesContent": ["import type {} from '@elliemae/ds-props-helpers';\n\nexport { ChatEmptyState, ChatEmptyStateWithSchema } from './ChatEmptyState.js';\nexport type { DSChatEmptyStateT } from './react-desc-prop-types.js';\nexport { DSChatEmptyStatePropTypes, DSChatEmptyStatePropTypesSchema } from './react-desc-prop-types.js';\nexport { DSChatEmptyStateName, CHAT_EMPTY_STATE_SLOTS, CHAT_EMPTY_STATE_DATA_TESTID } from './constants/index.js';\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,4BAAyD;AAEzD,mCAA2E;AAC3E,uBAA2F;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -28,17 +28,23 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
|
|
|
28
28
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
29
|
var react_desc_prop_types_exports = {};
|
|
30
30
|
__export(react_desc_prop_types_exports, {
|
|
31
|
-
|
|
32
|
-
|
|
31
|
+
DSChatEmptyStatePropTypes: () => DSChatEmptyStatePropTypes,
|
|
32
|
+
DSChatEmptyStatePropTypesSchema: () => DSChatEmptyStatePropTypesSchema,
|
|
33
|
+
defaultProps: () => defaultProps
|
|
33
34
|
});
|
|
34
35
|
module.exports = __toCommonJS(react_desc_prop_types_exports);
|
|
35
36
|
var React = __toESM(require("react"));
|
|
36
37
|
var import_ds_props_helpers = require("@elliemae/ds-props-helpers");
|
|
38
|
+
var import_constants = require("./constants/index.js");
|
|
37
39
|
const defaultProps = {
|
|
38
40
|
label: "No Messages Yet"
|
|
39
41
|
};
|
|
40
|
-
const
|
|
42
|
+
const DSChatEmptyStatePropTypes = {
|
|
43
|
+
...(0, import_ds_props_helpers.getPropsPerSlotPropTypes)(import_constants.DSChatEmptyStateName, import_constants.CHAT_EMPTY_STATE_SLOTS),
|
|
44
|
+
...import_ds_props_helpers.globalAttributesPropTypes,
|
|
45
|
+
...import_ds_props_helpers.xstyledPropTypes,
|
|
41
46
|
label: import_ds_props_helpers.PropTypes.string.description("No Message to show text helper").defaultValue(defaultProps.label),
|
|
42
47
|
action: import_ds_props_helpers.PropTypes.node.description("action element")
|
|
43
48
|
};
|
|
49
|
+
const DSChatEmptyStatePropTypesSchema = DSChatEmptyStatePropTypes;
|
|
44
50
|
//# sourceMappingURL=react-desc-prop-types.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/react-desc-prop-types.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
-
"sourcesContent": ["
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;
|
|
4
|
+
"sourcesContent": ["/* eslint-disable @typescript-eslint/no-empty-interface */\nimport type { DSPropTypesSchema, GlobalAttributesT, ValidationMap, XstyledProps } from '@elliemae/ds-props-helpers';\nimport {\n PropTypes,\n getPropsPerSlotPropTypes,\n globalAttributesPropTypes,\n xstyledPropTypes,\n} from '@elliemae/ds-props-helpers';\nimport { type TypescriptHelpersT } from '@elliemae/ds-typescript-helpers';\nimport { CHAT_EMPTY_STATE_SLOTS, DSChatEmptyStateName } from './constants/index.js';\n\nexport declare namespace DSChatEmptyStateT {\n export type SlotFunctionArguments = {\n dsChatemptystateRoot: () => object;\n dsChatemptystateContent: () => object;\n dsChatemptystateIconWrapper: () => object;\n dsChatemptystateMessageWrapper: () => object;\n dsChatemptystateMessage: () => object;\n dsChatemptystateActionWrapper: () => object;\n };\n\n export interface DefaultProps {\n label: string;\n }\n\n export interface OptionalProps\n extends TypescriptHelpersT.PropsForGlobalOnSlots<typeof DSChatEmptyStateName, typeof CHAT_EMPTY_STATE_SLOTS> {\n action?: JSX.Element;\n }\n\n export interface RequiredProps {}\n\n export interface Props\n extends Partial<DefaultProps>,\n OptionalProps,\n Omit<GlobalAttributesT<HTMLDivElement>, keyof DefaultProps | keyof OptionalProps>,\n XstyledProps,\n RequiredProps {}\n\n export interface InternalProps\n extends DefaultProps,\n OptionalProps,\n Omit<GlobalAttributesT<HTMLDivElement>, keyof DefaultProps | keyof OptionalProps>,\n XstyledProps,\n RequiredProps {}\n}\n\nexport const defaultProps: DSChatEmptyStateT.DefaultProps = {\n label: 'No Messages Yet',\n};\n\nexport const DSChatEmptyStatePropTypes: DSPropTypesSchema<DSChatEmptyStateT.Props> = {\n ...getPropsPerSlotPropTypes(DSChatEmptyStateName, CHAT_EMPTY_STATE_SLOTS),\n ...globalAttributesPropTypes,\n ...xstyledPropTypes,\n label: PropTypes.string.description('No Message to show text helper').defaultValue(defaultProps.label),\n action: PropTypes.node.description('action element'),\n};\n\nexport const DSChatEmptyStatePropTypesSchema =\n DSChatEmptyStatePropTypes as unknown as ValidationMap<DSChatEmptyStateT.Props>;\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADEvB,8BAKO;AAEP,uBAA6D;AAsCtD,MAAM,eAA+C;AAAA,EAC1D,OAAO;AACT;AAEO,MAAM,4BAAwE;AAAA,EACnF,OAAG,kDAAyB,uCAAsB,uCAAsB;AAAA,EACxE,GAAG;AAAA,EACH,GAAG;AAAA,EACH,OAAO,kCAAU,OAAO,YAAY,gCAAgC,EAAE,aAAa,aAAa,KAAK;AAAA,EACrG,QAAQ,kCAAU,KAAK,YAAY,gBAAgB;AACrD;AAEO,MAAM,kCACX;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
package/dist/cjs/styled.js
CHANGED
|
@@ -28,21 +28,48 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
|
|
|
28
28
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
29
|
var styled_exports = {};
|
|
30
30
|
__export(styled_exports, {
|
|
31
|
+
ActionWrapper: () => ActionWrapper,
|
|
31
32
|
CONTAINER_WIDTH: () => CONTAINER_WIDTH,
|
|
32
33
|
ChatEmptyStateWrapper: () => ChatEmptyStateWrapper,
|
|
33
|
-
|
|
34
|
+
Content: () => Content,
|
|
35
|
+
IconWrapper: () => IconWrapper,
|
|
36
|
+
MessageWrapper: () => MessageWrapper,
|
|
37
|
+
MessageWrapperGrid: () => MessageWrapperGrid
|
|
34
38
|
});
|
|
35
39
|
module.exports = __toCommonJS(styled_exports);
|
|
36
40
|
var React = __toESM(require("react"));
|
|
37
41
|
var import_ds_system = require("@elliemae/ds-system");
|
|
38
42
|
var import_ds_grid = require("@elliemae/ds-grid");
|
|
43
|
+
var import_constants = require("./constants/index.js");
|
|
39
44
|
const CONTAINER_WIDTH = 300;
|
|
40
|
-
const ChatEmptyStateWrapper = (0, import_ds_system.styled)(import_ds_grid.Grid
|
|
45
|
+
const ChatEmptyStateWrapper = (0, import_ds_system.styled)(import_ds_grid.Grid, {
|
|
46
|
+
name: import_constants.DSChatEmptyStateName,
|
|
47
|
+
slot: import_constants.CHAT_EMPTY_STATE_SLOTS.ROOT
|
|
48
|
+
})`
|
|
41
49
|
height: 100%;
|
|
42
50
|
overflow: hidden;
|
|
43
51
|
`;
|
|
44
|
-
const
|
|
52
|
+
const Content = (0, import_ds_system.styled)(import_ds_grid.Grid, {
|
|
53
|
+
name: import_constants.DSChatEmptyStateName,
|
|
54
|
+
slot: import_constants.CHAT_EMPTY_STATE_SLOTS.CONTENT
|
|
55
|
+
})``;
|
|
56
|
+
const IconWrapper = (0, import_ds_system.styled)(import_ds_grid.Grid, {
|
|
57
|
+
name: import_constants.DSChatEmptyStateName,
|
|
58
|
+
slot: import_constants.CHAT_EMPTY_STATE_SLOTS.ICON_WRAPPER
|
|
59
|
+
})``;
|
|
60
|
+
const MessageWrapperGrid = (0, import_ds_system.styled)(import_ds_grid.Grid, {
|
|
61
|
+
name: import_constants.DSChatEmptyStateName,
|
|
62
|
+
slot: import_constants.CHAT_EMPTY_STATE_SLOTS.MESSAGE_WRAPPER
|
|
63
|
+
})``;
|
|
64
|
+
const MessageWrapper = (0, import_ds_system.styled)("p", {
|
|
65
|
+
name: import_constants.DSChatEmptyStateName,
|
|
66
|
+
slot: import_constants.CHAT_EMPTY_STATE_SLOTS.MESSAGE
|
|
67
|
+
})`
|
|
45
68
|
font-size: 18px;
|
|
46
69
|
margin-bottom: 0px;
|
|
47
70
|
`;
|
|
71
|
+
const ActionWrapper = (0, import_ds_system.styled)(import_ds_grid.Grid, {
|
|
72
|
+
name: import_constants.DSChatEmptyStateName,
|
|
73
|
+
slot: import_constants.CHAT_EMPTY_STATE_SLOTS.ACTION_WRAPPER
|
|
74
|
+
})``;
|
|
48
75
|
//# sourceMappingURL=styled.js.map
|
package/dist/cjs/styled.js.map
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/styled.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
-
"sourcesContent": ["import { styled } from '@elliemae/ds-system';\nimport { Grid } from '@elliemae/ds-grid';\n\nexport const CONTAINER_WIDTH = 300;\n\nexport const ChatEmptyStateWrapper = styled(Grid)`\n height: 100%;\n overflow: hidden;\n`;\n\nexport const MessageWrapper = styled.
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,uBAAuB;AACvB,qBAAqB;
|
|
4
|
+
"sourcesContent": ["import { styled } from '@elliemae/ds-system';\nimport { Grid } from '@elliemae/ds-grid';\nimport { CHAT_EMPTY_STATE_SLOTS, DSChatEmptyStateName } from './constants/index.js';\n\nexport const CONTAINER_WIDTH = 300;\n\nexport const ChatEmptyStateWrapper = styled(Grid, {\n name: DSChatEmptyStateName,\n slot: CHAT_EMPTY_STATE_SLOTS.ROOT,\n})`\n height: 100%;\n overflow: hidden;\n`;\n\nexport const Content = styled(Grid, {\n name: DSChatEmptyStateName,\n slot: CHAT_EMPTY_STATE_SLOTS.CONTENT,\n})``;\n\nexport const IconWrapper = styled(Grid, {\n name: DSChatEmptyStateName,\n slot: CHAT_EMPTY_STATE_SLOTS.ICON_WRAPPER,\n})``;\n\nexport const MessageWrapperGrid = styled(Grid, {\n name: DSChatEmptyStateName,\n slot: CHAT_EMPTY_STATE_SLOTS.MESSAGE_WRAPPER,\n})``;\n\nexport const MessageWrapper = styled('p', {\n name: DSChatEmptyStateName,\n slot: CHAT_EMPTY_STATE_SLOTS.MESSAGE,\n})`\n font-size: 18px;\n margin-bottom: 0px;\n`;\n\nexport const ActionWrapper = styled(Grid, {\n name: DSChatEmptyStateName,\n slot: CHAT_EMPTY_STATE_SLOTS.ACTION_WRAPPER,\n})``;\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,uBAAuB;AACvB,qBAAqB;AACrB,uBAA6D;AAEtD,MAAM,kBAAkB;AAExB,MAAM,4BAAwB,yBAAO,qBAAM;AAAA,EAChD,MAAM;AAAA,EACN,MAAM,wCAAuB;AAC/B,CAAC;AAAA;AAAA;AAAA;AAKM,MAAM,cAAU,yBAAO,qBAAM;AAAA,EAClC,MAAM;AAAA,EACN,MAAM,wCAAuB;AAC/B,CAAC;AAEM,MAAM,kBAAc,yBAAO,qBAAM;AAAA,EACtC,MAAM;AAAA,EACN,MAAM,wCAAuB;AAC/B,CAAC;AAEM,MAAM,yBAAqB,yBAAO,qBAAM;AAAA,EAC7C,MAAM;AAAA,EACN,MAAM,wCAAuB;AAC/B,CAAC;AAEM,MAAM,qBAAiB,yBAAO,KAAK;AAAA,EACxC,MAAM;AAAA,EACN,MAAM,wCAAuB;AAC/B,CAAC;AAAA;AAAA;AAAA;AAKM,MAAM,oBAAgB,yBAAO,qBAAM;AAAA,EACxC,MAAM;AAAA,EACN,MAAM,wCAAuB;AAC/B,CAAC;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __copyProps = (to, from, except, desc) => {
|
|
9
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
10
|
+
for (let key of __getOwnPropNames(from))
|
|
11
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
12
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
13
|
+
}
|
|
14
|
+
return to;
|
|
15
|
+
};
|
|
16
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
17
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
18
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
19
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
20
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
21
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
22
|
+
mod
|
|
23
|
+
));
|
|
24
|
+
var React = __toESM(require("react"));
|
|
25
|
+
const SlotPropsAsObj = {
|
|
26
|
+
dsChatemptystateRoot: { "aria-label": "just a typescript test" },
|
|
27
|
+
dsChatemptystateContent: { "aria-label": "just a typescript test" },
|
|
28
|
+
dsChatemptystateIconWrapper: { "aria-hidden": true },
|
|
29
|
+
dsChatemptystateMessageWrapper: { "aria-label": "just a typescript test" },
|
|
30
|
+
dsChatemptystateMessage: { "aria-label": "just a typescript test" },
|
|
31
|
+
dsChatemptystateActionWrapper: { "aria-label": "just a typescript test" }
|
|
32
|
+
};
|
|
33
|
+
const SlotPropsAsFunctions = {
|
|
34
|
+
dsChatemptystateRoot: () => ({ "aria-label": "just a typescript test" }),
|
|
35
|
+
dsChatemptystateContent: () => ({ "aria-label": "just a typescript test" }),
|
|
36
|
+
dsChatemptystateIconWrapper: () => ({ "aria-hidden": true }),
|
|
37
|
+
dsChatemptystateMessageWrapper: () => ({ "aria-label": "just a typescript test" }),
|
|
38
|
+
dsChatemptystateMessage: () => ({ "aria-label": "just a typescript test" }),
|
|
39
|
+
dsChatemptystateActionWrapper: () => ({ "aria-label": "just a typescript test" })
|
|
40
|
+
};
|
|
41
|
+
const EnsureAllSlotsExistInSlotFunctionArguments = SlotPropsAsFunctions;
|
|
42
|
+
//# sourceMappingURL=slot-props.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../../../../scripts/build/transpile/react-shim.js", "../../../src/typescript-testing/slot-props.ts"],
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable @typescript-eslint/no-unused-vars, no-unused-vars */\n\nimport type { TypescriptHelpersT } from '@elliemae/ds-typescript-helpers';\nimport type { CHAT_EMPTY_STATE_SLOTS, DSChatEmptyStateName } from '../constants/index.js';\nimport type { DSChatEmptyStateT } from '../react-desc-prop-types.js';\n\nconst SlotPropsAsObj: Partial<DSChatEmptyStateT.Props> = {\n dsChatemptystateRoot: { 'aria-label': 'just a typescript test' },\n dsChatemptystateContent: { 'aria-label': 'just a typescript test' },\n dsChatemptystateIconWrapper: { 'aria-hidden': true },\n dsChatemptystateMessageWrapper: { 'aria-label': 'just a typescript test' },\n dsChatemptystateMessage: { 'aria-label': 'just a typescript test' },\n dsChatemptystateActionWrapper: { 'aria-label': 'just a typescript test' },\n};\n\nconst SlotPropsAsFunctions: DSChatEmptyStateT.SlotFunctionArguments = {\n dsChatemptystateRoot: () => ({ 'aria-label': 'just a typescript test' }),\n dsChatemptystateContent: () => ({ 'aria-label': 'just a typescript test' }),\n dsChatemptystateIconWrapper: () => ({ 'aria-hidden': true }),\n dsChatemptystateMessageWrapper: () => ({ 'aria-label': 'just a typescript test' }),\n dsChatemptystateMessage: () => ({ 'aria-label': 'just a typescript test' }),\n dsChatemptystateActionWrapper: () => ({ 'aria-label': 'just a typescript test' }),\n};\n\n// Exhaustiveness check \u2014 fails compilation if a slot is missing from SlotFunctionArguments\nconst EnsureAllSlotsExistInSlotFunctionArguments: Required<\n TypescriptHelpersT.PropsForSlots<typeof DSChatEmptyStateName, typeof CHAT_EMPTY_STATE_SLOTS>\n> = SlotPropsAsFunctions;\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;AAAA,YAAuB;ACMvB,MAAM,iBAAmD;AAAA,EACvD,sBAAsB,EAAE,cAAc,yBAAyB;AAAA,EAC/D,yBAAyB,EAAE,cAAc,yBAAyB;AAAA,EAClE,6BAA6B,EAAE,eAAe,KAAK;AAAA,EACnD,gCAAgC,EAAE,cAAc,yBAAyB;AAAA,EACzE,yBAAyB,EAAE,cAAc,yBAAyB;AAAA,EAClE,+BAA+B,EAAE,cAAc,yBAAyB;AAC1E;AAEA,MAAM,uBAAgE;AAAA,EACpE,sBAAsB,OAAO,EAAE,cAAc,yBAAyB;AAAA,EACtE,yBAAyB,OAAO,EAAE,cAAc,yBAAyB;AAAA,EACzE,6BAA6B,OAAO,EAAE,eAAe,KAAK;AAAA,EAC1D,gCAAgC,OAAO,EAAE,cAAc,yBAAyB;AAAA,EAChF,yBAAyB,OAAO,EAAE,cAAc,yBAAyB;AAAA,EACzE,+BAA+B,OAAO,EAAE,cAAc,yBAAyB;AACjF;AAGA,MAAM,6CAEF;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
|
@@ -1,29 +1,81 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
2
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
3
|
-
import {
|
|
4
|
-
|
|
5
|
-
|
|
3
|
+
import {
|
|
4
|
+
describe,
|
|
5
|
+
useValidateTypescriptPropTypes,
|
|
6
|
+
useMemoMergePropsWithDefault,
|
|
7
|
+
useOwnerProps
|
|
8
|
+
} from "@elliemae/ds-props-helpers";
|
|
6
9
|
import { Communications } from "@elliemae/ds-icons";
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
|
|
10
|
+
import { DSChatEmptyStatePropTypes, defaultProps } from "./react-desc-prop-types.js";
|
|
11
|
+
import {
|
|
12
|
+
ChatEmptyStateWrapper,
|
|
13
|
+
Content,
|
|
14
|
+
IconWrapper,
|
|
15
|
+
MessageWrapperGrid,
|
|
16
|
+
MessageWrapper,
|
|
17
|
+
ActionWrapper
|
|
18
|
+
} from "./styled.js";
|
|
19
|
+
import { DSChatEmptyStateName } from "./constants/index.js";
|
|
10
20
|
const ChatEmptyState = (props) => {
|
|
11
21
|
const propsWithDefault = useMemoMergePropsWithDefault(props, defaultProps);
|
|
12
|
-
useValidateTypescriptPropTypes(propsWithDefault,
|
|
22
|
+
useValidateTypescriptPropTypes(propsWithDefault, DSChatEmptyStatePropTypes, DSChatEmptyStateName);
|
|
23
|
+
const { getOwnerProps, getOwnerPropsArguments } = useOwnerProps(propsWithDefault);
|
|
13
24
|
const { label, action } = propsWithDefault;
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
25
|
+
return /* @__PURE__ */ jsx(
|
|
26
|
+
ChatEmptyStateWrapper,
|
|
27
|
+
{
|
|
28
|
+
alignItems: "center",
|
|
29
|
+
justifyContent: "center",
|
|
30
|
+
getOwnerProps,
|
|
31
|
+
getOwnerPropsArguments,
|
|
32
|
+
children: /* @__PURE__ */ jsxs(
|
|
33
|
+
Content,
|
|
34
|
+
{
|
|
35
|
+
alignItems: "center",
|
|
36
|
+
justifyContent: "center",
|
|
37
|
+
getOwnerProps,
|
|
38
|
+
getOwnerPropsArguments,
|
|
39
|
+
children: [
|
|
40
|
+
/* @__PURE__ */ jsx(
|
|
41
|
+
IconWrapper,
|
|
42
|
+
{
|
|
43
|
+
alignItems: "center",
|
|
44
|
+
justifyContent: "center",
|
|
45
|
+
getOwnerProps,
|
|
46
|
+
getOwnerPropsArguments,
|
|
47
|
+
children: /* @__PURE__ */ jsx(Communications, { size: "xxl", color: ["neutral", "400"] })
|
|
48
|
+
}
|
|
49
|
+
),
|
|
50
|
+
/* @__PURE__ */ jsx(
|
|
51
|
+
MessageWrapperGrid,
|
|
52
|
+
{
|
|
53
|
+
alignItems: "center",
|
|
54
|
+
justifyContent: "center",
|
|
55
|
+
getOwnerProps,
|
|
56
|
+
getOwnerPropsArguments,
|
|
57
|
+
children: /* @__PURE__ */ jsx(MessageWrapper, { getOwnerProps, getOwnerPropsArguments, children: label })
|
|
58
|
+
}
|
|
59
|
+
),
|
|
60
|
+
/* @__PURE__ */ jsx(
|
|
61
|
+
ActionWrapper,
|
|
62
|
+
{
|
|
63
|
+
alignItems: "center",
|
|
64
|
+
justifyContent: "center",
|
|
65
|
+
getOwnerProps,
|
|
66
|
+
getOwnerPropsArguments,
|
|
67
|
+
children: action
|
|
68
|
+
}
|
|
69
|
+
)
|
|
70
|
+
]
|
|
71
|
+
}
|
|
72
|
+
)
|
|
73
|
+
}
|
|
21
74
|
);
|
|
22
|
-
return /* @__PURE__ */ jsx(ChatEmptyStateWrapper, { alignItems: "center", justifyContent: "center", children: MainContent });
|
|
23
75
|
};
|
|
24
76
|
ChatEmptyState.displayName = DSChatEmptyStateName;
|
|
25
77
|
const ChatEmptyStateWithSchema = describe(ChatEmptyState);
|
|
26
|
-
ChatEmptyStateWithSchema.propTypes =
|
|
78
|
+
ChatEmptyStateWithSchema.propTypes = DSChatEmptyStatePropTypes;
|
|
27
79
|
export {
|
|
28
80
|
ChatEmptyState,
|
|
29
81
|
ChatEmptyStateWithSchema
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../src/ChatEmptyState.tsx"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import
|
|
5
|
-
"mappings": "AAAA,YAAY,WAAW;
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import React from 'react';\nimport {\n describe,\n useValidateTypescriptPropTypes,\n useMemoMergePropsWithDefault,\n useOwnerProps,\n type ValidationMap,\n} from '@elliemae/ds-props-helpers';\nimport { Communications } from '@elliemae/ds-icons';\nimport type { DSChatEmptyStateT } from './react-desc-prop-types.js';\nimport { DSChatEmptyStatePropTypes, defaultProps } from './react-desc-prop-types.js';\nimport {\n ChatEmptyStateWrapper,\n Content,\n IconWrapper,\n MessageWrapperGrid,\n MessageWrapper,\n ActionWrapper,\n} from './styled.js';\nimport { DSChatEmptyStateName } from './constants/index.js';\n\nconst ChatEmptyState: React.ComponentType<DSChatEmptyStateT.Props> = (props) => {\n const propsWithDefault = useMemoMergePropsWithDefault<DSChatEmptyStateT.InternalProps>(props, defaultProps);\n useValidateTypescriptPropTypes(propsWithDefault, DSChatEmptyStatePropTypes, DSChatEmptyStateName);\n const { getOwnerProps, getOwnerPropsArguments } = useOwnerProps<DSChatEmptyStateT.Props>(propsWithDefault);\n\n const { label, action } = propsWithDefault;\n return (\n <ChatEmptyStateWrapper\n alignItems=\"center\"\n justifyContent=\"center\"\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <Content\n alignItems=\"center\"\n justifyContent=\"center\"\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <IconWrapper\n alignItems=\"center\"\n justifyContent=\"center\"\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <Communications size=\"xxl\" color={['neutral', '400']} />\n </IconWrapper>\n <MessageWrapperGrid\n alignItems=\"center\"\n justifyContent=\"center\"\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <MessageWrapper getOwnerProps={getOwnerProps} getOwnerPropsArguments={getOwnerPropsArguments}>\n {label}\n </MessageWrapper>\n </MessageWrapperGrid>\n <ActionWrapper\n alignItems=\"center\"\n justifyContent=\"center\"\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n {action}\n </ActionWrapper>\n </Content>\n </ChatEmptyStateWrapper>\n );\n};\n\nChatEmptyState.displayName = DSChatEmptyStateName;\nconst ChatEmptyStateWithSchema = describe(ChatEmptyState);\nChatEmptyStateWithSchema.propTypes = DSChatEmptyStatePropTypes as ValidationMap<unknown>;\n\nexport { ChatEmptyState, ChatEmptyStateWithSchema };\n"],
|
|
5
|
+
"mappings": "AAAA,YAAY,WAAW;ACkCjB,SAYI,KAZJ;AAjCN;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OAEK;AACP,SAAS,sBAAsB;AAE/B,SAAS,2BAA2B,oBAAoB;AACxD;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACK;AACP,SAAS,4BAA4B;AAErC,MAAM,iBAA+D,CAAC,UAAU;AAC9E,QAAM,mBAAmB,6BAA8D,OAAO,YAAY;AAC1G,iCAA+B,kBAAkB,2BAA2B,oBAAoB;AAChG,QAAM,EAAE,eAAe,uBAAuB,IAAI,cAAuC,gBAAgB;AAEzG,QAAM,EAAE,OAAO,OAAO,IAAI;AAC1B,SACE;AAAA,IAAC;AAAA;AAAA,MACC,YAAW;AAAA,MACX,gBAAe;AAAA,MACf;AAAA,MACA;AAAA,MAEA;AAAA,QAAC;AAAA;AAAA,UACC,YAAW;AAAA,UACX,gBAAe;AAAA,UACf;AAAA,UACA;AAAA,UAEA;AAAA;AAAA,cAAC;AAAA;AAAA,gBACC,YAAW;AAAA,gBACX,gBAAe;AAAA,gBACf;AAAA,gBACA;AAAA,gBAEA,8BAAC,kBAAe,MAAK,OAAM,OAAO,CAAC,WAAW,KAAK,GAAG;AAAA;AAAA,YACxD;AAAA,YACA;AAAA,cAAC;AAAA;AAAA,gBACC,YAAW;AAAA,gBACX,gBAAe;AAAA,gBACf;AAAA,gBACA;AAAA,gBAEA,8BAAC,kBAAe,eAA8B,wBAC3C,iBACH;AAAA;AAAA,YACF;AAAA,YACA;AAAA,cAAC;AAAA;AAAA,gBACC,YAAW;AAAA,gBACX,gBAAe;AAAA,gBACf;AAAA,gBACA;AAAA,gBAEC;AAAA;AAAA,YACH;AAAA;AAAA;AAAA,MACF;AAAA;AAAA,EACF;AAEJ;AAEA,eAAe,cAAc;AAC7B,MAAM,2BAA2B,SAAS,cAAc;AACxD,yBAAyB,YAAY;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import { slotObjectToDataTestIds } from "@elliemae/ds-system";
|
|
3
|
+
const DSChatEmptyStateName = "DSChatemptystate";
|
|
4
|
+
const CHAT_EMPTY_STATE_SLOTS = {
|
|
5
|
+
ROOT: "root",
|
|
6
|
+
CONTENT: "content",
|
|
7
|
+
ICON_WRAPPER: "icon-wrapper",
|
|
8
|
+
MESSAGE_WRAPPER: "message-wrapper",
|
|
9
|
+
MESSAGE: "message",
|
|
10
|
+
ACTION_WRAPPER: "action-wrapper"
|
|
11
|
+
};
|
|
12
|
+
const CHAT_EMPTY_STATE_DATA_TESTID = {
|
|
13
|
+
...slotObjectToDataTestIds(DSChatEmptyStateName, CHAT_EMPTY_STATE_SLOTS)
|
|
14
|
+
};
|
|
15
|
+
export {
|
|
16
|
+
CHAT_EMPTY_STATE_DATA_TESTID,
|
|
17
|
+
CHAT_EMPTY_STATE_SLOTS,
|
|
18
|
+
DSChatEmptyStateName
|
|
19
|
+
};
|
|
20
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 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 DSChatEmptyStateName = 'DSChatemptystate';\n\n// we are naming this with the ${component_name}_slots convention to namespace & avoid errors on duplicate exports variables in aggregators\nexport const CHAT_EMPTY_STATE_SLOTS = {\n ROOT: 'root',\n CONTENT: 'content',\n ICON_WRAPPER: 'icon-wrapper',\n MESSAGE_WRAPPER: 'message-wrapper',\n MESSAGE: 'message',\n ACTION_WRAPPER: 'action-wrapper',\n} as const;\n\nexport const CHAT_EMPTY_STATE_DATA_TESTID = {\n ...slotObjectToDataTestIds(DSChatEmptyStateName, CHAT_EMPTY_STATE_SLOTS),\n};\n"],
|
|
5
|
+
"mappings": "AAAA,YAAY,WAAW;ACAvB,SAAS,+BAA+B;AAEjC,MAAM,uBAAuB;AAG7B,MAAM,yBAAyB;AAAA,EACpC,MAAM;AAAA,EACN,SAAS;AAAA,EACT,cAAc;AAAA,EACd,iBAAiB;AAAA,EACjB,SAAS;AAAA,EACT,gBAAgB;AAClB;AAEO,MAAM,+BAA+B;AAAA,EAC1C,GAAG,wBAAwB,sBAAsB,sBAAsB;AACzE;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
package/dist/esm/index.js
CHANGED
|
@@ -1,7 +1,14 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
2
|
import { ChatEmptyState, ChatEmptyStateWithSchema } from "./ChatEmptyState.js";
|
|
3
|
+
import { DSChatEmptyStatePropTypes, DSChatEmptyStatePropTypesSchema } from "./react-desc-prop-types.js";
|
|
4
|
+
import { DSChatEmptyStateName, CHAT_EMPTY_STATE_SLOTS, CHAT_EMPTY_STATE_DATA_TESTID } from "./constants/index.js";
|
|
3
5
|
export {
|
|
6
|
+
CHAT_EMPTY_STATE_DATA_TESTID,
|
|
7
|
+
CHAT_EMPTY_STATE_SLOTS,
|
|
4
8
|
ChatEmptyState,
|
|
5
|
-
ChatEmptyStateWithSchema
|
|
9
|
+
ChatEmptyStateWithSchema,
|
|
10
|
+
DSChatEmptyStateName,
|
|
11
|
+
DSChatEmptyStatePropTypes,
|
|
12
|
+
DSChatEmptyStatePropTypesSchema
|
|
6
13
|
};
|
|
7
14
|
//# sourceMappingURL=index.js.map
|
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.tsx"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import type {} from '@elliemae/ds-props-helpers';\nexport { ChatEmptyState, ChatEmptyStateWithSchema } from './ChatEmptyState.js';\nexport type { DSChatEmptyStateT } from './react-desc-prop-types.js';\n"],
|
|
5
|
-
"mappings": "AAAA,YAAY,WAAW;
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import type {} from '@elliemae/ds-props-helpers';\n\nexport { ChatEmptyState, ChatEmptyStateWithSchema } from './ChatEmptyState.js';\nexport type { DSChatEmptyStateT } from './react-desc-prop-types.js';\nexport { DSChatEmptyStatePropTypes, DSChatEmptyStatePropTypesSchema } from './react-desc-prop-types.js';\nexport { DSChatEmptyStateName, CHAT_EMPTY_STATE_SLOTS, CHAT_EMPTY_STATE_DATA_TESTID } from './constants/index.js';\n"],
|
|
5
|
+
"mappings": "AAAA,YAAY,WAAW;ACEvB,SAAS,gBAAgB,gCAAgC;AAEzD,SAAS,2BAA2B,uCAAuC;AAC3E,SAAS,sBAAsB,wBAAwB,oCAAoC;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -1,14 +1,25 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
|
-
import {
|
|
2
|
+
import {
|
|
3
|
+
PropTypes,
|
|
4
|
+
getPropsPerSlotPropTypes,
|
|
5
|
+
globalAttributesPropTypes,
|
|
6
|
+
xstyledPropTypes
|
|
7
|
+
} from "@elliemae/ds-props-helpers";
|
|
8
|
+
import { CHAT_EMPTY_STATE_SLOTS, DSChatEmptyStateName } from "./constants/index.js";
|
|
3
9
|
const defaultProps = {
|
|
4
10
|
label: "No Messages Yet"
|
|
5
11
|
};
|
|
6
|
-
const
|
|
12
|
+
const DSChatEmptyStatePropTypes = {
|
|
13
|
+
...getPropsPerSlotPropTypes(DSChatEmptyStateName, CHAT_EMPTY_STATE_SLOTS),
|
|
14
|
+
...globalAttributesPropTypes,
|
|
15
|
+
...xstyledPropTypes,
|
|
7
16
|
label: PropTypes.string.description("No Message to show text helper").defaultValue(defaultProps.label),
|
|
8
17
|
action: PropTypes.node.description("action element")
|
|
9
18
|
};
|
|
19
|
+
const DSChatEmptyStatePropTypesSchema = DSChatEmptyStatePropTypes;
|
|
10
20
|
export {
|
|
11
|
-
|
|
12
|
-
|
|
21
|
+
DSChatEmptyStatePropTypes,
|
|
22
|
+
DSChatEmptyStatePropTypesSchema,
|
|
23
|
+
defaultProps
|
|
13
24
|
};
|
|
14
25
|
//# sourceMappingURL=react-desc-prop-types.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../src/react-desc-prop-types.tsx"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "
|
|
5
|
-
"mappings": "AAAA,YAAY,WAAW;
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable @typescript-eslint/no-empty-interface */\nimport type { DSPropTypesSchema, GlobalAttributesT, ValidationMap, XstyledProps } from '@elliemae/ds-props-helpers';\nimport {\n PropTypes,\n getPropsPerSlotPropTypes,\n globalAttributesPropTypes,\n xstyledPropTypes,\n} from '@elliemae/ds-props-helpers';\nimport { type TypescriptHelpersT } from '@elliemae/ds-typescript-helpers';\nimport { CHAT_EMPTY_STATE_SLOTS, DSChatEmptyStateName } from './constants/index.js';\n\nexport declare namespace DSChatEmptyStateT {\n export type SlotFunctionArguments = {\n dsChatemptystateRoot: () => object;\n dsChatemptystateContent: () => object;\n dsChatemptystateIconWrapper: () => object;\n dsChatemptystateMessageWrapper: () => object;\n dsChatemptystateMessage: () => object;\n dsChatemptystateActionWrapper: () => object;\n };\n\n export interface DefaultProps {\n label: string;\n }\n\n export interface OptionalProps\n extends TypescriptHelpersT.PropsForGlobalOnSlots<typeof DSChatEmptyStateName, typeof CHAT_EMPTY_STATE_SLOTS> {\n action?: JSX.Element;\n }\n\n export interface RequiredProps {}\n\n export interface Props\n extends Partial<DefaultProps>,\n OptionalProps,\n Omit<GlobalAttributesT<HTMLDivElement>, keyof DefaultProps | keyof OptionalProps>,\n XstyledProps,\n RequiredProps {}\n\n export interface InternalProps\n extends DefaultProps,\n OptionalProps,\n Omit<GlobalAttributesT<HTMLDivElement>, keyof DefaultProps | keyof OptionalProps>,\n XstyledProps,\n RequiredProps {}\n}\n\nexport const defaultProps: DSChatEmptyStateT.DefaultProps = {\n label: 'No Messages Yet',\n};\n\nexport const DSChatEmptyStatePropTypes: DSPropTypesSchema<DSChatEmptyStateT.Props> = {\n ...getPropsPerSlotPropTypes(DSChatEmptyStateName, CHAT_EMPTY_STATE_SLOTS),\n ...globalAttributesPropTypes,\n ...xstyledPropTypes,\n label: PropTypes.string.description('No Message to show text helper').defaultValue(defaultProps.label),\n action: PropTypes.node.description('action element'),\n};\n\nexport const DSChatEmptyStatePropTypesSchema =\n DSChatEmptyStatePropTypes as unknown as ValidationMap<DSChatEmptyStateT.Props>;\n"],
|
|
5
|
+
"mappings": "AAAA,YAAY,WAAW;ACEvB;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACK;AAEP,SAAS,wBAAwB,4BAA4B;AAsCtD,MAAM,eAA+C;AAAA,EAC1D,OAAO;AACT;AAEO,MAAM,4BAAwE;AAAA,EACnF,GAAG,yBAAyB,sBAAsB,sBAAsB;AAAA,EACxE,GAAG;AAAA,EACH,GAAG;AAAA,EACH,OAAO,UAAU,OAAO,YAAY,gCAAgC,EAAE,aAAa,aAAa,KAAK;AAAA,EACrG,QAAQ,UAAU,KAAK,YAAY,gBAAgB;AACrD;AAEO,MAAM,kCACX;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
package/dist/esm/styled.js
CHANGED
|
@@ -1,18 +1,45 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
2
|
import { styled } from "@elliemae/ds-system";
|
|
3
3
|
import { Grid } from "@elliemae/ds-grid";
|
|
4
|
+
import { CHAT_EMPTY_STATE_SLOTS, DSChatEmptyStateName } from "./constants/index.js";
|
|
4
5
|
const CONTAINER_WIDTH = 300;
|
|
5
|
-
const ChatEmptyStateWrapper = styled(Grid
|
|
6
|
+
const ChatEmptyStateWrapper = styled(Grid, {
|
|
7
|
+
name: DSChatEmptyStateName,
|
|
8
|
+
slot: CHAT_EMPTY_STATE_SLOTS.ROOT
|
|
9
|
+
})`
|
|
6
10
|
height: 100%;
|
|
7
11
|
overflow: hidden;
|
|
8
12
|
`;
|
|
9
|
-
const
|
|
13
|
+
const Content = styled(Grid, {
|
|
14
|
+
name: DSChatEmptyStateName,
|
|
15
|
+
slot: CHAT_EMPTY_STATE_SLOTS.CONTENT
|
|
16
|
+
})``;
|
|
17
|
+
const IconWrapper = styled(Grid, {
|
|
18
|
+
name: DSChatEmptyStateName,
|
|
19
|
+
slot: CHAT_EMPTY_STATE_SLOTS.ICON_WRAPPER
|
|
20
|
+
})``;
|
|
21
|
+
const MessageWrapperGrid = styled(Grid, {
|
|
22
|
+
name: DSChatEmptyStateName,
|
|
23
|
+
slot: CHAT_EMPTY_STATE_SLOTS.MESSAGE_WRAPPER
|
|
24
|
+
})``;
|
|
25
|
+
const MessageWrapper = styled("p", {
|
|
26
|
+
name: DSChatEmptyStateName,
|
|
27
|
+
slot: CHAT_EMPTY_STATE_SLOTS.MESSAGE
|
|
28
|
+
})`
|
|
10
29
|
font-size: 18px;
|
|
11
30
|
margin-bottom: 0px;
|
|
12
31
|
`;
|
|
32
|
+
const ActionWrapper = styled(Grid, {
|
|
33
|
+
name: DSChatEmptyStateName,
|
|
34
|
+
slot: CHAT_EMPTY_STATE_SLOTS.ACTION_WRAPPER
|
|
35
|
+
})``;
|
|
13
36
|
export {
|
|
37
|
+
ActionWrapper,
|
|
14
38
|
CONTAINER_WIDTH,
|
|
15
39
|
ChatEmptyStateWrapper,
|
|
16
|
-
|
|
40
|
+
Content,
|
|
41
|
+
IconWrapper,
|
|
42
|
+
MessageWrapper,
|
|
43
|
+
MessageWrapperGrid
|
|
17
44
|
};
|
|
18
45
|
//# sourceMappingURL=styled.js.map
|
package/dist/esm/styled.js.map
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../src/styled.tsx"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { styled } from '@elliemae/ds-system';\nimport { Grid } from '@elliemae/ds-grid';\n\nexport const CONTAINER_WIDTH = 300;\n\nexport const ChatEmptyStateWrapper = styled(Grid)`\n height: 100%;\n overflow: hidden;\n`;\n\nexport const MessageWrapper = styled.
|
|
5
|
-
"mappings": "AAAA,YAAY,WAAW;ACAvB,SAAS,cAAc;AACvB,SAAS,YAAY;
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { styled } from '@elliemae/ds-system';\nimport { Grid } from '@elliemae/ds-grid';\nimport { CHAT_EMPTY_STATE_SLOTS, DSChatEmptyStateName } from './constants/index.js';\n\nexport const CONTAINER_WIDTH = 300;\n\nexport const ChatEmptyStateWrapper = styled(Grid, {\n name: DSChatEmptyStateName,\n slot: CHAT_EMPTY_STATE_SLOTS.ROOT,\n})`\n height: 100%;\n overflow: hidden;\n`;\n\nexport const Content = styled(Grid, {\n name: DSChatEmptyStateName,\n slot: CHAT_EMPTY_STATE_SLOTS.CONTENT,\n})``;\n\nexport const IconWrapper = styled(Grid, {\n name: DSChatEmptyStateName,\n slot: CHAT_EMPTY_STATE_SLOTS.ICON_WRAPPER,\n})``;\n\nexport const MessageWrapperGrid = styled(Grid, {\n name: DSChatEmptyStateName,\n slot: CHAT_EMPTY_STATE_SLOTS.MESSAGE_WRAPPER,\n})``;\n\nexport const MessageWrapper = styled('p', {\n name: DSChatEmptyStateName,\n slot: CHAT_EMPTY_STATE_SLOTS.MESSAGE,\n})`\n font-size: 18px;\n margin-bottom: 0px;\n`;\n\nexport const ActionWrapper = styled(Grid, {\n name: DSChatEmptyStateName,\n slot: CHAT_EMPTY_STATE_SLOTS.ACTION_WRAPPER,\n})``;\n"],
|
|
5
|
+
"mappings": "AAAA,YAAY,WAAW;ACAvB,SAAS,cAAc;AACvB,SAAS,YAAY;AACrB,SAAS,wBAAwB,4BAA4B;AAEtD,MAAM,kBAAkB;AAExB,MAAM,wBAAwB,OAAO,MAAM;AAAA,EAChD,MAAM;AAAA,EACN,MAAM,uBAAuB;AAC/B,CAAC;AAAA;AAAA;AAAA;AAKM,MAAM,UAAU,OAAO,MAAM;AAAA,EAClC,MAAM;AAAA,EACN,MAAM,uBAAuB;AAC/B,CAAC;AAEM,MAAM,cAAc,OAAO,MAAM;AAAA,EACtC,MAAM;AAAA,EACN,MAAM,uBAAuB;AAC/B,CAAC;AAEM,MAAM,qBAAqB,OAAO,MAAM;AAAA,EAC7C,MAAM;AAAA,EACN,MAAM,uBAAuB;AAC/B,CAAC;AAEM,MAAM,iBAAiB,OAAO,KAAK;AAAA,EACxC,MAAM;AAAA,EACN,MAAM,uBAAuB;AAC/B,CAAC;AAAA;AAAA;AAAA;AAKM,MAAM,gBAAgB,OAAO,MAAM;AAAA,EACxC,MAAM;AAAA,EACN,MAAM,uBAAuB;AAC/B,CAAC;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
const SlotPropsAsObj = {
|
|
3
|
+
dsChatemptystateRoot: { "aria-label": "just a typescript test" },
|
|
4
|
+
dsChatemptystateContent: { "aria-label": "just a typescript test" },
|
|
5
|
+
dsChatemptystateIconWrapper: { "aria-hidden": true },
|
|
6
|
+
dsChatemptystateMessageWrapper: { "aria-label": "just a typescript test" },
|
|
7
|
+
dsChatemptystateMessage: { "aria-label": "just a typescript test" },
|
|
8
|
+
dsChatemptystateActionWrapper: { "aria-label": "just a typescript test" }
|
|
9
|
+
};
|
|
10
|
+
const SlotPropsAsFunctions = {
|
|
11
|
+
dsChatemptystateRoot: () => ({ "aria-label": "just a typescript test" }),
|
|
12
|
+
dsChatemptystateContent: () => ({ "aria-label": "just a typescript test" }),
|
|
13
|
+
dsChatemptystateIconWrapper: () => ({ "aria-hidden": true }),
|
|
14
|
+
dsChatemptystateMessageWrapper: () => ({ "aria-label": "just a typescript test" }),
|
|
15
|
+
dsChatemptystateMessage: () => ({ "aria-label": "just a typescript test" }),
|
|
16
|
+
dsChatemptystateActionWrapper: () => ({ "aria-label": "just a typescript test" })
|
|
17
|
+
};
|
|
18
|
+
const EnsureAllSlotsExistInSlotFunctionArguments = SlotPropsAsFunctions;
|
|
19
|
+
//# sourceMappingURL=slot-props.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../../../../scripts/build/transpile/react-shim.js", "../../../src/typescript-testing/slot-props.ts"],
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable @typescript-eslint/no-unused-vars, no-unused-vars */\n\nimport type { TypescriptHelpersT } from '@elliemae/ds-typescript-helpers';\nimport type { CHAT_EMPTY_STATE_SLOTS, DSChatEmptyStateName } from '../constants/index.js';\nimport type { DSChatEmptyStateT } from '../react-desc-prop-types.js';\n\nconst SlotPropsAsObj: Partial<DSChatEmptyStateT.Props> = {\n dsChatemptystateRoot: { 'aria-label': 'just a typescript test' },\n dsChatemptystateContent: { 'aria-label': 'just a typescript test' },\n dsChatemptystateIconWrapper: { 'aria-hidden': true },\n dsChatemptystateMessageWrapper: { 'aria-label': 'just a typescript test' },\n dsChatemptystateMessage: { 'aria-label': 'just a typescript test' },\n dsChatemptystateActionWrapper: { 'aria-label': 'just a typescript test' },\n};\n\nconst SlotPropsAsFunctions: DSChatEmptyStateT.SlotFunctionArguments = {\n dsChatemptystateRoot: () => ({ 'aria-label': 'just a typescript test' }),\n dsChatemptystateContent: () => ({ 'aria-label': 'just a typescript test' }),\n dsChatemptystateIconWrapper: () => ({ 'aria-hidden': true }),\n dsChatemptystateMessageWrapper: () => ({ 'aria-label': 'just a typescript test' }),\n dsChatemptystateMessage: () => ({ 'aria-label': 'just a typescript test' }),\n dsChatemptystateActionWrapper: () => ({ 'aria-label': 'just a typescript test' }),\n};\n\n// Exhaustiveness check \u2014 fails compilation if a slot is missing from SlotFunctionArguments\nconst EnsureAllSlotsExistInSlotFunctionArguments: Required<\n TypescriptHelpersT.PropsForSlots<typeof DSChatEmptyStateName, typeof CHAT_EMPTY_STATE_SLOTS>\n> = SlotPropsAsFunctions;\n"],
|
|
5
|
+
"mappings": "AAAA,YAAY,WAAW;ACMvB,MAAM,iBAAmD;AAAA,EACvD,sBAAsB,EAAE,cAAc,yBAAyB;AAAA,EAC/D,yBAAyB,EAAE,cAAc,yBAAyB;AAAA,EAClE,6BAA6B,EAAE,eAAe,KAAK;AAAA,EACnD,gCAAgC,EAAE,cAAc,yBAAyB;AAAA,EACzE,yBAAyB,EAAE,cAAc,yBAAyB;AAAA,EAClE,+BAA+B,EAAE,cAAc,yBAAyB;AAC1E;AAEA,MAAM,uBAAgE;AAAA,EACpE,sBAAsB,OAAO,EAAE,cAAc,yBAAyB;AAAA,EACtE,yBAAyB,OAAO,EAAE,cAAc,yBAAyB;AAAA,EACzE,6BAA6B,OAAO,EAAE,eAAe,KAAK;AAAA,EAC1D,gCAAgC,OAAO,EAAE,cAAc,yBAAyB;AAAA,EAChF,yBAAyB,OAAO,EAAE,cAAc,yBAAyB;AAAA,EACzE,+BAA+B,OAAO,EAAE,cAAc,yBAAyB;AACjF;AAGA,MAAM,6CAEF;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
export declare const DSChatEmptyStateName = "DSChatemptystate";
|
|
2
|
+
export declare const CHAT_EMPTY_STATE_SLOTS: {
|
|
3
|
+
readonly ROOT: "root";
|
|
4
|
+
readonly CONTENT: "content";
|
|
5
|
+
readonly ICON_WRAPPER: "icon-wrapper";
|
|
6
|
+
readonly MESSAGE_WRAPPER: "message-wrapper";
|
|
7
|
+
readonly MESSAGE: "message";
|
|
8
|
+
readonly ACTION_WRAPPER: "action-wrapper";
|
|
9
|
+
};
|
|
10
|
+
export declare const CHAT_EMPTY_STATE_DATA_TESTID: {
|
|
11
|
+
ROOT: "ds-chatemptystate-root";
|
|
12
|
+
CONTENT: "ds-chatemptystate-content";
|
|
13
|
+
ICON_WRAPPER: "ds-chatemptystate-icon-wrapper";
|
|
14
|
+
MESSAGE_WRAPPER: "ds-chatemptystate-message-wrapper";
|
|
15
|
+
MESSAGE: "ds-chatemptystate-message";
|
|
16
|
+
ACTION_WRAPPER: "ds-chatemptystate-action-wrapper";
|
|
17
|
+
};
|
package/dist/types/index.d.ts
CHANGED
|
@@ -1,2 +1,4 @@
|
|
|
1
1
|
export { ChatEmptyState, ChatEmptyStateWithSchema } from './ChatEmptyState.js';
|
|
2
2
|
export type { DSChatEmptyStateT } from './react-desc-prop-types.js';
|
|
3
|
+
export { DSChatEmptyStatePropTypes, DSChatEmptyStatePropTypesSchema } from './react-desc-prop-types.js';
|
|
4
|
+
export { DSChatEmptyStateName, CHAT_EMPTY_STATE_SLOTS, CHAT_EMPTY_STATE_DATA_TESTID } from './constants/index.js';
|
|
@@ -1,17 +1,28 @@
|
|
|
1
|
+
import type { DSPropTypesSchema, GlobalAttributesT, ValidationMap, XstyledProps } from '@elliemae/ds-props-helpers';
|
|
2
|
+
import { type TypescriptHelpersT } from '@elliemae/ds-typescript-helpers';
|
|
3
|
+
import { CHAT_EMPTY_STATE_SLOTS, DSChatEmptyStateName } from './constants/index.js';
|
|
1
4
|
export declare namespace DSChatEmptyStateT {
|
|
5
|
+
type SlotFunctionArguments = {
|
|
6
|
+
dsChatemptystateRoot: () => object;
|
|
7
|
+
dsChatemptystateContent: () => object;
|
|
8
|
+
dsChatemptystateIconWrapper: () => object;
|
|
9
|
+
dsChatemptystateMessageWrapper: () => object;
|
|
10
|
+
dsChatemptystateMessage: () => object;
|
|
11
|
+
dsChatemptystateActionWrapper: () => object;
|
|
12
|
+
};
|
|
2
13
|
interface DefaultProps {
|
|
3
14
|
label: string;
|
|
4
15
|
}
|
|
5
|
-
interface OptionalProps {
|
|
16
|
+
interface OptionalProps extends TypescriptHelpersT.PropsForGlobalOnSlots<typeof DSChatEmptyStateName, typeof CHAT_EMPTY_STATE_SLOTS> {
|
|
6
17
|
action?: JSX.Element;
|
|
7
18
|
}
|
|
8
|
-
interface
|
|
19
|
+
interface RequiredProps {
|
|
9
20
|
}
|
|
10
|
-
interface
|
|
21
|
+
interface Props extends Partial<DefaultProps>, OptionalProps, Omit<GlobalAttributesT<HTMLDivElement>, keyof DefaultProps | keyof OptionalProps>, XstyledProps, RequiredProps {
|
|
22
|
+
}
|
|
23
|
+
interface InternalProps extends DefaultProps, OptionalProps, Omit<GlobalAttributesT<HTMLDivElement>, keyof DefaultProps | keyof OptionalProps>, XstyledProps, RequiredProps {
|
|
11
24
|
}
|
|
12
25
|
}
|
|
13
26
|
export declare const defaultProps: DSChatEmptyStateT.DefaultProps;
|
|
14
|
-
export declare const
|
|
15
|
-
|
|
16
|
-
action: import("@elliemae/ds-props-helpers/dist/types/propTypes/types").ReactDescT;
|
|
17
|
-
};
|
|
27
|
+
export declare const DSChatEmptyStatePropTypes: DSPropTypesSchema<DSChatEmptyStateT.Props>;
|
|
28
|
+
export declare const DSChatEmptyStatePropTypesSchema: ValidationMap<DSChatEmptyStateT.Props>;
|
package/dist/types/styled.d.ts
CHANGED
|
@@ -1,3 +1,7 @@
|
|
|
1
1
|
export declare const CONTAINER_WIDTH = 300;
|
|
2
2
|
export declare const ChatEmptyStateWrapper: import("styled-components").StyledComponent<import("react").ForwardRefExoticComponent<import("@elliemae/ds-grid").DSGridT.Props & import("react").RefAttributes<HTMLDivElement>>, import("@elliemae/ds-system").Theme, object & import("@elliemae/ds-system").OwnerInterface & import("@elliemae/ds-system").InnerRefInterface<import("react").ForwardRefExoticComponent<import("@elliemae/ds-grid").DSGridT.Props & import("react").RefAttributes<HTMLDivElement>>>, never>;
|
|
3
|
+
export declare const Content: import("styled-components").StyledComponent<import("react").ForwardRefExoticComponent<import("@elliemae/ds-grid").DSGridT.Props & import("react").RefAttributes<HTMLDivElement>>, import("@elliemae/ds-system").Theme, object & import("@elliemae/ds-system").OwnerInterface & import("@elliemae/ds-system").InnerRefInterface<import("react").ForwardRefExoticComponent<import("@elliemae/ds-grid").DSGridT.Props & import("react").RefAttributes<HTMLDivElement>>>, never>;
|
|
4
|
+
export declare const IconWrapper: import("styled-components").StyledComponent<import("react").ForwardRefExoticComponent<import("@elliemae/ds-grid").DSGridT.Props & import("react").RefAttributes<HTMLDivElement>>, import("@elliemae/ds-system").Theme, object & import("@elliemae/ds-system").OwnerInterface & import("@elliemae/ds-system").InnerRefInterface<import("react").ForwardRefExoticComponent<import("@elliemae/ds-grid").DSGridT.Props & import("react").RefAttributes<HTMLDivElement>>>, never>;
|
|
5
|
+
export declare const MessageWrapperGrid: import("styled-components").StyledComponent<import("react").ForwardRefExoticComponent<import("@elliemae/ds-grid").DSGridT.Props & import("react").RefAttributes<HTMLDivElement>>, import("@elliemae/ds-system").Theme, object & import("@elliemae/ds-system").OwnerInterface & import("@elliemae/ds-system").InnerRefInterface<import("react").ForwardRefExoticComponent<import("@elliemae/ds-grid").DSGridT.Props & import("react").RefAttributes<HTMLDivElement>>>, never>;
|
|
3
6
|
export declare const MessageWrapper: import("styled-components").StyledComponent<"p", import("@elliemae/ds-system").Theme, object & import("@elliemae/ds-system").OwnerInterface & import("@elliemae/ds-system").InnerRefInterface<"p">, never>;
|
|
7
|
+
export declare const ActionWrapper: import("styled-components").StyledComponent<import("react").ForwardRefExoticComponent<import("@elliemae/ds-grid").DSGridT.Props & import("react").RefAttributes<HTMLDivElement>>, import("@elliemae/ds-system").Theme, object & import("@elliemae/ds-system").OwnerInterface & import("@elliemae/ds-system").InnerRefInterface<import("react").ForwardRefExoticComponent<import("@elliemae/ds-grid").DSGridT.Props & import("react").RefAttributes<HTMLDivElement>>>, never>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
File without changes
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
File without changes
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@elliemae/ds-chat-empty-state",
|
|
3
|
-
"version": "3.70.0-next.
|
|
3
|
+
"version": "3.70.0-next.31",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"description": "ICE MT - Dimsum - Chat Empty State",
|
|
6
6
|
"files": [
|
|
@@ -36,18 +36,18 @@
|
|
|
36
36
|
"typeSafety": true
|
|
37
37
|
},
|
|
38
38
|
"dependencies": {
|
|
39
|
-
"@elliemae/ds-grid": "3.70.0-next.
|
|
40
|
-
"@elliemae/ds-
|
|
41
|
-
"@elliemae/ds-icons": "3.70.0-next.
|
|
42
|
-
"@elliemae/ds-
|
|
39
|
+
"@elliemae/ds-grid": "3.70.0-next.31",
|
|
40
|
+
"@elliemae/ds-system": "3.70.0-next.31",
|
|
41
|
+
"@elliemae/ds-icons": "3.70.0-next.31",
|
|
42
|
+
"@elliemae/ds-props-helpers": "3.70.0-next.31"
|
|
43
43
|
},
|
|
44
44
|
"devDependencies": {
|
|
45
45
|
"jest": "^30.0.0",
|
|
46
46
|
"styled-components": "~5.3.9",
|
|
47
|
-
"@elliemae/ds-monorepo-devops": "3.70.0-next.
|
|
47
|
+
"@elliemae/ds-monorepo-devops": "3.70.0-next.31"
|
|
48
48
|
},
|
|
49
49
|
"peerDependencies": {
|
|
50
|
-
"lodash-es": "^4.
|
|
50
|
+
"lodash-es": "^4.18.1",
|
|
51
51
|
"react": "^18.3.1",
|
|
52
52
|
"react-dom": "^18.3.1",
|
|
53
53
|
"styled-components": "~5.3.9"
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../src/DSChatEmptyStateDefinitions.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
-
"sourcesContent": ["export const DSChatEmptyStateName = 'DSChatemptystate';\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAhB,MAAM,uBAAuB;",
|
|
6
|
-
"names": []
|
|
7
|
-
}
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../src/DSChatEmptyStateDefinitions.tsx"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "export const DSChatEmptyStateName = 'DSChatemptystate';\n"],
|
|
5
|
-
"mappings": "AAAA,YAAY,WAAW;ACAhB,MAAM,uBAAuB;",
|
|
6
|
-
"names": []
|
|
7
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare const DSChatEmptyStateName = "DSChatemptystate";
|