@plaidev/karte-action-sdk 1.0.28 → 1.0.31
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/index.es.d.ts +51 -5
- package/dist/index.es.js +393 -224
- package/package.json +2 -1
package/dist/index.es.d.ts
CHANGED
|
@@ -230,13 +230,59 @@ declare function hasSuffix<Suffix extends "px" | "em" | "rem" | "%" | "fr" | "vw
|
|
|
230
230
|
declare function toBr(text: string): string;
|
|
231
231
|
declare function randStr(digit?: number): string;
|
|
232
232
|
declare const _default: "dummy";
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
233
|
+
declare function hideOnScroll<Props extends {
|
|
234
|
+
hide_on_scroll: boolean;
|
|
235
|
+
hide_on_scroll_rate: number;
|
|
236
|
+
show_on_scroll_reenter: boolean;
|
|
237
|
+
}>(props: Props, fn?: () => void): () => void;
|
|
238
|
+
declare function hideOnTime<Props extends {
|
|
239
|
+
hide_on_time: boolean;
|
|
240
|
+
hide_on_time_count: number;
|
|
241
|
+
}>(props: Props, fn?: () => void): () => void;
|
|
242
|
+
declare function showOnScroll<Props extends {
|
|
243
|
+
show_on_scroll: boolean;
|
|
244
|
+
show_on_scroll_rate: number;
|
|
245
|
+
show_on_scroll_reenter: boolean;
|
|
246
|
+
}>(props: Props, fn?: Function): () => void;
|
|
247
|
+
declare function showOnTime<Props extends {
|
|
248
|
+
show_on_time: boolean;
|
|
249
|
+
show_on_time_count: number;
|
|
250
|
+
}>(props: Props, fn?: Function): () => void;
|
|
251
|
+
declare function ensureModalRoot(useShadow?: boolean): ShadowRoot | HTMLElement;
|
|
252
|
+
declare const h: (type: string, props: any, ...children: Array<any>) => HTMLElement;
|
|
253
|
+
declare function createFog({ color, opacity, zIndex, onclick }: {
|
|
254
|
+
color?: string;
|
|
255
|
+
opacity?: string;
|
|
256
|
+
zIndex?: number;
|
|
257
|
+
onclick: () => void;
|
|
258
|
+
}): {
|
|
259
|
+
fog: HTMLDivElement;
|
|
260
|
+
close: () => void;
|
|
261
|
+
};
|
|
262
|
+
type EmbedLogic = "replace" | "append" | "prepend" | "after" | "before";
|
|
263
|
+
declare function embed(target: HTMLElement, replace: HTMLElement, embed_method: EmbedLogic): void;
|
|
264
|
+
declare const collection: (config: {
|
|
265
|
+
api_key: string;
|
|
266
|
+
table: string;
|
|
267
|
+
endpoint?: string;
|
|
268
|
+
}) => {
|
|
269
|
+
get(key: string | string[], cb: (err: Error | null, items?: any) => void): void;
|
|
270
|
+
getByQuery(query_name: string, params: {
|
|
271
|
+
[p: string]: string | number | boolean | (string | number | boolean)[];
|
|
272
|
+
}, options: {
|
|
273
|
+
ignore_fields?: string[];
|
|
274
|
+
} | null | undefined, cb: (err: Error | null, items?: any) => void): void;
|
|
275
|
+
set(key: string, value: string, cb: (err: Error | null) => void): void;
|
|
276
|
+
};
|
|
277
|
+
export { state, closed, maximumZindex, initialize, finalize, send_event, isPreview, setMiximumZindex, none, moveTo, linkTo, closeApp, _default, handleFocus, setPreviousFocus, handleKeydown, getPositionStyle, getMarginStyle, onScroll, onTime, hasSuffix, toBr, randStr, PropTypes, PropType, Code, MediaQueries, MediaQuery, Directions, Direction, AnimationStyles, AnimationStyle, AnimationStyleTranslations, ModalPositions, ModalPosition, ModalPositionTranslations, ModalMarginTranslations, ModalMargin, ModalPlacement, DefaultModalPlacement, LongText, Url, Image, LengthUnits, LengthUnit, Length, Color, Justifies, Justify, Alignments, Alignment, ObjectFits, ObjectFit, Repeats, Repeat, BackgroundSizes, BackgroundSize, Style, StateName, hideOnScroll, hideOnTime, showOnScroll, showOnTime, ensureModalRoot, h, createFog, EmbedLogic, embed, collection };
|
|
278
|
+
export { default as State } from './components/State.svelte';
|
|
279
|
+
export { default as StateItem } from './components/StateItem.svelte';
|
|
280
|
+
export { default as Modal } from './components/Modal.svelte';
|
|
281
|
+
export { default as GridModalState } from './components/GridModalState.svelte';
|
|
282
|
+
export { default as Grid } from './components/Grid.svelte';
|
|
283
|
+
export { default as GridItem } from './components/GridItem.svelte';
|
|
237
284
|
export { default as Flex } from './components/Flex.svelte';
|
|
238
285
|
export { default as FlexItem } from './components/FlexItem.svelte';
|
|
239
|
-
export { default as Modal } from './components/Modal.svelte';
|
|
240
286
|
export { default as TextBlock } from './components/TextBlock.svelte';
|
|
241
287
|
export { default as TextButtonBlock } from './components/TextButtonBlock.svelte';
|
|
242
288
|
export { default as ImageBlock } from './components/ImageBlock.svelte';
|
package/dist/index.es.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { writable, get } from 'svelte/store';
|
|
2
|
-
import { SvelteComponent, init, safe_not_equal, append_styles, create_slot, create_component, space, mount_component, insert, update_slot_base, get_all_dirty_from_scope, get_slot_changes, transition_in, transition_out, destroy_component, detach, empty, group_outros, check_outros, component_subscribe, noop, element, attr, listen, null_to_empty, append,
|
|
2
|
+
import { SvelteComponent, init, safe_not_equal, append_styles, create_slot, create_component, space, mount_component, insert, update_slot_base, get_all_dirty_from_scope, get_slot_changes, transition_in, transition_out, destroy_component, detach, empty, group_outros, check_outros, component_subscribe, noop, element, attr, listen, null_to_empty, append, binding_callbacks, svg_element, src_url_equal } from 'svelte/internal';
|
|
3
3
|
import { createEventDispatcher, onDestroy, onMount, setContext, getContext } from 'svelte';
|
|
4
4
|
|
|
5
5
|
/**
|
|
@@ -310,7 +310,179 @@ const ObjectFits = ['fill', 'contain', 'cover'];
|
|
|
310
310
|
const Repeats = ['repeat', 'space', 'round', 'no-repeat'];
|
|
311
311
|
const BackgroundSizes = ['cover', 'contain', 'auto'];
|
|
312
312
|
|
|
313
|
-
|
|
313
|
+
const NOOP = () => { };
|
|
314
|
+
function hideOnScroll(props, fn) {
|
|
315
|
+
return props.hide_on_scroll && props.hide_on_scroll_rate
|
|
316
|
+
? onScroll(() => {
|
|
317
|
+
fn && fn();
|
|
318
|
+
return props.show_on_scroll_reenter;
|
|
319
|
+
}, props.hide_on_scroll_rate / 100)
|
|
320
|
+
: NOOP;
|
|
321
|
+
}
|
|
322
|
+
function hideOnTime(props, fn) {
|
|
323
|
+
return props.hide_on_time && props.hide_on_time_count
|
|
324
|
+
? onTime(() => {
|
|
325
|
+
fn && fn();
|
|
326
|
+
}, props.hide_on_time_count * 1000)
|
|
327
|
+
: NOOP;
|
|
328
|
+
}
|
|
329
|
+
function showOnScroll(props, fn) {
|
|
330
|
+
return props.show_on_scroll && props.show_on_scroll_rate
|
|
331
|
+
? onScroll(() => {
|
|
332
|
+
fn && fn();
|
|
333
|
+
return props.show_on_scroll_reenter;
|
|
334
|
+
}, props.show_on_scroll_rate / 100)
|
|
335
|
+
: NOOP;
|
|
336
|
+
}
|
|
337
|
+
function showOnTime(props, fn) {
|
|
338
|
+
return props.show_on_time && props.show_on_time_count
|
|
339
|
+
? onTime(() => {
|
|
340
|
+
fn && fn();
|
|
341
|
+
}, props.show_on_time_count * 1000)
|
|
342
|
+
: NOOP;
|
|
343
|
+
}
|
|
344
|
+
|
|
345
|
+
const KARTE_MODAL_ROOT = 'karte-modal-root';
|
|
346
|
+
function ensureModalRoot(useShadow = true) {
|
|
347
|
+
let el = document.getElementById(KARTE_MODAL_ROOT);
|
|
348
|
+
if (el == null) {
|
|
349
|
+
el = h('div', { id: KARTE_MODAL_ROOT });
|
|
350
|
+
document.body.appendChild(el);
|
|
351
|
+
}
|
|
352
|
+
const isShadow = !!document.body.attachShadow && useShadow;
|
|
353
|
+
if (isShadow) {
|
|
354
|
+
return el.shadowRoot ?? el.attachShadow({ mode: 'open' });
|
|
355
|
+
}
|
|
356
|
+
else {
|
|
357
|
+
return el;
|
|
358
|
+
}
|
|
359
|
+
}
|
|
360
|
+
const h = (type, props, ...children) => {
|
|
361
|
+
const el = document.createElement(type);
|
|
362
|
+
for (const key of Object.keys(props)) {
|
|
363
|
+
const v = props[key];
|
|
364
|
+
if (key === 'style') {
|
|
365
|
+
Object.assign(el.style, v);
|
|
366
|
+
}
|
|
367
|
+
else {
|
|
368
|
+
// @ts-ignore
|
|
369
|
+
el[key] = v;
|
|
370
|
+
}
|
|
371
|
+
}
|
|
372
|
+
for (const child of children) {
|
|
373
|
+
el.appendChild(child);
|
|
374
|
+
}
|
|
375
|
+
return el;
|
|
376
|
+
};
|
|
377
|
+
function createFog({ color = '#000', opacity = '50%', zIndex = 999, onclick, }) {
|
|
378
|
+
const root = ensureModalRoot(false);
|
|
379
|
+
if (root.querySelector('.__krt-fog')) {
|
|
380
|
+
return { fog: null, close: () => { } };
|
|
381
|
+
}
|
|
382
|
+
const fog = document.createElement('div');
|
|
383
|
+
fog.className = '__krt-fog';
|
|
384
|
+
Object.assign(fog.style, {
|
|
385
|
+
position: 'fixed',
|
|
386
|
+
left: 0,
|
|
387
|
+
top: 0,
|
|
388
|
+
width: '100%',
|
|
389
|
+
height: '100%',
|
|
390
|
+
'z-index': zIndex,
|
|
391
|
+
'background-color': color,
|
|
392
|
+
opacity,
|
|
393
|
+
});
|
|
394
|
+
const close = () => {
|
|
395
|
+
onclick();
|
|
396
|
+
fog.remove();
|
|
397
|
+
};
|
|
398
|
+
fog.onclick = close;
|
|
399
|
+
root.appendChild(fog);
|
|
400
|
+
return { fog, close };
|
|
401
|
+
}
|
|
402
|
+
function embed(target, replace, embed_method) {
|
|
403
|
+
if (embed_method == 'replace') {
|
|
404
|
+
if (target.parentNode) {
|
|
405
|
+
target.parentNode.replaceChild(replace, target);
|
|
406
|
+
}
|
|
407
|
+
}
|
|
408
|
+
else if (embed_method == 'append') {
|
|
409
|
+
target.append(replace);
|
|
410
|
+
}
|
|
411
|
+
else if (embed_method == 'prepend') {
|
|
412
|
+
target.prepend(replace);
|
|
413
|
+
}
|
|
414
|
+
else if (embed_method == 'after') {
|
|
415
|
+
target.after(replace);
|
|
416
|
+
}
|
|
417
|
+
else if (embed_method == 'before') {
|
|
418
|
+
target.before(replace);
|
|
419
|
+
}
|
|
420
|
+
}
|
|
421
|
+
|
|
422
|
+
const ENDPOINT = 'https://t.karte.io/collection';
|
|
423
|
+
const collection = (config) => {
|
|
424
|
+
const endpoint = config.endpoint ?? ENDPOINT;
|
|
425
|
+
const api_key = config.api_key;
|
|
426
|
+
const table = config.table;
|
|
427
|
+
return {
|
|
428
|
+
get(key, cb) {
|
|
429
|
+
if (Array.isArray(key)) {
|
|
430
|
+
return request(`${endpoint}/getByKeys`, {
|
|
431
|
+
api_key,
|
|
432
|
+
name: table,
|
|
433
|
+
keys: key,
|
|
434
|
+
}, cb);
|
|
435
|
+
}
|
|
436
|
+
else {
|
|
437
|
+
request(`${endpoint}/getByKey`, {
|
|
438
|
+
api_key,
|
|
439
|
+
name: table,
|
|
440
|
+
key,
|
|
441
|
+
}, cb);
|
|
442
|
+
}
|
|
443
|
+
},
|
|
444
|
+
getByQuery(query_name, params, options, cb) {
|
|
445
|
+
request(`${endpoint}/getByQuery`, {
|
|
446
|
+
api_key,
|
|
447
|
+
name: table,
|
|
448
|
+
query_name,
|
|
449
|
+
params,
|
|
450
|
+
options,
|
|
451
|
+
}, cb);
|
|
452
|
+
},
|
|
453
|
+
set(key, value, cb) {
|
|
454
|
+
request(`${endpoint}/set`, {
|
|
455
|
+
api_key,
|
|
456
|
+
name: table,
|
|
457
|
+
key,
|
|
458
|
+
value,
|
|
459
|
+
}, cb);
|
|
460
|
+
},
|
|
461
|
+
};
|
|
462
|
+
};
|
|
463
|
+
function request(url, data, cb) {
|
|
464
|
+
const xhr = new XMLHttpRequest();
|
|
465
|
+
xhr.onreadystatechange = () => {
|
|
466
|
+
if (xhr.readyState != 4) {
|
|
467
|
+
return;
|
|
468
|
+
}
|
|
469
|
+
if (xhr.status != 200) {
|
|
470
|
+
return cb(new Error(`fail to send collection api request. reason: ${xhr.responseText}`));
|
|
471
|
+
}
|
|
472
|
+
try {
|
|
473
|
+
data = JSON.parse(xhr.responseText);
|
|
474
|
+
return cb(null, data);
|
|
475
|
+
}
|
|
476
|
+
catch (err) {
|
|
477
|
+
return cb(err);
|
|
478
|
+
}
|
|
479
|
+
};
|
|
480
|
+
xhr.open('POST', url);
|
|
481
|
+
xhr.setRequestHeader('Content-Type', 'text/plain;charset=UTF-8');
|
|
482
|
+
xhr.send(JSON.stringify({ ...data }));
|
|
483
|
+
}
|
|
484
|
+
|
|
485
|
+
/* src/components/elements/Normalize.svelte generated by Svelte v3.44.1 */
|
|
314
486
|
|
|
315
487
|
function add_css$9(target) {
|
|
316
488
|
append_styles(target, "svelte-zmz1k7", "@import 'https://cdn.skypack.dev/normalize.css';");
|
|
@@ -323,7 +495,7 @@ class Normalize extends SvelteComponent {
|
|
|
323
495
|
}
|
|
324
496
|
}
|
|
325
497
|
|
|
326
|
-
/* src/State.svelte generated by Svelte v3.44.1 */
|
|
498
|
+
/* src/components/State.svelte generated by Svelte v3.44.1 */
|
|
327
499
|
|
|
328
500
|
function create_fragment$c(ctx) {
|
|
329
501
|
let normalize;
|
|
@@ -526,7 +698,7 @@ class StateItem extends SvelteComponent {
|
|
|
526
698
|
}
|
|
527
699
|
}
|
|
528
700
|
|
|
529
|
-
/* src/components/BackgroundOverray.svelte generated by Svelte v3.44.1 */
|
|
701
|
+
/* src/components/elements/BackgroundOverray.svelte generated by Svelte v3.44.1 */
|
|
530
702
|
|
|
531
703
|
function add_css$8(target) {
|
|
532
704
|
append_styles(target, "svelte-1h4b6e3", ".background.svelte-1h4b6e3{position:fixed;top:0;left:0;width:100%;height:100%;background:rgba(0, 0, 0, 0.3)}");
|
|
@@ -615,7 +787,7 @@ class BackgroundOverray extends SvelteComponent {
|
|
|
615
787
|
}
|
|
616
788
|
}
|
|
617
789
|
|
|
618
|
-
/* src/components/Animation.svelte generated by Svelte v3.44.1 */
|
|
790
|
+
/* src/components/elements/Animation.svelte generated by Svelte v3.44.1 */
|
|
619
791
|
|
|
620
792
|
function add_css$7(target) {
|
|
621
793
|
append_styles(target, "svelte-sa0cac", "@keyframes svelte-sa0cac-fade{0%{opacity:0}100%{opacity:1}}.fade.svelte-sa0cac{animation-name:svelte-sa0cac-fade;animation-duration:1s}@keyframes svelte-sa0cac-bounce{0%{opacity:0;transform:scale(0.3)}50%{opacity:1;transform:scale(1.05)}70%{transform:scale(0.9)}100%{transform:scale(1)}}.bounce.svelte-sa0cac{animation-name:svelte-sa0cac-bounce;animation-duration:1s}@keyframes svelte-sa0cac-slide-down{0%{transform:translate3d(0, -100%, 0);visibility:visible}100%{transform:translate3d(0, 0, 0)}}.slide-down.svelte-sa0cac{animation-name:svelte-sa0cac-slide-down;animation-duration:1s;animation-delay:0.1s}@keyframes svelte-sa0cac-slide-up{0%{transform:translate3d(0, 100%, 0);visibility:visible}100%{transform:translate3d(0, 0, 0)}}.slide-up.svelte-sa0cac{animation-name:svelte-sa0cac-slide-up;animation-duration:1s;animation-delay:0.1s}@keyframes svelte-sa0cac-slide-left{0%{transform:translate3d(100%, 0, 0);visibility:visible}100%{transform:translate3d(0, 0, 0)}}.slide-left.svelte-sa0cac{animation-name:svelte-sa0cac-slide-left;animation-duration:1s;animation-delay:0.1s}@keyframes svelte-sa0cac-slide-right{0%{transform:translate3d(-100%, 0, 0);visibility:visible}100%{transform:translate3d(0, 0, 0)}}.slide-right.svelte-sa0cac{animation-name:svelte-sa0cac-slide-right;animation-duration:1s;animation-delay:0.1s}");
|
|
@@ -700,7 +872,7 @@ function add_css$6(target) {
|
|
|
700
872
|
append_styles(target, "svelte-1bxl6mz", ".modal.svelte-1bxl6mz{position:fixed;box-sizing:border-box;z-index:2147483647}.close.svelte-1bxl6mz{position:absolute;display:flex;justify-content:center;align-items:center;background-color:transparent;border:none;cursor:pointer;padding:0;transition:all 0.25s}.close.svelte-1bxl6mz:hover{transform:rotate(90deg)}");
|
|
701
873
|
}
|
|
702
874
|
|
|
703
|
-
// (
|
|
875
|
+
// (84:4) {#if closable}
|
|
704
876
|
function create_if_block(ctx) {
|
|
705
877
|
let button;
|
|
706
878
|
let svg;
|
|
@@ -723,7 +895,7 @@ function create_if_block(ctx) {
|
|
|
723
895
|
attr(svg, "fill", "none");
|
|
724
896
|
attr(svg, "xmlns", "http://www.w3.org/2000/svg");
|
|
725
897
|
attr(button, "class", "close svelte-1bxl6mz");
|
|
726
|
-
attr(button, "style", button_style_value = "z-index:" + (/*$maximumZindex*/ ctx[
|
|
898
|
+
attr(button, "style", button_style_value = "z-index:" + (/*$maximumZindex*/ ctx[9] + 1) + "; " + /*_closeStyle*/ ctx[4] + "");
|
|
727
899
|
},
|
|
728
900
|
m(target, anchor) {
|
|
729
901
|
insert(target, button, anchor);
|
|
@@ -731,7 +903,7 @@ function create_if_block(ctx) {
|
|
|
731
903
|
append(svg, path);
|
|
732
904
|
|
|
733
905
|
if (!mounted) {
|
|
734
|
-
dispose = listen(button, "click", /*close*/ ctx[
|
|
906
|
+
dispose = listen(button, "click", /*close*/ ctx[10]);
|
|
735
907
|
mounted = true;
|
|
736
908
|
}
|
|
737
909
|
},
|
|
@@ -740,7 +912,7 @@ function create_if_block(ctx) {
|
|
|
740
912
|
attr(path, "fill", /*closeButtonColor*/ ctx[1]);
|
|
741
913
|
}
|
|
742
914
|
|
|
743
|
-
if (dirty & /*$maximumZindex, _closeStyle*/
|
|
915
|
+
if (dirty & /*$maximumZindex, _closeStyle*/ 528 && button_style_value !== (button_style_value = "z-index:" + (/*$maximumZindex*/ ctx[9] + 1) + "; " + /*_closeStyle*/ ctx[4] + "")) {
|
|
744
916
|
attr(button, "style", button_style_value);
|
|
745
917
|
}
|
|
746
918
|
},
|
|
@@ -752,16 +924,15 @@ function create_if_block(ctx) {
|
|
|
752
924
|
};
|
|
753
925
|
}
|
|
754
926
|
|
|
755
|
-
|
|
927
|
+
// (72:0) <Animation {animation}>
|
|
928
|
+
function create_default_slot$1(ctx) {
|
|
756
929
|
let div;
|
|
757
930
|
let t;
|
|
758
931
|
let div_style_value;
|
|
759
932
|
let current;
|
|
760
|
-
let mounted;
|
|
761
|
-
let dispose;
|
|
762
933
|
let if_block = /*closable*/ ctx[0] && create_if_block(ctx);
|
|
763
|
-
const default_slot_template = /*#slots*/ ctx[
|
|
764
|
-
const default_slot = create_slot(default_slot_template, ctx, /*$$scope*/ ctx[
|
|
934
|
+
const default_slot_template = /*#slots*/ ctx[17].default;
|
|
935
|
+
const default_slot = create_slot(default_slot_template, ctx, /*$$scope*/ ctx[19], null);
|
|
765
936
|
|
|
766
937
|
return {
|
|
767
938
|
c() {
|
|
@@ -772,7 +943,7 @@ function create_fragment$8(ctx) {
|
|
|
772
943
|
attr(div, "class", "modal svelte-1bxl6mz");
|
|
773
944
|
attr(div, "role", "dialog");
|
|
774
945
|
attr(div, "aria-modal", "true");
|
|
775
|
-
attr(div, "style", div_style_value = "" + /*pos*/ ctx[
|
|
946
|
+
attr(div, "style", div_style_value = "" + /*pos*/ ctx[7] + " " + /*marginStyle*/ ctx[6] + " " + /*_style*/ ctx[3] + "");
|
|
776
947
|
},
|
|
777
948
|
m(target, anchor) {
|
|
778
949
|
insert(target, div, anchor);
|
|
@@ -783,15 +954,10 @@ function create_fragment$8(ctx) {
|
|
|
783
954
|
default_slot.m(div, null);
|
|
784
955
|
}
|
|
785
956
|
|
|
786
|
-
/*div_binding*/ ctx[
|
|
957
|
+
/*div_binding*/ ctx[18](div);
|
|
787
958
|
current = true;
|
|
788
|
-
|
|
789
|
-
if (!mounted) {
|
|
790
|
-
dispose = listen(window, "keydown", /*handle_keydown*/ ctx[9]);
|
|
791
|
-
mounted = true;
|
|
792
|
-
}
|
|
793
959
|
},
|
|
794
|
-
p(ctx,
|
|
960
|
+
p(ctx, dirty) {
|
|
795
961
|
if (/*closable*/ ctx[0]) {
|
|
796
962
|
if (if_block) {
|
|
797
963
|
if_block.p(ctx, dirty);
|
|
@@ -806,21 +972,21 @@ function create_fragment$8(ctx) {
|
|
|
806
972
|
}
|
|
807
973
|
|
|
808
974
|
if (default_slot) {
|
|
809
|
-
if (default_slot.p && (!current || dirty & /*$$scope*/
|
|
975
|
+
if (default_slot.p && (!current || dirty & /*$$scope*/ 524288)) {
|
|
810
976
|
update_slot_base(
|
|
811
977
|
default_slot,
|
|
812
978
|
default_slot_template,
|
|
813
979
|
ctx,
|
|
814
|
-
/*$$scope*/ ctx[
|
|
980
|
+
/*$$scope*/ ctx[19],
|
|
815
981
|
!current
|
|
816
|
-
? get_all_dirty_from_scope(/*$$scope*/ ctx[
|
|
817
|
-
: get_slot_changes(default_slot_template, /*$$scope*/ ctx[
|
|
982
|
+
? get_all_dirty_from_scope(/*$$scope*/ ctx[19])
|
|
983
|
+
: get_slot_changes(default_slot_template, /*$$scope*/ ctx[19], dirty, null),
|
|
818
984
|
null
|
|
819
985
|
);
|
|
820
986
|
}
|
|
821
987
|
}
|
|
822
988
|
|
|
823
|
-
if (!current || dirty & /*pos, marginStyle, _style*/
|
|
989
|
+
if (!current || dirty & /*pos, marginStyle, _style*/ 200 && div_style_value !== (div_style_value = "" + /*pos*/ ctx[7] + " " + /*marginStyle*/ ctx[6] + " " + /*_style*/ ctx[3] + "")) {
|
|
824
990
|
attr(div, "style", div_style_value);
|
|
825
991
|
}
|
|
826
992
|
},
|
|
@@ -837,7 +1003,80 @@ function create_fragment$8(ctx) {
|
|
|
837
1003
|
if (detaching) detach(div);
|
|
838
1004
|
if (if_block) if_block.d();
|
|
839
1005
|
if (default_slot) default_slot.d(detaching);
|
|
840
|
-
/*div_binding*/ ctx[
|
|
1006
|
+
/*div_binding*/ ctx[18](null);
|
|
1007
|
+
}
|
|
1008
|
+
};
|
|
1009
|
+
}
|
|
1010
|
+
|
|
1011
|
+
function create_fragment$8(ctx) {
|
|
1012
|
+
let backgroundoverray;
|
|
1013
|
+
let t;
|
|
1014
|
+
let animation_1;
|
|
1015
|
+
let current;
|
|
1016
|
+
let mounted;
|
|
1017
|
+
let dispose;
|
|
1018
|
+
|
|
1019
|
+
backgroundoverray = new BackgroundOverray({
|
|
1020
|
+
props: {
|
|
1021
|
+
backgroundOverray: /*backgroundOverray*/ ctx[8]
|
|
1022
|
+
}
|
|
1023
|
+
});
|
|
1024
|
+
|
|
1025
|
+
backgroundoverray.$on("click", /*close*/ ctx[10]);
|
|
1026
|
+
|
|
1027
|
+
animation_1 = new Animation({
|
|
1028
|
+
props: {
|
|
1029
|
+
animation: /*animation*/ ctx[2],
|
|
1030
|
+
$$slots: { default: [create_default_slot$1] },
|
|
1031
|
+
$$scope: { ctx }
|
|
1032
|
+
}
|
|
1033
|
+
});
|
|
1034
|
+
|
|
1035
|
+
return {
|
|
1036
|
+
c() {
|
|
1037
|
+
create_component(backgroundoverray.$$.fragment);
|
|
1038
|
+
t = space();
|
|
1039
|
+
create_component(animation_1.$$.fragment);
|
|
1040
|
+
},
|
|
1041
|
+
m(target, anchor) {
|
|
1042
|
+
mount_component(backgroundoverray, target, anchor);
|
|
1043
|
+
insert(target, t, anchor);
|
|
1044
|
+
mount_component(animation_1, target, anchor);
|
|
1045
|
+
current = true;
|
|
1046
|
+
|
|
1047
|
+
if (!mounted) {
|
|
1048
|
+
dispose = listen(window, "keydown", /*handle_keydown*/ ctx[11]);
|
|
1049
|
+
mounted = true;
|
|
1050
|
+
}
|
|
1051
|
+
},
|
|
1052
|
+
p(ctx, [dirty]) {
|
|
1053
|
+
const backgroundoverray_changes = {};
|
|
1054
|
+
if (dirty & /*backgroundOverray*/ 256) backgroundoverray_changes.backgroundOverray = /*backgroundOverray*/ ctx[8];
|
|
1055
|
+
backgroundoverray.$set(backgroundoverray_changes);
|
|
1056
|
+
const animation_1_changes = {};
|
|
1057
|
+
if (dirty & /*animation*/ 4) animation_1_changes.animation = /*animation*/ ctx[2];
|
|
1058
|
+
|
|
1059
|
+
if (dirty & /*$$scope, pos, marginStyle, _style, modal, $maximumZindex, _closeStyle, closeButtonColor, closable*/ 525051) {
|
|
1060
|
+
animation_1_changes.$$scope = { dirty, ctx };
|
|
1061
|
+
}
|
|
1062
|
+
|
|
1063
|
+
animation_1.$set(animation_1_changes);
|
|
1064
|
+
},
|
|
1065
|
+
i(local) {
|
|
1066
|
+
if (current) return;
|
|
1067
|
+
transition_in(backgroundoverray.$$.fragment, local);
|
|
1068
|
+
transition_in(animation_1.$$.fragment, local);
|
|
1069
|
+
current = true;
|
|
1070
|
+
},
|
|
1071
|
+
o(local) {
|
|
1072
|
+
transition_out(backgroundoverray.$$.fragment, local);
|
|
1073
|
+
transition_out(animation_1.$$.fragment, local);
|
|
1074
|
+
current = false;
|
|
1075
|
+
},
|
|
1076
|
+
d(detaching) {
|
|
1077
|
+
destroy_component(backgroundoverray, detaching);
|
|
1078
|
+
if (detaching) detach(t);
|
|
1079
|
+
destroy_component(animation_1, detaching);
|
|
841
1080
|
mounted = false;
|
|
842
1081
|
dispose();
|
|
843
1082
|
}
|
|
@@ -845,34 +1084,20 @@ function create_fragment$8(ctx) {
|
|
|
845
1084
|
}
|
|
846
1085
|
|
|
847
1086
|
function instance$8($$self, $$props, $$invalidate) {
|
|
1087
|
+
let backgroundOverray;
|
|
1088
|
+
let overwritePosition;
|
|
1089
|
+
let overwriteMargin;
|
|
848
1090
|
let pos;
|
|
849
1091
|
let marginStyle;
|
|
850
1092
|
let $maximumZindex;
|
|
851
|
-
component_subscribe($$self, maximumZindex, $$value => $$invalidate(
|
|
1093
|
+
component_subscribe($$self, maximumZindex, $$value => $$invalidate(9, $maximumZindex = $$value));
|
|
852
1094
|
let { $$slots: slots = {}, $$scope } = $$props;
|
|
853
1095
|
let { closable = true } = $$props;
|
|
854
1096
|
let { closeButtonColor = '#000000' } = $$props;
|
|
855
1097
|
let { eventName = '' } = $$props;
|
|
856
1098
|
let { eventValue = null } = $$props;
|
|
857
|
-
let {
|
|
858
|
-
|
|
859
|
-
|
|
860
|
-
let { margin = {
|
|
861
|
-
left: '0px',
|
|
862
|
-
right: '0px',
|
|
863
|
-
top: '0px',
|
|
864
|
-
bottom: '0px'
|
|
865
|
-
} } = $$props;
|
|
866
|
-
|
|
867
|
-
const overwriteMargin = isPreview()
|
|
868
|
-
? {
|
|
869
|
-
left: '0px',
|
|
870
|
-
right: '0px',
|
|
871
|
-
top: '0px',
|
|
872
|
-
bottom: '0px'
|
|
873
|
-
}
|
|
874
|
-
: margin;
|
|
875
|
-
|
|
1099
|
+
let { animation = 'none' } = $$props;
|
|
1100
|
+
let { placement = DefaultModalPlacement } = $$props;
|
|
876
1101
|
let { _style = '' } = $$props;
|
|
877
1102
|
let { _closeStyle = '' } = $$props;
|
|
878
1103
|
|
|
@@ -896,43 +1121,72 @@ function instance$8($$self, $$props, $$invalidate) {
|
|
|
896
1121
|
function div_binding($$value) {
|
|
897
1122
|
binding_callbacks[$$value ? 'unshift' : 'push'](() => {
|
|
898
1123
|
modal = $$value;
|
|
899
|
-
$$invalidate(
|
|
1124
|
+
$$invalidate(5, modal);
|
|
900
1125
|
});
|
|
901
1126
|
}
|
|
902
1127
|
|
|
903
1128
|
$$self.$$set = $$props => {
|
|
904
1129
|
if ('closable' in $$props) $$invalidate(0, closable = $$props.closable);
|
|
905
1130
|
if ('closeButtonColor' in $$props) $$invalidate(1, closeButtonColor = $$props.closeButtonColor);
|
|
906
|
-
if ('eventName' in $$props) $$invalidate(
|
|
907
|
-
if ('eventValue' in $$props) $$invalidate(
|
|
908
|
-
if ('
|
|
909
|
-
if ('
|
|
910
|
-
if ('_style' in $$props) $$invalidate(
|
|
911
|
-
if ('_closeStyle' in $$props) $$invalidate(
|
|
912
|
-
if ('$$scope' in $$props) $$invalidate(
|
|
1131
|
+
if ('eventName' in $$props) $$invalidate(12, eventName = $$props.eventName);
|
|
1132
|
+
if ('eventValue' in $$props) $$invalidate(13, eventValue = $$props.eventValue);
|
|
1133
|
+
if ('animation' in $$props) $$invalidate(2, animation = $$props.animation);
|
|
1134
|
+
if ('placement' in $$props) $$invalidate(14, placement = $$props.placement);
|
|
1135
|
+
if ('_style' in $$props) $$invalidate(3, _style = $$props._style);
|
|
1136
|
+
if ('_closeStyle' in $$props) $$invalidate(4, _closeStyle = $$props._closeStyle);
|
|
1137
|
+
if ('$$scope' in $$props) $$invalidate(19, $$scope = $$props.$$scope);
|
|
913
1138
|
};
|
|
914
1139
|
|
|
915
|
-
$$
|
|
916
|
-
|
|
1140
|
+
$$self.$$.update = () => {
|
|
1141
|
+
if ($$self.$$.dirty & /*placement*/ 16384) {
|
|
1142
|
+
$$invalidate(8, backgroundOverray = placement.backgroundOverlay);
|
|
1143
|
+
}
|
|
1144
|
+
|
|
1145
|
+
if ($$self.$$.dirty & /*placement*/ 16384) {
|
|
1146
|
+
$$invalidate(16, overwritePosition = isPreview() ? 'center' : placement.position);
|
|
1147
|
+
}
|
|
1148
|
+
|
|
1149
|
+
if ($$self.$$.dirty & /*placement*/ 16384) {
|
|
1150
|
+
$$invalidate(15, overwriteMargin = isPreview()
|
|
1151
|
+
? {
|
|
1152
|
+
left: '0px',
|
|
1153
|
+
right: '0px',
|
|
1154
|
+
top: '0px',
|
|
1155
|
+
bottom: '0px'
|
|
1156
|
+
}
|
|
1157
|
+
: placement.margin);
|
|
1158
|
+
}
|
|
1159
|
+
|
|
1160
|
+
if ($$self.$$.dirty & /*overwritePosition*/ 65536) {
|
|
1161
|
+
$$invalidate(7, pos = getPositionStyle(overwritePosition));
|
|
1162
|
+
}
|
|
1163
|
+
|
|
1164
|
+
if ($$self.$$.dirty & /*overwriteMargin*/ 32768) {
|
|
1165
|
+
$$invalidate(6, marginStyle = getMarginStyle(overwriteMargin));
|
|
1166
|
+
}
|
|
1167
|
+
};
|
|
917
1168
|
|
|
918
1169
|
return [
|
|
919
1170
|
closable,
|
|
920
1171
|
closeButtonColor,
|
|
1172
|
+
animation,
|
|
921
1173
|
_style,
|
|
922
1174
|
_closeStyle,
|
|
923
1175
|
modal,
|
|
924
1176
|
marginStyle,
|
|
925
1177
|
pos,
|
|
1178
|
+
backgroundOverray,
|
|
926
1179
|
$maximumZindex,
|
|
927
1180
|
close,
|
|
928
1181
|
handle_keydown,
|
|
929
1182
|
eventName,
|
|
930
1183
|
eventValue,
|
|
931
|
-
|
|
932
|
-
|
|
933
|
-
|
|
1184
|
+
placement,
|
|
1185
|
+
overwriteMargin,
|
|
1186
|
+
overwritePosition,
|
|
934
1187
|
slots,
|
|
935
|
-
div_binding
|
|
1188
|
+
div_binding,
|
|
1189
|
+
$$scope
|
|
936
1190
|
];
|
|
937
1191
|
}
|
|
938
1192
|
|
|
@@ -949,12 +1203,12 @@ class Modal extends SvelteComponent {
|
|
|
949
1203
|
{
|
|
950
1204
|
closable: 0,
|
|
951
1205
|
closeButtonColor: 1,
|
|
952
|
-
eventName:
|
|
953
|
-
eventValue:
|
|
954
|
-
|
|
955
|
-
|
|
956
|
-
_style:
|
|
957
|
-
_closeStyle:
|
|
1206
|
+
eventName: 12,
|
|
1207
|
+
eventValue: 13,
|
|
1208
|
+
animation: 2,
|
|
1209
|
+
placement: 14,
|
|
1210
|
+
_style: 3,
|
|
1211
|
+
_closeStyle: 4
|
|
958
1212
|
},
|
|
959
1213
|
add_css$6
|
|
960
1214
|
);
|
|
@@ -1077,12 +1331,12 @@ class Grid extends SvelteComponent {
|
|
|
1077
1331
|
}
|
|
1078
1332
|
}
|
|
1079
1333
|
|
|
1080
|
-
/* src/GridModalState.svelte generated by Svelte v3.44.1 */
|
|
1334
|
+
/* src/components/GridModalState.svelte generated by Svelte v3.44.1 */
|
|
1081
1335
|
|
|
1082
|
-
function
|
|
1336
|
+
function create_default_slot_2(ctx) {
|
|
1083
1337
|
let current;
|
|
1084
|
-
const default_slot_template = /*#slots*/ ctx[
|
|
1085
|
-
const default_slot = create_slot(default_slot_template, ctx, /*$$scope*/ ctx[
|
|
1338
|
+
const default_slot_template = /*#slots*/ ctx[16].default;
|
|
1339
|
+
const default_slot = create_slot(default_slot_template, ctx, /*$$scope*/ ctx[17], null);
|
|
1086
1340
|
|
|
1087
1341
|
return {
|
|
1088
1342
|
c() {
|
|
@@ -1097,15 +1351,15 @@ function create_default_slot_3(ctx) {
|
|
|
1097
1351
|
},
|
|
1098
1352
|
p(ctx, dirty) {
|
|
1099
1353
|
if (default_slot) {
|
|
1100
|
-
if (default_slot.p && (!current || dirty & /*$$scope*/
|
|
1354
|
+
if (default_slot.p && (!current || dirty & /*$$scope*/ 131072)) {
|
|
1101
1355
|
update_slot_base(
|
|
1102
1356
|
default_slot,
|
|
1103
1357
|
default_slot_template,
|
|
1104
1358
|
ctx,
|
|
1105
|
-
/*$$scope*/ ctx[
|
|
1359
|
+
/*$$scope*/ ctx[17],
|
|
1106
1360
|
!current
|
|
1107
|
-
? get_all_dirty_from_scope(/*$$scope*/ ctx[
|
|
1108
|
-
: get_slot_changes(default_slot_template, /*$$scope*/ ctx[
|
|
1361
|
+
? get_all_dirty_from_scope(/*$$scope*/ ctx[17])
|
|
1362
|
+
: get_slot_changes(default_slot_template, /*$$scope*/ ctx[17], dirty, null),
|
|
1109
1363
|
null
|
|
1110
1364
|
);
|
|
1111
1365
|
}
|
|
@@ -1126,20 +1380,20 @@ function create_default_slot_3(ctx) {
|
|
|
1126
1380
|
};
|
|
1127
1381
|
}
|
|
1128
1382
|
|
|
1129
|
-
// (
|
|
1130
|
-
function
|
|
1383
|
+
// (85:2) <Modal {closable} {closeButtonColor} {_closeStyle} _style={_modalStyle} on:close={close} >
|
|
1384
|
+
function create_default_slot_1(ctx) {
|
|
1131
1385
|
let grid;
|
|
1132
1386
|
let current;
|
|
1133
1387
|
|
|
1134
1388
|
grid = new Grid({
|
|
1135
1389
|
props: {
|
|
1136
|
-
width: /*width*/ ctx[
|
|
1137
|
-
height: /*height*/ ctx[
|
|
1138
|
-
rows: /*rows*/ ctx[
|
|
1139
|
-
columns: /*columns*/ ctx[
|
|
1140
|
-
gap: /*gap*/ ctx[
|
|
1141
|
-
background: /*background*/ ctx[
|
|
1142
|
-
$$slots: { default: [
|
|
1390
|
+
width: /*width*/ ctx[5],
|
|
1391
|
+
height: /*height*/ ctx[6],
|
|
1392
|
+
rows: /*rows*/ ctx[7],
|
|
1393
|
+
columns: /*columns*/ ctx[8],
|
|
1394
|
+
gap: /*gap*/ ctx[9],
|
|
1395
|
+
background: /*background*/ ctx[10],
|
|
1396
|
+
$$slots: { default: [create_default_slot_2] },
|
|
1143
1397
|
$$scope: { ctx }
|
|
1144
1398
|
}
|
|
1145
1399
|
});
|
|
@@ -1154,14 +1408,14 @@ function create_default_slot_2(ctx) {
|
|
|
1154
1408
|
},
|
|
1155
1409
|
p(ctx, dirty) {
|
|
1156
1410
|
const grid_changes = {};
|
|
1157
|
-
if (dirty & /*width*/
|
|
1158
|
-
if (dirty & /*height*/
|
|
1159
|
-
if (dirty & /*rows*/
|
|
1160
|
-
if (dirty & /*columns*/
|
|
1161
|
-
if (dirty & /*gap*/
|
|
1162
|
-
if (dirty & /*background*/
|
|
1163
|
-
|
|
1164
|
-
if (dirty & /*$$scope*/
|
|
1411
|
+
if (dirty & /*width*/ 32) grid_changes.width = /*width*/ ctx[5];
|
|
1412
|
+
if (dirty & /*height*/ 64) grid_changes.height = /*height*/ ctx[6];
|
|
1413
|
+
if (dirty & /*rows*/ 128) grid_changes.rows = /*rows*/ ctx[7];
|
|
1414
|
+
if (dirty & /*columns*/ 256) grid_changes.columns = /*columns*/ ctx[8];
|
|
1415
|
+
if (dirty & /*gap*/ 512) grid_changes.gap = /*gap*/ ctx[9];
|
|
1416
|
+
if (dirty & /*background*/ 1024) grid_changes.background = /*background*/ ctx[10];
|
|
1417
|
+
|
|
1418
|
+
if (dirty & /*$$scope*/ 131072) {
|
|
1165
1419
|
grid_changes.$$scope = { dirty, ctx };
|
|
1166
1420
|
}
|
|
1167
1421
|
|
|
@@ -1182,25 +1436,23 @@ function create_default_slot_2(ctx) {
|
|
|
1182
1436
|
};
|
|
1183
1437
|
}
|
|
1184
1438
|
|
|
1185
|
-
// (
|
|
1186
|
-
function
|
|
1439
|
+
// (84:0) <StateItem {path}>
|
|
1440
|
+
function create_default_slot(ctx) {
|
|
1187
1441
|
let modal;
|
|
1188
1442
|
let current;
|
|
1189
1443
|
|
|
1190
1444
|
modal = new Modal({
|
|
1191
1445
|
props: {
|
|
1192
|
-
closable: /*closable*/ ctx[
|
|
1193
|
-
closeButtonColor: /*closeButtonColor*/ ctx[
|
|
1194
|
-
_closeStyle: /*_closeStyle*/ ctx[
|
|
1195
|
-
|
|
1196
|
-
|
|
1197
|
-
_style: /*_modalStyle*/ ctx[2],
|
|
1198
|
-
$$slots: { default: [create_default_slot_2] },
|
|
1446
|
+
closable: /*closable*/ ctx[2],
|
|
1447
|
+
closeButtonColor: /*closeButtonColor*/ ctx[3],
|
|
1448
|
+
_closeStyle: /*_closeStyle*/ ctx[4],
|
|
1449
|
+
_style: /*_modalStyle*/ ctx[1],
|
|
1450
|
+
$$slots: { default: [create_default_slot_1] },
|
|
1199
1451
|
$$scope: { ctx }
|
|
1200
1452
|
}
|
|
1201
1453
|
});
|
|
1202
1454
|
|
|
1203
|
-
modal.$on("close", /*close*/ ctx[
|
|
1455
|
+
modal.$on("close", /*close*/ ctx[11]);
|
|
1204
1456
|
|
|
1205
1457
|
return {
|
|
1206
1458
|
c() {
|
|
@@ -1212,12 +1464,12 @@ function create_default_slot_1(ctx) {
|
|
|
1212
1464
|
},
|
|
1213
1465
|
p(ctx, dirty) {
|
|
1214
1466
|
const modal_changes = {};
|
|
1215
|
-
if (dirty & /*closable*/
|
|
1216
|
-
if (dirty & /*closeButtonColor*/
|
|
1217
|
-
if (dirty & /*_closeStyle*/
|
|
1218
|
-
if (dirty & /*_modalStyle*/
|
|
1467
|
+
if (dirty & /*closable*/ 4) modal_changes.closable = /*closable*/ ctx[2];
|
|
1468
|
+
if (dirty & /*closeButtonColor*/ 8) modal_changes.closeButtonColor = /*closeButtonColor*/ ctx[3];
|
|
1469
|
+
if (dirty & /*_closeStyle*/ 16) modal_changes._closeStyle = /*_closeStyle*/ ctx[4];
|
|
1470
|
+
if (dirty & /*_modalStyle*/ 2) modal_changes._style = /*_modalStyle*/ ctx[1];
|
|
1219
1471
|
|
|
1220
|
-
if (dirty & /*$$scope, width, height, rows, columns, gap, background*/
|
|
1472
|
+
if (dirty & /*$$scope, width, height, rows, columns, gap, background*/ 133088) {
|
|
1221
1473
|
modal_changes.$$scope = { dirty, ctx };
|
|
1222
1474
|
}
|
|
1223
1475
|
|
|
@@ -1238,70 +1490,6 @@ function create_default_slot_1(ctx) {
|
|
|
1238
1490
|
};
|
|
1239
1491
|
}
|
|
1240
1492
|
|
|
1241
|
-
// (101:0) <StateItem {path}>
|
|
1242
|
-
function create_default_slot(ctx) {
|
|
1243
|
-
let backgroundoverray;
|
|
1244
|
-
let t;
|
|
1245
|
-
let animation_1;
|
|
1246
|
-
let current;
|
|
1247
|
-
|
|
1248
|
-
backgroundoverray = new BackgroundOverray({
|
|
1249
|
-
props: {
|
|
1250
|
-
backgroundOverray: /*_backgroundOverray*/ ctx[15]
|
|
1251
|
-
}
|
|
1252
|
-
});
|
|
1253
|
-
|
|
1254
|
-
backgroundoverray.$on("click", /*close*/ ctx[12]);
|
|
1255
|
-
|
|
1256
|
-
animation_1 = new Animation({
|
|
1257
|
-
props: {
|
|
1258
|
-
animation: /*animation*/ ctx[1],
|
|
1259
|
-
$$slots: { default: [create_default_slot_1] },
|
|
1260
|
-
$$scope: { ctx }
|
|
1261
|
-
}
|
|
1262
|
-
});
|
|
1263
|
-
|
|
1264
|
-
return {
|
|
1265
|
-
c() {
|
|
1266
|
-
create_component(backgroundoverray.$$.fragment);
|
|
1267
|
-
t = space();
|
|
1268
|
-
create_component(animation_1.$$.fragment);
|
|
1269
|
-
},
|
|
1270
|
-
m(target, anchor) {
|
|
1271
|
-
mount_component(backgroundoverray, target, anchor);
|
|
1272
|
-
insert(target, t, anchor);
|
|
1273
|
-
mount_component(animation_1, target, anchor);
|
|
1274
|
-
current = true;
|
|
1275
|
-
},
|
|
1276
|
-
p(ctx, dirty) {
|
|
1277
|
-
const animation_1_changes = {};
|
|
1278
|
-
if (dirty & /*animation*/ 2) animation_1_changes.animation = /*animation*/ ctx[1];
|
|
1279
|
-
|
|
1280
|
-
if (dirty & /*$$scope, closable, closeButtonColor, _closeStyle, _modalStyle, width, height, rows, columns, gap, background*/ 4198396) {
|
|
1281
|
-
animation_1_changes.$$scope = { dirty, ctx };
|
|
1282
|
-
}
|
|
1283
|
-
|
|
1284
|
-
animation_1.$set(animation_1_changes);
|
|
1285
|
-
},
|
|
1286
|
-
i(local) {
|
|
1287
|
-
if (current) return;
|
|
1288
|
-
transition_in(backgroundoverray.$$.fragment, local);
|
|
1289
|
-
transition_in(animation_1.$$.fragment, local);
|
|
1290
|
-
current = true;
|
|
1291
|
-
},
|
|
1292
|
-
o(local) {
|
|
1293
|
-
transition_out(backgroundoverray.$$.fragment, local);
|
|
1294
|
-
transition_out(animation_1.$$.fragment, local);
|
|
1295
|
-
current = false;
|
|
1296
|
-
},
|
|
1297
|
-
d(detaching) {
|
|
1298
|
-
destroy_component(backgroundoverray, detaching);
|
|
1299
|
-
if (detaching) detach(t);
|
|
1300
|
-
destroy_component(animation_1, detaching);
|
|
1301
|
-
}
|
|
1302
|
-
};
|
|
1303
|
-
}
|
|
1304
|
-
|
|
1305
1493
|
function create_fragment$6(ctx) {
|
|
1306
1494
|
let stateitem;
|
|
1307
1495
|
let current;
|
|
@@ -1326,7 +1514,7 @@ function create_fragment$6(ctx) {
|
|
|
1326
1514
|
const stateitem_changes = {};
|
|
1327
1515
|
if (dirty & /*path*/ 1) stateitem_changes.path = /*path*/ ctx[0];
|
|
1328
1516
|
|
|
1329
|
-
if (dirty & /*$$scope,
|
|
1517
|
+
if (dirty & /*$$scope, closable, closeButtonColor, _closeStyle, _modalStyle, width, height, rows, columns, gap, background*/ 133118) {
|
|
1330
1518
|
stateitem_changes.$$scope = { dirty, ctx };
|
|
1331
1519
|
}
|
|
1332
1520
|
|
|
@@ -1351,11 +1539,9 @@ function instance$6($$self, $$props, $$invalidate) {
|
|
|
1351
1539
|
let { $$slots: slots = {}, $$scope } = $$props;
|
|
1352
1540
|
let { path } = $$props;
|
|
1353
1541
|
let { placement = DefaultModalPlacement } = $$props;
|
|
1354
|
-
let { position = 'center' } = $$props;
|
|
1355
1542
|
let { animation = 'none' } = $$props;
|
|
1356
1543
|
let { _modalStyle = '' } = $$props;
|
|
1357
1544
|
let { closable = true } = $$props;
|
|
1358
|
-
let { backgroundOverray = false } = $$props;
|
|
1359
1545
|
let { closeButtonColor = '#000000' } = $$props;
|
|
1360
1546
|
let { eventName = '' } = $$props;
|
|
1361
1547
|
let { eventValue = null } = $$props;
|
|
@@ -1373,41 +1559,30 @@ function instance$6($$self, $$props, $$invalidate) {
|
|
|
1373
1559
|
const dispatch = createEventDispatcher();
|
|
1374
1560
|
|
|
1375
1561
|
const close = () => {
|
|
1376
|
-
if (eventName) {
|
|
1377
|
-
send_event(eventName, eventValue);
|
|
1378
|
-
}
|
|
1379
|
-
|
|
1380
1562
|
dispatch('close');
|
|
1381
1563
|
};
|
|
1382
1564
|
|
|
1383
|
-
const _position = placement.position ?? position;
|
|
1384
|
-
const margin = placement.margin;
|
|
1385
|
-
const _backgroundOverray = placement.backgroundOverlay ?? backgroundOverray;
|
|
1386
|
-
|
|
1387
1565
|
$$self.$$set = $$props => {
|
|
1388
1566
|
if ('path' in $$props) $$invalidate(0, path = $$props.path);
|
|
1389
|
-
if ('placement' in $$props) $$invalidate(
|
|
1390
|
-
if ('
|
|
1391
|
-
if ('
|
|
1392
|
-
if ('
|
|
1393
|
-
if ('
|
|
1394
|
-
if ('
|
|
1395
|
-
if ('
|
|
1396
|
-
if ('
|
|
1397
|
-
if ('
|
|
1398
|
-
if ('
|
|
1399
|
-
if ('
|
|
1400
|
-
if ('
|
|
1401
|
-
if ('
|
|
1402
|
-
if ('
|
|
1403
|
-
if ('
|
|
1404
|
-
if ('background' in $$props) $$invalidate(11, background = $$props.background);
|
|
1405
|
-
if ('$$scope' in $$props) $$invalidate(22, $$scope = $$props.$$scope);
|
|
1567
|
+
if ('placement' in $$props) $$invalidate(12, placement = $$props.placement);
|
|
1568
|
+
if ('animation' in $$props) $$invalidate(13, animation = $$props.animation);
|
|
1569
|
+
if ('_modalStyle' in $$props) $$invalidate(1, _modalStyle = $$props._modalStyle);
|
|
1570
|
+
if ('closable' in $$props) $$invalidate(2, closable = $$props.closable);
|
|
1571
|
+
if ('closeButtonColor' in $$props) $$invalidate(3, closeButtonColor = $$props.closeButtonColor);
|
|
1572
|
+
if ('eventName' in $$props) $$invalidate(14, eventName = $$props.eventName);
|
|
1573
|
+
if ('eventValue' in $$props) $$invalidate(15, eventValue = $$props.eventValue);
|
|
1574
|
+
if ('_closeStyle' in $$props) $$invalidate(4, _closeStyle = $$props._closeStyle);
|
|
1575
|
+
if ('width' in $$props) $$invalidate(5, width = $$props.width);
|
|
1576
|
+
if ('height' in $$props) $$invalidate(6, height = $$props.height);
|
|
1577
|
+
if ('rows' in $$props) $$invalidate(7, rows = $$props.rows);
|
|
1578
|
+
if ('columns' in $$props) $$invalidate(8, columns = $$props.columns);
|
|
1579
|
+
if ('gap' in $$props) $$invalidate(9, gap = $$props.gap);
|
|
1580
|
+
if ('background' in $$props) $$invalidate(10, background = $$props.background);
|
|
1581
|
+
if ('$$scope' in $$props) $$invalidate(17, $$scope = $$props.$$scope);
|
|
1406
1582
|
};
|
|
1407
1583
|
|
|
1408
1584
|
return [
|
|
1409
1585
|
path,
|
|
1410
|
-
animation,
|
|
1411
1586
|
_modalStyle,
|
|
1412
1587
|
closable,
|
|
1413
1588
|
closeButtonColor,
|
|
@@ -1419,12 +1594,8 @@ function instance$6($$self, $$props, $$invalidate) {
|
|
|
1419
1594
|
gap,
|
|
1420
1595
|
background,
|
|
1421
1596
|
close,
|
|
1422
|
-
_position,
|
|
1423
|
-
margin,
|
|
1424
|
-
_backgroundOverray,
|
|
1425
1597
|
placement,
|
|
1426
|
-
|
|
1427
|
-
backgroundOverray,
|
|
1598
|
+
animation,
|
|
1428
1599
|
eventName,
|
|
1429
1600
|
eventValue,
|
|
1430
1601
|
slots,
|
|
@@ -1438,27 +1609,25 @@ class GridModalState extends SvelteComponent {
|
|
|
1438
1609
|
|
|
1439
1610
|
init(this, options, instance$6, create_fragment$6, safe_not_equal, {
|
|
1440
1611
|
path: 0,
|
|
1441
|
-
placement:
|
|
1442
|
-
|
|
1443
|
-
|
|
1444
|
-
|
|
1445
|
-
|
|
1446
|
-
|
|
1447
|
-
|
|
1448
|
-
|
|
1449
|
-
|
|
1450
|
-
|
|
1451
|
-
|
|
1452
|
-
|
|
1453
|
-
|
|
1454
|
-
|
|
1455
|
-
gap: 10,
|
|
1456
|
-
background: 11
|
|
1612
|
+
placement: 12,
|
|
1613
|
+
animation: 13,
|
|
1614
|
+
_modalStyle: 1,
|
|
1615
|
+
closable: 2,
|
|
1616
|
+
closeButtonColor: 3,
|
|
1617
|
+
eventName: 14,
|
|
1618
|
+
eventValue: 15,
|
|
1619
|
+
_closeStyle: 4,
|
|
1620
|
+
width: 5,
|
|
1621
|
+
height: 6,
|
|
1622
|
+
rows: 7,
|
|
1623
|
+
columns: 8,
|
|
1624
|
+
gap: 9,
|
|
1625
|
+
background: 10
|
|
1457
1626
|
});
|
|
1458
1627
|
}
|
|
1459
1628
|
}
|
|
1460
1629
|
|
|
1461
|
-
/* src/GridItem.svelte generated by Svelte v3.44.1 */
|
|
1630
|
+
/* src/components/GridItem.svelte generated by Svelte v3.44.1 */
|
|
1462
1631
|
|
|
1463
1632
|
function add_css$5(target) {
|
|
1464
1633
|
append_styles(target, "svelte-g0rfgr", ".grid-item.svelte-g0rfgr{word-break:break-all}");
|
|
@@ -2091,4 +2260,4 @@ class ImageBlock extends SvelteComponent {
|
|
|
2091
2260
|
}
|
|
2092
2261
|
}
|
|
2093
2262
|
|
|
2094
|
-
export { Alignments, AnimationStyleTranslations, AnimationStyles, BackgroundSizes, DefaultModalPlacement, Directions, Flex, FlexItem, GridItem, GridModalState, ImageBlock, Justifies, LengthUnits, MediaQueries, Modal, ModalMarginTranslations, ModalPositionTranslations, ModalPositions, ObjectFits, PropTypes, Repeats, State, TextBlock, TextButtonBlock, closeApp, closed, finalize, getMarginStyle, getPositionStyle, handleFocus, handleKeydown, hasSuffix, initialize, isPreview, linkTo, maximumZindex, moveTo, none, onScroll, onTime, randStr, send_event, setMiximumZindex, setPreviousFocus, state, toBr };
|
|
2263
|
+
export { Alignments, AnimationStyleTranslations, AnimationStyles, BackgroundSizes, DefaultModalPlacement, Directions, Flex, FlexItem, Grid, GridItem, GridModalState, ImageBlock, Justifies, LengthUnits, MediaQueries, Modal, ModalMarginTranslations, ModalPositionTranslations, ModalPositions, ObjectFits, PropTypes, Repeats, State, StateItem, TextBlock, TextButtonBlock, closeApp, closed, collection, createFog, embed, ensureModalRoot, finalize, getMarginStyle, getPositionStyle, h, handleFocus, handleKeydown, hasSuffix, hideOnScroll, hideOnTime, initialize, isPreview, linkTo, maximumZindex, moveTo, none, onScroll, onTime, randStr, send_event, setMiximumZindex, setPreviousFocus, showOnScroll, showOnTime, state, toBr };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@plaidev/karte-action-sdk",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.31",
|
|
4
4
|
"author": "Plaid Inc.",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"module": "./dist/index.es.js",
|
|
@@ -43,6 +43,7 @@
|
|
|
43
43
|
"node-fetch": "2.6.7",
|
|
44
44
|
"picocolors": "^1.0.0",
|
|
45
45
|
"playwright": "^1.23.4",
|
|
46
|
+
"preact": "10.5.7",
|
|
46
47
|
"rimraf": "^3.0.2",
|
|
47
48
|
"rollup": "^2.75.7",
|
|
48
49
|
"rollup-plugin-http-resolve": "4.0.1-alpha.0",
|