@abgov/react-components 4.0.0-alpha.25 → 4.0.0-alpha.28
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/lib/circular-progress/circular-progress.d.ts +3 -6
- package/package.json +1 -1
- package/react-components.esm.js +181 -238
- package/react-components.umd.js +182 -239
package/react-components.esm.js
CHANGED
|
@@ -1355,7 +1355,7 @@ function instance$y($$self, $$props, $$invalidate) {
|
|
|
1355
1355
|
class AppHeader extends SvelteElement {
|
|
1356
1356
|
constructor(options) {
|
|
1357
1357
|
super();
|
|
1358
|
-
this.shadowRoot.innerHTML = `<style>:host{box-sizing:border-box;font-family:var(--font-family)}.app-header{display:flex;align-items:center;justify-content:space-between;margin:0 auto;padding:1rem
|
|
1358
|
+
this.shadowRoot.innerHTML = `<style>:host{box-sizing:border-box;font-family:var(--font-family)}.app-header{display:flex;align-items:center;justify-content:space-between;margin:0 auto;padding:1rem 1.5rem;border-bottom:1px solid var(--color-gray-100)}@media(max-width: 640px){.app-header{padding:1rem 1rem}}.app-link{display:flex;align-items:center;text-decoration:none;color:inherit}.title{margin-left:0.5rem;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.image-desktop{display:none}.image-mobile{display:block}@media(min-width: 768px){.image-desktop{display:block}.image-mobile{display:none}.title{margin-left:1.75rem}.image-desktop{display:block}.image-mobile{display:none}}</style>`;
|
|
1359
1359
|
init(this, {
|
|
1360
1360
|
target: this.shadowRoot,
|
|
1361
1361
|
props: attribute_to_object(this.attributes),
|
|
@@ -2200,7 +2200,7 @@ class Button extends SvelteElement {
|
|
|
2200
2200
|
constructor(options) {
|
|
2201
2201
|
super();
|
|
2202
2202
|
this.shadowRoot.innerHTML = `<style>:host{box-sizing:border-box;font-family:var(--font-family)}@media(max-width: 480px){:host{width:100%}button{width:100%}}button{display:flex;box-sizing:border-box;border-radius:0.25rem;border:2px solid var(--goa-color-interactive);box-sizing:border-box;cursor:pointer;font-family:var(--font-family);font-size:var(--fs-lg);font-weight:400;height:var(--button-height);letter-spacing:0.5px;line-height:100%;padding:0 0.75rem;gap:0.5rem;align-items:center;justify-content:center;transition:transform 0.1s ease-in-out, background-color 0.2s ease-in-out,
|
|
2203
|
-
border-color 0.2s ease-in-out}.text{padding-bottom:var(--font-valign-fix)}button:disabled{pointer-events:none;opacity:0.5}button.compact{height:var(--button-height-compact);font-size:var(--fs-base)}button.start{height:var(--button-height-tall);font-weight:var(--fw-bold)}button.start,button.primary{border:2px solid var(--goa-color-interactive);background:var(--goa-color-interactive);color:var(--goa-color-text-light)}button.start:hover,button.primary:hover{border-color:var(--goa-color-interactive--hover);background:var(--goa-color-interactive--hover)}button.start:focus,button.start:active,button.primary:focus,button.primary:active{box-shadow:0 0 0 3px var(--goa-color-interactive--focus);border-color:var(--goa-color-interactive--active);background:var(--goa-color-interactive--active);outline:none}button.secondary{border:2px solid var(--goa-color-interactive);background:var(--color-white);color:var(--goa-color-interactive)}button.secondary:hover{border-color:var(--goa-color-interactive--hover);color:var(--goa-color-interactive--hover);background:var(--color-gray-100)}button.secondary:focus,button.secondary:active{border-color:var(--goa-color-interactive--active);box-shadow:0 0 0 3px var(--goa-color-interactive--focus);background:var(--color-gray-100);outline:none}button.tertiary{border:1px solid transparent;background:
|
|
2203
|
+
border-color 0.2s ease-in-out}.text{padding-bottom:var(--font-valign-fix)}button:disabled{pointer-events:none;opacity:0.5}button.compact{height:var(--button-height-compact);font-size:var(--fs-base)}button.start{height:var(--button-height-tall);font-weight:var(--fw-bold)}button.start,button.primary{border:2px solid var(--goa-color-interactive);background:var(--goa-color-interactive);color:var(--goa-color-text-light)}button.start:hover,button.primary:hover{border-color:var(--goa-color-interactive--hover);background:var(--goa-color-interactive--hover)}button.start:focus,button.start:active,button.primary:focus,button.primary:active{box-shadow:0 0 0 3px var(--goa-color-interactive--focus);border-color:var(--goa-color-interactive--active);background:var(--goa-color-interactive--active);outline:none}button.secondary{border:2px solid var(--goa-color-interactive);background:var(--color-white);color:var(--goa-color-interactive)}button.secondary:hover{border-color:var(--goa-color-interactive--hover);color:var(--goa-color-interactive--hover);background:var(--color-gray-100)}button.secondary:focus,button.secondary:active{border-color:var(--goa-color-interactive--active);box-shadow:0 0 0 3px var(--goa-color-interactive--focus);background:var(--color-gray-100);outline:none}button.tertiary{border:1px solid transparent;background:transparent;color:var(--goa-color-interactive);text-decoration:underline}button.tertiary:hover{border-color:var(--color-gray-100);color:var(--goa-color-interactive--hover);background:var(--color-gray-100)}button.tertiary:focus,button.tertiary:active{border-color:var(--color-gray-100);background:var(--color-gray-100);color:var(--goa-color-interactive--active);box-shadow:0 0 0 3px var(--goa-color-interactive--focus);outline:none}.primary.danger{color:var(--color-white);background:var(--goa-color-status-emergency);border-color:var(--goa-color-status-emergency)}.primary.danger:hover{background:var(--goa-color-status-emergency-dark);border-color:var(--goa-color-status-emergency-dark)}.primary.danger:focus,.primary.danger:active{background:var(--goa-color-status-emergency-dark);border-color:var(--goa-color-status-emergency-dark)}.secondary.danger{color:var(--goa-color-status-emergency);border-color:var(--goa-color-status-emergency);background:var(--color-white)}.secondary.danger:hover{border-color:var(--goa-color-status-emergency-dark);color:var(--goa-color-status-emergency-dark);background:var(--color-white)}.secondary.danger:focus,.secondary.danger:active{color:var(--goa-color-status-emergency-dark);border-color:var(--goa-color-status-emergency-dark);background:var(--color-white)}.tertiary.danger{color:var(--goa-color-status-emergency);border-color:var(--color-gray-200);background:var(--color-white)}.tertiary.danger:hover{border-color:var(--goa-color-status-emergency-dark);color:var(--goa-color-status-emergency-dark);background:var(--color-white)}.tertiary.danger:focus,.tertiary.danger:active{color:var(--goa-color-status-emergency-dark);border-color:var(--goa-color-status-emergency-dark);background:var(--color-white)}</style>`;
|
|
2204
2204
|
init(this, {
|
|
2205
2205
|
target: this.shadowRoot,
|
|
2206
2206
|
props: attribute_to_object(this.attributes),
|
|
@@ -2594,7 +2594,7 @@ function instance$u($$self, $$props, $$invalidate) {
|
|
|
2594
2594
|
type
|
|
2595
2595
|
} = $$props;
|
|
2596
2596
|
let {
|
|
2597
|
-
heading
|
|
2597
|
+
heading = ""
|
|
2598
2598
|
} = $$props;
|
|
2599
2599
|
let {
|
|
2600
2600
|
testid = ""
|
|
@@ -7664,7 +7664,7 @@ function create_if_block$9(ctx) {
|
|
|
7664
7664
|
ctx[2] && `--width: ${
|
|
7665
7665
|
/*width*/
|
|
7666
7666
|
ctx[2]};`) + ";");
|
|
7667
|
-
set_custom_element_data(goa_focus_trap, "
|
|
7667
|
+
set_custom_element_data(goa_focus_trap, "active",
|
|
7668
7668
|
/*open*/
|
|
7669
7669
|
ctx[1]);
|
|
7670
7670
|
},
|
|
@@ -7765,7 +7765,7 @@ function create_if_block$9(ctx) {
|
|
|
7765
7765
|
if (!current || dirty &
|
|
7766
7766
|
/*open*/
|
|
7767
7767
|
2) {
|
|
7768
|
-
set_custom_element_data(goa_focus_trap, "
|
|
7768
|
+
set_custom_element_data(goa_focus_trap, "active",
|
|
7769
7769
|
/*open*/
|
|
7770
7770
|
ctx[1]);
|
|
7771
7771
|
}
|
|
@@ -8497,10 +8497,10 @@ function create_if_block$7(ctx) {
|
|
|
8497
8497
|
function select_block_type(ctx, dirty) {
|
|
8498
8498
|
if (
|
|
8499
8499
|
/*fullscreen*/
|
|
8500
|
-
ctx[
|
|
8500
|
+
ctx[3]) return 0;
|
|
8501
8501
|
if (
|
|
8502
8502
|
/*inline*/
|
|
8503
|
-
ctx[
|
|
8503
|
+
ctx[4]) return 1;
|
|
8504
8504
|
return -1;
|
|
8505
8505
|
}
|
|
8506
8506
|
|
|
@@ -8578,39 +8578,35 @@ function create_if_block$7(ctx) {
|
|
|
8578
8578
|
}
|
|
8579
8579
|
|
|
8580
8580
|
};
|
|
8581
|
-
} // (
|
|
8581
|
+
} // (38:19)
|
|
8582
8582
|
|
|
8583
8583
|
|
|
8584
8584
|
function create_if_block_3$1(ctx) {
|
|
8585
8585
|
let div;
|
|
8586
8586
|
let goa_spinner;
|
|
8587
|
-
let goa_spinner_progress_value;
|
|
8588
8587
|
let t;
|
|
8589
8588
|
let div_class_value;
|
|
8590
8589
|
let if_block =
|
|
8591
8590
|
/*message*/
|
|
8592
|
-
ctx[
|
|
8591
|
+
ctx[0] && create_if_block_4(ctx);
|
|
8593
8592
|
return {
|
|
8594
8593
|
c() {
|
|
8595
8594
|
div = element("div");
|
|
8596
8595
|
goa_spinner = element("goa-spinner");
|
|
8597
8596
|
t = space();
|
|
8598
8597
|
if (if_block) if_block.c();
|
|
8599
|
-
set_custom_element_data(goa_spinner, "type",
|
|
8600
|
-
/*type*/
|
|
8601
|
-
ctx[0]);
|
|
8602
8598
|
set_custom_element_data(goa_spinner, "size",
|
|
8603
8599
|
/*spinnerSize*/
|
|
8604
|
-
ctx[
|
|
8605
|
-
set_custom_element_data(goa_spinner, "progress",
|
|
8600
|
+
ctx[2]);
|
|
8601
|
+
set_custom_element_data(goa_spinner, "progress",
|
|
8606
8602
|
/*progress*/
|
|
8607
|
-
ctx[
|
|
8603
|
+
ctx[1]);
|
|
8608
8604
|
attr(div, "class", div_class_value = "spinner-" +
|
|
8609
8605
|
/*spinnerSize*/
|
|
8610
|
-
ctx[
|
|
8606
|
+
ctx[2]);
|
|
8611
8607
|
toggle_class(div, "inline",
|
|
8612
8608
|
/*inline*/
|
|
8613
|
-
ctx[
|
|
8609
|
+
ctx[4]);
|
|
8614
8610
|
},
|
|
8615
8611
|
|
|
8616
8612
|
m(target, anchor) {
|
|
@@ -8621,33 +8617,25 @@ function create_if_block_3$1(ctx) {
|
|
|
8621
8617
|
},
|
|
8622
8618
|
|
|
8623
8619
|
p(ctx, dirty) {
|
|
8624
|
-
if (dirty &
|
|
8625
|
-
/*type*/
|
|
8626
|
-
1) {
|
|
8627
|
-
set_custom_element_data(goa_spinner, "type",
|
|
8628
|
-
/*type*/
|
|
8629
|
-
ctx[0]);
|
|
8630
|
-
}
|
|
8631
|
-
|
|
8632
8620
|
if (dirty &
|
|
8633
8621
|
/*spinnerSize*/
|
|
8634
|
-
|
|
8622
|
+
4) {
|
|
8635
8623
|
set_custom_element_data(goa_spinner, "size",
|
|
8636
8624
|
/*spinnerSize*/
|
|
8637
|
-
ctx[
|
|
8625
|
+
ctx[2]);
|
|
8638
8626
|
}
|
|
8639
8627
|
|
|
8640
8628
|
if (dirty &
|
|
8641
8629
|
/*progress*/
|
|
8642
|
-
|
|
8643
|
-
|
|
8644
|
-
|
|
8645
|
-
|
|
8630
|
+
2) {
|
|
8631
|
+
set_custom_element_data(goa_spinner, "progress",
|
|
8632
|
+
/*progress*/
|
|
8633
|
+
ctx[1]);
|
|
8646
8634
|
}
|
|
8647
8635
|
|
|
8648
8636
|
if (
|
|
8649
8637
|
/*message*/
|
|
8650
|
-
ctx[
|
|
8638
|
+
ctx[0]) {
|
|
8651
8639
|
if (if_block) {
|
|
8652
8640
|
if_block.p(ctx, dirty);
|
|
8653
8641
|
} else {
|
|
@@ -8662,18 +8650,18 @@ function create_if_block_3$1(ctx) {
|
|
|
8662
8650
|
|
|
8663
8651
|
if (dirty &
|
|
8664
8652
|
/*spinnerSize*/
|
|
8665
|
-
|
|
8653
|
+
4 && div_class_value !== (div_class_value = "spinner-" +
|
|
8666
8654
|
/*spinnerSize*/
|
|
8667
|
-
ctx[
|
|
8655
|
+
ctx[2])) {
|
|
8668
8656
|
attr(div, "class", div_class_value);
|
|
8669
8657
|
}
|
|
8670
8658
|
|
|
8671
8659
|
if (dirty &
|
|
8672
8660
|
/*spinnerSize, inline*/
|
|
8673
|
-
|
|
8661
|
+
20) {
|
|
8674
8662
|
toggle_class(div, "inline",
|
|
8675
8663
|
/*inline*/
|
|
8676
|
-
ctx[
|
|
8664
|
+
ctx[4]);
|
|
8677
8665
|
}
|
|
8678
8666
|
},
|
|
8679
8667
|
|
|
@@ -8686,13 +8674,12 @@ function create_if_block_3$1(ctx) {
|
|
|
8686
8674
|
}
|
|
8687
8675
|
|
|
8688
8676
|
};
|
|
8689
|
-
} // (
|
|
8677
|
+
} // (27:2) {#if fullscreen}
|
|
8690
8678
|
|
|
8691
8679
|
|
|
8692
8680
|
function create_if_block_1$4(ctx) {
|
|
8693
8681
|
let div;
|
|
8694
8682
|
let goa_spinner;
|
|
8695
|
-
let goa_spinner_progress_value;
|
|
8696
8683
|
let t;
|
|
8697
8684
|
let div_transition;
|
|
8698
8685
|
let current;
|
|
@@ -8700,25 +8687,22 @@ function create_if_block_1$4(ctx) {
|
|
|
8700
8687
|
let dispose;
|
|
8701
8688
|
let if_block =
|
|
8702
8689
|
/*message*/
|
|
8703
|
-
ctx[
|
|
8690
|
+
ctx[0] && create_if_block_2$3(ctx);
|
|
8704
8691
|
return {
|
|
8705
8692
|
c() {
|
|
8706
8693
|
div = element("div");
|
|
8707
8694
|
goa_spinner = element("goa-spinner");
|
|
8708
8695
|
t = space();
|
|
8709
8696
|
if (if_block) if_block.c();
|
|
8710
|
-
set_custom_element_data(goa_spinner, "type",
|
|
8711
|
-
/*type*/
|
|
8712
|
-
ctx[0]);
|
|
8713
8697
|
set_custom_element_data(goa_spinner, "size",
|
|
8714
8698
|
/*spinnerSize*/
|
|
8715
|
-
ctx[
|
|
8716
|
-
set_custom_element_data(goa_spinner, "progress",
|
|
8699
|
+
ctx[2]);
|
|
8700
|
+
set_custom_element_data(goa_spinner, "progress",
|
|
8717
8701
|
/*progress*/
|
|
8718
|
-
ctx[
|
|
8702
|
+
ctx[1]);
|
|
8719
8703
|
toggle_class(div, "fullscreen",
|
|
8720
8704
|
/*fullscreen*/
|
|
8721
|
-
ctx[
|
|
8705
|
+
ctx[3]);
|
|
8722
8706
|
},
|
|
8723
8707
|
|
|
8724
8708
|
m(target, anchor) {
|
|
@@ -8737,33 +8721,25 @@ function create_if_block_1$4(ctx) {
|
|
|
8737
8721
|
},
|
|
8738
8722
|
|
|
8739
8723
|
p(ctx, dirty) {
|
|
8740
|
-
if (!current || dirty &
|
|
8741
|
-
/*type*/
|
|
8742
|
-
1) {
|
|
8743
|
-
set_custom_element_data(goa_spinner, "type",
|
|
8744
|
-
/*type*/
|
|
8745
|
-
ctx[0]);
|
|
8746
|
-
}
|
|
8747
|
-
|
|
8748
8724
|
if (!current || dirty &
|
|
8749
8725
|
/*spinnerSize*/
|
|
8750
|
-
|
|
8726
|
+
4) {
|
|
8751
8727
|
set_custom_element_data(goa_spinner, "size",
|
|
8752
8728
|
/*spinnerSize*/
|
|
8753
|
-
ctx[
|
|
8729
|
+
ctx[2]);
|
|
8754
8730
|
}
|
|
8755
8731
|
|
|
8756
8732
|
if (!current || dirty &
|
|
8757
8733
|
/*progress*/
|
|
8758
|
-
|
|
8759
|
-
|
|
8760
|
-
|
|
8761
|
-
|
|
8734
|
+
2) {
|
|
8735
|
+
set_custom_element_data(goa_spinner, "progress",
|
|
8736
|
+
/*progress*/
|
|
8737
|
+
ctx[1]);
|
|
8762
8738
|
}
|
|
8763
8739
|
|
|
8764
8740
|
if (
|
|
8765
8741
|
/*message*/
|
|
8766
|
-
ctx[
|
|
8742
|
+
ctx[0]) {
|
|
8767
8743
|
if (if_block) {
|
|
8768
8744
|
if_block.p(ctx, dirty);
|
|
8769
8745
|
} else {
|
|
@@ -8778,10 +8754,10 @@ function create_if_block_1$4(ctx) {
|
|
|
8778
8754
|
|
|
8779
8755
|
if (dirty &
|
|
8780
8756
|
/*fullscreen*/
|
|
8781
|
-
|
|
8757
|
+
8) {
|
|
8782
8758
|
toggle_class(div, "fullscreen",
|
|
8783
8759
|
/*fullscreen*/
|
|
8784
|
-
ctx[
|
|
8760
|
+
ctx[3]);
|
|
8785
8761
|
}
|
|
8786
8762
|
},
|
|
8787
8763
|
|
|
@@ -8813,7 +8789,7 @@ function create_if_block_1$4(ctx) {
|
|
|
8813
8789
|
}
|
|
8814
8790
|
|
|
8815
8791
|
};
|
|
8816
|
-
} // (
|
|
8792
|
+
} // (41:6) {#if message}
|
|
8817
8793
|
|
|
8818
8794
|
|
|
8819
8795
|
function create_if_block_4(ctx) {
|
|
@@ -8824,7 +8800,7 @@ function create_if_block_4(ctx) {
|
|
|
8824
8800
|
div = element("div");
|
|
8825
8801
|
t = text(
|
|
8826
8802
|
/*message*/
|
|
8827
|
-
ctx[
|
|
8803
|
+
ctx[0]);
|
|
8828
8804
|
attr(div, "class", "message");
|
|
8829
8805
|
},
|
|
8830
8806
|
|
|
@@ -8836,9 +8812,9 @@ function create_if_block_4(ctx) {
|
|
|
8836
8812
|
p(ctx, dirty) {
|
|
8837
8813
|
if (dirty &
|
|
8838
8814
|
/*message*/
|
|
8839
|
-
|
|
8815
|
+
1) set_data(t,
|
|
8840
8816
|
/*message*/
|
|
8841
|
-
ctx[
|
|
8817
|
+
ctx[0]);
|
|
8842
8818
|
},
|
|
8843
8819
|
|
|
8844
8820
|
d(detaching) {
|
|
@@ -8846,7 +8822,7 @@ function create_if_block_4(ctx) {
|
|
|
8846
8822
|
}
|
|
8847
8823
|
|
|
8848
8824
|
};
|
|
8849
|
-
} // (
|
|
8825
|
+
} // (34:6) {#if message}
|
|
8850
8826
|
|
|
8851
8827
|
|
|
8852
8828
|
function create_if_block_2$3(ctx) {
|
|
@@ -8857,7 +8833,7 @@ function create_if_block_2$3(ctx) {
|
|
|
8857
8833
|
div = element("div");
|
|
8858
8834
|
t = text(
|
|
8859
8835
|
/*message*/
|
|
8860
|
-
ctx[
|
|
8836
|
+
ctx[0]);
|
|
8861
8837
|
attr(div, "class", "message");
|
|
8862
8838
|
},
|
|
8863
8839
|
|
|
@@ -8869,9 +8845,9 @@ function create_if_block_2$3(ctx) {
|
|
|
8869
8845
|
p(ctx, dirty) {
|
|
8870
8846
|
if (dirty &
|
|
8871
8847
|
/*message*/
|
|
8872
|
-
|
|
8848
|
+
1) set_data(t,
|
|
8873
8849
|
/*message*/
|
|
8874
|
-
ctx[
|
|
8850
|
+
ctx[0]);
|
|
8875
8851
|
},
|
|
8876
8852
|
|
|
8877
8853
|
d(detaching) {
|
|
@@ -8886,7 +8862,7 @@ function create_fragment$f(ctx) {
|
|
|
8886
8862
|
let current;
|
|
8887
8863
|
let if_block =
|
|
8888
8864
|
/*isVisible*/
|
|
8889
|
-
ctx[
|
|
8865
|
+
ctx[5] && create_if_block$7(ctx);
|
|
8890
8866
|
return {
|
|
8891
8867
|
c() {
|
|
8892
8868
|
if (if_block) if_block.c();
|
|
@@ -8903,13 +8879,13 @@ function create_fragment$f(ctx) {
|
|
|
8903
8879
|
p(ctx, [dirty]) {
|
|
8904
8880
|
if (
|
|
8905
8881
|
/*isVisible*/
|
|
8906
|
-
ctx[
|
|
8882
|
+
ctx[5]) {
|
|
8907
8883
|
if (if_block) {
|
|
8908
8884
|
if_block.p(ctx, dirty);
|
|
8909
8885
|
|
|
8910
8886
|
if (dirty &
|
|
8911
8887
|
/*isVisible*/
|
|
8912
|
-
|
|
8888
|
+
32) {
|
|
8913
8889
|
transition_in(if_block, 1);
|
|
8914
8890
|
}
|
|
8915
8891
|
} else {
|
|
@@ -8948,9 +8924,6 @@ function create_fragment$f(ctx) {
|
|
|
8948
8924
|
|
|
8949
8925
|
function instance$e($$self, $$props, $$invalidate) {
|
|
8950
8926
|
let isVisible;
|
|
8951
|
-
let {
|
|
8952
|
-
type = "infinite"
|
|
8953
|
-
} = $$props;
|
|
8954
8927
|
let {
|
|
8955
8928
|
variant = "inline"
|
|
8956
8929
|
} = $$props;
|
|
@@ -8961,7 +8934,7 @@ function instance$e($$self, $$props, $$invalidate) {
|
|
|
8961
8934
|
message = ""
|
|
8962
8935
|
} = $$props;
|
|
8963
8936
|
let {
|
|
8964
|
-
progress =
|
|
8937
|
+
progress = -1
|
|
8965
8938
|
} = $$props;
|
|
8966
8939
|
let {
|
|
8967
8940
|
visible = "false"
|
|
@@ -8970,29 +8943,28 @@ function instance$e($$self, $$props, $$invalidate) {
|
|
|
8970
8943
|
let fullscreen;
|
|
8971
8944
|
let inline;
|
|
8972
8945
|
onMount(async () => {
|
|
8973
|
-
$$invalidate(
|
|
8974
|
-
$$invalidate(
|
|
8975
|
-
$$invalidate(
|
|
8946
|
+
$$invalidate(2, spinnerSize = size === "small" ? "large" : "xlarge");
|
|
8947
|
+
$$invalidate(3, fullscreen = variant === "fullscreen");
|
|
8948
|
+
$$invalidate(4, inline = variant === "inline");
|
|
8976
8949
|
});
|
|
8977
8950
|
|
|
8978
8951
|
$$self.$$set = $$props => {
|
|
8979
|
-
if ('
|
|
8980
|
-
if ('
|
|
8981
|
-
if ('
|
|
8982
|
-
if ('
|
|
8983
|
-
if ('
|
|
8984
|
-
if ('visible' in $$props) $$invalidate(9, visible = $$props.visible);
|
|
8952
|
+
if ('variant' in $$props) $$invalidate(6, variant = $$props.variant);
|
|
8953
|
+
if ('size' in $$props) $$invalidate(7, size = $$props.size);
|
|
8954
|
+
if ('message' in $$props) $$invalidate(0, message = $$props.message);
|
|
8955
|
+
if ('progress' in $$props) $$invalidate(1, progress = $$props.progress);
|
|
8956
|
+
if ('visible' in $$props) $$invalidate(8, visible = $$props.visible);
|
|
8985
8957
|
};
|
|
8986
8958
|
|
|
8987
8959
|
$$self.$$.update = () => {
|
|
8988
8960
|
if ($$self.$$.dirty &
|
|
8989
8961
|
/*visible*/
|
|
8990
|
-
|
|
8991
|
-
$$invalidate(
|
|
8962
|
+
256) {
|
|
8963
|
+
$$invalidate(5, isVisible = toBoolean(visible));
|
|
8992
8964
|
}
|
|
8993
8965
|
};
|
|
8994
8966
|
|
|
8995
|
-
return [
|
|
8967
|
+
return [message, progress, spinnerSize, fullscreen, inline, isVisible, variant, size, visible];
|
|
8996
8968
|
}
|
|
8997
8969
|
|
|
8998
8970
|
class CircularProgress extends SvelteElement {
|
|
@@ -9004,12 +8976,11 @@ class CircularProgress extends SvelteElement {
|
|
|
9004
8976
|
props: attribute_to_object(this.attributes),
|
|
9005
8977
|
customElement: true
|
|
9006
8978
|
}, instance$e, create_fragment$f, safe_not_equal, {
|
|
9007
|
-
|
|
9008
|
-
|
|
9009
|
-
|
|
9010
|
-
|
|
9011
|
-
|
|
9012
|
-
visible: 9
|
|
8979
|
+
variant: 6,
|
|
8980
|
+
size: 7,
|
|
8981
|
+
message: 0,
|
|
8982
|
+
progress: 1,
|
|
8983
|
+
visible: 8
|
|
9013
8984
|
}, null);
|
|
9014
8985
|
|
|
9015
8986
|
if (options) {
|
|
@@ -9025,22 +8996,11 @@ class CircularProgress extends SvelteElement {
|
|
|
9025
8996
|
}
|
|
9026
8997
|
|
|
9027
8998
|
static get observedAttributes() {
|
|
9028
|
-
return ["
|
|
9029
|
-
}
|
|
9030
|
-
|
|
9031
|
-
get type() {
|
|
9032
|
-
return this.$$.ctx[0];
|
|
9033
|
-
}
|
|
9034
|
-
|
|
9035
|
-
set type(type) {
|
|
9036
|
-
this.$$set({
|
|
9037
|
-
type
|
|
9038
|
-
});
|
|
9039
|
-
flush();
|
|
8999
|
+
return ["variant", "size", "message", "progress", "visible"];
|
|
9040
9000
|
}
|
|
9041
9001
|
|
|
9042
9002
|
get variant() {
|
|
9043
|
-
return this.$$.ctx[
|
|
9003
|
+
return this.$$.ctx[6];
|
|
9044
9004
|
}
|
|
9045
9005
|
|
|
9046
9006
|
set variant(variant) {
|
|
@@ -9051,7 +9011,7 @@ class CircularProgress extends SvelteElement {
|
|
|
9051
9011
|
}
|
|
9052
9012
|
|
|
9053
9013
|
get size() {
|
|
9054
|
-
return this.$$.ctx[
|
|
9014
|
+
return this.$$.ctx[7];
|
|
9055
9015
|
}
|
|
9056
9016
|
|
|
9057
9017
|
set size(size) {
|
|
@@ -9062,7 +9022,7 @@ class CircularProgress extends SvelteElement {
|
|
|
9062
9022
|
}
|
|
9063
9023
|
|
|
9064
9024
|
get message() {
|
|
9065
|
-
return this.$$.ctx[
|
|
9025
|
+
return this.$$.ctx[0];
|
|
9066
9026
|
}
|
|
9067
9027
|
|
|
9068
9028
|
set message(message) {
|
|
@@ -9073,7 +9033,7 @@ class CircularProgress extends SvelteElement {
|
|
|
9073
9033
|
}
|
|
9074
9034
|
|
|
9075
9035
|
get progress() {
|
|
9076
|
-
return this.$$.ctx[
|
|
9036
|
+
return this.$$.ctx[1];
|
|
9077
9037
|
}
|
|
9078
9038
|
|
|
9079
9039
|
set progress(progress) {
|
|
@@ -9084,7 +9044,7 @@ class CircularProgress extends SvelteElement {
|
|
|
9084
9044
|
}
|
|
9085
9045
|
|
|
9086
9046
|
get visible() {
|
|
9087
|
-
return this.$$.ctx[
|
|
9047
|
+
return this.$$.ctx[8];
|
|
9088
9048
|
}
|
|
9089
9049
|
|
|
9090
9050
|
set visible(visible) {
|
|
@@ -9876,7 +9836,7 @@ function create_if_block_3(ctx) {
|
|
|
9876
9836
|
}
|
|
9877
9837
|
|
|
9878
9838
|
};
|
|
9879
|
-
} // (
|
|
9839
|
+
} // (34:2) {#if ["alpha", "beta"].includes(level)}
|
|
9880
9840
|
|
|
9881
9841
|
|
|
9882
9842
|
function create_if_block_1$3(ctx) {
|
|
@@ -9903,7 +9863,7 @@ function create_if_block_1$3(ctx) {
|
|
|
9903
9863
|
t2 = text("This is a new ");
|
|
9904
9864
|
a = element("a");
|
|
9905
9865
|
a.textContent = "Alberta Government";
|
|
9906
|
-
t4 = text("
|
|
9866
|
+
t4 = text(" service\n ");
|
|
9907
9867
|
if (if_block) if_block.c();
|
|
9908
9868
|
attr(div0, "data-testid", "level");
|
|
9909
9869
|
attr(div0, "class", div0_class_value = "service-level service-level--" +
|
|
@@ -9964,7 +9924,7 @@ function create_if_block_1$3(ctx) {
|
|
|
9964
9924
|
}
|
|
9965
9925
|
|
|
9966
9926
|
};
|
|
9967
|
-
} // (
|
|
9927
|
+
} // (43:6) {#if feedbackurl}
|
|
9968
9928
|
|
|
9969
9929
|
|
|
9970
9930
|
function create_if_block_2$2(ctx) {
|
|
@@ -10006,7 +9966,7 @@ function create_if_block_2$2(ctx) {
|
|
|
10006
9966
|
}
|
|
10007
9967
|
|
|
10008
9968
|
};
|
|
10009
|
-
} // (
|
|
9969
|
+
} // (49:2) {#if version}
|
|
10010
9970
|
|
|
10011
9971
|
|
|
10012
9972
|
function create_if_block$6(ctx) {
|
|
@@ -10174,7 +10134,7 @@ function instance$a($$self, $$props, $$invalidate) {
|
|
|
10174
10134
|
class MicrositeHeader extends SvelteElement {
|
|
10175
10135
|
constructor(options) {
|
|
10176
10136
|
super();
|
|
10177
|
-
this.shadowRoot.innerHTML = `<style>:host{box-sizing:border-box;font-family:var(--font-family)}a{color:var(--goa-color-interactive);cursor:pointer}a:hover{color:var(--goa-color-interactive--hover)}a:focus{outline-width:thin;outline-style:solid;outline-color:var(--goa-color-interactive--hover);outline-offset:0px}.goa-official-site-header{display:flex;font-size:var(--fs-
|
|
10137
|
+
this.shadowRoot.innerHTML = `<style>:host{box-sizing:border-box;font-family:var(--font-family)}a{color:var(--goa-color-interactive);cursor:pointer}a:hover{color:var(--goa-color-interactive--hover)}a:focus{outline-width:thin;outline-style:solid;outline-color:var(--goa-color-interactive--hover);outline-offset:0px}.goa-official-site-header{display:flex;font-size:var(--fs-sm);background-color:var(--color-gray-100);align-items:center;justify-content:space-between;padding:0.5rem 1.5rem}@media(max-width: 640px){.goa-official-site-header{padding:0.5rem 1rem;align-items:start}}.spacer{flex:1 1 auto}.version{color:var(--goa-color-text-secondary);padding-left:1rem;line-height:1.25rem}.service-level{font-weight:bold;padding:0.25rem;display:flex;margin-right:1rem;line-height:initial}.service-level--alpha{background-color:var(--goa-color-status-warning);color:var(--goa-color-text)}.service-level--beta{background-color:var(--goa-color-brand);color:var(--goa-color-text-light)}.service-level--live{padding:0}.site-text{color:var(--goa-color-text);line-height:1.25rem}</style>`;
|
|
10178
10138
|
init(this, {
|
|
10179
10139
|
target: this.shadowRoot,
|
|
10180
10140
|
props: attribute_to_object(this.attributes),
|
|
@@ -11046,7 +11006,7 @@ function create_if_block$4(ctx) {
|
|
|
11046
11006
|
attr(path, "stroke-linecap", "round");
|
|
11047
11007
|
attr(svg, "class", svg_class_value = `spinner-${
|
|
11048
11008
|
/*type*/
|
|
11049
|
-
ctx[
|
|
11009
|
+
ctx[2]}`);
|
|
11050
11010
|
attr(svg, "fill", "none");
|
|
11051
11011
|
attr(svg, "viewBox", svg_viewBox_value = "0 0 " +
|
|
11052
11012
|
/*diameter*/
|
|
@@ -11061,7 +11021,7 @@ function create_if_block$4(ctx) {
|
|
|
11061
11021
|
ctx[5]);
|
|
11062
11022
|
attr(svg, "data-testid",
|
|
11063
11023
|
/*testid*/
|
|
11064
|
-
ctx[
|
|
11024
|
+
ctx[1]);
|
|
11065
11025
|
attr(svg, "xmlns", "http://www.w3.org/2000/svg");
|
|
11066
11026
|
},
|
|
11067
11027
|
|
|
@@ -11142,9 +11102,9 @@ function create_if_block$4(ctx) {
|
|
|
11142
11102
|
|
|
11143
11103
|
if (dirty &
|
|
11144
11104
|
/*type*/
|
|
11145
|
-
|
|
11105
|
+
4 && svg_class_value !== (svg_class_value = `spinner-${
|
|
11146
11106
|
/*type*/
|
|
11147
|
-
ctx[
|
|
11107
|
+
ctx[2]}`)) {
|
|
11148
11108
|
attr(svg, "class", svg_class_value);
|
|
11149
11109
|
}
|
|
11150
11110
|
|
|
@@ -11176,10 +11136,10 @@ function create_if_block$4(ctx) {
|
|
|
11176
11136
|
|
|
11177
11137
|
if (dirty &
|
|
11178
11138
|
/*testid*/
|
|
11179
|
-
|
|
11139
|
+
2) {
|
|
11180
11140
|
attr(svg, "data-testid",
|
|
11181
11141
|
/*testid*/
|
|
11182
|
-
ctx[
|
|
11142
|
+
ctx[1]);
|
|
11183
11143
|
}
|
|
11184
11144
|
},
|
|
11185
11145
|
|
|
@@ -11249,14 +11209,12 @@ function instance$8($$self, $$props, $$invalidate) {
|
|
|
11249
11209
|
invert = false
|
|
11250
11210
|
} = $$props;
|
|
11251
11211
|
let {
|
|
11252
|
-
|
|
11253
|
-
} = $$props;
|
|
11254
|
-
let {
|
|
11255
|
-
progress = "0"
|
|
11212
|
+
progress = -1
|
|
11256
11213
|
} = $$props;
|
|
11257
11214
|
let {
|
|
11258
11215
|
testid = ""
|
|
11259
11216
|
} = $$props;
|
|
11217
|
+
let type = "infinite";
|
|
11260
11218
|
|
|
11261
11219
|
const _progress = tweened(0, {
|
|
11262
11220
|
duration: 500,
|
|
@@ -11293,9 +11251,8 @@ function instance$8($$self, $$props, $$invalidate) {
|
|
|
11293
11251
|
$$self.$$set = $$props => {
|
|
11294
11252
|
if ('size' in $$props) $$invalidate(10, size = $$props.size);
|
|
11295
11253
|
if ('invert' in $$props) $$invalidate(0, invert = $$props.invert);
|
|
11296
|
-
if ('type' in $$props) $$invalidate(1, type = $$props.type);
|
|
11297
11254
|
if ('progress' in $$props) $$invalidate(11, progress = $$props.progress);
|
|
11298
|
-
if ('testid' in $$props) $$invalidate(
|
|
11255
|
+
if ('testid' in $$props) $$invalidate(1, testid = $$props.testid);
|
|
11299
11256
|
};
|
|
11300
11257
|
|
|
11301
11258
|
$$self.$$.update = () => {
|
|
@@ -11304,7 +11261,16 @@ function instance$8($$self, $$props, $$invalidate) {
|
|
|
11304
11261
|
2048) {
|
|
11305
11262
|
// Reactive
|
|
11306
11263
|
{
|
|
11307
|
-
|
|
11264
|
+
// Typescript recognizes `progress` as a number, but once compiled, due to it being a web component, progress is a string.
|
|
11265
|
+
// This line makes both sides happy.
|
|
11266
|
+
const p = parseFloat(progress + '');
|
|
11267
|
+
|
|
11268
|
+
if (p >= 0) {
|
|
11269
|
+
_progress.set(p || 1); // start at 1 to prevent incorrect arc calculations
|
|
11270
|
+
|
|
11271
|
+
|
|
11272
|
+
$$invalidate(2, type = "progress");
|
|
11273
|
+
}
|
|
11308
11274
|
}
|
|
11309
11275
|
}
|
|
11310
11276
|
|
|
@@ -11344,12 +11310,12 @@ function instance$8($$self, $$props, $$invalidate) {
|
|
|
11344
11310
|
|
|
11345
11311
|
if ($$self.$$.dirty &
|
|
11346
11312
|
/*type, pathRadius, progress*/
|
|
11347
|
-
|
|
11313
|
+
6148) {
|
|
11348
11314
|
$$invalidate(6, ready = type === "infinite" ? pathRadius : pathRadius && progress);
|
|
11349
11315
|
}
|
|
11350
11316
|
};
|
|
11351
11317
|
|
|
11352
|
-
return [invert,
|
|
11318
|
+
return [invert, testid, type, radius, strokewidth, diameter, ready, $_progress, _progress, getArc, size, progress, pathRadius];
|
|
11353
11319
|
}
|
|
11354
11320
|
|
|
11355
11321
|
class Spinner extends SvelteElement {
|
|
@@ -11363,9 +11329,8 @@ class Spinner extends SvelteElement {
|
|
|
11363
11329
|
}, instance$8, create_fragment$9, safe_not_equal, {
|
|
11364
11330
|
size: 10,
|
|
11365
11331
|
invert: 0,
|
|
11366
|
-
type: 1,
|
|
11367
11332
|
progress: 11,
|
|
11368
|
-
testid:
|
|
11333
|
+
testid: 1
|
|
11369
11334
|
}, null);
|
|
11370
11335
|
|
|
11371
11336
|
if (options) {
|
|
@@ -11381,7 +11346,7 @@ class Spinner extends SvelteElement {
|
|
|
11381
11346
|
}
|
|
11382
11347
|
|
|
11383
11348
|
static get observedAttributes() {
|
|
11384
|
-
return ["size", "invert", "
|
|
11349
|
+
return ["size", "invert", "progress", "testid"];
|
|
11385
11350
|
}
|
|
11386
11351
|
|
|
11387
11352
|
get size() {
|
|
@@ -11406,17 +11371,6 @@ class Spinner extends SvelteElement {
|
|
|
11406
11371
|
flush();
|
|
11407
11372
|
}
|
|
11408
11373
|
|
|
11409
|
-
get type() {
|
|
11410
|
-
return this.$$.ctx[1];
|
|
11411
|
-
}
|
|
11412
|
-
|
|
11413
|
-
set type(type) {
|
|
11414
|
-
this.$$set({
|
|
11415
|
-
type
|
|
11416
|
-
});
|
|
11417
|
-
flush();
|
|
11418
|
-
}
|
|
11419
|
-
|
|
11420
11374
|
get progress() {
|
|
11421
11375
|
return this.$$.ctx[11];
|
|
11422
11376
|
}
|
|
@@ -11429,7 +11383,7 @@ class Spinner extends SvelteElement {
|
|
|
11429
11383
|
}
|
|
11430
11384
|
|
|
11431
11385
|
get testid() {
|
|
11432
|
-
return this.$$.ctx[
|
|
11386
|
+
return this.$$.ctx[1];
|
|
11433
11387
|
}
|
|
11434
11388
|
|
|
11435
11389
|
set testid(testid) {
|
|
@@ -11858,7 +11812,7 @@ function instance$7($$self, $$props, $$invalidate) {
|
|
|
11858
11812
|
class TextArea extends SvelteElement {
|
|
11859
11813
|
constructor(options) {
|
|
11860
11814
|
super();
|
|
11861
|
-
this.shadowRoot.innerHTML = `<style>:host{box-sizing:border-box;font-family:var(--font-family)}.container{position:relative;width:100%}@media(min-width: 640px){.container{max-width:var(--width)}}.goa-textarea{display:block;width:100%;box-sizing:border-box;outline:none;transition:box-shadow 0.1s ease-in;border:1px solid var(--color-gray-600);border-radius:3px;background:var(--color-white);color:var(--color-black, #ccc);padding:var(--
|
|
11815
|
+
this.shadowRoot.innerHTML = `<style>:host{box-sizing:border-box;font-family:var(--font-family)}.container{position:relative;width:100%}@media(min-width: 640px){.container{max-width:var(--width)}}.goa-textarea{display:block;width:100%;box-sizing:border-box;outline:none;transition:box-shadow 0.1s ease-in;border:1px solid var(--color-gray-600);border-radius:3px;background:var(--color-white);color:var(--color-black, #ccc);padding:var(--textarea-padding-vertical, 0.5rem) var(--textarea-padding-horizontal, 0.5rem);font-size:var(--input-font-size);font-family:var(--font-family);min-width:100%}@media(min-width: 640px){.goa-textarea{min-width:0;width:var(--width)}}.goa-textarea[readonly]{cursor:pointer}.goa-textarea:hover{border-color:var(--goa-color-interactive--hover)}.goa-textarea:active,.goa-textarea:focus,.goa-textarea:focus-within{box-shadow:0 0 0 3px var(--goa-color-interactive--focus)}.goa-textarea:disabled{border-color:var(--color-gray-200)}.goa-textarea:disabled:hover{border-color:var(--color-gray-200)}.goa-textarea:disabled:focus,.goa-textarea:disabled:active{box-shadow:none}.counter{position:absolute;right:0;padding-top:0.25rem;font-size:var(--fs-sm)}.counter-error{color:var(--goa-color-interactive--error)
|
|
11862
11816
|
}.error:hover,.error:focus,.error{border:2px solid var(--goa-color-interactive--error)}</style>`;
|
|
11863
11817
|
init(this, {
|
|
11864
11818
|
target: this.shadowRoot,
|
|
@@ -12035,7 +11989,7 @@ function create_fragment$7(ctx) {
|
|
|
12035
11989
|
insert(target, div, anchor);
|
|
12036
11990
|
/*div_binding*/
|
|
12037
11991
|
|
|
12038
|
-
ctx[
|
|
11992
|
+
ctx[4](div);
|
|
12039
11993
|
},
|
|
12040
11994
|
|
|
12041
11995
|
p: noop,
|
|
@@ -12046,20 +12000,16 @@ function create_fragment$7(ctx) {
|
|
|
12046
12000
|
if (detaching) detach(div);
|
|
12047
12001
|
/*div_binding*/
|
|
12048
12002
|
|
|
12049
|
-
ctx[
|
|
12003
|
+
ctx[4](null);
|
|
12050
12004
|
}
|
|
12051
12005
|
|
|
12052
12006
|
};
|
|
12053
12007
|
}
|
|
12054
12008
|
|
|
12055
12009
|
function isFocusable(element) {
|
|
12056
|
-
|
|
12057
|
-
|
|
12058
|
-
|
|
12059
|
-
|
|
12060
|
-
if (element.disabled) {
|
|
12061
|
-
return false;
|
|
12062
|
-
}
|
|
12010
|
+
const isTabbable = element.tabIndex > 0 || element.tabIndex === 0 && element.getAttribute('tabIndex') !== null;
|
|
12011
|
+
if (isTabbable) return true;
|
|
12012
|
+
if (element.disabled) return false;
|
|
12063
12013
|
|
|
12064
12014
|
switch (element.nodeName) {
|
|
12065
12015
|
case 'A':
|
|
@@ -12079,13 +12029,14 @@ function isFocusable(element) {
|
|
|
12079
12029
|
}
|
|
12080
12030
|
|
|
12081
12031
|
function instance$6($$self, $$props, $$invalidate) {
|
|
12082
|
-
let
|
|
12032
|
+
let isActive;
|
|
12033
|
+
let {
|
|
12034
|
+
active
|
|
12035
|
+
} = $$props;
|
|
12083
12036
|
let ignoreFocusChanges = false;
|
|
12084
12037
|
let lastFocus;
|
|
12085
12038
|
let element;
|
|
12086
|
-
let
|
|
12087
|
-
open
|
|
12088
|
-
} = $$props;
|
|
12039
|
+
let hasListeners = false;
|
|
12089
12040
|
|
|
12090
12041
|
function removeListeners() {
|
|
12091
12042
|
document.removeEventListener('focus', trapFocus, true);
|
|
@@ -12093,15 +12044,18 @@ function instance$6($$self, $$props, $$invalidate) {
|
|
|
12093
12044
|
|
|
12094
12045
|
function addListeners() {
|
|
12095
12046
|
document.addEventListener('focus', trapFocus, true);
|
|
12096
|
-
}
|
|
12047
|
+
} // ====
|
|
12048
|
+
// First Node
|
|
12049
|
+
// ====
|
|
12097
12050
|
|
|
12098
|
-
function attemptFocusOnFirstDescendant(descendants) {
|
|
12099
|
-
if (!descendants) return false;
|
|
12100
12051
|
|
|
12101
|
-
|
|
12102
|
-
|
|
12052
|
+
function focusOnFirstNode(nodes) {
|
|
12053
|
+
if (!nodes) return false;
|
|
12103
12054
|
|
|
12104
|
-
|
|
12055
|
+
for (const node of nodes) {
|
|
12056
|
+
const isFocusable = focus(node) || focusOnFirstNode(node.childNodes) || focusOnFirstNodeOfSlot(node) || focusOnFirstNodeOfShadowDOM(node);
|
|
12057
|
+
|
|
12058
|
+
if (isFocusable) {
|
|
12105
12059
|
return true;
|
|
12106
12060
|
}
|
|
12107
12061
|
}
|
|
@@ -12109,37 +12063,34 @@ function instance$6($$self, $$props, $$invalidate) {
|
|
|
12109
12063
|
return false;
|
|
12110
12064
|
}
|
|
12111
12065
|
|
|
12112
|
-
function
|
|
12113
|
-
|
|
12114
|
-
|
|
12115
|
-
if (node instanceof HTMLSlotElement) {
|
|
12116
|
-
let assingedNodesOfSlotElement = (_a = node) === null || _a === void 0 ? void 0 : _a.assignedNodes();
|
|
12066
|
+
function focusOnFirstNodeOfSlot(node) {
|
|
12067
|
+
if (!(node instanceof HTMLSlotElement)) return false;
|
|
12117
12068
|
|
|
12118
|
-
|
|
12119
|
-
|
|
12120
|
-
}
|
|
12069
|
+
if (focusOnFirstNode(node.assignedNodes())) {
|
|
12070
|
+
return true;
|
|
12121
12071
|
}
|
|
12122
12072
|
}
|
|
12123
12073
|
|
|
12124
|
-
function
|
|
12125
|
-
var _a
|
|
12074
|
+
function focusOnFirstNodeOfShadowDOM(node) {
|
|
12075
|
+
var _a;
|
|
12126
12076
|
|
|
12127
|
-
if (node instanceof HTMLElement)
|
|
12128
|
-
let childNodesOfShadowRoot = (_b = (_a = node) === null || _a === void 0 ? void 0 : _a.shadowRoot) === null || _b === void 0 ? void 0 : _b.childNodes;
|
|
12077
|
+
if (!(node instanceof HTMLElement)) return false;
|
|
12129
12078
|
|
|
12130
|
-
|
|
12131
|
-
|
|
12132
|
-
}
|
|
12079
|
+
if (focusOnFirstNode((_a = node.shadowRoot) === null || _a === void 0 ? void 0 : _a.childNodes)) {
|
|
12080
|
+
return true;
|
|
12133
12081
|
}
|
|
12134
|
-
}
|
|
12082
|
+
} // ====
|
|
12083
|
+
// Last Node
|
|
12084
|
+
// ====
|
|
12085
|
+
|
|
12135
12086
|
|
|
12136
|
-
function
|
|
12137
|
-
if (!
|
|
12087
|
+
function focusOnLastNode(nodes) {
|
|
12088
|
+
if (!nodes) return false;
|
|
12138
12089
|
|
|
12139
|
-
for (let i =
|
|
12140
|
-
let
|
|
12090
|
+
for (let i = nodes.length - 1; i >= 0; i--) {
|
|
12091
|
+
let node = nodes[i];
|
|
12141
12092
|
|
|
12142
|
-
if (
|
|
12093
|
+
if (focus(node) || focusOnLastNode(node.childNodes) || focusOnLastNodeOfSlot(node) || focusOnLastNodeOfShadowDOM(node)) {
|
|
12143
12094
|
return true;
|
|
12144
12095
|
}
|
|
12145
12096
|
}
|
|
@@ -12147,67 +12098,57 @@ function instance$6($$self, $$props, $$invalidate) {
|
|
|
12147
12098
|
return false;
|
|
12148
12099
|
}
|
|
12149
12100
|
|
|
12150
|
-
function
|
|
12151
|
-
|
|
12152
|
-
|
|
12153
|
-
if (node instanceof HTMLSlotElement) {
|
|
12154
|
-
let assingedNodesOfSlotElement = (_a = node) === null || _a === void 0 ? void 0 : _a.assignedNodes();
|
|
12101
|
+
function focusOnLastNodeOfSlot(node) {
|
|
12102
|
+
if (!(node instanceof HTMLSlotElement)) return false;
|
|
12155
12103
|
|
|
12156
|
-
|
|
12157
|
-
|
|
12158
|
-
}
|
|
12104
|
+
if (focusOnLastNode(node.assignedNodes())) {
|
|
12105
|
+
return true;
|
|
12159
12106
|
}
|
|
12160
12107
|
}
|
|
12161
12108
|
|
|
12162
|
-
function
|
|
12163
|
-
var _a
|
|
12109
|
+
function focusOnLastNodeOfShadowDOM(node) {
|
|
12110
|
+
var _a;
|
|
12164
12111
|
|
|
12165
|
-
if (node instanceof HTMLElement)
|
|
12166
|
-
let childNodesOfShadowRoot = (_b = (_a = node) === null || _a === void 0 ? void 0 : _a.shadowRoot) === null || _b === void 0 ? void 0 : _b.childNodes;
|
|
12112
|
+
if (!(node instanceof HTMLElement)) return false;
|
|
12167
12113
|
|
|
12168
|
-
|
|
12169
|
-
|
|
12170
|
-
}
|
|
12114
|
+
if (focusOnLastNode((_a = node.shadowRoot) === null || _a === void 0 ? void 0 : _a.childNodes)) {
|
|
12115
|
+
return true;
|
|
12171
12116
|
}
|
|
12172
12117
|
}
|
|
12173
12118
|
|
|
12174
|
-
function
|
|
12175
|
-
if (!isFocusable(element))
|
|
12176
|
-
return false;
|
|
12177
|
-
}
|
|
12178
|
-
|
|
12179
|
-
ignoreFocusChanges = true;
|
|
12119
|
+
function focus(element) {
|
|
12120
|
+
if (!isFocusable(element)) return false;
|
|
12180
12121
|
|
|
12181
12122
|
try {
|
|
12123
|
+
ignoreFocusChanges = true;
|
|
12182
12124
|
element.focus();
|
|
12183
|
-
} catch (e) {}
|
|
12125
|
+
} catch (e) {} finally {
|
|
12126
|
+
ignoreFocusChanges = false;
|
|
12127
|
+
}
|
|
12184
12128
|
|
|
12185
|
-
ignoreFocusChanges = false;
|
|
12186
12129
|
return document.activeElement === element;
|
|
12187
12130
|
}
|
|
12188
12131
|
|
|
12189
12132
|
function trapFocus(event) {
|
|
12190
12133
|
var _a;
|
|
12191
12134
|
|
|
12192
|
-
if (ignoreFocusChanges)
|
|
12193
|
-
return;
|
|
12194
|
-
}
|
|
12195
|
-
|
|
12135
|
+
if (ignoreFocusChanges) return;
|
|
12196
12136
|
const slotElements = (_a = element.firstChild) === null || _a === void 0 ? void 0 : _a.assignedElements();
|
|
12197
12137
|
if (!(slotElements === null || slotElements === void 0 ? void 0 : slotElements.length)) return;
|
|
12198
12138
|
const contentRootElement = slotElements[0];
|
|
12199
12139
|
|
|
12200
12140
|
if (event.composedPath().includes(contentRootElement)) {
|
|
12201
12141
|
lastFocus = event.target;
|
|
12202
|
-
|
|
12203
|
-
|
|
12142
|
+
return;
|
|
12143
|
+
}
|
|
12204
12144
|
|
|
12205
|
-
|
|
12206
|
-
attemptFocusOnLastDescendant(contentRootElement.childNodes);
|
|
12207
|
-
}
|
|
12145
|
+
focusOnFirstNode(contentRootElement.childNodes);
|
|
12208
12146
|
|
|
12209
|
-
|
|
12147
|
+
if (lastFocus == document.activeElement) {
|
|
12148
|
+
focusOnLastNode(contentRootElement.childNodes);
|
|
12210
12149
|
}
|
|
12150
|
+
|
|
12151
|
+
lastFocus = document.activeElement;
|
|
12211
12152
|
}
|
|
12212
12153
|
|
|
12213
12154
|
function div_binding($$value) {
|
|
@@ -12218,30 +12159,34 @@ function instance$6($$self, $$props, $$invalidate) {
|
|
|
12218
12159
|
}
|
|
12219
12160
|
|
|
12220
12161
|
$$self.$$set = $$props => {
|
|
12221
|
-
if ('
|
|
12162
|
+
if ('active' in $$props) $$invalidate(1, active = $$props.active);
|
|
12222
12163
|
};
|
|
12223
12164
|
|
|
12224
12165
|
$$self.$$.update = () => {
|
|
12225
12166
|
if ($$self.$$.dirty &
|
|
12226
|
-
/*
|
|
12167
|
+
/*active*/
|
|
12227
12168
|
2) {
|
|
12228
|
-
$$invalidate(
|
|
12169
|
+
$$invalidate(3, isActive = toBoolean(active));
|
|
12229
12170
|
}
|
|
12230
12171
|
|
|
12231
12172
|
if ($$self.$$.dirty &
|
|
12232
|
-
/*
|
|
12233
|
-
|
|
12173
|
+
/*isActive, hasListeners*/
|
|
12174
|
+
12) {
|
|
12234
12175
|
{
|
|
12235
|
-
if (
|
|
12176
|
+
if (isActive && !hasListeners) {
|
|
12236
12177
|
addListeners();
|
|
12237
|
-
|
|
12178
|
+
$$invalidate(2, hasListeners = true);
|
|
12179
|
+
}
|
|
12180
|
+
|
|
12181
|
+
if (!isActive && hasListeners) {
|
|
12238
12182
|
removeListeners();
|
|
12183
|
+
$$invalidate(2, hasListeners = false);
|
|
12239
12184
|
}
|
|
12240
12185
|
}
|
|
12241
12186
|
}
|
|
12242
12187
|
};
|
|
12243
12188
|
|
|
12244
|
-
return [element,
|
|
12189
|
+
return [element, active, hasListeners, isActive, div_binding];
|
|
12245
12190
|
}
|
|
12246
12191
|
|
|
12247
12192
|
class FocusTrap extends SvelteElement {
|
|
@@ -12252,7 +12197,7 @@ class FocusTrap extends SvelteElement {
|
|
|
12252
12197
|
props: attribute_to_object(this.attributes),
|
|
12253
12198
|
customElement: true
|
|
12254
12199
|
}, instance$6, create_fragment$7, safe_not_equal, {
|
|
12255
|
-
|
|
12200
|
+
active: 1
|
|
12256
12201
|
}, null);
|
|
12257
12202
|
|
|
12258
12203
|
if (options) {
|
|
@@ -12268,16 +12213,16 @@ class FocusTrap extends SvelteElement {
|
|
|
12268
12213
|
}
|
|
12269
12214
|
|
|
12270
12215
|
static get observedAttributes() {
|
|
12271
|
-
return ["
|
|
12216
|
+
return ["active"];
|
|
12272
12217
|
}
|
|
12273
12218
|
|
|
12274
|
-
get
|
|
12219
|
+
get active() {
|
|
12275
12220
|
return this.$$.ctx[1];
|
|
12276
12221
|
}
|
|
12277
12222
|
|
|
12278
|
-
set
|
|
12223
|
+
set active(active) {
|
|
12279
12224
|
this.$$set({
|
|
12280
|
-
|
|
12225
|
+
active
|
|
12281
12226
|
});
|
|
12282
12227
|
flush();
|
|
12283
12228
|
}
|
|
@@ -13996,7 +13941,6 @@ const GoAChip = ({
|
|
|
13996
13941
|
};
|
|
13997
13942
|
|
|
13998
13943
|
const GoACircularProgress = ({
|
|
13999
|
-
type,
|
|
14000
13944
|
visible,
|
|
14001
13945
|
message,
|
|
14002
13946
|
progress,
|
|
@@ -14004,7 +13948,6 @@ const GoACircularProgress = ({
|
|
|
14004
13948
|
size
|
|
14005
13949
|
}) => {
|
|
14006
13950
|
return jsx("goa-circular-progress", {
|
|
14007
|
-
type: type,
|
|
14008
13951
|
visible: visible ? "true" : "false",
|
|
14009
13952
|
message: message,
|
|
14010
13953
|
progress: progress,
|