@phatvu/web-component-poc 1.0.7 → 1.0.8
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/cjs/{fast-input_4.cjs.entry.js → fast-button_6.cjs.entry.js} +112 -33
- package/dist/cjs/fast-carousel.cjs.entry.js +1 -1
- package/dist/cjs/{index-BEvZs91D.js → index-227GpI8K.js} +64 -0
- package/dist/cjs/job-card.cjs.entry.js +1 -1
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/web-component-poc.cjs.js +2 -2
- package/dist/collection/collection-manifest.json +1 -0
- package/dist/collection/components/button/button.css +14 -14
- package/dist/collection/components/button/button.js +12 -24
- package/dist/collection/components/fast-form/fast-form.css +5 -0
- package/dist/collection/components/fast-form/fast-form.js +99 -0
- package/dist/collection/components/fast-input/fast-input.css +3 -13
- package/dist/collection/components/fast-input/fast-input.js +57 -33
- package/dist/collection/components/jobs-list-only/jobs-list-only.js +1 -1
- package/dist/collection/components/jobs-list-reactive/jobs-list-reactive.js +1 -1
- package/dist/components/fast-button.js +1 -1
- package/dist/components/fast-carousel.js +1 -1
- package/dist/components/fast-form.d.ts +11 -0
- package/dist/components/fast-form.js +1 -0
- package/dist/components/fast-input.js +1 -1
- package/dist/components/index.js +1 -1
- package/dist/components/job-card.js +1 -1
- package/dist/components/jobs-item.js +1 -1
- package/dist/components/jobs-list-only.js +1 -1
- package/dist/components/jobs-list-reactive.js +1 -1
- package/dist/components/p-Bb27ylcX.js +1 -0
- package/dist/components/{p-DQiaLjLf.js → p-CzgtwPsc.js} +1 -1
- package/dist/esm/{fast-input_4.entry.js → fast-button_6.entry.js} +111 -34
- package/dist/esm/fast-carousel.entry.js +1 -1
- package/dist/esm/{index-C_ZLQIpp.js → index-BqjrT3zA.js} +64 -0
- package/dist/esm/job-card.entry.js +1 -1
- package/dist/esm/loader.js +3 -3
- package/dist/esm/web-component-poc.js +3 -3
- package/dist/types/components/button/button.d.ts +1 -13
- package/dist/types/components/fast-form/fast-form.d.ts +10 -0
- package/dist/types/components/fast-input/fast-input.d.ts +3 -5
- package/dist/types/components.d.ts +35 -13
- package/dist/web-component-poc/{p-bef7c8e2.entry.js → p-14247159.entry.js} +1 -1
- package/dist/web-component-poc/{p-7d45772f.entry.js → p-309a490b.entry.js} +1 -1
- package/dist/web-component-poc/p-7ea9a87f.entry.js +1 -0
- package/dist/web-component-poc/{p-C_ZLQIpp.js → p-BqjrT3zA.js} +2 -2
- package/dist/web-component-poc/web-component-poc.esm.js +1 -1
- package/hydrate/index.js +136 -54
- package/hydrate/index.mjs +136 -54
- package/package.json +3 -3
- package/dist/cjs/fast-button.cjs.entry.js +0 -46
- package/dist/components/p-BiaJAQXY.js +0 -1
- package/dist/esm/fast-button.entry.js +0 -44
- package/dist/web-component-poc/p-618fba28.entry.js +0 -1
- package/dist/web-component-poc/p-cfb9aed9.entry.js +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
import{t,p as s,H as e,c as o,h as a}from"./p-
|
|
1
|
+
import{t,p as s,H as e,c as o,h as a}from"./p-Bb27ylcX.js";const i=s(class extends e{constructor(t){super(),!1!==t&&this.__registerHost(),this.fetchComplete=o(this,"fetchComplete")}get el(){return this}apiUrl="/api/get-jobs";watchParams="keyword,location_name";loadingClass="loading";isLoading=!1;fetchComplete;templateEl=null;searchExecutedHandler;popstateHandler;connectedCallback(){this.templateEl=this.el.querySelector("template"),this.searchExecutedHandler=()=>this.fetchJobs(),this.popstateHandler=()=>this.fetchJobs(),document.addEventListener("search-executed",this.searchExecutedHandler),window.addEventListener("popstate",this.popstateHandler)}disconnectedCallback(){document.removeEventListener("search-executed",this.searchExecutedHandler),window.removeEventListener("popstate",this.popstateHandler)}buildQueryString(){const t=new URLSearchParams(window.location.search),s=this.watchParams.split(",").map((t=>t.trim())).filter(Boolean),e=new URLSearchParams;for(const o of s){const s=t.get(o);null!==s&&""!==s&&e.set(o,s)}return""+e}async fetchJobs(){this.isLoading=!0,this.el.classList.add(this.loadingClass);const t=this.buildQueryString(),s=t?`${this.apiUrl}?${t}`:this.apiUrl;try{const t=await fetch(s,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({disable_switch_search_mode:!1})});if(!t.ok)throw Error("fetch failed");const e=await t.json();this.renderJobs(e.jobs),this.updateCountElements(e.jobs.length,e.totalJob),this.fetchComplete.emit({jobs:e.jobs,totalJob:e.totalJob})}catch{}finally{this.isLoading=!1,this.el.classList.remove(this.loadingClass)}}renderJobs(t){if(!this.templateEl)return;const s=Array.from(this.el.children);for(const t of s)t!==this.templateEl&&t.remove();for(const s of t){const t=this.templateEl.content.cloneNode(!0),e=t.querySelector("job-card");e&&e.setAttribute("job",JSON.stringify(s)),this.el.appendChild(t)}}updateCountElements(t,s){const e=document.querySelectorAll("[data-job-count]"),o=document.querySelectorAll("[data-job-total]");e.forEach((s=>{s.textContent=t+""})),o.forEach((t=>{t.textContent=s+""}))}render(){return a("slot",{key:"9f3ab802e19a298a790cfb5e86a4f4888e466804"})}static get style(){return"jobs-list-reactive{display:block}jobs-list-reactive.loading{opacity:0.6;pointer-events:none}"}},[772,"jobs-list-reactive",{apiUrl:[1,"api-url"],watchParams:[1,"watch-params"],loadingClass:[1,"loading-class"],isLoading:[32]}]);function n(){"undefined"!=typeof customElements&&["jobs-list-reactive"].forEach((s=>{"jobs-list-reactive"===s&&(customElements.get(t(s))||customElements.define(t(s),i))}))}n();const c=i,r=n;export{c as JobsListReactive,r as defineCustomElement}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
var t=(t=>(t.Undefined="undefined",t.Null="null",t.String="string",t.Number="number",t.SpecialNumber="number",t.Boolean="boolean",t.BigInt="bigint",t))(t||{}),n=(t=>(t.Array="array",t.Date="date",t.Map="map",t.Object="object",t.RegularExpression="regexp",t.Set="set",t.Channel="channel",t.Symbol="symbol",t))(n||{}),e="type",l="value",o="serialized:";function s(t,n,e){const l="undefined"!=typeof HTMLElement?HTMLElement.prototype:null;for(;t&&t!==l;){const l=Object.getOwnPropertyDescriptor(t,n);if(l&&(!e||l.get))return l;t=Object.getPrototypeOf(t)}}var r=(t,n)=>{var e;Object.entries(null!=(e=n.l.t)?e:{}).map((([e,[l]])=>{if(31&l||32&l){const l=t[e],o=s(Object.getPrototypeOf(t),e,!0)||Object.getOwnPropertyDescriptor(t,e);o&&Object.defineProperty(t,e,{get(){return o.get.call(this)},set(t){o.set.call(this,t)},configurable:!0,enumerable:!0}),n.o.has(e)?t[e]=n.o.get(e):void 0!==l&&(t[e]=l)}}))},i=t=>{if(t.__stencil__getHostRef)return t.__stencil__getHostRef()},c=(t,n)=>n in t,u=(t,n)=>(0,console.error)(t,n),f=new Map,a="s-id",d="sty-id",$="c-id",p="undefined"!=typeof window?window:{},h=p.HTMLElement||class{},v={i:0,u:"",jmp:t=>t(),raf:t=>requestAnimationFrame(t),ael:(t,n,e,l)=>t.addEventListener(n,e,l),rel:(t,n,e,l)=>t.removeEventListener(n,e,l),ce:(t,n)=>new CustomEvent(t,n)},b=(()=>{var t;let n=!1;try{null==(t=p.document)||t.addEventListener("e",null,Object.defineProperty({},"passive",{get(){n=!0}}))}catch(t){}return n})(),m=(()=>{try{return!!p.document.adoptedStyleSheets&&(new CSSStyleSheet,"function"==typeof(new CSSStyleSheet).replaceSync)}catch(t){}return!1})(),y=!!m&&(()=>!!p.document&&Object.getOwnPropertyDescriptor(p.document.adoptedStyleSheets,"length").writable)(),g=!1,w=[],j=[],O=(t,n)=>e=>{t.push(e),g||(g=!0,n&&4&v.i?k(N):v.raf(N))},S=t=>{for(let n=0;n<t.length;n++)try{t[n](performance.now())}catch(t){u(t)}t.length=0},N=()=>{S(w),S(j),(g=w.length>0)&&v.raf(N)},k=t=>Promise.resolve(undefined).then(t),x=O(j,!0),M=t=>{const n=new URL(t,v.u);return n.origin!==p.location.origin?n.href:n.pathname},E=t=>v.u=t,I=t=>{const n=T(t,"childNodes");t.tagName&&t.tagName.includes("-")&&t["s-cr"]&&"SLOT-FB"!==t.tagName&&L(n,t.tagName).forEach((t=>{1===t.nodeType&&"SLOT-FB"===t.tagName&&(t.hidden=!!A(t,R(t),!1).length)}));let e=0;for(e=0;e<n.length;e++){const t=n[e];1===t.nodeType&&T(t,"childNodes").length&&I(t)}};function L(t,n,e){let l,o=0,s=[];for(;o<t.length;o++){if(l=t[o],l["s-sr"]&&(!n||l["s-hn"]===n)&&(void 0===e||R(l)===e)&&(s.push(l),void 0!==e))return s;s=[...s,...L(l.childNodes,n,e)]}return s}var A=(t,n,e=!0)=>{const l=[];(e&&t["s-sr"]||!t["s-sr"])&&l.push(t);let o=t;for(;o=o.nextSibling;)R(o)!==n||!e&&o["s-sr"]||l.push(o);return l},C=(t,n)=>1===t.nodeType?null===t.getAttribute("slot")&&""===n||t.getAttribute("slot")===n:t["s-sn"]===n||""===n,_=(t,n,e,l)=>{if(t["s-ol"]&&t["s-ol"].isConnected)return;const o=document.createTextNode("");if(o["s-nr"]=t,!n["s-cr"]||!n["s-cr"].parentNode)return;const s=n["s-cr"].parentNode,r=T(s,"appendChild");if(void 0!==l){o["s-oo"]=l;const t=T(s,"childNodes"),n=[o];t.forEach((t=>{t["s-nr"]&&n.push(t)})),n.sort(((t,n)=>!t["s-oo"]||t["s-oo"]<(n["s-oo"]||0)?-1:!n["s-oo"]||n["s-oo"]<t["s-oo"]?1:0)),n.forEach((t=>r.call(s,t)))}else r.call(s,o);t["s-ol"]=o,t["s-sh"]=n["s-hn"]},R=t=>"string"==typeof t["s-sn"]?t["s-sn"]:1===t.nodeType&&t.getAttribute("slot")||void 0;function F(t){if(t.assignedElements||t.assignedNodes||!t["s-sr"])return;const n=n=>function(t){const e=[],l=this["s-sn"];(null==t?void 0:t.flatten)&&console.error("\n Flattening is not supported for Stencil non-shadow slots.\n You can use `.childNodes` to nested slot fallback content.\n If you have a particular use case, please open an issue on the Stencil repo.\n ");const o=this["s-cr"].parentElement;return(o.__childNodes?o.childNodes:(t=>{const n=[];for(let e=0;e<t.length;e++){const l=t[e]["s-nr"]||void 0;l&&l.isConnected&&n.push(l)}return n})(o.childNodes)).forEach((t=>{l===R(t)&&e.push(t)})),n?e.filter((t=>1===t.nodeType)):e}.bind(t);t.assignedElements=n(!0),t.assignedNodes=n(!1)}function T(t,n){if("__"+n in t){const e=t["__"+n];return"function"!=typeof e?e:e.bind(t)}return"function"!=typeof t[n]?t[n]:t[n].bind(t)}var D=new WeakMap,V=t=>"sc-"+t.$,H=t=>"object"==(t=typeof t)||"function"===t,P=(t,n,...e)=>{let l=null,o=null,s=null,r=!1,i=!1;const c=[],u=n=>{for(let e=0;e<n.length;e++)l=n[e],Array.isArray(l)?u(l):null!=l&&"boolean"!=typeof l&&((r="function"!=typeof t&&!H(l))&&(l=String(l)),r&&i?c[c.length-1].p+=l:c.push(r?U(null,l):l),i=r)};if(u(e),n){n.key&&(o=n.key),n.name&&(s=n.name);{const t=n.className||n.class;t&&(n.class="object"!=typeof t?t:Object.keys(t).filter((n=>t[n])).join(" "))}}const f=U(t,null);return f.h=n,c.length>0&&(f.v=c),f.m=o,f.j=s,f},U=(t,n)=>({i:0,O:t,p:null!=n?n:null,S:null,v:null,h:null,m:null,j:null}),B={},W=(t,n,e,l,o,s,r,i=[])=>{let c,u,f,a;if(1===s.nodeType){if(c=s.getAttribute($),c&&(u=c.split("."),u[0]===r||"0"===u[0])){f=q({i:0,N:u[0],k:u[1],M:u[2],I:u[3],O:s.tagName.toLowerCase(),S:s,h:{class:s.className||""}}),n.push(f),s.removeAttribute($),t.v||(t.v=[]);const l=f.S.getAttribute("s-sn");"string"==typeof l&&("slot-fb"===f.O&&Y(l,u[2],f,s,t,n,e,0,i),f.S["s-sn"]=l,f.S.removeAttribute("s-sn")),void 0!==f.I&&(t.v[f.I]=f),t=f}if(s.shadowRoot)for(a=s.shadowRoot.childNodes.length-1;a>=0;a--)W(t,n,e,l,o,s.shadowRoot.childNodes[a],r,i);const d=s.__childNodes||s.childNodes;for(a=d.length-1;a>=0;a--)W(t,n,e,l,o,d[a],r,i)}else if(8===s.nodeType)u=s.nodeValue.split("."),(u[1]===r||"0"===u[1])&&(c=u[0],f=q({N:u[1],k:u[2],M:u[3],I:u[4]||"0",S:s,h:null,v:null,m:null,j:null,O:null,p:null}),"t"===c?(f.S=K(s,3),f.S&&3===f.S.nodeType&&(f.p=f.S.textContent,n.push(f),s.remove(),r===f.N&&(t.v||(t.v=[]),t.v[f.I]=f))):"c"===c?(f.S=K(s,8),f.S&&8===f.S.nodeType&&(n.push(f),s.remove())):f.N===r&&("s"===c?Y(s["s-sn"]=u[5]||"",u[2],f,s,t,n,e,0,i):"r"===c&&(o["s-cr"]=s,s["s-cn"]=!0)));else if(t&&"style"===t.O){const n=U(null,s.textContent);n.S=s,n.I="0",t.v=[n]}return t},z=(t,n)=>{if(1===t.nodeType){const e=t[a]||t.getAttribute(a);e&&n.set(e,t);let l=0;if(t.shadowRoot)for(;l<t.shadowRoot.childNodes.length;l++)z(t.shadowRoot.childNodes[l],n);const o=t.__childNodes||t.childNodes;for(l=0;l<o.length;l++)z(o[l],n)}else if(8===t.nodeType){const e=t.nodeValue.split(".");"o"===e[0]&&(n.set(e[1]+"."+e[2],t),t.nodeValue="",t["s-en"]=e[3])}},q=t=>({i:0,N:null,k:null,M:null,I:"0",S:null,h:null,v:null,m:null,j:null,O:null,p:null,...t});function Y(t,n,e,l,o,s,r,i,c){l["s-sr"]=!0,e.j=t||null,e.O="slot";const u=(null==o?void 0:o.S)?o.S["s-id"]||o.S.getAttribute("s-id"):"";{const s=e.S,r=u&&u!==e.N&&o.S.shadowRoot;G(c,n,t,l,r?u:e.N),F(l),r&&o.S.insertBefore(s,o.S.children[0])}s.push(e),r.push(e),o.v||(o.v=[]),o.v[e.I]=e}var J,Z,G=(t,n,e,l,o)=>{var s,r;let i=l.nextSibling;if(t[n]=t[n]||[],i&&!(null==(s=i.nodeValue)?void 0:s.startsWith("s.")))do{!i||(i.getAttribute&&i.getAttribute("slot")||i["s-sn"])!==e&&(""!==e||i["s-sn"]||i.getAttribute&&i.getAttribute("slot")||8!==i.nodeType&&3!==i.nodeType)||(i["s-sn"]=e,t[n].push({slot:l,node:i,hostId:o})),i=null==i?void 0:i.nextSibling}while(i&&!(null==(r=i.nodeValue)?void 0:r.startsWith("s.")))},K=(t,n)=>{let e=t;do{e=e.nextSibling}while(e&&(e.nodeType!==n||!e.nodeValue));return e},Q=class o{static fromLocalValue(t){const n=t[e],s=l in t?t[l]:void 0;switch(n){case"string":case"boolean":return s;case"bigint":return BigInt(s);case"undefined":return;case"null":return null;case"number":return"NaN"===s?NaN:"-0"===s?-0:"Infinity"===s?1/0:"-Infinity"===s?-1/0:s;case"array":return s.map((t=>o.fromLocalValue(t)));case"date":return new Date(s);case"map":const t=new Map;for(const[n,e]of s){const l="object"==typeof n&&null!==n?o.fromLocalValue(n):n,s=o.fromLocalValue(e);t.set(l,s)}return t;case"object":const e={};for(const[t,n]of s)e[t]=o.fromLocalValue(n);return e;case"regexp":const{pattern:l,flags:r}=s;return new RegExp(l,r);case"set":const i=new Set;for(const t of s)i.add(o.fromLocalValue(t));return i;case"symbol":return Symbol(s);default:throw new Error(`Unsupported type: ${n}`)}}static fromLocalValueArray(t){return t.map((t=>o.fromLocalValue(t)))}static isLocalValueObject(o){if("object"!=typeof o||null===o)return!1;if(!o.hasOwnProperty(e))return!1;const s=o[e];return!!Object.values({...t,...n}).includes(s)&&("null"===s||"undefined"===s||o.hasOwnProperty(l))}},X=(t,n)=>{return"string"==typeof t&&t.startsWith(o)?t="string"==typeof(e=t)&&e.startsWith(o)?Q.fromLocalValue(JSON.parse(atob(e.slice(11)))):e:null==t||H(t)?t:4&n?"false"!==t&&(""===t||!!t):2&n?"string"==typeof t?parseFloat(t):"number"==typeof t?t:NaN:1&n?String(t):t;var e},tt=(t,n)=>{const e=t;return{emit:t=>nt(e,n,{bubbles:!0,composed:!0,cancelable:!0,detail:t})}},nt=(t,n,e)=>{const l=v.ce(n,e);return t.dispatchEvent(l),l},et=(t,n,e,l,o,s,r)=>{if(e===l)return;let u=c(t,n),f=n.toLowerCase();if("class"===n){const n=t.classList,o=ot(e);let s=ot(l);if((t["s-si"]||t["s-sc"])&&r){const e=t["s-sc"]||t["s-si"];s.push(e),o.forEach((t=>{t.startsWith(e)&&s.push(t)})),s=[...new Set(s)].filter((t=>t)),n.add(...s)}else n.remove(...o.filter((t=>t&&!s.includes(t)))),n.add(...s.filter((t=>t&&!o.includes(t))))}else if("style"===n){for(const n in e)l&&null!=l[n]||(n.includes("-")?t.style.removeProperty(n):t.style[n]="");for(const n in l)e&&l[n]===e[n]||(n.includes("-")?t.style.setProperty(n,l[n]):t.style[n]=l[n])}else if("key"===n);else if("ref"===n)l&&kt(l,t);else if(t.__lookupSetter__(n)||"o"!==n[0]||"n"!==n[1]){if("a"===n[0]&&n.startsWith("attr:")){const e=n.slice(5);let o;{const n=i(t);if(n&&n.l&&n.l.t){const t=n.l.t[e];t&&t[1]&&(o=t[1])}}return o||(o=e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase()),void(null==l||!1===l?!1===l&&""!==t.getAttribute(o)||t.removeAttribute(o):t.setAttribute(o,!0===l?"":l))}if("p"===n[0]&&n.startsWith("prop:")){const e=n.slice(5);try{t[e]=l}catch(t){}return}{const r=H(l);if((u||r&&null!==l)&&!o)try{if(t.tagName.includes("-"))t[n]!==l&&(t[n]=l);else{const o=null==l?"":l;"list"===n?u=!1:null!=e&&t[n]===o||("function"==typeof t.__lookupSetter__(n)?t[n]=o:t.setAttribute(n,o))}}catch(t){}null==l||!1===l?!1===l&&""!==t.getAttribute(n)||t.removeAttribute(n):(!u||4&s||o)&&!r&&1===t.nodeType&&t.setAttribute(n,l=!0===l?"":l)}}else if(n="-"===n[2]?n.slice(3):c(p,f)?f.slice(2):f[2]+n.slice(3),e||l){const o=n.endsWith(st);n=n.replace(rt,""),e&&v.rel(t,n,e,o),l&&v.ael(t,n,l,o)}},lt=/\s/,ot=t=>("object"==typeof t&&t&&"baseVal"in t&&(t=t.baseVal),t&&"string"==typeof t?t.split(lt):[]),st="Capture",rt=new RegExp(st+"$"),it=(t,n,e,l)=>{const o=11===n.S.nodeType&&n.S.host?n.S.host:n.S,s=t&&t.h||{},r=n.h||{};for(const t of ct(Object.keys(s)))t in r||et(o,t,s[t],void 0,e,n.i,l);for(const t of ct(Object.keys(r)))et(o,t,s[t],r[t],e,n.i,l)};function ct(t){return t.includes("ref")?[...t.filter((t=>"ref"!==t)),"ref"]:t}var ut=!1,ft=!1,at=!1,dt=!1,$t=[],pt=[],ht=(t,n,e)=>{var l;const o=n.v[e];let s,r,i,c=0;if(ut||(at=!0,"slot"===o.O&&(o.i|=o.v?2:1)),null!=o.p)s=o.S=p.document.createTextNode(o.p);else if(1&o.i)s=o.S=p.document.createTextNode(""),it(null,o,dt);else{if(dt||(dt="svg"===o.O),!p.document)throw new Error("You are trying to render a Stencil component in an environment that doesn't support the DOM.");if(s=o.S=p.document.createElementNS(dt?"http://www.w3.org/2000/svg":"http://www.w3.org/1999/xhtml",!ut&&2&o.i?"slot-fb":o.O),dt&&"foreignObject"===o.O&&(dt=!1),it(null,o,dt),o.v){const n="template"===o.O?s.content:s;for(c=0;c<o.v.length;++c)r=ht(t,o,c),r&&n.appendChild(r)}"svg"===o.O?dt=!1:"foreignObject"===s.tagName&&(dt=!0)}return s["s-hn"]=Z,3&o.i&&(s["s-sr"]=!0,s["s-cr"]=J,s["s-sn"]=o.j||"",s["s-rf"]=null==(l=o.h)?void 0:l.ref,F(s),i=t&&t.v&&t.v[e],i&&i.O===o.O&&t.S&&vt(t.S)),s},vt=t=>{v.i|=1;const n=t.closest(Z.toLowerCase());if(null!=n){const e=Array.from(n.__childNodes||n.childNodes).find((t=>t["s-cr"])),l=Array.from(t.__childNodes||t.childNodes);for(const t of e?l.reverse():l)null!=t["s-sh"]&&(xt(n,t,null!=e?e:null),t["s-sh"]=void 0,at=!0)}v.i&=-2},bt=(t,n)=>{v.i|=1;const e=Array.from(t.__childNodes||t.childNodes);if(t["s-sr"]){let n=t;for(;n=n.nextSibling;)n&&n["s-sn"]===t["s-sn"]&&n["s-sh"]===Z&&e.push(n)}for(let t=e.length-1;t>=0;t--){const l=e[t];l["s-hn"]!==Z&&l["s-ol"]&&(xt(wt(l).parentNode,l,wt(l)),l["s-ol"].remove(),l["s-ol"]=void 0,l["s-sh"]=void 0,at=!0),n&&bt(l,n)}v.i&=-2},mt=(t,n,e,l,o,s)=>{let r,i=t["s-cr"]&&t["s-cr"].parentNode||t;for("template"===e.O&&(i=i.content);o<=s;++o)l[o]&&(r=ht(null,e,o),r&&(l[o].S=r,xt(i,r,wt(n))))},yt=(t,n,e)=>{for(let l=n;l<=e;++l){const n=t[l];if(n){const t=n.S;Nt(n),t&&(ft=!0,t["s-ol"]?t["s-ol"].remove():bt(t,!0),t.remove())}}},gt=(t,n,e=!1)=>t.O===n.O&&("slot"===t.O?t.j===n.j:e?(e&&!t.m&&n.m&&(t.m=n.m),!0):t.m===n.m),wt=t=>t&&t["s-ol"]||t,jt=(t,n,e=!1)=>{const l=n.S=t.S,o=t.v,s=n.v,r=n.O,i=n.p;let c;null==i?(dt="svg"===r||"foreignObject"!==r&&dt,"slot"!==r||ut||t.j!==n.j&&(n.S["s-sn"]=n.j||"",vt(n.S.parentElement)),it(t,n,dt,e),null!==o&&null!==s?((t,n,e,l,o=!1)=>{let s,r,i=0,c=0,u=0,f=0,a=n.length-1,d=n[0],$=n[a],p=l.length-1,h=l[0],v=l[p];const b="template"===e.O?t.content:t;for(;i<=a&&c<=p;)if(null==d)d=n[++i];else if(null==$)$=n[--a];else if(null==h)h=l[++c];else if(null==v)v=l[--p];else if(gt(d,h,o))jt(d,h,o),d=n[++i],h=l[++c];else if(gt($,v,o))jt($,v,o),$=n[--a],v=l[--p];else if(gt(d,v,o))"slot"!==d.O&&"slot"!==v.O||bt(d.S.parentNode,!1),jt(d,v,o),xt(b,d.S,$.S.nextSibling),d=n[++i],v=l[--p];else if(gt($,h,o))"slot"!==d.O&&"slot"!==v.O||bt($.S.parentNode,!1),jt($,h,o),xt(b,$.S,d.S),$=n[--a],h=l[++c];else{for(u=-1,f=i;f<=a;++f)if(n[f]&&null!==n[f].m&&n[f].m===h.m){u=f;break}u>=0?(r=n[u],r.O!==h.O?s=ht(n&&n[c],e,u):(jt(r,h,o),n[u]=void 0,s=r.S),h=l[++c]):(s=ht(n&&n[c],e,c),h=l[++c]),s&&xt(wt(d.S).parentNode,s,wt(d.S))}i>a?mt(t,null==l[p+1]?null:l[p+1].S,e,l,c,p):c>p&&yt(n,i,a)})(l,o,n,s,e):null!==s?(null!==t.p&&(l.textContent=""),mt(l,null,n,s,0,s.length-1)):e||null===o?e&&null!==o&&null===s&&(n.v=o):yt(o,0,o.length-1),dt&&"svg"===r&&(dt=!1)):(c=l["s-cr"])?c.parentNode.textContent=i:t.p!==i&&(l.data=i)},Ot=[],St=t=>{let n,e,l;const o=t.__childNodes||t.childNodes;for(const t of o){if(t["s-sr"]&&(n=t["s-cr"])&&n.parentNode){e=n.parentNode.__childNodes||n.parentNode.childNodes;const o=t["s-sn"];for(l=e.length-1;l>=0;l--)if(n=e[l],!(n["s-cn"]||n["s-nr"]||n["s-hn"]===t["s-hn"]||n["s-sh"]&&n["s-sh"]===t["s-hn"]))if(C(n,o)){let e=Ot.find((t=>t.L===n));ft=!0,n["s-sn"]=n["s-sn"]||o,e?(e.L["s-sh"]=t["s-hn"],e.A=t):(n["s-sh"]=t["s-hn"],Ot.push({A:t,L:n})),n["s-sr"]&&Ot.map((t=>{C(t.L,n["s-sn"])&&(e=Ot.find((t=>t.L===n)),e&&!t.A&&(t.A=e.A))}))}else Ot.some((t=>t.L===n))||Ot.push({L:n})}1===t.nodeType&&St(t)}},Nt=t=>{t.h&&t.h.ref&&$t.push((()=>t.h.ref(null))),t.v&&t.v.map(Nt)},kt=(t,n)=>{pt.push((()=>t(n)))},xt=(t,n,e,l)=>{if("string"==typeof n["s-sn"]){t.insertBefore(n,e);const{slotNode:o}=function(t,n){var e;if(!(n=n||(null==(e=t["s-ol"])?void 0:e.parentElement)))return{slotNode:null,slotName:""};const l=t["s-sn"]=R(t)||"";return{slotNode:L(T(n,"childNodes"),n.tagName,l)[0],slotName:l}}(n);return o&&!l&&o.dispatchEvent(new CustomEvent("slotchange",{bubbles:!1,cancelable:!1,composed:!1})),n}return t.__insertBefore?t.__insertBefore(n,e):null==t?void 0:t.insertBefore(n,e)},Mt=(t,n,e=!1)=>{var l,o,s,r,i;const c=t.$hostElement$,u=t.l,f=t.C||U(null,null);var a;const d=(a=n)&&a.O===B?n:P(null,null,n);if(Z=c.tagName,e&&d.h)for(const t of Object.keys(d.h))c.hasAttribute(t)&&!["key","ref","style","class"].includes(t)&&(d.h[t]=c[t]);if(d.O=null,d.i|=4,t.C=d,d.S=f.S=c,ut=false,J=c["s-cr"],ft=!1,jt(f,d,e),v.i|=1,at){St(d.S);for(const t of Ot){const n=t.L;if(!n["s-ol"]&&p.document){const t=p.document.createTextNode("");t["s-nr"]=n,xt(n.parentNode,n["s-ol"]=t,n,e)}}for(const t of Ot){const n=t.L,i=t.A;if(1===n.nodeType&&e&&(n["s-ih"]=null!=(l=n.hidden)&&l),i){const t=i.parentNode;let l=i.nextSibling;if(l&&1===l.nodeType){let e=null==(o=n["s-ol"])?void 0:o.previousSibling;for(;e;){let o=null!=(s=e["s-nr"])?s:null;if(o&&o["s-sn"]===n["s-sn"]&&t===(o.__parentNode||o.parentNode)){for(o=o.nextSibling;o===n||(null==o?void 0:o["s-sr"]);)o=null==o?void 0:o.nextSibling;if(!o||!o["s-nr"]){l=o;break}}e=e.previousSibling}}if((!l&&t!==(n.__parentNode||n.parentNode)||(n.__nextSibling||n.nextSibling)!==l)&&n!==l){if(xt(t,n,l,e),8===n.nodeType&&n.nodeValue.startsWith("s-nt-")){const t=p.document.createTextNode(n.nodeValue.replace(/^s-nt-/,""));t["s-hn"]=n["s-hn"],t["s-sn"]=n["s-sn"],t["s-sh"]=n["s-sh"],t["s-sr"]=n["s-sr"],t["s-ol"]=n["s-ol"],t["s-ol"]["s-nr"]=t,xt(n.parentNode,t,n,e),n.parentNode.removeChild(n)}1===n.nodeType&&"SLOT-FB"!==n.tagName&&(n.hidden=null!=(r=n["s-ih"])&&r)}n&&"function"==typeof i["s-rf"]&&i["s-rf"](i)}else 1===n.nodeType&&(n.hidden=!0)}}if(ft&&I(d.S),v.i&=-2,Ot.length=0,!ut&&!(1&u.i)&&c["s-cr"]){const t=d.S.__childNodes||d.S.childNodes;for(const n of t)if(n["s-hn"]!==Z&&!n["s-sh"])if(e&&null==n["s-ih"]&&(n["s-ih"]=null!=(i=n.hidden)&&i),1===n.nodeType)n.hidden=!0;else if(3===n.nodeType&&n.nodeValue.trim()){const t=p.document.createComment("s-nt-"+n.nodeValue);t["s-sn"]=n["s-sn"],xt(n.parentNode,t,n,e),n.parentNode.removeChild(n)}}J=void 0,$t.forEach((t=>t())),$t.length=0,pt.forEach((t=>t())),pt.length=0},Et=(t,n)=>{if(n&&!t._&&n["s-p"]){const e=n["s-p"].push(new Promise((l=>t._=()=>{n["s-p"].splice(e-1,1),l()})))}},It=(t,n)=>{if(t.i|=16,4&t.i)return void(t.i|=512);Et(t,t.R);const e=()=>Lt(t,n);if(!n)return x(e);queueMicrotask((()=>{e()}))},Lt=(t,n)=>{const e=t.$hostElement$,l=e;if(!l)throw new Error(`Can't render component <${e.tagName.toLowerCase()} /> with invalid Stencil runtime! Make sure this imported component is compiled with a \`externalRuntime: true\` flag. For more information, please refer to https://stenciljs.com/docs/custom-elements#externalruntime`);let o;return o=Dt(l,n?"componentWillLoad":"componentWillUpdate",void 0,e),o=At(o,(()=>Dt(l,"componentWillRender",void 0,e))),At(o,(()=>_t(t,l,n)))},At=(t,n)=>Ct(t)?t.then(n).catch((t=>{console.error(t),n()})):n(),Ct=t=>t instanceof Promise||t&&t.then&&"function"==typeof t.then,_t=async(t,n,e)=>{var l;const o=t.$hostElement$,s=o["s-rc"];e&&(t=>{const n=t.l;((t,n)=>{var e,l,o;const s=V(n),r=f.get(s);if(!p.document)return s;if(t=11===t.nodeType?t:p.document,r)if("string"==typeof r){let o,i=D.get(t=t.head||t);i||D.set(t,i=new Set);const c=t.querySelector(`[${d}="${s}"]`);if(c)c.textContent=r;else if(!i.has(s)){o=p.document.createElement("style"),o.textContent=r;const c=null!=(e=v.F)?e:function(){var t,n,e;return null!=(e=null==(n=null==(t=p.document.head)?void 0:t.querySelector('meta[name="csp-nonce"]'))?void 0:n.getAttribute("content"))?e:void 0}();if(null!=c&&o.setAttribute("nonce",c),!(1&n.i))if("HEAD"===t.nodeName){const n=t.querySelectorAll("link[rel=preconnect]"),e=n.length>0?n[n.length-1].nextSibling:t.querySelector("style");t.insertBefore(o,(null==e?void 0:e.parentNode)===t?e:null)}else if("host"in t)if(m){const n=new(null!=(l=t.defaultView)?l:t.ownerDocument.defaultView).CSSStyleSheet;n.replaceSync(r),y?t.adoptedStyleSheets.unshift(n):t.adoptedStyleSheets=[n,...t.adoptedStyleSheets]}else{const n=t.querySelector("style");n?n.textContent=r+n.textContent:t.prepend(o)}else t.append(o);1&n.i&&t.insertBefore(o,null),4&n.i&&(o.textContent+="slot-fb{display:contents}slot-fb[hidden]{display:none}"),i&&i.add(s)}}else{let n=D.get(t);if(n||D.set(t,n=new Set),!n.has(s)){const e=null!=(o=t.defaultView)?o:t.ownerDocument.defaultView;let l;if(r.constructor===e.CSSStyleSheet)l=r;else{l=new e.CSSStyleSheet;for(let t=0;t<r.cssRules.length;t++)l.insertRule(r.cssRules[t].cssText,t)}if(y?t.adoptedStyleSheets.push(l):t.adoptedStyleSheets=[...t.adoptedStyleSheets,l],n.add(s),"host"in t){const n=t.querySelector(`[${d}="${s}"]`);n&&x((()=>n.remove()))}}}})(t.$hostElement$.getRootNode(),n)})(t);Rt(t,n,o,e),s&&(s.map((t=>t())),o["s-rc"]=void 0);{const n=null!=(l=o["s-p"])?l:[],e=()=>Ft(t);0===n.length?e():(Promise.all(n).then(e).catch(e),t.i|=4,n.length=0)}},Rt=(t,n,e,l)=>{try{n=n.render(),t.i&=-17,t.i|=2,Mt(t,n,l)}catch(n){u(n,t.$hostElement$)}return null},Ft=t=>{const n=t.$hostElement$,e=n,l=t.R;Dt(e,"componentDidRender",void 0,n),64&t.i?Dt(e,"componentDidUpdate",void 0,n):(t.i|=64,Vt(n),Dt(e,"componentDidLoad",void 0,n),t.T(n),l||Tt()),t._&&(t._(),t._=void 0),512&t.i&&k((()=>It(t,!1))),t.i&=-517},Tt=()=>{var t;k((()=>nt(p,"appload",{detail:{namespace:"web-component-poc"}}))),(null==(t=v.D)?void 0:t.size)&&v.D.clear()},Dt=(t,n,e,l)=>{if(t&&t[n])try{return t[n](e)}catch(t){u(t,l)}},Vt=t=>t.classList.add("hydrated"),Ht=(t,n,e,l)=>{const o=i(t);if(!o)return;const s=t,r=o.o.get(n),c=o.i,u=s;e=X(e,l.t[n][0]);const f=Number.isNaN(r)&&Number.isNaN(e);if(e!==r&&!f&&(o.o.set(n,e),2&c)){if(u.componentShouldUpdate&&!1===u.componentShouldUpdate(e,r,n)&&!(16&c))return;16&c||It(o,!1)}},Pt=(t,n)=>{var e,l;const o=t.prototype;if(n.t){const r=Object.entries(null!=(e=n.t)?e:{});r.map((([t,[e]])=>{if(31&e||32&e){const{get:l,set:r}=s(o,t)||{};l&&(n.t[t][0]|=2048),r&&(n.t[t][0]|=4096),Object.defineProperty(o,t,{get(){return l?l.apply(this):(n=t,i(this).o.get(n));var n},configurable:!0,enumerable:!0}),Object.defineProperty(o,t,{set(l){const o=i(this);if(o){if(r)return void 0===(32&e?this[t]:o.$hostElement$[t])&&o.o.get(t)&&(l=o.o.get(t)),r.apply(this,[X(l,e)]),void Ht(this,t,l=32&e?this[t]:o.$hostElement$[t],n);Ht(this,t,l,n)}}})}}));{const e=new Map;o.attributeChangedCallback=function(t,l,s){v.jmp((()=>{var c;const u=e.get(t),f=i(this);if(this.hasOwnProperty(u),o.hasOwnProperty(u)&&"number"==typeof this[u]&&this[u]==s)return;if(null==u){const e=null==f?void 0:f.i;if(f&&e&&!(8&e)&&s!==l){const o=this,r=null==(c=n.V)?void 0:c[t];null==r||r.forEach((n=>{const[[r,i]]=Object.entries(n);null!=o[r]&&(128&e||1&i)&&o[r].call(o,s,l,t)}))}return}const a=r.find((([t])=>t===u));a&&4&a[1][0]&&(s=null!==s&&"false"!==s);const d=Object.getOwnPropertyDescriptor(o,u);s==this[u]||d.get&&!d.set||(this[u]=s)}))},t.observedAttributes=Array.from(new Set([...Object.keys(null!=(l=n.V)?l:{}),...r.filter((([t,n])=>31&n[0])).map((([t,n])=>{const l=n[1]||t;return e.set(l,t),l}))]))}}return t},Ut=t=>{if(!(1&v.i)){const n=i(t);if(!n)return;const e=n.l,l=()=>{};if(1&n.i)zt(t,n,e.H),(null==n?void 0:n.P)||(null==n?void 0:n.U)&&n.U.then((()=>{}));else{let l;n.i|=1,l=t.getAttribute(a),l&&((t,n,e,l)=>{var o,s,r,c;const u=t.shadowRoot,f=[],d=[],$=U(n,null);$.S=t,!p.document||v.D&&v.D.size||z(p.document.body,v.D=new Map),t[a]=e,t.removeAttribute(a),l.C=W($,f,[],null,t,t,e,d);let h=0;const b=f.length;let m;for(;h<b;h++){m=f[h];const e=m.N+"."+m.k,l=v.D.get(e),s=m.S;if(u){if((null==(o=m.O)?void 0:o.toString().includes("-"))&&"slot-fb"!==m.O&&!m.S.shadowRoot){const t=i(m.S);if(t){const n=V(t.l),e=p.document.querySelector(`style[sty-id="${n}"]`);e&&null.unshift(e.cloneNode(!0))}}}else s["s-hn"]=n.toUpperCase(),"slot"===m.O&&(s["s-cr"]=t["s-cr"]);"slot"===m.O&&(m.j=m.S["s-sn"]||m.S.name||null,m.v?(m.i|=2,m.S.childNodes.length||m.v.forEach((t=>{m.S.appendChild(t.S)}))):m.i|=1),l&&l.isConnected&&(l.parentElement.shadowRoot&&""===l["s-en"]&&l.parentNode.insertBefore(s,l.nextSibling),l.parentNode.removeChild(l),u||(s["s-oo"]=parseInt(m.k))),l&&!l["s-id"]&&v.D.delete(e)}const y=[],g=d.length;let w,j,O,S,N=0,k=0;for(;N<g;N++)if(w=d[N],w&&w.length)for(O=w.length,j=0;j<O;j++){if(S=w[j],y[S.hostId]||(y[S.hostId]=v.D.get(S.hostId)),!y[S.hostId])continue;const t=y[S.hostId];t.shadowRoot&&S.node.parentElement!==t&&t.insertBefore(S.node,null==(r=null==(s=w[j-1])?void 0:s.node)?void 0:r.nextSibling),t.shadowRoot&&u||(S.slot["s-cr"]||(S.slot["s-cr"]=t["s-cr"],S.slot["s-cr"]=!S.slot["s-cr"]&&t.shadowRoot?t:(t.__childNodes||t.childNodes)[0]),_(S.node,S.slot,0,S.node["s-oo"]||k),(null==(c=S.node.parentElement)?void 0:c.shadowRoot)&&S.node.getAttribute&&S.node.getAttribute("slot")&&S.node.removeAttribute("slot")),k=(S.node["s-oo"]||k)+1}l.$hostElement$=t})(t,e.$,l,n),l||12&e.i&&Bt(t);{let e=t;for(;e=e.parentNode||e.host;)if(1===e.nodeType&&e.hasAttribute("s-id")&&e["s-p"]||e["s-p"]){Et(n,n.R=e);break}}e.t&&Object.entries(e.t).map((([n,[e]])=>{if(31&e&&Object.prototype.hasOwnProperty.call(t,n)){const e=t[n];delete t[n],t[n]=e}})),(async(t,n,e)=>{let l;try{if(!(32&n.i)&&(n.i|=32,l=t.constructor,customElements.whenDefined(t.localName).then((()=>n.i|=128)),l&&l.style)){let t;"string"==typeof l.style&&(t=l.style);const n=V(e);if(!f.has(n)){const l=()=>{};((t,n,e)=>{let l=f.get(t);m&&e?(l=l||new CSSStyleSheet,"string"==typeof l?l=n:l.replaceSync(n)):l=n,f.set(t,l)})(n,t,!!(1&e.i)),l()}}const o=n.R,s=()=>It(n,!0);o&&o["s-rc"]?o["s-rc"].push(s):s()}catch(e){u(e,t),n._&&(n._(),n._=void 0),n.T&&n.T(t)}})(t,n,e)}l()}},Bt=t=>{if(!p.document)return;const n=t["s-cr"]=p.document.createComment("");n["s-cn"]=!0,xt(t,n,t.firstChild)},Wt=(t,n)=>{const e={i:n[0],$:n[1]};try{e.t=n[2],e.H=n[3];const l=t.prototype.connectedCallback,o=t.prototype.disconnectedCallback;return Object.assign(t.prototype,{__hasHostListenerAttached:!1,__registerHost(){((t,n)=>{const e={i:0,$hostElement$:t,l:n,o:new Map,B:new Map};e.U=new Promise((t=>e.T=t)),t["s-p"]=[],t["s-rc"]=[];const l=e;t.__stencil__getHostRef=()=>l,512&n.i&&r(t,e)})(this,e)},connectedCallback(){if(!this.__hasHostListenerAttached){const t=i(this);if(!t)return;zt(this,t,e.H),this.__hasHostListenerAttached=!0}Ut(this),l&&l.call(this)},disconnectedCallback(){(async t=>{if(!(1&v.i)){const n=i(t);(null==n?void 0:n.W)&&(n.W.map((t=>t())),n.W=void 0)}D.has(t)&&D.delete(t),t.shadowRoot&&D.has(t.shadowRoot)&&D.delete(t.shadowRoot)})(this),o&&o.call(this)},__attachShadow(){this.shadowRoot=this}}),Object.defineProperty(t,"is",{value:e.$,configurable:!0}),Pt(t,e)}catch(n){return u(n),t}},zt=(t,n,e)=>{e&&p.document&&e.map((([e,l,o])=>{const s=t,r=qt(n,o),i=Yt(e);v.ael(s,l,r,i),(n.W=n.W||[]).push((()=>v.rel(s,l,r,i)))}))},qt=(t,n)=>e=>{try{t.$hostElement$[n](e)}catch(n){u(n,t.$hostElement$)}},Yt=t=>b?{passive:!!(1&t),capture:!!(2&t)}:!!(2&t),Jt=t=>v.F=t,Zt=t=>Object.assign(v,t);function Gt(t,n){Mt({l:{i:0,$:n.tagName},$hostElement$:n},t)}function Kt(t){return t}export{h as H,Jt as a,Zt as b,tt as c,M as g,P as h,Wt as p,Gt as r,E as s,Kt as t}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{t,p as e,H as s,h as i}from"./p-
|
|
1
|
+
import{t,p as e,H as s,h as i}from"./p-Bb27ylcX.js";const l=e(class extends s{constructor(t){super(),!1!==t&&this.__registerHost()}job;index=0;applyButtonText="Apply Now";showBrand=!0;showReference=!1;showEmploymentType=!0;multiLocationText="More locations";remoteLocationText="Remote";enableKilometers=!1;formatDistance(t){const e=this.enableKilometers?"Km":"Miles";return`${(this.enableKilometers?1.60934*t:t).toFixed(1)} ${e}`.replace(".0","")}render(){if(!this.job)return null;const t=function(t){const e=t.locations;if(e?.length)return e[0]}(this.job),e=t?(s=t).cityStateAbbr?s.cityStateAbbr:[s.streetAddress,s.city,s.stateAbbr||s.state,s.countryAbbr||s.country].filter(Boolean).join(", ")||s.locationText||"":"";var s;const l=t?.distance??0,r=l>0?this.formatDistance(l):"",n=this.job.applyURL||(this.job.originalURL?`${"undefined"!=typeof window?window.location.origin:""}${this.job.originalURL}`:"#"),o=`${this.applyButtonText}, ${this.job.title||""}`,a=this.job.locations??[],m=a.length>1;return i("li",{class:"results-list__item"},i("div",{class:"results-list__item-header"},i("h3",{class:"results-list__item-title"},i("a",{class:"results-list__item-title--link",href:n,target:"_blank",rel:"noopener noreferrer"},this.job.title||""),this.showReference&&i("span",{class:"reference "+(this.job.reference?"":"empty")},this.job.reference||""),this.job.isRemote&&i("span",{class:this.remoteLocationText?"remote":"remote remote--empty"},this.remoteLocationText)),r&&i("div",{class:"results-list__item-distance"},i("span",{class:"results-list__item-distance--icon"},i("svg",{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"1.5"},i("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M12 21a9 9 0 1 0 0-18 9 9 0 0 0 0 18z"}),i("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M12 8v4l2 2"}))),i("span",{class:"results-list__item-distance--label"},r))),i("div",{class:"results-list__item-content"},i("div",{class:"results-list__item-info"},i("div",{class:a.length?"results-list__item-street":"results-list__item-street results-list__item-street--empty"},i("div",{class:"results-list__item-street--label__wrapper"},i("span",{class:"results-list__item-street--icon"},i("svg",{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"1.5"},i("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M15 10.5a3 3 0 1 1-6 0 3 3 0 0 1 6 0z"}),i("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M19.5 10.5c0 7.142-7.5 11.25-7.5 11.25S4.5 17.642 4.5 10.5a7.5 7.5 0 1 1 15 0z"}))),i("span",{class:"results-list__item-street--label"},e||"—")),m&&i("div",{class:"results-list__item-street--more-locations__wrapper"},i("span",{class:"results-list__item-street--amount"},"+",a.length-1),i("span",{class:"results-list__item-street--more-locations"},this.multiLocationText))),this.showBrand&&i("div",{class:this.job.brandName?"results-list__item-brand":"results-list__item-brand results-list__item-brand--empty"},i("span",{class:"results-list__item-brand--icon"},i("svg",{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"1.5"},i("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M2.25 21h19.5m-18-18v18m10.5-18v18m6-13.5V21M6.75 6.75h.75m-.75 3h.75m-.75 3h.75m3-6h.75m-.75 3h.75m-.75 3h.75M6.75 21v-3.375c0-.621.504-1.125 1.125-1.125h2.25c.621 0 1.125.504 1.125 1.125V21M3 3h12m-.75 4.5H21m-3.75 3.75h.008v.008h-.008v-.008zm0 3h.008v.008h-.008v-.008zm0 3h.008v.008h-.008v-.008z"}))),i("span",{class:"results-list__item-brand--label"},this.job.brandName||"—")),this.showEmploymentType&&i("div",{class:this.job.employmentType?.length?"results-list__item-employment-type":"results-list__item-employment-type results-list__item-employment-type--empty"},i("span",{class:"results-list__item-employment-type--icon"},i("svg",{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"1.5"},i("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M12 6v6h4.5m4.5 0a9 9 0 1 1-18 0 9 9 0 0 1 18 0z"}))),(this.job.employmentType?.length?this.job.employmentType:["—"]).map((t=>i("span",{key:t,class:"results-list__item-employment-type--label"},t)))),(this.job.jobCardExtraFields??[]).map(((t,e)=>i("div",{key:e,class:(Array.isArray(t.value)?t.value.length:t.value)?t.classname:`${t.classname}--empty`},Array.isArray(t.value)?t.value.map(((e,s)=>i("span",{key:s,class:`${t.classname}--label`},e))):i("span",{class:`${t.classname}--label`},String(t.value)))))),i("a",{class:"results-list__item-apply",href:n,target:"_blank",rel:"noopener noreferrer","aria-label":o},i("span",{class:"results-list__item-apply--label"},this.applyButtonText),i("span",{class:"results-list__item-apply--icon"},i("svg",{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2"},i("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M13 7l5 5m0 0l-5 5m5-5H6"}))))))}static get style(){return".results-list__item{list-style:none;padding:10px 0;border-bottom:1px solid #ddd;margin:15px 0;display:inline-block;width:100%;position:relative}.results-list__item:last-child{border-bottom:none}.results-list__item-header{margin:10px 0;font-size:18px;font-weight:700;display:flex;flex-direction:column}.results-list__item-title{margin:0}.results-list__item-title--link{text-decoration:none;color:#1f9755}.results-list__item-title--link:hover{text-decoration:underline}.reference{margin-left:8px;font-size:0.9em;color:#666}.reference.empty{display:none}.remote{background:#f3f3f3;color:#808285;border-radius:100px;padding:6px 16px;text-transform:uppercase;font-size:12px;font-weight:700;line-height:24px;margin-left:8px}.remote--empty{display:none}.results-list__item-distance{display:inline-flex;align-items:center;gap:4px;margin-top:4px;font-size:14px;font-weight:400}.results-list__item-distance--icon{display:inline-flex}.results-list__item-distance--icon svg{width:16px;height:16px}.results-list__item-content{display:flex;align-items:flex-start;justify-content:space-between;gap:16px;margin-top:8px}.results-list__item-info{flex:1}.results-list__item-street,.results-list__item-brand,.results-list__item-employment-type{margin:10px 0;display:flex;flex-wrap:wrap;align-items:center;gap:4px 8px}.results-list__item-street--empty,.results-list__item-brand--empty,.results-list__item-employment-type--empty{color:#999}.results-list__item-street--icon,.results-list__item-brand--icon,.results-list__item-employment-type--icon{margin-right:6px;display:inline-flex}.results-list__item-street--icon svg,.results-list__item-brand--icon svg,.results-list__item-employment-type--icon svg{width:16px;height:16px}.results-list__item-street--more-locations__wrapper{margin-left:8px}.results-list__item-street--amount{font-weight:600}.results-list__item-apply{margin:10px 0;padding:10px 20px;display:inline-flex;align-items:center;gap:8px;background-color:#198754;color:#fff;border-radius:3px;text-decoration:none;font-weight:600;flex-shrink:0}.results-list__item-apply:hover{background-color:#1f9755;color:#fff}.results-list__item-apply--icon svg{width:14px;height:14px}"}},[512,"jobs-item",{job:[16],index:[2],applyButtonText:[1,"apply-button-text"],showBrand:[4,"show-brand"],showReference:[4,"show-reference"],showEmploymentType:[4,"show-employment-type"],multiLocationText:[1,"multi-location-text"],remoteLocationText:[1,"remote-location-text"],enableKilometers:[4,"enable-kilometers"]}]);function r(){"undefined"!=typeof customElements&&["jobs-item"].forEach((e=>{"jobs-item"===e&&(customElements.get(t(e))||customElements.define(t(e),l))}))}r();export{l as J,r as d}
|
|
@@ -1,11 +1,102 @@
|
|
|
1
|
-
import { r as registerInstance, c as createEvent, h, g as getElement } from './index-
|
|
1
|
+
import { r as registerInstance, c as createEvent, h, g as getElement } from './index-BqjrT3zA.js';
|
|
2
2
|
|
|
3
|
-
const
|
|
3
|
+
const buttonCss = () => `:host{display:inline-block}.fast-button{display:inline-flex;align-items:center;justify-content:center;padding:0.5rem 1rem;font-family:inherit;font-size:0.875rem;font-weight:500;line-height:1.25;border:none;border-radius:0.375rem;cursor:pointer;transition:background-color 0.15s ease, color 0.15s ease, box-shadow 0.15s ease}.fast-button:focus{outline:2px solid var(--custom-button-focus-ring, #2563eb);outline-offset:2px}.fast-button:focus:not(:focus-visible){outline:none}.fast-button--primary{background-color:var(--custom-button-primary-bg, #2563eb);color:var(--custom-button-primary-color, #fff)}.fast-button--primary:hover:not(.fast-button--disabled){background-color:var(--custom-button-primary-hover-bg, #1d4ed8)}.fast-button--primary:active:not(.fast-button--disabled){background-color:var(--custom-button-primary-active-bg, #1e40af)}.fast-button--secondary{background-color:var(--custom-button-secondary-bg, #e5e7eb);color:var(--custom-button-secondary-color, #1f2937)}.fast-button--secondary:hover:not(.fast-button--disabled){background-color:var(--custom-button-secondary-hover-bg, #d1d5db)}.fast-button--secondary:active:not(.fast-button--disabled){background-color:var(--custom-button-secondary-active-bg, #9ca3af)}.fast-button--text{background-color:transparent;color:var(--custom-button-text-color, #2563eb)}.fast-button--text:hover:not(.fast-button--disabled){background-color:var(--custom-button-text-hover-bg, rgba(37, 99, 235, 0.08))}.fast-button--text:active:not(.fast-button--disabled){background-color:var(--custom-button-text-active-bg, rgba(37, 99, 235, 0.12))}.fast-button--disabled,.fast-button:disabled{opacity:0.6;cursor:not-allowed}`;
|
|
4
4
|
|
|
5
|
-
const
|
|
5
|
+
const FastButton = class {
|
|
6
|
+
constructor(hostRef) {
|
|
7
|
+
registerInstance(this, hostRef);
|
|
8
|
+
this.buttonClick = createEvent(this, "buttonClick");
|
|
9
|
+
}
|
|
10
|
+
variant = 'primary';
|
|
11
|
+
type = 'submit';
|
|
12
|
+
disabled = false;
|
|
13
|
+
buttonClick;
|
|
14
|
+
handleClick = (e) => {
|
|
15
|
+
if (this.disabled) {
|
|
16
|
+
e.preventDefault();
|
|
17
|
+
e.stopPropagation();
|
|
18
|
+
return;
|
|
19
|
+
}
|
|
20
|
+
this.buttonClick.emit(e);
|
|
21
|
+
};
|
|
22
|
+
render() {
|
|
23
|
+
return (h("button", { key: 'b8e811748ade97c941bdf197a311d69d2801a120', type: this.type, class: {
|
|
24
|
+
'fast-button': true,
|
|
25
|
+
[`fast-button--${this.variant}`]: true,
|
|
26
|
+
'fast-button--disabled': this.disabled,
|
|
27
|
+
}, disabled: this.disabled, onClick: this.handleClick }, h("slot", { key: 'a6b987059cc33799abd580ea11f0fe644a3973bf' })));
|
|
28
|
+
}
|
|
29
|
+
};
|
|
30
|
+
FastButton.style = buttonCss();
|
|
31
|
+
|
|
32
|
+
const fastFormCss = () => `.fast-form{display:flex;gap:0.5rem;align-items:flex-start}`;
|
|
33
|
+
|
|
34
|
+
const FastForm = class {
|
|
6
35
|
constructor(hostRef) {
|
|
7
36
|
registerInstance(this, hostRef);
|
|
8
37
|
this.searchExecuted = createEvent(this, "searchExecuted");
|
|
38
|
+
}
|
|
39
|
+
get el() { return getElement(this); }
|
|
40
|
+
searchExecuted;
|
|
41
|
+
handleInputSubmit() {
|
|
42
|
+
this.submit();
|
|
43
|
+
}
|
|
44
|
+
async submit() {
|
|
45
|
+
const inputs = this.el.querySelectorAll('fast-input');
|
|
46
|
+
const params = {};
|
|
47
|
+
for (const input of Array.from(inputs)) {
|
|
48
|
+
const paramName = await input.getParamName();
|
|
49
|
+
const value = await input.getValue();
|
|
50
|
+
if (value) {
|
|
51
|
+
params[paramName] = value;
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
this.updateUrlParams(params);
|
|
55
|
+
document.dispatchEvent(new CustomEvent('search-executed', {
|
|
56
|
+
detail: params,
|
|
57
|
+
bubbles: true,
|
|
58
|
+
composed: true,
|
|
59
|
+
}));
|
|
60
|
+
this.searchExecuted.emit(params);
|
|
61
|
+
}
|
|
62
|
+
updateUrlParams(params) {
|
|
63
|
+
const urlParams = new URLSearchParams(window.location.search);
|
|
64
|
+
// Get all param names from inputs and clear them first
|
|
65
|
+
const inputs = this.el.querySelectorAll('fast-input');
|
|
66
|
+
for (const input of Array.from(inputs)) {
|
|
67
|
+
const paramName = input.paramName;
|
|
68
|
+
if (paramName) {
|
|
69
|
+
urlParams.delete(paramName);
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
// Set new values
|
|
73
|
+
for (const [key, value] of Object.entries(params)) {
|
|
74
|
+
if (value) {
|
|
75
|
+
urlParams.set(key, value);
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
const qs = urlParams.toString();
|
|
79
|
+
const newUrl = qs
|
|
80
|
+
? `${window.location.pathname}?${qs}`
|
|
81
|
+
: window.location.pathname;
|
|
82
|
+
history.pushState({}, '', newUrl);
|
|
83
|
+
}
|
|
84
|
+
handleFormSubmit = (e) => {
|
|
85
|
+
e.preventDefault();
|
|
86
|
+
this.submit();
|
|
87
|
+
};
|
|
88
|
+
render() {
|
|
89
|
+
return (h("form", { key: '50436bb904e8b175ae0c23158812a4e4756544c0', class: "fast-form", onSubmit: this.handleFormSubmit }, h("slot", { key: '2f76c4c42c15ebf389d6e0fdbcb9a2098bf1156a' })));
|
|
90
|
+
}
|
|
91
|
+
};
|
|
92
|
+
FastForm.style = fastFormCss();
|
|
93
|
+
|
|
94
|
+
const fastInputCss = () => `.fast-input{position:relative;display:inline-block}.fast-input__field{padding:0.5rem 0.75rem;font-size:1rem;border:1px solid #ccc;border-radius:4px;width:100%;box-sizing:border-box}.fast-input__dropdown{position:absolute;top:100%;left:0;right:0;margin:0;padding:0;list-style:none;background:#fff;border:1px solid #ccc;border-top:none;border-radius:0 0 4px 4px;z-index:100;max-height:200px;overflow-y:auto}.fast-input__dropdown-item{padding:0.5rem 0.75rem;cursor:pointer}.fast-input__dropdown-item:hover{background:#f0f0f0}.fast-input__dropdown-loading{padding:0.5rem 0.75rem;color:#999;font-style:italic}`;
|
|
95
|
+
|
|
96
|
+
const FastInput = class {
|
|
97
|
+
constructor(hostRef) {
|
|
98
|
+
registerInstance(this, hostRef);
|
|
99
|
+
this.inputSubmit = createEvent(this, "inputSubmit");
|
|
9
100
|
this.inputChanged = createEvent(this, "inputChanged");
|
|
10
101
|
}
|
|
11
102
|
placeholder = 'Search...';
|
|
@@ -16,7 +107,7 @@ const FastInput = class {
|
|
|
16
107
|
targetPath;
|
|
17
108
|
debounceMs = 300;
|
|
18
109
|
minChars = 3;
|
|
19
|
-
|
|
110
|
+
inputSubmit;
|
|
20
111
|
inputChanged;
|
|
21
112
|
inputValue = '';
|
|
22
113
|
suggestions = [];
|
|
@@ -24,6 +115,12 @@ const FastInput = class {
|
|
|
24
115
|
autocompleteLoading = false;
|
|
25
116
|
debounceTimer;
|
|
26
117
|
popstateHandler;
|
|
118
|
+
async getValue() {
|
|
119
|
+
return this.inputValue;
|
|
120
|
+
}
|
|
121
|
+
async getParamName() {
|
|
122
|
+
return this.paramName;
|
|
123
|
+
}
|
|
27
124
|
connectedCallback() {
|
|
28
125
|
const urlValue = this.getUrlParam();
|
|
29
126
|
this.inputValue = urlValue !== null ? urlValue : this.value;
|
|
@@ -40,30 +137,6 @@ const FastInput = class {
|
|
|
40
137
|
const params = new URLSearchParams(window.location.search);
|
|
41
138
|
return params.get(this.paramName);
|
|
42
139
|
}
|
|
43
|
-
updateUrlParam(value) {
|
|
44
|
-
const params = new URLSearchParams(window.location.search);
|
|
45
|
-
if (value) {
|
|
46
|
-
params.set(this.paramName, value);
|
|
47
|
-
}
|
|
48
|
-
else {
|
|
49
|
-
params.delete(this.paramName);
|
|
50
|
-
}
|
|
51
|
-
const qs = params.toString();
|
|
52
|
-
const newUrl = qs
|
|
53
|
-
? `${window.location.pathname}?${qs}`
|
|
54
|
-
: window.location.pathname;
|
|
55
|
-
history.pushState({}, '', newUrl);
|
|
56
|
-
}
|
|
57
|
-
submit() {
|
|
58
|
-
this.updateUrlParam(this.inputValue);
|
|
59
|
-
document.dispatchEvent(new CustomEvent('search-executed', {
|
|
60
|
-
detail: { keyword: this.inputValue },
|
|
61
|
-
bubbles: true,
|
|
62
|
-
composed: true,
|
|
63
|
-
}));
|
|
64
|
-
this.searchExecuted.emit({ keyword: this.inputValue });
|
|
65
|
-
this.showDropdown = false;
|
|
66
|
-
}
|
|
67
140
|
handleInput = (e) => {
|
|
68
141
|
const value = e.target.value;
|
|
69
142
|
this.inputValue = value;
|
|
@@ -74,7 +147,9 @@ const FastInput = class {
|
|
|
74
147
|
};
|
|
75
148
|
handleKeydown = (e) => {
|
|
76
149
|
if (e.key === 'Enter') {
|
|
77
|
-
|
|
150
|
+
e.preventDefault();
|
|
151
|
+
this.showDropdown = false;
|
|
152
|
+
this.inputSubmit.emit();
|
|
78
153
|
}
|
|
79
154
|
else if (e.key === 'Escape') {
|
|
80
155
|
this.showDropdown = false;
|
|
@@ -120,10 +195,12 @@ const FastInput = class {
|
|
|
120
195
|
selectSuggestion(title) {
|
|
121
196
|
this.inputValue = title;
|
|
122
197
|
this.showDropdown = false;
|
|
123
|
-
this.
|
|
198
|
+
this.inputSubmit.emit();
|
|
124
199
|
}
|
|
125
200
|
render() {
|
|
126
|
-
return (h("div", { key: '
|
|
201
|
+
return (h("div", { key: 'ea03f3dd68d0da4fc30cbc18a1ef66b5974a4f89', class: "fast-input" }, h("input", { key: '31d85c4c90dde0e10ea9424b960c5e4f4a3ca54a', type: "text", class: "fast-input__field", placeholder: this.placeholder, value: this.inputValue, onInput: this.handleInput, onKeyDown: this.handleKeydown, onBlur: this.handleBlur }), this.enableAutocomplete && this.showDropdown && (h("ul", { key: '0de6fd68709d906bafd2fec684f0a73045be3705', class: "fast-input__dropdown" }, this.autocompleteLoading ? (h("li", { class: "fast-input__dropdown-loading" }, "Loading...")) : (this.suggestions.map(s => (h("li", { class: "fast-input__dropdown-item", onMouseDown: e => {
|
|
202
|
+
e.preventDefault();
|
|
203
|
+
}, onClick: () => this.selectSuggestion(s.title) }, s.title))))))));
|
|
127
204
|
}
|
|
128
205
|
};
|
|
129
206
|
FastInput.style = fastInputCss();
|
|
@@ -382,7 +459,7 @@ const JobsListOnly = class {
|
|
|
382
459
|
: (this.totalJob || jobsArray.length);
|
|
383
460
|
const showNoResults = !loading && totalJob === 0 && !this.showSuggestions;
|
|
384
461
|
const showSuggestionsBlock = !loading && totalJob === 0 && this.showSuggestions;
|
|
385
|
-
return (h("div", { key: '
|
|
462
|
+
return (h("div", { key: '1974ecb7e1ded8237d851560fc4b20dd63b4e941', class: `jobs-list-root ${this.rootClass}`.trim() }, h("div", { key: '3d80283e8508cbe9ec4aa4516a6f832479374e08', class: "results-container" }, this.autoFetch && this.fetchLoading && (h("div", { key: 'c5d3c5362a10ce2442925093118d3436227e8058', class: "jobs-list-only__loading" }, "Loading...")), h("div", { key: 'c68e5aebee17cce16947029031b63364ab25ecda', class: loading ? 'loader' : 'loader hide', "aria-hidden": !loading }), totalJob > 0 && this.showCountText && (h("p", { key: 'e353fa146040fed1aed050ed3ed833903efcdf41', class: "jobs-list-only__count" }, this.renderCountText(jobsArray.length, totalJob))), totalJob > 0 && (h("div", { key: 'e38346f641a1e776a7e70525bf8f3a6a38b6eea5', class: "card" }, h("ul", { key: 'db82d99df76e33ad6041d4ec8dd7908cdf8b89d7', class: "results-list front" }, jobsArray.map((job, index) => this.renderJobItem(job, index))))), showNoResults && (h("div", { key: '8bd8f45ddb9fcd534c7f386919c1e6cd7a4fb6f3', class: "share-jobs__no-results" }, h("h2", { key: '228d32e9dd38f61bcec9f522d3bc4207e17b5365' }, this.noResultsLine1), h("h3", { key: '4289b10974936669a00afba6f1d55e33874198b1' }, this.noResultsLine2))), showSuggestionsBlock && (h("div", { key: '949e1fe01b2db39a69729a9fbc2eebaf2ea461ba', class: "card primary-color" }, h("h4", { key: 'af3361f98987a3a19d45afc1174a99fc4174a65a', class: "result-suggestions-title" }, this.clearResultSuggestionsTitleText, ":"), h("ul", { key: 'd7b9236dbbeb9f9596d642aa588d1c1305ed658b', class: "results-list front" }, h("li", { key: '0e65c9b985e5708096c8a4b0ea1455b6696db6dd', class: "result-suggestions-line" }, this.clearResultSuggestionsLine1), h("li", { key: 'a7fe8459960af60acc81822b48436a32c0e4ad0c', class: "result-suggestions-line" }, this.clearResultSuggestionsLine2), h("li", { key: '1e41d5730de755d6b2cb9e5fbda33704816f9096', class: "result-suggestions-line" }, this.clearResultSuggestionsLine3), this.clearResultSuggestionsLine4 && (h("li", { key: '9ab1bee87135bfda9996b2c99134597475bfaecb', class: "result-suggestions-line" }, this.clearResultSuggestionsLine4))))))));
|
|
386
463
|
}
|
|
387
464
|
};
|
|
388
465
|
JobsListOnly.style = jobsListOnlyCss();
|
|
@@ -486,9 +563,9 @@ const JobsListReactive = class {
|
|
|
486
563
|
});
|
|
487
564
|
}
|
|
488
565
|
render() {
|
|
489
|
-
return h("slot", { key: '
|
|
566
|
+
return h("slot", { key: '9f3ab802e19a298a790cfb5e86a4f4888e466804' });
|
|
490
567
|
}
|
|
491
568
|
};
|
|
492
569
|
JobsListReactive.style = jobsListReactiveCss();
|
|
493
570
|
|
|
494
|
-
export { FastInput as fast_input, JobsItem as jobs_item, JobsListOnly as jobs_list_only, JobsListReactive as jobs_list_reactive };
|
|
571
|
+
export { FastButton as fast_button, FastForm as fast_form, FastInput as fast_input, JobsItem as jobs_item, JobsListOnly as jobs_list_only, JobsListReactive as jobs_list_reactive };
|
|
@@ -173,6 +173,23 @@ var plt = {
|
|
|
173
173
|
ce: (eventName, opts) => new CustomEvent(eventName, opts)
|
|
174
174
|
};
|
|
175
175
|
var supportsShadow = BUILD.shadowDom;
|
|
176
|
+
var supportsListenerOptions = /* @__PURE__ */ (() => {
|
|
177
|
+
var _a;
|
|
178
|
+
let supportsListenerOptions2 = false;
|
|
179
|
+
try {
|
|
180
|
+
(_a = win.document) == null ? void 0 : _a.addEventListener(
|
|
181
|
+
"e",
|
|
182
|
+
null,
|
|
183
|
+
Object.defineProperty({}, "passive", {
|
|
184
|
+
get() {
|
|
185
|
+
supportsListenerOptions2 = true;
|
|
186
|
+
}
|
|
187
|
+
})
|
|
188
|
+
);
|
|
189
|
+
} catch (e) {
|
|
190
|
+
}
|
|
191
|
+
return supportsListenerOptions2;
|
|
192
|
+
})();
|
|
176
193
|
var promiseResolve = (v) => Promise.resolve(v);
|
|
177
194
|
var supportsConstructableStylesheets = /* @__PURE__ */ (() => {
|
|
178
195
|
try {
|
|
@@ -1859,6 +1876,13 @@ var dispatchHooks = (hostRef, isInitialLoad) => {
|
|
|
1859
1876
|
hostRef.$deferredConnectedCallback$ = false;
|
|
1860
1877
|
safeCall(instance, "connectedCallback", void 0, elm);
|
|
1861
1878
|
}
|
|
1879
|
+
{
|
|
1880
|
+
hostRef.$flags$ |= 256 /* isListenReady */;
|
|
1881
|
+
if (hostRef.$queuedListeners$) {
|
|
1882
|
+
hostRef.$queuedListeners$.map(([methodName, event]) => safeCall(instance, methodName, event, elm));
|
|
1883
|
+
hostRef.$queuedListeners$ = void 0;
|
|
1884
|
+
}
|
|
1885
|
+
}
|
|
1862
1886
|
if (hostRef.$fetchedCbList$.length) {
|
|
1863
1887
|
hostRef.$fetchedCbList$.forEach((cb) => cb(elm));
|
|
1864
1888
|
}
|
|
@@ -2301,6 +2325,7 @@ var connectedCallback = (elm) => {
|
|
|
2301
2325
|
initializeComponent(elm, hostRef, cmpMeta);
|
|
2302
2326
|
}
|
|
2303
2327
|
} else {
|
|
2328
|
+
addHostEventListeners(elm, hostRef, cmpMeta.$listeners$);
|
|
2304
2329
|
if (hostRef == null ? void 0 : hostRef.$lazyInstance$) {
|
|
2305
2330
|
fireConnectedCallback(hostRef.$lazyInstance$, elm);
|
|
2306
2331
|
} else if (hostRef == null ? void 0 : hostRef.$onReadyPromise$) {
|
|
@@ -2328,6 +2353,12 @@ var disconnectInstance = (instance, elm) => {
|
|
|
2328
2353
|
var disconnectedCallback = async (elm) => {
|
|
2329
2354
|
if ((plt.$flags$ & 1 /* isTmpDisconnected */) === 0) {
|
|
2330
2355
|
const hostRef = getHostRef(elm);
|
|
2356
|
+
{
|
|
2357
|
+
if (hostRef == null ? void 0 : hostRef.$rmListeners$) {
|
|
2358
|
+
hostRef.$rmListeners$.map((rmListener) => rmListener());
|
|
2359
|
+
hostRef.$rmListeners$ = void 0;
|
|
2360
|
+
}
|
|
2361
|
+
}
|
|
2331
2362
|
if (hostRef == null ? void 0 : hostRef.$lazyInstance$) {
|
|
2332
2363
|
disconnectInstance(hostRef.$lazyInstance$, elm);
|
|
2333
2364
|
} else if (hostRef == null ? void 0 : hostRef.$onReadyPromise$) {
|
|
@@ -2379,6 +2410,9 @@ var bootstrapLazy = (lazyBundles, options = {}) => {
|
|
|
2379
2410
|
{
|
|
2380
2411
|
cmpMeta.$members$ = compactMeta[2];
|
|
2381
2412
|
}
|
|
2413
|
+
{
|
|
2414
|
+
cmpMeta.$listeners$ = compactMeta[3];
|
|
2415
|
+
}
|
|
2382
2416
|
const tagName = transformTag(cmpMeta.$tagName$);
|
|
2383
2417
|
const HostElement = class extends HTMLElement {
|
|
2384
2418
|
["s-p"];
|
|
@@ -2397,6 +2431,7 @@ var bootstrapLazy = (lazyBundles, options = {}) => {
|
|
|
2397
2431
|
}
|
|
2398
2432
|
if (!this.hasRegisteredEventListeners) {
|
|
2399
2433
|
this.hasRegisteredEventListeners = true;
|
|
2434
|
+
addHostEventListeners(this, hostRef, cmpMeta.$listeners$);
|
|
2400
2435
|
}
|
|
2401
2436
|
if (appLoadFallback) {
|
|
2402
2437
|
clearTimeout(appLoadFallback);
|
|
@@ -2466,6 +2501,35 @@ var bootstrapLazy = (lazyBundles, options = {}) => {
|
|
|
2466
2501
|
}
|
|
2467
2502
|
endBootstrap();
|
|
2468
2503
|
};
|
|
2504
|
+
var addHostEventListeners = (elm, hostRef, listeners, attachParentListeners) => {
|
|
2505
|
+
if (listeners && win.document) {
|
|
2506
|
+
listeners.map(([flags, name, method]) => {
|
|
2507
|
+
const target = elm;
|
|
2508
|
+
const handler = hostListenerProxy(hostRef, method);
|
|
2509
|
+
const opts = hostListenerOpts(flags);
|
|
2510
|
+
plt.ael(target, name, handler, opts);
|
|
2511
|
+
(hostRef.$rmListeners$ = hostRef.$rmListeners$ || []).push(() => plt.rel(target, name, handler, opts));
|
|
2512
|
+
});
|
|
2513
|
+
}
|
|
2514
|
+
};
|
|
2515
|
+
var hostListenerProxy = (hostRef, methodName) => (ev) => {
|
|
2516
|
+
var _a;
|
|
2517
|
+
try {
|
|
2518
|
+
{
|
|
2519
|
+
if (hostRef.$flags$ & 256 /* isListenReady */) {
|
|
2520
|
+
(_a = hostRef.$lazyInstance$) == null ? void 0 : _a[methodName](ev);
|
|
2521
|
+
} else {
|
|
2522
|
+
(hostRef.$queuedListeners$ = hostRef.$queuedListeners$ || []).push([methodName, ev]);
|
|
2523
|
+
}
|
|
2524
|
+
}
|
|
2525
|
+
} catch (e) {
|
|
2526
|
+
consoleError(e, hostRef.$hostElement$);
|
|
2527
|
+
}
|
|
2528
|
+
};
|
|
2529
|
+
var hostListenerOpts = (flags) => supportsListenerOptions ? {
|
|
2530
|
+
passive: (flags & 1 /* Passive */) !== 0,
|
|
2531
|
+
capture: (flags & 2 /* Capture */) !== 0
|
|
2532
|
+
} : (flags & 2 /* Capture */) !== 0;
|
|
2469
2533
|
|
|
2470
2534
|
// src/runtime/nonce.ts
|
|
2471
2535
|
var setNonce = (nonce) => plt.$nonce$ = nonce;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { r as registerInstance, h } from './index-
|
|
1
|
+
import { r as registerInstance, h } from './index-BqjrT3zA.js';
|
|
2
2
|
|
|
3
3
|
const jobCardCss = () => `.job-card{display:block;padding:16px;border:1px solid #e0e0e0;border-radius:8px;background-color:#fff;box-shadow:0 2px 4px rgba(0, 0, 0, 0.08);transition:box-shadow 0.2s ease, border-color 0.2s ease}.job-card:hover{box-shadow:0 4px 8px rgba(0, 0, 0, 0.12);border-color:#d0d0d0}.job-card__header{margin-bottom:12px}.job-card__title{margin:0;font-size:18px;font-weight:700;display:flex;align-items:center;flex-wrap:wrap;gap:8px}.job-card__title--link{text-decoration:none;color:#1f9755;transition:color 0.2s ease}.job-card__title--link:hover{text-decoration:underline;color:#1a7a43}.job-card__reference{font-size:0.875em;color:#666;background-color:#f5f5f5;padding:2px 6px;border-radius:3px}.job-card__reference--empty{display:none}.job-card__remote{background:#e8f5e9;color:#2e7d32;border-radius:100px;padding:4px 12px;text-transform:uppercase;font-size:11px;font-weight:700;line-height:1.5;white-space:nowrap}.job-card__remote--empty{display:none}.job-card__distance{display:inline-flex;align-items:center;gap:4px;margin-top:6px;font-size:13px;font-weight:500;color:#555}.job-card__distance--icon{display:inline-flex;align-items:center}.job-card__distance--icon svg{width:16px;height:16px;color:#1f9755}.job-card__content{display:flex;align-items:flex-start;justify-content:space-between;gap:12px}.job-card__info{flex:1;display:flex;flex-direction:column;gap:8px}.job-card__street,.job-card__brand,.job-card__employment-type{display:flex;align-items:center;flex-wrap:wrap;gap:4px 6px;font-size:14px}.job-card__street--empty,.job-card__brand--empty,.job-card__employment-type--empty{color:#999}.job-card__street--icon,.job-card__brand--icon,.job-card__employment-type--icon{display:inline-flex;align-items:center;flex-shrink:0}.job-card__street--icon svg,.job-card__brand--icon svg,.job-card__employment-type--icon svg{width:16px;height:16px;color:#666}.job-card__street--label,.job-card__brand--label,.job-card__employment-type--label{color:#333}.job-card__street--label__wrapper{display:flex;align-items:center;gap:6px}.job-card__street--more-locations__wrapper{display:flex;align-items:center;gap:2px;font-size:12px;margin-left:2px}.job-card__street--amount{font-weight:600;color:#1f9755}.job-card__street--more-locations{color:#999}.job-card__apply{display:inline-flex;align-items:center;justify-content:center;gap:6px;padding:10px 16px;background-color:#198754;color:#fff;border-radius:4px;text-decoration:none;font-weight:600;font-size:14px;transition:background-color 0.2s ease, transform 0.1s ease;white-space:nowrap;flex-shrink:0}.job-card__apply:hover{background-color:#1a6f47;transform:translateY(-1px)}.job-card__apply:active{transform:translateY(0)}.job-card__apply--icon{display:inline-flex;align-items:center}.job-card__apply--icon svg{width:14px;height:14px}@media (max-width: 768px){.job-card{padding:12px}.job-card__content{flex-direction:column;gap:10px}.job-card__apply{width:100%;justify-content:center}.job-card__title{font-size:16px}}@media (max-width: 480px){.job-card{padding:10px}.job-card__title{font-size:15px}.job-card__distance{font-size:12px}.job-card__street,.job-card__brand,.job-card__employment-type{font-size:13px}}`;
|
|
4
4
|
|
package/dist/esm/loader.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { b as bootstrapLazy } from './index-
|
|
2
|
-
export { s as setNonce } from './index-
|
|
1
|
+
import { b as bootstrapLazy } from './index-BqjrT3zA.js';
|
|
2
|
+
export { s as setNonce } from './index-BqjrT3zA.js';
|
|
3
3
|
import { g as globalScripts } from './app-globals-DQuL1Twl.js';
|
|
4
4
|
|
|
5
5
|
const defineCustomElements = async (win, options) => {
|
|
6
6
|
if (typeof window === 'undefined') return undefined;
|
|
7
7
|
await globalScripts();
|
|
8
|
-
return bootstrapLazy([["fast-
|
|
8
|
+
return bootstrapLazy([["fast-carousel",[[772,"fast-carousel",{"items":[1],"loop":[4],"class":[1],"controlClass":[1,"control-class"],"slideClass":[1,"slide-class"],"itemClass":[1,"item-class"],"scrollPrev":[64],"scrollNext":[64],"goToSlide":[64],"getEmbla":[64]}]]],["job-card",[[512,"job-card",{"job":[1],"index":[2],"applyButtonText":[1,"apply-button-text"],"showBrand":[4,"show-brand"],"showReference":[4,"show-reference"],"showEmploymentType":[4,"show-employment-type"],"multiLocationText":[1,"multi-location-text"],"remoteLocationText":[1,"remote-location-text"],"enableKilometers":[4,"enable-kilometers"],"showCommuteTime":[4,"show-commute-time"],"streetFormat":[1,"street-format"],"rootClass":[1,"root-class"],"extraFieldsConfig":[16]}]]],["fast-button_6",[[512,"jobs-list-only",{"mockData":[4,"mock-data"],"jobs":[1],"loading":[4],"totalJob":[2,"total-job"],"noResultsLine1":[1,"no-results-line-1"],"noResultsLine2":[1,"no-results-line-2"],"applyButtonText":[1,"apply-button-text"],"showBrand":[4,"show-brand"],"showReference":[4,"show-reference"],"showEmploymentType":[4,"show-employment-type"],"streetFormat":[1,"street-format"],"multiLocationText":[1,"multi-location-text"],"remoteLocationText":[1,"remote-location-text"],"enableKilometers":[4,"enable-kilometers"],"rootClass":[1,"root-class"],"showCountText":[1,"show-count-text"],"showSuggestions":[4,"show-suggestions"],"clearResultSuggestionsTitleText":[1,"clear-result-suggestions-title-text"],"clearResultSuggestionsLine1":[1,"clear-result-suggestions-line-1"],"clearResultSuggestionsLine2":[1,"clear-result-suggestions-line-2"],"clearResultSuggestionsLine3":[1,"clear-result-suggestions-line-3"],"clearResultSuggestionsLine4":[1,"clear-result-suggestions-line-4"],"autoFetch":[4,"auto-fetch"],"apiUrl":[1,"api-url"],"watchParams":[1,"watch-params"],"fetchedJobs":[32],"fetchedTotal":[32],"fetchLoading":[32]}],[772,"fast-button",{"variant":[1],"type":[1],"disabled":[4]}],[260,"fast-form",null,[[0,"inputSubmit","handleInputSubmit"]]],[512,"fast-input",{"placeholder":[1],"value":[1],"paramName":[1,"param-name"],"enableAutocomplete":[4,"enable-autocomplete"],"autocompleteUrl":[1,"autocomplete-url"],"targetPath":[1,"target-path"],"debounceMs":[2,"debounce-ms"],"minChars":[2,"min-chars"],"inputValue":[32],"suggestions":[32],"showDropdown":[32],"autocompleteLoading":[32],"getValue":[64],"getParamName":[64]}],[772,"jobs-list-reactive",{"apiUrl":[1,"api-url"],"watchParams":[1,"watch-params"],"loadingClass":[1,"loading-class"],"isLoading":[32]}],[512,"jobs-item",{"job":[16],"index":[2],"applyButtonText":[1,"apply-button-text"],"showBrand":[4,"show-brand"],"showReference":[4,"show-reference"],"showEmploymentType":[4,"show-employment-type"],"multiLocationText":[1,"multi-location-text"],"remoteLocationText":[1,"remote-location-text"],"enableKilometers":[4,"enable-kilometers"]}]]]], options);
|
|
9
9
|
};
|
|
10
10
|
|
|
11
11
|
export { defineCustomElements };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { p as promiseResolve, b as bootstrapLazy } from './index-
|
|
2
|
-
export { s as setNonce } from './index-
|
|
1
|
+
import { p as promiseResolve, b as bootstrapLazy } from './index-BqjrT3zA.js';
|
|
2
|
+
export { s as setNonce } from './index-BqjrT3zA.js';
|
|
3
3
|
import { g as globalScripts } from './app-globals-DQuL1Twl.js';
|
|
4
4
|
|
|
5
5
|
/*
|
|
@@ -17,5 +17,5 @@ var patchBrowser = () => {
|
|
|
17
17
|
|
|
18
18
|
patchBrowser().then(async (options) => {
|
|
19
19
|
await globalScripts();
|
|
20
|
-
return bootstrapLazy([["fast-
|
|
20
|
+
return bootstrapLazy([["fast-carousel",[[772,"fast-carousel",{"items":[1],"loop":[4],"class":[1],"controlClass":[1,"control-class"],"slideClass":[1,"slide-class"],"itemClass":[1,"item-class"],"scrollPrev":[64],"scrollNext":[64],"goToSlide":[64],"getEmbla":[64]}]]],["job-card",[[512,"job-card",{"job":[1],"index":[2],"applyButtonText":[1,"apply-button-text"],"showBrand":[4,"show-brand"],"showReference":[4,"show-reference"],"showEmploymentType":[4,"show-employment-type"],"multiLocationText":[1,"multi-location-text"],"remoteLocationText":[1,"remote-location-text"],"enableKilometers":[4,"enable-kilometers"],"showCommuteTime":[4,"show-commute-time"],"streetFormat":[1,"street-format"],"rootClass":[1,"root-class"],"extraFieldsConfig":[16]}]]],["fast-button_6",[[512,"jobs-list-only",{"mockData":[4,"mock-data"],"jobs":[1],"loading":[4],"totalJob":[2,"total-job"],"noResultsLine1":[1,"no-results-line-1"],"noResultsLine2":[1,"no-results-line-2"],"applyButtonText":[1,"apply-button-text"],"showBrand":[4,"show-brand"],"showReference":[4,"show-reference"],"showEmploymentType":[4,"show-employment-type"],"streetFormat":[1,"street-format"],"multiLocationText":[1,"multi-location-text"],"remoteLocationText":[1,"remote-location-text"],"enableKilometers":[4,"enable-kilometers"],"rootClass":[1,"root-class"],"showCountText":[1,"show-count-text"],"showSuggestions":[4,"show-suggestions"],"clearResultSuggestionsTitleText":[1,"clear-result-suggestions-title-text"],"clearResultSuggestionsLine1":[1,"clear-result-suggestions-line-1"],"clearResultSuggestionsLine2":[1,"clear-result-suggestions-line-2"],"clearResultSuggestionsLine3":[1,"clear-result-suggestions-line-3"],"clearResultSuggestionsLine4":[1,"clear-result-suggestions-line-4"],"autoFetch":[4,"auto-fetch"],"apiUrl":[1,"api-url"],"watchParams":[1,"watch-params"],"fetchedJobs":[32],"fetchedTotal":[32],"fetchLoading":[32]}],[772,"fast-button",{"variant":[1],"type":[1],"disabled":[4]}],[260,"fast-form",null,[[0,"inputSubmit","handleInputSubmit"]]],[512,"fast-input",{"placeholder":[1],"value":[1],"paramName":[1,"param-name"],"enableAutocomplete":[4,"enable-autocomplete"],"autocompleteUrl":[1,"autocomplete-url"],"targetPath":[1,"target-path"],"debounceMs":[2,"debounce-ms"],"minChars":[2,"min-chars"],"inputValue":[32],"suggestions":[32],"showDropdown":[32],"autocompleteLoading":[32],"getValue":[64],"getParamName":[64]}],[772,"jobs-list-reactive",{"apiUrl":[1,"api-url"],"watchParams":[1,"watch-params"],"loadingClass":[1,"loading-class"],"isLoading":[32]}],[512,"jobs-item",{"job":[16],"index":[2],"applyButtonText":[1,"apply-button-text"],"showBrand":[4,"show-brand"],"showReference":[4,"show-reference"],"showEmploymentType":[4,"show-employment-type"],"multiLocationText":[1,"multi-location-text"],"remoteLocationText":[1,"remote-location-text"],"enableKilometers":[4,"enable-kilometers"]}]]]], options);
|
|
21
21
|
});
|
|
@@ -1,22 +1,10 @@
|
|
|
1
1
|
import { EventEmitter } from '../../stencil-public-runtime';
|
|
2
2
|
export type ButtonVariant = 'primary' | 'secondary' | 'text';
|
|
3
3
|
export type ButtonType = 'button' | 'submit';
|
|
4
|
-
export declare class
|
|
5
|
-
/**
|
|
6
|
-
* Visual variant of the button.
|
|
7
|
-
*/
|
|
4
|
+
export declare class FastButton {
|
|
8
5
|
variant: ButtonVariant;
|
|
9
|
-
/**
|
|
10
|
-
* Native button type (button or submit).
|
|
11
|
-
*/
|
|
12
6
|
type: ButtonType;
|
|
13
|
-
/**
|
|
14
|
-
* When true, the button is disabled and does not emit events.
|
|
15
|
-
*/
|
|
16
7
|
disabled: boolean;
|
|
17
|
-
/**
|
|
18
|
-
* Emitted when the button is clicked (not emitted when disabled).
|
|
19
|
-
*/
|
|
20
8
|
buttonClick: EventEmitter<MouseEvent>;
|
|
21
9
|
private handleClick;
|
|
22
10
|
render(): any;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { EventEmitter } from '../../stencil-public-runtime';
|
|
2
|
+
export declare class FastForm {
|
|
3
|
+
el: HTMLElement;
|
|
4
|
+
searchExecuted: EventEmitter<Record<string, string>>;
|
|
5
|
+
handleInputSubmit(): void;
|
|
6
|
+
private submit;
|
|
7
|
+
private updateUrlParams;
|
|
8
|
+
private handleFormSubmit;
|
|
9
|
+
render(): any;
|
|
10
|
+
}
|
|
@@ -8,9 +8,7 @@ export declare class FastInput {
|
|
|
8
8
|
targetPath: string | undefined;
|
|
9
9
|
debounceMs: number;
|
|
10
10
|
minChars: number;
|
|
11
|
-
|
|
12
|
-
keyword: string;
|
|
13
|
-
}>;
|
|
11
|
+
inputSubmit: EventEmitter<void>;
|
|
14
12
|
inputChanged: EventEmitter<{
|
|
15
13
|
value: string;
|
|
16
14
|
}>;
|
|
@@ -22,11 +20,11 @@ export declare class FastInput {
|
|
|
22
20
|
autocompleteLoading: boolean;
|
|
23
21
|
private debounceTimer;
|
|
24
22
|
private popstateHandler;
|
|
23
|
+
getValue(): Promise<string>;
|
|
24
|
+
getParamName(): Promise<string>;
|
|
25
25
|
connectedCallback(): void;
|
|
26
26
|
disconnectedCallback(): void;
|
|
27
27
|
private getUrlParam;
|
|
28
|
-
private updateUrlParam;
|
|
29
|
-
private submit;
|
|
30
28
|
private handleInput;
|
|
31
29
|
private handleKeydown;
|
|
32
30
|
private handleBlur;
|