PageSourceSearch

https://www.greeneking.co.uk/dist/gk-jss-app/js/6860.b9cb72ce.js

js greeneking.co.uk collected 2026-09-24 09:03:14 UTC 9,908 bytes, 2 lines download raw bytes

1"use strict";(globalThis["webpackChunkgk_jss_app"]=globalThis["webpackChunkgk_jss_app"]||[]).push([[6860],{13511:(e,a,t)=>{t.d(a,{A:()=>f});var d=t(20641),l=t(90033),i=t(50953),r=t(50258),s=t(97572);const n=["data-test-id"],o=["id","data-test-id","name","type","placeholder","aria-placeholder","aria-required","aria-disabled","aria-invalid","aria-labelledby","disabled","minLength","maxLength","value","rows"],u={"aria-live":"polite"},c=["data-test-id"],m=(0,d.pM)({__name:"TextareaField",props:{fields:{default:()=>({})},error:{type:Boolean,default:!1},name:{},validation:{},modelValue:{},tracker:{},rendering:{},params:{default:()=>({})},dataTestId:{},isLight:{type:Boolean,default:!1},isRequiredIndicator:{type:Boolean,default:!0}},emits:["update:modelValue","focusout"],setup(e,{emit:a}){const{t}=(0,r.s9)(),m=e,p=a,f=e=>{b(e.target.value),k(e)},h=()=>{m?.validation?.$touch?.(),p("focusout")},b=e=>{p("update:modelValue",e)},v=(0,i.KR)(m.fields.defaultValue),y=(0,i.KR)(v?.value?.length||0),g=(0,d.EW)((()=>`${m.fields.maxLength-y.value} ${t("textarea-characters-remaining")}`)),k=e=>{y.value=e.currentTarget.value.length||0,v.value=e.currentTarget.value};return(a,t)=>((0,d.uX)(),(0,d.CE)(d.FK,null,[(0,d.bF)(s.A,{id:`${e.fields.itemId}-label`,"data-test-id":e.dataTestId+"-label",for:e.fields.itemId,label:e.fields.title,required:e.fields.required,"is-light":e.isLight,"is-required-indicator":e.isRequiredIndicator},null,8,["id","data-test-id","for","label","required","is-light","is-required-indicator"]),(0,d.Lk)("div",{class:"form-field-wrapper","data-test-id":e.dataTestId+"-form-field-wrapper"},[(0,d.Lk)("textarea",{id:e.fields.itemId,"data-test-id":e.dataTestId+"-textarea",name:e.name,type:e.fields.type,placeholder:e.fields.placeholderText,"aria-placeholder":e.fields.placeholderText,"aria-required":e.fields.required,"aria-disabled":e.fields.disabled,"aria-invalid":e.error,"aria-labelledby":`${e.fields.itemId}-label`,disabled:e.fields.disabled,class:(0,l.C4)({error:e.error}),minLength:e.fields.minLength,maxLength:e.fields.maxLength,value:e.modelValue,rows:e.fields.rows,onKeyup:f,onFocusout:h,onChange:f},null,42,o),e.fields.icon?((0,d.uX)(),(0,d.CE)("i",{key:0,class:(0,l.C4)(e.fields.icon),"aria-hidden":"true"},null,2)):(0,d.Q3)("",!0),(0,d.Lk)("div",u,[!g.value||e.fields.disabled||e.error?(0,d.Q3)("",!0):((0,d.uX)(),(0,d.CE)("span",{key:0,"data-test-id":e.dataTestId+"-form-content-length",class:"form-content-length font-s-copy"},(0,l.v_)(g.value),9,c))])],8,n)],64))}}),p=m,f=p},34756:(e,a,t)=>{t.d(a,{A:()=>b});var d=t(20641),l=t(90033),i=t(50953),r=t(97572),s=t(15067),n=t(20002);const o=["data-test-id"],u={key:0,class:"form-select-wrapper"},c=["id","data-test-id","name","disabled","value","aria-required","aria-disabled","aria-invalid","aria-labelledby"],m={selected:"",disabled:"",hidden:"",value:""},p=["id","value","selected"],f=(0,d.pM)({__name:"DropdownField",props:{fields:{default:()=>({})},error:{type:Boolean,default:!1},validation:{},name:{},modelValue:{},tracker:{},rendering:{},params:{},dataTestId:{},hideLabel:{type:Boolean,default:!1},icon:{default:"icon-Down"},isLight:{type:Boolean,default:!1}},emits:["update:modelValue"],setup(e,{emit:a}){const t=e,{isMedia:f}=(0,n.A)("(max-width: 1024px)"),h=a,b=e=>{h("update:modelValue",e),g()},v=e=>{h("update:modelValue",e.target.value),g()},y=()=>{setTimeout((()=>{g()}),100)},g=()=>{t?.validation?.$touch()};return(a,t)=>((0,d.uX)(),(0,d.CE)(d.FK,null,[(0,d.bF)(r.A,{id:`${e.fields.itemId}-label`,for:e.fields.itemId,class:(0,l.C4)(e.hideLabel&&"sr-only"),"data-test-id":e.dataTestId+"-label",label:e.fields.title,required:e.fields.required,"is-light":e.isLight},null,8,["id","for","class","data-test-id","label","required","is-light"]),(0,d.Lk)("div",{class:"form-field-wrapper","data-test-id":e.dataTestId+"-form-field-wrapper"},[e.fields.items&&(0,i.R1)(f)?((0,d.uX)(),(0,d.CE)("div",u,[(0,d.Lk)("select",{id:e.fields.itemId,"data-test-id":e.dataTestId+"-select",name:e.name,disabled:e.fields.disabled,class:(0,l.C4)({error:e.error,"form-select-wrapper__select--empty":!e.modelValue}),value:e.modelValue,"aria-required":e.fields.required,"aria-disabled":e.fields.disabled,"aria-invalid":e.error,"aria-labelledby":`${e.fields.itemId}-label`,onChange:v,onFocusout:g},[(0,d.Lk)("option",m,(0,l.v_)(e.fields.placeholderText),1),((0,d.uX)(!0),(0,d.CE)(d.FK,null,(0,d.pI)(e.fields.items,(e=>((0,d.uX)(),(0,d.CE)("option",{key:e.itemId,id:e.itemId,value:e.value,selected:e.selected},(0,l.v_)(e.text),9,p)))),128))],42,c),(0,d.Lk)("i",{class:(0,l.C4)(["icon",e.icon]),"aria-hidden":"true"},null,2)])):(0,d.Q3)("",!0),(0,i.R1)(f)?(0,d.Q3)("",!0):((0,d.uX)(),(0,d.Wv)(s.A,{key:1,id:e.f
1ields.itemId,options:e.fields.items,"model-value":e.modelValue,disabled:e.fields.disabled,error:e.error,required:e.fields.required,placeholder:e.fields.placeholderText,icon:e.icon,name:e.name,"data-test-id":e.dataTestId+"-custom-select-button","aria-labelledby":`${e.fields.itemId}-label`,"onUpdate:modelValue":b,onClose:y},null,8,["id","options","model-value","disabled","error","required","placeholder","icon","name","data-test-id","aria-labelledby"]))],8,o)],64))}}),h=f,b=h},54559:(e,a,t)=>{t.d(a,{x:()=>r});var d=t(10810),l=t(50953),i=t(30843);const r=(0,d.nY)("form",(()=>{const e=(0,i.B)(),a=(0,l.KR)({}),t=(0,l.KR)({}),d="true"===e.$state["Foundation.Consents.Epic3.Enabled"],r=(0,l.Kh)({apiURL:d?e.consentApiUrl:null,apiKey:d?e.consentApiKey:null,marketingBrandName:e.marketingBrandName,currentEmail:null,data:null,error:!e.marketingBrandName,alreadySubscribed:!1}),s={setApiUrl(e){r.apiURL=e},setCurrentEmail(e){r.currentEmail=e},setConsentsData(e){r.data=e},setError(e){r.error=e},setAlreadySubscribed(e){r.alreadySubscribed=e},clearStore(){r.currentEmail=null,r.data=null,r.error=!1,r.alreadySubscribed=!1}},n=(e,t)=>{a.value[e]=t},o=(e,a)=>{t.value[e]=a};return{consentsData:r,consentsMethods:s,formSuccessState:a,formSubmittedData:t,updateFormSuccessState:n,updateFormSubmittedData:o}}))},69747:(e,a,t)=>{t.d(a,{H:()=>f,g:()=>h});var d=t(20641),l=t(50953),i=t(54559),r=t(10141),s=t(23041);const n=(e,a,t,d)=>(0,s.A)({method:"post",url:`${e}/${t}`,data:a,...d&&{headers:{"ocp-apim-subscription-key":d}}}).then((e=>({status:e.status,data:e.data}))),o=(e,a,t,d)=>(0,r.I)({queryKey:["consents-check",a],queryFn:()=>n((0,l.R1)(e)??"",(0,l.R1)(a),t,(0,l.R1)(d)??void 0),retry:1,refetchOnWindowFocus:!1,refetchOnReconnect:!1,refetchOnMount:!1,staleTime:0,enabled:!1}),u=(e,a,t)=>o(e,a,"prompt",t),c=(e,a,t)=>n(e,a,"update",t);var m=t(20188),p=t(30843);const f={NEWSLETTER:"Newsletter",WEB_TABLE_BOOKING:"WebTableBooking"},h=e=>{const a=(0,i.x)(),t=(0,p.B)(),r="true"===t.$state["Foundation.Consents.Epic3.Enabled"],s=(0,d.EW)((()=>a.consentsData.error)),n=(0,d.EW)((()=>a.consentsData.apiURL)),o=(0,d.EW)((()=>a.consentsData.apiKey)),h=(0,d.EW)((()=>a.consentsData.currentEmail)),b=(0,l.KR)({emailAddress:h,brandName:a.consentsData.marketingBrandName,source:e}),{data:v,error:y,isFetching:g,refetch:k}=u(n,b,o),{setupUser:E}=(0,m.b)(),I=e=>{a.consentsMethods.setCurrentEmail(e)},C=async()=>{await k();const e=v.value?.status,t=v.value?.data;if(a.consentsData.error&&!y.value&&a.consentsMethods.setError(!1),204===e)return a.consentsMethods.setConsentsData(null),a.consentsMethods.setAlreadySubscribed(!0),void E(h.value??"");const d=r?t:t?.value;y.value||!d?.key?a.consentsMethods.setError(!0):d.hideCheckbox&&(a.consentsMethods.setAlreadySubscribed(!0),E(h.value??"")),a.consentsMethods.setConsentsData(d??null)},L=async(t=!0,d=null)=>{const l=a.consentsData.data?.key,i=h.value;if(!i||!l)return;E(i);const r=e===f.NEWSLETTER||t!==a.consentsData.data?.checkedByDefault,s=c(n.value??"",{emailAddress:i,key:l,value:t,hasChanged:r,source:e,...d&&{meta:d}},o.value??void 0);return s};return{emailAddress:h,error:s,isFetching:g,checkConsent:C,setEmailAddress:I,updateConsent:L}}},95149:(e,a,t)=>{t.d(a,{A:()=>f});t(22489),t(13579);var d=t(20641),l=t(90033),i=t(80130);const r=["data-test-id"],s=["id","data-test-id"],n={key:0,"aria-hidden":"true"},o={key:1,"aria-hidden":"true"},u="checkbox",c="radio",m=(0,d.pM)({__name:"OptionListField",props:{fields:{default:()=>({})},fieldId:{},name:{},error:{type:Boolean,default:!1},type:{},title:{},validation:{},modelValue:{},tracker:{},rendering:{},params:{default:()=>({})},dataTestId:{},isLight:{type:Boolean,default:!1},isRequiredIndicator:{type:Boolean,default:!0}},emits:["update:modelValue"],setup(e,{emit:a}){const t=a,m=e,p=(0,d.EW)((()=>m.fields.required&&!m.modelValue?.length||null)),f=()=>{m.validation?.$touch()},h=(e,a)=>{if(m.type===u){let d=Array.isArray(m.modelValue)?m.modelValue:[];a&&!d.includes(e)?d=[...d,e]:a||(d=d.filter((a=>a!==e))),t("update:modelValue",d)}else t("update:modelValue",e);m.validation?.$touch()};return(a,t)=>((0,d.uX)(),(0,d.CE)("fieldset",{class:"option-list-field","data-test-id":e.dataTestId,onFocusout:f},[(0,d.Lk)("legend",{id:`${e.name}-label`,class:(0,l.C4)(["form-label",e.isLight&&"form-label--light"]),"data-test-id":e.dataTestId+"-legend"},[(0,d.eW)((0,l.v_)(e.title??e.fields.title)+" ",1),e.fields.required&&e.isRequiredIndicator?((0,d.uX)(),(0,d.CE)("span",n,(0,l.v_)("*"))):(0,d.Q3)("",!0),!e.fields.required&&e.isLight&&e.isRequiredIndicator?((0,d.uX)(),(0,d.CE)("span",o,(0,l.v_)("(optional)"))):(0,d.Q3)("",!0)],10,s),((0,d.uX)(!0),(0,d.CE)(d.FK,null,(0,d.pI)(e.fields.items,((a,t)=>((0,d.uX)(),(0,d.Wv)(i.A,{key:a.itemId,"field-id":a.itemId,name:e.type===c?e.name:a.itemId,"model-value":Array.isArray(e.modelValue)?e.modelValue.some((e=>e===a.value)):e.modelValue===a.value,title:a.text,type:e.type,required:p.value,error:e.error,"data-test-id":e.dataTestId+`-${e.type}-${t}`,"is-required-indicator":!1,"onUpdate:modelValue":e=>h(a.value,e)},null,8,["field-id","name","model-value","title","type","required","error","data-test-id","onUpdate:modelValue"])))),128))],40,r))}}),p=m,f=p}}]);
2//# sourceMappingURL=6860.b9cb72ce.js.map

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.