@pagehub/sdk 0.1.4 → 0.1.6

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 (141) hide show
  1. package/README.md +1 -1
  2. package/dist/chrome/viewport/Viewport/hooks/usePageLoadIndicator.d.ts +2 -2
  3. package/dist/chrome/viewport/design-system/hooks/useDesignSystem.d.ts +2 -2
  4. package/dist/chrome/viewport/design-system/hooks/usePaletteState.d.ts +2 -2
  5. package/dist/chunks/ActionEditorPanel-9v50QUwu.js +89 -0
  6. package/dist/chunks/ActionInput-CTt7sOs6.js +929 -0
  7. package/dist/chunks/ActionsAddPicker-BeTPUUor.js +51 -0
  8. package/dist/chunks/ActionsInput-D0h-zLYj.js +174 -0
  9. package/dist/chunks/AnchoredPopover-CckPTxXu.js +2676 -0
  10. package/dist/chunks/AnimationEditorPanel-CXNmsTqV.js +26 -0
  11. package/dist/chunks/AnimationsInput-Djyz0uXG.js +292 -0
  12. package/dist/chunks/AnimationsInputPopover-B2-oNebx.js +71 -0
  13. package/dist/chunks/AnimationsPanel-DungA9qb.js +25 -0
  14. package/dist/chunks/Audio.render-CsR69fZ9.js +22 -0
  15. package/dist/chunks/AudioMainTab-BljM2NMQ.js +70 -0
  16. package/dist/chunks/BackdropEditorPanel-CA2k-6SR.js +26 -0
  17. package/dist/chunks/BackgroundImageInputPopover-vB_217Ig.js +94 -0
  18. package/dist/chunks/BackgroundImagePanel-BvMhF9eU.js +100 -0
  19. package/dist/chunks/BackgroundMainTab-CI4c5DEF.js +10 -0
  20. package/dist/chunks/BundleRowPanel-BcYfyfGQ.js +33 -0
  21. package/dist/chunks/ButtonMainTab-Civy_DoA.js +43 -0
  22. package/dist/chunks/CSSEditorInput-C1ITwAh3.js +73 -0
  23. package/dist/chunks/ClassNameInput-Ce0fGQES.js +720 -0
  24. package/dist/chunks/CodeEditor-axBXmPH8.js +33370 -0
  25. package/dist/chunks/ColorInput-BSfMNt86.js +187 -0
  26. package/dist/chunks/ColorPanel-DOLrT-gS.js +562 -0
  27. package/dist/chunks/ComponentImportExportPanel-DVcnGhGx.js +161 -0
  28. package/dist/chunks/ComponentImportExportPopover-BY1_oxU8.js +26 -0
  29. package/dist/chunks/ConditionEditorPanel-DLbqYaSF.js +43 -0
  30. package/dist/chunks/ConditionsAddPicker-SsHJlc1E.js +54 -0
  31. package/dist/chunks/ConditionsInput-B_5Nge8o.js +474 -0
  32. package/dist/chunks/ContainerMainTab-kkktm1Ns.js +1107 -0
  33. package/dist/chunks/ContainerOverflowSectionPanel-ibKXf-1N.js +120 -0
  34. package/dist/chunks/ContainerOverflowSectionPopover-CRQ9EPsn.js +24 -0
  35. package/dist/chunks/ContainerPaddingOverlay-Cd3xOv-S.js +340 -0
  36. package/dist/chunks/ContainerScrollEffectSection-Dbztqdnr.js +123 -0
  37. package/dist/chunks/ContainerStateSection-DY_gjBJL.js +478 -0
  38. package/dist/chunks/ConversionFields-Bpfl-SGP.js +135 -0
  39. package/dist/chunks/CraftListEditor-_TIy1ogW.js +73 -0
  40. package/dist/chunks/CreateTokenDialog-DNWtWqJd.js +147 -0
  41. package/dist/chunks/Data.render-DTmaqSyz.js +10 -0
  42. package/dist/chunks/DataAttributesPanel-mYhisO_O.js +125 -0
  43. package/dist/chunks/DataMainTab-Batm515E.js +23 -0
  44. package/dist/chunks/DataSourceSectionSlot-BKoO6Vxn.js +10 -0
  45. package/dist/chunks/EditorEmptyLeafHintView-D3E3UN_0.js +78 -0
  46. package/dist/chunks/EffectRowInputPopover-CYhfjFwJ.js +323 -0
  47. package/dist/chunks/EffectsClassInput-Yujuchwy.js +315 -0
  48. package/dist/chunks/Embed.render-BgKpUV8n.js +17 -0
  49. package/dist/chunks/EmbedMainTab-d_-Bnkug.js +225 -0
  50. package/dist/chunks/FilterEditorPanel-CRa0IpLr.js +26 -0
  51. package/dist/chunks/FlexDirectionInput-C5gYjk5W.js +78 -0
  52. package/dist/chunks/FloatingPanel-DJP5Vhua.js +553 -0
  53. package/dist/chunks/FontFamilyInput-CVNnVylt.js +111 -0
  54. package/dist/chunks/Form.render-6GjcmL2u.js +54 -0
  55. package/dist/chunks/FormElement.render-DWrG-2ID.js +36 -0
  56. package/dist/chunks/FormElementMainTab-DSbF3F6e.js +470 -0
  57. package/dist/chunks/FormMainTab-SHny1HxF.js +240 -0
  58. package/dist/chunks/GradientInputPopover-1K6O9jBq.js +103 -0
  59. package/dist/chunks/GradientPanel-DSRQKkaB.js +194 -0
  60. package/dist/chunks/HTMLCodeInput-CCe4Bj5z.js +69 -0
  61. package/dist/chunks/HandlerEditorPanel-DiOXobsl.js +93 -0
  62. package/dist/chunks/HandlersAddPicker-DWTgjKgo.js +101 -0
  63. package/dist/chunks/HandlersInput-p49STTn8.js +132 -0
  64. package/dist/chunks/IconDialogInput-C-81_L2n.js +105 -0
  65. package/dist/chunks/IconInput-D2Gy7Hvf.js +182 -0
  66. package/dist/chunks/IconMainTab-CNrVjDWP.js +26 -0
  67. package/dist/chunks/IconPickerPanel-BjNOlCh6.js +670 -0
  68. package/dist/chunks/ImageMainTab-C4O7RjX0.js +66 -0
  69. package/dist/chunks/ImageSettingsPanel-dvOmGg3C.js +485 -0
  70. package/dist/chunks/LayoutPresetPanel-CNAVAcvw.js +81 -0
  71. package/dist/chunks/LayoutPresetSlot-BqMTdE33.js +16 -0
  72. package/dist/chunks/LinkMainTab-BfFZx0AU.js +13 -0
  73. package/dist/chunks/ListEditor-mD-CmRNE.js +178 -0
  74. package/dist/chunks/Map.render-DFkmncHz.js +82 -0
  75. package/dist/chunks/MapLeaflet-DOfmZ3Pk.js +6588 -0
  76. package/dist/chunks/MapMainTab-CxI7IS1_.js +165 -0
  77. package/dist/chunks/MapPoint.render-0OAfCZTp.js +16 -0
  78. package/dist/chunks/MapPointMainTab-CmLcaSR5.js +60 -0
  79. package/dist/chunks/MediaInput-DHs3D8TJ.js +672 -0
  80. package/dist/chunks/MediaManagerModal-Dc5PK3dn.js +240 -0
  81. package/dist/chunks/MiniPreviewTile-B4zxTj9Y.js +32 -0
  82. package/dist/chunks/ModifierChipList-CwsWklih.js +33 -0
  83. package/dist/chunks/ModifiersAddPicker-D-vSYw7O.js +74 -0
  84. package/dist/chunks/ModifiersPickerPanel-CTefidBx.js +243 -0
  85. package/dist/chunks/NodeAiContextInputPopover-D5bn5o_T.js +66 -0
  86. package/dist/chunks/NodeAiContextPanel-Bx4rcjiM.js +81 -0
  87. package/dist/chunks/NumberSettingsPanel-DASi_l6V.js +56 -0
  88. package/dist/chunks/PageSettingsModal-D6o450IR.js +2678 -0
  89. package/dist/chunks/PatternInputPopover-qMWBv_nl.js +100 -0
  90. package/dist/chunks/PatternPanel-D2fgWDd-.js +352 -0
  91. package/dist/chunks/PeekTargetButton-ClrJX7zh.js +26 -0
  92. package/dist/chunks/PermissionsSection-DwobrV40.js +82 -0
  93. package/dist/chunks/PresetAddChildList-D6a0xdt8.js +35 -0
  94. package/dist/chunks/PropertiesInput-9O39ngbb.js +125 -0
  95. package/dist/chunks/PropertiesPanel-DO0RlalO.js +76 -0
  96. package/dist/chunks/SaveModifierPanel-B6mjKyrT.js +130 -0
  97. package/dist/chunks/ScrollEffectEditorPanel-CllGUhui.js +26 -0
  98. package/dist/chunks/SearchInput-DRUztbM0.js +76 -0
  99. package/dist/chunks/SearchableMenuPopover-DZKVXiEl.js +1251 -0
  100. package/dist/chunks/SlotRenderer-CaLf_2_C.js +38 -0
  101. package/dist/chunks/StateBindingEditorPanel-DKdcG5py.js +101 -0
  102. package/dist/chunks/StateBindingsAddPicker-DxMNAWAD.js +91 -0
  103. package/dist/chunks/StateBindingsInput-iWiqvAVB.js +103 -0
  104. package/dist/chunks/TailwindInput-660FZtyK.js +24 -0
  105. package/dist/chunks/TextEditor-B2O7DlN8.js +22032 -0
  106. package/dist/chunks/TextMainTab-B5udsXsk.js +260 -0
  107. package/dist/chunks/TextStyleEditorPanel-GRNPGzUL.js +381 -0
  108. package/dist/chunks/TextStylePickerPanel-l108SmGQ.js +140 -0
  109. package/dist/chunks/TextareaSettingsPanel-C1rQuF1O.js +50 -0
  110. package/dist/chunks/TokenPicker-Q0LToF_p.js +291 -0
  111. package/dist/chunks/ToolbarDashedButton-DbUxGmDg.js +23 -0
  112. package/dist/chunks/TransformEditorPanel-BGwyznZ6.js +26 -0
  113. package/dist/chunks/TransitionEditorPanel-BSvk58Ow.js +26 -0
  114. package/dist/chunks/TypographyPresetInput-DqnGSgR2.js +296 -0
  115. package/dist/chunks/ValidationPanel-CmA9SfoF.js +56 -0
  116. package/dist/chunks/Video.render-Dg6xvis4.js +21 -0
  117. package/dist/chunks/VideoMainTab-v5UFhUm-.js +174 -0
  118. package/dist/chunks/YouTube.esm-EbHnLU1Z.js +744 -0
  119. package/dist/chunks/dialogAtoms-CeQ2G05l.js +59 -0
  120. package/dist/chunks/extends-hS2Bh-Yp.js +12 -0
  121. package/dist/chunks/formatStorage-C3o2s3dk.js +22 -0
  122. package/dist/chunks/googleFonts-Dj4AntNi.js +323 -0
  123. package/dist/chunks/helpers-Cll72tMn.js +18 -0
  124. package/dist/chunks/index-B-GJd039.js +2875 -0
  125. package/dist/chunks/index-C66dAl3Q.js +32177 -0
  126. package/dist/chunks/index.esm-mqFx3NOs.js +644 -0
  127. package/dist/chunks/popoverOpenRequestAtom-hBS_siXv.js +22 -0
  128. package/dist/chunks/propertyRegistry-CMhVNOgl.js +38 -0
  129. package/dist/chunks/resolveAnchorsViaCraft-Cixm6ZyJ.js +31 -0
  130. package/dist/chunks/toolboxUtils-DjTMslSn.js +370 -0
  131. package/dist/chunks/uiPrimitives-BtohldWg.js +15 -0
  132. package/dist/chunks/use-event-listener-DO3Sk7g0.js +15 -0
  133. package/dist/chunks/useElementPicker-DoNuXNMQ.js +41 -0
  134. package/dist/chunks/useLayoutPreset-wOMV5YnO.js +528 -0
  135. package/dist/chunks/useMediaManager-CmKDbFfw.js +4629 -0
  136. package/dist/chunks/usePopoverAutoOpen-CxIjt0ez.js +25 -0
  137. package/dist/chunks/usePopoverPosition-83Vti7Aw.js +15 -0
  138. package/dist/render/static/index.js +9 -0
  139. package/package.json +22 -13
  140. package/dist/pagehub-viewer.umd.cjs +0 -574
  141. package/dist/pagehub.umd.cjs +0 -1130
@@ -0,0 +1,644 @@
1
+ import { _ as rt } from "./extends-hS2Bh-Yp.js";
2
+ import { createElement as q, PureComponent as nt } from "react";
3
+ function B(r) {
4
+ if (r === void 0) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
5
+ return r;
6
+ }
7
+ function X(r, t) {
8
+ return X = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(n, a) {
9
+ return n.__proto__ = a, n;
10
+ }, X(r, t);
11
+ }
12
+ function it(r, t) {
13
+ r.prototype = Object.create(t.prototype), r.prototype.constructor = r, X(r, t);
14
+ }
15
+ var et = Number.isNaN || function(t) {
16
+ return typeof t == "number" && t !== t;
17
+ };
18
+ function dt(r, t) {
19
+ return !!(r === t || et(r) && et(t));
20
+ }
21
+ function mt(r, t) {
22
+ if (r.length !== t.length)
23
+ return !1;
24
+ for (var n = 0; n < r.length; n++)
25
+ if (!dt(r[n], t[n]))
26
+ return !1;
27
+ return !0;
28
+ }
29
+ function K(r, t) {
30
+ t === void 0 && (t = mt);
31
+ var n, a = [], u, F = !1;
32
+ function b() {
33
+ for (var C = [], S = 0; S < arguments.length; S++)
34
+ C[S] = arguments[S];
35
+ return F && n === this && t(C, a) || (u = r.apply(this, C), F = !0, n = this, a = C), u;
36
+ }
37
+ return b;
38
+ }
39
+ var ft = typeof performance == "object" && typeof performance.now == "function", ot = ft ? function() {
40
+ return performance.now();
41
+ } : function() {
42
+ return Date.now();
43
+ };
44
+ function G(r) {
45
+ cancelAnimationFrame(r.id);
46
+ }
47
+ function lt(r, t) {
48
+ var n = ot();
49
+ function a() {
50
+ ot() - n >= t ? r.call(null) : u.id = requestAnimationFrame(a);
51
+ }
52
+ var u = {
53
+ id: requestAnimationFrame(a)
54
+ };
55
+ return u;
56
+ }
57
+ var Q = -1;
58
+ function Y(r) {
59
+ if (r === void 0 && (r = !1), Q === -1 || r) {
60
+ var t = document.createElement("div"), n = t.style;
61
+ n.width = "50px", n.height = "50px", n.overflow = "scroll", document.body.appendChild(t), Q = t.offsetWidth - t.clientWidth, document.body.removeChild(t);
62
+ }
63
+ return Q;
64
+ }
65
+ var $ = null;
66
+ function J(r) {
67
+ if (r === void 0 && (r = !1), $ === null || r) {
68
+ var t = document.createElement("div"), n = t.style;
69
+ n.width = "50px", n.height = "50px", n.overflow = "scroll", n.direction = "rtl";
70
+ var a = document.createElement("div"), u = a.style;
71
+ return u.width = "100px", u.height = "100px", t.appendChild(a), document.body.appendChild(t), t.scrollLeft > 0 ? $ = "positive-descending" : (t.scrollLeft = 1, t.scrollLeft === 0 ? $ = "negative" : $ = "positive-ascending"), document.body.removeChild(t), $;
72
+ }
73
+ return $;
74
+ }
75
+ var pt = 150, vt = function(t) {
76
+ var n = t.columnIndex;
77
+ t.data;
78
+ var a = t.rowIndex;
79
+ return a + ":" + n;
80
+ };
81
+ function gt(r) {
82
+ var t, n = r.getColumnOffset, a = r.getColumnStartIndexForOffset, u = r.getColumnStopIndexForStartIndex, F = r.getColumnWidth, b = r.getEstimatedTotalHeight, C = r.getEstimatedTotalWidth, S = r.getOffsetForColumnAndAlignment, z = r.getOffsetForRowAndAlignment, P = r.getRowHeight, x = r.getRowOffset, g = r.getRowStartIndexForOffset, O = r.getRowStopIndexForStartIndex, _ = r.initInstanceProps, o = r.shouldResetStyleCacheOnItemSizeChange, s = r.validateProps;
83
+ return t = /* @__PURE__ */ (function(c) {
84
+ it(m, c);
85
+ function m(v) {
86
+ var e;
87
+ return e = c.call(this, v) || this, e._instanceProps = _(e.props, B(e)), e._resetIsScrollingTimeoutId = null, e._outerRef = void 0, e.state = {
88
+ instance: B(e),
89
+ isScrolling: !1,
90
+ horizontalScrollDirection: "forward",
91
+ scrollLeft: typeof e.props.initialScrollLeft == "number" ? e.props.initialScrollLeft : 0,
92
+ scrollTop: typeof e.props.initialScrollTop == "number" ? e.props.initialScrollTop : 0,
93
+ scrollUpdateWasRequested: !1,
94
+ verticalScrollDirection: "forward"
95
+ }, e._callOnItemsRendered = void 0, e._callOnItemsRendered = K(function(l, i, h, p, d, I, T, M) {
96
+ return e.props.onItemsRendered({
97
+ overscanColumnStartIndex: l,
98
+ overscanColumnStopIndex: i,
99
+ overscanRowStartIndex: h,
100
+ overscanRowStopIndex: p,
101
+ visibleColumnStartIndex: d,
102
+ visibleColumnStopIndex: I,
103
+ visibleRowStartIndex: T,
104
+ visibleRowStopIndex: M
105
+ });
106
+ }), e._callOnScroll = void 0, e._callOnScroll = K(function(l, i, h, p, d) {
107
+ return e.props.onScroll({
108
+ horizontalScrollDirection: h,
109
+ scrollLeft: l,
110
+ scrollTop: i,
111
+ verticalScrollDirection: p,
112
+ scrollUpdateWasRequested: d
113
+ });
114
+ }), e._getItemStyle = void 0, e._getItemStyle = function(l, i) {
115
+ var h = e.props, p = h.columnWidth, d = h.direction, I = h.rowHeight, T = e._getItemStyleCache(o && p, o && d, o && I), M = l + ":" + i, y;
116
+ if (T.hasOwnProperty(M))
117
+ y = T[M];
118
+ else {
119
+ var R = n(e.props, i, e._instanceProps), w = d === "rtl";
120
+ T[M] = y = {
121
+ position: "absolute",
122
+ left: w ? void 0 : R,
123
+ right: w ? R : void 0,
124
+ top: x(e.props, l, e._instanceProps),
125
+ height: P(e.props, l, e._instanceProps),
126
+ width: F(e.props, i, e._instanceProps)
127
+ };
128
+ }
129
+ return y;
130
+ }, e._getItemStyleCache = void 0, e._getItemStyleCache = K(function(l, i, h) {
131
+ return {};
132
+ }), e._onScroll = function(l) {
133
+ var i = l.currentTarget, h = i.clientHeight, p = i.clientWidth, d = i.scrollLeft, I = i.scrollTop, T = i.scrollHeight, M = i.scrollWidth;
134
+ e.setState(function(y) {
135
+ if (y.scrollLeft === d && y.scrollTop === I)
136
+ return null;
137
+ var R = e.props.direction, w = d;
138
+ if (R === "rtl")
139
+ switch (J()) {
140
+ case "negative":
141
+ w = -d;
142
+ break;
143
+ case "positive-descending":
144
+ w = M - p - d;
145
+ break;
146
+ }
147
+ w = Math.max(0, Math.min(w, M - p));
148
+ var W = Math.max(0, Math.min(I, T - h));
149
+ return {
150
+ isScrolling: !0,
151
+ horizontalScrollDirection: y.scrollLeft < d ? "forward" : "backward",
152
+ scrollLeft: w,
153
+ scrollTop: W,
154
+ verticalScrollDirection: y.scrollTop < I ? "forward" : "backward",
155
+ scrollUpdateWasRequested: !1
156
+ };
157
+ }, e._resetIsScrollingDebounced);
158
+ }, e._outerRefSetter = function(l) {
159
+ var i = e.props.outerRef;
160
+ e._outerRef = l, typeof i == "function" ? i(l) : i != null && typeof i == "object" && i.hasOwnProperty("current") && (i.current = l);
161
+ }, e._resetIsScrollingDebounced = function() {
162
+ e._resetIsScrollingTimeoutId !== null && G(e._resetIsScrollingTimeoutId), e._resetIsScrollingTimeoutId = lt(e._resetIsScrolling, pt);
163
+ }, e._resetIsScrolling = function() {
164
+ e._resetIsScrollingTimeoutId = null, e.setState({
165
+ isScrolling: !1
166
+ }, function() {
167
+ e._getItemStyleCache(-1);
168
+ });
169
+ }, e;
170
+ }
171
+ m.getDerivedStateFromProps = function(e, l) {
172
+ return St(e, l), s(e), null;
173
+ };
174
+ var f = m.prototype;
175
+ return f.scrollTo = function(e) {
176
+ var l = e.scrollLeft, i = e.scrollTop;
177
+ l !== void 0 && (l = Math.max(0, l)), i !== void 0 && (i = Math.max(0, i)), this.setState(function(h) {
178
+ return l === void 0 && (l = h.scrollLeft), i === void 0 && (i = h.scrollTop), h.scrollLeft === l && h.scrollTop === i ? null : {
179
+ horizontalScrollDirection: h.scrollLeft < l ? "forward" : "backward",
180
+ scrollLeft: l,
181
+ scrollTop: i,
182
+ scrollUpdateWasRequested: !0,
183
+ verticalScrollDirection: h.scrollTop < i ? "forward" : "backward"
184
+ };
185
+ }, this._resetIsScrollingDebounced);
186
+ }, f.scrollToItem = function(e) {
187
+ var l = e.align, i = l === void 0 ? "auto" : l, h = e.columnIndex, p = e.rowIndex, d = this.props, I = d.columnCount, T = d.height, M = d.rowCount, y = d.width, R = this.state, w = R.scrollLeft, W = R.scrollTop, L = Y();
188
+ h !== void 0 && (h = Math.max(0, Math.min(h, I - 1))), p !== void 0 && (p = Math.max(0, Math.min(p, M - 1)));
189
+ var H = b(this.props, this._instanceProps), D = C(this.props, this._instanceProps), E = D > y ? L : 0, A = H > T ? L : 0;
190
+ this.scrollTo({
191
+ scrollLeft: h !== void 0 ? S(this.props, h, i, w, this._instanceProps, A) : w,
192
+ scrollTop: p !== void 0 ? z(this.props, p, i, W, this._instanceProps, E) : W
193
+ });
194
+ }, f.componentDidMount = function() {
195
+ var e = this.props, l = e.initialScrollLeft, i = e.initialScrollTop;
196
+ if (this._outerRef != null) {
197
+ var h = this._outerRef;
198
+ typeof l == "number" && (h.scrollLeft = l), typeof i == "number" && (h.scrollTop = i);
199
+ }
200
+ this._callPropsCallbacks();
201
+ }, f.componentDidUpdate = function() {
202
+ var e = this.props.direction, l = this.state, i = l.scrollLeft, h = l.scrollTop, p = l.scrollUpdateWasRequested;
203
+ if (p && this._outerRef != null) {
204
+ var d = this._outerRef;
205
+ if (e === "rtl")
206
+ switch (J()) {
207
+ case "negative":
208
+ d.scrollLeft = -i;
209
+ break;
210
+ case "positive-ascending":
211
+ d.scrollLeft = i;
212
+ break;
213
+ default:
214
+ var I = d.clientWidth, T = d.scrollWidth;
215
+ d.scrollLeft = T - I - i;
216
+ break;
217
+ }
218
+ else
219
+ d.scrollLeft = Math.max(0, i);
220
+ d.scrollTop = Math.max(0, h);
221
+ }
222
+ this._callPropsCallbacks();
223
+ }, f.componentWillUnmount = function() {
224
+ this._resetIsScrollingTimeoutId !== null && G(this._resetIsScrollingTimeoutId);
225
+ }, f.render = function() {
226
+ var e = this.props, l = e.children, i = e.className, h = e.columnCount, p = e.direction, d = e.height, I = e.innerRef, T = e.innerElementType, M = e.innerTagName, y = e.itemData, R = e.itemKey, w = R === void 0 ? vt : R, W = e.outerElementType, L = e.outerTagName, H = e.rowCount, D = e.style, E = e.useIsScrolling, A = e.width, N = this.state.isScrolling, k = this._getHorizontalRangeToRender(), U = k[0], at = k[1], Z = this._getVerticalRangeToRender(), st = Z[0], ct = Z[1], tt = [];
227
+ if (h > 0 && H)
228
+ for (var V = st; V <= ct; V++)
229
+ for (var j = U; j <= at; j++)
230
+ tt.push(q(l, {
231
+ columnIndex: j,
232
+ data: y,
233
+ isScrolling: E ? N : void 0,
234
+ key: w({
235
+ columnIndex: j,
236
+ data: y,
237
+ rowIndex: V
238
+ }),
239
+ rowIndex: V,
240
+ style: this._getItemStyle(V, j)
241
+ }));
242
+ var ut = b(this.props, this._instanceProps), ht = C(this.props, this._instanceProps);
243
+ return q(W || L || "div", {
244
+ className: i,
245
+ onScroll: this._onScroll,
246
+ ref: this._outerRefSetter,
247
+ style: rt({
248
+ position: "relative",
249
+ height: d,
250
+ width: A,
251
+ overflow: "auto",
252
+ WebkitOverflowScrolling: "touch",
253
+ willChange: "transform",
254
+ direction: p
255
+ }, D)
256
+ }, q(T || M || "div", {
257
+ children: tt,
258
+ ref: I,
259
+ style: {
260
+ height: ut,
261
+ pointerEvents: N ? "none" : void 0,
262
+ width: ht
263
+ }
264
+ }));
265
+ }, f._callPropsCallbacks = function() {
266
+ var e = this.props, l = e.columnCount, i = e.onItemsRendered, h = e.onScroll, p = e.rowCount;
267
+ if (typeof i == "function" && l > 0 && p > 0) {
268
+ var d = this._getHorizontalRangeToRender(), I = d[0], T = d[1], M = d[2], y = d[3], R = this._getVerticalRangeToRender(), w = R[0], W = R[1], L = R[2], H = R[3];
269
+ this._callOnItemsRendered(I, T, w, W, M, y, L, H);
270
+ }
271
+ if (typeof h == "function") {
272
+ var D = this.state, E = D.horizontalScrollDirection, A = D.scrollLeft, N = D.scrollTop, k = D.scrollUpdateWasRequested, U = D.verticalScrollDirection;
273
+ this._callOnScroll(A, N, E, U, k);
274
+ }
275
+ }, f._getHorizontalRangeToRender = function() {
276
+ var e = this.props, l = e.columnCount, i = e.overscanColumnCount, h = e.overscanColumnsCount, p = e.overscanCount, d = e.rowCount, I = this.state, T = I.horizontalScrollDirection, M = I.isScrolling, y = I.scrollLeft, R = i || h || p || 1;
277
+ if (l === 0 || d === 0)
278
+ return [0, 0, 0, 0];
279
+ var w = a(this.props, y, this._instanceProps), W = u(this.props, w, y, this._instanceProps), L = !M || T === "backward" ? Math.max(1, R) : 1, H = !M || T === "forward" ? Math.max(1, R) : 1;
280
+ return [Math.max(0, w - L), Math.max(0, Math.min(l - 1, W + H)), w, W];
281
+ }, f._getVerticalRangeToRender = function() {
282
+ var e = this.props, l = e.columnCount, i = e.overscanCount, h = e.overscanRowCount, p = e.overscanRowsCount, d = e.rowCount, I = this.state, T = I.isScrolling, M = I.verticalScrollDirection, y = I.scrollTop, R = h || p || i || 1;
283
+ if (l === 0 || d === 0)
284
+ return [0, 0, 0, 0];
285
+ var w = g(this.props, y, this._instanceProps), W = O(this.props, w, y, this._instanceProps), L = !T || M === "backward" ? Math.max(1, R) : 1, H = !T || M === "forward" ? Math.max(1, R) : 1;
286
+ return [Math.max(0, w - L), Math.max(0, Math.min(d - 1, W + H)), w, W];
287
+ }, m;
288
+ })(nt), t.defaultProps = {
289
+ direction: "ltr",
290
+ itemData: void 0,
291
+ useIsScrolling: !1
292
+ }, t;
293
+ }
294
+ var St = function(t, n) {
295
+ t.children, t.direction, t.height, t.innerTagName, t.outerTagName, t.overscanColumnsCount, t.overscanCount, t.overscanRowsCount, t.width, n.instance;
296
+ }, It = 150, Ct = function(t, n) {
297
+ return t;
298
+ };
299
+ function wt(r) {
300
+ var t, n = r.getItemOffset, a = r.getEstimatedTotalSize, u = r.getItemSize, F = r.getOffsetForIndexAndAlignment, b = r.getStartIndexForOffset, C = r.getStopIndexForStartIndex, S = r.initInstanceProps, z = r.shouldResetStyleCacheOnItemSizeChange, P = r.validateProps;
301
+ return t = /* @__PURE__ */ (function(x) {
302
+ it(g, x);
303
+ function g(_) {
304
+ var o;
305
+ return o = x.call(this, _) || this, o._instanceProps = S(o.props, B(o)), o._outerRef = void 0, o._resetIsScrollingTimeoutId = null, o.state = {
306
+ instance: B(o),
307
+ isScrolling: !1,
308
+ scrollDirection: "forward",
309
+ scrollOffset: typeof o.props.initialScrollOffset == "number" ? o.props.initialScrollOffset : 0,
310
+ scrollUpdateWasRequested: !1
311
+ }, o._callOnItemsRendered = void 0, o._callOnItemsRendered = K(function(s, c, m, f) {
312
+ return o.props.onItemsRendered({
313
+ overscanStartIndex: s,
314
+ overscanStopIndex: c,
315
+ visibleStartIndex: m,
316
+ visibleStopIndex: f
317
+ });
318
+ }), o._callOnScroll = void 0, o._callOnScroll = K(function(s, c, m) {
319
+ return o.props.onScroll({
320
+ scrollDirection: s,
321
+ scrollOffset: c,
322
+ scrollUpdateWasRequested: m
323
+ });
324
+ }), o._getItemStyle = void 0, o._getItemStyle = function(s) {
325
+ var c = o.props, m = c.direction, f = c.itemSize, v = c.layout, e = o._getItemStyleCache(z && f, z && v, z && m), l;
326
+ if (e.hasOwnProperty(s))
327
+ l = e[s];
328
+ else {
329
+ var i = n(o.props, s, o._instanceProps), h = u(o.props, s, o._instanceProps), p = m === "horizontal" || v === "horizontal", d = m === "rtl", I = p ? i : 0;
330
+ e[s] = l = {
331
+ position: "absolute",
332
+ left: d ? void 0 : I,
333
+ right: d ? I : void 0,
334
+ top: p ? 0 : i,
335
+ height: p ? "100%" : h,
336
+ width: p ? h : "100%"
337
+ };
338
+ }
339
+ return l;
340
+ }, o._getItemStyleCache = void 0, o._getItemStyleCache = K(function(s, c, m) {
341
+ return {};
342
+ }), o._onScrollHorizontal = function(s) {
343
+ var c = s.currentTarget, m = c.clientWidth, f = c.scrollLeft, v = c.scrollWidth;
344
+ o.setState(function(e) {
345
+ if (e.scrollOffset === f)
346
+ return null;
347
+ var l = o.props.direction, i = f;
348
+ if (l === "rtl")
349
+ switch (J()) {
350
+ case "negative":
351
+ i = -f;
352
+ break;
353
+ case "positive-descending":
354
+ i = v - m - f;
355
+ break;
356
+ }
357
+ return i = Math.max(0, Math.min(i, v - m)), {
358
+ isScrolling: !0,
359
+ scrollDirection: e.scrollOffset < i ? "forward" : "backward",
360
+ scrollOffset: i,
361
+ scrollUpdateWasRequested: !1
362
+ };
363
+ }, o._resetIsScrollingDebounced);
364
+ }, o._onScrollVertical = function(s) {
365
+ var c = s.currentTarget, m = c.clientHeight, f = c.scrollHeight, v = c.scrollTop;
366
+ o.setState(function(e) {
367
+ if (e.scrollOffset === v)
368
+ return null;
369
+ var l = Math.max(0, Math.min(v, f - m));
370
+ return {
371
+ isScrolling: !0,
372
+ scrollDirection: e.scrollOffset < l ? "forward" : "backward",
373
+ scrollOffset: l,
374
+ scrollUpdateWasRequested: !1
375
+ };
376
+ }, o._resetIsScrollingDebounced);
377
+ }, o._outerRefSetter = function(s) {
378
+ var c = o.props.outerRef;
379
+ o._outerRef = s, typeof c == "function" ? c(s) : c != null && typeof c == "object" && c.hasOwnProperty("current") && (c.current = s);
380
+ }, o._resetIsScrollingDebounced = function() {
381
+ o._resetIsScrollingTimeoutId !== null && G(o._resetIsScrollingTimeoutId), o._resetIsScrollingTimeoutId = lt(o._resetIsScrolling, It);
382
+ }, o._resetIsScrolling = function() {
383
+ o._resetIsScrollingTimeoutId = null, o.setState({
384
+ isScrolling: !1
385
+ }, function() {
386
+ o._getItemStyleCache(-1, null);
387
+ });
388
+ }, o;
389
+ }
390
+ g.getDerivedStateFromProps = function(o, s) {
391
+ return Tt(o, s), P(o), null;
392
+ };
393
+ var O = g.prototype;
394
+ return O.scrollTo = function(o) {
395
+ o = Math.max(0, o), this.setState(function(s) {
396
+ return s.scrollOffset === o ? null : {
397
+ scrollDirection: s.scrollOffset < o ? "forward" : "backward",
398
+ scrollOffset: o,
399
+ scrollUpdateWasRequested: !0
400
+ };
401
+ }, this._resetIsScrollingDebounced);
402
+ }, O.scrollToItem = function(o, s) {
403
+ s === void 0 && (s = "auto");
404
+ var c = this.props, m = c.itemCount, f = c.layout, v = this.state.scrollOffset;
405
+ o = Math.max(0, Math.min(o, m - 1));
406
+ var e = 0;
407
+ if (this._outerRef) {
408
+ var l = this._outerRef;
409
+ f === "vertical" ? e = l.scrollWidth > l.clientWidth ? Y() : 0 : e = l.scrollHeight > l.clientHeight ? Y() : 0;
410
+ }
411
+ this.scrollTo(F(this.props, o, s, v, this._instanceProps, e));
412
+ }, O.componentDidMount = function() {
413
+ var o = this.props, s = o.direction, c = o.initialScrollOffset, m = o.layout;
414
+ if (typeof c == "number" && this._outerRef != null) {
415
+ var f = this._outerRef;
416
+ s === "horizontal" || m === "horizontal" ? f.scrollLeft = c : f.scrollTop = c;
417
+ }
418
+ this._callPropsCallbacks();
419
+ }, O.componentDidUpdate = function() {
420
+ var o = this.props, s = o.direction, c = o.layout, m = this.state, f = m.scrollOffset, v = m.scrollUpdateWasRequested;
421
+ if (v && this._outerRef != null) {
422
+ var e = this._outerRef;
423
+ if (s === "horizontal" || c === "horizontal")
424
+ if (s === "rtl")
425
+ switch (J()) {
426
+ case "negative":
427
+ e.scrollLeft = -f;
428
+ break;
429
+ case "positive-ascending":
430
+ e.scrollLeft = f;
431
+ break;
432
+ default:
433
+ var l = e.clientWidth, i = e.scrollWidth;
434
+ e.scrollLeft = i - l - f;
435
+ break;
436
+ }
437
+ else
438
+ e.scrollLeft = f;
439
+ else
440
+ e.scrollTop = f;
441
+ }
442
+ this._callPropsCallbacks();
443
+ }, O.componentWillUnmount = function() {
444
+ this._resetIsScrollingTimeoutId !== null && G(this._resetIsScrollingTimeoutId);
445
+ }, O.render = function() {
446
+ var o = this.props, s = o.children, c = o.className, m = o.direction, f = o.height, v = o.innerRef, e = o.innerElementType, l = o.innerTagName, i = o.itemCount, h = o.itemData, p = o.itemKey, d = p === void 0 ? Ct : p, I = o.layout, T = o.outerElementType, M = o.outerTagName, y = o.style, R = o.useIsScrolling, w = o.width, W = this.state.isScrolling, L = m === "horizontal" || I === "horizontal", H = L ? this._onScrollHorizontal : this._onScrollVertical, D = this._getRangeToRender(), E = D[0], A = D[1], N = [];
447
+ if (i > 0)
448
+ for (var k = E; k <= A; k++)
449
+ N.push(q(s, {
450
+ data: h,
451
+ key: d(k, h),
452
+ index: k,
453
+ isScrolling: R ? W : void 0,
454
+ style: this._getItemStyle(k)
455
+ }));
456
+ var U = a(this.props, this._instanceProps);
457
+ return q(T || M || "div", {
458
+ className: c,
459
+ onScroll: H,
460
+ ref: this._outerRefSetter,
461
+ style: rt({
462
+ position: "relative",
463
+ height: f,
464
+ width: w,
465
+ overflow: "auto",
466
+ WebkitOverflowScrolling: "touch",
467
+ willChange: "transform",
468
+ direction: m
469
+ }, y)
470
+ }, q(e || l || "div", {
471
+ children: N,
472
+ ref: v,
473
+ style: {
474
+ height: L ? "100%" : U,
475
+ pointerEvents: W ? "none" : void 0,
476
+ width: L ? U : "100%"
477
+ }
478
+ }));
479
+ }, O._callPropsCallbacks = function() {
480
+ if (typeof this.props.onItemsRendered == "function") {
481
+ var o = this.props.itemCount;
482
+ if (o > 0) {
483
+ var s = this._getRangeToRender(), c = s[0], m = s[1], f = s[2], v = s[3];
484
+ this._callOnItemsRendered(c, m, f, v);
485
+ }
486
+ }
487
+ if (typeof this.props.onScroll == "function") {
488
+ var e = this.state, l = e.scrollDirection, i = e.scrollOffset, h = e.scrollUpdateWasRequested;
489
+ this._callOnScroll(l, i, h);
490
+ }
491
+ }, O._getRangeToRender = function() {
492
+ var o = this.props, s = o.itemCount, c = o.overscanCount, m = this.state, f = m.isScrolling, v = m.scrollDirection, e = m.scrollOffset;
493
+ if (s === 0)
494
+ return [0, 0, 0, 0];
495
+ var l = b(this.props, e, this._instanceProps), i = C(this.props, l, e, this._instanceProps), h = !f || v === "backward" ? Math.max(1, c) : 1, p = !f || v === "forward" ? Math.max(1, c) : 1;
496
+ return [Math.max(0, l - h), Math.max(0, Math.min(s - 1, i + p)), l, i];
497
+ }, g;
498
+ })(nt), t.defaultProps = {
499
+ direction: "ltr",
500
+ itemData: void 0,
501
+ layout: "vertical",
502
+ overscanCount: 2,
503
+ useIsScrolling: !1
504
+ }, t;
505
+ }
506
+ var Tt = function(t, n) {
507
+ t.children, t.direction, t.height, t.layout, t.innerTagName, t.outerTagName, t.width, n.instance;
508
+ }, xt = /* @__PURE__ */ gt({
509
+ getColumnOffset: function(t, n) {
510
+ var a = t.columnWidth;
511
+ return n * a;
512
+ },
513
+ getColumnWidth: function(t, n) {
514
+ var a = t.columnWidth;
515
+ return a;
516
+ },
517
+ getRowOffset: function(t, n) {
518
+ var a = t.rowHeight;
519
+ return n * a;
520
+ },
521
+ getRowHeight: function(t, n) {
522
+ var a = t.rowHeight;
523
+ return a;
524
+ },
525
+ getEstimatedTotalHeight: function(t) {
526
+ var n = t.rowCount, a = t.rowHeight;
527
+ return a * n;
528
+ },
529
+ getEstimatedTotalWidth: function(t) {
530
+ var n = t.columnCount, a = t.columnWidth;
531
+ return a * n;
532
+ },
533
+ getOffsetForColumnAndAlignment: function(t, n, a, u, F, b) {
534
+ var C = t.columnCount, S = t.columnWidth, z = t.width, P = Math.max(0, C * S - z), x = Math.min(P, n * S), g = Math.max(0, n * S - z + b + S);
535
+ switch (a === "smart" && (u >= g - z && u <= x + z ? a = "auto" : a = "center"), a) {
536
+ case "start":
537
+ return x;
538
+ case "end":
539
+ return g;
540
+ case "center":
541
+ var O = Math.round(g + (x - g) / 2);
542
+ return O < Math.ceil(z / 2) ? 0 : O > P + Math.floor(z / 2) ? P : O;
543
+ case "auto":
544
+ default:
545
+ return u >= g && u <= x ? u : g > x || u < g ? g : x;
546
+ }
547
+ },
548
+ getOffsetForRowAndAlignment: function(t, n, a, u, F, b) {
549
+ var C = t.rowHeight, S = t.height, z = t.rowCount, P = Math.max(0, z * C - S), x = Math.min(P, n * C), g = Math.max(0, n * C - S + b + C);
550
+ switch (a === "smart" && (u >= g - S && u <= x + S ? a = "auto" : a = "center"), a) {
551
+ case "start":
552
+ return x;
553
+ case "end":
554
+ return g;
555
+ case "center":
556
+ var O = Math.round(g + (x - g) / 2);
557
+ return O < Math.ceil(S / 2) ? 0 : O > P + Math.floor(S / 2) ? P : O;
558
+ case "auto":
559
+ default:
560
+ return u >= g && u <= x ? u : g > x || u < g ? g : x;
561
+ }
562
+ },
563
+ getColumnStartIndexForOffset: function(t, n) {
564
+ var a = t.columnWidth, u = t.columnCount;
565
+ return Math.max(0, Math.min(u - 1, Math.floor(n / a)));
566
+ },
567
+ getColumnStopIndexForStartIndex: function(t, n, a) {
568
+ var u = t.columnWidth, F = t.columnCount, b = t.width, C = n * u, S = Math.ceil((b + a - C) / u);
569
+ return Math.max(0, Math.min(
570
+ F - 1,
571
+ n + S - 1
572
+ // -1 is because stop index is inclusive
573
+ ));
574
+ },
575
+ getRowStartIndexForOffset: function(t, n) {
576
+ var a = t.rowHeight, u = t.rowCount;
577
+ return Math.max(0, Math.min(u - 1, Math.floor(n / a)));
578
+ },
579
+ getRowStopIndexForStartIndex: function(t, n, a) {
580
+ var u = t.rowHeight, F = t.rowCount, b = t.height, C = n * u, S = Math.ceil((b + a - C) / u);
581
+ return Math.max(0, Math.min(
582
+ F - 1,
583
+ n + S - 1
584
+ // -1 is because stop index is inclusive
585
+ ));
586
+ },
587
+ initInstanceProps: function(t) {
588
+ },
589
+ shouldResetStyleCacheOnItemSizeChange: !0,
590
+ validateProps: function(t) {
591
+ t.columnWidth, t.rowHeight;
592
+ }
593
+ }), Ot = /* @__PURE__ */ wt({
594
+ getItemOffset: function(t, n) {
595
+ var a = t.itemSize;
596
+ return n * a;
597
+ },
598
+ getItemSize: function(t, n) {
599
+ var a = t.itemSize;
600
+ return a;
601
+ },
602
+ getEstimatedTotalSize: function(t) {
603
+ var n = t.itemCount, a = t.itemSize;
604
+ return a * n;
605
+ },
606
+ getOffsetForIndexAndAlignment: function(t, n, a, u, F, b) {
607
+ var C = t.direction, S = t.height, z = t.itemCount, P = t.itemSize, x = t.layout, g = t.width, O = C === "horizontal" || x === "horizontal", _ = O ? g : S, o = Math.max(0, z * P - _), s = Math.min(o, n * P), c = Math.max(0, n * P - _ + P + b);
608
+ switch (a === "smart" && (u >= c - _ && u <= s + _ ? a = "auto" : a = "center"), a) {
609
+ case "start":
610
+ return s;
611
+ case "end":
612
+ return c;
613
+ case "center": {
614
+ var m = Math.round(c + (s - c) / 2);
615
+ return m < Math.ceil(_ / 2) ? 0 : m > o + Math.floor(_ / 2) ? o : m;
616
+ }
617
+ case "auto":
618
+ default:
619
+ return u >= c && u <= s ? u : u < c ? c : s;
620
+ }
621
+ },
622
+ getStartIndexForOffset: function(t, n) {
623
+ var a = t.itemCount, u = t.itemSize;
624
+ return Math.max(0, Math.min(a - 1, Math.floor(n / u)));
625
+ },
626
+ getStopIndexForStartIndex: function(t, n, a) {
627
+ var u = t.direction, F = t.height, b = t.itemCount, C = t.itemSize, S = t.layout, z = t.width, P = u === "horizontal" || S === "horizontal", x = n * C, g = P ? z : F, O = Math.ceil((g + a - x) / C);
628
+ return Math.max(0, Math.min(
629
+ b - 1,
630
+ n + O - 1
631
+ // -1 is because stop index is inclusive
632
+ ));
633
+ },
634
+ initInstanceProps: function(t) {
635
+ },
636
+ shouldResetStyleCacheOnItemSizeChange: !0,
637
+ validateProps: function(t) {
638
+ t.itemSize;
639
+ }
640
+ });
641
+ export {
642
+ Ot as F,
643
+ xt as a
644
+ };
@@ -0,0 +1,22 @@
1
+ import { useRef as u, useEffect as a } from "react";
2
+ import { aE as f, u as i } from "./index-C66dAl3Q.js";
3
+ const R = f(
4
+ "settingsPopoverOpenRequest",
5
+ () => /* @__PURE__ */ new Map()
6
+ ), c = (t, o) => `${t}:${o}`;
7
+ function q(t, o, n, r) {
8
+ const e = c(n, r), s = new Map(t);
9
+ s.set(e, (t.get(e) || 0) + 1), o(s);
10
+ }
11
+ function P(t, o, n) {
12
+ const e = i(R).get(c(t, o)) || 0, s = u(0), p = u(n);
13
+ p.current = n, a(() => {
14
+ e === 0 || e === s.current || (s.current = e, p.current());
15
+ }, [e]);
16
+ }
17
+ export {
18
+ R as P,
19
+ c as p,
20
+ q as r,
21
+ P as u
22
+ };