@abgov/react-components 4.0.0-alpha.77 → 4.0.0-alpha.78
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/form/form-item.d.ts +3 -2
- package/lib/input/input.d.ts +0 -4
- package/package.json +1 -1
- package/react-components.esm.js +184 -356
- package/react-components.umd.js +184 -356
package/react-components.esm.js
CHANGED
|
@@ -3010,7 +3010,7 @@ function create_if_block_1$9(ctx) {
|
|
|
3010
3010
|
}
|
|
3011
3011
|
|
|
3012
3012
|
};
|
|
3013
|
-
} // (
|
|
3013
|
+
} // (59:4) {#if isIndeterminate}
|
|
3014
3014
|
|
|
3015
3015
|
|
|
3016
3016
|
function create_if_block$f(ctx) {
|
|
@@ -3267,22 +3267,27 @@ function instance$t($$self, $$props, $$invalidate) {
|
|
|
3267
3267
|
value = ""
|
|
3268
3268
|
} = $$props;
|
|
3269
3269
|
let {
|
|
3270
|
-
disabled
|
|
3270
|
+
disabled = "false"
|
|
3271
3271
|
} = $$props;
|
|
3272
3272
|
let {
|
|
3273
|
-
error
|
|
3273
|
+
error = "false"
|
|
3274
3274
|
} = $$props;
|
|
3275
3275
|
let {
|
|
3276
3276
|
testid = ""
|
|
3277
|
-
} = $$props;
|
|
3277
|
+
} = $$props; // Private
|
|
3278
|
+
|
|
3279
|
+
let _value;
|
|
3280
|
+
|
|
3281
|
+
onMount(() => {
|
|
3282
|
+
// hold on to the initial value to prevent losing it on check changes
|
|
3283
|
+
_value = value;
|
|
3284
|
+
});
|
|
3278
3285
|
|
|
3279
3286
|
function onChange(e) {
|
|
3280
3287
|
// An empty string is required as setting the second value to `null` caused the data to get
|
|
3281
3288
|
// out of sync with the events.
|
|
3282
3289
|
const newCheckStatus = !isChecked;
|
|
3283
|
-
|
|
3284
|
-
const _value = newCheckStatus ? `${value || "checked"}` : ""; // set the local state
|
|
3285
|
-
|
|
3290
|
+
const newValue = newCheckStatus ? `${_value || "checked"}` : ""; // set the local state
|
|
3286
3291
|
|
|
3287
3292
|
$$invalidate(9, checked = fromBoolean(newCheckStatus));
|
|
3288
3293
|
e.target.dispatchEvent(new CustomEvent("_change", {
|
|
@@ -3290,7 +3295,7 @@ function instance$t($$self, $$props, $$invalidate) {
|
|
|
3290
3295
|
detail: {
|
|
3291
3296
|
name,
|
|
3292
3297
|
checked: newCheckStatus,
|
|
3293
|
-
value:
|
|
3298
|
+
value: newValue
|
|
3294
3299
|
}
|
|
3295
3300
|
}));
|
|
3296
3301
|
}
|
|
@@ -3309,6 +3314,7 @@ function instance$t($$self, $$props, $$invalidate) {
|
|
|
3309
3314
|
if ($$self.$$.dirty &
|
|
3310
3315
|
/*disabled*/
|
|
3311
3316
|
1024) {
|
|
3317
|
+
// Binding
|
|
3312
3318
|
$$invalidate(7, isDisabled = toBoolean(disabled));
|
|
3313
3319
|
}
|
|
3314
3320
|
|
|
@@ -7135,9 +7141,14 @@ function create_if_block_2$5(ctx) {
|
|
|
7135
7141
|
let div;
|
|
7136
7142
|
let t0;
|
|
7137
7143
|
let t1;
|
|
7138
|
-
let
|
|
7139
|
-
/*
|
|
7140
|
-
ctx[3] &&
|
|
7144
|
+
let show_if =
|
|
7145
|
+
/*requirement*/
|
|
7146
|
+
ctx[3] &&
|
|
7147
|
+
/*REQUIREMENT_TYPES*/
|
|
7148
|
+
ctx[4].includes(
|
|
7149
|
+
/*requirement*/
|
|
7150
|
+
ctx[3]);
|
|
7151
|
+
let if_block = show_if && create_if_block_3$3(ctx);
|
|
7141
7152
|
return {
|
|
7142
7153
|
c() {
|
|
7143
7154
|
div = element("div");
|
|
@@ -7162,12 +7173,21 @@ function create_if_block_2$5(ctx) {
|
|
|
7162
7173
|
1) set_data(t0,
|
|
7163
7174
|
/*label*/
|
|
7164
7175
|
ctx[0]);
|
|
7176
|
+
if (dirty &
|
|
7177
|
+
/*requirement*/
|
|
7178
|
+
8) show_if =
|
|
7179
|
+
/*requirement*/
|
|
7180
|
+
ctx[3] &&
|
|
7181
|
+
/*REQUIREMENT_TYPES*/
|
|
7182
|
+
ctx[4].includes(
|
|
7183
|
+
/*requirement*/
|
|
7184
|
+
ctx[3]);
|
|
7165
7185
|
|
|
7166
|
-
if (
|
|
7167
|
-
|
|
7168
|
-
|
|
7169
|
-
|
|
7170
|
-
if_block = create_if_block_3$3();
|
|
7186
|
+
if (show_if) {
|
|
7187
|
+
if (if_block) {
|
|
7188
|
+
if_block.p(ctx, dirty);
|
|
7189
|
+
} else {
|
|
7190
|
+
if_block = create_if_block_3$3(ctx);
|
|
7171
7191
|
if_block.c();
|
|
7172
7192
|
if_block.m(div, null);
|
|
7173
7193
|
}
|
|
@@ -7183,19 +7203,37 @@ function create_if_block_2$5(ctx) {
|
|
|
7183
7203
|
}
|
|
7184
7204
|
|
|
7185
7205
|
};
|
|
7186
|
-
} // (
|
|
7206
|
+
} // (28:6) {#if requirement && REQUIREMENT_TYPES.includes(requirement)}
|
|
7187
7207
|
|
|
7188
7208
|
|
|
7189
7209
|
function create_if_block_3$3(ctx) {
|
|
7190
7210
|
let em;
|
|
7211
|
+
let t0;
|
|
7212
|
+
let t1;
|
|
7213
|
+
let t2;
|
|
7191
7214
|
return {
|
|
7192
7215
|
c() {
|
|
7193
7216
|
em = element("em");
|
|
7194
|
-
|
|
7217
|
+
t0 = text("(");
|
|
7218
|
+
t1 = text(
|
|
7219
|
+
/*requirement*/
|
|
7220
|
+
ctx[3]);
|
|
7221
|
+
t2 = text(")");
|
|
7195
7222
|
},
|
|
7196
7223
|
|
|
7197
7224
|
m(target, anchor) {
|
|
7198
7225
|
insert(target, em, anchor);
|
|
7226
|
+
append(em, t0);
|
|
7227
|
+
append(em, t1);
|
|
7228
|
+
append(em, t2);
|
|
7229
|
+
},
|
|
7230
|
+
|
|
7231
|
+
p(ctx, dirty) {
|
|
7232
|
+
if (dirty &
|
|
7233
|
+
/*requirement*/
|
|
7234
|
+
8) set_data(t1,
|
|
7235
|
+
/*requirement*/
|
|
7236
|
+
ctx[3]);
|
|
7199
7237
|
},
|
|
7200
7238
|
|
|
7201
7239
|
d(detaching) {
|
|
@@ -7203,7 +7241,7 @@ function create_if_block_3$3(ctx) {
|
|
|
7203
7241
|
}
|
|
7204
7242
|
|
|
7205
7243
|
};
|
|
7206
|
-
} // (
|
|
7244
|
+
} // (36:2) {#if error}
|
|
7207
7245
|
|
|
7208
7246
|
|
|
7209
7247
|
function create_if_block_1$6(ctx) {
|
|
@@ -7236,7 +7274,7 @@ function create_if_block_1$6(ctx) {
|
|
|
7236
7274
|
}
|
|
7237
7275
|
|
|
7238
7276
|
};
|
|
7239
|
-
} // (
|
|
7277
|
+
} // (39:2) {#if helptext}
|
|
7240
7278
|
|
|
7241
7279
|
|
|
7242
7280
|
function create_if_block$9(ctx) {
|
|
@@ -7374,7 +7412,12 @@ function create_fragment$j(ctx) {
|
|
|
7374
7412
|
}
|
|
7375
7413
|
|
|
7376
7414
|
function instance$h($$self, $$props, $$invalidate) {
|
|
7377
|
-
|
|
7415
|
+
const REQUIREMENT_TYPES = ["optional", "required", ""]; // type check function
|
|
7416
|
+
|
|
7417
|
+
function isRequirementType(value) {
|
|
7418
|
+
return REQUIREMENT_TYPES.includes(value);
|
|
7419
|
+
}
|
|
7420
|
+
|
|
7378
7421
|
let {
|
|
7379
7422
|
label = ""
|
|
7380
7423
|
} = $$props;
|
|
@@ -7385,25 +7428,22 @@ function instance$h($$self, $$props, $$invalidate) {
|
|
|
7385
7428
|
error = ""
|
|
7386
7429
|
} = $$props;
|
|
7387
7430
|
let {
|
|
7388
|
-
|
|
7431
|
+
requirement = ""
|
|
7389
7432
|
} = $$props;
|
|
7433
|
+
onMount(() => {
|
|
7434
|
+
if (!isRequirementType(requirement)) {
|
|
7435
|
+
throw "Invalid requirement type";
|
|
7436
|
+
}
|
|
7437
|
+
});
|
|
7390
7438
|
|
|
7391
7439
|
$$self.$$set = $$props => {
|
|
7392
7440
|
if ('label' in $$props) $$invalidate(0, label = $$props.label);
|
|
7393
7441
|
if ('helptext' in $$props) $$invalidate(1, helptext = $$props.helptext);
|
|
7394
7442
|
if ('error' in $$props) $$invalidate(2, error = $$props.error);
|
|
7395
|
-
if ('
|
|
7443
|
+
if ('requirement' in $$props) $$invalidate(3, requirement = $$props.requirement);
|
|
7396
7444
|
};
|
|
7397
7445
|
|
|
7398
|
-
|
|
7399
|
-
if ($$self.$$.dirty &
|
|
7400
|
-
/*optional*/
|
|
7401
|
-
16) {
|
|
7402
|
-
$$invalidate(3, isOptional = toBoolean(optional));
|
|
7403
|
-
}
|
|
7404
|
-
};
|
|
7405
|
-
|
|
7406
|
-
return [label, helptext, error, isOptional, optional];
|
|
7446
|
+
return [label, helptext, error, requirement, REQUIREMENT_TYPES];
|
|
7407
7447
|
}
|
|
7408
7448
|
|
|
7409
7449
|
class FormItem extends SvelteElement {
|
|
@@ -7418,7 +7458,7 @@ class FormItem extends SvelteElement {
|
|
|
7418
7458
|
label: 0,
|
|
7419
7459
|
helptext: 1,
|
|
7420
7460
|
error: 2,
|
|
7421
|
-
|
|
7461
|
+
requirement: 3
|
|
7422
7462
|
}, null);
|
|
7423
7463
|
|
|
7424
7464
|
if (options) {
|
|
@@ -7434,7 +7474,7 @@ class FormItem extends SvelteElement {
|
|
|
7434
7474
|
}
|
|
7435
7475
|
|
|
7436
7476
|
static get observedAttributes() {
|
|
7437
|
-
return ["label", "helptext", "error", "
|
|
7477
|
+
return ["label", "helptext", "error", "requirement"];
|
|
7438
7478
|
}
|
|
7439
7479
|
|
|
7440
7480
|
get label() {
|
|
@@ -7470,13 +7510,13 @@ class FormItem extends SvelteElement {
|
|
|
7470
7510
|
flush();
|
|
7471
7511
|
}
|
|
7472
7512
|
|
|
7473
|
-
get
|
|
7474
|
-
return this.$$.ctx[
|
|
7513
|
+
get requirement() {
|
|
7514
|
+
return this.$$.ctx[3];
|
|
7475
7515
|
}
|
|
7476
7516
|
|
|
7477
|
-
set
|
|
7517
|
+
set requirement(requirement) {
|
|
7478
7518
|
this.$$set({
|
|
7479
|
-
|
|
7519
|
+
requirement
|
|
7480
7520
|
});
|
|
7481
7521
|
flush();
|
|
7482
7522
|
}
|
|
@@ -8344,7 +8384,7 @@ class Icon extends SvelteElement {
|
|
|
8344
8384
|
customElements.define("goa-icon", Icon);
|
|
8345
8385
|
/* libs/web-components/src/components/input/Input.svelte generated by Svelte v3.51.0 */
|
|
8346
8386
|
|
|
8347
|
-
function
|
|
8387
|
+
function create_if_block_4(ctx) {
|
|
8348
8388
|
let div;
|
|
8349
8389
|
let t;
|
|
8350
8390
|
return {
|
|
@@ -8362,7 +8402,7 @@ function create_if_block_7(ctx) {
|
|
|
8362
8402
|
},
|
|
8363
8403
|
|
|
8364
8404
|
p(ctx, dirty) {
|
|
8365
|
-
if (dirty
|
|
8405
|
+
if (dirty &
|
|
8366
8406
|
/*prefix*/
|
|
8367
8407
|
16384) set_data(t,
|
|
8368
8408
|
/*prefix*/
|
|
@@ -8374,10 +8414,10 @@ function create_if_block_7(ctx) {
|
|
|
8374
8414
|
}
|
|
8375
8415
|
|
|
8376
8416
|
};
|
|
8377
|
-
} // (
|
|
8417
|
+
} // (78:4) {#if leadingicon}
|
|
8378
8418
|
|
|
8379
8419
|
|
|
8380
|
-
function
|
|
8420
|
+
function create_if_block_3$2(ctx) {
|
|
8381
8421
|
let goa_icon;
|
|
8382
8422
|
return {
|
|
8383
8423
|
c() {
|
|
@@ -8394,7 +8434,7 @@ function create_if_block_6(ctx) {
|
|
|
8394
8434
|
},
|
|
8395
8435
|
|
|
8396
8436
|
p(ctx, dirty) {
|
|
8397
|
-
if (dirty
|
|
8437
|
+
if (dirty &
|
|
8398
8438
|
/*leadingicon*/
|
|
8399
8439
|
32) {
|
|
8400
8440
|
set_custom_element_data(goa_icon, "type",
|
|
@@ -8408,10 +8448,10 @@ function create_if_block_6(ctx) {
|
|
|
8408
8448
|
}
|
|
8409
8449
|
|
|
8410
8450
|
};
|
|
8411
|
-
} // (
|
|
8451
|
+
} // (108:4) {#if trailingicon && !handlesTrailingIconClick}
|
|
8412
8452
|
|
|
8413
8453
|
|
|
8414
|
-
function
|
|
8454
|
+
function create_if_block_2$4(ctx) {
|
|
8415
8455
|
let goa_icon;
|
|
8416
8456
|
return {
|
|
8417
8457
|
c() {
|
|
@@ -8429,7 +8469,7 @@ function create_if_block_5(ctx) {
|
|
|
8429
8469
|
},
|
|
8430
8470
|
|
|
8431
8471
|
p(ctx, dirty) {
|
|
8432
|
-
if (dirty
|
|
8472
|
+
if (dirty &
|
|
8433
8473
|
/*trailingicon*/
|
|
8434
8474
|
64) {
|
|
8435
8475
|
set_custom_element_data(goa_icon, "type",
|
|
@@ -8443,10 +8483,10 @@ function create_if_block_5(ctx) {
|
|
|
8443
8483
|
}
|
|
8444
8484
|
|
|
8445
8485
|
};
|
|
8446
|
-
} // (
|
|
8486
|
+
} // (118:4) {#if trailingicon && handlesTrailingIconClick}
|
|
8447
8487
|
|
|
8448
8488
|
|
|
8449
|
-
function
|
|
8489
|
+
function create_if_block_1$5(ctx) {
|
|
8450
8490
|
let goa_icon_button;
|
|
8451
8491
|
let mounted;
|
|
8452
8492
|
let dispose;
|
|
@@ -8455,7 +8495,7 @@ function create_if_block_4(ctx) {
|
|
|
8455
8495
|
goa_icon_button = element("goa-icon-button");
|
|
8456
8496
|
set_custom_element_data(goa_icon_button, "disabled",
|
|
8457
8497
|
/*isDisabled*/
|
|
8458
|
-
ctx[
|
|
8498
|
+
ctx[17]);
|
|
8459
8499
|
set_custom_element_data(goa_icon_button, "variant", "nocolor");
|
|
8460
8500
|
set_custom_element_data(goa_icon_button, "size", "medium");
|
|
8461
8501
|
set_custom_element_data(goa_icon_button, "icon",
|
|
@@ -8474,15 +8514,15 @@ function create_if_block_4(ctx) {
|
|
|
8474
8514
|
},
|
|
8475
8515
|
|
|
8476
8516
|
p(ctx, dirty) {
|
|
8477
|
-
if (dirty
|
|
8517
|
+
if (dirty &
|
|
8478
8518
|
/*isDisabled*/
|
|
8479
|
-
|
|
8519
|
+
131072) {
|
|
8480
8520
|
set_custom_element_data(goa_icon_button, "disabled",
|
|
8481
8521
|
/*isDisabled*/
|
|
8482
|
-
ctx[
|
|
8522
|
+
ctx[17]);
|
|
8483
8523
|
}
|
|
8484
8524
|
|
|
8485
|
-
if (dirty
|
|
8525
|
+
if (dirty &
|
|
8486
8526
|
/*trailingicon*/
|
|
8487
8527
|
64) {
|
|
8488
8528
|
set_custom_element_data(goa_icon_button, "icon",
|
|
@@ -8498,10 +8538,10 @@ function create_if_block_4(ctx) {
|
|
|
8498
8538
|
}
|
|
8499
8539
|
|
|
8500
8540
|
};
|
|
8501
|
-
} // (
|
|
8541
|
+
} // (129:4) {#if suffix}
|
|
8502
8542
|
|
|
8503
8543
|
|
|
8504
|
-
function
|
|
8544
|
+
function create_if_block$7(ctx) {
|
|
8505
8545
|
let span;
|
|
8506
8546
|
let t;
|
|
8507
8547
|
return {
|
|
@@ -8519,7 +8559,7 @@ function create_if_block_3$2(ctx) {
|
|
|
8519
8559
|
},
|
|
8520
8560
|
|
|
8521
8561
|
p(ctx, dirty) {
|
|
8522
|
-
if (dirty
|
|
8562
|
+
if (dirty &
|
|
8523
8563
|
/*suffix*/
|
|
8524
8564
|
32768) set_data(t,
|
|
8525
8565
|
/*suffix*/
|
|
@@ -8530,151 +8570,6 @@ function create_if_block_3$2(ctx) {
|
|
|
8530
8570
|
if (detaching) detach(span);
|
|
8531
8571
|
}
|
|
8532
8572
|
|
|
8533
|
-
};
|
|
8534
|
-
} // (139:2) {#if showCounter}
|
|
8535
|
-
|
|
8536
|
-
|
|
8537
|
-
function create_if_block$7(ctx) {
|
|
8538
|
-
let if_block_anchor;
|
|
8539
|
-
|
|
8540
|
-
function select_block_type(ctx, dirty) {
|
|
8541
|
-
if (
|
|
8542
|
-
/*maxcharcount*/
|
|
8543
|
-
ctx[16] > 0) return create_if_block_1$5;
|
|
8544
|
-
if (
|
|
8545
|
-
/*value*/
|
|
8546
|
-
ctx[0].length > 0) return create_if_block_2$4;
|
|
8547
|
-
}
|
|
8548
|
-
|
|
8549
|
-
let current_block_type = select_block_type(ctx);
|
|
8550
|
-
let if_block = current_block_type && current_block_type(ctx);
|
|
8551
|
-
return {
|
|
8552
|
-
c() {
|
|
8553
|
-
if (if_block) if_block.c();
|
|
8554
|
-
if_block_anchor = empty();
|
|
8555
|
-
},
|
|
8556
|
-
|
|
8557
|
-
m(target, anchor) {
|
|
8558
|
-
if (if_block) if_block.m(target, anchor);
|
|
8559
|
-
insert(target, if_block_anchor, anchor);
|
|
8560
|
-
},
|
|
8561
|
-
|
|
8562
|
-
p(ctx, dirty) {
|
|
8563
|
-
if (current_block_type === (current_block_type = select_block_type(ctx)) && if_block) {
|
|
8564
|
-
if_block.p(ctx, dirty);
|
|
8565
|
-
} else {
|
|
8566
|
-
if (if_block) if_block.d(1);
|
|
8567
|
-
if_block = current_block_type && current_block_type(ctx);
|
|
8568
|
-
|
|
8569
|
-
if (if_block) {
|
|
8570
|
-
if_block.c();
|
|
8571
|
-
if_block.m(if_block_anchor.parentNode, if_block_anchor);
|
|
8572
|
-
}
|
|
8573
|
-
}
|
|
8574
|
-
},
|
|
8575
|
-
|
|
8576
|
-
d(detaching) {
|
|
8577
|
-
if (if_block) {
|
|
8578
|
-
if_block.d(detaching);
|
|
8579
|
-
}
|
|
8580
|
-
|
|
8581
|
-
if (detaching) detach(if_block_anchor);
|
|
8582
|
-
}
|
|
8583
|
-
|
|
8584
|
-
};
|
|
8585
|
-
} // (144:31)
|
|
8586
|
-
|
|
8587
|
-
|
|
8588
|
-
function create_if_block_2$4(ctx) {
|
|
8589
|
-
let div;
|
|
8590
|
-
let t_value =
|
|
8591
|
-
/*value*/
|
|
8592
|
-
ctx[0].length + "";
|
|
8593
|
-
let t;
|
|
8594
|
-
return {
|
|
8595
|
-
c() {
|
|
8596
|
-
div = element("div");
|
|
8597
|
-
t = text(t_value);
|
|
8598
|
-
attr(div, "class", "counter");
|
|
8599
|
-
},
|
|
8600
|
-
|
|
8601
|
-
m(target, anchor) {
|
|
8602
|
-
insert(target, div, anchor);
|
|
8603
|
-
append(div, t);
|
|
8604
|
-
},
|
|
8605
|
-
|
|
8606
|
-
p(ctx, dirty) {
|
|
8607
|
-
if (dirty[0] &
|
|
8608
|
-
/*value*/
|
|
8609
|
-
1 && t_value !== (t_value =
|
|
8610
|
-
/*value*/
|
|
8611
|
-
ctx[0].length + "")) set_data(t, t_value);
|
|
8612
|
-
},
|
|
8613
|
-
|
|
8614
|
-
d(detaching) {
|
|
8615
|
-
if (detaching) detach(div);
|
|
8616
|
-
}
|
|
8617
|
-
|
|
8618
|
-
};
|
|
8619
|
-
} // (140:4) {#if maxcharcount > 0}
|
|
8620
|
-
|
|
8621
|
-
|
|
8622
|
-
function create_if_block_1$5(ctx) {
|
|
8623
|
-
let div;
|
|
8624
|
-
let t0_value =
|
|
8625
|
-
/*value*/
|
|
8626
|
-
ctx[0].length + "";
|
|
8627
|
-
let t0;
|
|
8628
|
-
let t1_value = `/${
|
|
8629
|
-
/*maxcharcount*/
|
|
8630
|
-
ctx[16]}` + "";
|
|
8631
|
-
let t1;
|
|
8632
|
-
return {
|
|
8633
|
-
c() {
|
|
8634
|
-
div = element("div");
|
|
8635
|
-
t0 = text(t0_value);
|
|
8636
|
-
t1 = text(t1_value);
|
|
8637
|
-
attr(div, "class", "counter");
|
|
8638
|
-
toggle_class(div, "counter-error",
|
|
8639
|
-
/*value*/
|
|
8640
|
-
ctx[0].length >
|
|
8641
|
-
/*maxcharcount*/
|
|
8642
|
-
ctx[16]);
|
|
8643
|
-
},
|
|
8644
|
-
|
|
8645
|
-
m(target, anchor) {
|
|
8646
|
-
insert(target, div, anchor);
|
|
8647
|
-
append(div, t0);
|
|
8648
|
-
append(div, t1);
|
|
8649
|
-
},
|
|
8650
|
-
|
|
8651
|
-
p(ctx, dirty) {
|
|
8652
|
-
if (dirty[0] &
|
|
8653
|
-
/*value*/
|
|
8654
|
-
1 && t0_value !== (t0_value =
|
|
8655
|
-
/*value*/
|
|
8656
|
-
ctx[0].length + "")) set_data(t0, t0_value);
|
|
8657
|
-
if (dirty[0] &
|
|
8658
|
-
/*maxcharcount*/
|
|
8659
|
-
65536 && t1_value !== (t1_value = `/${
|
|
8660
|
-
/*maxcharcount*/
|
|
8661
|
-
ctx[16]}` + "")) set_data(t1, t1_value);
|
|
8662
|
-
|
|
8663
|
-
if (dirty[0] &
|
|
8664
|
-
/*value, maxcharcount*/
|
|
8665
|
-
65537) {
|
|
8666
|
-
toggle_class(div, "counter-error",
|
|
8667
|
-
/*value*/
|
|
8668
|
-
ctx[0].length >
|
|
8669
|
-
/*maxcharcount*/
|
|
8670
|
-
ctx[16]);
|
|
8671
|
-
}
|
|
8672
|
-
},
|
|
8673
|
-
|
|
8674
|
-
d(detaching) {
|
|
8675
|
-
if (detaching) detach(div);
|
|
8676
|
-
}
|
|
8677
|
-
|
|
8678
8573
|
};
|
|
8679
8574
|
}
|
|
8680
8575
|
|
|
@@ -8691,32 +8586,28 @@ function create_fragment$f(ctx) {
|
|
|
8691
8586
|
let t3;
|
|
8692
8587
|
let t4;
|
|
8693
8588
|
let div0_class_value;
|
|
8694
|
-
let t5;
|
|
8695
8589
|
let div1_style_value;
|
|
8696
8590
|
let mounted;
|
|
8697
8591
|
let dispose;
|
|
8698
8592
|
let if_block0 =
|
|
8699
8593
|
/*prefix*/
|
|
8700
|
-
ctx[14] &&
|
|
8594
|
+
ctx[14] && create_if_block_4(ctx);
|
|
8701
8595
|
let if_block1 =
|
|
8702
8596
|
/*leadingicon*/
|
|
8703
|
-
ctx[5] &&
|
|
8597
|
+
ctx[5] && create_if_block_3$2(ctx);
|
|
8704
8598
|
let if_block2 =
|
|
8705
8599
|
/*trailingicon*/
|
|
8706
8600
|
ctx[6] && !
|
|
8707
8601
|
/*handlesTrailingIconClick*/
|
|
8708
|
-
ctx[
|
|
8602
|
+
ctx[20] && create_if_block_2$4(ctx);
|
|
8709
8603
|
let if_block3 =
|
|
8710
8604
|
/*trailingicon*/
|
|
8711
8605
|
ctx[6] &&
|
|
8712
8606
|
/*handlesTrailingIconClick*/
|
|
8713
|
-
ctx[
|
|
8607
|
+
ctx[20] && create_if_block_1$5(ctx);
|
|
8714
8608
|
let if_block4 =
|
|
8715
8609
|
/*suffix*/
|
|
8716
|
-
ctx[15] &&
|
|
8717
|
-
let if_block5 =
|
|
8718
|
-
/*showCounter*/
|
|
8719
|
-
ctx[18] && create_if_block$7(ctx);
|
|
8610
|
+
ctx[15] && create_if_block$7(ctx);
|
|
8720
8611
|
return {
|
|
8721
8612
|
c() {
|
|
8722
8613
|
div1 = element("div");
|
|
@@ -8732,8 +8623,6 @@ function create_fragment$f(ctx) {
|
|
|
8732
8623
|
if (if_block3) if_block3.c();
|
|
8733
8624
|
t4 = space();
|
|
8734
8625
|
if (if_block4) if_block4.c();
|
|
8735
|
-
t5 = space();
|
|
8736
|
-
if (if_block5) if_block5.c();
|
|
8737
8626
|
this.c = noop;
|
|
8738
8627
|
attr(input, "class", input_class_value = `input--${
|
|
8739
8628
|
/*variant*/
|
|
@@ -8743,10 +8632,10 @@ function create_fragment$f(ctx) {
|
|
|
8743
8632
|
ctx[6] ? "-0.5rem" : "0"}`);
|
|
8744
8633
|
input.readOnly =
|
|
8745
8634
|
/*isReadonly*/
|
|
8746
|
-
ctx[
|
|
8635
|
+
ctx[19];
|
|
8747
8636
|
input.disabled =
|
|
8748
8637
|
/*isDisabled*/
|
|
8749
|
-
ctx[
|
|
8638
|
+
ctx[17];
|
|
8750
8639
|
attr(input, "data-testid",
|
|
8751
8640
|
/*testid*/
|
|
8752
8641
|
ctx[8]);
|
|
@@ -8784,7 +8673,7 @@ function create_fragment$f(ctx) {
|
|
|
8784
8673
|
goa-input
|
|
8785
8674
|
${
|
|
8786
8675
|
/*isDisabled*/
|
|
8787
|
-
ctx[
|
|
8676
|
+
ctx[17] ? "goa-input--disabled" : ""}
|
|
8788
8677
|
variant--${
|
|
8789
8678
|
/*variant*/
|
|
8790
8679
|
ctx[7]}
|
|
@@ -8794,7 +8683,7 @@ function create_fragment$f(ctx) {
|
|
|
8794
8683
|
`);
|
|
8795
8684
|
toggle_class(div0, "error",
|
|
8796
8685
|
/*isError*/
|
|
8797
|
-
ctx[
|
|
8686
|
+
ctx[18]);
|
|
8798
8687
|
attr(div1, "class", "container");
|
|
8799
8688
|
attr(div1, "style", div1_style_value = `
|
|
8800
8689
|
--width: ${
|
|
@@ -8813,34 +8702,32 @@ function create_fragment$f(ctx) {
|
|
|
8813
8702
|
append(div0, input);
|
|
8814
8703
|
/*input_binding*/
|
|
8815
8704
|
|
|
8816
|
-
ctx[
|
|
8705
|
+
ctx[28](input);
|
|
8817
8706
|
append(div0, t2);
|
|
8818
8707
|
if (if_block2) if_block2.m(div0, null);
|
|
8819
8708
|
append(div0, t3);
|
|
8820
8709
|
if (if_block3) if_block3.m(div0, null);
|
|
8821
8710
|
append(div0, t4);
|
|
8822
8711
|
if (if_block4) if_block4.m(div0, null);
|
|
8823
|
-
append(div1, t5);
|
|
8824
|
-
if (if_block5) if_block5.m(div1, null);
|
|
8825
8712
|
|
|
8826
8713
|
if (!mounted) {
|
|
8827
8714
|
dispose = [listen(input, "keyup",
|
|
8828
8715
|
/*onKeyUp*/
|
|
8829
|
-
ctx[
|
|
8716
|
+
ctx[21]), listen(input, "change",
|
|
8830
8717
|
/*onKeyUp*/
|
|
8831
|
-
ctx[
|
|
8718
|
+
ctx[21])];
|
|
8832
8719
|
mounted = true;
|
|
8833
8720
|
}
|
|
8834
8721
|
},
|
|
8835
8722
|
|
|
8836
|
-
p(ctx, dirty) {
|
|
8723
|
+
p(ctx, [dirty]) {
|
|
8837
8724
|
if (
|
|
8838
8725
|
/*prefix*/
|
|
8839
8726
|
ctx[14]) {
|
|
8840
8727
|
if (if_block0) {
|
|
8841
8728
|
if_block0.p(ctx, dirty);
|
|
8842
8729
|
} else {
|
|
8843
|
-
if_block0 =
|
|
8730
|
+
if_block0 = create_if_block_4(ctx);
|
|
8844
8731
|
if_block0.c();
|
|
8845
8732
|
if_block0.m(div0, t0);
|
|
8846
8733
|
}
|
|
@@ -8855,7 +8742,7 @@ function create_fragment$f(ctx) {
|
|
|
8855
8742
|
if (if_block1) {
|
|
8856
8743
|
if_block1.p(ctx, dirty);
|
|
8857
8744
|
} else {
|
|
8858
|
-
if_block1 =
|
|
8745
|
+
if_block1 = create_if_block_3$2(ctx);
|
|
8859
8746
|
if_block1.c();
|
|
8860
8747
|
if_block1.m(div0, t1);
|
|
8861
8748
|
}
|
|
@@ -8864,7 +8751,7 @@ function create_fragment$f(ctx) {
|
|
|
8864
8751
|
if_block1 = null;
|
|
8865
8752
|
}
|
|
8866
8753
|
|
|
8867
|
-
if (dirty
|
|
8754
|
+
if (dirty &
|
|
8868
8755
|
/*variant*/
|
|
8869
8756
|
128 && input_class_value !== (input_class_value = `input--${
|
|
8870
8757
|
/*variant*/
|
|
@@ -8872,7 +8759,7 @@ function create_fragment$f(ctx) {
|
|
|
8872
8759
|
attr(input, "class", input_class_value);
|
|
8873
8760
|
}
|
|
8874
8761
|
|
|
8875
|
-
if (dirty
|
|
8762
|
+
if (dirty &
|
|
8876
8763
|
/*trailingicon*/
|
|
8877
8764
|
64 && input_style_value !== (input_style_value = `--search-icon-offset: ${
|
|
8878
8765
|
/*trailingicon*/
|
|
@@ -8880,23 +8767,23 @@ function create_fragment$f(ctx) {
|
|
|
8880
8767
|
attr(input, "style", input_style_value);
|
|
8881
8768
|
}
|
|
8882
8769
|
|
|
8883
|
-
if (dirty
|
|
8770
|
+
if (dirty &
|
|
8884
8771
|
/*isReadonly*/
|
|
8885
|
-
|
|
8772
|
+
524288) {
|
|
8886
8773
|
input.readOnly =
|
|
8887
8774
|
/*isReadonly*/
|
|
8888
|
-
ctx[
|
|
8775
|
+
ctx[19];
|
|
8889
8776
|
}
|
|
8890
8777
|
|
|
8891
|
-
if (dirty
|
|
8778
|
+
if (dirty &
|
|
8892
8779
|
/*isDisabled*/
|
|
8893
|
-
|
|
8780
|
+
131072) {
|
|
8894
8781
|
input.disabled =
|
|
8895
8782
|
/*isDisabled*/
|
|
8896
|
-
ctx[
|
|
8783
|
+
ctx[17];
|
|
8897
8784
|
}
|
|
8898
8785
|
|
|
8899
|
-
if (dirty
|
|
8786
|
+
if (dirty &
|
|
8900
8787
|
/*testid*/
|
|
8901
8788
|
256) {
|
|
8902
8789
|
attr(input, "data-testid",
|
|
@@ -8904,7 +8791,7 @@ function create_fragment$f(ctx) {
|
|
|
8904
8791
|
ctx[8]);
|
|
8905
8792
|
}
|
|
8906
8793
|
|
|
8907
|
-
if (dirty
|
|
8794
|
+
if (dirty &
|
|
8908
8795
|
/*autocapitalize*/
|
|
8909
8796
|
8) {
|
|
8910
8797
|
attr(input, "autocapitalize",
|
|
@@ -8912,7 +8799,7 @@ function create_fragment$f(ctx) {
|
|
|
8912
8799
|
ctx[3]);
|
|
8913
8800
|
}
|
|
8914
8801
|
|
|
8915
|
-
if (dirty
|
|
8802
|
+
if (dirty &
|
|
8916
8803
|
/*name*/
|
|
8917
8804
|
4) {
|
|
8918
8805
|
attr(input, "name",
|
|
@@ -8920,7 +8807,7 @@ function create_fragment$f(ctx) {
|
|
|
8920
8807
|
ctx[2]);
|
|
8921
8808
|
}
|
|
8922
8809
|
|
|
8923
|
-
if (dirty
|
|
8810
|
+
if (dirty &
|
|
8924
8811
|
/*type*/
|
|
8925
8812
|
2) {
|
|
8926
8813
|
attr(input, "type",
|
|
@@ -8928,7 +8815,7 @@ function create_fragment$f(ctx) {
|
|
|
8928
8815
|
ctx[1]);
|
|
8929
8816
|
}
|
|
8930
8817
|
|
|
8931
|
-
if (dirty
|
|
8818
|
+
if (dirty &
|
|
8932
8819
|
/*value*/
|
|
8933
8820
|
1 && input.value !==
|
|
8934
8821
|
/*value*/
|
|
@@ -8938,7 +8825,7 @@ function create_fragment$f(ctx) {
|
|
|
8938
8825
|
ctx[0];
|
|
8939
8826
|
}
|
|
8940
8827
|
|
|
8941
|
-
if (dirty
|
|
8828
|
+
if (dirty &
|
|
8942
8829
|
/*placeholder*/
|
|
8943
8830
|
16) {
|
|
8944
8831
|
attr(input, "placeholder",
|
|
@@ -8946,7 +8833,7 @@ function create_fragment$f(ctx) {
|
|
|
8946
8833
|
ctx[4]);
|
|
8947
8834
|
}
|
|
8948
8835
|
|
|
8949
|
-
if (dirty
|
|
8836
|
+
if (dirty &
|
|
8950
8837
|
/*min*/
|
|
8951
8838
|
2048) {
|
|
8952
8839
|
attr(input, "min",
|
|
@@ -8954,7 +8841,7 @@ function create_fragment$f(ctx) {
|
|
|
8954
8841
|
ctx[11]);
|
|
8955
8842
|
}
|
|
8956
8843
|
|
|
8957
|
-
if (dirty
|
|
8844
|
+
if (dirty &
|
|
8958
8845
|
/*max*/
|
|
8959
8846
|
4096) {
|
|
8960
8847
|
attr(input, "max",
|
|
@@ -8962,7 +8849,7 @@ function create_fragment$f(ctx) {
|
|
|
8962
8849
|
ctx[12]);
|
|
8963
8850
|
}
|
|
8964
8851
|
|
|
8965
|
-
if (dirty
|
|
8852
|
+
if (dirty &
|
|
8966
8853
|
/*step*/
|
|
8967
8854
|
8192) {
|
|
8968
8855
|
attr(input, "step",
|
|
@@ -8970,7 +8857,7 @@ function create_fragment$f(ctx) {
|
|
|
8970
8857
|
ctx[13]);
|
|
8971
8858
|
}
|
|
8972
8859
|
|
|
8973
|
-
if (dirty
|
|
8860
|
+
if (dirty &
|
|
8974
8861
|
/*arialabel, name*/
|
|
8975
8862
|
1028 && input_aria_label_value !== (input_aria_label_value =
|
|
8976
8863
|
/*arialabel*/
|
|
@@ -8984,11 +8871,11 @@ function create_fragment$f(ctx) {
|
|
|
8984
8871
|
/*trailingicon*/
|
|
8985
8872
|
ctx[6] && !
|
|
8986
8873
|
/*handlesTrailingIconClick*/
|
|
8987
|
-
ctx[
|
|
8874
|
+
ctx[20]) {
|
|
8988
8875
|
if (if_block2) {
|
|
8989
8876
|
if_block2.p(ctx, dirty);
|
|
8990
8877
|
} else {
|
|
8991
|
-
if_block2 =
|
|
8878
|
+
if_block2 = create_if_block_2$4(ctx);
|
|
8992
8879
|
if_block2.c();
|
|
8993
8880
|
if_block2.m(div0, t3);
|
|
8994
8881
|
}
|
|
@@ -9001,11 +8888,11 @@ function create_fragment$f(ctx) {
|
|
|
9001
8888
|
/*trailingicon*/
|
|
9002
8889
|
ctx[6] &&
|
|
9003
8890
|
/*handlesTrailingIconClick*/
|
|
9004
|
-
ctx[
|
|
8891
|
+
ctx[20]) {
|
|
9005
8892
|
if (if_block3) {
|
|
9006
8893
|
if_block3.p(ctx, dirty);
|
|
9007
8894
|
} else {
|
|
9008
|
-
if_block3 =
|
|
8895
|
+
if_block3 = create_if_block_1$5(ctx);
|
|
9009
8896
|
if_block3.c();
|
|
9010
8897
|
if_block3.m(div0, t4);
|
|
9011
8898
|
}
|
|
@@ -9020,7 +8907,7 @@ function create_fragment$f(ctx) {
|
|
|
9020
8907
|
if (if_block4) {
|
|
9021
8908
|
if_block4.p(ctx, dirty);
|
|
9022
8909
|
} else {
|
|
9023
|
-
if_block4 =
|
|
8910
|
+
if_block4 = create_if_block$7(ctx);
|
|
9024
8911
|
if_block4.c();
|
|
9025
8912
|
if_block4.m(div0, null);
|
|
9026
8913
|
}
|
|
@@ -9029,13 +8916,13 @@ function create_fragment$f(ctx) {
|
|
|
9029
8916
|
if_block4 = null;
|
|
9030
8917
|
}
|
|
9031
8918
|
|
|
9032
|
-
if (dirty
|
|
8919
|
+
if (dirty &
|
|
9033
8920
|
/*isDisabled, variant, type*/
|
|
9034
|
-
|
|
8921
|
+
131202 && div0_class_value !== (div0_class_value = `
|
|
9035
8922
|
goa-input
|
|
9036
8923
|
${
|
|
9037
8924
|
/*isDisabled*/
|
|
9038
|
-
ctx[
|
|
8925
|
+
ctx[17] ? "goa-input--disabled" : ""}
|
|
9039
8926
|
variant--${
|
|
9040
8927
|
/*variant*/
|
|
9041
8928
|
ctx[7]}
|
|
@@ -9046,30 +8933,15 @@ function create_fragment$f(ctx) {
|
|
|
9046
8933
|
attr(div0, "class", div0_class_value);
|
|
9047
8934
|
}
|
|
9048
8935
|
|
|
9049
|
-
if (dirty
|
|
8936
|
+
if (dirty &
|
|
9050
8937
|
/*isDisabled, variant, type, isError*/
|
|
9051
|
-
|
|
8938
|
+
393346) {
|
|
9052
8939
|
toggle_class(div0, "error",
|
|
9053
8940
|
/*isError*/
|
|
9054
|
-
ctx[
|
|
9055
|
-
}
|
|
9056
|
-
|
|
9057
|
-
if (
|
|
9058
|
-
/*showCounter*/
|
|
9059
|
-
ctx[18]) {
|
|
9060
|
-
if (if_block5) {
|
|
9061
|
-
if_block5.p(ctx, dirty);
|
|
9062
|
-
} else {
|
|
9063
|
-
if_block5 = create_if_block$7(ctx);
|
|
9064
|
-
if_block5.c();
|
|
9065
|
-
if_block5.m(div1, null);
|
|
9066
|
-
}
|
|
9067
|
-
} else if (if_block5) {
|
|
9068
|
-
if_block5.d(1);
|
|
9069
|
-
if_block5 = null;
|
|
8941
|
+
ctx[18]);
|
|
9070
8942
|
}
|
|
9071
8943
|
|
|
9072
|
-
if (dirty
|
|
8944
|
+
if (dirty &
|
|
9073
8945
|
/*width*/
|
|
9074
8946
|
512 && div1_style_value !== (div1_style_value = `
|
|
9075
8947
|
--width: ${
|
|
@@ -9089,11 +8961,10 @@ function create_fragment$f(ctx) {
|
|
|
9089
8961
|
if (if_block1) if_block1.d();
|
|
9090
8962
|
/*input_binding*/
|
|
9091
8963
|
|
|
9092
|
-
ctx[
|
|
8964
|
+
ctx[28](null);
|
|
9093
8965
|
if (if_block2) if_block2.d();
|
|
9094
8966
|
if (if_block3) if_block3.d();
|
|
9095
8967
|
if (if_block4) if_block4.d();
|
|
9096
|
-
if (if_block5) if_block5.d();
|
|
9097
8968
|
mounted = false;
|
|
9098
8969
|
run_all(dispose);
|
|
9099
8970
|
}
|
|
@@ -9113,7 +8984,6 @@ function instance$d($$self, $$props, $$invalidate) {
|
|
|
9113
8984
|
let isReadonly;
|
|
9114
8985
|
let isError;
|
|
9115
8986
|
let isDisabled;
|
|
9116
|
-
let showCounter;
|
|
9117
8987
|
let {
|
|
9118
8988
|
type = "text"
|
|
9119
8989
|
} = $$props;
|
|
@@ -9177,12 +9047,6 @@ function instance$d($$self, $$props, $$invalidate) {
|
|
|
9177
9047
|
let {
|
|
9178
9048
|
suffix = ""
|
|
9179
9049
|
} = $$props;
|
|
9180
|
-
let {
|
|
9181
|
-
showcounter = "false"
|
|
9182
|
-
} = $$props;
|
|
9183
|
-
let {
|
|
9184
|
-
maxcharcount = 0
|
|
9185
|
-
} = $$props;
|
|
9186
9050
|
let inputEl;
|
|
9187
9051
|
|
|
9188
9052
|
function onKeyUp(e) {
|
|
@@ -9201,7 +9065,7 @@ function instance$d($$self, $$props, $$invalidate) {
|
|
|
9201
9065
|
function input_binding($$value) {
|
|
9202
9066
|
binding_callbacks[$$value ? 'unshift' : 'push'](() => {
|
|
9203
9067
|
inputEl = $$value;
|
|
9204
|
-
$$invalidate(
|
|
9068
|
+
$$invalidate(16, inputEl);
|
|
9205
9069
|
});
|
|
9206
9070
|
}
|
|
9207
9071
|
|
|
@@ -9214,11 +9078,11 @@ function instance$d($$self, $$props, $$invalidate) {
|
|
|
9214
9078
|
if ('leadingicon' in $$props) $$invalidate(5, leadingicon = $$props.leadingicon);
|
|
9215
9079
|
if ('trailingicon' in $$props) $$invalidate(6, trailingicon = $$props.trailingicon);
|
|
9216
9080
|
if ('variant' in $$props) $$invalidate(7, variant = $$props.variant);
|
|
9217
|
-
if ('disabled' in $$props) $$invalidate(
|
|
9218
|
-
if ('handletrailingiconclick' in $$props) $$invalidate(
|
|
9219
|
-
if ('focused' in $$props) $$invalidate(
|
|
9220
|
-
if ('readonly' in $$props) $$invalidate(
|
|
9221
|
-
if ('error' in $$props) $$invalidate(
|
|
9081
|
+
if ('disabled' in $$props) $$invalidate(22, disabled = $$props.disabled);
|
|
9082
|
+
if ('handletrailingiconclick' in $$props) $$invalidate(23, handletrailingiconclick = $$props.handletrailingiconclick);
|
|
9083
|
+
if ('focused' in $$props) $$invalidate(24, focused = $$props.focused);
|
|
9084
|
+
if ('readonly' in $$props) $$invalidate(25, readonly = $$props.readonly);
|
|
9085
|
+
if ('error' in $$props) $$invalidate(26, error = $$props.error);
|
|
9222
9086
|
if ('testid' in $$props) $$invalidate(8, testid = $$props.testid);
|
|
9223
9087
|
if ('width' in $$props) $$invalidate(9, width = $$props.width);
|
|
9224
9088
|
if ('arialabel' in $$props) $$invalidate(10, arialabel = $$props.arialabel);
|
|
@@ -9227,58 +9091,50 @@ function instance$d($$self, $$props, $$invalidate) {
|
|
|
9227
9091
|
if ('step' in $$props) $$invalidate(13, step = $$props.step);
|
|
9228
9092
|
if ('prefix' in $$props) $$invalidate(14, prefix = $$props.prefix);
|
|
9229
9093
|
if ('suffix' in $$props) $$invalidate(15, suffix = $$props.suffix);
|
|
9230
|
-
if ('showcounter' in $$props) $$invalidate(29, showcounter = $$props.showcounter);
|
|
9231
|
-
if ('maxcharcount' in $$props) $$invalidate(16, maxcharcount = $$props.maxcharcount);
|
|
9232
9094
|
};
|
|
9233
9095
|
|
|
9234
9096
|
$$self.$$.update = () => {
|
|
9235
|
-
if ($$self.$$.dirty
|
|
9097
|
+
if ($$self.$$.dirty &
|
|
9236
9098
|
/*handletrailingiconclick*/
|
|
9237
|
-
|
|
9238
|
-
$$invalidate(
|
|
9099
|
+
8388608) {
|
|
9100
|
+
$$invalidate(20, handlesTrailingIconClick = toBoolean(handletrailingiconclick));
|
|
9239
9101
|
}
|
|
9240
9102
|
|
|
9241
|
-
if ($$self.$$.dirty
|
|
9103
|
+
if ($$self.$$.dirty &
|
|
9242
9104
|
/*focused*/
|
|
9243
|
-
|
|
9244
|
-
$$invalidate(
|
|
9105
|
+
16777216) {
|
|
9106
|
+
$$invalidate(27, isFocused = toBoolean(focused));
|
|
9245
9107
|
}
|
|
9246
9108
|
|
|
9247
|
-
if ($$self.$$.dirty
|
|
9109
|
+
if ($$self.$$.dirty &
|
|
9248
9110
|
/*readonly*/
|
|
9249
|
-
|
|
9250
|
-
$$invalidate(
|
|
9111
|
+
33554432) {
|
|
9112
|
+
$$invalidate(19, isReadonly = toBoolean(readonly));
|
|
9251
9113
|
}
|
|
9252
9114
|
|
|
9253
|
-
if ($$self.$$.dirty
|
|
9115
|
+
if ($$self.$$.dirty &
|
|
9254
9116
|
/*error*/
|
|
9255
|
-
|
|
9256
|
-
$$invalidate(
|
|
9117
|
+
67108864) {
|
|
9118
|
+
$$invalidate(18, isError = toBoolean(error));
|
|
9257
9119
|
}
|
|
9258
9120
|
|
|
9259
|
-
if ($$self.$$.dirty
|
|
9121
|
+
if ($$self.$$.dirty &
|
|
9260
9122
|
/*disabled*/
|
|
9261
|
-
|
|
9262
|
-
$$invalidate(
|
|
9263
|
-
}
|
|
9264
|
-
|
|
9265
|
-
if ($$self.$$.dirty[0] &
|
|
9266
|
-
/*showcounter*/
|
|
9267
|
-
536870912) {
|
|
9268
|
-
$$invalidate(18, showCounter = toBoolean(showcounter));
|
|
9123
|
+
4194304) {
|
|
9124
|
+
$$invalidate(17, isDisabled = toBoolean(disabled));
|
|
9269
9125
|
}
|
|
9270
9126
|
|
|
9271
|
-
if ($$self.$$.dirty
|
|
9127
|
+
if ($$self.$$.dirty &
|
|
9272
9128
|
/*isFocused, inputEl*/
|
|
9273
|
-
|
|
9129
|
+
134283264) {
|
|
9274
9130
|
if (isFocused && inputEl) {
|
|
9275
9131
|
setTimeout(() => inputEl.focus(), 1);
|
|
9276
9132
|
}
|
|
9277
9133
|
}
|
|
9278
9134
|
|
|
9279
|
-
if ($$self.$$.dirty
|
|
9135
|
+
if ($$self.$$.dirty &
|
|
9280
9136
|
/*inputEl, type*/
|
|
9281
|
-
|
|
9137
|
+
65538) {
|
|
9282
9138
|
if (inputEl && type === "search") {
|
|
9283
9139
|
inputEl.addEventListener("search", e => {
|
|
9284
9140
|
onKeyUp(e);
|
|
@@ -9287,13 +9143,13 @@ function instance$d($$self, $$props, $$invalidate) {
|
|
|
9287
9143
|
}
|
|
9288
9144
|
};
|
|
9289
9145
|
|
|
9290
|
-
return [value, type, name, autocapitalize, placeholder, leadingicon, trailingicon, variant, testid, width, arialabel, min, max, step, prefix, suffix,
|
|
9146
|
+
return [value, type, name, autocapitalize, placeholder, leadingicon, trailingicon, variant, testid, width, arialabel, min, max, step, prefix, suffix, inputEl, isDisabled, isError, isReadonly, handlesTrailingIconClick, onKeyUp, disabled, handletrailingiconclick, focused, readonly, error, isFocused, input_binding];
|
|
9291
9147
|
}
|
|
9292
9148
|
|
|
9293
9149
|
class Input extends SvelteElement {
|
|
9294
9150
|
constructor(options) {
|
|
9295
9151
|
super();
|
|
9296
|
-
this.shadowRoot.innerHTML = `<style>:host{box-sizing:border-box}.container{position:relative;width:100%}@media(min-width: 640px){.container{width:var(--width)}}.goa-input,.goa-input *{box-sizing:border-box}.goa-input{box-sizing:border-box;outline:none;transition:box-shadow 0.1s ease-in;border:1px solid var(--color-gray-600);border-radius:var(--input-border-radius);background:white;display:inline-flex;align-items:stretch;vertical-align:middle;min-width:100%}.goa-input:hover{border-color:var(--goa-color-interactive--hover)}.goa-input:active,.goa-input:focus,.goa-input:focus-within{box-shadow:0 0 0 3px var(--goa-color-interactive--focus)}.goa-input.type--range{border:none}.goa-input.type--range:active,.goa-input.type--range:focus,.goa-input.type--range:focus-within{box-shadow:none}.goa-input-leading-icon{margin-left:0.5rem}.goa-input-trailing-icon{margin-right:0.5rem}input{display:inline-block;color:var(--goa-color-text);font-size:var(--input-font-size);padding:var(--input-padding);line-height:calc(40px - calc(var(--input-padding) * 2));background-color:transparent;width:0;flex:1 1 auto}input[type=text],input[type=date],input[type="datetime-local"],input[type=number]{font-family:var(--font-family)}input[readonly]{cursor:pointer}.goa-input-leading-icon+input{padding-left:0.5rem}input,input:focus,input:hover,input:active{outline:none;border:none}.goa-input--disabled,.goa-input--disabled:hover,.goa-input--disabled:active,.goa-input--disabled:focus{background-color:var(--color-gray-100);border-color:var(--color-gray-200);cursor:default;box-shadow:none}.goa-input--disabled input,.goa-input--disabled input:hover,.goa-input--disabled input:active,.goa-input--disabled input:focus{color:var(--goa-color-text-secondary)}.goa-input--disabled input:hover{cursor:default !important}.prefix,.suffix{background-color:var(--color-gray-100);padding:0 0.75rem;display:flex;align-items:center}.prefix{border-top-left-radius:var(--input-border-radius);border-bottom-left-radius:var(--input-border-radius);border-right:1px solid var(--color-gray-600)}.suffix{border-top-right-radius:var(--input-border-radius);border-bottom-right-radius:var(--input-border-radius);border-left:1px solid var(--color-gray-600)}input.input--goa{display:block;border:none;flex:1 1 auto}.variant--bare{border:none}.variant--bare:focus,.variant--bare:active,.variant--bare:focus-within{box-shadow:none}.
|
|
9152
|
+
this.shadowRoot.innerHTML = `<style>:host{box-sizing:border-box}.container{position:relative;width:100%}@media(min-width: 640px){.container{width:var(--width)}}.goa-input,.goa-input *{box-sizing:border-box}.goa-input{box-sizing:border-box;outline:none;transition:box-shadow 0.1s ease-in;border:1px solid var(--color-gray-600);border-radius:var(--input-border-radius);background:white;display:inline-flex;align-items:stretch;vertical-align:middle;min-width:100%}.goa-input:hover{border-color:var(--goa-color-interactive--hover)}.goa-input:active,.goa-input:focus,.goa-input:focus-within{box-shadow:0 0 0 3px var(--goa-color-interactive--focus)}.goa-input.type--range{border:none}.goa-input.type--range:active,.goa-input.type--range:focus,.goa-input.type--range:focus-within{box-shadow:none}.goa-input-leading-icon{margin-left:0.5rem}.goa-input-trailing-icon{margin-right:0.5rem}input{display:inline-block;color:var(--goa-color-text);font-size:var(--input-font-size);padding:var(--input-padding);line-height:calc(40px - calc(var(--input-padding) * 2));background-color:transparent;width:0;flex:1 1 auto}input[type=text],input[type=date],input[type="datetime-local"],input[type=number]{font-family:var(--font-family)}input[readonly]{cursor:pointer}.goa-input-leading-icon+input{padding-left:0.5rem}input,input:focus,input:hover,input:active{outline:none;border:none}.goa-input--disabled,.goa-input--disabled:hover,.goa-input--disabled:active,.goa-input--disabled:focus{background-color:var(--color-gray-100);border-color:var(--color-gray-200);cursor:default;box-shadow:none}.goa-input--disabled input,.goa-input--disabled input:hover,.goa-input--disabled input:active,.goa-input--disabled input:focus{color:var(--goa-color-text-secondary)}.goa-input--disabled input:hover{cursor:default !important}.prefix,.suffix{background-color:var(--color-gray-100);padding:0 0.75rem;display:flex;align-items:center}.prefix{border-top-left-radius:var(--input-border-radius);border-bottom-left-radius:var(--input-border-radius);border-right:1px solid var(--color-gray-600)}.suffix{border-top-right-radius:var(--input-border-radius);border-bottom-right-radius:var(--input-border-radius);border-left:1px solid var(--color-gray-600)}input.input--goa{display:block;border:none;flex:1 1 auto}.variant--bare{border:none}.variant--bare:focus,.variant--bare:active,.variant--bare:focus-within{box-shadow:none}.error:hover,.error:focus,.error{border:2px solid var(--goa-color-interactive--error)}input[type="search" i]:enabled:read-write:-webkit-any(:focus, :hover)::-webkit-search-cancel-button{position:relative;right:var(--search-icon-offset);cursor:pointer;-webkit-appearance:none;height:1.2rem;width:1.2rem;background:url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512"><path fill="%23333" d="M405 136.798L375.202 107 256 226.202 136.798 107 107 136.798 226.202 256 107 375.202 136.798 405 256 285.798 375.202 405 405 375.202 285.798 256z"/></svg>')
|
|
9297
9153
|
center center no-repeat}</style>`;
|
|
9298
9154
|
init(this, {
|
|
9299
9155
|
target: this.shadowRoot,
|
|
@@ -9308,11 +9164,11 @@ class Input extends SvelteElement {
|
|
|
9308
9164
|
leadingicon: 5,
|
|
9309
9165
|
trailingicon: 6,
|
|
9310
9166
|
variant: 7,
|
|
9311
|
-
disabled:
|
|
9312
|
-
handletrailingiconclick:
|
|
9313
|
-
focused:
|
|
9314
|
-
readonly:
|
|
9315
|
-
error:
|
|
9167
|
+
disabled: 22,
|
|
9168
|
+
handletrailingiconclick: 23,
|
|
9169
|
+
focused: 24,
|
|
9170
|
+
readonly: 25,
|
|
9171
|
+
error: 26,
|
|
9316
9172
|
testid: 8,
|
|
9317
9173
|
width: 9,
|
|
9318
9174
|
arialabel: 10,
|
|
@@ -9320,10 +9176,8 @@ class Input extends SvelteElement {
|
|
|
9320
9176
|
max: 12,
|
|
9321
9177
|
step: 13,
|
|
9322
9178
|
prefix: 14,
|
|
9323
|
-
suffix: 15
|
|
9324
|
-
|
|
9325
|
-
maxcharcount: 16
|
|
9326
|
-
}, null, [-1, -1]);
|
|
9179
|
+
suffix: 15
|
|
9180
|
+
}, null);
|
|
9327
9181
|
|
|
9328
9182
|
if (options) {
|
|
9329
9183
|
if (options.target) {
|
|
@@ -9338,7 +9192,7 @@ class Input extends SvelteElement {
|
|
|
9338
9192
|
}
|
|
9339
9193
|
|
|
9340
9194
|
static get observedAttributes() {
|
|
9341
|
-
return ["type", "name", "value", "autocapitalize", "placeholder", "leadingicon", "trailingicon", "variant", "disabled", "handletrailingiconclick", "focused", "readonly", "error", "testid", "width", "arialabel", "min", "max", "step", "prefix", "suffix"
|
|
9195
|
+
return ["type", "name", "value", "autocapitalize", "placeholder", "leadingicon", "trailingicon", "variant", "disabled", "handletrailingiconclick", "focused", "readonly", "error", "testid", "width", "arialabel", "min", "max", "step", "prefix", "suffix"];
|
|
9342
9196
|
}
|
|
9343
9197
|
|
|
9344
9198
|
get type() {
|
|
@@ -9430,7 +9284,7 @@ class Input extends SvelteElement {
|
|
|
9430
9284
|
}
|
|
9431
9285
|
|
|
9432
9286
|
get disabled() {
|
|
9433
|
-
return this.$$.ctx[
|
|
9287
|
+
return this.$$.ctx[22];
|
|
9434
9288
|
}
|
|
9435
9289
|
|
|
9436
9290
|
set disabled(disabled) {
|
|
@@ -9441,7 +9295,7 @@ class Input extends SvelteElement {
|
|
|
9441
9295
|
}
|
|
9442
9296
|
|
|
9443
9297
|
get handletrailingiconclick() {
|
|
9444
|
-
return this.$$.ctx[
|
|
9298
|
+
return this.$$.ctx[23];
|
|
9445
9299
|
}
|
|
9446
9300
|
|
|
9447
9301
|
set handletrailingiconclick(handletrailingiconclick) {
|
|
@@ -9452,7 +9306,7 @@ class Input extends SvelteElement {
|
|
|
9452
9306
|
}
|
|
9453
9307
|
|
|
9454
9308
|
get focused() {
|
|
9455
|
-
return this.$$.ctx[
|
|
9309
|
+
return this.$$.ctx[24];
|
|
9456
9310
|
}
|
|
9457
9311
|
|
|
9458
9312
|
set focused(focused) {
|
|
@@ -9463,7 +9317,7 @@ class Input extends SvelteElement {
|
|
|
9463
9317
|
}
|
|
9464
9318
|
|
|
9465
9319
|
get readonly() {
|
|
9466
|
-
return this.$$.ctx[
|
|
9320
|
+
return this.$$.ctx[25];
|
|
9467
9321
|
}
|
|
9468
9322
|
|
|
9469
9323
|
set readonly(readonly) {
|
|
@@ -9474,7 +9328,7 @@ class Input extends SvelteElement {
|
|
|
9474
9328
|
}
|
|
9475
9329
|
|
|
9476
9330
|
get error() {
|
|
9477
|
-
return this.$$.ctx[
|
|
9331
|
+
return this.$$.ctx[26];
|
|
9478
9332
|
}
|
|
9479
9333
|
|
|
9480
9334
|
set error(error) {
|
|
@@ -9572,28 +9426,6 @@ class Input extends SvelteElement {
|
|
|
9572
9426
|
flush();
|
|
9573
9427
|
}
|
|
9574
9428
|
|
|
9575
|
-
get showcounter() {
|
|
9576
|
-
return this.$$.ctx[29];
|
|
9577
|
-
}
|
|
9578
|
-
|
|
9579
|
-
set showcounter(showcounter) {
|
|
9580
|
-
this.$$set({
|
|
9581
|
-
showcounter
|
|
9582
|
-
});
|
|
9583
|
-
flush();
|
|
9584
|
-
}
|
|
9585
|
-
|
|
9586
|
-
get maxcharcount() {
|
|
9587
|
-
return this.$$.ctx[16];
|
|
9588
|
-
}
|
|
9589
|
-
|
|
9590
|
-
set maxcharcount(maxcharcount) {
|
|
9591
|
-
this.$$set({
|
|
9592
|
-
maxcharcount
|
|
9593
|
-
});
|
|
9594
|
-
flush();
|
|
9595
|
-
}
|
|
9596
|
-
|
|
9597
9429
|
}
|
|
9598
9430
|
|
|
9599
9431
|
customElements.define("goa-input", Input);
|
|
@@ -14619,13 +14451,13 @@ const GoAFormItem = ({
|
|
|
14619
14451
|
children,
|
|
14620
14452
|
helpText,
|
|
14621
14453
|
error,
|
|
14622
|
-
|
|
14454
|
+
requirement,
|
|
14623
14455
|
label
|
|
14624
14456
|
}) => {
|
|
14625
14457
|
return jsx("goa-form-item", Object.assign({
|
|
14626
14458
|
label: label,
|
|
14627
14459
|
error: error,
|
|
14628
|
-
|
|
14460
|
+
requirement: requirement,
|
|
14629
14461
|
helptext: helpText
|
|
14630
14462
|
}, {
|
|
14631
14463
|
children: children
|
|
@@ -14751,8 +14583,6 @@ const GoAInput = ({
|
|
|
14751
14583
|
placeholder,
|
|
14752
14584
|
error,
|
|
14753
14585
|
width,
|
|
14754
|
-
showCounter,
|
|
14755
|
-
maxCharCount,
|
|
14756
14586
|
testId,
|
|
14757
14587
|
min,
|
|
14758
14588
|
max,
|
|
@@ -14811,8 +14641,6 @@ const GoAInput = ({
|
|
|
14811
14641
|
step: step,
|
|
14812
14642
|
prefix: prefix,
|
|
14813
14643
|
suffix: suffix,
|
|
14814
|
-
showcounter: showCounter,
|
|
14815
|
-
maxcharcount: maxCharCount,
|
|
14816
14644
|
handletrailingiconclick: !!onTrailingIconClick
|
|
14817
14645
|
}, void 0);
|
|
14818
14646
|
};
|