@covalent/components 8.18.0 → 8.19.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/action-ribbon.js +1 -1
- package/action-ribbon.mjs +4 -3
- package/alert.js +1 -1
- package/alert.mjs +4 -3
- package/app-shell.js +1 -1
- package/app-shell.mjs +8 -7
- package/async-directive-4a34f75e.js +5 -0
- package/async-directive-99a01ec7.mjs +78 -0
- package/badge.js +1 -1
- package/badge.mjs +4 -3
- package/button.js +1 -1
- package/button.mjs +10 -9
- package/card.js +1 -1
- package/card.mjs +14 -13
- package/check-list-item.js +1 -1
- package/check-list-item.mjs +8 -7
- package/checkbox.js +1 -1
- package/checkbox.mjs +16 -15
- package/{chip-ebd0a88e.js → chip-c65a4549.js} +1 -1
- package/{chip-2d0fd3f0.mjs → chip-fb0ea5c5.mjs} +1 -1
- package/chip-set.js +2 -2
- package/chip-set.mjs +46 -45
- package/chip.js +1 -1
- package/chip.mjs +5 -4
- package/circular-progress.js +1 -1
- package/circular-progress.mjs +5 -4
- package/class-map-0a4c6ca9.js +5 -0
- package/class-map-6e504a9a.mjs +38 -0
- package/code-editor/code-editor.d.ts +58 -0
- package/code-editor/code-editor.d.ts.map +1 -0
- package/code-editor/code-editor.theme.d.ts +61 -0
- package/code-editor/code-editor.theme.d.ts.map +1 -0
- package/code-editor-8064b078.mjs +61268 -0
- package/code-editor-f85b0a6b.js +662 -0
- package/code-editor.js +1 -0
- package/code-editor.mjs +10 -0
- package/code-snippet.js +2 -2
- package/code-snippet.mjs +5 -4
- package/css-5dd354ac.mjs +186 -0
- package/css-9be95551.js +8 -0
- package/{dialog-c9dbe94d.mjs → dialog-16aad066.mjs} +1 -1
- package/{dialog-82b03745.js → dialog-86192b9a.js} +1 -1
- package/dialog.js +1 -1
- package/dialog.mjs +5 -4
- package/directive-1186bc23.js +5 -0
- package/directive-daf4e9b6.mjs +27 -0
- package/drawer.js +1 -1
- package/drawer.mjs +5 -4
- package/formfield.js +3 -3
- package/formfield.mjs +4 -3
- package/html-5fd3a841.mjs +286 -0
- package/html-73c71ff4.js +6 -0
- package/icon-button-toggle.js +1 -1
- package/icon-button-toggle.mjs +6 -5
- package/icon-button.js +1 -1
- package/icon-button.mjs +6 -5
- package/icon-check-toggle.js +1 -1
- package/icon-check-toggle.mjs +7 -6
- package/icon-radio-toggle.js +3 -3
- package/icon-radio-toggle.mjs +7 -6
- package/index.d.ts +2 -0
- package/index.d.ts.map +1 -1
- package/index.js +1 -1
- package/index.mjs +123 -117
- package/javascript-204f9122.js +6 -0
- package/javascript-85aeeec4.mjs +80 -0
- package/linear-progress.js +1 -1
- package/linear-progress.mjs +5 -4
- package/list-item.js +2 -2
- package/list-item.mjs +7 -6
- package/list.js +1 -1
- package/list.mjs +8 -7
- package/markdown-9b448c46.mjs +202 -0
- package/markdown-eae8e3ba.js +6 -0
- package/menu.js +5 -5
- package/menu.mjs +9 -8
- package/{mwc-checkbox-base-c40d16d2.mjs → mwc-checkbox-base-02b4eb91.mjs} +2 -2
- package/{mwc-checkbox-base-3d8c9549.js → mwc-checkbox-base-935d9566.js} +1 -1
- package/{mwc-drawer-base-798b11f8.js → mwc-drawer-base-bbae43c3.js} +1 -1
- package/{mwc-drawer-base-9c77129c.mjs → mwc-drawer-base-ca75f41f.mjs} +1 -1
- package/{mwc-line-ripple-directive-a6b39a3c.js → mwc-line-ripple-directive-40145003.js} +14 -14
- package/{mwc-line-ripple-directive-f9dd7fe3.mjs → mwc-line-ripple-directive-aabd8778.mjs} +6 -5
- package/{mwc-list-base-400b00e2.js → mwc-list-base-22616d0a.js} +1 -1
- package/{mwc-list-base-495cbb3b.mjs → mwc-list-base-402e1d8e.mjs} +1 -1
- package/{mwc-list-item-base-297d86b0.js → mwc-list-item-base-06d93e6e.js} +1 -1
- package/{mwc-list-item-base-6449e812.mjs → mwc-list-item-base-3c6a3bfb.mjs} +2 -2
- package/{mwc-menu-base-9704207e.mjs → mwc-menu-base-04586160.mjs} +3 -3
- package/{mwc-menu-base-c75ca473.js → mwc-menu-base-08f54c38.js} +1 -1
- package/{mwc-radio-base-913e02e2.js → mwc-radio-base-147cf999.js} +1 -1
- package/{mwc-radio-base-4dbe9e38.mjs → mwc-radio-base-768b4221.mjs} +2 -2
- package/{mwc-slider.css-c7107d94.js → mwc-slider.css-c5f99704.js} +1 -1
- package/{mwc-slider.css-30c91236.mjs → mwc-slider.css-cda43bd0.mjs} +3 -3
- package/{mwc-tab-base-effde6e4.mjs → mwc-tab-base-0814a3ef.mjs} +2 -2
- package/{mwc-tab-base-f28722aa.js → mwc-tab-base-f2269fd1.js} +1 -1
- package/{mwc-top-app-bar-base-28c4192d.mjs → mwc-top-app-bar-base-8a7f7312.mjs} +1 -1
- package/{mwc-top-app-bar-base-aec60f27.js → mwc-top-app-bar-base-8c8cde51.js} +1 -1
- package/nav-list-item.js +1 -1
- package/nav-list-item.mjs +7 -6
- package/notebook-cell/notebook-cell.d.ts +94 -0
- package/notebook-cell/notebook-cell.d.ts.map +1 -0
- package/notebook-cell.js +47 -0
- package/notebook-cell.mjs +217 -0
- package/package.json +11 -1
- package/python-abc06189.mjs +264 -0
- package/python-cb76a8a4.js +6 -0
- package/r-42c6f0aa.js +6 -0
- package/r-630f5d6b.mjs +245 -0
- package/radio-list-item.js +1 -1
- package/radio-list-item.mjs +8 -7
- package/radio.js +2 -2
- package/radio.mjs +7 -6
- package/{ripple-handlers-0d9ad7c2.mjs → ripple-handlers-8883e893.mjs} +2 -2
- package/{ripple-handlers-5d5b21db.js → ripple-handlers-9fb4a31a.js} +1 -1
- package/select.js +2 -2
- package/select.mjs +11 -10
- package/side-sheet.js +1 -1
- package/side-sheet.mjs +3 -2
- package/slider-range.js +1 -1
- package/slider-range.mjs +7 -6
- package/slider.js +1 -1
- package/slider.mjs +12 -11
- package/snackbar.js +14 -18
- package/snackbar.mjs +88 -159
- package/sql-63ec8e76.mjs +818 -0
- package/sql-faf05577.js +6 -0
- package/status-dialog.js +1 -1
- package/status-dialog.mjs +7 -6
- package/status-header.js +1 -1
- package/status-header.mjs +4 -3
- package/{style-map-88d2563f.js → style-map-a135c6ab.js} +2 -2
- package/{style-map-bc3ed3e0.mjs → style-map-e7ec6d41.mjs} +1 -1
- package/style.css +1 -0
- package/switch.js +1 -1
- package/switch.mjs +6 -5
- package/tab-bar.js +2 -2
- package/tab-bar.mjs +7 -6
- package/tab.js +1 -1
- package/tab.mjs +9 -8
- package/text-lockup.js +1 -1
- package/text-lockup.mjs +4 -3
- package/textarea.js +1 -1
- package/textarea.mjs +6 -5
- package/{textfield-a064a2b4.js → textfield-48207bf2.js} +16 -16
- package/{textfield-69844234.mjs → textfield-a994ca16.mjs} +5 -4
- package/textfield.js +1 -1
- package/textfield.mjs +6 -5
- package/toolbar.js +1 -1
- package/toolbar.mjs +5 -4
- package/top-app-bar-fixed.js +1 -1
- package/top-app-bar-fixed.mjs +5 -4
- package/top-app-bar.js +1 -1
- package/top-app-bar.mjs +8 -7
- package/tree-list-item.js +1 -1
- package/tree-list-item.mjs +4 -3
- package/typescript-5cbac06a.mjs +332 -0
- package/typescript-95376fa5.js +6 -0
- package/class-map-4b94b017.mjs +0 -62
- package/class-map-b5efe8da.js +0 -9
package/snackbar.mjs
CHANGED
@@ -1,12 +1,14 @@
|
|
1
|
-
import { D as
|
2
|
-
import { a as
|
3
|
-
import { B as
|
4
|
-
import { o as
|
1
|
+
import { D as S, x as b, i as T, r as A, e as I } from "./query-assigned-elements-4a39219d.mjs";
|
2
|
+
import { a as N, b as y, _ as m } from "./tslib.es6-c4b0f3b1.mjs";
|
3
|
+
import { B as M } from "./base-element-acf30176.mjs";
|
4
|
+
import { o as f } from "./observer-be7b92e2.mjs";
|
5
5
|
import { n as l } from "./property-9b6ea53b.mjs";
|
6
|
-
import { i as
|
7
|
-
import {
|
8
|
-
import {
|
9
|
-
import {
|
6
|
+
import { i as C } from "./query-d843aa92.mjs";
|
7
|
+
import { o as D } from "./class-map-6e504a9a.mjs";
|
8
|
+
import { c as w } from "./async-directive-99a01ec7.mjs";
|
9
|
+
import { e as F, t as L } from "./directive-daf4e9b6.mjs";
|
10
|
+
import { a as P } from "./utils-dc65fdc9.mjs";
|
11
|
+
import "./directive-helpers-e3ea6592.mjs";
|
10
12
|
/**
|
11
13
|
* @license
|
12
14
|
* Copyright 2016 Google Inc.
|
@@ -29,39 +31,39 @@ import { a as U } from "./utils-dc65fdc9.mjs";
|
|
29
31
|
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
30
32
|
* THE SOFTWARE.
|
31
33
|
*/
|
32
|
-
var
|
34
|
+
var R = (
|
33
35
|
/** @class */
|
34
36
|
function() {
|
35
|
-
function
|
37
|
+
function i(e) {
|
36
38
|
e === void 0 && (e = {}), this.adapter = e;
|
37
39
|
}
|
38
|
-
return Object.defineProperty(
|
40
|
+
return Object.defineProperty(i, "cssClasses", {
|
39
41
|
get: function() {
|
40
42
|
return {};
|
41
43
|
},
|
42
44
|
enumerable: !1,
|
43
45
|
configurable: !0
|
44
|
-
}), Object.defineProperty(
|
46
|
+
}), Object.defineProperty(i, "strings", {
|
45
47
|
get: function() {
|
46
48
|
return {};
|
47
49
|
},
|
48
50
|
enumerable: !1,
|
49
51
|
configurable: !0
|
50
|
-
}), Object.defineProperty(
|
52
|
+
}), Object.defineProperty(i, "numbers", {
|
51
53
|
get: function() {
|
52
54
|
return {};
|
53
55
|
},
|
54
56
|
enumerable: !1,
|
55
57
|
configurable: !0
|
56
|
-
}), Object.defineProperty(
|
58
|
+
}), Object.defineProperty(i, "defaultAdapter", {
|
57
59
|
get: function() {
|
58
60
|
return {};
|
59
61
|
},
|
60
62
|
enumerable: !1,
|
61
63
|
configurable: !0
|
62
|
-
}),
|
63
|
-
},
|
64
|
-
},
|
64
|
+
}), i.prototype.init = function() {
|
65
|
+
}, i.prototype.destroy = function() {
|
66
|
+
}, i;
|
65
67
|
}()
|
66
68
|
);
|
67
69
|
/**
|
@@ -90,7 +92,7 @@ var c = {
|
|
90
92
|
CLOSING: "mdc-snackbar--closing",
|
91
93
|
OPEN: "mdc-snackbar--open",
|
92
94
|
OPENING: "mdc-snackbar--opening"
|
93
|
-
},
|
95
|
+
}, h = {
|
94
96
|
ACTION_SELECTOR: ".mdc-snackbar__action",
|
95
97
|
ARIA_LIVE_LABEL_TEXT_ATTR: "data-mdc-snackbar-label-text",
|
96
98
|
CLOSED_EVENT: "MDCSnackbar:closed",
|
@@ -139,13 +141,13 @@ var c = {
|
|
139
141
|
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
140
142
|
* THE SOFTWARE.
|
141
143
|
*/
|
142
|
-
var
|
144
|
+
var x = c.OPENING, v = c.OPEN, E = c.CLOSING, z = h.REASON_ACTION, _ = h.REASON_DISMISS, U = (
|
143
145
|
/** @class */
|
144
|
-
function(
|
145
|
-
|
146
|
+
function(i) {
|
147
|
+
N(e, i);
|
146
148
|
function e(t) {
|
147
|
-
var
|
148
|
-
return
|
149
|
+
var a = i.call(this, y(y({}, e.defaultAdapter), t)) || this;
|
150
|
+
return a.opened = !1, a.animationFrame = 0, a.animationTimer = 0, a.autoDismissTimer = 0, a.autoDismissTimeoutMs = o.DEFAULT_AUTO_DISMISS_TIMEOUT_MS, a.closeOnEscape = !0, a;
|
149
151
|
}
|
150
152
|
return Object.defineProperty(e, "cssClasses", {
|
151
153
|
get: function() {
|
@@ -155,7 +157,7 @@ var E = c.OPENING, A = c.OPEN, T = c.CLOSING, V = k.REASON_ACTION, h = k.REASON_
|
|
155
157
|
configurable: !0
|
156
158
|
}), Object.defineProperty(e, "strings", {
|
157
159
|
get: function() {
|
158
|
-
return
|
160
|
+
return h;
|
159
161
|
},
|
160
162
|
enumerable: !1,
|
161
163
|
configurable: !0
|
@@ -187,174 +189,101 @@ var E = c.OPENING, A = c.OPEN, T = c.CLOSING, V = k.REASON_ACTION, h = k.REASON_
|
|
187
189
|
enumerable: !1,
|
188
190
|
configurable: !0
|
189
191
|
}), e.prototype.destroy = function() {
|
190
|
-
this.clearAutoDismissTimer(), cancelAnimationFrame(this.animationFrame), this.animationFrame = 0, clearTimeout(this.animationTimer), this.animationTimer = 0, this.adapter.removeClass(
|
192
|
+
this.clearAutoDismissTimer(), cancelAnimationFrame(this.animationFrame), this.animationFrame = 0, clearTimeout(this.animationTimer), this.animationTimer = 0, this.adapter.removeClass(x), this.adapter.removeClass(v), this.adapter.removeClass(E);
|
191
193
|
}, e.prototype.open = function() {
|
192
194
|
var t = this;
|
193
|
-
this.clearAutoDismissTimer(), this.opened = !0, this.adapter.notifyOpening(), this.adapter.removeClass(
|
194
|
-
t.adapter.addClass(
|
195
|
-
var
|
196
|
-
t.handleAnimationTimerEnd(), t.adapter.notifyOpened(),
|
197
|
-
t.close(
|
198
|
-
},
|
195
|
+
this.clearAutoDismissTimer(), this.opened = !0, this.adapter.notifyOpening(), this.adapter.removeClass(E), this.adapter.addClass(x), this.adapter.announce(), this.runNextAnimationFrame(function() {
|
196
|
+
t.adapter.addClass(v), t.animationTimer = setTimeout(function() {
|
197
|
+
var a = t.getTimeoutMs();
|
198
|
+
t.handleAnimationTimerEnd(), t.adapter.notifyOpened(), a !== o.INDETERMINATE && (t.autoDismissTimer = setTimeout(function() {
|
199
|
+
t.close(_);
|
200
|
+
}, a));
|
199
201
|
}, o.SNACKBAR_ANIMATION_OPEN_TIME_MS);
|
200
202
|
});
|
201
203
|
}, e.prototype.close = function(t) {
|
202
|
-
var
|
204
|
+
var a = this;
|
203
205
|
t === void 0 && (t = ""), this.opened && (cancelAnimationFrame(this.animationFrame), this.animationFrame = 0, this.clearAutoDismissTimer(), this.opened = !1, this.adapter.notifyClosing(t), this.adapter.addClass(c.CLOSING), this.adapter.removeClass(c.OPEN), this.adapter.removeClass(c.OPENING), clearTimeout(this.animationTimer), this.animationTimer = setTimeout(function() {
|
204
|
-
|
206
|
+
a.handleAnimationTimerEnd(), a.adapter.notifyClosed(t);
|
205
207
|
}, o.SNACKBAR_ANIMATION_CLOSE_TIME_MS));
|
206
208
|
}, e.prototype.isOpen = function() {
|
207
209
|
return this.opened;
|
208
210
|
}, e.prototype.getTimeoutMs = function() {
|
209
211
|
return this.autoDismissTimeoutMs;
|
210
212
|
}, e.prototype.setTimeoutMs = function(t) {
|
211
|
-
var
|
212
|
-
if (t === o.INDETERMINATE || t <= n && t >=
|
213
|
+
var a = o.MIN_AUTO_DISMISS_TIMEOUT_MS, n = o.MAX_AUTO_DISMISS_TIMEOUT_MS, s = o.INDETERMINATE;
|
214
|
+
if (t === o.INDETERMINATE || t <= n && t >= a)
|
213
215
|
this.autoDismissTimeoutMs = t;
|
214
216
|
else
|
215
217
|
throw new Error(`
|
216
|
-
timeoutMs must be an integer in the range ` +
|
218
|
+
timeoutMs must be an integer in the range ` + a + "–" + n + `
|
217
219
|
(or ` + s + " to disable), but got '" + t + "'");
|
218
220
|
}, e.prototype.getCloseOnEscape = function() {
|
219
221
|
return this.closeOnEscape;
|
220
222
|
}, e.prototype.setCloseOnEscape = function(t) {
|
221
223
|
this.closeOnEscape = t;
|
222
224
|
}, e.prototype.handleKeyDown = function(t) {
|
223
|
-
var
|
224
|
-
|
225
|
+
var a = t.key === "Escape" || t.keyCode === 27;
|
226
|
+
a && this.getCloseOnEscape() && this.close(_);
|
225
227
|
}, e.prototype.handleActionButtonClick = function(t) {
|
226
|
-
this.close(
|
228
|
+
this.close(z);
|
227
229
|
}, e.prototype.handleActionIconClick = function(t) {
|
228
|
-
this.close(
|
230
|
+
this.close(_);
|
229
231
|
}, e.prototype.clearAutoDismissTimer = function() {
|
230
232
|
clearTimeout(this.autoDismissTimer), this.autoDismissTimer = 0;
|
231
233
|
}, e.prototype.handleAnimationTimerEnd = function() {
|
232
234
|
this.animationTimer = 0, this.adapter.removeClass(c.OPENING), this.adapter.removeClass(c.CLOSING);
|
233
235
|
}, e.prototype.runNextAnimationFrame = function(t) {
|
234
|
-
var
|
236
|
+
var a = this;
|
235
237
|
cancelAnimationFrame(this.animationFrame), this.animationFrame = requestAnimationFrame(function() {
|
236
|
-
|
238
|
+
a.animationFrame = 0, clearTimeout(a.animationTimer), a.animationTimer = setTimeout(t, 0);
|
237
239
|
});
|
238
240
|
}, e;
|
239
|
-
}(
|
241
|
+
}(R)
|
240
242
|
);
|
241
|
-
const
|
242
|
-
/**
|
243
|
-
* @license
|
244
|
-
* Copyright 2017 Google LLC
|
245
|
-
* SPDX-License-Identifier: BSD-3-Clause
|
246
|
-
*/
|
247
|
-
const p = (a, e) => {
|
248
|
-
var t, i;
|
249
|
-
const n = a._$AN;
|
250
|
-
if (n === void 0)
|
251
|
-
return !1;
|
252
|
-
for (const s of n)
|
253
|
-
(i = (t = s)._$AO) === null || i === void 0 || i.call(t, e, !1), p(s, e);
|
254
|
-
return !0;
|
255
|
-
}, _ = (a) => {
|
256
|
-
let e, t;
|
257
|
-
do {
|
258
|
-
if ((e = a._$AM) === void 0)
|
259
|
-
break;
|
260
|
-
t = e._$AN, t.delete(a), a = e;
|
261
|
-
} while ((t == null ? void 0 : t.size) === 0);
|
262
|
-
}, I = (a) => {
|
263
|
-
for (let e; e = a._$AM; a = e) {
|
264
|
-
let t = e._$AN;
|
265
|
-
if (t === void 0)
|
266
|
-
e._$AN = t = /* @__PURE__ */ new Set();
|
267
|
-
else if (t.has(a))
|
268
|
-
break;
|
269
|
-
t.add(a), H(e);
|
270
|
-
}
|
271
|
-
};
|
272
|
-
function G(a) {
|
273
|
-
this._$AN !== void 0 ? (_(this), this._$AM = a, I(this)) : this._$AM = a;
|
274
|
-
}
|
275
|
-
function K(a, e = !1, t = 0) {
|
276
|
-
const i = this._$AH, n = this._$AN;
|
277
|
-
if (n !== void 0 && n.size !== 0)
|
278
|
-
if (e)
|
279
|
-
if (Array.isArray(i))
|
280
|
-
for (let s = t; s < i.length; s++)
|
281
|
-
p(i[s], !1), _(i[s]);
|
282
|
-
else
|
283
|
-
i != null && (p(i, !1), _(i));
|
284
|
-
else
|
285
|
-
p(this, a);
|
286
|
-
}
|
287
|
-
const H = (a) => {
|
288
|
-
var e, t, i, n;
|
289
|
-
a.type == S.CHILD && ((e = (i = a)._$AP) !== null && e !== void 0 || (i._$AP = K), (t = (n = a)._$AQ) !== null && t !== void 0 || (n._$AQ = G));
|
290
|
-
};
|
291
|
-
class X extends L {
|
292
|
-
constructor() {
|
293
|
-
super(...arguments), this._$AN = void 0;
|
294
|
-
}
|
295
|
-
_$AT(e, t, i) {
|
296
|
-
super._$AT(e, t, i), I(this), this.isConnected = e._$AU;
|
297
|
-
}
|
298
|
-
_$AO(e, t = !0) {
|
299
|
-
var i, n;
|
300
|
-
e !== this.isConnected && (this.isConnected = e, e ? (i = this.reconnected) === null || i === void 0 || i.call(this) : (n = this.disconnected) === null || n === void 0 || n.call(this)), t && (p(this, e), _(this));
|
301
|
-
}
|
302
|
-
setValue(e) {
|
303
|
-
if (z(this._$Ct))
|
304
|
-
this._$Ct._$AI(e, this);
|
305
|
-
else {
|
306
|
-
const t = [...this._$Ct._$AH];
|
307
|
-
t[this._$Ci] = e, this._$Ct._$AI(t, this, 0);
|
308
|
-
}
|
309
|
-
}
|
310
|
-
disconnected() {
|
311
|
-
}
|
312
|
-
reconnected() {
|
313
|
-
}
|
314
|
-
}
|
243
|
+
const g = U;
|
315
244
|
/**
|
316
245
|
* @license
|
317
246
|
* Copyright 2019 Google LLC
|
318
247
|
* SPDX-License-Identifier: Apache-2.0
|
319
248
|
*/
|
320
|
-
const { ARIA_LIVE_DELAY_MS:
|
321
|
-
class
|
249
|
+
const { ARIA_LIVE_DELAY_MS: B } = g.numbers;
|
250
|
+
class j extends w {
|
322
251
|
constructor(e) {
|
323
|
-
if (super(e), this.labelEl = null, this.timerId = null, this.previousPart = null, e.type !==
|
252
|
+
if (super(e), this.labelEl = null, this.timerId = null, this.previousPart = null, e.type !== L.CHILD)
|
324
253
|
throw new Error("AccessibleSnackbarLabel only supports child parts.");
|
325
254
|
}
|
326
|
-
update(e, [t,
|
255
|
+
update(e, [t, a]) {
|
327
256
|
var n;
|
328
|
-
if (!
|
257
|
+
if (!a)
|
329
258
|
return;
|
330
259
|
if (this.labelEl === null) {
|
331
|
-
const
|
332
|
-
|
333
|
-
const
|
334
|
-
return
|
260
|
+
const k = document.createElement("div"), O = b`<div class="mdc-snackbar__label" role="status" aria-live="polite"></div>`;
|
261
|
+
S(O, k);
|
262
|
+
const p = k.firstElementChild;
|
263
|
+
return p.textContent = t, (n = e.endNode) === null || n === void 0 || n.parentNode.insertBefore(p, e.endNode), this.labelEl = p, p;
|
335
264
|
}
|
336
265
|
const s = this.labelEl;
|
337
266
|
s.setAttribute("aria-live", "off"), s.textContent = "";
|
338
267
|
const r = document.createElement("span");
|
339
268
|
return r.style.display = "inline-block", r.style.width = "0", r.style.height = "1px", r.textContent = " ", s.appendChild(r), s.setAttribute("data-mdc-snackbar-label-text", t), this.timerId !== null && clearTimeout(this.timerId), this.timerId = window.setTimeout(() => {
|
340
269
|
this.timerId = null, s.setAttribute("aria-live", "polite"), s.removeAttribute("data-mdc-snackbar-label-text"), s.textContent = t, this.setValue(this.labelEl);
|
341
|
-
},
|
270
|
+
}, B), s;
|
342
271
|
}
|
343
272
|
render(e, t) {
|
344
273
|
return t ? b`
|
345
274
|
<div class="mdc-snackbar__label" role="status" aria-live="polite">${e}</div>` : b``;
|
346
275
|
}
|
347
276
|
}
|
348
|
-
const
|
277
|
+
const V = F(j);
|
349
278
|
/**
|
350
279
|
* @license
|
351
280
|
* Copyright 2018 Google LLC
|
352
281
|
* SPDX-License-Identifier: Apache-2.0
|
353
282
|
*/
|
354
|
-
const { OPENING_EVENT:
|
355
|
-
class d extends
|
283
|
+
const { OPENING_EVENT: G, OPENED_EVENT: $, CLOSING_EVENT: K, CLOSED_EVENT: X } = g.strings;
|
284
|
+
class d extends M {
|
356
285
|
constructor() {
|
357
|
-
super(...arguments), this.mdcFoundationClass =
|
286
|
+
super(...arguments), this.mdcFoundationClass = g, this.open = !1, this.timeoutMs = 5e3, this.closeOnEscape = !1, this.labelText = "", this.stacked = !1, this.leading = !1, this.reason = "";
|
358
287
|
}
|
359
288
|
render() {
|
360
289
|
const e = {
|
@@ -362,9 +291,9 @@ class d extends F {
|
|
362
291
|
"mdc-snackbar--leading": this.leading
|
363
292
|
};
|
364
293
|
return b`
|
365
|
-
<div class="mdc-snackbar ${
|
294
|
+
<div class="mdc-snackbar ${D(e)}" @keydown="${this._handleKeydown}">
|
366
295
|
<div class="mdc-snackbar__surface">
|
367
|
-
${
|
296
|
+
${V(this.labelText, this.open)}
|
368
297
|
<div class="mdc-snackbar__actions">
|
369
298
|
<slot name="action" @click="${this._handleActionClick}"></slot>
|
370
299
|
<slot name="dismiss" @click="${this._handleDismissClick}"></slot>
|
@@ -373,15 +302,15 @@ class d extends F {
|
|
373
302
|
</div>`;
|
374
303
|
}
|
375
304
|
createAdapter() {
|
376
|
-
return Object.assign(Object.assign({},
|
305
|
+
return Object.assign(Object.assign({}, P(this.mdcRoot)), { announce: () => {
|
377
306
|
}, notifyClosed: (e) => {
|
378
|
-
this.dispatchEvent(new CustomEvent(
|
307
|
+
this.dispatchEvent(new CustomEvent(X, { bubbles: !0, cancelable: !0, detail: { reason: e } }));
|
379
308
|
}, notifyClosing: (e) => {
|
380
|
-
this.open = !1, this.dispatchEvent(new CustomEvent(
|
309
|
+
this.open = !1, this.dispatchEvent(new CustomEvent(K, { bubbles: !0, cancelable: !0, detail: { reason: e } }));
|
381
310
|
}, notifyOpened: () => {
|
382
|
-
this.dispatchEvent(new CustomEvent(
|
311
|
+
this.dispatchEvent(new CustomEvent($, { bubbles: !0, cancelable: !0 }));
|
383
312
|
}, notifyOpening: () => {
|
384
|
-
this.open = !0, this.dispatchEvent(new CustomEvent(
|
313
|
+
this.open = !0, this.dispatchEvent(new CustomEvent(G, { bubbles: !0, cancelable: !0 }));
|
385
314
|
} });
|
386
315
|
}
|
387
316
|
/** @export */
|
@@ -406,26 +335,26 @@ class d extends F {
|
|
406
335
|
}
|
407
336
|
}
|
408
337
|
m([
|
409
|
-
|
338
|
+
C(".mdc-snackbar")
|
410
339
|
], d.prototype, "mdcRoot", void 0);
|
411
340
|
m([
|
412
|
-
|
341
|
+
C(".mdc-snackbar__label")
|
413
342
|
], d.prototype, "labelElement", void 0);
|
414
343
|
m([
|
415
344
|
l({ type: Boolean, reflect: !0 }),
|
416
|
-
|
417
|
-
this.mdcFoundation && (
|
345
|
+
f(function(i) {
|
346
|
+
this.mdcFoundation && (i ? this.mdcFoundation.open() : (this.mdcFoundation.close(this.reason), this.reason = ""));
|
418
347
|
})
|
419
348
|
], d.prototype, "open", void 0);
|
420
349
|
m([
|
421
|
-
|
422
|
-
this.mdcFoundation.setTimeoutMs(
|
350
|
+
f(function(i) {
|
351
|
+
this.mdcFoundation.setTimeoutMs(i);
|
423
352
|
}),
|
424
353
|
l({ type: Number })
|
425
354
|
], d.prototype, "timeoutMs", void 0);
|
426
355
|
m([
|
427
|
-
|
428
|
-
this.mdcFoundation.setCloseOnEscape(
|
356
|
+
f(function(i) {
|
357
|
+
this.mdcFoundation.setCloseOnEscape(i);
|
429
358
|
}),
|
430
359
|
l({ type: Boolean })
|
431
360
|
], d.prototype, "closeOnEscape", void 0);
|
@@ -443,21 +372,21 @@ m([
|
|
443
372
|
* Copyright 2021 Google LLC
|
444
373
|
* SPDX-LIcense-Identifier: Apache-2.0
|
445
374
|
*/
|
446
|
-
const
|
375
|
+
const H = T`.mdc-snackbar{z-index:8;margin:8px;display:none;position:fixed;right:0;bottom:0;left:0;align-items:center;justify-content:center;box-sizing:border-box;pointer-events:none;-webkit-tap-highlight-color:rgba(0,0,0,0)}.mdc-snackbar__surface{background-color:#333333}.mdc-snackbar__label{color:rgba(255, 255, 255, 0.87)}.mdc-snackbar__surface{min-width:344px}@media(max-width: 480px),(max-width: 344px){.mdc-snackbar__surface{min-width:100%}}.mdc-snackbar__surface{max-width:672px}.mdc-snackbar__surface{box-shadow:0px 3px 5px -1px rgba(0, 0, 0, 0.2),0px 6px 10px 0px rgba(0, 0, 0, 0.14),0px 1px 18px 0px rgba(0,0,0,.12)}.mdc-snackbar__surface{border-radius:4px;border-radius:var(--mdc-shape-small, 4px)}.mdc-snackbar--opening,.mdc-snackbar--open,.mdc-snackbar--closing{display:flex}.mdc-snackbar--open .mdc-snackbar__label,.mdc-snackbar--open .mdc-snackbar__actions{visibility:visible}.mdc-snackbar--leading{justify-content:flex-start}.mdc-snackbar--stacked .mdc-snackbar__label{padding-left:16px;padding-right:8px;padding-bottom:12px}[dir=rtl] .mdc-snackbar--stacked .mdc-snackbar__label,.mdc-snackbar--stacked .mdc-snackbar__label[dir=rtl]{padding-left:8px;padding-right:16px}.mdc-snackbar--stacked .mdc-snackbar__surface{flex-direction:column;align-items:flex-start}.mdc-snackbar--stacked .mdc-snackbar__actions{align-self:flex-end;margin-bottom:8px}.mdc-snackbar__surface{padding-left:0;padding-right:8px;display:flex;align-items:center;justify-content:flex-start;box-sizing:border-box;transform:scale(0.8);opacity:0}.mdc-snackbar__surface::before{position:absolute;box-sizing:border-box;width:100%;height:100%;top:0;left:0;border:1px solid transparent;border-radius:inherit;content:"";pointer-events:none}@media screen and (forced-colors: active){.mdc-snackbar__surface::before{border-color:CanvasText}}[dir=rtl] .mdc-snackbar__surface,.mdc-snackbar__surface[dir=rtl]{padding-left:8px;padding-right:0}.mdc-snackbar--open .mdc-snackbar__surface{transform:scale(1);opacity:1;pointer-events:auto;transition:opacity 150ms 0ms cubic-bezier(0, 0, 0.2, 1),transform 150ms 0ms cubic-bezier(0, 0, 0.2, 1)}.mdc-snackbar--closing .mdc-snackbar__surface{transform:scale(1);transition:opacity 75ms 0ms cubic-bezier(0.4, 0, 1, 1)}.mdc-snackbar__label{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:Roboto, sans-serif;font-family:var(--mdc-typography-body2-font-family, var(--mdc-typography-font-family, Roboto, sans-serif));font-size:0.875rem;font-size:var(--mdc-typography-body2-font-size, 0.875rem);line-height:1.25rem;line-height:var(--mdc-typography-body2-line-height, 1.25rem);font-weight:400;font-weight:var(--mdc-typography-body2-font-weight, 400);letter-spacing:0.0178571429em;letter-spacing:var(--mdc-typography-body2-letter-spacing, 0.0178571429em);text-decoration:inherit;text-decoration:var(--mdc-typography-body2-text-decoration, inherit);text-transform:inherit;text-transform:var(--mdc-typography-body2-text-transform, inherit);padding-left:16px;padding-right:8px;width:100%;flex-grow:1;box-sizing:border-box;margin:0;visibility:hidden;padding-top:14px;padding-bottom:14px}[dir=rtl] .mdc-snackbar__label,.mdc-snackbar__label[dir=rtl]{padding-left:8px;padding-right:16px}.mdc-snackbar__label::before{display:inline;content:attr(data-mdc-snackbar-label-text)}.mdc-snackbar__actions{display:flex;flex-shrink:0;align-items:center;box-sizing:border-box;visibility:hidden}.mdc-snackbar__action:not(:disabled){color:#bb86fc}.mdc-snackbar__action .mdc-button__ripple::before,.mdc-snackbar__action .mdc-button__ripple::after{background-color:#bb86fc;background-color:var(--mdc-ripple-color, #bb86fc)}.mdc-snackbar__action:hover .mdc-button__ripple::before,.mdc-snackbar__action.mdc-ripple-surface--hover .mdc-button__ripple::before{opacity:0.08;opacity:var(--mdc-ripple-hover-opacity, 0.08)}.mdc-snackbar__action.mdc-ripple-upgraded--background-focused .mdc-button__ripple::before,.mdc-snackbar__action:not(.mdc-ripple-upgraded):focus .mdc-button__ripple::before{transition-duration:75ms;opacity:0.24;opacity:var(--mdc-ripple-focus-opacity, 0.24)}.mdc-snackbar__action:not(.mdc-ripple-upgraded) .mdc-button__ripple::after{transition:opacity 150ms linear}.mdc-snackbar__action:not(.mdc-ripple-upgraded):active .mdc-button__ripple::after{transition-duration:75ms;opacity:0.24;opacity:var(--mdc-ripple-press-opacity, 0.24)}.mdc-snackbar__action.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.24)}.mdc-snackbar__dismiss{color:rgba(255, 255, 255, 0.87)}.mdc-snackbar__dismiss .mdc-icon-button__ripple::before,.mdc-snackbar__dismiss .mdc-icon-button__ripple::after{background-color:rgba(255, 255, 255, 0.87);background-color:var(--mdc-ripple-color, rgba(255, 255, 255, 0.87))}.mdc-snackbar__dismiss:hover .mdc-icon-button__ripple::before,.mdc-snackbar__dismiss.mdc-ripple-surface--hover .mdc-icon-button__ripple::before{opacity:0.08;opacity:var(--mdc-ripple-hover-opacity, 0.08)}.mdc-snackbar__dismiss.mdc-ripple-upgraded--background-focused .mdc-icon-button__ripple::before,.mdc-snackbar__dismiss:not(.mdc-ripple-upgraded):focus .mdc-icon-button__ripple::before{transition-duration:75ms;opacity:0.24;opacity:var(--mdc-ripple-focus-opacity, 0.24)}.mdc-snackbar__dismiss:not(.mdc-ripple-upgraded) .mdc-icon-button__ripple::after{transition:opacity 150ms linear}.mdc-snackbar__dismiss:not(.mdc-ripple-upgraded):active .mdc-icon-button__ripple::after{transition-duration:75ms;opacity:0.24;opacity:var(--mdc-ripple-press-opacity, 0.24)}.mdc-snackbar__dismiss.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.24)}.mdc-snackbar__dismiss.mdc-snackbar__dismiss{width:36px;height:36px;padding:6px;font-size:18px}.mdc-snackbar__dismiss.mdc-snackbar__dismiss .mdc-icon-button__focus-ring{display:none}.mdc-snackbar__dismiss.mdc-snackbar__dismiss.mdc-ripple-upgraded--background-focused .mdc-icon-button__focus-ring,.mdc-snackbar__dismiss.mdc-snackbar__dismiss:not(.mdc-ripple-upgraded):focus .mdc-icon-button__focus-ring{display:block;max-height:36px;max-width:36px}@media screen and (forced-colors: active){.mdc-snackbar__dismiss.mdc-snackbar__dismiss.mdc-ripple-upgraded--background-focused .mdc-icon-button__focus-ring,.mdc-snackbar__dismiss.mdc-snackbar__dismiss:not(.mdc-ripple-upgraded):focus .mdc-icon-button__focus-ring{pointer-events:none;border:2px solid transparent;border-radius:6px;box-sizing:content-box;position:absolute;top:50%;left:50%;transform:translate(-50%, -50%);height:100%;width:100%}}@media screen and (forced-colors: active)and (forced-colors: active){.mdc-snackbar__dismiss.mdc-snackbar__dismiss.mdc-ripple-upgraded--background-focused .mdc-icon-button__focus-ring,.mdc-snackbar__dismiss.mdc-snackbar__dismiss:not(.mdc-ripple-upgraded):focus .mdc-icon-button__focus-ring{border-color:CanvasText}}@media screen and (forced-colors: active){.mdc-snackbar__dismiss.mdc-snackbar__dismiss.mdc-ripple-upgraded--background-focused .mdc-icon-button__focus-ring::after,.mdc-snackbar__dismiss.mdc-snackbar__dismiss:not(.mdc-ripple-upgraded):focus .mdc-icon-button__focus-ring::after{content:"";border:2px solid transparent;border-radius:8px;display:block;position:absolute;top:50%;left:50%;transform:translate(-50%, -50%);height:calc(100% + 4px);width:calc(100% + 4px)}}@media screen and (forced-colors: active)and (forced-colors: active){.mdc-snackbar__dismiss.mdc-snackbar__dismiss.mdc-ripple-upgraded--background-focused .mdc-icon-button__focus-ring::after,.mdc-snackbar__dismiss.mdc-snackbar__dismiss:not(.mdc-ripple-upgraded):focus .mdc-icon-button__focus-ring::after{border-color:CanvasText}}.mdc-snackbar__dismiss.mdc-snackbar__dismiss.mdc-icon-button--reduced-size .mdc-icon-button__ripple{width:36px;height:36px;margin-top:0px;margin-bottom:0px;margin-right:0px;margin-left:0px}.mdc-snackbar__dismiss.mdc-snackbar__dismiss.mdc-icon-button--reduced-size.mdc-ripple-upgraded--background-focused .mdc-icon-button__focus-ring,.mdc-snackbar__dismiss.mdc-snackbar__dismiss.mdc-icon-button--reduced-size:not(.mdc-ripple-upgraded):focus .mdc-icon-button__focus-ring{max-height:36px;max-width:36px}.mdc-snackbar__dismiss.mdc-snackbar__dismiss .mdc-icon-button__touch{position:absolute;top:50%;height:36px;left:50%;width:36px;transform:translate(-50%, -50%)}.mdc-snackbar__action+.mdc-snackbar__dismiss{margin-left:8px;margin-right:0}[dir=rtl] .mdc-snackbar__action+.mdc-snackbar__dismiss,.mdc-snackbar__action+.mdc-snackbar__dismiss[dir=rtl]{margin-left:0;margin-right:8px}slot[name=action]::slotted(mwc-button){--mdc-theme-primary: var( --mdc-snackbar-action-color, #bb86fc )}slot[name=dismiss]::slotted(mwc-icon-button){--mdc-icon-size: 18px;--mdc-icon-button-size: 36px;color:rgba(255, 255, 255, 0.87);margin-left:8px;margin-right:0}[dir=rtl] slot[name=dismiss]::slotted(mwc-icon-button),::slotted(mwc-icon-buttonslot[name=dismiss][dir=rtl]){margin-left:0;margin-right:8px}`, Y = `:host{--mdc-snackbar-action-color: var(--mdc-theme-text-primary-on-dark);--mdc-theme-text-primary-on-background: var(--mdc-theme-text-primary-on-dark)}:host ::slotted(cv-icon-button){color:var(--mdc-theme-text-icon-on-dark)}
|
447
376
|
`;
|
448
|
-
var
|
449
|
-
for (var n =
|
450
|
-
(r =
|
451
|
-
return
|
377
|
+
var q = Object.defineProperty, J = Object.getOwnPropertyDescriptor, Q = (i, e, t, a) => {
|
378
|
+
for (var n = a > 1 ? void 0 : a ? J(e, t) : e, s = i.length - 1, r; s >= 0; s--)
|
379
|
+
(r = i[s]) && (n = (a ? r(e, t, n) : r(n)) || n);
|
380
|
+
return a && n && q(e, t, n), n;
|
452
381
|
};
|
453
|
-
let
|
382
|
+
let u = class extends d {
|
454
383
|
};
|
455
|
-
|
456
|
-
|
457
|
-
|
458
|
-
],
|
459
|
-
const
|
384
|
+
u.styles = [H, T`${A(Y)}`];
|
385
|
+
u = Q([
|
386
|
+
I("cv-snackbar")
|
387
|
+
], u);
|
388
|
+
const de = u;
|
460
389
|
export {
|
461
|
-
|
462
|
-
|
390
|
+
u as CovalentSnackbar,
|
391
|
+
de as default
|
463
392
|
};
|