@hortiview/shared-components 0.0.4529 → 0.0.4540

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 (30) hide show
  1. package/dist/{ListAreaService-BPp_O2BH.js → ListAreaService-CFOmATRF.js} +17 -16
  2. package/dist/SearchBar-CY2zfu6B.js +3232 -0
  3. package/dist/assets/main.css +22 -0
  4. package/dist/component-D1YrRAXe.js +673 -0
  5. package/dist/components/BaseView/BaseView.d.ts +5 -1
  6. package/dist/components/BaseView/BaseView.js +300 -44
  7. package/dist/components/BaseView/BaseView.test.js +1 -1
  8. package/dist/components/BasicHeading/BasicHeading.js +27 -26
  9. package/dist/components/BasicHeading/BasicHeading.test.js +333 -32
  10. package/dist/components/BlockView/BlockView.js +17 -17
  11. package/dist/components/EmptyView/EmptyView.js +247 -8
  12. package/dist/components/HashTabView/HashTabView.js +1845 -59
  13. package/dist/components/Iconify/Iconify.js +1 -1
  14. package/dist/components/ListArea/ListArea.js +5326 -755
  15. package/dist/components/ListArea/ListArea.test.js +2 -2
  16. package/dist/components/ListArea/ListAreaService.js +5 -4
  17. package/dist/components/SearchBar/SearchBar.js +3 -31
  18. package/dist/components/SearchBar/SearchBar.test.js +1 -1
  19. package/dist/hooks/useBreakpoint.js +2 -2
  20. package/dist/index.es-BD4kFWFx.js +673 -0
  21. package/dist/index.es-CUWXKh7P.js +106 -0
  22. package/dist/index.es-Cv6meSAn.js +1067 -0
  23. package/dist/index.es-DYsXox--.js +151 -0
  24. package/dist/index.es-WZ1mqvGz.js +1769 -0
  25. package/dist/index.es-mBp_Btvi.js +45 -0
  26. package/dist/main.d.ts +1 -0
  27. package/dist/main.js +23 -22
  28. package/dist/tslib.es6-BOWp4lfV.js +72 -0
  29. package/dist/{useBreakpoint-DyAmuka7.js → useBreakpoint-DROHPVxO.js} +2 -2
  30. package/package.json +1 -1
@@ -0,0 +1,673 @@
1
+ import { a as b, b as I, c as T, _ as v } from "./tslib.es6-BOWp4lfV.js";
2
+ /**
3
+ * @license
4
+ * Copyright 2016 Google Inc.
5
+ *
6
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
7
+ * of this software and associated documentation files (the "Software"), to deal
8
+ * in the Software without restriction, including without limitation the rights
9
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10
+ * copies of the Software, and to permit persons to whom the Software is
11
+ * furnished to do so, subject to the following conditions:
12
+ *
13
+ * The above copyright notice and this permission notice shall be included in
14
+ * all copies or substantial portions of the Software.
15
+ *
16
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
21
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
22
+ * THE SOFTWARE.
23
+ */
24
+ var E = (
25
+ /** @class */
26
+ function() {
27
+ function a(i) {
28
+ i === void 0 && (i = {}), this.adapter = i;
29
+ }
30
+ return Object.defineProperty(a, "cssClasses", {
31
+ get: function() {
32
+ return {};
33
+ },
34
+ enumerable: !1,
35
+ configurable: !0
36
+ }), Object.defineProperty(a, "strings", {
37
+ get: function() {
38
+ return {};
39
+ },
40
+ enumerable: !1,
41
+ configurable: !0
42
+ }), Object.defineProperty(a, "numbers", {
43
+ get: function() {
44
+ return {};
45
+ },
46
+ enumerable: !1,
47
+ configurable: !0
48
+ }), Object.defineProperty(a, "defaultAdapter", {
49
+ get: function() {
50
+ return {};
51
+ },
52
+ enumerable: !1,
53
+ configurable: !0
54
+ }), a.prototype.init = function() {
55
+ }, a.prototype.destroy = function() {
56
+ }, a;
57
+ }()
58
+ );
59
+ /**
60
+ * @license
61
+ * Copyright 2016 Google Inc.
62
+ *
63
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
64
+ * of this software and associated documentation files (the "Software"), to deal
65
+ * in the Software without restriction, including without limitation the rights
66
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
67
+ * copies of the Software, and to permit persons to whom the Software is
68
+ * furnished to do so, subject to the following conditions:
69
+ *
70
+ * The above copyright notice and this permission notice shall be included in
71
+ * all copies or substantial portions of the Software.
72
+ *
73
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
74
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
75
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
76
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
77
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
78
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
79
+ * THE SOFTWARE.
80
+ */
81
+ var D = (
82
+ /** @class */
83
+ function() {
84
+ function a(i, t) {
85
+ for (var e = [], n = 2; n < arguments.length; n++)
86
+ e[n - 2] = arguments[n];
87
+ this.root = i, this.initialize.apply(this, b([], I(e))), this.foundation = t === void 0 ? this.getDefaultFoundation() : t, this.foundation.init(), this.initialSyncWithDOM();
88
+ }
89
+ return a.attachTo = function(i) {
90
+ return new a(i, new E({}));
91
+ }, a.prototype.initialize = function() {
92
+ }, a.prototype.getDefaultFoundation = function() {
93
+ throw new Error("Subclasses must override getDefaultFoundation to return a properly configured foundation class");
94
+ }, a.prototype.initialSyncWithDOM = function() {
95
+ }, a.prototype.destroy = function() {
96
+ this.foundation.destroy();
97
+ }, a.prototype.listen = function(i, t, e) {
98
+ this.root.addEventListener(i, t, e);
99
+ }, a.prototype.unlisten = function(i, t, e) {
100
+ this.root.removeEventListener(i, t, e);
101
+ }, a.prototype.emit = function(i, t, e) {
102
+ e === void 0 && (e = !1);
103
+ var n;
104
+ typeof CustomEvent == "function" ? n = new CustomEvent(i, {
105
+ bubbles: e,
106
+ detail: t
107
+ }) : (n = document.createEvent("CustomEvent"), n.initCustomEvent(i, e, !1, t)), this.root.dispatchEvent(n);
108
+ }, a;
109
+ }()
110
+ );
111
+ /**
112
+ * @license
113
+ * Copyright 2018 Google Inc.
114
+ *
115
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
116
+ * of this software and associated documentation files (the "Software"), to deal
117
+ * in the Software without restriction, including without limitation the rights
118
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
119
+ * copies of the Software, and to permit persons to whom the Software is
120
+ * furnished to do so, subject to the following conditions:
121
+ *
122
+ * The above copyright notice and this permission notice shall be included in
123
+ * all copies or substantial portions of the Software.
124
+ *
125
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
126
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
127
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
128
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
129
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
130
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
131
+ * THE SOFTWARE.
132
+ */
133
+ function P(a, i) {
134
+ if (a.closest)
135
+ return a.closest(i);
136
+ for (var t = a; t; ) {
137
+ if (S(t, i))
138
+ return t;
139
+ t = t.parentElement;
140
+ }
141
+ return null;
142
+ }
143
+ function S(a, i) {
144
+ var t = a.matches || a.webkitMatchesSelector || a.msMatchesSelector;
145
+ return t.call(a, i);
146
+ }
147
+ function M(a) {
148
+ var i = a;
149
+ if (i.offsetParent !== null)
150
+ return i.scrollWidth;
151
+ var t = i.cloneNode(!0);
152
+ t.style.setProperty("position", "absolute"), t.style.setProperty("transform", "translate(-9999px, -9999px)"), document.documentElement.appendChild(t);
153
+ var e = t.scrollWidth;
154
+ return document.documentElement.removeChild(t), e;
155
+ }
156
+ /**
157
+ * @license
158
+ * Copyright 2019 Google Inc.
159
+ *
160
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
161
+ * of this software and associated documentation files (the "Software"), to deal
162
+ * in the Software without restriction, including without limitation the rights
163
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
164
+ * copies of the Software, and to permit persons to whom the Software is
165
+ * furnished to do so, subject to the following conditions:
166
+ *
167
+ * The above copyright notice and this permission notice shall be included in
168
+ * all copies or substantial portions of the Software.
169
+ *
170
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
171
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
172
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
173
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
174
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
175
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
176
+ * THE SOFTWARE.
177
+ */
178
+ function f(a) {
179
+ return a === void 0 && (a = window), R(a) ? { passive: !0 } : !1;
180
+ }
181
+ function R(a) {
182
+ a === void 0 && (a = window);
183
+ var i = !1;
184
+ try {
185
+ var t = {
186
+ // This function will be called when the browser
187
+ // attempts to access the passive property.
188
+ get passive() {
189
+ return i = !0, !1;
190
+ }
191
+ }, e = function() {
192
+ };
193
+ a.document.addEventListener("test", e, t), a.document.removeEventListener("test", e, t);
194
+ } catch {
195
+ i = !1;
196
+ }
197
+ return i;
198
+ }
199
+ /**
200
+ * @license
201
+ * Copyright 2016 Google Inc.
202
+ *
203
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
204
+ * of this software and associated documentation files (the "Software"), to deal
205
+ * in the Software without restriction, including without limitation the rights
206
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
207
+ * copies of the Software, and to permit persons to whom the Software is
208
+ * furnished to do so, subject to the following conditions:
209
+ *
210
+ * The above copyright notice and this permission notice shall be included in
211
+ * all copies or substantial portions of the Software.
212
+ *
213
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
214
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
215
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
216
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
217
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
218
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
219
+ * THE SOFTWARE.
220
+ */
221
+ var w = {
222
+ // Ripple is a special case where the "root" component is really a "mixin" of sorts,
223
+ // given that it's an 'upgrade' to an existing component. That being said it is the root
224
+ // CSS class that all other CSS classes derive from.
225
+ BG_FOCUSED: "mdc-ripple-upgraded--background-focused",
226
+ FG_ACTIVATION: "mdc-ripple-upgraded--foreground-activation",
227
+ FG_DEACTIVATION: "mdc-ripple-upgraded--foreground-deactivation",
228
+ ROOT: "mdc-ripple-upgraded",
229
+ UNBOUNDED: "mdc-ripple-upgraded--unbounded"
230
+ }, F = {
231
+ VAR_FG_SCALE: "--mdc-ripple-fg-scale",
232
+ VAR_FG_SIZE: "--mdc-ripple-fg-size",
233
+ VAR_FG_TRANSLATE_END: "--mdc-ripple-fg-translate-end",
234
+ VAR_FG_TRANSLATE_START: "--mdc-ripple-fg-translate-start",
235
+ VAR_LEFT: "--mdc-ripple-left",
236
+ VAR_TOP: "--mdc-ripple-top"
237
+ }, g = {
238
+ DEACTIVATION_TIMEOUT_MS: 225,
239
+ FG_DEACTIVATION_MS: 150,
240
+ INITIAL_ORIGIN_SCALE: 0.6,
241
+ PADDING: 10,
242
+ TAP_DELAY_MS: 300
243
+ // Delay between touch and simulated mouse events on touch devices
244
+ }, l;
245
+ function V(a, i) {
246
+ i === void 0 && (i = !1);
247
+ var t = a.CSS, e = l;
248
+ if (typeof l == "boolean" && !i)
249
+ return l;
250
+ var n = t && typeof t.supports == "function";
251
+ if (!n)
252
+ return !1;
253
+ var r = t.supports("--css-vars", "yes"), s = t.supports("(--css-vars: yes)") && t.supports("color", "#00000000");
254
+ return e = r || s, i || (l = e), e;
255
+ }
256
+ function O(a, i, t) {
257
+ if (!a)
258
+ return { x: 0, y: 0 };
259
+ var e = i.x, n = i.y, r = e + t.left, s = n + t.top, o, u;
260
+ if (a.type === "touchstart") {
261
+ var c = a;
262
+ o = c.changedTouches[0].pageX - r, u = c.changedTouches[0].pageY - s;
263
+ } else {
264
+ var d = a;
265
+ o = d.pageX - r, u = d.pageY - s;
266
+ }
267
+ return { x: o, y: u };
268
+ }
269
+ /**
270
+ * @license
271
+ * Copyright 2016 Google Inc.
272
+ *
273
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
274
+ * of this software and associated documentation files (the "Software"), to deal
275
+ * in the Software without restriction, including without limitation the rights
276
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
277
+ * copies of the Software, and to permit persons to whom the Software is
278
+ * furnished to do so, subject to the following conditions:
279
+ *
280
+ * The above copyright notice and this permission notice shall be included in
281
+ * all copies or substantial portions of the Software.
282
+ *
283
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
284
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
285
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
286
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
287
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
288
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
289
+ * THE SOFTWARE.
290
+ */
291
+ var y = [
292
+ "touchstart",
293
+ "pointerdown",
294
+ "mousedown",
295
+ "keydown"
296
+ ], C = [
297
+ "touchend",
298
+ "pointerup",
299
+ "mouseup",
300
+ "contextmenu"
301
+ ], p = [], H = (
302
+ /** @class */
303
+ function(a) {
304
+ T(i, a);
305
+ function i(t) {
306
+ var e = a.call(this, v(v({}, i.defaultAdapter), t)) || this;
307
+ return e.activationAnimationHasEnded_ = !1, e.activationTimer_ = 0, e.fgDeactivationRemovalTimer_ = 0, e.fgScale_ = "0", e.frame_ = { width: 0, height: 0 }, e.initialSize_ = 0, e.layoutFrame_ = 0, e.maxRadius_ = 0, e.unboundedCoords_ = { left: 0, top: 0 }, e.activationState_ = e.defaultActivationState_(), e.activationTimerCallback_ = function() {
308
+ e.activationAnimationHasEnded_ = !0, e.runDeactivationUXLogicIfReady_();
309
+ }, e.activateHandler_ = function(n) {
310
+ return e.activate_(n);
311
+ }, e.deactivateHandler_ = function() {
312
+ return e.deactivate_();
313
+ }, e.focusHandler_ = function() {
314
+ return e.handleFocus();
315
+ }, e.blurHandler_ = function() {
316
+ return e.handleBlur();
317
+ }, e.resizeHandler_ = function() {
318
+ return e.layout();
319
+ }, e;
320
+ }
321
+ return Object.defineProperty(i, "cssClasses", {
322
+ get: function() {
323
+ return w;
324
+ },
325
+ enumerable: !1,
326
+ configurable: !0
327
+ }), Object.defineProperty(i, "strings", {
328
+ get: function() {
329
+ return F;
330
+ },
331
+ enumerable: !1,
332
+ configurable: !0
333
+ }), Object.defineProperty(i, "numbers", {
334
+ get: function() {
335
+ return g;
336
+ },
337
+ enumerable: !1,
338
+ configurable: !0
339
+ }), Object.defineProperty(i, "defaultAdapter", {
340
+ get: function() {
341
+ return {
342
+ addClass: function() {
343
+ },
344
+ browserSupportsCssVars: function() {
345
+ return !0;
346
+ },
347
+ computeBoundingRect: function() {
348
+ return { top: 0, right: 0, bottom: 0, left: 0, width: 0, height: 0 };
349
+ },
350
+ containsEventTarget: function() {
351
+ return !0;
352
+ },
353
+ deregisterDocumentInteractionHandler: function() {
354
+ },
355
+ deregisterInteractionHandler: function() {
356
+ },
357
+ deregisterResizeHandler: function() {
358
+ },
359
+ getWindowPageOffset: function() {
360
+ return { x: 0, y: 0 };
361
+ },
362
+ isSurfaceActive: function() {
363
+ return !0;
364
+ },
365
+ isSurfaceDisabled: function() {
366
+ return !0;
367
+ },
368
+ isUnbounded: function() {
369
+ return !0;
370
+ },
371
+ registerDocumentInteractionHandler: function() {
372
+ },
373
+ registerInteractionHandler: function() {
374
+ },
375
+ registerResizeHandler: function() {
376
+ },
377
+ removeClass: function() {
378
+ },
379
+ updateCssVariable: function() {
380
+ }
381
+ };
382
+ },
383
+ enumerable: !1,
384
+ configurable: !0
385
+ }), i.prototype.init = function() {
386
+ var t = this, e = this.supportsPressRipple_();
387
+ if (this.registerRootHandlers_(e), e) {
388
+ var n = i.cssClasses, r = n.ROOT, s = n.UNBOUNDED;
389
+ requestAnimationFrame(function() {
390
+ t.adapter.addClass(r), t.adapter.isUnbounded() && (t.adapter.addClass(s), t.layoutInternal_());
391
+ });
392
+ }
393
+ }, i.prototype.destroy = function() {
394
+ var t = this;
395
+ if (this.supportsPressRipple_()) {
396
+ this.activationTimer_ && (clearTimeout(this.activationTimer_), this.activationTimer_ = 0, this.adapter.removeClass(i.cssClasses.FG_ACTIVATION)), this.fgDeactivationRemovalTimer_ && (clearTimeout(this.fgDeactivationRemovalTimer_), this.fgDeactivationRemovalTimer_ = 0, this.adapter.removeClass(i.cssClasses.FG_DEACTIVATION));
397
+ var e = i.cssClasses, n = e.ROOT, r = e.UNBOUNDED;
398
+ requestAnimationFrame(function() {
399
+ t.adapter.removeClass(n), t.adapter.removeClass(r), t.removeCssVars_();
400
+ });
401
+ }
402
+ this.deregisterRootHandlers_(), this.deregisterDeactivationHandlers_();
403
+ }, i.prototype.activate = function(t) {
404
+ this.activate_(t);
405
+ }, i.prototype.deactivate = function() {
406
+ this.deactivate_();
407
+ }, i.prototype.layout = function() {
408
+ var t = this;
409
+ this.layoutFrame_ && cancelAnimationFrame(this.layoutFrame_), this.layoutFrame_ = requestAnimationFrame(function() {
410
+ t.layoutInternal_(), t.layoutFrame_ = 0;
411
+ });
412
+ }, i.prototype.setUnbounded = function(t) {
413
+ var e = i.cssClasses.UNBOUNDED;
414
+ t ? this.adapter.addClass(e) : this.adapter.removeClass(e);
415
+ }, i.prototype.handleFocus = function() {
416
+ var t = this;
417
+ requestAnimationFrame(function() {
418
+ return t.adapter.addClass(i.cssClasses.BG_FOCUSED);
419
+ });
420
+ }, i.prototype.handleBlur = function() {
421
+ var t = this;
422
+ requestAnimationFrame(function() {
423
+ return t.adapter.removeClass(i.cssClasses.BG_FOCUSED);
424
+ });
425
+ }, i.prototype.supportsPressRipple_ = function() {
426
+ return this.adapter.browserSupportsCssVars();
427
+ }, i.prototype.defaultActivationState_ = function() {
428
+ return {
429
+ activationEvent: void 0,
430
+ hasDeactivationUXRun: !1,
431
+ isActivated: !1,
432
+ isProgrammatic: !1,
433
+ wasActivatedByPointer: !1,
434
+ wasElementMadeActive: !1
435
+ };
436
+ }, i.prototype.registerRootHandlers_ = function(t) {
437
+ var e = this;
438
+ t && (y.forEach(function(n) {
439
+ e.adapter.registerInteractionHandler(n, e.activateHandler_);
440
+ }), this.adapter.isUnbounded() && this.adapter.registerResizeHandler(this.resizeHandler_)), this.adapter.registerInteractionHandler("focus", this.focusHandler_), this.adapter.registerInteractionHandler("blur", this.blurHandler_);
441
+ }, i.prototype.registerDeactivationHandlers_ = function(t) {
442
+ var e = this;
443
+ t.type === "keydown" ? this.adapter.registerInteractionHandler("keyup", this.deactivateHandler_) : C.forEach(function(n) {
444
+ e.adapter.registerDocumentInteractionHandler(n, e.deactivateHandler_);
445
+ });
446
+ }, i.prototype.deregisterRootHandlers_ = function() {
447
+ var t = this;
448
+ y.forEach(function(e) {
449
+ t.adapter.deregisterInteractionHandler(e, t.activateHandler_);
450
+ }), this.adapter.deregisterInteractionHandler("focus", this.focusHandler_), this.adapter.deregisterInteractionHandler("blur", this.blurHandler_), this.adapter.isUnbounded() && this.adapter.deregisterResizeHandler(this.resizeHandler_);
451
+ }, i.prototype.deregisterDeactivationHandlers_ = function() {
452
+ var t = this;
453
+ this.adapter.deregisterInteractionHandler("keyup", this.deactivateHandler_), C.forEach(function(e) {
454
+ t.adapter.deregisterDocumentInteractionHandler(e, t.deactivateHandler_);
455
+ });
456
+ }, i.prototype.removeCssVars_ = function() {
457
+ var t = this, e = i.strings, n = Object.keys(e);
458
+ n.forEach(function(r) {
459
+ r.indexOf("VAR_") === 0 && t.adapter.updateCssVariable(e[r], null);
460
+ });
461
+ }, i.prototype.activate_ = function(t) {
462
+ var e = this;
463
+ if (!this.adapter.isSurfaceDisabled()) {
464
+ var n = this.activationState_;
465
+ if (!n.isActivated) {
466
+ var r = this.previousActivationEvent_, s = r && t !== void 0 && r.type !== t.type;
467
+ if (!s) {
468
+ n.isActivated = !0, n.isProgrammatic = t === void 0, n.activationEvent = t, n.wasActivatedByPointer = n.isProgrammatic ? !1 : t !== void 0 && (t.type === "mousedown" || t.type === "touchstart" || t.type === "pointerdown");
469
+ var o = t !== void 0 && p.length > 0 && p.some(function(u) {
470
+ return e.adapter.containsEventTarget(u);
471
+ });
472
+ if (o) {
473
+ this.resetActivationState_();
474
+ return;
475
+ }
476
+ t !== void 0 && (p.push(t.target), this.registerDeactivationHandlers_(t)), n.wasElementMadeActive = this.checkElementMadeActive_(t), n.wasElementMadeActive && this.animateActivation_(), requestAnimationFrame(function() {
477
+ p = [], !n.wasElementMadeActive && t !== void 0 && (t.key === " " || t.keyCode === 32) && (n.wasElementMadeActive = e.checkElementMadeActive_(t), n.wasElementMadeActive && e.animateActivation_()), n.wasElementMadeActive || (e.activationState_ = e.defaultActivationState_());
478
+ });
479
+ }
480
+ }
481
+ }
482
+ }, i.prototype.checkElementMadeActive_ = function(t) {
483
+ return t !== void 0 && t.type === "keydown" ? this.adapter.isSurfaceActive() : !0;
484
+ }, i.prototype.animateActivation_ = function() {
485
+ var t = this, e = i.strings, n = e.VAR_FG_TRANSLATE_START, r = e.VAR_FG_TRANSLATE_END, s = i.cssClasses, o = s.FG_DEACTIVATION, u = s.FG_ACTIVATION, c = i.numbers.DEACTIVATION_TIMEOUT_MS;
486
+ this.layoutInternal_();
487
+ var d = "", h = "";
488
+ if (!this.adapter.isUnbounded()) {
489
+ var _ = this.getFgTranslationCoordinates_(), m = _.startPoint, A = _.endPoint;
490
+ d = m.x + "px, " + m.y + "px", h = A.x + "px, " + A.y + "px";
491
+ }
492
+ this.adapter.updateCssVariable(n, d), this.adapter.updateCssVariable(r, h), clearTimeout(this.activationTimer_), clearTimeout(this.fgDeactivationRemovalTimer_), this.rmBoundedActivationClasses_(), this.adapter.removeClass(o), this.adapter.computeBoundingRect(), this.adapter.addClass(u), this.activationTimer_ = setTimeout(function() {
493
+ return t.activationTimerCallback_();
494
+ }, c);
495
+ }, i.prototype.getFgTranslationCoordinates_ = function() {
496
+ var t = this.activationState_, e = t.activationEvent, n = t.wasActivatedByPointer, r;
497
+ n ? r = O(e, this.adapter.getWindowPageOffset(), this.adapter.computeBoundingRect()) : r = {
498
+ x: this.frame_.width / 2,
499
+ y: this.frame_.height / 2
500
+ }, r = {
501
+ x: r.x - this.initialSize_ / 2,
502
+ y: r.y - this.initialSize_ / 2
503
+ };
504
+ var s = {
505
+ x: this.frame_.width / 2 - this.initialSize_ / 2,
506
+ y: this.frame_.height / 2 - this.initialSize_ / 2
507
+ };
508
+ return { startPoint: r, endPoint: s };
509
+ }, i.prototype.runDeactivationUXLogicIfReady_ = function() {
510
+ var t = this, e = i.cssClasses.FG_DEACTIVATION, n = this.activationState_, r = n.hasDeactivationUXRun, s = n.isActivated, o = r || !s;
511
+ o && this.activationAnimationHasEnded_ && (this.rmBoundedActivationClasses_(), this.adapter.addClass(e), this.fgDeactivationRemovalTimer_ = setTimeout(function() {
512
+ t.adapter.removeClass(e);
513
+ }, g.FG_DEACTIVATION_MS));
514
+ }, i.prototype.rmBoundedActivationClasses_ = function() {
515
+ var t = i.cssClasses.FG_ACTIVATION;
516
+ this.adapter.removeClass(t), this.activationAnimationHasEnded_ = !1, this.adapter.computeBoundingRect();
517
+ }, i.prototype.resetActivationState_ = function() {
518
+ var t = this;
519
+ this.previousActivationEvent_ = this.activationState_.activationEvent, this.activationState_ = this.defaultActivationState_(), setTimeout(function() {
520
+ return t.previousActivationEvent_ = void 0;
521
+ }, i.numbers.TAP_DELAY_MS);
522
+ }, i.prototype.deactivate_ = function() {
523
+ var t = this, e = this.activationState_;
524
+ if (e.isActivated) {
525
+ var n = v({}, e);
526
+ e.isProgrammatic ? (requestAnimationFrame(function() {
527
+ return t.animateDeactivation_(n);
528
+ }), this.resetActivationState_()) : (this.deregisterDeactivationHandlers_(), requestAnimationFrame(function() {
529
+ t.activationState_.hasDeactivationUXRun = !0, t.animateDeactivation_(n), t.resetActivationState_();
530
+ }));
531
+ }
532
+ }, i.prototype.animateDeactivation_ = function(t) {
533
+ var e = t.wasActivatedByPointer, n = t.wasElementMadeActive;
534
+ (e || n) && this.runDeactivationUXLogicIfReady_();
535
+ }, i.prototype.layoutInternal_ = function() {
536
+ var t = this;
537
+ this.frame_ = this.adapter.computeBoundingRect();
538
+ var e = Math.max(this.frame_.height, this.frame_.width), n = function() {
539
+ var s = Math.sqrt(Math.pow(t.frame_.width, 2) + Math.pow(t.frame_.height, 2));
540
+ return s + i.numbers.PADDING;
541
+ };
542
+ this.maxRadius_ = this.adapter.isUnbounded() ? e : n();
543
+ var r = Math.floor(e * i.numbers.INITIAL_ORIGIN_SCALE);
544
+ this.adapter.isUnbounded() && r % 2 !== 0 ? this.initialSize_ = r - 1 : this.initialSize_ = r, this.fgScale_ = "" + this.maxRadius_ / this.initialSize_, this.updateLayoutCssVars_();
545
+ }, i.prototype.updateLayoutCssVars_ = function() {
546
+ var t = i.strings, e = t.VAR_FG_SIZE, n = t.VAR_LEFT, r = t.VAR_TOP, s = t.VAR_FG_SCALE;
547
+ this.adapter.updateCssVariable(e, this.initialSize_ + "px"), this.adapter.updateCssVariable(s, this.fgScale_), this.adapter.isUnbounded() && (this.unboundedCoords_ = {
548
+ left: Math.round(this.frame_.width / 2 - this.initialSize_ / 2),
549
+ top: Math.round(this.frame_.height / 2 - this.initialSize_ / 2)
550
+ }, this.adapter.updateCssVariable(n, this.unboundedCoords_.left + "px"), this.adapter.updateCssVariable(r, this.unboundedCoords_.top + "px"));
551
+ }, i;
552
+ }(E)
553
+ );
554
+ /**
555
+ * @license
556
+ * Copyright 2016 Google Inc.
557
+ *
558
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
559
+ * of this software and associated documentation files (the "Software"), to deal
560
+ * in the Software without restriction, including without limitation the rights
561
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
562
+ * copies of the Software, and to permit persons to whom the Software is
563
+ * furnished to do so, subject to the following conditions:
564
+ *
565
+ * The above copyright notice and this permission notice shall be included in
566
+ * all copies or substantial portions of the Software.
567
+ *
568
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
569
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
570
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
571
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
572
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
573
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
574
+ * THE SOFTWARE.
575
+ */
576
+ var U = (
577
+ /** @class */
578
+ function(a) {
579
+ T(i, a);
580
+ function i() {
581
+ var t = a !== null && a.apply(this, arguments) || this;
582
+ return t.disabled = !1, t;
583
+ }
584
+ return i.attachTo = function(t, e) {
585
+ e === void 0 && (e = { isUnbounded: void 0 });
586
+ var n = new i(t);
587
+ return e.isUnbounded !== void 0 && (n.unbounded = e.isUnbounded), n;
588
+ }, i.createAdapter = function(t) {
589
+ return {
590
+ addClass: function(e) {
591
+ return t.root.classList.add(e);
592
+ },
593
+ browserSupportsCssVars: function() {
594
+ return V(window);
595
+ },
596
+ computeBoundingRect: function() {
597
+ return t.root.getBoundingClientRect();
598
+ },
599
+ containsEventTarget: function(e) {
600
+ return t.root.contains(e);
601
+ },
602
+ deregisterDocumentInteractionHandler: function(e, n) {
603
+ return document.documentElement.removeEventListener(e, n, f());
604
+ },
605
+ deregisterInteractionHandler: function(e, n) {
606
+ return t.root.removeEventListener(e, n, f());
607
+ },
608
+ deregisterResizeHandler: function(e) {
609
+ return window.removeEventListener("resize", e);
610
+ },
611
+ getWindowPageOffset: function() {
612
+ return { x: window.pageXOffset, y: window.pageYOffset };
613
+ },
614
+ isSurfaceActive: function() {
615
+ return S(t.root, ":active");
616
+ },
617
+ isSurfaceDisabled: function() {
618
+ return !!t.disabled;
619
+ },
620
+ isUnbounded: function() {
621
+ return !!t.unbounded;
622
+ },
623
+ registerDocumentInteractionHandler: function(e, n) {
624
+ return document.documentElement.addEventListener(e, n, f());
625
+ },
626
+ registerInteractionHandler: function(e, n) {
627
+ return t.root.addEventListener(e, n, f());
628
+ },
629
+ registerResizeHandler: function(e) {
630
+ return window.addEventListener("resize", e);
631
+ },
632
+ removeClass: function(e) {
633
+ return t.root.classList.remove(e);
634
+ },
635
+ updateCssVariable: function(e, n) {
636
+ return t.root.style.setProperty(e, n);
637
+ }
638
+ };
639
+ }, Object.defineProperty(i.prototype, "unbounded", {
640
+ get: function() {
641
+ return !!this.unbounded_;
642
+ },
643
+ set: function(t) {
644
+ this.unbounded_ = !!t, this.setUnbounded_();
645
+ },
646
+ enumerable: !1,
647
+ configurable: !0
648
+ }), i.prototype.activate = function() {
649
+ this.foundation.activate();
650
+ }, i.prototype.deactivate = function() {
651
+ this.foundation.deactivate();
652
+ }, i.prototype.layout = function() {
653
+ this.foundation.layout();
654
+ }, i.prototype.getDefaultFoundation = function() {
655
+ return new H(i.createAdapter(this));
656
+ }, i.prototype.initialSyncWithDOM = function() {
657
+ var t = this.root;
658
+ this.unbounded = "mdcRippleIsUnbounded" in t.dataset;
659
+ }, i.prototype.setUnbounded_ = function() {
660
+ this.foundation.setUnbounded(!!this.unbounded_);
661
+ }, i;
662
+ }(D)
663
+ );
664
+ export {
665
+ U as M,
666
+ E as a,
667
+ f as b,
668
+ D as c,
669
+ H as d,
670
+ M as e,
671
+ P as f,
672
+ S as m
673
+ };
@@ -41,6 +41,10 @@ type BaseViewProps = {
41
41
  * listMaxHeight is the max height of the list, @default 'calc(100vh - 200px)'
42
42
  */
43
43
  listMaxHeight?: string;
44
+ /**
45
+ * searchPlaceholder is the placeholder of the search input, @default ''
46
+ */
47
+ searchPlaceholder?: string;
44
48
  /**
45
49
  * routerLinkElement is the element to be used for the elements link, use react-router Link component for the best experience.
46
50
  * If the element has `noNavigation=false` and the `routerLinkElement` is undefined an `<a>` tag is used.
@@ -51,5 +55,5 @@ type BaseViewProps = {
51
55
  /**
52
56
  * `BaseView` is a layout component that displays a main (a list) and a detail section.
53
57
  */
54
- export declare const BaseView: ({ action, heading, elements, emptyText, hasSearch, isSorted, className, withAvatar, listMaxHeight, pathname, routerLinkElement, }: BaseViewProps) => import("react/jsx-runtime").JSX.Element;
58
+ export declare const BaseView: ({ action, heading, elements, emptyText, hasSearch, isSorted, className, withAvatar, listMaxHeight, pathname, routerLinkElement, searchPlaceholder, }: BaseViewProps) => import("react/jsx-runtime").JSX.Element;
55
59
  export {};