@elliemae/ds-circular-progress-indicator 2.3.0-alpha.2 → 2.3.0-alpha.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/cjs/index.js +3 -0
- package/cjs/index.js.map +2 -2
- package/cjs/v2/DSCircularIndeterminateIndicator.js +149 -0
- package/cjs/v2/DSCircularIndeterminateIndicator.js.map +7 -0
- package/cjs/v2/index.js +36 -0
- package/cjs/v2/index.js.map +7 -0
- package/cjs/v2/react-desc-prop-types.js +56 -0
- package/cjs/v2/react-desc-prop-types.js.map +7 -0
- package/esm/index.js +3 -0
- package/esm/index.js.map +2 -2
- package/esm/v2/DSCircularIndeterminateIndicator.js +120 -0
- package/esm/v2/DSCircularIndeterminateIndicator.js.map +7 -0
- package/esm/v2/index.js +10 -0
- package/esm/v2/index.js.map +7 -0
- package/esm/v2/react-desc-prop-types.js +27 -0
- package/esm/v2/react-desc-prop-types.js.map +7 -0
- package/package.json +15 -3
- package/types/index.d.ts +1 -0
- package/types/v2/DSCircularIndeterminateIndicator.d.ts +9 -0
- package/types/v2/index.d.ts +1 -0
- package/types/v2/react-desc-prop-types.d.ts +32 -0
package/cjs/index.js
CHANGED
|
@@ -28,10 +28,13 @@ var __toCommonJS = /* @__PURE__ */ ((cache) => {
|
|
|
28
28
|
var src_exports = {};
|
|
29
29
|
__export(src_exports, {
|
|
30
30
|
CircularProgressIndicatorWithSchema: () => import_DSCircularProgressIndicator.CircularProgressIndicatorWithSchema,
|
|
31
|
+
DSCircularIndeterminateIndicator: () => import_v2.DSCircularIndeterminateIndicator,
|
|
32
|
+
DSCircularIndeterminateIndicatorWithSchema: () => import_v2.DSCircularIndeterminateIndicatorWithSchema,
|
|
31
33
|
DSCircularProgressIndicator: () => import_DSCircularProgressIndicator.default,
|
|
32
34
|
default: () => import_DSCircularProgressIndicator.default
|
|
33
35
|
});
|
|
34
36
|
var React = __toESM(require("react"));
|
|
35
37
|
var import_DSCircularProgressIndicator = __toESM(require("./DSCircularProgressIndicator"));
|
|
38
|
+
var import_v2 = require("./v2");
|
|
36
39
|
module.exports = __toCommonJS(src_exports);
|
|
37
40
|
//# sourceMappingURL=index.js.map
|
package/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": ["/* eslint-disable import/named */\nexport {\n default,\n default as DSCircularProgressIndicator,\n CircularProgressIndicatorWithSchema,\n} from './DSCircularProgressIndicator';\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADCvB,yCAIO;",
|
|
4
|
+
"sourcesContent": ["/* eslint-disable import/named */\nexport {\n default,\n default as DSCircularProgressIndicator,\n CircularProgressIndicatorWithSchema,\n} from './DSCircularProgressIndicator';\nexport { DSCircularIndeterminateIndicator, DSCircularIndeterminateIndicatorWithSchema } from './v2';\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADCvB,yCAIO;AACP,gBAA6F;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -0,0 +1,149 @@
|
|
|
1
|
+
var __create = Object.create;
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
6
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
|
+
var __markAsModule = (target) => __defProp(target, "__esModule", { value: true });
|
|
8
|
+
var __export = (target, all) => {
|
|
9
|
+
for (var name in all)
|
|
10
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
+
};
|
|
12
|
+
var __reExport = (target, module2, copyDefault, desc) => {
|
|
13
|
+
if (module2 && typeof module2 === "object" || typeof module2 === "function") {
|
|
14
|
+
for (let key of __getOwnPropNames(module2))
|
|
15
|
+
if (!__hasOwnProp.call(target, key) && (copyDefault || key !== "default"))
|
|
16
|
+
__defProp(target, key, { get: () => module2[key], enumerable: !(desc = __getOwnPropDesc(module2, key)) || desc.enumerable });
|
|
17
|
+
}
|
|
18
|
+
return target;
|
|
19
|
+
};
|
|
20
|
+
var __toESM = (module2, isNodeMode) => {
|
|
21
|
+
return __reExport(__markAsModule(__defProp(module2 != null ? __create(__getProtoOf(module2)) : {}, "default", !isNodeMode && module2 && module2.__esModule ? { get: () => module2.default, enumerable: true } : { value: module2, enumerable: true })), module2);
|
|
22
|
+
};
|
|
23
|
+
var __toCommonJS = /* @__PURE__ */ ((cache) => {
|
|
24
|
+
return (module2, temp) => {
|
|
25
|
+
return cache && cache.get(module2) || (temp = __reExport(__markAsModule({}), module2, 1), cache && cache.set(module2, temp), temp);
|
|
26
|
+
};
|
|
27
|
+
})(typeof WeakMap !== "undefined" ? /* @__PURE__ */ new WeakMap() : 0);
|
|
28
|
+
var DSCircularIndeterminateIndicator_exports = {};
|
|
29
|
+
__export(DSCircularIndeterminateIndicator_exports, {
|
|
30
|
+
DSCircularIndeterminateIndicator: () => DSCircularIndeterminateIndicator,
|
|
31
|
+
DSCircularIndeterminateIndicatorWithSchema: () => DSCircularIndeterminateIndicatorWithSchema
|
|
32
|
+
});
|
|
33
|
+
var React = __toESM(require("react"));
|
|
34
|
+
var import_react = __toESM(require("react"));
|
|
35
|
+
var import_ds_grid = require("@elliemae/ds-grid");
|
|
36
|
+
var import_ds_tooltip = require("@elliemae/ds-tooltip");
|
|
37
|
+
var import_react_desc = require("react-desc");
|
|
38
|
+
var import_styled_components = __toESM(require("styled-components"));
|
|
39
|
+
var import_ds_system = require("@elliemae/ds-system");
|
|
40
|
+
var import_uid = require("uid");
|
|
41
|
+
var import_react_desc_prop_types = require("./react-desc-prop-types");
|
|
42
|
+
const r = import_ds_system.kfrm`to { transform: rotate(2turn) }`;
|
|
43
|
+
const s = import_ds_system.kfrm`0%, 39% { stroke-dasharray: 942px 2826px }`;
|
|
44
|
+
const StyledSvg = import_styled_components.default.svg`
|
|
45
|
+
#gg {
|
|
46
|
+
transform: rotate(45deg);
|
|
47
|
+
stroke: url(#${(props) => props.linearGradientUid});
|
|
48
|
+
mask: url(#${(props) => props.maskUid});
|
|
49
|
+
}
|
|
50
|
+
mask use {
|
|
51
|
+
stroke: #fff;
|
|
52
|
+
stroke-linecap: round;
|
|
53
|
+
stroke-dasharray: 942px 2826px;
|
|
54
|
+
animation: ${r} ${(props) => props.duration}s cubic-bezier(0.5, -0.43, 0.5, 1.43) infinite,
|
|
55
|
+
${s} ${(props) => props.duration / 2}s ease-in-out infinite alternate;
|
|
56
|
+
}
|
|
57
|
+
`;
|
|
58
|
+
const sizeToPx = {
|
|
59
|
+
xs: "16px",
|
|
60
|
+
s: "24px",
|
|
61
|
+
m: "32px",
|
|
62
|
+
l: "48px",
|
|
63
|
+
xl: "56px",
|
|
64
|
+
xxl: "64px"
|
|
65
|
+
};
|
|
66
|
+
const sizeToWeight = {
|
|
67
|
+
xs: "10%",
|
|
68
|
+
s: "9%",
|
|
69
|
+
m: "8%",
|
|
70
|
+
l: "6%",
|
|
71
|
+
xl: "5%",
|
|
72
|
+
xxl: "4%"
|
|
73
|
+
};
|
|
74
|
+
const colorToHex = {
|
|
75
|
+
light: "#FFFFFF",
|
|
76
|
+
dark: "#0F364A"
|
|
77
|
+
};
|
|
78
|
+
const sizeToTextSize = {
|
|
79
|
+
xs: "12px",
|
|
80
|
+
s: "12px",
|
|
81
|
+
m: "12px",
|
|
82
|
+
l: "13px",
|
|
83
|
+
xl: "14px",
|
|
84
|
+
xxl: "16px"
|
|
85
|
+
};
|
|
86
|
+
const DSCircularIndeterminateIndicator = ({
|
|
87
|
+
size = "m",
|
|
88
|
+
color = "dark",
|
|
89
|
+
text = "",
|
|
90
|
+
showText = true,
|
|
91
|
+
withTooltip = false,
|
|
92
|
+
tooltipStartPlacementPreference = "bottom",
|
|
93
|
+
__duration = 1.5
|
|
94
|
+
}) => {
|
|
95
|
+
const Wrapper = withTooltip ? import_ds_tooltip.DSTooltipV3 : ({ children }) => /* @__PURE__ */ import_react.default.createElement(import_react.default.Fragment, null, children);
|
|
96
|
+
const linearGradientUid = (0, import_uid.uid)(16);
|
|
97
|
+
const maskUid = (0, import_uid.uid)(16);
|
|
98
|
+
const circleUid = (0, import_uid.uid)(16);
|
|
99
|
+
return /* @__PURE__ */ import_react.default.createElement(import_ds_grid.Grid, {
|
|
100
|
+
gutter: "xs",
|
|
101
|
+
justifyContent: "center",
|
|
102
|
+
role: "status"
|
|
103
|
+
}, /* @__PURE__ */ import_react.default.createElement(Wrapper, {
|
|
104
|
+
text,
|
|
105
|
+
textAlign: "center",
|
|
106
|
+
startPlacementPreference: tooltipStartPlacementPreference
|
|
107
|
+
}, /* @__PURE__ */ import_react.default.createElement(StyledSvg, {
|
|
108
|
+
viewBox: "-1950 -975 3900 1950",
|
|
109
|
+
fill: "none",
|
|
110
|
+
stroke: "transparent",
|
|
111
|
+
strokeWidth: sizeToWeight[size],
|
|
112
|
+
width: sizeToPx[size],
|
|
113
|
+
height: sizeToPx[size],
|
|
114
|
+
style: { display: "block", margin: "auto" },
|
|
115
|
+
linearGradientUid,
|
|
116
|
+
maskUid,
|
|
117
|
+
duration: __duration
|
|
118
|
+
}, /* @__PURE__ */ import_react.default.createElement("g", {
|
|
119
|
+
transform: "scale(2.298)"
|
|
120
|
+
}, /* @__PURE__ */ import_react.default.createElement("linearGradient", {
|
|
121
|
+
id: linearGradientUid
|
|
122
|
+
}, /* @__PURE__ */ import_react.default.createElement("stop", {
|
|
123
|
+
stopColor: color === "dark" ? "#48a3ff" : "#ccd6ff"
|
|
124
|
+
}), /* @__PURE__ */ import_react.default.createElement("stop", {
|
|
125
|
+
stopColor: color === "dark" ? "#49d0ff" : "#ebf6ff",
|
|
126
|
+
offset: "1"
|
|
127
|
+
})), /* @__PURE__ */ import_react.default.createElement("mask", {
|
|
128
|
+
id: maskUid
|
|
129
|
+
}, /* @__PURE__ */ import_react.default.createElement("circle", {
|
|
130
|
+
r: "1200",
|
|
131
|
+
fill: "#000"
|
|
132
|
+
}), /* @__PURE__ */ import_react.default.createElement("use", {
|
|
133
|
+
xlinkHref: `#${circleUid}`
|
|
134
|
+
})), /* @__PURE__ */ import_react.default.createElement("circle", {
|
|
135
|
+
id: circleUid,
|
|
136
|
+
r: "600"
|
|
137
|
+
}), /* @__PURE__ */ import_react.default.createElement("g", {
|
|
138
|
+
id: "gg"
|
|
139
|
+
}, /* @__PURE__ */ import_react.default.createElement("use", {
|
|
140
|
+
xlinkHref: `#${circleUid}`
|
|
141
|
+
})))), text !== "" && showText && /* @__PURE__ */ import_react.default.createElement("span", {
|
|
142
|
+
style: { color: colorToHex[color], fontSize: sizeToTextSize[size] }
|
|
143
|
+
}, text)));
|
|
144
|
+
};
|
|
145
|
+
DSCircularIndeterminateIndicator.propTypes = import_react_desc_prop_types.CircularIndeterminateIndicatorPropTypes;
|
|
146
|
+
const DSCircularIndeterminateIndicatorWithSchema = (0, import_react_desc.describe)(DSCircularIndeterminateIndicator);
|
|
147
|
+
DSCircularIndeterminateIndicatorWithSchema.propTypes = import_react_desc_prop_types.CircularIndeterminateIndicatorPropTypes;
|
|
148
|
+
module.exports = __toCommonJS(DSCircularIndeterminateIndicator_exports);
|
|
149
|
+
//# sourceMappingURL=DSCircularIndeterminateIndicator.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/v2/DSCircularIndeterminateIndicator.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
+
"sourcesContent": ["import React, { PropsWithChildren, WeakValidationMap } from 'react';\nimport { Grid } from '@elliemae/ds-grid';\nimport { DSTooltipV3 } from '@elliemae/ds-tooltip';\nimport { describe } from 'react-desc';\nimport styled from 'styled-components';\nimport { kfrm } from '@elliemae/ds-system';\nimport { uid } from 'uid';\nimport { DSCircularIndeterminateIndicatorT, CircularIndeterminateIndicatorPropTypes } from './react-desc-prop-types';\n\nconst r = kfrm`to { transform: rotate(2turn) }`;\nconst s = kfrm`0%, 39% { stroke-dasharray: 942px 2826px }`;\n\nconst StyledSvg = styled.svg<{ linearGradientUid: string; maskUid: string; duration: number }>`\n #gg {\n transform: rotate(45deg);\n stroke: url(#${(props) => props.linearGradientUid});\n mask: url(#${(props) => props.maskUid});\n }\n mask use {\n stroke: #fff;\n stroke-linecap: round;\n stroke-dasharray: 942px 2826px;\n animation: ${r} ${(props) => props.duration}s cubic-bezier(0.5, -0.43, 0.5, 1.43) infinite,\n ${s} ${(props) => props.duration / 2}s ease-in-out infinite alternate;\n }\n`;\n\nconst sizeToPx = {\n xs: '16px',\n s: '24px',\n m: '32px',\n l: '48px',\n xl: '56px',\n xxl: '64px',\n};\n\nconst sizeToWeight = {\n xs: '10%',\n s: '9%',\n m: '8%',\n l: '6%',\n xl: '5%',\n xxl: '4%',\n};\n\nconst colorToHex = {\n light: '#FFFFFF',\n dark: '#0F364A',\n};\n\nconst sizeToTextSize = {\n xs: '12px',\n s: '12px',\n m: '12px',\n l: '13px',\n xl: '14px',\n xxl: '16px',\n};\n\nexport const DSCircularIndeterminateIndicator: React.ComponentType<DSCircularIndeterminateIndicatorT.Props> = ({\n size = 'm',\n color = 'dark',\n text = '',\n showText = true,\n withTooltip = false,\n tooltipStartPlacementPreference = 'bottom',\n __duration = 1.5,\n}) => {\n const Wrapper = withTooltip ? DSTooltipV3 : ({ children }: PropsWithChildren<unknown>) => <>{children}</>;\n\n const linearGradientUid = uid(16);\n const maskUid = uid(16);\n const circleUid = uid(16);\n\n return (\n <Grid gutter=\"xs\" justifyContent=\"center\" role=\"status\">\n <Wrapper text={text} textAlign=\"center\" startPlacementPreference={tooltipStartPlacementPreference}>\n <StyledSvg\n viewBox=\"-1950 -975 3900 1950\"\n fill=\"none\"\n stroke=\"transparent\"\n strokeWidth={sizeToWeight[size]}\n width={sizeToPx[size]}\n height={sizeToPx[size]}\n style={{ display: 'block', margin: 'auto' }}\n linearGradientUid={linearGradientUid}\n maskUid={maskUid}\n duration={__duration}\n >\n <g transform=\"scale(2.298)\">\n <linearGradient id={linearGradientUid}>\n <stop stopColor={color === 'dark' ? '#48a3ff' : '#ccd6ff'}></stop>\n <stop stopColor={color === 'dark' ? '#49d0ff' : '#ebf6ff'} offset=\"1\"></stop>\n </linearGradient>\n <mask id={maskUid}>\n <circle r=\"1200\" fill=\"#000\"></circle>\n <use xlinkHref={`#${circleUid}`}></use>\n </mask>\n <circle id={circleUid} r=\"600\"></circle>\n <g id=\"gg\">\n <use xlinkHref={`#${circleUid}`}></use>\n </g>\n </g>\n </StyledSvg>\n {text !== '' && showText && (\n <span style={{ color: colorToHex[color], fontSize: sizeToTextSize[size] }}>{text}</span>\n )}\n </Wrapper>\n </Grid>\n );\n};\n\nDSCircularIndeterminateIndicator.propTypes = CircularIndeterminateIndicatorPropTypes as WeakValidationMap<unknown>;\n\nexport const DSCircularIndeterminateIndicatorWithSchema = describe(DSCircularIndeterminateIndicator);\nDSCircularIndeterminateIndicatorWithSchema.propTypes = CircularIndeterminateIndicatorPropTypes;\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,mBAA4D;AAC5D,qBAAqB;AACrB,wBAA4B;AAC5B,wBAAyB;AACzB,+BAAmB;AACnB,uBAAqB;AACrB,iBAAoB;AACpB,mCAA2F;AAE3F,MAAM,IAAI;AACV,MAAM,IAAI;AAEV,MAAM,YAAY,iCAAO;AAAA;AAAA;AAAA,mBAGN,CAAC,UAAU,MAAM;AAAA,iBACnB,CAAC,UAAU,MAAM;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,iBAMjB,KAAK,CAAC,UAAU,MAAM;AAAA,QAC/B,KAAK,CAAC,UAAU,MAAM,WAAW;AAAA;AAAA;AAIzC,MAAM,WAAW;AAAA,EACf,IAAI;AAAA,EACJ,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,IAAI;AAAA,EACJ,KAAK;AAAA;AAGP,MAAM,eAAe;AAAA,EACnB,IAAI;AAAA,EACJ,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,IAAI;AAAA,EACJ,KAAK;AAAA;AAGP,MAAM,aAAa;AAAA,EACjB,OAAO;AAAA,EACP,MAAM;AAAA;AAGR,MAAM,iBAAiB;AAAA,EACrB,IAAI;AAAA,EACJ,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,IAAI;AAAA,EACJ,KAAK;AAAA;AAGA,MAAM,mCAAiG,CAAC;AAAA,EAC7G,OAAO;AAAA,EACP,QAAQ;AAAA,EACR,OAAO;AAAA,EACP,WAAW;AAAA,EACX,cAAc;AAAA,EACd,kCAAkC;AAAA,EAClC,aAAa;AAAA,MACT;AACJ,QAAM,UAAU,cAAc,gCAAc,CAAC,EAAE,eAA2C,wFAAG;AAE7F,QAAM,oBAAoB,oBAAI;AAC9B,QAAM,UAAU,oBAAI;AACpB,QAAM,YAAY,oBAAI;AAEtB,SACE,mDAAC,qBAAD;AAAA,IAAM,QAAO;AAAA,IAAK,gBAAe;AAAA,IAAS,MAAK;AAAA,KAC7C,mDAAC,SAAD;AAAA,IAAS;AAAA,IAAY,WAAU;AAAA,IAAS,0BAA0B;AAAA,KAChE,mDAAC,WAAD;AAAA,IACE,SAAQ;AAAA,IACR,MAAK;AAAA,IACL,QAAO;AAAA,IACP,aAAa,aAAa;AAAA,IAC1B,OAAO,SAAS;AAAA,IAChB,QAAQ,SAAS;AAAA,IACjB,OAAO,EAAE,SAAS,SAAS,QAAQ;AAAA,IACnC;AAAA,IACA;AAAA,IACA,UAAU;AAAA,KAEV,mDAAC,KAAD;AAAA,IAAG,WAAU;AAAA,KACX,mDAAC,kBAAD;AAAA,IAAgB,IAAI;AAAA,KAClB,mDAAC,QAAD;AAAA,IAAM,WAAW,UAAU,SAAS,YAAY;AAAA,MAChD,mDAAC,QAAD;AAAA,IAAM,WAAW,UAAU,SAAS,YAAY;AAAA,IAAW,QAAO;AAAA,OAEpE,mDAAC,QAAD;AAAA,IAAM,IAAI;AAAA,KACR,mDAAC,UAAD;AAAA,IAAQ,GAAE;AAAA,IAAO,MAAK;AAAA,MACtB,mDAAC,OAAD;AAAA,IAAK,WAAW,IAAI;AAAA,OAEtB,mDAAC,UAAD;AAAA,IAAQ,IAAI;AAAA,IAAW,GAAE;AAAA,MACzB,mDAAC,KAAD;AAAA,IAAG,IAAG;AAAA,KACJ,mDAAC,OAAD;AAAA,IAAK,WAAW,IAAI;AAAA,SAIzB,SAAS,MAAM,YACd,mDAAC,QAAD;AAAA,IAAM,OAAO,EAAE,OAAO,WAAW,QAAQ,UAAU,eAAe;AAAA,KAAU;AAAA;AAOtF,iCAAiC,YAAY;AAEtC,MAAM,6CAA6C,gCAAS;AACnE,2CAA2C,YAAY;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
package/cjs/v2/index.js
ADDED
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
var __create = Object.create;
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
6
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
|
+
var __markAsModule = (target) => __defProp(target, "__esModule", { value: true });
|
|
8
|
+
var __export = (target, all) => {
|
|
9
|
+
for (var name in all)
|
|
10
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
+
};
|
|
12
|
+
var __reExport = (target, module2, copyDefault, desc) => {
|
|
13
|
+
if (module2 && typeof module2 === "object" || typeof module2 === "function") {
|
|
14
|
+
for (let key of __getOwnPropNames(module2))
|
|
15
|
+
if (!__hasOwnProp.call(target, key) && (copyDefault || key !== "default"))
|
|
16
|
+
__defProp(target, key, { get: () => module2[key], enumerable: !(desc = __getOwnPropDesc(module2, key)) || desc.enumerable });
|
|
17
|
+
}
|
|
18
|
+
return target;
|
|
19
|
+
};
|
|
20
|
+
var __toESM = (module2, isNodeMode) => {
|
|
21
|
+
return __reExport(__markAsModule(__defProp(module2 != null ? __create(__getProtoOf(module2)) : {}, "default", !isNodeMode && module2 && module2.__esModule ? { get: () => module2.default, enumerable: true } : { value: module2, enumerable: true })), module2);
|
|
22
|
+
};
|
|
23
|
+
var __toCommonJS = /* @__PURE__ */ ((cache) => {
|
|
24
|
+
return (module2, temp) => {
|
|
25
|
+
return cache && cache.get(module2) || (temp = __reExport(__markAsModule({}), module2, 1), cache && cache.set(module2, temp), temp);
|
|
26
|
+
};
|
|
27
|
+
})(typeof WeakMap !== "undefined" ? /* @__PURE__ */ new WeakMap() : 0);
|
|
28
|
+
var v2_exports = {};
|
|
29
|
+
__export(v2_exports, {
|
|
30
|
+
DSCircularIndeterminateIndicator: () => import_DSCircularIndeterminateIndicator.DSCircularIndeterminateIndicator,
|
|
31
|
+
DSCircularIndeterminateIndicatorWithSchema: () => import_DSCircularIndeterminateIndicator.DSCircularIndeterminateIndicatorWithSchema
|
|
32
|
+
});
|
|
33
|
+
var React = __toESM(require("react"));
|
|
34
|
+
var import_DSCircularIndeterminateIndicator = require("./DSCircularIndeterminateIndicator");
|
|
35
|
+
module.exports = __toCommonJS(v2_exports);
|
|
36
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/v2/index.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
+
"sourcesContent": ["export {\n DSCircularIndeterminateIndicator,\n DSCircularIndeterminateIndicatorWithSchema,\n} from './DSCircularIndeterminateIndicator';\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,8CAGO;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
var __create = Object.create;
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
6
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
|
+
var __markAsModule = (target) => __defProp(target, "__esModule", { value: true });
|
|
8
|
+
var __export = (target, all) => {
|
|
9
|
+
for (var name in all)
|
|
10
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
+
};
|
|
12
|
+
var __reExport = (target, module2, copyDefault, desc) => {
|
|
13
|
+
if (module2 && typeof module2 === "object" || typeof module2 === "function") {
|
|
14
|
+
for (let key of __getOwnPropNames(module2))
|
|
15
|
+
if (!__hasOwnProp.call(target, key) && (copyDefault || key !== "default"))
|
|
16
|
+
__defProp(target, key, { get: () => module2[key], enumerable: !(desc = __getOwnPropDesc(module2, key)) || desc.enumerable });
|
|
17
|
+
}
|
|
18
|
+
return target;
|
|
19
|
+
};
|
|
20
|
+
var __toESM = (module2, isNodeMode) => {
|
|
21
|
+
return __reExport(__markAsModule(__defProp(module2 != null ? __create(__getProtoOf(module2)) : {}, "default", !isNodeMode && module2 && module2.__esModule ? { get: () => module2.default, enumerable: true } : { value: module2, enumerable: true })), module2);
|
|
22
|
+
};
|
|
23
|
+
var __toCommonJS = /* @__PURE__ */ ((cache) => {
|
|
24
|
+
return (module2, temp) => {
|
|
25
|
+
return cache && cache.get(module2) || (temp = __reExport(__markAsModule({}), module2, 1), cache && cache.set(module2, temp), temp);
|
|
26
|
+
};
|
|
27
|
+
})(typeof WeakMap !== "undefined" ? /* @__PURE__ */ new WeakMap() : 0);
|
|
28
|
+
var react_desc_prop_types_exports = {};
|
|
29
|
+
__export(react_desc_prop_types_exports, {
|
|
30
|
+
CircularIndeterminateIndicatorPropTypes: () => CircularIndeterminateIndicatorPropTypes
|
|
31
|
+
});
|
|
32
|
+
var React = __toESM(require("react"));
|
|
33
|
+
var import_react_desc = require("react-desc");
|
|
34
|
+
const CircularIndeterminateIndicatorPropTypes = {
|
|
35
|
+
size: import_react_desc.PropTypes.oneOf(["xs", "s", "m", "l", "xl", "xxl"]).description("Size of the indicator").defaultValue("m"),
|
|
36
|
+
color: import_react_desc.PropTypes.oneOf(["light", "dark"]).description("Color mode for the indicator").defaultValue("dark"),
|
|
37
|
+
text: import_react_desc.PropTypes.string.description("Optional text to show under the indicator").defaultValue(""),
|
|
38
|
+
showText: import_react_desc.PropTypes.bool.description("Whether to show the optional text or not").defaultValue(true),
|
|
39
|
+
withTooltip: import_react_desc.PropTypes.bool.description("Whether to include a tooltip that shows the optional text on hover").defaultValue(false),
|
|
40
|
+
tooltipStartPlacementPreference: import_react_desc.PropTypes.oneOf([
|
|
41
|
+
"top-start",
|
|
42
|
+
"top",
|
|
43
|
+
"top-end",
|
|
44
|
+
"right-start",
|
|
45
|
+
"right",
|
|
46
|
+
"right-end",
|
|
47
|
+
"bottom-end",
|
|
48
|
+
"bottom",
|
|
49
|
+
"bottom-start",
|
|
50
|
+
"left-end",
|
|
51
|
+
"left",
|
|
52
|
+
"left-start"
|
|
53
|
+
]).description("start placement preference for the tooltip").defaultValue("center")
|
|
54
|
+
};
|
|
55
|
+
module.exports = __toCommonJS(react_desc_prop_types_exports);
|
|
56
|
+
//# sourceMappingURL=react-desc-prop-types.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/v2/react-desc-prop-types.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
+
"sourcesContent": ["/* eslint-disable max-lines */\nimport { PropTypes } from 'react-desc';\n\nexport declare namespace DSCircularIndeterminateIndicatorT {\n interface Props {\n size?: 'xs' | 's' | 'm' | 'l' | 'xl' | 'xxl';\n color?: 'light' | 'dark';\n text?: string;\n showText?: boolean;\n withTooltip: boolean;\n tooltipStartPlacementPreference?:\n | 'top-start'\n | 'top'\n | 'top-end'\n | 'right-start'\n | 'right'\n | 'right-end'\n | 'bottom-end'\n | 'bottom'\n | 'bottom-start'\n | 'left-end'\n | 'left'\n | 'left-start';\n __duration: number;\n }\n}\n\nexport const CircularIndeterminateIndicatorPropTypes = {\n size: PropTypes.oneOf(['xs', 's', 'm', 'l', 'xl', 'xxl']).description('Size of the indicator').defaultValue('m'),\n color: PropTypes.oneOf(['light', 'dark']).description('Color mode for the indicator').defaultValue('dark'),\n text: PropTypes.string.description('Optional text to show under the indicator').defaultValue(''),\n showText: PropTypes.bool.description('Whether to show the optional text or not').defaultValue(true),\n withTooltip: PropTypes.bool\n .description('Whether to include a tooltip that shows the optional text on hover')\n .defaultValue(false),\n tooltipStartPlacementPreference: PropTypes.oneOf([\n 'top-start',\n 'top',\n 'top-end',\n 'right-start',\n 'right',\n 'right-end',\n 'bottom-end',\n 'bottom',\n 'bottom-start',\n 'left-end',\n 'left',\n 'left-start',\n ])\n .description('start placement preference for the tooltip')\n .defaultValue('center'),\n};\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADCvB,wBAA0B;AA0BnB,MAAM,0CAA0C;AAAA,EACrD,MAAM,4BAAU,MAAM,CAAC,MAAM,KAAK,KAAK,KAAK,MAAM,QAAQ,YAAY,yBAAyB,aAAa;AAAA,EAC5G,OAAO,4BAAU,MAAM,CAAC,SAAS,SAAS,YAAY,gCAAgC,aAAa;AAAA,EACnG,MAAM,4BAAU,OAAO,YAAY,6CAA6C,aAAa;AAAA,EAC7F,UAAU,4BAAU,KAAK,YAAY,4CAA4C,aAAa;AAAA,EAC9F,aAAa,4BAAU,KACpB,YAAY,sEACZ,aAAa;AAAA,EAChB,iCAAiC,4BAAU,MAAM;AAAA,IAC/C;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,KAEC,YAAY,8CACZ,aAAa;AAAA;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
package/esm/index.js
CHANGED
|
@@ -4,8 +4,11 @@ import {
|
|
|
4
4
|
default as default3,
|
|
5
5
|
CircularProgressIndicatorWithSchema
|
|
6
6
|
} from "./DSCircularProgressIndicator";
|
|
7
|
+
import { DSCircularIndeterminateIndicator, DSCircularIndeterminateIndicatorWithSchema } from "./v2";
|
|
7
8
|
export {
|
|
8
9
|
CircularProgressIndicatorWithSchema,
|
|
10
|
+
DSCircularIndeterminateIndicator,
|
|
11
|
+
DSCircularIndeterminateIndicatorWithSchema,
|
|
9
12
|
default3 as DSCircularProgressIndicator,
|
|
10
13
|
default2 as default
|
|
11
14
|
};
|
package/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", "/* eslint-disable import/named */\nexport {\n default,\n default as DSCircularProgressIndicator,\n CircularProgressIndicatorWithSchema,\n} from './DSCircularProgressIndicator';\n"],
|
|
5
|
-
"mappings": "AAAA;ACCA;AAAA;AAAA;AAAA;AAAA;",
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable import/named */\nexport {\n default,\n default as DSCircularProgressIndicator,\n CircularProgressIndicatorWithSchema,\n} from './DSCircularProgressIndicator';\nexport { DSCircularIndeterminateIndicator, DSCircularIndeterminateIndicatorWithSchema } from './v2';\n"],
|
|
5
|
+
"mappings": "AAAA;ACCA;AAAA;AAAA;AAAA;AAAA;AAKA;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -0,0 +1,120 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import React2 from "react";
|
|
3
|
+
import { Grid } from "@elliemae/ds-grid";
|
|
4
|
+
import { DSTooltipV3 } from "@elliemae/ds-tooltip";
|
|
5
|
+
import { describe } from "react-desc";
|
|
6
|
+
import styled from "styled-components";
|
|
7
|
+
import { kfrm } from "@elliemae/ds-system";
|
|
8
|
+
import { uid } from "uid";
|
|
9
|
+
import { CircularIndeterminateIndicatorPropTypes } from "./react-desc-prop-types";
|
|
10
|
+
const r = kfrm`to { transform: rotate(2turn) }`;
|
|
11
|
+
const s = kfrm`0%, 39% { stroke-dasharray: 942px 2826px }`;
|
|
12
|
+
const StyledSvg = styled.svg`
|
|
13
|
+
#gg {
|
|
14
|
+
transform: rotate(45deg);
|
|
15
|
+
stroke: url(#${(props) => props.linearGradientUid});
|
|
16
|
+
mask: url(#${(props) => props.maskUid});
|
|
17
|
+
}
|
|
18
|
+
mask use {
|
|
19
|
+
stroke: #fff;
|
|
20
|
+
stroke-linecap: round;
|
|
21
|
+
stroke-dasharray: 942px 2826px;
|
|
22
|
+
animation: ${r} ${(props) => props.duration}s cubic-bezier(0.5, -0.43, 0.5, 1.43) infinite,
|
|
23
|
+
${s} ${(props) => props.duration / 2}s ease-in-out infinite alternate;
|
|
24
|
+
}
|
|
25
|
+
`;
|
|
26
|
+
const sizeToPx = {
|
|
27
|
+
xs: "16px",
|
|
28
|
+
s: "24px",
|
|
29
|
+
m: "32px",
|
|
30
|
+
l: "48px",
|
|
31
|
+
xl: "56px",
|
|
32
|
+
xxl: "64px"
|
|
33
|
+
};
|
|
34
|
+
const sizeToWeight = {
|
|
35
|
+
xs: "10%",
|
|
36
|
+
s: "9%",
|
|
37
|
+
m: "8%",
|
|
38
|
+
l: "6%",
|
|
39
|
+
xl: "5%",
|
|
40
|
+
xxl: "4%"
|
|
41
|
+
};
|
|
42
|
+
const colorToHex = {
|
|
43
|
+
light: "#FFFFFF",
|
|
44
|
+
dark: "#0F364A"
|
|
45
|
+
};
|
|
46
|
+
const sizeToTextSize = {
|
|
47
|
+
xs: "12px",
|
|
48
|
+
s: "12px",
|
|
49
|
+
m: "12px",
|
|
50
|
+
l: "13px",
|
|
51
|
+
xl: "14px",
|
|
52
|
+
xxl: "16px"
|
|
53
|
+
};
|
|
54
|
+
const DSCircularIndeterminateIndicator = ({
|
|
55
|
+
size = "m",
|
|
56
|
+
color = "dark",
|
|
57
|
+
text = "",
|
|
58
|
+
showText = true,
|
|
59
|
+
withTooltip = false,
|
|
60
|
+
tooltipStartPlacementPreference = "bottom",
|
|
61
|
+
__duration = 1.5
|
|
62
|
+
}) => {
|
|
63
|
+
const Wrapper = withTooltip ? DSTooltipV3 : ({ children }) => /* @__PURE__ */ React2.createElement(React2.Fragment, null, children);
|
|
64
|
+
const linearGradientUid = uid(16);
|
|
65
|
+
const maskUid = uid(16);
|
|
66
|
+
const circleUid = uid(16);
|
|
67
|
+
return /* @__PURE__ */ React2.createElement(Grid, {
|
|
68
|
+
gutter: "xs",
|
|
69
|
+
justifyContent: "center",
|
|
70
|
+
role: "status"
|
|
71
|
+
}, /* @__PURE__ */ React2.createElement(Wrapper, {
|
|
72
|
+
text,
|
|
73
|
+
textAlign: "center",
|
|
74
|
+
startPlacementPreference: tooltipStartPlacementPreference
|
|
75
|
+
}, /* @__PURE__ */ React2.createElement(StyledSvg, {
|
|
76
|
+
viewBox: "-1950 -975 3900 1950",
|
|
77
|
+
fill: "none",
|
|
78
|
+
stroke: "transparent",
|
|
79
|
+
strokeWidth: sizeToWeight[size],
|
|
80
|
+
width: sizeToPx[size],
|
|
81
|
+
height: sizeToPx[size],
|
|
82
|
+
style: { display: "block", margin: "auto" },
|
|
83
|
+
linearGradientUid,
|
|
84
|
+
maskUid,
|
|
85
|
+
duration: __duration
|
|
86
|
+
}, /* @__PURE__ */ React2.createElement("g", {
|
|
87
|
+
transform: "scale(2.298)"
|
|
88
|
+
}, /* @__PURE__ */ React2.createElement("linearGradient", {
|
|
89
|
+
id: linearGradientUid
|
|
90
|
+
}, /* @__PURE__ */ React2.createElement("stop", {
|
|
91
|
+
stopColor: color === "dark" ? "#48a3ff" : "#ccd6ff"
|
|
92
|
+
}), /* @__PURE__ */ React2.createElement("stop", {
|
|
93
|
+
stopColor: color === "dark" ? "#49d0ff" : "#ebf6ff",
|
|
94
|
+
offset: "1"
|
|
95
|
+
})), /* @__PURE__ */ React2.createElement("mask", {
|
|
96
|
+
id: maskUid
|
|
97
|
+
}, /* @__PURE__ */ React2.createElement("circle", {
|
|
98
|
+
r: "1200",
|
|
99
|
+
fill: "#000"
|
|
100
|
+
}), /* @__PURE__ */ React2.createElement("use", {
|
|
101
|
+
xlinkHref: `#${circleUid}`
|
|
102
|
+
})), /* @__PURE__ */ React2.createElement("circle", {
|
|
103
|
+
id: circleUid,
|
|
104
|
+
r: "600"
|
|
105
|
+
}), /* @__PURE__ */ React2.createElement("g", {
|
|
106
|
+
id: "gg"
|
|
107
|
+
}, /* @__PURE__ */ React2.createElement("use", {
|
|
108
|
+
xlinkHref: `#${circleUid}`
|
|
109
|
+
})))), text !== "" && showText && /* @__PURE__ */ React2.createElement("span", {
|
|
110
|
+
style: { color: colorToHex[color], fontSize: sizeToTextSize[size] }
|
|
111
|
+
}, text)));
|
|
112
|
+
};
|
|
113
|
+
DSCircularIndeterminateIndicator.propTypes = CircularIndeterminateIndicatorPropTypes;
|
|
114
|
+
const DSCircularIndeterminateIndicatorWithSchema = describe(DSCircularIndeterminateIndicator);
|
|
115
|
+
DSCircularIndeterminateIndicatorWithSchema.propTypes = CircularIndeterminateIndicatorPropTypes;
|
|
116
|
+
export {
|
|
117
|
+
DSCircularIndeterminateIndicator,
|
|
118
|
+
DSCircularIndeterminateIndicatorWithSchema
|
|
119
|
+
};
|
|
120
|
+
//# sourceMappingURL=DSCircularIndeterminateIndicator.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../../src/v2/DSCircularIndeterminateIndicator.tsx"],
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import React, { PropsWithChildren, WeakValidationMap } from 'react';\nimport { Grid } from '@elliemae/ds-grid';\nimport { DSTooltipV3 } from '@elliemae/ds-tooltip';\nimport { describe } from 'react-desc';\nimport styled from 'styled-components';\nimport { kfrm } from '@elliemae/ds-system';\nimport { uid } from 'uid';\nimport { DSCircularIndeterminateIndicatorT, CircularIndeterminateIndicatorPropTypes } from './react-desc-prop-types';\n\nconst r = kfrm`to { transform: rotate(2turn) }`;\nconst s = kfrm`0%, 39% { stroke-dasharray: 942px 2826px }`;\n\nconst StyledSvg = styled.svg<{ linearGradientUid: string; maskUid: string; duration: number }>`\n #gg {\n transform: rotate(45deg);\n stroke: url(#${(props) => props.linearGradientUid});\n mask: url(#${(props) => props.maskUid});\n }\n mask use {\n stroke: #fff;\n stroke-linecap: round;\n stroke-dasharray: 942px 2826px;\n animation: ${r} ${(props) => props.duration}s cubic-bezier(0.5, -0.43, 0.5, 1.43) infinite,\n ${s} ${(props) => props.duration / 2}s ease-in-out infinite alternate;\n }\n`;\n\nconst sizeToPx = {\n xs: '16px',\n s: '24px',\n m: '32px',\n l: '48px',\n xl: '56px',\n xxl: '64px',\n};\n\nconst sizeToWeight = {\n xs: '10%',\n s: '9%',\n m: '8%',\n l: '6%',\n xl: '5%',\n xxl: '4%',\n};\n\nconst colorToHex = {\n light: '#FFFFFF',\n dark: '#0F364A',\n};\n\nconst sizeToTextSize = {\n xs: '12px',\n s: '12px',\n m: '12px',\n l: '13px',\n xl: '14px',\n xxl: '16px',\n};\n\nexport const DSCircularIndeterminateIndicator: React.ComponentType<DSCircularIndeterminateIndicatorT.Props> = ({\n size = 'm',\n color = 'dark',\n text = '',\n showText = true,\n withTooltip = false,\n tooltipStartPlacementPreference = 'bottom',\n __duration = 1.5,\n}) => {\n const Wrapper = withTooltip ? DSTooltipV3 : ({ children }: PropsWithChildren<unknown>) => <>{children}</>;\n\n const linearGradientUid = uid(16);\n const maskUid = uid(16);\n const circleUid = uid(16);\n\n return (\n <Grid gutter=\"xs\" justifyContent=\"center\" role=\"status\">\n <Wrapper text={text} textAlign=\"center\" startPlacementPreference={tooltipStartPlacementPreference}>\n <StyledSvg\n viewBox=\"-1950 -975 3900 1950\"\n fill=\"none\"\n stroke=\"transparent\"\n strokeWidth={sizeToWeight[size]}\n width={sizeToPx[size]}\n height={sizeToPx[size]}\n style={{ display: 'block', margin: 'auto' }}\n linearGradientUid={linearGradientUid}\n maskUid={maskUid}\n duration={__duration}\n >\n <g transform=\"scale(2.298)\">\n <linearGradient id={linearGradientUid}>\n <stop stopColor={color === 'dark' ? '#48a3ff' : '#ccd6ff'}></stop>\n <stop stopColor={color === 'dark' ? '#49d0ff' : '#ebf6ff'} offset=\"1\"></stop>\n </linearGradient>\n <mask id={maskUid}>\n <circle r=\"1200\" fill=\"#000\"></circle>\n <use xlinkHref={`#${circleUid}`}></use>\n </mask>\n <circle id={circleUid} r=\"600\"></circle>\n <g id=\"gg\">\n <use xlinkHref={`#${circleUid}`}></use>\n </g>\n </g>\n </StyledSvg>\n {text !== '' && showText && (\n <span style={{ color: colorToHex[color], fontSize: sizeToTextSize[size] }}>{text}</span>\n )}\n </Wrapper>\n </Grid>\n );\n};\n\nDSCircularIndeterminateIndicator.propTypes = CircularIndeterminateIndicatorPropTypes as WeakValidationMap<unknown>;\n\nexport const DSCircularIndeterminateIndicatorWithSchema = describe(DSCircularIndeterminateIndicator);\nDSCircularIndeterminateIndicatorWithSchema.propTypes = CircularIndeterminateIndicatorPropTypes;\n"],
|
|
5
|
+
"mappings": "AAAA;ACAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AAEA,MAAM,IAAI;AACV,MAAM,IAAI;AAEV,MAAM,YAAY,OAAO;AAAA;AAAA;AAAA,mBAGN,CAAC,UAAU,MAAM;AAAA,iBACnB,CAAC,UAAU,MAAM;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,iBAMjB,KAAK,CAAC,UAAU,MAAM;AAAA,QAC/B,KAAK,CAAC,UAAU,MAAM,WAAW;AAAA;AAAA;AAIzC,MAAM,WAAW;AAAA,EACf,IAAI;AAAA,EACJ,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,IAAI;AAAA,EACJ,KAAK;AAAA;AAGP,MAAM,eAAe;AAAA,EACnB,IAAI;AAAA,EACJ,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,IAAI;AAAA,EACJ,KAAK;AAAA;AAGP,MAAM,aAAa;AAAA,EACjB,OAAO;AAAA,EACP,MAAM;AAAA;AAGR,MAAM,iBAAiB;AAAA,EACrB,IAAI;AAAA,EACJ,GAAG;AAAA,EACH,GAAG;AAAA,EACH,GAAG;AAAA,EACH,IAAI;AAAA,EACJ,KAAK;AAAA;AAGA,MAAM,mCAAiG,CAAC;AAAA,EAC7G,OAAO;AAAA,EACP,QAAQ;AAAA,EACR,OAAO;AAAA,EACP,WAAW;AAAA,EACX,cAAc;AAAA,EACd,kCAAkC;AAAA,EAClC,aAAa;AAAA,MACT;AACJ,QAAM,UAAU,cAAc,cAAc,CAAC,EAAE,eAA2C,4DAAG;AAE7F,QAAM,oBAAoB,IAAI;AAC9B,QAAM,UAAU,IAAI;AACpB,QAAM,YAAY,IAAI;AAEtB,SACE,qCAAC,MAAD;AAAA,IAAM,QAAO;AAAA,IAAK,gBAAe;AAAA,IAAS,MAAK;AAAA,KAC7C,qCAAC,SAAD;AAAA,IAAS;AAAA,IAAY,WAAU;AAAA,IAAS,0BAA0B;AAAA,KAChE,qCAAC,WAAD;AAAA,IACE,SAAQ;AAAA,IACR,MAAK;AAAA,IACL,QAAO;AAAA,IACP,aAAa,aAAa;AAAA,IAC1B,OAAO,SAAS;AAAA,IAChB,QAAQ,SAAS;AAAA,IACjB,OAAO,EAAE,SAAS,SAAS,QAAQ;AAAA,IACnC;AAAA,IACA;AAAA,IACA,UAAU;AAAA,KAEV,qCAAC,KAAD;AAAA,IAAG,WAAU;AAAA,KACX,qCAAC,kBAAD;AAAA,IAAgB,IAAI;AAAA,KAClB,qCAAC,QAAD;AAAA,IAAM,WAAW,UAAU,SAAS,YAAY;AAAA,MAChD,qCAAC,QAAD;AAAA,IAAM,WAAW,UAAU,SAAS,YAAY;AAAA,IAAW,QAAO;AAAA,OAEpE,qCAAC,QAAD;AAAA,IAAM,IAAI;AAAA,KACR,qCAAC,UAAD;AAAA,IAAQ,GAAE;AAAA,IAAO,MAAK;AAAA,MACtB,qCAAC,OAAD;AAAA,IAAK,WAAW,IAAI;AAAA,OAEtB,qCAAC,UAAD;AAAA,IAAQ,IAAI;AAAA,IAAW,GAAE;AAAA,MACzB,qCAAC,KAAD;AAAA,IAAG,IAAG;AAAA,KACJ,qCAAC,OAAD;AAAA,IAAK,WAAW,IAAI;AAAA,SAIzB,SAAS,MAAM,YACd,qCAAC,QAAD;AAAA,IAAM,OAAO,EAAE,OAAO,WAAW,QAAQ,UAAU,eAAe;AAAA,KAAU;AAAA;AAOtF,iCAAiC,YAAY;AAEtC,MAAM,6CAA6C,SAAS;AACnE,2CAA2C,YAAY;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
package/esm/v2/index.js
ADDED
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import {
|
|
3
|
+
DSCircularIndeterminateIndicator,
|
|
4
|
+
DSCircularIndeterminateIndicatorWithSchema
|
|
5
|
+
} from "./DSCircularIndeterminateIndicator";
|
|
6
|
+
export {
|
|
7
|
+
DSCircularIndeterminateIndicator,
|
|
8
|
+
DSCircularIndeterminateIndicatorWithSchema
|
|
9
|
+
};
|
|
10
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../../src/v2/index.tsx"],
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "export {\n DSCircularIndeterminateIndicator,\n DSCircularIndeterminateIndicatorWithSchema,\n} from './DSCircularIndeterminateIndicator';\n"],
|
|
5
|
+
"mappings": "AAAA;ACAA;AAAA;AAAA;AAAA;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import { PropTypes } from "react-desc";
|
|
3
|
+
const CircularIndeterminateIndicatorPropTypes = {
|
|
4
|
+
size: PropTypes.oneOf(["xs", "s", "m", "l", "xl", "xxl"]).description("Size of the indicator").defaultValue("m"),
|
|
5
|
+
color: PropTypes.oneOf(["light", "dark"]).description("Color mode for the indicator").defaultValue("dark"),
|
|
6
|
+
text: PropTypes.string.description("Optional text to show under the indicator").defaultValue(""),
|
|
7
|
+
showText: PropTypes.bool.description("Whether to show the optional text or not").defaultValue(true),
|
|
8
|
+
withTooltip: PropTypes.bool.description("Whether to include a tooltip that shows the optional text on hover").defaultValue(false),
|
|
9
|
+
tooltipStartPlacementPreference: PropTypes.oneOf([
|
|
10
|
+
"top-start",
|
|
11
|
+
"top",
|
|
12
|
+
"top-end",
|
|
13
|
+
"right-start",
|
|
14
|
+
"right",
|
|
15
|
+
"right-end",
|
|
16
|
+
"bottom-end",
|
|
17
|
+
"bottom",
|
|
18
|
+
"bottom-start",
|
|
19
|
+
"left-end",
|
|
20
|
+
"left",
|
|
21
|
+
"left-start"
|
|
22
|
+
]).description("start placement preference for the tooltip").defaultValue("center")
|
|
23
|
+
};
|
|
24
|
+
export {
|
|
25
|
+
CircularIndeterminateIndicatorPropTypes
|
|
26
|
+
};
|
|
27
|
+
//# sourceMappingURL=react-desc-prop-types.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../../src/v2/react-desc-prop-types.tsx"],
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable max-lines */\nimport { PropTypes } from 'react-desc';\n\nexport declare namespace DSCircularIndeterminateIndicatorT {\n interface Props {\n size?: 'xs' | 's' | 'm' | 'l' | 'xl' | 'xxl';\n color?: 'light' | 'dark';\n text?: string;\n showText?: boolean;\n withTooltip: boolean;\n tooltipStartPlacementPreference?:\n | 'top-start'\n | 'top'\n | 'top-end'\n | 'right-start'\n | 'right'\n | 'right-end'\n | 'bottom-end'\n | 'bottom'\n | 'bottom-start'\n | 'left-end'\n | 'left'\n | 'left-start';\n __duration: number;\n }\n}\n\nexport const CircularIndeterminateIndicatorPropTypes = {\n size: PropTypes.oneOf(['xs', 's', 'm', 'l', 'xl', 'xxl']).description('Size of the indicator').defaultValue('m'),\n color: PropTypes.oneOf(['light', 'dark']).description('Color mode for the indicator').defaultValue('dark'),\n text: PropTypes.string.description('Optional text to show under the indicator').defaultValue(''),\n showText: PropTypes.bool.description('Whether to show the optional text or not').defaultValue(true),\n withTooltip: PropTypes.bool\n .description('Whether to include a tooltip that shows the optional text on hover')\n .defaultValue(false),\n tooltipStartPlacementPreference: PropTypes.oneOf([\n 'top-start',\n 'top',\n 'top-end',\n 'right-start',\n 'right',\n 'right-end',\n 'bottom-end',\n 'bottom',\n 'bottom-start',\n 'left-end',\n 'left',\n 'left-start',\n ])\n .description('start placement preference for the tooltip')\n .defaultValue('center'),\n};\n"],
|
|
5
|
+
"mappings": "AAAA;ACCA;AA0BO,MAAM,0CAA0C;AAAA,EACrD,MAAM,UAAU,MAAM,CAAC,MAAM,KAAK,KAAK,KAAK,MAAM,QAAQ,YAAY,yBAAyB,aAAa;AAAA,EAC5G,OAAO,UAAU,MAAM,CAAC,SAAS,SAAS,YAAY,gCAAgC,aAAa;AAAA,EACnG,MAAM,UAAU,OAAO,YAAY,6CAA6C,aAAa;AAAA,EAC7F,UAAU,UAAU,KAAK,YAAY,4CAA4C,aAAa;AAAA,EAC9F,aAAa,UAAU,KACpB,YAAY,sEACZ,aAAa;AAAA,EAChB,iCAAiC,UAAU,MAAM;AAAA,IAC/C;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,KAEC,YAAY,8CACZ,aAAa;AAAA;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@elliemae/ds-circular-progress-indicator",
|
|
3
|
-
"version": "2.3.0-alpha.
|
|
3
|
+
"version": "2.3.0-alpha.3",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"description": "ICE MT - Dimsum - Circular progress indicator",
|
|
6
6
|
"module": "./esm/index.js",
|
|
@@ -11,6 +11,18 @@
|
|
|
11
11
|
"import": "./esm/index.js",
|
|
12
12
|
"require": "./cjs/index.js"
|
|
13
13
|
},
|
|
14
|
+
"./v2/react-desc-prop-types": {
|
|
15
|
+
"import": "./esm/v2/react-desc-prop-types.js",
|
|
16
|
+
"require": "./cjs/v2/react-desc-prop-types.js"
|
|
17
|
+
},
|
|
18
|
+
"./v2": {
|
|
19
|
+
"import": "./esm/v2/index.js",
|
|
20
|
+
"require": "./cjs/v2/index.js"
|
|
21
|
+
},
|
|
22
|
+
"./v2/DSCircularIndeterminateIndicator": {
|
|
23
|
+
"import": "./esm/v2/DSCircularIndeterminateIndicator.js",
|
|
24
|
+
"require": "./cjs/v2/DSCircularIndeterminateIndicator.js"
|
|
25
|
+
},
|
|
14
26
|
"./DSCircularProgressIndicator": {
|
|
15
27
|
"import": "./esm/DSCircularProgressIndicator.js",
|
|
16
28
|
"require": "./cjs/DSCircularProgressIndicator.js"
|
|
@@ -36,8 +48,8 @@
|
|
|
36
48
|
"build": "node ../../scripts/build/build.js"
|
|
37
49
|
},
|
|
38
50
|
"dependencies": {
|
|
39
|
-
"@elliemae/ds-classnames": "2.3.0-alpha.
|
|
40
|
-
"@elliemae/ds-tooltip": "2.3.0-alpha.
|
|
51
|
+
"@elliemae/ds-classnames": "2.3.0-alpha.3",
|
|
52
|
+
"@elliemae/ds-tooltip": "2.3.0-alpha.3",
|
|
41
53
|
"react-desc": "~4.1.3"
|
|
42
54
|
},
|
|
43
55
|
"devDependencies": {
|
package/types/index.d.ts
CHANGED
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/// <reference path="../../../../../shared/typings/react-desc.d.ts" />
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import { DSCircularIndeterminateIndicatorT } from './react-desc-prop-types';
|
|
4
|
+
export declare const DSCircularIndeterminateIndicator: React.ComponentType<DSCircularIndeterminateIndicatorT.Props>;
|
|
5
|
+
export declare const DSCircularIndeterminateIndicatorWithSchema: {
|
|
6
|
+
(props?: unknown): JSX.Element;
|
|
7
|
+
propTypes: unknown;
|
|
8
|
+
toTypescript: () => import("react-desc").TypescriptSchema;
|
|
9
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { DSCircularIndeterminateIndicator, DSCircularIndeterminateIndicatorWithSchema, } from './DSCircularIndeterminateIndicator';
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
/// <reference path="../../../../../shared/typings/react-desc.d.ts" />
|
|
2
|
+
export declare namespace DSCircularIndeterminateIndicatorT {
|
|
3
|
+
interface Props {
|
|
4
|
+
size?: 'xs' | 's' | 'm' | 'l' | 'xl' | 'xxl';
|
|
5
|
+
color?: 'light' | 'dark';
|
|
6
|
+
text?: string;
|
|
7
|
+
showText?: boolean;
|
|
8
|
+
withTooltip: boolean;
|
|
9
|
+
tooltipStartPlacementPreference?: 'top-start' | 'top' | 'top-end' | 'right-start' | 'right' | 'right-end' | 'bottom-end' | 'bottom' | 'bottom-start' | 'left-end' | 'left' | 'left-start';
|
|
10
|
+
__duration: number;
|
|
11
|
+
}
|
|
12
|
+
}
|
|
13
|
+
export declare const CircularIndeterminateIndicatorPropTypes: {
|
|
14
|
+
size: {
|
|
15
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
16
|
+
};
|
|
17
|
+
color: {
|
|
18
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
19
|
+
};
|
|
20
|
+
text: {
|
|
21
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
22
|
+
};
|
|
23
|
+
showText: {
|
|
24
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
25
|
+
};
|
|
26
|
+
withTooltip: {
|
|
27
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
28
|
+
};
|
|
29
|
+
tooltipStartPlacementPreference: {
|
|
30
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
31
|
+
};
|
|
32
|
+
};
|