@randstad-uca/design-system 1.0.45 → 1.0.47
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/Form.d.ts +3 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +814 -121
- package/dist/index.js.map +1 -1
- package/dist/package.json +1 -1
- package/dist/stories/Form.stories.d.ts +7 -3
- package/dist/styles/forms.css +106 -107
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,31 +1,31 @@
|
|
|
1
|
-
import{css as t,LitElement as e,html as i,nothing as o,isServer as r}from"lit";import{classMap as
|
|
1
|
+
import{css as t,LitElement as e,html as i,nothing as o,isServer as r}from"lit";import{classMap as n}from"lit/directives/class-map.js";function a(t,e,i,o){var r,n=arguments.length,a=n<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,o);else for(var s=t.length-1;s>=0;s--)(r=t[s])&&(a=(n<3?r(a):n>3?r(e,i,a):r(e,i))||a);return n>3&&a&&Object.defineProperty(e,i,a),a}function s(t,e){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(t,e)}"function"==typeof SuppressedError&&SuppressedError;
|
|
2
2
|
/**
|
|
3
3
|
* @license
|
|
4
4
|
* Copyright 2017 Google LLC
|
|
5
5
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
6
6
|
*/
|
|
7
|
-
const
|
|
7
|
+
const d=t=>(e,i)=>{void 0!==i?i.addInitializer((()=>{customElements.define(t,e)})):customElements.define(t,e)},l=globalThis,c=l.ShadowRoot&&(void 0===l.ShadyCSS||l.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,p=Symbol(),h=new WeakMap;
|
|
8
8
|
/**
|
|
9
9
|
* @license
|
|
10
10
|
* Copyright 2019 Google LLC
|
|
11
11
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
12
|
-
*/let u=class{constructor(t,e,i){if(this._$cssResult$=!0,i!==p)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=t,this.t=e}get styleSheet(){let t=this.o;const e=this.t;if(c&&void 0===t){const i=void 0!==e&&1===e.length;i&&(t=h.get(e)),void 0===t&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),i&&h.set(e,t))}return t}toString(){return this.cssText}};const b=(t,e)=>{if(c)t.adoptedStyleSheets=e.map((t=>t instanceof CSSStyleSheet?t:t.styleSheet));else for(const i of e){const e=document.createElement("style"),o=
|
|
12
|
+
*/let u=class{constructor(t,e,i){if(this._$cssResult$=!0,i!==p)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=t,this.t=e}get styleSheet(){let t=this.o;const e=this.t;if(c&&void 0===t){const i=void 0!==e&&1===e.length;i&&(t=h.get(e)),void 0===t&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),i&&h.set(e,t))}return t}toString(){return this.cssText}};const b=(t,e)=>{if(c)t.adoptedStyleSheets=e.map((t=>t instanceof CSSStyleSheet?t:t.styleSheet));else for(const i of e){const e=document.createElement("style"),o=l.litNonce;void 0!==o&&e.setAttribute("nonce",o),e.textContent=i.cssText,t.appendChild(e)}},g=c?t=>t:t=>t instanceof CSSStyleSheet?(t=>{let e="";for(const i of t.cssRules)e+=i.cssText;return(t=>new u("string"==typeof t?t:t+"",void 0,p))(e)})(t):t,{is:m,defineProperty:y,getOwnPropertyDescriptor:f,getOwnPropertyNames:v,getOwnPropertySymbols:x,getPrototypeOf:w}=Object,k=globalThis,$=k.trustedTypes,S=$?$.emptyScript:"",C=k.reactiveElementPolyfillSupport,E=(t,e)=>t,O={toAttribute(t,e){switch(e){case Boolean:t=t?S:null;break;case Object:case Array:t=null==t?t:JSON.stringify(t)}return t},fromAttribute(t,e){let i=t;switch(e){case Boolean:i=null!==t;break;case Number:i=null===t?null:Number(t);break;case Object:case Array:try{i=JSON.parse(t)}catch(t){i=null}}return i}},D=(t,e)=>!m(t,e),M={attribute:!0,type:String,converter:O,reflect:!1,useDefault:!1,hasChanged:D};
|
|
13
13
|
/**
|
|
14
14
|
* @license
|
|
15
15
|
* Copyright 2017 Google LLC
|
|
16
16
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
17
|
-
*/Symbol.metadata??=Symbol("metadata"),k.litPropertyMetadata??=new WeakMap;class
|
|
17
|
+
*/Symbol.metadata??=Symbol("metadata"),k.litPropertyMetadata??=new WeakMap;class P extends HTMLElement{static addInitializer(t){this._$Ei(),(this.l??=[]).push(t)}static get observedAttributes(){return this.finalize(),this._$Eh&&[...this._$Eh.keys()]}static createProperty(t,e=M){if(e.state&&(e.attribute=!1),this._$Ei(),this.prototype.hasOwnProperty(t)&&((e=Object.create(e)).wrapped=!0),this.elementProperties.set(t,e),!e.noAccessor){const i=Symbol(),o=this.getPropertyDescriptor(t,i,e);void 0!==o&&y(this.prototype,t,o)}}static getPropertyDescriptor(t,e,i){const{get:o,set:r}=f(this.prototype,t)??{get(){return this[e]},set(t){this[e]=t}};return{get:o,set(e){const n=o?.call(this);r?.call(this,e),this.requestUpdate(t,n,i)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){return this.elementProperties.get(t)??M}static _$Ei(){if(this.hasOwnProperty(E("elementProperties")))return;const t=w(this);t.finalize(),void 0!==t.l&&(this.l=[...t.l]),this.elementProperties=new Map(t.elementProperties)}static finalize(){if(this.hasOwnProperty(E("finalized")))return;if(this.finalized=!0,this._$Ei(),this.hasOwnProperty(E("properties"))){const t=this.properties,e=[...v(t),...x(t)];for(const i of e)this.createProperty(i,t[i])}const t=this[Symbol.metadata];if(null!==t){const e=litPropertyMetadata.get(t);if(void 0!==e)for(const[t,i]of e)this.elementProperties.set(t,i)}this._$Eh=new Map;for(const[t,e]of this.elementProperties){const i=this._$Eu(t,e);void 0!==i&&this._$Eh.set(i,t)}this.elementStyles=this.finalizeStyles(this.styles)}static finalizeStyles(t){const e=[];if(Array.isArray(t)){const i=new Set(t.flat(1/0).reverse());for(const t of i)e.unshift(g(t))}else void 0!==t&&e.push(g(t));return e}static _$Eu(t,e){const i=e.attribute;return!1===i?void 0:"string"==typeof i?i:"string"==typeof t?t.toLowerCase():void 0}constructor(){super(),this._$Ep=void 0,this.isUpdatePending=!1,this.hasUpdated=!1,this._$Em=null,this._$Ev()}_$Ev(){this._$ES=new Promise((t=>this.enableUpdating=t)),this._$AL=new Map,this._$E_(),this.requestUpdate(),this.constructor.l?.forEach((t=>t(this)))}addController(t){(this._$EO??=new Set).add(t),void 0!==this.renderRoot&&this.isConnected&&t.hostConnected?.()}removeController(t){this._$EO?.delete(t)}_$E_(){const t=new Map,e=this.constructor.elementProperties;for(const i of e.keys())this.hasOwnProperty(i)&&(t.set(i,this[i]),delete this[i]);t.size>0&&(this._$Ep=t)}createRenderRoot(){const t=this.shadowRoot??this.attachShadow(this.constructor.shadowRootOptions);return b(t,this.constructor.elementStyles),t}connectedCallback(){this.renderRoot??=this.createRenderRoot(),this.enableUpdating(!0),this._$EO?.forEach((t=>t.hostConnected?.()))}enableUpdating(t){}disconnectedCallback(){this._$EO?.forEach((t=>t.hostDisconnected?.()))}attributeChangedCallback(t,e,i){this._$AK(t,i)}_$ET(t,e){const i=this.constructor.elementProperties.get(t),o=this.constructor._$Eu(t,i);if(void 0!==o&&!0===i.reflect){const r=(void 0!==i.converter?.toAttribute?i.converter:O).toAttribute(e,i.type);this._$Em=t,null==r?this.removeAttribute(o):this.setAttribute(o,r),this._$Em=null}}_$AK(t,e){const i=this.constructor,o=i._$Eh.get(t);if(void 0!==o&&this._$Em!==o){const t=i.getPropertyOptions(o),r="function"==typeof t.converter?{fromAttribute:t.converter}:void 0!==t.converter?.fromAttribute?t.converter:O;this._$Em=o,this[o]=r.fromAttribute(e,t.type)??this._$Ej?.get(o)??null,this._$Em=null}}requestUpdate(t,e,i){if(void 0!==t){const o=this.constructor,r=this[t];if(i??=o.getPropertyOptions(t),!((i.hasChanged??D)(r,e)||i.useDefault&&i.reflect&&r===this._$Ej?.get(t)&&!this.hasAttribute(o._$Eu(t,i))))return;this.C(t,e,i)}!1===this.isUpdatePending&&(this._$ES=this._$EP())}C(t,e,{useDefault:i,reflect:o,wrapped:r},n){i&&!(this._$Ej??=new Map).has(t)&&(this._$Ej.set(t,n??e??this[t]),!0!==r||void 0!==n)||(this._$AL.has(t)||(this.hasUpdated||i||(e=void 0),this._$AL.set(t,e)),!0===o&&this._$Em!==t&&(this._$Eq??=new Set).add(t))}async _$EP(){this.isUpdatePending=!0;try{await this._$ES}catch(t){Promise.reject(t)}const t=this.scheduleUpdate();return null!=t&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){if(!this.isUpdatePending)return;if(!this.hasUpdated){if(this.renderRoot??=this.createRenderRoot(),this._$Ep){for(const[t,e]of this._$Ep)this[t]=e;this._$Ep=void 0}const t=this.constructor.elementProperties;if(t.size>0)for(const[e,i]of t){const{wrapped:t}=i,o=this[e];!0!==t||this._$AL.has(e)||void 0===o||this.C(e,void 0,i,o)}}let t=!1;const e=this._$AL;try{t=this.shouldUpdate(e),t?(this.willUpdate(e),this._$EO?.forEach((t=>t.hostUpdate?.())),this.update(e)):this._$EM()}catch(e){throw t=!1,this._$EM(),e}t&&this._$AE(e)}willUpdate(t){}_$AE(t){this._$EO?.forEach((t=>t.hostUpdated?.())),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(t)),this.updated(t)}_$EM(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$ES}shouldUpdate(t){return!0}update(t){this._$Eq&&=this._$Eq.forEach((t=>this._$ET(t,this[t]))),this._$EM()}updated(t){}firstUpdated(t){}}P.elementStyles=[],P.shadowRootOptions={mode:"open"},P[E("elementProperties")]=new Map,P[E("finalized")]=new Map,C?.({ReactiveElement:P}),(k.reactiveElementVersions??=[]).push("2.1.0");
|
|
18
18
|
/**
|
|
19
19
|
* @license
|
|
20
20
|
* Copyright 2017 Google LLC
|
|
21
21
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
22
22
|
*/
|
|
23
|
-
const
|
|
23
|
+
const j={attribute:!0,type:String,converter:O,reflect:!1,hasChanged:D},F=(t=j,e,i)=>{const{kind:o,metadata:r}=i;let n=globalThis.litPropertyMetadata.get(r);if(void 0===n&&globalThis.litPropertyMetadata.set(r,n=new Map),"setter"===o&&((t=Object.create(t)).wrapped=!0),n.set(i.name,t),"accessor"===o){const{name:o}=i;return{set(i){const r=e.get.call(this);e.set.call(this,i),this.requestUpdate(o,r,t)},init(e){return void 0!==e&&this.C(o,void 0,t,e),e}}}if("setter"===o){const{name:o}=i;return function(i){const r=this[o];e.call(this,i),this.requestUpdate(o,r,t)}}throw Error("Unsupported decorator location: "+o)};function z(t){return(e,i)=>"object"==typeof i?F(t,e,i):((t,e,i)=>{const o=e.hasOwnProperty(i);return e.constructor.createProperty(i,t),o?Object.getOwnPropertyDescriptor(e,i):void 0})(t,e,i)}
|
|
24
24
|
/**
|
|
25
25
|
* @license
|
|
26
26
|
* Copyright 2017 Google LLC
|
|
27
27
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
28
|
-
*/function
|
|
28
|
+
*/function T(t){return z({...t,state:!0,attribute:!1})}
|
|
29
29
|
/**
|
|
30
30
|
* @license
|
|
31
31
|
* Copyright 2017 Google LLC
|
|
@@ -36,19 +36,19 @@ const P={attribute:!0,type:String,converter:O,reflect:!1,hasChanged:j},I=(t=P,e,
|
|
|
36
36
|
* Copyright 2017 Google LLC
|
|
37
37
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
38
38
|
*/
|
|
39
|
-
function
|
|
39
|
+
function A(t,e){return(e,i,o)=>((t,e,i)=>(i.configurable=!0,i.enumerable=!0,Reflect.decorate&&"object"!=typeof e&&Object.defineProperty(t,e,i),i))(e,i,{get(){return(e=>e.renderRoot?.querySelector(t)??null)(this)}})}const L=t`
|
|
40
40
|
font-family: 'Graphik', sans-serif;
|
|
41
41
|
font-weight: 400;
|
|
42
42
|
font-size: 12px;
|
|
43
43
|
line-height: 15px;
|
|
44
44
|
letter-spacing: 0%;
|
|
45
|
-
`,
|
|
45
|
+
`,I=t`
|
|
46
46
|
font-family: 'Graphik', sans-serif;
|
|
47
47
|
font-weight: 400;
|
|
48
48
|
font-size: 14px;
|
|
49
49
|
line-height: 25px;
|
|
50
50
|
letter-spacing: 0%;
|
|
51
|
-
`,
|
|
51
|
+
`,_=t`
|
|
52
52
|
font-family: 'Graphik', sans-serif;
|
|
53
53
|
font-weight: 400;
|
|
54
54
|
font-size: 16px;
|
|
@@ -60,14 +60,14 @@ function F(t,e){return(e,i,o)=>((t,e,i)=>(i.configurable=!0,i.enumerable=!0,Refl
|
|
|
60
60
|
font-size: 18px;
|
|
61
61
|
line-height: 30px;
|
|
62
62
|
letter-spacing: 0%;
|
|
63
|
-
`,
|
|
63
|
+
`,N=t`
|
|
64
64
|
font-family: 'Graphik', sans-serif;
|
|
65
65
|
font-weight: 400;
|
|
66
66
|
font-size: 18px;
|
|
67
67
|
line-height: 30px;
|
|
68
68
|
letter-spacing: 0%;
|
|
69
69
|
vertical-align: middle;
|
|
70
|
-
`,
|
|
70
|
+
`,R=t`
|
|
71
71
|
font-family: 'Graphik', sans-serif;
|
|
72
72
|
font-weight: 400;
|
|
73
73
|
font-size: 20px;
|
|
@@ -100,7 +100,7 @@ function F(t,e){return(e,i,o)=>((t,e,i)=>(i.configurable=!0,i.enumerable=!0,Refl
|
|
|
100
100
|
}
|
|
101
101
|
|
|
102
102
|
.title {
|
|
103
|
-
${
|
|
103
|
+
${_}
|
|
104
104
|
color: var(--secondary-color);
|
|
105
105
|
}
|
|
106
106
|
|
|
@@ -159,13 +159,13 @@ function F(t,e){return(e,i,o)=>((t,e,i)=>(i.configurable=!0,i.enumerable=!0,Refl
|
|
|
159
159
|
<div class="content ${this.isOpen?"open":""}">
|
|
160
160
|
<slot></slot>
|
|
161
161
|
</div>
|
|
162
|
-
`}};
|
|
162
|
+
`}};a([z({type:String}),s("design:type",Object)],V.prototype,"title",void 0),a([T(),s("design:type",Object)],V.prototype,"isOpen",void 0),a([T(),s("design:type",Object)],V.prototype,"isDesktop",void 0),V=a([d("accordion-panel")],V);let Y=class extends e{static{this.styles=t`
|
|
163
163
|
:host {
|
|
164
164
|
display: flex;
|
|
165
165
|
flex-direction: column;
|
|
166
166
|
gap: 16px;
|
|
167
167
|
}
|
|
168
|
-
`}render(){return i`<slot></slot>`}};
|
|
168
|
+
`}render(){return i`<slot></slot>`}};Y=a([d("accordion-list")],Y);let W=class extends e{constructor(){super(...arguments),this.variant="button-primary",this.size="md",this.label="",this.loader=!1,this.iconPosition="left",this.disabled=!1,this.iconName=null,this.type="button",this.idevent=""}static{this.styles=t`
|
|
169
169
|
:host {
|
|
170
170
|
display: inline-block;
|
|
171
171
|
}
|
|
@@ -190,7 +190,7 @@ function F(t,e){return(e,i,o)=>((t,e,i)=>(i.configurable=!0,i.enumerable=!0,Refl
|
|
|
190
190
|
}
|
|
191
191
|
|
|
192
192
|
.button-md {
|
|
193
|
-
${
|
|
193
|
+
${_}
|
|
194
194
|
min-height: 57px;
|
|
195
195
|
}
|
|
196
196
|
|
|
@@ -392,7 +392,7 @@ function F(t,e){return(e,i,o)=>((t,e,i)=>(i.configurable=!0,i.enumerable=!0,Refl
|
|
|
392
392
|
<button
|
|
393
393
|
part="button"
|
|
394
394
|
type=${this.type}
|
|
395
|
-
class=${
|
|
395
|
+
class=${n(t)}
|
|
396
396
|
?disabled=${this.disabled}
|
|
397
397
|
?aria-busy=${this.loader}
|
|
398
398
|
@click=${this.handleClick}
|
|
@@ -410,7 +410,7 @@ function F(t,e){return(e,i,o)=>((t,e,i)=>(i.configurable=!0,i.enumerable=!0,Refl
|
|
|
410
410
|
${this.iconName&&"button-round"!==this.variant&&"right"===this.iconPosition?i`<randstad-icon name=${this.iconName} size="24px"></randstad-icon>`:""}
|
|
411
411
|
`}
|
|
412
412
|
</button>
|
|
413
|
-
`}};
|
|
413
|
+
`}};a([z({type:String}),s("design:type",String)],W.prototype,"variant",void 0),a([z({type:String}),s("design:type",String)],W.prototype,"size",void 0),a([z({type:String}),s("design:type",Object)],W.prototype,"label",void 0),a([z({type:Boolean}),s("design:type",Object)],W.prototype,"loader",void 0),a([z({type:String,attribute:"icon-src"}),s("design:type",String)],W.prototype,"iconSrc",void 0),a([z({type:String}),s("design:type",String)],W.prototype,"iconPosition",void 0),a([z({type:Boolean,reflect:!0}),s("design:type",Boolean)],W.prototype,"disabled",void 0),a([z({type:String}),s("design:type",Object)],W.prototype,"iconName",void 0),a([z({type:String}),s("design:type",String)],W.prototype,"type",void 0),a([z({type:String}),s("design:type",Object)],W.prototype,"idevent",void 0),W=a([d("randstad-button")],W);let U=class extends e{constructor(){super(...arguments),this.img="",this.name="",this.title="",this.description="",this.buttonLabel="Contactanos",this.cardId=""}static{this.styles=t`
|
|
414
414
|
:host {
|
|
415
415
|
display: inline-block;
|
|
416
416
|
font-family: "Graphik", sans-serif;
|
|
@@ -489,7 +489,7 @@ function F(t,e){return(e,i,o)=>((t,e,i)=>(i.configurable=!0,i.enumerable=!0,Refl
|
|
|
489
489
|
}
|
|
490
490
|
|
|
491
491
|
.description {
|
|
492
|
-
${
|
|
492
|
+
${I}
|
|
493
493
|
}
|
|
494
494
|
|
|
495
495
|
::part(button) {
|
|
@@ -527,14 +527,14 @@ function F(t,e){return(e,i,o)=>((t,e,i)=>(i.configurable=!0,i.enumerable=!0,Refl
|
|
|
527
527
|
</div>
|
|
528
528
|
</div>
|
|
529
529
|
</div>
|
|
530
|
-
`}};
|
|
530
|
+
`}};a([z({type:String}),s("design:type",Object)],U.prototype,"img",void 0),a([z({type:String}),s("design:type",Object)],U.prototype,"name",void 0),a([z({type:String}),s("design:type",Object)],U.prototype,"title",void 0),a([z({type:String}),s("design:type",Object)],U.prototype,"description",void 0),a([z({type:String}),s("design:type",Object)],U.prototype,"buttonLabel",void 0),a([z({type:String}),s("design:type",Object)],U.prototype,"cardId",void 0),U=a([d("carousel-card")],U);let G=class extends e{constructor(){super(...arguments),this.checked=!1,this.error=!1,this.disabled=!1}static{this.styles=t`
|
|
531
531
|
:host {
|
|
532
532
|
display: block;
|
|
533
533
|
max-width: 100%;
|
|
534
534
|
}
|
|
535
535
|
|
|
536
536
|
label {
|
|
537
|
-
${
|
|
537
|
+
${I}
|
|
538
538
|
display: flex;
|
|
539
539
|
align-items: center;
|
|
540
540
|
gap: 8px;
|
|
@@ -642,7 +642,7 @@ function F(t,e){return(e,i,o)=>((t,e,i)=>(i.configurable=!0,i.enumerable=!0,Refl
|
|
|
642
642
|
<slot></slot>
|
|
643
643
|
</span>
|
|
644
644
|
</label>
|
|
645
|
-
`}};
|
|
645
|
+
`}};a([z({type:Boolean,reflect:!0}),s("design:type",Object)],G.prototype,"checked",void 0),a([z({type:Boolean}),s("design:type",Object)],G.prototype,"error",void 0),a([z({type:Boolean}),s("design:type",Object)],G.prototype,"disabled",void 0),G=a([d("randstad-checkbox")],G);let H=class extends e{constructor(){super(...arguments),this.value="",this.size="md",this.icon=null,this.helper=null,this.error=!1,this.errorMessage="",this.disabled=!1,this.typing=!1,this.type="text",this.isPasswordVisible=!1,this.cleanButton=!1,this.required=!1,this.optional=!1,this.helperAlign="left"}static{this.styles=t`
|
|
646
646
|
:host {
|
|
647
647
|
display: block;
|
|
648
648
|
font-family: 'Graphik', sans-serif;
|
|
@@ -664,7 +664,7 @@ function F(t,e){return(e,i,o)=>((t,e,i)=>(i.configurable=!0,i.enumerable=!0,Refl
|
|
|
664
664
|
}
|
|
665
665
|
|
|
666
666
|
.form-label {
|
|
667
|
-
${
|
|
667
|
+
${_}
|
|
668
668
|
display: flex;
|
|
669
669
|
align-items: baseline;
|
|
670
670
|
flex-direction: row;
|
|
@@ -727,10 +727,10 @@ function F(t,e){return(e,i,o)=>((t,e,i)=>(i.configurable=!0,i.enumerable=!0,Refl
|
|
|
727
727
|
|
|
728
728
|
.input-with-button input {
|
|
729
729
|
width: 100%;
|
|
730
|
-
|
|
730
|
+
}
|
|
731
731
|
|
|
732
732
|
.input-with-button input[type="password"]{
|
|
733
|
-
|
|
733
|
+
padding-right: 40px;
|
|
734
734
|
}
|
|
735
735
|
|
|
736
736
|
.input-with-button button {
|
|
@@ -761,7 +761,7 @@ function F(t,e){return(e,i,o)=>((t,e,i)=>(i.configurable=!0,i.enumerable=!0,Refl
|
|
|
761
761
|
}
|
|
762
762
|
|
|
763
763
|
textarea.form-input {
|
|
764
|
-
min-height:
|
|
764
|
+
min-height: 30px;
|
|
765
765
|
width: 100%;
|
|
766
766
|
}
|
|
767
767
|
|
|
@@ -771,19 +771,19 @@ function F(t,e){return(e,i,o)=>((t,e,i)=>(i.configurable=!0,i.enumerable=!0,Refl
|
|
|
771
771
|
}
|
|
772
772
|
|
|
773
773
|
.helper-description {
|
|
774
|
-
${
|
|
774
|
+
${_}
|
|
775
775
|
color: var(--secondary-color-40);
|
|
776
776
|
margin: 0px;
|
|
777
777
|
}
|
|
778
778
|
|
|
779
779
|
.error-message {
|
|
780
|
-
${
|
|
780
|
+
${_}
|
|
781
781
|
color: var(--ui-negative);
|
|
782
782
|
margin: 0px;
|
|
783
783
|
}
|
|
784
784
|
|
|
785
785
|
.link-text {
|
|
786
|
-
${
|
|
786
|
+
${_}
|
|
787
787
|
color: var(--primary-color);
|
|
788
788
|
cursor: pointer;
|
|
789
789
|
text-align: end;
|
|
@@ -873,44 +873,47 @@ function F(t,e){return(e,i,o)=>((t,e,i)=>(i.configurable=!0,i.enumerable=!0,Refl
|
|
|
873
873
|
|
|
874
874
|
.optional {
|
|
875
875
|
color: var(--secondary-color-60);
|
|
876
|
-
${
|
|
876
|
+
${L}
|
|
877
877
|
}
|
|
878
|
-
`}togglePassword(t){this.isPasswordVisible=!this.isPasswordVisible;const e=t.currentTarget.parentElement?.querySelector("input");e&&(e.type=this.isPasswordVisible?"text":"password"),this.requestUpdate()}handleInput(t){const e=t.target.value;void 0!==this.maxLength&&"textarea"!==this.type?this.value=e.slice(0,this.maxLength):this.value=e,this.dispatchEvent(new CustomEvent("valueChanged",{detail:this.value})),this.dispatchEvent(new Event("input",{bubbles:!0})),this.requestUpdate()}handleClear(){this.value="",this.dispatchEvent(new CustomEvent("valueChanged",{detail:this.value})),this.dispatchEvent(new Event("input",{bubbles:!0})),this.requestUpdate()}handleLinkClick(t){t.preventDefault(),this.linkRoute&&this.dispatchEvent(new CustomEvent("linkClicked",{detail:this.linkRoute,bubbles:!0,composed:!0}))}handleKeyDown(t){if("Enter"===t.key){const t=new Event("submit",{bubbles:!0,composed:!0,cancelable:!0}),e=this.closest("form");e&&e.dispatchEvent(t)}}render(){const t=this.cleanButton&&this.value&&"password"!==this.type&&"textarea"!==this.type;
|
|
878
|
+
`}togglePassword(t){this.isPasswordVisible=!this.isPasswordVisible;const e=t.currentTarget.parentElement?.querySelector("input");e&&(e.type=this.isPasswordVisible?"text":"password"),this.requestUpdate()}handleInput(t){const e=t.target.value;void 0!==this.maxLength&&"textarea"!==this.type?this.value=e.slice(0,this.maxLength):this.value=e,this.dispatchEvent(new CustomEvent("valueChanged",{detail:this.value})),this.dispatchEvent(new Event("input",{bubbles:!0})),this.requestUpdate()}handleClear(){this.value="",this.dispatchEvent(new CustomEvent("valueChanged",{detail:this.value})),this.dispatchEvent(new Event("input",{bubbles:!0})),this.requestUpdate()}handleLinkClick(t){t.preventDefault(),this.linkRoute&&this.dispatchEvent(new CustomEvent("linkClicked",{detail:this.linkRoute,bubbles:!0,composed:!0}))}handleKeyDown(t){if("Enter"===t.key){const t=new Event("submit",{bubbles:!0,composed:!0,cancelable:!0}),e=this.closest("form");e&&e.dispatchEvent(t)}}render(){const t=this.cleanButton&&this.value&&"password"!==this.type&&"textarea"!==this.type,e="textarea"===this.type?`height: ${this.heightTextArea??"30px"}; max-height: ${this.maxHeightTextArea??"30px"}; overflow-y: auto;`:"",r=i`
|
|
879
|
+
${this.labelColor?`--label-color: ${this.labelColor};`:""}
|
|
880
|
+
`,n=`text-align: ${this.helperAlign??"left"};`;return i`
|
|
879
881
|
<div
|
|
880
882
|
class="form ${this.error?"error":""} ${this.disabled?"disabled":""}"
|
|
881
|
-
style
|
|
883
|
+
style="${r}"
|
|
882
884
|
>
|
|
883
885
|
${this.label?i`
|
|
884
|
-
|
|
885
|
-
|
|
886
|
-
|
|
887
|
-
|
|
888
|
-
|
|
889
|
-
|
|
890
|
-
|
|
891
|
-
|
|
892
|
-
|
|
893
|
-
|
|
894
|
-
|
|
895
|
-
|
|
896
|
-
|
|
897
|
-
|
|
898
|
-
`:o}
|
|
886
|
+
<div class="label-container">
|
|
887
|
+
<label class="form-label">
|
|
888
|
+
${this.label}
|
|
889
|
+
${this.required?i`<span class="required">*</span>`:this.optional?i`<span class="optional">opcional</span>`:o}
|
|
890
|
+
</label>
|
|
891
|
+
|
|
892
|
+
${this.helpLink?i`
|
|
893
|
+
<a class="tooltip-wrapper" href="${this.helpLink}">
|
|
894
|
+
<randstad-icon name="ayuda" size="20px">
|
|
895
|
+
</randstad-icon>
|
|
896
|
+
</a>
|
|
897
|
+
`:o}
|
|
898
|
+
</div>
|
|
899
|
+
`:o}
|
|
899
900
|
|
|
900
901
|
<div class="form-container">
|
|
901
902
|
${"left"===this.icon?i`<span class="icon left"></span>`:o}
|
|
902
903
|
|
|
903
904
|
<div class="input-with-button">
|
|
904
|
-
${"textarea"===this.type?i`
|
|
905
|
-
|
|
906
|
-
|
|
907
|
-
|
|
908
|
-
|
|
909
|
-
|
|
910
|
-
|
|
911
|
-
|
|
912
|
-
|
|
913
|
-
|
|
905
|
+
${"textarea"===this.type?i`
|
|
906
|
+
<textarea
|
|
907
|
+
class="form-input"
|
|
908
|
+
placeholder=${this.placeholder||""}
|
|
909
|
+
.value=${this.value}
|
|
910
|
+
?disabled=${this.disabled}
|
|
911
|
+
@input=${this.handleInput}
|
|
912
|
+
@keydown=${this.handleKeyDown}
|
|
913
|
+
maxlength=${this.maxLength??o}
|
|
914
|
+
style="${e}"
|
|
915
|
+
>
|
|
916
|
+
</textarea>`:i`
|
|
914
917
|
<input
|
|
915
918
|
class="form-input"
|
|
916
919
|
type=${"password"!==this.type||this.isPasswordVisible?"text":"password"}
|
|
@@ -922,31 +925,67 @@ function F(t,e){return(e,i,o)=>((t,e,i)=>(i.configurable=!0,i.enumerable=!0,Refl
|
|
|
922
925
|
maxlength=${this.maxLength??o}
|
|
923
926
|
/>
|
|
924
927
|
|
|
925
|
-
${"password"===this.type?i
|
|
926
|
-
|
|
928
|
+
${"password"===this.type?i`
|
|
929
|
+
<button
|
|
930
|
+
type="button"
|
|
931
|
+
class="toggle-password"
|
|
932
|
+
@click=${this.togglePassword}
|
|
933
|
+
>
|
|
934
|
+
${this.isPasswordVisible?i`
|
|
935
|
+
<randstad-icon
|
|
936
|
+
name="eye_crossed"
|
|
937
|
+
size="24px"
|
|
938
|
+
>
|
|
939
|
+
</randstad-icon>
|
|
940
|
+
`:i`
|
|
941
|
+
<randstad-icon
|
|
942
|
+
name="eye"
|
|
943
|
+
size="24px"
|
|
944
|
+
>
|
|
945
|
+
</randstad-icon>`}
|
|
927
946
|
</button>`:o}
|
|
928
947
|
|
|
929
|
-
${t?i
|
|
930
|
-
|
|
948
|
+
${t?i`
|
|
949
|
+
<button
|
|
950
|
+
type="button"
|
|
951
|
+
class="clean-button"
|
|
952
|
+
@click=${this.handleClear}
|
|
953
|
+
>
|
|
954
|
+
<randstad-icon
|
|
955
|
+
name="close"
|
|
956
|
+
size="24px"
|
|
957
|
+
style="--icon-color: var(--primary-color);"
|
|
958
|
+
>
|
|
959
|
+
</randstad-icon>
|
|
931
960
|
</button>`:o}
|
|
932
|
-
|
|
961
|
+
`}
|
|
933
962
|
</div>
|
|
934
963
|
|
|
935
964
|
${"right"===this.icon?i`<span class="icon right"></span>`:o}
|
|
936
965
|
</div>
|
|
937
966
|
|
|
938
|
-
${this.error?i`
|
|
939
|
-
|
|
940
|
-
|
|
941
|
-
|
|
967
|
+
${this.error?i`
|
|
968
|
+
<p class="error-message">
|
|
969
|
+
${this.errorMessage?this.errorMessage:i`<slot name="error-extended"></slot>`}
|
|
970
|
+
</p>`:o}
|
|
942
971
|
|
|
943
|
-
${this.linkText&&this.linkRoute?i
|
|
944
|
-
|
|
972
|
+
${this.linkText&&this.linkRoute?i`
|
|
973
|
+
<div style="text-align: end;">
|
|
974
|
+
<a class="link-text" @click=${this.handleLinkClick}>
|
|
975
|
+
${this.linkText}
|
|
976
|
+
</a
|
|
945
977
|
</div>`:o}
|
|
946
978
|
|
|
947
|
-
${this.helper?i
|
|
979
|
+
${this.helper?i`
|
|
980
|
+
<p
|
|
981
|
+
class="helper-description"
|
|
982
|
+
style=${n}
|
|
983
|
+
>
|
|
984
|
+
${this.helper}
|
|
985
|
+
</p>
|
|
986
|
+
`:o}
|
|
948
987
|
</div>
|
|
949
|
-
`}};
|
|
988
|
+
`}};a([z({type:String}),s("design:type",String)],H.prototype,"placeholder",void 0),a([z({type:String}),s("design:type",String)],H.prototype,"label",void 0),a([z({type:String}),s("design:type",String)],H.prototype,"labelColor",void 0),a([z({type:String}),s("design:type",String)],H.prototype,"value",void 0),a([z({type:String}),s("design:type",String)],H.prototype,"size",void 0),a([z({type:String}),s("design:type",Object)],H.prototype,"icon",void 0),a([z({type:String}),s("design:type",Object)],H.prototype,"helper",void 0),a([z({type:Boolean}),s("design:type",Boolean)],H.prototype,"error",void 0),a([z({type:String}),s("design:type",String)],H.prototype,"errorMessage",void 0),a([z({type:Boolean}),s("design:type",Boolean)],H.prototype,"disabled",void 0),a([z({type:Boolean}),s("design:type",Boolean)],H.prototype,"typing",void 0),a([z({type:String}),s("design:type",String)],H.prototype,"type",void 0),a([z({type:String}),s("design:type",String)],H.prototype,"tooltipMessage",void 0),a([z({type:String}),s("design:type",String)],H.prototype,"linkText",void 0),a([z({type:String}),s("design:type",String)],H.prototype,"linkRoute",void 0),a([z({type:Boolean,reflect:!0}),s("design:type",Object)],H.prototype,"isPasswordVisible",void 0),a([z({type:Boolean}),s("design:type",Boolean)],H.prototype,"cleanButton",void 0),a([z({type:Number}),s("design:type",Number)],H.prototype,"maxLength",void 0),a([z({type:Boolean}),s("design:type",Object)],H.prototype,"required",void 0),a([z({type:Boolean}),s("design:type",Object)],H.prototype,"optional",void 0),a([z({type:String}),s("design:type",String)],H.prototype,"helpLink",void 0),a([z({type:String}),s("design:type",String)],H.prototype,"heightTextArea",void 0),a([z({type:String}),s("design:type",String)],H.prototype,"maxHeightTextArea",void 0),a([z({type:String}),s("design:type",String)],H.prototype,"helperAlign",void 0),H=a([d("randstad-form")],H);let K=class extends e{constructor(){super(...arguments),this.label="",this.error=!1,this.errorMessage="",this.required=!1,this.optional=!1}static{this.styles=t`
|
|
950
989
|
:host {
|
|
951
990
|
display: flex;
|
|
952
991
|
flex-direction: column;
|
|
@@ -956,7 +995,7 @@ function F(t,e){return(e,i,o)=>((t,e,i)=>(i.configurable=!0,i.enumerable=!0,Refl
|
|
|
956
995
|
}
|
|
957
996
|
|
|
958
997
|
.form-label {
|
|
959
|
-
${
|
|
998
|
+
${_}
|
|
960
999
|
display: flex;
|
|
961
1000
|
align-items: baseline;
|
|
962
1001
|
flex-direction: row;
|
|
@@ -971,12 +1010,12 @@ function F(t,e){return(e,i,o)=>((t,e,i)=>(i.configurable=!0,i.enumerable=!0,Refl
|
|
|
971
1010
|
}
|
|
972
1011
|
|
|
973
1012
|
.helper {
|
|
974
|
-
${
|
|
1013
|
+
${_}
|
|
975
1014
|
color: var(--secondary-color-40);
|
|
976
1015
|
}
|
|
977
1016
|
|
|
978
1017
|
.error {
|
|
979
|
-
${
|
|
1018
|
+
${_}
|
|
980
1019
|
color: var(--ui-negative);
|
|
981
1020
|
}
|
|
982
1021
|
|
|
@@ -986,12 +1025,13 @@ function F(t,e){return(e,i,o)=>((t,e,i)=>(i.configurable=!0,i.enumerable=!0,Refl
|
|
|
986
1025
|
|
|
987
1026
|
.optional {
|
|
988
1027
|
color: var(--secondary-color-60);
|
|
989
|
-
${
|
|
1028
|
+
${L}
|
|
990
1029
|
}
|
|
991
1030
|
`}render(){return i`
|
|
992
1031
|
<label class="form-label">
|
|
993
1032
|
${this.label}
|
|
994
|
-
${this.required?i
|
|
1033
|
+
${this.required?i`
|
|
1034
|
+
<span class="required">*</span>`:this.optional?i`<span class="optional">opcional</span>`:o}
|
|
995
1035
|
</label>
|
|
996
1036
|
|
|
997
1037
|
<div class="fields">
|
|
@@ -999,7 +1039,7 @@ function F(t,e){return(e,i,o)=>((t,e,i)=>(i.configurable=!0,i.enumerable=!0,Refl
|
|
|
999
1039
|
</div>
|
|
1000
1040
|
|
|
1001
1041
|
${this.error?i`<span class="error">${this.errorMessage}</span>`:this.helper?i`<span class="helper">${this.helper}</span>`:null}
|
|
1002
|
-
`}};
|
|
1042
|
+
`}};a([z({type:String}),s("design:type",Object)],K.prototype,"label",void 0),a([z({type:String}),s("design:type",String)],K.prototype,"helper",void 0),a([z({type:Boolean}),s("design:type",Object)],K.prototype,"error",void 0),a([z({type:String}),s("design:type",Object)],K.prototype,"errorMessage",void 0),a([z({type:Boolean}),s("design:type",Object)],K.prototype,"required",void 0),a([z({type:Boolean}),s("design:type",Object)],K.prototype,"optional",void 0),K=a([d("randstad-form-group")],K);class X extends e{constructor(){super(...arguments),this.name="",this.size="24px"}static{this.styles=t`
|
|
1003
1043
|
:host {
|
|
1004
1044
|
display: inline-flex;
|
|
1005
1045
|
width: var(--icon-size, 24px);
|
|
@@ -1013,14 +1053,14 @@ function F(t,e){return(e,i,o)=>((t,e,i)=>(i.configurable=!0,i.enumerable=!0,Refl
|
|
|
1013
1053
|
height: var(--icon-size, 24px);
|
|
1014
1054
|
fill: var(--icon-color, currentColor);
|
|
1015
1055
|
}
|
|
1016
|
-
`}connectedCallback(){super.connectedCallback(),this.style.setProperty("--icon-size",this.size)}updated(t){t.has("size")&&this.style.setProperty("--icon-size",this.size)}async loadIcon(){try{const t=await fetch(`/assets/icons/${this.name}.svg`);if(!t.ok)throw new Error("Icon not found");const e=await t.text(),i=new DOMParser,o=i.parseFromString(e,"image/svg+xml").querySelector("svg");if(!o)throw new Error("No se encontró un elemento SVG válido");o.removeAttribute("fill"),o.setAttribute("width",this.size),o.setAttribute("height",this.size),o.querySelectorAll("[fill]").forEach((t=>t.removeAttribute("fill"))),o.setAttribute("fill","currentColor"),"innerHTML"in this.renderRoot&&(this.renderRoot.innerHTML=""),this.renderRoot.appendChild(o)}catch(t){console.error(`❌ Error cargando icono ${this.name}:`,t),"innerHTML"in this.renderRoot&&(this.renderRoot.innerHTML="<span>⚠️</span>")}}render(){return this.loadIcon(),null}}
|
|
1056
|
+
`}connectedCallback(){super.connectedCallback(),this.style.setProperty("--icon-size",this.size)}updated(t){t.has("size")&&this.style.setProperty("--icon-size",this.size)}async loadIcon(){try{const t=await fetch(`/assets/icons/${this.name}.svg`);if(!t.ok)throw new Error("Icon not found");const e=await t.text(),i=new DOMParser,o=i.parseFromString(e,"image/svg+xml").querySelector("svg");if(!o)throw new Error("No se encontró un elemento SVG válido");o.removeAttribute("fill"),o.setAttribute("width",this.size),o.setAttribute("height",this.size),o.querySelectorAll("[fill]").forEach((t=>t.removeAttribute("fill"))),o.setAttribute("fill","currentColor"),"innerHTML"in this.renderRoot&&(this.renderRoot.innerHTML=""),this.renderRoot.appendChild(o)}catch(t){console.error(`❌ Error cargando icono ${this.name}:`,t),"innerHTML"in this.renderRoot&&(this.renderRoot.innerHTML="<span>⚠️</span>")}}render(){return this.loadIcon(),null}}a([z({type:String}),s("design:type",Object)],X.prototype,"name",void 0),a([z({type:String}),s("design:type",Object)],X.prototype,"size",void 0),customElements.define("randstad-icon",X);let Q=class extends e{constructor(){super(...arguments),this.type="informative",this.icon="info",this.message="Este es un mensaje.",this.open=!1}static{this.styles=t`
|
|
1017
1057
|
:host {
|
|
1018
1058
|
display: block;
|
|
1019
1059
|
font-family: 'Graphik', sans-serif;
|
|
1020
1060
|
}
|
|
1021
1061
|
|
|
1022
1062
|
.container {
|
|
1023
|
-
${
|
|
1063
|
+
${_}
|
|
1024
1064
|
display: flex;
|
|
1025
1065
|
align-items: flex-start;
|
|
1026
1066
|
gap: 8px;
|
|
@@ -1066,7 +1106,7 @@ function F(t,e){return(e,i,o)=>((t,e,i)=>(i.configurable=!0,i.enumerable=!0,Refl
|
|
|
1066
1106
|
<randstad-icon class="icon" name="${this.icon}" size="24px" style="color: var(--icon-color);"></randstad-icon>
|
|
1067
1107
|
<span class="message">${this.message}</span>
|
|
1068
1108
|
</div>
|
|
1069
|
-
`}};
|
|
1109
|
+
`}};a([z({type:String}),s("design:type",String)],Q.prototype,"type",void 0),a([z({type:String}),s("design:type",String)],Q.prototype,"icon",void 0),a([z({type:String}),s("design:type",String)],Q.prototype,"message",void 0),a([z({type:Boolean}),s("design:type",Boolean)],Q.prototype,"open",void 0),Q=a([d("randstad-notice")],Q);let J=class extends e{constructor(){super(...arguments),this.open=!1,this.title="Título del modal",this.showNotice=!1,this.noticeType="informative",this.noticeMessage="",this.noticeIcon="info",this.showPrimaryButton=!1,this.primaryButtonLabel="Aceptar",this.showSecondaryButton=!1,this.secondaryButtonLabel="Cancelar",this.isFooterCustom=!1,this.modalWidth="500px",this.scrollable=!1,this.setScrollableMode=()=>{this.scrollable=window.innerWidth>940}}static{this.styles=t`
|
|
1070
1110
|
:host {
|
|
1071
1111
|
font-family: 'Graphik', sans-serif;
|
|
1072
1112
|
display: none;
|
|
@@ -1178,7 +1218,7 @@ function F(t,e){return(e,i,o)=>((t,e,i)=>(i.configurable=!0,i.enumerable=!0,Refl
|
|
|
1178
1218
|
}
|
|
1179
1219
|
|
|
1180
1220
|
.modal-subtitle {
|
|
1181
|
-
${
|
|
1221
|
+
${_}
|
|
1182
1222
|
margin: 0;
|
|
1183
1223
|
color: var(--secondary-color-60);
|
|
1184
1224
|
}
|
|
@@ -1265,7 +1305,7 @@ function F(t,e){return(e,i,o)=>((t,e,i)=>(i.configurable=!0,i.enumerable=!0,Refl
|
|
|
1265
1305
|
</div>
|
|
1266
1306
|
</div>
|
|
1267
1307
|
</div>
|
|
1268
|
-
`}};
|
|
1308
|
+
`}};a([z({type:Boolean,reflect:!0}),s("design:type",Object)],J.prototype,"open",void 0),a([z({type:String}),s("design:type",Object)],J.prototype,"title",void 0),a([z({type:String}),s("design:type",String)],J.prototype,"subtitle",void 0),a([z({type:Boolean}),s("design:type",Object)],J.prototype,"showNotice",void 0),a([z({type:String}),s("design:type",String)],J.prototype,"noticeType",void 0),a([z({type:String}),s("design:type",Object)],J.prototype,"noticeMessage",void 0),a([z({type:String}),s("design:type",Object)],J.prototype,"noticeIcon",void 0),a([z({type:Boolean}),s("design:type",Object)],J.prototype,"showPrimaryButton",void 0),a([z({type:String}),s("design:type",Object)],J.prototype,"primaryButtonLabel",void 0),a([z({type:Boolean}),s("design:type",Object)],J.prototype,"showSecondaryButton",void 0),a([z({type:String}),s("design:type",Object)],J.prototype,"secondaryButtonLabel",void 0),a([z({type:Boolean}),s("design:type",Object)],J.prototype,"isFooterCustom",void 0),a([z({type:String}),s("design:type",Object)],J.prototype,"modalWidth",void 0),a([T(),s("design:type",Object)],J.prototype,"scrollable",void 0),J=a([d("custom-modal")],J);let Z=class extends e{constructor(){super(...arguments),this.open=!1,this.type="default",this.icon="warning",this.title="Título del Popup",this.description="Descripción del popup",this.width="400px",this.buttonText="Aceptar",this.confirmText="Sí",this.cancelText="No",this.stackedActions=[],this._onBackgroundClick=t=>{const e=t.composedPath(),i=this.renderRoot.querySelector(".popup");i&&!e.includes(i)&&(this.dispatchEvent(new CustomEvent("popup-close",{detail:null})),this.open=!1)}}static{this.styles=t`
|
|
1269
1309
|
:host {
|
|
1270
1310
|
display: none;
|
|
1271
1311
|
position: fixed;
|
|
@@ -1327,13 +1367,13 @@ function F(t,e){return(e,i,o)=>((t,e,i)=>(i.configurable=!0,i.enumerable=!0,Refl
|
|
|
1327
1367
|
}
|
|
1328
1368
|
|
|
1329
1369
|
.popup-title {
|
|
1330
|
-
${
|
|
1370
|
+
${R}
|
|
1331
1371
|
margin: 0;
|
|
1332
1372
|
color: var(--secondary-color-80);
|
|
1333
1373
|
}
|
|
1334
1374
|
|
|
1335
1375
|
.popup-description {
|
|
1336
|
-
${
|
|
1376
|
+
${_}
|
|
1337
1377
|
margin: 0;
|
|
1338
1378
|
color: var(--secondary-color-60);
|
|
1339
1379
|
}
|
|
@@ -1361,7 +1401,7 @@ function F(t,e){return(e,i,o)=>((t,e,i)=>(i.configurable=!0,i.enumerable=!0,Refl
|
|
|
1361
1401
|
}
|
|
1362
1402
|
|
|
1363
1403
|
.action-item {
|
|
1364
|
-
${
|
|
1404
|
+
${N};
|
|
1365
1405
|
display: flex;
|
|
1366
1406
|
align-items: center;
|
|
1367
1407
|
gap: 16px;
|
|
@@ -1449,7 +1489,7 @@ function F(t,e){return(e,i,o)=>((t,e,i)=>(i.configurable=!0,i.enumerable=!0,Refl
|
|
|
1449
1489
|
`}
|
|
1450
1490
|
</div>
|
|
1451
1491
|
</div>
|
|
1452
|
-
`}};
|
|
1492
|
+
`}};a([z({type:Boolean,reflect:!0}),s("design:type",Object)],Z.prototype,"open",void 0),a([z({type:String}),s("design:type",String)],Z.prototype,"type",void 0),a([z({type:String}),s("design:type",Object)],Z.prototype,"icon",void 0),a([z({type:String}),s("design:type",Object)],Z.prototype,"title",void 0),a([z({type:String}),s("design:type",Object)],Z.prototype,"description",void 0),a([z({type:String}),s("design:type",Object)],Z.prototype,"width",void 0),a([z({type:String}),s("design:type",Object)],Z.prototype,"buttonText",void 0),a([z({type:String}),s("design:type",Object)],Z.prototype,"confirmText",void 0),a([z({type:String}),s("design:type",Object)],Z.prototype,"cancelText",void 0),a([z({type:Array}),s("design:type",Array)],Z.prototype,"stackedActions",void 0),Z=a([d("custom-popup")],Z);let tt=class extends e{constructor(){super(...arguments),this.value=0,this.max=5}static{this.styles=t`
|
|
1453
1493
|
:host {
|
|
1454
1494
|
display: inline-block;
|
|
1455
1495
|
width: 64px;
|
|
@@ -1462,7 +1502,7 @@ function F(t,e){return(e,i,o)=>((t,e,i)=>(i.configurable=!0,i.enumerable=!0,Refl
|
|
|
1462
1502
|
}
|
|
1463
1503
|
|
|
1464
1504
|
.circle-text {
|
|
1465
|
-
${
|
|
1505
|
+
${L};
|
|
1466
1506
|
text-align: center;
|
|
1467
1507
|
vertical-align: middle;
|
|
1468
1508
|
fill: var(--randstad-dark-blue-40);
|
|
@@ -1510,7 +1550,7 @@ function F(t,e){return(e,i,o)=>((t,e,i)=>(i.configurable=!0,i.enumerable=!0,Refl
|
|
|
1510
1550
|
${this.value} de ${this.max}
|
|
1511
1551
|
</text>
|
|
1512
1552
|
</svg>
|
|
1513
|
-
`}};
|
|
1553
|
+
`}};a([z({type:Number}),s("design:type",Object)],tt.prototype,"value",void 0),a([z({type:Number}),s("design:type",Object)],tt.prototype,"max",void 0),tt=a([d("progress-circle")],tt);
|
|
1514
1554
|
/**
|
|
1515
1555
|
* @license
|
|
1516
1556
|
* Copyright 2023 Google LLC
|
|
@@ -1521,7 +1561,7 @@ const et=Symbol("attachableController");let it;r||(it=new MutationObserver((t=>{
|
|
|
1521
1561
|
* @license
|
|
1522
1562
|
* Copyright 2021 Google LLC
|
|
1523
1563
|
* SPDX-License-Identifier: Apache-2.0
|
|
1524
|
-
*/const rt=["focusin","focusout","pointerdown"];class
|
|
1564
|
+
*/const rt=["focusin","focusout","pointerdown"];class nt extends e{constructor(){super(...arguments),this.visible=!1,this.inward=!1,this.attachableController=new ot(this,this.onControlChange.bind(this))}get htmlFor(){return this.attachableController.htmlFor}set htmlFor(t){this.attachableController.htmlFor=t}get control(){return this.attachableController.control}set control(t){this.attachableController.control=t}attach(t){this.attachableController.attach(t)}detach(){this.attachableController.detach()}connectedCallback(){super.connectedCallback(),this.setAttribute("aria-hidden","true")}handleEvent(t){if(!t[at]){switch(t.type){default:return;case"focusin":this.visible=this.control?.matches(":focus-visible")??!1;break;case"focusout":case"pointerdown":this.visible=!1}t[at]=!0}}onControlChange(t,e){if(!r)for(const i of rt)t?.removeEventListener(i,this),e?.addEventListener(i,this)}update(t){t.has("visible")&&this.dispatchEvent(new Event("visibility-changed")),super.update(t)}}a([z({type:Boolean,reflect:!0})],nt.prototype,"visible",void 0),a([z({type:Boolean,reflect:!0})],nt.prototype,"inward",void 0);const at=Symbol("handledByFocusRing"),st=t`:host{animation-delay:0s,calc(var(--md-focus-ring-duration, 600ms)*.25);animation-duration:calc(var(--md-focus-ring-duration, 600ms)*.25),calc(var(--md-focus-ring-duration, 600ms)*.75);animation-timing-function:cubic-bezier(0.2, 0, 0, 1);box-sizing:border-box;color:var(--md-focus-ring-color, var(--md-sys-color-secondary, #625b71));display:none;pointer-events:none;position:absolute}:host([visible]){display:flex}:host(:not([inward])){animation-name:outward-grow,outward-shrink;border-end-end-radius:calc(var(--md-focus-ring-shape-end-end, var(--md-focus-ring-shape, var(--md-sys-shape-corner-full, 9999px))) + var(--md-focus-ring-outward-offset, 2px));border-end-start-radius:calc(var(--md-focus-ring-shape-end-start, var(--md-focus-ring-shape, var(--md-sys-shape-corner-full, 9999px))) + var(--md-focus-ring-outward-offset, 2px));border-start-end-radius:calc(var(--md-focus-ring-shape-start-end, var(--md-focus-ring-shape, var(--md-sys-shape-corner-full, 9999px))) + var(--md-focus-ring-outward-offset, 2px));border-start-start-radius:calc(var(--md-focus-ring-shape-start-start, var(--md-focus-ring-shape, var(--md-sys-shape-corner-full, 9999px))) + var(--md-focus-ring-outward-offset, 2px));inset:calc(-1*var(--md-focus-ring-outward-offset, 2px));outline:var(--md-focus-ring-width, 3px) solid currentColor}:host([inward]){animation-name:inward-grow,inward-shrink;border-end-end-radius:calc(var(--md-focus-ring-shape-end-end, var(--md-focus-ring-shape, var(--md-sys-shape-corner-full, 9999px))) - var(--md-focus-ring-inward-offset, 0px));border-end-start-radius:calc(var(--md-focus-ring-shape-end-start, var(--md-focus-ring-shape, var(--md-sys-shape-corner-full, 9999px))) - var(--md-focus-ring-inward-offset, 0px));border-start-end-radius:calc(var(--md-focus-ring-shape-start-end, var(--md-focus-ring-shape, var(--md-sys-shape-corner-full, 9999px))) - var(--md-focus-ring-inward-offset, 0px));border-start-start-radius:calc(var(--md-focus-ring-shape-start-start, var(--md-focus-ring-shape, var(--md-sys-shape-corner-full, 9999px))) - var(--md-focus-ring-inward-offset, 0px));border:var(--md-focus-ring-width, 3px) solid currentColor;inset:var(--md-focus-ring-inward-offset, 0px)}@keyframes outward-grow{from{outline-width:0}to{outline-width:var(--md-focus-ring-active-width, 8px)}}@keyframes outward-shrink{from{outline-width:var(--md-focus-ring-active-width, 8px)}}@keyframes inward-grow{from{border-width:0}to{border-width:var(--md-focus-ring-active-width, 8px)}}@keyframes inward-shrink{from{border-width:var(--md-focus-ring-active-width, 8px)}}@media(prefers-reduced-motion){:host{animation:none}}
|
|
1525
1565
|
`
|
|
1526
1566
|
/**
|
|
1527
1567
|
* @license
|
|
@@ -1532,18 +1572,18 @@ const et=Symbol("attachableController");let it;r||(it=new MutationObserver((t=>{
|
|
|
1532
1572
|
* @license
|
|
1533
1573
|
* Copyright 2024 Google LLC
|
|
1534
1574
|
* SPDX-License-Identifier: Apache-2.0
|
|
1535
|
-
*/let
|
|
1575
|
+
*/let dt=class extends nt{};dt.styles=[st],dt=a([d("md-focus-ring")],dt);
|
|
1536
1576
|
/**
|
|
1537
1577
|
* @license
|
|
1538
1578
|
* Copyright 2021 Google LLC
|
|
1539
1579
|
* SPDX-License-Identifier: Apache-2.0
|
|
1540
1580
|
*/
|
|
1541
|
-
const
|
|
1581
|
+
const lt="cubic-bezier(0.2, 0, 0, 1)";
|
|
1542
1582
|
/**
|
|
1543
1583
|
* @license
|
|
1544
1584
|
* Copyright 2022 Google LLC
|
|
1545
1585
|
* SPDX-License-Identifier: Apache-2.0
|
|
1546
|
-
*/var ct;!function(t){t[t.INACTIVE=0]="INACTIVE",t[t.TOUCH_DELAY=1]="TOUCH_DELAY",t[t.HOLDING=2]="HOLDING",t[t.WAITING_FOR_CLICK=3]="WAITING_FOR_CLICK"}(ct||(ct={}));const pt=["click","contextmenu","pointercancel","pointerdown","pointerenter","pointerleave","pointerup"],ht=r?null:window.matchMedia("(forced-colors: active)");class ut extends e{constructor(){super(...arguments),this.disabled=!1,this.hovered=!1,this.pressed=!1,this.rippleSize="",this.rippleScale="",this.initialSize=0,this.state=ct.INACTIVE,this.checkBoundsAfterContextMenu=!1,this.attachableController=new ot(this,this.onControlChange.bind(this))}get htmlFor(){return this.attachableController.htmlFor}set htmlFor(t){this.attachableController.htmlFor=t}get control(){return this.attachableController.control}set control(t){this.attachableController.control=t}attach(t){this.attachableController.attach(t)}detach(){this.attachableController.detach()}connectedCallback(){super.connectedCallback(),this.setAttribute("aria-hidden","true")}render(){const t={hovered:this.hovered,pressed:this.pressed};return i`<div class="surface ${
|
|
1586
|
+
*/var ct;!function(t){t[t.INACTIVE=0]="INACTIVE",t[t.TOUCH_DELAY=1]="TOUCH_DELAY",t[t.HOLDING=2]="HOLDING",t[t.WAITING_FOR_CLICK=3]="WAITING_FOR_CLICK"}(ct||(ct={}));const pt=["click","contextmenu","pointercancel","pointerdown","pointerenter","pointerleave","pointerup"],ht=r?null:window.matchMedia("(forced-colors: active)");class ut extends e{constructor(){super(...arguments),this.disabled=!1,this.hovered=!1,this.pressed=!1,this.rippleSize="",this.rippleScale="",this.initialSize=0,this.state=ct.INACTIVE,this.checkBoundsAfterContextMenu=!1,this.attachableController=new ot(this,this.onControlChange.bind(this))}get htmlFor(){return this.attachableController.htmlFor}set htmlFor(t){this.attachableController.htmlFor=t}get control(){return this.attachableController.control}set control(t){this.attachableController.control=t}attach(t){this.attachableController.attach(t)}detach(){this.attachableController.detach()}connectedCallback(){super.connectedCallback(),this.setAttribute("aria-hidden","true")}render(){const t={hovered:this.hovered,pressed:this.pressed};return i`<div class="surface ${n(t)}"></div>`}update(t){t.has("disabled")&&this.disabled&&(this.hovered=!1,this.pressed=!1),super.update(t)}handlePointerenter(t){this.shouldReactToEvent(t)&&(this.hovered=!0)}handlePointerleave(t){this.shouldReactToEvent(t)&&(this.hovered=!1,this.state!==ct.INACTIVE&&this.endPressAnimation())}handlePointerup(t){if(this.shouldReactToEvent(t)){if(this.state!==ct.HOLDING)return this.state===ct.TOUCH_DELAY?(this.state=ct.WAITING_FOR_CLICK,void this.startPressAnimation(this.rippleStartEvent)):void 0;this.state=ct.WAITING_FOR_CLICK}}async handlePointerdown(t){if(this.shouldReactToEvent(t)){if(this.rippleStartEvent=t,!this.isTouch(t))return this.state=ct.WAITING_FOR_CLICK,void this.startPressAnimation(t);this.checkBoundsAfterContextMenu&&!this.inBounds(t)||(this.checkBoundsAfterContextMenu=!1,this.state=ct.TOUCH_DELAY,await new Promise((t=>{setTimeout(t,150)})),this.state===ct.TOUCH_DELAY&&(this.state=ct.HOLDING,this.startPressAnimation(t)))}}handleClick(){this.disabled||(this.state!==ct.WAITING_FOR_CLICK?this.state===ct.INACTIVE&&(this.startPressAnimation(),this.endPressAnimation()):this.endPressAnimation())}handlePointercancel(t){this.shouldReactToEvent(t)&&this.endPressAnimation()}handleContextmenu(){this.disabled||(this.checkBoundsAfterContextMenu=!0,this.endPressAnimation())}determineRippleSize(){const{height:t,width:e}=this.getBoundingClientRect(),i=Math.max(t,e),o=Math.max(.35*i,75),r=Math.floor(.2*i),n=Math.sqrt(e**2+t**2)+10;this.initialSize=r,this.rippleScale=""+(n+o)/r,this.rippleSize=`${r}px`}getNormalizedPointerEventCoords(t){const{scrollX:e,scrollY:i}=window,{left:o,top:r}=this.getBoundingClientRect(),n=e+o,a=i+r,{pageX:s,pageY:d}=t;return{x:s-n,y:d-a}}getTranslationCoordinates(t){const{height:e,width:i}=this.getBoundingClientRect(),o={x:(i-this.initialSize)/2,y:(e-this.initialSize)/2};let r;return r=t instanceof PointerEvent?this.getNormalizedPointerEventCoords(t):{x:i/2,y:e/2},r={x:r.x-this.initialSize/2,y:r.y-this.initialSize/2},{startPoint:r,endPoint:o}}startPressAnimation(t){if(!this.mdRoot)return;this.pressed=!0,this.growAnimation?.cancel(),this.determineRippleSize();const{startPoint:e,endPoint:i}=this.getTranslationCoordinates(t),o=`${e.x}px, ${e.y}px`,r=`${i.x}px, ${i.y}px`;this.growAnimation=this.mdRoot.animate({top:[0,0],left:[0,0],height:[this.rippleSize,this.rippleSize],width:[this.rippleSize,this.rippleSize],transform:[`translate(${o}) scale(1)`,`translate(${r}) scale(${this.rippleScale})`]},{pseudoElement:"::after",duration:450,easing:lt,fill:"forwards"})}async endPressAnimation(){this.rippleStartEvent=void 0,this.state=ct.INACTIVE;const t=this.growAnimation;let e=1/0;"number"==typeof t?.currentTime?e=t.currentTime:t?.currentTime&&(e=t.currentTime.to("ms").value),e>=225?this.pressed=!1:(await new Promise((t=>{setTimeout(t,225-e)})),this.growAnimation===t&&(this.pressed=!1))}shouldReactToEvent(t){if(this.disabled||!t.isPrimary)return!1;if(this.rippleStartEvent&&this.rippleStartEvent.pointerId!==t.pointerId)return!1;if("pointerenter"===t.type||"pointerleave"===t.type)return!this.isTouch(t);const e=1===t.buttons;return this.isTouch(t)||e}inBounds({x:t,y:e}){const{top:i,left:o,bottom:r,right:n}=this.getBoundingClientRect();return t>=o&&t<=n&&e>=i&&e<=r}isTouch({pointerType:t}){return"touch"===t}async handleEvent(t){if(!ht?.matches)switch(t.type){case"click":this.handleClick();break;case"contextmenu":this.handleContextmenu();break;case"pointercancel":this.handlePointercancel(t);break;case"pointerdown":await this.handlePointerdown(t);break;case"pointerenter":this.handlePointerenter(t);break;case"pointerleave":this.handlePointerleave(t);break;case"pointerup":this.handlePointerup(t)}}onControlChange(t,e){if(!r)for(const i of pt)t?.removeEventListener(i,this),e?.addEventListener(i,this)}}a([z({type:Boolean,reflect:!0})],ut.prototype,"disabled",void 0),a([T()],ut.prototype,"hovered",void 0),a([T()],ut.prototype,"pressed",void 0),a([A(".surface")],ut.prototype,"mdRoot",void 0);
|
|
1547
1587
|
/**
|
|
1548
1588
|
* @license
|
|
1549
1589
|
* Copyright 2024 Google LLC
|
|
@@ -1561,12 +1601,12 @@ const bt=t`:host{display:flex;margin:auto;pointer-events:none}:host([disabled]){
|
|
|
1561
1601
|
* Copyright 2021 Google LLC
|
|
1562
1602
|
* SPDX-License-Identifier: Apache-2.0
|
|
1563
1603
|
*/
|
|
1564
|
-
function
|
|
1604
|
+
function mt(t){return t.currentTarget===t.target&&(t.composedPath()[0]===t.target&&(!t.target.disabled&&!function(t){const e=yt;e&&(t.preventDefault(),t.stopImmediatePropagation());return async function(){yt=!0,await null,yt=!1}
|
|
1565
1605
|
/**
|
|
1566
1606
|
* @license
|
|
1567
1607
|
* Copyright 2023 Google LLC
|
|
1568
1608
|
* SPDX-License-Identifier: Apache-2.0
|
|
1569
|
-
*/(),e}(t)))}gt.styles=[bt],gt=
|
|
1609
|
+
*/(),e}(t)))}gt.styles=[bt],gt=a([d("md-ripple")],gt);let yt=!1;const ft=Symbol("internals"),vt=Symbol("privateInternals");
|
|
1570
1610
|
/**
|
|
1571
1611
|
* @license
|
|
1572
1612
|
* Copyright 2023 Google LLC
|
|
@@ -1578,35 +1618,35 @@ const xt=Symbol("createValidator"),wt=Symbol("getValidityAnchor"),kt=Symbol("pri
|
|
|
1578
1618
|
* Copyright 2023 Google LLC
|
|
1579
1619
|
* SPDX-License-Identifier: Apache-2.0
|
|
1580
1620
|
*/
|
|
1581
|
-
const Ct=Symbol("isFocusable"),Et=Symbol("privateIsFocusable"),Ot=Symbol("externalTabIndex"),
|
|
1621
|
+
const Ct=Symbol("isFocusable"),Et=Symbol("privateIsFocusable"),Ot=Symbol("externalTabIndex"),Dt=Symbol("isUpdatingTabIndex"),Mt=Symbol("updateTabIndex");
|
|
1582
1622
|
/**
|
|
1583
1623
|
* @license
|
|
1584
1624
|
* Copyright 2023 Google LLC
|
|
1585
1625
|
* SPDX-License-Identifier: Apache-2.0
|
|
1586
1626
|
*/
|
|
1587
|
-
const
|
|
1627
|
+
const Pt=Symbol("getFormValue"),jt=Symbol("getFormState");
|
|
1588
1628
|
/**
|
|
1589
1629
|
* @license
|
|
1590
1630
|
* Copyright 2023 Google LLC
|
|
1591
1631
|
* SPDX-License-Identifier: Apache-2.0
|
|
1592
1632
|
*/
|
|
1593
|
-
class
|
|
1633
|
+
class Ft{constructor(t){this.getCurrentState=t,this.currentValidity={validity:{},validationMessage:""}}getValidity(){const t=this.getCurrentState();if(!(!this.prevState||!this.equals(this.prevState,t)))return this.currentValidity;const{validity:e,validationMessage:i}=this.computeValidity(t);return this.prevState=this.copy(t),this.currentValidity={validationMessage:i,validity:{badInput:e.badInput,customError:e.customError,patternMismatch:e.patternMismatch,rangeOverflow:e.rangeOverflow,rangeUnderflow:e.rangeUnderflow,stepMismatch:e.stepMismatch,tooLong:e.tooLong,tooShort:e.tooShort,typeMismatch:e.typeMismatch,valueMissing:e.valueMissing}},this.currentValidity}}
|
|
1594
1634
|
/**
|
|
1595
1635
|
* @license
|
|
1596
1636
|
* Copyright 2023 Google LLC
|
|
1597
1637
|
* SPDX-License-Identifier: Apache-2.0
|
|
1598
|
-
*/class
|
|
1638
|
+
*/class zt extends Ft{computeValidity(t){this.radioElement||(this.radioElement=document.createElement("input"),this.radioElement.type="radio",this.radioElement.name="group");let e=!1,i=!1;for(const{checked:o,required:r}of t)r&&(e=!0),o&&(i=!0);return this.radioElement.checked=i,this.radioElement.required=e,{validity:{valueMissing:e&&!i},validationMessage:this.radioElement.validationMessage}}equals(t,e){if(t.length!==e.length)return!1;for(let i=0;i<t.length;i++){const o=t[i],r=e[i];if(o.checked!==r.checked||o.required!==r.required)return!1}return!0}copy(t){return t.map((({checked:t,required:e})=>({checked:t,required:e})))}}
|
|
1599
1639
|
/**
|
|
1600
1640
|
* @license
|
|
1601
1641
|
* Copyright 2022 Google LLC
|
|
1602
1642
|
* SPDX-License-Identifier: Apache-2.0
|
|
1603
|
-
*/class
|
|
1643
|
+
*/class Tt{get controls(){const t=this.host.getAttribute("name");return t&&this.root&&this.host.isConnected?Array.from(this.root.querySelectorAll(`[name="${t}"]`)):[this.host]}constructor(t){this.host=t,this.focused=!1,this.root=null,this.handleFocusIn=()=>{this.focused=!0,this.updateTabIndices()},this.handleFocusOut=()=>{this.focused=!1,this.updateTabIndices()},this.handleKeyDown=t=>{const e="ArrowDown"===t.key,i="ArrowUp"===t.key,o="ArrowLeft"===t.key,r="ArrowRight"===t.key;if(!(o||r||e||i))return;const n=this.controls;if(!n.length)return;t.preventDefault();const a="rtl"===getComputedStyle(this.host).direction?o||e:r||e,s=n.indexOf(this.host);let d=a?s+1:s-1;for(;d!==s;){d>=n.length?d=0:d<0&&(d=n.length-1);const t=n[d];if(!t.hasAttribute("disabled")){for(const e of n)e!==t&&(e.checked=!1,e.tabIndex=-1,e.blur());t.checked=!0,t.tabIndex=0,t.focus(),t.dispatchEvent(new Event("change",{bubbles:!0}));break}a?d++:d--}}}hostConnected(){this.root=this.host.getRootNode(),this.host.addEventListener("keydown",this.handleKeyDown),this.host.addEventListener("focusin",this.handleFocusIn),this.host.addEventListener("focusout",this.handleFocusOut),this.host.checked&&this.uncheckSiblings(),this.updateTabIndices()}hostDisconnected(){this.host.removeEventListener("keydown",this.handleKeyDown),this.host.removeEventListener("focusin",this.handleFocusIn),this.host.removeEventListener("focusout",this.handleFocusOut),this.updateTabIndices(),this.root=null}handleCheckedChange(){this.host.checked&&(this.uncheckSiblings(),this.updateTabIndices())}uncheckSiblings(){for(const t of this.controls)t!==this.host&&(t.checked=!1)}updateTabIndices(){const t=this.controls,e=t.find((t=>t.checked));if(e||this.focused){const i=e||this.host;i.tabIndex=0;for(const e of t)e!==i&&(e.tabIndex=-1)}else for(const e of t)e.tabIndex=0}}
|
|
1604
1644
|
/**
|
|
1605
1645
|
* @license
|
|
1606
1646
|
* Copyright 2018 Google LLC
|
|
1607
1647
|
* SPDX-License-Identifier: Apache-2.0
|
|
1608
|
-
*/var
|
|
1609
|
-
<div class="container ${
|
|
1648
|
+
*/var At;const Lt=Symbol("checked");let It=0;const _t=function(t){var e;class i extends t{constructor(){super(...arguments),this[e]=""}get validity(){return this[$t](),this[ft].validity}get validationMessage(){return this[$t](),this[ft].validationMessage}get willValidate(){return this[$t](),this[ft].willValidate}checkValidity(){return this[$t](),this[ft].checkValidity()}reportValidity(){return this[$t](),this[ft].reportValidity()}setCustomValidity(t){this[St]=t,this[$t]()}requestUpdate(t,e,i){super.requestUpdate(t,e,i),this[$t]()}firstUpdated(t){super.firstUpdated(t),this[$t]()}[(e=St,$t)](){if(r)return;this[kt]||(this[kt]=this[xt]());const{validity:t,validationMessage:e}=this[kt].getValidity(),i=!!this[St],o=this[St]||e;this[ft].setValidity({...t,customError:i},o,this[wt]()??void 0)}[xt](){throw new Error("Implement [createValidator]")}[wt](){throw new Error("Implement [getValidityAnchor]")}}return i}(function(t){class e extends t{get form(){return this[ft].form}get labels(){return this[ft].labels}get name(){return this.getAttribute("name")??""}set name(t){this.setAttribute("name",t)}get disabled(){return this.hasAttribute("disabled")}set disabled(t){this.toggleAttribute("disabled",t)}attributeChangedCallback(t,e,i){if("name"!==t&&"disabled"!==t)super.attributeChangedCallback(t,e,i);else{const i="disabled"===t?null!==e:e;this.requestUpdate(t,i)}}requestUpdate(t,e,i){super.requestUpdate(t,e,i),this[ft].setFormValue(this[Pt](),this[jt]())}[Pt](){throw new Error("Implement [getFormValue]")}[jt](){return this[Pt]()}formDisabledCallback(t){this.disabled=t}}return e.formAssociated=!0,a([z({noAccessor:!0})],e.prototype,"name",null),a([z({type:Boolean,noAccessor:!0})],e.prototype,"disabled",null),e}((Bt=function(t){var e,i,o;class r extends t{constructor(){super(...arguments),this[e]=!0,this[i]=null,this[o]=!1}get[Ct](){return this[Et]}set[Ct](t){this[Ct]!==t&&(this[Et]=t,this[Mt]())}connectedCallback(){super.connectedCallback(),this[Mt]()}attributeChangedCallback(t,e,i){if("tabindex"===t){if(this.requestUpdate("tabIndex",Number(e??-1)),!this[Dt])return this.hasAttribute("tabindex")?void(this[Ot]=this.tabIndex):(this[Ot]=null,void this[Mt]())}else super.attributeChangedCallback(t,e,i)}[(e=Et,i=Ot,o=Dt,Mt)](){const t=this[Ct]?0:-1,e=this[Ot]??t;this[Dt]=!0,this.tabIndex=e,this[Dt]=!1}}return a([z({noAccessor:!0})],r.prototype,"tabIndex",void 0),r}(e),class extends Bt{get[ft](){return this[vt]||(this[vt]=this.attachInternals()),this[vt]}})));var Bt;class Nt extends _t{get checked(){return this[Lt]}set checked(t){const e=this.checked;e!==t&&(this[Lt]=t,this.requestUpdate("checked",e),this.selectionController.handleCheckedChange())}constructor(){super(),this.maskId="cutout"+ ++It,this[At]=!1,this.required=!1,this.value="on",this.selectionController=new Tt(this),this.addController(this.selectionController),r||(this[ft].role="radio",this.addEventListener("click",this.handleClick.bind(this)),this.addEventListener("keydown",this.handleKeydown.bind(this)))}render(){const t={checked:this.checked};return i`
|
|
1649
|
+
<div class="container ${n(t)}" aria-hidden="true">
|
|
1610
1650
|
<md-ripple
|
|
1611
1651
|
part="ripple"
|
|
1612
1652
|
.control=${this}
|
|
@@ -1628,19 +1668,19 @@ class It{constructor(t){this.getCurrentState=t,this.currentValidity={validity:{}
|
|
|
1628
1668
|
|
|
1629
1669
|
<div class="touch-target"></div>
|
|
1630
1670
|
</div>
|
|
1631
|
-
`}updated(){this[
|
|
1671
|
+
`}updated(){this[ft].ariaChecked=String(this.checked)}async handleClick(t){this.disabled||(await 0,t.defaultPrevented||(mt(t)&&this.focus(),this.checked=!0,this.dispatchEvent(new Event("change",{bubbles:!0})),this.dispatchEvent(new InputEvent("input",{bubbles:!0,composed:!0}))))}async handleKeydown(t){await 0," "!==t.key||t.defaultPrevented||this.click()}[(At=Lt,Pt)](){return this.checked?this.value:null}[jt](){return String(this.checked)}formResetCallback(){this.checked=this.hasAttribute("checked")}formStateRestoreCallback(t){this.checked="true"===t}[xt](){return new zt((()=>this.selectionController?this.selectionController.controls:[this]))}[wt](){return this.container}}a([z({type:Boolean})],Nt.prototype,"checked",null),a([z({type:Boolean})],Nt.prototype,"required",void 0),a([z()],Nt.prototype,"value",void 0),a([A(".container")],Nt.prototype,"container",void 0);
|
|
1632
1672
|
/**
|
|
1633
1673
|
* @license
|
|
1634
1674
|
* Copyright 2024 Google LLC
|
|
1635
1675
|
* SPDX-License-Identifier: Apache-2.0
|
|
1636
1676
|
*/
|
|
1637
|
-
const
|
|
1677
|
+
const Rt=t`@layer{:host{display:inline-flex;height:var(--md-radio-icon-size, 20px);outline:none;position:relative;vertical-align:top;width:var(--md-radio-icon-size, 20px);-webkit-tap-highlight-color:rgba(0,0,0,0);cursor:pointer;--md-ripple-hover-color: var(--md-radio-hover-state-layer-color, var(--md-sys-color-on-surface, #1d1b20));--md-ripple-hover-opacity: var(--md-radio-hover-state-layer-opacity, 0.08);--md-ripple-pressed-color: var(--md-radio-pressed-state-layer-color, var(--md-sys-color-primary, #6750a4));--md-ripple-pressed-opacity: var(--md-radio-pressed-state-layer-opacity, 0.12)}:host([disabled]){cursor:default}:host([touch-target=wrapper]){margin:max(0px,(48px - var(--md-radio-icon-size, 20px))/2)}.container{display:flex;height:100%;place-content:center;place-items:center;width:100%}md-focus-ring{height:44px;inset:unset;width:44px}.checked{--md-ripple-hover-color: var(--md-radio-selected-hover-state-layer-color, var(--md-sys-color-primary, #6750a4));--md-ripple-hover-opacity: var(--md-radio-selected-hover-state-layer-opacity, 0.08);--md-ripple-pressed-color: var(--md-radio-selected-pressed-state-layer-color, var(--md-sys-color-on-surface, #1d1b20));--md-ripple-pressed-opacity: var(--md-radio-selected-pressed-state-layer-opacity, 0.12)}.touch-target{height:48px;position:absolute;width:48px}:host([touch-target=none]) .touch-target{display:none}md-ripple{border-radius:50%;height:var(--md-radio-state-layer-size, 40px);inset:unset;width:var(--md-radio-state-layer-size, 40px)}.icon{fill:var(--md-radio-icon-color, var(--md-sys-color-on-surface-variant, #49454f));inset:0;position:absolute}.outer.circle{transition:fill 50ms linear}.inner.circle{opacity:0;transform-origin:center;transition:opacity 50ms linear}.checked .icon{fill:var(--md-radio-selected-icon-color, var(--md-sys-color-primary, #6750a4))}.checked .inner.circle{animation:inner-circle-grow 300ms cubic-bezier(0.05, 0.7, 0.1, 1);opacity:1}@keyframes inner-circle-grow{from{transform:scale(0)}to{transform:scale(1)}}:host([disabled]) .circle{animation-duration:0s;transition-duration:0s}:host(:hover) .icon{fill:var(--md-radio-hover-icon-color, var(--md-sys-color-on-surface, #1d1b20))}:host(:focus-within) .icon{fill:var(--md-radio-focus-icon-color, var(--md-sys-color-on-surface, #1d1b20))}:host(:active) .icon{fill:var(--md-radio-pressed-icon-color, var(--md-sys-color-on-surface, #1d1b20))}:host([disabled]) .icon{fill:var(--md-radio-disabled-unselected-icon-color, var(--md-sys-color-on-surface, #1d1b20));opacity:var(--md-radio-disabled-unselected-icon-opacity, 0.38)}:host(:hover) .checked .icon{fill:var(--md-radio-selected-hover-icon-color, var(--md-sys-color-primary, #6750a4))}:host(:focus-within) .checked .icon{fill:var(--md-radio-selected-focus-icon-color, var(--md-sys-color-primary, #6750a4))}:host(:active) .checked .icon{fill:var(--md-radio-selected-pressed-icon-color, var(--md-sys-color-primary, #6750a4))}:host([disabled]) .checked .icon{fill:var(--md-radio-disabled-selected-icon-color, var(--md-sys-color-on-surface, #1d1b20));opacity:var(--md-radio-disabled-selected-icon-opacity, 0.38)}}@layer hcm{@media(forced-colors: active){.icon{fill:CanvasText}:host([disabled]) .icon{fill:GrayText;opacity:1}}}
|
|
1638
1678
|
`
|
|
1639
1679
|
/**
|
|
1640
1680
|
* @license
|
|
1641
1681
|
* Copyright 2022 Google LLC
|
|
1642
1682
|
* SPDX-License-Identifier: Apache-2.0
|
|
1643
|
-
*/;let qt=class extends
|
|
1683
|
+
*/;let qt=class extends Nt{};qt.styles=[Rt],qt=a([d("md-radio")],qt);let Vt=class extends e{constructor(){super(...arguments),this.name="radio-group",this.checked=!1,this.disabled=!1,this.error=!1}static{this.styles=t`
|
|
1644
1684
|
:host {
|
|
1645
1685
|
font-family: "Graphik", sans-serif;
|
|
1646
1686
|
}
|
|
@@ -1699,7 +1739,7 @@ const Ut=t`@layer{:host{display:inline-flex;height:var(--md-radio-icon-size, 20p
|
|
|
1699
1739
|
></md-radio>
|
|
1700
1740
|
<span>${this.checked?"On":"Off"} ${this.error?"Error":""}</span>
|
|
1701
1741
|
</label>
|
|
1702
|
-
`}};
|
|
1742
|
+
`}};a([z({type:String}),s("design:type",Object)],Vt.prototype,"name",void 0),a([z({type:Boolean}),s("design:type",Object)],Vt.prototype,"checked",void 0),a([z({type:Boolean}),s("design:type",Object)],Vt.prototype,"disabled",void 0),a([z({type:Boolean}),s("design:type",Object)],Vt.prototype,"error",void 0),Vt=a([d("custom-radio")],Vt);let Yt=class extends e{constructor(){super(...arguments),this.options=[],this.placeholder="Filtrar opciones...",this.defaultValue="",this.disabled=!1,this.value="",this.label="",this.labelColor="",this.filterable=!0,this.error=!1,this.required=!1,this.optional=!1,this.isMobile=!1,this.filteredOptions=[],this.filterValue="",this.isOpen=!1,this.mobileFilterValue="",this.highlightedIndex=-1,this._isCleared=!1,this.debounceTimeout=null,this.updateResponsiveModeBound=this.updateResponsiveMode.bind(this)}static{this.styles=t`
|
|
1703
1743
|
:host {
|
|
1704
1744
|
display: block;
|
|
1705
1745
|
font-family: 'Graphik', sans-serif;
|
|
@@ -1742,7 +1782,7 @@ const Ut=t`@layer{:host{display:inline-flex;height:var(--md-radio-icon-size, 20p
|
|
|
1742
1782
|
}
|
|
1743
1783
|
|
|
1744
1784
|
.form-label {
|
|
1745
|
-
${
|
|
1785
|
+
${_}
|
|
1746
1786
|
display: flex;
|
|
1747
1787
|
align-items: baseline;
|
|
1748
1788
|
flex-direction: row;
|
|
@@ -1998,7 +2038,7 @@ const Ut=t`@layer{:host{display:inline-flex;height:var(--md-radio-icon-size, 20p
|
|
|
1998
2038
|
|
|
1999
2039
|
.optional {
|
|
2000
2040
|
color: var(--secondary-color-60);
|
|
2001
|
-
${
|
|
2041
|
+
${L}
|
|
2002
2042
|
}
|
|
2003
2043
|
|
|
2004
2044
|
/* Estilos por defecto del icon para mobile */
|
|
@@ -2113,14 +2153,14 @@ const Ut=t`@layer{:host{display:inline-flex;height:var(--md-radio-icon-size, 20p
|
|
|
2113
2153
|
</button>
|
|
2114
2154
|
</div>
|
|
2115
2155
|
<ul class="options-list">
|
|
2116
|
-
${this.filteredOptions.map(((t,e)=>{const o="string"==typeof t?t:t.label,r="object"==typeof t&&t.disabled,
|
|
2156
|
+
${this.filteredOptions.map(((t,e)=>{const o="string"==typeof t?t:t.label,r="object"==typeof t&&t.disabled,n="object"==typeof t?t.icon:void 0;return i`
|
|
2117
2157
|
<li
|
|
2118
2158
|
class="${r?"disabled":""} ${e===this.highlightedIndex?"highlighted":""}"
|
|
2119
2159
|
role="option"
|
|
2120
2160
|
aria-selected="${e===this.highlightedIndex}"
|
|
2121
2161
|
@click="${()=>{r||this.handleSelect(t)}}"
|
|
2122
2162
|
>
|
|
2123
|
-
${this.renderOptionIcon(
|
|
2163
|
+
${this.renderOptionIcon(n)}
|
|
2124
2164
|
${o}
|
|
2125
2165
|
</li>
|
|
2126
2166
|
`}))}
|
|
@@ -2129,14 +2169,14 @@ const Ut=t`@layer{:host{display:inline-flex;height:var(--md-radio-icon-size, 20p
|
|
|
2129
2169
|
</div>
|
|
2130
2170
|
`:!t&&this.isOpen&&this.filteredOptions.length>0?i`
|
|
2131
2171
|
<ul class="options-list">
|
|
2132
|
-
${this.filteredOptions.map(((t,e)=>{const o="string"==typeof t?t:t.label,r="object"==typeof t&&t.disabled,
|
|
2172
|
+
${this.filteredOptions.map(((t,e)=>{const o="string"==typeof t?t:t.label,r="object"==typeof t&&t.disabled,n="object"==typeof t?t.icon:void 0;return i`
|
|
2133
2173
|
<li
|
|
2134
2174
|
class="${r?"disabled":""} ${e===this.highlightedIndex?"highlighted":""}"
|
|
2135
2175
|
role="option"
|
|
2136
2176
|
aria-selected="${e===this.highlightedIndex}"
|
|
2137
2177
|
@click="${()=>{r||this.handleSelect(t)}}"
|
|
2138
2178
|
>
|
|
2139
|
-
${this.renderOptionIcon(
|
|
2179
|
+
${this.renderOptionIcon(n)}
|
|
2140
2180
|
${o}
|
|
2141
2181
|
</li>
|
|
2142
2182
|
`}))}
|
|
@@ -2144,7 +2184,7 @@ const Ut=t`@layer{:host{display:inline-flex;height:var(--md-radio-icon-size, 20p
|
|
|
2144
2184
|
`:""}
|
|
2145
2185
|
</div>
|
|
2146
2186
|
</div>
|
|
2147
|
-
`}};
|
|
2187
|
+
`}};a([z({type:Array}),s("design:type",Array)],Yt.prototype,"options",void 0),a([z({type:String}),s("design:type",Object)],Yt.prototype,"placeholder",void 0),a([z({type:String,attribute:"default-value"}),s("design:type",Object)],Yt.prototype,"defaultValue",void 0),a([z({type:Boolean}),s("design:type",Object)],Yt.prototype,"disabled",void 0),a([z({type:Object}),s("design:type",Object)],Yt.prototype,"value",void 0),a([z({type:String}),s("design:type",Object)],Yt.prototype,"label",void 0),a([z({type:String}),s("design:type",Object)],Yt.prototype,"labelColor",void 0),a([z({type:Boolean}),s("design:type",Object)],Yt.prototype,"filterable",void 0),a([z({type:Number}),s("design:type",Number)],Yt.prototype,"maxLength",void 0),a([z({type:Boolean,reflect:!0}),s("design:type",Boolean)],Yt.prototype,"error",void 0),a([z({type:Boolean}),s("design:type",Object)],Yt.prototype,"required",void 0),a([z({type:Boolean}),s("design:type",Object)],Yt.prototype,"optional",void 0),a([T(),s("design:type",Boolean)],Yt.prototype,"isMobile",void 0),a([T(),s("design:type",Array)],Yt.prototype,"filteredOptions",void 0),a([T(),s("design:type",Object)],Yt.prototype,"filterValue",void 0),a([T(),s("design:type",Object)],Yt.prototype,"isOpen",void 0),a([T(),s("design:type",Object)],Yt.prototype,"mobileFilterValue",void 0),a([T(),s("design:type",Object)],Yt.prototype,"highlightedIndex",void 0),a([T(),s("design:type",Boolean)],Yt.prototype,"_isCleared",void 0),Yt=a([d("filterable-select")],Yt);const Wt=new CSSStyleSheet;Wt.replaceSync("\n @font-face {\n font-family: 'Graphik';\n src: url('/src/assets/font/Graphik-Regular.woff2') format('woff2'),\n url('/src/assets/font/Graphik-Regular.woff') format('woff'),\n url('/src/assets/font/Graphik-Regular.eot') format('embedded-opentype');\n font-weight: normal;\n font-style: normal;\n }\n\n .body-s {\n font-weight: 400;\n font-size: 14px;\n line-height: 100%;\n letter-spacing: 0%;\n color: green;\n }\n\n .body-l {\n font-family: Graphik;\n font-size: 18px;\n font-style: normal;\n font-weight: 400;\n line-height: 30px;\n }\n");class Ut extends e{static{this.styles=[Wt,t`
|
|
2148
2188
|
:host {
|
|
2149
2189
|
display: flex;
|
|
2150
2190
|
position: fixed;
|
|
@@ -2214,7 +2254,7 @@ const Ut=t`@layer{:host{display:inline-flex;height:var(--md-radio-icon-size, 20p
|
|
|
2214
2254
|
}
|
|
2215
2255
|
|
|
2216
2256
|
.container {
|
|
2217
|
-
${
|
|
2257
|
+
${I};
|
|
2218
2258
|
display: flex;
|
|
2219
2259
|
align-items: center;
|
|
2220
2260
|
box-sizing: border-box;
|
|
@@ -2280,7 +2320,7 @@ const Ut=t`@layer{:host{display:inline-flex;height:var(--md-radio-icon-size, 20p
|
|
|
2280
2320
|
<randstad-icon name=${this.icon} size="24px" color="white"></randstad-icon>
|
|
2281
2321
|
<span class="message">${this.message}</span>
|
|
2282
2322
|
</div>
|
|
2283
|
-
`}}customElements.define("randstad-snackbar",
|
|
2323
|
+
`}}customElements.define("randstad-snackbar",Ut);let Gt=class extends e{constructor(){super(...arguments),this.totalSteps=4,this.currentStep=0}static{this.styles=t`
|
|
2284
2324
|
.stepper {
|
|
2285
2325
|
display: flex;
|
|
2286
2326
|
gap: 20px;
|
|
@@ -2380,7 +2420,7 @@ const Ut=t`@layer{:host{display:inline-flex;height:var(--md-radio-icon-size, 20p
|
|
|
2380
2420
|
</div>
|
|
2381
2421
|
`))}
|
|
2382
2422
|
</div>
|
|
2383
|
-
`}};
|
|
2423
|
+
`}};a([z({type:Number}),s("design:type",Object)],Gt.prototype,"totalSteps",void 0),a([z({type:Number}),s("design:type",Object)],Gt.prototype,"currentStep",void 0),Gt=a([d("custom-stepper")],Gt);let Ht=class extends e{constructor(){super(...arguments),this.tabs=[],this.selected="",this.internalSelected="",this.showPrev=!1,this.showNext=!1,this.SCROLL_OFFSET=56,this.handleScroll=()=>{const t=this.renderRoot.querySelector(".tab-wrapper");if(!t)return;const{scrollLeft:e,scrollWidth:i,clientWidth:o}=t;this.showPrev=e>0,this.showNext=e+o<i-1}}static{this.styles=t`
|
|
2384
2424
|
:host {
|
|
2385
2425
|
display: block;
|
|
2386
2426
|
border-bottom: 1px solid #E7E8EC;
|
|
@@ -2393,7 +2433,7 @@ const Ut=t`@layer{:host{display:inline-flex;height:var(--md-radio-icon-size, 20p
|
|
|
2393
2433
|
}
|
|
2394
2434
|
|
|
2395
2435
|
.tab {
|
|
2396
|
-
${
|
|
2436
|
+
${N};
|
|
2397
2437
|
display: flex;
|
|
2398
2438
|
gap: 8px;
|
|
2399
2439
|
flex-direction: row;
|
|
@@ -2491,7 +2531,7 @@ const Ut=t`@layer{:host{display:inline-flex;height:var(--md-radio-icon-size, 20p
|
|
|
2491
2531
|
|
|
2492
2532
|
@media (max-width: 940px) {
|
|
2493
2533
|
.tab {
|
|
2494
|
-
${
|
|
2534
|
+
${_};
|
|
2495
2535
|
padding: 16px;
|
|
2496
2536
|
}
|
|
2497
2537
|
}
|
|
@@ -2519,7 +2559,7 @@ const Ut=t`@layer{:host{display:inline-flex;height:var(--md-radio-icon-size, 20p
|
|
|
2519
2559
|
</button>
|
|
2520
2560
|
`:null}
|
|
2521
2561
|
</div>
|
|
2522
|
-
`}};
|
|
2562
|
+
`}};a([z({type:Array}),s("design:type",Array)],Ht.prototype,"tabs",void 0),a([z({type:String}),s("design:type",String)],Ht.prototype,"selected",void 0),a([T(),s("design:type",String)],Ht.prototype,"internalSelected",void 0),a([T(),s("design:type",Object)],Ht.prototype,"showPrev",void 0),a([T(),s("design:type",Object)],Ht.prototype,"showNext",void 0),Ht=a([d("tabs-bar")],Ht);let Kt=class extends e{constructor(){super(...arguments),this.files=[],this.loading=!1,this.progress=0,this.isDragging=!1,this.disabled=!1}static{this.styles=t`
|
|
2523
2563
|
|
|
2524
2564
|
:host {
|
|
2525
2565
|
font-family: 'Graphik', sans-serif;
|
|
@@ -2554,28 +2594,28 @@ const Ut=t`@layer{:host{display:inline-flex;height:var(--md-radio-icon-size, 20p
|
|
|
2554
2594
|
}
|
|
2555
2595
|
|
|
2556
2596
|
.text-main {
|
|
2557
|
-
${
|
|
2597
|
+
${I};
|
|
2558
2598
|
text-align: center;
|
|
2559
2599
|
vertical-align: middle;
|
|
2560
2600
|
color: var(--secondary-color-80);
|
|
2561
2601
|
}
|
|
2562
2602
|
|
|
2563
2603
|
.text-secondary {
|
|
2564
|
-
${
|
|
2604
|
+
${L};
|
|
2565
2605
|
text-align: center;
|
|
2566
2606
|
vertical-align: middle;
|
|
2567
2607
|
color: var(--secondary-color-60);
|
|
2568
2608
|
}
|
|
2569
2609
|
|
|
2570
2610
|
.text-tertiary {
|
|
2571
|
-
${
|
|
2611
|
+
${L};
|
|
2572
2612
|
text-align: center;
|
|
2573
2613
|
vertical-align: middle;
|
|
2574
2614
|
color: var(--secondary-color-40);
|
|
2575
2615
|
}
|
|
2576
2616
|
|
|
2577
2617
|
.button {
|
|
2578
|
-
${
|
|
2618
|
+
${L};
|
|
2579
2619
|
background-color: var(--primary-color);
|
|
2580
2620
|
border: none;
|
|
2581
2621
|
padding: 4px 16px;
|
|
@@ -2643,5 +2683,658 @@ const Ut=t`@layer{:host{display:inline-flex;height:var(--md-radio-icon-size, 20p
|
|
|
2643
2683
|
</label>
|
|
2644
2684
|
`}
|
|
2645
2685
|
</div>
|
|
2646
|
-
`}};n([T({type:Array}),a("design:type",Array)],Yt.prototype,"files",void 0),n([L(),a("design:type",Object)],Yt.prototype,"loading",void 0),n([L(),a("design:type",Object)],Yt.prototype,"progress",void 0),n([L(),a("design:type",Object)],Yt.prototype,"isDragging",void 0),n([T({type:Boolean,reflect:!0}),a("design:type",Object)],Yt.prototype,"disabled",void 0),Yt=n([l("upload-image")],Yt);export{N as AccordionList,V as AccordionPanel,H as CarouselCard,K as Checkbox,Q as CustomModal,Z as CustomPopup,Vt as CustomRadio,Kt as CustomStepper,Nt as FilterableSelect,Y as FormGroup,X as IconComponent,tt as ProgressCircle,G as RandstadButton,W as RandstadForm,J as RandstadNotice,Wt as TabsBar,Yt as UploadImage};
|
|
2686
|
+
`}};a([z({type:Array}),s("design:type",Array)],Kt.prototype,"files",void 0),a([T(),s("design:type",Object)],Kt.prototype,"loading",void 0),a([T(),s("design:type",Object)],Kt.prototype,"progress",void 0),a([T(),s("design:type",Object)],Kt.prototype,"isDragging",void 0),a([z({type:Boolean,reflect:!0}),s("design:type",Object)],Kt.prototype,"disabled",void 0),Kt=a([d("upload-image")],Kt);const Xt=6048e5,Qt=Symbol.for("constructDateFrom");function Jt(t,e){return"function"==typeof t?t(e):t&&"object"==typeof t&&Qt in t?t[Qt](e):t instanceof Date?new t.constructor(e):new Date(e)}function Zt(t,e){return Jt(e||t,t)}function te(t,e,i){const o=Zt(t,i?.in);if(isNaN(e))return Jt(t,NaN);if(!e)return o;const r=o.getDate(),n=Jt(t,o.getTime());n.setMonth(o.getMonth()+e+1,0);return r>=n.getDate()?n:(o.setFullYear(n.getFullYear(),n.getMonth(),r),o)}let ee={};function ie(){return ee}function oe(t,e){const i=ie(),o=e?.weekStartsOn??e?.locale?.options?.weekStartsOn??i.weekStartsOn??i.locale?.options?.weekStartsOn??0,r=Zt(t,e?.in),n=r.getDay(),a=(n<o?7:0)+n-o;return r.setDate(r.getDate()-a),r.setHours(0,0,0,0),r}function re(t,e){return oe(t,{...e,weekStartsOn:1})}function ne(t,e){const i=Zt(t,e?.in),o=i.getFullYear(),r=Jt(i,0);r.setFullYear(o+1,0,4),r.setHours(0,0,0,0);const n=re(r),a=Jt(i,0);a.setFullYear(o,0,4),a.setHours(0,0,0,0);const s=re(a);return i.getTime()>=n.getTime()?o+1:i.getTime()>=s.getTime()?o:o-1}function ae(t){const e=Zt(t),i=new Date(Date.UTC(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()));return i.setUTCFullYear(e.getFullYear()),+t-+i}function se(t,...e){const i=Jt.bind(null,e.find((t=>"object"==typeof t)));return e.map(i)}function de(t,e){const i=Zt(t,e?.in);return i.setHours(0,0,0,0),i}function le(t,e,i){return te(t,12*e,i)}function ce(t){return!(!((e=t)instanceof Date||"object"==typeof e&&"[object Date]"===Object.prototype.toString.call(e))&&"number"!=typeof t||isNaN(+Zt(t)));var e}function pe(t,e){const i=Zt(t,e?.in);return i.setDate(1),i.setHours(0,0,0,0),i}const he={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}};function ue(t){return(e={})=>{const i=e.width?String(e.width):t.defaultWidth;return t.formats[i]||t.formats[t.defaultWidth]}}const be={date:ue({formats:{full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},defaultWidth:"full"}),time:ue({formats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},defaultWidth:"full"}),dateTime:ue({formats:{full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},defaultWidth:"full"})},ge={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"};function me(t){return(e,i)=>{let o;if("formatting"===(i?.context?String(i.context):"standalone")&&t.formattingValues){const e=t.defaultFormattingWidth||t.defaultWidth,r=i?.width?String(i.width):e;o=t.formattingValues[r]||t.formattingValues[e]}else{const e=t.defaultWidth,r=i?.width?String(i.width):t.defaultWidth;o=t.values[r]||t.values[e]}return o[t.argumentCallback?t.argumentCallback(e):e]}}function ye(t){return(e,i={})=>{const o=i.width,r=o&&t.matchPatterns[o]||t.matchPatterns[t.defaultMatchWidth],n=e.match(r);if(!n)return null;const a=n[0],s=o&&t.parsePatterns[o]||t.parsePatterns[t.defaultParseWidth],d=Array.isArray(s)?function(t,e){for(let i=0;i<t.length;i++)if(e(t[i]))return i;return}(s,(t=>t.test(a))):function(t,e){for(const i in t)if(Object.prototype.hasOwnProperty.call(t,i)&&e(t[i]))return i;return}(s,(t=>t.test(a)));let l;l=t.valueCallback?t.valueCallback(d):d,l=i.valueCallback?i.valueCallback(l):l;return{value:l,rest:e.slice(a.length)}}}var fe;const ve={code:"en-US",formatDistance:(t,e,i)=>{let o;const r=he[t];return o="string"==typeof r?r:1===e?r.one:r.other.replace("{{count}}",e.toString()),i?.addSuffix?i.comparison&&i.comparison>0?"in "+o:o+" ago":o},formatLong:be,formatRelative:(t,e,i,o)=>ge[t],localize:{ordinalNumber:(t,e)=>{const i=Number(t),o=i%100;if(o>20||o<10)switch(o%10){case 1:return i+"st";case 2:return i+"nd";case 3:return i+"rd"}return i+"th"},era:me({values:{narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},defaultWidth:"wide"}),quarter:me({values:{narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},defaultWidth:"wide",argumentCallback:t=>t-1}),month:me({values:{narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},defaultWidth:"wide"}),day:me({values:{narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},defaultWidth:"wide"}),dayPeriod:me({values:{narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},defaultWidth:"wide",formattingValues:{narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},defaultFormattingWidth:"wide"})},match:{ordinalNumber:(fe={matchPattern:/^(\d+)(th|st|nd|rd)?/i,parsePattern:/\d+/i,valueCallback:t=>parseInt(t,10)},(t,e={})=>{const i=t.match(fe.matchPattern);if(!i)return null;const o=i[0],r=t.match(fe.parsePattern);if(!r)return null;let n=fe.valueCallback?fe.valueCallback(r[0]):r[0];return n=e.valueCallback?e.valueCallback(n):n,{value:n,rest:t.slice(o.length)}}),era:ye({matchPatterns:{narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},defaultMatchWidth:"wide",parsePatterns:{any:[/^b/i,/^(a|c)/i]},defaultParseWidth:"any"}),quarter:ye({matchPatterns:{narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},defaultMatchWidth:"wide",parsePatterns:{any:[/1/i,/2/i,/3/i,/4/i]},defaultParseWidth:"any",valueCallback:t=>t+1}),month:ye({matchPatterns:{narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},defaultParseWidth:"any"}),day:ye({matchPatterns:{narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},defaultParseWidth:"any"}),dayPeriod:ye({matchPatterns:{narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},defaultMatchWidth:"any",parsePatterns:{any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},defaultParseWidth:"any"})},options:{weekStartsOn:0,firstWeekContainsDate:1}};function xe(t,e){const i=Zt(t,e?.in),o=function(t,e){const[i,o]=se(0,t,e),r=de(i),n=de(o),a=+r-ae(r),s=+n-ae(n);return Math.round((a-s)/864e5)}(i,function(t,e){const i=Zt(t,e?.in);return i.setFullYear(i.getFullYear(),0,1),i.setHours(0,0,0,0),i}(i));return o+1}function we(t,e){const i=Zt(t,e?.in),o=+re(i)-+function(t,e){const i=ne(t,e),o=Jt(t,0);return o.setFullYear(i,0,4),o.setHours(0,0,0,0),re(o)}(i);return Math.round(o/Xt)+1}function ke(t,e){const i=Zt(t,e?.in),o=i.getFullYear(),r=ie(),n=e?.firstWeekContainsDate??e?.locale?.options?.firstWeekContainsDate??r.firstWeekContainsDate??r.locale?.options?.firstWeekContainsDate??1,a=Jt(e?.in||t,0);a.setFullYear(o+1,0,n),a.setHours(0,0,0,0);const s=oe(a,e),d=Jt(e?.in||t,0);d.setFullYear(o,0,n),d.setHours(0,0,0,0);const l=oe(d,e);return+i>=+s?o+1:+i>=+l?o:o-1}function $e(t,e){const i=Zt(t,e?.in),o=+oe(i,e)-+function(t,e){const i=ie(),o=e?.firstWeekContainsDate??e?.locale?.options?.firstWeekContainsDate??i.firstWeekContainsDate??i.locale?.options?.firstWeekContainsDate??1,r=ke(t,e),n=Jt(e?.in||t,0);return n.setFullYear(r,0,o),n.setHours(0,0,0,0),oe(n,e)}(i,e);return Math.round(o/Xt)+1}function Se(t,e){return(t<0?"-":"")+Math.abs(t).toString().padStart(e,"0")}const Ce={y(t,e){const i=t.getFullYear(),o=i>0?i:1-i;return Se("yy"===e?o%100:o,e.length)},M(t,e){const i=t.getMonth();return"M"===e?String(i+1):Se(i+1,2)},d:(t,e)=>Se(t.getDate(),e.length),a(t,e){const i=t.getHours()/12>=1?"pm":"am";switch(e){case"a":case"aa":return i.toUpperCase();case"aaa":return i;case"aaaaa":return i[0];default:return"am"===i?"a.m.":"p.m."}},h:(t,e)=>Se(t.getHours()%12||12,e.length),H:(t,e)=>Se(t.getHours(),e.length),m:(t,e)=>Se(t.getMinutes(),e.length),s:(t,e)=>Se(t.getSeconds(),e.length),S(t,e){const i=e.length,o=t.getMilliseconds();return Se(Math.trunc(o*Math.pow(10,i-3)),e.length)}},Ee="midnight",Oe="noon",De="morning",Me="afternoon",Pe="evening",je="night",Fe={G:function(t,e,i){const o=t.getFullYear()>0?1:0;switch(e){case"G":case"GG":case"GGG":return i.era(o,{width:"abbreviated"});case"GGGGG":return i.era(o,{width:"narrow"});default:return i.era(o,{width:"wide"})}},y:function(t,e,i){if("yo"===e){const e=t.getFullYear(),o=e>0?e:1-e;return i.ordinalNumber(o,{unit:"year"})}return Ce.y(t,e)},Y:function(t,e,i,o){const r=ke(t,o),n=r>0?r:1-r;if("YY"===e){return Se(n%100,2)}return"Yo"===e?i.ordinalNumber(n,{unit:"year"}):Se(n,e.length)},R:function(t,e){return Se(ne(t),e.length)},u:function(t,e){return Se(t.getFullYear(),e.length)},Q:function(t,e,i){const o=Math.ceil((t.getMonth()+1)/3);switch(e){case"Q":return String(o);case"QQ":return Se(o,2);case"Qo":return i.ordinalNumber(o,{unit:"quarter"});case"QQQ":return i.quarter(o,{width:"abbreviated",context:"formatting"});case"QQQQQ":return i.quarter(o,{width:"narrow",context:"formatting"});default:return i.quarter(o,{width:"wide",context:"formatting"})}},q:function(t,e,i){const o=Math.ceil((t.getMonth()+1)/3);switch(e){case"q":return String(o);case"qq":return Se(o,2);case"qo":return i.ordinalNumber(o,{unit:"quarter"});case"qqq":return i.quarter(o,{width:"abbreviated",context:"standalone"});case"qqqqq":return i.quarter(o,{width:"narrow",context:"standalone"});default:return i.quarter(o,{width:"wide",context:"standalone"})}},M:function(t,e,i){const o=t.getMonth();switch(e){case"M":case"MM":return Ce.M(t,e);case"Mo":return i.ordinalNumber(o+1,{unit:"month"});case"MMM":return i.month(o,{width:"abbreviated",context:"formatting"});case"MMMMM":return i.month(o,{width:"narrow",context:"formatting"});default:return i.month(o,{width:"wide",context:"formatting"})}},L:function(t,e,i){const o=t.getMonth();switch(e){case"L":return String(o+1);case"LL":return Se(o+1,2);case"Lo":return i.ordinalNumber(o+1,{unit:"month"});case"LLL":return i.month(o,{width:"abbreviated",context:"standalone"});case"LLLLL":return i.month(o,{width:"narrow",context:"standalone"});default:return i.month(o,{width:"wide",context:"standalone"})}},w:function(t,e,i,o){const r=$e(t,o);return"wo"===e?i.ordinalNumber(r,{unit:"week"}):Se(r,e.length)},I:function(t,e,i){const o=we(t);return"Io"===e?i.ordinalNumber(o,{unit:"week"}):Se(o,e.length)},d:function(t,e,i){return"do"===e?i.ordinalNumber(t.getDate(),{unit:"date"}):Ce.d(t,e)},D:function(t,e,i){const o=xe(t);return"Do"===e?i.ordinalNumber(o,{unit:"dayOfYear"}):Se(o,e.length)},E:function(t,e,i){const o=t.getDay();switch(e){case"E":case"EE":case"EEE":return i.day(o,{width:"abbreviated",context:"formatting"});case"EEEEE":return i.day(o,{width:"narrow",context:"formatting"});case"EEEEEE":return i.day(o,{width:"short",context:"formatting"});default:return i.day(o,{width:"wide",context:"formatting"})}},e:function(t,e,i,o){const r=t.getDay(),n=(r-o.weekStartsOn+8)%7||7;switch(e){case"e":return String(n);case"ee":return Se(n,2);case"eo":return i.ordinalNumber(n,{unit:"day"});case"eee":return i.day(r,{width:"abbreviated",context:"formatting"});case"eeeee":return i.day(r,{width:"narrow",context:"formatting"});case"eeeeee":return i.day(r,{width:"short",context:"formatting"});default:return i.day(r,{width:"wide",context:"formatting"})}},c:function(t,e,i,o){const r=t.getDay(),n=(r-o.weekStartsOn+8)%7||7;switch(e){case"c":return String(n);case"cc":return Se(n,e.length);case"co":return i.ordinalNumber(n,{unit:"day"});case"ccc":return i.day(r,{width:"abbreviated",context:"standalone"});case"ccccc":return i.day(r,{width:"narrow",context:"standalone"});case"cccccc":return i.day(r,{width:"short",context:"standalone"});default:return i.day(r,{width:"wide",context:"standalone"})}},i:function(t,e,i){const o=t.getDay(),r=0===o?7:o;switch(e){case"i":return String(r);case"ii":return Se(r,e.length);case"io":return i.ordinalNumber(r,{unit:"day"});case"iii":return i.day(o,{width:"abbreviated",context:"formatting"});case"iiiii":return i.day(o,{width:"narrow",context:"formatting"});case"iiiiii":return i.day(o,{width:"short",context:"formatting"});default:return i.day(o,{width:"wide",context:"formatting"})}},a:function(t,e,i){const o=t.getHours()/12>=1?"pm":"am";switch(e){case"a":case"aa":return i.dayPeriod(o,{width:"abbreviated",context:"formatting"});case"aaa":return i.dayPeriod(o,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return i.dayPeriod(o,{width:"narrow",context:"formatting"});default:return i.dayPeriod(o,{width:"wide",context:"formatting"})}},b:function(t,e,i){const o=t.getHours();let r;switch(r=12===o?Oe:0===o?Ee:o/12>=1?"pm":"am",e){case"b":case"bb":return i.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"bbb":return i.dayPeriod(r,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return i.dayPeriod(r,{width:"narrow",context:"formatting"});default:return i.dayPeriod(r,{width:"wide",context:"formatting"})}},B:function(t,e,i){const o=t.getHours();let r;switch(r=o>=17?Pe:o>=12?Me:o>=4?De:je,e){case"B":case"BB":case"BBB":return i.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"BBBBB":return i.dayPeriod(r,{width:"narrow",context:"formatting"});default:return i.dayPeriod(r,{width:"wide",context:"formatting"})}},h:function(t,e,i){if("ho"===e){let e=t.getHours()%12;return 0===e&&(e=12),i.ordinalNumber(e,{unit:"hour"})}return Ce.h(t,e)},H:function(t,e,i){return"Ho"===e?i.ordinalNumber(t.getHours(),{unit:"hour"}):Ce.H(t,e)},K:function(t,e,i){const o=t.getHours()%12;return"Ko"===e?i.ordinalNumber(o,{unit:"hour"}):Se(o,e.length)},k:function(t,e,i){let o=t.getHours();return 0===o&&(o=24),"ko"===e?i.ordinalNumber(o,{unit:"hour"}):Se(o,e.length)},m:function(t,e,i){return"mo"===e?i.ordinalNumber(t.getMinutes(),{unit:"minute"}):Ce.m(t,e)},s:function(t,e,i){return"so"===e?i.ordinalNumber(t.getSeconds(),{unit:"second"}):Ce.s(t,e)},S:function(t,e){return Ce.S(t,e)},X:function(t,e,i){const o=t.getTimezoneOffset();if(0===o)return"Z";switch(e){case"X":return Te(o);case"XXXX":case"XX":return Ae(o);default:return Ae(o,":")}},x:function(t,e,i){const o=t.getTimezoneOffset();switch(e){case"x":return Te(o);case"xxxx":case"xx":return Ae(o);default:return Ae(o,":")}},O:function(t,e,i){const o=t.getTimezoneOffset();switch(e){case"O":case"OO":case"OOO":return"GMT"+ze(o,":");default:return"GMT"+Ae(o,":")}},z:function(t,e,i){const o=t.getTimezoneOffset();switch(e){case"z":case"zz":case"zzz":return"GMT"+ze(o,":");default:return"GMT"+Ae(o,":")}},t:function(t,e,i){return Se(Math.trunc(+t/1e3),e.length)},T:function(t,e,i){return Se(+t,e.length)}};function ze(t,e=""){const i=t>0?"-":"+",o=Math.abs(t),r=Math.trunc(o/60),n=o%60;return 0===n?i+String(r):i+String(r)+e+Se(n,2)}function Te(t,e){if(t%60==0){return(t>0?"-":"+")+Se(Math.abs(t)/60,2)}return Ae(t,e)}function Ae(t,e=""){const i=t>0?"-":"+",o=Math.abs(t);return i+Se(Math.trunc(o/60),2)+e+Se(o%60,2)}const Le=(t,e)=>{switch(t){case"P":return e.date({width:"short"});case"PP":return e.date({width:"medium"});case"PPP":return e.date({width:"long"});default:return e.date({width:"full"})}},Ie=(t,e)=>{switch(t){case"p":return e.time({width:"short"});case"pp":return e.time({width:"medium"});case"ppp":return e.time({width:"long"});default:return e.time({width:"full"})}},_e={p:Ie,P:(t,e)=>{const i=t.match(/(P+)(p+)?/)||[],o=i[1],r=i[2];if(!r)return Le(t,e);let n;switch(o){case"P":n=e.dateTime({width:"short"});break;case"PP":n=e.dateTime({width:"medium"});break;case"PPP":n=e.dateTime({width:"long"});break;default:n=e.dateTime({width:"full"})}return n.replace("{{date}}",Le(o,e)).replace("{{time}}",Ie(r,e))}},Be=/^D+$/,Ne=/^Y+$/,Re=["D","DD","YY","YYYY"];const qe=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,Ve=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,Ye=/^'([^]*?)'?$/,We=/''/g,Ue=/[a-zA-Z]/;function Ge(t,e,i){const o=ie(),r=o.locale??ve,n=o.firstWeekContainsDate??o.locale?.options?.firstWeekContainsDate??1,a=o.weekStartsOn??o.locale?.options?.weekStartsOn??0,s=Zt(t,i?.in);if(!ce(s))throw new RangeError("Invalid time value");let d=e.match(Ve).map((t=>{const e=t[0];if("p"===e||"P"===e){return(0,_e[e])(t,r.formatLong)}return t})).join("").match(qe).map((t=>{if("''"===t)return{isToken:!1,value:"'"};const e=t[0];if("'"===e)return{isToken:!1,value:He(t)};if(Fe[e])return{isToken:!0,value:t};if(e.match(Ue))throw new RangeError("Format string contains an unescaped latin alphabet character `"+e+"`");return{isToken:!1,value:t}}));r.localize.preprocessor&&(d=r.localize.preprocessor(s,d));const l={firstWeekContainsDate:n,weekStartsOn:a,locale:r};return d.map((i=>{if(!i.isToken)return i.value;const o=i.value;(function(t){return Ne.test(t)}(o)||function(t){return Be.test(t)}(o))&&function(t,e,i){const o=function(t,e,i){const o="Y"===t[0]?"years":"days of the month";return`Use \`${t.toLowerCase()}\` instead of \`${t}\` (in \`${e}\`) for formatting ${o} to the input \`${i}\`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md`}(t,e,i);if(console.warn(o),Re.includes(t))throw new RangeError(o)}(o,e,String(t));return(0,Fe[o[0]])(s,o,r.localize,l)})).join("")}function He(t){const e=t.match(Ye);return e?e[1].replace(We,"'"):t}function Ke(t,e){return Zt(t,e?.in).getDate()}function Xe(t,e){const i=Zt(t,e?.in),o=i.getFullYear(),r=i.getMonth(),n=Jt(i,0);return n.setFullYear(o,r+1,0),n.setHours(0,0,0,0),n.getDate()}function Qe(t,e){return+Zt(t)>+Zt(e)}function Je(t,e){return+Zt(t)<+Zt(e)}function Ze(t,e,i){const[o,r]=se(0,t,e);return o.getFullYear()===r.getFullYear()&&o.getMonth()===r.getMonth()}function ti(t,e,i){const[o,r]=se(0,t,e);return o.getFullYear()===r.getFullYear()}function ei(t,e){return function(t,e){const[i,o]=se(0,t,e);return+de(i)===+de(o)}(Jt(t,t),function(t){return Jt(t,Date.now())}(t))}let ii=class extends e{constructor(){super(...arguments),this.selectedDate=null,this.viewDate=new Date,this.isMobile=!1,this.calendarWidth=0,this.minDate=null,this.maxDate=null,this.currentView="days",this.handleOutsideClick=t=>{const e=this.getRootNode(),i=e?.host;!i||t.composedPath().includes(this)||t.composedPath().includes(i)||this.dispatchEvent(new CustomEvent("close",{bubbles:!0,composed:!0}))}}static{this.styles=t`
|
|
2687
|
+
/* Estilos generales del contenedor del calendario (escritorio) */
|
|
2688
|
+
.calendar-container {
|
|
2689
|
+
position: absolute;
|
|
2690
|
+
top: 100%;
|
|
2691
|
+
left: 0;
|
|
2692
|
+
z-index: 10;
|
|
2693
|
+
border: var(--border-weight-default, 1px) solid var(--secondary-randstad-dark-blue-10, #e7e8ec);
|
|
2694
|
+
background: var(--secondary-white, #fff);
|
|
2695
|
+
border-radius: 4px;
|
|
2696
|
+
margin-top: 8px;
|
|
2697
|
+
padding: 16px;
|
|
2698
|
+
box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.1);
|
|
2699
|
+
font-family: Graphik;
|
|
2700
|
+
display: flex;
|
|
2701
|
+
flex-direction: column;
|
|
2702
|
+
box-sizing: border-box;
|
|
2703
|
+
min-width: 360px;
|
|
2704
|
+
}
|
|
2705
|
+
|
|
2706
|
+
/* El header no tiene margin-bottom */
|
|
2707
|
+
.header {
|
|
2708
|
+
margin-bottom: 0;
|
|
2709
|
+
}
|
|
2710
|
+
|
|
2711
|
+
/* El separador no tiene margin-top para no dejar espacio con el header */
|
|
2712
|
+
.weekdays-separator {
|
|
2713
|
+
width: 100%;
|
|
2714
|
+
height: 1px;
|
|
2715
|
+
background-color: var(--secondary-randstad-dark-blue-10, #e7e8ec);
|
|
2716
|
+
margin-top: 0;
|
|
2717
|
+
margin-bottom: 16px;
|
|
2718
|
+
}
|
|
2719
|
+
|
|
2720
|
+
/* Estilos del encabezado de navegación (botones y título) */
|
|
2721
|
+
.header {
|
|
2722
|
+
display: flex;
|
|
2723
|
+
justify-content: space-between;
|
|
2724
|
+
align-items: center;
|
|
2725
|
+
}
|
|
2726
|
+
|
|
2727
|
+
/* Estilos generales para los botones de navegación */
|
|
2728
|
+
.nav-button {
|
|
2729
|
+
background: none;
|
|
2730
|
+
border: none;
|
|
2731
|
+
cursor: pointer;
|
|
2732
|
+
padding: 8px;
|
|
2733
|
+
color: var(--primary-randstad-blue-70, #2175d9);
|
|
2734
|
+
border-radius: 50%;
|
|
2735
|
+
transition: background-color 0.2s;
|
|
2736
|
+
gap: 8px;
|
|
2737
|
+
}
|
|
2738
|
+
|
|
2739
|
+
.nav-button:hover {
|
|
2740
|
+
background-color: var(--secondary-randstad-light-blue-10, #e8f1fb);
|
|
2741
|
+
}
|
|
2742
|
+
|
|
2743
|
+
.header-left,
|
|
2744
|
+
.header-right {
|
|
2745
|
+
display: flex;
|
|
2746
|
+
align-items: center;
|
|
2747
|
+
gap: 4px;
|
|
2748
|
+
}
|
|
2749
|
+
|
|
2750
|
+
.month-year-button {
|
|
2751
|
+
${I}
|
|
2752
|
+
display: flex;
|
|
2753
|
+
align-items: center;
|
|
2754
|
+
justify-content: center;
|
|
2755
|
+
gap: 8px;
|
|
2756
|
+
background: none;
|
|
2757
|
+
border: none;
|
|
2758
|
+
cursor: pointer;
|
|
2759
|
+
transition: background-color 0.2s;
|
|
2760
|
+
color: var(--secondary-randstad-dark-blue-80, #3c4257);
|
|
2761
|
+
border-radius: 16px;
|
|
2762
|
+
width: auto;
|
|
2763
|
+
height: 41px;
|
|
2764
|
+
padding: 8px;
|
|
2765
|
+
}
|
|
2766
|
+
|
|
2767
|
+
.month-year-button:hover {
|
|
2768
|
+
background-color: var(--secondary-randstad-light-blue-10, #e8f1fb);
|
|
2769
|
+
}
|
|
2770
|
+
|
|
2771
|
+
.month-year-button randstad-icon {
|
|
2772
|
+
color: var(--primary-randstad-blue-70, #2175d9);
|
|
2773
|
+
}
|
|
2774
|
+
|
|
2775
|
+
/* Contenedor de los nombres de los días de la semana */
|
|
2776
|
+
.weekdays {
|
|
2777
|
+
display: grid;
|
|
2778
|
+
place-items: center;
|
|
2779
|
+
grid-template-columns: repeat(7, 1fr);
|
|
2780
|
+
text-align: center;
|
|
2781
|
+
color: var(--secondary-randstad-dark-blue-60, #6c7387);
|
|
2782
|
+
opacity: 1;
|
|
2783
|
+
margin-bottom: 8px; /* Gap de 8px entre nombres y días */
|
|
2784
|
+
font-size: 16px;
|
|
2785
|
+
font-style: normal;
|
|
2786
|
+
font-weight: 500;
|
|
2787
|
+
margin-top: 0;
|
|
2788
|
+
}
|
|
2789
|
+
|
|
2790
|
+
/* Cuadrícula para los días del mes */
|
|
2791
|
+
.days-grid {
|
|
2792
|
+
display: grid;
|
|
2793
|
+
place-items: center;
|
|
2794
|
+
grid-template-columns: repeat(7, 1fr);
|
|
2795
|
+
gap: 8px;
|
|
2796
|
+
}
|
|
2797
|
+
|
|
2798
|
+
/* Estilos para cada botón de día */
|
|
2799
|
+
.day {
|
|
2800
|
+
${_}
|
|
2801
|
+
display: flex;
|
|
2802
|
+
align-items: center;
|
|
2803
|
+
justify-content: center;
|
|
2804
|
+
width: 40px;
|
|
2805
|
+
height: 40px;
|
|
2806
|
+
border-radius: 50%;
|
|
2807
|
+
cursor: pointer;
|
|
2808
|
+
background-color: transparent;
|
|
2809
|
+
border: none;
|
|
2810
|
+
color: var(--secondary-randstad-dark-blue-80, #3c4257);
|
|
2811
|
+
padding: 0;
|
|
2812
|
+
position: relative;
|
|
2813
|
+
}
|
|
2814
|
+
|
|
2815
|
+
.day:hover {
|
|
2816
|
+
background-color: var(--secondary-randstad-light-blue-10, #e8f1fb);
|
|
2817
|
+
}
|
|
2818
|
+
|
|
2819
|
+
/* Estilos para el día, mes y año de hoy */
|
|
2820
|
+
.day.today {
|
|
2821
|
+
color: var(--primary-randstad-blue-70, #2175d9);
|
|
2822
|
+
font-weight: 500;
|
|
2823
|
+
}
|
|
2824
|
+
|
|
2825
|
+
.day.today::after {
|
|
2826
|
+
content: '';
|
|
2827
|
+
position: absolute;
|
|
2828
|
+
bottom: 0;
|
|
2829
|
+
left: 0;
|
|
2830
|
+
right: 0;
|
|
2831
|
+
width: 100%;
|
|
2832
|
+
height: 2px;
|
|
2833
|
+
background-color: var(--primary-randstad-blue-70, #2175d9);
|
|
2834
|
+
border-radius: 2px;
|
|
2835
|
+
}
|
|
2836
|
+
|
|
2837
|
+
/* Estilos para el día seleccionado */
|
|
2838
|
+
.day.selected {
|
|
2839
|
+
background-color: var(--primary-randstad-blue-70, #2175d9);
|
|
2840
|
+
color: var(--secondary-white, #fff);
|
|
2841
|
+
font-weight: 500;
|
|
2842
|
+
}
|
|
2843
|
+
|
|
2844
|
+
/* Estilos para el día seleccionado cuando se muestra en un mes o año diferente */
|
|
2845
|
+
.day.secondary-selected {
|
|
2846
|
+
background-color: var(--secondary-randstad-dark-blue-10, #e7e8ec);
|
|
2847
|
+
color: var(--secondary-randstad-dark-blue-80, #3c4257);
|
|
2848
|
+
font-weight: 500;
|
|
2849
|
+
border: 1px solid var(--secondary-randstad-dark-blue-10, #e7e8ec);
|
|
2850
|
+
}
|
|
2851
|
+
|
|
2852
|
+
/* Grillas para selección de año y mes */
|
|
2853
|
+
.year-grid,
|
|
2854
|
+
.month-grid {
|
|
2855
|
+
display: grid;
|
|
2856
|
+
grid-template-columns: repeat(3, 1fr);
|
|
2857
|
+
gap: 8px;
|
|
2858
|
+
}
|
|
2859
|
+
|
|
2860
|
+
/* Botones de año y mes en la grilla */
|
|
2861
|
+
.year-button,
|
|
2862
|
+
.month-button {
|
|
2863
|
+
${_}
|
|
2864
|
+
background: var(--secondary-white, #fff);
|
|
2865
|
+
border: 1px solid transparent;
|
|
2866
|
+
color: var(--secondary-randstad-dark-blue-80, #3c4257);
|
|
2867
|
+
cursor: pointer;
|
|
2868
|
+
transition: background-color 0.2s, border-color 0.2s;
|
|
2869
|
+
border-radius: 9999px;
|
|
2870
|
+
padding: 4px 16px;
|
|
2871
|
+
text-align: center;
|
|
2872
|
+
display: flex;
|
|
2873
|
+
justify-content: center;
|
|
2874
|
+
align-items: center;
|
|
2875
|
+
height: 38px;
|
|
2876
|
+
}
|
|
2877
|
+
|
|
2878
|
+
.year-button:hover,
|
|
2879
|
+
.month-button:hover {
|
|
2880
|
+
background-color: var(--secondary-randstad-light-blue-10, #e8f1fb);
|
|
2881
|
+
}
|
|
2882
|
+
|
|
2883
|
+
/* Estilos para el año o mes seleccionado */
|
|
2884
|
+
.year-button.selected,
|
|
2885
|
+
.month-button.selected {
|
|
2886
|
+
background-color: var(--primary-randstad-blue-70, #2175d9);
|
|
2887
|
+
color: var(--secondary-white, #fff);
|
|
2888
|
+
border: 1px solid var(--primary-randstad-blue-70, #2175d9);
|
|
2889
|
+
}
|
|
2890
|
+
|
|
2891
|
+
/* Estilos para el mes seleccionado en otro año (estilo secundario) */
|
|
2892
|
+
.month-button.secondary-selected {
|
|
2893
|
+
background-color: var(--secondary-randstad-dark-blue-10, #e7e8ec);
|
|
2894
|
+
color: var(--secondary-randstad-dark-blue-80, #3c4257);
|
|
2895
|
+
font-weight: 500;
|
|
2896
|
+
border: 1px solid var(--secondary-randstad-dark-blue-10, #e7e8ec);
|
|
2897
|
+
}
|
|
2898
|
+
|
|
2899
|
+
/* Estilos para el año y mes current */
|
|
2900
|
+
.year-button.current,
|
|
2901
|
+
.month-button.current {
|
|
2902
|
+
position: relative;
|
|
2903
|
+
}
|
|
2904
|
+
|
|
2905
|
+
.year-button.current::after,
|
|
2906
|
+
.month-button.current::after {
|
|
2907
|
+
content: '';
|
|
2908
|
+
position: absolute;
|
|
2909
|
+
bottom: 0;
|
|
2910
|
+
width: 100%;
|
|
2911
|
+
height: 2px;
|
|
2912
|
+
border-radius: 2px;
|
|
2913
|
+
background-color: var(--primary-randstad-blue-70, #2175d9);
|
|
2914
|
+
}
|
|
2915
|
+
|
|
2916
|
+
/* Estilos para el botón de navegación deshabilitado */
|
|
2917
|
+
.nav-button[disabled] {
|
|
2918
|
+
color: var(--secondary-randstad-dark-blue-30, #b1b5c4);
|
|
2919
|
+
pointer-events: none;
|
|
2920
|
+
}
|
|
2921
|
+
|
|
2922
|
+
.nav-button[disabled]:hover {
|
|
2923
|
+
background-color: transparent;
|
|
2924
|
+
}
|
|
2925
|
+
|
|
2926
|
+
/* Estilos para el botón de día deshabilitado */
|
|
2927
|
+
.day[disabled] {
|
|
2928
|
+
color: var(--secondary-randstad-dark-blue-30, #b1b5c4);
|
|
2929
|
+
pointer-events: none;
|
|
2930
|
+
background-color: transparent;
|
|
2931
|
+
}
|
|
2932
|
+
|
|
2933
|
+
.day[disabled]:hover {
|
|
2934
|
+
background-color: transparent;
|
|
2935
|
+
}
|
|
2936
|
+
|
|
2937
|
+
/* Estilos para los botones de año y mes deshabilitados */
|
|
2938
|
+
.year-button[disabled],
|
|
2939
|
+
.month-button[disabled] {
|
|
2940
|
+
color: var(--secondary-randstad-dark-blue-30, #b1b5c4);
|
|
2941
|
+
pointer-events: none;
|
|
2942
|
+
background-color: transparent;
|
|
2943
|
+
}
|
|
2944
|
+
|
|
2945
|
+
.year-button[disabled]:hover,
|
|
2946
|
+
.month-button[disabled]:hover {
|
|
2947
|
+
background-color: transparent;
|
|
2948
|
+
}
|
|
2949
|
+
|
|
2950
|
+
/* --- Estilos para móvil --- */
|
|
2951
|
+
.mobile-backdrop {
|
|
2952
|
+
position: fixed;
|
|
2953
|
+
inset: 0;
|
|
2954
|
+
background-color: rgba(0, 0, 0, 0.4);
|
|
2955
|
+
z-index: 999;
|
|
2956
|
+
font-family: Graphik;
|
|
2957
|
+
}
|
|
2958
|
+
|
|
2959
|
+
.mobile-modal {
|
|
2960
|
+
position: fixed;
|
|
2961
|
+
bottom: 0;
|
|
2962
|
+
left: 0;
|
|
2963
|
+
right: 0;
|
|
2964
|
+
background-color: white;
|
|
2965
|
+
z-index: 1000;
|
|
2966
|
+
border-radius: 12px 12px 0 0;
|
|
2967
|
+
box-shadow: 0 -4px 10px rgba(0, 0, 0, 0.15);
|
|
2968
|
+
display: flex;
|
|
2969
|
+
flex-direction: column;
|
|
2970
|
+
padding: 24px 16px;
|
|
2971
|
+
animation: slideUp 0.5s ease-out;
|
|
2972
|
+
max-height: 80vh;
|
|
2973
|
+
overflow-y: auto;
|
|
2974
|
+
font-family: Graphik;
|
|
2975
|
+
}
|
|
2976
|
+
|
|
2977
|
+
@keyframes slideUp {
|
|
2978
|
+
from {
|
|
2979
|
+
transform: translateY(100%);
|
|
2980
|
+
}
|
|
2981
|
+
to {
|
|
2982
|
+
transform: translateY(0);
|
|
2983
|
+
}
|
|
2984
|
+
}
|
|
2985
|
+
|
|
2986
|
+
.mobile-modal .header {
|
|
2987
|
+
margin-bottom: 0;
|
|
2988
|
+
position: sticky;
|
|
2989
|
+
top: 0;
|
|
2990
|
+
background: white;
|
|
2991
|
+
z-index: 10;
|
|
2992
|
+
}
|
|
2993
|
+
|
|
2994
|
+
.mobile-modal .weekdays-separator {
|
|
2995
|
+
margin: 0;
|
|
2996
|
+
}
|
|
2997
|
+
|
|
2998
|
+
.mobile-modal .weekdays {
|
|
2999
|
+
place-items: center;
|
|
3000
|
+
margin-top: 16px;
|
|
3001
|
+
margin-bottom: 8px;
|
|
3002
|
+
}
|
|
3003
|
+
|
|
3004
|
+
.mobile-modal .days-grid {
|
|
3005
|
+
gap: 8px;
|
|
3006
|
+
grid-template-columns: repeat(7, 1fr);
|
|
3007
|
+
place-items: center;
|
|
3008
|
+
}
|
|
3009
|
+
|
|
3010
|
+
.mobile-modal .month-grid,
|
|
3011
|
+
.mobile-modal .year-grid {
|
|
3012
|
+
gap: 16px;
|
|
3013
|
+
margin-top: 16px;
|
|
3014
|
+
}
|
|
3015
|
+
|
|
3016
|
+
.mobile-modal .day {
|
|
3017
|
+
${B}
|
|
3018
|
+
font-weight: 500;
|
|
3019
|
+
display: flex;
|
|
3020
|
+
align-items: center;
|
|
3021
|
+
justify-content: center;
|
|
3022
|
+
width: 40px;
|
|
3023
|
+
height: 40px;
|
|
3024
|
+
border-radius: 50%;
|
|
3025
|
+
cursor: pointer;
|
|
3026
|
+
background-color: transparent;
|
|
3027
|
+
border: none;
|
|
3028
|
+
color: var(--secondary-randstad-dark-blue-80, #3c4257);
|
|
3029
|
+
position: relative;
|
|
3030
|
+
}
|
|
3031
|
+
|
|
3032
|
+
.mobile-modal .day.selected {
|
|
3033
|
+
background-color: var(--primary-randstad-blue-70, #2175d9);
|
|
3034
|
+
color: var(--secondary-white, #fff);
|
|
3035
|
+
font-weight: 500;
|
|
3036
|
+
border-radius: 50%;
|
|
3037
|
+
}
|
|
3038
|
+
|
|
3039
|
+
.mobile-modal .day.today {
|
|
3040
|
+
color: var(--primary-randstad-blue-70, #2175d9);
|
|
3041
|
+
font-weight: 500;
|
|
3042
|
+
}
|
|
3043
|
+
|
|
3044
|
+
.mobile-modal .day.today::after {
|
|
3045
|
+
content: '';
|
|
3046
|
+
position: absolute;
|
|
3047
|
+
bottom: 0;
|
|
3048
|
+
width: 40px;
|
|
3049
|
+
left: 50%;
|
|
3050
|
+
transform: translateX(-50%);
|
|
3051
|
+
height: 2px;
|
|
3052
|
+
background-color: var(--primary-randstad-blue-70, #2175d9);
|
|
3053
|
+
border-radius: 2px;
|
|
3054
|
+
}
|
|
3055
|
+
|
|
3056
|
+
.mobile-modal .year-grid,
|
|
3057
|
+
.mobile-modal .month-grid {
|
|
3058
|
+
grid-template-columns: repeat(3, 1fr);
|
|
3059
|
+
gap: 8px;
|
|
3060
|
+
}
|
|
3061
|
+
|
|
3062
|
+
.mobile-modal .year-button,
|
|
3063
|
+
.mobile-modal .month-button {
|
|
3064
|
+
width: 100%;
|
|
3065
|
+
height: 48px;
|
|
3066
|
+
border-radius: 9999px;
|
|
3067
|
+
flex: 1 1 33.3333%;
|
|
3068
|
+
padding: 0;
|
|
3069
|
+
}
|
|
3070
|
+
|
|
3071
|
+
.mobile-modal .day.secondary-selected,
|
|
3072
|
+
.mobile-modal .month-button.secondary-selected {
|
|
3073
|
+
background-color: var(--secondary-randstad-dark-blue-10, #e7e8ec);
|
|
3074
|
+
color: var(--secondary-randstad-dark-blue-80, #3c4257);
|
|
3075
|
+
font-weight: 500;
|
|
3076
|
+
border: 1px solid var(--secondary-randstad-dark-blue-10, #e7e8ec);
|
|
3077
|
+
}
|
|
3078
|
+
|
|
3079
|
+
/* Estilos para elementos deshabilitados dentro del modal de móviles. */
|
|
3080
|
+
.mobile-modal .day[disabled],
|
|
3081
|
+
.mobile-modal .month-button[disabled],
|
|
3082
|
+
.mobile-modal .year-button[disabled] {
|
|
3083
|
+
color: var(--secondary-randstad-dark-blue-30, #b1b5c4);
|
|
3084
|
+
pointer-events: none;
|
|
3085
|
+
background-color: transparent;
|
|
3086
|
+
}
|
|
3087
|
+
|
|
3088
|
+
.mobile-modal .nav-button[disabled] {
|
|
3089
|
+
color: var(--secondary-randstad-dark-blue-30, #b1b5c4);
|
|
3090
|
+
pointer-events: none;
|
|
3091
|
+
background-color: transparent;
|
|
3092
|
+
}
|
|
3093
|
+
|
|
3094
|
+
/* Evitamos que el estilo 'today' o 'current' se aplique si el elemento está deshabilitado */
|
|
3095
|
+
.mobile-modal .day.today[disabled]::after,
|
|
3096
|
+
.mobile-modal .nav-button[disabled] randstad-icon {
|
|
3097
|
+
color: var(--secondary-randstad-dark-blue-30, #b1b5c4);
|
|
3098
|
+
}
|
|
3099
|
+
/* */
|
|
3100
|
+
`}connectedCallback(){super.connectedCallback(),document.addEventListener("click",this.handleOutsideClick)}disconnectedCallback(){super.disconnectedCallback(),document.removeEventListener("click",this.handleOutsideClick)}handleHeaderClick(){"days"===this.currentView?this.currentView="years":this.currentView="days"}_updateView(t,e=null){this.viewDate=t,e&&(this.currentView=e),this.dispatchEvent(new CustomEvent("view-date-change",{detail:{date:this.viewDate}}))}handleNavClick(t){let e=this.viewDate;e="days"===this.currentView?te(this.viewDate,t):"months"===this.currentView?le(this.viewDate,t):le(this.viewDate,21*t),this._updateView(e)}handleYearSelect(t){const e=function(t,e,i){const o=Zt(t,i?.in);return isNaN(+o)?Jt(t,NaN):(o.setFullYear(e),o)}(this.viewDate,t);this._updateView(e,"months")}handleMonthSelect(t){const e=function(t,e,i){const o=Zt(t,i?.in),r=o.getFullYear(),n=o.getDate(),a=Jt(t,0);a.setFullYear(r,e,15),a.setHours(0,0,0,0);const s=Xe(a);return o.setMonth(e,Math.min(n,s)),o}(this.viewDate,t);this._updateView(e,"days")}handleDayClick(t){this.selectedDate=t,this.dispatchEvent(new CustomEvent("date-selected",{detail:{date:t},bubbles:!0,composed:!0}))}getFullMonthNames(){return["Enero","Febrero","Marzo","Abril","Mayo","Junio","Julio","Agosto","Septiembre","Octubre","Noviembre","Diciembre"]}getShortMonthNames(){return this.getFullMonthNames().map((t=>t.substring(0,3)))}getShortWeekdays(){return["lu","ma","mi","ju","vi","sa","do"]}renderHeader(){const t=this.getFullMonthNames();let e="",o=!1,r=!1;if("years"===this.currentView){const t=this.viewDate.getFullYear()-this.viewDate.getFullYear()%21,i=t+20;e=`${t} - ${i}`;o=t<=(this.minDate?this.minDate.getFullYear():-1/0),r=i>=(this.maxDate?this.maxDate.getFullYear():1/0)}else if("months"===this.currentView){e=`${this.viewDate.getFullYear()}`;const t=this.viewDate.getFullYear();o=t<=(this.minDate?this.minDate.getFullYear():-1/0),r=t>=(this.maxDate?this.maxDate.getFullYear():1/0)}else{e=`${t[this.viewDate.getMonth()]} ${this.viewDate.getFullYear()}`,this.minDate&&(o=Ze(pe(this.viewDate),pe(this.minDate))||Je(this.viewDate,this.minDate)),this.maxDate&&(r=Ze(pe(this.viewDate),pe(this.maxDate))||Qe(this.viewDate,this.maxDate))}return i`
|
|
3101
|
+
<div class="header">
|
|
3102
|
+
<div class="header-left">
|
|
3103
|
+
<button class="month-year-button" @click=${this.handleHeaderClick}>
|
|
3104
|
+
<span>${e}</span>
|
|
3105
|
+
|
|
3106
|
+
${"days"===this.currentView?i`<randstad-icon name="arrow_drop_down" class="select-icon"></randstad-icon>`:i`<randstad-icon name="arrow_drop_up" class="select-icon"></randstad-icon>`}
|
|
3107
|
+
</button>
|
|
3108
|
+
</div>
|
|
3109
|
+
|
|
3110
|
+
<div class="header-right">
|
|
3111
|
+
<button class="nav-button" @click=${()=>this.handleNavClick(-1)} ?disabled=${o}>
|
|
3112
|
+
<randstad-icon name="arrow_left"></randstad-icon>
|
|
3113
|
+
</button>
|
|
3114
|
+
|
|
3115
|
+
<button class="nav-button" @click=${()=>this.handleNavClick(1)} ?disabled=${r}>
|
|
3116
|
+
<randstad-icon name="arrow_right"></randstad-icon>
|
|
3117
|
+
</button>
|
|
3118
|
+
</div>
|
|
3119
|
+
</div>
|
|
3120
|
+
`}renderYearsView(){const t=this.viewDate.getFullYear()-this.viewDate.getFullYear()%21,e=Array.from({length:21},((e,i)=>t+i)),o=this.selectedDate?this.selectedDate.getFullYear():null,r=(new Date).getFullYear(),n=this.minDate?this.minDate.getFullYear():-1/0,a=this.maxDate?this.maxDate.getFullYear():1/0;return i`
|
|
3121
|
+
<div class="year-grid">
|
|
3122
|
+
${e.map((t=>i`
|
|
3123
|
+
<button
|
|
3124
|
+
class="${"year-button "+(t===o?"selected":t===r?"current":"")}"
|
|
3125
|
+
@click=${()=>this.handleYearSelect(t)}
|
|
3126
|
+
?disabled=${t<n||t>a}
|
|
3127
|
+
>
|
|
3128
|
+
${t}
|
|
3129
|
+
</button>
|
|
3130
|
+
`))}
|
|
3131
|
+
</div>
|
|
3132
|
+
`}renderMonthsView(){const t=this.getShortMonthNames(),e=this.selectedDate?.getMonth(),o=(new Date).getMonth(),r=this.viewDate.getFullYear();return i`
|
|
3133
|
+
<div class="month-grid">
|
|
3134
|
+
${t.map(((t,n)=>{const a=n===o,s=n===e&&this.selectedDate&&ti(this.viewDate,this.selectedDate),d=n===e&&this.selectedDate&&!ti(this.viewDate,this.selectedDate);let l=!1;this.minDate&&r===this.minDate.getFullYear()&&(l=n<this.minDate.getMonth()),this.maxDate&&r===this.maxDate.getFullYear()&&(l=l||n>this.maxDate.getMonth());return i`
|
|
3135
|
+
<button
|
|
3136
|
+
class="${"month-button "+(s?"selected":d?"secondary-selected":a?"current":"")}"
|
|
3137
|
+
?disabled=${l}
|
|
3138
|
+
@click=${()=>this.handleMonthSelect(n)}
|
|
3139
|
+
>
|
|
3140
|
+
${t}
|
|
3141
|
+
</button>
|
|
3142
|
+
`}))}
|
|
3143
|
+
</div>
|
|
3144
|
+
`}renderDayView(){const t=Xe(this.viewDate),e=pe(this.viewDate),o=Zt(e,r?.in).getDay();var r;const n=Array.from({length:0===o?6:o-1},(()=>null)),a=Array.from({length:t},((t,i)=>function(t,e,i){const o=Zt(t,i?.in);return o.setDate(e),o}(e,i+1))),s=this.getShortWeekdays();return i`
|
|
3145
|
+
<div class="weekdays">
|
|
3146
|
+
${s.map((t=>i`<div>${t}</div>`))}
|
|
3147
|
+
</div>
|
|
3148
|
+
|
|
3149
|
+
<div class="days-grid">
|
|
3150
|
+
${n.map((()=>i`<div></div>`))}
|
|
3151
|
+
${a.map((t=>{const e=de(t),o=this.selectedDate?de(this.selectedDate):null,r=this.minDate&&Je(e,de(this.minDate))||this.maxDate&&Qe(e,de(this.maxDate)),n=ei(e),a=o&&Ke(e)===Ke(o),s=a&&o&&Ze(e,o)&&ti(e,o);return i`
|
|
3152
|
+
<button
|
|
3153
|
+
class="${`day ${n?"today":""} ${s?"selected":a&&!s?"secondary-selected":""}`}"
|
|
3154
|
+
?disabled=${r}
|
|
3155
|
+
@click=${()=>this.handleDayClick(t)}
|
|
3156
|
+
>
|
|
3157
|
+
${Ge(t,"d")}
|
|
3158
|
+
</button>
|
|
3159
|
+
`}))}
|
|
3160
|
+
</div>
|
|
3161
|
+
`}render(){let t;t="days"===this.currentView?this.renderDayView():"months"===this.currentView?this.renderMonthsView():this.renderYearsView();const e=i`${this.renderHeader()} <div class="weekdays-separator"></div> ${t}`;return this.isMobile?i`
|
|
3162
|
+
<div
|
|
3163
|
+
class="mobile-backdrop"
|
|
3164
|
+
@click=${()=>this.dispatchEvent(new CustomEvent("close"))}
|
|
3165
|
+
>
|
|
3166
|
+
<div class="mobile-modal" @click=${t=>t.stopPropagation()}>
|
|
3167
|
+
${e}
|
|
3168
|
+
</div>
|
|
3169
|
+
</div>
|
|
3170
|
+
`:i`
|
|
3171
|
+
<div class="calendar-container" style="width: ${this.calendarWidth}px;">
|
|
3172
|
+
${e}
|
|
3173
|
+
</div>
|
|
3174
|
+
`}};a([z({type:Object}),s("design:type",Object)],ii.prototype,"selectedDate",void 0),a([z({type:Object}),s("design:type",Date)],ii.prototype,"viewDate",void 0),a([z({type:Boolean}),s("design:type",Object)],ii.prototype,"isMobile",void 0),a([z({type:Number}),s("design:type",Number)],ii.prototype,"calendarWidth",void 0),a([z({type:Object}),s("design:type",Object)],ii.prototype,"minDate",void 0),a([z({type:Object}),s("design:type",Object)],ii.prototype,"maxDate",void 0),a([T(),s("design:type",String)],ii.prototype,"currentView",void 0),ii=a([d("calendar-overlay")],ii);let oi=class extends e{constructor(){super(...arguments),this.label="",this.placeholder="Selecciona una fecha",this.value="",this.required=!1,this.disabled=!1,this.error=!1,this.isRenderClearButton=!0,this.isOpen=!1,this.selectedDate=null,this.viewDate=new Date,this.isMobile=!1,this.calendarWidth=0,this.updateResponsiveModeBound=this.updateResponsiveMode.bind(this),this.handleClickOutside=t=>{t.composedPath().includes(this)||(this.isOpen=!1)}}static{this.styles=t`
|
|
3175
|
+
/* Contenedor principal y tipografía base */
|
|
3176
|
+
:host {
|
|
3177
|
+
display: block;
|
|
3178
|
+
font-family: "Graphik", sans-serif;
|
|
3179
|
+
color: var(--secondary-randstad-dark-blue, #0f1941);
|
|
3180
|
+
}
|
|
3181
|
+
|
|
3182
|
+
/* Si se proporciona una propiedad width (ej. width="600px"), se usa ese valor. */
|
|
3183
|
+
:host([width]) {
|
|
3184
|
+
width: var(--datepicker-width);
|
|
3185
|
+
}
|
|
3186
|
+
|
|
3187
|
+
/* Contenedor principal para el input */
|
|
3188
|
+
.input-container {
|
|
3189
|
+
position: relative;
|
|
3190
|
+
/* El contenedor siempre toma el 100% del ancho del host */
|
|
3191
|
+
max-width: 100%;
|
|
3192
|
+
}
|
|
3193
|
+
|
|
3194
|
+
/* Estilos para evitar el desbordamiento en móviles */
|
|
3195
|
+
calendar-overlay {
|
|
3196
|
+
max-width: 100vw;
|
|
3197
|
+
box-sizing: border-box;
|
|
3198
|
+
}
|
|
3199
|
+
.form-label {
|
|
3200
|
+
${B}
|
|
3201
|
+
color: var(--secondary-randstad-dark-blue-80, #404767);
|
|
3202
|
+
margin-bottom: 4px;
|
|
3203
|
+
display: block;
|
|
3204
|
+
}
|
|
3205
|
+
|
|
3206
|
+
/* Estilos del campo de entrada y sus estados */
|
|
3207
|
+
.input-wrapper {
|
|
3208
|
+
display: flex;
|
|
3209
|
+
align-items: center;
|
|
3210
|
+
border: 1px solid var(--md-sys-color-outline, #e0e0e0);
|
|
3211
|
+
border-radius: 4px;
|
|
3212
|
+
padding: 0 16px;
|
|
3213
|
+
transition: border-color 0.2s;
|
|
3214
|
+
background: white;
|
|
3215
|
+
box-sizing: border-box;
|
|
3216
|
+
min-width: 360px;
|
|
3217
|
+
}
|
|
3218
|
+
|
|
3219
|
+
.input-wrapper:hover {
|
|
3220
|
+
box-shadow: 0px 0px 0px 4px #0f19411a;
|
|
3221
|
+
}
|
|
3222
|
+
|
|
3223
|
+
.input-wrapper.active:hover {
|
|
3224
|
+
box-shadow: 0px 0px 0px 4px #0f19411a;
|
|
3225
|
+
}
|
|
3226
|
+
|
|
3227
|
+
.input-wrapper.active {
|
|
3228
|
+
border: 1px solid var(--primary-color);
|
|
3229
|
+
box-shadow: none;
|
|
3230
|
+
}
|
|
3231
|
+
|
|
3232
|
+
.date-input {
|
|
3233
|
+
${B}
|
|
3234
|
+
flex-grow: 1;
|
|
3235
|
+
border: none;
|
|
3236
|
+
outline: none;
|
|
3237
|
+
padding: 16px 0;
|
|
3238
|
+
cursor: text;
|
|
3239
|
+
background: white;
|
|
3240
|
+
color: #49454f;
|
|
3241
|
+
}
|
|
3242
|
+
|
|
3243
|
+
.icon-button {
|
|
3244
|
+
background: none;
|
|
3245
|
+
border: none;
|
|
3246
|
+
cursor: pointer;
|
|
3247
|
+
display: flex;
|
|
3248
|
+
align-items: center;
|
|
3249
|
+
justify-content: center;
|
|
3250
|
+
padding: 0;
|
|
3251
|
+
}
|
|
3252
|
+
|
|
3253
|
+
.clear-button {
|
|
3254
|
+
margin-right: 18px;
|
|
3255
|
+
color: #49454f;
|
|
3256
|
+
opacity: 0.6;
|
|
3257
|
+
}
|
|
3258
|
+
|
|
3259
|
+
.clear-button randstad-icon {
|
|
3260
|
+
width: 18px;
|
|
3261
|
+
height: 18px;
|
|
3262
|
+
}
|
|
3263
|
+
|
|
3264
|
+
.calendar-button {
|
|
3265
|
+
color: #2175d9;
|
|
3266
|
+
}
|
|
3267
|
+
|
|
3268
|
+
.calendar-button randstad-icon {
|
|
3269
|
+
font-size: 18px;
|
|
3270
|
+
}
|
|
3271
|
+
|
|
3272
|
+
.required {
|
|
3273
|
+
color: var(--ui-negative);
|
|
3274
|
+
}
|
|
3275
|
+
|
|
3276
|
+
/* --- Error Styles --- */
|
|
3277
|
+
:host([error]) .input-wrapper {
|
|
3278
|
+
border: 1px solid var(--ui-negative, red) !important;
|
|
3279
|
+
}
|
|
3280
|
+
|
|
3281
|
+
:host([error]) .input-wrapper:hover {
|
|
3282
|
+
box-shadow: 0px 0px 0px 4px #e00f0f1a !important;
|
|
3283
|
+
}
|
|
3284
|
+
|
|
3285
|
+
:host([error]) .input-wrapper.active {
|
|
3286
|
+
border: 1px solid var(--ui-negative, red) !important;
|
|
3287
|
+
box-shadow: none !important;
|
|
3288
|
+
}
|
|
3289
|
+
/* */
|
|
3290
|
+
`}connectedCallback(){super.connectedCallback(),this.updateResponsiveMode(),window.addEventListener("resize",this.updateResponsiveModeBound)}disconnectedCallback(){window.removeEventListener("resize",this.updateResponsiveModeBound),document.removeEventListener("click",this.handleClickOutside),super.disconnectedCallback()}firstUpdated(){this.setInitialWidth()}updated(t){(t.has("isOpen")||t.has("value"))&&this.setInitialWidth(),super.updated(t)}setInitialWidth(){this.inputContainer&&(this.calendarWidth=this.inputContainer.getBoundingClientRect().width)}updateResponsiveMode(){this.isMobile=window.innerWidth<=940,this.setInitialWidth()}update(t){if(t.has("value"))if(this.value){let t=null;const e=this.value.split("-");if(3===e.length){const[i,o,r]=e.map(Number);i>1e3?(t=new Date(i,o-1,r),ce(t)&&(this.value=Ge(t,"dd-MM-yyyy"))):o>=1&&o<=12&&(t=new Date(r,o-1,i)),t&&ce(t)?(this.selectedDate=t,this.viewDate=t):this.selectedDate=null}}else this.selectedDate=null,this.viewDate=new Date;super.update(t)}handleInput(t){if(this.disabled)return;const e=t.target.value;if(""===e)return this.selectedDate=null,this.value="",this.error=!1,void this.requestUpdate();const[i,o,r]=e.split("-").map(Number);let n=null;if(i&&o&&r&&o>=1&&o<=12&&r>1e3){const t=new Date(r,o-1,i,12);ce(t)&&Ge(t,"dd-MM-yyyy")===e&&(n=t)}n?this._isWithinBounds(n)?(this.selectedDate=n,this.viewDate=n,this.value=e,this.error=!1):(this.error=!0,console.error("La fecha escrita está fuera del rango permitido.")):this.error=!0,this.requestUpdate()}handleCalendarButtonClick(t){this.disabled||(t.stopPropagation(),this.isOpen=!this.isOpen,this.selectedDate?this.viewDate=this.selectedDate:this.viewDate=new Date,this.requestUpdate())}handleClearDate(){this.selectedDate=null,this.error=!1,this.closeOverlay("")}handleDateSelect(t){const e=t.detail.date;e&&(this.selectedDate=e,this.viewDate=e,this.closeOverlay(Ge(e,"dd-MM-yyyy")))}handleViewDateChange(t){this.viewDate=t.detail.date}closeOverlay(t){this.value=t,this.isOpen=!1,this.dispatchEvent(new CustomEvent("date-selected",{detail:{value:t}}))}_parseDateString(t){if(!t)return null;const e=t.split("-").map(Number);if(3===e.length&&!isNaN(e[0])&&!isNaN(e[1])&&!isNaN(e[2])){return new Date(e[0],e[1]-1,e[2],12)}return null}_getValidDateRange(){const t=this._parseDateString(this.minDate),e=this._parseDateString(this.maxDate);return t||e?t&&e&&Qe(t,e)?null:{minDate:t,maxDate:e}:{minDate:null,maxDate:null}}_isWithinBounds(t){const e=this._getValidDateRange();return!e||(!e.minDate||!Je(t,e.minDate))&&(!e.maxDate||!Qe(t,e.maxDate))}render(){const t=`input-wrapper ${this.isOpen?"active":""} ${this.error?"error":""} ${this.disabled?"disabled":""}`,e=`width: ${this.width||"100%"};`,r=this._getValidDateRange();return i`
|
|
3291
|
+
<div class="input-container" style="${e}">
|
|
3292
|
+
<label class="form-label">
|
|
3293
|
+
${this.label}
|
|
3294
|
+
${this.required?i`<span class="required">*</span>`:""}
|
|
3295
|
+
</label>
|
|
3296
|
+
|
|
3297
|
+
<div class="${t}" style="width: 100%">
|
|
3298
|
+
<input
|
|
3299
|
+
type="text"
|
|
3300
|
+
class="date-input"
|
|
3301
|
+
.value="${this.value}"
|
|
3302
|
+
placeholder="${this.placeholder}"
|
|
3303
|
+
?disabled=${this.disabled}
|
|
3304
|
+
@input=${this.handleInput}
|
|
3305
|
+
/>
|
|
3306
|
+
|
|
3307
|
+
${this.isRenderClearButton&&this.selectedDate&&!this.disabled?i`
|
|
3308
|
+
<button
|
|
3309
|
+
class="icon-button clear-button"
|
|
3310
|
+
@click=${this.handleClearDate}
|
|
3311
|
+
>
|
|
3312
|
+
<randstad-icon name="close"></randstad-icon>
|
|
3313
|
+
</button>
|
|
3314
|
+
`:o}
|
|
3315
|
+
|
|
3316
|
+
<button
|
|
3317
|
+
class="icon-button calendar-button"
|
|
3318
|
+
@click=${this.handleCalendarButtonClick}
|
|
3319
|
+
>
|
|
3320
|
+
<randstad-icon name="calendar"></randstad-icon>
|
|
3321
|
+
</button>
|
|
3322
|
+
</div>
|
|
3323
|
+
|
|
3324
|
+
${this.isOpen?i`
|
|
3325
|
+
<calendar-overlay
|
|
3326
|
+
.isMobile=${this.isMobile}
|
|
3327
|
+
.selectedDate=${this.selectedDate}
|
|
3328
|
+
.viewDate=${this.viewDate}
|
|
3329
|
+
.calendarWidth=${this.calendarWidth}
|
|
3330
|
+
.minDate=${r?.minDate}
|
|
3331
|
+
.maxDate=${r?.maxDate}
|
|
3332
|
+
@close=${()=>this.isOpen=!1}
|
|
3333
|
+
@view-date-change=${this.handleViewDateChange}
|
|
3334
|
+
@date-selected=${this.handleDateSelect}
|
|
3335
|
+
>
|
|
3336
|
+
</calendar-overlay>
|
|
3337
|
+
`:o}
|
|
3338
|
+
</div>
|
|
3339
|
+
`}};a([z({type:String}),s("design:type",Object)],oi.prototype,"label",void 0),a([z({type:String}),s("design:type",Object)],oi.prototype,"placeholder",void 0),a([z({type:String}),s("design:type",Object)],oi.prototype,"value",void 0),a([z({type:Boolean}),s("design:type",Object)],oi.prototype,"required",void 0),a([z({type:Boolean}),s("design:type",Object)],oi.prototype,"disabled",void 0),a([z({type:Boolean,reflect:!0}),s("design:type",Object)],oi.prototype,"error",void 0),a([z({type:String}),s("design:type",String)],oi.prototype,"width",void 0),a([z({type:Boolean}),s("design:type",Object)],oi.prototype,"isRenderClearButton",void 0),a([z({type:String}),s("design:type",String)],oi.prototype,"minDate",void 0),a([z({type:String}),s("design:type",String)],oi.prototype,"maxDate",void 0),a([T(),s("design:type",Object)],oi.prototype,"isOpen",void 0),a([T(),s("design:type",Object)],oi.prototype,"selectedDate",void 0),a([T(),s("design:type",Date)],oi.prototype,"viewDate",void 0),a([T(),s("design:type",Object)],oi.prototype,"isMobile",void 0),a([T(),s("design:type",Number)],oi.prototype,"calendarWidth",void 0),a([A(".input-container"),s("design:type",HTMLDivElement)],oi.prototype,"inputContainer",void 0),oi=a([d("datepicker-component")],oi);export{Y as AccordionList,V as AccordionPanel,ii as CalendarOverlay,U as CarouselCard,G as Checkbox,J as CustomModal,Z as CustomPopup,Vt as CustomRadio,Gt as CustomStepper,oi as DatePickerComponent,Yt as FilterableSelect,K as FormGroup,X as IconComponent,tt as ProgressCircle,W as RandstadButton,H as RandstadForm,Q as RandstadNotice,Ht as TabsBar,Kt as UploadImage};
|
|
2647
3340
|
//# sourceMappingURL=index.js.map
|