@elliemae/ds-modal-slide 3.70.0-next.2 → 3.70.0-next.3
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/DSModalSlide.js +45 -22
- package/dist/cjs/DSModalSlide.js.map +2 -2
- package/dist/cjs/constants/index.js +7 -3
- package/dist/cjs/constants/index.js.map +3 -3
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/parts/DSModalFooter/react-desc-prop-types.js +2 -2
- package/dist/cjs/parts/DSModalFooter/react-desc-prop-types.js.map +2 -2
- package/dist/cjs/parts/DSModalFooter/typescript-testing/slot-props.js +36 -0
- package/dist/cjs/parts/DSModalFooter/typescript-testing/slot-props.js.map +7 -0
- package/dist/cjs/parts/DSModalHeader/DSModalHeader.js +10 -3
- package/dist/cjs/parts/DSModalHeader/DSModalHeader.js.map +2 -2
- package/dist/cjs/parts/DSModalHeader/constants/index.js +2 -0
- package/dist/cjs/parts/DSModalHeader/constants/index.js.map +2 -2
- package/dist/cjs/parts/DSModalHeader/react-desc-prop-types.js.map +2 -2
- package/dist/cjs/parts/DSModalHeader/typescript-testing/slot-props.js +42 -0
- package/dist/cjs/parts/DSModalHeader/typescript-testing/slot-props.js.map +7 -0
- package/dist/cjs/react-desc-prop-types.js +2 -0
- package/dist/cjs/react-desc-prop-types.js.map +3 -3
- package/dist/cjs/styled.js +20 -4
- package/dist/cjs/styled.js.map +2 -2
- package/dist/cjs/typescript-testing/slot-props.js +46 -0
- package/dist/cjs/typescript-testing/slot-props.js.map +7 -0
- package/dist/esm/DSModalSlide.js +49 -24
- package/dist/esm/DSModalSlide.js.map +2 -2
- package/dist/esm/constants/index.js +7 -3
- package/dist/esm/constants/index.js.map +3 -3
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/parts/DSModalFooter/react-desc-prop-types.js +4 -4
- package/dist/esm/parts/DSModalFooter/react-desc-prop-types.js.map +2 -2
- package/dist/esm/parts/DSModalFooter/typescript-testing/slot-props.js +13 -0
- package/dist/esm/parts/DSModalFooter/typescript-testing/slot-props.js.map +7 -0
- package/dist/esm/parts/DSModalHeader/DSModalHeader.js +11 -4
- package/dist/esm/parts/DSModalHeader/DSModalHeader.js.map +2 -2
- package/dist/esm/parts/DSModalHeader/constants/index.js +2 -0
- package/dist/esm/parts/DSModalHeader/constants/index.js.map +2 -2
- package/dist/esm/parts/DSModalHeader/react-desc-prop-types.js.map +2 -2
- package/dist/esm/parts/DSModalHeader/typescript-testing/slot-props.js +19 -0
- package/dist/esm/parts/DSModalHeader/typescript-testing/slot-props.js.map +7 -0
- package/dist/esm/react-desc-prop-types.js +8 -1
- package/dist/esm/react-desc-prop-types.js.map +3 -3
- package/dist/esm/styled.js +20 -4
- package/dist/esm/styled.js.map +2 -2
- package/dist/esm/typescript-testing/slot-props.js +23 -0
- package/dist/esm/typescript-testing/slot-props.js.map +7 -0
- package/dist/types/constants/index.d.ts +16 -12
- package/dist/types/parts/DSModalFooter/react-desc-prop-types.d.ts +8 -1
- package/dist/types/parts/DSModalHeader/constants/index.d.ts +2 -0
- package/dist/types/parts/DSModalHeader/react-desc-prop-types.d.ts +8 -0
- package/dist/types/react-desc-prop-types.d.ts +16 -2
- package/dist/types/styled.d.ts +15 -1
- package/dist/types/tests/DSModalSlide.a11y.test.d.ts +1 -0
- package/dist/types/tests/DSModalSlide.api.test.d.ts +1 -0
- package/dist/types/tests/DSModalSlide.data-testid.test.d.ts +1 -0
- package/dist/types/tests/DSModalSlide.events.test.d.ts +1 -0
- package/dist/types/tests/DSModalSlide.exports.test.d.ts +1 -0
- package/dist/types/tests/DSModalSlide.get-owner-props-arguments.test.d.ts +1 -0
- package/dist/types/tests/DSModalSlide.keyboard.test.d.ts +1 -0
- package/dist/types/typescript-testing/slot-props.d.ts +1 -0
- package/package.json +9 -9
- /package/dist/types/{tests/DSModalSLide.axe.test.d.ts → parts/DSModalFooter/typescript-testing/slot-props.d.ts} +0 -0
- /package/dist/types/{tests/DSModalSlide.test.d.ts → parts/DSModalHeader/typescript-testing/slot-props.d.ts} +0 -0
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": ["/* eslint-disable max-lines */\nimport { DSButtonV3 } from '@elliemae/ds-button-v2';\nimport { Grid } from '@elliemae/ds-grid';\nimport { DSSeparatorV2 } from '@elliemae/ds-separator';\nimport { styled, kfrm } from '@elliemae/ds-system';\nimport { DSTypography } from '@elliemae/ds-typography';\nimport { DSModalSlideName, MODAL_SLIDE_SLOTS } from './constants/index.js';\nimport { MODAL_FOOTER_SLOTS } from './parts/DSModalFooter/constants/index.js';\nimport { MODAL_HEADER_SLOTS } from './parts/DSModalHeader/constants/index.js';\n\nconst overlayAnimation = kfrm`{\n 0% {\n background: rgba(37, 41, 47, 0);\n }\n 100% {\n background: rgba(37, 41, 47, 0.25);\n }\n}`;\n\nconst overlayAnimationOut = kfrm`{\n 0% {\n background: rgba(37, 41, 47, 0.25);\n }\n 100% {\n background: rgba(37, 41, 47, 0);\n }\n}`;\n\nconst contentAnimationOut = kfrm`{\n 0% {\n transform: translateX(0);\n }\n 100% {\n transform: translateX(100%);\n }\n}`;\n\nconst contentAnimationIn = kfrm`{\n 0% {\n transform: translateX(100%);\n }\n 100% {\n transform: translateX(0);\n }\n}`;\n\nexport const StyledModalWrapper = styled('div', {\n name: DSModalSlideName,\n slot: MODAL_SLIDE_SLOTS.ROOT,\n})<{ height: string | number }>`\n position: absolute;\n display: flex;\n height: calc(${(props) => props.height} * 1px);\n width: 100%;\n top: 0;\n left: 0;\n z-index: 10;\n`;\n\nexport const StyledOverlay = styled('div', {\n name: DSModalSlideName,\n slot: MODAL_SLIDE_SLOTS.OVERLAY,\n})<{ disappearing: boolean; showing: boolean; fadeIn: number; fadeOut: number }>`\n height: 100%;\n width: 100%;\n background: rgba(37, 41, 47, 0.25);\n display: flex;\n animation: ${(props) => (props.disappearing ? overlayAnimationOut : overlayAnimation)}\n calc(${(props) => (props.disappearing ? props.fadeOut : props.fadeIn)} * 1ms) linear;\n\n ${(props) =>\n props.showing &&\n `display: flex;\n height: 100%;`}\n`;\n\nexport const StyledContent = styled('div', { name: DSModalSlideName, slot: MODAL_SLIDE_SLOTS.CONTENT })<{\n height: number | string;\n width: number | string;\n disappearing: boolean;\n fadeIn: number;\n fadeOut: number;\n}>`\n height: calc(${(props) => props.height} * 1px);\n background: neutral-000;\n box-shadow:\n 0 6px 20px 0 rgba(0, 0, 0, 0.24),\n 0 8px 17px 0 rgba(0, 0, 0, 0.19);\n width: calc(${(props) => props.width} * 1%);\n margin-left: auto;\n align-items: center;\n flex-direction: column;\n display: flex;\n overflow-y: auto;\n border: 1px solid neutral-300;\n border-left: 2px solid neutral-300;\n animation: ${(props) => (props.disappearing ? contentAnimationOut : contentAnimationIn)}\n calc(${(props) => (props.disappearing ? props.fadeOut / 2 : props.fadeIn / 2)} * 1ms) linear;\n`;\n\nexport const StyledGridContent = styled(Grid)`\n height: 100%;\n width: 100%;\n max-height: 100%;\n overflow: hidden;\n -webkit-backface-visibility: hidden;\n backface-visibility: hidden;\n -webkit-transform-style: preserve-3d;\n transform-style: preserve-3d;\n`;\n\nexport const StyledTitle = styled(DSTypography, { name: DSModalSlideName, slot: MODAL_HEADER_SLOTS.TITLE })`\n font-size: 1.3846rem;\n color: neutral-700;\n white-space: normal;\n word-break: break-word;\n`;\n\nexport const StyledHeaderLeftSide = styled('div', {\n name: DSModalSlideName,\n slot: MODAL_HEADER_SLOTS.HEADER_LEFT_SIDE,\n})`\n width: 100%;\n height: 100%;\n display: flex;\n flex-direction: row;\n text-align: left;\n`;\n\nexport const StyledActualContent = styled('div', { name: DSModalSlideName, slot: MODAL_SLIDE_SLOTS.ACTUAL_CONTENT })`\n display: flex;\n flex-direction: column;\n`;\n\nexport const StyledHeader = styled('div', { name: DSModalSlideName, slot: MODAL_HEADER_SLOTS.HEADER })`\n display: flex;\n flex-direction: column;\n justify-content: center;\n`;\n\nexport const StyledFooterWrapper = styled('div', { name: DSModalSlideName, slot: MODAL_FOOTER_SLOTS.FOOTER_WRAPPER })`\n width: 100%;\n height: auto;\n display: flex;\n flex-wrap: wrap;\n text-align: left;\n align-items: center;\n justify-content: flex-end;\n padding: 0.61538rem 1.23077rem 0 0;\n .em-ds-button {\n margin-left: 1.23077rem;\n }\n`;\n\nexport const HeaderWrapper = styled('div', { name: DSModalSlideName, slot: MODAL_HEADER_SLOTS.HEADER_WRAPPER })`\n display: flex;\n justify-content: space-between;\n width: 100%;\n align-items: flex-start;\n overflow: hidden;\n padding: ${(props) => props.theme.space.xxs} ${(props) => props.theme.space.xs};\n`;\n\nexport const
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADCvB,0BAA2B;AAC3B,qBAAqB;AACrB,0BAA8B;AAC9B,uBAA6B;AAC7B,2BAA6B;AAC7B,uBAAoD;AACpD,IAAAA,oBAAmC;AACnC,IAAAA,oBAAmC;AAEnC,MAAM,mBAAmB;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AASzB,MAAM,sBAAsB;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAS5B,MAAM,sBAAsB;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAS5B,MAAM,qBAAqB;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AASpB,MAAM,yBAAqB,yBAAO,OAAO;AAAA,EAC9C,MAAM;AAAA,EACN,MAAM,mCAAkB;AAC1B,CAAC;AAAA;AAAA;AAAA,iBAGgB,CAAC,UAAU,MAAM,MAAM;AAAA;AAAA;AAAA;AAAA;AAAA;AAOjC,MAAM,oBAAgB,yBAAO,OAAO;AAAA,EACzC,MAAM;AAAA,EACN,MAAM,mCAAkB;AAC1B,CAAC;AAAA;AAAA;AAAA;AAAA;AAAA,eAKc,CAAC,UAAW,MAAM,eAAe,sBAAsB,gBAAiB;AAAA,WAC5E,CAAC,UAAW,MAAM,eAAe,MAAM,UAAU,MAAM,MAAO;AAAA;AAAA,IAErE,CAAC,UACD,MAAM,WACN;AAAA,mBACe;AAAA;AAGZ,MAAM,oBAAgB,yBAAO,OAAO,EAAE,MAAM,mCAAkB,MAAM,mCAAkB,QAAQ,CAAC;AAAA,iBAOrF,CAAC,UAAU,MAAM,MAAM;AAAA;AAAA;AAAA;AAAA;AAAA,gBAKxB,CAAC,UAAU,MAAM,KAAK;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,eAQvB,CAAC,UAAW,MAAM,eAAe,sBAAsB,kBAAmB;AAAA,WAC9E,CAAC,UAAW,MAAM,eAAe,MAAM,UAAU,IAAI,MAAM,SAAS,CAAE;AAAA;AAG1E,MAAM,wBAAoB,yBAAO,
|
|
4
|
+
"sourcesContent": ["/* eslint-disable max-lines */\nimport { DSButtonV3 } from '@elliemae/ds-button-v2';\nimport { Grid } from '@elliemae/ds-grid';\nimport { DSSeparatorV2 } from '@elliemae/ds-separator';\nimport { styled, kfrm } from '@elliemae/ds-system';\nimport { DSTypography } from '@elliemae/ds-typography';\nimport { DSModalSlideName, MODAL_SLIDE_SLOTS } from './constants/index.js';\nimport { MODAL_FOOTER_SLOTS } from './parts/DSModalFooter/constants/index.js';\nimport { MODAL_HEADER_SLOTS } from './parts/DSModalHeader/constants/index.js';\n\nconst overlayAnimation = kfrm`{\n 0% {\n background: rgba(37, 41, 47, 0);\n }\n 100% {\n background: rgba(37, 41, 47, 0.25);\n }\n}`;\n\nconst overlayAnimationOut = kfrm`{\n 0% {\n background: rgba(37, 41, 47, 0.25);\n }\n 100% {\n background: rgba(37, 41, 47, 0);\n }\n}`;\n\nconst contentAnimationOut = kfrm`{\n 0% {\n transform: translateX(0);\n }\n 100% {\n transform: translateX(100%);\n }\n}`;\n\nconst contentAnimationIn = kfrm`{\n 0% {\n transform: translateX(100%);\n }\n 100% {\n transform: translateX(0);\n }\n}`;\n\nexport const StyledModalWrapper = styled('div', {\n name: DSModalSlideName,\n slot: MODAL_SLIDE_SLOTS.ROOT,\n})<{ height: string | number }>`\n position: absolute;\n display: flex;\n height: calc(${(props) => props.height} * 1px);\n width: 100%;\n top: 0;\n left: 0;\n z-index: 10;\n`;\n\nexport const StyledOverlay = styled('div', {\n name: DSModalSlideName,\n slot: MODAL_SLIDE_SLOTS.OVERLAY,\n})<{ disappearing: boolean; showing: boolean; fadeIn: number; fadeOut: number }>`\n height: 100%;\n width: 100%;\n background: rgba(37, 41, 47, 0.25);\n display: flex;\n animation: ${(props) => (props.disappearing ? overlayAnimationOut : overlayAnimation)}\n calc(${(props) => (props.disappearing ? props.fadeOut : props.fadeIn)} * 1ms) linear;\n\n ${(props) =>\n props.showing &&\n `display: flex;\n height: 100%;`}\n`;\n\nexport const StyledContent = styled('div', { name: DSModalSlideName, slot: MODAL_SLIDE_SLOTS.CONTENT })<{\n height: number | string;\n width: number | string;\n disappearing: boolean;\n fadeIn: number;\n fadeOut: number;\n}>`\n height: calc(${(props) => props.height} * 1px);\n background: neutral-000;\n box-shadow:\n 0 6px 20px 0 rgba(0, 0, 0, 0.24),\n 0 8px 17px 0 rgba(0, 0, 0, 0.19);\n width: calc(${(props) => props.width} * 1%);\n margin-left: auto;\n align-items: center;\n flex-direction: column;\n display: flex;\n overflow-y: auto;\n border: 1px solid neutral-300;\n border-left: 2px solid neutral-300;\n animation: ${(props) => (props.disappearing ? contentAnimationOut : contentAnimationIn)}\n calc(${(props) => (props.disappearing ? props.fadeOut / 2 : props.fadeIn / 2)} * 1ms) linear;\n`;\n\nexport const StyledGridContent = styled(Grid, {\n name: DSModalSlideName,\n slot: MODAL_SLIDE_SLOTS.GRID_CONTENT,\n})`\n height: 100%;\n width: 100%;\n max-height: 100%;\n overflow: hidden;\n -webkit-backface-visibility: hidden;\n backface-visibility: hidden;\n -webkit-transform-style: preserve-3d;\n transform-style: preserve-3d;\n`;\n\nexport const StyledTitle = styled(DSTypography, { name: DSModalSlideName, slot: MODAL_HEADER_SLOTS.TITLE })`\n font-size: 1.3846rem;\n color: neutral-700;\n white-space: normal;\n word-break: break-word;\n`;\n\nexport const StyledHeaderLeftSide = styled('div', {\n name: DSModalSlideName,\n slot: MODAL_HEADER_SLOTS.HEADER_LEFT_SIDE,\n})`\n width: 100%;\n height: 100%;\n display: flex;\n flex-direction: row;\n text-align: left;\n`;\n\nexport const StyledActualContent = styled('div', { name: DSModalSlideName, slot: MODAL_SLIDE_SLOTS.ACTUAL_CONTENT })`\n display: flex;\n flex-direction: column;\n`;\n\nexport const StyledHeader = styled('div', { name: DSModalSlideName, slot: MODAL_HEADER_SLOTS.HEADER })`\n display: flex;\n flex-direction: column;\n justify-content: center;\n`;\n\nexport const StyledFooterWrapper = styled('div', { name: DSModalSlideName, slot: MODAL_FOOTER_SLOTS.FOOTER_WRAPPER })`\n width: 100%;\n height: auto;\n display: flex;\n flex-wrap: wrap;\n text-align: left;\n align-items: center;\n justify-content: flex-end;\n padding: 0.61538rem 1.23077rem 0 0;\n .em-ds-button {\n margin-left: 1.23077rem;\n }\n`;\n\nexport const HeaderWrapper = styled('div', { name: DSModalSlideName, slot: MODAL_HEADER_SLOTS.HEADER_WRAPPER })`\n display: flex;\n justify-content: space-between;\n width: 100%;\n align-items: flex-start;\n overflow: hidden;\n padding: ${(props) => props.theme.space.xxs} ${(props) => props.theme.space.xs};\n`;\n\nexport const StyledHeaderSeparator = styled(DSSeparatorV2, {\n name: DSModalSlideName,\n slot: MODAL_SLIDE_SLOTS.HEADER_SEPARATOR,\n})``;\n\nexport const StyledFooterSeparator = styled(DSSeparatorV2, {\n name: DSModalSlideName,\n slot: MODAL_SLIDE_SLOTS.FOOTER_SEPARATOR,\n})``;\n\nexport const StyledToolbarSeparator = styled(DSSeparatorV2, {\n name: DSModalSlideName,\n slot: MODAL_HEADER_SLOTS.TOOLBAR_SEPARATOR,\n})`\n height: 33%;\n background: ${(props) => props.theme.colors.neutral['300']};\n`;\n\nexport const StyledCloseButton = styled(DSButtonV3, {\n name: DSModalSlideName,\n slot: MODAL_HEADER_SLOTS.CLOSE_BUTTON,\n})``;\n\nexport const StyledContentWrapper = styled(Grid, { name: DSModalSlideName, slot: MODAL_SLIDE_SLOTS.CONTENT_WRAPPER })`\n overflow: auto;\n &:focus,\n &:focus-visible {\n outline: 2px solid ${({ theme }) => theme.colors.brand['600']};\n outline-offset: -2px;\n }\n`;\n\nexport const StyledRejectButton = styled(DSButtonV3, {\n name: DSModalSlideName,\n slot: MODAL_FOOTER_SLOTS.REJECT_BUTTON,\n})`\n margin-bottom: 0.61538rem;\n`;\n\nexport const StyledConfirmButton = styled(DSButtonV3, {\n name: DSModalSlideName,\n slot: MODAL_FOOTER_SLOTS.CONFIRM_BUTTON,\n})`\n margin-bottom: 0.61538rem;\n`;\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": "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",
|
|
6
6
|
"names": ["import_constants"]
|
|
7
7
|
}
|
|
@@ -0,0 +1,46 @@
|
|
|
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
|
+
dsModalslideRoot: { "aria-label": "just a typescript test" },
|
|
27
|
+
dsModalslideOverlay: { "aria-label": "just a typescript test" },
|
|
28
|
+
dsModalslideContent: { "aria-label": "just a typescript test" },
|
|
29
|
+
dsModalslideActualContent: { "aria-label": "just a typescript test" },
|
|
30
|
+
dsModalslideHeaderSeparator: { "aria-label": "just a typescript test" },
|
|
31
|
+
dsModalslideFooterSeparator: { "aria-label": "just a typescript test" },
|
|
32
|
+
dsModalslideContentWrapper: { "aria-label": "just a typescript test" },
|
|
33
|
+
dsModalslideGridContent: { "aria-label": "just a typescript test" }
|
|
34
|
+
};
|
|
35
|
+
const SlotPropsAsFunctions = {
|
|
36
|
+
dsModalslideRoot: () => ({ "aria-label": "just a typescript test" }),
|
|
37
|
+
dsModalslideOverlay: () => ({ "aria-label": "just a typescript test" }),
|
|
38
|
+
dsModalslideContent: () => ({ "aria-label": "just a typescript test" }),
|
|
39
|
+
dsModalslideActualContent: () => ({ "aria-label": "just a typescript test" }),
|
|
40
|
+
dsModalslideHeaderSeparator: () => ({ "aria-label": "just a typescript test" }),
|
|
41
|
+
dsModalslideFooterSeparator: () => ({ "aria-label": "just a typescript test" }),
|
|
42
|
+
dsModalslideContentWrapper: () => ({ "aria-label": "just a typescript test" }),
|
|
43
|
+
dsModalslideGridContent: () => ({ "aria-label": "just a typescript test" })
|
|
44
|
+
};
|
|
45
|
+
const EnsureAllSlotsExistInSlotFunctionArguments = SlotPropsAsFunctions;
|
|
46
|
+
//# 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';\n\nimport type { DSModalSlideT } from '../react-desc-prop-types.js';\nimport type { DSModalSlideName, MODAL_SLIDE_SLOTS } from '../constants/index.js';\n\nconst SlotPropsAsObj: Partial<DSModalSlideT.Props> = {\n dsModalslideRoot: { 'aria-label': 'just a typescript test' },\n dsModalslideOverlay: { 'aria-label': 'just a typescript test' },\n dsModalslideContent: { 'aria-label': 'just a typescript test' },\n dsModalslideActualContent: { 'aria-label': 'just a typescript test' },\n dsModalslideHeaderSeparator: { 'aria-label': 'just a typescript test' },\n dsModalslideFooterSeparator: { 'aria-label': 'just a typescript test' },\n dsModalslideContentWrapper: { 'aria-label': 'just a typescript test' },\n dsModalslideGridContent: { 'aria-label': 'just a typescript test' },\n};\n\nconst SlotPropsAsFunctions: DSModalSlideT.SlotFunctionArguments = {\n dsModalslideRoot: () => ({ 'aria-label': 'just a typescript test' }),\n dsModalslideOverlay: () => ({ 'aria-label': 'just a typescript test' }),\n dsModalslideContent: () => ({ 'aria-label': 'just a typescript test' }),\n dsModalslideActualContent: () => ({ 'aria-label': 'just a typescript test' }),\n dsModalslideHeaderSeparator: () => ({ 'aria-label': 'just a typescript test' }),\n dsModalslideFooterSeparator: () => ({ 'aria-label': 'just a typescript test' }),\n dsModalslideContentWrapper: () => ({ 'aria-label': 'just a typescript test' }),\n dsModalslideGridContent: () => ({ 'aria-label': 'just a typescript test' }),\n};\n\nconst EnsureAllSlotsExistInSlotFunctionArguments: Required<\n TypescriptHelpersT.PropsForSlots<typeof DSModalSlideName, typeof MODAL_SLIDE_SLOTS>\n> = SlotPropsAsFunctions;\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;AAAA,YAAuB;ACOvB,MAAM,iBAA+C;AAAA,EACnD,kBAAkB,EAAE,cAAc,yBAAyB;AAAA,EAC3D,qBAAqB,EAAE,cAAc,yBAAyB;AAAA,EAC9D,qBAAqB,EAAE,cAAc,yBAAyB;AAAA,EAC9D,2BAA2B,EAAE,cAAc,yBAAyB;AAAA,EACpE,6BAA6B,EAAE,cAAc,yBAAyB;AAAA,EACtE,6BAA6B,EAAE,cAAc,yBAAyB;AAAA,EACtE,4BAA4B,EAAE,cAAc,yBAAyB;AAAA,EACrE,yBAAyB,EAAE,cAAc,yBAAyB;AACpE;AAEA,MAAM,uBAA4D;AAAA,EAChE,kBAAkB,OAAO,EAAE,cAAc,yBAAyB;AAAA,EAClE,qBAAqB,OAAO,EAAE,cAAc,yBAAyB;AAAA,EACrE,qBAAqB,OAAO,EAAE,cAAc,yBAAyB;AAAA,EACrE,2BAA2B,OAAO,EAAE,cAAc,yBAAyB;AAAA,EAC3E,6BAA6B,OAAO,EAAE,cAAc,yBAAyB;AAAA,EAC7E,6BAA6B,OAAO,EAAE,cAAc,yBAAyB;AAAA,EAC7E,4BAA4B,OAAO,EAAE,cAAc,yBAAyB;AAAA,EAC5E,yBAAyB,OAAO,EAAE,cAAc,yBAAyB;AAC3E;AAEA,MAAM,6CAEF;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
package/dist/esm/DSModalSlide.js
CHANGED
|
@@ -12,7 +12,6 @@ import { uid } from "uid";
|
|
|
12
12
|
import ReactDOM from "react-dom";
|
|
13
13
|
import { styled } from "@elliemae/ds-system";
|
|
14
14
|
import { Grid } from "@elliemae/ds-grid";
|
|
15
|
-
import { DSSeparator } from "@elliemae/ds-separator";
|
|
16
15
|
import { ModalHeader } from "./parts/DSModalHeader/index.js";
|
|
17
16
|
import { ModalFooter } from "./parts/DSModalFooter/index.js";
|
|
18
17
|
import { defaultProps, DSModalSlidePropTypesSchema } from "./react-desc-prop-types.js";
|
|
@@ -22,9 +21,11 @@ import {
|
|
|
22
21
|
StyledModalWrapper,
|
|
23
22
|
StyledOverlay,
|
|
24
23
|
StyledContentWrapper,
|
|
25
|
-
StyledGridContent
|
|
24
|
+
StyledGridContent,
|
|
25
|
+
StyledHeaderSeparator,
|
|
26
|
+
StyledFooterSeparator
|
|
26
27
|
} from "./styled.js";
|
|
27
|
-
import { DSModalSlideName } from "./constants/index.js";
|
|
28
|
+
import { DSModalSlideName, MODAL_SLIDE_DATA_TESTID } from "./constants/index.js";
|
|
28
29
|
const ModalSlideAnimationFix = styled.div`
|
|
29
30
|
.em-ds-modal-slide__overlay--disappearing,
|
|
30
31
|
.em-ds-modal-slide__content--disappearing {
|
|
@@ -96,6 +97,7 @@ const DSModalSlide = (props) => {
|
|
|
96
97
|
setMoving(false);
|
|
97
98
|
if (!isOpen) setShow(isOpen);
|
|
98
99
|
};
|
|
100
|
+
const modalLabelledBy = header ? modalTitleId : void 0;
|
|
99
101
|
return ReactDOM.createPortal(
|
|
100
102
|
/* @__PURE__ */ jsx(ModalSlideAnimationFix, { children: /* @__PURE__ */ jsx(
|
|
101
103
|
StyledModalWrapper,
|
|
@@ -127,33 +129,56 @@ const DSModalSlide = (props) => {
|
|
|
127
129
|
disappearing: !isOpen,
|
|
128
130
|
role: "dialog",
|
|
129
131
|
"aria-modal": "true",
|
|
130
|
-
"aria-labelledby":
|
|
132
|
+
"aria-labelledby": modalLabelledBy,
|
|
131
133
|
getOwnerProps,
|
|
132
134
|
getOwnerPropsArguments,
|
|
133
|
-
children: /* @__PURE__ */ jsxs(
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
135
|
+
children: /* @__PURE__ */ jsxs(
|
|
136
|
+
StyledGridContent,
|
|
137
|
+
{
|
|
138
|
+
rows: contentRows,
|
|
139
|
+
"data-testid": MODAL_SLIDE_DATA_TESTID.GRID_CONTENT,
|
|
140
|
+
getOwnerProps,
|
|
141
|
+
getOwnerPropsArguments,
|
|
142
|
+
children: [
|
|
143
|
+
header && React2.cloneElement(header, { fullWidth, modalTitleId }),
|
|
144
|
+
header && /* @__PURE__ */ jsx(
|
|
145
|
+
StyledHeaderSeparator,
|
|
144
146
|
{
|
|
145
|
-
|
|
146
|
-
|
|
147
|
+
colorType: "light",
|
|
148
|
+
getOwnerProps,
|
|
149
|
+
getOwnerPropsArguments
|
|
150
|
+
}
|
|
151
|
+
),
|
|
152
|
+
/* @__PURE__ */ jsx(Grid, { style: { overflow: "hidden" }, children: /* @__PURE__ */ jsx(
|
|
153
|
+
StyledContentWrapper,
|
|
154
|
+
{
|
|
155
|
+
innerRef,
|
|
147
156
|
getOwnerProps,
|
|
148
157
|
getOwnerPropsArguments,
|
|
149
|
-
children
|
|
158
|
+
children: /* @__PURE__ */ jsx(
|
|
159
|
+
StyledActualContent,
|
|
160
|
+
{
|
|
161
|
+
className: "em-ds-modal-slide__actual-content",
|
|
162
|
+
"aria-label": "Modal Slide Content",
|
|
163
|
+
getOwnerProps,
|
|
164
|
+
getOwnerPropsArguments,
|
|
165
|
+
children
|
|
166
|
+
}
|
|
167
|
+
)
|
|
168
|
+
}
|
|
169
|
+
) }),
|
|
170
|
+
footer && /* @__PURE__ */ jsx(
|
|
171
|
+
StyledFooterSeparator,
|
|
172
|
+
{
|
|
173
|
+
colorType: "light",
|
|
174
|
+
getOwnerProps,
|
|
175
|
+
getOwnerPropsArguments
|
|
150
176
|
}
|
|
151
|
-
)
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
] })
|
|
177
|
+
),
|
|
178
|
+
footer
|
|
179
|
+
]
|
|
180
|
+
}
|
|
181
|
+
)
|
|
157
182
|
}
|
|
158
183
|
)
|
|
159
184
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../src/DSModalSlide.tsx"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable max-statements */\nimport React, { useState, useEffect, useCallback, useMemo } from 'react';\nimport {\n describe,\n useGetGlobalAttributes,\n useMemoMergePropsWithDefault,\n useOwnerProps,\n} from '@elliemae/ds-props-helpers';\nimport { debounce } from 'lodash-es';\nimport { uid } from 'uid';\nimport ReactDOM from 'react-dom';\nimport { styled } from '@elliemae/ds-system';\nimport { Grid } from '@elliemae/ds-grid';\nimport {
|
|
5
|
-
"mappings": "AAAA,YAAY,WAAW;
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable max-statements, max-lines */\nimport React, { useState, useEffect, useCallback, useMemo } from 'react';\nimport {\n describe,\n useGetGlobalAttributes,\n useMemoMergePropsWithDefault,\n useOwnerProps,\n} from '@elliemae/ds-props-helpers';\nimport { debounce } from 'lodash-es';\nimport { uid } from 'uid';\nimport ReactDOM from 'react-dom';\nimport { styled } from '@elliemae/ds-system';\nimport { Grid } from '@elliemae/ds-grid';\nimport { ModalHeader } from './parts/DSModalHeader/index.js';\nimport { ModalFooter } from './parts/DSModalFooter/index.js';\nimport { defaultProps, DSModalSlidePropTypesSchema, type DSModalSlideT } from './react-desc-prop-types.js';\nimport {\n StyledActualContent,\n StyledContent,\n StyledModalWrapper,\n StyledOverlay,\n StyledContentWrapper,\n StyledGridContent,\n StyledHeaderSeparator,\n StyledFooterSeparator,\n} from './styled.js';\nimport { DSModalSlideName, MODAL_SLIDE_DATA_TESTID } from './constants/index.js';\n\n// js engine and css engine can't be guaranteed to be in sync due to how they run on different threads in the browsers\n// this means that in some edge-cases react may have \"out-dated\" information like \"isMoving\" in this case\n// this can cause some animation frame to have the animation \"after\" end but before react has updated the state\n// if the css animation is not configured to stay in the end state,\n// in those edge-cases,\n// the animation will \"jump\" back to the start and cause a flicker\n// this is the fix for that, it's an hack because the component is still css classname based\n// when we re-do the modal slide, we should integrate this as the styled component css itself instead of this extra wrapper\nconst ModalSlideAnimationFix = styled.div`\n .em-ds-modal-slide__overlay--disappearing,\n .em-ds-modal-slide__content--disappearing {\n animation-fill-mode: forwards;\n }\n`;\n// eslint-disable-next-line complexity\nconst DSModalSlide: React.FC<DSModalSlideT.Props> = (props) => {\n const propsWithDefault = useMemoMergePropsWithDefault<DSModalSlideT.InternalProps>(props, defaultProps);\n const {\n isOpen,\n children,\n getContainer,\n fullWidth,\n header,\n footer,\n fadeOut,\n fadeIn,\n overrideHeight,\n innerRef,\n onClose,\n } = propsWithDefault;\n const [, setMoving] = useState(false);\n const [show, setShow] = useState(isOpen);\n const [width, setWidth] = useState(50);\n const [height, setHeight] = useState<string | number>('100%');\n const contentRows = [...(header ? ['auto', '1px'] : []), '1fr', ...(footer ? ['1px', 'auto'] : [])];\n const modalTitleId = React.useMemo(() => `ds-modal-slide-title-${uid(5)}`, []);\n\n const handleOnKeyDown = useCallback(\n (e: React.KeyboardEvent) => {\n if (e.key === 'Escape') onClose();\n },\n [onClose],\n );\n\n const globalAttrs = useGetGlobalAttributes(props, { onKeyDown: handleOnKeyDown });\n\n const updateShow = useCallback(() => {\n if (fullWidth) setWidth(100);\n else setWidth(50);\n if (isOpen !== show) {\n setMoving(true);\n if (isOpen) {\n setShow(isOpen);\n }\n }\n }, [fullWidth, isOpen, show]);\n const { getOwnerProps, getOwnerPropsArguments } = useOwnerProps(propsWithDefault);\n\n useEffect(updateShow, [updateShow]);\n\n const container = getContainer();\n\n const handleHeight = useCallback(() => {\n const newHeight =\n overrideHeight && container.scrollHeight > container.getBoundingClientRect().height\n ? container.scrollHeight\n : container.getBoundingClientRect().height;\n setHeight(newHeight);\n }, [container, overrideHeight]);\n\n const onChangeParent = useMemo(() => debounce(handleHeight, 300, { leading: true }), [handleHeight]);\n\n useEffect(() => {\n const resizeObserver = new ResizeObserver(() => onChangeParent());\n if (container) {\n resizeObserver.observe(container);\n if (!container.style.position) {\n container.style.position = 'relative';\n }\n onChangeParent();\n }\n return () => {\n if (container) resizeObserver.unobserve(container);\n };\n }, [container, onChangeParent]);\n\n if (!show) return null;\n if (!container) return null;\n\n const handleAnimationEnd = () => {\n setMoving(false);\n if (!isOpen) setShow(isOpen);\n };\n\n const modalLabelledBy = header ? modalTitleId : undefined;\n\n return ReactDOM.createPortal(\n <ModalSlideAnimationFix>\n <StyledModalWrapper\n className=\"em-ds-modal-slide__wrapper\"\n {...globalAttrs}\n height={height}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <StyledOverlay\n className={`em-ds-modal-slide__overlay ${\n !isOpen ? 'em-ds-modal-slide__overlay--disappearing' : 'em-ds-modal-slide__overlay--showing'\n }`}\n fadeIn={fadeIn}\n fadeOut={fadeOut}\n showing={isOpen}\n disappearing={!isOpen}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <StyledContent\n className={`em-ds-modal-slide__content ${\n !isOpen ? 'em-ds-modal-slide__content--disappearing' : 'em-ds-modal-slide__content--showing'\n }`}\n onAnimationEnd={handleAnimationEnd}\n width={width}\n height={height}\n fadeIn={fadeIn}\n fadeOut={fadeOut}\n disappearing={!isOpen}\n role=\"dialog\"\n aria-modal=\"true\"\n aria-labelledby={modalLabelledBy}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <StyledGridContent\n rows={contentRows}\n data-testid={MODAL_SLIDE_DATA_TESTID.GRID_CONTENT}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n {header && React.cloneElement(header, { fullWidth, modalTitleId })}\n {header && (\n <StyledHeaderSeparator\n colorType=\"light\"\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n />\n )}\n <Grid style={{ overflow: 'hidden' }}>\n <StyledContentWrapper\n innerRef={innerRef}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <StyledActualContent\n className=\"em-ds-modal-slide__actual-content\"\n aria-label=\"Modal Slide Content\"\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n {children}\n </StyledActualContent>\n </StyledContentWrapper>\n </Grid>\n {footer && (\n <StyledFooterSeparator\n colorType=\"light\"\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n />\n )}\n {footer}\n </StyledGridContent>\n </StyledContent>\n </StyledOverlay>\n </StyledModalWrapper>\n </ModalSlideAnimationFix>,\n container,\n );\n};\n\nDSModalSlide.displayName = DSModalSlideName;\nconst DSModalSlideWithSchema = describe(DSModalSlide);\nDSModalSlideWithSchema.propTypes = DSModalSlidePropTypesSchema;\n\nexport { ModalHeader, ModalFooter, DSModalSlide, DSModalSlideWithSchema };\n\nexport default DSModalSlide;\n"],
|
|
5
|
+
"mappings": "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",
|
|
6
6
|
"names": ["React"]
|
|
7
7
|
}
|
|
@@ -6,11 +6,15 @@ const MODAL_SLIDE_SLOTS = {
|
|
|
6
6
|
OVERLAY: "overlay",
|
|
7
7
|
CONTENT: "content",
|
|
8
8
|
ACTUAL_CONTENT: "actual-content",
|
|
9
|
-
|
|
10
|
-
|
|
9
|
+
HEADER_SEPARATOR: "header-separator",
|
|
10
|
+
FOOTER_SEPARATOR: "footer-separator",
|
|
11
|
+
CONTENT_WRAPPER: "content-wrapper",
|
|
12
|
+
GRID_CONTENT: "grid-content"
|
|
11
13
|
};
|
|
12
14
|
const MODAL_SLIDE_DATA_TESTID = {
|
|
13
|
-
...slotObjectToDataTestIds(DSModalSlideName, MODAL_SLIDE_SLOTS)
|
|
15
|
+
...slotObjectToDataTestIds(DSModalSlideName, MODAL_SLIDE_SLOTS),
|
|
16
|
+
// legacy data-testid
|
|
17
|
+
GRID_CONTENT: "ds-modal-slide"
|
|
14
18
|
};
|
|
15
19
|
export {
|
|
16
20
|
DSModalSlideName,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
|
-
"sources": ["../../../../../../scripts/build/transpile/react-shim.js", "../../../src/constants/index.
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { slotObjectToDataTestIds } from '@elliemae/ds-system';\n\nexport const DSModalSlideName = 'DSModalslide';\n\nexport const MODAL_SLIDE_SLOTS = {\n ROOT: 'root',\n OVERLAY: 'overlay',\n CONTENT: 'content',\n ACTUAL_CONTENT: 'actual-content',\n
|
|
5
|
-
"mappings": "AAAA,YAAY,WAAW;ACAvB,SAAS,+BAA+B;AAEjC,MAAM,mBAAmB;AAEzB,MAAM,oBAAoB;AAAA,EAC/B,MAAM;AAAA,EACN,SAAS;AAAA,EACT,SAAS;AAAA,EACT,gBAAgB;AAAA,EAChB,
|
|
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 DSModalSlideName = 'DSModalslide';\n\nexport const MODAL_SLIDE_SLOTS = {\n ROOT: 'root',\n OVERLAY: 'overlay',\n CONTENT: 'content',\n ACTUAL_CONTENT: 'actual-content',\n HEADER_SEPARATOR: 'header-separator',\n FOOTER_SEPARATOR: 'footer-separator',\n CONTENT_WRAPPER: 'content-wrapper',\n GRID_CONTENT: 'grid-content',\n} as const;\n\nexport const MODAL_SLIDE_DATA_TESTID = {\n ...slotObjectToDataTestIds(DSModalSlideName, MODAL_SLIDE_SLOTS),\n // legacy data-testid\n GRID_CONTENT: 'ds-modal-slide',\n};\n"],
|
|
5
|
+
"mappings": "AAAA,YAAY,WAAW;ACAvB,SAAS,+BAA+B;AAEjC,MAAM,mBAAmB;AAEzB,MAAM,oBAAoB;AAAA,EAC/B,MAAM;AAAA,EACN,SAAS;AAAA,EACT,SAAS;AAAA,EACT,gBAAgB;AAAA,EAChB,kBAAkB;AAAA,EAClB,kBAAkB;AAAA,EAClB,iBAAiB;AAAA,EACjB,cAAc;AAChB;AAEO,MAAM,0BAA0B;AAAA,EACrC,GAAG,wBAAwB,kBAAkB,iBAAiB;AAAA;AAAA,EAE9D,cAAc;AAChB;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
package/dist/esm/index.js.map
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
|
-
"sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../src/index.
|
|
3
|
+
"sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../src/index.ts"],
|
|
4
4
|
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "export { DSModalSlide, DSModalSlideWithSchema } from './DSModalSlide.js';\nexport {\n DSModalHeader,\n DSModalHeaderWithSchema,\n DSModalHeader as ModalHeader,\n DSModalHeaderWithSchema as DSModalSlideHeaderWithSchema,\n DSModalHeaderName,\n MODAL_HEADER_DATA_TESTID,\n MODAL_HEADER_SLOTS,\n type DSModalHeaderT,\n} from './parts/DSModalHeader/index.js';\nexport {\n DSModalFooter,\n DSModalFooterWithSchema,\n DSModalFooter as ModalFooter,\n DSModalFooterWithSchema as DSModalSlideFooterWithSchema,\n DSModalFooterName,\n MODAL_FOOTER_DATA_TESTID,\n MODAL_FOOTER_SLOTS,\n type DSModalFooterT,\n} from './parts/DSModalFooter/index.js';\nexport type { DSModalSlideT } from './react-desc-prop-types.js';\nexport {\n MODAL_SLIDE_SLOTS,\n MODAL_SLIDE_DATA_TESTID,\n MODAL_SLIDE_DATA_TESTID as DSModalSlideDataTestIds,\n DSModalSlideName,\n} from './constants/index.js';\n"],
|
|
5
5
|
"mappings": "AAAA,YAAY,WAAW;ACAvB,SAAS,cAAc,8BAA8B;AACrD;AAAA,EACE;AAAA,EACA;AAAA,EACiB,iBAAjBA;AAAA,EAC2B,2BAA3BC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OAEK;AACP;AAAA,EACE;AAAA,EACA;AAAA,EACiB,iBAAjBC;AAAA,EAC2B,2BAA3BC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OAEK;AAEP;AAAA,EACE;AAAA,EACA;AAAA,EAC2B,2BAA3BC;AAAA,EACA;AAAA,OACK;",
|
|
6
6
|
"names": ["DSModalHeader", "DSModalHeaderWithSchema", "DSModalFooter", "DSModalFooterWithSchema", "MODAL_SLIDE_DATA_TESTID"]
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
2
|
import {
|
|
3
3
|
PropTypes,
|
|
4
|
-
|
|
4
|
+
getPropsPerSlotPropTypes,
|
|
5
5
|
globalAttributesPropTypes,
|
|
6
6
|
xstyledPropTypes
|
|
7
7
|
} from "@elliemae/ds-props-helpers";
|
|
8
|
-
import {
|
|
8
|
+
import { DSModalSlideName, MODAL_FOOTER_SLOTS } from "./constants/index.js";
|
|
9
9
|
const defaultProps = {
|
|
10
10
|
confirmLabel: "Confirm",
|
|
11
11
|
rejectLabel: "Cancel",
|
|
@@ -13,6 +13,7 @@ const defaultProps = {
|
|
|
13
13
|
rejectProps: { disabled: false, applyAriaDisabled: false }
|
|
14
14
|
};
|
|
15
15
|
const DSModalFooterPropTypes = {
|
|
16
|
+
...getPropsPerSlotPropTypes(DSModalSlideName, MODAL_FOOTER_SLOTS),
|
|
16
17
|
...globalAttributesPropTypes,
|
|
17
18
|
...xstyledPropTypes,
|
|
18
19
|
confirmLabel: PropTypes.string.description("Confirm Label"),
|
|
@@ -25,8 +26,7 @@ const DSModalFooterPropTypes = {
|
|
|
25
26
|
rejectProps: PropTypes.shape({
|
|
26
27
|
disabled: PropTypes.bool,
|
|
27
28
|
applyAriaDisabled: PropTypes.bool
|
|
28
|
-
}).description("Extra DSButton props for reject btn.")
|
|
29
|
-
...getPropsPerDatatestIdPropTypes(MODAL_FOOTER_DATA_TESTID)
|
|
29
|
+
}).description("Extra DSButton props for reject btn.")
|
|
30
30
|
};
|
|
31
31
|
const DSModalFooterPropTypesSchema = DSModalFooterPropTypes;
|
|
32
32
|
export {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../../../scripts/build/transpile/react-shim.js", "../../../../src/parts/DSModalFooter/react-desc-prop-types.ts"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable @typescript-eslint/no-empty-interface */\nimport type { GlobalAttributesT, XstyledProps, DSPropTypesSchema, ValidationMap } from '@elliemae/ds-props-helpers';\nimport {\n PropTypes,\n
|
|
5
|
-
"mappings": "AAAA,YAAY,WAAW;ACEvB;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACK;
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable @typescript-eslint/no-empty-interface */\nimport type { GlobalAttributesT, XstyledProps, DSPropTypesSchema, ValidationMap } 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 { DSModalSlideName, MODAL_FOOTER_SLOTS } from './constants/index.js';\n\nexport declare namespace DSModalFooterT {\n export interface RequiredProps {}\n\n export interface DefaultProps {\n confirmLabel: string;\n rejectLabel: string;\n confirmProps: {\n disabled: boolean;\n applyAriaDisabled?: boolean;\n innerRef?: React.MutableRefObject<HTMLButtonElement | null> | React.RefCallback<HTMLButtonElement>;\n };\n rejectProps: {\n disabled: boolean;\n applyAriaDisabled?: boolean;\n };\n }\n\n export type SlotFunctionArguments = {\n dsModalslideConfirmButton: () => object;\n dsModalslideRejectButton: () => object;\n dsModalslideFooterWrapper: () => object;\n };\n\n export interface OptionalProps\n extends TypescriptHelpersT.PropsForGlobalOnSlots<typeof DSModalSlideName, typeof MODAL_FOOTER_SLOTS> {\n onConfirm?: () => void;\n onReject?: () => void;\n }\n export interface Props\n extends Partial<DefaultProps>,\n RequiredProps,\n OptionalProps,\n Omit<GlobalAttributesT<HTMLDivElement>, keyof DefaultProps | keyof XstyledProps>,\n XstyledProps {}\n\n export interface InternalProps\n extends DefaultProps,\n RequiredProps,\n OptionalProps,\n Omit<GlobalAttributesT<HTMLDivElement>, keyof DefaultProps | keyof XstyledProps>,\n XstyledProps {}\n}\n\nexport const defaultProps: DSModalFooterT.DefaultProps = {\n confirmLabel: 'Confirm',\n rejectLabel: 'Cancel',\n confirmProps: { disabled: false },\n rejectProps: { disabled: false, applyAriaDisabled: false },\n};\n\nexport const DSModalFooterPropTypes: DSPropTypesSchema<DSModalFooterT.Props> = {\n ...getPropsPerSlotPropTypes(DSModalSlideName, MODAL_FOOTER_SLOTS),\n ...globalAttributesPropTypes,\n ...xstyledPropTypes,\n confirmLabel: PropTypes.string.description('Confirm Label'),\n rejectLabel: PropTypes.string.description('Reject Label'),\n onConfirm: PropTypes.func.description('Callback'),\n onReject: PropTypes.func.description('Callback'),\n confirmProps: PropTypes.shape({\n disabled: PropTypes.bool,\n }).description('Extra DSButton props for confirm btn.'),\n rejectProps: PropTypes.shape({\n disabled: PropTypes.bool,\n applyAriaDisabled: PropTypes.bool,\n }).description('Extra DSButton props for reject btn.'),\n};\n\nexport const DSModalFooterPropTypesSchema = DSModalFooterPropTypes as unknown as ValidationMap<DSModalFooterT.Props>;\n"],
|
|
5
|
+
"mappings": "AAAA,YAAY,WAAW;ACEvB;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACK;AAEP,SAAS,kBAAkB,0BAA0B;AA6C9C,MAAM,eAA4C;AAAA,EACvD,cAAc;AAAA,EACd,aAAa;AAAA,EACb,cAAc,EAAE,UAAU,MAAM;AAAA,EAChC,aAAa,EAAE,UAAU,OAAO,mBAAmB,MAAM;AAC3D;AAEO,MAAM,yBAAkE;AAAA,EAC7E,GAAG,yBAAyB,kBAAkB,kBAAkB;AAAA,EAChE,GAAG;AAAA,EACH,GAAG;AAAA,EACH,cAAc,UAAU,OAAO,YAAY,eAAe;AAAA,EAC1D,aAAa,UAAU,OAAO,YAAY,cAAc;AAAA,EACxD,WAAW,UAAU,KAAK,YAAY,UAAU;AAAA,EAChD,UAAU,UAAU,KAAK,YAAY,UAAU;AAAA,EAC/C,cAAc,UAAU,MAAM;AAAA,IAC5B,UAAU,UAAU;AAAA,EACtB,CAAC,EAAE,YAAY,uCAAuC;AAAA,EACtD,aAAa,UAAU,MAAM;AAAA,IAC3B,UAAU,UAAU;AAAA,IACpB,mBAAmB,UAAU;AAAA,EAC/B,CAAC,EAAE,YAAY,sCAAsC;AACvD;AAEO,MAAM,+BAA+B;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
const SlotPropsAsObj = {
|
|
3
|
+
dsModalslideConfirmButton: { "aria-label": "just a typescript test" },
|
|
4
|
+
dsModalslideRejectButton: { "aria-label": "just a typescript test" },
|
|
5
|
+
dsModalslideFooterWrapper: { "aria-label": "just a typescript test" }
|
|
6
|
+
};
|
|
7
|
+
const SlotPropsAsFunctions = {
|
|
8
|
+
dsModalslideConfirmButton: () => ({ "aria-label": "just a typescript test" }),
|
|
9
|
+
dsModalslideRejectButton: () => ({ "aria-label": "just a typescript test" }),
|
|
10
|
+
dsModalslideFooterWrapper: () => ({ "aria-label": "just a typescript test" })
|
|
11
|
+
};
|
|
12
|
+
const EnsureAllSlotsExistInSlotFunctionArguments = SlotPropsAsFunctions;
|
|
13
|
+
//# sourceMappingURL=slot-props.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../../../../../../scripts/build/transpile/react-shim.js", "../../../../../src/parts/DSModalFooter/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';\n\nimport type { DSModalFooterT } from '../react-desc-prop-types.js';\nimport type { DSModalSlideName, MODAL_FOOTER_SLOTS } from '../constants/index.js';\n\nconst SlotPropsAsObj: Partial<DSModalFooterT.Props> = {\n dsModalslideConfirmButton: { 'aria-label': 'just a typescript test' },\n dsModalslideRejectButton: { 'aria-label': 'just a typescript test' },\n dsModalslideFooterWrapper: { 'aria-label': 'just a typescript test' },\n};\n\nconst SlotPropsAsFunctions: DSModalFooterT.SlotFunctionArguments = {\n dsModalslideConfirmButton: () => ({ 'aria-label': 'just a typescript test' }),\n dsModalslideRejectButton: () => ({ 'aria-label': 'just a typescript test' }),\n dsModalslideFooterWrapper: () => ({ 'aria-label': 'just a typescript test' }),\n};\n\nconst EnsureAllSlotsExistInSlotFunctionArguments: Required<\n TypescriptHelpersT.PropsForSlots<typeof DSModalSlideName, typeof MODAL_FOOTER_SLOTS>\n> = SlotPropsAsFunctions;\n"],
|
|
5
|
+
"mappings": "AAAA,YAAY,WAAW;ACOvB,MAAM,iBAAgD;AAAA,EACpD,2BAA2B,EAAE,cAAc,yBAAyB;AAAA,EACpE,0BAA0B,EAAE,cAAc,yBAAyB;AAAA,EACnE,2BAA2B,EAAE,cAAc,yBAAyB;AACtE;AAEA,MAAM,uBAA6D;AAAA,EACjE,2BAA2B,OAAO,EAAE,cAAc,yBAAyB;AAAA,EAC3E,0BAA0B,OAAO,EAAE,cAAc,yBAAyB;AAAA,EAC1E,2BAA2B,OAAO,EAAE,cAAc,yBAAyB;AAC7E;AAEA,MAAM,6CAEF;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
|
@@ -10,7 +10,7 @@ import {
|
|
|
10
10
|
StyledHeaderLeftSide,
|
|
11
11
|
StyledTitle,
|
|
12
12
|
HeaderWrapper,
|
|
13
|
-
|
|
13
|
+
StyledToolbarSeparator,
|
|
14
14
|
StyledCloseButton
|
|
15
15
|
} from "../../styled.js";
|
|
16
16
|
const DSModalHeader = (props) => {
|
|
@@ -34,18 +34,25 @@ const DSModalHeader = (props) => {
|
|
|
34
34
|
}
|
|
35
35
|
) }) }),
|
|
36
36
|
toolbar,
|
|
37
|
-
toolbar && /* @__PURE__ */ jsx(
|
|
37
|
+
toolbar && /* @__PURE__ */ jsx(
|
|
38
|
+
StyledToolbarSeparator,
|
|
39
|
+
{
|
|
40
|
+
isVertical: true,
|
|
41
|
+
getOwnerProps,
|
|
42
|
+
getOwnerPropsArguments
|
|
43
|
+
}
|
|
44
|
+
),
|
|
38
45
|
/* @__PURE__ */ jsx(
|
|
39
46
|
StyledCloseButton,
|
|
40
47
|
{
|
|
41
48
|
"data-testid": MODAL_HEADER_DATA_TESTID.CLOSE_BUTTON,
|
|
42
|
-
"aria-label": "Close modal slide",
|
|
49
|
+
"aria-label": title ? `Close ${title}` : "Close modal slide",
|
|
43
50
|
buttonType: "icon",
|
|
44
51
|
onClick: onClose,
|
|
45
52
|
innerRef,
|
|
46
53
|
getOwnerProps,
|
|
47
54
|
getOwnerPropsArguments,
|
|
48
|
-
children: /* @__PURE__ */ jsx(Close, {
|
|
55
|
+
children: /* @__PURE__ */ jsx(Close, { size: "s", color: ["brand-primary", "600"] })
|
|
49
56
|
}
|
|
50
57
|
)
|
|
51
58
|
]
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../../../scripts/build/transpile/react-shim.js", "../../../../src/parts/DSModalHeader/DSModalHeader.tsx"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import React from 'react';\nimport { describe } from '@elliemae/ds-props-helpers';\nimport { Close } from '@elliemae/ds-icons';\nimport { type DSModalHeaderT, DSModalHeaderPropTypesSchema } from './react-desc-prop-types.js';\nimport { useModalHeader } from './config/useModalHeader.js';\nimport { MODAL_HEADER_DATA_TESTID, DSModalHeaderName } from './constants/index.js';\nimport {\n StyledHeader,\n StyledHeaderLeftSide,\n StyledTitle,\n HeaderWrapper,\n
|
|
5
|
-
"mappings": "AAAA,YAAY,WAAW;ACqBnB,SAOM,KAPN;AApBJ,SAAS,gBAAgB;AACzB,SAAS,aAAa;AACtB,SAA8B,oCAAoC;AAClE,SAAS,sBAAsB;AAC/B,SAAS,0BAA0B,yBAAyB;AAC5D;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACK;AAEP,MAAM,gBAA2D,CAAC,UAAU;AAC1E,QAAM,EAAE,kBAAkB,eAAe,uBAAuB,IAAI,eAAe,KAAK;AAExF,QAAM,EAAE,UAAU,OAAO,SAAS,SAAS,cAAc,aAAa,IAAI;AAE1E,SACE;AAAA,IAAC;AAAA;AAAA,MACC,cAAW;AAAA,MACX;AAAA,MACA;AAAA,MAEA;AAAA,4BAAC,wBAAqB,eAA8B,wBAClD,8BAAC,gBAAa,eAA8B,wBAC1C;AAAA,UAAC;AAAA;AAAA,YACC,IAAI;AAAA,YACJ,SAAS;AAAA,YACT;AAAA,YACA;AAAA,YAEC;AAAA;AAAA,QACH,GACF,GACF;AAAA,QAEC;AAAA,QAEA,
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import React from 'react';\nimport { describe } from '@elliemae/ds-props-helpers';\nimport { Close } from '@elliemae/ds-icons';\nimport { type DSModalHeaderT, DSModalHeaderPropTypesSchema } from './react-desc-prop-types.js';\nimport { useModalHeader } from './config/useModalHeader.js';\nimport { MODAL_HEADER_DATA_TESTID, DSModalHeaderName } from './constants/index.js';\nimport {\n StyledHeader,\n StyledHeaderLeftSide,\n StyledTitle,\n HeaderWrapper,\n StyledToolbarSeparator,\n StyledCloseButton,\n} from '../../styled.js';\n\nconst DSModalHeader: React.ComponentType<DSModalHeaderT.Props> = (props) => {\n const { propsWithDefault, getOwnerProps, getOwnerPropsArguments } = useModalHeader(props);\n\n const { innerRef, title, onClose, toolbar, headingLevel, modalTitleId } = propsWithDefault;\n\n return (\n <HeaderWrapper\n aria-label=\"Modal Slide Header\"\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <StyledHeaderLeftSide getOwnerProps={getOwnerProps} getOwnerPropsArguments={getOwnerPropsArguments}>\n <StyledHeader getOwnerProps={getOwnerProps} getOwnerPropsArguments={getOwnerPropsArguments}>\n <StyledTitle\n id={modalTitleId}\n variant={headingLevel}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n {title}\n </StyledTitle>\n </StyledHeader>\n </StyledHeaderLeftSide>\n\n {toolbar}\n\n {toolbar && (\n <StyledToolbarSeparator\n isVertical\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n />\n )}\n\n <StyledCloseButton\n data-testid={MODAL_HEADER_DATA_TESTID.CLOSE_BUTTON}\n aria-label={title ? `Close ${title}` : 'Close modal slide'}\n buttonType=\"icon\"\n onClick={onClose}\n innerRef={innerRef}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <Close size=\"s\" color={['brand-primary', '600']} />\n </StyledCloseButton>\n </HeaderWrapper>\n );\n};\n\nDSModalHeader.displayName = DSModalHeaderName;\nconst DSModalHeaderWithSchema = describe(DSModalHeader);\nDSModalHeaderWithSchema.propTypes = DSModalHeaderPropTypesSchema;\n\nexport { DSModalHeader, DSModalHeaderWithSchema };\n"],
|
|
5
|
+
"mappings": "AAAA,YAAY,WAAW;ACqBnB,SAOM,KAPN;AApBJ,SAAS,gBAAgB;AACzB,SAAS,aAAa;AACtB,SAA8B,oCAAoC;AAClE,SAAS,sBAAsB;AAC/B,SAAS,0BAA0B,yBAAyB;AAC5D;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACK;AAEP,MAAM,gBAA2D,CAAC,UAAU;AAC1E,QAAM,EAAE,kBAAkB,eAAe,uBAAuB,IAAI,eAAe,KAAK;AAExF,QAAM,EAAE,UAAU,OAAO,SAAS,SAAS,cAAc,aAAa,IAAI;AAE1E,SACE;AAAA,IAAC;AAAA;AAAA,MACC,cAAW;AAAA,MACX;AAAA,MACA;AAAA,MAEA;AAAA,4BAAC,wBAAqB,eAA8B,wBAClD,8BAAC,gBAAa,eAA8B,wBAC1C;AAAA,UAAC;AAAA;AAAA,YACC,IAAI;AAAA,YACJ,SAAS;AAAA,YACT;AAAA,YACA;AAAA,YAEC;AAAA;AAAA,QACH,GACF,GACF;AAAA,QAEC;AAAA,QAEA,WACC;AAAA,UAAC;AAAA;AAAA,YACC,YAAU;AAAA,YACV;AAAA,YACA;AAAA;AAAA,QACF;AAAA,QAGF;AAAA,UAAC;AAAA;AAAA,YACC,eAAa,yBAAyB;AAAA,YACtC,cAAY,QAAQ,SAAS,KAAK,KAAK;AAAA,YACvC,YAAW;AAAA,YACX,SAAS;AAAA,YACT;AAAA,YACA;AAAA,YACA;AAAA,YAEA,8BAAC,SAAM,MAAK,KAAI,OAAO,CAAC,iBAAiB,KAAK,GAAG;AAAA;AAAA,QACnD;AAAA;AAAA;AAAA,EACF;AAEJ;AAEA,cAAc,cAAc;AAC5B,MAAM,0BAA0B,SAAS,aAAa;AACtD,wBAAwB,YAAY;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -7,10 +7,12 @@ const MODAL_HEADER_SLOTS = {
|
|
|
7
7
|
HEADER_LEFT_SIDE: "header-left-side",
|
|
8
8
|
HEADER: "header",
|
|
9
9
|
HEADER_WRAPPER: "header-wrapper",
|
|
10
|
+
TOOLBAR_SEPARATOR: "toolbar-separator",
|
|
10
11
|
CLOSE_BUTTON: "close-button"
|
|
11
12
|
};
|
|
12
13
|
const MODAL_HEADER_DATA_TESTID = {
|
|
13
14
|
...slotObjectToDataTestIds(DSModalSlideName, MODAL_HEADER_SLOTS),
|
|
15
|
+
// legacy test IDs — preserved for QA/consumer compatibility, breaking change if removed
|
|
14
16
|
CLOSE_BUTTON: "modal-slider-header-close"
|
|
15
17
|
};
|
|
16
18
|
export {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../../../../scripts/build/transpile/react-shim.js", "../../../../../src/parts/DSModalHeader/constants/index.ts"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { slotObjectToDataTestIds } from '@elliemae/ds-system';\nimport { DSModalSlideName } from '../../../constants/index.js';\nexport { DSModalSlideName };\n\nexport const DSModalHeaderName = 'DSModalHeader';\n\nexport const MODAL_HEADER_SLOTS = {\n TITLE: 'title',\n HEADER_LEFT_SIDE: 'header-left-side',\n HEADER: 'header',\n HEADER_WRAPPER: 'header-wrapper',\n CLOSE_BUTTON: 'close-button',\n} as const;\n\nexport const MODAL_HEADER_DATA_TESTID = {\n ...slotObjectToDataTestIds(DSModalSlideName, MODAL_HEADER_SLOTS),\n CLOSE_BUTTON: 'modal-slider-header-close',\n};\n"],
|
|
5
|
-
"mappings": "AAAA,YAAY,WAAW;ACAvB,SAAS,+BAA+B;AACxC,SAAS,wBAAwB;AAG1B,MAAM,oBAAoB;AAE1B,MAAM,qBAAqB;AAAA,EAChC,OAAO;AAAA,EACP,kBAAkB;AAAA,EAClB,QAAQ;AAAA,EACR,gBAAgB;AAAA,EAChB,cAAc;AAChB;AAEO,MAAM,2BAA2B;AAAA,EACtC,GAAG,wBAAwB,kBAAkB,kBAAkB;AAAA,
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { slotObjectToDataTestIds } from '@elliemae/ds-system';\nimport { DSModalSlideName } from '../../../constants/index.js';\nexport { DSModalSlideName };\n\nexport const DSModalHeaderName = 'DSModalHeader';\n\nexport const MODAL_HEADER_SLOTS = {\n TITLE: 'title',\n HEADER_LEFT_SIDE: 'header-left-side',\n HEADER: 'header',\n HEADER_WRAPPER: 'header-wrapper',\n TOOLBAR_SEPARATOR: 'toolbar-separator',\n CLOSE_BUTTON: 'close-button',\n} as const;\n\nexport const MODAL_HEADER_DATA_TESTID = {\n ...slotObjectToDataTestIds(DSModalSlideName, MODAL_HEADER_SLOTS),\n // legacy test IDs \u2014 preserved for QA/consumer compatibility, breaking change if removed\n CLOSE_BUTTON: 'modal-slider-header-close',\n};\n"],
|
|
5
|
+
"mappings": "AAAA,YAAY,WAAW;ACAvB,SAAS,+BAA+B;AACxC,SAAS,wBAAwB;AAG1B,MAAM,oBAAoB;AAE1B,MAAM,qBAAqB;AAAA,EAChC,OAAO;AAAA,EACP,kBAAkB;AAAA,EAClB,QAAQ;AAAA,EACR,gBAAgB;AAAA,EAChB,mBAAmB;AAAA,EACnB,cAAc;AAChB;AAEO,MAAM,2BAA2B;AAAA,EACtC,GAAG,wBAAwB,kBAAkB,kBAAkB;AAAA;AAAA,EAE/D,cAAc;AAChB;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../../../scripts/build/transpile/react-shim.js", "../../../../src/parts/DSModalHeader/react-desc-prop-types.ts"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable @typescript-eslint/no-empty-interface */\nimport type { GlobalAttributesT, XstyledProps, DSPropTypesSchema, ValidationMap } 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 type { DSTypographyT } from '@elliemae/ds-typography';\nimport { DSModalSlideName, MODAL_HEADER_SLOTS } from './constants/index.js';\n\nexport declare namespace DSModalHeaderT {\n export interface RequiredProps {}\n\n export interface DefaultProps {\n title: string;\n onClose: () => void;\n headingLevel: DSTypographyT.HeadingVariants;\n modalTitleId: string;\n }\n\n export interface OptionalProps\n extends TypescriptHelpersT.PropsForGlobalOnSlots<typeof DSModalSlideName, typeof MODAL_HEADER_SLOTS> {\n toolbar?: React.ReactNode;\n innerRef?: React.MutableRefObject<HTMLButtonElement | null> | React.RefCallback<HTMLButtonElement>;\n }\n export interface Props\n extends Partial<DefaultProps>,\n OptionalProps,\n Omit<GlobalAttributesT<HTMLButtonElement>, keyof DefaultProps | keyof XstyledProps>,\n XstyledProps,\n RequiredProps {}\n\n export interface InternalProps\n extends DefaultProps,\n OptionalProps,\n Omit<GlobalAttributesT<HTMLButtonElement>, keyof DefaultProps | keyof XstyledProps>,\n XstyledProps,\n RequiredProps {}\n}\n\nexport const defaultProps: DSModalHeaderT.DefaultProps = {\n title: '',\n onClose: () => null,\n headingLevel: 'h3',\n modalTitleId: 'ds-modal-slide-title',\n};\n\nexport const DSModalHeaderPropTypes: DSPropTypesSchema<DSModalHeaderT.Props> = {\n ...getPropsPerSlotPropTypes(DSModalSlideName, MODAL_HEADER_SLOTS),\n ...globalAttributesPropTypes,\n ...xstyledPropTypes,\n title: PropTypes.string.description('Modal title'),\n onClose: PropTypes.func.description('Callback when modal is closed'),\n toolbar: PropTypes.node.description('Modal toolbar component'),\n innerRef: PropTypes.oneOfType([PropTypes.func, PropTypes.object]).description('Ref to the modal header button'),\n headingLevel: PropTypes.string.description('Heading level for modal title'),\n modalTitleId: PropTypes.string.description('Id of the modal title'),\n};\n\nexport const DSModalHeaderPropTypesSchema = DSModalHeaderPropTypes as unknown as ValidationMap<DSModalHeaderT.Props>;\n"],
|
|
5
|
-
"mappings": "AAAA,YAAY,WAAW;ACEvB;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACK;AAGP,SAAS,kBAAkB,0BAA0B;
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable @typescript-eslint/no-empty-interface */\nimport type { GlobalAttributesT, XstyledProps, DSPropTypesSchema, ValidationMap } 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 type { DSTypographyT } from '@elliemae/ds-typography';\nimport { DSModalSlideName, MODAL_HEADER_SLOTS } from './constants/index.js';\n\nexport declare namespace DSModalHeaderT {\n export interface RequiredProps {}\n\n export interface DefaultProps {\n title: string;\n onClose: () => void;\n headingLevel: DSTypographyT.HeadingVariants;\n modalTitleId: string;\n }\n\n export type SlotFunctionArguments = {\n dsModalslideTitle: () => object;\n dsModalslideHeaderLeftSide: () => object;\n dsModalslideHeader: () => object;\n dsModalslideHeaderWrapper: () => object;\n dsModalslideToolbarSeparator: () => object;\n dsModalslideCloseButton: () => object;\n };\n\n export interface OptionalProps\n extends TypescriptHelpersT.PropsForGlobalOnSlots<typeof DSModalSlideName, typeof MODAL_HEADER_SLOTS> {\n toolbar?: React.ReactNode;\n innerRef?: React.MutableRefObject<HTMLButtonElement | null> | React.RefCallback<HTMLButtonElement>;\n }\n export interface Props\n extends Partial<DefaultProps>,\n OptionalProps,\n Omit<GlobalAttributesT<HTMLButtonElement>, keyof DefaultProps | keyof XstyledProps>,\n XstyledProps,\n RequiredProps {}\n\n export interface InternalProps\n extends DefaultProps,\n OptionalProps,\n Omit<GlobalAttributesT<HTMLButtonElement>, keyof DefaultProps | keyof XstyledProps>,\n XstyledProps,\n RequiredProps {}\n}\n\nexport const defaultProps: DSModalHeaderT.DefaultProps = {\n title: '',\n onClose: () => null,\n headingLevel: 'h3',\n modalTitleId: 'ds-modal-slide-title',\n};\n\nexport const DSModalHeaderPropTypes: DSPropTypesSchema<DSModalHeaderT.Props> = {\n ...getPropsPerSlotPropTypes(DSModalSlideName, MODAL_HEADER_SLOTS),\n ...globalAttributesPropTypes,\n ...xstyledPropTypes,\n title: PropTypes.string.description('Modal title'),\n onClose: PropTypes.func.description('Callback when modal is closed'),\n toolbar: PropTypes.node.description('Modal toolbar component'),\n innerRef: PropTypes.oneOfType([PropTypes.func, PropTypes.object]).description('Ref to the modal header button'),\n headingLevel: PropTypes.string.description('Heading level for modal title'),\n modalTitleId: PropTypes.string.description('Id of the modal title'),\n};\n\nexport const DSModalHeaderPropTypesSchema = DSModalHeaderPropTypes as unknown as ValidationMap<DSModalHeaderT.Props>;\n"],
|
|
5
|
+
"mappings": "AAAA,YAAY,WAAW;ACEvB;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACK;AAGP,SAAS,kBAAkB,0BAA0B;AAyC9C,MAAM,eAA4C;AAAA,EACvD,OAAO;AAAA,EACP,SAAS,MAAM;AAAA,EACf,cAAc;AAAA,EACd,cAAc;AAChB;AAEO,MAAM,yBAAkE;AAAA,EAC7E,GAAG,yBAAyB,kBAAkB,kBAAkB;AAAA,EAChE,GAAG;AAAA,EACH,GAAG;AAAA,EACH,OAAO,UAAU,OAAO,YAAY,aAAa;AAAA,EACjD,SAAS,UAAU,KAAK,YAAY,+BAA+B;AAAA,EACnE,SAAS,UAAU,KAAK,YAAY,yBAAyB;AAAA,EAC7D,UAAU,UAAU,UAAU,CAAC,UAAU,MAAM,UAAU,MAAM,CAAC,EAAE,YAAY,gCAAgC;AAAA,EAC9G,cAAc,UAAU,OAAO,YAAY,+BAA+B;AAAA,EAC1E,cAAc,UAAU,OAAO,YAAY,uBAAuB;AACpE;AAEO,MAAM,+BAA+B;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
const SlotPropsAsObj = {
|
|
3
|
+
dsModalslideTitle: { "aria-label": "just a typescript test" },
|
|
4
|
+
dsModalslideHeaderLeftSide: { "aria-label": "just a typescript test" },
|
|
5
|
+
dsModalslideHeader: { "aria-label": "just a typescript test" },
|
|
6
|
+
dsModalslideHeaderWrapper: { "aria-label": "just a typescript test" },
|
|
7
|
+
dsModalslideToolbarSeparator: { "aria-label": "just a typescript test" },
|
|
8
|
+
dsModalslideCloseButton: { "aria-label": "just a typescript test" }
|
|
9
|
+
};
|
|
10
|
+
const SlotPropsAsFunctions = {
|
|
11
|
+
dsModalslideTitle: () => ({ "aria-label": "just a typescript test" }),
|
|
12
|
+
dsModalslideHeaderLeftSide: () => ({ "aria-label": "just a typescript test" }),
|
|
13
|
+
dsModalslideHeader: () => ({ "aria-label": "just a typescript test" }),
|
|
14
|
+
dsModalslideHeaderWrapper: () => ({ "aria-label": "just a typescript test" }),
|
|
15
|
+
dsModalslideToolbarSeparator: () => ({ "aria-label": "just a typescript test" }),
|
|
16
|
+
dsModalslideCloseButton: () => ({ "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/parts/DSModalHeader/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';\n\nimport type { DSModalHeaderT } from '../react-desc-prop-types.js';\nimport type { DSModalSlideName, MODAL_HEADER_SLOTS } from '../constants/index.js';\n\nconst SlotPropsAsObj: Partial<DSModalHeaderT.Props> = {\n dsModalslideTitle: { 'aria-label': 'just a typescript test' },\n dsModalslideHeaderLeftSide: { 'aria-label': 'just a typescript test' },\n dsModalslideHeader: { 'aria-label': 'just a typescript test' },\n dsModalslideHeaderWrapper: { 'aria-label': 'just a typescript test' },\n dsModalslideToolbarSeparator: { 'aria-label': 'just a typescript test' },\n dsModalslideCloseButton: { 'aria-label': 'just a typescript test' },\n};\n\nconst SlotPropsAsFunctions: DSModalHeaderT.SlotFunctionArguments = {\n dsModalslideTitle: () => ({ 'aria-label': 'just a typescript test' }),\n dsModalslideHeaderLeftSide: () => ({ 'aria-label': 'just a typescript test' }),\n dsModalslideHeader: () => ({ 'aria-label': 'just a typescript test' }),\n dsModalslideHeaderWrapper: () => ({ 'aria-label': 'just a typescript test' }),\n dsModalslideToolbarSeparator: () => ({ 'aria-label': 'just a typescript test' }),\n dsModalslideCloseButton: () => ({ 'aria-label': 'just a typescript test' }),\n};\n\nconst EnsureAllSlotsExistInSlotFunctionArguments: Required<\n TypescriptHelpersT.PropsForSlots<typeof DSModalSlideName, typeof MODAL_HEADER_SLOTS>\n> = SlotPropsAsFunctions;\n"],
|
|
5
|
+
"mappings": "AAAA,YAAY,WAAW;ACOvB,MAAM,iBAAgD;AAAA,EACpD,mBAAmB,EAAE,cAAc,yBAAyB;AAAA,EAC5D,4BAA4B,EAAE,cAAc,yBAAyB;AAAA,EACrE,oBAAoB,EAAE,cAAc,yBAAyB;AAAA,EAC7D,2BAA2B,EAAE,cAAc,yBAAyB;AAAA,EACpE,8BAA8B,EAAE,cAAc,yBAAyB;AAAA,EACvE,yBAAyB,EAAE,cAAc,yBAAyB;AACpE;AAEA,MAAM,uBAA6D;AAAA,EACjE,mBAAmB,OAAO,EAAE,cAAc,yBAAyB;AAAA,EACnE,4BAA4B,OAAO,EAAE,cAAc,yBAAyB;AAAA,EAC5E,oBAAoB,OAAO,EAAE,cAAc,yBAAyB;AAAA,EACpE,2BAA2B,OAAO,EAAE,cAAc,yBAAyB;AAAA,EAC3E,8BAA8B,OAAO,EAAE,cAAc,yBAAyB;AAAA,EAC9E,yBAAyB,OAAO,EAAE,cAAc,yBAAyB;AAC3E;AAEA,MAAM,6CAEF;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
|
@@ -1,5 +1,11 @@
|
|
|
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 { DSModalSlideName, MODAL_SLIDE_SLOTS } from "./constants/index.js";
|
|
3
9
|
const defaultProps = {
|
|
4
10
|
isOpen: false,
|
|
5
11
|
centered: false,
|
|
@@ -11,6 +17,7 @@ const defaultProps = {
|
|
|
11
17
|
}
|
|
12
18
|
};
|
|
13
19
|
const DSModalSlidePropTypes = {
|
|
20
|
+
...getPropsPerSlotPropTypes(DSModalSlideName, MODAL_SLIDE_SLOTS),
|
|
14
21
|
...globalAttributesPropTypes,
|
|
15
22
|
...xstyledPropTypes,
|
|
16
23
|
/**
|