@astrato-io/visualizations 0.8.0 → 0.10.0
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/README.md +9 -5
- package/THIRD_PARTY_NOTICES.md +403 -325
- package/VISUALIZATION_DEFINITIONS.md +319 -32
- package/chunks/{Button-BrGKp9Nm.js → Button-CCF851ea.js} +10 -10
- package/chunks/CircularProgress-yupH6YWs.js +765 -0
- package/chunks/FieldTypeIcon-D_MzsdfY.js +22 -0
- package/chunks/LinearProgress-CyFjN4px.js +327 -0
- package/chunks/{MenuOption-ByRqhRdX.js → MenuOption-CQpT79AP.js} +1391 -1008
- package/chunks/Title-C-p4ZarD.js +1804 -0
- package/chunks/_createAggregator-BF4qG9XK.js +50 -0
- package/chunks/{app-filter-bar.compiler-TwVTeoj5.js → app-filter-bar.compiler-8fxCo2q7.js} +10 -10
- package/chunks/bar-layout-DStC-GNV.js +9 -0
- package/chunks/{bar.compiler-DuQg8EUb.js → bar.compiler-CQAu8KL8.js} +102 -84
- package/chunks/{builder-DEDvNq1k.js → builder-CScg1TOS.js} +156 -60
- package/chunks/color-rules-DYJL4fIW.js +15 -0
- package/chunks/color-settings-DJFoFTip.js +5 -0
- package/chunks/{coloring-CncX_JRX.js → coloring-9jU3s_-p.js} +41 -41
- package/chunks/contains-BK-sRXcB.js +21 -0
- package/chunks/createSimplePaletteValueFilter-C4hZpCdn.js +2005 -0
- package/chunks/defaults-cyNhn37t.js +3 -0
- package/chunks/{definitions-BPJQTx16.js → definitions-C4grxhye.js} +612 -400
- package/chunks/{escobar-DRhRMYRE.js → escobar-CjirINHP.js} +5354 -5473
- package/chunks/{extend-preset-CUFNpmPe.js → extend-preset-D-l9u_we.js} +974 -909
- package/chunks/{filter.compiler-w27dlv0C.js → filter.compiler-lji2Acgn.js} +7 -7
- package/chunks/{filtering-cc7WqWpg.js → filtering-C1zakrrX.js} +570 -390
- package/chunks/handlers-ZviIUC-j.js +15387 -0
- package/chunks/{icon-picker-styles-CoJmwTRi.js → icon-picker-styles-Bj80ZUBK.js} +11 -11
- package/chunks/isEqual-Ch9OEye3.js +16 -0
- package/chunks/isFocusVisible-CgMP0qkR.js +144 -0
- package/chunks/label-format-type-C46pzgx7.js +17 -0
- package/chunks/{line.compiler-Ct1WhN2p.js → line.compiler-De5fiKuR.js} +6 -6
- package/chunks/{logger-DpQtYQnX.js → logger-CKRjhSHQ.js} +77 -66
- package/chunks/map.compiler-CKzorLgK.js +345 -0
- package/chunks/{metadata-WABZrt7Y.js → metadata-Bb9pTXrq.js} +1 -1
- package/chunks/{number.compiler-D8TPly-4.js → number.compiler-CaTmJkmi.js} +4 -4
- package/chunks/operations-DZoY50VX.js +31297 -0
- package/chunks/{range-Bi-7zT0k.js → range-D1BTmFMp.js} +2 -2
- package/chunks/react-dom-Dgv2azN2.js +368 -0
- package/chunks/{render-wrappers-OEmtaM8g.js → render-wrappers-_P3xwu5A.js} +1 -1
- package/chunks/{requirements-Dvd8jqYF.js → requirements-NHNrR8Ie.js} +55 -53
- package/chunks/responsive.styles-FItb913l.js +93 -0
- package/chunks/shared-UitWpq1J.js +1331 -0
- package/chunks/standalone-B0U6c3su.js +3638 -0
- package/chunks/{standalone-we5D5MIn.js → standalone-BBu90BhK.js} +113 -113
- package/chunks/standalone-BEekPuA12.js +357 -0
- package/chunks/{standalone-BMTCb10X.js → standalone-BOzHA_d4.js} +41 -41
- package/chunks/standalone-BR2JuRIC.js +422 -0
- package/chunks/{standalone-BGkmozIb.js → standalone-BapqaniK.js} +619 -619
- package/chunks/standalone-Bnnr87pc.js +2009 -0
- package/chunks/standalone-BwJqDj2Z.js +396 -0
- package/chunks/{standalone-BDhPQtzQ.js → standalone-ByKKqT5L.js} +308 -300
- package/chunks/{standalone-vBnBS2YC.js → standalone-CRdDZYeM.js} +1788 -1004
- package/chunks/standalone-CRfDOO1x.js +287 -0
- package/chunks/{standalone-D5Q5ngsD.js → standalone-CVknVdUC.js} +30 -27
- package/chunks/standalone-CbPk8bKn.js +580 -0
- package/chunks/{standalone-CJvIXsQE.js → standalone-Ck63MZzj.js} +234 -232
- package/chunks/{standalone-CM5XcAN5.js → standalone-DCFY1MAV.js} +8075 -7729
- package/chunks/{standalone-DW6NT205.js → standalone-DZDGX3aa.js} +168 -168
- package/chunks/standalone-DhfgeJIk.js +1012 -0
- package/chunks/{standalone-DT0wKji7.js → standalone-DibjA73M.js} +2 -2
- package/chunks/{standalone-XuGksArp.js → standalone-DtBk_iUz.js} +9 -8
- package/chunks/standalone-DxBAyqAu.js +772 -0
- package/chunks/standalone-KMQPsNsq.js +2 -0
- package/chunks/standalone-MBLSvsrY.js +2 -0
- package/chunks/standalone-U0WJwFlG.js +354 -0
- package/chunks/{standalone-C8ZAEutO.js → standalone-swGs70tD.js} +49 -51
- package/chunks/standalone-wgFAVnnm.js +355 -0
- package/chunks/standalone-xGV0dqPV.js +689 -0
- package/chunks/{table.compiler-DMeeHxb6.js → table.compiler-OWSx5MOq.js} +7 -7
- package/chunks/{typeof-CJDtcySz.js → typeof-DCq3QgvY.js} +6 -1
- package/chunks/useFieldName-B8iCYyw1.js +7 -0
- package/chunks/{utils-vdmi_2PK.js → utils-3Igg6xmO.js} +7668 -12779
- package/chunks/{view-BuwQugKb.js → view-DdMLZySj.js} +2430 -2110
- package/chunks/{visualization-filters-Cc4KU-l-.js → visualization-filters-CzvFHE6M.js} +5205 -4438
- package/chunks/with-html-element-DOfkR3C1.js +16094 -0
- package/definitions.js +2 -2
- package/docs/operations/astrato-app-filter-bar.md +1 -1
- package/docs/operations/bar.md +303 -2
- package/docs/operations/combo.md +262 -1
- package/docs/operations/date-picker.md +1 -1
- package/docs/operations/distribution-gauge.md +1 -1
- package/docs/operations/dot.md +148 -1
- package/docs/operations/filter.md +1 -1
- package/docs/operations/gauge.md +1 -1
- package/docs/operations/heatMap.md +1 -1
- package/docs/operations/histogram.md +262 -1
- package/docs/operations/iframe.md +1 -1
- package/docs/operations/image.md +1 -1
- package/docs/operations/index.md +8 -8
- package/docs/operations/line.md +262 -1
- package/docs/operations/number.md +1 -1
- package/docs/operations/pie.md +1 -1
- package/docs/operations/radar.md +1 -1
- package/docs/operations/sankey.md +1 -1
- package/docs/operations/scatter.md +148 -1
- package/docs/operations/shape.md +1 -1
- package/docs/operations/simpleTextObject.md +1 -1
- package/docs/operations/slider.md +1 -1
- package/docs/operations/table.md +439 -157
- package/docs/operations/tree.md +1 -1
- package/docs/operations/treemap.md +1 -1
- package/docs/operations/waterfall.md +1 -1
- package/docs/operations/word-cloud.md +1 -1
- package/getters.js +2 -2
- package/index.js +523 -469
- package/metadata.js +2 -2
- package/operations.js +5 -5
- package/package.json +74 -68
- package/src/definitions/index.d.ts +1 -1
- package/src/definitions/model/definitions/available-fields.d.ts +2 -2
- package/src/definitions/model/definitions/compilers/compile.d.ts +1 -0
- package/src/definitions/model/definitions/data-item-resolution.d.ts +3 -3
- package/src/definitions/model/definitions/descriptors/descriptor-metadata.d.ts +535 -349
- package/src/definitions/model/definitions/index.d.ts +2 -1
- package/src/definitions/model/definitions/schema-registry.d.ts +406 -101
- package/src/definitions/model/definitions/schemas/bar.schema.d.ts +10 -8
- package/src/definitions/model/definitions/schemas/common.schema.d.ts +33 -32
- package/src/definitions/model/definitions/schemas/index.d.ts +1 -0
- package/src/definitions/model/definitions/schemas/line.schema.d.ts +10 -10
- package/src/definitions/model/definitions/schemas/map.schema.d.ts +590 -0
- package/src/definitions/model/definitions/schemas/number.schema.d.ts +4 -4
- package/src/definitions/model/definitions/schemas/object.schema.d.ts +38 -38
- package/src/definitions/model/definitions/schemas/table.schema.d.ts +61 -61
- package/src/definitions/model/definitions/types/compilation.types.d.ts +7 -2
- package/src/definitions/model/definitions/types/definition.types.d.ts +2 -2
- package/src/definitions/model/definitions/types/index.d.ts +1 -1
- package/src/index.d.ts +1 -1
- package/src/operations/index.d.ts +1 -1
- package/src/types.d.ts +45 -41
- package/src/visualization-catalog.d.ts +26 -26
- package/chunks/DefaultPropsProvider-BsfB7QTn.js +0 -257
- package/chunks/FieldTypeIcon-Drs6hSJF.js +0 -22
- package/chunks/LinearProgress-VtfFx2vJ.js +0 -253
- package/chunks/Title-CO5dP1ma.js +0 -1691
- package/chunks/ToggleButton-KOBAimC1.js +0 -112
- package/chunks/color-rules-CN7TcGrC.js +0 -6
- package/chunks/color-settings-3VRlf_Vw.js +0 -6
- package/chunks/colorManipulator-D8Pjy1pf.js +0 -45
- package/chunks/handlers-TOT-7INo.js +0 -12871
- package/chunks/isEqual-B8loyPsC.js +0 -12
- package/chunks/label-format-type-weq1XfcX.js +0 -8
- package/chunks/operations-Dh4v1Ovt.js +0 -26280
- package/chunks/responsive.styles-DSiOGD7u.js +0 -82
- package/chunks/shared-Bn4N5QcZ.js +0 -1218
- package/chunks/standalone-B55oyW6c.js +0 -689
- package/chunks/standalone-BXKRE_Se.js +0 -468
- package/chunks/standalone-Bes8srx1.js +0 -354
- package/chunks/standalone-BjZp0QMe.js +0 -2
- package/chunks/standalone-BlMIwpEe.js +0 -1877
- package/chunks/standalone-C8qAelL4.js +0 -2
- package/chunks/standalone-CLmGb7nn2.js +0 -355
- package/chunks/standalone-CXNP6-xD.js +0 -420
- package/chunks/standalone-DLlyRIE6.js +0 -287
- package/chunks/standalone-DMcI1afI.js +0 -396
- package/chunks/standalone-DN4S1MjT.js +0 -3874
- package/chunks/standalone-DYQIQH4c.js +0 -2095
- package/chunks/standalone-D__XCp-h.js +0 -1003
- package/chunks/standalone-XTgSsTAa.js +0 -354
- package/chunks/useFieldName-Cjn9KCVp.js +0 -7
- package/chunks/useSlotProps-DLbQp4lc.js +0 -166
- package/chunks/with-html-element-D0uY2zjI.js +0 -7328
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { _r as e, br as t, dr as n, fr as r, gr as i, hr as a, lr as o, mr as s, pr as c, ur as l, vr as u, xr as d, yr as f, zr as p } from "./utils-3Igg6xmO.js";
|
|
2
|
+
import { s as m } from "./logger-CKRjhSHQ.js";
|
|
3
|
+
var h = m(), g = p(), _ = ({ fieldType: p, fill: m, isBucketing: _ }) => {
|
|
4
|
+
if (_) return /* @__PURE__ */ (0, g.jsx)(t, { fill: m });
|
|
5
|
+
switch (p) {
|
|
6
|
+
case h.FieldType.BOOLEAN: return /* @__PURE__ */ (0, g.jsx)(d, { fill: m });
|
|
7
|
+
case h.FieldType.DATE: return /* @__PURE__ */ (0, g.jsx)(f, { fill: m });
|
|
8
|
+
case h.FieldType.DECIMAL: return /* @__PURE__ */ (0, g.jsx)(u, { fill: m });
|
|
9
|
+
case h.FieldType.FLOAT: return /* @__PURE__ */ (0, g.jsx)(e, { fill: m });
|
|
10
|
+
case h.FieldType.GROUPED_DIMENSION: return /* @__PURE__ */ (0, g.jsx)(a, { fill: m });
|
|
11
|
+
case h.FieldType.INT: return /* @__PURE__ */ (0, g.jsx)(s, { fill: m });
|
|
12
|
+
case h.FieldType.JSON: return /* @__PURE__ */ (0, g.jsx)(c, { fill: m });
|
|
13
|
+
case h.FieldType.REAL: return /* @__PURE__ */ (0, g.jsx)(s, { fill: m });
|
|
14
|
+
case h.FieldType.STRING: return /* @__PURE__ */ (0, g.jsx)(r, { fill: m });
|
|
15
|
+
case h.FieldType.TIME: return /* @__PURE__ */ (0, g.jsx)(n, { fill: m });
|
|
16
|
+
case h.FieldType.TIMESTAMP: return /* @__PURE__ */ (0, g.jsx)(l, { fill: m });
|
|
17
|
+
case h.FieldType.TIMESTAMP_TZ: return /* @__PURE__ */ (0, g.jsx)(o, { fill: m });
|
|
18
|
+
case h.FieldType.GEOGRAPHY: return /* @__PURE__ */ (0, g.jsx)(i, { fill: m });
|
|
19
|
+
default: return null;
|
|
20
|
+
}
|
|
21
|
+
};
|
|
22
|
+
export { _ as t };
|
|
@@ -0,0 +1,327 @@
|
|
|
1
|
+
import { o as e } from "./rolldown-runtime-DleVn1XH.js";
|
|
2
|
+
import { $ as t, Dt as n, Et as r, ci as i, it as a, zr as o } from "./utils-3Igg6xmO.js";
|
|
3
|
+
import { _ as s, a as c, c as l, d as u, l as d, m as f, n as p, u as m, v as h } from "./react-dom-Dgv2azN2.js";
|
|
4
|
+
import { p as g } from "./responsive.styles-FItb913l.js";
|
|
5
|
+
var _ = /* @__PURE__ */ e(i(), 1);
|
|
6
|
+
function v(e) {
|
|
7
|
+
return h("MuiLinearProgress", e);
|
|
8
|
+
}
|
|
9
|
+
var y = s("MuiLinearProgress", [
|
|
10
|
+
"root",
|
|
11
|
+
"colorPrimary",
|
|
12
|
+
"colorSecondary",
|
|
13
|
+
"determinate",
|
|
14
|
+
"indeterminate",
|
|
15
|
+
"buffer",
|
|
16
|
+
"query",
|
|
17
|
+
"dashed",
|
|
18
|
+
"bar",
|
|
19
|
+
"bar1",
|
|
20
|
+
"bar2"
|
|
21
|
+
]), b = o(), x = 4, S = {}, C = n`
|
|
22
|
+
0% {
|
|
23
|
+
left: -35%;
|
|
24
|
+
right: 100%;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
60% {
|
|
28
|
+
left: 100%;
|
|
29
|
+
right: -90%;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
100% {
|
|
33
|
+
left: 100%;
|
|
34
|
+
right: -90%;
|
|
35
|
+
}
|
|
36
|
+
`, w = typeof C == "string" ? null : r`
|
|
37
|
+
animation: ${C} 2.1s cubic-bezier(0.65, 0.815, 0.735, 0.395) infinite;
|
|
38
|
+
`, T = n`
|
|
39
|
+
0% {
|
|
40
|
+
left: -200%;
|
|
41
|
+
right: 100%;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
60% {
|
|
45
|
+
left: 107%;
|
|
46
|
+
right: -8%;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
100% {
|
|
50
|
+
left: 107%;
|
|
51
|
+
right: -8%;
|
|
52
|
+
}
|
|
53
|
+
`, E = typeof T == "string" ? null : r`
|
|
54
|
+
animation: ${T} 2.1s cubic-bezier(0.165, 0.84, 0.44, 1) 1.15s infinite;
|
|
55
|
+
`, D = n`
|
|
56
|
+
0% {
|
|
57
|
+
opacity: 1;
|
|
58
|
+
background-position: 0 -23px;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
60% {
|
|
62
|
+
opacity: 0;
|
|
63
|
+
background-position: 0 -23px;
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
100% {
|
|
67
|
+
opacity: 1;
|
|
68
|
+
background-position: -200px -23px;
|
|
69
|
+
}
|
|
70
|
+
`, O = typeof D == "string" ? null : r`
|
|
71
|
+
animation: ${D} 3s infinite linear;
|
|
72
|
+
`, k = (e) => {
|
|
73
|
+
let { classes: t, variant: n, color: r } = e;
|
|
74
|
+
return f({
|
|
75
|
+
root: [
|
|
76
|
+
"root",
|
|
77
|
+
`color${l(r)}`,
|
|
78
|
+
n
|
|
79
|
+
],
|
|
80
|
+
dashed: ["dashed"],
|
|
81
|
+
bar1: ["bar", "bar1"],
|
|
82
|
+
bar2: [
|
|
83
|
+
"bar",
|
|
84
|
+
"bar2",
|
|
85
|
+
n === "buffer" && `color${l(r)}`
|
|
86
|
+
]
|
|
87
|
+
}, v, t);
|
|
88
|
+
}, A = (e, t) => e.vars ? e.vars.palette.LinearProgress[`${t}Bg`] : e.palette.mode === "light" ? e.lighten(e.palette[t].main, .62) : e.darken(e.palette[t].main, .5), j = u("span", {
|
|
89
|
+
name: "MuiLinearProgress",
|
|
90
|
+
slot: "Root",
|
|
91
|
+
overridesResolver: (e, t) => {
|
|
92
|
+
let { ownerState: n } = e;
|
|
93
|
+
return [
|
|
94
|
+
t.root,
|
|
95
|
+
t[`color${l(n.color)}`],
|
|
96
|
+
t[n.variant]
|
|
97
|
+
];
|
|
98
|
+
}
|
|
99
|
+
})(m(({ theme: e }) => ({
|
|
100
|
+
position: "relative",
|
|
101
|
+
overflow: "hidden",
|
|
102
|
+
display: "block",
|
|
103
|
+
height: 4,
|
|
104
|
+
zIndex: 0,
|
|
105
|
+
"@media print": { colorAdjust: "exact" },
|
|
106
|
+
variants: [
|
|
107
|
+
...Object.entries(e.palette).filter(g()).map(([t]) => ({
|
|
108
|
+
props: { color: t },
|
|
109
|
+
style: { backgroundColor: A(e, t) }
|
|
110
|
+
})),
|
|
111
|
+
{
|
|
112
|
+
props: ({ ownerState: e }) => e.color === "inherit" && e.variant !== "buffer",
|
|
113
|
+
style: { "&::before": {
|
|
114
|
+
content: "\"\"",
|
|
115
|
+
position: "absolute",
|
|
116
|
+
left: 0,
|
|
117
|
+
top: 0,
|
|
118
|
+
right: 0,
|
|
119
|
+
bottom: 0,
|
|
120
|
+
backgroundColor: "currentColor",
|
|
121
|
+
opacity: .3
|
|
122
|
+
} }
|
|
123
|
+
},
|
|
124
|
+
{
|
|
125
|
+
props: { variant: "buffer" },
|
|
126
|
+
style: { backgroundColor: "transparent" }
|
|
127
|
+
},
|
|
128
|
+
{
|
|
129
|
+
props: { variant: "query" },
|
|
130
|
+
style: { transform: "rotate(180deg)" }
|
|
131
|
+
}
|
|
132
|
+
]
|
|
133
|
+
}))), M = u("span", {
|
|
134
|
+
name: "MuiLinearProgress",
|
|
135
|
+
slot: "Dashed"
|
|
136
|
+
})(m(({ theme: e }) => ({
|
|
137
|
+
position: "absolute",
|
|
138
|
+
marginTop: 0,
|
|
139
|
+
height: "100%",
|
|
140
|
+
width: "100%",
|
|
141
|
+
backgroundSize: "10px 10px",
|
|
142
|
+
backgroundPosition: "0 -23px",
|
|
143
|
+
variants: [{
|
|
144
|
+
props: { color: "inherit" },
|
|
145
|
+
style: {
|
|
146
|
+
opacity: .3,
|
|
147
|
+
backgroundImage: "radial-gradient(currentColor 0%, currentColor 16%, transparent 42%)"
|
|
148
|
+
}
|
|
149
|
+
}, ...Object.entries(e.palette).filter(g()).map(([t]) => {
|
|
150
|
+
let n = A(e, t);
|
|
151
|
+
return {
|
|
152
|
+
props: { color: t },
|
|
153
|
+
style: { backgroundImage: `radial-gradient(${n} 0%, ${n} 16%, transparent 42%)` }
|
|
154
|
+
};
|
|
155
|
+
})]
|
|
156
|
+
})), O || { animation: `${D} 3s infinite linear` }, m(({ theme: e }) => p(e, { animation: "none" }) || S)), N = u("span", {
|
|
157
|
+
name: "MuiLinearProgress",
|
|
158
|
+
slot: "Bar1",
|
|
159
|
+
overridesResolver: (e, t) => [t.bar, t.bar1]
|
|
160
|
+
})(m(({ theme: e }) => {
|
|
161
|
+
let t = p(e, {
|
|
162
|
+
animation: "none",
|
|
163
|
+
left: "30%",
|
|
164
|
+
right: "auto",
|
|
165
|
+
width: "40%"
|
|
166
|
+
});
|
|
167
|
+
return {
|
|
168
|
+
width: "100%",
|
|
169
|
+
position: "absolute",
|
|
170
|
+
left: 0,
|
|
171
|
+
bottom: 0,
|
|
172
|
+
top: 0,
|
|
173
|
+
...c(e, "transform", {
|
|
174
|
+
duration: "0.2s",
|
|
175
|
+
easing: "linear"
|
|
176
|
+
}),
|
|
177
|
+
transformOrigin: "left",
|
|
178
|
+
variants: [
|
|
179
|
+
{
|
|
180
|
+
props: { color: "inherit" },
|
|
181
|
+
style: { backgroundColor: "currentColor" }
|
|
182
|
+
},
|
|
183
|
+
...Object.entries(e.palette).filter(g()).map(([t]) => ({
|
|
184
|
+
props: { color: t },
|
|
185
|
+
style: { backgroundColor: (e.vars || e).palette[t].main }
|
|
186
|
+
})),
|
|
187
|
+
{
|
|
188
|
+
props: { variant: "determinate" },
|
|
189
|
+
style: { ...c(e, "transform", {
|
|
190
|
+
duration: `.${x}s`,
|
|
191
|
+
easing: "linear"
|
|
192
|
+
}) }
|
|
193
|
+
},
|
|
194
|
+
{
|
|
195
|
+
props: { variant: "buffer" },
|
|
196
|
+
style: {
|
|
197
|
+
zIndex: 1,
|
|
198
|
+
...c(e, "transform", {
|
|
199
|
+
duration: `.${x}s`,
|
|
200
|
+
easing: "linear"
|
|
201
|
+
})
|
|
202
|
+
}
|
|
203
|
+
},
|
|
204
|
+
{
|
|
205
|
+
props: ({ ownerState: e }) => e.variant === "indeterminate" || e.variant === "query",
|
|
206
|
+
style: { width: "auto" }
|
|
207
|
+
},
|
|
208
|
+
{
|
|
209
|
+
props: ({ ownerState: e }) => e.variant === "indeterminate" || e.variant === "query",
|
|
210
|
+
style: w || { animation: `${C} 2.1s cubic-bezier(0.65, 0.815, 0.735, 0.395) infinite` }
|
|
211
|
+
},
|
|
212
|
+
...t ? [{
|
|
213
|
+
props: ({ ownerState: e }) => e.variant === "indeterminate" || e.variant === "query",
|
|
214
|
+
style: t
|
|
215
|
+
}] : []
|
|
216
|
+
]
|
|
217
|
+
};
|
|
218
|
+
})), P = u("span", {
|
|
219
|
+
name: "MuiLinearProgress",
|
|
220
|
+
slot: "Bar2",
|
|
221
|
+
overridesResolver: (e, t) => [t.bar, t.bar2]
|
|
222
|
+
})(m(({ theme: e }) => {
|
|
223
|
+
let t = p(e, {
|
|
224
|
+
animation: "none",
|
|
225
|
+
display: "none"
|
|
226
|
+
});
|
|
227
|
+
return {
|
|
228
|
+
width: "100%",
|
|
229
|
+
position: "absolute",
|
|
230
|
+
left: 0,
|
|
231
|
+
bottom: 0,
|
|
232
|
+
top: 0,
|
|
233
|
+
...c(e, "transform", {
|
|
234
|
+
duration: "0.2s",
|
|
235
|
+
easing: "linear"
|
|
236
|
+
}),
|
|
237
|
+
transformOrigin: "left",
|
|
238
|
+
variants: [
|
|
239
|
+
...Object.entries(e.palette).filter(g()).map(([t]) => ({
|
|
240
|
+
props: { color: t },
|
|
241
|
+
style: { "--LinearProgressBar2-barColor": (e.vars || e).palette[t].main }
|
|
242
|
+
})),
|
|
243
|
+
{
|
|
244
|
+
props: ({ ownerState: e }) => e.variant !== "buffer" && e.color !== "inherit",
|
|
245
|
+
style: { backgroundColor: "var(--LinearProgressBar2-barColor, currentColor)" }
|
|
246
|
+
},
|
|
247
|
+
{
|
|
248
|
+
props: ({ ownerState: e }) => e.variant !== "buffer" && e.color === "inherit",
|
|
249
|
+
style: { backgroundColor: "currentColor" }
|
|
250
|
+
},
|
|
251
|
+
{
|
|
252
|
+
props: { color: "inherit" },
|
|
253
|
+
style: { opacity: .3 }
|
|
254
|
+
},
|
|
255
|
+
...Object.entries(e.palette).filter(g()).map(([t]) => ({
|
|
256
|
+
props: {
|
|
257
|
+
color: t,
|
|
258
|
+
variant: "buffer"
|
|
259
|
+
},
|
|
260
|
+
style: {
|
|
261
|
+
backgroundColor: A(e, t),
|
|
262
|
+
...c(e, "transform", {
|
|
263
|
+
duration: `.${x}s`,
|
|
264
|
+
easing: "linear"
|
|
265
|
+
})
|
|
266
|
+
}
|
|
267
|
+
})),
|
|
268
|
+
{
|
|
269
|
+
props: ({ ownerState: e }) => e.variant === "indeterminate" || e.variant === "query",
|
|
270
|
+
style: { width: "auto" }
|
|
271
|
+
},
|
|
272
|
+
{
|
|
273
|
+
props: ({ ownerState: e }) => e.variant === "indeterminate" || e.variant === "query",
|
|
274
|
+
style: E || { animation: `${T} 2.1s cubic-bezier(0.165, 0.84, 0.44, 1) 1.15s infinite` }
|
|
275
|
+
},
|
|
276
|
+
...t ? [{
|
|
277
|
+
props: ({ ownerState: e }) => e.variant === "indeterminate" || e.variant === "query",
|
|
278
|
+
style: t
|
|
279
|
+
}] : []
|
|
280
|
+
]
|
|
281
|
+
};
|
|
282
|
+
})), F = /*#__PURE__*/ _.forwardRef(function(e, n) {
|
|
283
|
+
let r = d({
|
|
284
|
+
props: e,
|
|
285
|
+
name: "MuiLinearProgress"
|
|
286
|
+
}), { className: i, color: o = "primary", max: s, min: c, value: l, valueBuffer: u, variant: f = "indeterminate", ...p } = r, m = {
|
|
287
|
+
...r,
|
|
288
|
+
color: o,
|
|
289
|
+
variant: f
|
|
290
|
+
}, h = c ?? 0, g = s ?? 100, _ = k(m), v = t(), y = {}, x = {
|
|
291
|
+
bar1: {},
|
|
292
|
+
bar2: {}
|
|
293
|
+
};
|
|
294
|
+
if ((f === "determinate" || f === "buffer") && l !== void 0) {
|
|
295
|
+
let e = g - h, t = (l - h) / e * 100 - 100;
|
|
296
|
+
v && (t = -t), x.bar1.transform = e > 0 ? `translateX(${t}%)` : "translateX(-100%)", y["aria-valuenow"] = l, y["aria-valuemin"] = h, y["aria-valuemax"] = g;
|
|
297
|
+
}
|
|
298
|
+
if (f === "buffer" && u !== void 0) {
|
|
299
|
+
let e = g - h, t = (u - h) / e * 100 - 100;
|
|
300
|
+
v && (t = -t), x.bar2.transform = e > 0 ? `translateX(${t}%)` : "translateX(-100%)";
|
|
301
|
+
}
|
|
302
|
+
return /*#__PURE__*/ (0, b.jsxs)(j, {
|
|
303
|
+
className: a(_.root, i),
|
|
304
|
+
ownerState: m,
|
|
305
|
+
role: "progressbar",
|
|
306
|
+
...y,
|
|
307
|
+
ref: n,
|
|
308
|
+
...p,
|
|
309
|
+
children: [
|
|
310
|
+
f === "buffer" ? /*#__PURE__*/ (0, b.jsx)(M, {
|
|
311
|
+
className: _.dashed,
|
|
312
|
+
ownerState: m
|
|
313
|
+
}) : null,
|
|
314
|
+
/*#__PURE__*/ (0, b.jsx)(N, {
|
|
315
|
+
className: _.bar1,
|
|
316
|
+
ownerState: m,
|
|
317
|
+
style: x.bar1
|
|
318
|
+
}),
|
|
319
|
+
f === "determinate" ? null : /*#__PURE__*/ (0, b.jsx)(P, {
|
|
320
|
+
className: _.bar2,
|
|
321
|
+
ownerState: m,
|
|
322
|
+
style: x.bar2
|
|
323
|
+
})
|
|
324
|
+
]
|
|
325
|
+
});
|
|
326
|
+
});
|
|
327
|
+
export { y as n, F as t };
|