@baloise/ds-core 16.5.2-nightly.20241016 → 16.6.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/components/all.d.ts +0 -2
- package/components/all.js +0 -3
- package/components/bal-app.js +85 -1
- package/components/bal-divider.js +6 -3
- package/components/index.js +289 -5
- package/components/tokens.esm.js +1 -1
- package/dist/baloise-design-system/baloise-design-system.esm.js +1 -1
- package/dist/baloise-design-system/baloise-design-system.js +1 -1
- package/dist/baloise-design-system/index.esm.js +1 -1
- package/dist/baloise-design-system/{p-f959646a.system.js → p-013b4c72.system.js} +1 -1
- package/dist/baloise-design-system/{p-21b808e0d9.system.entry.js → p-049f6f9bc3.system.entry.js} +1 -1
- package/dist/baloise-design-system/{p-728f5b41.system.js → p-0570eb56.system.js} +1 -1
- package/dist/baloise-design-system/{p-4d8fe449d5.system.entry.js → p-06a5a7af22.system.entry.js} +1 -1
- package/dist/baloise-design-system/p-1509eaa7.system.js +1 -1
- package/dist/baloise-design-system/{p-715ca77ce1.system.entry.js → p-22cf548aa1.system.entry.js} +1 -1
- package/dist/baloise-design-system/{p-ccd0a1e926.system.entry.js → p-29d8f4a3f3.system.entry.js} +1 -1
- package/dist/baloise-design-system/{p-96acac65da.entry.js → p-318d8566b5.entry.js} +1 -1
- package/dist/baloise-design-system/{p-8f0603e035.entry.js → p-33e346ee9c.entry.js} +1 -1
- package/dist/baloise-design-system/{p-c0e29842fb.entry.js → p-414e6186de.entry.js} +1 -1
- package/dist/baloise-design-system/{p-9318d4668f.system.entry.js → p-4ecfee4374.system.entry.js} +1 -1
- package/dist/baloise-design-system/{p-59d20b29cf.entry.js → p-5003a0c597.entry.js} +1 -1
- package/dist/baloise-design-system/p-54f81c32.js +1 -1
- package/dist/baloise-design-system/{p-1440dc0f02.system.entry.js → p-60dccd31d0.system.entry.js} +1 -1
- package/dist/baloise-design-system/p-6aafd1a509.entry.js +1 -0
- package/dist/baloise-design-system/{p-76edb36f.js → p-7369c393.js} +1 -1
- package/dist/baloise-design-system/{p-e3f9726328.entry.js → p-737c1fb94a.entry.js} +1 -1
- package/dist/baloise-design-system/{p-534e596b58.entry.js → p-74eb881086.entry.js} +1 -1
- package/dist/baloise-design-system/{p-f4fecd6a61.entry.js → p-77cdc5cbab.entry.js} +1 -1
- package/dist/baloise-design-system/{p-425a147622.entry.js → p-798e2ef3fc.entry.js} +1 -1
- package/dist/baloise-design-system/{p-dcabad09c4.system.entry.js → p-840578b091.system.entry.js} +1 -1
- package/dist/baloise-design-system/{p-350ff60bf2.system.entry.js → p-9bff7b8289.system.entry.js} +1 -1
- package/dist/baloise-design-system/{p-1999fcbbbb.entry.js → p-9df14aeb44.entry.js} +1 -1
- package/dist/baloise-design-system/{p-27c25842.system.js → p-9e2ff161.system.js} +1 -1
- package/dist/baloise-design-system/p-a37806b3.js +1 -0
- package/dist/baloise-design-system/{p-2996de33c9.system.entry.js → p-a5ef8dac6d.system.entry.js} +1 -1
- package/dist/baloise-design-system/{p-69cdf5b662.entry.js → p-a818a7381b.entry.js} +1 -1
- package/dist/baloise-design-system/{p-13e6d9b4.system.js → p-ab3a5c74.system.js} +1 -1
- package/dist/baloise-design-system/{p-f04137fded.entry.js → p-ae96e76be8.entry.js} +1 -1
- package/dist/baloise-design-system/{p-f493d1cf99.system.entry.js → p-b439906a26.system.entry.js} +1 -1
- package/dist/baloise-design-system/p-bcca1ed3.system.js +1 -0
- package/dist/baloise-design-system/{p-c4737ccfad.system.entry.js → p-c5e4359d53.system.entry.js} +1 -1
- package/dist/baloise-design-system/{p-b6e796784f.system.entry.js → p-c7a5bfc385.system.entry.js} +1 -1
- package/dist/baloise-design-system/{p-f57acb8d.system.js → p-ca3cb874.system.js} +1 -1
- package/dist/baloise-design-system/{p-98f62e5849.system.entry.js → p-ca496a02d5.system.entry.js} +1 -1
- package/dist/baloise-design-system/{p-540343b3b9.entry.js → p-ce5ca16861.entry.js} +1 -1
- package/dist/baloise-design-system/{p-efc0b7d41b.entry.js → p-e15280fb2b.entry.js} +1 -1
- package/dist/baloise-design-system/p-e78a6409.js +1 -0
- package/dist/baloise-design-system/{p-e59f3615.js → p-ea5b8ead.js} +1 -1
- package/dist/baloise-design-system/{p-4c19e69b4c.system.entry.js → p-fecc5b1e11.system.entry.js} +1 -1
- package/dist/cjs/{global-2562a984.js → app-globals-ae3a8623.js} +4 -2
- package/dist/cjs/bal-carousel_2.cjs.entry.js +3 -3
- package/dist/cjs/bal-datepicker.cjs.entry.js +3 -3
- package/dist/cjs/bal-divider.cjs.entry.js +4 -2
- package/dist/cjs/bal-hint_5.cjs.entry.js +3 -3
- package/dist/cjs/bal-list_8.cjs.entry.js +3 -3
- package/dist/cjs/bal-logo.cjs.entry.js +3 -3
- package/dist/cjs/bal-nav_8.cjs.entry.js +3 -3
- package/dist/cjs/bal-navbar_5.cjs.entry.js +3 -3
- package/dist/cjs/bal-pagination.cjs.entry.js +3 -3
- package/dist/cjs/bal-progress-bar.cjs.entry.js +4 -4
- package/dist/cjs/bal-segment_2.cjs.entry.js +4 -4
- package/dist/cjs/bal-shape.cjs.entry.js +1 -1
- package/dist/cjs/bal-steps.cjs.entry.js +3 -3
- package/dist/cjs/bal-tab-item_2.cjs.entry.js +3 -3
- package/dist/cjs/baloise-design-system.cjs.js +2 -3
- package/dist/cjs/{breakpoints.decorator-78f08267.js → breakpoints.decorator-e7e9f44f.js} +1 -1
- package/dist/cjs/{breakpoints.subject-7a3a48a5.js → breakpoints.subject-e81f405a.js} +1 -1
- package/dist/cjs/index.cjs.js +2 -2
- package/dist/cjs/initialize-2a19d091.js +1 -1
- package/dist/cjs/loader.cjs.js +2 -3
- package/dist/cjs/{tokens.esm-d9c84eb7.js → tokens.esm-bd463bce.js} +1 -1
- package/dist/cjs/{window-resize.decorator-f85cd134.js → window-resize.decorator-7c2d851d.js} +1 -1
- package/dist/collection/collection-manifest.json +1 -2
- package/dist/collection/components/bal-divider/bal-divider.css +1 -1
- package/dist/collection/components/bal-divider/bal-divider.js +26 -1
- package/dist/collection/utils/constants/version.constant.js +1 -1
- package/dist/esm/{global-63f4bcec.js → app-globals-b0dd0fc4.js} +4 -2
- package/dist/esm/bal-carousel_2.entry.js +3 -3
- package/dist/esm/bal-datepicker.entry.js +3 -3
- package/dist/esm/bal-divider.entry.js +4 -2
- package/dist/esm/bal-hint_5.entry.js +3 -3
- package/dist/esm/bal-list_8.entry.js +3 -3
- package/dist/esm/bal-logo.entry.js +3 -3
- package/dist/esm/bal-nav_8.entry.js +3 -3
- package/dist/esm/bal-navbar_5.entry.js +3 -3
- package/dist/esm/bal-pagination.entry.js +3 -3
- package/dist/esm/bal-progress-bar.entry.js +4 -4
- package/dist/esm/bal-segment_2.entry.js +4 -4
- package/dist/esm/bal-shape.entry.js +1 -1
- package/dist/esm/bal-steps.entry.js +3 -3
- package/dist/esm/bal-tab-item_2.entry.js +3 -3
- package/dist/esm/baloise-design-system.js +2 -3
- package/dist/esm/{breakpoints.decorator-e82931ce.js → breakpoints.decorator-c7356fbf.js} +1 -1
- package/dist/esm/{breakpoints.subject-76a230e3.js → breakpoints.subject-c11e7472.js} +1 -1
- package/dist/esm/index.js +3 -3
- package/dist/esm/initialize-e216cfe4.js +1 -1
- package/dist/esm/loader.js +2 -3
- package/dist/esm/{tokens.esm-37a3b6c5.js → tokens.esm-ebe36fdf.js} +1 -1
- package/dist/esm/{window-resize.decorator-76d795d0.js → window-resize.decorator-4d922021.js} +1 -1
- package/dist/esm-es5/app-globals-b0dd0fc4.js +1 -0
- package/dist/esm-es5/bal-carousel_2.entry.js +1 -1
- package/dist/esm-es5/bal-datepicker.entry.js +1 -1
- package/dist/esm-es5/bal-divider.entry.js +1 -1
- package/dist/esm-es5/bal-hint_5.entry.js +1 -1
- package/dist/esm-es5/bal-list_8.entry.js +1 -1
- package/dist/esm-es5/bal-logo.entry.js +1 -1
- package/dist/esm-es5/bal-nav_8.entry.js +1 -1
- package/dist/esm-es5/bal-navbar_5.entry.js +1 -1
- package/dist/esm-es5/bal-pagination.entry.js +1 -1
- package/dist/esm-es5/bal-progress-bar.entry.js +1 -1
- package/dist/esm-es5/bal-segment_2.entry.js +1 -1
- package/dist/esm-es5/bal-shape.entry.js +1 -1
- package/dist/esm-es5/bal-steps.entry.js +1 -1
- package/dist/esm-es5/bal-tab-item_2.entry.js +1 -1
- package/dist/esm-es5/baloise-design-system.js +1 -1
- package/dist/esm-es5/{breakpoints.decorator-e82931ce.js → breakpoints.decorator-c7356fbf.js} +1 -1
- package/dist/esm-es5/{breakpoints.subject-76a230e3.js → breakpoints.subject-c11e7472.js} +1 -1
- package/dist/esm-es5/index.js +1 -1
- package/dist/esm-es5/initialize-e216cfe4.js +1 -1
- package/dist/esm-es5/loader.js +1 -1
- package/dist/esm-es5/{window-resize.decorator-76d795d0.js → window-resize.decorator-4d922021.js} +1 -1
- package/dist/html.html-data.json +12 -0
- package/dist/types/components/bal-divider/bal-divider.d.ts +4 -0
- package/dist/types/components/bal-divider/bal-divider.interfaces.d.ts +1 -0
- package/dist/types/components.d.ts +8 -37
- package/package.json +7 -7
- package/components/bal-app2.js +0 -87
- package/components/bal-doc-app.d.ts +0 -11
- package/components/bal-doc-app.js +0 -260
- package/components/initialize.js +0 -288
- package/dist/baloise-design-system/p-360068a4.system.js +0 -1
- package/dist/baloise-design-system/p-4ff656dd48.entry.js +0 -1
- package/dist/baloise-design-system/p-6d1b6215.js +0 -1
- package/dist/baloise-design-system/p-7291766c.system.js +0 -1
- package/dist/baloise-design-system/p-7cc52e4a3b.system.entry.js +0 -1
- package/dist/baloise-design-system/p-9aa1b794.js +0 -1
- package/dist/baloise-design-system/p-b20a3b881d.entry.js +0 -1
- package/dist/baloise-design-system/p-e8ffddeb.js +0 -1
- package/dist/cjs/app-globals-5fd73c0c.js +0 -7
- package/dist/cjs/bal-doc-app.cjs.entry.js +0 -231
- package/dist/collection/components/docs/bal-doc-app/bal-doc-app.css +0 -1
- package/dist/collection/components/docs/bal-doc-app/bal-doc-app.js +0 -229
- package/dist/esm/app-globals-970bab17.js +0 -5
- package/dist/esm/bal-doc-app.entry.js +0 -227
- package/dist/esm-es5/app-globals-970bab17.js +0 -1
- package/dist/esm-es5/bal-doc-app.entry.js +0 -1
- package/dist/esm-es5/global-63f4bcec.js +0 -1
- package/dist/types/components/docs/bal-doc-app/bal-doc-app.d.ts +0 -21
- package/dist/types/home/runner/work/design-system/design-system/packages/core/.stencil/packages/icons/src/index.d.ts +0 -81
- /package/dist/baloise-design-system/{p-08982ec1.system.js → p-788f308a.system.js} +0 -0
- /package/dist/baloise-design-system/{p-41b9b40c.js → p-8e798e23.js} +0 -0
- /package/dist/esm-es5/{tokens.esm-37a3b6c5.js → tokens.esm-ebe36fdf.js} +0 -0
package/components/initialize.js
DELETED
|
@@ -1,288 +0,0 @@
|
|
|
1
|
-
import { setPlatformHelpers } from '@stencil/core/internal/client';
|
|
2
|
-
import { b as balBrowser } from './browser.js';
|
|
3
|
-
import { d as defaultConfig } from './config.default.js';
|
|
4
|
-
|
|
5
|
-
const BALOISE_SESSION_KEY = 'baloise-persist-config';
|
|
6
|
-
|
|
7
|
-
class Config {
|
|
8
|
-
constructor() {
|
|
9
|
-
this._componentObservers = [];
|
|
10
|
-
this._observers = [];
|
|
11
|
-
this._config = defaultConfig;
|
|
12
|
-
}
|
|
13
|
-
get locale() {
|
|
14
|
-
return `${this._config.language}-${this._config.region}`;
|
|
15
|
-
}
|
|
16
|
-
get region() {
|
|
17
|
-
return this._config.region;
|
|
18
|
-
}
|
|
19
|
-
set region(region) {
|
|
20
|
-
if (region !== this._config.region) {
|
|
21
|
-
this._config.region = region;
|
|
22
|
-
this._notify();
|
|
23
|
-
}
|
|
24
|
-
}
|
|
25
|
-
get language() {
|
|
26
|
-
return this._config.language;
|
|
27
|
-
}
|
|
28
|
-
set language(language) {
|
|
29
|
-
if (language !== this._config.language) {
|
|
30
|
-
if (this._config.allowedLanguages.includes(language)) {
|
|
31
|
-
this._config.language = language;
|
|
32
|
-
}
|
|
33
|
-
else {
|
|
34
|
-
this._config.language = this._config.fallbackLanguage;
|
|
35
|
-
}
|
|
36
|
-
this._notify();
|
|
37
|
-
}
|
|
38
|
-
}
|
|
39
|
-
get allowedLanguages() {
|
|
40
|
-
return this._config.allowedLanguages;
|
|
41
|
-
}
|
|
42
|
-
set allowedLanguages(allowedLanguages) {
|
|
43
|
-
if (allowedLanguages !== this._config.allowedLanguages) {
|
|
44
|
-
this._config.allowedLanguages = allowedLanguages;
|
|
45
|
-
this._notify();
|
|
46
|
-
}
|
|
47
|
-
}
|
|
48
|
-
get icons() {
|
|
49
|
-
return this._config.icons;
|
|
50
|
-
}
|
|
51
|
-
set icons(icons) {
|
|
52
|
-
this._config.icons = Object.assign(Object.assign({}, this._config.icons), icons);
|
|
53
|
-
this._notify();
|
|
54
|
-
}
|
|
55
|
-
get logger() {
|
|
56
|
-
return this._config.logger;
|
|
57
|
-
}
|
|
58
|
-
set logger(logger) {
|
|
59
|
-
this._config.logger = Object.assign({}, logger);
|
|
60
|
-
this._notify();
|
|
61
|
-
}
|
|
62
|
-
get animated() {
|
|
63
|
-
return this._config.animated;
|
|
64
|
-
}
|
|
65
|
-
set animated(animated) {
|
|
66
|
-
this._config.animated = animated;
|
|
67
|
-
this._notify();
|
|
68
|
-
}
|
|
69
|
-
get httpFormSubmit() {
|
|
70
|
-
return this._config.httpFormSubmit;
|
|
71
|
-
}
|
|
72
|
-
set httpFormSubmit(httpFormSubmit) {
|
|
73
|
-
this._config.httpFormSubmit = httpFormSubmit;
|
|
74
|
-
this._notify();
|
|
75
|
-
}
|
|
76
|
-
attach(observer) {
|
|
77
|
-
const isExist = this._observers.includes(observer);
|
|
78
|
-
if (isExist) {
|
|
79
|
-
return console.log('Subject: Observer has been attached already.');
|
|
80
|
-
}
|
|
81
|
-
this._observers.push(observer);
|
|
82
|
-
observer.configChanged(this._config);
|
|
83
|
-
}
|
|
84
|
-
detach(observer) {
|
|
85
|
-
const observerIndex = this._observers.indexOf(observer);
|
|
86
|
-
if (observerIndex === -1) {
|
|
87
|
-
return console.log('Subject: Nonexistent observer.');
|
|
88
|
-
}
|
|
89
|
-
this._observers.splice(observerIndex, 1);
|
|
90
|
-
}
|
|
91
|
-
attachComponent(observer) {
|
|
92
|
-
const isExist = this._componentObservers.includes(observer);
|
|
93
|
-
if (isExist) {
|
|
94
|
-
return console.log('Subject: Observer has been attached already.');
|
|
95
|
-
}
|
|
96
|
-
this._componentObservers.push(observer);
|
|
97
|
-
observer.configChanged(this._config);
|
|
98
|
-
}
|
|
99
|
-
detachComponent(observer) {
|
|
100
|
-
const observerIndex = this._componentObservers.indexOf(observer);
|
|
101
|
-
if (observerIndex === -1) {
|
|
102
|
-
return console.log('Subject: Nonexistent observer.');
|
|
103
|
-
}
|
|
104
|
-
this._componentObservers.splice(observerIndex, 1);
|
|
105
|
-
}
|
|
106
|
-
toString() {
|
|
107
|
-
return JSON.stringify(this._config);
|
|
108
|
-
}
|
|
109
|
-
reset(config) {
|
|
110
|
-
this._config = Object.assign(Object.assign(Object.assign({}, this._config), config), { icons: Object.assign(Object.assign({}, this._config.icons), config.icons) });
|
|
111
|
-
this._notify(false);
|
|
112
|
-
}
|
|
113
|
-
_notify(all = true) {
|
|
114
|
-
for (const observer of this._componentObservers) {
|
|
115
|
-
observer.configChanged(this._config);
|
|
116
|
-
}
|
|
117
|
-
if (all) {
|
|
118
|
-
for (const observer of this._observers) {
|
|
119
|
-
observer.configChanged(this._config);
|
|
120
|
-
}
|
|
121
|
-
}
|
|
122
|
-
if (balBrowser.hasWindow) {
|
|
123
|
-
saveConfig(window, this._config);
|
|
124
|
-
}
|
|
125
|
-
}
|
|
126
|
-
}
|
|
127
|
-
const config = /*@__PURE__*/ new Config();
|
|
128
|
-
const configFromSession = (win) => {
|
|
129
|
-
try {
|
|
130
|
-
const configStr = win.sessionStorage.getItem(BALOISE_SESSION_KEY);
|
|
131
|
-
return configStr !== null ? JSON.parse(configStr) : {};
|
|
132
|
-
}
|
|
133
|
-
catch (e) {
|
|
134
|
-
return {};
|
|
135
|
-
}
|
|
136
|
-
};
|
|
137
|
-
const saveConfig = (win, c) => {
|
|
138
|
-
try {
|
|
139
|
-
win.sessionStorage.setItem(BALOISE_SESSION_KEY, JSON.stringify(c));
|
|
140
|
-
}
|
|
141
|
-
catch (e) {
|
|
142
|
-
return;
|
|
143
|
-
}
|
|
144
|
-
};
|
|
145
|
-
|
|
146
|
-
const setupConfig = (userConfig = {}, win = {}) => {
|
|
147
|
-
if (Object.keys(win).length === 0 && balBrowser.hasWindow) {
|
|
148
|
-
win = window;
|
|
149
|
-
}
|
|
150
|
-
win.BaloiseDesignSystem = win.BaloiseDesignSystem || {};
|
|
151
|
-
config.reset(Object.assign(Object.assign(Object.assign({}, configFromSession(win)), userConfig), { icons: Object.assign(Object.assign({}, configFromSession(win).icons), userConfig.icons) }));
|
|
152
|
-
win.BaloiseDesignSystem.config = config;
|
|
153
|
-
};
|
|
154
|
-
|
|
155
|
-
class BalNoticeController {
|
|
156
|
-
constructor(options) {
|
|
157
|
-
this.options = options;
|
|
158
|
-
this.container = null;
|
|
159
|
-
this.queue = [];
|
|
160
|
-
this.preQueue = [];
|
|
161
|
-
this.queueLimit = 5;
|
|
162
|
-
}
|
|
163
|
-
create(options) {
|
|
164
|
-
if (balBrowser.hasDocument) {
|
|
165
|
-
this.setupContainer();
|
|
166
|
-
const clone = this.findClone(options);
|
|
167
|
-
if (clone === undefined) {
|
|
168
|
-
const el = document.createElement(this.options.tag);
|
|
169
|
-
Object.assign(el, options);
|
|
170
|
-
el.addEventListener('balClose', ev => {
|
|
171
|
-
this.removeFromQueue(ev.detail);
|
|
172
|
-
});
|
|
173
|
-
this.preQueue.push(el);
|
|
174
|
-
this.updateQueue();
|
|
175
|
-
return el;
|
|
176
|
-
}
|
|
177
|
-
return clone;
|
|
178
|
-
}
|
|
179
|
-
}
|
|
180
|
-
setQueue(queueLimit) {
|
|
181
|
-
this.queueLimit = queueLimit;
|
|
182
|
-
}
|
|
183
|
-
async dismissAll() {
|
|
184
|
-
var _a;
|
|
185
|
-
const elements = (_a = this.container) === null || _a === void 0 ? void 0 : _a.querySelectorAll(this.options.tag);
|
|
186
|
-
if (elements) {
|
|
187
|
-
const closingQueue = [];
|
|
188
|
-
for (let index = 0; index < elements.length; index++) {
|
|
189
|
-
const el = elements[index];
|
|
190
|
-
if (el.close) {
|
|
191
|
-
closingQueue.push(el.close());
|
|
192
|
-
}
|
|
193
|
-
}
|
|
194
|
-
await Promise.all(closingQueue);
|
|
195
|
-
}
|
|
196
|
-
}
|
|
197
|
-
/**
|
|
198
|
-
* @deprecated use dismissAll instead
|
|
199
|
-
*/
|
|
200
|
-
async clearAll() {
|
|
201
|
-
console.warn('[DEPRECATED] - use dismissAll() instead');
|
|
202
|
-
return this.dismissAll();
|
|
203
|
-
}
|
|
204
|
-
findClone(options) {
|
|
205
|
-
for (let index = 0; index < this.queue.length; index++) {
|
|
206
|
-
const el = this.queue[index];
|
|
207
|
-
if (el.message === options.message && el.color === options.color) {
|
|
208
|
-
return el;
|
|
209
|
-
}
|
|
210
|
-
}
|
|
211
|
-
return undefined;
|
|
212
|
-
}
|
|
213
|
-
setupContainer() {
|
|
214
|
-
if (balBrowser.hasDocument) {
|
|
215
|
-
const containerId = `${this.options.tag}-container`;
|
|
216
|
-
this.container = document.getElementById(containerId);
|
|
217
|
-
if (this.container)
|
|
218
|
-
return;
|
|
219
|
-
if (!this.container) {
|
|
220
|
-
this.container = document.createElement('bal-notices');
|
|
221
|
-
this.container.setAttribute('interface', this.options.tag.replace('bal-', ''));
|
|
222
|
-
this.container.id = containerId;
|
|
223
|
-
}
|
|
224
|
-
document.body.appendChild(this.container);
|
|
225
|
-
}
|
|
226
|
-
}
|
|
227
|
-
updateQueue() {
|
|
228
|
-
var _a;
|
|
229
|
-
if (this.queue.length < this.queueLimit) {
|
|
230
|
-
const el = this.preQueue.shift();
|
|
231
|
-
if (el && this.container) {
|
|
232
|
-
this.queue.push(el);
|
|
233
|
-
this.container.insertAdjacentElement('beforeend', el);
|
|
234
|
-
}
|
|
235
|
-
}
|
|
236
|
-
if (this.queue.length === 0) {
|
|
237
|
-
(_a = this.container) === null || _a === void 0 ? void 0 : _a.remove();
|
|
238
|
-
}
|
|
239
|
-
}
|
|
240
|
-
removeFromQueue(toastId) {
|
|
241
|
-
this.queue = this.queue.filter(el => el.id !== toastId);
|
|
242
|
-
setTimeout(() => this.updateQueue(), 0);
|
|
243
|
-
}
|
|
244
|
-
}
|
|
245
|
-
|
|
246
|
-
class BalToastController extends BalNoticeController {
|
|
247
|
-
constructor() {
|
|
248
|
-
super({
|
|
249
|
-
tag: 'bal-toast',
|
|
250
|
-
});
|
|
251
|
-
}
|
|
252
|
-
create(options) {
|
|
253
|
-
return super.create(options);
|
|
254
|
-
}
|
|
255
|
-
}
|
|
256
|
-
const balToastController = new BalToastController();
|
|
257
|
-
|
|
258
|
-
class BalSnackbarController extends BalNoticeController {
|
|
259
|
-
constructor() {
|
|
260
|
-
super({
|
|
261
|
-
tag: 'bal-snackbar',
|
|
262
|
-
});
|
|
263
|
-
}
|
|
264
|
-
create(options) {
|
|
265
|
-
return super.create(options);
|
|
266
|
-
}
|
|
267
|
-
}
|
|
268
|
-
const balSnackbarController = new BalSnackbarController();
|
|
269
|
-
|
|
270
|
-
// generated by .build/version.js
|
|
271
|
-
const VERSION = '16.5.2-nightly.20241016';
|
|
272
|
-
|
|
273
|
-
const initializeBaloiseDesignSystem = (userConfig = {}, platformConfig = undefined, win = {}) => {
|
|
274
|
-
if (Object.keys(win).length === 0 && balBrowser.hasWindow) {
|
|
275
|
-
win = window;
|
|
276
|
-
}
|
|
277
|
-
win.BaloiseDesignSystem = win.BaloiseDesignSystem || {};
|
|
278
|
-
if (platformConfig) {
|
|
279
|
-
setPlatformHelpers(platformConfig);
|
|
280
|
-
}
|
|
281
|
-
setupConfig(Object.assign(Object.assign({}, userConfig), platformConfig), win);
|
|
282
|
-
win.BaloiseDesignSystem.toastController = balToastController;
|
|
283
|
-
win.BaloiseDesignSystem.snackbarController = balSnackbarController;
|
|
284
|
-
win.BaloiseDesignSystem.initialize = () => setupConfig(win.BaloiseDesignSystem.config, win);
|
|
285
|
-
win.BaloiseDesignSystem.version = VERSION;
|
|
286
|
-
};
|
|
287
|
-
|
|
288
|
-
export { BalToastController as B, BalSnackbarController as a, balToastController as b, balSnackbarController as c, initializeBaloiseDesignSystem as i, setupConfig as s };
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
System.register(["./p-f959646a.system.js"],(function(t){"use strict";var e;return{setters:[function(t){e=t.g}],execute:function(){var s=t("g",e)}}}));
|