@postnord/pn-marketweb-components 2.0.0 → 2.0.2-beta2

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.
Files changed (91) hide show
  1. package/cjs/loader.cjs.js +1 -1
  2. package/cjs/pn-find-price-result.cjs.entry.js +3 -3
  3. package/cjs/{pn-find-price-store-c6cb51c1.js → pn-find-price-store-6aab7fd0.js} +0 -1
  4. package/cjs/pn-find-price.cjs.entry.js +7 -10
  5. package/cjs/pn-market-web-components.cjs.js +1 -1
  6. package/cjs/pn-marketweb-input.cjs.entry.js +76 -0
  7. package/cjs/pn-marketweb-search.cjs.entry.js +2 -2
  8. package/cjs/pn-pex-pricefinder.cjs.entry.js +10 -2
  9. package/cjs/pn-product-card_3.cjs.entry.js +8 -8
  10. package/cjs/pn-product-pricelist.cjs.entry.js +1 -1
  11. package/collection/collection-manifest.json +1 -0
  12. package/collection/components/input/pn-marketweb-input/marketweb-input.stories.js +51 -0
  13. package/collection/components/input/pn-marketweb-input/pn-marketweb-input.css +156 -0
  14. package/collection/components/input/pn-marketweb-input/pn-marketweb-input.js +412 -0
  15. package/collection/components/input/pn-marketweb-search/pn-marketweb-search.css +18 -15
  16. package/collection/components/input/pn-marketweb-search/pn-marketweb-search.js +2 -2
  17. package/collection/components/widgets/pn-find-price/img/clouds.svg +5 -0
  18. package/collection/components/widgets/pn-find-price/pn-find-price-result.js +2 -2
  19. package/collection/components/widgets/pn-find-price/pn-find-price-store.js +0 -1
  20. package/collection/components/widgets/pn-find-price/pn-find-price-translations.js +1 -6
  21. package/collection/components/widgets/pn-find-price/pn-find-price.css +18 -5
  22. package/collection/components/widgets/pn-find-price/pn-find-price.js +4 -3
  23. package/collection/components/widgets/pn-pex-pricefinder/pn-pex-pricefinder.js +10 -2
  24. package/collection/components/widgets/pn-product-card/pn-product-card-info.css +10 -3
  25. package/collection/components/widgets/pn-product-card/pn-product-card-info.js +2 -3
  26. package/collection/components/widgets/pn-product-card/pn-product-card-price.css +24 -5
  27. package/collection/components/widgets/pn-product-card/pn-product-card-price.js +3 -3
  28. package/collection/components/widgets/pn-product-card/pn-product-card.css +88 -30
  29. package/collection/components/widgets/pn-product-card/pn-product-card.js +1 -1
  30. package/collection/components/widgets/pn-product-pricelist/pn-product-pricelist.css +1 -0
  31. package/collection/components/widgets/pn-product-pricelist/pn-product-pricelist.stories.js +1 -1
  32. package/custom-elements/index.d.ts +6 -0
  33. package/custom-elements/index.js +102 -26
  34. package/esm/loader.js +1 -1
  35. package/esm/pn-find-price-result.entry.js +3 -3
  36. package/esm/{pn-find-price-store-c857dbc4.js → pn-find-price-store-3301df0a.js} +0 -1
  37. package/esm/pn-find-price.entry.js +7 -10
  38. package/esm/pn-market-web-components.js +1 -1
  39. package/esm/pn-marketweb-input.entry.js +72 -0
  40. package/esm/pn-marketweb-search.entry.js +2 -2
  41. package/esm/pn-pex-pricefinder.entry.js +10 -2
  42. package/esm/pn-product-card_3.entry.js +8 -8
  43. package/esm/pn-product-pricelist.entry.js +1 -1
  44. package/esm-es5/loader.js +1 -1
  45. package/esm-es5/pn-find-price-result.entry.js +1 -1
  46. package/esm-es5/pn-find-price-store-3301df0a.js +1 -0
  47. package/esm-es5/pn-find-price.entry.js +1 -1
  48. package/esm-es5/pn-market-web-components.js +1 -1
  49. package/esm-es5/pn-marketweb-input.entry.js +1 -0
  50. package/esm-es5/pn-marketweb-search.entry.js +1 -1
  51. package/esm-es5/pn-pex-pricefinder.entry.js +1 -1
  52. package/esm-es5/pn-product-card_3.entry.js +1 -1
  53. package/esm-es5/pn-product-pricelist.entry.js +1 -1
  54. package/package.json +1 -1
  55. package/pn-market-web-components/{p-c7c3361a.entry.js → p-045a349a.entry.js} +1 -1
  56. package/pn-market-web-components/p-07cc9f6b.system.entry.js +1 -0
  57. package/pn-market-web-components/p-1be1dcc1.entry.js +1 -0
  58. package/pn-market-web-components/p-3971ddb9.system.js +1 -0
  59. package/pn-market-web-components/p-5243b992.entry.js +1 -0
  60. package/pn-market-web-components/p-5d587499.js +1 -0
  61. package/pn-market-web-components/p-67887512.system.js +1 -1
  62. package/pn-market-web-components/p-72195bd8.entry.js +1 -0
  63. package/pn-market-web-components/{p-fc41fcf6.system.entry.js → p-7e494e9d.system.entry.js} +1 -1
  64. package/pn-market-web-components/p-80dce81e.system.entry.js +1 -0
  65. package/pn-market-web-components/p-996d8a6a.entry.js +1 -0
  66. package/pn-market-web-components/p-9e8c5793.system.entry.js +1 -0
  67. package/pn-market-web-components/p-9edaf6b6.system.entry.js +1 -0
  68. package/pn-market-web-components/p-d13a78db.system.entry.js +1 -0
  69. package/pn-market-web-components/p-e5fffc92.entry.js +1 -0
  70. package/pn-market-web-components/p-e9fe5c54.entry.js +1 -0
  71. package/pn-market-web-components/p-eb394e3b.system.entry.js +1 -0
  72. package/pn-market-web-components/pn-market-web-components.esm.js +1 -1
  73. package/types/components/input/pn-marketweb-input/pn-marketweb-input.d.ts +32 -0
  74. package/types/components/widgets/pn-find-price/pn-find-price-store.d.ts +0 -2
  75. package/types/components/widgets/pn-find-price/pn-find-price-translations.d.ts +0 -5
  76. package/types/components/widgets/pn-find-price/pn-find-price-types.d.ts +0 -1
  77. package/types/components/widgets/pn-pex-pricefinder/pn-pex-pricefinder.d.ts +1 -0
  78. package/types/components.d.ts +79 -0
  79. package/esm-es5/pn-find-price-store-c857dbc4.js +0 -1
  80. package/pn-market-web-components/p-0cff4955.entry.js +0 -1
  81. package/pn-market-web-components/p-0fe71e75.entry.js +0 -1
  82. package/pn-market-web-components/p-2239befa.system.entry.js +0 -1
  83. package/pn-market-web-components/p-38c4be82.system.entry.js +0 -1
  84. package/pn-market-web-components/p-3ddbc14c.entry.js +0 -1
  85. package/pn-market-web-components/p-6b505c69.entry.js +0 -1
  86. package/pn-market-web-components/p-6fab218d.system.js +0 -1
  87. package/pn-market-web-components/p-89ef9dad.system.entry.js +0 -1
  88. package/pn-market-web-components/p-b82f45b9.system.entry.js +0 -1
  89. package/pn-market-web-components/p-f0a468ef.entry.js +0 -1
  90. package/pn-market-web-components/p-f20380fb.js +0 -1
  91. package/pn-market-web-components/p-f5f1287a.system.entry.js +0 -1
@@ -0,0 +1,156 @@
1
+ pn--marketweb-input {
2
+ display: inline-flex;
3
+ flex-direction: column;
4
+ }
5
+
6
+ pn-marketweb-input input {
7
+ padding: 0.75em;
8
+ font-size: 1em;
9
+ font-weight: 500;
10
+ -webkit-font-smoothing: antialiased;
11
+ outline: none;
12
+ border-radius: 0.8rem;
13
+ border: 0.1rem solid #5E554A;
14
+ transition: box-shadow 0.15s, border 0.15s;
15
+ color: #000000;
16
+ width: 100%;
17
+ }
18
+ pn-marketweb-input input::placeholder {
19
+ color: #969087;
20
+ font-weight: normal;
21
+ }
22
+ pn-marketweb-input input:focus {
23
+ border: 0.1rem solid #005D92;
24
+ box-shadow: 0 0 0 0.2rem #fff, 0 0 0 0.4rem #005D92;
25
+ }
26
+ pn-marketweb-input input:hover {
27
+ border: 0.1rem solid #00A0D6;
28
+ }
29
+ pn-marketweb-input input:disabled {
30
+ background: #F3F2F2;
31
+ border: none;
32
+ }
33
+
34
+ pn-marketweb-input > .input-container {
35
+ position: relative;
36
+ }
37
+ pn-marketweb-input > .input-container > button {
38
+ position: absolute;
39
+ right: 1.2rem;
40
+ top: 50%;
41
+ transform: translateY(-50%);
42
+ background: none;
43
+ border: none;
44
+ cursor: pointer;
45
+ color: #005D92;
46
+ padding: 0.6rem;
47
+ border-radius: 0.8rem;
48
+ outline: none;
49
+ transition: border 0.1s, background 0.2s, color 0.1s;
50
+ border: 0.1rem solid transparent;
51
+ }
52
+ pn-marketweb-input > .input-container > button:focus {
53
+ border: 0.1rem solid #005D92;
54
+ }
55
+ pn-marketweb-input > .input-container > button:hover {
56
+ background: #E0F8FF;
57
+ }
58
+ pn-marketweb-input > .input-container > button:active {
59
+ background: #005D92;
60
+ color: white;
61
+ }
62
+ pn-marketweb-input > .input-container > svg {
63
+ position: absolute;
64
+ right: 0.75em;
65
+ top: 50%;
66
+ transform: translateY(-50%);
67
+ height: 1.5em;
68
+ width: 1.5em;
69
+ pointer-events: none;
70
+ }
71
+ pn-marketweb-input > .input-container > svg polyline {
72
+ stroke-linecap: round;
73
+ transition: stroke-dashoffset 0.2s cubic-bezier(0.79, 0.14, 0.15, 0.86);
74
+ }
75
+ pn-marketweb-input > .input-container > svg.pn-input-checkmark polyline {
76
+ stroke: #005E41;
77
+ stroke-dashoffset: 23;
78
+ stroke-dasharray: 23;
79
+ }
80
+
81
+ pn-marketweb-input .label-container {
82
+ margin-bottom: 0.4rem;
83
+ color: #5E554A;
84
+ font-size: 0.875em;
85
+ display: flex;
86
+ justify-content: space-between;
87
+ align-items: flex-end;
88
+ }
89
+ pn-marketweb-input .label-container label {
90
+ cursor: pointer;
91
+ transition: color 0.2s;
92
+ }
93
+
94
+ .label-container label.char-count {
95
+ flex-shrink: 0;
96
+ padding-left: 0.5em;
97
+ }
98
+
99
+ pn-marketweb-input small {
100
+ font-size: 0.75em;
101
+ font-size: max(.6em, 1.2rem);
102
+ transition: transform 0.2s cubic-bezier(0.79, 0.14, 0.15, 0.86);
103
+ margin-top: 0.5em;
104
+ color: #5E554A;
105
+ }
106
+
107
+ pn-input.error {
108
+ color: #A70707;
109
+ }
110
+ pn-input.error label {
111
+ color: #A70707;
112
+ }
113
+ pn-input.error small {
114
+ color: #A70707;
115
+ }
116
+ pn-input.error small > pn-icon {
117
+ margin-right: 0.25em;
118
+ }
119
+ pn-input.error input {
120
+ border: 0.1rem solid #A70707;
121
+ }
122
+ pn-input.error input:focus {
123
+ border: 0.1rem solid #A70707;
124
+ box-shadow: 0 0 0 0.2rem #fff, 0 0 0 0.4rem #A70707;
125
+ }
126
+ pn-input.error input:hover {
127
+ border: 0.1rem solid #F06365;
128
+ }
129
+
130
+ pn-input.valid {
131
+ color: #005E41;
132
+ }
133
+ pn-input.valid .input-container > svg.pn-input-checkmark polyline {
134
+ stroke-dashoffset: 0;
135
+ }
136
+ pn-input.valid label {
137
+ color: #005E41;
138
+ }
139
+ pn-input.valid input {
140
+ border: 0.1rem solid #005E41;
141
+ }
142
+ pn-input.valid input:focus {
143
+ border: 0.1rem solid #005E41;
144
+ box-shadow: 0 0 0 0.2rem #fff, 0 0 0 0.4rem #005E41;
145
+ }
146
+ pn-input.valid input:hover {
147
+ border: 0.1rem solid #5EC584;
148
+ }
149
+
150
+ pn-marketweb-input.password input {
151
+ padding-right: 4em;
152
+ }
153
+
154
+ pn-marketweb-input.icon input {
155
+ padding-right: 2.3em;
156
+ }
@@ -0,0 +1,412 @@
1
+ import { Component, Prop, h, Host, State } from "@stencil/core";
2
+ export class PnMarketwebInput {
3
+ constructor() {
4
+ this.disabled = false;
5
+ /** Error message; will take precedence over helpertext if both are provided (applies invalid styles automatically) */
6
+ this.error = '';
7
+ /** Error state without message (If you want to control the error messaging on your own) */
8
+ this.invalid = false;
9
+ /** Text message placed underneath the input field */
10
+ this.helpertext = '';
11
+ /** Text label placed above the input field */
12
+ this.label = '';
13
+ this.placeholder = '';
14
+ this.inputid = `${Math.random()}`;
15
+ this.name = '';
16
+ this.required = null;
17
+ this.type = 'text';
18
+ this.autocomplete = '';
19
+ this.valid = null;
20
+ this.value = '';
21
+ /** The maximum number of characters the user should be able to add, also adds a visible counter */
22
+ this.maxlength = '';
23
+ this.min = '';
24
+ this.max = '';
25
+ this.step = '';
26
+ this.pattern = '';
27
+ this.showText = false;
28
+ }
29
+ getTextMessage() {
30
+ if (this.error)
31
+ return this.error;
32
+ if (this.helpertext)
33
+ return this.helpertext;
34
+ return null;
35
+ }
36
+ toggleTextVisibility() {
37
+ this.showText = !this.showText;
38
+ }
39
+ getInputType() {
40
+ let types = ['text', 'password', 'url', 'tel', 'search', 'number', 'email', 'date', 'datetime-local', 'month', 'week', 'time'];
41
+ return (types.includes(this.type) && !this.showText) ? this.type : 'text';
42
+ }
43
+ setVal(e) {
44
+ var _a;
45
+ const target = (_a = e.composedPath) === null || _a === void 0 ? void 0 : _a.call(e)[0];
46
+ this.value = target.value;
47
+ }
48
+ getClassNames() {
49
+ let classNames = 'pn-input ';
50
+ if (this.error.length > 0 || this.invalid)
51
+ classNames += 'error ';
52
+ if (this.valid)
53
+ classNames += 'valid ';
54
+ if (this.type === 'password')
55
+ classNames += 'password ';
56
+ if (this.error || this.invalid || this.valid)
57
+ classNames += 'icon ';
58
+ return classNames;
59
+ }
60
+ render() {
61
+ return (h(Host, { class: this.getClassNames() },
62
+ (this.label || this.maxlength) &&
63
+ h("div", { class: "label-container" },
64
+ this.label && h("label", { htmlFor: this.inputid }, this.label),
65
+ parseInt(this.maxlength) > 0 && h("label", { class: "char-count", htmlFor: this.inputid }, `${this.value.length}/${this.maxlength}`)),
66
+ h("div", { class: "input-container" },
67
+ h("input", { type: this.getInputType(), value: this.value, id: this.inputid, name: this.name, placeholder: this.placeholder, disabled: this.disabled, autocomplete: this.autocomplete, onInput: (e) => this.setVal(e), maxlength: this.maxlength ? this.maxlength : null, min: (this.min ? this.min : null), max: (this.max ? this.max : null), step: (this.step ? this.step : null), pattern: (this.pattern ? this.pattern : null) }),
68
+ h("svg", { class: "pn-input-checkmark", xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "none" },
69
+ h("polyline", { class: "checkmark-path", points: "4,12 9,17 20,6", "stroke-width": "3" })),
70
+ this.type === 'password' && !this.disabled && h("button", { onClick: () => this.toggleTextVisibility() }, "Show")),
71
+ this.getTextMessage() &&
72
+ h("small", null,
73
+ this.error && h("pn-icon", { symbol: "alert-exclamation-circle", small: true, color: "warning" }),
74
+ this.getTextMessage())));
75
+ }
76
+ static get is() { return "pn-marketweb-input"; }
77
+ static get originalStyleUrls() { return {
78
+ "$": ["pn-marketweb-input.scss"]
79
+ }; }
80
+ static get styleUrls() { return {
81
+ "$": ["pn-marketweb-input.css"]
82
+ }; }
83
+ static get properties() { return {
84
+ "disabled": {
85
+ "type": "boolean",
86
+ "mutable": false,
87
+ "complexType": {
88
+ "original": "boolean",
89
+ "resolved": "boolean",
90
+ "references": {}
91
+ },
92
+ "required": false,
93
+ "optional": false,
94
+ "docs": {
95
+ "tags": [],
96
+ "text": ""
97
+ },
98
+ "attribute": "disabled",
99
+ "reflect": false,
100
+ "defaultValue": "false"
101
+ },
102
+ "error": {
103
+ "type": "string",
104
+ "mutable": false,
105
+ "complexType": {
106
+ "original": "string",
107
+ "resolved": "string",
108
+ "references": {}
109
+ },
110
+ "required": false,
111
+ "optional": false,
112
+ "docs": {
113
+ "tags": [],
114
+ "text": "Error message; will take precedence over helpertext if both are provided (applies invalid styles automatically)"
115
+ },
116
+ "attribute": "error",
117
+ "reflect": false,
118
+ "defaultValue": "''"
119
+ },
120
+ "invalid": {
121
+ "type": "boolean",
122
+ "mutable": false,
123
+ "complexType": {
124
+ "original": "boolean",
125
+ "resolved": "boolean",
126
+ "references": {}
127
+ },
128
+ "required": false,
129
+ "optional": false,
130
+ "docs": {
131
+ "tags": [],
132
+ "text": "Error state without message (If you want to control the error messaging on your own)"
133
+ },
134
+ "attribute": "invalid",
135
+ "reflect": false,
136
+ "defaultValue": "false"
137
+ },
138
+ "helpertext": {
139
+ "type": "string",
140
+ "mutable": false,
141
+ "complexType": {
142
+ "original": "string",
143
+ "resolved": "string",
144
+ "references": {}
145
+ },
146
+ "required": false,
147
+ "optional": false,
148
+ "docs": {
149
+ "tags": [],
150
+ "text": "Text message placed underneath the input field"
151
+ },
152
+ "attribute": "helpertext",
153
+ "reflect": false,
154
+ "defaultValue": "''"
155
+ },
156
+ "label": {
157
+ "type": "string",
158
+ "mutable": false,
159
+ "complexType": {
160
+ "original": "string",
161
+ "resolved": "string",
162
+ "references": {}
163
+ },
164
+ "required": false,
165
+ "optional": false,
166
+ "docs": {
167
+ "tags": [],
168
+ "text": "Text label placed above the input field"
169
+ },
170
+ "attribute": "label",
171
+ "reflect": false,
172
+ "defaultValue": "''"
173
+ },
174
+ "placeholder": {
175
+ "type": "string",
176
+ "mutable": false,
177
+ "complexType": {
178
+ "original": "string",
179
+ "resolved": "string",
180
+ "references": {}
181
+ },
182
+ "required": false,
183
+ "optional": false,
184
+ "docs": {
185
+ "tags": [],
186
+ "text": ""
187
+ },
188
+ "attribute": "placeholder",
189
+ "reflect": false,
190
+ "defaultValue": "''"
191
+ },
192
+ "inputid": {
193
+ "type": "string",
194
+ "mutable": false,
195
+ "complexType": {
196
+ "original": "string",
197
+ "resolved": "string",
198
+ "references": {}
199
+ },
200
+ "required": false,
201
+ "optional": false,
202
+ "docs": {
203
+ "tags": [],
204
+ "text": ""
205
+ },
206
+ "attribute": "inputid",
207
+ "reflect": false,
208
+ "defaultValue": "`${Math.random()}`"
209
+ },
210
+ "name": {
211
+ "type": "string",
212
+ "mutable": false,
213
+ "complexType": {
214
+ "original": "string",
215
+ "resolved": "string",
216
+ "references": {}
217
+ },
218
+ "required": false,
219
+ "optional": false,
220
+ "docs": {
221
+ "tags": [],
222
+ "text": ""
223
+ },
224
+ "attribute": "name",
225
+ "reflect": false,
226
+ "defaultValue": "''"
227
+ },
228
+ "required": {
229
+ "type": "boolean",
230
+ "mutable": false,
231
+ "complexType": {
232
+ "original": "boolean",
233
+ "resolved": "boolean",
234
+ "references": {}
235
+ },
236
+ "required": false,
237
+ "optional": false,
238
+ "docs": {
239
+ "tags": [],
240
+ "text": ""
241
+ },
242
+ "attribute": "required",
243
+ "reflect": false,
244
+ "defaultValue": "null"
245
+ },
246
+ "type": {
247
+ "type": "string",
248
+ "mutable": true,
249
+ "complexType": {
250
+ "original": "string",
251
+ "resolved": "string",
252
+ "references": {}
253
+ },
254
+ "required": false,
255
+ "optional": false,
256
+ "docs": {
257
+ "tags": [],
258
+ "text": ""
259
+ },
260
+ "attribute": "type",
261
+ "reflect": false,
262
+ "defaultValue": "'text'"
263
+ },
264
+ "autocomplete": {
265
+ "type": "string",
266
+ "mutable": false,
267
+ "complexType": {
268
+ "original": "string",
269
+ "resolved": "string",
270
+ "references": {}
271
+ },
272
+ "required": false,
273
+ "optional": false,
274
+ "docs": {
275
+ "tags": [],
276
+ "text": ""
277
+ },
278
+ "attribute": "autocomplete",
279
+ "reflect": false,
280
+ "defaultValue": "''"
281
+ },
282
+ "valid": {
283
+ "type": "boolean",
284
+ "mutable": false,
285
+ "complexType": {
286
+ "original": "boolean",
287
+ "resolved": "boolean",
288
+ "references": {}
289
+ },
290
+ "required": false,
291
+ "optional": false,
292
+ "docs": {
293
+ "tags": [],
294
+ "text": ""
295
+ },
296
+ "attribute": "valid",
297
+ "reflect": false,
298
+ "defaultValue": "null"
299
+ },
300
+ "value": {
301
+ "type": "string",
302
+ "mutable": false,
303
+ "complexType": {
304
+ "original": "string",
305
+ "resolved": "string",
306
+ "references": {}
307
+ },
308
+ "required": false,
309
+ "optional": false,
310
+ "docs": {
311
+ "tags": [],
312
+ "text": ""
313
+ },
314
+ "attribute": "value",
315
+ "reflect": false,
316
+ "defaultValue": "''"
317
+ },
318
+ "maxlength": {
319
+ "type": "string",
320
+ "mutable": false,
321
+ "complexType": {
322
+ "original": "string",
323
+ "resolved": "string",
324
+ "references": {}
325
+ },
326
+ "required": false,
327
+ "optional": false,
328
+ "docs": {
329
+ "tags": [],
330
+ "text": "The maximum number of characters the user should be able to add, also adds a visible counter"
331
+ },
332
+ "attribute": "maxlength",
333
+ "reflect": false,
334
+ "defaultValue": "''"
335
+ },
336
+ "min": {
337
+ "type": "string",
338
+ "mutable": false,
339
+ "complexType": {
340
+ "original": "string",
341
+ "resolved": "string",
342
+ "references": {}
343
+ },
344
+ "required": false,
345
+ "optional": false,
346
+ "docs": {
347
+ "tags": [],
348
+ "text": ""
349
+ },
350
+ "attribute": "min",
351
+ "reflect": false,
352
+ "defaultValue": "''"
353
+ },
354
+ "max": {
355
+ "type": "string",
356
+ "mutable": false,
357
+ "complexType": {
358
+ "original": "string",
359
+ "resolved": "string",
360
+ "references": {}
361
+ },
362
+ "required": false,
363
+ "optional": false,
364
+ "docs": {
365
+ "tags": [],
366
+ "text": ""
367
+ },
368
+ "attribute": "max",
369
+ "reflect": false,
370
+ "defaultValue": "''"
371
+ },
372
+ "step": {
373
+ "type": "string",
374
+ "mutable": false,
375
+ "complexType": {
376
+ "original": "string",
377
+ "resolved": "string",
378
+ "references": {}
379
+ },
380
+ "required": false,
381
+ "optional": false,
382
+ "docs": {
383
+ "tags": [],
384
+ "text": ""
385
+ },
386
+ "attribute": "step",
387
+ "reflect": false,
388
+ "defaultValue": "''"
389
+ },
390
+ "pattern": {
391
+ "type": "string",
392
+ "mutable": false,
393
+ "complexType": {
394
+ "original": "string",
395
+ "resolved": "string",
396
+ "references": {}
397
+ },
398
+ "required": false,
399
+ "optional": false,
400
+ "docs": {
401
+ "tags": [],
402
+ "text": ""
403
+ },
404
+ "attribute": "pattern",
405
+ "reflect": false,
406
+ "defaultValue": "''"
407
+ }
408
+ }; }
409
+ static get states() { return {
410
+ "showText": {}
411
+ }; }
412
+ }
@@ -66,12 +66,15 @@
66
66
  align-items: center;
67
67
  justify-content: center;
68
68
  }
69
+ :host[list] :host > .input-container .button-container {
70
+ display: none;
71
+ }
69
72
  :host > .input-container button {
70
73
  position: absolute;
71
74
  left: 50%;
72
75
  top: 50%;
73
76
  transform: translate(100%, -50%);
74
- background: none;
77
+ background: #FFFFFF;
75
78
  border: none;
76
79
  color: #005D92;
77
80
  padding: 0.3rem;
@@ -100,44 +103,44 @@
100
103
  fill: white;
101
104
  }
102
105
 
103
- :host.searching button.search {
106
+ :host .searching button.search {
104
107
  transform: translate(150%, -50%);
105
108
  }
106
- :host.searching button.clear {
109
+ :host .searching button.clear {
107
110
  transform: translate(-50%, -50%);
108
111
  }
109
112
 
110
113
  /*---------------------------------------Button Variants-------------------------------------------*/
111
- :host.button-none input,
112
- :host.button-icon-inline input {
114
+ :host .button-none input,
115
+ :host .button-icon-inline input {
113
116
  padding-right: 3.3em;
114
117
  }
115
- :host.button-none pn-spinner,
116
- :host.button-icon-inline pn-spinner {
118
+ :host .button-none pn-spinner,
119
+ :host .button-icon-inline pn-spinner {
117
120
  position: absolute;
118
121
  left: 50%;
119
122
  top: 50%;
120
123
  transform: translate(100%, -50%);
121
124
  transition: transform cubic-bezier(0.7, 0, 0.3, 1) 0.2s;
122
125
  }
123
- :host.button-none button.search,
124
- :host.button-icon-inline button.search {
126
+ :host .button-none button.search,
127
+ :host .button-icon-inline button.search {
125
128
  transform: translate(-50%, -50%);
126
129
  }
127
- :host.button-none.loading button,
128
- :host.button-icon-inline.loading button {
130
+ :host .button-none.loading button,
131
+ :host .button-icon-inline.loading button {
129
132
  transform: translate(100%, -50%);
130
133
  }
131
- :host.button-none.loading pn-spinner,
132
- :host.button-icon-inline.loading pn-spinner {
134
+ :host .button-none.loading pn-spinner,
135
+ :host .button-icon-inline.loading pn-spinner {
133
136
  transform: translate(-50%, -50%);
134
137
  }
135
138
 
136
- :host.button-none.searching button.search {
139
+ :host .button-none.searching button.search {
137
140
  transform: translate(100%, -50%);
138
141
  }
139
142
 
140
- :host.button-icon > pn-button[data-loading=true] .pn-button-bg {
143
+ :host .button-icon > pn-button[data-loading=true] .pn-button-bg {
141
144
  left: 50%;
142
145
  transform: translateX(-50%);
143
146
  }
@@ -78,8 +78,8 @@ export class PnMarketwebSearch {
78
78
  });
79
79
  }
80
80
  render() {
81
- return (h(Host, { class: this.getClassNames() },
82
- h("div", { class: "input-container" },
81
+ return (h(Host, null,
82
+ h("div", { class: `input-container ${this.getClassNames()}`, "data-haslist": (this.list !== null) + '' },
83
83
  h("input", { type: "search", value: this.value, id: this.inputid, name: this.name, placeholder: this.placeholder, disabled: this.disabled, autocomplete: this.autocomplete, list: this.list, onKeyDown: (e) => this.emitSearch(e), onInput: (e) => this.setVal(e) }),
84
84
  h("div", { class: "button-container" },
85
85
  (this.button === 'none' || this.button === 'icon-inline') &&
@@ -0,0 +1,5 @@
1
+ <svg width="278" height="55" viewBox="0 0 278 55" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <path d="M247.355 49.6815C247.694 52.479 249.722 54.6261 252.181 54.6261H272.926C275.62 54.6261 277.798 52.0522 277.798 48.8686V48.8008C277.798 45.6173 275.62 43.0433 272.926 43.0433H270.537C269.608 39.2439 266.846 36.473 263.585 36.473H259.717C259.373 31.841 256.101 28.2092 252.124 28.2092C248.146 28.2092 244.88 31.841 244.53 36.473H242.095C238.083 36.473 234.816 40.6726 234.816 45.8205V49.6815H247.355Z" fill="#E0F8FF"/>
3
+ <path d="M12.0391 46.1022C12.3176 48.5569 14.0867 50.4373 16.2421 50.4373H34.5807C36.9304 50.4373 38.8216 48.202 38.8216 45.4248V45.3571C38.8216 42.5799 36.9304 40.3446 34.5807 40.3446H32.4684C31.6678 37.0209 29.227 34.5872 26.3283 34.5872H22.9179C22.6004 30.5597 19.7327 27.4071 16.2421 27.4071C12.7514 27.4071 9.88371 30.5597 9.56622 34.5872H7.41658C3.86346 34.5872 0.998047 38.2448 0.998047 42.7154V46.1022H12.0391Z" fill="#E0F8FF"/>
4
+ <path d="M131.056 26.5864C131.449 30.0423 133.948 32.6895 136.991 32.6895H162.891C166.209 32.6895 168.88 29.5426 168.88 25.6328V25.5375C168.88 21.6277 166.209 18.4808 162.891 18.4808H159.907C158.777 13.8015 155.33 10.3753 151.236 10.3753H146.42C145.971 4.70533 141.921 0.26709 136.991 0.26709C132.062 0.26709 128.012 4.70533 127.563 10.3753H124.528C119.51 10.3753 115.463 15.5247 115.463 21.8184V26.5864H131.056Z" fill="#E0F8FF"/>
5
+ </svg>
@@ -30,7 +30,7 @@ export class PnfindPriceResult {
30
30
  " "),
31
31
  (this.item.highestrankusp) ?
32
32
  (this.item.highestrankusp === "Billigast") ?
33
- (h("span", { slot: "Biligast" },
33
+ (h("span", { slot: "Billigast" },
34
34
  this.item.highestrankusp,
35
35
  h("pn-icon", { symbol: "box-label", small: "false", color: "green700" })))
36
36
  : (h("span", { slot: "Snabbast" },
@@ -50,7 +50,7 @@ export class PnfindPriceResult {
50
50
  h("div", { slot: "cardprice" },
51
51
  this.item.priceagent ? (h("pn-product-card-price", { slot: "price", label: "", amount: this.item.priceagent + '', currency: state.market.currency, url: "https://shop.postnord.se/ebutik/default.aspx", service: this.item.name + "-eshop" })) : null,
52
52
  this.item.pricesenddirect ? (h("pn-product-card-price", { slot: "sendDirectPrice", label: state.i18n.senddirectcta, amount: this.item.pricesenddirect + '', currency: state.market.currency, url: "https://portal.postnord.com/skickadirekt/", service: this.item.name + "-portal" })) : null,
53
- this.item.pricestamps ? (h("pn-product-card-price", { slot: "stampPrice", label: state.i18n.stampshopcta, amount: this.item.pricestamps + '', currency: state.market.currency, url: "https://shop.postnord.se/ebutik/default.aspx", service: this.item.name + "-eshop", note: state.i18n.message })) : null))));
53
+ this.item.pricestamps ? (h("pn-product-card-price", { slot: "stampPrice", label: state.i18n.stampshopcta, amount: this.item.pricestamps + '', currency: state.market.currency, url: "https://shop.postnord.se/ebutik/default.aspx", service: this.item.name + "-eshop" })) : null))));
54
54
  }
55
55
  static get is() { return "pn-find-price-result"; }
56
56
  static get originalStyleUrls() { return {
@@ -4,7 +4,6 @@ const { state, onChange } = createStore({
4
4
  i18n: {
5
5
  componentheading: '',
6
6
  deliveryscopeheading: '',
7
- sizeheading: '',
8
7
  resultlistheading: '',
9
8
  weightlabel: '',
10
9
  maxweightlabel: '',