dynamic-mui 2.2.0 → 2.3.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.
Files changed (166) hide show
  1. package/README.md +142 -5
  2. package/dist/accordion-DqBdGRim.mjs +23 -0
  3. package/dist/accordion-lvbD_BpX.js +1 -0
  4. package/dist/addressfield-CGX3UppE.mjs +152 -0
  5. package/dist/addressfield-DDG15fqJ.js +1 -0
  6. package/dist/asyncautocomplete-BAfBR9P7.mjs +89 -0
  7. package/dist/asyncautocomplete-w9q_1DWt.js +1 -0
  8. package/dist/bar-BzO7tvYJ.mjs +20 -0
  9. package/dist/bar-DEVxyUVS.js +1 -0
  10. package/dist/cascadeselect-C3QVfoig.mjs +64 -0
  11. package/dist/cascadeselect-DzbhK9en.js +1 -0
  12. package/dist/colorpicker-5qmEq7ZI.js +1 -0
  13. package/dist/colorpicker-DhNZulJY.mjs +98 -0
  14. package/dist/components/DynamicComponent.d.ts +2 -0
  15. package/dist/components/FormGenerator.d.ts +99 -10
  16. package/dist/components/controls/index.d.ts +45 -79
  17. package/dist/consentfield-B7Rm8d3U.js +1 -0
  18. package/dist/consentfield-CBQUR4J5.mjs +78 -0
  19. package/dist/datatable-BIQznwQe.mjs +20 -0
  20. package/dist/datatable-BWlcUP0M.js +1 -0
  21. package/dist/dynamic-mui.cjs +1 -0
  22. package/dist/dynamic-mui.mjs +32 -0
  23. package/dist/editabletable-DCoRmsEO.js +1 -0
  24. package/dist/editabletable-DRlBV8lk.mjs +126 -0
  25. package/dist/fileupload-ByBv1UjT.mjs +172 -0
  26. package/dist/fileupload-Cze3Oc_2.js +1 -0
  27. package/dist/formrepeater-BBkKGLFJ.mjs +71 -0
  28. package/dist/formrepeater-BxJzXoHx.js +1 -0
  29. package/dist/formwizard-BDZE1UDD.js +1 -0
  30. package/dist/formwizard-D2u1bMvK.mjs +83 -0
  31. package/dist/geofield-8WTeZk0Z.mjs +104 -0
  32. package/dist/geofield-Bw3p4NLJ.js +1 -0
  33. package/dist/group-B2mSylHd.mjs +23 -0
  34. package/dist/group-BlfO3ZZf.js +1 -0
  35. package/dist/imagelist-Bn9QhIv7.js +1 -0
  36. package/dist/imagelist-rqmJajHt.mjs +18 -0
  37. package/dist/index-CddjLTWF.mjs +12499 -0
  38. package/dist/index-D08GIfqF.js +43 -0
  39. package/dist/index.d.ts +9 -1
  40. package/dist/intlphone-B_Xn98pU.js +1 -0
  41. package/dist/intlphone-DtQZ12xk.mjs +140 -0
  42. package/dist/keyvaluefield-B_1NeGuP.mjs +125 -0
  43. package/dist/keyvaluefield-DyKCGd32.js +1 -0
  44. package/dist/line-B-DwR1hm.mjs +20 -0
  45. package/dist/line-BkymZu31.js +1 -0
  46. package/dist/lineitemlist-DGo8UOZC.js +1 -0
  47. package/dist/lineitemlist-vGKzJlQx.mjs +166 -0
  48. package/dist/list-7uNWrepS.mjs +20 -0
  49. package/dist/list-C0FgmtQw.js +1 -0
  50. package/dist/locationfield-CeUgxLkQ.mjs +119 -0
  51. package/dist/locationfield-Duyw1ZEz.js +1 -0
  52. package/dist/markdowneditor-B1y-hfny.mjs +90 -0
  53. package/dist/markdowneditor-Db0Un1_Z.js +2 -0
  54. package/dist/matrixfield-C7Sc-YpI.mjs +117 -0
  55. package/dist/matrixfield-CckODuPn.js +1 -0
  56. package/dist/mixChart-C3o184UT.js +1 -0
  57. package/dist/mixChart-ISf3Kbr-.mjs +75 -0
  58. package/dist/multitextbox-BYazIAeG.js +1 -0
  59. package/dist/multitextbox-ide2lvJ6.mjs +78 -0
  60. package/dist/npsscale-C2e88qk_.js +1 -0
  61. package/dist/npsscale-lndz7GEq.mjs +87 -0
  62. package/dist/numberstepper-DitbcvV9.mjs +128 -0
  63. package/dist/numberstepper-DyRjQM_K.js +1 -0
  64. package/dist/pie-CJSL8Sv5.js +1 -0
  65. package/dist/pie-CL29dlh5.mjs +20 -0
  66. package/dist/richtexteditor-CVg-MnKp.js +1 -0
  67. package/dist/richtexteditor-DsC1XC7h.mjs +141 -0
  68. package/dist/s3Upload-B0JeoLkS.js +1 -0
  69. package/dist/s3Upload-dpioZ2c8.mjs +51 -0
  70. package/dist/signature-14OrZriO.mjs +1225 -0
  71. package/dist/signature-D582X6tB.js +2 -0
  72. package/dist/stepper-B-FpcZvT.js +1 -0
  73. package/dist/stepper-CDfEy_C6.mjs +140 -0
  74. package/dist/summaryfield-B08ZmVHh.js +1 -0
  75. package/dist/summaryfield-CTpPlZBG.mjs +96 -0
  76. package/dist/tabs-BIliqFOs.js +1 -0
  77. package/dist/tabs-DDeJCFt8.mjs +39 -0
  78. package/dist/tagsinput-D-q6rRZS.mjs +58 -0
  79. package/dist/tagsinput-qh_lhdFb.js +1 -0
  80. package/dist/util/registry.d.ts +29 -0
  81. package/dist/util/resolvers.d.ts +45 -0
  82. package/dist/util/useFormEngine.d.ts +74 -0
  83. package/dist/util/validateSchema.d.ts +23 -0
  84. package/dist/v4-BysszJq8.mjs +30 -0
  85. package/dist/v4-CqdK_b8Y.js +1 -0
  86. package/package.json +36 -11
  87. package/dist/AxisSharedComponents-BbsKw1BT.js +0 -3
  88. package/dist/AxisSharedComponents-xLtpOLH_.mjs +0 -605
  89. package/dist/ChartsAxis-CANvBdY9.mjs +0 -47
  90. package/dist/ChartsAxis-EZ7m_KrU.js +0 -1
  91. package/dist/ChartsGrid-BCRTvNTr.js +0 -3
  92. package/dist/ChartsGrid-C_HT7qpL.mjs +0 -381
  93. package/dist/ChartsWrapper-CM7EDyAK.js +0 -5
  94. package/dist/ChartsWrapper-CO5_Z6BD.mjs +0 -1878
  95. package/dist/ChartsXAxis-CPmuCRhq.mjs +0 -487
  96. package/dist/ChartsXAxis-DFFY1sPg.js +0 -3
  97. package/dist/ChartsYAxis-DLUMr9vG.mjs +0 -392
  98. package/dist/ChartsYAxis-fpevi1sP.js +0 -1
  99. package/dist/XmlShapeDeserializer-3yQdm0b0.mjs +0 -237
  100. package/dist/XmlShapeDeserializer-XKJAoqLc.js +0 -1
  101. package/dist/clampAngle-BvZjnf53.mjs +0 -11
  102. package/dist/clampAngle-DpAsDoeT.js +0 -1
  103. package/dist/createSelector-B-9FwV16.mjs +0 -430
  104. package/dist/createSelector-f0oqn8Lr.js +0 -7
  105. package/dist/date-utils-CFUUt6NL.js +0 -4
  106. package/dist/date-utils-pGzaKb0p.mjs +0 -477
  107. package/dist/dynamic-mui.cjs.js +0 -1
  108. package/dist/dynamic-mui.es.js +0 -22
  109. package/dist/index--8Zky9Oh.js +0 -299
  110. package/dist/index-6WTs1Xy_.js +0 -1
  111. package/dist/index-B1R1akM2.js +0 -1
  112. package/dist/index-BW8_rRff.js +0 -7
  113. package/dist/index-BXFVK_GX.js +0 -1
  114. package/dist/index-B_KNUTjy.js +0 -1
  115. package/dist/index-BhaKvHkU.mjs +0 -62051
  116. package/dist/index-Bif92ima.js +0 -1
  117. package/dist/index-BnZOu8CL.js +0 -1
  118. package/dist/index-CDxpgRlR.mjs +0 -7
  119. package/dist/index-CThMfvtJ.mjs +0 -2555
  120. package/dist/index-CVqLvm8B.js +0 -1
  121. package/dist/index-CodJBIn6.mjs +0 -1665
  122. package/dist/index-Cr6Wp_S-.mjs +0 -3141
  123. package/dist/index-CslPwsrf.mjs +0 -4
  124. package/dist/index-CuV0MQzZ.mjs +0 -1173
  125. package/dist/index-DA0XouZs.mjs +0 -153
  126. package/dist/index-DKS5Sz9e.js +0 -14
  127. package/dist/index-DSkYYZuW.mjs +0 -4
  128. package/dist/index-DU78_FiA.js +0 -1
  129. package/dist/index-D_mYhgJ0.js +0 -10
  130. package/dist/index-DcWfyXJp.mjs +0 -92
  131. package/dist/index-Dlimbnxj.mjs +0 -2965
  132. package/dist/index-MllWgTJ5.mjs +0 -9372
  133. package/dist/index-in5z9hUb.js +0 -133
  134. package/dist/index-qUW7FnZ-.mjs +0 -20540
  135. package/dist/index.browser-BSu11T_q.mjs +0 -363
  136. package/dist/index.browser-By7-GABP.js +0 -4
  137. package/dist/isDeepEqual-BHfPvf9U.mjs +0 -393
  138. package/dist/isDeepEqual-CqxZGVRk.js +0 -1
  139. package/dist/loadCognitoIdentity-DtYTy-DW.js +0 -1
  140. package/dist/loadCognitoIdentity-DzdR91GB.mjs +0 -872
  141. package/dist/loadSts-Cic6UToN.mjs +0 -593
  142. package/dist/loadSts-csbFP6zX.js +0 -1
  143. package/dist/main.d.ts +0 -1
  144. package/dist/noAuth-B8ui2kBg.mjs +0 -71
  145. package/dist/noAuth-JPA2o4dt.js +0 -1
  146. package/dist/playground/AIContext.d.ts +0 -18
  147. package/dist/playground/AIPanel.d.ts +0 -10
  148. package/dist/playground/Builder.d.ts +0 -1
  149. package/dist/playground/Canvas.d.ts +0 -9
  150. package/dist/playground/DemoGallery.d.ts +0 -6
  151. package/dist/playground/PropertiesEditor.d.ts +0 -10
  152. package/dist/playground/Sidebar.d.ts +0 -9
  153. package/dist/playground/demoForms.d.ts +0 -3
  154. package/dist/playground/demoRecipes.d.ts +0 -15
  155. package/dist/playground/demoVariants.d.ts +0 -11
  156. package/dist/playground/documentation.d.ts +0 -6
  157. package/dist/playground/templates.d.ts +0 -7
  158. package/dist/playground/testData.d.ts +0 -2
  159. package/dist/test/setup.d.ts +0 -0
  160. package/dist/theme/theme.d.ts +0 -6
  161. package/dist/useAxis-DSbfEtO7.js +0 -3
  162. package/dist/useAxis-SiNBMMWq.mjs +0 -3010
  163. package/dist/useChartContainerProps-Bl3hO-r1.mjs +0 -5418
  164. package/dist/useChartContainerProps-C_C_PZoi.js +0 -12
  165. package/dist/useItemHighlightedGetter-9CIwqsGj.js +0 -1
  166. package/dist/useItemHighlightedGetter-CTISrNdV.mjs +0 -88
@@ -1,392 +0,0 @@
1
- import { c as ae, a as R, u as D, _ as r, b as U, d as $, e as F, j as d, s as ce, w as le, P as e } from "./index-BhaKvHkU.mjs";
2
- import * as V from "react";
3
- import { e as re, d as de, b as X, g as xe, C as W, c as ue, f as fe, i as pe, u as K, h as ke, j as be, k as me, A as he } from "./AxisSharedComponents-xLtpOLH_.mjs";
4
- import { a as q, c as J, d as Q, i as Z } from "./useAxis-SiNBMMWq.mjs";
5
- import { c as Te } from "./clampAngle-BvZjnf53.mjs";
6
- function ye(s, t, a, i, c) {
7
- const f = /* @__PURE__ */ new Map(), p = Te(c?.angle ?? 0);
8
- let l = 1, o = 1;
9
- c?.textAnchor === "start" ? (l = 1 / 0, o = 1) : c?.textAnchor === "end" ? (l = 1, o = 1 / 0) : (l = 2, o = 2), p > 180 && ([l, o] = [o, l]), i && ([l, o] = [o, l]);
10
- for (const n of s)
11
- if (n.formattedValue) {
12
- const x = Math.min((n.offset + n.labelOffset) * l, (t.top + t.height + t.bottom - n.offset - n.labelOffset) * o), u = (b) => de(b, {
13
- width: a,
14
- height: x,
15
- angle: p,
16
- measureText: (m) => X(m, c)
17
- });
18
- f.set(n, re(n.formattedValue.toString(), u));
19
- }
20
- return f;
21
- }
22
- const ee = (s) => {
23
- const {
24
- classes: t,
25
- position: a,
26
- id: i
27
- } = s, c = {
28
- root: ["root", "directionY", a, `id-${i}`],
29
- line: ["line"],
30
- tickContainer: ["tickContainer"],
31
- tick: ["tick"],
32
- tickLabel: ["tickLabel"],
33
- label: ["label"]
34
- };
35
- return ae(c, xe, t);
36
- }, B = 2, ge = 2, te = {
37
- disableLine: !1,
38
- disableTicks: !1,
39
- tickSize: 6
40
- }, Le = ["scale", "tickNumber", "reverse"];
41
- function se(s) {
42
- const {
43
- yAxis: t,
44
- yAxisIds: a
45
- } = q(), i = t[s.axisId ?? a[0]], {
46
- scale: c,
47
- tickNumber: f
48
- } = i, p = R(i, Le), l = D({
49
- props: r({}, p, s),
50
- name: "MuiChartsYAxis"
51
- }), o = r({}, te, l), {
52
- position: n,
53
- tickLabelStyle: x,
54
- slots: u,
55
- slotProps: b
56
- } = o, m = U(), C = $(), y = ee(o), P = n === "right" ? 1 : -1, A = typeof x?.fontSize == "number" ? x.fontSize : 12, h = u?.axisTick ?? "line", k = u?.axisTickLabel ?? W, T = ue((n === "right" ? -90 : 90) - (x?.angle ?? 0)), g = fe((n === "right" ? -90 : 90) - (x?.angle ?? 0)), j = F({
57
- elementType: k,
58
- // @ts-expect-error `useSlotProps` applies `WithCommonProps` with adds a `style: React.CSSProperties` prop automatically.
59
- externalSlotProps: b?.axisTickLabel,
60
- // @ts-expect-error `useSlotProps` applies `WithCommonProps` with adds a `style: React.CSSProperties` prop automatically.
61
- additionalProps: {
62
- style: r({}, m.typography.caption, {
63
- fontSize: A,
64
- textAnchor: C ? pe(T) : T,
65
- dominantBaseline: g
66
- }, x)
67
- },
68
- className: y.tickLabel,
69
- ownerState: {}
70
- });
71
- return {
72
- yScale: c,
73
- defaultizedProps: o,
74
- tickNumber: f,
75
- positionSign: P,
76
- classes: y,
77
- Tick: h,
78
- TickLabel: k,
79
- axisTickLabelProps: j
80
- };
81
- }
82
- function Se(s) {
83
- const {
84
- axisLabelHeight: t,
85
- ordinalTimeTicks: a
86
- } = s, {
87
- yScale: i,
88
- defaultizedProps: c,
89
- tickNumber: f,
90
- positionSign: p,
91
- classes: l,
92
- Tick: o,
93
- TickLabel: n,
94
- axisTickLabelProps: x
95
- } = se(s), u = $(), {
96
- disableTicks: b,
97
- tickSize: m,
98
- valueFormatter: C,
99
- slotProps: y,
100
- tickPlacement: P,
101
- tickLabelPlacement: A,
102
- tickInterval: h,
103
- tickLabelInterval: k,
104
- tickSpacing: T,
105
- width: g
106
- } = c, j = J(), {
107
- instance: N
108
- } = Q(), z = K(), I = b ? 4 : m, L = ke({
109
- scale: i,
110
- tickNumber: f,
111
- valueFormatter: C,
112
- tickPlacement: P,
113
- tickLabelPlacement: A,
114
- tickInterval: h,
115
- tickSpacing: T,
116
- direction: "y",
117
- ordinalTimeTicks: a
118
- }), O = Math.max(0, g - (t > 0 ? t + ge : 0) - I - B), w = z ? ye(L, j, O, u, x.style) : new Map(Array.from(L).map((S) => [S, S.formattedValue]));
119
- return /* @__PURE__ */ d.jsx(V.Fragment, {
120
- children: L.map((S, v) => {
121
- const {
122
- offset: _,
123
- labelOffset: G,
124
- value: M
125
- } = S, Y = p * (I + B), ie = G, oe = typeof k == "function" && !k?.(M, v), ne = N.isYInside(_), E = w.get(S);
126
- return ne ? /* @__PURE__ */ d.jsxs("g", {
127
- transform: `translate(0, ${_})`,
128
- className: l.tickContainer,
129
- children: [!b && /* @__PURE__ */ d.jsx(o, r({
130
- x2: p * I,
131
- className: l.tick
132
- }, y?.axisTick)), E !== void 0 && !oe && /* @__PURE__ */ d.jsx(n, r({
133
- x: Y,
134
- y: ie,
135
- text: E
136
- }, x))]
137
- }, v) : null;
138
- })
139
- });
140
- }
141
- const H = {
142
- tickSize: 6
143
- }, Pe = (s, t, a) => {
144
- const i = s[t] ?? {}, c = a ?? H.tickSize, f = c * t * 2 + c;
145
- return r({}, H, i, {
146
- tickSize: i.tickSize ?? f
147
- });
148
- };
149
- function Ae(s) {
150
- const {
151
- yScale: t,
152
- defaultizedProps: a,
153
- positionSign: i,
154
- classes: c,
155
- Tick: f,
156
- TickLabel: p,
157
- axisTickLabelProps: l
158
- } = se(s);
159
- if (!Z(t))
160
- throw new Error("MUI X Charts: ChartsGroupedYAxis only supports the `band` and `point` scale types.");
161
- const {
162
- disableTicks: o,
163
- tickSize: n,
164
- valueFormatter: x,
165
- slotProps: u,
166
- tickInterval: b,
167
- tickPlacement: m,
168
- tickLabelPlacement: C
169
- } = a, y = a.groups, {
170
- instance: P
171
- } = Q(), A = be({
172
- scale: t,
173
- tickInterval: b,
174
- tickPlacement: m,
175
- tickLabelPlacement: C,
176
- groups: y
177
- });
178
- return /* @__PURE__ */ d.jsx(V.Fragment, {
179
- children: A.map((h, k) => {
180
- const {
181
- offset: T,
182
- labelOffset: g
183
- } = h, j = g ?? 0, N = P.isYInside(T), z = h.formattedValue, I = h.ignoreTick ?? !1, L = h.groupIndex ?? 0, O = Pe(y, L, n), w = i * O.tickSize, S = i * (O.tickSize + B);
184
- return /* @__PURE__ */ d.jsxs("g", {
185
- transform: `translate(0, ${T})`,
186
- className: c.tickContainer,
187
- "data-group-index": L,
188
- children: [!o && !I && N && /* @__PURE__ */ d.jsx(f, r({
189
- x2: w,
190
- className: c.tick
191
- }, u?.axisTick)), z !== void 0 && /* @__PURE__ */ d.jsx(p, r({
192
- x: S,
193
- y: j
194
- }, l, {
195
- style: r({}, l.style, O.tickLabelStyle),
196
- text: z
197
- }))]
198
- }, k);
199
- })
200
- });
201
- }
202
- const Ie = ["axis"], Ce = ["scale", "tickNumber", "reverse", "ordinalTimeTicks"], je = ce(he, {
203
- name: "MuiChartsYAxis",
204
- slot: "Root"
205
- })({});
206
- function ze(s) {
207
- let {
208
- axis: t
209
- } = s, a = R(s, Ie);
210
- const {
211
- scale: i,
212
- ordinalTimeTicks: c
213
- } = t, f = R(t, Ce), p = K(), l = D({
214
- props: r({}, f, a),
215
- name: "MuiChartsYAxis"
216
- }), o = r({}, te, l), {
217
- position: n,
218
- disableLine: x,
219
- label: u,
220
- labelStyle: b,
221
- offset: m,
222
- width: C,
223
- sx: y,
224
- slots: P,
225
- slotProps: A
226
- } = o, h = U(), k = ee(o), {
227
- left: T,
228
- top: g,
229
- width: j,
230
- height: N
231
- } = J(), z = n === "right" ? 1 : -1, I = P?.axisLine ?? "line", L = P?.axisLabel ?? W, O = F({
232
- elementType: I,
233
- externalSlotProps: A?.axisLine,
234
- additionalProps: {
235
- strokeLinecap: "square"
236
- },
237
- ownerState: {}
238
- }), w = F({
239
- elementType: L,
240
- // @ts-expect-error `useSlotProps` applies `WithCommonProps` with adds a `style: React.CSSProperties` prop automatically.
241
- externalSlotProps: A?.axisLabel,
242
- // @ts-expect-error `useSlotProps` applies `WithCommonProps` with adds a `style: React.CSSProperties` prop automatically.
243
- additionalProps: {
244
- style: r({}, h.typography.body1, {
245
- lineHeight: 1,
246
- fontSize: 14,
247
- angle: z * 90,
248
- textAnchor: "middle",
249
- dominantBaseline: "text-before-edge"
250
- }, b)
251
- },
252
- ownerState: {}
253
- });
254
- if (n === "none")
255
- return null;
256
- const S = {
257
- x: z * C,
258
- y: g + N / 2
259
- }, v = u == null ? 0 : X(u, w.style).height, _ = i.domain(), M = Z(i) ? _.length === 0 : _.some(me);
260
- let Y = null;
261
- return M || (Y = "groups" in t && Array.isArray(t.groups) ? /* @__PURE__ */ d.jsx(Ae, r({}, a)) : /* @__PURE__ */ d.jsx(Se, r({}, a, {
262
- axisLabelHeight: v,
263
- ordinalTimeTicks: c
264
- }))), /* @__PURE__ */ d.jsxs(je, {
265
- transform: `translate(${n === "right" ? T + j + m : T - m}, 0)`,
266
- className: k.root,
267
- "data-axis-id": o.id,
268
- sx: y,
269
- children: [!x && /* @__PURE__ */ d.jsx(I, r({
270
- y1: g,
271
- y2: g + N,
272
- className: k.line
273
- }, O)), Y, u && p && /* @__PURE__ */ d.jsx("g", {
274
- className: k.label,
275
- children: /* @__PURE__ */ d.jsx(L, r({}, S, w, {
276
- text: u
277
- }))
278
- })]
279
- });
280
- }
281
- function Oe(s) {
282
- const {
283
- yAxis: t,
284
- yAxisIds: a
285
- } = q(), i = t[s.axisId ?? a[0]];
286
- return i ? /* @__PURE__ */ d.jsx(ze, r({}, s, {
287
- axis: i
288
- })) : (le(`MUI X Charts: No axis found. The axisId "${s.axisId}" is probably invalid.`), null);
289
- }
290
- process.env.NODE_ENV !== "production" && (Oe.propTypes = {
291
- // ----------------------------- Warning --------------------------------
292
- // | These PropTypes are generated from the TypeScript type definitions |
293
- // | To update them edit the TypeScript types and run "pnpm proptypes" |
294
- // ----------------------------------------------------------------------
295
- axis: e.oneOf(["y"]),
296
- /**
297
- * The id of the axis to render.
298
- * If undefined, it will be the first defined axis.
299
- */
300
- axisId: e.oneOfType([e.number, e.string]),
301
- /**
302
- * Override or extend the styles applied to the component.
303
- */
304
- classes: e.object,
305
- /**
306
- * If true, the axis line is disabled.
307
- * @default false
308
- */
309
- disableLine: e.bool,
310
- /**
311
- * If true, the ticks are disabled.
312
- * @default false
313
- */
314
- disableTicks: e.bool,
315
- /**
316
- * The label of the axis.
317
- */
318
- label: e.string,
319
- /**
320
- * The style applied to the axis label.
321
- */
322
- labelStyle: e.object,
323
- /**
324
- * The props used for each component slot.
325
- * @default {}
326
- */
327
- slotProps: e.object,
328
- /**
329
- * Overridable component slots.
330
- * @default {}
331
- */
332
- slots: e.object,
333
- sx: e.oneOfType([e.arrayOf(e.oneOfType([e.func, e.object, e.bool])), e.func, e.object]),
334
- /**
335
- * Defines which ticks are displayed.
336
- * Its value can be:
337
- * - 'auto' In such case the ticks are computed based on axis scale and other parameters.
338
- * - a filtering function of the form `(value, index) => boolean` which is available only if the axis has "point" scale.
339
- * - an array containing the values where ticks should be displayed.
340
- * @see See {@link https://mui.com/x/react-charts/axis/#fixed-tick-positions}
341
- * @default 'auto'
342
- */
343
- tickInterval: e.oneOfType([e.oneOf(["auto"]), e.array, e.func]),
344
- /**
345
- * Defines which ticks get its label displayed. Its value can be:
346
- * - 'auto' In such case, labels are displayed if they do not overlap with the previous one.
347
- * - a filtering function of the form (value, index) => boolean. Warning: the index is tick index, not data ones.
348
- * @default 'auto'
349
- */
350
- tickLabelInterval: e.oneOfType([e.oneOf(["auto"]), e.func]),
351
- /**
352
- * The placement of ticks label. Can be the middle of the band, or the tick position.
353
- * Only used if scale is 'band'.
354
- * @default 'middle'
355
- */
356
- tickLabelPlacement: e.oneOf(["middle", "tick"]),
357
- /**
358
- * The style applied to ticks text.
359
- */
360
- tickLabelStyle: e.object,
361
- /**
362
- * Maximal step between two ticks.
363
- * When using time data, the value is assumed to be in ms.
364
- * Not supported by categorical axis (band, points).
365
- */
366
- tickMaxStep: e.number,
367
- /**
368
- * Minimal step between two ticks.
369
- * When using time data, the value is assumed to be in ms.
370
- * Not supported by categorical axis (band, points).
371
- */
372
- tickMinStep: e.number,
373
- /**
374
- * The number of ticks. This number is not guaranteed.
375
- * Not supported by categorical axis (band, points).
376
- */
377
- tickNumber: e.number,
378
- /**
379
- * The placement of ticks in regard to the band interval.
380
- * Only used if scale is 'band'.
381
- * @default 'extremities'
382
- */
383
- tickPlacement: e.oneOf(["end", "extremities", "middle", "start"]),
384
- /**
385
- * The size of the ticks.
386
- * @default 6
387
- */
388
- tickSize: e.number
389
- });
390
- export {
391
- Oe as C
392
- };
@@ -1 +0,0 @@
1
- "use strict";const e=require("./index--8Zky9Oh.js"),$=require("react"),l=require("./AxisSharedComponents-BbsKw1BT.js"),A=require("./useAxis-DSbfEtO7.js"),K=require("./clampAngle-DpAsDoeT.js");function J(s){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(s){for(const i in s)if(i!=="default"){const o=Object.getOwnPropertyDescriptor(s,i);Object.defineProperty(t,i,o.get?o:{enumerable:!0,get:()=>s[i]})}}return t.default=s,Object.freeze(t)}const D=J($);function Q(s,t,i,o,r){const d=new Map,u=K.clampAngle(r?.angle??0);let c=1,n=1;r?.textAnchor==="start"?(c=1/0,n=1):r?.textAnchor==="end"?(c=1,n=1/0):(c=2,n=2),u>180&&([c,n]=[n,c]),o&&([c,n]=[n,c]);for(const a of s)if(a.formattedValue){const p=Math.min((a.offset+a.labelOffset)*c,(t.top+t.height+t.bottom-a.offset-a.labelOffset)*n),x=T=>l.doesTextFitInRect(T,{width:i,height:p,angle:u,measureText:y=>l.getStringSize(y,r)});d.set(a,l.ellipsize(a.formattedValue.toString(),x))}return d}const G=s=>{const{classes:t,position:i,id:o}=s,r={root:["root","directionY",i,`id-${o}`],line:["line"],tickContainer:["tickContainer"],tick:["tick"],tickLabel:["tickLabel"],label:["label"]};return e.composeClasses(r,l.getAxisUtilityClass,t)},Y=2,Z=2,H={disableLine:!1,disableTicks:!1,tickSize:6},ee=["scale","tickNumber","reverse"];function q(s){const{yAxis:t,yAxisIds:i}=A.useYAxes(),o=t[s.axisId??i[0]],{scale:r,tickNumber:d}=o,u=e._objectWithoutPropertiesLoose(o,ee),c=e.useThemeProps({props:e._extends({},u,s),name:"MuiChartsYAxis"}),n=e._extends({},H,c),{position:a,tickLabelStyle:p,slots:x,slotProps:T}=n,y=e.useTheme(),_=e.useRtl(),b=G(n),S=a==="right"?1:-1,L=typeof p?.fontSize=="number"?p.fontSize:12,k=x?.axisTick??"line",f=x?.axisTickLabel??l.ChartsText,m=l.getDefaultTextAnchor((a==="right"?-90:90)-(p?.angle??0)),h=l.getDefaultBaseline((a==="right"?-90:90)-(p?.angle??0)),C=e.useSlotProps({elementType:f,externalSlotProps:T?.axisTickLabel,additionalProps:{style:e._extends({},y.typography.caption,{fontSize:L,textAnchor:_?l.invertTextAnchor(m):m,dominantBaseline:h},p)},className:b.tickLabel,ownerState:{}});return{yScale:r,defaultizedProps:n,tickNumber:d,positionSign:S,classes:b,Tick:k,TickLabel:f,axisTickLabelProps:C}}function te(s){const{axisLabelHeight:t,ordinalTimeTicks:i}=s,{yScale:o,defaultizedProps:r,tickNumber:d,positionSign:u,classes:c,Tick:n,TickLabel:a,axisTickLabelProps:p}=q(s),x=e.useRtl(),{disableTicks:T,tickSize:y,valueFormatter:_,slotProps:b,tickPlacement:S,tickLabelPlacement:L,tickInterval:k,tickLabelInterval:f,tickSpacing:m,width:h}=r,C=A.useDrawingArea(),{instance:z}=A.useChartContext(),O=l.useIsHydrated(),j=T?4:y,P=l.useTicks({scale:o,tickNumber:d,valueFormatter:_,tickPlacement:S,tickLabelPlacement:L,tickInterval:k,tickSpacing:m,direction:"y",ordinalTimeTicks:i}),I=Math.max(0,h-(t>0?t+Z:0)-j-Y),R=O?Q(P,C,I,x,p.style):new Map(Array.from(P).map(g=>[g,g.formattedValue]));return e.jsxRuntimeExports.jsx(D.Fragment,{children:P.map((g,N)=>{const{offset:E,labelOffset:M,value:v}=g,w=u*(j+Y),W=M,V=typeof f=="function"&&!f?.(v,N),X=z.isYInside(E),F=R.get(g);return X?e.jsxRuntimeExports.jsxs("g",{transform:`translate(0, ${E})`,className:c.tickContainer,children:[!T&&e.jsxRuntimeExports.jsx(n,e._extends({x2:u*j,className:c.tick},b?.axisTick)),F!==void 0&&!V&&e.jsxRuntimeExports.jsx(a,e._extends({x:w,y:W,text:F},p))]},N):null})})}const B={tickSize:6},se=(s,t,i)=>{const o=s[t]??{},r=i??B.tickSize,d=r*t*2+r;return e._extends({},B,o,{tickSize:o.tickSize??d})};function ie(s){const{yScale:t,defaultizedProps:i,positionSign:o,classes:r,Tick:d,TickLabel:u,axisTickLabelProps:c}=q(s);if(!A.isOrdinalScale(t))throw new Error("MUI X Charts: ChartsGroupedYAxis only supports the `band` and `point` scale types.");const{disableTicks:n,tickSize:a,valueFormatter:p,slotProps:x,tickInterval:T,tickPlacement:y,tickLabelPlacement:_}=i,b=i.groups,{instance:S}=A.useChartContext(),L=l.useTicksGrouped({scale:t,tickInterval:T,tickPlacement:y,tickLabelPlacement:_,groups:b});return e.jsxRuntimeExports.jsx(D.Fragment,{children:L.map((k,f)=>{const{offset:m,labelOffset:h}=k,C=h??0,z=S.isYInside(m),O=k.formattedValue,j=k.ignoreTick??!1,P=k.groupIndex??0,I=se(b,P,a),R=o*I.tickSize,g=o*(I.tickSize+Y);return e.jsxRuntimeExports.jsxs("g",{transform:`translate(0, ${m})`,className:r.tickContainer,"data-group-index":P,children:[!n&&!j&&z&&e.jsxRuntimeExports.jsx(d,e._extends({x2:R,className:r.tick},x?.axisTick)),O!==void 0&&e.jsxRuntimeExports.jsx(u,e._extends({x:g,y:C},c,{style:e._extends({},c.style,I.tickLabelStyle),text:O}))]},f)})})}const oe=["axis"],ne=["scale","tickNumber","reverse","ordinalTimeTicks"],ae=e.styled(l.AxisRoot,{name:"MuiChartsYAxis",slot:"Root"})({});function re(s){let{axis:t}=s,i=e._objectWithoutPropertiesLoose(s,oe);const{scale:o,ordinalTimeTicks:r}=t,d=e._objectWithoutPropertiesLoose(t,ne),u=l.useIsHydrated(),c=e.useThemeProps({props:e._extends({},d,i),name:"MuiChartsYAxis"}),n=e._extends({},H,c),{position:a,disableLine:p,label:x,labelStyle:T,offset:y,width:_,sx:b,slots:S,slotProps:L}=n,k=e.useTheme(),f=G(n),{left:m,top:h,width:C,height:z}=A.useDrawingArea(),O=a==="right"?1:-1,j=S?.axisLine??"line",P=S?.axisLabel??l.ChartsText,I=e.useSlotProps({elementType:j,externalSlotProps:L?.axisLine,additionalProps:{strokeLinecap:"square"},ownerState:{}}),R=e.useSlotProps({elementType:P,externalSlotProps:L?.axisLabel,additionalProps:{style:e._extends({},k.typography.body1,{lineHeight:1,fontSize:14,angle:O*90,textAnchor:"middle",dominantBaseline:"text-before-edge"},T)},ownerState:{}});if(a==="none")return null;const g={x:O*_,y:h+z/2},N=x==null?0:l.getStringSize(x,R.style).height,E=o.domain(),v=A.isOrdinalScale(o)?E.length===0:E.some(l.isInfinity);let w=null;return v||(w="groups"in t&&Array.isArray(t.groups)?e.jsxRuntimeExports.jsx(ie,e._extends({},i)):e.jsxRuntimeExports.jsx(te,e._extends({},i,{axisLabelHeight:N,ordinalTimeTicks:r}))),e.jsxRuntimeExports.jsxs(ae,{transform:`translate(${a==="right"?m+C+y:m-y}, 0)`,className:f.root,"data-axis-id":n.id,sx:b,children:[!p&&e.jsxRuntimeExports.jsx(j,e._extends({y1:h,y2:h+z,className:f.line},I)),w,x&&u&&e.jsxRuntimeExports.jsx("g",{className:f.label,children:e.jsxRuntimeExports.jsx(P,e._extends({},g,R,{text:x}))})]})}function U(s){const{yAxis:t,yAxisIds:i}=A.useYAxes(),o=t[s.axisId??i[0]];return o?e.jsxRuntimeExports.jsx(re,e._extends({},s,{axis:o})):(e.warnOnce(`MUI X Charts: No axis found. The axisId "${s.axisId}" is probably invalid.`),null)}process.env.NODE_ENV!=="production"&&(U.propTypes={axis:e.PropTypes.oneOf(["y"]),axisId:e.PropTypes.oneOfType([e.PropTypes.number,e.PropTypes.string]),classes:e.PropTypes.object,disableLine:e.PropTypes.bool,disableTicks:e.PropTypes.bool,label:e.PropTypes.string,labelStyle:e.PropTypes.object,slotProps:e.PropTypes.object,slots:e.PropTypes.object,sx:e.PropTypes.oneOfType([e.PropTypes.arrayOf(e.PropTypes.oneOfType([e.PropTypes.func,e.PropTypes.object,e.PropTypes.bool])),e.PropTypes.func,e.PropTypes.object]),tickInterval:e.PropTypes.oneOfType([e.PropTypes.oneOf(["auto"]),e.PropTypes.array,e.PropTypes.func]),tickLabelInterval:e.PropTypes.oneOfType([e.PropTypes.oneOf(["auto"]),e.PropTypes.func]),tickLabelPlacement:e.PropTypes.oneOf(["middle","tick"]),tickLabelStyle:e.PropTypes.object,tickMaxStep:e.PropTypes.number,tickMinStep:e.PropTypes.number,tickNumber:e.PropTypes.number,tickPlacement:e.PropTypes.oneOf(["end","extremities","middle","start"]),tickSize:e.PropTypes.number});exports.ChartsYAxis=U;
@@ -1,237 +0,0 @@
1
- import { S as D, N as S, d as $, L as F, b as A, e as O, U as R } from "./index-Cr6Wp_S-.mjs";
2
- import { a as w, t as x } from "./date-utils-pGzaKb0p.mjs";
3
- function W(s) {
4
- return encodeURIComponent(s).replace(/[!'()*]/g, function(r) {
5
- return "%" + r.charCodeAt(0).toString(16).toUpperCase();
6
- });
7
- }
8
- const y = "(?:Mon|Tue|Wed|Thu|Fri|Sat|Sun)(?:[ne|u?r]?s?day)?", b = "(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)", N = "(\\d?\\d):(\\d{2}):(\\d{2})(?:\\.(\\d+))?", M = "(\\d?\\d)", E = "(\\d{4})", U = new RegExp(/^(\d{4})-(\d\d)-(\d\d)[tT](\d\d):(\d\d):(\d\d)(\.(\d+))?(([-+]\d\d:\d\d)|[zZ])$/), k = new RegExp(`^${y}, ${M} ${b} ${E} ${N} GMT$`), z = new RegExp(`^${y}, ${M}-${b}-(\\d\\d) ${N} GMT$`), I = new RegExp(`^${y} ${b} ( [1-9]|\\d\\d) ${N} ${E}$`), _ = ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"], L = (s) => {
9
- if (s == null)
10
- return;
11
- let r = NaN;
12
- if (typeof s == "number")
13
- r = s;
14
- else if (typeof s == "string") {
15
- if (!/^-?\d*\.?\d+$/.test(s))
16
- throw new TypeError("parseEpochTimestamp - numeric string invalid.");
17
- r = Number.parseFloat(s);
18
- } else typeof s == "object" && s.tag === 1 && (r = s.value);
19
- if (isNaN(r) || Math.abs(r) === 1 / 0)
20
- throw new TypeError("Epoch timestamps must be valid finite numbers.");
21
- return new Date(Math.round(r * 1e3));
22
- }, P = (s) => {
23
- if (s == null)
24
- return;
25
- if (typeof s != "string")
26
- throw new TypeError("RFC3339 timestamps must be strings");
27
- const r = U.exec(s);
28
- if (!r)
29
- throw new TypeError(`Invalid RFC3339 timestamp format ${s}`);
30
- const [, e, t, o, n, i, c, , m, f] = r;
31
- h(t, 1, 12), h(o, 1, 31), h(n, 0, 23), h(i, 0, 59), h(c, 0, 60);
32
- const a = new Date(Date.UTC(Number(e), Number(t) - 1, Number(o), Number(n), Number(i), Number(c), Number(m) ? Math.round(parseFloat(`0.${m}`) * 1e3) : 0));
33
- if (a.setUTCFullYear(Number(e)), f.toUpperCase() != "Z") {
34
- const [, d, l, u] = /([+-])(\d\d):(\d\d)/.exec(f) || [void 0, "+", 0, 0], p = d === "-" ? 1 : -1;
35
- a.setTime(a.getTime() + p * (Number(l) * 60 * 60 * 1e3 + Number(u) * 60 * 1e3));
36
- }
37
- return a;
38
- }, B = (s) => {
39
- if (s == null)
40
- return;
41
- if (typeof s != "string")
42
- throw new TypeError("RFC7231 timestamps must be strings.");
43
- let r, e, t, o, n, i, c, m;
44
- if ((m = k.exec(s)) ? [, r, e, t, o, n, i, c] = m : (m = z.exec(s)) ? ([, r, e, t, o, n, i, c] = m, t = (Number(t) + 1900).toString()) : (m = I.exec(s)) && ([, e, r, o, n, i, c, t] = m), t && i) {
45
- const f = Date.UTC(Number(t), _.indexOf(e), Number(r), Number(o), Number(n), Number(i), c ? Math.round(parseFloat(`0.${c}`) * 1e3) : 0);
46
- h(r, 1, 31), h(o, 0, 23), h(n, 0, 59), h(i, 0, 60);
47
- const a = new Date(f);
48
- return a.setUTCFullYear(Number(t)), a;
49
- }
50
- throw new TypeError(`Invalid RFC7231 date-time value ${s}.`);
51
- };
52
- function h(s, r, e) {
53
- const t = Number(s);
54
- if (t < r || t > e)
55
- throw new Error(`Value ${t} out of range [${r}, ${e}]`);
56
- }
57
- const J = (s) => {
58
- const r = s.length, e = [];
59
- let t = !1, o, n = 0;
60
- for (let i = 0; i < r; ++i) {
61
- const c = s[i];
62
- switch (c) {
63
- case '"':
64
- o !== "\\" && (t = !t);
65
- break;
66
- case ",":
67
- t || (e.push(s.slice(n, i)), n = i + 1);
68
- break;
69
- }
70
- o = c;
71
- }
72
- return e.push(s.slice(n)), e.map((i) => {
73
- i = i.trim();
74
- const c = i.length;
75
- return c < 2 ? i : (i[0] === '"' && i[c - 1] === '"' && (i = i.slice(1, c - 1)), i.replace(/\\"/g, '"'));
76
- });
77
- };
78
- class V extends D {
79
- settings;
80
- constructor(r) {
81
- super(), this.settings = r;
82
- }
83
- read(r, e) {
84
- const t = S.of(r);
85
- if (t.isListSchema())
86
- return J(e).map((o) => this.read(t.getValueSchema(), o));
87
- if (t.isBlobSchema())
88
- return (this.serdeContext?.base64Decoder ?? w)(e);
89
- if (t.isTimestampSchema())
90
- switch ($(t, this.settings)) {
91
- case 5:
92
- return P(e);
93
- case 6:
94
- return B(e);
95
- case 7:
96
- return L(e);
97
- default:
98
- return console.warn("Missing timestamp format, parsing value with Date constructor:", e), new Date(e);
99
- }
100
- if (t.isStringSchema()) {
101
- const o = t.getMergedTraits().mediaType;
102
- let n = e;
103
- if (o)
104
- return t.getMergedTraits().httpHeader && (n = this.base64ToUtf8(n)), (o === "application/json" || o.endsWith("+json")) && (n = F.from(n)), n;
105
- }
106
- return t.isNumericSchema() ? Number(e) : t.isBigIntegerSchema() ? BigInt(e) : t.isBigDecimalSchema() ? new A(e, "bigDecimal") : t.isBooleanSchema() ? String(e).toLowerCase() === "true" : e;
107
- }
108
- base64ToUtf8(r) {
109
- return (this.serdeContext?.utf8Encoder ?? x)((this.serdeContext?.base64Decoder ?? w)(r));
110
- }
111
- }
112
- const C = (s) => {
113
- const r = "#text";
114
- for (const e in s)
115
- s.hasOwnProperty(e) && s[e][r] !== void 0 ? s[e] = s[e][r] : typeof s[e] == "object" && s[e] !== null && (s[e] = C(s[e]));
116
- return s;
117
- };
118
- let g;
119
- function X(s) {
120
- g || (g = new DOMParser());
121
- const r = g.parseFromString(s, "application/xml");
122
- if (r.getElementsByTagName("parsererror").length > 0)
123
- throw new Error("DOMParser XML parsing error.");
124
- const e = (t) => {
125
- if (t.nodeType === Node.TEXT_NODE && t.textContent?.trim())
126
- return t.textContent;
127
- if (t.nodeType === Node.ELEMENT_NODE) {
128
- const o = t;
129
- if (o.attributes.length === 0 && o.childNodes.length === 0)
130
- return "";
131
- const n = {}, i = Array.from(o.attributes);
132
- for (const m of i)
133
- n[`${m.name}`] = m.value;
134
- const c = Array.from(o.childNodes);
135
- for (const m of c) {
136
- const f = e(m);
137
- if (f != null) {
138
- const a = m.nodeName;
139
- if (c.length === 1 && i.length === 0 && a === "#text")
140
- return f;
141
- n[a] ? Array.isArray(n[a]) ? n[a].push(f) : n[a] = [n[a], f] : n[a] = f;
142
- } else if (c.length === 1 && i.length === 0)
143
- return o.textContent;
144
- }
145
- return n;
146
- }
147
- return null;
148
- };
149
- return {
150
- [r.documentElement.nodeName]: e(r.documentElement)
151
- };
152
- }
153
- class K extends O {
154
- settings;
155
- stringDeserializer;
156
- constructor(r) {
157
- super(), this.settings = r, this.stringDeserializer = new V(r);
158
- }
159
- setSerdeContext(r) {
160
- this.serdeContext = r, this.stringDeserializer.setSerdeContext(r);
161
- }
162
- read(r, e, t) {
163
- const o = S.of(r), n = o.getMemberSchemas();
164
- if (o.isStructSchema() && o.isMemberSchema() && !!Object.values(n).find((f) => !!f.getMemberTraits().eventPayload)) {
165
- const f = {}, a = Object.keys(n)[0];
166
- return n[a].isBlobSchema() ? f[a] = e : f[a] = this.read(n[a], e), f;
167
- }
168
- const c = (this.serdeContext?.utf8Encoder ?? x)(e), m = this.parseXml(c);
169
- return this.readSchema(r, t ? m[t] : m);
170
- }
171
- readSchema(r, e) {
172
- const t = S.of(r);
173
- if (t.isUnitSchema())
174
- return;
175
- const o = t.getMergedTraits();
176
- if (t.isListSchema() && !Array.isArray(e))
177
- return this.readSchema(t, [e]);
178
- if (e == null)
179
- return e;
180
- if (typeof e == "object") {
181
- const n = !!o.sparse, i = !!o.xmlFlattened;
182
- if (t.isListSchema()) {
183
- const m = t.getValueSchema(), f = [], a = m.getMergedTraits().xmlName ?? "member", d = i ? e : (e[0] ?? e)[a], l = Array.isArray(d) ? d : [d];
184
- for (const u of l)
185
- (u != null || n) && f.push(this.readSchema(m, u));
186
- return f;
187
- }
188
- const c = {};
189
- if (t.isMapSchema()) {
190
- const m = t.getKeySchema(), f = t.getValueSchema();
191
- let a;
192
- i ? a = Array.isArray(e) ? e : [e] : a = Array.isArray(e.entry) ? e.entry : [e.entry];
193
- const d = m.getMergedTraits().xmlName ?? "key", l = f.getMergedTraits().xmlName ?? "value";
194
- for (const u of a) {
195
- const p = u[d], T = u[l];
196
- (T != null || n) && (c[p] = this.readSchema(f, T));
197
- }
198
- return c;
199
- }
200
- if (t.isStructSchema()) {
201
- const m = t.isUnionSchema();
202
- let f;
203
- m && (f = new R(e, c));
204
- for (const [a, d] of t.structIterator()) {
205
- const l = d.getMergedTraits(), u = l.httpPayload ? l.xmlName ?? d.getName() : d.getMemberTraits().xmlName ?? a;
206
- m && f.mark(u), e[u] != null && (c[a] = this.readSchema(d, e[u]));
207
- }
208
- return m && f.writeUnknown(), c;
209
- }
210
- if (t.isDocumentSchema())
211
- return e;
212
- throw new Error(`@aws-sdk/core/protocols - xml deserializer unhandled schema type for ${t.getName(!0)}`);
213
- }
214
- return t.isListSchema() ? [] : t.isMapSchema() || t.isStructSchema() ? {} : this.stringDeserializer.read(t, e);
215
- }
216
- parseXml(r) {
217
- if (r.length) {
218
- let e;
219
- try {
220
- e = X(r);
221
- } catch (i) {
222
- throw i && typeof i == "object" && Object.defineProperty(i, "$responseBodyText", {
223
- value: r
224
- }), i;
225
- }
226
- const t = "#text", o = Object.keys(e)[0], n = e[o];
227
- return n[t] && (n[o] = n[t], delete n[t]), C(n);
228
- }
229
- return {};
230
- }
231
- }
232
- export {
233
- V as F,
234
- K as X,
235
- W as e,
236
- J as s
237
- };
@@ -1 +0,0 @@
1
- "use strict";const h=require("./index-DKS5Sz9e.js"),g=require("./date-utils-CFUUt6NL.js");function $(s){return encodeURIComponent(s).replace(/[!'()*]/g,function(r){return"%"+r.charCodeAt(0).toString(16).toUpperCase()})}const N="(?:Mon|Tue|Wed|Thu|Fri|Sat|Sun)(?:[ne|u?r]?s?day)?",b="(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)",T="(\\d?\\d):(\\d{2}):(\\d{2})(?:\\.(\\d+))?",w="(\\d?\\d)",E="(\\d{4})",F=new RegExp(/^(\d{4})-(\d\d)-(\d\d)[tT](\d\d):(\d\d):(\d\d)(\.(\d+))?(([-+]\d\d:\d\d)|[zZ])$/),A=new RegExp(`^${N}, ${w} ${b} ${E} ${T} GMT$`),O=new RegExp(`^${N}, ${w}-${b}-(\\d\\d) ${T} GMT$`),U=new RegExp(`^${N} ${b} ( [1-9]|\\d\\d) ${T} ${E}$`),R=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],z=s=>{if(s==null)return;let r=NaN;if(typeof s=="number")r=s;else if(typeof s=="string"){if(!/^-?\d*\.?\d+$/.test(s))throw new TypeError("parseEpochTimestamp - numeric string invalid.");r=Number.parseFloat(s)}else typeof s=="object"&&s.tag===1&&(r=s.value);if(isNaN(r)||Math.abs(r)===1/0)throw new TypeError("Epoch timestamps must be valid finite numbers.");return new Date(Math.round(r*1e3))},I=s=>{if(s==null)return;if(typeof s!="string")throw new TypeError("RFC3339 timestamps must be strings");const r=F.exec(s);if(!r)throw new TypeError(`Invalid RFC3339 timestamp format ${s}`);const[,e,t,o,n,i,c,,m,d]=r;l(t,1,12),l(o,1,31),l(n,0,23),l(i,0,59),l(c,0,60);const a=new Date(Date.UTC(Number(e),Number(t)-1,Number(o),Number(n),Number(i),Number(c),Number(m)?Math.round(parseFloat(`0.${m}`)*1e3):0));if(a.setUTCFullYear(Number(e)),d.toUpperCase()!="Z"){const[,f,p,u]=/([+-])(\d\d):(\d\d)/.exec(d)||[void 0,"+",0,0],S=f==="-"?1:-1;a.setTime(a.getTime()+S*(Number(p)*60*60*1e3+Number(u)*60*1e3))}return a},k=s=>{if(s==null)return;if(typeof s!="string")throw new TypeError("RFC7231 timestamps must be strings.");let r,e,t,o,n,i,c,m;if((m=A.exec(s))?[,r,e,t,o,n,i,c]=m:(m=O.exec(s))?([,r,e,t,o,n,i,c]=m,t=(Number(t)+1900).toString()):(m=U.exec(s))&&([,e,r,o,n,i,c,t]=m),t&&i){const d=Date.UTC(Number(t),R.indexOf(e),Number(r),Number(o),Number(n),Number(i),c?Math.round(parseFloat(`0.${c}`)*1e3):0);l(r,1,31),l(o,0,23),l(n,0,59),l(i,0,60);const a=new Date(d);return a.setUTCFullYear(Number(t)),a}throw new TypeError(`Invalid RFC7231 date-time value ${s}.`)};function l(s,r,e){const t=Number(s);if(t<r||t>e)throw new Error(`Value ${t} out of range [${r}, ${e}]`)}const M=s=>{const r=s.length,e=[];let t=!1,o,n=0;for(let i=0;i<r;++i){const c=s[i];switch(c){case'"':o!=="\\"&&(t=!t);break;case",":t||(e.push(s.slice(n,i)),n=i+1);break}o=c}return e.push(s.slice(n)),e.map(i=>{i=i.trim();const c=i.length;return c<2?i:(i[0]==='"'&&i[c-1]==='"'&&(i=i.slice(1,c-1)),i.replace(/\\"/g,'"'))})};class C extends h.SerdeContext{settings;constructor(r){super(),this.settings=r}read(r,e){const t=h.NormalizedSchema.of(r);if(t.isListSchema())return M(e).map(o=>this.read(t.getValueSchema(),o));if(t.isBlobSchema())return(this.serdeContext?.base64Decoder??g.fromBase64)(e);if(t.isTimestampSchema())switch(h.determineTimestampFormat(t,this.settings)){case 5:return I(e);case 6:return k(e);case 7:return z(e);default:return console.warn("Missing timestamp format, parsing value with Date constructor:",e),new Date(e)}if(t.isStringSchema()){const o=t.getMergedTraits().mediaType;let n=e;if(o)return t.getMergedTraits().httpHeader&&(n=this.base64ToUtf8(n)),(o==="application/json"||o.endsWith("+json"))&&(n=h.LazyJsonString.from(n)),n}return t.isNumericSchema()?Number(e):t.isBigIntegerSchema()?BigInt(e):t.isBigDecimalSchema()?new h.NumericValue(e,"bigDecimal"):t.isBooleanSchema()?String(e).toLowerCase()==="true":e}base64ToUtf8(r){return(this.serdeContext?.utf8Encoder??g.toUtf8)((this.serdeContext?.base64Decoder??g.fromBase64)(r))}}const D=s=>{const r="#text";for(const e in s)s.hasOwnProperty(e)&&s[e][r]!==void 0?s[e]=s[e][r]:typeof s[e]=="object"&&s[e]!==null&&(s[e]=D(s[e]));return s};let y;function _(s){y||(y=new DOMParser);const r=y.parseFromString(s,"application/xml");if(r.getElementsByTagName("parsererror").length>0)throw new Error("DOMParser XML parsing error.");const e=t=>{if(t.nodeType===Node.TEXT_NODE&&t.textContent?.trim())return t.textContent;if(t.nodeType===Node.ELEMENT_NODE){const o=t;if(o.attributes.length===0&&o.childNodes.length===0)return"";const n={},i=Array.from(o.attributes);for(const m of i)n[`${m.name}`]=m.value;const c=Array.from(o.childNodes);for(const m of c){const d=e(m);if(d!=null){const a=m.nodeName;if(c.length===1&&i.length===0&&a==="#text")return d;n[a]?Array.isArray(n[a])?n[a].push(d):n[a]=[n[a],d]:n[a]=d}else if(c.length===1&&i.length===0)return o.textContent}return n}return null};return{[r.documentElement.nodeName]:e(r.documentElement)}}class B extends h.SerdeContextConfig{settings;stringDeserializer;constructor(r){super(),this.settings=r,this.stringDeserializer=new C(r)}setSerdeContext(r){this.serdeContext=r,this.stringDeserializer.setSerdeContext(r)}read(r,e,t){const o=h.NormalizedSchema.of(r),n=o.getMemberSchemas();if(o.isStructSchema()&&o.isMemberSchema()&&!!Object.values(n).find(d=>!!d.getMemberTraits().eventPayload)){const d={},a=Object.keys(n)[0];return n[a].isBlobSchema()?d[a]=e:d[a]=this.read(n[a],e),d}const c=(this.serdeContext?.utf8Encoder??g.toUtf8)(e),m=this.parseXml(c);return this.readSchema(r,t?m[t]:m)}readSchema(r,e){const t=h.NormalizedSchema.of(r);if(t.isUnitSchema())return;const o=t.getMergedTraits();if(t.isListSchema()&&!Array.isArray(e))return this.readSchema(t,[e]);if(e==null)return e;if(typeof e=="object"){const n=!!o.sparse,i=!!o.xmlFlattened;if(t.isListSchema()){const m=t.getValueSchema(),d=[],a=m.getMergedTraits().xmlName??"member",f=i?e:(e[0]??e)[a],p=Array.isArray(f)?f:[f];for(const u of p)(u!=null||n)&&d.push(this.readSchema(m,u));return d}const c={};if(t.isMapSchema()){const m=t.getKeySchema(),d=t.getValueSchema();let a;i?a=Array.isArray(e)?e:[e]:a=Array.isArray(e.entry)?e.entry:[e.entry];const f=m.getMergedTraits().xmlName??"key",p=d.getMergedTraits().xmlName??"value";for(const u of a){const S=u[f],x=u[p];(x!=null||n)&&(c[S]=this.readSchema(d,x))}return c}if(t.isStructSchema()){const m=t.isUnionSchema();let d;m&&(d=new h.UnionSerde(e,c));for(const[a,f]of t.structIterator()){const p=f.getMergedTraits(),u=p.httpPayload?p.xmlName??f.getName():f.getMemberTraits().xmlName??a;m&&d.mark(u),e[u]!=null&&(c[a]=this.readSchema(f,e[u]))}return m&&d.writeUnknown(),c}if(t.isDocumentSchema())return e;throw new Error(`@aws-sdk/core/protocols - xml deserializer unhandled schema type for ${t.getName(!0)}`)}return t.isListSchema()?[]:t.isMapSchema()||t.isStructSchema()?{}:this.stringDeserializer.read(t,e)}parseXml(r){if(r.length){let e;try{e=_(r)}catch(i){throw i&&typeof i=="object"&&Object.defineProperty(i,"$responseBodyText",{value:r}),i}const t="#text",o=Object.keys(e)[0],n=e[o];return n[t]&&(n[o]=n[t],delete n[t]),D(n)}return{}}}exports.FromStringShapeDeserializer=C;exports.XmlShapeDeserializer=B;exports.extendedEncodeURIComponent=$;exports.splitHeader=M;
@@ -1,11 +0,0 @@
1
- function t(n) {
2
- return (n % 360 + 360) % 360;
3
- }
4
- const a = 2 * Math.PI;
5
- function c(n) {
6
- return (n % a + a) % a;
7
- }
8
- export {
9
- c as a,
10
- t as c
11
- };
@@ -1 +0,0 @@
1
- "use strict";function l(n){return(n%360+360)%360}const c=2*Math.PI;function t(n){return(n%c+c)%c}exports.clampAngle=l;exports.clampAngleRad=t;