@3t-transform/threeteeui 0.1.7 → 0.1.8
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/dist/cjs/{index-451f61dd.js → index-8ba406f6.js} +91 -3
- package/dist/cjs/loader.cjs.js +3 -18
- package/dist/cjs/tttx-button.cjs.entry.js +2 -2
- package/dist/cjs/tttx-form.cjs.entry.js +1 -1
- package/dist/cjs/tttx-icon.cjs.entry.js +1 -1
- package/dist/cjs/tttx-keyvalue-block.cjs.entry.js +1 -1
- package/dist/cjs/tttx-list.cjs.entry.js +4 -34
- package/dist/cjs/tttx-loading-spinner.cjs.entry.js +1 -1
- package/dist/cjs/tttx-standalone-input.cjs.entry.js +1 -1
- package/dist/cjs/tttx-toolbar.cjs.entry.js +1 -1
- package/dist/cjs/tttx.cjs.js +8 -116
- package/dist/collection/collection-manifest.json +2 -2
- package/dist/collection/components/atoms/tttx-button/tttx-button.css +8 -0
- package/dist/collection/components/molecules/tttx-standalone-input/tttx-standalone-input.stories.js +13 -0
- package/dist/collection/components/molecules/tttx-toolbar/tttx-toolbar.stories.js +1 -1
- package/dist/components/index.d.ts +9 -0
- package/dist/components/index.js +1 -5
- package/dist/components/tttx-button.js +1 -1
- package/dist/components/tttx-list.js +3 -33
- package/dist/esm/{index-0350f122.js → index-5f9b72ff.js} +91 -4
- package/dist/esm/loader.js +3 -18
- package/dist/esm/polyfills/css-shim.js +1 -1
- package/dist/esm/tttx-button.entry.js +2 -2
- package/dist/esm/tttx-form.entry.js +1 -1
- package/dist/esm/tttx-icon.entry.js +1 -1
- package/dist/esm/tttx-keyvalue-block.entry.js +1 -1
- package/dist/esm/tttx-list.entry.js +4 -34
- package/dist/esm/tttx-loading-spinner.entry.js +1 -1
- package/dist/esm/tttx-standalone-input.entry.js +1 -1
- package/dist/esm/tttx-toolbar.entry.js +1 -1
- package/dist/esm/tttx.js +5 -116
- package/dist/tttx/index.esm.js +0 -1
- package/dist/tttx/{p-0a85dda4.entry.js → p-0342cc46.entry.js} +1 -1
- package/dist/tttx/p-1290dcd7.entry.js +3 -0
- package/dist/tttx/{p-a0179cb1.entry.js → p-1b394414.entry.js} +1 -1
- package/dist/tttx/{p-5cae1beb.entry.js → p-405219b2.entry.js} +1 -1
- package/dist/tttx/{p-4f3958fa.entry.js → p-435c62b3.entry.js} +1 -1
- package/dist/tttx/{p-1b015a9d.entry.js → p-4ecc9e8b.entry.js} +1 -1
- package/dist/tttx/{p-cc6644c9.entry.js → p-9cff9c64.entry.js} +1 -1
- package/dist/tttx/{p-92465671.entry.js → p-adf35f58.entry.js} +1 -1
- package/dist/tttx/p-c4b803fc.js +2 -0
- package/dist/tttx/tttx.esm.js +1 -129
- package/dist/types/components/molecules/tttx-standalone-input/tttx-standalone-input.d.ts +6 -6
- package/dist/types/components/molecules/tttx-standalone-input/tttx-standalone-input.stories.d.ts +1 -0
- package/dist/types/stencil-public-runtime.d.ts +59 -3
- package/loader/index.d.ts +9 -0
- package/package.json +1 -1
- package/dist/cjs/app-globals-3a1e7e63.js +0 -5
- package/dist/cjs/css-shim-211819bc.js +0 -6
- package/dist/cjs/dom-9deb26c8.js +0 -75
- package/dist/cjs/index-11cfdabe.js +0 -3297
- package/dist/cjs/shadow-css-bf3843d2.js +0 -389
- package/dist/collection/components/atoms/tttx-button/test/tttx-button.e2e.js +0 -9
- package/dist/collection/components/atoms/tttx-button/test/tttx-button.spec.js +0 -83
- package/dist/collection/components/atoms/tttx-icon/test/tttx-icon.e2e.js +0 -9
- package/dist/collection/components/atoms/tttx-icon/test/tttx-icon.spec.js +0 -16
- package/dist/collection/components/atoms/tttx-keyvalue-block/test/tttx-keyvalue-block.spec.js +0 -216
- package/dist/collection/components/atoms/tttx-loading-spinner/Test/tttx-loading-spinner.spec.js +0 -64
- package/dist/collection/components/molecules/tttx-form/lib/setErrorState.spec.js +0 -38
- package/dist/collection/components/molecules/tttx-form/lib/validityCheck.spec.js +0 -214
- package/dist/collection/components/molecules/tttx-form/test/tttx-form.e2e.js +0 -9
- package/dist/collection/components/molecules/tttx-form/test/tttx-form.spec.js +0 -232
- package/dist/collection/components/molecules/tttx-list/test/ttttx-list.spec.e2e.js +0 -26
- package/dist/collection/components/molecules/tttx-list/test/tttx-list.spec.js +0 -183
- package/dist/collection/components/molecules/tttx-standalone-input/test/tttx-standalone-input.e2e.js +0 -9
- package/dist/collection/components/molecules/tttx-standalone-input/test/tttx-standalone-input.spec.js +0 -219
- package/dist/collection/components/molecules/tttx-toolbar/test/tttx-toolbar.test.js +0 -0
- package/dist/collection/shared/test/domsanitiser.options.spec.js +0 -23
- package/dist/esm/app-globals-0f993ce5.js +0 -3
- package/dist/esm/css-shim-9d54a2f2.js +0 -4
- package/dist/esm/dom-6be6f662.js +0 -73
- package/dist/esm/index-dbe25028.js +0 -3262
- package/dist/esm/shadow-css-ed4599f8.js +0 -387
- package/dist/tttx/app-globals-0f993ce5.js +0 -3
- package/dist/tttx/css-shim-9d54a2f2.js +0 -4
- package/dist/tttx/dom-6be6f662.js +0 -73
- package/dist/tttx/index-dbe25028.js +0 -3262
- package/dist/tttx/p-62869344.js +0 -2
- package/dist/tttx/p-cd1565e0.entry.js +0 -3
- package/dist/tttx/shadow-css-ed4599f8.js +0 -387
- package/dist/tttx/tttx-button.entry.js +0 -30
- package/dist/tttx/tttx-form.entry.js +0 -373
- package/dist/tttx/tttx-icon.entry.js +0 -17
- package/dist/tttx/tttx-keyvalue-block.entry.js +0 -63
- package/dist/tttx/tttx-list.entry.js +0 -1730
- package/dist/tttx/tttx-loading-spinner.entry.js +0 -22
- package/dist/tttx/tttx-standalone-input.entry.js +0 -66
- package/dist/tttx/tttx-toolbar.entry.js +0 -16
- package/dist/types/components/atoms/tttx-button/test/tttx-button.e2e.d.ts +0 -1
- package/dist/types/components/atoms/tttx-button/test/tttx-button.spec.d.ts +0 -1
- package/dist/types/components/atoms/tttx-icon/test/tttx-icon.e2e.d.ts +0 -1
- package/dist/types/components/atoms/tttx-icon/test/tttx-icon.spec.d.ts +0 -1
- package/dist/types/components/atoms/tttx-keyvalue-block/test/tttx-keyvalue-block.spec.d.ts +0 -1
- package/dist/types/components/atoms/tttx-loading-spinner/Test/tttx-loading-spinner.spec.d.ts +0 -1
- package/dist/types/components/molecules/tttx-form/lib/setErrorState.spec.d.ts +0 -1
- package/dist/types/components/molecules/tttx-form/lib/validityCheck.spec.d.ts +0 -1
- package/dist/types/components/molecules/tttx-form/test/tttx-form.e2e.d.ts +0 -1
- package/dist/types/components/molecules/tttx-form/test/tttx-form.spec.d.ts +0 -1
- package/dist/types/components/molecules/tttx-list/test/ttttx-list.spec.e2e.d.ts +0 -1
- package/dist/types/components/molecules/tttx-list/test/tttx-list.spec.d.ts +0 -1
- package/dist/types/components/molecules/tttx-standalone-input/test/tttx-standalone-input.e2e.d.ts +0 -1
- package/dist/types/components/molecules/tttx-standalone-input/test/tttx-standalone-input.spec.d.ts +0 -1
- package/dist/types/components/molecules/tttx-toolbar/test/tttx-toolbar.test.d.ts +0 -0
- package/dist/types/shared/test/domsanitiser.options.spec.d.ts +0 -1
|
@@ -3,43 +3,16 @@ import { d as defineCustomElement$2 } from './tttx-icon2.js';
|
|
|
3
3
|
|
|
4
4
|
var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
|
|
5
5
|
|
|
6
|
-
function getDefaultExportFromCjs (x) {
|
|
7
|
-
return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, 'default') ? x['default'] : x;
|
|
8
|
-
}
|
|
9
|
-
|
|
10
6
|
function createCommonjsModule(fn, basedir, module) {
|
|
11
7
|
return module = {
|
|
12
8
|
path: basedir,
|
|
13
9
|
exports: {},
|
|
14
10
|
require: function (path, base) {
|
|
15
|
-
return commonjsRequire(
|
|
11
|
+
return commonjsRequire();
|
|
16
12
|
}
|
|
17
13
|
}, fn(module, module.exports), module.exports;
|
|
18
14
|
}
|
|
19
15
|
|
|
20
|
-
function getDefaultExportFromNamespaceIfPresent (n) {
|
|
21
|
-
return n && Object.prototype.hasOwnProperty.call(n, 'default') ? n['default'] : n;
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
function getDefaultExportFromNamespaceIfNotNamed (n) {
|
|
25
|
-
return n && Object.prototype.hasOwnProperty.call(n, 'default') && Object.keys(n).length === 1 ? n['default'] : n;
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
function getAugmentedNamespace(n) {
|
|
29
|
-
if (n.__esModule) return n;
|
|
30
|
-
var a = Object.defineProperty({}, '__esModule', {value: true});
|
|
31
|
-
Object.keys(n).forEach(function (k) {
|
|
32
|
-
var d = Object.getOwnPropertyDescriptor(n, k);
|
|
33
|
-
Object.defineProperty(a, k, d.get ? d : {
|
|
34
|
-
enumerable: true,
|
|
35
|
-
get: function () {
|
|
36
|
-
return n[k];
|
|
37
|
-
}
|
|
38
|
-
});
|
|
39
|
-
});
|
|
40
|
-
return a;
|
|
41
|
-
}
|
|
42
|
-
|
|
43
16
|
function commonjsRequire () {
|
|
44
17
|
throw new Error('Dynamic requires are not currently supported by @rollup/plugin-commonjs');
|
|
45
18
|
}
|
|
@@ -48,11 +21,8 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
48
21
|
/*! @license DOMPurify 3.0.3 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.0.3/LICENSE */
|
|
49
22
|
|
|
50
23
|
(function (global, factory) {
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, global.DOMPurify = factory());
|
|
54
|
-
})(commonjsGlobal, (function () { 'use strict';
|
|
55
|
-
|
|
24
|
+
module.exports = factory() ;
|
|
25
|
+
})(commonjsGlobal, (function () {
|
|
56
26
|
const {
|
|
57
27
|
entries,
|
|
58
28
|
setPrototypeOf,
|
|
@@ -41,6 +41,18 @@ const isComplexType = (o) => {
|
|
|
41
41
|
o = typeof o;
|
|
42
42
|
return o === 'object' || o === 'function';
|
|
43
43
|
};
|
|
44
|
+
/**
|
|
45
|
+
* Helper method for querying a `meta` tag that contains a nonce value
|
|
46
|
+
* out of a DOM's head.
|
|
47
|
+
*
|
|
48
|
+
* @param doc The DOM containing the `head` to query against
|
|
49
|
+
* @returns The content of the meta tag representing the nonce value, or `undefined` if no tag
|
|
50
|
+
* exists or the tag has no content.
|
|
51
|
+
*/
|
|
52
|
+
function queryNonceMetaTagContent(doc) {
|
|
53
|
+
var _a, _b, _c;
|
|
54
|
+
return (_c = (_b = (_a = doc.head) === null || _a === void 0 ? void 0 : _a.querySelector('meta[name="csp-nonce"]')) === null || _b === void 0 ? void 0 : _b.getAttribute('content')) !== null && _c !== void 0 ? _c : undefined;
|
|
55
|
+
}
|
|
44
56
|
/**
|
|
45
57
|
* Production h() function based on Preact by
|
|
46
58
|
* Jason Miller (@developit)
|
|
@@ -49,7 +61,6 @@ const isComplexType = (o) => {
|
|
|
49
61
|
*
|
|
50
62
|
* Modified for Stencil's compiler and vdom
|
|
51
63
|
*/
|
|
52
|
-
// const stack: any[] = [];
|
|
53
64
|
// export function h(nodeName: string | d.FunctionalComponent, vnodeData: d.PropsType, child?: d.ChildType): d.VNode;
|
|
54
65
|
// export function h(nodeName: string | d.FunctionalComponent, vnodeData: d.PropsType, ...children: d.ChildType[]): d.VNode;
|
|
55
66
|
const h = (nodeName, vnodeData, ...children) => {
|
|
@@ -100,6 +111,14 @@ const h = (nodeName, vnodeData, ...children) => {
|
|
|
100
111
|
}
|
|
101
112
|
return vnode;
|
|
102
113
|
};
|
|
114
|
+
/**
|
|
115
|
+
* A utility function for creating a virtual DOM node from a tag and some
|
|
116
|
+
* possible text content.
|
|
117
|
+
*
|
|
118
|
+
* @param tag the tag for this element
|
|
119
|
+
* @param text possible text content for the node
|
|
120
|
+
* @returns a newly-minted virtual DOM node
|
|
121
|
+
*/
|
|
103
122
|
const newVNode = (tag, text) => {
|
|
104
123
|
const vnode = {
|
|
105
124
|
$flags$: 0,
|
|
@@ -114,6 +133,12 @@ const newVNode = (tag, text) => {
|
|
|
114
133
|
return vnode;
|
|
115
134
|
};
|
|
116
135
|
const Host = {};
|
|
136
|
+
/**
|
|
137
|
+
* Check whether a given node is a Host node or not
|
|
138
|
+
*
|
|
139
|
+
* @param node the virtual DOM node to check
|
|
140
|
+
* @returns whether it's a Host node or not
|
|
141
|
+
*/
|
|
117
142
|
const isHost = (node) => node && node.$tag$ === Host;
|
|
118
143
|
/**
|
|
119
144
|
* Parse a new property value for a given property type.
|
|
@@ -202,6 +227,7 @@ const registerStyle = (scopeId, cssText, allowCS) => {
|
|
|
202
227
|
styles.set(scopeId, style);
|
|
203
228
|
};
|
|
204
229
|
const addStyle = (styleContainerNode, cmpMeta, mode, hostElm) => {
|
|
230
|
+
var _a;
|
|
205
231
|
let scopeId = getScopeId(cmpMeta);
|
|
206
232
|
const style = styles.get(scopeId);
|
|
207
233
|
// if an element is NOT connected then getRootNode() will return the wrong root node
|
|
@@ -221,6 +247,11 @@ const addStyle = (styleContainerNode, cmpMeta, mode, hostElm) => {
|
|
|
221
247
|
styleElm = doc.createElement('style');
|
|
222
248
|
styleElm.innerHTML = style;
|
|
223
249
|
}
|
|
250
|
+
// Apply CSP nonce to the style tag if it exists
|
|
251
|
+
const nonce = (_a = plt.$nonce$) !== null && _a !== void 0 ? _a : queryNonceMetaTagContent(doc);
|
|
252
|
+
if (nonce != null) {
|
|
253
|
+
styleElm.setAttribute('nonce', nonce);
|
|
254
|
+
}
|
|
224
255
|
styleContainerNode.insertBefore(styleElm, styleContainerNode.querySelector('link'));
|
|
225
256
|
}
|
|
226
257
|
if (appliedStyles) {
|
|
@@ -428,6 +459,21 @@ const createElm = (oldParentVNode, newParentVNode, childIndex, parentElm) => {
|
|
|
428
459
|
}
|
|
429
460
|
return elm;
|
|
430
461
|
};
|
|
462
|
+
/**
|
|
463
|
+
* Create DOM nodes corresponding to a list of {@link d.Vnode} objects and
|
|
464
|
+
* add them to the DOM in the appropriate place.
|
|
465
|
+
*
|
|
466
|
+
* @param parentElm the DOM node which should be used as a parent for the new
|
|
467
|
+
* DOM nodes
|
|
468
|
+
* @param before a child of the `parentElm` which the new children should be
|
|
469
|
+
* inserted before (optional)
|
|
470
|
+
* @param parentVNode the parent virtual DOM node
|
|
471
|
+
* @param vnodes the new child virtual DOM nodes to produce DOM nodes for
|
|
472
|
+
* @param startIdx the index in the child virtual DOM nodes at which to start
|
|
473
|
+
* creating DOM nodes (inclusive)
|
|
474
|
+
* @param endIdx the index in the child virtual DOM nodes at which to stop
|
|
475
|
+
* creating DOM nodes (inclusive)
|
|
476
|
+
*/
|
|
431
477
|
const addVnodes = (parentElm, before, parentVNode, vnodes, startIdx, endIdx) => {
|
|
432
478
|
let containerElm = (parentElm);
|
|
433
479
|
let childNode;
|
|
@@ -444,6 +490,19 @@ const addVnodes = (parentElm, before, parentVNode, vnodes, startIdx, endIdx) =>
|
|
|
444
490
|
}
|
|
445
491
|
}
|
|
446
492
|
};
|
|
493
|
+
/**
|
|
494
|
+
* Remove the DOM elements corresponding to a list of {@link d.VNode} objects.
|
|
495
|
+
* This can be used to, for instance, clean up after a list of children which
|
|
496
|
+
* should no longer be shown.
|
|
497
|
+
*
|
|
498
|
+
* This function also handles some of Stencil's slot relocation logic.
|
|
499
|
+
*
|
|
500
|
+
* @param vnodes a list of virtual DOM nodes to remove
|
|
501
|
+
* @param startIdx the index at which to start removing nodes (inclusive)
|
|
502
|
+
* @param endIdx the index at which to stop removing nodes (inclusive)
|
|
503
|
+
* @param vnode a VNode
|
|
504
|
+
* @param elm an element
|
|
505
|
+
*/
|
|
447
506
|
const removeVnodes = (vnodes, startIdx, endIdx, vnode, elm) => {
|
|
448
507
|
for (; startIdx <= endIdx; ++startIdx) {
|
|
449
508
|
if ((vnode = vnodes[startIdx])) {
|
|
@@ -636,7 +695,8 @@ const updateChildren = (parentElm, oldCh, newVNode, newCh) => {
|
|
|
636
695
|
*
|
|
637
696
|
* So, in other words, if `key` attrs are not set on VNodes which may be
|
|
638
697
|
* changing order within a `children` array or something along those lines then
|
|
639
|
-
* we could obtain a false
|
|
698
|
+
* we could obtain a false negative and then have to do needless re-rendering
|
|
699
|
+
* (i.e. we'd say two VNodes aren't equal when in fact they should be).
|
|
640
700
|
*
|
|
641
701
|
* @param leftVNode the first VNode to check
|
|
642
702
|
* @param rightVNode the second VNode to check
|
|
@@ -706,6 +766,18 @@ const callNodeRefs = (vNode) => {
|
|
|
706
766
|
vNode.$children$ && vNode.$children$.map(callNodeRefs);
|
|
707
767
|
}
|
|
708
768
|
};
|
|
769
|
+
/**
|
|
770
|
+
* The main entry point for Stencil's virtual DOM-based rendering engine
|
|
771
|
+
*
|
|
772
|
+
* Given a {@link d.HostRef} container and some virtual DOM nodes, this
|
|
773
|
+
* function will handle creating a virtual DOM tree with a single root, patching
|
|
774
|
+
* the current virtual DOM tree onto an old one (if any), dealing with slot
|
|
775
|
+
* relocation, and reflecting attributes.
|
|
776
|
+
*
|
|
777
|
+
* @param hostRef data needed to root and render the virtual DOM tree, such as
|
|
778
|
+
* the DOM node into which it should be rendered.
|
|
779
|
+
* @param renderFnResults the virtual DOM nodes to be rendered
|
|
780
|
+
*/
|
|
709
781
|
const renderVdom = (hostRef, renderFnResults) => {
|
|
710
782
|
const hostElm = hostRef.$hostElement$;
|
|
711
783
|
const oldVNode = hostRef.$vnode$ || newVNode(null, null);
|
|
@@ -1152,6 +1224,7 @@ const disconnectedCallback = (elm) => {
|
|
|
1152
1224
|
}
|
|
1153
1225
|
};
|
|
1154
1226
|
const bootstrapLazy = (lazyBundles, options = {}) => {
|
|
1227
|
+
var _a;
|
|
1155
1228
|
const endBootstrap = createTime();
|
|
1156
1229
|
const cmpTags = [];
|
|
1157
1230
|
const exclude = options.exclude || [];
|
|
@@ -1178,7 +1251,9 @@ const bootstrapLazy = (lazyBundles, options = {}) => {
|
|
|
1178
1251
|
{
|
|
1179
1252
|
cmpMeta.$watchers$ = {};
|
|
1180
1253
|
}
|
|
1181
|
-
const tagName =
|
|
1254
|
+
const tagName = options.transformTagName
|
|
1255
|
+
? options.transformTagName(cmpMeta.$tagName$)
|
|
1256
|
+
: cmpMeta.$tagName$;
|
|
1182
1257
|
const HostElement = class extends HTMLElement {
|
|
1183
1258
|
// StencilLazyHost
|
|
1184
1259
|
constructor(self) {
|
|
@@ -1228,6 +1303,11 @@ const bootstrapLazy = (lazyBundles, options = {}) => {
|
|
|
1228
1303
|
{
|
|
1229
1304
|
visibilityStyle.innerHTML = cmpTags + HYDRATED_CSS;
|
|
1230
1305
|
visibilityStyle.setAttribute('data-styles', '');
|
|
1306
|
+
// Apply CSP nonce to the style tag if it exists
|
|
1307
|
+
const nonce = (_a = plt.$nonce$) !== null && _a !== void 0 ? _a : queryNonceMetaTagContent(doc);
|
|
1308
|
+
if (nonce != null) {
|
|
1309
|
+
visibilityStyle.setAttribute('nonce', nonce);
|
|
1310
|
+
}
|
|
1231
1311
|
head.insertBefore(visibilityStyle, metaCharset ? metaCharset.nextSibling : head.firstChild);
|
|
1232
1312
|
}
|
|
1233
1313
|
// Process deferred connectedCallbacks now all components have been registered
|
|
@@ -1243,6 +1323,13 @@ const bootstrapLazy = (lazyBundles, options = {}) => {
|
|
|
1243
1323
|
// Fallback appLoad event
|
|
1244
1324
|
endBootstrap();
|
|
1245
1325
|
};
|
|
1326
|
+
/**
|
|
1327
|
+
* Assigns the given value to the nonce property on the runtime platform object.
|
|
1328
|
+
* During runtime, this value is used to set the nonce attribute on all dynamically created script and style tags.
|
|
1329
|
+
* @param nonce The value to be assigned to the platform nonce property.
|
|
1330
|
+
* @returns void
|
|
1331
|
+
*/
|
|
1332
|
+
const setNonce = (nonce) => (plt.$nonce$ = nonce);
|
|
1246
1333
|
const hostRefs = /*@__PURE__*/ new WeakMap();
|
|
1247
1334
|
const getHostRef = (ref) => hostRefs.get(ref);
|
|
1248
1335
|
const registerInstance = (lazyInstance, hostRef) => hostRefs.set((hostRef.$lazyInstance$ = lazyInstance), hostRef);
|
|
@@ -1349,4 +1436,4 @@ const flush = () => {
|
|
|
1349
1436
|
const nextTick = /*@__PURE__*/ (cb) => promiseResolve().then(cb);
|
|
1350
1437
|
const writeTask = /*@__PURE__*/ queueTask(queueDomWrites, true);
|
|
1351
1438
|
|
|
1352
|
-
export { Host as H, bootstrapLazy as b, createEvent as c, h, promiseResolve as p, registerInstance as r };
|
|
1439
|
+
export { Host as H, bootstrapLazy as b, createEvent as c, h, promiseResolve as p, registerInstance as r, setNonce as s };
|
package/dist/esm/loader.js
CHANGED
|
@@ -1,31 +1,16 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
1
|
+
import { p as promiseResolve, b as bootstrapLazy } from './index-5f9b72ff.js';
|
|
2
|
+
export { s as setNonce } from './index-5f9b72ff.js';
|
|
3
3
|
|
|
4
4
|
/*
|
|
5
|
-
Stencil Client Patch Esm v2.
|
|
5
|
+
Stencil Client Patch Esm v2.22.3 | MIT Licensed | https://stenciljs.com
|
|
6
6
|
*/
|
|
7
7
|
const patchEsm = () => {
|
|
8
|
-
// NOTE!! This fn cannot use async/await!
|
|
9
|
-
// @ts-ignore
|
|
10
|
-
if (BUILD.cssVarShim && !(CSS && CSS.supports && CSS.supports('color', 'var(--c)'))) {
|
|
11
|
-
// @ts-ignore
|
|
12
|
-
return import(/* webpackChunkName: "polyfills-css-shim" */ './css-shim-9d54a2f2.js').then(() => {
|
|
13
|
-
if ((plt.$cssShim$ = win.__cssshim)) {
|
|
14
|
-
return plt.$cssShim$.i();
|
|
15
|
-
}
|
|
16
|
-
else {
|
|
17
|
-
// for better minification
|
|
18
|
-
return 0;
|
|
19
|
-
}
|
|
20
|
-
});
|
|
21
|
-
}
|
|
22
8
|
return promiseResolve();
|
|
23
9
|
};
|
|
24
10
|
|
|
25
11
|
const defineCustomElements = (win, options) => {
|
|
26
12
|
if (typeof window === 'undefined') return Promise.resolve();
|
|
27
13
|
return patchEsm().then(() => {
|
|
28
|
-
globalScripts();
|
|
29
14
|
return bootstrapLazy([["tttx-button",[[1,"tttx-button",{"notext":[4],"icon":[1],"iconposition":[1],"design":[1]}]]],["tttx-list",[[1,"tttx-list",{"data":[1025],"name":[1]}]]],["tttx-standalone-input",[[2,"tttx-standalone-input",{"label":[1],"showerrormsg":[4],"showerrorbubble":[4],"errormsg":[1],"iconleft":[1],"iconright":[1],"inputicon":[1],"inline":[4],"inputAutocapitalize":[1,"input-autocapitalize"],"inputAutofocus":[4,"input-autofocus"],"inputKeyhint":[1,"input-keyhint"],"inputIndex":[8,"input-index"],"inputTitle":[1,"input-title"],"autocomplete":[1],"checked":[4],"disabled":[4],"max":[8],"maxlength":[8],"min":[8],"minlength":[8],"name":[1],"pattern":[1],"placeholder":[1],"readonly":[8],"required":[4],"step":[8],"type":[1],"value":[1032]}]]],["tttx-form",[[1,"tttx-form",{"formschema":[1032],"submitValue":[1032,"submit-value"]}]]],["tttx-keyvalue-block",[[1,"tttx-keyvalue-block",{"keyvalues":[8],"horizontal":[4]}]]],["tttx-loading-spinner",[[1,"tttx-loading-spinner",{"loadingMessage":[1028,"loading-message"],"size":[1025]}]]],["tttx-toolbar",[[1,"tttx-toolbar",{"border":[4]}]]],["tttx-icon",[[1,"tttx-icon",{"icon":[1],"color":[1]}]]]], options);
|
|
30
15
|
});
|
|
31
16
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
var __assign=this&&this.__assign||function(){return(__assign=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var s in t=arguments[r])Object.prototype.hasOwnProperty.call(t,s)&&(e[s]=t[s]);return e}).apply(this,arguments)},StyleNode=function(){this.start=0,this.end=0,this.previous=null,this.parent=null,this.rules=null,this.parsedCssText="",this.cssText="",this.atRule=!1,this.type=0,this.keyframesName="",this.selector="",this.parsedSelector=""};function parse(e){return parseCss(lex(e=clean(e)),e)}function clean(e){return e.replace(RX.comments,"").replace(RX.port,"")}function lex(e){var t=new StyleNode;t.start=0,t.end=e.length;for(var r=t,n=0,s=e.length;n<s;n++)if(e[n]===OPEN_BRACE){r.rules||(r.rules=[]);var o=r,a=o.rules[o.rules.length-1]||null;(r=new StyleNode).start=n+1,r.parent=o,r.previous=a,o.rules.push(r)}else e[n]===CLOSE_BRACE&&(r.end=n+1,r=r.parent||t);return t}function parseCss(e,t){var r=t.substring(e.start,e.end-1);if(e.parsedCssText=e.cssText=r.trim(),e.parent){var n=e.previous?e.previous.end:e.parent.start;r=(r=(r=_expandUnicodeEscapes(r=t.substring(n,e.start-1))).replace(RX.multipleSpaces," ")).substring(r.lastIndexOf(";")+1);var s=e.parsedSelector=e.selector=r.trim();e.atRule=0===s.indexOf(AT_START),e.atRule?0===s.indexOf(MEDIA_START)?e.type=types.MEDIA_RULE:s.match(RX.keyframesRule)&&(e.type=types.KEYFRAMES_RULE,e.keyframesName=e.selector.split(RX.multipleSpaces).pop()):0===s.indexOf(VAR_START)?e.type=types.MIXIN_RULE:e.type=types.STYLE_RULE}var o=e.rules;if(o)for(var a=0,i=o.length,l=void 0;a<i&&(l=o[a]);a++)parseCss(l,t);return e}function _expandUnicodeEscapes(e){return e.replace(/\\([0-9a-f]{1,6})\s/gi,(function(){for(var e=arguments[1],t=6-e.length;t--;)e="0"+e;return"\\"+e}))}var types={STYLE_RULE:1,KEYFRAMES_RULE:7,MEDIA_RULE:4,MIXIN_RULE:1e3},OPEN_BRACE="{",CLOSE_BRACE="}",RX={comments:/\/\*[^*]*\*+([^/*][^*]*\*+)*\//gim,port:/@import[^;]*;/gim,customProp:/(?:^[^;\-\s}]+)?--[^;{}]*?:[^{};]*?(?:[;\n]|$)/gim,mixinProp:/(?:^[^;\-\s}]+)?--[^;{}]*?:[^{};]*?{[^}]*?}(?:[;\n]|$)?/gim,mixinApply:/@apply\s*\(?[^);]*\)?\s*(?:[;\n]|$)?/gim,varApply:/[^;:]*?:[^;]*?var\([^;]*\)(?:[;\n]|$)?/gim,keyframesRule:/^@[^\s]*keyframes/,multipleSpaces:/\s+/g},VAR_START="--",MEDIA_START="@media",AT_START="@",VAR_USAGE_START=/\bvar\(/,VAR_ASSIGN_START=/\B--[\w-]+\s*:/,COMMENTS=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//gim,TRAILING_LINES=/^[\t ]+\n/gm;function findRegex(e,t,r){e.lastIndex=0;var n=t.substring(r).match(e);if(n){var s=r+n.index;return{start:s,end:s+n[0].length}}return null}function resolveVar(e,t,r){return e[t]?e[t]:r?executeTemplate(r,e):""}function findVarEndIndex(e,t){for(var r=0,n=t;n<e.length;n++){var s=e[n];if("("===s)r++;else if(")"===s&&--r<=0)return n+1}return n}function parseVar(e,t){var r=findRegex(VAR_USAGE_START,e,t);if(!r)return null;var n=findVarEndIndex(e,r.start),s=e.substring(r.end,n-1).split(","),o=s[0],a=s.slice(1);return{start:r.start,end:n,propName:o.trim(),fallback:a.length>0?a.join(",").trim():void 0}}function compileVar(e,t,r){var n=parseVar(e,r);if(!n)return t.push(e.substring(r,e.length)),e.length;var s=n.propName,o=null!=n.fallback?compileTemplate(n.fallback):void 0;return t.push(e.substring(r,n.start),(function(e){return resolveVar(e,s,o)})),n.end}function executeTemplate(e,t){for(var r="",n=0;n<e.length;n++){var s=e[n];r+="string"==typeof s?s:s(t)}return r}function findEndValue(e,t){for(var r=!1,n=!1,s=t;s<e.length;s++){var o=e[s];if(r)n&&'"'===o&&(r=!1),n||"'"!==o||(r=!1);else if('"'===o)r=!0,n=!0;else if("'"===o)r=!0,n=!1;else{if(";"===o)return s+1;if("}"===o)return s}}return s}function removeCustomAssigns(e){for(var t="",r=0;;){var n=findRegex(VAR_ASSIGN_START,e,r),s=n?n.start:e.length;if(t+=e.substring(r,s),!n)break;r=findEndValue(e,s)}return t}function compileTemplate(e){var t=0;e=removeCustomAssigns(e=e.replace(COMMENTS,"")).replace(TRAILING_LINES,"");for(var r=[];t<e.length;)t=compileVar(e,r,t);return r}function resolveValues(e){var t={};e.forEach((function(e){e.declarations.forEach((function(e){t[e.prop]=e.value}))}));for(var r={},n=Object.entries(t),s=function(e){var t=!1;if(n.forEach((function(e){var n=e[0],s=executeTemplate(e[1],r);s!==r[n]&&(r[n]=s,t=!0)})),!t)return"break"},o=0;o<10;o++){if("break"===s())break}return r}function getSelectors(e,t){if(void 0===t&&(t=0),!e.rules)return[];var r=[];return e.rules.filter((function(e){return e.type===types.STYLE_RULE})).forEach((function(e){var n=getDeclarations(e.cssText);n.length>0&&e.parsedSelector.split(",").forEach((function(e){e=e.trim(),r.push({selector:e,declarations:n,specificity:computeSpecificity(),nu:t})})),t++})),r}function computeSpecificity(e){return 1}var IMPORTANT="!important",FIND_DECLARATIONS=/(?:^|[;\s{]\s*)(--[\w-]*?)\s*:\s*(?:((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};{])+)|\{([^}]*)\}(?:(?=[;\s}])|$))/gm;function getDeclarations(e){for(var t,r=[];t=FIND_DECLARATIONS.exec(e.trim());){var n=normalizeValue(t[2]),s=n.value,o=n.important;r.push({prop:t[1].trim(),value:compileTemplate(s),important:o})}return r}function normalizeValue(e){var t=(e=e.replace(/\s+/gim," ").trim()).endsWith(IMPORTANT);return t&&(e=e.slice(0,e.length-IMPORTANT.length).trim()),{value:e,important:t}}function getActiveSelectors(e,t,r){var n=[],s=getScopesForElement(t,e);return r.forEach((function(e){return n.push(e)})),s.forEach((function(e){return n.push(e)})),sortSelectors(getSelectorsForScopes(n).filter((function(t){return matches(e,t.selector)})))}function getScopesForElement(e,t){for(var r=[];t;){var n=e.get(t);n&&r.push(n),t=t.parentElement}return r}function getSelectorsForScopes(e){var t=[];return e.forEach((function(e){t.push.apply(t,e.selectors)})),t}function sortSelectors(e){return e.sort((function(e,t){return e.specificity===t.specificity?e.nu-t.nu:e.specificity-t.specificity})),e}function matches(e,t){return":root"===t||"html"===t||e.matches(t)}function parseCSS(e){var t=parse(e),r=compileTemplate(e);return{original:e,template:r,selectors:getSelectors(t),usesCssVars:r.length>1}}function addGlobalStyle(e,t){if(e.some((function(e){return e.styleEl===t})))return!1;var r=parseCSS(t.textContent);return r.styleEl=t,e.push(r),!0}function updateGlobalScopes(e){var t=resolveValues(getSelectorsForScopes(e));e.forEach((function(e){e.usesCssVars&&(e.styleEl.textContent=executeTemplate(e.template,t))}))}function reScope(e,t){var r=e.template.map((function(r){return"string"==typeof r?replaceScope(r,e.scopeId,t):r})),n=e.selectors.map((function(r){return __assign(__assign({},r),{selector:replaceScope(r.selector,e.scopeId,t)})}));return __assign(__assign({},e),{template:r,selectors:n,scopeId:t})}function replaceScope(e,t,r){return e=replaceAll(e,"\\.".concat(t),".".concat(r))}function replaceAll(e,t,r){return e.replace(new RegExp(t,"g"),r)}function loadDocument(e,t){return loadDocumentStyles(e,t),loadDocumentLinks(e,t).then((function(){updateGlobalScopes(t)}))}function startWatcher(e,t){"undefined"!=typeof MutationObserver&&new MutationObserver((function(){loadDocumentStyles(e,t)&&updateGlobalScopes(t)})).observe(document.head,{childList:!0})}function loadDocumentLinks(e,t){for(var r=[],n=e.querySelectorAll('link[rel="stylesheet"][href]:not([data-no-shim])'),s=0;s<n.length;s++)r.push(addGlobalLink(e,t,n[s]));return Promise.all(r)}function loadDocumentStyles(e,t){return Array.from(e.querySelectorAll("style:not([data-styles]):not([data-no-shim])")).map((function(e){return addGlobalStyle(t,e)})).some(Boolean)}function addGlobalLink(e,t,r){var n=r.href;return fetch(n).then((function(e){return e.text()})).then((function(s){if(hasCssVariables(s)&&r.parentNode){hasRelativeUrls(s)&&(s=fixRelativeUrls(s,n));var o=e.createElement("style");o.setAttribute("data-styles",""),o.textContent=s,addGlobalStyle(t,o),r.parentNode.insertBefore(o,r),r.remove()}})).catch((function(e){console.error(e)}))}var CSS_VARIABLE_REGEXP=/[\s;{]--[-a-zA-Z0-9]+\s*:/m;function hasCssVariables(e){return e.indexOf("var(")>-1||CSS_VARIABLE_REGEXP.test(e)}var CSS_URL_REGEXP=/url[\s]*\([\s]*['"]?(?!(?:https?|data)\:|\/)([^\'\"\)]*)[\s]*['"]?\)[\s]*/gim;function hasRelativeUrls(e){return CSS_URL_REGEXP.lastIndex=0,CSS_URL_REGEXP.test(e)}function fixRelativeUrls(e,t){var r=t.replace(/[^/]*$/,"");return e.replace(CSS_URL_REGEXP,(function(e,t){var n=r+t;return e.replace(t,n)}))}var CustomStyle=function(){function e(e,t){this.win=e,this.doc=t,this.count=0,this.hostStyleMap=new WeakMap,this.hostScopeMap=new WeakMap,this.globalScopes=[],this.scopesMap=new Map,this.didInit=!1}return e.prototype.i=function(){var e=this;return this.didInit||!this.win.requestAnimationFrame?Promise.resolve():(this.didInit=!0,new Promise((function(t){e.win.requestAnimationFrame((function(){startWatcher(e.doc,e.globalScopes),loadDocument(e.doc,e.globalScopes).then((function(){return t()}))}))})))},e.prototype.addLink=function(e){var t=this;return addGlobalLink(this.doc,this.globalScopes,e).then((function(){t.updateGlobal()}))},e.prototype.addGlobalStyle=function(e){addGlobalStyle(this.globalScopes,e)&&this.updateGlobal()},e.prototype.createHostStyle=function(e,t,r,n){if(this.hostScopeMap.has(e))throw new Error("host style already created");var s=this.registerHostTemplate(r,t,n),o=this.doc.createElement("style");return o.setAttribute("data-no-shim",""),s.usesCssVars?n?(o["s-sc"]=t="".concat(s.scopeId,"-").concat(this.count),o.textContent="/*needs update*/",this.hostStyleMap.set(e,o),this.hostScopeMap.set(e,reScope(s,t)),this.count++):(s.styleEl=o,s.usesCssVars||(o.textContent=executeTemplate(s.template,{})),this.globalScopes.push(s),this.updateGlobal(),this.hostScopeMap.set(e,s)):o.textContent=r,o},e.prototype.removeHost=function(e){var t=this.hostStyleMap.get(e);t&&t.remove(),this.hostStyleMap.delete(e),this.hostScopeMap.delete(e)},e.prototype.updateHost=function(e){var t=this.hostScopeMap.get(e);if(t&&t.usesCssVars&&t.isScoped){var r=this.hostStyleMap.get(e);if(r){var n=resolveValues(getActiveSelectors(e,this.hostScopeMap,this.globalScopes));r.textContent=executeTemplate(t.template,n)}}},e.prototype.updateGlobal=function(){updateGlobalScopes(this.globalScopes)},e.prototype.registerHostTemplate=function(e,t,r){var n=this.scopesMap.get(t);return n||((n=parseCSS(e)).scopeId=t,n.isScoped=r,this.scopesMap.set(t,n)),n},e}();!function(e){!e||e.__cssshim||e.CSS&&e.CSS.supports&&e.CSS.supports("color","var(--c)")||(e.__cssshim=new CustomStyle(e,e.document))}("undefined"!=typeof window&&window);
|
|
1
|
+
var __assign=this&&this.__assign||function(){return __assign=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var s in t=arguments[r])Object.prototype.hasOwnProperty.call(t,s)&&(e[s]=t[s]);return e},__assign.apply(this,arguments)},StyleNode=function(){this.start=0,this.end=0,this.previous=null,this.parent=null,this.rules=null,this.parsedCssText="",this.cssText="",this.atRule=!1,this.type=0,this.keyframesName="",this.selector="",this.parsedSelector=""};function parse(e){return parseCss(lex(e=clean(e)),e)}function clean(e){return e.replace(RX.comments,"").replace(RX.port,"")}function lex(e){var t=new StyleNode;t.start=0,t.end=e.length;for(var r=t,n=0,s=e.length;n<s;n++)if(e[n]===OPEN_BRACE){r.rules||(r.rules=[]);var o=r,a=o.rules[o.rules.length-1]||null;(r=new StyleNode).start=n+1,r.parent=o,r.previous=a,o.rules.push(r)}else e[n]===CLOSE_BRACE&&(r.end=n+1,r=r.parent||t);return t}function parseCss(e,t){var r=t.substring(e.start,e.end-1);if(e.parsedCssText=e.cssText=r.trim(),e.parent){var n=e.previous?e.previous.end:e.parent.start;r=(r=(r=_expandUnicodeEscapes(r=t.substring(n,e.start-1))).replace(RX.multipleSpaces," ")).substring(r.lastIndexOf(";")+1);var s=e.parsedSelector=e.selector=r.trim();e.atRule=0===s.indexOf(AT_START),e.atRule?0===s.indexOf(MEDIA_START)?e.type=types.MEDIA_RULE:s.match(RX.keyframesRule)&&(e.type=types.KEYFRAMES_RULE,e.keyframesName=e.selector.split(RX.multipleSpaces).pop()):0===s.indexOf(VAR_START)?e.type=types.MIXIN_RULE:e.type=types.STYLE_RULE}var o=e.rules;if(o)for(var a=0,i=o.length,l=void 0;a<i&&(l=o[a]);a++)parseCss(l,t);return e}function _expandUnicodeEscapes(e){return e.replace(/\\([0-9a-f]{1,6})\s/gi,(function(){for(var e=arguments[1],t=6-e.length;t--;)e="0"+e;return"\\"+e}))}var types={STYLE_RULE:1,KEYFRAMES_RULE:7,MEDIA_RULE:4,MIXIN_RULE:1e3},OPEN_BRACE="{",CLOSE_BRACE="}",RX={comments:/\/\*[^*]*\*+([^/*][^*]*\*+)*\//gim,port:/@import[^;]*;/gim,customProp:/(?:^[^;\-\s}]+)?--[^;{}]*?:[^{};]*?(?:[;\n]|$)/gim,mixinProp:/(?:^[^;\-\s}]+)?--[^;{}]*?:[^{};]*?{[^}]*?}(?:[;\n]|$)?/gim,mixinApply:/@apply\s*\(?[^);]*\)?\s*(?:[;\n]|$)?/gim,varApply:/[^;:]*?:[^;]*?var\([^;]*\)(?:[;\n]|$)?/gim,keyframesRule:/^@[^\s]*keyframes/,multipleSpaces:/\s+/g},VAR_START="--",MEDIA_START="@media",AT_START="@",VAR_USAGE_START=/\bvar\(/,VAR_ASSIGN_START=/\B--[\w-]+\s*:/,COMMENTS=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//gim,TRAILING_LINES=/^[\t ]+\n/gm;function findRegex(e,t,r){e.lastIndex=0;var n=t.substring(r).match(e);if(n){var s=r+n.index;return{start:s,end:s+n[0].length}}return null}function resolveVar(e,t,r){return e[t]?e[t]:r?executeTemplate(r,e):""}function findVarEndIndex(e,t){for(var r=0,n=t;n<e.length;n++){var s=e[n];if("("===s)r++;else if(")"===s&&--r<=0)return n+1}return n}function parseVar(e,t){var r=findRegex(VAR_USAGE_START,e,t);if(!r)return null;var n=findVarEndIndex(e,r.start),s=e.substring(r.end,n-1).split(","),o=s[0],a=s.slice(1);return{start:r.start,end:n,propName:o.trim(),fallback:a.length>0?a.join(",").trim():void 0}}function compileVar(e,t,r){var n=parseVar(e,r);if(!n)return t.push(e.substring(r,e.length)),e.length;var s=n.propName,o=null!=n.fallback?compileTemplate(n.fallback):void 0;return t.push(e.substring(r,n.start),(function(e){return resolveVar(e,s,o)})),n.end}function executeTemplate(e,t){for(var r="",n=0;n<e.length;n++){var s=e[n];r+="string"==typeof s?s:s(t)}return r}function findEndValue(e,t){for(var r=!1,n=!1,s=t;s<e.length;s++){var o=e[s];if(r)n&&'"'===o&&(r=!1),n||"'"!==o||(r=!1);else if('"'===o)r=!0,n=!0;else if("'"===o)r=!0,n=!1;else{if(";"===o)return s+1;if("}"===o)return s}}return s}function removeCustomAssigns(e){for(var t="",r=0;;){var n=findRegex(VAR_ASSIGN_START,e,r),s=n?n.start:e.length;if(t+=e.substring(r,s),!n)break;r=findEndValue(e,s)}return t}function compileTemplate(e){var t=0;e=removeCustomAssigns(e=e.replace(COMMENTS,"")).replace(TRAILING_LINES,"");for(var r=[];t<e.length;)t=compileVar(e,r,t);return r}function resolveValues(e){var t={};e.forEach((function(e){e.declarations.forEach((function(e){t[e.prop]=e.value}))}));for(var r={},n=Object.entries(t),s=function(e){var t=!1;if(n.forEach((function(e){var n=e[0],s=executeTemplate(e[1],r);s!==r[n]&&(r[n]=s,t=!0)})),!t)return"break"},o=0;o<10;o++){if("break"===s())break}return r}function getSelectors(e,t){if(void 0===t&&(t=0),!e.rules)return[];var r=[];return e.rules.filter((function(e){return e.type===types.STYLE_RULE})).forEach((function(e){var n=getDeclarations(e.cssText);n.length>0&&e.parsedSelector.split(",").forEach((function(e){e=e.trim(),r.push({selector:e,declarations:n,specificity:computeSpecificity(),nu:t})})),t++})),r}function computeSpecificity(e){return 1}var IMPORTANT="!important",FIND_DECLARATIONS=/(?:^|[;\s{]\s*)(--[\w-]*?)\s*:\s*(?:((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};{])+)|\{([^}]*)\}(?:(?=[;\s}])|$))/gm;function getDeclarations(e){for(var t,r=[];t=FIND_DECLARATIONS.exec(e.trim());){var n=normalizeValue(t[2]),s=n.value,o=n.important;r.push({prop:t[1].trim(),value:compileTemplate(s),important:o})}return r}function normalizeValue(e){var t=(e=e.replace(/\s+/gim," ").trim()).endsWith(IMPORTANT);return t&&(e=e.slice(0,e.length-IMPORTANT.length).trim()),{value:e,important:t}}function getActiveSelectors(e,t,r){var n=[],s=getScopesForElement(t,e);return r.forEach((function(e){return n.push(e)})),s.forEach((function(e){return n.push(e)})),sortSelectors(getSelectorsForScopes(n).filter((function(t){return matches(e,t.selector)})))}function getScopesForElement(e,t){for(var r=[];t;){var n=e.get(t);n&&r.push(n),t=t.parentElement}return r}function getSelectorsForScopes(e){var t=[];return e.forEach((function(e){t.push.apply(t,e.selectors)})),t}function sortSelectors(e){return e.sort((function(e,t){return e.specificity===t.specificity?e.nu-t.nu:e.specificity-t.specificity})),e}function matches(e,t){return":root"===t||"html"===t||e.matches(t)}function parseCSS(e){var t=parse(e),r=compileTemplate(e);return{original:e,template:r,selectors:getSelectors(t),usesCssVars:r.length>1}}function addGlobalStyle(e,t){if(e.some((function(e){return e.styleEl===t})))return!1;var r=parseCSS(t.textContent);return r.styleEl=t,e.push(r),!0}function updateGlobalScopes(e){var t=resolveValues(getSelectorsForScopes(e));e.forEach((function(e){e.usesCssVars&&(e.styleEl.textContent=executeTemplate(e.template,t))}))}function reScope(e,t){var r=e.template.map((function(r){return"string"==typeof r?replaceScope(r,e.scopeId,t):r})),n=e.selectors.map((function(r){return __assign(__assign({},r),{selector:replaceScope(r.selector,e.scopeId,t)})}));return __assign(__assign({},e),{template:r,selectors:n,scopeId:t})}function replaceScope(e,t,r){return e=replaceAll(e,"\\.".concat(t),".".concat(r))}function replaceAll(e,t,r){return e.replace(new RegExp(t,"g"),r)}function loadDocument(e,t){return loadDocumentStyles(e,t),loadDocumentLinks(e,t).then((function(){updateGlobalScopes(t)}))}function startWatcher(e,t){"undefined"!=typeof MutationObserver&&new MutationObserver((function(){loadDocumentStyles(e,t)&&updateGlobalScopes(t)})).observe(document.head,{childList:!0})}function loadDocumentLinks(e,t){for(var r=[],n=e.querySelectorAll('link[rel="stylesheet"][href]:not([data-no-shim])'),s=0;s<n.length;s++)r.push(addGlobalLink(e,t,n[s]));return Promise.all(r)}function loadDocumentStyles(e,t){return Array.from(e.querySelectorAll("style:not([data-styles]):not([data-no-shim])")).map((function(e){return addGlobalStyle(t,e)})).some(Boolean)}function addGlobalLink(e,t,r){var n=r.href;return fetch(n).then((function(e){return e.text()})).then((function(s){if(hasCssVariables(s)&&r.parentNode){hasRelativeUrls(s)&&(s=fixRelativeUrls(s,n));var o=e.createElement("style");o.setAttribute("data-styles",""),o.textContent=s,addGlobalStyle(t,o),r.parentNode.insertBefore(o,r),r.remove()}})).catch((function(e){console.error(e)}))}var CSS_VARIABLE_REGEXP=/[\s;{]--[-a-zA-Z0-9]+\s*:/m;function hasCssVariables(e){return e.indexOf("var(")>-1||CSS_VARIABLE_REGEXP.test(e)}var CSS_URL_REGEXP=/url[\s]*\([\s]*['"]?(?!(?:https?|data)\:|\/)([^\'\"\)]*)[\s]*['"]?\)[\s]*/gim;function hasRelativeUrls(e){return CSS_URL_REGEXP.lastIndex=0,CSS_URL_REGEXP.test(e)}function fixRelativeUrls(e,t){var r=t.replace(/[^/]*$/,"");return e.replace(CSS_URL_REGEXP,(function(e,t){var n=r+t;return e.replace(t,n)}))}var CustomStyle=function(){function e(e,t){this.win=e,this.doc=t,this.count=0,this.hostStyleMap=new WeakMap,this.hostScopeMap=new WeakMap,this.globalScopes=[],this.scopesMap=new Map,this.didInit=!1}return e.prototype.i=function(){var e=this;return this.didInit||!this.win.requestAnimationFrame?Promise.resolve():(this.didInit=!0,new Promise((function(t){e.win.requestAnimationFrame((function(){startWatcher(e.doc,e.globalScopes),loadDocument(e.doc,e.globalScopes).then((function(){return t()}))}))})))},e.prototype.addLink=function(e){var t=this;return addGlobalLink(this.doc,this.globalScopes,e).then((function(){t.updateGlobal()}))},e.prototype.addGlobalStyle=function(e){addGlobalStyle(this.globalScopes,e)&&this.updateGlobal()},e.prototype.createHostStyle=function(e,t,r,n){if(this.hostScopeMap.has(e))throw new Error("host style already created");var s=this.registerHostTemplate(r,t,n),o=this.doc.createElement("style");return o.setAttribute("data-no-shim",""),s.usesCssVars?n?(o["s-sc"]=t="".concat(s.scopeId,"-").concat(this.count),o.textContent="/*needs update*/",this.hostStyleMap.set(e,o),this.hostScopeMap.set(e,reScope(s,t)),this.count++):(s.styleEl=o,s.usesCssVars||(o.textContent=executeTemplate(s.template,{})),this.globalScopes.push(s),this.updateGlobal(),this.hostScopeMap.set(e,s)):o.textContent=r,o},e.prototype.removeHost=function(e){var t=this.hostStyleMap.get(e);t&&t.remove(),this.hostStyleMap.delete(e),this.hostScopeMap.delete(e)},e.prototype.updateHost=function(e){var t=this.hostScopeMap.get(e);if(t&&t.usesCssVars&&t.isScoped){var r=this.hostStyleMap.get(e);if(r){var n=resolveValues(getActiveSelectors(e,this.hostScopeMap,this.globalScopes));r.textContent=executeTemplate(t.template,n)}}},e.prototype.updateGlobal=function(){updateGlobalScopes(this.globalScopes)},e.prototype.registerHostTemplate=function(e,t,r){var n=this.scopesMap.get(t);return n||((n=parseCSS(e)).scopeId=t,n.isScoped=r,this.scopesMap.set(t,n)),n},e}();!function(e){!e||e.__cssshim||e.CSS&&e.CSS.supports&&e.CSS.supports("color","var(--c)")||(e.__cssshim=new CustomStyle(e,e.document))}("undefined"!=typeof window&&window);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { r as registerInstance, h,
|
|
1
|
+
import { r as registerInstance, h, H as Host } from './index-5f9b72ff.js';
|
|
2
2
|
|
|
3
|
-
const tttxButtonCss = ".material-symbols-rounded{font-variation-settings:\"FILL\" 1, \"wght\" 400, \"GRAD\" 0, \"opsz\" 24}.button{font-family:Roboto, serif;box-sizing:border-box;height:36px;min-width:36px;padding:0;margin:0;background:transparent;color:#212121;border:1px solid #c8c8c8;border-radius:4px;text-transform:uppercase;display:flex;justify-content:left;align-items:center;font-size:14px;font-weight:400}.button-content{display:block;padding:0 16px}.icon-left,.icon-right{margin-top:4px}.iconleft{padding-left:8px}.iconleft .button-content{padding-left:4px}.iconright{padding-right:8px}.iconright .button-content{padding-right:4px}.notext{padding:0 6px}.button:hover{background:rgba(17, 17, 17, 0.1);border:1px solid #D5D5D5}.button:active{background:rgba(17, 17, 17, 0.2);border:1px solid #D5D5D5}.primary{background:#1479c6;border:1px solid #1479c6;color:white}.primary:hover{background:#146EB3;border:1px solid #146EB3}.primary:active{background:#1464A2;border:1px solid #1464A2}.borderless{background:transparent;border:none;color:#212121}.borderless:hover{background:rgba(17, 17, 17, 0.1);border:none}.borderless:active{background:rgba(17, 17, 17, 0.2);border:none}.danger{background:#DC0000;border:1px solid #DC0000;color:white}.danger:hover{background:#C60000;border:1px solid #C60000}.danger:active{background:#B00000;border:1px solid #B00000}.disabled{background:#aeaeae;border:none;color:#4c4c4c;cursor:not-allowed}.disabled:hover{background:#aeaeae;border:none;color:#4c4c4c;cursor:not-allowed}.disabled:active{background:#aeaeae;border:none;color:#4c4c4c;cursor:not-allowed}:host{display:inline-block}.spacingleft{margin-left:8px}";
|
|
3
|
+
const tttxButtonCss = ".material-symbols-rounded{font-variation-settings:\"FILL\" 1, \"wght\" 400, \"GRAD\" 0, \"opsz\" 24}.button{font-family:Roboto, serif;box-sizing:border-box;height:36px;min-width:36px;padding:0;margin:0;background:transparent;color:#212121;border:1px solid #c8c8c8;border-radius:4px;text-transform:uppercase;display:flex;justify-content:left;align-items:center;font-size:14px;font-weight:400}.button-content{display:block;padding:0 16px}.icon-left,.icon-right{margin-top:4px}.iconleft{padding-left:8px}.iconleft .button-content{padding-left:4px}.iconright{padding-right:8px}.iconright .button-content{padding-right:4px}.notext{padding:0 6px}.button:hover{background:rgba(17, 17, 17, 0.1);border:1px solid #D5D5D5}.button:active{background:rgba(17, 17, 17, 0.2);border:1px solid #D5D5D5}.primary{background:#1479c6;border:1px solid #1479c6;color:white}.primary:hover{background:#146EB3;border:1px solid #146EB3}.primary:active{background:#1464A2;border:1px solid #1464A2}.borderless{background:transparent;border:none;color:#212121}.borderless:hover{background:rgba(17, 17, 17, 0.1);border:none}.borderless:active{background:rgba(17, 17, 17, 0.2);border:none}.danger{background:#DC0000;border:1px solid #DC0000;color:white}.danger:hover{background:#C60000;border:1px solid #C60000}.danger:active{background:#B00000;border:1px solid #B00000}.disabled{background:#aeaeae;border:none;color:#4c4c4c;cursor:not-allowed}.disabled:hover{background:#aeaeae;border:none;color:#4c4c4c;cursor:not-allowed}.disabled:active{background:#aeaeae;border:none;color:#4c4c4c;cursor:not-allowed}:host{display:inline-block}button{cursor:pointer}tttx-icon{cursor:inherit}.spacingleft{margin-left:8px}";
|
|
4
4
|
|
|
5
5
|
const TttxButton = class {
|
|
6
6
|
constructor(hostRef) {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { r as registerInstance,
|
|
1
|
+
import { r as registerInstance, c as createEvent, h, H as Host } from './index-5f9b72ff.js';
|
|
2
2
|
|
|
3
3
|
/**
|
|
4
4
|
* Validates the input field on focusout event by checking its validity state,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { r as registerInstance, h,
|
|
1
|
+
import { r as registerInstance, h, H as Host } from './index-5f9b72ff.js';
|
|
2
2
|
|
|
3
3
|
const tttxIconCss = ".material-symbols-rounded{font-variation-settings:\"FILL\" 1, \"wght\" 400, \"GRAD\" 0, \"opsz\" 24}.material-symbols-rounded{font-family:\"Material Symbols Rounded\", sans-serif;font-weight:400;font-style:normal;font-size:24px;line-height:1;letter-spacing:normal;text-transform:none;display:inline-block;white-space:nowrap;word-wrap:normal;direction:ltr;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;color:#9e9e9e}:host{display:inline-block;cursor:default;user-select:none}.icon-size{width:24px;height:24px}.tooltip{background:#ffffff;color:#343434;font-weight:bold;padding:8px 16px;font-size:13px;border-radius:4px;box-shadow:0 0 5px 1px rgba(0, 0, 0, 0.3);display:none}.tooltip[data-show]{display:block}.arrow,.arrow::before{position:absolute;width:8px;height:8px;background:inherit}.arrow{visibility:hidden}.arrow::before{visibility:visible;content:\"\";transform:rotate(45deg)}.tooltip[data-popper-placement^=top]>.arrow{bottom:-4px}.tooltip[data-popper-placement^=bottom]>.arrow{top:-4px}.tooltip[data-popper-placement^=left]>.arrow{right:-4px}.tooltip[data-popper-placement^=right]>.arrow{left:-4px}.red{color:#dc0000}.darkred{color:#A20000}.orange{color:#f59500}.blue{color:#1479c6}.green{color:#a2bb31}.gray{color:#757575}.black{color:#212121}.white{color:white}";
|
|
4
4
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { r as registerInstance, h,
|
|
1
|
+
import { r as registerInstance, h, H as Host } from './index-5f9b72ff.js';
|
|
2
2
|
|
|
3
3
|
const tttxKeyvalueBlockCss = ":host{display:block}dl{margin:0;padding:0;font-family:\"Roboto\", sans-serif;cursor:default}dt{font-weight:400;line-height:21px;font-size:16px}dt,dt.subTitle{color:#757575}dt.mainTitle{color:#212121}dd{margin:0;font-weight:400;font-size:16px;color:#212121;line-height:21px;margin-bottom:18px}dl.horizontal{display:flex;flex-direction:row;width:100%}dl.horizontal div{flex-grow:1}@media (max-width: 769px){dl.horizontal{flex-wrap:wrap}dl.horizontal div{width:50%}}@media (max-width: 600px){dl.horizontal div{width:100%}}";
|
|
4
4
|
|
|
@@ -1,44 +1,17 @@
|
|
|
1
|
-
import { r as registerInstance,
|
|
1
|
+
import { r as registerInstance, c as createEvent, h } from './index-5f9b72ff.js';
|
|
2
2
|
|
|
3
3
|
var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
|
|
4
4
|
|
|
5
|
-
function getDefaultExportFromCjs (x) {
|
|
6
|
-
return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, 'default') ? x['default'] : x;
|
|
7
|
-
}
|
|
8
|
-
|
|
9
5
|
function createCommonjsModule(fn, basedir, module) {
|
|
10
6
|
return module = {
|
|
11
7
|
path: basedir,
|
|
12
8
|
exports: {},
|
|
13
9
|
require: function (path, base) {
|
|
14
|
-
return commonjsRequire(
|
|
10
|
+
return commonjsRequire();
|
|
15
11
|
}
|
|
16
12
|
}, fn(module, module.exports), module.exports;
|
|
17
13
|
}
|
|
18
14
|
|
|
19
|
-
function getDefaultExportFromNamespaceIfPresent (n) {
|
|
20
|
-
return n && Object.prototype.hasOwnProperty.call(n, 'default') ? n['default'] : n;
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
function getDefaultExportFromNamespaceIfNotNamed (n) {
|
|
24
|
-
return n && Object.prototype.hasOwnProperty.call(n, 'default') && Object.keys(n).length === 1 ? n['default'] : n;
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
function getAugmentedNamespace(n) {
|
|
28
|
-
if (n.__esModule) return n;
|
|
29
|
-
var a = Object.defineProperty({}, '__esModule', {value: true});
|
|
30
|
-
Object.keys(n).forEach(function (k) {
|
|
31
|
-
var d = Object.getOwnPropertyDescriptor(n, k);
|
|
32
|
-
Object.defineProperty(a, k, d.get ? d : {
|
|
33
|
-
enumerable: true,
|
|
34
|
-
get: function () {
|
|
35
|
-
return n[k];
|
|
36
|
-
}
|
|
37
|
-
});
|
|
38
|
-
});
|
|
39
|
-
return a;
|
|
40
|
-
}
|
|
41
|
-
|
|
42
15
|
function commonjsRequire () {
|
|
43
16
|
throw new Error('Dynamic requires are not currently supported by @rollup/plugin-commonjs');
|
|
44
17
|
}
|
|
@@ -47,11 +20,8 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
47
20
|
/*! @license DOMPurify 3.0.3 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.0.3/LICENSE */
|
|
48
21
|
|
|
49
22
|
(function (global, factory) {
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, global.DOMPurify = factory());
|
|
53
|
-
})(commonjsGlobal, (function () { 'use strict';
|
|
54
|
-
|
|
23
|
+
module.exports = factory() ;
|
|
24
|
+
})(commonjsGlobal, (function () {
|
|
55
25
|
const {
|
|
56
26
|
entries,
|
|
57
27
|
setPrototypeOf,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { r as registerInstance, h } from './index-
|
|
1
|
+
import { r as registerInstance, h } from './index-5f9b72ff.js';
|
|
2
2
|
|
|
3
3
|
const tttxLoadingSpinnerCss = ".material-symbols-rounded{font-variation-settings:\"FILL\" 1, \"wght\" 400, \"GRAD\" 0, \"opsz\" 24}.spinner-container{position:absolute}.loading-box{display:flex;align-items:center;justify-content:center}.loading-text{font-size:16px;font-weight:400;padding-top:10px;text-align:center}.spinner{border:solid #1479c6;border-bottom-color:#d5d5d5;border-radius:50%;position:relative;box-sizing:border-box;animation:rotation 1s linear infinite}.spinner.small{height:20px;width:20px;border-width:4px}.spinner.large{height:60px;width:60px;border-width:8px}@keyframes rotation{0%{transform:rotate(0deg)}100%{transform:rotate(360deg)}}";
|
|
4
4
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { r as registerInstance,
|
|
1
|
+
import { r as registerInstance, c as createEvent, h, H as Host } from './index-5f9b72ff.js';
|
|
2
2
|
|
|
3
3
|
const tttxStandaloneInputCss = ".material-symbols-rounded.sc-tttx-standalone-input{font-variation-settings:\"FILL\" 1, \"wght\" 400, \"GRAD\" 0, \"opsz\" 24}.material-symbols-rounded.sc-tttx-standalone-input{font-family:\"Material Symbols Rounded\", sans-serif;font-weight:400;font-style:normal;font-size:24px;line-height:1;letter-spacing:normal;text-transform:none;display:inline-block;white-space:nowrap;word-wrap:normal;direction:ltr;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;color:#9e9e9e}.icon-left.sc-tttx-standalone-input,.icon-right.sc-tttx-standalone-input{flex-basis:24px}.icon-left.sc-tttx-standalone-input span.sc-tttx-standalone-input,.icon-right.sc-tttx-standalone-input span.sc-tttx-standalone-input{font-size:24px;line-height:24px;text-align:center;display:block;width:24px;height:24px;margin-top:4px}.icon-left.sc-tttx-standalone-input span.sc-tttx-standalone-input{margin-left:4px}.icon-right.sc-tttx-standalone-input span.sc-tttx-standalone-input{margin-right:4px}.icon-right.sc-tttx-standalone-input{margin-top:5px}.icon-left.sc-tttx-standalone-input{margin-top:5px;margin-left:4px}.iconleft.sc-tttx-standalone-input .input.sc-tttx-standalone-input{padding-left:4px}.iconright.sc-tttx-standalone-input .input.sc-tttx-standalone-input{padding-right:4px}.input-icon.sc-tttx-standalone-input{position:absolute;margin-top:9px;margin-left:4px}.errormsg.sc-tttx-standalone-input{display:flex;justify-content:center;align-items:center;float:left;margin-bottom:16px;box-sizing:border-box;background-color:transparent;height:26px;font-size:14px;border-radius:none;z-index:2;color:#dc0000}.errormsg.sc-tttx-standalone-input .validationicon.sc-tttx-standalone-input{width:16px;height:16px;font-size:16px;margin-right:4px;vertical-align:middle;color:#dc0000}.danger.sc-tttx-standalone-input{color:#dc0000}.optional.sc-tttx-standalone-input{color:#757575;font-weight:normal}label.inputBlock.sc-tttx-standalone-input{display:block;position:relative;line-height:21px}label.inputInline.sc-tttx-standalone-input{display:flex;white-space:nowrap;align-items:center}label.inputInline.sc-tttx-standalone-input .input-container.sc-tttx-standalone-input{margin:0 4px;width:100%;display:flex;align-items:center;gap:4px;position:relative}label.sc-tttx-standalone-input{font-weight:500;font-size:16px}input.sc-tttx-standalone-input:not([type=submit]){font-family:\"Roboto\", serif;box-sizing:border-box;width:100%;height:36px;padding:0 16px;font-size:16px;border:1px solid #d5d5d5;border-radius:4px;margin-top:4px}input[type=date].sc-tttx-standalone-input{background:white;display:block;min-width:calc(100% - 18px);line-height:37px}@media (max-width: 600px){input[type=date].sc-tttx-standalone-input{padding-top:6px}}input.invalid.sc-tttx-standalone-input:invalid,input.standalone.invalid.sc-tttx-standalone-input{border:1px solid #dc0000}.input-icon.sc-tttx-standalone-input~input.sc-tttx-standalone-input{padding:0 32px}input.sc-tttx-standalone-input~.errorBubble.sc-tttx-standalone-input{min-height:27px;position:relative;font-size:14px;font-weight:normal;width:100%;font-family:\"Roboto\", sans-serif;color:#dc0000;display:flex;align-content:center;align-items:center;justify-items:center}input.sc-tttx-standalone-input~.errorBubble.sc-tttx-standalone-input:not(.visible){visibility:hidden}input.sc-tttx-standalone-input~.errorBubble.sc-tttx-standalone-input span.sc-tttx-standalone-input{color:#dc0000;font-size:16px;margin-right:4px;height:16px}input.invalid.sc-tttx-standalone-input:invalid~.errorBubble.sc-tttx-standalone-input{position:relative;font-size:14px;font-weight:normal;width:100%;font-family:\"Roboto\", sans-serif;color:#dc0000;visibility:visible}input.sc-tttx-standalone-input:focus{border-color:#1479c6}input.sc-tttx-standalone-input:focus-visible{outline:none}.sc-tttx-standalone-input-h{display:block}";
|
|
4
4
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { r as registerInstance, h,
|
|
1
|
+
import { r as registerInstance, h, H as Host } from './index-5f9b72ff.js';
|
|
2
2
|
|
|
3
3
|
const tttxToolbarCss = ":host{height:36px;display:flex;padding:8px 0;gap:8px}:host(.bordered){border-bottom:1px solid #d5d5d5}slot[name=before]{display:flex;flex:1 1 0px;gap:8px}slot[name=center]{display:flex;justify-content:center;flex:1 1 0px;gap:8px}slot[name=after]{display:flex;justify-content:end;flex:1 1 0px;gap:8px}";
|
|
4
4
|
|
package/dist/esm/tttx.js
CHANGED
|
@@ -1,129 +1,18 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
1
|
+
import { p as promiseResolve, b as bootstrapLazy } from './index-5f9b72ff.js';
|
|
2
|
+
export { s as setNonce } from './index-5f9b72ff.js';
|
|
3
3
|
|
|
4
4
|
/*
|
|
5
|
-
Stencil Client Patch Browser v2.
|
|
5
|
+
Stencil Client Patch Browser v2.22.3 | MIT Licensed | https://stenciljs.com
|
|
6
6
|
*/
|
|
7
|
-
const getDynamicImportFunction = (namespace) => `__sc_import_${namespace.replace(/\s|-/g, '_')}`;
|
|
8
7
|
const patchBrowser = () => {
|
|
9
|
-
// NOTE!! This fn cannot use async/await!
|
|
10
|
-
if (BUILD.isDev && !BUILD.isTesting) {
|
|
11
|
-
consoleDevInfo('Running in development mode.');
|
|
12
|
-
}
|
|
13
|
-
if (BUILD.cssVarShim) {
|
|
14
|
-
// shim css vars
|
|
15
|
-
plt.$cssShim$ = win.__cssshim;
|
|
16
|
-
}
|
|
17
|
-
if (BUILD.cloneNodeFix) {
|
|
18
|
-
// opted-in to polyfill cloneNode() for slot polyfilled components
|
|
19
|
-
patchCloneNodeFix(H.prototype);
|
|
20
|
-
}
|
|
21
|
-
if (BUILD.profile && !performance.mark) {
|
|
22
|
-
// not all browsers support performance.mark/measure (Safari 10)
|
|
23
|
-
// because the mark/measure APIs are designed to write entries to a buffer in the browser that does not exist,
|
|
24
|
-
// simply stub the implementations out.
|
|
25
|
-
// TODO(STENCIL-323): Remove this patch when support for older browsers is removed (breaking)
|
|
26
|
-
// @ts-ignore
|
|
27
|
-
performance.mark = performance.measure = () => {
|
|
28
|
-
/*noop*/
|
|
29
|
-
};
|
|
30
|
-
performance.getEntriesByName = () => [];
|
|
31
|
-
}
|
|
32
|
-
// @ts-ignore
|
|
33
|
-
const scriptElm = BUILD.scriptDataOpts || BUILD.safari10 || BUILD.dynamicImportShim
|
|
34
|
-
? Array.from(doc.querySelectorAll('script')).find((s) => new RegExp(`\/${NAMESPACE}(\\.esm)?\\.js($|\\?|#)`).test(s.src) ||
|
|
35
|
-
s.getAttribute('data-stencil-namespace') === NAMESPACE)
|
|
36
|
-
: null;
|
|
37
8
|
const importMeta = import.meta.url;
|
|
38
|
-
const opts =
|
|
39
|
-
if (
|
|
40
|
-
// Safari < v11 support: This IF is true if it's Safari below v11.
|
|
41
|
-
// This fn cannot use async/await since Safari didn't support it until v11,
|
|
42
|
-
// however, Safari 10 did support modules. Safari 10 also didn't support "nomodule",
|
|
43
|
-
// so both the ESM file and nomodule file would get downloaded. Only Safari
|
|
44
|
-
// has 'onbeforeload' in the script, and "history.scrollRestoration" was added
|
|
45
|
-
// to Safari in v11. Return a noop then() so the async/await ESM code doesn't continue.
|
|
46
|
-
// IS_ESM_BUILD is replaced at build time so this check doesn't happen in systemjs builds.
|
|
47
|
-
return {
|
|
48
|
-
then() {
|
|
49
|
-
/* promise noop */
|
|
50
|
-
},
|
|
51
|
-
};
|
|
52
|
-
}
|
|
53
|
-
if (!BUILD.safari10 && importMeta !== '') {
|
|
9
|
+
const opts = {};
|
|
10
|
+
if (importMeta !== '') {
|
|
54
11
|
opts.resourcesUrl = new URL('.', importMeta).href;
|
|
55
12
|
}
|
|
56
|
-
else if (BUILD.dynamicImportShim || BUILD.safari10) {
|
|
57
|
-
opts.resourcesUrl = new URL('.', new URL(scriptElm.getAttribute('data-resources-url') || scriptElm.src, win.location.href)).href;
|
|
58
|
-
if (BUILD.dynamicImportShim) {
|
|
59
|
-
patchDynamicImport(opts.resourcesUrl, scriptElm);
|
|
60
|
-
}
|
|
61
|
-
if (BUILD.dynamicImportShim && !win.customElements) {
|
|
62
|
-
// module support, but no custom elements support (Old Edge)
|
|
63
|
-
// @ts-ignore
|
|
64
|
-
return import(/* webpackChunkName: "polyfills-dom" */ './dom-6be6f662.js').then(() => opts);
|
|
65
|
-
}
|
|
66
|
-
}
|
|
67
13
|
return promiseResolve(opts);
|
|
68
14
|
};
|
|
69
|
-
const patchDynamicImport = (base, orgScriptElm) => {
|
|
70
|
-
const importFunctionName = getDynamicImportFunction(NAMESPACE);
|
|
71
|
-
try {
|
|
72
|
-
// test if this browser supports dynamic imports
|
|
73
|
-
// There is a caching issue in V8, that breaks using import() in Function
|
|
74
|
-
// By generating a random string, we can workaround it
|
|
75
|
-
// Check https://bugs.chromium.org/p/chromium/issues/detail?id=990810 for more info
|
|
76
|
-
win[importFunctionName] = new Function('w', `return import(w);//${Math.random()}`);
|
|
77
|
-
}
|
|
78
|
-
catch (e) {
|
|
79
|
-
// this shim is specifically for browsers that do support "esm" imports
|
|
80
|
-
// however, they do NOT support "dynamic" imports
|
|
81
|
-
// basically this code is for old Edge, v18 and below
|
|
82
|
-
const moduleMap = new Map();
|
|
83
|
-
win[importFunctionName] = (src) => {
|
|
84
|
-
const url = new URL(src, base).href;
|
|
85
|
-
let mod = moduleMap.get(url);
|
|
86
|
-
if (!mod) {
|
|
87
|
-
const script = doc.createElement('script');
|
|
88
|
-
script.type = 'module';
|
|
89
|
-
script.crossOrigin = orgScriptElm.crossOrigin;
|
|
90
|
-
script.src = URL.createObjectURL(new Blob([`import * as m from '${url}'; window.${importFunctionName}.m = m;`], {
|
|
91
|
-
type: 'application/javascript',
|
|
92
|
-
}));
|
|
93
|
-
mod = new Promise((resolve) => {
|
|
94
|
-
script.onload = () => {
|
|
95
|
-
resolve(win[importFunctionName].m);
|
|
96
|
-
script.remove();
|
|
97
|
-
};
|
|
98
|
-
});
|
|
99
|
-
moduleMap.set(url, mod);
|
|
100
|
-
doc.head.appendChild(script);
|
|
101
|
-
}
|
|
102
|
-
return mod;
|
|
103
|
-
};
|
|
104
|
-
}
|
|
105
|
-
};
|
|
106
|
-
const patchCloneNodeFix = (HTMLElementPrototype) => {
|
|
107
|
-
const nativeCloneNodeFn = HTMLElementPrototype.cloneNode;
|
|
108
|
-
HTMLElementPrototype.cloneNode = function (deep) {
|
|
109
|
-
if (this.nodeName === 'TEMPLATE') {
|
|
110
|
-
return nativeCloneNodeFn.call(this, deep);
|
|
111
|
-
}
|
|
112
|
-
const clonedNode = nativeCloneNodeFn.call(this, false);
|
|
113
|
-
const srcChildNodes = this.childNodes;
|
|
114
|
-
if (deep) {
|
|
115
|
-
for (let i = 0; i < srcChildNodes.length; i++) {
|
|
116
|
-
// Node.ATTRIBUTE_NODE === 2, and checking because IE11
|
|
117
|
-
if (srcChildNodes[i].nodeType !== 2) {
|
|
118
|
-
clonedNode.appendChild(srcChildNodes[i].cloneNode(true));
|
|
119
|
-
}
|
|
120
|
-
}
|
|
121
|
-
}
|
|
122
|
-
return clonedNode;
|
|
123
|
-
};
|
|
124
|
-
};
|
|
125
15
|
|
|
126
16
|
patchBrowser().then(options => {
|
|
127
|
-
globalScripts();
|
|
128
17
|
return bootstrapLazy([["tttx-button",[[1,"tttx-button",{"notext":[4],"icon":[1],"iconposition":[1],"design":[1]}]]],["tttx-list",[[1,"tttx-list",{"data":[1025],"name":[1]}]]],["tttx-standalone-input",[[2,"tttx-standalone-input",{"label":[1],"showerrormsg":[4],"showerrorbubble":[4],"errormsg":[1],"iconleft":[1],"iconright":[1],"inputicon":[1],"inline":[4],"inputAutocapitalize":[1,"input-autocapitalize"],"inputAutofocus":[4,"input-autofocus"],"inputKeyhint":[1,"input-keyhint"],"inputIndex":[8,"input-index"],"inputTitle":[1,"input-title"],"autocomplete":[1],"checked":[4],"disabled":[4],"max":[8],"maxlength":[8],"min":[8],"minlength":[8],"name":[1],"pattern":[1],"placeholder":[1],"readonly":[8],"required":[4],"step":[8],"type":[1],"value":[1032]}]]],["tttx-form",[[1,"tttx-form",{"formschema":[1032],"submitValue":[1032,"submit-value"]}]]],["tttx-keyvalue-block",[[1,"tttx-keyvalue-block",{"keyvalues":[8],"horizontal":[4]}]]],["tttx-loading-spinner",[[1,"tttx-loading-spinner",{"loadingMessage":[1028,"loading-message"],"size":[1025]}]]],["tttx-toolbar",[[1,"tttx-toolbar",{"border":[4]}]]],["tttx-icon",[[1,"tttx-icon",{"icon":[1],"color":[1]}]]]], options);
|
|
129
18
|
});
|
package/dist/tttx/index.esm.js
CHANGED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as e,h as t,H as s}from"./p-
|
|
1
|
+
import{r as e,h as t,H as s}from"./p-c4b803fc.js";const o=class{constructor(t){e(this,t),this.border=!0}render(){return t(s,{class:this.border?"bordered":""},t("slot",{name:"before"}),t("slot",{name:"center"}),t("slot",{name:"after"}))}};o.style=":host{height:36px;display:flex;padding:8px 0;gap:8px}:host(.bordered){border-bottom:1px solid #d5d5d5}slot[name=before]{display:flex;flex:1 1 0px;gap:8px}slot[name=center]{display:flex;justify-content:center;flex:1 1 0px;gap:8px}slot[name=after]{display:flex;justify-content:end;flex:1 1 0px;gap:8px}";export{o as tttx_toolbar}
|