fungiorganic commited on
Commit
e941df1
·
verified ·
1 Parent(s): e8ba3fd

venue refresh: upload 202 files (abbotsford only; no Anchorage)

Browse files
This view is limited to 50 files because it contains too many changes.   See raw diff
Files changed (50) hide show
  1. .gitattributes +20 -0
  2. abbotsford/chef-app/_expo/static/js/web/+not-found-a85f4163079f520711a9e40e645ca875.js +1 -0
  3. abbotsford/chef-app/_expo/static/js/web/[did]-d0ec4f21f40eb7b8eb13e49d83178ff4.js +1 -0
  4. abbotsford/chef-app/_expo/static/js/web/[n]-21ee7870b018e4360f6e825c15dd672b.js +1 -0
  5. abbotsford/chef-app/_expo/static/js/web/[oid]-0ef90855abb82d22ac5def655ebb19b6.js +3 -0
  6. abbotsford/chef-app/_expo/static/js/web/[section]-2201675add2ff7b9966ea9d886c9adf3.js +1 -0
  7. abbotsford/chef-app/_expo/static/js/web/[token]-060d0a0e0a07c4da23ca6d5b04c35e87.js +3 -0
  8. abbotsford/chef-app/_expo/static/js/web/__common-d92ed2b513b48a7e75fdf07ee4f937c8.js +0 -0
  9. abbotsford/chef-app/_expo/static/js/web/_layout-28f52c5d547984f57d779d2d1595deac.js +0 -0
  10. abbotsford/chef-app/_expo/static/js/web/basket-c05ffa92d4d6d13484ce78275193c02c.js +1 -0
  11. abbotsford/chef-app/_expo/static/js/web/book-34e99aaf0197899dc09c20d6bb54139f.js +4 -0
  12. abbotsford/chef-app/_expo/static/js/web/demo-bb0072f641fdd92aa99cba5bc91fc36d.js +1 -0
  13. abbotsford/chef-app/_expo/static/js/web/feedback-e234bfa389c6fd89a2e9f35bd3515c4d.js +1 -0
  14. abbotsford/chef-app/_expo/static/js/web/gift-791c64f5dbcb5e9b9629af9241dde456.js +1 -0
  15. abbotsford/chef-app/_expo/static/js/web/index-0a34312c3724df867c229ae4363d5bf9.js +15 -0
  16. abbotsford/chef-app/_expo/static/js/web/index-0d5420913a09234192e03fb64f496fd4.js +1 -0
  17. abbotsford/chef-app/_expo/static/js/web/index-18a42003614e46ed29f029ff3e81efd8.js +1 -0
  18. abbotsford/chef-app/_expo/static/js/web/index-4caab44ee144794fe5f1c5f3fbaed93d.js +0 -0
  19. abbotsford/chef-app/_expo/static/js/web/index-708cc108b14a03d1e55d135c08408edf.js +1 -0
  20. abbotsford/chef-app/_expo/static/js/web/index-a7e511353fde4e4907f278d874667ffb.js +0 -0
  21. abbotsford/chef-app/_expo/static/js/web/index-b2fb0e8ee9c9e5267d8b0725148d8bf3.js +0 -0
  22. abbotsford/chef-app/_expo/static/js/web/index-ba5aea4e23e402619315d92ef1e4fc6c.js +1 -0
  23. abbotsford/chef-app/_expo/static/js/web/index-d72f0e09722c49318a402489e965ec4a.js +1 -0
  24. abbotsford/chef-app/_expo/static/js/web/index-e9112f8ce9e859f928720bf6bff6ea9e.js +2 -0
  25. abbotsford/chef-app/_expo/static/js/web/lost-cceda4c454fce783fcc4c1cdf454f0cd.js +1 -0
  26. abbotsford/chef-app/_expo/static/js/web/loyalty-bb43e2009908082ac56ab35a52b228ca.js +1 -0
  27. abbotsford/chef-app/_expo/static/js/web/merch-77ea1815cef4942701820887c797ac92.js +1 -0
  28. abbotsford/chef-app/_expo/static/js/web/offers-31ec634ef9aa42a8856b1215ab24e6f3.js +1 -0
  29. abbotsford/chef-app/_expo/static/js/web/profile-94f3e7175fc7efdfa4351ecc255fb11b.js +1 -0
  30. abbotsford/chef-app/_expo/static/js/web/refer-281b0170b80b5db0e1402a8c4d823a68.js +1 -0
  31. abbotsford/chef-app/_expo/static/js/web/waitlist-0820a9a3f8a549bf0d6f432f6a7ad617.js +1 -0
  32. abbotsford/chef-app/_expo/static/js/web/whatson-6498b8821e66bd4aa1639b57afb933a3.js +1 -0
  33. abbotsford/chef-app/assets/assets/brand/3idiots-hero.77d66ccb53ec1835c3b8a838e9bcfb5a.png +0 -0
  34. abbotsford/chef-app/assets/assets/brand/drunkencoo-hero.7c01fed6cb075a3a8e4f969bff1cf103.png +3 -0
  35. abbotsford/chef-app/assets/assets/brand/drunkencoo.272f746bf13376f503acd81a524a7998.png +3 -0
  36. abbotsford/chef-app/assets/assets/brand/smokinggoat-hero.b2ae48c4a1fcf2521ae9ff58435a6649.png +3 -0
  37. abbotsford/chef-app/assets/assets/brand/smokinggoat.fff2a9a694b41fed68c80a2c9bfe65da.png +3 -0
  38. abbotsford/chef-app/index.html +1 -1
  39. abbotsford/chef-app/kitchen.html +1 -1
  40. abbotsford/chef-app/sw.js +1 -1
  41. abbotsford/customer-app/_expo/static/js/web/+not-found-a85f4163079f520711a9e40e645ca875.js +1 -0
  42. abbotsford/customer-app/_expo/static/js/web/[did]-d0ec4f21f40eb7b8eb13e49d83178ff4.js +1 -0
  43. abbotsford/customer-app/_expo/static/js/web/[n]-21ee7870b018e4360f6e825c15dd672b.js +1 -0
  44. abbotsford/customer-app/_expo/static/js/web/[oid]-34de93199ed1b45f11064148f5365bb9.js +3 -0
  45. abbotsford/customer-app/_expo/static/js/web/[section]-2201675add2ff7b9966ea9d886c9adf3.js +1 -0
  46. abbotsford/customer-app/_expo/static/js/web/[token]-27d64602702848e6f817cb3e11170985.js +3 -0
  47. abbotsford/customer-app/_expo/static/js/web/__common-62dc618bc7e7f7ce3382df95eac3e0c0.js +0 -0
  48. abbotsford/customer-app/_expo/static/js/web/_layout-dca323c29b087b4dc8695422b2ba2b49.js +44 -0
  49. abbotsford/customer-app/_expo/static/js/web/basket-b6d5d5daeda35a03cd8137d4a926f820.js +1 -0
  50. abbotsford/customer-app/_expo/static/js/web/book-34e99aaf0197899dc09c20d6bb54139f.js +4 -0
.gitattributes CHANGED
@@ -2888,3 +2888,23 @@ kirkton/staff-app/assets/assets/brand/drunkencoo-hero.7c01fed6cb075a3a8e4f969bff
2888
  kirkton/staff-app/assets/assets/brand/drunkencoo.272f746bf13376f503acd81a524a7998.png filter=lfs diff=lfs merge=lfs -text
2889
  kirkton/staff-app/assets/assets/brand/smokinggoat-hero.b2ae48c4a1fcf2521ae9ff58435a6649.png filter=lfs diff=lfs merge=lfs -text
2890
  kirkton/staff-app/assets/assets/brand/smokinggoat.fff2a9a694b41fed68c80a2c9bfe65da.png filter=lfs diff=lfs merge=lfs -text
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2888
  kirkton/staff-app/assets/assets/brand/drunkencoo.272f746bf13376f503acd81a524a7998.png filter=lfs diff=lfs merge=lfs -text
2889
  kirkton/staff-app/assets/assets/brand/smokinggoat-hero.b2ae48c4a1fcf2521ae9ff58435a6649.png filter=lfs diff=lfs merge=lfs -text
2890
  kirkton/staff-app/assets/assets/brand/smokinggoat.fff2a9a694b41fed68c80a2c9bfe65da.png filter=lfs diff=lfs merge=lfs -text
2891
+ abbotsford/chef-app/assets/assets/brand/drunkencoo-hero.7c01fed6cb075a3a8e4f969bff1cf103.png filter=lfs diff=lfs merge=lfs -text
2892
+ abbotsford/chef-app/assets/assets/brand/drunkencoo.272f746bf13376f503acd81a524a7998.png filter=lfs diff=lfs merge=lfs -text
2893
+ abbotsford/chef-app/assets/assets/brand/smokinggoat-hero.b2ae48c4a1fcf2521ae9ff58435a6649.png filter=lfs diff=lfs merge=lfs -text
2894
+ abbotsford/chef-app/assets/assets/brand/smokinggoat.fff2a9a694b41fed68c80a2c9bfe65da.png filter=lfs diff=lfs merge=lfs -text
2895
+ abbotsford/customer-app/assets/assets/brand/drunkencoo-hero.7c01fed6cb075a3a8e4f969bff1cf103.png filter=lfs diff=lfs merge=lfs -text
2896
+ abbotsford/customer-app/assets/assets/brand/drunkencoo.272f746bf13376f503acd81a524a7998.png filter=lfs diff=lfs merge=lfs -text
2897
+ abbotsford/customer-app/assets/assets/brand/smokinggoat-hero.b2ae48c4a1fcf2521ae9ff58435a6649.png filter=lfs diff=lfs merge=lfs -text
2898
+ abbotsford/customer-app/assets/assets/brand/smokinggoat.fff2a9a694b41fed68c80a2c9bfe65da.png filter=lfs diff=lfs merge=lfs -text
2899
+ abbotsford/display-app/assets/assets/brand/drunkencoo-hero.7c01fed6cb075a3a8e4f969bff1cf103.png filter=lfs diff=lfs merge=lfs -text
2900
+ abbotsford/display-app/assets/assets/brand/drunkencoo.272f746bf13376f503acd81a524a7998.png filter=lfs diff=lfs merge=lfs -text
2901
+ abbotsford/display-app/assets/assets/brand/smokinggoat-hero.b2ae48c4a1fcf2521ae9ff58435a6649.png filter=lfs diff=lfs merge=lfs -text
2902
+ abbotsford/display-app/assets/assets/brand/smokinggoat.fff2a9a694b41fed68c80a2c9bfe65da.png filter=lfs diff=lfs merge=lfs -text
2903
+ abbotsford/owner-app/assets/assets/brand/drunkencoo-hero.7c01fed6cb075a3a8e4f969bff1cf103.png filter=lfs diff=lfs merge=lfs -text
2904
+ abbotsford/owner-app/assets/assets/brand/drunkencoo.272f746bf13376f503acd81a524a7998.png filter=lfs diff=lfs merge=lfs -text
2905
+ abbotsford/owner-app/assets/assets/brand/smokinggoat-hero.b2ae48c4a1fcf2521ae9ff58435a6649.png filter=lfs diff=lfs merge=lfs -text
2906
+ abbotsford/owner-app/assets/assets/brand/smokinggoat.fff2a9a694b41fed68c80a2c9bfe65da.png filter=lfs diff=lfs merge=lfs -text
2907
+ abbotsford/staff-app/assets/assets/brand/drunkencoo-hero.7c01fed6cb075a3a8e4f969bff1cf103.png filter=lfs diff=lfs merge=lfs -text
2908
+ abbotsford/staff-app/assets/assets/brand/drunkencoo.272f746bf13376f503acd81a524a7998.png filter=lfs diff=lfs merge=lfs -text
2909
+ abbotsford/staff-app/assets/assets/brand/smokinggoat-hero.b2ae48c4a1fcf2521ae9ff58435a6649.png filter=lfs diff=lfs merge=lfs -text
2910
+ abbotsford/staff-app/assets/assets/brand/smokinggoat.fff2a9a694b41fed68c80a2c9bfe65da.png filter=lfs diff=lfs merge=lfs -text
abbotsford/chef-app/_expo/static/js/web/+not-found-a85f4163079f520711a9e40e645ca875.js ADDED
@@ -0,0 +1 @@
 
 
1
+ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return c}});var t=r(d[0]);r(d[1]);var n=r(d[2]),u=r(d[3]);function c(){return(0,u.jsx)(t.Redirect,{href:n.ENTRY[n.APP_VARIANT]})}},802,[805,31,807,25]);
abbotsford/chef-app/_expo/static/js/web/[did]-d0ec4f21f40eb7b8eb13e49d83178ff4.js ADDED
@@ -0,0 +1 @@
 
 
1
+ __d(function(_g,_r,i,_a,_m,_e,_d){"use strict";function e(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(_e,'__esModule',{value:!0}),Object.defineProperty(_e,"default",{enumerable:!0,get:function(){return b}});var n=_r(_d[0]),t=_r(_d[1]),s=_r(_d[2]),a=e(_r(_d[3])),l=e(_r(_d[4])),r=_r(_d[5]),o=_r(_d[6]),d=_r(_d[7]),c=_r(_d[8]),u=_r(_d[9]),h=_r(_d[10]),g=_r(_d[11]),p=_r(_d[12]),f=_r(_d[13]);function b(){const{rid:e,did:b}=(0,t.useLocalSearchParams)(),j=(0,h.useRestaurant)(e),x=(0,h.useMenu)(e).find(e=>e.id===b),y=(0,h.useCustomer)(),m=(0,h.useRecipeCards)(e).find(e=>e.id===x?.recipeCardId),k=m?.signOff&&m.photo?(0,g.recipeCards)().photoSource(m.photo):null,v=(0,h.useStore)(e=>e.addLine),w=(0,n.useTakeawayMenu)(n=>n.byVenue[e]),S=(0,h.useStore)(n=>n.basket.restaurantId===e&&'table'===n.basket.mode),[C,B]=(0,s.useState)(()=>(x?.optionGroups??[]).filter(e=>e.required).map(e=>e.choices[0].id)),[$,I]=(0,s.useState)(1),[P,T]=(0,s.useState)(''),[L,O]=(0,s.useState)(!1),[D,A]=(0,s.useState)(!1),[M,R]=(0,s.useState)(!1),[q,_]=(0,s.useState)(!1),N=(0,s.useMemo)(()=>x?(0,c.effectiveAllergens)(x,C):{},[x,C]);if(!j||!x)return(0,f.jsx)(d.Screen,{title:"Not found",children:(0,f.jsx)(d.T,{children:"Dish not found."})});const G=(0,c.conflictsFor)(N,y.allergies),Y=(x.price??0)+(x.optionGroups??[]).flatMap(e=>e.choices).filter(e=>C.includes(e.id)).reduce((e,n)=>e+n.priceDelta,0),z=S||j.fictional?'on':(0,n.takeawayAvail)(x,w),F=x.soldOut||!x.signOff||null===x.price||'on'!==z,Q=(e,n)=>{const t=x.optionGroups.find(n=>n.id===e);B(e=>{const s=t.choices.map(e=>e.id);return t.multi?e.includes(n)?e.filter(e=>e!==n):[...e,n]:e.includes(n)&&!t.required?e.filter(e=>e!==n):[...e.filter(e=>!s.includes(e)),n]})},V=e=>{h.useStore.getState().basket.restaurantId!==j.id&&h.useStore.getState().startBasket(j.id,'takeaway'),v({itemId:x.id,qty:$,choiceIds:C,notes:P,override:e?{allergens:G.contains,at:(new Date).toISOString()}:void 0}),O(!1),_(!0)};return(0,f.jsxs)(d.Screen,{title:x.name,subtitle:j.name,right:(0,f.jsx)(o.BasketButton,{}),children:[k?(0,f.jsx)(a.default,{testID:"dish-photo",source:k,accessibilityLabel:`${x.name}${'example'===m?.origin?' (example photo)':''}`,style:{width:'100%',height:200,borderRadius:12},resizeMode:"cover"}):null,(0,f.jsxs)(d.Row,{wrap:!0,gap:6,children:[(0,f.jsx)(d.T,{weight:"bold",size:20,colour:p.colours.gold,children:null===x.price?x.priceNote:(0,u.gbp)(Y)}),x.dietary.map(e=>(0,f.jsx)(d.Badge,{kind:"ok",label:e},e))]}),(0,f.jsx)(d.T,{children:x.description}),G.contains.length?(0,f.jsx)(d.Banner,{kind:"danger",title:`Blocked: contains ${G.contains.map(c.allergenLabel).join(', ')}`,children:`You\u2019ve told us: ${y.allergies.filter(e=>G.contains.includes(e.allergen)).map(e=>`${(0,c.allergenLabel)(e.allergen)} \u2014 ${(0,c.severityLabel)(e.severity)}`).join('; ')}. This dish can\u2019t be added unless you deliberately override (for example, ordering for someone else).`}):null,G.may.length?(0,f.jsx)(d.Banner,{kind:"warn",title:`Warning: may contain ${G.may.map(c.allergenLabel).join(', ')}`,children:"Cross-contact is possible (e.g. shared fryer). Please speak to staff before ordering."}):null,(x.optionGroups??[]).map(e=>(0,f.jsxs)(d.Card,{children:[(0,f.jsxs)(d.T,{weight:"semibold",children:[e.name,e.required?' (required)':' (optional)']}),(0,f.jsx)(d.Row,{wrap:!0,gap:6,children:e.choices.map(n=>(0,f.jsx)(d.Chip,{label:n.label,sub:n.priceDelta?`+${(0,u.gbp)(n.priceDelta)}`:void 0,selected:C.includes(n.id),onPress:()=>Q(e.id,n.id)},n.id))})]},e.id)),(0,f.jsx)(d.Card,{children:(0,f.jsx)(r.AllergenPanel,{item:x,map:N,declared:y.allergies})}),j.fictional?null:(0,f.jsx)(d.AllergenNotice,{phone:j.phone}),(0,f.jsx)(d.Field,{label:"Notes for the kitchen (optional)",placeholder:"e.g. no gherkins",value:P,onChangeText:T}),(0,f.jsxs)(d.Row,{style:{justifyContent:'space-between'},children:[(0,f.jsx)(d.T,{weight:"semibold",children:"Quantity"}),(0,f.jsx)(d.Stepper,{value:$,onChange:I,label:"quantity"})]}),q?(0,f.jsx)(d.Banner,{kind:"success",title:"Added to basket",children:G.contains.length?'Allergy override recorded \u2014 the kitchen will see a large allergy alert.':'Carry on browsing or go to your basket.'}):null,F?(0,f.jsx)(d.Banner,{kind:"warn",children:x.soldOut||'sold-out'===z?'Sold out today.':'off'===z&&x.signOff&&null!==x.price?'This dish isn\u2019t on the takeaway menu. You can have it when you eat in.':x.signOff?'Price on the specials board \u2014 ask staff.':'Not available to order online until the head chef signs off its allergens.'}):G.contains.length?(0,f.jsxs)(l.default,{style:{gap:8},children:[(0,f.jsx)(d.Button,{kind:"secondary",label:"Choose something else",onPress:()=>t.router.back()}),(0,f.jsx)(d.Button,{kind:"danger",label:"Override and add anyway\u2026",onPress:()=>{A(!1),R(!1),O(!0)},testID:"override-open"})]}):(0,f.jsxs)(d.Row,{gap:8,children:[(0,f.jsx)(d.Button,{style:{flex:1},label:`Add ${$} to basket \xb7 ${(0,u.gbp)(Y*$)}`,onPress:()=>V(!1),testID:"add-to-basket"}),q?(0,f.jsx)(d.Button,{kind:"secondary",label:"Basket",onPress:()=>t.router.push('/customer/basket')}):null]}),(0,f.jsxs)(d.Sheet,{visible:L,onClose:()=>O(!1),title:"Allergy override",children:[(0,f.jsx)(d.Banner,{kind:"danger",title:`${x.name} contains ${G.contains.map(c.allergenLabel).join(', ')}`,children:`Your profile says: ${y.allergies.filter(e=>G.contains.includes(e.allergen)).map(e=>`${(0,c.allergenLabel)(e.allergen)} \u2014 ${(0,c.severityLabel)(e.severity)}`).join('; ')}.`}),(0,f.jsx)(d.Toggle,{label:"I understand this dish contains an allergen I have declared",value:D,onChange:A}),(0,f.jsx)(d.Toggle,{label:"It is for someone without this allergy, or I have spoken to staff",value:M,onChange:R}),(0,f.jsx)(d.Muted,{children:"The override is logged and shown to the kitchen as an allergy alert that must be acknowledged."}),(0,f.jsx)(d.Button,{kind:"danger",disabled:!D||!M,label:"Confirm override and add",onPress:()=>V(!0),testID:"override-confirm"})]})]})}},779,[836,805,31,197,128,837,838,818,819,820,823,839,825,25]);
abbotsford/chef-app/_expo/static/js/web/[n]-21ee7870b018e4360f6e825c15dd672b.js ADDED
@@ -0,0 +1 @@
 
 
1
+ __d(function(g,_r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return f}});var t=_r(d[0]),r=_r(d[1]),n=_r(d[2]),o=_r(d[3]),u=_r(d[4]),c=_r(d[5]),s=_r(d[6]),l=_r(d[7]);function f(){const{n:f,r:b}=(0,r.useLocalSearchParams)(),E=(0,u.useStore)(t=>t.startBasket),[_,h]=(0,n.useState)(!1),S=b??c.VENUE_RID,j=(0,u.useOrderAtTable)(S),I=(0,s.guestServer)();return(0,n.useEffect)(()=>{t.LIVE_VENUE_BUILD||I||(j&&E(S,'table',String(f)),h(!0))},[S,f,j,I]),t.LIVE_VENUE_BUILD||I?(0,l.jsx)(o.Screen,{title:"Order at the table",children:(0,l.jsx)(o.Banner,{kind:"demo",title:"Scan the code on your table",children:"To order from your table, scan the QR code printed on it. Or order at the bar."})}):_?(0,l.jsx)(r.Redirect,{href:`/customer/${S}`}):null}},795,[842,805,31,818,823,5,845,25]);
abbotsford/chef-app/_expo/static/js/web/[oid]-0ef90855abb82d22ac5def655ebb19b6.js ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ __d(function(g,_r,_i,a,m,_e,d){"use strict";Object.defineProperty(_e,'__esModule',{value:!0}),Object.defineProperty(_e,"default",{enumerable:!0,get:function(){return f}});var e,t=_r(d[0]),l=_r(d[1]),s=_r(d[2]),r=_r(d[3]),n=(e=r)&&e.__esModule?e:{default:e},o=_r(d[4]),i=_r(d[5]),c=_r(d[6]),u=_r(d[7]),h=_r(d[8]),p=_r(d[9]),y=_r(d[10]),b=_r(d[11]),j=_r(d[12]);const x=[['new','Placed'],['acknowledged','Accepted'],['preparing','Cooking'],['ready','Ready to collect'],['collected','Collected']],w=[['new','Sent'],['acknowledged','Accepted'],['preparing','Cooking'],['served','Food out'],['closed','Paid']];function f(){const{oid:e}=(0,l.useLocalSearchParams)(),r=(0,p.useOrder)(e),f=(0,p.useRestaurant)(r?.restaurantId),[k,T]=(0,s.useState)(0),[S,C]=(0,s.useState)(''),[v,M]=(0,s.useState)(!1),[P,A]=(0,s.useState)(0),[R,$]=(0,s.useState)(r?.split?.ways??1);if(!r||!f)return(0,j.jsx)(i.Screen,{title:"Order",children:(0,j.jsx)(i.T,{children:"Order not found."})});const O='takeaway'===r.type?x:w,I=Math.max(0,O.findIndex(([e])=>e===r.status)),N=Math.round(r.subtotal*P/100),B='table'===r.type?r.subtotal+(r.split?r.tip:N):r.total,_=B-r.paid,H=r.split?.ways??R,D=r.split?.paidShares??0,F=Math.ceil(B/H),q='collected'===r.status||'closed'===r.status;return(0,j.jsxs)(i.Screen,{title:`Order ${r.ref}`,subtitle:`${f.name} \xb7 ${'table'===r.type?`${(0,t.tableNumbers)(r.tableNo)}`:`Collection at ${r.slotTime?(0,h.hm)(new Date(r.slotTime)):'\u2014'}`}`,children:['takeaway'===r.type?(0,j.jsx)(b.TakeawayPayCard,{o:r,phone:f.phone}):null,'takeaway'===r.type&&'awaiting_payment'!==r.status&&'cancelled'!==r.status?(0,j.jsx)(i.Banner,{kind:"success",title:'ready'===r.status?'Your order is ready!':'Order placed',children:'ready'===r.status?'Head to the bar and give your order number. Staff will check allergies with you at handover.':`Show order number ${r.ref} at the bar when you arrive.`}):null,'awaiting_payment'===r.status||'cancelled'===r.status?null:(0,j.jsxs)(i.Card,{children:[(0,j.jsx)(i.H2,{children:"Status"}),O.map(([e,t],l)=>(0,j.jsxs)(i.Row,{gap:10,children:[(0,j.jsx)(n.default,{style:{width:22,height:22,borderRadius:11,backgroundColor:l<=I?y.colours.gold:y.colours.surface2,borderWidth:1,borderColor:y.colours.gold}}),(0,j.jsx)(i.T,{weight:l===I?'semibold':'regular',colour:l<=I?y.colours.text:y.colours.muted,children:t})]},e)),r.allergyAck?(0,j.jsxs)(i.Muted,{children:["Kitchen signed off your allergies (",r.allergyAck.by,", ",(0,h.hm)(new Date(r.allergyAck.at)),")"]}):r.allergies.length?(0,j.jsx)(i.Muted,{children:"Waiting for the kitchen to sign off your allergies\u2026"}):null,'takeaway'!==r.type||q?null:(0,j.jsxs)(i.Row,{gap:8,children:[(0,j.jsx)(i.Button,{small:!0,kind:'on-my-way'===r.customerSignal?'primary':'secondary',label:"On my way",onPress:()=>p.repo.orders.customerSignal(r.id,'on-my-way')}),(0,j.jsx)(i.Button,{small:!0,kind:'here'===r.customerSignal?'primary':'secondary',label:"I\u2019m here",onPress:()=>p.repo.orders.customerSignal(r.id,'here')})]})]}),(0,j.jsxs)(i.Card,{children:[(0,j.jsx)(i.H2,{children:"Items"}),r.lines.map((e,t)=>(0,j.jsxs)(n.default,{children:[(0,j.jsxs)(i.Row,{style:{justifyContent:'space-between'},children:[(0,j.jsxs)(i.T,{style:{flex:1},children:[e.qty,"\xd7 ",e.name]}),(0,j.jsx)(i.T,{children:(0,u.gbp)(e.unitPrice*e.qty)})]}),e.choices.length?(0,j.jsx)(i.Muted,{children:e.choices.join(' \xb7 ')}):null,e.overridden?(0,j.jsx)(i.Badge,{kind:"red",label:`Allergy override: ${e.contains.map(c.allergenLabel).join(', ')}`}):null]},t)),(0,j.jsxs)(i.Row,{style:{justifyContent:'space-between'},children:[(0,j.jsx)(i.Muted,{children:"Subtotal"}),(0,j.jsx)(i.T,{children:(0,u.gbp)(r.subtotal)})]}),r.giftCardApplied?(0,j.jsxs)(i.Row,{style:{justifyContent:'space-between'},children:[(0,j.jsx)(i.Muted,{children:"Of which gift card"}),(0,j.jsxs)(i.T,{colour:y.colours.ok,children:["\u2212",(0,u.gbp)(r.giftCardApplied)]})]}):null,r.tip?(0,j.jsxs)(i.Row,{style:{justifyContent:'space-between'},children:[(0,j.jsx)(i.Muted,{children:"Tip"}),(0,j.jsx)(i.T,{children:(0,u.gbp)(r.tip)})]}):null,(0,j.jsxs)(i.Row,{style:{justifyContent:'space-between'},children:[(0,j.jsx)(i.T,{weight:"semibold",children:"Paid (test, no real money)"}),(0,j.jsx)(i.T,{weight:"semibold",colour:y.colours.gold,children:(0,u.gbp)(r.paid)})]})]}),'table'===r.type&&'closed'!==r.status&&'cancelled'!==r.status?(0,j.jsxs)(i.Card,{highlight:y.colours.gold,children:[(0,j.jsxs)(i.H2,{children:["Your bill \u2014 ",(0,t.tableNumbers)(r.tableNo)]}),r.split?(0,j.jsxs)(j.Fragment,{children:[(0,j.jsxs)(i.T,{children:["Total ",(0,u.gbp)(B)," \xb7 split ",H," way",H>1?'s':''," \xb7 ",(0,u.gbp)(F)," each"]}),(0,j.jsxs)(i.T,{children:["Shares paid: ",D," of ",H," \xb7 remaining ",(0,u.gbp)(_)]}),(0,j.jsx)(i.Muted,{children:"Pay with a member of staff at your table. Online card payment for the table bill isn\u2019t set up."})]}):(0,j.jsxs)(j.Fragment,{children:[(0,j.jsx)(i.T,{weight:"semibold",children:"Add a tip?"}),(0,j.jsx)(i.Row,{wrap:!0,children:[0,10,12.5,15].map(e=>(0,j.jsx)(i.Chip,{label:e?`${e}%`:'No tip',selected:P===e,onPress:()=>A(e)},e))}),(0,j.jsx)(i.Muted,{children:"Tips go to staff under the restaurant\u2019s tipping policy (Employment (Allocation of Tips) Act 2023)."}),(0,j.jsxs)(i.Row,{style:{justifyContent:'space-between'},children:[(0,j.jsx)(i.T,{weight:"semibold",children:"Split evenly between"}),(0,j.jsx)(i.Stepper,{value:R,onChange:$,min:1,max:8,label:"people"})]}),(0,j.jsxs)(i.T,{children:["Total ",(0,u.gbp)(r.subtotal+N),R>1?` \xb7 ${(0,u.gbp)(Math.ceil((r.subtotal+N)/R))} each`:'']}),(0,j.jsx)(i.Button,{label:"Get the bill",onPress:()=>p.repo.orders.setSplit(r.id,R,N),testID:"get-bill"})]})]}):null,!q||r.rated||v?null:(0,j.jsxs)(i.Card,{highlight:y.colours.gold,children:[(0,j.jsx)(i.H2,{children:"How was everything?"}),(0,j.jsxs)(i.Muted,{children:["One tap \u2014 this goes privately to ",f.name," only, never published."]}),(0,j.jsx)(o.Stars,{value:k,onChange:T}),k?(0,j.jsx)(i.Field,{label:"Anything to add? (optional)",value:S,onChangeText:C}):null,(0,j.jsx)(i.Button,{label:"Send feedback",disabled:!k,onPress:()=>{p.repo.feedback.add({restaurantId:f.id,orderId:r.id,customerId:r.customerId,customerName:r.customerName,stars:k,comment:S,context:'table'===r.type?`${(0,t.tableNumbers)(r.tableNo)}`:`Takeaway ${r.ref}`}),M(!0)},testID:"send-rating"})]}),v||r.rated?(0,j.jsx)(i.Banner,{kind:"success",children:"Thanks \u2014 your feedback went privately to the restaurant."}):null,q?(0,j.jsx)(i.Button,{kind:"secondary",label:"View stamp card",onPress:()=>l.router.push(`/customer/${f.id}/loyalty`)}):null]})}},792,[812,805,31,128,840,818,819,820,822,823,825,879,25]);
2
+ __d(function(g,_r,i,a,m,_e,d){"use strict";function e(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(_e,'__esModule',{value:!0}),_e.TakeawayPayCard=function({o:e,phone:y}){const[f,k]=(0,n.useState)(Date.now()),[w,x]=(0,n.useState)(!1),[j,b]=(0,n.useState)(''),[P,v]=(0,n.useState)(null),_=(0,n.useRef)(!1),B=(0,c.payView)(e,f);(0,n.useEffect)(()=>{const e=setInterval(()=>k(Date.now()),1e3);return()=>clearInterval(e)},[]);const T='pay'===B.kind||'expired'===B.kind&&_.current&&'awaiting_payment'===e.status;(0,n.useEffect)(()=>{if(!T||!_.current)return;const n=setInterval(()=>{(0,h.checkPaid)(e.id)},1e4),r=t.default.addEventListener('change',n=>{'active'===n&&(0,h.checkPaid)(e.id)});return()=>{clearInterval(n),r.remove()}},[T,e.id]);if('none'===B.kind)return null;if('sending'===B.kind)return(0,p.jsx)(s.Banner,{kind:"warn",title:"Saving your order\u2026",children:"Sending it to the restaurant. Card payment opens in a moment."});if('refused'===B.kind)return(0,p.jsxs)(s.Banner,{kind:"danger",title:"The restaurant couldn\u2019t take this order",children:[(0,p.jsx)(s.T,{size:14,colour:"#FFE3DF",children:`${B.reason} Nothing has been charged.`}),(0,p.jsx)(s.Button,{small:!0,kind:"secondary",label:"Back to the menu",onPress:()=>o.router.replace(`/customer/${e.restaurantId}`)})]});if('paid'===B.kind)return(0,p.jsx)(s.Banner,{kind:"success",title:`Paid ${(0,l.gbp)(B.amount)} by card`,children:B.late?'Your payment came in after the time ran out. The restaurant has your order and will contact you if the collection time needs to change.':'Your order has gone to the kitchen.'});if('expired'===B.kind)return(0,p.jsxs)(s.Banner,{kind:"warn",title:'awaiting_payment'===e.status?'Checking your payment\u2026':'Time ran out: order not sent',children:[(0,p.jsx)(s.T,{size:14,children:'awaiting_payment'===e.status?'We\u2019re checking with the payment page. If you paid, your order will show as paid shortly.':`Nothing has been charged. You can order again${y?` or ring ${y}`:''}.`}),'awaiting_payment'!==e.status?(0,p.jsx)(s.Button,{small:!0,kind:"secondary",label:"Order again",onPress:()=>o.router.replace(`/customer/${e.restaurantId}`)}):null]});return(0,p.jsxs)(s.Card,{highlight:u.colours.gold,children:[(0,p.jsx)(s.H2,{children:"Pay to send your order"}),(0,p.jsxs)(s.T,{children:["Your order goes to the kitchen once it\u2019s paid. Time left to pay: ",(0,p.jsx)(s.T,{weight:"bold",colour:B.secondsLeft<120?u.colours.red:u.colours.gold,children:(0,c.mmss)(B.secondsLeft)})]}),(0,p.jsx)(s.Button,{label:w?'Opening the payment page\u2026':`Pay ${(0,l.gbp)(e.total)} by card`,disabled:w||B.secondsLeft<120,onPress:async()=>{x(!0),b('');const n='undefined'!=typeof window?window.open('','_blank'):null,t=await(0,h.getPayLink)(e.id);if(x(!1),!t.ok)return n?.close(),void b(t.message);if(v(t.url),_.current=!0,n)try{return void(n.location.href=t.url)}catch{}},testID:"pay-card"}),B.secondsLeft<120?(0,p.jsx)(s.Muted,{children:"Not enough time left to pay. Wait for this order to expire, then order again."}):null,P?(0,p.jsx)(s.Button,{small:!0,kind:"secondary",label:"Open the payment page again",onPress:()=>{'undefined'!=typeof window?window.open(P,'_blank'):r.default.openURL(P)}}):null,P?(0,p.jsx)(s.Button,{small:!0,kind:"ghost",label:"I\u2019ve paid: check now",onPress:()=>{(0,h.checkPaid)(e.id)}}):null,j?(0,p.jsx)(s.T,{size:14,colour:u.colours.red,children:j}):null,(0,p.jsx)(s.Muted,{children:"Secure card payment on the restaurant\u2019s website. Apple Pay and Google Pay may be offered there."})]})};var n=_r(d[0]),t=e(_r(d[1])),r=e(_r(d[2]));_r(d[3]);var o=_r(d[4]),s=_r(d[5]),l=_r(d[6]),u=_r(d[7]),c=_r(d[8]),h=_r(d[9]),p=_r(d[10])},879,[31,232,240,123,805,818,820,825,836,880,25]);
3
+ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"PAY_OFF",{enumerable:!0,get:function(){return o}}),e.getPayLink=async function(u){try{if(!await(0,n.guestSession)())return{ok:!1,message:'Can\u2019t reach the restaurant. Check your signal and try again.'};const{data:c,error:y}=await(0,t.getSupabase)().functions.invoke('takeaway-pay',{body:{order_id:u}}),f=await s(c,y);return f&&'string'==typeof f.url&&f.url.startsWith('https://')?{ok:!0,url:f.url,expiresAt:String(f.expiresAt??''),amountPence:Number(f.amountPence??0)}:{ok:!1,message:'string'==typeof f?.error?f.error:o}}catch{return{ok:!1,message:o}}},e.checkPaid=async function(o){try{const{data:u,error:c}=await(0,t.getSupabase)().functions.invoke('takeaway-pay-check',{body:{order_id:o}}),y=await s(u,c);return(0,n.nudgeGuestSync)(),y?.off?'off':String(y?.state??'unknown')}catch{return'unknown'}};var t=r(d[0]),n=r(d[1]);const o='Card payment isn\u2019t available right now. Nothing has been charged. Please ring the restaurant.';async function s(t,n){if(t&&'object'==typeof t)return t;const o=n?.context;try{const t=o?.json?await o.json():null;return t&&'object'==typeof t?t:null}catch{return null}}},880,[871,824]);
abbotsford/chef-app/_expo/static/js/web/[section]-2201675add2ff7b9966ea9d886c9adf3.js ADDED
@@ -0,0 +1 @@
 
 
1
+ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return s}});var t=r(d[0]);r(d[1]);var n=r(d[2]),c=r(d[3]),o=r(d[4]),f=r(d[5]);function s(){const{section:s}=(0,t.useLocalSearchParams)();return(0,c.canShow)('chef')?s&&(0,o.chefSectionAllowed)(String(s))?(0,f.jsx)(n.ChefApp,{section:String(s)},String(s)):(0,f.jsx)(t.Redirect,{href:"/kitchen"}):(0,f.jsx)(t.Redirect,{href:c.ENTRY[c.APP_VARIANT]})}},776,[805,31,806,807,808,25]);
abbotsford/chef-app/_expo/static/js/web/[token]-060d0a0e0a07c4da23ca6d5b04c35e87.js ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return u}});var t=r(d[0]);r(d[1]);var n=r(d[2]),o=r(d[3]),c=r(d[4]),s=r(d[5]),l=r(d[6]);function u(){const{token:u}=(0,t.useLocalSearchParams)(),h=(0,c.cleanToken)(u);return h?(0,s.guestServer)()?(0,l.jsx)(o.TableOrderLive,{token:h}):(0,l.jsx)(n.Screen,{title:"Order at the table",children:(0,l.jsx)(n.Banner,{kind:"demo",title:"Not connected",children:"This preview isn't connected to a venue, so table orders can't be sent from here."})}):(0,l.jsx)(n.Screen,{title:"Order at the table",children:(0,l.jsx)(n.Banner,{kind:"warn",title:"This code isn't working",children:"Please scan the QR code on your table again, or ask a member of staff."})})}},796,[805,31,818,882,884,845,25]);
2
+ __d(function(g,_r,_i,_a,_m,_e,_d){"use strict";Object.defineProperty(_e,'__esModule',{value:!0}),_e.TableOrderLive=function({token:e}){const[s,m]=(0,l.useState)(null),[x,y]=(0,l.useState)(null),[j,f]=(0,l.useState)([]),[k,w]=(0,l.useState)(null),T=(0,h.useCustomer)(),[C,S]=(0,l.useState)(()=>(T?.allergies??[]).map(e=>e.allergen)),[v,O]=(0,l.useState)(''),[P,R]=(0,l.useState)(''),[I,M]=(0,l.useState)(''),[L,N]=(0,l.useState)(!1),[$,A]=(0,l.useState)(null),[B,D]=(0,l.useState)([]),q=(0,l.useCallback)(async()=>{try{m(await(0,c.tablePublic)(e)),y(null)}catch(e){y((0,d.tableOrderError)(e,'menu'))}},[e]),_=(0,l.useCallback)(async()=>{try{D(await(0,c.myTableOrders)(e))}catch{}},[e]);(0,l.useEffect)(()=>{q(),_();const e=setInterval(()=>{_(),q()},8e3);return()=>clearInterval(e)},[q,_]);const W=s?.menu??[];(0,l.useEffect)(()=>{f(e=>e.filter(e=>W.some(t=>t.id===e.id&&!t.soldOut)))},[s]);const E=(0,l.useMemo)(()=>{const e=new Map;for(const t of W)e.set(t.section,[...e.get(t.section)??[],t]);return[...e.entries()]},[s]),Y=(0,d.cartTotal)(j,W),z='yes'===k?C.map(e=>({allergen:e,severity:T?.allergies?.find(t=>t.allergen===e)?.severity??'allergy'})):[],G=(0,d.allergyClashes)(j,W,z.map(e=>e.allergen)),V=e=>j.find(t=>t.id===e)?.qty??0,F=(e,t)=>f(n=>t<=0?n.filter(t=>t.id!==e):n.some(t=>t.id===e)?n.map(n=>n.id===e?{...n,qty:t}:n):[...n,{id:e,qty:t,note:''}]),H=(e,t)=>f(n=>n.map(n=>n.id===e?{...n,note:t}:n)),J=async()=>{N(!0),A(null);try{const t=await(0,c.sendTableOrder)(e,j,{note:I,name:v,phone:P,allergies:z});f([]),M(''),A({kind:'success',text:t.held?`Order ${t.ref} sent. A member of staff will check it, then it goes to the kitchen.`:`Order ${t.ref} sent to the kitchen.`}),_()}catch(e){A({kind:'warn',text:(0,d.tableOrderError)(e,'send')}),q()}finally{N(!1)}};if(x)return(0,p.jsxs)(o.Screen,{title:"Order at the table",children:[(0,p.jsx)(o.Banner,{kind:"warn",title:"Couldn't open the menu",children:x}),(0,p.jsx)(o.Button,{label:"Try again",onPress:()=>{q()}})]});if(!s)return(0,p.jsx)(o.Screen,{title:"Order at the table",children:(0,p.jsx)(o.Muted,{children:"Opening the menu\u2026"})});if(!s.ok)return(0,p.jsx)(o.Screen,{title:"Order at the table",children:(0,p.jsx)(o.Banner,{kind:"warn",title:"This code isn't working",children:s.reason??'Please ask a member of staff.'})});const K=s.open&&j.length>0&&null!==k&&('none'===k||C.length>0)&&(0,d.nameOk)(v)&&(0,d.phoneOk)(P)&&!L,Q=s.askServer??[],U=[...new Set(Q.map(e=>e.section))],X=L?'Sending\u2026':j.length?null===k?'Answer the allergy question':(0,d.nameOk)(v)?(0,d.phoneOk)(P)?`Send order to the kitchen (${(0,i.gbp)(Y)})`:'Check the phone number':'Add your name to send':'Add a dish to order';return(0,p.jsxs)(o.Screen,{title:`Table ${(0,n.tableNumbers)(s.table)}`,subtitle:s.venueName,footer:s.open?(0,p.jsx)(o.Button,{label:X,disabled:!K,onPress:()=>{J()},testID:"send-table-order-live"}):void 0,children:[(0,p.jsxs)(o.Muted,{center:!0,children:["Tip: add dishes, answer the allergy question, add your name, then send. Staff bring it to table ",(0,n.tableNumbers)(s.table),". ",d.PAY_WORDS]}),s.tip?(0,p.jsx)(o.Banner,{kind:"demo",children:s.tip}):null,s.open?null:(0,p.jsx)(o.Banner,{kind:"warn",title:"Not taking table orders right now",children:s.reason}),s.open&&s.staffAccept&&!B.some(e=>e.accepted)?(0,p.jsx)(o.Muted,{children:"The first order from your phone is checked by a member of staff before it goes to the kitchen."}):null,$?(0,p.jsx)(o.Banner,{kind:$.kind,children:$.text}):null,B.length?(0,p.jsx)(r.default,{testID:"my-table-orders",children:(0,p.jsxs)(o.Card,{children:[(0,p.jsx)(o.T,{weight:"semibold",children:"Your orders at this table"}),B.map(e=>(0,p.jsxs)(r.default,{style:{gap:2,paddingVertical:4},children:[(0,p.jsxs)(o.Row,{style:{justifyContent:'space-between'},children:[(0,p.jsx)(o.T,{children:e.ref}),(0,p.jsx)(o.T,{size:13,colour:'cancelled'===e.status?u.colours.amber:u.colours.gold,children:(0,d.guestStatusWords)(e)})]}),(0,p.jsxs)(o.Muted,{children:[e.lines.map(e=>`${e.qty}\xd7 ${e.name}`).join(', ')," \xb7 ",(0,i.gbp)(e.totalPence)," to pay at the bar or with the server"]})]},e.id))]})}):null,s.open?E.map(([e,t])=>(0,p.jsxs)(r.default,{style:{gap:8},children:[(0,p.jsx)(o.T,{center:!0,size:20,weight:"semibold",colour:u.colours.gold,accessibilityRole:"header",children:e}),t.map(e=>(0,p.jsxs)(o.Card,{children:[(0,p.jsxs)(o.Row,{style:{justifyContent:'space-between',alignItems:'flex-start'},children:[(0,p.jsxs)(r.default,{style:{flex:1,gap:2},children:[(0,p.jsx)(o.T,{weight:"semibold",children:e.name}),e.description?(0,p.jsx)(o.Muted,{children:e.description}):null,(0,p.jsxs)(o.T,{size:13,colour:u.colours.muted,children:[e.allergens.length?`Contains: ${e.allergens.map(a.allergenLabel).join(', ')}`:'No allergens listed: ask staff if unsure',e.mayContain.length?` \xb7 May contain: ${e.mayContain.map(a.allergenLabel).join(', ')}`:'']})]}),(0,p.jsx)(o.T,{weight:"semibold",colour:u.colours.gold,children:(0,i.gbp)(e.pricePence)})]}),e.soldOut?(0,p.jsx)(o.Badge,{kind:"amber",label:"Sold out today"}):V(e.id)?(0,p.jsxs)(o.Row,{style:{justifyContent:'space-between'},children:[(0,p.jsx)(o.Stepper,{value:V(e.id),min:0,max:20,onChange:t=>F(e.id,t),label:e.name}),(0,p.jsx)(o.Button,{small:!0,kind:"ghost",label:"Remove",onPress:()=>F(e.id,0)})]}):(0,p.jsx)(o.Button,{small:!0,kind:"secondary",label:"Add",accessibilityLabel:`Add ${e.name}`,onPress:()=>F(e.id,1)})]},e.id))]},e)):null,s.open&&!W.length?(0,p.jsx)(o.Banner,{kind:"demo",title:"No dishes to order from your phone yet",children:"The kitchen is still checking the allergens on the menu. Please order with your server or at the bar."}):null,s.open&&Q.length?(0,p.jsxs)(r.default,{testID:"table-ask-server",style:{gap:8},children:[(0,p.jsx)(o.T,{center:!0,size:20,weight:"semibold",colour:u.colours.gold,accessibilityRole:"header",children:W.length?'Also on the menu':'On the menu'}),(0,p.jsx)(o.Muted,{center:!0,children:"Ask your server for these. They can't be ordered from your phone yet, while the kitchen checks their allergens."}),U.map(e=>(0,p.jsxs)(o.Card,{children:[(0,p.jsx)(o.T,{center:!0,weight:"semibold",children:e}),Q.filter(t=>t.section===e).map((e,t)=>(0,p.jsxs)(o.Row,{style:{justifyContent:'space-between'},children:[(0,p.jsx)(o.T,{style:{flex:1},children:e.name}),(0,p.jsx)(o.T,{colour:u.colours.muted,children:(0,i.gbp)(e.pricePence)})]},`${e.name}-${t}`))]},e))]}):null,s.open&&j.length?(0,p.jsx)(r.default,{testID:"table-cart",children:(0,p.jsxs)(o.Card,{children:[(0,p.jsx)(o.T,{center:!0,weight:"semibold",accessibilityRole:"header",children:"Review your order"}),j.map(e=>{const n=W.find(t=>t.id===e.id);return(0,p.jsxs)(r.default,{style:{gap:4},children:[(0,p.jsxs)(o.Row,{style:{justifyContent:'space-between'},children:[(0,p.jsxs)(o.T,{children:[e.qty,"\xd7 ",n?.name]}),(0,p.jsx)(o.T,{children:(0,i.gbp)(e.qty*(n?.pricePence??0))})]}),(0,p.jsx)(t.TextInput,{style:b,value:e.note,onChangeText:t=>H(e.id,t),placeholder:"Note for the kitchen (optional), e.g. no onions",placeholderTextColor:u.colours.muted,maxLength:140,accessibilityLabel:`Note for ${n?.name}`,testID:`table-note-${e.id}`})]},e.id)}),(0,p.jsxs)(o.Row,{style:{justifyContent:'space-between'},children:[(0,p.jsx)(o.T,{weight:"semibold",children:"Total"}),(0,p.jsx)(o.T,{weight:"semibold",children:(0,i.gbp)(Y)})]})]})}):null,s.open?(0,p.jsx)(r.default,{testID:"table-allergy",children:(0,p.jsxs)(o.Card,{children:[(0,p.jsx)(o.T,{center:!0,weight:"semibold",children:"Does anyone at the table have a food allergy?"}),(0,p.jsx)(o.Muted,{center:!0,children:"We ask everyone, so the kitchen can keep you safe."}),(0,p.jsxs)(o.Row,{gap:8,style:{justifyContent:'center'},children:[(0,p.jsx)(o.Chip,{label:"No allergies",selected:'none'===k,onPress:()=>w('none')}),(0,p.jsx)(o.Chip,{label:"Yes, allergies",selected:'yes'===k,onPress:()=>w('yes')})]}),'yes'===k?(0,p.jsx)(o.Row,{wrap:!0,gap:6,children:a.ALLERGENS.map(e=>(0,p.jsx)(o.Chip,{label:e.short,selected:C.includes(e.id),onPress:()=>S(t=>t.includes(e.id)?t.filter(t=>t!==e.id):[...t,e.id])},e.id))}):null,G.length?(0,p.jsxs)(o.Banner,{kind:"warn",title:"Check with staff",children:[G.map(e=>e.name).join(', ')," ",G.length>1?'contain':'contains'," or may contain an allergy you picked. The kitchen will see your allergies on the ticket."]}):null]})}):null,s.open?(0,p.jsxs)(o.Card,{children:[(0,p.jsx)(o.T,{center:!0,weight:"semibold",children:"Who's the order for?"}),(0,p.jsx)(t.TextInput,{style:b,value:v,onChangeText:O,placeholder:"Your name (needed)",placeholderTextColor:u.colours.muted,maxLength:40,accessibilityLabel:"Your name, needed",testID:"table-name",autoComplete:"name"}),(0,p.jsx)(t.TextInput,{style:b,value:P,onChangeText:R,placeholder:"Phone number (optional)",placeholderTextColor:u.colours.muted,maxLength:20,keyboardType:"phone-pad",accessibilityLabel:"Phone number, optional",testID:"table-phone",autoComplete:"tel"}),P&&!(0,d.phoneOk)(P)?(0,p.jsx)(o.Muted,{center:!0,children:"Please check the phone number, or leave it blank."}):null,(0,p.jsx)(o.Muted,{center:!0,children:"We only use these for this order."}),(0,p.jsx)(t.TextInput,{style:b,value:I,onChangeText:M,placeholder:"Note for the staff (optional)",placeholderTextColor:u.colours.muted,maxLength:300,accessibilityLabel:"Note for the staff (optional)"})]}):null,(0,p.jsx)(r.default,{testID:"pay-placeholder",children:(0,p.jsxs)(o.Card,{children:[(0,p.jsx)(o.T,{center:!0,weight:"semibold",children:"Paying"}),(0,p.jsx)(o.T,{center:!0,children:d.PAY_WORDS}),(0,p.jsx)(o.Muted,{center:!0,children:"No card details are asked for or kept in this app."})]})})]})};var e,t=_r(_d[0]),n=_r(_d[1]),l=_r(_d[2]),s=_r(_d[3]),r=(e=s)&&e.__esModule?e:{default:e},o=_r(_d[4]),a=_r(_d[5]),i=_r(_d[6]),d=_r(_d[7]),c=_r(_d[8]),h=_r(_d[9]),u=_r(_d[10]),p=_r(_d[11]);const b={borderWidth:1,borderColor:u.colours.border,borderRadius:10,padding:10,color:u.colours.text,backgroundColor:u.colours.surface2}},882,[873,812,31,128,818,819,820,884,883,823,825,25]);
3
+ __d(function(g,_r,i,_a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"tablePublic",{enumerable:!0,get:function(){return s}}),e.sendTableOrder=async function(t,r,a){if(!await(0,n.guestSession)())throw new Error('No connection. Try again when you are back online.');const o=await(0,n.rpc)('guest_table_order_v2',{p_phone:(a.phone??'').trim().slice(0,20)||null,p_token:t,p_lines:r.map(t=>({id:t.id,qty:t.qty,note:t.note.trim().slice(0,140)})),p_note:a.note.trim().slice(0,300)||null,p_allergies:a.allergies.map(t=>({allergen:t.allergen,severity:t.severity})),p_name:a.name.trim().slice(0,40)||null});if(!o||!1===o.ok||!o.id)throw new Error(o?.reason||'This table code isn\u2019t working any more. Please ask a member of staff.');return{id:o.id,ref:o.ref,held:!!o.held,totalPence:o.totalPence}},e.myTableOrders=async function(t){return await(0,n.guestSession)()?await(0,n.rpc)('guest_table_my_orders',{p_token:t})??[]:[]},e.loadTableSettings=async function(){const{data:t,error:n}=await a().from('table_order_settings').select('*').eq('venue_id',o()).maybeSingle();if(n)throw n;return(0,r.fromRow)(t)},e.saveTableSettings=async function(t,n){const{error:s}=await a().from('table_order_settings').upsert({venue_id:o(),...(0,r.toRow)(t),updated_at:(new Date).toISOString(),updated_by:n.slice(0,80)});if(s)throw s},e.listTableCodes=async function(){const{data:t,error:n}=await a().from('table_qr_codes').select('table_no, token, created_at').eq('venue_id',o()).eq('is_on',!0);if(n)throw n;return(t??[]).map(t=>({table:String(t.table_no),token:String(t.token),createdAt:String(t.created_at)})).sort((t,n)=>Number(t.table)-Number(n.table))},Object.defineProperty(e,"tableReadiness",{enumerable:!0,get:function(){return l}}),Object.defineProperty(e,"makeTableCodes",{enumerable:!0,get:function(){return c}}),Object.defineProperty(e,"renewTableCode",{enumerable:!0,get:function(){return u}}),e.watchTableSettings=function(t){const r=n.useSync.getState().venueId;if(!r)return()=>{};const o=a().channel(`tos-${r}-${Math.random().toString(36).slice(2,8)}`).on('postgres_changes',{event:'*',schema:'public',table:'table_order_settings',filter:`venue_id=eq.${r}`},()=>t()).subscribe();return()=>{a().removeChannel(o)}};var t=_r(d[0]),n=_r(d[1]),r=_r(d[2]);const a=()=>(0,t.getSupabase)(),o=()=>{const t=n.useSync.getState().venueId;if(!t)throw new Error('Not connected to the venue yet.');return t},s=t=>(0,n.rpc)('table_public',{p_token:t});const l=()=>(0,n.rpc)('table_order_readiness',{p_venue:o()}),c=t=>(0,n.rpc)('table_qr_make',{p_venue:o(),p_tables:t}),u=t=>(0,n.rpc)('table_qr_renew',{p_venue:o(),p_table:t})},883,[871,824,884]);
abbotsford/chef-app/_expo/static/js/web/__common-d92ed2b513b48a7e75fdf07ee4f937c8.js ADDED
The diff for this file is too large to render. See raw diff
 
abbotsford/chef-app/_expo/static/js/web/_layout-28f52c5d547984f57d779d2d1595deac.js ADDED
The diff for this file is too large to render. See raw diff
 
abbotsford/chef-app/_expo/static/js/web/basket-c05ffa92d4d6d13484ce78275193c02c.js ADDED
@@ -0,0 +1 @@
 
 
1
+ __d(function(g,_r,_i,_a,_m,_e,d){"use strict";function e(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(_e,'__esModule',{value:!0}),Object.defineProperty(_e,"default",{enumerable:!0,get:function(){return v}});var l=_r(d[0]),t=_r(d[1]),a=_r(d[2]),n=e(a),o=_r(d[3]),r=_r(d[4]),s=e(_r(d[5])),i=_r(d[6]),u=_r(d[7]),c=_r(d[8]),h=_r(d[9]),m=_r(d[10]),b=_r(d[11]),y=_r(d[12]),j=_r(d[13]),x=_r(d[14]),k=_r(d[15]),p=_r(d[16]),f=_r(d[17]);function v(){const e=(0,b.useBasket)(),v=(0,b.useRestaurant)(e.restaurantId??void 0),w=(0,b.useAllMenu)(e.restaurantId??void 0),C=(0,b.useCustomer)(),S=(0,b.useOrders)(v?.id),T=(0,b.useStore)(e=>e.setLineQty),B=(0,b.useStore)(e=>e.overrideLine),P=(0,b.useStore)(e=>e.startBasket),I=(0,b.useNow)(15e3),[O,$]=(0,a.useState)(null),[N,M]=(0,a.useState)(!1),[F,L]=(0,a.useState)(''),[z]=(0,a.useState)(()=>(0,r.startForm)()),[A,R]=(0,a.useState)(''),[Y,D]=(0,a.useState)(C.phone??''),[E,_]=(0,a.useState)(C.email??''),[q,H]=(0,a.useState)(C.name&&'Guest'!==C.name?C.name:''),[G,V]=(0,a.useState)(!1),K=(0,b.useOrderAtTable)(e.restaurantId??void 0),Q=(0,p.useTakeawayMenu)(l=>e.restaurantId?l.byVenue[e.restaurantId]:void 0);n.default.useEffect(()=>{K||'table'!==e.mode||b.useStore.setState(e=>({basket:{...e.basket,mode:'takeaway',tableNo:void 0}}))},[K,e.mode]);const[U,J]=(0,a.useState)(null),[W,X]=(0,a.useState)(!1),Z=(0,a.useMemo)(()=>(0,y.linesFromBasket)(e,w,C.allergies),[e,w,C.allergies]);if(!v||!e.lines.length)return(0,f.jsxs)(i.Screen,{title:"Your basket",children:[(0,f.jsx)(i.Muted,{children:"Your basket is empty."}),(0,f.jsx)(i.Button,{label:"Browse restaurants",onPress:()=>t.router.replace('/customer')})]});const ee=K&&'table'===e.mode,le=(0,h.takeawaySlots)(v,S,I),te=Z.reduce((e,l)=>e+l.unitPrice*l.qty,0),ae=Z.some(e=>e.contains.length&&!e.overridden),ne=e.lines.filter(e=>{const l=w.find(l=>l.id===e.itemId);return!l||l.soldOut||!l.signOff||!ee&&'on'!==(0,p.takeawayAvail)(l,Q)}),oe=!ee&&!O,re=!ee&&v.settings.takeawayPaused,se=(0,x.ukPhone)(Y),ie=q.trim().length>=2&&'guest'!==q.trim().toLowerCase(),de=ee||(0,p.takesCardTakeaway)(v,k.IS_ISOLATED_VENUE),ue=!G&&de&&!ae&&!ne.length&&N&&!oe&&!re&&(ee||ie&&se.ok&&(0,x.emailOk)(E)),ce=async()=>{V(!0);try{const e=await b.repo.orders.placeFromBasket({slotTime:ee?void 0:O,tip:0,notes:F,phone:ee?void 0:se.pretty,email:ee?void 0:E.trim()||void 0,customerName:ee?void 0:q.trim()});(0,r.rememberGuard)(e.id,(0,r.guardFor)({...z,hp:A})),t.router.replace(`/customer/order/${e.id}`)}finally{V(!1)}},he=e.lines.find(e=>e.key===U),me=he?Z[e.lines.indexOf(he)]:void 0;return(0,f.jsxs)(i.Screen,{title:"Your basket",subtitle:`${v.name} \xb7 ${ee?`${(0,l.tableNumbers)(e.tableNo)} (order at table)`:'Takeaway \u2014 collection'}`,footer:(0,f.jsxs)(s.default,{style:{gap:8},children:[(0,f.jsxs)(i.Row,{style:{justifyContent:'space-between'},children:[(0,f.jsx)(i.T,{weight:"semibold",children:"Subtotal"}),(0,f.jsx)(i.T,{weight:"bold",size:20,colour:j.colours.gold,children:(0,c.gbp)(te)})]}),de?ae?(0,f.jsx)(i.T,{size:14,colour:j.colours.red,children:"Resolve the blocked allergy item(s) before continuing."}):N?oe&&!re?(0,f.jsx)(i.T,{size:14,colour:j.colours.amber,children:"Choose a collection time."}):ee||ie?ee||se.ok?null:(0,f.jsx)(i.T,{size:14,colour:j.colours.amber,children:"Add your mobile number."}):(0,f.jsx)(i.T,{size:14,colour:j.colours.amber,children:"Add your name for the order."}):(0,f.jsx)(i.T,{size:14,colour:j.colours.amber,children:"Confirm your allergies to continue."}):(0,f.jsx)(i.T,{size:14,colour:j.colours.amber,children:"Online takeaway orders aren\u2019t available for this restaurant. Please ring them to order."}),ee?(0,f.jsx)(i.Button,{label:"Send order to the kitchen",disabled:!ue,onPress:()=>ce(),testID:"send-table-order"}):(0,f.jsx)(i.Button,{label:G?'Saving your order\u2026':`Continue to card payment \xb7 ${(0,c.gbp)(te)}`,disabled:!ue,onPress:()=>ce(),testID:"checkout"}),ee?null:(0,f.jsx)(i.Muted,{children:"You pay by card on the restaurant\u2019s secure checkout. Your order goes to the kitchen once it\u2019s paid. You have 15 minutes to pay."})]}),children:[(ee||e.tableNo,null),ee?(0,f.jsx)(i.Banner,{kind:"success",title:`${(0,l.tableNumbers)(e.tableNo)}`,children:"Ordered food goes to the kitchen straight away; you pay at the end (split the bill if you like)."}):null,v.fictional?null:(0,f.jsx)(i.AllergenNotice,{phone:v.phone}),Z.map((l,t)=>{const a=e.lines[t],n=l.contains.length&&!l.overridden;return(0,f.jsxs)(i.Card,{highlight:l.contains.length?j.colours.red:l.may.length?j.colours.amber:void 0,children:[(0,f.jsxs)(i.Row,{style:{justifyContent:'space-between',alignItems:'flex-start'},children:[(0,f.jsxs)(s.default,{style:{flex:1,paddingRight:8},children:[(0,f.jsx)(i.T,{weight:"semibold",children:l.name}),l.choices.length?(0,f.jsx)(i.Muted,{children:l.choices.join(' \xb7 ')}):null,l.notes?(0,f.jsxs)(i.Muted,{children:["Note: ",l.notes]}):null]}),(0,f.jsx)(i.T,{weight:"semibold",children:(0,c.gbp)(l.unitPrice*l.qty)})]}),n?(0,f.jsxs)(i.Banner,{kind:"danger",title:`BLOCKED \u2014 contains ${l.contains.map(u.allergenLabel).join(', ')}`,children:[(0,f.jsx)(i.T,{size:14,colour:"#FFE3DF",children:`Conflicts with your declared ${C.allergies.filter(e=>l.contains.includes(e.allergen)).map(e=>`${(0,u.allergenLabel)(e.allergen)} (${(0,u.severityLabel)(e.severity)})`).join(', ')}.`}),(0,f.jsxs)(i.Row,{gap:8,style:{marginTop:6},children:[(0,f.jsx)(i.Button,{small:!0,kind:"secondary",label:"Remove",onPress:()=>T(a.key,0)}),(0,f.jsx)(i.Button,{small:!0,kind:"danger",label:"Override\u2026",onPress:()=>{X(!1),J(a.key)}})]})]}):l.contains.length?(0,f.jsx)(i.Banner,{kind:"danger",title:`Allergy override recorded \u2014 contains ${l.contains.map(u.allergenLabel).join(', ')}`,children:"The kitchen will get an allergy alert that must be acknowledged, and staff will check with you at handover."}):null,l.may.length?(0,f.jsx)(i.Banner,{kind:"warn",title:`May contain ${l.may.map(u.allergenLabel).join(', ')}`,children:"Cross-contact risk (e.g. shared fryer). Please check with staff."}):null,ne.includes(a)?(0,f.jsx)(i.Badge,{kind:"amber",label:!ee&&Q&&w.find(e=>e.id===a.itemId)&&'sold-out'===(0,p.takeawayAvail)(w.find(e=>e.id===a.itemId),Q)?'Sold out \u2014 please remove':'Not available for takeaway \u2014 please remove'}):null,(0,f.jsxs)(i.Row,{style:{justifyContent:'space-between'},children:[(0,f.jsx)(i.Button,{small:!0,kind:"ghost",label:"Remove",onPress:()=>T(a.key,0)}),(0,f.jsx)(i.Stepper,{value:a.qty,onChange:e=>T(a.key,e),min:1,label:l.name})]})]},a.key)}),(0,f.jsx)(i.Button,{kind:"ghost",label:"Add more items",onPress:()=>t.router.push(`/customer/${v.id}`)}),ee?null:(0,f.jsxs)(i.Card,{children:[(0,f.jsxs)(i.H2,{children:["Collection time \u2014 ",(0,m.niceDate)(I)]}),re?(0,f.jsx)(i.Banner,{kind:"warn",title:"Takeaway paused",children:"The restaurant has paused takeaway slots for now. Please try again later or book a table."}):0===le.length?(0,f.jsx)(i.Banner,{kind:"warn",children:"No collection slots left today."}):(0,f.jsxs)(f.Fragment,{children:[(0,f.jsxs)(i.Muted,{children:["15-minute slots, max ",v.settings.slotCap," orders each so the kitchen isn\u2019t overloaded."]}),(0,f.jsx)(i.Row,{wrap:!0,gap:6,children:le.slice(0,16).map(e=>(0,f.jsx)(i.Chip,{label:e.label,sub:e.full?'Full':e.cap-e.taken+" left",disabled:e.full,selected:O===e.time.toISOString(),onPress:()=>$(e.time.toISOString())},e.label))})]})]}),(0,f.jsxs)(i.Card,{highlight:N?void 0:j.colours.amber,children:[(0,f.jsx)(i.H2,{children:"Confirm allergies for this order"}),(0,f.jsx)(i.Row,{wrap:!0,gap:6,children:C.allergies.length?C.allergies.map(e=>(0,f.jsx)(i.Badge,{kind:"red",label:`${(0,u.allergenLabel)(e.allergen)} \u2014 ${(0,u.severityLabel)(e.severity)}`},e.allergen)):(0,f.jsx)(i.Muted,{children:"No allergies declared on your profile."})}),(0,f.jsx)(i.Toggle,{label:C.allergies.length?'Yes, these are correct for everyone this order is for':'I confirm no one in this order has a food allergy',value:N,onChange:M}),(0,f.jsx)(i.Button,{small:!0,kind:"ghost",label:"Edit allergies in profile",onPress:()=>t.router.push('/customer/profile')})]}),ee?null:(0,f.jsxs)(i.Card,{children:[(0,f.jsx)(i.H2,{children:"Your details"}),(0,f.jsx)(i.Field,{testID:"order-name",label:"Name for the order",value:q,onChangeText:H,autoComplete:"name",placeholder:"e.g. Sam Smith"}),q&&!ie?(0,f.jsx)(i.T,{size:13,colour:j.colours.amber,children:"Please add your name."}):null,(0,f.jsx)(i.Field,{testID:"order-phone",label:"Mobile number (needed for collection)",value:Y,onChangeText:D,keyboardType:"phone-pad",autoComplete:"tel",placeholder:"e.g. 07700 900123"}),!se.ok&&Y?(0,f.jsx)(i.T,{size:13,colour:j.colours.amber,children:se.error}):null,(0,f.jsx)(i.Field,{label:"Email (optional)",value:E,onChangeText:_,keyboardType:"email-address",autoCapitalize:"none",placeholder:"you@example.com"}),(0,x.emailOk)(E)?null:(0,f.jsx)(i.T,{size:13,colour:j.colours.amber,children:"That email doesn\u2019t look quite right. Check it, or leave it blank."}),(0,f.jsx)(i.Muted,{children:"Your order confirmation and collection time are shown here. Text messages are not connected."})]}),(0,f.jsx)(i.Field,{label:"Order notes (optional)",value:F,onChangeText:L,placeholder:"e.g. cutlery please"}),ee?(0,f.jsx)(i.Button,{small:!0,kind:"ghost",label:"Switch to takeaway instead",onPress:()=>P(v.id,'takeaway')}):null,(0,f.jsxs)(i.Sheet,{visible:!!he,onClose:()=>J(null),title:"Allergy override",children:[me?(0,f.jsx)(i.Banner,{kind:"danger",title:`${me.name} contains ${me.contains.map(u.allergenLabel).join(', ')}`,children:"Only continue if this item is for someone without this allergy, or you have spoken to staff."}):null,(0,f.jsx)(i.Toggle,{label:"I understand and want to add it anyway",value:W,onChange:X}),(0,f.jsx)(i.Button,{kind:"danger",disabled:!W,label:"Confirm override",onPress:()=>{he&&me&&B(he.key,me.contains),J(null)}})]}),(0,f.jsx)(o.Honeypot,{value:A,onChange:R})]})}},790,[812,805,31,815,816,128,818,819,820,821,822,823,878,825,827,5,836,25]);
abbotsford/chef-app/_expo/static/js/web/book-34e99aaf0197899dc09c20d6bb54139f.js ADDED
@@ -0,0 +1,4 @@
 
 
 
 
 
1
+ __d(function(g,_r,_i,_a,m,_e,d){"use strict";Object.defineProperty(_e,'__esModule',{value:!0}),Object.defineProperty(_e,"default",{enumerable:!0,get:function(){return A}});var e,t=_r(d[0]),o=_r(d[1]),n=_r(d[2]),s=_r(d[3]),l=_r(d[4]),i=_r(d[5]),a=_r(d[6]),r=_r(d[7]),u=(e=r)&&e.__esModule?e:{default:e},c=_r(d[8]),h=_r(d[9]),p=_r(d[10]),b=_r(d[11]),f=_r(d[12]),y=_r(d[13]),x=_r(d[14]),k=_r(d[15]),j=_r(d[16]),v=_r(d[17]),S=_r(d[18]),w=_r(d[19]),T=_r(d[20]),C=_r(d[21]),D=_r(d[22]),$=_r(d[23]),P=_r(d[24]),M=_r(d[25]),B=_r(d[26]),O=_r(d[27]);function A(){const{rid:e,date:r}=(0,s.useLocalSearchParams)(),A=(0,j.useRestaurant)(e),N=(0,j.useCustomer)(),z=(0,j.useBookings)(e),I=(0,j.useEvents)(e),R=(0,j.useNow)(6e4),[q]=(0,l.useState)(()=>(0,a.startForm)()),[F,L]=(0,l.useState)(''),[E,H]=(0,l.useState)(2),[W,_]=(0,l.useState)(0),Y=Math.min(W,Math.max(0,E-1)),[U,G]=(0,l.useState)(r??(0,k.ymd)(R)),[Q,V]=(0,l.useState)(null),[J,K]=(0,l.useState)(N.name),[X,Z]=(0,l.useState)(N.phone??''),[ee,te]=(0,l.useState)(N.email??''),[oe,ne]=(0,l.useState)(!1),[se,le]=(0,l.useState)(''),[ie,ae]=(0,l.useState)(!1),[re,de]=(0,l.useState)([]),[ue,ce]=(0,l.useState)(!1),he=[...N.allergies,...re.filter(e=>!N.allergies.some(t=>t.allergen===e)).map(e=>({allergen:e,severity:'allergy'}))],[me,ge]=(0,l.useState)(null),pe=(0,C.useBlocks)(e=>e.blocks);(0,v.usePublicDayStore)(e=>e.n);const be=e?(0,v.publicDay)(e,U):null,fe=be?[...be.bookings,...z.filter(e=>e.date!==U)]:z,ye=be?[...pe.filter(t=>t.rid!==e||t.date!==U),...be.blocks]:pe,xe=(0,D.usePlan)(e),[ke,je]=(0,l.useState)((0,P.emptyNeeds)()),ve=!0===ke.dog,Se=ve?ke.dogs:0;if(!A)return(0,O.jsx)(b.Screen,{title:"Not found",children:(0,O.jsx)(b.T,{children:"Restaurant not found."})});const we=A.settings,Te=(0,k.parseYmd)(U),Ce=(0,x.onlinePartyBounds)(A),De=(0,C.blocksOn)(ye,A.id,U),$e=fe.filter(e=>e.date===U),Pe=xe.areas.filter(e=>e.dogs),Me=(0,M.dogSetUp)(xe),Be=e=>(0,$.freeTablesAt)(xe,$e,E,new Date(`${U}${(0,t.tableNumbers)(e)}:00`),(0,$.turnFor)(E,we.turnMins),we.turnMins,{dog:!0,closed:(0,C.closedAreasAt)(ye,A.id,U,e)}),Oe=(0,x.bookingSlots)(A,Te,e=>fe.filter(t=>t.date===U&&t.time===e&&!['cancelled','noshow'].includes(t.status)).reduce((e,t)=>e+t.partySize,0),E,R,e=>fe.filter(t=>t.date===U&&t.time===e&&!['cancelled','noshow'].includes(t.status)).length).map(e=>{const t=(0,C.blockAt)(ye,A.id,U,e.time),o=ve&&Me&&e.available&&!t&&(!Be(e.time).length||!(0,P.dogTimeOk)(A,fe,U,e.time,Se));return{...e,blocked:!!t,noDog:o,available:e.available&&!t&&!o}}),Ae=Oe.some(e=>e.available),Ne=(0,c.depositOf)(we),ze=(0,c.depositDue)(Ne,E,Y),Ie=ze>0?'deposit':'none',Re=(0,c.depositWords)(Ne,E,A.name,Y),qe=I.filter(e=>e.date===U),Fe=(0,T.guestPhone)(X),Le=(0,T.emailOk)(ee),Ee=(0,P.needsMissing)(ke,N.allergies),He=!!Q&&ie&&!Ee.length&&J.trim().length>1&&Fe.ok&&Le,We=async()=>{const e=(0,P.needsPatch)(ke,N.allergies),t=ve&&Me?Be(Q).map(e=>e.table):[],o=ve?ke.tableReq.find(e=>t.includes(e))??t[0]:void 0,n=await j.repo.bookings.create({restaurantId:A.id,customerId:N.id,name:J,partySize:E,...Y?{children:Y}:{},date:U,time:Q,notes:se.trim(),security:Ie,depositPaid:0,...ze?{depositDue:ze,depositPolicy:Re.join(' '),depositRefundable:Ne.refundable,depositCutoffHours:Ne.cutoffHours}:{},phone:Fe.pretty,email:ee.trim()||void 0,source:'online',...e,...Oe.find(e=>e.time===Q)?.drinksOnly?{drinksOnly:!0}:{},allergies:e.allergies??he,...o?{table:o}:{}});(0,a.rememberGuard)(n.id,(0,a.guardFor)({...q,hp:F})),ge(n)},Ye=(0,j.useStore)(e=>me?e.bookings.find(e=>e.id===me.id)?.ref:void 0),Ue=e=>(0,w.waMeLink)(A.settings.whatsapp,(0,w.guestWhatsAppText)({name:e.name,ref:Ye??e.ref,date:e.date,time:e.time,partySize:e.partySize},A.name));if(me){const e='pending'===me.status;return(0,O.jsxs)(b.Screen,{title:e?'Booking request received':'Booking confirmed',subtitle:A.name,children:[(0,O.jsx)(b.Banner,{kind:e?'info':'success',title:`Reference ${Ye??me.ref}`,children:`${me.partySize} people \xb7 ${(0,k.niceDateYear)((0,k.parseYmd)(me.date))} at ${me.time}`}),e?(0,O.jsx)(b.Banner,{kind:"warn",title:"The team will confirm shortly",children:"For larger parties and special requests, a member of the team checks your booking first. Contact the venue if you need an update."}):null,(0,O.jsxs)(b.Card,{children:[(0,O.jsxs)(b.T,{children:["Name: ",me.name]}),(0,O.jsxs)(b.T,{children:["Mobile: ",me.phone]}),me.email?(0,O.jsxs)(b.T,{children:["Email: ",me.email]}):null,(0,O.jsxs)(b.T,{children:["Allergies shared with the restaurant: ",me.allergies.length?me.allergies.map(e=>`${(0,f.allergenLabel)(e.allergen)} (${(0,f.severityLabel)(e.severity)})`).join(', '):'none']}),me.notes?(0,O.jsxs)(b.T,{children:["Notes: ",me.notes]}):null,me.dog?(0,O.jsxs)(b.T,{children:["\ud83d\udc15 Dog coming too",me.table?` \xb7 dog-friendly table ${me.table}`:'']}):null,me.holds?.length?(0,O.jsxs)(b.T,{children:["Reserved: ",me.holds.map(e=>`${e.qty} \xd7 ${'item'===e.kind?(A.settings.reservables??M.ANCHORAGE_RESERVABLES).find(t=>t.id===e.id)?.name??'item':e.id}`).join(', ')," (the kitchen confirms it)"]}):null,me.tableReq?.length?(0,O.jsxs)(b.T,{children:["Table requested: ",me.tableReq.map(e=>`${(0,t.tableNumbers)(e)}`).join(' or ')," (not guaranteed, but we\u2019ll do our best)"]}):null,'deposit'===me.security&&me.depositDue?(0,O.jsxs)(b.T,{weight:"semibold",children:["Deposit due: ",(0,y.gbp)(me.depositDue),". ",A.name," will tell you how to pay it."]}):null,'deposit'===me.security&&me.depositPolicy?(0,O.jsx)(b.Muted,{children:me.depositPolicy}):null,(0,O.jsx)(b.Muted,{children:"Your booking details are shown above. If you need confirmation, contact the venue and quote your reference."}),(0,O.jsxs)(b.Muted,{children:["Need to change or cancel? Call ",A.phone," and quote ",Ye??me.ref,"."]})]}),Ue(me)?(0,O.jsxs)(u.default,{style:{gap:4},children:[(0,O.jsx)(b.Button,{kind:"secondary",label:"\ud83d\udcac Message us on WhatsApp",testID:"guest-whatsapp",onPress:()=>{const e=Ue(me);e&&(0,w.openWhatsApp)(e)}}),(0,O.jsx)(b.Muted,{size:13,children:"Opens WhatsApp with your booking details typed in. You can change the message before you send it."})]}):null,(0,O.jsx)(b.Button,{label:"Back to restaurant",onPress:()=>s.router.replace(`/customer/${A.id}`)})]})}return(0,O.jsxs)(b.Screen,{title:"Book a table",subtitle:A.name,footer:(0,O.jsx)(b.Button,{label:Ee.length?Ee[0]:E>(we.autoAcceptUpTo??7)?'Send booking request':'Confirm booking',disabled:!He,onPress:()=>We(),testID:"confirm-booking"}),children:[(0,O.jsx)(P.FirstQuestions,{rid:A.id,value:ke,onChange:e=>{e.dog===ke.dog&&e.dogs===ke.dogs||V(null),je(e)},party:E,audience:"guest",profile:N.allergies}),(0,O.jsxs)(b.Card,{children:[(0,O.jsxs)(u.default,{style:{gap:6,alignItems:'center'},children:[(0,O.jsx)(b.H2,{children:"Party size"}),(0,O.jsx)(o.PartySizeInput,{value:E,onChange:e=>{H(e),V(null)},min:Ce.min,max:Ce.max,label:"Party size",testID:"party-size"})]}),(0,O.jsx)(h.ChildrenCount,{guest:!0,party:E,value:Y,onChange:_,depositsOn:Ne.on&&Ne.perPersonPence>0,testID:"book-children"}),ze?(0,O.jsx)(b.Banner,{kind:"info",title:Y?`Deposit: ${(0,y.gbp)(ze)} for ${E-Y} adults (children free)`:`Deposit: ${(0,y.gbp)(ze)} for ${E} guests`,children:(0,O.jsx)(u.default,{style:{gap:4},children:Re.map(e=>(0,O.jsx)(b.T,{size:13,children:e},e))})}):Ne.on&&Ne.perPersonPence>0?(0,O.jsxs)(b.Muted,{children:["No deposit for fewer than ",Ne.fromParty," guests."]}):null,E>(we.autoAcceptUpTo??7)?(0,O.jsxs)(b.Muted,{children:["For ",E," people the team checks the booking first, then texts you to confirm."]}):null,ve&&Me?(0,O.jsxs)(b.Muted,{children:["Dogs are welcome in the ",Pe.map(e=>`${e.name}${e.outdoor?' (outdoors, weather permitting)':''}`).join(' and ')||'dog-friendly tables',". We\u2019ll only show times with a dog-friendly table",A.settings.maxDogsPerSlot?' and room for your dog':'',"."]}):null]}),(0,O.jsxs)(b.Card,{children:[(0,O.jsx)(b.H2,{children:"Date"}),(0,O.jsx)(B.CustomerDatePicker,{r:A,today:R,value:U,events:I,onChange:e=>{G(e),V(null)}}),qe.map(e=>(0,O.jsx)(b.Banner,{kind:"demo",title:e.title,children:e.description},e.id))]}),(0,O.jsxs)(b.Card,{children:[(0,O.jsx)(b.H2,{children:"Time"}),0===Oe.length?(0,O.jsx)(b.Muted,{children:"Closed on this day (per listed kitchen hours)."}):(0,O.jsx)(b.Row,{wrap:!0,gap:6,children:Oe.map(e=>(0,O.jsx)(b.Chip,{testID:`book-slot-${e.time}`,label:e.time,sub:e.available?e.drinksOnly?'Drinks only':void 0:e.blocked?'Unavailable':e.noDog?'No dog table':e.left<E||null!=e.partiesLeft&&e.partiesLeft<1?'Full':'\u2014',disabled:!e.available,selected:Q===e.time,onPress:()=>V(e.time)},e.time))}),De.length>0&&Oe.some(e=>e.blocked)?(0,O.jsx)(b.Banner,{kind:"info",title:Ae?'Some times aren\u2019t available online':'Online booking isn\u2019t available for this time',children:`We\u2019re not taking online bookings ${De.map(e=>`${e.from}\u2013${e.to}`).join(', ')} on ${(0,k.niceDate)(Te)}. Please give us a ring on ${A.phone??"the restaurant"} and we\u2019ll do our best to fit you in.`}):null,(()=>{const e=(0,n.lastFoodOn)(A,U);return e&&Oe.some(e=>e.drinksOnly)?(0,O.jsx)(b.Banner,{kind:"info",title:`Last food orders ${(0,n.fmt12)(e.time)}${'kitchen closes'!==e.reason?` (${e.reason})`:''}`,children:"Times marked \u201cDrinks only\u201d are after the kitchen\u2019s last food orders that day: you\u2019re welcome for drinks, but we can\u2019t serve food."}):null})(),ve&&Oe.some(e=>e.noDog)?(0,O.jsx)(b.Banner,{kind:"info",title:"Some times are full for dogs",children:`Times marked "No dog table" are full in the ${Pe.map(e=>e.name).join(' and ')}${A.settings.maxDogsPerSlot?' or already have the most dogs we can look after':''}${(0,C.closedAreasAt)(ye,A.id,U,Q??'12:00').size?', or the garden is closed for weather':''}. We\u2019d love to see you both, so please try one of the other times shown.`}):null,(0,O.jsx)(b.Muted,{children:(0,x.bookingLimitsHint)(A)})]}),(0,O.jsx)(P.MoreQuestions,{rid:A.id,r:A,value:ke,onChange:je,party:E,date:U,time:Q,today:(0,k.ymd)(R),bookings:fe,audience:"guest",showTables:!0}),(0,O.jsxs)(b.Card,{highlight:ie?void 0:S.colours.amber,children:[(0,O.jsx)(b.Field,{label:"Notes (optional)",value:se,onChangeText:le,placeholder:p.NOTES_PLACEHOLDER,multiline:!0,numberOfLines:3,testID:"book-notes"}),(0,O.jsx)(b.Toggle,{label:"I confirm the allergy information for this booking",value:ie,onChange:ae}),(0,O.jsx)(b.Muted,{children:"Table requests aren\u2019t guaranteed, but we\u2019ll do our best. Nothing here is charged now; reserved dishes are paid on the night."})]}),(0,O.jsxs)(b.Card,{children:[(0,O.jsx)(b.H2,{children:"Your details"}),(0,O.jsx)(b.Field,{label:"Name for the booking",value:J,onChangeText:K}),(0,O.jsx)(b.Field,{testID:"book-phone",label:"Mobile number (needed to book)",value:X,onChangeText:Z,onBlur:()=>ne(!0),keyboardType:"phone-pad",autoComplete:"tel",placeholder:"e.g. 07700 900123"}),Fe.ok||!oe&&!X?null:(0,O.jsx)(b.T,{size:13,colour:S.colours.amber,children:Fe.error}),(0,O.jsx)(b.Field,{testID:"book-email",label:"Email (optional)",value:ee,onChangeText:te,keyboardType:"email-address",autoCapitalize:"none",autoComplete:"email",placeholder:"you@example.com"}),Le?null:(0,O.jsx)(b.T,{size:13,colour:S.colours.amber,children:"That email doesn\u2019t look quite right. Check it, or leave it blank."}),(0,O.jsxs)(b.Muted,{children:["We\u2019ll text you a confirmation",ee.trim()?' and email it too':'',", with how to change or cancel. We only use your number for this booking."]})]}),(0,O.jsx)(i.Honeypot,{value:F,onChange:L})]})}},778,[812,813,814,805,31,815,816,128,14,809,817,818,819,820,821,822,823,824,825,826,827,828,829,830,831,832,810,25]);
2
+ __d(function(g,r,i,a,m,_e,d){"use strict";Object.defineProperty(_e,'__esModule',{value:!0}),Object.defineProperty(_e,"maxChildren",{enumerable:!0,get:function(){return u}}),_e.ChildrenCount=function({party:e,value:t,onChange:o,depositsOn:h,testID:c="children-count",guest:p}){const f=u(e);if(f<1)return null;const x=Math.min(t,f);return(0,s.jsxs)(n.default,{style:{gap:6,alignItems:'center',width:'100%'},testID:c,children:[(0,s.jsx)(l.T,{size:17,weight:"semibold",center:!0,children:p?`How many of the ${e} are children?`:`Children in the ${e}`}),(0,s.jsx)(l.Stepper,{value:x,onChange:e=>o(Math.max(0,Math.min(f,e))),min:0,max:f,label:"children",testID:`${c}-stepper`,format:e=>e?String(e):'None'}),h?(0,s.jsx)(l.Muted,{center:!0,children:"Children never pay a deposit."}):null]})},r(d[0]);var e,t=r(d[1]),n=(e=t)&&e.__esModule?e:{default:e},l=r(d[2]),s=r(d[3]);const u=e=>Math.max(0,Math.round(Number(e)||0)-1)},809,[31,128,818,25]);
3
+ __d(function(g,_r,_i,a,_m,_e,_d){"use strict";function e(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(_e,'__esModule',{value:!0}),_e.CustomerDatePicker=function({r:e,today:m,value:D,events:x,onChange:f}){const p=(0,n.ymd)(m),j=(0,r.lastBookableDay)(p,e),[C,w]=(0,t.useState)(!1),[Y,k]=(0,t.useState)((0,i.slashDay)(D)),[I,P]=(0,t.useState)(D);I!==D&&(P(D),k((0,i.slashDay)(D)));const T=new Date(m);T.setHours(12,0,0,0);const $=Array.from({length:b},(e,t)=>{const s=new Date(T);return s.setDate(T.getDate()+t),s}).filter(e=>(0,n.ymd)(e)<=j),v=t=>!!(0,o.hoursFor)(e,t),F=(0,n.parseYmd)(D),[L,M]=(0,t.useState)(()=>({y:F.getFullYear(),m:F.getMonth()})),S=(new Date(L.y,L.m,1,12).getDay()+6)%7,R=new Date(L.y,L.m+1,0).getDate(),A=[...Array.from({length:S},()=>null),...Array.from({length:R},(e,t)=>new Date(L.y,L.m,t+1,12))];for(;A.length%7;)A.push(null);const z=(0,n.parseYmd)(j),W=L.y>m.getFullYear()||L.y===m.getFullYear()&&L.m>m.getMonth(),B=L.y<z.getFullYear()||L.y===z.getFullYear()&&L.m<z.getMonth(),H=e=>M(({y:t,m:s})=>{const l=new Date(t,s+e,1);return{y:l.getFullYear(),m:l.getMonth()}}),_=Y===(0,i.slashDay)(D)?null:(0,r.typedBookDateProblem)(Y,p,e),O=e=>{f(e),w(!1)},G=(e,t)=>0===t?'Today':1===t?'Tomorrow':`${(0,n.dayShort)(e)} ${e.getDate()}`,N=$.some(e=>(0,n.ymd)(e)===D);return(0,h.jsxs)(l.default,{testID:"cust-date",style:{gap:10,alignItems:'center',width:'100%'},children:[(0,h.jsx)(l.default,{accessible:!0,accessibilityLiveRegion:"polite",testID:"cust-date-chosen",children:(0,h.jsx)(d.T,{center:!0,weight:"semibold",colour:c.colours.goldLight,children:`Booking for ${(0,n.niceDateYear)(F)}${v(F)?'':' (closed that day)'}`})}),(0,h.jsxs)(d.Row,{wrap:!0,gap:6,style:{justifyContent:'center'},children:[$.map((e,t)=>{const s=(0,n.ymd)(e),l=x.some(e=>e.date===s);return(0,h.jsx)(d.Chip,{testID:`cust-day-${s}`,label:G(e,t),sub:v(e)?l?'\u2605 event':void 0:'Closed',disabled:!v(e),selected:D===s,accessibilityLabel:`${(0,n.niceDate)(e)}${v(e)?l?', event':'':', closed'}`,onPress:()=>O(s)},s)}),N?null:(0,h.jsx)(d.Chip,{label:(0,n.niceDate)(F),sub:v(F)?void 0:'Closed',selected:!0,onPress:()=>w(!0),accessibilityLabel:`Chosen: ${(0,n.niceDateYear)(F)}. Opens the calendar`})]}),(0,h.jsxs)(l.default,{style:{width:'100%',maxWidth:360,gap:4},children:[(0,h.jsx)(d.Field,{label:"Any other date (DD/MM/YYYY)",testID:"cust-date-typed",value:Y,placeholder:"24/12/2026",keyboardType:"numbers-and-punctuation",maxLength:10,autoCapitalize:"none",autoCorrect:!1,style:{textAlign:'center'},accessibilityLabel:"Booking date, typed as day, month and four-digit year",onChangeText:t=>{const s=(0,i.slashDate)(t,Y);k(s);const l=(0,i.dayFromSlash)(s);l&&!(0,r.typedBookDateProblem)(s,p,e)&&f(l)}}),_&&Y.length>=10?(0,h.jsx)(d.T,{center:!0,size:15,colour:c.colours.amber,testID:"cust-date-problem",children:_}):null]}),(0,h.jsx)(d.Button,{kind:"secondary",label:C?'Hide calendar':'\ud83d\udcc5 Pick a date from a calendar',testID:"cust-date-cal",style:{minHeight:48},accessibilityLabel:C?'Hide the calendar':'Pick a date from a month calendar',onPress:()=>{C||M({y:F.getFullYear(),m:F.getMonth()}),w(!C)}}),C?(0,h.jsxs)(l.default,{testID:"cust-calendar",style:{borderWidth:1,borderColor:c.colours.border,borderRadius:14,padding:10,gap:6,backgroundColor:c.colours.surface2,width:'100%',maxWidth:420},children:[(0,h.jsx)(l.default,{style:{alignItems:'flex-end'},children:(0,h.jsx)(u.GoldClose,{label:"Close the calendar",testID:"cust-calendar-close",onPress:()=>w(!1),size:"sm"})}),(0,h.jsxs)(d.Row,{style:{justifyContent:'space-between',alignItems:'center'},children:[(0,h.jsx)(s.default,{accessibilityRole:"button",accessibilityLabel:"Previous month",accessibilityState:{disabled:!W},disabled:!W,onPress:()=>H(-1),style:{minWidth:48,minHeight:48,alignItems:'center',justifyContent:'center',opacity:W?1:.3},children:(0,h.jsx)(d.T,{size:22,colour:c.colours.gold,children:"\u2039"})}),(0,h.jsxs)(d.T,{center:!0,weight:"semibold",accessibilityRole:"header",children:[(0,n.monthLong)(L.m)," ",L.y]}),(0,h.jsx)(s.default,{accessibilityRole:"button",accessibilityLabel:"Next month",accessibilityState:{disabled:!B},disabled:!B,onPress:()=>H(1),style:{minWidth:48,minHeight:48,alignItems:'center',justifyContent:'center',opacity:B?1:.3},children:(0,h.jsx)(d.T,{size:22,colour:c.colours.gold,children:"\u203a"})})]}),(0,h.jsx)(l.default,{style:{flexDirection:'row'},importantForAccessibility:"no-hide-descendants",children:y.map(e=>(0,h.jsx)(d.T,{size:12,colour:c.colours.muted,center:!0,style:{flex:1},children:e},e))}),Array.from({length:A.length/7},(e,t)=>(0,h.jsx)(l.default,{style:{flexDirection:'row',gap:4},children:A.slice(7*t,7*t+7).map((e,t)=>{if(!e)return(0,h.jsx)(l.default,{style:{flex:1,height:44}},t);const o=(0,n.ymd)(e),i=o<p||o>j,r=o===D,u=!v(e);return(0,h.jsx)(s.default,{testID:`cust-cal-${o}`,accessibilityRole:"button",accessibilityLabel:`${(0,n.niceDateYear)(e)}${i?', not bookable online':u?', closed':''}`,accessibilityState:{disabled:i||u,selected:r},disabled:i||u,onPress:()=>O(o),style:{flex:1,height:44,borderRadius:10,alignItems:'center',justifyContent:'center',borderWidth:o===p?1.5:0,borderColor:c.colours.gold,backgroundColor:r?c.colours.gold:'transparent',opacity:i?.3:1},children:(0,h.jsx)(d.T,{size:15,center:!0,weight:r?'bold':'regular',colour:r?c.colours.onGold:u?c.colours.muted:c.colours.text,style:u&&!i?{textDecorationLine:'line-through'}:void 0,children:e.getDate()})},t)})},t)),(0,h.jsxs)(d.Muted,{center:!0,children:["Crossed-out days: closed. ",(0,r.bookAheadUnlimited)(e)?`You can book up to ${(0,i.slashDay)(j)}.`:`Online booking is open up to ${(0,i.slashDay)(j)}.`]})]}):null]})};var t=_r(_d[0]),s=e(_r(_d[1])),l=e(_r(_d[2])),o=_r(_d[3]),n=_r(_d[4]),i=_r(_d[5]),r=_r(_d[6]),c=_r(_d[7]),d=_r(_d[8]),u=_r(_d[9]),h=_r(_d[10]);const y=['Mon','Tue','Wed','Thu','Fri','Sat','Sun'],b=14},810,[31,264,128,833,822,834,811,825,818,835,25]);
4
+ __d(function(g,_r,i,a,_m,e,_d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"SERVER_MAX_DAYS_AHEAD",{enumerable:!0,get:function(){return n}}),e.bookAheadDays=r,Object.defineProperty(e,"bookAheadUnlimited",{enumerable:!0,get:function(){return o}}),Object.defineProperty(e,"lastBookableDay",{enumerable:!0,get:function(){return u}}),e.typedBookDateProblem=function(n,r,o){const s=(n??'').trim();if(!s)return'Type a date as DD/MM/YYYY, for example 24/12/2026.';const l=(0,t.dayFromSlash)(s);if(!l)return'That isn\u2019t a date yet. Type it as DD/MM/YYYY, for example 24/12/2026.';if(l<r)return'That date has passed. Pick today or a later date.';const c=u(r,o);if(l>c){const[t,n,r]=c.split('-');return`Online booking is open up to ${r}/${n}/${t}. For later dates, please call us.`}return null};var t=_r(_d[0]);const n=366;function r(t){const r=Number(t?.settings?.onlineBookDaysAhead);return Number.isFinite(r)&&r>=1?Math.min(Math.round(r),n):n}const o=t=>r(t)>=n,s=(t,n)=>{const r=new Date(t+'T12:00:00Z');return r.setUTCDate(r.getUTCDate()+n),r.toISOString().slice(0,10)},u=(t,n)=>s(t,r(n))},811,[834]);
abbotsford/chef-app/_expo/static/js/web/demo-bb0072f641fdd92aa99cba5bc91fc36d.js ADDED
@@ -0,0 +1 @@
 
 
1
+ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return c}});var t=r(d[0]);r(d[1]);var n=r(d[2]),u=r(d[3]);function c(){return(0,u.jsx)(t.Redirect,{href:n.ENTRY[n.APP_VARIANT]})}},794,[805,31,807,25]);
abbotsford/chef-app/_expo/static/js/web/feedback-e234bfa389c6fd89a2e9f35bd3515c4d.js ADDED
@@ -0,0 +1 @@
 
 
1
+ __d(function(g,_r,i,_a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return c}});var t=_r(d[0]),a=_r(d[1]),s=_r(d[2]),n=_r(d[3]),r=_r(d[4]),o=_r(d[5]),l=_r(d[6]);const u=['Food','Service','Takeaway','Booking','Allergens','Something else'];function c(){const{rid:c,token:h,optout:p}=(0,t.useLocalSearchParams)(),b=(0,r.useRestaurant)(c),v=(0,r.useCustomer)(),[j,x]=(0,a.useState)(0),[y,w]=(0,a.useState)('Food'),[f,S]=(0,a.useState)(''),[k,C]=(0,a.useState)(!1),[P,R]=(0,a.useState)(!1);return b?'string'==typeof p&&p?(0,l.jsx)(s.Screen,{title:"Review emails",subtitle:b.name,children:(0,l.jsx)(s.Card,{children:(0,l.jsx)(o.ReviewOptOut,{token:p})})}):'string'==typeof h&&h?(0,l.jsx)(s.Screen,{title:"Your review",subtitle:b.name,children:(0,l.jsx)(s.Card,{children:(0,l.jsx)(o.ReviewForm,{rid:b.id,venueName:b.name,token:h})})}):(0,l.jsxs)(s.Screen,{title:"Private feedback",subtitle:`Straight to the team at ${b.name}`,children:[P?(0,l.jsxs)(s.Banner,{kind:"success",title:"Thank you",children:["Your feedback went privately to ",b.name,". It is never published.",k?' They may reply by email (demo: nothing is sent).':'']}):null,P?(0,l.jsx)(s.Button,{kind:"secondary",label:"Send more feedback",onPress:()=>{R(!1),x(0),S('')}}):(0,l.jsxs)(s.Card,{children:[(0,l.jsx)(s.H2,{children:"How did we do?"}),(0,l.jsx)(n.Stars,{value:j,onChange:x}),(0,l.jsx)(s.T,{size:14,children:"What's it about?"}),(0,l.jsx)(s.Row,{wrap:!0,gap:6,children:u.map(t=>(0,l.jsx)(s.Chip,{label:t,selected:y===t,onPress:()=>w(t)},t))}),(0,l.jsx)(s.Field,{label:"Tell us more (optional)",value:f,onChangeText:S,multiline:!0,placeholder:"What went well, what could be better?"}),(0,l.jsx)(s.Chip,{label:k?'\u2713 Happy to be contacted':'Happy to be contacted?',selected:k,onPress:()=>C(!k)}),(0,l.jsx)(s.Button,{label:"Send privately",disabled:!j,onPress:()=>{r.repo.feedback.add({restaurantId:b.id,customerId:v.id,customerName:v.name,stars:j,comment:`${y}: ${f.trim()}${k?` (happy to be contacted: ${v.email})`:''}`,context:`App feedback \xb7 ${y}`}),R(!0)}})]}),(0,l.jsx)(s.Muted,{children:"Every rating, from 1 to 5 stars, goes the same way: privately to the restaurant. We never ask only happy guests to post a public review, and stamps or rewards are never given for reviews. A public review uses the link from your visit."}),(0,l.jsx)(o.ReviewsSection,{rid:b.id,mode:"read",venueName:b.name})]}):(0,l.jsx)(s.Screen,{title:"Not found",children:(0,l.jsx)(s.T,{children:"Restaurant not found."})})}},780,[805,31,818,840,823,841,25]);
abbotsford/chef-app/_expo/static/js/web/gift-791c64f5dbcb5e9b9629af9241dde456.js ADDED
@@ -0,0 +1 @@
 
 
1
+ __d(function(_g,_r,i,_a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return x}});var t=_r(d[0]),a=_r(d[1]),n=_r(d[2]),s=_r(d[3]),r=_r(d[4]),l=_r(d[5]),o=_r(d[6]),u=_r(d[7]),c=_r(d[8]),h=_r(d[9]),b=_r(d[10]);function x(){const{rid:n}=(0,a.useLocalSearchParams)(),s=(0,o.useRestaurant)(n);(0,o.useCustomer)();return t.LIVE_VENUE_BUILD||(0,h.guestServer)()?s?(0,b.jsx)(c.GiftLive,{slug:n,venue:s.name}):(0,b.jsx)(r.Screen,{title:"Not found",children:(0,b.jsx)(r.T,{children:"Restaurant not found."})}):(0,b.jsx)(f,{})}function f(){const{rid:t}=(0,a.useLocalSearchParams)(),c=(0,o.useRestaurant)(t),h=(0,o.useGiftCards)(t),[x,f]=(0,n.useState)(5e3),[j,p]=(0,n.useState)(''),[g,y]=(0,n.useState)(''),[C,S]=(0,n.useState)(''),[v,w]=(0,n.useState)(!1),[P,T]=(0,n.useState)(null);if(!c)return(0,b.jsx)(r.Screen,{title:"Not found",children:(0,b.jsx)(r.T,{children:"Restaurant not found."})});const B=j?Math.round(100*Number(j))||0:x;return(0,b.jsxs)(r.Screen,{title:"Gift cards",subtitle:`${c.name} \u2014 redeemable only at ${c.name}`,children:[P?(0,b.jsx)(r.Banner,{kind:"success",title:`Gift card created \u2014 ${(0,l.gbp)(P.initial)}`,children:`Code ${P.code}. In production it would be emailed or sent in-app to ${P.recipientName||'the recipient'} (nothing sent in this demo).`}):null,(0,b.jsxs)(r.Card,{children:[(0,b.jsx)(r.H2,{children:"Your gift cards"}),h.length?h.map(t=>(0,b.jsxs)(r.Row,{style:{justifyContent:'space-between'},children:[(0,b.jsx)(r.T,{style:{flex:1},children:t.code}),(0,b.jsxs)(r.T,{weight:"semibold",colour:u.colours.gold,children:[(0,l.gbp)(t.balance)," of ",(0,l.gbp)(t.initial)]})]},t.id)):(0,b.jsx)(r.Muted,{children:"None yet."}),(0,b.jsx)(r.Muted,{children:"Balances can be used at checkout on takeaway orders and table bills. Part-use leaves a balance."})]}),(0,b.jsxs)(r.Card,{children:[(0,b.jsx)(r.H2,{children:"Buy a gift card"}),(0,b.jsx)(r.Row,{wrap:!0,children:[1e3,2500,5e3,15e3].map(t=>(0,b.jsx)(r.Chip,{label:(0,l.gbp)(t),selected:!j&&x===t,onPress:()=>{p(''),f(t)}},t))}),(0,b.jsx)(r.Field,{label:"Or another amount (\xa3)",keyboardType:"decimal-pad",value:j,onChangeText:p,placeholder:"e.g. 40"}),(0,b.jsx)(r.Field,{label:"Recipient\u2019s name",value:g,onChangeText:y}),(0,b.jsx)(r.Field,{label:"Message",value:C,onChangeText:S,multiline:!0,placeholder:"Happy birthday!"}),(0,b.jsx)(r.Muted,{children:"Valid for 24 months from purchase (suggested terms \u2014 to be confirmed by the restaurant)."}),(0,b.jsx)(r.Button,{label:`Buy ${(0,l.gbp)(B)} gift card`,disabled:B<500||B>5e4,onPress:()=>w(!0)})]}),(0,b.jsx)(s.MockPay,{visible:v,onClose:()=>w(!1),amount:B,restaurantId:c.id,allowGiftCard:!1,title:"Buy gift card",onPaid:async()=>{const t=await o.repo.giftCards.purchase(c.id,B,g,C);w(!1),T(t)}})]})}},781,[842,805,31,843,818,820,823,825,844,845,25]);
abbotsford/chef-app/_expo/static/js/web/index-0a34312c3724df867c229ae4363d5bf9.js ADDED
@@ -0,0 +1,15 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ __d(function(g,_r,_i,_a,_m,_e,_d){"use strict";function e(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(_e,'__esModule',{value:!0}),Object.defineProperty(_e,"default",{enumerable:!0,get:function(){return H}});var t=e(_r(_d[0])),l=_r(_d[1]),a=_r(_d[2]),s=_r(_d[3]),n=e(_r(_d[4])),o=e(_r(_d[5])),r=e(_r(_d[6])),i=_r(_d[7]),d=_r(_d[8]),u=_r(_d[9]),c=e(u);_r(_d[10]);var h=e(_r(_d[11])),b=e(_r(_d[12])),f=_r(_d[13]),p=_r(_d[14]),m=_r(_d[15]),y=_r(_d[16]),x=_r(_d[17]),j=_r(_d[18]),k=_r(_d[19]),w=_r(_d[20]),S=_r(_d[21]),T=_r(_d[22]),I=_r(_d[23]),O=_r(_d[24]),R=_r(_d[25]),A=_r(_d[26]),B=_r(_d[27]),P=_r(_d[28]),C=_r(_d[29]),_=_r(_d[30]),N=_r(_d[31]),v=_r(_d[32]);const M=['book','takeaway'].includes(C.START_GO??'')?C.START_GO:null;let $=!1,E=!1,L=!1;const D=[{id:'main',label:'Main menu'},{id:'specials',label:'Specials'},{id:'takeaway',label:'Takeaway'}];function H(){const{rid:e}=(0,d.useLocalSearchParams)(),i=(0,k.useRestaurant)(e),u=a.IS_QUEUED_VENUE?(0,v.jsx)(t.default,{}):a.IS_ABBOTSFORD?(0,v.jsx)(o.default,{}):a.IS_KIRKTON?(0,v.jsx)(r.default,{}):a.IS_GREENSIDE?(0,v.jsx)(n.default,{}):l.IsolatedCustomerHome&&(a.IS_WILDINGS||a.IS_KIRKMICHAEL||a.IS_SOUTERS)?(0,v.jsx)(l.IsolatedCustomerHome,{}):(0,v.jsx)(K,{});return a.IS_ABBOTSFORD||a.IS_KIRKTON||a.IS_WILDINGS||!i?.settings.hotel?.enabled?u:(0,v.jsx)(s.HotelRequestGate,{rid:e,hotel:i.settings.hotel,children:u})}function K(){const{rid:e}=(0,d.useLocalSearchParams)(),t=(0,k.useRestaurant)(e),l=(0,k.useMenu)(e),a=(0,k.useCustomer)(),s=(0,k.useBasket)(),n=(0,k.useStore)(e=>e.startBasket),o=(0,k.useNow)(3e4),[r,H]=(0,u.useState)('All'),[K,W]=(0,u.useState)(null),[G,F]=(0,u.useState)(!1),[U,V]=(0,u.useState)(!1),[Q,Y]=(0,u.useState)('takeaway'===M?'takeaway':'main');c.default.useEffect(()=>{M&&!$&&($=!0,'book'===M?setTimeout(()=>d.router.push(`/customer/${e}/book`),0):setTimeout(()=>{try{document.querySelector('[data-testid="menu-tabs"]')?.scrollIntoView({block:'start'})}catch{}},400))},[e]);const q=(0,B.useSpecials)(t=>t.current[e]??null),z=!!q&&(0,P.isToday)(q.postedAt,o),J=(0,R.useOwner)(e=>e.offers.filter(e=>e.live).length),X=(0,k.useStore)(t=>t.stampCards.find(l=>l.restaurantId===e&&l.customerId===t.customer.id)),Z=(0,_.useLiveTile)(e),ee=(0,N.guestServer)();c.default.useEffect(()=>{C.START_TABLE_TOKEN&&!L&&(L=!0,setTimeout(()=>d.router.push(`/table/live/${C.START_TABLE_TOKEN}`),0))},[e]),c.default.useEffect(()=>{C.START_LOYALTY_CODE&&!E&&(E=!0,setTimeout(()=>d.router.push(`/customer/${e}/loyalty`),0))},[e]);const te=(0,k.useOrderAtTable)(e),le=(0,w.useTakeawayMenu)(t=>t.byVenue[e]);if(c.default.useEffect(()=>{te||s.restaurantId!==e||'table'!==s.mode||k.useStore.setState(e=>({basket:{...e.basket,mode:'takeaway',tableNo:void 0}}))},[te,s.mode,s.restaurantId,e]),!t)return(0,v.jsx)(m.Screen,{title:"Not found",children:(0,v.jsx)(m.T,{children:"Restaurant not found."})});const ae=te&&s.restaurantId===t.id&&'table'===s.mode,se=t.sections.length?t.sections:Array.from(new Set(l.map(e=>e.section))),ne=e=>ae||t.fictional?e.signOff&&null!==e.price?e.soldOut?'sold-out':'on':'off':(0,w.takeawayAvail)(e,le),oe=l.filter(e=>!('All'!==r&&e.section!==r||'takeaway'===Q&&'off'===ne(e))),re=(0,j.hoursFor)(t,o),ie=e=>()=>d.router.push(`/customer/${t.id}${e}`),de=[{icon:'box',label:'Takeaway',sub:'Order to collect',on:()=>{H('All'),Y('takeaway'),ae&&n(t.id,'takeaway')}},...te?[{icon:'phone',label:'Order at table',sub:'Scan the QR',on:()=>V(!0)}]:[],{icon:'calendarPlus',label:'Book a table',on:ie('/book')},{icon:'clock',label:'Waitlist',sub:'Walk in',on:ie('/waitlist')},{icon:'star',label:'Stamp card',sub:ee?Z.stamps:`${X?.stamps??0} of ${t.settings.stampTarget}`,on:ie('/loyalty')},{icon:'userPlus',label:'Bring a friend',on:ie('/refer')},{icon:'gift',label:'Gift cards',on:ie('/gift')},{icon:'alert',label:'My allergens',sub:a.allergies.length?`${a.allergies.length} declared`:'None declared',on:()=>d.router.push('/customer/profile')},{icon:'tag',label:'Offers',sub:ee?void 0:a.marketingOptIn[t.id]?'Opted in':'Opt in',on:ie('/offers'),badge:(ee?Z.offers:J)?String(ee?Z.offers:J):void 0},{icon:'sparkle',label:"What's on",on:ie('/whatson')},{icon:'chat',label:'Feedback',sub:'Private',on:ie('/feedback')},{icon:'star',label:'Reviews',sub:'Published',on:ie('/feedback')},{icon:'hanger',label:'Lost property',on:ie('/lost')},{icon:'bag',label:'Shop',sub:'Merch',on:ie('/merch')}];return(0,v.jsxs)(m.Screen,{title:t.name,subtitle:`${t.location}${t.phone?` \xb7 ${t.phone}`:''}`,back:'customer'!==O.APP_VARIANT,right:(0,v.jsxs)(m.Row,{children:[(0,v.jsx)(p.BasketButton,{}),(0,v.jsx)(m.Button,{small:!0,kind:"ghost",label:"Account",onPress:()=>d.router.push('/customer/profile')})]}),children:[t.fictional?(0,v.jsx)(m.Banner,{kind:"warn",title:"Fictional demo restaurant",children:"Shown only to demonstrate multi-restaurant support."}):null,ae?(0,v.jsx)(m.Banner,{kind:"success",title:`Ordering at ${(0,i.tableNumbers)(s.tableNo)}`,children:"Your order goes straight to the kitchen. Pay and split the bill from your order page. A member of staff is always available \u2014 tap \u201cCall staff\u201d any time."}):(0,v.jsx)(m.Card,{children:(0,v.jsxs)(m.Row,{style:{justifyContent:'space-between'},children:[(0,v.jsxs)(b.default,{style:{flex:1},children:[(0,v.jsx)(m.T,{weight:"semibold",children:"Takeaway \u2014 collection"}),(0,v.jsxs)(m.Muted,{children:[re?`Kitchen today ${(0,j.kitchenHoursOn)(t,o)[0]}\u2013${(0,j.kitchenHoursOn)(t,o)[1]}`:'Kitchen closed today',t.settings.takeawayPaused?' \xb7 slots paused by the restaurant':'']})]}),(0,v.jsx)(m.Badge,{kind:t.settings.takeawayPaused||!re?'amber':'ok',label:t.settings.takeawayPaused?'Paused':re?'Taking orders':'Closed'})]})}),t.fictional?(0,v.jsx)(m.Row,{wrap:!0,gap:8,children:de.slice(2,7).map(e=>(0,v.jsx)(m.Button,{small:!0,kind:"secondary",label:e.label,onPress:e.on},e.label))}):(0,v.jsx)(b.default,{style:{flexDirection:'row',flexWrap:'wrap',gap:8},children:de.map(e=>(0,v.jsx)(T.HubTile,{icon:e.icon,label:e.label,sub:e.sub,badge:e.badge,onPress:e.on},e.label))}),ae?(0,v.jsx)(m.Button,{small:!0,kind:"danger",label:"Call staff",onPress:()=>F(!0)}):null,G?(0,v.jsx)(m.Banner,{kind:"success",children:"We've told the staff on this device. Calling staff: not set up yet."}):null,t.hoursNote?(0,v.jsx)(m.Muted,{children:t.hoursNote}):null,t.fictional?null:(0,v.jsx)(m.AllergenNotice,{phone:t.phone}),(0,v.jsxs)(m.Muted,{children:["Menu dishes and prices from ",t.name,"\u2019s menu. Items marked \u26a0 conflict with your declared allergies."]}),(0,v.jsx)(b.default,{accessibilityRole:"tablist",testID:"menu-tabs",style:{flexDirection:'row',flexWrap:'wrap',justifyContent:'center',gap:6,backgroundColor:S.colours.surface,borderRadius:14,borderWidth:1,borderColor:S.colours.border,padding:4},children:D.map(e=>{const t=Q===e.id;return(0,v.jsxs)(h.default,{testID:`menu-tab-${e.id}`,accessibilityRole:"tab",accessibilityState:{selected:t},"aria-selected":t,accessibilityLabel:'specials'===e.id&&z?'Specials, updated today':e.label,onPress:()=>Y(e.id),style:{flex:1,minWidth:120,flexBasis:120,minHeight:44,borderRadius:10,alignItems:'center',justifyContent:'center',paddingHorizontal:4,backgroundColor:t?S.colours.gold:'transparent'},children:[(0,v.jsx)(m.T,{size:14,weight:"semibold",colour:t?S.colours.onGold:S.colours.text,center:!0,children:e.label}),'specials'===e.id&&z&&!t?(0,v.jsx)(b.default,{style:{position:'absolute',top:6,right:8,width:7,height:7,borderRadius:4,backgroundColor:S.colours.gold}}):null]},e.id)})}),'specials'===Q?(0,v.jsx)(A.SpecialsTab,{rid:t.id,declared:a.allergies,now:o}):null,'takeaway'===Q?(0,v.jsx)(m.Muted,{children:"Order to collect. Only dishes available to order online are shown; pick a collection slot at checkout."}):null,'specials'!==Q?(0,v.jsxs)(m.Row,{wrap:!0,gap:6,children:[(0,v.jsx)(m.Chip,{label:"All",selected:'All'===r,onPress:()=>H('All')}),se.map(e=>(0,v.jsx)(m.Chip,{label:e,selected:r===e,onPress:()=>H(e)},e))]}):null,'takeaway'!==Q||oe.length?null:(0,v.jsx)(m.Muted,{children:le||t.fictional?'Nothing is on the takeaway menu right now. Please ring the restaurant.':'Loading the takeaway menu\u2026'}),'specials'!==Q?se.filter(e=>('All'===r||e===r)&&oe.some(t=>t.section===e)).map(e=>(0,v.jsxs)(b.default,{style:{gap:10},children:[(0,v.jsx)(m.H2,{style:{color:S.colours.gold,marginTop:6},children:e}),oe.filter(t=>t.section===e).map(e=>{const l=(0,y.conflictsFor)(e.allergens,a.allergies),o=ne(e),r='on'!==o,i=e.soldOut||'sold-out'===o;return(0,v.jsxs)(m.Card,{highlight:l.contains.length?S.colours.red:l.may.length?S.colours.amber:void 0,children:[(0,v.jsxs)(h.default,{accessibilityRole:"button",onPress:()=>{r?W(K===e.id?null:e.id):(s.restaurantId&&s.restaurantId===t.id||n(t.id,'takeaway'),d.router.push(`/customer/${t.id}/dish/${e.id}`))},children:[(0,v.jsxs)(m.Row,{style:{justifyContent:'space-between',alignItems:'flex-start'},children:[(0,v.jsx)(m.T,{center:!0,weight:"semibold",style:{width:'100%',flexBasis:'100%',paddingRight:8},children:e.name}),(0,v.jsx)(m.T,{weight:"semibold",colour:S.colours.gold,children:null===e.price?e.priceNote??'\u2014':(0,x.gbp)(e.price)})]}),(0,v.jsx)(m.Muted,{numberOfLines:2,children:e.description})]}),(0,v.jsxs)(m.Row,{wrap:!0,gap:6,children:[e.dietary.map(e=>(0,v.jsx)(m.Badge,{kind:"ok",label:e},e)),e.special?(0,v.jsx)(m.Badge,{kind:"gold",label:"Special"}):null,i?(0,v.jsx)(m.Badge,{kind:"neutral",label:"Sold out"}):null,e.signOff?null:(0,v.jsx)(m.Badge,{kind:"amber",label:"Awaiting allergen sign-off"}),l.contains.length?(0,v.jsx)(m.Badge,{kind:"red",label:"\u26a0 Contains your allergen"}):l.may.length?(0,v.jsx)(m.Badge,{kind:"amber",label:"\u26a0 May contain your allergen"}):null]}),(0,v.jsx)(f.AllergenChips,{map:e.allergens,declared:a.allergies,signedOff:!!e.signOff}),K===e.id?(0,v.jsx)(f.AllergenPanel,{item:e,map:e.allergens,declared:a.allergies}):null,(0,v.jsxs)(m.Row,{gap:8,children:[(0,v.jsx)(m.Button,{small:!0,kind:"ghost",label:K===e.id?'Hide allergen panel':'Allergen panel',onPress:()=>W(K===e.id?null:e.id)}),(0,v.jsx)(b.default,{style:{flex:1}}),(0,v.jsx)(m.Button,{small:!0,label:r?i?'Sold out':e.signOff&&null!==e.price?'Not on the takeaway menu':'Not available online':'Choose',disabled:r,onPress:()=>{s.restaurantId&&s.restaurantId===t.id||n(t.id,'takeaway'),d.router.push(`/customer/${t.id}/dish/${e.id}`)}})]})]},e.id)})]},e)):null,(0,v.jsx)(I.ReviewsSection,{rid:t.id,mode:"read",venueName:t.name}),(0,v.jsx)(m.Muted,{children:"Drinks list coming soon. Ask your server for today\u2019s drinks."}),(0,v.jsx)(m.Muted,{children:"Card payments: not set up yet. Pay at the till as usual."}),(0,v.jsx)(T.LauncherLine,{}),te?(0,v.jsxs)(m.Sheet,{visible:U,onClose:()=>V(!1),title:"Order at your table",children:[(0,v.jsx)(m.Muted,{children:"Scan the QR code on your table with your phone camera, or pick your table number."}),(0,v.jsx)(m.Row,{wrap:!0,gap:6,children:Array.from({length:12},(e,t)=>String(t+1)).map(e=>(0,v.jsx)(m.Button,{small:!0,kind:"secondary",label:`${(0,i.tableNumbers)(e)}`,onPress:()=>{V(!1),n(t.id,'table',e)}},e))}),(0,v.jsx)(m.Muted,{children:"Orders go straight to the kitchen. Card payments: not set up yet. Pay at the till as usual."})]}):null]})}},782,[846,853,5,854,855,856,859,812,805,31,123,264,128,837,838,818,819,820,833,823,836,825,860,841,807,861,862,863,864,865,866,845,25]);
2
+ __d(function(g,_r,i,a,m,_e,d){"use strict";Object.defineProperty(_e,'__esModule',{value:!0}),Object.defineProperty(_e,"default",{enumerable:!0,get:function(){return f}});var e,n=_r(d[0]),t=_r(d[1]),s=(e=t)&&e.__esModule?e:{default:e},r=_r(d[2]),o=_r(d[3]),u=_r(d[4]),l=_r(d[5]),c=_r(d[6]),h=_r(d[7]),j=_r(d[8]),x=_r(d[9]),b=_r(d[10]);function f(){const e=j.VENUE_RID,t=x.queuedVenues[e],f=(0,h.useRestaurant)(e)??(0,x.queuedRestaurant)(e),[p,k]=(0,n.useState)(!1),y=f.kitchenSessionsByDay;return(0,b.jsxs)(r.Screen,{title:t.name,back:!1,children:[(0,b.jsx)(o.RestaurantHero,{rid:e,size:240}),p?(0,b.jsx)(l.NativeRequestSetup,{rid:e,kind:"table",sessionHours:y,onClose:()=>k(!1)}):(0,b.jsxs)(b.Fragment,{children:[(0,b.jsx)(r.Button,{testID:`${e}-book-table`,label:"Book a table",onPress:()=>k(!0)}),t.phone?(0,b.jsx)(r.Button,{kind:"secondary",label:`Call ${t.phone}`,onPress:()=>{s.default.openURL('tel:'+t.phone.replace(/[^0-9+]/g,''))}}):null,(0,b.jsx)(r.Muted,{children:"Send a table request for this venue\u2019s managers to confirm. This is not an instant booking. No deposit or payment is taken. No emails or texts are sent by this app."}),(0,b.jsxs)(r.Card,{children:[(0,b.jsx)(r.H2,{children:"Kitchen and venue hours"}),(0,b.jsx)(r.T,{children:t.hours.note})]}),t.clockArea.on?(0,b.jsx)(u.FindPub,{rid:e}):(0,b.jsxs)(r.Muted,{children:["Find us: ",t.address,". Precise map location to confirm."]}),(0,b.jsx)(c.QueuedMenus,{menu:t.menu,context:t.menuServiceContext,allergens:t.allergenCaveat}),(0,b.jsxs)(r.Banner,{kind:"warn",title:"To confirm",children:[t.gatesToConfirm.join(', '),"."]}),(0,b.jsx)(r.Muted,{children:"Ordering, takeaway, delivery and loyalty: to set up. Deposits are blank and off."})]})]})}},846,[31,240,818,867,847,848,852,823,5,6,25]);
3
+ __d(function(g,r,i,a,m,_e,d){"use strict";function e(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(_e,'__esModule',{value:!0}),_e.FindPub=function({rid:e}){const p=(0,l.pubLocation)(e),[b,y]=(0,n.useState)(!1),[f,x]=(0,n.useState)(!1),[j,w]=(0,n.useState)(null),[I,v]=(0,n.useState)(null);if(!p)return null;const D=async()=>{y(!1),x(!0),v(null);const e=await(0,u.getFix)();x(!1),'object'==typeof e?(w(Math.round((0,c.distanceM)(p,e))),v(null)):(w(null),v('Your location was not shared. You can still use the address and open directions.'))};return(0,h.jsx)(o.Card,{children:(0,h.jsxs)(t.default,{testID:"find-pub",style:{gap:10},children:[(0,h.jsx)(o.T,{accessibilityRole:"header",weight:"bold",children:"Find us"}),(0,h.jsx)(o.T,{children:p.address}),(0,h.jsx)(o.Muted,{children:"See your approximate distance, or open directions. Location is optional and is never saved."}),(0,h.jsx)(o.Button,{testID:"find-pub-distance",label:f?'Finding your distance\u2026':'Find us \u2014 show my distance',accessibilityLabel:`Find ${p.name}, show my distance using my location once`,disabled:f,onPress:()=>y(!0)}),(0,h.jsxs)(t.default,{accessibilityLiveRegion:"polite",testID:"find-pub-result",children:[null!=j?(0,h.jsxs)(o.T,{children:["About ",j<1e3?`${j} m`:`${(j/1e3).toFixed(1)} km`," away, in a straight line."]}):null,I?(0,h.jsx)(o.T,{children:I}):null]}),(0,h.jsx)(o.Button,{testID:"find-pub-directions",kind:"secondary",label:"Open directions in Maps",accessibilityLabel:`Open directions to ${p.name}, ${p.address}, without sharing my location with CoverCharge`,onPress:()=>{s.default.openURL(`https://www.google.com/maps/dir/?api=1&destination=${encodeURIComponent(p.address)}`)}}),(0,h.jsx)(o.Sheet,{visible:b,onClose:()=>y(!1),title:"Use your location for distance?",testID:"find-pub-reason",children:(0,h.jsxs)(t.default,{style:{gap:12},children:[(0,h.jsxs)(o.T,{children:["We use your phone\u2019s location once to estimate how far you are from ",p.name,". Your position stays on this screen only: it is not stored or sent to the pub."]}),(0,h.jsx)(o.T,{children:"You can refuse location and still see the address and use directions."}),(0,h.jsx)(o.Button,{testID:"find-pub-allow",label:"Use my location once",onPress:()=>{D()}}),(0,h.jsx)(o.Button,{testID:"find-pub-cancel",kind:"secondary",label:"Not now \u2014 keep the address",onPress:()=>y(!1)})]})})]})})};var n=r(d[0]),s=e(r(d[1])),t=e(r(d[2])),o=r(d[3]),l=r(d[4]),c=r(d[5]),u=r(d[6]),h=r(d[7])},847,[31,240,128,818,868,869,870,25]);
4
+ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),e.NativeRequestSetup=function(l){const[h,p]=(0,u.useState)(null);return(0,u.useEffect)(()=>{let u=!0;p(null);const s=(0,t.isQueuedVenue)(l.rid),o=s?'queued_venue_request_setup_ready':'kirkton'===l.rid?'kirkton_request_setup_ready':'abbotsford_request_setup_ready';return(0,n.getSupabase)().rpc(o,s?{p_slug:(0,t.queuedDatabaseSlug)(l.rid)}:void 0).then(({data:t,error:n})=>{u&&p(!n&&!0===t)},()=>{u&&p(!1)}),()=>{u=!1}},[l.rid,l.kind]),!0===h?(0,c.jsx)(o.VenueRequestForm,{...l}):(0,c.jsxs)(s.Card,{children:[(0,c.jsx)(s.H2,{children:null===h?'Checking booking setup\u2026':'Manager setup needed'}),(0,c.jsx)(s.Muted,{children:null===h?'Checking whether requests are ready.':(0,t.isQueuedVenue)(l.rid)?'An authorised manager must complete setup and confirm current kitchen hours before requests can be sent.':'kirkton'===l.rid?'An authorised manager must complete setup and confirm current kitchen hours before table requests can be sent. Contact details are to confirm.':'An authorised hotel manager must complete setup before requests can be sent.'}),(0,c.jsx)(s.Button,{kind:"secondary",label:"Back to Customer home",onPress:l.onClose})]})};var t=r(d[0]),u=r(d[1]),n=r(d[2]),s=r(d[3]),o=r(d[4]),c=r(d[5])},848,[6,31,871,818,849,25]);
5
+ __d(function(g,_r,i,a,m,_e,d){"use strict";Object.defineProperty(_e,'__esModule',{value:!0}),_e.VenueRequestForm=function({rid:e,kind:u,hotel:h,allDayHours:q,sessionHours:T,onClose:D}){const[f,v]=(0,l.useState)({name:'',phone:'',email:'',notes:'',date:(0,b.localDate)(),service:(0,t.isQueuedVenue)(e)||'greenside'===e?void 0:'Lunch',time:q||'greenside'===e?'10:00':'12:00',covers:2,checkIn:(0,b.localDate)(),checkOut:'',roomType:h?.roomTypes[0]?.id,guests:2,addDinner:!1}),C=e=>v(t=>({...t,...e})),[I,S]=(0,l.useState)(''),[w,B]=(0,l.useState)(''),[P,R]=(0,l.useState)(null),[Y,M]=(0,l.useState)(''),[N,$]=(0,l.useState)(!1),[L,V]=(0,l.useState)(!1),z=(0,l.useRef)(!1);(0,l.useEffect)(()=>{let s=!0;return(0,x.requestChallenge)(e,u).then(e=>{s&&R(e)}).catch(n=>{s&&M((0,t.isQueuedVenue)(e)||['greenside','kirkton'].includes(e)?(0,x.requestMessage)(n).replace(/the hotel/g,'the restaurant'):(0,x.requestMessage)(n))}),()=>{s=!1}},[e,u]);const F=async()=>{if(z.current)return;const s=(0,t.isQueuedVenue)(e)?(0,n.queuedRequestError)(e,f,T):q&&'table'===u?(0,o.allDayRequestError)(f,q):(0,r.errorForVenue)(e,u,f,h);if(s)M(s);else if(P&&I.trim()){z.current=!0,V(!0),M('');try{await(0,x.sendVenueRequest)(e,u,f,P.id,I,w),$(!0)}catch(s){M((0,t.isQueuedVenue)(e)||['greenside','kirkton'].includes(e)?(0,x.requestMessage)(s).replace(/the hotel/g,'the restaurant'):(0,x.requestMessage)(s))}finally{z.current=!1,V(!1)}}else M('Complete the security check.')},H={minHeight:48,fontSize:18,color:p.colours.text};return(0,k.jsxs)(c.default,{testID:`venue-${u}-form`,style:{gap:16,alignItems:'stretch'},children:[(0,k.jsx)(y.H2,{children:'table'===u?'Book a table':'Book a room'}),(0,k.jsx)(y.T,{size:18,center:!0,children:'greenside'===e?'No payment is taken for this request. Deposit terms to confirm. This is a request, not an instant confirmation.':'No deposit. No payment. This is a request, not an instant confirmation.'}),N?(0,k.jsx)(y.Banner,{kind:"info",title:'greenside'===e?'Request sent. A Greenside manager must confirm your table.':h?.enabled?'Request sent. The hotel will contact you to confirm.':'Request sent. The venue will contact you to confirm.',children:"Nothing has been charged. No email or text is sent by this app."}):(0,k.jsxs)(k.Fragment,{children:['table'===u?(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(j,{label:"Date (DD/MM/YYYY)",testID:"request-date",...(0,s.slashBox)(f.date,e=>C({date:e})),placeholder:"20/11/2026",keyboardType:"numbers-and-punctuation",maxLength:10,style:H}),(0,t.isQueuedVenue)(e)||'greenside'===e||q?null:(0,k.jsx)(y.Row,{wrap:!0,children:['Lunch','Dinner'].map(e=>(0,k.jsx)(y.Button,{testID:`request-service-${e.toLowerCase()}`,label:e+(f.service===e?' \xb7 selected':''),kind:f.service===e?'primary':'secondary',onPress:()=>C({service:e,time:'Lunch'===e?'12:00':'18:00'}),style:{alignSelf:'auto'}},e))}),(0,k.jsx)(y.T,{size:18,weight:"semibold",center:!0,children:"Time within kitchen hours"}),(0,k.jsx)(y.Row,{wrap:!0,children:((0,t.isQueuedVenue)(e)?(0,n.queuedRequestSlots)(e,f.date||'',T):q?(0,o.allDaySlots)(f.date||'',q):(0,r.slotsForVenue)(e,f.date||'',f.service||'Lunch')).map(e=>(0,k.jsx)(y.Button,{testID:`request-time-${e.replace(':','')}`,label:e+(f.time===e?' \xb7 selected':''),kind:f.time===e?'primary':'secondary',onPress:()=>C({time:e}),style:{alignSelf:'auto'}},e))}),(0,k.jsx)(j,{label:"Covers",testID:"request-covers",keyboardType:"number-pad",value:String(f.covers??''),onChangeText:e=>C({covers:Number(e)}),style:H})]}):(0,k.jsxs)(k.Fragment,{children:[(0,k.jsxs)(y.T,{size:18,center:!0,children:[null==h?.bedrooms?'':`${h.bedrooms} bedrooms. `,h?.priceNote,"."]}),(0,k.jsx)(j,{label:"Check-in date (DD/MM/YYYY)",testID:"request-check-in",...(0,s.slashBox)(f.checkIn,e=>C({checkIn:e})),placeholder:"20/11/2026",keyboardType:"numbers-and-punctuation",maxLength:10,style:H}),(0,k.jsx)(j,{label:"Check-out date (DD/MM/YYYY)",testID:"request-check-out",...(0,s.slashBox)(f.checkOut,e=>C({checkOut:e})),placeholder:"21/11/2026",keyboardType:"numbers-and-punctuation",maxLength:10,style:H}),(0,k.jsx)(y.T,{size:18,weight:"semibold",center:!0,children:"Room type"}),h?.roomTypes.map(e=>(0,k.jsx)(y.Button,{testID:`request-room-${e.id}`,label:`${e.name} \xb7 ${null==e.pricePence?'Price to confirm with the hotel':`${e.from?'from ':''}\xa3${e.pricePence/100}`} \xb7 ${h.breakfast}${f.roomType===e.id?' \xb7 selected':''}`,kind:f.roomType===e.id?'primary':'secondary',onPress:()=>C({roomType:e.id})},e.id)),(0,k.jsx)(j,{label:"Guests",testID:"request-guests",keyboardType:"number-pad",value:String(f.guests??''),onChangeText:e=>C({guests:Number(e)}),style:H}),(0,k.jsx)(y.Button,{testID:"request-add-dinner",label:"Add dinner \xb7 "+(f.addDinner?'Yes':'No'),kind:f.addDinner?'primary':'secondary',onPress:()=>C({addDinner:!f.addDinner})}),(0,k.jsx)(y.T,{size:18,center:!0,children:"The hotel will arrange dinner details with you."})]}),(0,k.jsx)(j,{label:"Name",testID:"request-name",autoComplete:"name",value:f.name,onChangeText:e=>C({name:e}),style:H}),(0,k.jsx)(j,{label:"Phone",testID:"request-phone",keyboardType:"phone-pad",autoComplete:"tel",value:f.phone,onChangeText:e=>C({phone:e}),style:H}),(0,k.jsx)(j,{label:"Email",testID:"request-email",keyboardType:"email-address",autoCapitalize:"none",autoComplete:"email",value:f.email,onChangeText:e=>C({email:e}),style:H}),(0,k.jsx)(j,{label:'table'===u?'Notes (allergies, occasion)':'Notes',testID:"request-notes",multiline:!0,maxLength:2e3,value:f.notes,onChangeText:e=>C({notes:e}),style:H}),(0,k.jsx)(c.default,{style:{display:'none'},accessibilityElementsHidden:!0,importantForAccessibility:"no-hide-descendants",children:(0,k.jsx)(j,{label:"Leave this empty",value:w,onChangeText:B})}),P?(0,k.jsx)(j,{label:`Security check: ${P.question} = ?`,testID:"request-answer",keyboardType:"number-pad",value:I,onChangeText:S,style:H}):(0,k.jsx)(y.T,{size:18,center:!0,children:"Preparing security check\u2026"}),Y?(0,k.jsx)(y.Banner,{kind:"warn",title:"Please check your request",children:Y}):null,(0,k.jsx)(y.Button,{testID:"request-submit",label:L?'Sending request\u2026':'Send request',disabled:L||!P,onPress:()=>{F()}})]}),(0,k.jsx)(y.Button,{kind:"secondary",label:N?'greenside'===e?'Back to the restaurant':h?.enabled?'Back to the hotel':'Back to Customer home':'Back to Customer home',onPress:D})]})};var e,t=_r(d[0]),s=_r(d[1]),n=_r(d[2]),r=_r(d[3]),o=_r(d[4]),l=_r(d[5]),u=_r(d[6]),c=(e=u)&&e.__esModule?e:{default:e},h=_r(d[7]),y=_r(d[8]),p=_r(d[9]),b=_r(d[10]),x=_r(d[11]),k=_r(d[12]);function j({label:e,...t}){return(0,k.jsxs)(c.default,{style:{gap:6,alignSelf:'stretch',width:'100%'},children:[(0,k.jsx)(y.T,{size:18,weight:"semibold",center:!0,children:e}),(0,k.jsx)(h.TextInput,{accessibilityLabel:e,placeholderTextColor:p.colours.muted,...t,style:[{minHeight:48,fontSize:18,color:p.colours.text,backgroundColor:p.colours.surface2,borderWidth:1,borderColor:p.colours.border,borderRadius:12,padding:12},t.multiline?{minHeight:96,textAlignVertical:'top'}:null,t.style]})]})}},849,[6,834,872,850,851,31,128,873,818,825,11,874,25]);
6
+ __d(function(g,r,_i,a,m,e,_d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),e.greensideSlots=o,e.greensideRequestError=i,Object.defineProperty(e,"slotsForVenue",{enumerable:!0,get:function(){return s}}),Object.defineProperty(e,"errorForVenue",{enumerable:!0,get:function(){return u}});var t=r(_d[0]),n=r(_d[1]);function o(n){if(!/^\d{4}-\d{2}-\d{2}$/.test(n))return[];const o=new Date(n+'T12:00:00Z');if(!Number.isFinite(+o)||o.toISOString().slice(0,10)!==n)return[];const i=t.GREENSIDE_KITCHEN_HOURS[o.getUTCDay()];if(!i)return[];const s=t=>60*Number(t.slice(0,2))+Number(t.slice(3)),u=s(i[0]),l=s(i[1]);return Array.from({length:Math.floor((l-u)/15)+1},(t,n)=>{const o=u+15*n;return`${String(Math.floor(o/60)).padStart(2,'0')}:${String(o%60).padStart(2,'0')}`})}function i(t,i,s=new Date){if('table'!==t)return'Only table requests are available at this restaurant.';if(i.name.trim().length<2||i.name.trim().length>100||!/^[0-9 +()\-]{7,30}$/.test(i.phone)||!/^[0-9]{7,15}$/.test(i.phone.replace(/\D/g,''))||i.email.length>254||!/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(i.email))return'Enter your name, phone number and email.';if(i.notes.length>2e3)return'Keep notes under 2000 characters.';const u=(0,n.localDate)(s),l=(0,n.localDate)(new Date(+s+63072e6));if(!i.date||i.date<u||i.date>l||!o(i.date).includes(i.time||''))return'Choose an open date and a time within kitchen hours. Closed Monday and Tuesday.';const d=new Intl.DateTimeFormat('en-GB',{timeZone:'Europe/London',hour:'2-digit',minute:'2-digit',hour12:!1}).format(s);return i.date===u&&(i.time||'')<=d?'Choose a future time within kitchen hours.':!Number.isInteger(i.covers)||i.covers<1||i.covers>200?'Enter 1 to 200 Covers.':''}const s=(t,i,s)=>'greenside'===t?o(i):(0,n.requestSlots)(i,s),u=(t,o,s,u,l=new Date)=>'greenside'===t?i(o,s,l):(0,n.requestError)(o,s,u,l)},850,[4,11]);
7
+ __d(function(g,r,_i,_a,m,e,_d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),e.allDaySlots=n,e.allDayRequestError=function(i,o,a=new Date){if(i.name.trim().length<2||i.name.trim().length>100||!/^[0-9 +()\-]{7,30}$/.test(i.phone)||!/^[0-9]{7,15}$/.test(i.phone.replace(/\D/g,''))||i.email.length>254||!/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(i.email))return'Enter your name, phone number and email.';if(i.notes.length>2e3)return'Keep notes under 2000 characters.';const s=(0,t.localDate)(a),u=(0,t.localDate)(new Date(+a+63072e6));if(!i.date||i.date<s||i.date>u||!n(i.date,o).includes(i.time||''))return'Choose a future date and a time within the published hours, which are to confirm.';const l=new Intl.DateTimeFormat('en-GB',{timeZone:'Europe/London',hour:'2-digit',minute:'2-digit',hour12:!1}).format(a);return i.date===s&&(i.time||'')<=l?'Choose a future time within the published hours.':!Number.isInteger(i.covers)||i.covers<1||i.covers>200?'Enter 1 to 200 Covers.':''};var t=r(_d[0]);function n(t,n){if(!/^\d{4}-\d{2}-\d{2}$/.test(t))return[];const i=new Date(t+'T12:00:00Z');if(!Number.isFinite(+i)||i.toISOString().slice(0,10)!==t)return[];const o=n[i.getUTCDay()];if(!Array.isArray(o)||2!==o.length||!o.every(t=>'string'==typeof t&&/^([01]\d|2[0-3]):[0-5]\d$/.test(t)))return[];const a=t=>60*+t.slice(0,2)+ +t.slice(3),s=a(o[0]),u=a(o[1]);return!Number.isFinite(s)||!Number.isFinite(u)||s>u?[]:Array.from({length:Math.floor((u-s)/15)+1},(t,n)=>{const i=s+15*n;return`${String(Math.floor(i/60)).padStart(2,'0')}:${String(i%60).padStart(2,'0')}`})}},851,[11]);
8
+ __d(function(g,r,_i,_a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),e.QueuedMenus=function({menu:c,context:o,allergens:a}){const u=c,f=(0,n.useMemo)(()=>t(c),[c]),[p,b]=(0,n.useState)(null);return(0,s.jsxs)(i.Card,{children:[(0,s.jsx)(i.H2,{children:"Published menus"}),(0,s.jsx)(i.Banner,{kind:"warn",title:"Menu \u2014 to confirm",children:"Published reference only. Current prices, availability and allergens need confirmation. Items cannot be ordered here."}),o?(0,s.jsx)(i.Muted,{children:o}):null,a?(0,s.jsx)(i.Muted,{children:a}):(0,s.jsx)(i.Muted,{children:"Ask the restaurant about every allergy. Published dietary labels are not an allergen guarantee."}),u.offers?.map((n,t)=>(0,s.jsxs)(i.Muted,{children:["Published offer \u2014 ",n.name,'number'==typeof n.priceGbp?` \xb7 \xa3${n.priceGbp.toFixed(2)}`:'',": ",n.when||'Terms to confirm',". To confirm."]},'offer'+t)),u.buffetSessionPrices?.sessions?.map((n,t)=>(0,s.jsxs)(i.Muted,{children:[n.label,": \xa3",n.price.toFixed(2)," \xb7 to confirm"]},'session'+t)),u.buffetSessionPrices?.kids?(0,s.jsxs)(i.Muted,{children:["Published children\u2019s prices \u2014 ",u.buffetSessionPrices.kids,". To confirm."]}):null,f.map((n,t)=>(0,s.jsx)(i.Button,{kind:"secondary",label:n.name+(p===t?' \xb7 selected':''),onPress:()=>b(p===t?null:t)},t)),null!==p?f[p]?.items.map((n,t)=>(0,s.jsxs)(i.Card,{children:[(0,s.jsx)(i.T,{weight:"bold",children:n.name||n.label||'Published item'}),(0,s.jsx)(i.T,{children:l(n)}),n.description||n.desc?(0,s.jsx)(i.Muted,{children:n.description||n.desc}):null,n.options?.map((n,t)=>(0,s.jsxs)(i.Muted,{children:[n.name||n.label,": ",l(n)]},t))]},t)):null]})};var n=r(d[0]),i=r(d[1]),s=r(d[2]);function t(n,i=""){if(Array.isArray(n))return n.flatMap(n=>t(n,i));if(!n||'object'!=typeof n)return[];const s=n,l='string'==typeof s.name?s.name:'string'==typeof s.label?s.label:i;return(Array.isArray(s.items)?[{name:[i,l].filter((n,i,s)=>n&&s.indexOf(n)===i).join(' \xb7 ')||'Published menu',items:s.items}]:[]).concat(Object.entries(s).filter(([n])=>'items'!==n&&'options'!==n).flatMap(([,n])=>t(n,l||i)))}const l=n=>'included_in_buffet'===n.priceType?'Included in buffet \xb7 session price to confirm':n.priceLabel||('number'==typeof(n.priceGbp??n.price)?`\xa3${(n.priceGbp??n.price).toFixed(2)}`:'Price to confirm')},852,[31,818,25]);
9
+ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"IsolatedCustomerHome",{enumerable:!0,get:function(){return t}});const t=null},853,[]);
10
+ __d(function(g,r,i,a,m,_e,d){"use strict";Object.defineProperty(_e,'__esModule',{value:!0}),_e.HotelRequestGate=function({rid:e,hotel:l,children:c}){const[h,f]=(0,t.useState)(!1);return l?.enabled?(0,u.jsxs)(o.default,{style:{flex:1},children:[c,(0,u.jsx)(o.default,{style:{padding:12},children:(0,u.jsx)(s.Button,{label:"Book a room",onPress:()=>f(!0)})}),(0,u.jsx)(s.Sheet,{visible:h,onClose:()=>f(!1),title:"Room request",children:(0,u.jsx)(n.VenueRequestForm,{rid:e,kind:"room",hotel:l,onClose:()=>f(!1)})})]}):(0,u.jsx)(u.Fragment,{children:c})};var e,t=r(d[0]),l=r(d[1]),o=(e=l)&&e.__esModule?e:{default:e},s=r(d[2]),n=r(d[3]),u=r(d[4])},854,[31,128,818,849,25]);
11
+ __d(function(g,r,i,a,m,_e,d){"use strict";Object.defineProperty(_e,'__esModule',{value:!0}),Object.defineProperty(_e,"default",{enumerable:!0,get:function(){return x}});var e,n=r(d[0]),s=r(d[1]),t=(e=s)&&e.__esModule?e:{default:e},o=r(d[2]),l=r(d[3]),u=r(d[4]),c=r(d[5]),h=r(d[6]),b=r(d[7]),j=r(d[8]);function x(){const[e,s]=(0,n.useState)(!1),[x,p]=(0,n.useState)(null);return(0,n.useEffect)(()=>{if(!e)return;let n=!0;return p(null),(0,o.getSupabase)().rpc('greenside_request_setup_ready').then(({data:e,error:s})=>{n&&p(!s&&!0===e)},()=>{n&&p(!1)}),()=>{n=!1}},[e]),(0,j.jsxs)(l.Screen,{title:b.GREENSIDE_RESTAURANT.name,back:!1,children:[(0,j.jsx)(u.RestaurantHero,{rid:"greenside",size:240}),e?!0===x?(0,j.jsx)(h.VenueRequestForm,{rid:"greenside",kind:"table",onClose:()=>s(!1)}):(0,j.jsxs)(l.Card,{children:[(0,j.jsx)(l.H2,{children:null===x?'Checking booking setup\u2026':'Manager setup needed'}),(0,j.jsx)(l.Muted,{children:null===x?'Checking whether table requests are ready.':'An authorised manager must complete setup before table requests can be sent. Please call 01655 889685.'}),(0,j.jsx)(l.Button,{label:"Call 01655 889685",kind:"secondary",onPress:()=>{t.default.openURL(b.GREENSIDE_BOOKING_PHONE)}}),(0,j.jsx)(l.Button,{label:"Back to Customer home",kind:"secondary",onPress:()=>s(!1)})]}):(0,j.jsxs)(j.Fragment,{children:[(0,j.jsx)(l.T,{center:!0,children:"Bar, restaurant and wood-fired pizza"}),(0,j.jsxs)(l.Row,{wrap:!0,children:[(0,j.jsx)(l.Button,{testID:"greenside-book-table",label:"Book a table",onPress:()=>s(!0)}),(0,j.jsx)(l.Button,{testID:"greenside-book-phone",kind:"secondary",label:"Call 01655 889685",onPress:()=>{t.default.openURL(b.GREENSIDE_BOOKING_PHONE)}})]}),(0,j.jsx)(l.Muted,{children:"Send a table request for a Greenside manager to confirm. This is not an instant booking. No deposit, payment, email or text is taken or sent by this app."}),(0,j.jsxs)(l.Card,{children:[(0,j.jsx)(l.H2,{children:"Kitchen hours"}),(0,j.jsx)(l.T,{children:"Wednesday, Thursday and Sunday: 10:00\u201320:00"}),(0,j.jsx)(l.T,{children:"Friday and Saturday: 10:00\u201321:00"}),(0,j.jsx)(l.T,{children:"Closed Monday and Tuesday"}),(0,j.jsx)(l.H2,{children:"Venue hours"}),(0,j.jsx)(l.T,{children:"Wednesday and Thursday: 10:00\u201323:00"}),(0,j.jsx)(l.T,{children:"Friday to Sunday: 10:00\u201300:00"}),(0,j.jsx)(l.T,{children:"Cash only"})]}),(0,j.jsx)(c.FindPub,{rid:"greenside"}),(0,j.jsx)(l.Banner,{kind:"warn",title:"Menus \u2014 unconfirmed",children:"The published menus, prices, availability and allergens need confirmation. Ask the restaurant about every allergy. No menu items are available to order here."}),(0,j.jsx)(l.Muted,{children:"Deposit policy needs confirmation. Deposits are off. The public email address needs confirmation."}),(0,j.jsx)(l.Button,{kind:"secondary",label:"View published menus on our website",onPress:()=>{t.default.openURL('https://thegreensiderestaurant.co.uk/menus/')}})]})]})}},855,[31,240,871,818,867,847,849,4,25]);
12
+ __d(function(g,r,i,a,m,_e,d){"use strict";Object.defineProperty(_e,'__esModule',{value:!0}),Object.defineProperty(_e,"default",{enumerable:!0,get:function(){return j}});var e,o=r(d[0]),t=r(d[1]),n=(e=t)&&e.__esModule?e:{default:e},l=r(d[2]),s=r(d[3]),c=r(d[4]),u=r(d[5]),h=r(d[6]),b=r(d[7]),f=r(d[8]);function j(){const[e,t]=(0,o.useState)(null);return(0,f.jsxs)(l.Screen,{title:"The Abbotsford Hotel",back:!1,children:[(0,f.jsx)(c.RestaurantHero,{rid:"abbotsford",size:240}),(0,f.jsx)(l.T,{center:!0,children:"Epicurious restaurant \xb7 The Copper Bar"}),(0,f.jsx)(l.T,{children:"14 Corsehill Road, Ayr KA7 2ST"}),(0,f.jsx)(l.T,{children:"Daily 10:00\u201320:30 \u2014 to confirm. Copper Bar hours to confirm."}),(0,f.jsxs)(l.Card,{children:[(0,f.jsx)(l.H2,{children:"Book with the hotel"}),(0,f.jsx)(l.T,{children:"Table and room requests go to the hotel managers to confirm. They are not instant bookings or a guarantee of availability. No payment or deposit."}),(0,f.jsx)(l.Button,{label:"Book a table",onPress:()=>t('table')}),(0,f.jsx)(l.Button,{label:"Book a room",onPress:()=>t('room')}),(0,f.jsx)(l.Muted,{children:"Rooms: Prices to confirm with the hotel. Room details and inclusions need confirmation."})]}),(0,f.jsx)(b.AbbotsfordMenus,{}),(0,f.jsx)(s.FindPub,{rid:"abbotsford"}),(0,f.jsxs)(l.Card,{children:[(0,f.jsx)(l.H2,{children:"Contact the hotel"}),(0,f.jsx)(l.Button,{kind:"secondary",label:"Call 01292 261506",onPress:()=>{n.default.openURL('tel:01292261506')}}),(0,f.jsx)(l.T,{children:"info@abbotsfordhotel.co.uk"})]}),(0,f.jsx)(l.Banner,{kind:"info",title:"Details to confirm",children:"Covers and table plan, deposit, Copper Bar hours, dog policy and allergens are still to confirm."}),(0,f.jsx)(l.Sheet,{visible:!!e,onClose:()=>t(null),title:'room'===e?'Book a room':'Book a table',children:e?(0,f.jsx)(u.NativeRequestSetup,{rid:"abbotsford",kind:e,hotel:h.ABBOTSFORD_HOTEL,allDayHours:h.ABBOTSFORD_HOURS,onClose:()=>t(null)}):null})]})}},856,[31,240,818,847,867,848,8,857,25]);
13
+ __d(function(g,r,i,a,_m,_e,d){"use strict";function e(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(_e,'__esModule',{value:!0}),_e.AbbotsfordMenus=function(){const[e,t]=(0,n.useState)(null),h=o.find(n=>n.id===e);return(0,c.jsxs)(s.default,{testID:"abbotsford-menus",style:{gap:12},children:[(0,c.jsxs)(l.Card,{children:[(0,c.jsx)(l.H2,{children:"Menus"}),(0,c.jsx)(l.T,{children:"Published menus for reference. Confirm availability, current prices and allergens with the team. No ordering is available here."}),(0,c.jsx)(l.T,{children:"Allergens: please speak to staff. Published dietary marks are not a complete allergen check."}),o.map(n=>(0,c.jsx)(l.Button,{kind:n.id===e?'primary':'secondary',label:`${n.name}${n.id===e?' \xb7 selected':''}`,onPress:()=>t(n.id)},n.id))]}),h?(0,c.jsxs)(s.default,{style:{gap:12},children:[(0,c.jsx)(l.H2,{children:h.name}),h.when?(0,c.jsx)(l.Muted,{children:h.when}):null,h.note?(0,c.jsx)(l.T,{children:h.note}):null,h.categories.map((e,n)=>(0,c.jsxs)(s.default,{style:{gap:10},children:[(0,c.jsx)(l.H2,{children:e.name}),e.note?(0,c.jsx)(l.T,{children:e.note}):null,e.items.map((e,n)=>(0,c.jsx)(l.Card,{children:(0,c.jsxs)(s.default,{style:{gap:8},children:[(0,c.jsxs)(l.Row,{wrap:!0,children:[(0,c.jsx)(l.T,{size:18,weight:"semibold",style:{flex:1},children:e.name}),(0,c.jsx)(l.T,{children:'number'==typeof e.price?u(e.price):'Price to confirm'})]}),e.description?(0,c.jsx)(l.T,{children:e.description}):null,e.note?(0,c.jsx)(l.T,{children:e.note}):null,e.priceOptions?.length?(0,c.jsxs)(l.T,{children:["Published price options: ",e.priceOptions.map(u).join(' / ')]}):null,'number'==typeof e.sharedPrice?(0,c.jsxs)(l.T,{children:["Published group price: ",u(e.sharedPrice)," \u2014 confirm with staff"]}):null,e.dietary?.length?(0,c.jsxs)(l.Muted,{children:["Published marks: ",e.dietary.join(', '),". Ask staff about allergens."]}):null]})},n))]},n))]}):null]})};var n=r(d[0]),s=e(r(d[1])),l=r(d[2]),t=e(r(d[3])),c=r(d[4]);const o=t.default.menus,u=e=>new Intl.NumberFormat('en-GB',{style:'currency',currency:'GBP'}).format(e)},857,[31,128,818,858,25]);
14
+ __d(function(e,i,a,r,n,t,o){n.exports={currency:"GBP",note:"Parsed with pdftotext. Do not invent dishes. Menus subject to change. Dietary codes from a la carte: GF, GFA, V, VV.",menus:[{id:"breakfast",name:"Breakfast \u2014 Morning Edition",when:"Breakfast service; Morning Deals Monday\u2013Friday",sourcePdf:"raw/menu-breakfast.pdf",sourceUrl:"https://www.abbotsfordhotel.co.uk/wp-content/uploads/2026/10/Abbotsford-Breakfast-Menu-1.pdf",categories:[{name:"Morning Deals (Monday\u2013Friday)",items:[{name:"Rolling Report",description:"Morning roll with choice of 2 fillings: Ayrshire Bacon, Pork Link Sausage, Potato Scone or Egg, plus filter tea or coffee",price:6.5,dietary:[]},{name:"The Full Feature",description:"The Abbotsford Breakfast plus fruit juice and filter tea or coffee",price:15,dietary:[]}]},{name:"The Epicurious Express",items:[{name:"The Abbotsford Breakfast",description:"Ayrshire bacon, link sausage, black pudding, haggis, potato scone, beans, tomato, mushrooms and two eggs (poached, scrambled or fried) with white or wholemeal toasted bloomer",price:11.95,dietary:[]},{name:"Light Breakfast",description:"Ayrshire bacon, link sausage, beans, tomato and two eggs with white or wholemeal toasted bloomer",price:9.5,dietary:[]},{name:"Vegetarian Breakfast",description:"Potato scone, tomato, mushrooms, beans and two eggs with white or wholemeal toasted bloomer",price:9.5,dietary:["V"]},{name:"Breakfast Roll",description:"Choice of Ayrshire bacon, pork link sausage, potato scone or egg; 2 items 4.50 | 3 items 5.50",price:3.95,dietary:[]},{name:"Eggs Benedict",description:"Two poached eggs with Ayrshire bacon on toasted muffin, hollandaise",price:10.95,dietary:[]},{name:"Eggs Royale",description:"Two poached eggs with flaked smoked salmon on toasted muffin, hollandaise",price:11.45,dietary:[]},{name:"Smashed Avocado Benedict",description:"Smashed avocado guacamole, two poached eggs on toasted muffin, hollandaise",price:10.95,dietary:["V"]},{name:"Pancake Stack",description:"American-style pancakes with Biscoff, Nutella, chocolate sauce and fresh strawberries",price:9.95,dietary:["V"]},{name:"French Toast",description:"Two slices of bloomer eggy bread with Ayrshire bacon and maple syrup",price:10.95,dietary:[]},{name:"The Morning Stack",description:"American-style pancakes with Ayrshire bacon and maple syrup; add two eggs 2.00",price:9.95,dietary:[]},{name:"Granola Bowl",description:"Almond and raisin granola topped with berries, natural yoghurt and honey",price:8.95,dietary:["V"]},{name:"Brunch \xc0 La Tina",description:"Wholemeal toasted bloomer, smashed avocado, grilled Bonnet goats cheese, smoked salmon, fried free-range egg and balsamic glaze",price:12.5,dietary:[]}]},{name:"Little Legends Ledger (Kids)",items:[{name:"Kids Breakfast",description:"Pork link sausage, beans, potato scone, slice of toast",price:5.95,dietary:[]},{name:"Kids Pancakes",description:"American-style pancakes with syrup, Nutella or butter and jam; add banana or strawberries 1.50",price:5.95,dietary:[]}]},{name:"Extras Desk",items:[{name:"Black Pudding",description:null,price:1.5,dietary:[]},{name:"Pork Link Sausage",description:null,price:1.5,dietary:[]},{name:"Ayrshire Bacon (2)",description:null,price:1.5,dietary:[]},{name:"Smashed Avocado",description:null,price:2,dietary:[]},{name:"Haggis",description:null,price:1.5,dietary:[]},{name:"Mushrooms",description:null,price:1.5,dietary:[]},{name:"Beans",description:null,price:1,dietary:[]},{name:"Tomato",description:null,price:1,dietary:[]},{name:"Egg",description:null,price:1,dietary:[]},{name:"Potato Scone",description:null,price:1,dietary:[]},{name:"Bucket of Chips",description:null,price:4.25,dietary:[]},{name:"Toasted White or Wholemeal Bread",description:"Served with butter and preserve",price:4.5,dietary:[]}]},{name:"Treat Tales",items:[{name:"Scone with butter, jam and hot drink",description:"9am\u201312noon offer",price:4.5,dietary:[]},{name:"Scones, Traybakes and Cakes",description:"From 2.50, available all day",price:2.5,dietary:[],note:"Price 'from' as printed"}]},{name:"Coffee",items:[{name:"Latte",description:null,price:3.75,dietary:[]},{name:"Espresso",description:null,price:3.25,dietary:[]},{name:"Cappuccino",description:null,price:3.75,dietary:[]},{name:"Americano",description:null,price:3.5,dietary:[]},{name:"Double Espresso",description:null,price:3.75,dietary:[]},{name:"Macchiato",description:null,price:3.75,dietary:[]},{name:"Espresso Con Panna",description:null,price:3.75,dietary:[]},{name:"Flavour Shot",description:null,price:.75,dietary:[]},{name:"Extra Shot of Coffee",description:null,price:.75,dietary:[]}]},{name:"Tea and Hot Chocolate",items:[{name:"Breakfast Tea",description:null,price:3.5,dietary:[]},{name:"Camomile Tea",description:null,price:3.5,dietary:[]},{name:"Earl Grey Tea",description:null,price:3.5,dietary:[]},{name:"Green Tea",description:null,price:3.5,dietary:[]},{name:"Peppermint Tea",description:null,price:3.5,dietary:[]},{name:"Red Berry Tea",description:null,price:3.5,dietary:[]},{name:"Lemon and Ginger Tea",description:null,price:3.5,dietary:[]},{name:"Hot Chocolate",description:null,price:3.95,dietary:[]},{name:"Luxury Hot Chocolate",description:"With cream and marshmallows",price:4.95,dietary:[]}]}]},{id:"alacarte",name:"\xc0 La Carte \u2014 Epicurious",when:"Sept 2026 menu; sandwiches 12noon\u20134pm",sourcePdf:"raw/menu-alacarte.pdf",sourceUrl:"https://www.abbotsfordhotel.co.uk/wp-content/uploads/2026/09/Sept-2026-NEW-Menu-Abbotsford-A-La-Carte.pdf",categories:[{name:"The Birch Wine Board",items:[{name:"The Birch Wine Board",description:"Charred halloumi, roasted cauliflower, cured meats, chicken liver parfait, chutney, Scottish cheese, pickled onions, gherkins and fresh seasonal vegetables",price:19.95,dietary:[]}]},{name:"Starters",items:[{name:"Haggis Scotch Egg",description:"Smoked turnip veloute, Arran mustard and crispy leeks",price:10.95,dietary:[]},{name:"Traditional Cullen Skink",description:"With crusty ciabatta bread",price:10.95,dietary:["GFA"]},{name:"Chef's Soup of the Day",description:"With freshly baked bread",price:6.5,dietary:["GFA","VV"]},{name:"Moules Marini\xe8re",description:"Shetland mussels, white wine and garlic cream with garlic ciabatta",price:12.95,dietary:["GFA"]},{name:"Chicken Liver and Brandy Parfait",description:"Red onion chutney and bannocks",price:9.5,dietary:["GFA"]},{name:"Sweet Chilli and Soy Glazed Pork Belly Bites",description:"Chilli mint yogurt and pickled cucumber ribbons",price:10.5,dietary:["GFA"]},{name:"Fruit Platter",description:"Duo of melon, seasonal berries, passionfruit sorbet and raspberry coulis",price:9.95,dietary:["GF","VV"]}]},{name:"Sandwiches",note:"Served 12noon\u20134pm. White or malted bloomer with tortilla chips, house salad and coleslaw. GF on request. Add soup 3.95 | chips 4.50",items:[{name:"Tuna Mayonnaise",description:null,price:10.95,dietary:[]},{name:"Ploughman's",description:null,price:11.95,dietary:[]},{name:"Coronation Chicken",description:null,price:10.95,dietary:[]},{name:"Chicken and Bacon Club",description:null,price:12.95,dietary:[]}]},{name:"Burgers",note:"Toasted brioche, house slaw and hand-cut chips",items:[{name:"6oz Homemade Abbotsford Burger",description:"Burger sauce, pickles, tomato and baby gem; add cheese/blue cheese/bacon 1.50",price:16.95,dietary:[]},{name:"Abbotsford Spiced Buttermilk Chicken Burger",description:"BBQ pulled beef, garlic mayonnaise, pickles, tomato and baby gem",price:18.95,dietary:[]},{name:"The Burns Burger",description:"6oz Scotch beef, haggis, tattie scone, smoked Arran cheddar and peppercorn sauce",price:18.95,dietary:[]},{name:"Moving Mountains Burger",description:"Plant-based patty, lettuce, tomato, red onion and vegan garlic mayonnaise",price:16.95,dietary:["VV"]}]},{name:"From the Grill",note:"Flat-cap mushrooms, grilled plum tomato, fries and onion rings (GFA). Sauce 2.50: peppercorn | garlic butter | red wine jus",items:[{name:"8 oz Fillet Steak",description:null,price:38.95,dietary:["GFA"]},{name:"10 oz Sirloin Steak",description:null,price:35.95,dietary:["GFA"]}]},{name:"Mains",items:[{name:"Cajun Spiced Breast of Chicken",description:"Rice pilaf, proven\xe7al vegetables, coconut curry cream and spiced onions",price:null,dietary:["GFA"],note:"Printed 14.50 // 18.50",priceOptions:[14.5,18.5]},{name:"Confit Pork Belly",description:"Chorizo creamed potatoes, black pudding bon bons, beer-braised onion and mustard jus",price:21.95,dietary:[]},{name:"Individual Steak and Ale Pie",description:"Creamed potatoes, roasted carrot, tenderstem broccoli and red wine jus",price:19.95,dietary:[]},{name:"Trio of Seafood",description:"Chef's catch of the day, potato fondant, buttered greens and white wine chive cream",price:23.95,dietary:["GF"]},{name:"Beer Battered Haddock",description:"Pickled onion, mushy peas, tartare, fries and lemon",price:null,dietary:["GFA"],note:"Printed 13.45 // 18.50",priceOptions:[13.45,18.5]},{name:"Wild Mushroom Stroganoff",description:"Pilaf rice and tempura gherkins",price:null,dietary:["V"],note:"Printed 13.95 // 17.95",priceOptions:[13.95,17.95]}]},{name:"Sides",note:"All sides vegetarian; ask for GF",items:[{name:"Onion Rings",description:null,price:4,dietary:["V"]},{name:"House Slaw",description:null,price:4,dietary:["V"]},{name:"Creamed Potatoes",description:null,price:5,dietary:["V"]},{name:"House Salad",description:null,price:4,dietary:["V"]},{name:"Hand Cut Chips",description:null,price:4.5,dietary:["V"]},{name:"Sweet Potato Wedges",description:null,price:5.25,dietary:["V"]},{name:"Chilli and Parmesan Hand Cut Chips",description:null,price:5.25,dietary:["V"]}]},{name:"Desserts",items:[{name:"Sticky Toffee Pudding",description:"Butterscotch sauce and vanilla ice cream",price:8.95,dietary:["V","GF"]},{name:"Passionfruit Martini Panna Cotta",description:"Passionfruit syrup and prosecco sorbet",price:9.95,dietary:["GF"]},{name:"Warm Orange Scented Rice Pudding",description:"Ginger biscuit crumb",price:8.95,dietary:["VV","GF"]},{name:"Cheesecake of the Day",description:"With vanilla ice cream and fresh fruit garnish",price:9.95,dietary:["V"]},{name:"Traditional Tiramisu",description:"Coffee sponge fingers, amaretto mascarpone and dark chocolate powder",price:9.95,dietary:["V"]},{name:"Trio of Scottish Cheeses",description:"Cheese, fig chutney, biscuits and grapes",price:10.95,dietary:["GFA"]}]},{name:"Notes",items:[{name:"Chef's Daily Specials",description:"Ask your server",price:null,dietary:[]},{name:"The Ultimate Sunday Roast",description:"Every Sunday until stock runs out",price:null,dietary:[]}]}]},{id:"kids",name:"Kids \u2014 Abby's Favourites",when:null,sourcePdf:"raw/menu-kids.pdf",sourceUrl:"https://www.abbotsfordhotel.co.uk/wp-content/uploads/2026/02/NEW-Menu-Abbotsford-Kids-Menu.pdf",categories:[{name:"Wee Lamb \xb7 Starters (\xa33)",items:[{name:"Garlic Bread",description:null,price:3,dietary:[]},{name:"Soup of the Day",description:null,price:3,dietary:[]}]},{name:"Rowan Pony \xb7 Mains (\xa37)",note:"Add bacon \xa31 | add cheese \xa31",items:[{name:"Chicken Goujons and Chips",description:null,price:7,dietary:[]},{name:"Cheesy Pasta and Garlic Bread",description:null,price:7,dietary:[]},{name:"Haddock and Chips",description:null,price:7,dietary:[]},{name:"3oz Beef Burger and Chips",description:null,price:7,dietary:[]}]},{name:"Scottie Dog \xb7 Treats (\xa33)",items:[{name:"Sticky Toffee Pudding",description:null,price:3,dietary:[]},{name:"Two Scoops of Ice Cream",description:null,price:3,dietary:[]}]}]},{id:"taco-tuesday",name:"Taco Tuesday",when:"Tuesdays",sourcePdf:"raw/menu-taco-tuesday.pdf",sourceUrl:"https://www.abbotsfordhotel.co.uk/wp-content/uploads/2026/08/Taco-Tuesday-Menu-The-Abbotsford.pdf",categories:[{name:"Tacos",note:"Salad, pickled red onion, pico de gallo, fresh lime. Single \xa35 / Double \xa310",items:[{name:"Crispy Fried Chicken",description:"Sriracha mayo",price:null,dietary:[],note:"Single 5.00 / Double 10.00",priceOptions:[5,10]},{name:"Beef Birria and Cheese",description:"Birria dip",price:null,dietary:[],note:"Single 5.00 / Double 10.00",priceOptions:[5,10]},{name:"Breaded Haddock",description:"Tartare sauce",price:null,dietary:[],note:"Single 5.00 / Double 10.00",priceOptions:[5,10]},{name:"Sweet Potato and Chickpea Falafel",description:"Sriracha mayo",price:null,dietary:["V"],note:"Single 5.00 / Double 10.00",priceOptions:[5,10]}]},{name:"Sides and Extras",items:[{name:"Nachos",description:"Guacamole, pico de gallo, sour cream and cheese",price:5,dietary:[]},{name:"Onion Rings",description:null,price:4,dietary:[]},{name:"Fries",description:null,price:4,dietary:[]},{name:"House Slaw",description:null,price:4,dietary:[]},{name:"Mexican Black Bean and Rice",description:null,price:4,dietary:[]},{name:"Chargrilled Cob",description:null,price:null,dietary:[],note:"Single \xa32 / Double \xa34",priceOptions:[2,4]}]},{name:"Cocktails",items:[{name:"Classic Margarita",description:"Or Spicy | Mango | Passionfruit",price:9.95,dietary:[]}]}]},{id:"bar-bites",name:"Bar Bites",when:"The Copper Bar",sourcePdf:"raw/menu-bar-bites.pdf",sourceUrl:"https://www.abbotsfordhotel.co.uk/wp-content/uploads/2026/08/The-Abbotsford-Bar-Bites.pdf",categories:[{name:"Small Plates (\xa35)",items:[{name:"Ham Hough, Confit Chicken and Apricot Croquette",description:null,price:5,dietary:[]},{name:"Sriracha and Maple Glazed Chicken Goujons",description:null,price:5,dietary:[]},{name:"Goats Cheese, Caramelised Onion and Truffle Oil Arancini",description:null,price:5,dietary:["V"]},{name:"Homemade Sausage Roll",description:"Whole grain mustard, Arran cheddar, apple and walnut ketchup",price:5,dietary:[]}]},{name:"Loaded Fries (\xa38.95)",items:[{name:"Cajun Chicken Loaded Fries",description:"Cajun fries, diced cajun chicken, peppers, onions, cheddar and sriracha mayo",price:8.95,dietary:[]},{name:"Locally Caught Haggis Loaded Fries",description:"Seasoned fries, haggis, cheese and peppercorn sauce",price:8.95,dietary:[]}]},{name:"Sharing Plates",items:[{name:"Nice to Meat You",description:"Cold meats, olives and sun-dried tomatoes",price:10,dietary:[]},{name:"Say Cheese",description:"Scottish cheeses, quince jelly, chutney and oatcakes",price:10,dietary:[]},{name:"Sharing is Caring",description:"Nice to Meat You and Say Cheese combo",price:18,dietary:[]}]}]},{id:"drinks",name:"Drinks \u2014 Social Pours",when:null,sourcePdf:"raw/menu-drinks.pdf",sourceUrl:"https://www.abbotsfordhotel.co.uk/wp-content/uploads/2026/08/The-Abbotsford-Drinks-Menu.pdf",note:"Some cocktail groups share one printed price on the PDF.",categories:[{name:"The Classics",note:"Shared price line 9.95",items:[{name:"Daiquiri",description:"White rum, lime and sugar syrup; Strawberry, Passionfruit or Mango",price:null,dietary:[],sharedPrice:9.95},{name:"Old Fashioned",description:"Bourbon, sugar syrup and orange bitters",price:null,dietary:[],sharedPrice:9.95},{name:"Whisky Sour",description:"Whisky, lemon, sugar syrup, Angostura and egg white",price:null,dietary:[],sharedPrice:9.95},{name:"Margarita",description:"Tequila, lime, sugar syrup and triple sec",price:null,dietary:[],sharedPrice:9.95},{name:"Cosmopolitan",description:"Heroes vodka, cranberry, lime, triple sec and sugar syrup",price:9.95,dietary:[]}]},{name:"Martini Style",items:[{name:"Pornstar Martini",description:"Vanilla vodka, passionfruit, Passoa and pineapple",price:null,dietary:[],sharedPrice:10.95},{name:"French Martini",description:"Heroes vodka, pineapple and Chambord",price:null,dietary:[],sharedPrice:10.95},{name:"Espresso Martini",description:"Heroes vodka, coffee liqueur, sugar syrup and espresso",price:10.95,dietary:[]}]},{name:"That's the Spritz",note:"Shared price 9.95",items:[{name:"Aperol Spritz",description:"Aperol, prosecco and soda",price:null,dietary:[],sharedPrice:9.95},{name:"Hugo Spritz",description:"Elderflower liqueur, prosecco and soda",price:null,dietary:[],sharedPrice:9.95},{name:"Limoncello Spritz",description:"Limoncello, prosecco and lemonade",price:null,dietary:[],sharedPrice:9.95},{name:"Pink Gin Spritz",description:"Pink gin, prosecco and lemonade",price:9.95,dietary:[]}]},{name:"Hangover Free (Mocktails)",note:"Shared price 6.95",items:[{name:"Abbotsford Sunset",description:"Tanqueray Flor De Sevilla 0%, orange, lemon, grenadine and lemonade",price:null,dietary:[],sharedPrice:6.95},{name:"Mixed Berry Fizz",description:"Whitley Neill Raspberry 0%, lemon and soda",price:null,dietary:[],sharedPrice:6.95},{name:"Not So Mojito",description:"Apple juice, lime, sugar syrup, mint and soda",price:6.95,dietary:[]}]},{name:"Wine by the Glass \u2014 White",items:[{name:"Berri Estates Chardonnay, South Eastern Australia",description:null,price:null,dietary:[],glass:{"175ml":6.5,"250ml":8.5}},{name:"Petal and Stem Sauvignon Blanc, Marlborough, New Zealand",description:null,price:null,dietary:[],glass:{"175ml":7.5,"250ml":10}},{name:"Grave del Friuli Pinot Grigio, Fantinel, Italy",description:null,price:null,dietary:[],glass:{"175ml":7.5,"250ml":10}},{name:"Mas Puech Picpoul de Pinet, France",description:null,price:null,dietary:[],glass:{"175ml":7.5,"250ml":10}},{name:"Leiras Albarino, Rias Baixas, Spain",description:null,price:null,dietary:[],glass:{"175ml":9.95,"250ml":11.95}}]},{name:"Wine by the Glass \u2014 Rose",items:[{name:"La Maglia Rosa Pinot Grigio Blush, Pavia, Italy",description:null,price:null,dietary:[],glass:{"175ml":7.5,"250ml":10}},{name:"Whispering Hills Zinfandel Rose, California, USA",description:null,price:null,dietary:[],glass:{"175ml":6.5,"250ml":8.5}}]},{name:"Wine by the Glass \u2014 Red",items:[{name:"Berri Estates Shiraz, South Eastern Australia",description:null,price:null,dietary:[],glass:{"175ml":6.95,"250ml":8.95}},{name:"La Campagne Merlot, Pays d'Oc, France",description:null,price:null,dietary:[],glass:{"175ml":7.95,"250ml":10.5}},{name:"Fico Grande Sangiovese, Italy",description:null,price:null,dietary:[],glass:{"175ml":7.5,"250ml":10}},{name:"Alma Mora Malbec, San Juan, Argentina",description:null,price:null,dietary:[],glass:{"175ml":8.95,"250ml":10.95}}]},{name:"Cellar Table \u2014 White (bottle)",items:[{name:"Petal and Stem Sauvignon Blanc, Marlborough, New Zealand",description:null,price:29.95,dietary:[]},{name:"Berri Estates Chardonnay, South Eastern Australia",description:null,price:24.95,dietary:[]},{name:"Grave del Friuli Pinot Grigio, Fantinel, Italy",description:null,price:29.95,dietary:[]},{name:"Mas Puech Picpoul de Pinet, France",description:null,price:29.95,dietary:[]},{name:"Monte di Sarocco Gavi, Italy",description:null,price:34.95,dietary:[]},{name:"Leiras Albarino, Rias Baixas, Spain",description:null,price:35.95,dietary:[]},{name:"Chateau Ste Michelle Chardonnay, Washington State, USA",description:null,price:47.95,dietary:[]},{name:"Louis Jadot Macon-Villages, France",description:null,price:60,dietary:[]}]},{name:"Cellar Table \u2014 Red (bottle)",items:[{name:"Berri Estates Shiraz, South Eastern Australia",description:null,price:25.95,dietary:[]},{name:"La Campagne Merlot, Pays d'Oc, France",description:null,price:30.95,dietary:[]},{name:"Fico Grande Sangiovese, Italy",description:null,price:29.95,dietary:[]},{name:"Zensa Primitivo Salento, Italy",description:null,price:30.95,dietary:[]},{name:"Chateauneuf-du-Pape, France",description:null,price:74.95,dietary:[]},{name:"Louis Jadot Pinot Noir, France",description:null,price:42,dietary:[]},{name:"Vina Pomal Reserva Centenario, Spain",description:null,price:55,dietary:[]}]},{name:"Cellar Table \u2014 Rose (bottle)",items:[{name:"Coteaux Varois en Provence Rose, Estandon, France",description:null,price:55,dietary:[]},{name:"La Maglia Rosa Pinot Grigio Blush, Italy",description:null,price:29.95,dietary:[]},{name:"Whispering Hills Zinfandel, USA",description:null,price:24.95,dietary:[]}]},{name:"Sparkling and Champagne",items:[{name:"Oliver and Greg's Prosecco Brut, Italy",description:null,price:29.95,dietary:[],note:"200ml 8.95 | Bottle 29.95",glass:{"200ml":8.95}},{name:"Bottega Gold Prosecco Brut, Italy",description:null,price:40,dietary:[]},{name:"Veuve Clicquot Yellow Label, France",description:null,price:89,dietary:[]},{name:"Veuve Clicquot Rose, France",description:null,price:99,dietary:[]}]},{name:"Abbotsford Top Picks",items:[{name:"Sancerre, Domaine des Chaintres, France",description:null,price:70,dietary:[]},{name:"Peth Wetz Riesling, Germany",description:null,price:55,dietary:[]},{name:"Fico Grande Sangiovese, Italy",description:null,price:29.95,dietary:[]},{name:"Valpolicella Classico Superiore Ripasso, Italy",description:null,price:65,dietary:[]},{name:"Chateau Ste. Michelle Cabernet Sauvignon, USA",description:null,price:60,dietary:[]},{name:"Chateau Grand Jauga Sauternes, France",description:null,price:40,dietary:[],note:"Dessert wine"}]}]}]}},858,[]);
15
+ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return k}});var n=r(d[0]),t=r(d[1]),o=r(d[2]),s=r(d[3]),l=r(d[4]),c=r(d[5]),u=r(d[6]),h=r(d[7]);function k(){const[k,j]=(0,n.useState)(!1),p=(0,c.useRestaurant)('kirkton')??u.KIRKTON_RESTAURANT;return(0,h.jsxs)(t.Screen,{title:p.name,back:!1,children:[(0,h.jsx)(o.RestaurantHero,{rid:"kirkton",size:240}),(0,h.jsx)(t.T,{center:!0,children:"Bar and restaurant in Dalrymple"}),k?(0,h.jsx)(l.NativeRequestSetup,{rid:"kirkton",kind:"table",allDayHours:p.kitchenHours,onClose:()=>j(!1)}):(0,h.jsxs)(h.Fragment,{children:[(0,h.jsxs)(t.Card,{children:[(0,h.jsx)(t.H2,{children:"Book a table"}),(0,h.jsx)(t.Button,{testID:"kirkton-book-table",label:"Book a table",onPress:()=>j(!0)}),(0,h.jsx)(t.T,{children:"Send a table request for the venue managers to confirm once setup is complete. This is not an instant booking."}),(0,h.jsx)(t.Muted,{children:"No deposit, payment, email or text is taken or sent by this app."})]}),(0,h.jsxs)(t.Card,{children:[(0,h.jsx)(t.H2,{children:"Venue setup in progress"}),(0,h.jsx)(t.T,{children:"Contact phone: to confirm"}),(0,h.jsx)(t.T,{children:"Opening and kitchen hours: to confirm"}),(0,h.jsx)(t.T,{children:"Table plan and Covers: to confirm"}),(0,h.jsx)(t.T,{children:"Takeaway: to confirm"}),(0,h.jsx)(t.Muted,{children:"Table requests need an authorised manager and confirmed kitchen hours. Orders and payments are not enabled. Deposit policy needs confirmation; deposits are off."})]}),(0,h.jsx)(s.FindPub,{rid:"kirkton"}),(0,h.jsx)(t.Banner,{kind:"warn",title:"Menus \u2014 provisional and unconfirmed",children:"The available menu records are archived from 2019. They are not current prices, availability or allergen information. No menu items are available to order here."})]})]})}},859,[31,818,867,847,848,823,9,25]);
abbotsford/chef-app/_expo/static/js/web/index-0d5420913a09234192e03fb64f496fd4.js ADDED
@@ -0,0 +1 @@
 
 
1
+ __d(function(g,_r,i,_a,m,_e,d){"use strict";Object.defineProperty(_e,'__esModule',{value:!0}),Object.defineProperty(_e,"default",{enumerable:!0,get:function(){return f}});var e=_r(d[0]);_r(d[1]);var s,r=_r(d[2]),n=(s=r)&&s.__esModule?s:{default:s},t=_r(d[3]),l=_r(d[4]),o=_r(d[5]),a=_r(d[6]),u=_r(d[7]),c=_r(d[8]),h=_r(d[9]),j=_r(d[10]),x=_r(d[11]);function f(){const s=(0,u.useStore)(e=>e.restaurants),r=(0,u.useCustomer)(),f=(0,u.useNow)(3e4);return(0,x.jsxs)(l.Screen,{title:"Restaurants",subtitle:"Book, order and pay at local restaurants",right:(0,x.jsxs)(l.Row,{children:[(0,x.jsx)(t.BasketButton,{}),(0,x.jsx)(l.Button,{small:!0,kind:"ghost",label:"Profile",onPress:()=>e.router.push('/customer/profile')})]}),children:[(0,x.jsxs)(l.Card,{onPress:()=>e.router.push('/customer/profile'),children:[(0,x.jsxs)(l.Row,{style:{justifyContent:'space-between'},children:[(0,x.jsx)(l.T,{weight:"semibold",children:r.name?`Hello, ${r.name.split(' ')[0]}`:'Add your profile'}),(0,x.jsx)(l.Muted,{children:"Edit profile \u203a"})]}),(0,x.jsx)(l.Muted,{children:"Your allergies (stored once, confirmed on every order and booking):"}),(0,x.jsx)(l.Row,{wrap:!0,gap:6,children:r.allergies.length?r.allergies.map(e=>(0,x.jsx)(l.Badge,{kind:"red",label:`${(0,o.allergenLabel)(e.allergen)} \u2014 ${(0,o.severityLabel)(e.severity)}`},e.allergen)):(0,x.jsx)(l.Muted,{children:"None declared"})})]}),s.map(s=>{const r=(0,a.hoursFor)(s,f);return(0,x.jsxs)(l.Card,{onPress:()=>e.router.push(`/customer/${s.id}`),highlight:s.id===j.VENUE_RID?c.colours.gold:void 0,children:[(0,x.jsxs)(l.Row,{style:{justifyContent:'space-between'},children:[(0,x.jsx)(l.H2,{style:{flex:1},children:s.name}),s.fictional?(0,x.jsx)(l.Badge,{kind:"amber",label:"FICTIONAL DEMO"}):(0,x.jsx)(l.Badge,{kind:"gold",label:"VENUE"})]}),(0,x.jsx)(l.Muted,{children:s.tagline}),(0,x.jsx)(l.Muted,{children:s.location}),(0,x.jsx)(l.T,{size:14,colour:r?c.colours.ok:c.colours.amber,children:r?`Kitchen today ${(0,a.kitchenHoursOn)(s,f)[0]}\u2013${(0,a.kitchenHoursOn)(s,f)[1]}`:'Kitchen closed today (hours not listed)'})]},s.id)}),(0,x.jsx)(l.Banner,{kind:"info",children:"Each venue uses only its own saved menu, cards and booking details."}),(0,x.jsx)(h.LauncherLine,{}),(0,x.jsx)(n.default,{style:{height:8}})]})}},791,[805,31,128,838,818,819,833,823,825,860,5,25]);
abbotsford/chef-app/_expo/static/js/web/index-18a42003614e46ed29f029ff3e81efd8.js ADDED
@@ -0,0 +1 @@
 
 
1
+ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return c}});var t=r(d[0]);r(d[1]);var n=r(d[2]),u=r(d[3]);function c(){return(0,u.jsx)(t.Redirect,{href:n.ENTRY[n.APP_VARIANT]})}},798,[805,31,807,25]);
abbotsford/chef-app/_expo/static/js/web/index-4caab44ee144794fe5f1c5f3fbaed93d.js ADDED
The diff for this file is too large to render. See raw diff
 
abbotsford/chef-app/_expo/static/js/web/index-708cc108b14a03d1e55d135c08408edf.js ADDED
@@ -0,0 +1 @@
 
 
1
+ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return f}});var t=r(d[0]);r(d[1]);var n=r(d[2]),u=r(d[3]),c=r(d[4]);function f(){return(0,u.canShow)('chef')?(0,c.jsx)(n.ChefApp,{}):(0,c.jsx)(t.Redirect,{href:u.ENTRY[u.APP_VARIANT]})}},777,[805,31,806,807,25]);
abbotsford/chef-app/_expo/static/js/web/index-a7e511353fde4e4907f278d874667ffb.js ADDED
The diff for this file is too large to render. See raw diff
 
abbotsford/chef-app/_expo/static/js/web/index-b2fb0e8ee9c9e5267d8b0725148d8bf3.js ADDED
The diff for this file is too large to render. See raw diff
 
abbotsford/chef-app/_expo/static/js/web/index-ba5aea4e23e402619315d92ef1e4fc6c.js ADDED
@@ -0,0 +1 @@
 
 
1
+ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return c}});var t=r(d[0]);r(d[1]);var n=r(d[2]),u=r(d[3]);function c(){return(0,u.jsx)(t.Redirect,{href:n.ENTRY[n.APP_VARIANT]})}},799,[805,31,807,25]);
abbotsford/chef-app/_expo/static/js/web/index-d72f0e09722c49318a402489e965ec4a.js ADDED
@@ -0,0 +1 @@
 
 
1
+ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return c}});var t=r(d[0]);r(d[1]);var n=r(d[2]),u=r(d[3]);function c(){return(0,u.jsx)(t.Redirect,{href:n.ENTRY[n.APP_VARIANT]})}},804,[805,31,807,25]);
abbotsford/chef-app/_expo/static/js/web/index-e9112f8ce9e859f928720bf6bff6ea9e.js ADDED
@@ -0,0 +1,2 @@
 
 
 
1
+ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return f}});var t=r(d[0]);r(d[1]);var n=r(d[2]),u=r(d[3]),c=r(d[4]);function f(){return'owner'!==u.APP_VARIANT?(0,c.jsx)(t.Redirect,{href:u.ENTRY[u.APP_VARIANT]}):(0,c.jsx)(n.OwnerApp,{})}},800,[805,31,1000,807,25]);
2
+ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),e.OwnerApp=function(){return null}},1000,[]);
abbotsford/chef-app/_expo/static/js/web/lost-cceda4c454fce783fcc4c1cdf454f0cd.js ADDED
@@ -0,0 +1 @@
 
 
1
+ __d(function(g,_r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return u}});var t=_r(d[0]),n=_r(d[1]),s=_r(d[2]),r=_r(d[3]),l=_r(d[4]),o=_r(d[5]);function u(){const{rid:u}=(0,t.useLocalSearchParams)(),h=(0,r.useRestaurant)(u),c=(0,r.useCustomer)(),x=(0,r.useNow)(6e4),j=(0,l.useOwner)(t=>t.lost),p=(0,l.useOwner)(t=>t.lostReports),[f,y]=(0,n.useState)(''),[w,b]=(0,n.useState)(''),[S,C]=(0,n.useState)(''),[R,v]=(0,n.useState)(!1);if(!h)return(0,o.jsx)(s.Screen,{title:"Not found",children:(0,o.jsx)(s.T,{children:"Restaurant not found."})});const O=p.filter(t=>t.contact.includes(c.email));return(0,o.jsxs)(s.Screen,{title:"Lost property",subtitle:h.name,children:[(0,o.jsxs)(s.Card,{children:[(0,o.jsx)(s.H2,{children:"Recently handed in"}),j.filter(t=>'held'===t.status).map(t=>(0,o.jsxs)(s.Row,{style:{justifyContent:'space-between'},children:[(0,o.jsx)(s.T,{style:{flex:1},children:t.item}),(0,o.jsx)(s.Muted,{children:t.foundAt.slice(0,10)})]},t.id)),j.some(t=>'held'===t.status)?null:(0,o.jsx)(s.Muted,{children:"Nothing handed in right now."}),(0,o.jsx)(s.Muted,{children:"To collect, bring ID or describe the item to staff. Items are kept for 3 months."})]}),R?(0,o.jsxs)(s.Banner,{kind:"success",children:["Report sent to ",h.name,". They'll be in touch if it turns up (sent to the venue on this device only: messaging is not set up yet)."]}):null,(0,o.jsxs)(s.Card,{children:[(0,o.jsx)(s.H2,{children:"Lost something?"}),(0,o.jsx)(s.Field,{label:"What did you lose?",value:f,onChangeText:y,placeholder:"e.g. Grey scarf"}),(0,o.jsx)(s.Field,{label:"When were you in?",value:w,onChangeText:b,placeholder:"e.g. Saturday evening"}),(0,o.jsx)(s.Field,{label:"Where were you sitting? (optional)",value:S,onChangeText:C,placeholder:"e.g. By the window"}),(0,o.jsxs)(s.Muted,{children:["We'll share your name and email (",c.email,") with ",h.name," for this report only."]}),(0,o.jsx)(s.Button,{label:"Send report",disabled:f.trim().length<2||w.trim().length<2,onPress:()=>{l.useOwner.getState().setOwner({lostReports:[{id:`lr-${Date.now()}`,item:f.trim(),when:w.trim(),where:S.trim()||'Not sure',contact:`${c.name} \xb7 ${c.email}`,at:x.toISOString(),status:'open'},...l.useOwner.getState().lostReports]}),y(''),b(''),C(''),v(!0)}})]}),O.length?(0,o.jsxs)(s.Card,{children:[(0,o.jsx)(s.H2,{children:"Your reports"}),O.map(t=>(0,o.jsxs)(s.Row,{style:{justifyContent:'space-between'},children:[(0,o.jsxs)(s.T,{style:{flex:1},children:[t.item," \xb7 ",t.when]}),(0,o.jsx)(s.Badge,{kind:'matched'===t.status?'ok':'open'===t.status?'amber':'neutral',label:'matched'===t.status?'Found!':'open'===t.status?'Looking':'Closed'})]},t.id))]}):null]})}},783,[805,31,818,823,861,25]);
abbotsford/chef-app/_expo/static/js/web/loyalty-bb43e2009908082ac56ab35a52b228ca.js ADDED
@@ -0,0 +1 @@
 
 
1
+ __d(function(g,_r,_i,a,m,_e,d){"use strict";Object.defineProperty(_e,'__esModule',{value:!0}),Object.defineProperty(_e,"default",{enumerable:!0,get:function(){return j}});var e=_r(d[0]),r=_r(d[1]);_r(d[2]);var s,t=_r(d[3]),n=(s=t)&&s.__esModule?s:{default:s},i=_r(d[4]),o=_r(d[5]),l=_r(d[6]),c=_r(d[7]),u=_r(d[8]),h=_r(d[9]),p=_r(d[10]),f=_r(d[11]);function j(){const{rid:s}=(0,r.useLocalSearchParams)(),t=(0,c.useRestaurant)(s);return e.LIVE_VENUE_BUILD||(0,p.guestServer)()?t?(0,f.jsx)(h.LoyaltyLive,{slug:s,venue:t.name}):(0,f.jsx)(o.Screen,{title:"Not found",children:(0,f.jsx)(o.T,{children:"Restaurant not found."})}):(0,f.jsx)(x,{})}function x(){const{rid:e}=(0,r.useLocalSearchParams)(),s=(0,c.useRestaurant)(e),t=(0,c.useCustomer)(),h=(0,c.useStampCard)(e);if(!s)return(0,f.jsx)(o.Screen,{title:"Not found",children:(0,f.jsx)(o.T,{children:"Restaurant not found."})});const p=s.settings.stampTarget,j=h?.stamps??0;return(0,f.jsxs)(o.Screen,{title:"Stamp card",subtitle:`${s.name} \u2014 this card is just for ${s.name}`,children:[(0,f.jsx)(o.Banner,{kind:"example",title:"Example card (demo)",children:"On a real venue your card is saved by the venue and is the same on any phone."}),(0,f.jsxs)(o.Card,{highlight:u.colours.gold,children:[(0,f.jsxs)(o.Row,{style:{justifyContent:'space-between'},children:[(0,f.jsxs)(o.H2,{children:[j," of ",p," stamps"]}),(0,f.jsxs)(o.T,{colour:u.colours.gold,weight:"semibold",children:["Reward: ",s.settings.stampReward]})]}),(0,f.jsx)(n.default,{style:{flexDirection:'row',flexWrap:'wrap',gap:10,justifyContent:'center',paddingVertical:8},children:Array.from({length:p}).map((e,r)=>(0,f.jsx)(n.default,{accessibilityLabel:r<j?'Stamp collected':'Empty stamp',style:{width:52,height:52,borderRadius:26,borderWidth:2,borderColor:u.colours.gold,backgroundColor:r<j?u.colours.gold:'transparent',alignItems:'center',justifyContent:'center'},children:(0,f.jsx)(o.T,{size:22,colour:r<j?u.colours.onGold:u.colours.border,children:"\u2605"})},r))}),(0,f.jsxs)(o.Muted,{children:["One stamp per paid visit or order over ",(0,l.gbp)(s.settings.stampMinSpend)," \u2014 dine-in, table QR or takeaway. Rewards are funded by ",s.name,"."]}),h?.rewardsAvailable?(0,f.jsx)(o.Banner,{kind:"success",title:`${h.rewardsAvailable} reward${h.rewardsAvailable>1?'s':''} ready: ${s.settings.stampReward}`,children:(0,f.jsx)(o.Button,{small:!0,label:"Use reward (show staff)",onPress:()=>c.repo.loyalty.redeemReward(s.id,t.id)})}):null]}),(0,f.jsxs)(o.Card,{children:[(0,f.jsx)(o.H2,{children:"Show this to staff"}),(0,f.jsx)(o.Muted,{children:"Staff scan this on the tablet to add a stamp for dine-in visits not paid by table QR."}),(0,f.jsx)(i.QR,{value:`covercharge:stamp:${s.id}:${t.id}`,size:190}),(0,f.jsx)(o.T,{center:!0,weight:"semibold",children:t.name})]}),(0,f.jsxs)(o.Card,{children:[(0,f.jsx)(o.H2,{children:"Bring a friend"}),(0,f.jsx)(o.T,{children:"Your referral code"}),(0,f.jsx)(o.T,{size:28,weight:"bold",colour:u.colours.gold,center:!0,children:t.referralCode}),(0,f.jsx)(o.Muted,{children:"When a friend completes their first qualifying paid visit or order, you both get a stamp. One referral reward per new account, phone and card; monthly cap applies."})]}),(0,f.jsxs)(o.Card,{children:[(0,f.jsx)(o.H2,{children:"History"}),(h?.history??[]).length?h.history.slice(0,10).map((e,r)=>(0,f.jsxs)(o.Muted,{children:[e.at.slice(0,10)," \xb7 ",e.source]},r)):(0,f.jsx)(o.Muted,{children:"No stamps yet."})]}),(0,f.jsx)(o.Muted,{children:"Rewards are kept on food (Scottish licensing rules restrict drinks promotions). Stamps are never given for reviews."})]})}},784,[842,805,31,128,875,818,820,823,825,866,845,25]);
abbotsford/chef-app/_expo/static/js/web/merch-77ea1815cef4942701820887c797ac92.js ADDED
@@ -0,0 +1 @@
 
 
1
+ __d(function(g,_r,i,a,_m,_e,d){"use strict";Object.defineProperty(_e,'__esModule',{value:!0}),Object.defineProperty(_e,"default",{enumerable:!0,get:function(){return y}});var e,t=_r(d[0]),n=_r(d[1]),s=_r(d[2]),l=_r(d[3]),r=(e=l)&&e.__esModule?e:{default:e},u=_r(d[4]),o=_r(d[5]),c=_r(d[6]),m=_r(d[7]),h=_r(d[8]),j=_r(d[9]),x=_r(d[10]),f=_r(d[11]),b=_r(d[12]),p=_r(d[13]);function y(){const{rid:e}=(0,n.useLocalSearchParams)(),s=(0,c.useRestaurant)(e),l=(0,c.useCustomer)();return t.LIVE_VENUE_BUILD||(0,b.guestServer)()?s?(0,p.jsx)(f.ShopLive,{slug:e,venue:s.name,guestName:l.name}):(0,p.jsx)(o.Screen,{title:"Not found",children:(0,p.jsx)(o.T,{children:"Restaurant not found."})}):(0,p.jsx)(S,{})}function S(){const{rid:e}=(0,n.useLocalSearchParams)(),t=(0,c.useRestaurant)(e),l=(0,c.useCustomer)(),f=(0,c.useNow)(6e4),b=(0,m.useOwner)(e=>e.merch),[y,S]=(0,s.useState)({}),[k,w]=(0,s.useState)(null),[v,C]=(0,s.useState)(null);if(!t)return(0,p.jsx)(o.Screen,{title:"Not found",children:(0,p.jsx)(o.T,{children:"Restaurant not found."})});const $=b.find(e=>e.id===k),O=e=>y[e]??1;return(0,p.jsxs)(o.Screen,{title:"Shop",subtitle:`${t.name} merch \xb7 collect in the restaurant`,children:[v?(0,p.jsxs)(o.Banner,{kind:"success",title:"Order noted (no payment taken)",children:[v," Collect it at the bar on your next visit."]}):null,b.filter(e=>e.live||0===e.stock).map(e=>(0,p.jsxs)(o.Card,{children:[(0,p.jsxs)(o.Row,{style:{justifyContent:'space-between'},children:[(0,p.jsxs)(r.default,{style:{flex:1},children:[(0,p.jsx)(o.T,{weight:"semibold",children:e.name}),(0,p.jsx)(o.T,{colour:x.colours.gold,weight:"semibold",children:(0,h.gbp)(e.price)})]}),0!==e.stock&&e.live?e.stock<8?(0,p.jsx)(o.Badge,{kind:"amber",label:`${e.stock} left`}):null:(0,p.jsx)(o.Badge,{kind:"neutral",label:"Sold out"})]}),e.live&&e.stock>0?(0,p.jsxs)(o.Row,{style:{justifyContent:'space-between'},children:[(0,p.jsx)(o.Stepper,{value:O(e.id),min:1,max:Math.min(5,e.stock),onChange:t=>S({...y,[e.id]:t}),label:`${e.name} quantity`}),(0,p.jsx)(o.Button,{small:!0,label:`Buy \xb7 ${(0,h.gbp)(e.price*O(e.id))}`,onPress:()=>w(e.id)})]}):null]},e.id)),(0,p.jsxs)(o.Muted,{children:["Collection only. Prices set by ",t.name,"."]}),$?(0,p.jsx)(u.MockPay,{visible:!0,onClose:()=>w(null),amount:$.price*O($.id),restaurantId:t.id,allowGiftCard:!1,title:`Buy ${$.name}`,onPaid:()=>{const e=m.useOwner.getState();e.setOwner({merch:e.merch.map(e=>e.id===$.id?{...e,stock:Math.max(0,e.stock-O($.id))}:e),merchOrders:[{id:`mo-${Date.now()}`,productId:$.id,qty:O($.id),customer:l.name,at:(0,j.ymd)(f),status:'new'},...e.merchOrders]}),C(`${O($.id)} \xd7 ${$.name}, ${(0,h.gbp)($.price*O($.id))}.`),w(null)}}):null]})}},785,[842,805,31,128,843,818,823,861,820,822,825,844,845,25]);
abbotsford/chef-app/_expo/static/js/web/offers-31ec634ef9aa42a8856b1215ab24e6f3.js ADDED
@@ -0,0 +1 @@
 
 
1
+ __d(function(g,_r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return j}});var n=_r(d[0]),t=_r(d[1]);_r(d[2]);var s=_r(d[3]),r=_r(d[4]),o=_r(d[5]),l=_r(d[6]),c=_r(d[7]),u=_r(d[8]),f=_r(d[9]),h=_r(d[10]);function j(){const{rid:o}=(0,t.useLocalSearchParams)(),l=(0,r.useRestaurant)(o);return n.LIVE_VENUE_BUILD||(0,f.guestServer)()?l?(0,h.jsx)(u.OffersLive,{slug:o,venue:l.name}):(0,h.jsx)(s.Screen,{title:"Not found",children:(0,h.jsx)(s.T,{children:"Restaurant not found."})}):(0,h.jsx)(x,{})}function x(){const{rid:n}=(0,t.useLocalSearchParams)(),u=(0,r.useRestaurant)(n),f=(0,r.useCustomer)(),j=(0,o.useOwner)(n=>n.offers);if(!u)return(0,h.jsx)(s.Screen,{title:"Not found",children:(0,h.jsx)(s.T,{children:"Restaurant not found."})});const x=!!f.marketingOptIn[u.id],b=j.filter(n=>n.live),p=b.filter(n=>'special'===n.kind),y=b.filter(n=>'offer'===n.kind);return(0,h.jsxs)(s.Screen,{title:"Specials & offers",subtitle:u.name,children:[(0,h.jsxs)(s.Card,{highlight:x?c.colours.ok:c.colours.gold,children:[(0,h.jsx)(s.Toggle,{label:`Send me offers from ${u.name}`,value:x,onChange:n=>r.repo.customers.update({marketingOptIn:{...f.marketingOptIn,[u.id]:n}})}),(0,h.jsx)(s.Muted,{children:x?'You can switch this off any time. We only use it for this restaurant.':'Off by default. Turn on to see member offers and get the occasional notification (max one a week). You can switch it off any time.'})]}),(0,h.jsx)(s.H2,{children:"Today's specials"}),p.length?p.map(n=>(0,h.jsxs)(s.Card,{children:[(0,h.jsxs)(s.Row,{style:{justifyContent:'space-between'},children:[(0,h.jsx)(s.T,{weight:"semibold",style:{flex:1},children:n.title}),(0,h.jsx)(s.Badge,{kind:"gold",label:"Special"})]}),(0,h.jsx)(s.Muted,{children:n.body})]},n.id)):(0,h.jsx)(s.Muted,{children:"No specials on the board right now."}),(0,h.jsx)(s.H2,{children:"Member offers"}),x?y.length?y.map(n=>(0,h.jsxs)(s.Card,{children:[(0,h.jsxs)(s.Row,{style:{justifyContent:'space-between'},children:[(0,h.jsx)(s.T,{weight:"semibold",style:{flex:1},children:n.title}),(0,h.jsx)(s.Badge,{kind:"ok",label:"Offer"})]}),(0,h.jsx)(s.Muted,{children:n.body}),n.until?(0,h.jsxs)(s.Muted,{children:["Until ",(0,l.niceDate)((0,l.parseYmd)(n.until))]}):null]},n.id)):(0,h.jsx)(s.Muted,{children:"No offers right now."}):(0,h.jsxs)(s.Banner,{kind:"info",children:["Turn on offers above to see ",y.length," member offer",1===y.length?'':'s',"."]}),(0,h.jsxs)(s.Muted,{children:["Offers are set by ",u.name,". Drinks promotions follow Scottish licensing rules. Demo: no notifications are sent."]})]})}},786,[842,805,31,818,823,861,822,825,866,845,25]);
abbotsford/chef-app/_expo/static/js/web/profile-94f3e7175fc7efdfa4351ecc255fb11b.js ADDED
@@ -0,0 +1 @@
 
 
1
+ __d(function(g,_r,i,_a,m,_e,d){"use strict";Object.defineProperty(_e,'__esModule',{value:!0}),Object.defineProperty(_e,"default",{enumerable:!0,get:function(){return y}});var e=_r(d[0]),r=_r(d[1]),s=_r(d[2]);_r(d[3]);var t,l=_r(d[4]),n=(t=l)&&t.__esModule?t:{default:t},a=_r(d[5]),o=_r(d[6]),u=_r(d[7]),c=_r(d[8]),h=_r(d[9]),p=_r(d[10]),b=_r(d[11]);function y(){const t=(0,h.useCustomer)(),l=(0,h.useStore)((0,p.useShallow)(e=>e.orders.filter(r=>r.customerId===e.customer.id))),y=(0,h.useStore)((0,p.useShallow)(e=>e.bookings.filter(r=>r.customerId===e.customer.id))),x=(0,h.useStore)(e=>e.restaurants),j=e=>x.find(r=>r.id===e)?.name??e;return(0,b.jsxs)(a.Screen,{title:"Your account",subtitle:"One CoverCharge account for every restaurant",children:[(0,b.jsxs)(a.Card,{children:[(0,b.jsx)(a.Field,{label:"Name",value:t.name,onChangeText:e=>h.repo.customers.update({name:e})}),(0,b.jsx)(a.Field,{label:"Email",value:t.email,keyboardType:"email-address",onChangeText:e=>h.repo.customers.update({email:e})}),(0,b.jsx)(a.Field,{label:"Mobile",value:t.phone,keyboardType:"phone-pad",onChangeText:e=>h.repo.customers.update({phone:e})}),(0,b.jsx)(a.Muted,{children:(0,r.guestServer)()?'Your bring-a-friend code is on each restaurant\u2019s stamp card.':`Referral code: ${t.referralCode}`})]}),(0,b.jsxs)(a.Card,{children:[(0,b.jsx)(a.H2,{children:"Allergies & severity"}),(0,b.jsx)(a.Muted,{children:"Stored once and shared with a restaurant only when you order or book there. You confirm them on every order, table session and booking."}),(0,b.jsx)(a.Toggle,{label:"I consent to CoverCharge storing my allergy information (health data, UK GDPR)",value:t.allergyConsent,onChange:e=>h.repo.customers.update({allergyConsent:e})}),t.allergyConsent?null:(0,b.jsx)(a.Banner,{kind:"warn",children:"Without consent your allergies won\u2019t be stored \u2014 tell staff directly."}),o.ALLERGENS.map(e=>{const r=t.allergies.find(r=>r.allergen===e.id);return(0,b.jsxs)(n.default,{style:{gap:6,paddingVertical:6},children:[(0,b.jsxs)(a.Row,{style:{justifyContent:'space-between'},children:[(0,b.jsx)(a.T,{weight:r?'semibold':'regular',children:e.label}),r?(0,b.jsx)(a.Badge,{kind:"red",label:"Declared"}):null]}),(0,b.jsxs)(a.Row,{wrap:!0,gap:6,children:[(0,b.jsx)(a.Chip,{label:"None",selected:!r,onPress:()=>h.repo.customers.setAllergy(e.id,null),disabled:!t.allergyConsent&&!r}),o.SEVERITIES.map(s=>(0,b.jsx)(a.Chip,{label:s.label,selected:r?.severity===s.id,disabled:!t.allergyConsent,onPress:()=>h.repo.customers.setAllergy(e.id,s.id)},s.id))]})]},e.id)})]}),(0,b.jsxs)(a.Card,{children:[(0,b.jsx)(a.H2,{children:"Your orders"}),l.length?l.map(r=>(0,b.jsxs)(a.Row,{style:{justifyContent:'space-between'},children:[(0,b.jsxs)(a.T,{style:{flex:1},children:[r.ref," \xb7 ",j(r.restaurantId)," \xb7 ",'table'===r.type?`${(0,e.tableNumbers)(r.tableNo)}`:'Takeaway']}),(0,b.jsx)(a.Button,{small:!0,kind:"secondary",label:`${r.status} \xb7 ${(0,u.gbp)(r.subtotal+r.tip)}`,onPress:()=>s.router.push(`/customer/order/${r.id}`)})]},r.id)):(0,b.jsx)(a.Muted,{children:"No orders yet."})]}),(0,b.jsxs)(a.Card,{children:[(0,b.jsx)(a.H2,{children:"Your bookings"}),y.length?y.map(e=>(0,b.jsxs)(a.T,{children:[e.ref," \xb7 ",j(e.restaurantId)," \xb7 ",(0,c.niceDate)((0,c.parseYmd)(e.date))," ",e.time," \xb7 ",e.partySize," people \xb7 ",e.status]},e.id)):(0,b.jsx)(a.Muted,{children:"No bookings yet."})]}),(0,b.jsx)(a.Muted,{children:"Account deletion and data export would live here (Apple 5.1.1(v); Google web deletion link)."})]})}},793,[812,845,805,31,128,818,819,820,822,823,881,25]);
abbotsford/chef-app/_expo/static/js/web/refer-281b0170b80b5db0e1402a8c4d823a68.js ADDED
@@ -0,0 +1 @@
 
 
1
+ __d(function(g,_r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return j}});var r=_r(d[0]),n=_r(d[1]),s=_r(d[2]),t=_r(d[3]),l=_r(d[4]),o=_r(d[5]),u=_r(d[6]),c=_r(d[7]),h=_r(d[8]),f=_r(d[9]);function j(){const{rid:s}=(0,n.useLocalSearchParams)(),o=(0,l.useRestaurant)(s);return r.LIVE_VENUE_BUILD||(0,h.guestServer)()?o?(0,f.jsx)(c.ReferLive,{slug:s,venue:o.name}):(0,f.jsx)(t.Screen,{title:"Not found",children:(0,f.jsx)(t.T,{children:"Restaurant not found."})}):(0,f.jsx)(x,{})}function x(){const{rid:r}=(0,n.useLocalSearchParams)(),c=(0,l.useRestaurant)(r),h=(0,l.useCustomer)(),j=(0,o.useOwner)(r=>r.referral),x=(0,o.useOwner)(r=>r.referrals),[p,w]=(0,s.useState)(!1);if(!c)return(0,f.jsx)(t.Screen,{title:"Not found",children:(0,f.jsx)(t.T,{children:"Restaurant not found."})});const b=x.filter(r=>r.referrer===h.name);return(0,f.jsxs)(t.Screen,{title:"Bring a friend",subtitle:c.name,children:[j.active?null:(0,f.jsxs)(t.Banner,{kind:"info",children:[c.name," isn't running referrals right now."]}),(0,f.jsxs)(t.Card,{highlight:u.colours.gold,children:[(0,f.jsxs)(t.H2,{children:["You get: ",j.giverReward]}),(0,f.jsxs)(t.T,{children:["Your friend gets: ",j.friendReward]}),(0,f.jsx)(t.Muted,{children:"When your friend makes their first paid visit or order."}),(0,f.jsx)(t.T,{size:30,weight:"bold",colour:u.colours.gold,center:!0,children:h.referralCode}),(0,f.jsx)(t.Button,{label:"Share my code",disabled:!j.active,onPress:()=>w(!0)}),p?(0,f.jsx)(t.Muted,{center:!0,children:"Demo: in the real app this opens your phone's share sheet. Nothing is sent from here."}):null]}),(0,f.jsxs)(t.Card,{children:[(0,f.jsx)(t.H2,{children:"Your referrals"}),b.length?b.map(r=>(0,f.jsxs)(t.Row,{style:{justifyContent:'space-between'},children:[(0,f.jsx)(t.T,{style:{flex:1},children:r.friend}),(0,f.jsx)(t.Badge,{kind:'rewarded'===r.status?'ok':'amber',label:r.status})]},r.id)):(0,f.jsx)(t.Muted,{children:"No referrals yet."})]}),(0,f.jsx)(t.Muted,{children:"One reward per new account, phone and card. Monthly cap applies. Rewards are on food, not drinks."})]})}},787,[842,805,31,818,823,861,825,866,845,25]);
abbotsford/chef-app/_expo/static/js/web/waitlist-0820a9a3f8a549bf0d6f432f6a7ad617.js ADDED
@@ -0,0 +1 @@
 
 
1
+ __d(function(g,_r,i,_a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return h}});var t=_r(d[0]),s=_r(d[1]),n=_r(d[2]),a=_r(d[3]),r=_r(d[4]),o=_r(d[5]),u=_r(d[6]),l=_r(d[7]),c=_r(d[8]);function h(){const{rid:h}=(0,t.useLocalSearchParams)(),x=(0,u.useRestaurant)(h),j=(0,u.useCustomer)(),b=(0,u.useWaitlist)(h),f=(0,u.useBookings)(h),w=(0,u.useOrders)(h),y=(0,u.useEvents)(h),p=(0,u.useNow)(15e3),[v,M]=(0,s.useState)(2),[P,S]=(0,s.useState)(j.name);if(!x)return(0,c.jsx)(n.Screen,{title:"Not found",children:(0,c.jsx)(n.T,{children:"Restaurant not found."})});const T=b.filter(t=>'waiting'===t.status||'notified'===t.status).sort((t,s)=>t.number-s.number),k=T.find(t=>t.customerId===j.id),B=(0,r.forecastToday)(x,f,w,y,p),C=B.nextHour?Math.min(1.6,Math.max(.8,B.nextHour.covers/(.75*x.settings.capacityPerHour))):1;if(k){const t=T.indexOf(k)+1;return(0,c.jsxs)(n.Screen,{title:"You\u2019re on the waitlist",subtitle:x.name,children:[(0,c.jsxs)(n.Card,{highlight:l.colours.gold,children:[(0,c.jsx)(n.Muted,{children:"Your queue number"}),(0,c.jsxs)(n.T,{size:56,weight:"bold",colour:l.colours.gold,children:["#",k.number]}),(0,c.jsx)(n.T,{children:1===t?'You\u2019re next':`${t-1} part${t-1==1?'y':'ies'} ahead of you`}),(0,c.jsxs)(n.T,{weight:"semibold",children:["Estimated wait: about ",(0,o.estimateWait)(t,x.settings.turnMins,C)," minutes"]}),(0,c.jsxs)(n.Muted,{children:["Estimate only \u2014 based on tables in use, typical turn times and today\u2019s forecast. Joined ",(0,a.minsBetween)(new Date(k.joinedAt),p)," min ago."]})]}),'notified'===k.status?(0,c.jsx)(n.Banner,{kind:"success",title:"Your table is ready!",children:"Please come to the door within 5 minutes to keep your table."}):(0,c.jsx)(n.Banner,{kind:"info",children:"Keep this page open to see when your table is ready. Text alerts are not connected."}),(0,c.jsx)(n.Button,{kind:"secondary",label:"Leave the waitlist",onPress:()=>u.repo.waitlist.setStatus(k.id,'removed')})]})}return(0,c.jsxs)(n.Screen,{title:"Join the waitlist",subtitle:x.name,children:[(0,c.jsxs)(n.Card,{children:[(0,c.jsxs)(n.H2,{children:[T.length," part",1===T.length?'y':'ies'," waiting"]}),(0,c.jsxs)(n.Muted,{children:["Estimated wait if you join now: about ",(0,o.estimateWait)(T.length+1,x.settings.turnMins,C)," minutes (estimate)."]})]}),(0,c.jsx)(n.Field,{label:"Name",value:P,onChangeText:S}),(0,c.jsxs)(n.Row,{style:{justifyContent:'space-between'},children:[(0,c.jsx)(n.T,{weight:"semibold",children:"Party size"}),(0,c.jsx)(n.Stepper,{value:v,onChange:M,min:1,max:12,label:"party size"})]}),(0,c.jsx)(n.Button,{label:"Join the queue",disabled:P.trim().length<2,onPress:()=>u.repo.waitlist.join(x.id,P,v,j.id),testID:"join-waitlist"}),(0,c.jsx)(n.Muted,{children:"Waitlist messages are service messages only \u2014 no marketing."})]})}},788,[805,31,818,822,876,877,823,825,25]);
abbotsford/chef-app/_expo/static/js/web/whatson-6498b8821e66bd4aa1639b57afb933a3.js ADDED
@@ -0,0 +1 @@
 
 
1
+ __d(function(g,_r,_i,_a,m,_e,_d){"use strict";function e(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(_e,'__esModule',{value:!0}),Object.defineProperty(_e,"default",{enumerable:!0,get:function(){return h}});var t=_r(_d[0]),l=_r(_d[1]),n=_r(_d[2]),s=e(_r(_d[3])),o=e(_r(_d[4])),a=_r(_d[5]),r=_r(_d[6]),d=_r(_d[7]),i=_r(_d[8]),u=_r(_d[9]);const c=e=>'bank-holiday'===e.kind?(0,u.jsx)(a.Badge,{kind:"blue",label:"Scottish bank holiday"}):'school-holiday'===e.kind?(0,u.jsx)(a.Badge,{kind:"neutral",label:"School holiday"}):'occasion'===e.kind?(0,u.jsx)(a.Badge,{kind:"gold",label:"Key dining date"}):(0,u.jsx)(a.Badge,{kind:"ok",label:"Restaurant event"});function h(){const{rid:e}=(0,t.useLocalSearchParams)(),h=(0,d.useRestaurant)(e),x=(0,d.useEvents)(e),y=(0,d.useNow)(6e4),[j,f]=(0,n.useState)(()=>new Date(y.getFullYear(),y.getMonth(),1)),[b,k]=(0,n.useState)(null);if(!h)return(0,u.jsx)(a.Screen,{title:"Not found",children:(0,u.jsx)(a.T,{children:"Restaurant not found."})});const p=(new Date(j).getDay()+6)%7,w=new Date(j.getFullYear(),j.getMonth()+1,0).getDate(),M=[...Array(p).fill(null),...Array.from({length:w},(e,t)=>new Date(j.getFullYear(),j.getMonth(),t+1))];for(;M.length%7;)M.push(null);const D=e=>x.filter(t=>t.date===e),v=x.filter(e=>e.date>=(0,r.ymd)(y)).sort((e,t)=>e.date.localeCompare(t.date)),B=b?D(b):v.slice(0,20);return(0,u.jsxs)(a.Screen,{title:"What\u2019s on",subtitle:`${h.name} \xb7 holidays, key dates and events`,children:[(0,u.jsxs)(a.Card,{children:[(0,u.jsxs)(a.Row,{style:{justifyContent:'space-between'},children:[(0,u.jsx)(a.Button,{small:!0,kind:"ghost",label:"\u2039 Prev",onPress:()=>f(new Date(j.getFullYear(),j.getMonth()-1,1))}),(0,u.jsxs)(a.H2,{children:[(0,r.monthLong)(j.getMonth())," ",j.getFullYear()]}),(0,u.jsx)(a.Button,{small:!0,kind:"ghost",label:"Next \u203a",onPress:()=>f(new Date(j.getFullYear(),j.getMonth()+1,1))})]}),(0,u.jsx)(o.default,{style:{flexDirection:'row'},children:['Mon','Tue','Wed','Thu','Fri','Sat','Sun'].map(e=>(0,u.jsx)(a.T,{size:13,colour:i.colours.muted,style:{flex:1,textAlign:'center'},children:e},e))}),Array.from({length:M.length/7}).map((e,t)=>(0,u.jsx)(o.default,{style:{flexDirection:'row'},children:M.slice(7*t,7*t+7).map((e,t)=>{if(!e)return(0,u.jsx)(o.default,{style:{flex:1,height:44}},t);const l=(0,r.ymd)(e),n=D(l),d=l===(0,r.ymd)(y);return(0,u.jsxs)(s.default,{accessibilityLabel:`${l}${n.length?`, ${n.length} events`:''}`,onPress:()=>k(b===l?null:l),style:{flex:1,height:44,alignItems:'center',justifyContent:'center',borderRadius:8,backgroundColor:b===l?i.colours.goldTint:'transparent',borderWidth:d?1:0,borderColor:i.colours.gold},children:[(0,u.jsx)(a.T,{size:15,colour:n.length?i.colours.text:i.colours.muted,weight:n.length?'semibold':'regular',children:e.getDate()}),(0,u.jsx)(a.Row,{gap:2,children:n.slice(0,3).map(e=>(0,u.jsx)(o.default,{style:{width:6,height:6,borderRadius:3,backgroundColor:'bank-holiday'===e.kind?i.colours.blue:'event'===e.kind?i.colours.ok:i.colours.gold}},e.id))})]},t)})},t))]}),(0,u.jsx)(a.H2,{children:b?(0,r.niceDateYear)((0,r.parseYmd)(b)):'Coming up'}),0===B.length?(0,u.jsx)(a.Muted,{children:"Nothing on this day."}):B.map(e=>(0,u.jsxs)(a.Card,{children:[(0,u.jsxs)(a.Row,{style:{justifyContent:'space-between'},children:[(0,u.jsx)(a.T,{center:!0,weight:"semibold",style:{width:'100%',flexBasis:'100%'},children:(0,l.holidayName)(e.title)}),c(e)]}),(0,u.jsxs)(a.Muted,{children:[(0,r.niceDateYear)((0,r.parseYmd)(e.date)),e.source?` \xb7 source: ${e.source}`:'']}),(0,u.jsx)(a.T,{size:15,children:e.description}),e.example?(0,u.jsx)(a.Badge,{kind:"amber",label:"EXAMPLE EVENT"}):null,e.date>=(0,r.ymd)(y)?(0,u.jsx)(a.Button,{small:!0,kind:"secondary",label:"Book for this date",onPress:()=>t.router.push({pathname:'/customer/[rid]/book',params:{rid:h.id,date:e.date}})}):null]},e.id)),(0,u.jsx)(a.Muted,{children:"Bank holidays from gov.uk (Scotland division). Easter Monday is not a Scottish bank holiday; local council holidays vary."})]})}},789,[805,832,31,264,128,818,822,823,825,25]);
abbotsford/chef-app/assets/assets/brand/3idiots-hero.77d66ccb53ec1835c3b8a838e9bcfb5a.png ADDED
abbotsford/chef-app/assets/assets/brand/drunkencoo-hero.7c01fed6cb075a3a8e4f969bff1cf103.png ADDED

Git LFS Details

  • SHA256: b0f0d39993c7277bbb638281d6e866210f531e6a1b1d15725438492744ad8b27
  • Pointer size: 131 Bytes
  • Size of remote file: 785 kB
abbotsford/chef-app/assets/assets/brand/drunkencoo.272f746bf13376f503acd81a524a7998.png ADDED

Git LFS Details

  • SHA256: ee818c12a718a102300ba2029c69175576fc924cd69ec20ecffd1501d8aa4ce7
  • Pointer size: 131 Bytes
  • Size of remote file: 277 kB
abbotsford/chef-app/assets/assets/brand/smokinggoat-hero.b2ae48c4a1fcf2521ae9ff58435a6649.png ADDED

Git LFS Details

  • SHA256: f79b6753533967207707737ad36818ef3c282de039b1b4846174ea4f9869beb8
  • Pointer size: 131 Bytes
  • Size of remote file: 799 kB
abbotsford/chef-app/assets/assets/brand/smokinggoat.fff2a9a694b41fed68c80a2c9bfe65da.png ADDED

Git LFS Details

  • SHA256: 8a4a0fc824f897baf074abfd3324fb200ed3cf21e81f5545f7fafe36288df957
  • Pointer size: 132 Bytes
  • Size of remote file: 1.04 MB
abbotsford/chef-app/index.html CHANGED
@@ -30,6 +30,6 @@
30
  <noscript> You need to enable JavaScript to run this app. </noscript>
31
  <!-- The root element for your Expo app. -->
32
  <div id="root"><div style="position:fixed;inset:0;background:#32373C;display:grid;place-items:center"><img src="/abbotsford/chef-app/brand-hero.png" alt="The Abbotsford Hotel" width="260" height="260" style="display:block;max-width:80vw;height:auto;margin:0 auto;object-fit:contain"><p style="text-align:center;color:#E5D08D;font-size:22px">The Abbotsford Hotel</p><p style="text-align:center;color:#E5D08D;font-size:16px">14 Corsehill Road, Ayr KA7 2ST</p></div></div>
33
- <script src="/abbotsford/chef-app/_expo/static/js/web/__expo-metro-runtime-8c088df87a31e4e6accd81c554ec290d.js" defer></script><script src="/abbotsford/chef-app/_expo/static/js/web/__common-0425404e400a21b23676d48bb03fc623.js" defer></script><script src="/abbotsford/chef-app/_expo/static/js/web/index-fb16c776fdd291d3aa642c194ec798bc.js" defer></script>
34
  </body>
35
  </html>
 
30
  <noscript> You need to enable JavaScript to run this app. </noscript>
31
  <!-- The root element for your Expo app. -->
32
  <div id="root"><div style="position:fixed;inset:0;background:#32373C;display:grid;place-items:center"><img src="/abbotsford/chef-app/brand-hero.png" alt="The Abbotsford Hotel" width="260" height="260" style="display:block;max-width:80vw;height:auto;margin:0 auto;object-fit:contain"><p style="text-align:center;color:#E5D08D;font-size:22px">The Abbotsford Hotel</p><p style="text-align:center;color:#E5D08D;font-size:16px">14 Corsehill Road, Ayr KA7 2ST</p></div></div>
33
+ <script src="/abbotsford/chef-app/_expo/static/js/web/__expo-metro-runtime-8c088df87a31e4e6accd81c554ec290d.js" defer></script><script src="/abbotsford/chef-app/_expo/static/js/web/__common-d92ed2b513b48a7e75fdf07ee4f937c8.js" defer></script><script src="/abbotsford/chef-app/_expo/static/js/web/index-4caab44ee144794fe5f1c5f3fbaed93d.js" defer></script>
34
  </body>
35
  </html>
abbotsford/chef-app/kitchen.html CHANGED
@@ -30,6 +30,6 @@
30
  <noscript> You need to enable JavaScript to run this app. </noscript>
31
  <!-- The root element for your Expo app. -->
32
  <div id="root"><div style="position:fixed;inset:0;background:#32373C;display:grid;place-items:center"><img src="/abbotsford/chef-app/brand-hero.png" alt="The Abbotsford Hotel" width="260" height="260" style="display:block;max-width:80vw;height:auto;margin:0 auto;object-fit:contain"><p style="text-align:center;color:#E5D08D;font-size:22px">The Abbotsford Hotel</p><p style="text-align:center;color:#E5D08D;font-size:16px">14 Corsehill Road, Ayr KA7 2ST</p></div></div>
33
- <script src="/abbotsford/chef-app/_expo/static/js/web/__expo-metro-runtime-8c088df87a31e4e6accd81c554ec290d.js" defer></script><script src="/abbotsford/chef-app/_expo/static/js/web/__common-0425404e400a21b23676d48bb03fc623.js" defer></script><script src="/abbotsford/chef-app/_expo/static/js/web/index-fb16c776fdd291d3aa642c194ec798bc.js" defer></script>
34
  </body>
35
  </html>
 
30
  <noscript> You need to enable JavaScript to run this app. </noscript>
31
  <!-- The root element for your Expo app. -->
32
  <div id="root"><div style="position:fixed;inset:0;background:#32373C;display:grid;place-items:center"><img src="/abbotsford/chef-app/brand-hero.png" alt="The Abbotsford Hotel" width="260" height="260" style="display:block;max-width:80vw;height:auto;margin:0 auto;object-fit:contain"><p style="text-align:center;color:#E5D08D;font-size:22px">The Abbotsford Hotel</p><p style="text-align:center;color:#E5D08D;font-size:16px">14 Corsehill Road, Ayr KA7 2ST</p></div></div>
33
+ <script src="/abbotsford/chef-app/_expo/static/js/web/__expo-metro-runtime-8c088df87a31e4e6accd81c554ec290d.js" defer></script><script src="/abbotsford/chef-app/_expo/static/js/web/__common-d92ed2b513b48a7e75fdf07ee4f937c8.js" defer></script><script src="/abbotsford/chef-app/_expo/static/js/web/index-4caab44ee144794fe5f1c5f3fbaed93d.js" defer></script>
34
  </body>
35
  </html>
abbotsford/chef-app/sw.js CHANGED
@@ -1,4 +1,4 @@
1
- const V="cc-abbotsford-chef-bafa96ad70c2d3f4",B="/abbotsford/chef-app/",P=["/abbotsford/chef-app/apple-touch-icon.png", "/abbotsford/chef-app/favicon.ico", "/abbotsford/chef-app/icon-192.png", "/abbotsford/chef-app/icon-512.png", "/abbotsford/chef-app/brand-logo.png", "/abbotsford/chef-app/index.html", "/abbotsford/chef-app/manifest.webmanifest", "/abbotsford/chef-app/brand-hero.png", "/abbotsford/chef-app/kitchen.html", "/abbotsford/chef-app/_expo/static/js/web/feedback-3a26c70c9f758c4e362493c3b124ff43.js", "/abbotsford/chef-app/_expo/static/js/web/[n]-ced785c534ba69ad6c9c35369d7ecc36.js", "/abbotsford/chef-app/_expo/static/js/web/index-f9b07e7c25cec3623c10876ff1e01e58.js", "/abbotsford/chef-app/_expo/static/js/web/index-22ab313389266900b67350334e3d7a33.js", "/abbotsford/chef-app/_expo/static/js/web/[section]-93e8e4ffe952e5b3c505e21ca771e570.js", "/abbotsford/chef-app/_expo/static/js/web/index-a39af53b0c36f30a0cc27647d3da5a52.js", "/abbotsford/chef-app/_expo/static/js/web/offers-3f4e351ccaa73514bd508bf7bd2a3fa2.js", "/abbotsford/chef-app/_expo/static/js/web/[oid]-7fa4f78cb447d1c659e81fff8893269f.js", "/abbotsford/chef-app/_expo/static/js/web/index-7fc09fb9e425fe86489cd7f975b72892.js", "/abbotsford/chef-app/_expo/static/js/web/[did]-2a2aaaa129307f15140971a22b834cd3.js", "/abbotsford/chef-app/_expo/static/js/web/index-572239673a2eda40ce1d7171531ee6dc.js", "/abbotsford/chef-app/_expo/static/js/web/book-7c4c90140093809a35e48a974143bb55.js", "/abbotsford/chef-app/_expo/static/js/web/demo-6323990816bb686dcab3b33d7e6ec148.js", "/abbotsford/chef-app/_expo/static/js/web/_layout-56fe98b075405db708171d6d13d135d3.js", "/abbotsford/chef-app/_expo/static/js/web/__common-0425404e400a21b23676d48bb03fc623.js", "/abbotsford/chef-app/_expo/static/js/web/__expo-metro-runtime-8c088df87a31e4e6accd81c554ec290d.js", "/abbotsford/chef-app/_expo/static/js/web/index-3907adcde835a3ea4b369b11444932ca.js", "/abbotsford/chef-app/_expo/static/js/web/merch-dcc4bf2e12c5c983cc8637b3dae25ae6.js", "/abbotsford/chef-app/_expo/static/js/web/refer-9cf3652c6de6015e443d52d85aa73db7.js", "/abbotsford/chef-app/_expo/static/js/web/whatson-dd3d796ea1e77876d5803d9ecd8c1109.js", "/abbotsford/chef-app/_expo/static/js/web/basket-39cdf98ed8418bbc1a1ff3b2f269cbcb.js", "/abbotsford/chef-app/_expo/static/js/web/index-ec4a702c34ea762b0b3ef33b63506ae5.js", "/abbotsford/chef-app/_expo/static/js/web/profile-7858c56bba02a864da6a44be8f8ce02f.js", "/abbotsford/chef-app/_expo/static/js/web/gift-eb5daa22c1465e33034a87271e1b8b3b.js", "/abbotsford/chef-app/_expo/static/js/web/waitlist-5949dfe032d315503649cf449ffe870a.js", "/abbotsford/chef-app/_expo/static/js/web/lost-53fa50fd975a0e31c68fdd69575c2342.js", "/abbotsford/chef-app/_expo/static/js/web/index-3c5f820b3b21978c61372b3163c55b0a.js", "/abbotsford/chef-app/_expo/static/js/web/+not-found-585f3164ae74e5ff35af71a4ba7360a3.js", "/abbotsford/chef-app/_expo/static/js/web/loyalty-f6d17fe0987432e6c679359636231949.js", "/abbotsford/chef-app/_expo/static/js/web/historicalBookingApi-bfa4e54c4063e9fc2635ab60c034b3f8.js", "/abbotsford/chef-app/_expo/static/js/web/index-837efe1be9c39737e9750ae18a91c7cb.js", "/abbotsford/chef-app/_expo/static/js/web/index-fb16c776fdd291d3aa642c194ec798bc.js", "/abbotsford/chef-app/_expo/static/js/web/[token]-bee6add88cca58f03680987578d45fcf.js", "/abbotsford/chef-app/assets/node_modules/expo-router/assets/pkg.ab19f4cbc543357183a20571f68380a3.png", "/abbotsford/chef-app/assets/node_modules/expo-router/assets/sitemap.412dd9275b6b48ad28f5e3d81bb1f626.png", "/abbotsford/chef-app/assets/node_modules/expo-router/assets/file.19eeb73b9593a38f8e9f418337fc7d10.png", "/abbotsford/chef-app/assets/node_modules/expo-router/assets/unmatched.20e71bdf79e3a97bf55fd9e164041578.png", "/abbotsford/chef-app/assets/node_modules/expo-router/assets/forward.d8b800c443b8972542883e0b9de2bdc6.png", "/abbotsford/chef-app/assets/node_modules/expo-router/assets/error.d1ea1496f9057eb392d5bbf3732a61b7.png", "/abbotsford/chef-app/assets/node_modules/expo-router/assets/arrow_down.017bc6ba3fc25503e5eb5e53826d48a8.png", "/abbotsford/chef-app/assets/node_modules/expo-router/assets/react-navigation/elements/clear-icon.c94f6478e7ae0cdd9f15de1fcb9e5e55@3x.png", "/abbotsford/chef-app/assets/node_modules/expo-router/assets/react-navigation/elements/close-icon.808e1b1b9b53114ec2838071a7e6daa7.png", "/abbotsford/chef-app/assets/node_modules/expo-router/assets/react-navigation/elements/close-icon.808e1b1b9b53114ec2838071a7e6daa7@3x.png", "/abbotsford/chef-app/assets/node_modules/expo-router/assets/react-navigation/elements/close-icon.808e1b1b9b53114ec2838071a7e6daa7@4x.png", "/abbotsford/chef-app/assets/node_modules/expo-router/assets/react-navigation/elements/close-icon.808e1b1b9b53114ec2838071a7e6daa7@2x.png", "/abbotsford/chef-app/assets/node_modules/expo-router/assets/react-navigation/elements/search-icon.286d67d3f74808a60a78d3ebf1a5fb57.png", "/abbotsford/chef-app/assets/node_modules/expo-router/assets/react-navigation/elements/clear-icon.c94f6478e7ae0cdd9f15de1fcb9e5e55.png", "/abbotsford/chef-app/assets/node_modules/expo-router/assets/react-navigation/elements/back-icon-mask.0a328cd9c1afd0afe8e3b1ec5165b1b4.png", "/abbotsford/chef-app/assets/node_modules/expo-router/assets/react-navigation/elements/clear-icon.c94f6478e7ae0cdd9f15de1fcb9e5e55@2x.png", "/abbotsford/chef-app/assets/node_modules/expo-router/assets/react-navigation/elements/clear-icon.c94f6478e7ae0cdd9f15de1fcb9e5e55@4x.png", "/abbotsford/chef-app/assets/node_modules/expo-router/assets/react-navigation/elements/back-icon.35ba0eaec5a4f5ed12ca16fabeae451d.png", "/abbotsford/chef-app/assets/node_modules/@expo-google-fonts/poppins/500Medium/Poppins_500Medium.bf59c687bc6d3a70204d3944082c5cc0.ttf", "/abbotsford/chef-app/assets/node_modules/@expo-google-fonts/poppins/600SemiBold/Poppins_600SemiBold.6f1520d107205975713ba09df778f93f.ttf", "/abbotsford/chef-app/assets/node_modules/@expo-google-fonts/poppins/700Bold/Poppins_700Bold.08c20a487911694291bd8c5de41315ad.ttf", "/abbotsford/chef-app/assets/node_modules/@expo-google-fonts/poppins/400Regular/Poppins_400Regular.093ee89be9ede30383f39a899c485a82.ttf", "/abbotsford/chef-app/assets/assets/specials/sample-chalkboard.e7b4e4450a8483d4219bc6a214158d8f.jpg", "/abbotsford/chef-app/assets/assets/recipes/moules.a4f342fc7e7fb62c8a0b5c1678bbea3f.jpg", "/abbotsford/chef-app/assets/assets/recipes/stp.1061ced765efdcafff2554adc3fc7113.jpg", "/abbotsford/chef-app/assets/assets/recipes/skink.4ce7b7c676f9cdcd0a060eda46f5a00e.jpg", "/abbotsford/chef-app/assets/assets/recipes/fishsupper.1609c58319e1e8721f5c639049fb054e.jpg", "/abbotsford/chef-app/assets/assets/recipes/lobster.2fb3485c8e372972099259017358c1b8.jpg", "/abbotsford/chef-app/assets/assets/brand/wildings.076f4fcd06d19a0af0205c410f461b14.png", "/abbotsford/chef-app/assets/assets/brand/anchorage-hero.0450b828e4f9c1f4456240096598f6f5.png", "/abbotsford/chef-app/assets/assets/brand/3idiots-hero.e5dfd53739f05086b1956e72d585a66a.png", "/abbotsford/chef-app/assets/assets/brand/mrbasrais.7cc4086dd12ace82529795f1c9f8c900.png", "/abbotsford/chef-app/assets/assets/brand/cecchinis.ebf752fef363247848ae7c0d91938765.png", "/abbotsford/chef-app/assets/assets/brand/kirkmichael.63b13cde7fd82eb622622b39ac80c394.png", "/abbotsford/chef-app/assets/assets/brand/3idiots.df4a76d2130f0e5b0042f06a8c88693a.png", "/abbotsford/chef-app/assets/assets/brand/brae.8de9e89ac30966c6669de990370d8e40.png", "/abbotsford/chef-app/assets/assets/brand/rupeeroom-hero.969fa372add526aaacf3a6c009b8ac92.png", "/abbotsford/chef-app/assets/assets/brand/kirkmichael-hero.63b13cde7fd82eb622622b39ac80c394.png", "/abbotsford/chef-app/assets/assets/brand/williewastles.055a77893ced99bf3a6c5402ba5baac6.png", "/abbotsford/chef-app/assets/assets/brand/drunkencoo-hero.65c21c4da9e466cf4bffc969639a1427.png", "/abbotsford/chef-app/assets/assets/brand/pizzaioli-hero.1896657c08264cefb49b401891d5448d.png", "/abbotsford/chef-app/assets/assets/brand/drunkencoo.f6d92af3b14e4205a3deaf4434754c51.png", "/abbotsford/chef-app/assets/assets/brand/smokinggoat.20a3a1970596ab43c5d6468d4ed549a7.png", "/abbotsford/chef-app/assets/assets/brand/greenside.9d1556db97dcb903a3c57e2063ee2255.png", "/abbotsford/chef-app/assets/assets/brand/abbotsford-hero.78fcb8ee06ee22c4ca659c9254db7512.png", "/abbotsford/chef-app/assets/assets/brand/rupeeroom.689e6fb536dc0845eeb174a1ec7bd346.png", "/abbotsford/chef-app/assets/assets/brand/kirkton.bcf8d846df4861474d224a7a77f498fb.png", "/abbotsford/chef-app/assets/assets/brand/anchorage.fea5ce2f6fd18bf2950aa21c0980ed8e.png", "/abbotsford/chef-app/assets/assets/brand/williewastles-hero.b9d53d27b66f903b5618a7177b2ffad4.png", "/abbotsford/chef-app/assets/assets/brand/pizzaioli.db8c000b62ee407121aa8b90ce45e170.png", "/abbotsford/chef-app/assets/assets/brand/yasmins-hero.a5aef62e37dfcecbe0afc056186f4ad9.png", "/abbotsford/chef-app/assets/assets/brand/wildings-hero-logo-text.4661e4b935726f2511f9c17a1567c89a.png", "/abbotsford/chef-app/assets/assets/brand/yasmins.8482602e9f0a965655924835625cb02b.png", "/abbotsford/chef-app/assets/assets/brand/kirkton-hero.9d0837b292c2f4f30f4521d806bb28c3.png", "/abbotsford/chef-app/assets/assets/brand/saltmarsh.85a6a65732635e5148478d743d9ca884.png", "/abbotsford/chef-app/assets/assets/brand/souters.f4c58d9349b6e1700fe5abcc9e9b665c.png", "/abbotsford/chef-app/assets/assets/brand/greenside-hero.1caec5a6cb939434cccb5f3a613b50f8.png", "/abbotsford/chef-app/assets/assets/brand/abbotsford.b26602bba5ce4969733c5422a45ad053.png", "/abbotsford/chef-app/assets/assets/brand/smokinggoat-hero.0588f17ef0eed7f757f22916cd4d37db.png", "/abbotsford/chef-app/assets/assets/brand/cecchinis-hero.f77780fcc94fd668cf35d66d6dc52d81.png", "/abbotsford/chef-app/assets/assets/brand/mrbasrais-hero.4ce74641cfcf52d099157c84005b9d2a.png"];
2
  self.addEventListener('install',e=>e.waitUntil(caches.open(V).then(c=>Promise.all(P.map(u=>fetch(u).then(r=>{if(!r.ok)throw Error('cache');return c.put(u,r)})))).then(()=>self.skipWaiting())));
3
  self.addEventListener('activate',e=>e.waitUntil(caches.keys().then(ks=>Promise.all(ks.filter(k=>k.startsWith('cc-abbotsford-chef-')&&k!==V).map(k=>caches.delete(k)))).then(()=>self.clients.claim())));
4
  self.addEventListener('fetch',e=>{const u=new URL(e.request.url);if(e.request.method!=='GET'||u.origin!==location.origin||!u.pathname.startsWith(B))return;if(e.request.mode==='navigate'){e.respondWith(fetch(e.request).then(r=>r.ok?r:caches.match(B+'index.html')).catch(()=>caches.match(B+'index.html')));return;}e.respondWith(caches.match(e.request).then(r=>r||fetch(e.request)));});
 
1
+ const V="cc-abbotsford-chef-b76c3ce3e746e674",B="/abbotsford/chef-app/",P=["/abbotsford/chef-app/index.html", "/abbotsford/chef-app/icon-192.png", "/abbotsford/chef-app/brand-logo.png", "/abbotsford/chef-app/kitchen.html", "/abbotsford/chef-app/favicon.ico", "/abbotsford/chef-app/brand-hero.png", "/abbotsford/chef-app/icon-512.png", "/abbotsford/chef-app/apple-touch-icon.png", "/abbotsford/chef-app/manifest.webmanifest", "/abbotsford/chef-app/assets/assets/recipes/fishsupper.1609c58319e1e8721f5c639049fb054e.jpg", "/abbotsford/chef-app/assets/assets/recipes/lobster.2fb3485c8e372972099259017358c1b8.jpg", "/abbotsford/chef-app/assets/assets/recipes/moules.a4f342fc7e7fb62c8a0b5c1678bbea3f.jpg", "/abbotsford/chef-app/assets/assets/recipes/skink.4ce7b7c676f9cdcd0a060eda46f5a00e.jpg", "/abbotsford/chef-app/assets/assets/recipes/stp.1061ced765efdcafff2554adc3fc7113.jpg", "/abbotsford/chef-app/assets/assets/specials/sample-chalkboard.e7b4e4450a8483d4219bc6a214158d8f.jpg", "/abbotsford/chef-app/assets/assets/brand/souters.f4c58d9349b6e1700fe5abcc9e9b665c.png", "/abbotsford/chef-app/assets/assets/brand/kirkton-hero.9d0837b292c2f4f30f4521d806bb28c3.png", "/abbotsford/chef-app/assets/assets/brand/wildings-hero-logo-text.4661e4b935726f2511f9c17a1567c89a.png", "/abbotsford/chef-app/assets/assets/brand/mrbasrais.7cc4086dd12ace82529795f1c9f8c900.png", "/abbotsford/chef-app/assets/assets/brand/yasmins-hero.a5aef62e37dfcecbe0afc056186f4ad9.png", "/abbotsford/chef-app/assets/assets/brand/cecchinis.ebf752fef363247848ae7c0d91938765.png", "/abbotsford/chef-app/assets/assets/brand/anchorage.fea5ce2f6fd18bf2950aa21c0980ed8e.png", "/abbotsford/chef-app/assets/assets/brand/3idiots.df4a76d2130f0e5b0042f06a8c88693a.png", "/abbotsford/chef-app/assets/assets/brand/brae.8de9e89ac30966c6669de990370d8e40.png", "/abbotsford/chef-app/assets/assets/brand/williewastles-hero.b9d53d27b66f903b5618a7177b2ffad4.png", "/abbotsford/chef-app/assets/assets/brand/smokinggoat.fff2a9a694b41fed68c80a2c9bfe65da.png", "/abbotsford/chef-app/assets/assets/brand/wildings.076f4fcd06d19a0af0205c410f461b14.png", "/abbotsford/chef-app/assets/assets/brand/pizzaioli.db8c000b62ee407121aa8b90ce45e170.png", "/abbotsford/chef-app/assets/assets/brand/drunkencoo.272f746bf13376f503acd81a524a7998.png", "/abbotsford/chef-app/assets/assets/brand/yasmins.8482602e9f0a965655924835625cb02b.png", "/abbotsford/chef-app/assets/assets/brand/greenside-hero.1caec5a6cb939434cccb5f3a613b50f8.png", "/abbotsford/chef-app/assets/assets/brand/williewastles.055a77893ced99bf3a6c5402ba5baac6.png", "/abbotsford/chef-app/assets/assets/brand/rupeeroom-hero.969fa372add526aaacf3a6c009b8ac92.png", "/abbotsford/chef-app/assets/assets/brand/rupeeroom.689e6fb536dc0845eeb174a1ec7bd346.png", "/abbotsford/chef-app/assets/assets/brand/abbotsford-hero.78fcb8ee06ee22c4ca659c9254db7512.png", "/abbotsford/chef-app/assets/assets/brand/kirkmichael-hero.63b13cde7fd82eb622622b39ac80c394.png", "/abbotsford/chef-app/assets/assets/brand/pizzaioli-hero.1896657c08264cefb49b401891d5448d.png", "/abbotsford/chef-app/assets/assets/brand/kirkmichael.63b13cde7fd82eb622622b39ac80c394.png", "/abbotsford/chef-app/assets/assets/brand/saltmarsh.85a6a65732635e5148478d743d9ca884.png", "/abbotsford/chef-app/assets/assets/brand/mrbasrais-hero.4ce74641cfcf52d099157c84005b9d2a.png", "/abbotsford/chef-app/assets/assets/brand/anchorage-hero.0450b828e4f9c1f4456240096598f6f5.png", "/abbotsford/chef-app/assets/assets/brand/kirkton.bcf8d846df4861474d224a7a77f498fb.png", "/abbotsford/chef-app/assets/assets/brand/3idiots-hero.77d66ccb53ec1835c3b8a838e9bcfb5a.png", "/abbotsford/chef-app/assets/assets/brand/abbotsford.b26602bba5ce4969733c5422a45ad053.png", "/abbotsford/chef-app/assets/assets/brand/greenside.9d1556db97dcb903a3c57e2063ee2255.png", "/abbotsford/chef-app/assets/assets/brand/drunkencoo-hero.7c01fed6cb075a3a8e4f969bff1cf103.png", "/abbotsford/chef-app/assets/assets/brand/smokinggoat-hero.b2ae48c4a1fcf2521ae9ff58435a6649.png", "/abbotsford/chef-app/assets/assets/brand/cecchinis-hero.f77780fcc94fd668cf35d66d6dc52d81.png", "/abbotsford/chef-app/assets/node_modules/expo-router/assets/sitemap.412dd9275b6b48ad28f5e3d81bb1f626.png", "/abbotsford/chef-app/assets/node_modules/expo-router/assets/forward.d8b800c443b8972542883e0b9de2bdc6.png", "/abbotsford/chef-app/assets/node_modules/expo-router/assets/unmatched.20e71bdf79e3a97bf55fd9e164041578.png", "/abbotsford/chef-app/assets/node_modules/expo-router/assets/pkg.ab19f4cbc543357183a20571f68380a3.png", "/abbotsford/chef-app/assets/node_modules/expo-router/assets/arrow_down.017bc6ba3fc25503e5eb5e53826d48a8.png", "/abbotsford/chef-app/assets/node_modules/expo-router/assets/file.19eeb73b9593a38f8e9f418337fc7d10.png", "/abbotsford/chef-app/assets/node_modules/expo-router/assets/error.d1ea1496f9057eb392d5bbf3732a61b7.png", "/abbotsford/chef-app/assets/node_modules/expo-router/assets/react-navigation/elements/close-icon.808e1b1b9b53114ec2838071a7e6daa7@3x.png", "/abbotsford/chef-app/assets/node_modules/expo-router/assets/react-navigation/elements/clear-icon.c94f6478e7ae0cdd9f15de1fcb9e5e55@4x.png", "/abbotsford/chef-app/assets/node_modules/expo-router/assets/react-navigation/elements/back-icon.35ba0eaec5a4f5ed12ca16fabeae451d.png", "/abbotsford/chef-app/assets/node_modules/expo-router/assets/react-navigation/elements/clear-icon.c94f6478e7ae0cdd9f15de1fcb9e5e55.png", "/abbotsford/chef-app/assets/node_modules/expo-router/assets/react-navigation/elements/back-icon-mask.0a328cd9c1afd0afe8e3b1ec5165b1b4.png", "/abbotsford/chef-app/assets/node_modules/expo-router/assets/react-navigation/elements/search-icon.286d67d3f74808a60a78d3ebf1a5fb57.png", "/abbotsford/chef-app/assets/node_modules/expo-router/assets/react-navigation/elements/clear-icon.c94f6478e7ae0cdd9f15de1fcb9e5e55@2x.png", "/abbotsford/chef-app/assets/node_modules/expo-router/assets/react-navigation/elements/close-icon.808e1b1b9b53114ec2838071a7e6daa7@4x.png", "/abbotsford/chef-app/assets/node_modules/expo-router/assets/react-navigation/elements/clear-icon.c94f6478e7ae0cdd9f15de1fcb9e5e55@3x.png", "/abbotsford/chef-app/assets/node_modules/expo-router/assets/react-navigation/elements/close-icon.808e1b1b9b53114ec2838071a7e6daa7.png", "/abbotsford/chef-app/assets/node_modules/expo-router/assets/react-navigation/elements/close-icon.808e1b1b9b53114ec2838071a7e6daa7@2x.png", "/abbotsford/chef-app/assets/node_modules/@expo-google-fonts/poppins/500Medium/Poppins_500Medium.bf59c687bc6d3a70204d3944082c5cc0.ttf", "/abbotsford/chef-app/assets/node_modules/@expo-google-fonts/poppins/700Bold/Poppins_700Bold.08c20a487911694291bd8c5de41315ad.ttf", "/abbotsford/chef-app/assets/node_modules/@expo-google-fonts/poppins/600SemiBold/Poppins_600SemiBold.6f1520d107205975713ba09df778f93f.ttf", "/abbotsford/chef-app/assets/node_modules/@expo-google-fonts/poppins/400Regular/Poppins_400Regular.093ee89be9ede30383f39a899c485a82.ttf", "/abbotsford/chef-app/_expo/static/js/web/index-ba5aea4e23e402619315d92ef1e4fc6c.js", "/abbotsford/chef-app/_expo/static/js/web/gift-791c64f5dbcb5e9b9629af9241dde456.js", "/abbotsford/chef-app/_expo/static/js/web/index-708cc108b14a03d1e55d135c08408edf.js", "/abbotsford/chef-app/_expo/static/js/web/[oid]-0ef90855abb82d22ac5def655ebb19b6.js", "/abbotsford/chef-app/_expo/static/js/web/merch-77ea1815cef4942701820887c797ac92.js", "/abbotsford/chef-app/_expo/static/js/web/index-d72f0e09722c49318a402489e965ec4a.js", "/abbotsford/chef-app/_expo/static/js/web/feedback-e234bfa389c6fd89a2e9f35bd3515c4d.js", "/abbotsford/chef-app/_expo/static/js/web/index-0d5420913a09234192e03fb64f496fd4.js", "/abbotsford/chef-app/_expo/static/js/web/index-b2fb0e8ee9c9e5267d8b0725148d8bf3.js", "/abbotsford/chef-app/_expo/static/js/web/__expo-metro-runtime-8c088df87a31e4e6accd81c554ec290d.js", "/abbotsford/chef-app/_expo/static/js/web/index-4caab44ee144794fe5f1c5f3fbaed93d.js", "/abbotsford/chef-app/_expo/static/js/web/_layout-28f52c5d547984f57d779d2d1595deac.js", "/abbotsford/chef-app/_expo/static/js/web/__common-d92ed2b513b48a7e75fdf07ee4f937c8.js", "/abbotsford/chef-app/_expo/static/js/web/[did]-d0ec4f21f40eb7b8eb13e49d83178ff4.js", "/abbotsford/chef-app/_expo/static/js/web/+not-found-a85f4163079f520711a9e40e645ca875.js", "/abbotsford/chef-app/_expo/static/js/web/profile-94f3e7175fc7efdfa4351ecc255fb11b.js", "/abbotsford/chef-app/_expo/static/js/web/basket-c05ffa92d4d6d13484ce78275193c02c.js", "/abbotsford/chef-app/_expo/static/js/web/index-18a42003614e46ed29f029ff3e81efd8.js", "/abbotsford/chef-app/_expo/static/js/web/[section]-2201675add2ff7b9966ea9d886c9adf3.js", "/abbotsford/chef-app/_expo/static/js/web/offers-31ec634ef9aa42a8856b1215ab24e6f3.js", "/abbotsford/chef-app/_expo/static/js/web/refer-281b0170b80b5db0e1402a8c4d823a68.js", "/abbotsford/chef-app/_expo/static/js/web/book-34e99aaf0197899dc09c20d6bb54139f.js", "/abbotsford/chef-app/_expo/static/js/web/index-0a34312c3724df867c229ae4363d5bf9.js", "/abbotsford/chef-app/_expo/static/js/web/waitlist-0820a9a3f8a549bf0d6f432f6a7ad617.js", "/abbotsford/chef-app/_expo/static/js/web/[token]-060d0a0e0a07c4da23ca6d5b04c35e87.js", "/abbotsford/chef-app/_expo/static/js/web/loyalty-bb43e2009908082ac56ab35a52b228ca.js", "/abbotsford/chef-app/_expo/static/js/web/index-e9112f8ce9e859f928720bf6bff6ea9e.js", "/abbotsford/chef-app/_expo/static/js/web/demo-bb0072f641fdd92aa99cba5bc91fc36d.js", "/abbotsford/chef-app/_expo/static/js/web/[n]-21ee7870b018e4360f6e825c15dd672b.js", "/abbotsford/chef-app/_expo/static/js/web/whatson-6498b8821e66bd4aa1639b57afb933a3.js", "/abbotsford/chef-app/_expo/static/js/web/index-a7e511353fde4e4907f278d874667ffb.js", "/abbotsford/chef-app/_expo/static/js/web/lost-cceda4c454fce783fcc4c1cdf454f0cd.js"];
2
  self.addEventListener('install',e=>e.waitUntil(caches.open(V).then(c=>Promise.all(P.map(u=>fetch(u).then(r=>{if(!r.ok)throw Error('cache');return c.put(u,r)})))).then(()=>self.skipWaiting())));
3
  self.addEventListener('activate',e=>e.waitUntil(caches.keys().then(ks=>Promise.all(ks.filter(k=>k.startsWith('cc-abbotsford-chef-')&&k!==V).map(k=>caches.delete(k)))).then(()=>self.clients.claim())));
4
  self.addEventListener('fetch',e=>{const u=new URL(e.request.url);if(e.request.method!=='GET'||u.origin!==location.origin||!u.pathname.startsWith(B))return;if(e.request.mode==='navigate'){e.respondWith(fetch(e.request).then(r=>r.ok?r:caches.match(B+'index.html')).catch(()=>caches.match(B+'index.html')));return;}e.respondWith(caches.match(e.request).then(r=>r||fetch(e.request)));});
abbotsford/customer-app/_expo/static/js/web/+not-found-a85f4163079f520711a9e40e645ca875.js ADDED
@@ -0,0 +1 @@
 
 
1
+ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return c}});var t=r(d[0]);r(d[1]);var n=r(d[2]),u=r(d[3]);function c(){return(0,u.jsx)(t.Redirect,{href:n.ENTRY[n.APP_VARIANT]})}},802,[805,31,807,25]);
abbotsford/customer-app/_expo/static/js/web/[did]-d0ec4f21f40eb7b8eb13e49d83178ff4.js ADDED
@@ -0,0 +1 @@
 
 
1
+ __d(function(_g,_r,i,_a,_m,_e,_d){"use strict";function e(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(_e,'__esModule',{value:!0}),Object.defineProperty(_e,"default",{enumerable:!0,get:function(){return b}});var n=_r(_d[0]),t=_r(_d[1]),s=_r(_d[2]),a=e(_r(_d[3])),l=e(_r(_d[4])),r=_r(_d[5]),o=_r(_d[6]),d=_r(_d[7]),c=_r(_d[8]),u=_r(_d[9]),h=_r(_d[10]),g=_r(_d[11]),p=_r(_d[12]),f=_r(_d[13]);function b(){const{rid:e,did:b}=(0,t.useLocalSearchParams)(),j=(0,h.useRestaurant)(e),x=(0,h.useMenu)(e).find(e=>e.id===b),y=(0,h.useCustomer)(),m=(0,h.useRecipeCards)(e).find(e=>e.id===x?.recipeCardId),k=m?.signOff&&m.photo?(0,g.recipeCards)().photoSource(m.photo):null,v=(0,h.useStore)(e=>e.addLine),w=(0,n.useTakeawayMenu)(n=>n.byVenue[e]),S=(0,h.useStore)(n=>n.basket.restaurantId===e&&'table'===n.basket.mode),[C,B]=(0,s.useState)(()=>(x?.optionGroups??[]).filter(e=>e.required).map(e=>e.choices[0].id)),[$,I]=(0,s.useState)(1),[P,T]=(0,s.useState)(''),[L,O]=(0,s.useState)(!1),[D,A]=(0,s.useState)(!1),[M,R]=(0,s.useState)(!1),[q,_]=(0,s.useState)(!1),N=(0,s.useMemo)(()=>x?(0,c.effectiveAllergens)(x,C):{},[x,C]);if(!j||!x)return(0,f.jsx)(d.Screen,{title:"Not found",children:(0,f.jsx)(d.T,{children:"Dish not found."})});const G=(0,c.conflictsFor)(N,y.allergies),Y=(x.price??0)+(x.optionGroups??[]).flatMap(e=>e.choices).filter(e=>C.includes(e.id)).reduce((e,n)=>e+n.priceDelta,0),z=S||j.fictional?'on':(0,n.takeawayAvail)(x,w),F=x.soldOut||!x.signOff||null===x.price||'on'!==z,Q=(e,n)=>{const t=x.optionGroups.find(n=>n.id===e);B(e=>{const s=t.choices.map(e=>e.id);return t.multi?e.includes(n)?e.filter(e=>e!==n):[...e,n]:e.includes(n)&&!t.required?e.filter(e=>e!==n):[...e.filter(e=>!s.includes(e)),n]})},V=e=>{h.useStore.getState().basket.restaurantId!==j.id&&h.useStore.getState().startBasket(j.id,'takeaway'),v({itemId:x.id,qty:$,choiceIds:C,notes:P,override:e?{allergens:G.contains,at:(new Date).toISOString()}:void 0}),O(!1),_(!0)};return(0,f.jsxs)(d.Screen,{title:x.name,subtitle:j.name,right:(0,f.jsx)(o.BasketButton,{}),children:[k?(0,f.jsx)(a.default,{testID:"dish-photo",source:k,accessibilityLabel:`${x.name}${'example'===m?.origin?' (example photo)':''}`,style:{width:'100%',height:200,borderRadius:12},resizeMode:"cover"}):null,(0,f.jsxs)(d.Row,{wrap:!0,gap:6,children:[(0,f.jsx)(d.T,{weight:"bold",size:20,colour:p.colours.gold,children:null===x.price?x.priceNote:(0,u.gbp)(Y)}),x.dietary.map(e=>(0,f.jsx)(d.Badge,{kind:"ok",label:e},e))]}),(0,f.jsx)(d.T,{children:x.description}),G.contains.length?(0,f.jsx)(d.Banner,{kind:"danger",title:`Blocked: contains ${G.contains.map(c.allergenLabel).join(', ')}`,children:`You\u2019ve told us: ${y.allergies.filter(e=>G.contains.includes(e.allergen)).map(e=>`${(0,c.allergenLabel)(e.allergen)} \u2014 ${(0,c.severityLabel)(e.severity)}`).join('; ')}. This dish can\u2019t be added unless you deliberately override (for example, ordering for someone else).`}):null,G.may.length?(0,f.jsx)(d.Banner,{kind:"warn",title:`Warning: may contain ${G.may.map(c.allergenLabel).join(', ')}`,children:"Cross-contact is possible (e.g. shared fryer). Please speak to staff before ordering."}):null,(x.optionGroups??[]).map(e=>(0,f.jsxs)(d.Card,{children:[(0,f.jsxs)(d.T,{weight:"semibold",children:[e.name,e.required?' (required)':' (optional)']}),(0,f.jsx)(d.Row,{wrap:!0,gap:6,children:e.choices.map(n=>(0,f.jsx)(d.Chip,{label:n.label,sub:n.priceDelta?`+${(0,u.gbp)(n.priceDelta)}`:void 0,selected:C.includes(n.id),onPress:()=>Q(e.id,n.id)},n.id))})]},e.id)),(0,f.jsx)(d.Card,{children:(0,f.jsx)(r.AllergenPanel,{item:x,map:N,declared:y.allergies})}),j.fictional?null:(0,f.jsx)(d.AllergenNotice,{phone:j.phone}),(0,f.jsx)(d.Field,{label:"Notes for the kitchen (optional)",placeholder:"e.g. no gherkins",value:P,onChangeText:T}),(0,f.jsxs)(d.Row,{style:{justifyContent:'space-between'},children:[(0,f.jsx)(d.T,{weight:"semibold",children:"Quantity"}),(0,f.jsx)(d.Stepper,{value:$,onChange:I,label:"quantity"})]}),q?(0,f.jsx)(d.Banner,{kind:"success",title:"Added to basket",children:G.contains.length?'Allergy override recorded \u2014 the kitchen will see a large allergy alert.':'Carry on browsing or go to your basket.'}):null,F?(0,f.jsx)(d.Banner,{kind:"warn",children:x.soldOut||'sold-out'===z?'Sold out today.':'off'===z&&x.signOff&&null!==x.price?'This dish isn\u2019t on the takeaway menu. You can have it when you eat in.':x.signOff?'Price on the specials board \u2014 ask staff.':'Not available to order online until the head chef signs off its allergens.'}):G.contains.length?(0,f.jsxs)(l.default,{style:{gap:8},children:[(0,f.jsx)(d.Button,{kind:"secondary",label:"Choose something else",onPress:()=>t.router.back()}),(0,f.jsx)(d.Button,{kind:"danger",label:"Override and add anyway\u2026",onPress:()=>{A(!1),R(!1),O(!0)},testID:"override-open"})]}):(0,f.jsxs)(d.Row,{gap:8,children:[(0,f.jsx)(d.Button,{style:{flex:1},label:`Add ${$} to basket \xb7 ${(0,u.gbp)(Y*$)}`,onPress:()=>V(!1),testID:"add-to-basket"}),q?(0,f.jsx)(d.Button,{kind:"secondary",label:"Basket",onPress:()=>t.router.push('/customer/basket')}):null]}),(0,f.jsxs)(d.Sheet,{visible:L,onClose:()=>O(!1),title:"Allergy override",children:[(0,f.jsx)(d.Banner,{kind:"danger",title:`${x.name} contains ${G.contains.map(c.allergenLabel).join(', ')}`,children:`Your profile says: ${y.allergies.filter(e=>G.contains.includes(e.allergen)).map(e=>`${(0,c.allergenLabel)(e.allergen)} \u2014 ${(0,c.severityLabel)(e.severity)}`).join('; ')}.`}),(0,f.jsx)(d.Toggle,{label:"I understand this dish contains an allergen I have declared",value:D,onChange:A}),(0,f.jsx)(d.Toggle,{label:"It is for someone without this allergy, or I have spoken to staff",value:M,onChange:R}),(0,f.jsx)(d.Muted,{children:"The override is logged and shown to the kitchen as an allergy alert that must be acknowledged."}),(0,f.jsx)(d.Button,{kind:"danger",disabled:!D||!M,label:"Confirm override and add",onPress:()=>V(!0),testID:"override-confirm"})]})]})}},779,[836,805,31,197,128,837,838,818,819,820,823,839,825,25]);
abbotsford/customer-app/_expo/static/js/web/[n]-21ee7870b018e4360f6e825c15dd672b.js ADDED
@@ -0,0 +1 @@
 
 
1
+ __d(function(g,_r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return f}});var t=_r(d[0]),r=_r(d[1]),n=_r(d[2]),o=_r(d[3]),u=_r(d[4]),c=_r(d[5]),s=_r(d[6]),l=_r(d[7]);function f(){const{n:f,r:b}=(0,r.useLocalSearchParams)(),E=(0,u.useStore)(t=>t.startBasket),[_,h]=(0,n.useState)(!1),S=b??c.VENUE_RID,j=(0,u.useOrderAtTable)(S),I=(0,s.guestServer)();return(0,n.useEffect)(()=>{t.LIVE_VENUE_BUILD||I||(j&&E(S,'table',String(f)),h(!0))},[S,f,j,I]),t.LIVE_VENUE_BUILD||I?(0,l.jsx)(o.Screen,{title:"Order at the table",children:(0,l.jsx)(o.Banner,{kind:"demo",title:"Scan the code on your table",children:"To order from your table, scan the QR code printed on it. Or order at the bar."})}):_?(0,l.jsx)(r.Redirect,{href:`/customer/${S}`}):null}},795,[842,805,31,818,823,5,845,25]);
abbotsford/customer-app/_expo/static/js/web/[oid]-34de93199ed1b45f11064148f5365bb9.js ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ __d(function(g,_r,_i,a,m,_e,d){"use strict";Object.defineProperty(_e,'__esModule',{value:!0}),Object.defineProperty(_e,"default",{enumerable:!0,get:function(){return f}});var e,t=_r(d[0]),l=_r(d[1]),s=_r(d[2]),r=_r(d[3]),n=(e=r)&&e.__esModule?e:{default:e},o=_r(d[4]),i=_r(d[5]),c=_r(d[6]),u=_r(d[7]),h=_r(d[8]),p=_r(d[9]),y=_r(d[10]),b=_r(d[11]),j=_r(d[12]);const x=[['new','Placed'],['acknowledged','Accepted'],['preparing','Cooking'],['ready','Ready to collect'],['collected','Collected']],w=[['new','Sent'],['acknowledged','Accepted'],['preparing','Cooking'],['served','Food out'],['closed','Paid']];function f(){const{oid:e}=(0,l.useLocalSearchParams)(),r=(0,p.useOrder)(e),f=(0,p.useRestaurant)(r?.restaurantId),[k,T]=(0,s.useState)(0),[S,C]=(0,s.useState)(''),[v,M]=(0,s.useState)(!1),[P,A]=(0,s.useState)(0),[R,$]=(0,s.useState)(r?.split?.ways??1);if(!r||!f)return(0,j.jsx)(i.Screen,{title:"Order",children:(0,j.jsx)(i.T,{children:"Order not found."})});const O='takeaway'===r.type?x:w,I=Math.max(0,O.findIndex(([e])=>e===r.status)),N=Math.round(r.subtotal*P/100),B='table'===r.type?r.subtotal+(r.split?r.tip:N):r.total,_=B-r.paid,H=r.split?.ways??R,D=r.split?.paidShares??0,F=Math.ceil(B/H),q='collected'===r.status||'closed'===r.status;return(0,j.jsxs)(i.Screen,{title:`Order ${r.ref}`,subtitle:`${f.name} \xb7 ${'table'===r.type?`${(0,t.tableNumbers)(r.tableNo)}`:`Collection at ${r.slotTime?(0,h.hm)(new Date(r.slotTime)):'\u2014'}`}`,children:['takeaway'===r.type?(0,j.jsx)(b.TakeawayPayCard,{o:r,phone:f.phone}):null,'takeaway'===r.type&&'awaiting_payment'!==r.status&&'cancelled'!==r.status?(0,j.jsx)(i.Banner,{kind:"success",title:'ready'===r.status?'Your order is ready!':'Order placed',children:'ready'===r.status?'Head to the bar and give your order number. Staff will check allergies with you at handover.':`Show order number ${r.ref} at the bar when you arrive.`}):null,'awaiting_payment'===r.status||'cancelled'===r.status?null:(0,j.jsxs)(i.Card,{children:[(0,j.jsx)(i.H2,{children:"Status"}),O.map(([e,t],l)=>(0,j.jsxs)(i.Row,{gap:10,children:[(0,j.jsx)(n.default,{style:{width:22,height:22,borderRadius:11,backgroundColor:l<=I?y.colours.gold:y.colours.surface2,borderWidth:1,borderColor:y.colours.gold}}),(0,j.jsx)(i.T,{weight:l===I?'semibold':'regular',colour:l<=I?y.colours.text:y.colours.muted,children:t})]},e)),r.allergyAck?(0,j.jsxs)(i.Muted,{children:["Kitchen signed off your allergies (",r.allergyAck.by,", ",(0,h.hm)(new Date(r.allergyAck.at)),")"]}):r.allergies.length?(0,j.jsx)(i.Muted,{children:"Waiting for the kitchen to sign off your allergies\u2026"}):null,'takeaway'!==r.type||q?null:(0,j.jsxs)(i.Row,{gap:8,children:[(0,j.jsx)(i.Button,{small:!0,kind:'on-my-way'===r.customerSignal?'primary':'secondary',label:"On my way",onPress:()=>p.repo.orders.customerSignal(r.id,'on-my-way')}),(0,j.jsx)(i.Button,{small:!0,kind:'here'===r.customerSignal?'primary':'secondary',label:"I\u2019m here",onPress:()=>p.repo.orders.customerSignal(r.id,'here')})]})]}),(0,j.jsxs)(i.Card,{children:[(0,j.jsx)(i.H2,{children:"Items"}),r.lines.map((e,t)=>(0,j.jsxs)(n.default,{children:[(0,j.jsxs)(i.Row,{style:{justifyContent:'space-between'},children:[(0,j.jsxs)(i.T,{style:{flex:1},children:[e.qty,"\xd7 ",e.name]}),(0,j.jsx)(i.T,{children:(0,u.gbp)(e.unitPrice*e.qty)})]}),e.choices.length?(0,j.jsx)(i.Muted,{children:e.choices.join(' \xb7 ')}):null,e.overridden?(0,j.jsx)(i.Badge,{kind:"red",label:`Allergy override: ${e.contains.map(c.allergenLabel).join(', ')}`}):null]},t)),(0,j.jsxs)(i.Row,{style:{justifyContent:'space-between'},children:[(0,j.jsx)(i.Muted,{children:"Subtotal"}),(0,j.jsx)(i.T,{children:(0,u.gbp)(r.subtotal)})]}),r.giftCardApplied?(0,j.jsxs)(i.Row,{style:{justifyContent:'space-between'},children:[(0,j.jsx)(i.Muted,{children:"Of which gift card"}),(0,j.jsxs)(i.T,{colour:y.colours.ok,children:["\u2212",(0,u.gbp)(r.giftCardApplied)]})]}):null,r.tip?(0,j.jsxs)(i.Row,{style:{justifyContent:'space-between'},children:[(0,j.jsx)(i.Muted,{children:"Tip"}),(0,j.jsx)(i.T,{children:(0,u.gbp)(r.tip)})]}):null,(0,j.jsxs)(i.Row,{style:{justifyContent:'space-between'},children:[(0,j.jsx)(i.T,{weight:"semibold",children:"Paid (test, no real money)"}),(0,j.jsx)(i.T,{weight:"semibold",colour:y.colours.gold,children:(0,u.gbp)(r.paid)})]})]}),'table'===r.type&&'closed'!==r.status&&'cancelled'!==r.status?(0,j.jsxs)(i.Card,{highlight:y.colours.gold,children:[(0,j.jsxs)(i.H2,{children:["Your bill \u2014 ",(0,t.tableNumbers)(r.tableNo)]}),r.split?(0,j.jsxs)(j.Fragment,{children:[(0,j.jsxs)(i.T,{children:["Total ",(0,u.gbp)(B)," \xb7 split ",H," way",H>1?'s':''," \xb7 ",(0,u.gbp)(F)," each"]}),(0,j.jsxs)(i.T,{children:["Shares paid: ",D," of ",H," \xb7 remaining ",(0,u.gbp)(_)]}),(0,j.jsx)(i.Muted,{children:"Pay with a member of staff at your table. Online card payment for the table bill isn\u2019t set up."})]}):(0,j.jsxs)(j.Fragment,{children:[(0,j.jsx)(i.T,{weight:"semibold",children:"Add a tip?"}),(0,j.jsx)(i.Row,{wrap:!0,children:[0,10,12.5,15].map(e=>(0,j.jsx)(i.Chip,{label:e?`${e}%`:'No tip',selected:P===e,onPress:()=>A(e)},e))}),(0,j.jsx)(i.Muted,{children:"Tips go to staff under the restaurant\u2019s tipping policy (Employment (Allocation of Tips) Act 2023)."}),(0,j.jsxs)(i.Row,{style:{justifyContent:'space-between'},children:[(0,j.jsx)(i.T,{weight:"semibold",children:"Split evenly between"}),(0,j.jsx)(i.Stepper,{value:R,onChange:$,min:1,max:8,label:"people"})]}),(0,j.jsxs)(i.T,{children:["Total ",(0,u.gbp)(r.subtotal+N),R>1?` \xb7 ${(0,u.gbp)(Math.ceil((r.subtotal+N)/R))} each`:'']}),(0,j.jsx)(i.Button,{label:"Get the bill",onPress:()=>p.repo.orders.setSplit(r.id,R,N),testID:"get-bill"})]})]}):null,!q||r.rated||v?null:(0,j.jsxs)(i.Card,{highlight:y.colours.gold,children:[(0,j.jsx)(i.H2,{children:"How was everything?"}),(0,j.jsxs)(i.Muted,{children:["One tap \u2014 this goes privately to ",f.name," only, never published."]}),(0,j.jsx)(o.Stars,{value:k,onChange:T}),k?(0,j.jsx)(i.Field,{label:"Anything to add? (optional)",value:S,onChangeText:C}):null,(0,j.jsx)(i.Button,{label:"Send feedback",disabled:!k,onPress:()=>{p.repo.feedback.add({restaurantId:f.id,orderId:r.id,customerId:r.customerId,customerName:r.customerName,stars:k,comment:S,context:'table'===r.type?`${(0,t.tableNumbers)(r.tableNo)}`:`Takeaway ${r.ref}`}),M(!0)},testID:"send-rating"})]}),v||r.rated?(0,j.jsx)(i.Banner,{kind:"success",children:"Thanks \u2014 your feedback went privately to the restaurant."}):null,q?(0,j.jsx)(i.Button,{kind:"secondary",label:"View stamp card",onPress:()=>l.router.push(`/customer/${f.id}/loyalty`)}):null]})}},792,[812,805,31,128,840,818,819,820,822,823,825,882,25]);
2
+ __d(function(g,_r,i,a,m,_e,d){"use strict";function e(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(_e,'__esModule',{value:!0}),_e.TakeawayPayCard=function({o:e,phone:y}){const[f,k]=(0,n.useState)(Date.now()),[w,x]=(0,n.useState)(!1),[j,b]=(0,n.useState)(''),[P,v]=(0,n.useState)(null),_=(0,n.useRef)(!1),B=(0,c.payView)(e,f);(0,n.useEffect)(()=>{const e=setInterval(()=>k(Date.now()),1e3);return()=>clearInterval(e)},[]);const T='pay'===B.kind||'expired'===B.kind&&_.current&&'awaiting_payment'===e.status;(0,n.useEffect)(()=>{if(!T||!_.current)return;const n=setInterval(()=>{(0,h.checkPaid)(e.id)},1e4),r=t.default.addEventListener('change',n=>{'active'===n&&(0,h.checkPaid)(e.id)});return()=>{clearInterval(n),r.remove()}},[T,e.id]);if('none'===B.kind)return null;if('sending'===B.kind)return(0,p.jsx)(s.Banner,{kind:"warn",title:"Saving your order\u2026",children:"Sending it to the restaurant. Card payment opens in a moment."});if('refused'===B.kind)return(0,p.jsxs)(s.Banner,{kind:"danger",title:"The restaurant couldn\u2019t take this order",children:[(0,p.jsx)(s.T,{size:14,colour:"#FFE3DF",children:`${B.reason} Nothing has been charged.`}),(0,p.jsx)(s.Button,{small:!0,kind:"secondary",label:"Back to the menu",onPress:()=>o.router.replace(`/customer/${e.restaurantId}`)})]});if('paid'===B.kind)return(0,p.jsx)(s.Banner,{kind:"success",title:`Paid ${(0,l.gbp)(B.amount)} by card`,children:B.late?'Your payment came in after the time ran out. The restaurant has your order and will contact you if the collection time needs to change.':'Your order has gone to the kitchen.'});if('expired'===B.kind)return(0,p.jsxs)(s.Banner,{kind:"warn",title:'awaiting_payment'===e.status?'Checking your payment\u2026':'Time ran out: order not sent',children:[(0,p.jsx)(s.T,{size:14,children:'awaiting_payment'===e.status?'We\u2019re checking with the payment page. If you paid, your order will show as paid shortly.':`Nothing has been charged. You can order again${y?` or ring ${y}`:''}.`}),'awaiting_payment'!==e.status?(0,p.jsx)(s.Button,{small:!0,kind:"secondary",label:"Order again",onPress:()=>o.router.replace(`/customer/${e.restaurantId}`)}):null]});return(0,p.jsxs)(s.Card,{highlight:u.colours.gold,children:[(0,p.jsx)(s.H2,{children:"Pay to send your order"}),(0,p.jsxs)(s.T,{children:["Your order goes to the kitchen once it\u2019s paid. Time left to pay: ",(0,p.jsx)(s.T,{weight:"bold",colour:B.secondsLeft<120?u.colours.red:u.colours.gold,children:(0,c.mmss)(B.secondsLeft)})]}),(0,p.jsx)(s.Button,{label:w?'Opening the payment page\u2026':`Pay ${(0,l.gbp)(e.total)} by card`,disabled:w||B.secondsLeft<120,onPress:async()=>{x(!0),b('');const n='undefined'!=typeof window?window.open('','_blank'):null,t=await(0,h.getPayLink)(e.id);if(x(!1),!t.ok)return n?.close(),void b(t.message);if(v(t.url),_.current=!0,n)try{return void(n.location.href=t.url)}catch{}},testID:"pay-card"}),B.secondsLeft<120?(0,p.jsx)(s.Muted,{children:"Not enough time left to pay. Wait for this order to expire, then order again."}):null,P?(0,p.jsx)(s.Button,{small:!0,kind:"secondary",label:"Open the payment page again",onPress:()=>{'undefined'!=typeof window?window.open(P,'_blank'):r.default.openURL(P)}}):null,P?(0,p.jsx)(s.Button,{small:!0,kind:"ghost",label:"I\u2019ve paid: check now",onPress:()=>{(0,h.checkPaid)(e.id)}}):null,j?(0,p.jsx)(s.T,{size:14,colour:u.colours.red,children:j}):null,(0,p.jsx)(s.Muted,{children:"Secure card payment on the restaurant\u2019s website. Apple Pay and Google Pay may be offered there."})]})};var n=_r(d[0]),t=e(_r(d[1])),r=e(_r(d[2]));_r(d[3]);var o=_r(d[4]),s=_r(d[5]),l=_r(d[6]),u=_r(d[7]),c=_r(d[8]),h=_r(d[9]),p=_r(d[10])},882,[31,232,240,123,805,818,820,825,836,883,25]);
3
+ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"PAY_OFF",{enumerable:!0,get:function(){return o}}),e.getPayLink=async function(u){try{if(!await(0,n.guestSession)())return{ok:!1,message:'Can\u2019t reach the restaurant. Check your signal and try again.'};const{data:c,error:y}=await(0,t.getSupabase)().functions.invoke('takeaway-pay',{body:{order_id:u}}),f=await s(c,y);return f&&'string'==typeof f.url&&f.url.startsWith('https://')?{ok:!0,url:f.url,expiresAt:String(f.expiresAt??''),amountPence:Number(f.amountPence??0)}:{ok:!1,message:'string'==typeof f?.error?f.error:o}}catch{return{ok:!1,message:o}}},e.checkPaid=async function(o){try{const{data:u,error:c}=await(0,t.getSupabase)().functions.invoke('takeaway-pay-check',{body:{order_id:o}}),y=await s(u,c);return(0,n.nudgeGuestSync)(),y?.off?'off':String(y?.state??'unknown')}catch{return'unknown'}};var t=r(d[0]),n=r(d[1]);const o='Card payment isn\u2019t available right now. Nothing has been charged. Please ring the restaurant.';async function s(t,n){if(t&&'object'==typeof t)return t;const o=n?.context;try{const t=o?.json?await o.json():null;return t&&'object'==typeof t?t:null}catch{return null}}},883,[872,824]);
abbotsford/customer-app/_expo/static/js/web/[section]-2201675add2ff7b9966ea9d886c9adf3.js ADDED
@@ -0,0 +1 @@
 
 
1
+ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return s}});var t=r(d[0]);r(d[1]);var n=r(d[2]),c=r(d[3]),o=r(d[4]),f=r(d[5]);function s(){const{section:s}=(0,t.useLocalSearchParams)();return(0,c.canShow)('chef')?s&&(0,o.chefSectionAllowed)(String(s))?(0,f.jsx)(n.ChefApp,{section:String(s)},String(s)):(0,f.jsx)(t.Redirect,{href:"/kitchen"}):(0,f.jsx)(t.Redirect,{href:c.ENTRY[c.APP_VARIANT]})}},776,[805,31,806,807,808,25]);
abbotsford/customer-app/_expo/static/js/web/[token]-27d64602702848e6f817cb3e11170985.js ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return u}});var t=r(d[0]);r(d[1]);var n=r(d[2]),o=r(d[3]),c=r(d[4]),s=r(d[5]),l=r(d[6]);function u(){const{token:u}=(0,t.useLocalSearchParams)(),h=(0,c.cleanToken)(u);return h?(0,s.guestServer)()?(0,l.jsx)(o.TableOrderLive,{token:h}):(0,l.jsx)(n.Screen,{title:"Order at the table",children:(0,l.jsx)(n.Banner,{kind:"demo",title:"Not connected",children:"This preview isn't connected to a venue, so table orders can't be sent from here."})}):(0,l.jsx)(n.Screen,{title:"Order at the table",children:(0,l.jsx)(n.Banner,{kind:"warn",title:"This code isn't working",children:"Please scan the QR code on your table again, or ask a member of staff."})})}},796,[805,31,818,885,887,845,25]);
2
+ __d(function(g,_r,_i,_a,_m,_e,_d){"use strict";Object.defineProperty(_e,'__esModule',{value:!0}),_e.TableOrderLive=function({token:e}){const[s,m]=(0,l.useState)(null),[x,y]=(0,l.useState)(null),[j,f]=(0,l.useState)([]),[k,w]=(0,l.useState)(null),T=(0,h.useCustomer)(),[C,S]=(0,l.useState)(()=>(T?.allergies??[]).map(e=>e.allergen)),[v,O]=(0,l.useState)(''),[P,R]=(0,l.useState)(''),[I,M]=(0,l.useState)(''),[L,N]=(0,l.useState)(!1),[$,A]=(0,l.useState)(null),[B,D]=(0,l.useState)([]),q=(0,l.useCallback)(async()=>{try{m(await(0,c.tablePublic)(e)),y(null)}catch(e){y((0,d.tableOrderError)(e,'menu'))}},[e]),_=(0,l.useCallback)(async()=>{try{D(await(0,c.myTableOrders)(e))}catch{}},[e]);(0,l.useEffect)(()=>{q(),_();const e=setInterval(()=>{_(),q()},8e3);return()=>clearInterval(e)},[q,_]);const W=s?.menu??[];(0,l.useEffect)(()=>{f(e=>e.filter(e=>W.some(t=>t.id===e.id&&!t.soldOut)))},[s]);const E=(0,l.useMemo)(()=>{const e=new Map;for(const t of W)e.set(t.section,[...e.get(t.section)??[],t]);return[...e.entries()]},[s]),Y=(0,d.cartTotal)(j,W),z='yes'===k?C.map(e=>({allergen:e,severity:T?.allergies?.find(t=>t.allergen===e)?.severity??'allergy'})):[],G=(0,d.allergyClashes)(j,W,z.map(e=>e.allergen)),V=e=>j.find(t=>t.id===e)?.qty??0,F=(e,t)=>f(n=>t<=0?n.filter(t=>t.id!==e):n.some(t=>t.id===e)?n.map(n=>n.id===e?{...n,qty:t}:n):[...n,{id:e,qty:t,note:''}]),H=(e,t)=>f(n=>n.map(n=>n.id===e?{...n,note:t}:n)),J=async()=>{N(!0),A(null);try{const t=await(0,c.sendTableOrder)(e,j,{note:I,name:v,phone:P,allergies:z});f([]),M(''),A({kind:'success',text:t.held?`Order ${t.ref} sent. A member of staff will check it, then it goes to the kitchen.`:`Order ${t.ref} sent to the kitchen.`}),_()}catch(e){A({kind:'warn',text:(0,d.tableOrderError)(e,'send')}),q()}finally{N(!1)}};if(x)return(0,p.jsxs)(o.Screen,{title:"Order at the table",children:[(0,p.jsx)(o.Banner,{kind:"warn",title:"Couldn't open the menu",children:x}),(0,p.jsx)(o.Button,{label:"Try again",onPress:()=>{q()}})]});if(!s)return(0,p.jsx)(o.Screen,{title:"Order at the table",children:(0,p.jsx)(o.Muted,{children:"Opening the menu\u2026"})});if(!s.ok)return(0,p.jsx)(o.Screen,{title:"Order at the table",children:(0,p.jsx)(o.Banner,{kind:"warn",title:"This code isn't working",children:s.reason??'Please ask a member of staff.'})});const K=s.open&&j.length>0&&null!==k&&('none'===k||C.length>0)&&(0,d.nameOk)(v)&&(0,d.phoneOk)(P)&&!L,Q=s.askServer??[],U=[...new Set(Q.map(e=>e.section))],X=L?'Sending\u2026':j.length?null===k?'Answer the allergy question':(0,d.nameOk)(v)?(0,d.phoneOk)(P)?`Send order to the kitchen (${(0,i.gbp)(Y)})`:'Check the phone number':'Add your name to send':'Add a dish to order';return(0,p.jsxs)(o.Screen,{title:`Table ${(0,n.tableNumbers)(s.table)}`,subtitle:s.venueName,footer:s.open?(0,p.jsx)(o.Button,{label:X,disabled:!K,onPress:()=>{J()},testID:"send-table-order-live"}):void 0,children:[(0,p.jsxs)(o.Muted,{center:!0,children:["Tip: add dishes, answer the allergy question, add your name, then send. Staff bring it to table ",(0,n.tableNumbers)(s.table),". ",d.PAY_WORDS]}),s.tip?(0,p.jsx)(o.Banner,{kind:"demo",children:s.tip}):null,s.open?null:(0,p.jsx)(o.Banner,{kind:"warn",title:"Not taking table orders right now",children:s.reason}),s.open&&s.staffAccept&&!B.some(e=>e.accepted)?(0,p.jsx)(o.Muted,{children:"The first order from your phone is checked by a member of staff before it goes to the kitchen."}):null,$?(0,p.jsx)(o.Banner,{kind:$.kind,children:$.text}):null,B.length?(0,p.jsx)(r.default,{testID:"my-table-orders",children:(0,p.jsxs)(o.Card,{children:[(0,p.jsx)(o.T,{weight:"semibold",children:"Your orders at this table"}),B.map(e=>(0,p.jsxs)(r.default,{style:{gap:2,paddingVertical:4},children:[(0,p.jsxs)(o.Row,{style:{justifyContent:'space-between'},children:[(0,p.jsx)(o.T,{children:e.ref}),(0,p.jsx)(o.T,{size:13,colour:'cancelled'===e.status?u.colours.amber:u.colours.gold,children:(0,d.guestStatusWords)(e)})]}),(0,p.jsxs)(o.Muted,{children:[e.lines.map(e=>`${e.qty}\xd7 ${e.name}`).join(', ')," \xb7 ",(0,i.gbp)(e.totalPence)," to pay at the bar or with the server"]})]},e.id))]})}):null,s.open?E.map(([e,t])=>(0,p.jsxs)(r.default,{style:{gap:8},children:[(0,p.jsx)(o.T,{center:!0,size:20,weight:"semibold",colour:u.colours.gold,accessibilityRole:"header",children:e}),t.map(e=>(0,p.jsxs)(o.Card,{children:[(0,p.jsxs)(o.Row,{style:{justifyContent:'space-between',alignItems:'flex-start'},children:[(0,p.jsxs)(r.default,{style:{flex:1,gap:2},children:[(0,p.jsx)(o.T,{weight:"semibold",children:e.name}),e.description?(0,p.jsx)(o.Muted,{children:e.description}):null,(0,p.jsxs)(o.T,{size:13,colour:u.colours.muted,children:[e.allergens.length?`Contains: ${e.allergens.map(a.allergenLabel).join(', ')}`:'No allergens listed: ask staff if unsure',e.mayContain.length?` \xb7 May contain: ${e.mayContain.map(a.allergenLabel).join(', ')}`:'']})]}),(0,p.jsx)(o.T,{weight:"semibold",colour:u.colours.gold,children:(0,i.gbp)(e.pricePence)})]}),e.soldOut?(0,p.jsx)(o.Badge,{kind:"amber",label:"Sold out today"}):V(e.id)?(0,p.jsxs)(o.Row,{style:{justifyContent:'space-between'},children:[(0,p.jsx)(o.Stepper,{value:V(e.id),min:0,max:20,onChange:t=>F(e.id,t),label:e.name}),(0,p.jsx)(o.Button,{small:!0,kind:"ghost",label:"Remove",onPress:()=>F(e.id,0)})]}):(0,p.jsx)(o.Button,{small:!0,kind:"secondary",label:"Add",accessibilityLabel:`Add ${e.name}`,onPress:()=>F(e.id,1)})]},e.id))]},e)):null,s.open&&!W.length?(0,p.jsx)(o.Banner,{kind:"demo",title:"No dishes to order from your phone yet",children:"The kitchen is still checking the allergens on the menu. Please order with your server or at the bar."}):null,s.open&&Q.length?(0,p.jsxs)(r.default,{testID:"table-ask-server",style:{gap:8},children:[(0,p.jsx)(o.T,{center:!0,size:20,weight:"semibold",colour:u.colours.gold,accessibilityRole:"header",children:W.length?'Also on the menu':'On the menu'}),(0,p.jsx)(o.Muted,{center:!0,children:"Ask your server for these. They can't be ordered from your phone yet, while the kitchen checks their allergens."}),U.map(e=>(0,p.jsxs)(o.Card,{children:[(0,p.jsx)(o.T,{center:!0,weight:"semibold",children:e}),Q.filter(t=>t.section===e).map((e,t)=>(0,p.jsxs)(o.Row,{style:{justifyContent:'space-between'},children:[(0,p.jsx)(o.T,{style:{flex:1},children:e.name}),(0,p.jsx)(o.T,{colour:u.colours.muted,children:(0,i.gbp)(e.pricePence)})]},`${e.name}-${t}`))]},e))]}):null,s.open&&j.length?(0,p.jsx)(r.default,{testID:"table-cart",children:(0,p.jsxs)(o.Card,{children:[(0,p.jsx)(o.T,{center:!0,weight:"semibold",accessibilityRole:"header",children:"Review your order"}),j.map(e=>{const n=W.find(t=>t.id===e.id);return(0,p.jsxs)(r.default,{style:{gap:4},children:[(0,p.jsxs)(o.Row,{style:{justifyContent:'space-between'},children:[(0,p.jsxs)(o.T,{children:[e.qty,"\xd7 ",n?.name]}),(0,p.jsx)(o.T,{children:(0,i.gbp)(e.qty*(n?.pricePence??0))})]}),(0,p.jsx)(t.TextInput,{style:b,value:e.note,onChangeText:t=>H(e.id,t),placeholder:"Note for the kitchen (optional), e.g. no onions",placeholderTextColor:u.colours.muted,maxLength:140,accessibilityLabel:`Note for ${n?.name}`,testID:`table-note-${e.id}`})]},e.id)}),(0,p.jsxs)(o.Row,{style:{justifyContent:'space-between'},children:[(0,p.jsx)(o.T,{weight:"semibold",children:"Total"}),(0,p.jsx)(o.T,{weight:"semibold",children:(0,i.gbp)(Y)})]})]})}):null,s.open?(0,p.jsx)(r.default,{testID:"table-allergy",children:(0,p.jsxs)(o.Card,{children:[(0,p.jsx)(o.T,{center:!0,weight:"semibold",children:"Does anyone at the table have a food allergy?"}),(0,p.jsx)(o.Muted,{center:!0,children:"We ask everyone, so the kitchen can keep you safe."}),(0,p.jsxs)(o.Row,{gap:8,style:{justifyContent:'center'},children:[(0,p.jsx)(o.Chip,{label:"No allergies",selected:'none'===k,onPress:()=>w('none')}),(0,p.jsx)(o.Chip,{label:"Yes, allergies",selected:'yes'===k,onPress:()=>w('yes')})]}),'yes'===k?(0,p.jsx)(o.Row,{wrap:!0,gap:6,children:a.ALLERGENS.map(e=>(0,p.jsx)(o.Chip,{label:e.short,selected:C.includes(e.id),onPress:()=>S(t=>t.includes(e.id)?t.filter(t=>t!==e.id):[...t,e.id])},e.id))}):null,G.length?(0,p.jsxs)(o.Banner,{kind:"warn",title:"Check with staff",children:[G.map(e=>e.name).join(', ')," ",G.length>1?'contain':'contains'," or may contain an allergy you picked. The kitchen will see your allergies on the ticket."]}):null]})}):null,s.open?(0,p.jsxs)(o.Card,{children:[(0,p.jsx)(o.T,{center:!0,weight:"semibold",children:"Who's the order for?"}),(0,p.jsx)(t.TextInput,{style:b,value:v,onChangeText:O,placeholder:"Your name (needed)",placeholderTextColor:u.colours.muted,maxLength:40,accessibilityLabel:"Your name, needed",testID:"table-name",autoComplete:"name"}),(0,p.jsx)(t.TextInput,{style:b,value:P,onChangeText:R,placeholder:"Phone number (optional)",placeholderTextColor:u.colours.muted,maxLength:20,keyboardType:"phone-pad",accessibilityLabel:"Phone number, optional",testID:"table-phone",autoComplete:"tel"}),P&&!(0,d.phoneOk)(P)?(0,p.jsx)(o.Muted,{center:!0,children:"Please check the phone number, or leave it blank."}):null,(0,p.jsx)(o.Muted,{center:!0,children:"We only use these for this order."}),(0,p.jsx)(t.TextInput,{style:b,value:I,onChangeText:M,placeholder:"Note for the staff (optional)",placeholderTextColor:u.colours.muted,maxLength:300,accessibilityLabel:"Note for the staff (optional)"})]}):null,(0,p.jsx)(r.default,{testID:"pay-placeholder",children:(0,p.jsxs)(o.Card,{children:[(0,p.jsx)(o.T,{center:!0,weight:"semibold",children:"Paying"}),(0,p.jsx)(o.T,{center:!0,children:d.PAY_WORDS}),(0,p.jsx)(o.Muted,{center:!0,children:"No card details are asked for or kept in this app."})]})})]})};var e,t=_r(_d[0]),n=_r(_d[1]),l=_r(_d[2]),s=_r(_d[3]),r=(e=s)&&e.__esModule?e:{default:e},o=_r(_d[4]),a=_r(_d[5]),i=_r(_d[6]),d=_r(_d[7]),c=_r(_d[8]),h=_r(_d[9]),u=_r(_d[10]),p=_r(_d[11]);const b={borderWidth:1,borderColor:u.colours.border,borderRadius:10,padding:10,color:u.colours.text,backgroundColor:u.colours.surface2}},885,[874,812,31,128,818,819,820,887,886,823,825,25]);
3
+ __d(function(g,_r,i,_a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"tablePublic",{enumerable:!0,get:function(){return s}}),e.sendTableOrder=async function(t,r,a){if(!await(0,n.guestSession)())throw new Error('No connection. Try again when you are back online.');const o=await(0,n.rpc)('guest_table_order_v2',{p_phone:(a.phone??'').trim().slice(0,20)||null,p_token:t,p_lines:r.map(t=>({id:t.id,qty:t.qty,note:t.note.trim().slice(0,140)})),p_note:a.note.trim().slice(0,300)||null,p_allergies:a.allergies.map(t=>({allergen:t.allergen,severity:t.severity})),p_name:a.name.trim().slice(0,40)||null});if(!o||!1===o.ok||!o.id)throw new Error(o?.reason||'This table code isn\u2019t working any more. Please ask a member of staff.');return{id:o.id,ref:o.ref,held:!!o.held,totalPence:o.totalPence}},e.myTableOrders=async function(t){return await(0,n.guestSession)()?await(0,n.rpc)('guest_table_my_orders',{p_token:t})??[]:[]},e.loadTableSettings=async function(){const{data:t,error:n}=await a().from('table_order_settings').select('*').eq('venue_id',o()).maybeSingle();if(n)throw n;return(0,r.fromRow)(t)},e.saveTableSettings=async function(t,n){const{error:s}=await a().from('table_order_settings').upsert({venue_id:o(),...(0,r.toRow)(t),updated_at:(new Date).toISOString(),updated_by:n.slice(0,80)});if(s)throw s},e.listTableCodes=async function(){const{data:t,error:n}=await a().from('table_qr_codes').select('table_no, token, created_at').eq('venue_id',o()).eq('is_on',!0);if(n)throw n;return(t??[]).map(t=>({table:String(t.table_no),token:String(t.token),createdAt:String(t.created_at)})).sort((t,n)=>Number(t.table)-Number(n.table))},Object.defineProperty(e,"tableReadiness",{enumerable:!0,get:function(){return l}}),Object.defineProperty(e,"makeTableCodes",{enumerable:!0,get:function(){return c}}),Object.defineProperty(e,"renewTableCode",{enumerable:!0,get:function(){return u}}),e.watchTableSettings=function(t){const r=n.useSync.getState().venueId;if(!r)return()=>{};const o=a().channel(`tos-${r}-${Math.random().toString(36).slice(2,8)}`).on('postgres_changes',{event:'*',schema:'public',table:'table_order_settings',filter:`venue_id=eq.${r}`},()=>t()).subscribe();return()=>{a().removeChannel(o)}};var t=_r(d[0]),n=_r(d[1]),r=_r(d[2]);const a=()=>(0,t.getSupabase)(),o=()=>{const t=n.useSync.getState().venueId;if(!t)throw new Error('Not connected to the venue yet.');return t},s=t=>(0,n.rpc)('table_public',{p_token:t});const l=()=>(0,n.rpc)('table_order_readiness',{p_venue:o()}),c=t=>(0,n.rpc)('table_qr_make',{p_venue:o(),p_tables:t}),u=t=>(0,n.rpc)('table_qr_renew',{p_venue:o(),p_table:t})},886,[872,824,887]);
abbotsford/customer-app/_expo/static/js/web/__common-62dc618bc7e7f7ce3382df95eac3e0c0.js ADDED
The diff for this file is too large to render. See raw diff
 
abbotsford/customer-app/_expo/static/js/web/_layout-dca323c29b087b4dc8695422b2ba2b49.js ADDED
@@ -0,0 +1,44 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ __d(function(g,r,i,a,m,_e,_d){"use strict";function e(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(_e,'__esModule',{value:!0}),Object.defineProperty(_e,"default",{enumerable:!0,get:function(){return K}});var s=r(_d[0]),t=r(_d[1]);r(_d[2]),r(_d[3]);var o=r(_d[4]),n=r(_d[5]),u=r(_d[6]),l=(function(e){if(e&&e.__esModule)return e;var s={};return e&&Object.keys(e).forEach(function(t){if('default'!==t){var o=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(s,t,o.get?o:{enumerable:!0,get:function(){return e[t]}})}}),s.default=e,s})(r(_d[7])),c=r(_d[8]),d=r(_d[9]),f=e(r(_d[10])),p=e(r(_d[11]));r(_d[12]);var y=e(r(_d[13])),h=e(r(_d[14])),S=r(_d[15]),_=r(_d[16]),O=r(_d[17]),P=r(_d[18]),j=r(_d[19]),v=r(_d[20]),A=r(_d[21]),b=r(_d[22]),x=r(_d[23]),w=r(_d[24]),E=r(_d[25]),C=r(_d[26]),k=r(_d[27]);r(_d[28]);var I=r(_d[29]),R=r(_d[30]),H=r(_d[31]),T=r(_d[32]),F=r(_d[33]),B=r(_d[34]),V=r(_d[35]),N=r(_d[36]),G=r(_d[37]),L=r(_d[38]);const M=r(_d[39]),D=r(_d[40]),U=r(_d[41]),q=r(_d[42]);function K(){const[e]=(0,o.useFonts)({Poppins_400Regular:M,Poppins_500Medium:D,Poppins_600SemiBold:U,Poppins_700Bold:q}),[s,C]=(0,d.useState)(A.useStore.persist.hasHydrated()),[F,B]=(0,d.useState)(x.useOwner.persist.hasHydrated()),V=s&&F;(0,d.useEffect)(()=>{const e=A.useStore.persist.onFinishHydration(()=>C(!0)),s=x.useOwner.persist.onFinishHydration(()=>B(!0));return A.useStore.persist.hasHydrated()&&C(!0),x.useOwner.persist.hasHydrated()&&B(!0),()=>{e(),s()}},[]),(0,d.useEffect)(()=>{if('undefined'==typeof window)return;const e=e=>{e.key===(0,S.venueKey)(A.useStore.persist.getOptions().name??'')&&(0,k.quietly)(()=>A.useStore.persist.rehydrate()),e.key===(0,S.venueKey)(b.useFloor.persist.getOptions().name??'')&&(0,k.quietly)(()=>b.useFloor.persist.rehydrate()),e.key===(0,S.venueKey)(n.useBlocks.persist.getOptions().name??'')&&(0,k.quietly)(()=>n.useBlocks.persist.rehydrate())};return window.addEventListener('storage',e),()=>window.removeEventListener('storage',e)},[]),(0,d.useEffect)(()=>{V&&x.useOwner.getState().syncRoster()},[V]),(0,d.useEffect)(()=>{V&&(0,t.startAppSync)()},[V]);const N=e&&V,G=(0,E.useSignedOutGate)(),K=(0,u.usePathname)(),Q=N&&!(0,P.isAllowedPath)(K||'/');return(0,d.useEffect)(()=>{if(!Q)return;const e=setTimeout(()=>u.router.replace(P.ENTRY[P.APP_VARIANT]),0);return()=>clearTimeout(e)},[Q,K]),(0,d.useEffect)(()=>{N&&l.hideAsync().catch(()=>{})},[N]),N?(0,L.jsxs)(v.SafeAreaProvider,{children:[(0,L.jsx)(c.StatusBar,{style:"light"}),G?(0,L.jsx)(h.default,{style:{flex:1,backgroundColor:w.colours.bg}}):(0,L.jsx)(h.default,{style:{flex:1},children:(0,L.jsx)(u.Stack,{screenOptions:{headerShown:!1,contentStyle:{backgroundColor:w.colours.bg}}})}),Q&&!G?(0,L.jsx)(h.default,{style:[y.default.absoluteFill,{backgroundColor:w.colours.bg}]}):null,Q||G||P.IS_CAR?null:(0,L.jsx)(H.VoiceHost,{}),G?null:(0,L.jsx)(I.SyncBadge,{}),Q||G||P.IS_CAR?null:(0,L.jsx)(R.PushPrompt,{}),P.IS_CAR?(0,L.jsx)(j.CarGate,{}):(0,L.jsx)(E.InviteGate,{}),(0,L.jsx)(O.BackToDisplay,{}),Q||G?null:(0,L.jsx)(T.SliderHost,{})]}):(0,L.jsxs)(h.default,{style:{flex:1,backgroundColor:w.colours.bg,alignItems:'center',justifyContent:'center',gap:18},children:[_.HERO_LOGOS[S.VENUE_RID]?(0,L.jsx)(p.default,{source:_.HERO_LOGOS[S.VENUE_RID],accessibilityLabel:"Venue logo",style:{width:180,height:180},resizeMode:"contain"}):null,(0,L.jsx)(f.default,{color:w.colours.gold})]})}F.PITCH&&(globalThis.__pitch={useSaverCfg:G.useSaverCfg,useSync:t.useSync,seedInvitePairsForQA:s.seedInvitePairsForQA,appVariant:P.APP_VARIANT,useStore:A.useStore,useOwner:x.useOwner,useFloor:b.useFloor,useBlocks:n.useBlocks,useSession:C.useSession,useCashUp:B.useCashUp,useCashAccess:V.useCashAccess,seedPitch:N.seedPitch},setTimeout(()=>{try{(0,N.seedPitch)()}catch(e){console.warn('pitch seed',e)}},1500)),C.START_INVITE,l.preventAutoHideAsync().catch(()=>{})},803,[1104,824,1147,1001,1106,828,805,1133,568,31,247,197,123,47,128,5,868,1148,807,1135,290,823,829,863,825,1060,866,1149,1138,1139,1042,1140,943,2,1050,1049,1141,957,25,1143,1144,1145,1146]);
2
+ __d(function(g,r,i,a,_m,_e,_d){"use strict";Object.defineProperty(_e,'__esModule',{value:!0}),Object.defineProperty(_e,"inviteCache",{enumerable:!0,get:function(){return S}}),_e.refreshLinkPhones=P,_e.linkedSinceText=L,_e.refreshInvites=A,_e.useInviteStatus=function(){const[,e]=(0,t.useState)(0);return(0,t.useEffect)(()=>{const n=()=>e(e=>e+1);return $.add(n),A(),()=>{$.delete(n)}},[]),j},Object.defineProperty(_e,"when",{enumerable:!0,get:function(){return C}}),_e.inviteStateText=function(e,n=Date.now()){return'used'===e?.state?'Previous link used. Make a new link only if they need one.':e?.devices?`Signed in on ${e.devices} device${1===e.devices?'':'s'}`:'Personal Android and iPhone links'},_e.seedInvitePairsForQA=function(n,t,s){if(!e.PITCH)throw new Error('QA only');w.set(`${n}:${t}`,{working:[s.android,s.iphone].filter(Boolean).length,...s}),x()},Object.defineProperty(_e,"installSteps",{enumerable:!0,get:function(){return B}}),Object.defineProperty(_e,"installMessage",{enumerable:!0,get:function(){return R}}),_e.InviteLinkControls=function({m:e,actorRole:s}){const o=(0,h.useSync)(e=>e.venueId),x=(0,h.useSync)(e=>'staff'===e.kind&&!!e.venueId),j=(0,h.useSync)(e=>e.perms.includes('*')||e.perms.includes('roles.manage')),S=x&&e.active&&!e.name.includes('(example)')&&('owner'===s||j||'manager'===s&&'owner'!==e.role&&!e.ownerAccess),A=`${o}:${e.id}`,O=(0,k.useSession)(e=>e.meId),E=(0,y.useOwner)(e=>O?e.staff.find(e=>e.id===O):void 0),W=!O||!!E&&(0,f.ownJobManagesLinks)(E),[,_]=(0,t.useState)(0),[F,Y]=(0,t.useState)(''),[Z,N]=(0,t.useState)(null),[U,G]=(0,t.useState)(!1),[Q,q]=(0,t.useState)(null),[J,K]=(0,t.useState)(null),[V,X]=(0,t.useState)(!1);if((0,t.useEffect)(()=>{if(!S)return;const n=()=>_(e=>e+1);return $.add(n),P(),M(A,e.id),()=>{$.delete(n)}},[S,A,e.id]),!S)return null;const ee=w.get(A),ne=e.name.split(' ')[0],te=['android','iphone'].filter(e=>T(ee?.[e])),ie=ee?.working??te.length,se=!0===ee?.oldLinksSwitchOff?'Their old link switches off once they open this one.':'Their other links keep working.',ae=async n=>{try{await(0,h.revokeStaffAppLink)(n),K(null),Y('Link switched off. Phones already signed in stay signed in.'),b.delete(A),await M(A,e.id),Q&&q(await(0,h.staffAppLinkHistory)(e.id))}catch(e){Y(String(e.message))}},re=async n=>{if(!Z){N(n);try{await D(A,e.id,n),G(!1),Y(`New ${'android'===n?'Android':'iPhone'} link made for ${ne}. ${se} Copy or Share it below.`),Q&&q(await(0,h.staffAppLinkHistory)(e.id))}catch(e){Y(String(e.message))}finally{N(null)}}};return(0,m.jsxs)(l.default,{testID:`invite-${e.id}`,style:{gap:10},children:[(()=>{const n=L(I[e.id]);return n?(0,m.jsxs)(l.default,{testID:`invite-phone-${e.id}`,style:{gap:8,padding:12,borderRadius:10,borderWidth:1,borderColor:u.colours.gold,backgroundColor:u.colours.bg,alignItems:'center'},children:[(0,m.jsx)(d.T,{center:!0,weight:"semibold",colour:u.colours.goldLight,testID:`invite-phone-since-${e.id}`,children:n}),(0,m.jsxs)(d.Muted,{center:!0,size:13,children:["Another phone that opens ",e.name,"\u2019s link is asked to see a manager."]}),W?V?(0,m.jsxs)(l.default,{style:{gap:8,alignItems:'center',width:'100%'},children:[(0,m.jsxs)(d.T,{center:!0,size:15,children:["Reset ",e.name,"\u2019s phone? Their link will link to the next phone that opens it. Phones already signed in stay signed in."]}),(0,m.jsxs)(d.Row,{gap:8,wrap:!0,style:{justifyContent:'center'},children:[(0,m.jsx)(d.Button,{label:"Yes, reset phone",testID:`invite-reset-yes-${e.id}`,style:{minHeight:44},accessibilityLabel:`Yes, reset ${e.name}'s phone`,onPress:async()=>{try{await(0,h.resetStaffLinkPhone)(e.id),await P(),Y(`Phone reset. ${e.name}\u2019s link will link to the next phone that opens it.`)}catch(e){Y(String(e.message))}finally{X(!1)}}}),(0,m.jsx)(d.Button,{label:"Cancel",kind:"ghost",style:{minHeight:44},testID:`invite-reset-no-${e.id}`,onPress:()=>X(!1)})]})]}):(0,m.jsx)(d.Button,{label:"Reset phone",kind:"secondary",testID:`invite-reset-${e.id}`,style:{minHeight:44},accessibilityLabel:`Reset phone for ${e.name}. Asks to confirm.`,onPress:()=>X(!0)}):(0,m.jsx)(d.Muted,{center:!0,size:13,testID:`invite-reset-managers-only-${e.id}`,children:"Only a manager or owner can reset a phone or switch a link off."})]}):null})(),ee?null:(0,m.jsx)(d.Muted,{center:!0,testID:`invite-loading-${e.id}`,children:v.has(A)?'Cannot load the links right now. Close and open again to retry.':'Loading current links\u2026'}),ee&&0===ie?(0,m.jsxs)(l.default,{testID:`invite-none-${e.id}`,style:{gap:6,padding:12,borderRadius:10,borderWidth:2,borderColor:u.colours.gold,backgroundColor:u.colours.bg,alignItems:'center'},children:[(0,m.jsx)(d.T,{center:!0,weight:"semibold",size:17,accessibilityRole:"header",children:"No link yet - tap Make a new link"}),(0,m.jsxs)(d.Muted,{center:!0,size:13,children:[ne," has no working link. Make one for the phone they use, then Share it privately."]})]}):null,ee&&ie>0&&0===te.length?(0,m.jsxs)(d.Muted,{center:!0,testID:`invite-hidden-${e.id}`,children:[ne," has ",1===ie?'a working link':`${ie} working links`," sent earlier. For safety it can\u2019t be shown again here. Tap Make a new link only if ",ne," needs a new one."]}):null,te.map(t=>{const s=H(t),o=ee[t],h=(0,c.personalAppUrl)(t,o);return(0,m.jsxs)(l.default,{testID:`invite-${t}-${e.id}`,style:{gap:6,padding:10,borderRadius:10,borderWidth:1,borderColor:u.colours.gold,backgroundColor:u.colours.bg,alignItems:'center'},children:[(0,m.jsx)(d.T,{center:!0,weight:"semibold",children:s}),(0,m.jsx)(n.Text,{selectable:!0,accessibilityLabel:`${e.name}, ${s} personal link`,testID:`invite-link-${t}-${e.id}`,style:{color:u.colours.goldLight,fontSize:14,textAlign:'center',width:'100%'},children:o.shortCode?`Short link: ${o.shortCode}`:"Secure personal link \u2014 Copy or Share"}),o.linked?(0,m.jsxs)(d.Muted,{center:!0,size:13,testID:`invite-linked-${t}-${e.id}`,children:["Already linked to ",ne,"\u2019s phone. Another phone that opens it is asked to see a manager."]}):(0,m.jsxs)(m.Fragment,{children:[(0,m.jsx)(d.Muted,{center:!0,size:13,children:B(t)}),(0,m.jsx)(d.Muted,{center:!0,size:13,children:"Works for good on the first phone that opens it."})]}),(0,m.jsxs)(d.Row,{gap:8,wrap:!0,style:{justifyContent:'center'},children:[(0,m.jsx)(d.Button,{label:"Copy",kind:"secondary",style:{minHeight:44,minWidth:44},accessibilityLabel:`Copy ${e.name}'s ${s} link`,testID:`invite-copy-${t}-${e.id}`,onPress:async()=>Y(await(0,p.copyText)(R(h,e.name,t))?'Link and install steps copied':'Select and copy the link.')}),(0,m.jsx)(d.Button,{label:"Share",style:{minHeight:44,minWidth:44},accessibilityLabel:`Share ${e.name}'s ${s} link`,testID:`invite-share-${t}-${e.id}`,onPress:async()=>Y(await z(h,e.name,t))}),W?(0,m.jsx)(d.Button,{label:"Revoke link",kind:"ghost",style:{minHeight:44},accessibilityLabel:`Revoke ${e.name}'s ${s} link`,onPress:()=>K(o.id)}):null]})]},t)}),J&&W?(0,m.jsxs)(d.Row,{gap:8,wrap:!0,style:{justifyContent:'center'},children:[(0,m.jsx)(d.Button,{label:"Confirm revoke link",accessibilityLabel:`Confirm revoke link for ${e.name}`,style:{minHeight:44},onPress:()=>{ae(J)}}),(0,m.jsx)(d.Button,{label:"Cancel",kind:"ghost",style:{minHeight:44},onPress:()=>K(null)})]}):null,F?(0,m.jsx)(d.T,{center:!0,size:14,children:F}):null,ee&&W?(0,m.jsx)(l.default,{testID:`invite-make-${e.id}`,style:{gap:8,alignItems:'center',width:'100%'},children:U?(0,m.jsxs)(m.Fragment,{children:[(0,m.jsxs)(d.T,{center:!0,size:15,testID:`invite-make-ask-${e.id}`,children:["Make a new link for ",ne,"? Which phone do they use? ",se]}),(0,m.jsxs)(d.Row,{gap:8,wrap:!0,style:{justifyContent:'center'},children:[(0,m.jsx)(d.Button,{label:'android'===Z?'Making\u2026':'Android phone',testID:`invite-make-android-${e.id}`,disabled:!!Z,style:{minHeight:48},accessibilityLabel:`Yes, make a new Android link for ${e.name}`,onPress:()=>{re('android')}}),(0,m.jsx)(d.Button,{label:'iphone'===Z?'Making\u2026':'iPhone',testID:`invite-make-iphone-${e.id}`,disabled:!!Z,style:{minHeight:48},accessibilityLabel:`Yes, make a new iPhone link for ${e.name}`,onPress:()=>{re('iphone')}}),(0,m.jsx)(d.Button,{label:"Cancel",kind:"ghost",testID:`invite-make-cancel-${e.id}`,disabled:!!Z,style:{minHeight:48},accessibilityLabel:"Cancel, make no link",onPress:()=>G(!1)})]})]}):(0,m.jsx)(d.Button,{label:"Make a new link",kind:0===ie?'primary':'secondary',testID:`invite-new-${e.id}`,style:{minHeight:52,alignSelf:'center'},accessibilityLabel:`Make a new link for ${e.name}. Asks which phone first.`,onPress:()=>{Y(''),G(!0)}})}):null,ee&&!W?(0,m.jsx)(d.Muted,{center:!0,size:13,testID:`invite-make-managers-only-${e.id}`,children:"Only a manager or owner can make a new link."}):null,(0,m.jsxs)(d.Muted,{center:!0,size:13,children:["Share privately with ",e.name,". Links never expire. Opening this page never makes a link. Each link works on the first phone that opens it; Reset phone lets it link to a new one."]}),(0,m.jsx)(d.Button,{label:Q?'Hide previous links':'Manage previous links',kind:"ghost",style:{minHeight:44},accessibilityLabel:`Manage all previous app links for ${e.name}`,onPress:async()=>{try{q(Q?null:await(0,h.staffAppLinkHistory)(e.id))}catch(e){Y(String(e.message))}}}),Q?.map(n=>(0,m.jsxs)(l.default,{style:{gap:4},children:[(0,m.jsxs)(d.Muted,{center:!0,size:13,children:['legacy'===n.platform?'Previous app link':'android'===n.platform?'Android app':'iPhone'," \xb7 ",C(n.createdAt)," \xb7 ",n.revokedAt?'Revoked':n.usedAt?'Used for sign-in':'Unused']}),!n.revokedAt&&W?(0,m.jsx)(d.Button,{label:"Revoke this link",kind:"ghost",style:{minHeight:44},accessibilityLabel:`Revoke ${e.name}'s ${n.platform} link from ${C(n.createdAt)}`,onPress:()=>K(n.id)}):null]},n.id))]})};var e=r(_d[0]),n=r(_d[1]),t=r(_d[2]);r(_d[3]),r(_d[4]);var s,o=r(_d[5]),l=(s=o)&&s.__esModule?s:{default:s},d=r(_d[6]),c=r(_d[7]),h=r(_d[8]),u=r(_d[9]),p=r(_d[10]),k=r(_d[11]),y=r(_d[12]),f=r(_d[13]),m=r(_d[14]);const w=new Map,b=new Map,$=new Set,v=new Map,x=()=>$.forEach(e=>e());let j=null;const S=()=>j;let I={};async function P(){return I=await(0,h.staffLinkPhones)(),x(),I}function L(e){if(!e||!e.phones)return null;const n=new Date(e.since).toLocaleDateString('en-GB',{timeZone:'Europe/London',day:'numeric',month:'short',year:'numeric'});return e.phones>1?`Linked to ${e.phones} phones, the first since ${n}`:`Linked to a phone since ${n}`}async function A(){return j=await(0,h.readInviteStatus)(),x(),j}const C=e=>e?new Date(e).toLocaleString('en-GB',{timeZone:'Europe/London',day:'numeric',month:'short',hour:'2-digit',minute:'2-digit',timeZoneName:'short'}):'';async function M(n,t){if(e.PITCH)return void(w.has(n)||(w.set(n,{working:0}),x()));if(b.has(n))return b.get(n);const s=(async()=>{try{w.set(n,await(0,h.currentStaffAppLinks)(t)),v.delete(n)}catch(e){v.set(n,String(e.message||e))}finally{b.delete(n),x()}})();return b.set(n,s),s}async function D(n,t,s){if(e.PITCH){const e=w.get(n)??{},o=(e.working??0)+1,l={id:`qa-${s}-${t}-${o}`,token:('android'===s?'A':'B').repeat(32),device:'iphone'===s?'D'.repeat(32):null,app:'staff',expiresAt:'infinity',shortCode:('android'===s?'A':'I')+String(o).padStart(9,'0')},d={...e,[s]:l,working:o};return w.set(n,d),x(),d}const o=await(0,h.makeStaffAppLink)(t,s);return w.set(n,o),v.delete(n),x(),o}const H=e=>'android'===e?'Android app':'iPhone web app',T=e=>!!e&&('infinity'===e.expiresAt?/^[A-Za-z0-9_-]{16,64}$/.test(e.token):(0,c.currentAppLink)(e)),B=e=>'android'===e?'Tap the link, download the app, allow installation, then open it. It signs you in.':'Open in Safari and tap Open app. In the app, tap Share, Add to Home Screen, then open it from your Home Screen.',R=(e,n,t)=>`${n} \u2014 ${'android'===t?'Android app':'iPhone web app'}\n${e}\n${B(t)}`;async function z(e,n,t){const s=R(e,n,t);try{if('undefined'!=typeof navigator&&navigator.share)return await navigator.share({title:`CoverCharge for ${n}`,text:s,url:e}),'Share opened'}catch(e){if('AbortError'===e.name)return'Share cancelled'}return await(0,p.copyText)(s)?'Link and install steps copied. Paste them into a private message.':'Select and copy the link.'}},1104,[2,874,31,123,245,128,818,1105,824,825,1063,866,863,808,25]);
3
+ __d(function(g,r,i,a,_m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"IOS_WEB",{enumerable:!0,get:function(){return t}}),e.getPageSlug=n,e.personalGetUrl=o,e.siteRootFromLocation=s,e.mintPersonalUrl=function(t,c,h){const p=s();if(p)return o({origin:p.origin,basePath:p.basePath,staffId:t,name:c,token:h});return`get/${n(c)||n(t)}.html?v=2#i=${encodeURIComponent(h)}`},e.currentAppLink=function(t,n=Date.now()){return!!t&&/^[A-Za-z0-9_-]{16,64}$/.test(t.token)&&Date.parse(t.expiresAt)>n},e.personalAppUrl=function(t,n){if(n.shortCode&&/^[A-Za-z0-9_-]{10}$/.test(n.shortCode)){const t=s()??{origin:'https://covercharge-apps.static.hf.space',basePath:'/'};return`${t.origin}${t.basePath}s.html#${n.shortCode}`}if(n.url)try{const t=new URL(n.url);if('https:'===t.protocol&&'covercharge-apps.static.hf.space'===t.hostname&&/^\/(?:(?:kirkmichael|wildings)\/)?get\/[a-z0-9-]+\.html$/.test(t.pathname))return t.href}catch{}const o=s()??{origin:'https://covercharge-apps.static.hf.space',basePath:'/'},c=['owner','chef'].includes(n.app)?n.app:'staff',h=`i=${encodeURIComponent(n.token)}${'iphone'===t?`&d=${encodeURIComponent(n.device||'')}`:''}`;return`${o.origin}${o.basePath}get/${t}.html?a=${c}${'android'===t?'&v=2':'&v=61'}#${h}`};const t=new Set(['st-jack','st-agate','st-lenny','st-james','st-lillie','st-bisto','st-gordon','st-cameron','st-mia','st-emily','st-gabrielle','st-harvey','st-tracy','st-eilidh','st-finn']);function n(t){return(t.startsWith('st-')||t.startsWith('ow-')||t.startsWith('ch-')?t.replace(/^(st|ow|ch)-/,''):t.replace(/\s*\(.*?\)\s*/g,' ').trim().split(/\s+/)[0]||t).toLowerCase().replace(/[^a-z0-9]+/g,'-').replace(/^-|-$/g,'')||'staff'}function o(t){const o=t.origin.replace(/\/$/,'');let s=(t.basePath||'/').replace(/\/?$/,'/');s.startsWith('/')||(s='/'+s);return`${o}${s}get/${n(t.name)||n(t.staffId)}.html?v=2#i=${encodeURIComponent(t.token)}`}function s(t){try{if(!(t||'undefined'!=typeof window&&window.location))return null;const n=new URL(t||window.location.href),o=n.pathname.match(/^(.*?\/)(?:owner|staff|chef|display|customer)-app(?:\/|$)/);return{origin:n.origin,basePath:o?o[1]:'/'}}catch{return null}}},1105,[]);
4
+ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"useFonts",{enumerable:!0,get:function(){return o.useFonts}});var t=r(d[0]);Object.keys(t).forEach(function(n){'default'===n||Object.prototype.hasOwnProperty.call(e,n)||Object.defineProperty(e,n,{enumerable:!0,get:function(){return t[n]}})});var n=r(d[1]);Object.keys(n).forEach(function(t){'default'===t||Object.prototype.hasOwnProperty.call(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:function(){return n[t]}})});var o=r(d[2])},1106,[1107,1130,1132]);
5
+ __d(function(g,r,i,a,m,_e,d){"use strict";Object.defineProperty(_e,'__esModule',{value:!0}),Object.defineProperty(_e,"FontDisplay",{enumerable:!0,get:function(){return y.FontDisplay}}),_e.isLoaded=F,_e.getLoadedFonts=function(){return t.default.getLoadedFonts()},_e.isLoading=function(e){return e in c.loadPromises},_e.loadAsync=function(e,n){const t='undefined'==typeof window;if(Array.isArray(e)){if(n)return Promise.reject(new o.CodedError("ERR_FONT_API",`No fontFamily can be used for the provided source: ${n}. The second argument of \`loadAsync()\` can only be used with a \`string\` value as the first argument.`));const s=e;if(t){(0,l.assertValidFontFamilyDefinitions)(s);for(const{fontFamily:e,fontDefinitions:o}of s){(0,l.assertValidFontFaces)(e,o);for(const n of o)(0,u.registerStaticFont)(e,(0,f.fontSourceFromFace)(n))}return Promise.resolve()}try{(0,l.assertValidFontFamilyDefinitions)(s)}catch(e){return Promise.reject(e)}return Promise.all(s.map(w)).then(()=>{})}if('object'==typeof e){if(n)return Promise.reject(new o.CodedError("ERR_FONT_API",`No fontFamily can be used for the provided source: ${n}. The second argument of \`loadAsync()\` can only be used with a \`string\` value as the first argument.`));const s=e,l=Object.keys(s);return t?(l.map(e=>(0,u.registerStaticFont)(e,s[e])),Promise.resolve()):Promise.all(l.map(e=>h(e,s[e]))).then(()=>{})}if(t)return(0,u.registerStaticFont)(e,n),Promise.resolve();return h(e,n)},_e.unloadAllAsync=async function(){if(!t.default.unloadAllAsync)throw new o.UnavailabilityError('expo-font','unloadAllAsync');if(Object.keys(c.loadPromises).length)throw new o.CodedError("ERR_UNLOAD",`Cannot unload fonts while they're still loading: ${Object.keys(c.loadPromises).join(', ')}`);(0,c.purgeCache)(),await t.default.unloadAllAsync()},_e.unloadAsync=async function(e,n){if(!t.default.unloadAsync)throw new o.UnavailabilityError('expo-font','unloadAsync');if('object'==typeof e){if(n)throw new o.CodedError("ERR_FONT_API",`No fontFamily can be used for the provided options: ${n}. The second argument of \`unloadAsync()\` can only be used with a \`string\` value as the first argument.`);const t=e,s=Object.keys(t);return void await Promise.all(s.map(e=>p(e,t[e])))}return await p(e,n)};var e,o=r(d[0]),n=r(d[1]),t=(e=n)&&e.__esModule?e:{default:e},s=r(d[2]),l=r(d[3]),f=r(d[4]),c=r(d[5]),u=r(d[6]),y=r(d[7]);function F(e){if('function'!=typeof t.default.isLoaded)throw new Error("expected ExpoFontLoader.isLoaded to be a function, was "+typeof t.default.isLoaded);return(0,c.isLoadedInCache)(e)||t.default.isLoaded(e)}async function w(e){const{fontFamily:o,fontDefinitions:n}=e;if((0,l.assertValidFontFaces)(o,n),c.loadPromises.hasOwnProperty(o))return c.loadPromises[o];F(o)||(c.loadPromises[o]=(async()=>{try{await(0,s.loadFontFamilyAsync)(o,n),(0,c.markLoaded)(o)}finally{delete c.loadPromises[o]}})(),await c.loadPromises[o])}async function h(e,n){if(!n)throw new o.CodedError("ERR_FONT_SOURCE",`Cannot load null or undefined font source: { "${e}": ${n} }. Expected asset of type \`FontSource\` for fontFamily of name: "${e}"`);if(c.loadPromises.hasOwnProperty(e))return c.loadPromises[e];if(F(e))return;const t=(0,s.getAssetForSource)(n);c.loadPromises[e]=(async()=>{try{await(0,s.loadSingleFontAsync)(e,t),(0,c.markLoaded)(e)}finally{delete c.loadPromises[e]}})(),await c.loadPromises[e]}async function p(e,n){if(F(e)){if((0,c.purgeFontFamilyFromCache)(e),!e)throw new o.CodedError("ERR_FONT_FAMILY","Cannot unload an empty name");if(!t.default.unloadAsync)throw new o.UnavailabilityError('expo-font','unloadAsync');await t.default.unloadAsync(e,n)}}},1107,[302,1108,1111,1125,1126,1127,1128,1129]);
6
+ __d(function(g,r,_i,_a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return p}}),e._matchesFontFaceOptions=l,e._fontFaceRuleSrcMatches=f,e._createWebFontTemplate=R;var t=r(d[0]),n=r(d[1]);function s(){if('undefined'==typeof window)return null;const t=S();return t.sheet?t.sheet:null}function o(){const t=s();if(t){const n=[...t.cssRules],s=[];for(let t=0;t<n.length;t++){const o=n[t];o instanceof CSSFontFaceRule&&s.push({rule:o,index:t})}return s}return[]}function i(t){const n=t?.trim();if(!n)return'';const s=n[0];return n.length>=2&&('"'===s||"'"===s)&&n.endsWith(s)?n.slice(1,-1).replace(/\\(.)/g,'$1'):n}function u(t){if(null==t||''===t)return;if('number'==typeof t)return Number.isFinite(t)?t:void 0;const n=t.trim().toLowerCase();if('normal'===n)return 400;if('bold'===n)return 700;const s=Number(n);return Number.isFinite(s)?s:n}function l(t,n,s){return i(t.style.fontFamily)===n&&((!s?.display||s.display===t.style.fontDisplay)&&((null==s?.weight||u(s.weight)===u(t.style.fontWeight))&&(null==s?.style||s.style===t.style.fontStyle)))}function c(t,n){return o().filter(({rule:s})=>l(s,t,n))}function f(t,n){const s=t.style.getPropertyValue('src').match(/url\((['"]?)([^'")]*)\1\)/);if(!s)return!0;let o=s[2]??'';try{o=decodeURIComponent(o)}catch{}return o===String(n)}const a={async unloadAllAsync(){if('undefined'==typeof window)return;const t=document.getElementById(w);t&&t instanceof HTMLStyleElement&&document.removeChild(t)},async unloadAsync(t,n){const o=s();if(!o)return;const i=[...c(t,n)].sort((t,n)=>n.index-t.index);for(const t of i)o.deleteRule(t.index)},getServerResources:()=>(0,n.getServerResourceDescriptors)().map(t=>{switch(t.type){case'style':return`<style id="${t.id}">${t.css}</style>`;case'link':return`<link rel="${t.rel}" href="${t.href}" as="${t.as}" crossorigin="${t.crossOrigin}" />`;default:return''}}).filter(Boolean),getServerResourceDescriptors:()=>(0,n.getServerResourceDescriptors)(),getLoadedFonts(){if('undefined'==typeof window)return(0,n.getLoadedServerFonts)();const t=new Set,s=[];for(const{rule:n}of o()){const o=i(n.style.fontFamily);t.has(o)||(t.add(o),s.push(o))}return s},isLoaded:(t,s={})=>'undefined'==typeof window?(0,n.isServerFontLoaded)(t):c(t,s)?.length>0,loadAsync(s,o){if('undefined'==typeof window)return(0,n.addServerFont)({name:s,css:R(s,o),resourceId:o.uri}),Promise.resolve();if(!(document.head&&'function'==typeof document.head.appendChild))throw new t.CodedError('ERR_WEB_ENVIRONMENT',"The browser's `document.head` element doesn't support injecting fonts.");const i=S();i.isConnected||document.head.appendChild(i);if(c(s,o).some(({rule:t})=>f(t,o.uri))||b(s,o),'function'!=typeof document.fonts?.load)return Promise.resolve();let u='';return'string'==typeof o.style&&$.test(o.style)&&(u+=`${o.style} `),('number'==typeof o.weight&&Number.isFinite(o.weight)||'string'==typeof o.weight&&($.test(o.weight)||F.test(o.weight)&&!o.weight.includes(' ')))&&(u+=`${o.weight} `),h(document.fonts.load(`${u}1em ${JSON.stringify(s)}`),s)}},y=12e3;function h(n,s){let o;const i=new Promise((n,i)=>{o=setTimeout(()=>{i(new t.CodedError('ERR_DOWNLOAD',`Fetching the font family "${s}" timed out after ${y}ms. Check that the font URL is reachable and served with CORS headers.`))},y)});return Promise.race([n,i]).finally(()=>clearTimeout(o)).then(()=>{})}var p='undefined'==typeof window?a:(0,t.registerWebModule)(function(){return a},'ExpoFontLoader');const w='expo-generated-fonts';function S(){const t=document.getElementById(w);if(t&&t instanceof HTMLStyleElement)return t;const n=document.createElement('style');return n.id=w,n}const $=/^[a-zA-Z_-][\w-]*$/,F=/^(1000|[1-9]\d{0,2})( (1000|[1-9]\d{0,2}))?$/;function R(t,n){const s=[`font-family:${JSON.stringify(t)}`,`src:url(${JSON.stringify(n.uri)})`];return'string'==typeof n.display&&$.test(n.display)&&s.push(`font-display:${n.display}`),('number'==typeof n.weight&&Number.isFinite(n.weight)||'string'==typeof n.weight&&($.test(n.weight)||F.test(n.weight)))&&s.push(`font-weight:${n.weight}`),'string'==typeof n.style&&$.test(n.style)&&s.push(`font-style:${n.style}`),`@font-face{${s.join(';')}}`}function b(t,n){const s=R(t,n),o=S();if(o.styleSheet){const t=o;t.styleSheet.cssText=t.styleSheet.cssText?t.styleSheet.cssText+s:s}else if(o.sheet)o.sheet.insertRule(s,o.sheet.cssRules.length);else{const t=document.createTextNode(s);o.appendChild(t)}return o}},1108,[302,1109]);
7
+ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),e.withServerContext=function(n){if('undefined'!=typeof window)return n();return s().run(new Map,n)},e.addServerFont=function(n){const t=u();t.has(n.css)||t.set(n.css,n)},e.getServerResourceDescriptors=function(){const n=[...u().values()];if(!n.length)return[];const o=n.map(({css:n})=>n).join('\n'),s=[...new Set(n.map(({resourceId:n})=>n))];return[{css:o,id:t,type:'style'},...s.map(n=>({as:'font',crossOrigin:'',href:n,rel:'preload',type:'link'}))]},e.getLoadedServerFonts=function(){const n=s().getStore();if(!n)return[];return[...new Set([...n.values()].map(({name:n})=>n))]},e.isServerFontLoaded=function(n){const t=s().getStore();if(!t)return!1;for(const o of t.values())if(o.name===n)return!0;return!1};var n=r(d[0]);const t='expo-generated-fonts';let o=null;function s(){if('undefined'!=typeof window)throw new Error('expo-font server context is server-only and cannot be used in the browser.');return o||(o=new n.AsyncLocalStorage),o}function u(){const n=s().getStore();if(!n)throw new Error("expo-font server context accessed outside of withServerContext(). Wrap your server-side font usage in withServerContext(() => /* server code */).");return n}},1109,[1110]);
8
+ __d(function(g,r,i,a,m,e,d){},1110,[]);
9
+ __d(function(g,r,i,a,m,_e,d){"use strict";Object.defineProperty(_e,'__esModule',{value:!0}),_e.getAssetForSource=p,_e.loadFontFamilyAsync=async function(t,e){await Promise.all(e.map(e=>{const o=p((0,f.fontSourceFromFace)(e));return j(t,o)}))},_e.loadSingleFontAsync=j;var t,e=r(d[0]),o=r(d[1]),n=r(d[2]),u=(t=n)&&t.__esModule?t:{default:t};r(d[3]);var f=r(d[4]);function s(t){return'string'==typeof t?t||null:'number'==typeof t?s(e.Asset.fromModule(t)):'object'==typeof t&&'number'==typeof t.uri?s(t.uri):'object'==typeof t&&(t.uri||t.localUri||t.default)||null}function c(t){if('object'==typeof t&&'display'in t)return t.display??void 0}function l(t){if('object'==typeof t&&'weight'in t)return t.weight??void 0}function y(t){if('object'==typeof t&&'style'in t)return t.style??void 0}function p(t){const e=s(t),o=c(t),n=l(t),u=y(t);return e&&'string'==typeof e||b(e),{uri:e,display:o,weight:n,style:u}}function b(t){let e=typeof t;throw'object'===e&&(e=JSON.stringify(t,null,2)),new o.CodedError("ERR_FONT_SOURCE",`Expected font asset of type \`string | FontResource | Asset\` instead got: ${e}`)}function j(t,e){return('object'!=typeof e||'string'!=typeof e.uri||e.downloadAsync)&&b(e),u.default.loadAsync(t,e)}},1111,[1112,302,1108,1125,1126]);
10
+ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),r(d[0]);var t=r(d[1]);Object.keys(t).forEach(function(n){'default'===n||Object.prototype.hasOwnProperty.call(e,n)||Object.defineProperty(e,n,{enumerable:!0,get:function(){return t[n]}})});var n=r(d[2]);Object.keys(n).forEach(function(t){'default'===t||Object.prototype.hasOwnProperty.call(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:function(){return n[t]}})})},1112,[1113,1114,1124]);
11
+ __d(function(g,r,i,a,m,_e,d){"use strict";var e,t=r(d[0]),s=r(d[1]),u=r(d[2]),o=(e=u)&&e.__esModule?e:{default:e};if(s.IS_ENV_WITH_LOCAL_ASSETS){(o.default.setCustomSourceTransformer||u.setCustomSourceTransformer)(function(e){try{if('fileHashes'in e.asset&&e.asset.fileHashes){const s=t.Asset.fromMetadata(e.asset);return s.uri.startsWith(t.ANDROID_EMBEDDED_URL_BASE_RESOURCE)?e.resourceIdentifierWithoutScale():e.fromSource(s.downloaded?s.localUri:s.uri)}return e.defaultAsset()}catch{return e.defaultAsset()}})}},1113,[1114,1118,1123]);
12
+ __d(function(g,r,i,a,m,_e,_d){"use strict";function t(t){return t&&t.__esModule?t:{default:t}}function e(t){if(t&&t.__esModule)return t;var e={};return t&&Object.keys(t).forEach(function(s){if('default'!==s){var n=Object.getOwnPropertyDescriptor(t,s);Object.defineProperty(e,s,n.get?n:{enumerable:!0,get:function(){return t[s]}})}}),e.default=t,e}Object.defineProperty(_e,'__esModule',{value:!0}),Object.defineProperty(_e,"ANDROID_EMBEDDED_URL_BASE_RESOURCE",{enumerable:!0,get:function(){return y}}),Object.defineProperty(_e,"Asset",{enumerable:!0,get:function(){return w}}),r(_d[0]);var s=t(r(_d[1])),n=r(_d[2]),h=e(r(_d[3])),o=r(_d[4]),l=e(r(_d[5])),u=r(_d[6]),d=r(_d[7]),c=t(r(_d[8]));function f(t){return!!t&&'object'==typeof t&&'uri'in t&&'string'==typeof t.uri}const y='file:///android_res/';class w{static byHash={};static byUri={};hash=null;localUri=null;width=null;height=null;downloading=!1;downloaded=!1;_downloadCallbacks=[];constructor({name:t,type:e,hash:s=null,uri:n,width:o,height:l}){this.name=t,this.type=e,this.hash=s,this.uri=n,'number'==typeof o&&(this.width=o),'number'==typeof l&&(this.height=l),s&&(this.localUri=(0,u.getLocalAssetUri)(s,e),this.localUri?.startsWith(y)?(this.uri=this.localUri,this.localUri=null):this.localUri&&(this.downloaded=!0)),t||(this.name=h.getFilename(n)),e||(this.type=h.getFileExtension(n))}static loadAsync(t){const e=Array.isArray(t)?t:[t];return Promise.all(e.map(t=>w.fromModule(t).downloadAsync()))}static fromModule(t){if('string'==typeof t)return w.fromURI(t);if(f(t)){const e=h.getFileExtension(t.uri);return new w({name:'',type:e.startsWith('.')?e.substring(1):e,hash:null,uri:t.uri,width:t.width,height:t.height})}const e=s.default.getAssetByID(t);if(!e)throw new Error(`Module "${t}" is missing from the asset registry`);if(!d.IS_ENV_WITH_LOCAL_ASSETS){const{uri:s}=(0,c.default)(t),n=new w({name:e.name,type:e.type,hash:e.hash,uri:s,width:e.width,height:e.height});return w.byHash[e.hash]=n,n}return w.fromMetadata(e)}static fromMetadata(t){const e=t.hash,s=w.byHash[e];if(s)return s;const{uri:h,hash:o}=(0,n.selectAssetSource)(t),l=new w({name:t.name,type:t.type,hash:o,uri:h,width:t.width,height:t.height});return w.byHash[e]=l,l}static fromURI(t){if(w.byUri[t])return w.byUri[t];let e='';if(t.indexOf(';base64')>-1)e=t.split(';')[0]?.split('/')[1]??'';else{const s=h.getFileExtension(t);e=s.startsWith('.')?s.substring(1):s}const s=new w({name:'',type:e,hash:null,uri:t});return w.byUri[t]=s,s}async downloadAsync(){if(this.downloaded)return this;if(this.downloading)return await new Promise((t,e)=>{this._downloadCallbacks.push({resolve:t,reject:e})}),this;this.downloading=!0;try{if(l.isImageType(this.type)){const{width:t,height:e,name:s}=await l.getImageInfoAsync(this.uri);this.width=t,this.height=e,this.name=s}else this.name=h.getFilename(this.uri);this.localUri=await(0,o.downloadAsync)(this.uri,this.hash,this.type),this.downloaded=!0,this._downloadCallbacks.forEach(({resolve:t})=>t())}catch(t){throw this._downloadCallbacks.forEach(({reject:e})=>e(t)),t}finally{this.downloading=!1,this._downloadCallbacks=[]}return this}}},1114,[302,233,1115,1119,1120,1121,1122,1118,1123]);
13
+ __d(function(g,r,i,a,m,_e,d){"use strict";function e(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(_e,'__esModule',{value:!0}),_e.selectAssetSource=function(e){const t=o.default.pickScale(e.scales,s.default.get()),f=e.scales.findIndex(e=>e===t),l=e.fileHashes?.[f]??e.fileHashes?.[0]??e.hash,p=e.fileUris?e.fileUris[f]??e.fileUris[0]:e.uri;if(p)return{uri:c(p),hash:l};const U=1===t?'':`@${t}x`,v=e.type?`.${encodeURIComponent(e.type)}`:'',x=`/${encodeURIComponent(e.name)}${U}${v}`,L=new URLSearchParams({platform:"web",hash:e.hash});if(/^https?:\/\//.test(e.httpServerLocation)){return{uri:e.httpServerLocation+x+'?'+L,hash:l}}const R=(0,h.getManifest2)(),S=R?.extra?.expoGo?.developer?u(R):null;if(S){const t=new URL(e.httpServerLocation+x,S);return t.searchParams.set('platform',"web"),t.searchParams.set('hash',e.hash),{uri:t.href,hash:l}}if(n.default.ExponentKernel)return{uri:`https://classic-assets.eascdn.net/~assets/${encodeURIComponent(l)}`,hash:l};return{uri:'',hash:l}},_e.resolveUri=c,r(d[0]);var t=r(d[1]),s=e(r(d[2])),n=e(r(d[3])),o=e(r(d[4])),h=r(d[5]);function u(e){const s=(0,t.getBundleOrigin)();if(s)return s;const n=e.extra?.expoGo?.debuggerHost;if(!n)return null;return(h.manifestBaseUrl?.startsWith('https://')?'https://':'http://')+n}function c(e){return h.manifestBaseUrl?new URL(e,h.manifestBaseUrl).href:e}},1115,[302,1116,200,113,1117,1118]);
14
+ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"getBundleUrl",{enumerable:!0,get:function(){return t.getBundleUrl}}),e.getBundleOrigin=function(n=(0,t.getBundleUrl)()){if(!n)return null;try{const{protocol:t,origin:u}=new URL(n);return'http:'===t||'https:'===t?u:null}catch{return null}};var t=r(d[0])},1116,[576]);
15
+ __d(function(g,r,i,a,m,_e,d){"use strict";Object.defineProperty(_e,'__esModule',{value:!0}),Object.defineProperty(_e,"default",{enumerable:!0,get:function(){return n}}),r(d[0]);var e,t=r(d[1]),s=(e=t)&&e.__esModule?e:{default:e};function c(e){const t=n.pickScale(e.scales,s.default.get()),c=1===t?'':'@'+t+'x',o=e.type?`.${e.type}`:'';return e.httpServerLocation.replace(/\.\.\//g,'_')+'/'+e.name+c+o}class n{constructor(e,t,s){this.serverUrl=e||'https://expo.dev',this.jsbundleUrl=null,this.asset=s}isLoadedFromServer(){return!0}isLoadedFromFileSystem(){return!1}defaultAsset(){return this.assetServerURL()}assetServerURL(){const e=new URL(c(this.asset),this.serverUrl);return e.searchParams.set('platform',"web"),e.searchParams.set('hash',this.asset.hash),this.fromSource(e.toString().replace(e.origin,''))}fromSource(e){return{__packager_asset:!0,width:this.asset.width??void 0,height:this.asset.height??void 0,uri:e,scale:n.pickScale(this.asset.scales,s.default.get())}}static pickScale(e,t){for(const s of e)if(s>=t)return s;return e[e.length-1]||1}}},1117,[302,200]);
16
+ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"IS_ENV_WITH_LOCAL_ASSETS",{enumerable:!0,get:function(){return t}}),e.getLocalAssets=function(){return{}},e.getManifest2=function(){return{}},Object.defineProperty(e,"manifestBaseUrl",{enumerable:!0,get:function(){return n}});const t=!1;const n=null},1118,[]);
17
+ __d(function(g,r,i,a,m,e,d){"use strict";function t(t){const{pathname:s,searchParams:o}=new URL(t,'https://e');return n(s)}function n(t){return t.substring(t.lastIndexOf('/')+1)}Object.defineProperty(e,'__esModule',{value:!0}),e.getFilename=t,e.getFileExtension=function(n){const s=t(n),o=s.lastIndexOf('.');return o>0?s.substring(o):''},e.getManifestBaseUrl=function(t){const n=new URL(t);let s=n.protocol;'exp:'===s?s='http:':'exps:'===s&&(s='https:');n.protocol=s;const o=n.pathname.substring(0,n.pathname.lastIndexOf('/')+1);return n.pathname=o,n.search='',n.hash='',n.protocol!==s?n.href.replace(n.protocol,s):n.href}},1119,[]);
18
+ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),e.downloadAsync=async function(n,t,c){return n}},1120,[]);
19
+ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),e.isImageType=function(n){return/^(jpeg|jpg|gif|png|bmp|webp|heic)$/i.test(n)},e.getImageInfoAsync=function(t){if('undefined'==typeof window)return Promise.resolve({name:(0,n.getFilename)(t),width:0,height:0});return new Promise((o,u)=>{const s=new Image;s.onerror=u,s.onload=()=>{o({name:(0,n.getFilename)(t),width:s.naturalWidth,height:s.naturalHeight})},s.src=t})};var n=r(d[0])},1121,[1119]);
20
+ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),e.getLocalAssetUri=function(t,n){return null}},1122,[]);
21
+ __d(function(g,r,i,a,m,_e,d){"use strict";function e(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(_e,'__esModule',{value:!0}),Object.defineProperty(_e,"default",{enumerable:!0,get:function(){return f}}),_e.setCustomSourceTransformer=o,Object.defineProperty(_e,"pickScale",{enumerable:!0,get:function(){return l}});var t=e(r(d[0])),n=e(r(d[1]));let u;function o(e){u=e}function c(e){if('object'==typeof e)return e;const o=t.default.getAssetByID(e);if(!o)return null;const c=new n.default('https://expo.dev',null,o);return u?u(c):c.defaultAsset()}Object.defineProperty(c,'setCustomSourceTransformer',{get:()=>o});var f=c;const{pickScale:l}=n.default},1123,[233,1117]);
22
+ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),e.useAssets=function(u){const[c,n]=(0,t.useState)(),[o,f]=(0,t.useState)();return(0,t.useEffect)(()=>{s.Asset.loadAsync(u).then(n).catch(f)},[]),[c,o]};var t=r(d[0]),s=r(d[1])},1124,[31,1114]);
23
+ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),e.normalizeWeight=o,e.normalizeStyle=f,e.resolveFaceWeight=l,e.resolveFaceStyle=c,e.assertValidFontFaces=function(t,s){if('string'!=typeof t||0===t.length)throw new n.CodedError("ERR_FONT_API",`Expected a non-empty string for \`fontFamily\`, instead got ${JSON.stringify(t)}. Set \`fontFamily\` to the name to use as the \`fontFamily\` style prop.`);if(!Array.isArray(s)||0===s.length)throw new n.CodedError("ERR_FONT_API",`No font faces were provided for font family "${t}". Set \`fontDefinitions\` to a non-empty array of \`FontFaceDefinition\`s.`);const y=new Set;for(const u of s){if('object'!=typeof u||null===u||null==u.path)throw new n.CodedError("ERR_FONT_API",`A face of font family "${t}" has no \`path\`. Set the face's \`path\` to a \`FontSource\`.`);const s=o(l(u)),h=f(c(u));if(void 0===s||void 0===h)continue;const F=`${s}/${h}`;if(y.has(F))throw new n.CodedError("ERR_FONT_API",`Font family "${t}" declares two faces with weight ${s} and style "${h}". Give each face a distinct weight or style so the correct face is selected at render time.`);y.add(F)}},e.assertValidFontFamilyDefinitions=function(t){const o=new Set;for(const f of t){if('object'!=typeof f||null===f||Array.isArray(f)||!('fontFamily'in f)||!('fontDefinitions'in f))throw new n.CodedError("ERR_FONT_API",`Expected an object with \`fontFamily\` and \`fontDefinitions\`, instead got ${JSON.stringify(f)}. Set each array element to \`{ fontFamily, fontDefinitions }\`.`);const{fontFamily:t}=f;if(o.has(t))throw new n.CodedError("ERR_FONT_API",`Font family "${t}" is declared more than once in this \`loadAsync\` call. Declare each \`fontFamily\` once, with all of its faces in one \`fontDefinitions\` array.`);o.add(t)}};var t=r(d[0]),n=r(d[1]);function o(t){if(null==t)return;if('number'==typeof t)return Number.isFinite(t)?t:void 0;const n=t.trim().toLowerCase();if('normal'===n)return 400;if('bold'===n)return 700;const o=Number(n);return Number.isFinite(o)?o:void 0}function f(t){if(null==t)return;const n=t.trim().toLowerCase();return'italic'===n||'oblique'===n?'italic':'normal'}function s(n){if(!(n instanceof t.Asset||'string'==typeof n||'number'==typeof n))return n}function l(t){return t.weight??s(t.path)?.weight}function c(t){return t.style??s(t.path)?.style}},1125,[1112,302]);
24
+ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),e.fontSourceFromFace=function(n){const{path:o,display:s}=n,u=(0,l.resolveFaceWeight)(n),c=(0,l.resolveFaceStyle)(n);if(o instanceof t.Asset)return{uri:o.uri,...void 0!==u?{weight:u}:null,...void 0!==c?{style:c}:null,...void 0!==s?{display:s}:null};const y='string'==typeof o||'number'==typeof o?{uri:o}:o;return{...y,weight:u,style:c,display:s??y.display}};var t=r(d[0]),l=r(d[1])},1126,[1112,1125]);
25
+ __d(function(g,r,i,a,m,_e,d){"use strict";Object.defineProperty(_e,'__esModule',{value:!0}),Object.defineProperty(_e,"loadPromises",{enumerable:!0,get:function(){return o}}),_e.markLoaded=function(e){u[e]=!0},_e.isLoadedInCache=c,_e.isLoadedNative=function(e){if(c(e))return!0;{const n=t.default.getLoadedFonts();return!!n?.length&&(n.forEach(e=>{u[e]=!0}),e in u)}},_e.purgeFontFamilyFromCache=function(e){delete u[e]},_e.purgeCache=function(){u={}};var e,n=r(d[0]),t=(e=n)&&e.__esModule?e:{default:e};const o={};let u={};function c(e){return e in u}},1127,[1108]);
26
+ __d(function(g,r,i,a,m,_e,d){"use strict";Object.defineProperty(_e,'__esModule',{value:!0}),Object.defineProperty(_e,"withServerContext",{enumerable:!0,get:function(){return u.withServerContext}}),_e.getServerResources=function(){if(!n.default.getServerResources)throw new t.UnavailabilityError('expo-font','getServerResources');return n.default.getServerResources()},_e.getServerResourceDescriptors=function(){if(!n.default.getServerResourceDescriptors)throw new t.UnavailabilityError('expo-font','getServerResourceDescriptors');return n.default.getServerResourceDescriptors()},_e.registerStaticFont=function(e,o){if(!o)throw new t.CodedError("ERR_FONT_SOURCE",`Cannot load null or undefined font source: { "${e}": ${o} }. Expected asset of type \`FontSource\` for fontFamily of name: "${e}"`);const n=(0,s.getAssetForSource)(o);(0,s.loadSingleFontAsync)(e,n)};var e,t=r(d[0]),o=r(d[1]),n=(e=o)&&e.__esModule?e:{default:e},s=r(d[2]),u=r(d[3])},1128,[302,1108,1111,1109]);
27
+ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"FontDisplay",{enumerable:!0,get:function(){return t}});var t=(function(t){return t.AUTO="auto",t.SWAP="swap",t.BLOCK="block",t.FALLBACK="fallback",t.OPTIONAL="optional",t})({})},1129,[]);
28
+ __d(function(g,r,i,a,m,_e,d){"use strict";function e(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(_e,'__esModule',{value:!0}),_e.renderToImageAsync=async function(e,l){if(!t.default)throw new o.UnavailabilityError('expo-font','ExpoFontUtils.renderToImageAsync');return await t.default.renderToImageAsync(e,{...l,color:l?.color?(0,n.default)(l.color):void 0})};var o=r(d[0]),n=e(r(d[1])),t=e(r(d[2]))},1130,[302,54,1131]);
29
+ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return o}});var t=r(d[0]);class n extends t.NativeModule{async renderToImageAsync(n,o){throw new t.UnavailabilityError('expo-font','renderToImageAsync')}}var o=(0,t.registerWebModule)(n,'ExpoFontUtils')},1131,[302]);
30
+ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"useFonts",{enumerable:!0,get:function(){return u}});var t=r(d[0]),n=r(d[1]);function o(t){return'string'==typeof t?(0,n.isLoaded)(t):Array.isArray(t)?t.every(t=>{const o=t?.fontFamily;return'string'==typeof o&&(0,n.isLoaded)(o)}):Object.keys(t).every(t=>(0,n.isLoaded)(t))}const u='undefined'==typeof window?function(t){return(0,n.loadAsync)(t),[!0,null]}:function(u){const[s,c]=(0,t.useState)(o(u)),[f,y]=(0,t.useState)(null);return(0,t.useEffect)(()=>{let t=!0;return(0,n.loadAsync)(u).then(()=>{t&&c(!0)}).catch(n=>{t&&y(n)}),()=>{t=!1}},[]),[s,f]}},1132,[31,1107]);
31
+ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0});var t=r(d[0]);Object.keys(t).forEach(function(n){'default'===n||Object.prototype.hasOwnProperty.call(e,n)||Object.defineProperty(e,n,{enumerable:!0,get:function(){return t[n]}})})},1133,[1134]);
32
+ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),e.preventAutoHideAsync=async function(){return!1},e.setOptions=function(n){},e.hide=function(){},e.hideAsync=async function(){}},1134,[]);
33
+ __d(function(g,_r,i,a,m,_e,d){"use strict";function e(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(_e,'__esModule',{value:!0}),_e.CarGate=function(){const e=(0,u.useSync)(e=>'device'===e.kind&&!!e.venueId),s=(0,u.useSync)(e=>e.mode),[o,l]=(0,t.useState)(c.useSession.persist.hasHydrated()),[x,b]=(0,t.useState)(!1);return(0,t.useEffect)(()=>{h.PITCH&&(globalThis.__pitchCarBoot=e=>b(!!e))},[]),(0,t.useEffect)(()=>{const e=c.useSession.persist.onFinishHydration(()=>l(!0));return c.useSession.persist.hasHydrated()&&l(!0),e},[]),o?h.PITCH&&x?(0,p.jsx)(T,{}):h.PITCH||e?null:s&&'connecting'!==s?(0,p.jsx)(I,{}):(0,p.jsx)(T,{}):(0,p.jsx)(r.default,{style:[n.default.absoluteFill,{backgroundColor:y.colours.bg,zIndex:1e3}]})};var t=_r(d[0]),n=e(_r(d[1])),r=e(_r(d[2])),s=e(_r(d[3])),o=_r(d[4]),l=_r(d[5]),c=_r(d[6]),u=_r(d[7]),h=_r(d[8]),x=_r(d[9]),y=_r(d[10]),b=_r(d[11]),f=_r(d[12]),p=_r(d[13]);let j=null,w=null;async function C(e){return!e&&w&&Date.now()-w.at<6e4&&new Date(w.r.expiresAt).getTime()-Date.now()>12e4?w.r:j||(j=(0,u.carPairStart)().then(e=>(e.ok&&(w={r:e,at:Date.now()}),e)).finally(()=>{j=null}),j)}function I(){const{width:e,height:c}=(0,s.default)(),[h,j]=(0,t.useState)(null),[w,I]=(0,t.useState)('starting'),[T,k]=(0,t.useState)(''),[D,M]=(0,t.useState)(0),S=(0,t.useRef)(!1),z=(0,t.useCallback)(async(e=!0)=>{if(S.current)return;S.current=!0,I('starting'),k('');const t=await C(e);if(S.current=!1,!t.ok)return I('error'),void k(t.error);j({id:t.requestId,code:t.code,until:new Date(t.expiresAt).getTime()}),I('waiting')},[]);(0,t.useEffect)(()=>{z(!1)},[]),(0,t.useEffect)(()=>{if(!h||'waiting'!==w)return;const e=setInterval(async()=>{M(Math.max(0,Math.round((h.until-Date.now())/1e3)));('expired'===await(0,u.carPairPoll)(h.id)||Date.now()>h.until)&&I('expired')},3e3);return()=>clearInterval(e)},[h,w]);const P=Math.min(120,Math.max(64,Math.round(Math.min(e/9,c/7)))),R=h?.code??'',H=R?`${R.slice(0,3)} ${R.slice(3)}`:'\xb7\xb7\xb7 \xb7\xb7\xb7';return(0,p.jsx)(r.default,{testID:"car-pairing",style:[n.default.absoluteFill,{backgroundColor:y.colours.bg,zIndex:1e3,alignItems:'center',justifyContent:'center',padding:24}],children:(0,p.jsxs)(r.default,{style:{width:'100%',maxWidth:880,alignItems:'center',gap:c<820?10:16},children:[(0,p.jsx)(l.RestaurantLogo,{rid:x.VENUE_RID,size:c<820?64:88}),(0,p.jsx)(o.T,{center:!0,size:28,weight:"semibold",accessibilityRole:"header",children:"The Anchorage \xb7 car screen"}),(0,p.jsx)(f.ParkedOnly,{}),'waiting'===w||'starting'===w?(0,p.jsxs)(p.Fragment,{children:[(0,p.jsx)(o.T,{center:!0,size:18,colour:y.colours.muted,children:"Pair this car from your phone"}),(0,p.jsx)(r.default,{testID:"car-code",accessible:!0,accessibilityLabel:R?`Car code ${(0,b.spokenCode)(R)}`:'Making a code',accessibilityLiveRegion:"polite",style:{paddingHorizontal:32,paddingVertical:10,borderRadius:20,borderWidth:1.5,borderColor:y.colours.gold,backgroundColor:'rgba(201,162,74,0.10)'},children:(0,p.jsx)(o.T,{center:!0,size:P,weight:"bold",colour:y.colours.goldLight,style:{letterSpacing:P/8,lineHeight:1.2*P},children:H})}),R?(0,p.jsx)(o.Muted,{center:!0,children:`This code works for ${Math.max(1,Math.ceil((D||600)/60))} more minute${1===Math.ceil((D||600)/60)?'':'s'}.`}):null,(0,p.jsxs)(r.default,{testID:"car-steps",style:{gap:4,alignItems:'center'},children:[(0,p.jsx)(o.T,{center:!0,size:18,children:"1. On your phone, open CoverCharge for Managers."}),(0,p.jsx)(o.T,{center:!0,size:18,children:"2. Go to More, then Car screen."}),(0,p.jsx)(o.T,{center:!0,size:18,children:"3. Type these 6 numbers and tap Approve. Only an owner can do this."})]}),(0,p.jsx)(r.default,{style:{flexDirection:'row',gap:12,flexWrap:'wrap',justifyContent:'center'},children:(0,p.jsx)(o.Button,{testID:"car-new-code",kind:"secondary",label:"New code",onPress:()=>{z()},style:{minHeight:64,minWidth:200}})})]}):'expired'===w?(0,p.jsxs)(p.Fragment,{children:[(0,p.jsx)(o.T,{center:!0,size:22,weight:"semibold",colour:y.colours.goldLight,children:"That code has run out"}),(0,p.jsx)(o.Button,{testID:"car-new-code",label:"Make a new code",onPress:()=>{z()},style:{minHeight:64,minWidth:280}})]}):(0,p.jsxs)(p.Fragment,{children:[(0,p.jsx)(o.T,{center:!0,size:20,weight:"semibold",colour:y.colours.amber,children:"Couldn\u2019t make a code"}),(0,p.jsx)(o.Muted,{center:!0,children:T}),(0,p.jsx)(o.Button,{testID:"car-new-code",label:"Try again",onPress:()=>{z()},style:{minHeight:64,minWidth:240}})]}),T&&'error'!==w?(0,p.jsx)(o.T,{center:!0,colour:y.colours.amber,children:T}):null,(0,p.jsx)(o.Muted,{center:!0,style:{maxWidth:640},children:"Don\u2019t open your personal app link in the car: it stays on your phone. Use this screen only when the car is in Park."})]})})}function T(){const[e,s]=(0,t.useState)(!1);return(0,t.useEffect)(()=>{const e=setTimeout(()=>s(!0),15e3);return()=>clearTimeout(e)},[]),(0,p.jsxs)(r.default,{testID:"car-boot",style:[n.default.absoluteFill,{backgroundColor:y.colours.bg,zIndex:1e3,alignItems:'center',justifyContent:'center',padding:24,gap:16}],children:[(0,p.jsx)(l.RestaurantLogo,{rid:x.VENUE_RID,size:72}),(0,p.jsxs)(r.default,{accessible:!0,accessibilityRole:'alert',accessibilityLiveRegion:"polite",accessibilityLabel:e?'Still connecting. Check the car has mobile data or Wi-Fi, or tap Reload.':'The Anchorage car screen. Connecting\u2026',children:[(0,p.jsx)(o.T,{center:!0,size:24,weight:"semibold",children:e?'Still connecting\u2026':'Connecting\u2026'}),e?(0,p.jsx)(o.Muted,{center:!0,children:"Check the car has mobile data or Wi-Fi, or tap Reload."}):null]}),e?(0,p.jsx)(o.Button,{testID:"car-boot-reload",label:"Reload",onPress:()=>{try{location.reload()}catch{}},style:{minHeight:64,minWidth:220}}):null]})}},1135,[31,47,128,288,818,868,866,824,2,5,825,1136,1137,25]);
34
+ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"CAR_BUTTONS",{enumerable:!0,get:function(){return s}}),Object.defineProperty(e,"MENU_BUTTON",{enumerable:!0,get:function(){return o}}),e.menuSizes=function(s,o){const t=Math.round(Math.max(300,Math.min(s-24,s>=1600?520:s>=1200?460:420))),l=Math.floor((t-40-2)/3),n=Math.floor(Math.max(84,(o-72-40)/4)),c=o>=1e3?15:13,b=Math.round(1.4*c),h=Math.max(52,Math.min(76,n-b-18,l-28));return{panelW:t,colW:l,per:n,circle:h,label:c,lineH:b,icon:Math.round(.44*h),cols:3,rows:4,head:72,pad:20}},Object.defineProperty(e,"spokenCode",{enumerable:!0,get:function(){return t}});const s=[{id:'rota',label:'Rota',short:'Rota',icon:'rota',pages:[{id:'rota',label:'Rota'}]},{id:'signoff',label:'Sign off hours',short:'Sign off',icon:'signoff',pages:[{id:'signoff',label:'Sign off hours'},{id:'timesheets',label:'Timesheets'}]},{id:'menu',label:'Menu & sold out',short:'Menu',icon:'menu',pages:[{id:'soldout',label:'Sold out'},{id:'menu',label:'Menu & allergens'},{id:'tableqr',label:'Table QR codes'}]},{id:'bookings',label:'Bookings',short:'Bookings',icon:'bookings',pages:[{id:'@bookings',label:'Bookings'},{id:'lookback',label:'Look back'}]},{id:'noshows',label:'No-shows',short:'No-shows',icon:'noshow',pages:[{id:'@noshows',label:'No-shows'}]},{id:'chat',label:'Staff chat',short:'Chat',icon:'chat',pages:[{id:'@chat',label:'Staff chat'}]},{id:'stock',label:'Stock & suppliers',short:'Stock',icon:'stock',pages:[{id:'kitchencosts',label:'Deliveries & GP'},{id:'trackedstock',label:'Tracked stock'},{id:'orderlists',label:'Order lists'},{id:'suppliers',label:'Suppliers'}]},{id:'loyalty',label:'Loyalty',short:'Loyalty',icon:'loyalty',pages:[{id:'loyalty',label:'Stamp card'}]},{id:'takings',label:'Takings & tips',short:'Takings',icon:'takings',pages:[{id:'cashup',label:'Cash up & sales'},{id:'tips',label:'Tips'},{id:'spendhead',label:'Spend per head'}]},{id:'safety',label:'Food safety',short:'Safety',icon:'safety',pages:[{id:'haccp',label:'CookSafe log'}]},{id:'reviews',label:'Reviews',short:'Reviews',icon:'reviews',pages:[{id:'reviews',label:'Reviews'}]},{id:'assistant',label:'Assistant',short:'Assistant',icon:'assistant',pages:[{id:'assistant',label:'Assistant'}]}],o=56;const t=s=>s.split('').join(' ')},1136,[]);
35
+ __d(function(g,r,i,a,m,_e,d){"use strict";Object.defineProperty(_e,'__esModule',{value:!0}),_e.ParkedOnly=function({small:e}){return(0,s.jsx)(n.default,{testID:"parked-only",accessible:!0,accessibilityLabel:"Parked only. Use this screen only when the car is in Park.",style:{minHeight:e?28:36,paddingHorizontal:e?8:12,borderRadius:999,borderWidth:1,borderColor:t.colours.amber,backgroundColor:'rgba(232,168,56,0.12)',alignItems:'center',justifyContent:'center',flexShrink:0},children:(0,s.jsx)(o.T,{size:e?11:13,weight:"semibold",colour:t.colours.amber,center:!0,children:"PARKED ONLY"})})},r(d[0]);var e,l=r(d[1]),n=(e=l)&&e.__esModule?e:{default:e},o=r(d[2]),t=r(d[3]),s=r(d[4])},1137,[31,128,818,825,25]);
36
+ __d(function(g,_r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"sharedRecipeCards",{enumerable:!0,get:function(){return l}});var c=_r(d[0]),r=_r(d[1]),s=_r(d[2]),n=_r(d[3]);const o=()=>{const c=n.useSync.getState();return'live'===c.mode&&'guest'!==c.kind&&!!c.venueId};function t(c){if(o()&&!(0,n.can)(c))throw new Error('recipes.signoff'===c?'Only the Head Chef, an owner or a manager can sign off a recipe card.':'Only the head chef, managers and owners can change recipe cards.')}const l={mode:'shared',list:c=>r.localRecipeCards.list(c),get:c=>r.localRecipeCards.get(c),byMenuItem:c=>r.localRecipeCards.byMenuItem(c),subscribe:c=>r.localRecipeCards.subscribe(c),create:async(c,s,n)=>(t('recipes.edit'),r.localRecipeCards.create(c,s,n)),update:async(c,s,n)=>(t('recipes.edit'),r.localRecipeCards.update(c,s,n)),signOff:async(c,s)=>(t('recipes.signoff'),r.localRecipeCards.signOff(c,s)),remove:async(s,n)=>{t('recipes.edit');const o=await r.localRecipeCards.remove(s,n);return c.useGpCalc.getState().removeCardCost(s),o},savePhoto:async(c,s,n)=>(t('recipes.edit'),r.localRecipeCards.savePhoto(c,s,n)),photoSource:c=>r.localRecipeCards.photoSource(c)};function p(){const c=o()?l:r.localRecipeCards;(0,s.recipeCards)()!==c&&(0,s.setRecipeCardRepository)(c)}p(),n.useSync.subscribe((c,r)=>{c.mode===r.mode&&c.kind===r.kind&&c.venueId===r.venueId||p()})},1138,[1150,1151,839,824]);
37
+ __d(function(g,r,i,a,m,_e,d){"use strict";function e(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(_e,'__esModule',{value:!0}),Object.defineProperty(_e,"STRIP",{enumerable:!0,get:function(){return S}}),Object.defineProperty(_e,"SYNC_CONNECTED_GREEN",{enumerable:!0,get:function(){return P}}),_e.syncTone=k,Object.defineProperty(_e,"syncToneColour",{enumerable:!0,get:function(){return z}}),Object.defineProperty(_e,"syncToneSpoken",{enumerable:!0,get:function(){return A}}),_e.SyncBadge=function(){const e=(0,p.useSync)(),[P,L]=(0,o.useState)(!1),[N,W]=(0,o.useState)(e.refused?.at??''),$=e.refused&&e.refused.at!==N?e.refused:void 0,[O,H]=(0,o.useState)(!1),[E,_]=(0,o.useState)(''),V=(0,v.useDisplaySettings)(x.VENUE_RID),M=(0,D.useScreensaverAsleep)(e=>e.asleep),[Y,U]=(0,o.useState)(()=>Date.now());(0,o.useEffect)(()=>{const e=setInterval(()=>U(Date.now()),5e3);return()=>clearInterval(e)},[]);const B='off'===e.mode&&(I.PITCH||!(0,w.isSupabaseConfigured)());if('customer'===b.APP_VARIANT||'off'===e.mode&&!B)return null;if(M)return(0,C.jsx)(y.default,{testID:"sync-strip-asleep",accessibilityElementsHidden:!0,importantForAccessibility:"no-hide-descendants",style:{height:S,backgroundColor:T.colours.bg}});const G=!B&&!!e.venueId&&('live'===e.mode||'offline'===e.mode)&&(e.lastServerAt?(0,l.syncStale)(e.lastServerAt,Y):'offline'===e.mode),K=e.lastServerAt?new Date(e.lastServerAt).toLocaleTimeString('en-GB',{hour:'2-digit',minute:'2-digit'}):'',F='live'===e.mode&&!G,Q='display'===b.APP_VARIANT,q=e.waiting??0,J=`${q} change${1===q?'':'s'} waiting to save`,X=G?'Out of sync':B?I.PITCH?'Demo \xb7 this device only':'This device only':F?q?J:e.pending?`Live \xb7 sending ${e.pending}`:'Live':'offline'===e.mode?"Offline"+(e.pending?` \xb7 ${e.pending} waiting`:''):'connecting'===e.mode?'Connecting\u2026':'unpaired'===e.mode?'Not paired':'On this device',Z=G?'disconnected':k(e.mode,B,q),ee=z(Z),te=G?`Out of sync: nothing from the shared system since ${K||'this app opened'}. Reconnecting by itself; changes made here are kept and sent when it is back.`:B?I.PITCH?'Demo mode. Nothing is shared or sent: everything you do stays in this browser.':'This copy isn\u2019t connected to a shared system. Everything stays on this device.':F?`Shared live with ${e.venueName??'your venue'}${e.lastSyncAt?`. Last update ${new Date(e.lastSyncAt).toLocaleTimeString('en-GB',{hour:'2-digit',minute:'2-digit'})}`:''}.`:'offline'===e.mode?'No connection. Changes are saved on this device and sent when you\u2019re back online.':'signin'===e.mode?'Not connected to the shared system. Open your personal invite link once on this device to connect.':'unpaired'===e.mode?'This display isn\u2019t paired. Use a pairing code from Managers \u2192 Displays.':'connecting'===e.mode?'Connecting to the shared system\u2026':'The shared system can\u2019t be reached, so this device is using its own data.';return(0,C.jsxs)(C.Fragment,{children:[(0,C.jsxs)(y.default,{testID:"sync-strip",style:{height:S,paddingHorizontal:10,flexDirection:'row',gap:10,alignItems:'center',justifyContent:'flex-start',backgroundColor:T.colours.bg,borderTopWidth:1,borderTopColor:'rgba(255,255,255,0.06)'},children:[(0,C.jsxs)(h.default,{testID:"sync-badge",accessibilityRole:"button",accessibilityLabel:q&&F?`${J}, ${A(Z)}. Kept on this device and tried again by itself. Tap for details.`:`${X}, ${A(Z)}. Tap for details.`,accessibilityLiveRegion:"polite",onPress:()=>L(e=>!e),style:{flexDirection:'row',alignItems:'center',gap:6,paddingHorizontal:14,minHeight:44,borderRadius:999,backgroundColor:(0,t.soutersSurface)('rgba(16,14,11,0.92)'),borderWidth:1,borderColor:`${ee}80`,maxWidth:320},children:[(0,C.jsx)(y.default,{testID:"sync-dot",style:{width:10,height:10,borderRadius:5,backgroundColor:ee}}),(0,C.jsx)(j.T,{size:12,weight:"semibold",children:X})]}),G?(0,C.jsx)(y.default,{testID:"sync-out-banner",accessibilityRole:"alert",accessibilityLiveRegion:"assertive",style:{flexShrink:1,flexDirection:'row',alignItems:'center',gap:8,paddingHorizontal:14,minHeight:40,borderRadius:10,backgroundColor:'#3A1712',borderWidth:1,borderColor:T.colours.red},children:(0,C.jsx)(j.T,{size:13,weight:"semibold",numberOfLines:1,children:"Out of sync, reconnecting\u2026"+(K?` Last synced ${K}`:'')})}):null]}),P?(0,C.jsxs)(y.default,{testID:"sync-detail",style:{position:'absolute',left:10,bottom:52,zIndex:900,maxWidth:320,padding:12,borderRadius:12,backgroundColor:(0,t.soutersSurface)('#15120E'),borderWidth:1,borderColor:'rgba(255,255,255,0.14)',gap:4},children:[(0,C.jsx)(j.T,{size:13,children:te}),q?(0,C.jsxs)(y.default,{testID:"sync-waiting",style:{gap:4},children:[(0,C.jsxs)(j.T,{size:12,colour:T.colours.gold,children:[J,". ",1===q?'It is':'They are'," kept on this device and tried again by ",1===q?'itself':'themselves'," until the shared system takes ",1===q?'it':'them',".",e.waitingWhat?` Waiting: ${e.waitingWhat}.`:'']}),(0,C.jsx)(h.default,{testID:"sync-retry",accessibilityRole:"button",accessibilityLabel:"Try saving again now",onPress:()=>{f.mutationQueue.retryNow()},style:{minHeight:44,justifyContent:'center',alignSelf:'flex-start',paddingHorizontal:12,borderRadius:8,borderWidth:1,borderColor:T.colours.gold},children:(0,C.jsx)(j.T,{size:12,colour:T.colours.gold,children:"Try again now"})})]}):null,e.refused?(0,C.jsxs)(j.T,{size:12,colour:T.colours.red,children:["Last change not saved: ",e.refused.what,". ",e.refused.why,"."]}):null,e.message?(0,C.jsx)(j.T,{size:12,colour:T.colours.muted,children:e.message}):null,e.venueId&&(F||'offline'===e.mode)?O?(0,C.jsxs)(y.default,{style:{gap:6,marginTop:6},children:[(0,C.jsx)(j.T,{size:12,children:Q?'Unpair this display? It goes back to the pairing screen and needs a new code from Managers \u2192 Displays.':'Disconnect this device? Your changes stay on it; open your personal invite link to connect again.'}),Q&&V.pinOn?(0,C.jsx)(s.TextInput,{testID:"unpair-pin",value:E,onChangeText:_,placeholder:"Display PIN",placeholderTextColor:T.colours.muted,secureTextEntry:!0,keyboardType:"number-pad",accessibilityLabel:"Display PIN",style:{borderWidth:1,borderColor:'rgba(255,255,255,0.2)',borderRadius:8,paddingHorizontal:10,paddingVertical:6,color:T.colours.text}}):null,(0,C.jsxs)(y.default,{style:{flexDirection:'row',gap:8},children:[(0,C.jsx)(h.default,{testID:"unpair-confirm",accessibilityRole:"button",accessibilityLabel:Q?'Yes, unpair':'Yes, disconnect',disabled:Q&&V.pinOn&&!(0,u.wakePinMatches)(V,E),onPress:()=>{H(!1),L(!1),_(''),Q?(0,p.unpairDisplay)():(0,p.disconnectStaff)()},style:{paddingHorizontal:12,paddingVertical:6,borderRadius:8,backgroundColor:Q&&V.pinOn&&!(0,u.wakePinMatches)(V,E)?'rgba(255,255,255,0.08)':T.colours.red},children:(0,C.jsx)(j.T,{size:12,weight:"semibold",children:Q?'Yes, unpair':'Yes, disconnect'})}),(0,C.jsx)(h.default,{accessibilityRole:"button",accessibilityLabel:"Keep connected",onPress:()=>{H(!1),_('')},style:{paddingHorizontal:12,paddingVertical:6,borderRadius:8,borderWidth:1,borderColor:'rgba(255,255,255,0.2)'},children:(0,C.jsx)(j.T,{size:12,children:"Keep"})})]})]}):(0,C.jsx)(h.default,{testID:"unpair",accessibilityRole:"button",accessibilityLabel:Q?'Unpair this display':'Disconnect this device',onPress:()=>H(!0),style:{marginTop:6,alignSelf:'flex-start'},children:(0,C.jsx)(j.T,{size:12,colour:T.colours.gold,children:Q?'Unpair this display\u2026':'Disconnect this device\u2026'})}):null,(0,C.jsx)(c.WipeDevice,{compact:!0})]}):null,$?(0,C.jsx)(y.default,{testID:"sync-toast",style:{position:'absolute',left:16,right:16,bottom:S+R+8,zIndex:950,alignItems:'center'},pointerEvents:"box-none",children:(0,C.jsxs)(y.default,{accessibilityRole:"alert",accessibilityLiveRegion:"assertive",style:{padding:12,borderRadius:12,backgroundColor:'#3A1712',borderWidth:1,borderColor:T.colours.red,maxWidth:460,gap:8},children:[(0,C.jsx)(j.T,{size:13,children:`Not saved: ${$.what}. Why: ${$.why}. This device now shows what the shared system has, so please make the change again if it is still needed.`}),(0,C.jsx)(n.ToastClose,{testID:"sync-toast-ok",label:"Close this message",onPress:()=>W($.at),style:{minHeight:44,minWidth:44,alignSelf:'flex-end'}})]})}):null]})};var t=r(d[0]),n=r(d[1]),s=r(d[2]),o=r(d[3]),l=r(d[4]),c=r(d[5]),u=r(d[6]),h=e(r(d[7])),y=e(r(d[8])),b=r(d[9]),p=r(d[10]),f=r(d[11]),v=r(d[12]),x=r(d[13]),T=r(d[14]),j=r(d[15]),D=r(d[16]),w=r(d[17]),I=r(d[18]),C=r(d[19]);const S=48,R='display'===b.APP_VARIANT?0:57,P='#3DD68C';function k(e,t,n){return t?'disconnected':'live'===e?n?'pending':'connected':'connecting'===e?'pending':'disconnected'}const z=e=>'connected'===e?P:'pending'===e?T.colours.amber:T.colours.red,A=e=>'connected'===e?'connected':'pending'===e?'not connected yet':'not connected'},1139,[876,835,874,31,1152,1069,986,264,128,807,824,1076,829,5,825,818,939,1153,2,25]);
38
+ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),e.VoiceHost=function(){return null}},1140,[]);
39
+ __d(function(g,r,_i,a,_m,_e,_d){"use strict";Object.defineProperty(_e,'__esModule',{value:!0}),_e.seedPitch=function(){const p='owner'===d.APP_VARIANT?'st-tracy':'chef'===d.APP_VARIANT?'st-bisto':'staff'===d.APP_VARIANT?'st-lenny':null;!p||i.useSession.getState().meId||/[?&]invite=/.test('undefined'!=typeof window?window.location.search:'')||i.useSession.getState().signIn(p);t.useStore.setState(t=>({bookings:t.bookings.map((t,e)=>t.phone||t.walkIn?t:{...t,phone:`07700 900${String(100+e).slice(-3)}`})})),c.PITCH_ANCHORAGE&&(0,u.seedDesktopDemo)((0,e.nowFrom)(t.useStore.getState().clock));const y=s.useOwner.getState();if(y.shifts.some(t=>t.id.startsWith('pitch-')))return;const m=(0,e.nowFrom)(t.useStore.getState().clock),w=l(m),k=m.getHours()+m.getMinutes()/60,A=(0,s.addDays)(w,-(0,s.weekdayOf)(w)),I=[],b=[];for(const[t,[e,o,i]]of Object.entries(S))if(n.ROSTER.some(e=>e.id===t))for(let n=-7;n<14;n++){const d=(0,s.addDays)(A,n),c=(0,s.weekdayOf)(d);if(i.includes(c))continue;I.push({id:`pitch-${t}-${d}`,staffId:t,date:d,day:c,start:e,end:o,published:n<7,breakAt:o-e>=6?e+3.5:void 0});const u='st-jack'===t?{auto:'rota'}:{};d<w?b.push({id:`pitch-a-${t}-${d}`,staffId:t,date:d,in:h(d,u.auto?e:e-.1),out:h(d,u.auto?o:o+.15),inSite:!0,outSite:!0,breakMins:o-e>=6?30:0,signOff:d<(0,s.addDays)(w,-1)?{by:'Alex',byId:'st-gordon',at:h(d,23.5)}:void 0,...u}):d===w&&e<=k&&b.push({id:`pitch-a-${t}-${d}`,staffId:t,date:d,in:h(d,u.auto?e:e-.05),inSite:!0,...u})}s.useOwner.setState({shifts:[...y.shifts.filter(t=>!I.some(e=>e.staffId===t.staffId&&e.date===t.date)),...I],attendance:[...y.attendance,...b]});const v=o.useCashUp.getState();for(let t=1;t<=10;t++){const e=(0,s.addDays)(w,-t);if([0,1].includes((0,s.weekdayOf)(e)))continue;if(v.cashUps.some(t=>t.rid===f&&t.date===e))continue;const o=1450+373*t%900,n=210+97*t%240;v.saveCashUp({rid:f,date:e,vals:{card:o,cash:n,float:200,cashTips:38+13*t%40,cardTips:92+29*t%70,overUnder:3===t?-2.5:0,notes:3===t?'Till 2 short \xa32.50, counted twice.':''},photos:[],confirmedBy:t%2?'Alex':'Priya',confirmedAt:h(e,23.25),readBy:null})}for(let t=1;t<=3;t++){const e=(0,s.addDays)(A,-7*t);if(v.sales.some(t=>t.rid===f&&t.weekStart===e))continue;const o=11800+640*t;v.saveSales({rid:f,weekStart:e,vals:{gross:o,net:Math.round(o/1.2),vat:Math.round(o-o/1.2),covers:610+22*t,discounts:140,refunds:35},categories:[{name:'Food',amount:Math.round(.62*o)},{name:'Drinks',amount:Math.round(.31*o)},{name:'Takeaway',amount:Math.round(.07*o)}],photos:[],confirmedBy:'Alex',confirmedAt:h((0,s.addDays)(e,7),11),readBy:null})}};var t=r(_d[0]),e=r(_d[1]),s=r(_d[2]),o=r(_d[3]),n=r(_d[4]),i=r(_d[5]),d=r(_d[6]),c=r(_d[7]),u=r(_d[8]);const f='anchorage',l=t=>`${t.getFullYear()}-${String(t.getMonth()+1).padStart(2,'0')}-${String(t.getDate()).padStart(2,'0')}`,h=(t,e)=>{const[s,o,n]=t.split('-').map(Number);return new Date(s,o-1,n,Math.floor(e),Math.round(e%1*60)).toISOString()},S={'st-gordon':[11,21,[0,1]],'st-bisto':[10,20.5,[0,1]],'st-agate':[16,22.5,[0,1,2]],'st-lenny':[11,19,[0,1,3]],'st-finn':[17,23,[0,1,4]],'st-eilidh':[12,18,[0,1,2]],'st-emily':[17,22,[0,1,3]],'st-lillie':[12,20,[0,1,5]],'st-jack':[16,22,[0,1,6]]}},1141,[823,881,863,1050,15,866,807,2,1142]);
40
+ __d(function(g,_r,_i,a,_m,e,_d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),e.desktopDemoBookings=m,e.seedDesktopDemo=function(o){if(t.useStore.getState().bookings.some(t=>t.id.startsWith('desk-')))return;const s=m(o);t.useStore.setState(t=>({bookings:[...t.bookings.filter(t=>t.restaurantId!==r),...s]}));const i=n.useCashUp.getState(),l=c(o);for(let t=1;t<=35;t++){const n=u(l,-t),o=new Date(`${n}T12:00:00`).getDay();if(1===o||2===o)continue;if(i.cashUps.some(t=>t.rid===r&&t.date===n))continue;const s=5===o||6===o?1.45:0===o?1.2:.8,d=Math.round((1550+700*h(t+41))*s),c=Math.round((190+200*h(t+43))*s);i.saveCashUp({rid:r,date:n,vals:{card:d,cash:c,float:200,cashTips:Math.round(30+40*h(t+47)),cardTips:Math.round(80+80*h(t+53)*s),overUnder:0,notes:''},photos:[],confirmedBy:'Alex',confirmedAt:new Date(`${n}T23:15:00`).toISOString(),readBy:null})}};var t=_r(_d[0]),n=_r(_d[1]);const r='anchorage',o=['Campbell','Fraser','McLeod','Kerr','Wallace','Boyd','Hamilton','Stewart','Murray','Robertson','Thomson','Reid','Paterson','Ross','Morrison','Young','Watson','Mitchell','Gray','Ferguson','Kennedy','Duncan','Sinclair','Munro','Grant','Docherty','Gallacher','Craig','Shaw','Baird','Hunter','Hendry','Lindsay','Ogilvie','Rennie','Galbraith'],s=['Fiona','Callum','Isla','Euan','Morag','Ross','Kirsty','Andrew','Heather','Neil','Catriona','Graeme','Shona','Iain','Lorna','Craig','Ailsa','Douglas'],i=['12:00','12:30','13:00','13:15','13:30','14:00','17:00','17:30','18:00','18:15','18:30','19:00','19:15','19:30','20:00','20:30'],l=['1','2','3','4','5','6','7','8','9','10','11','12','14','15','16','17','18','19','20','21','22'],d=[[{allergen:'gluten',severity:'coeliac'}],[{allergen:'crustaceans',severity:'allergy'}],[{allergen:'milk',severity:'intolerance'}],[{allergen:'peanuts',severity:'anaphylaxis'},{allergen:'treenuts',severity:'anaphylaxis'}]],c=t=>`${t.getFullYear()}-${String(t.getMonth()+1).padStart(2,'0')}-${String(t.getDate()).padStart(2,'0')}`,u=(t,n)=>{const[r,o,s]=t.split('-').map(Number);return c(new Date(r,o-1,s+n,12))},h=t=>{const n=233280*Math.sin(9301*t+49297);return n-Math.floor(n)},p=t=>60*Number(t.slice(0,2))+Number(t.slice(3,5)),y=(t,n)=>t[Math.floor(h(n)*t.length)%t.length];function m(t){const n=c(t),m=60*t.getHours()+t.getMinutes(),S=[];let f=0;for(let c=-28;c<=14;c++){const M=u(n,c),D=new Date(`${M}T12:00:00`).getDay();if(1===D||2===D)continue;const v=5===D||6===D?16:0===D?13:8,b=Math.max(2,v-(c>0?Math.round(.7*c):0));for(let u=0;u<b;u++){f++;const u=h(f),D=y(i,f+7),v=u<.45?2:u<.7?4:u<.82?3:u<.92?6:u<.97?5:8,b=M<n||M===n&&p(D)<=m,w=M===n&&p(D)<=m&&m-p(D)<100,$=h(f+3),k=!b&&c>0&&$<.05,I=b?$<.03?'noshow':$<.07?'cancelled':w?'seated':'finished':k?'pending':'confirmed',T=k?9+f%4:v,C=h(f+13)<.12?y(d,f+17):[],A=h(f+19);S.push({id:`desk-${f}`,ref:`B-${4100+f}`,restaurantId:r,customerId:null,name:`${y(s,f+11)} ${y(o,f+5)}`,partySize:T,date:M,time:D,table:k?void 0:y(l,f+29),allergies:C,allergyNone:!C.length,notes:h(f+31)<.08?'Window table if possible':'',status:I,security:T>=8?'deposit':'none',depositPaid:T>=8&&!k?1e3*T:0,depositDue:T>=8?1e3*T:void 0,createdAt:new Date(t.getTime()-864e5*(30-c)).toISOString(),phone:`07700 900${String(f%1e3).padStart(3,'0')}`,source:h(f+37)<.62?'online':'phone',occasion:A<.06?'birthday':A<.09?'anniversary':void 0,...'seated'===I?{seatedAt:new Date(t.getTime()-6e4*(m-p(D))).toISOString()}:{}})}}return S}},1142,[823,1050]);
41
+ __d(function(e,o,s,t,p,a,n){"use strict";p.exports="/abbotsford/customer-app/assets/node_modules/@expo-google-fonts/poppins/400Regular/Poppins_400Regular.093ee89be9ede30383f39a899c485a82.ttf"},1143,[]);
42
+ __d(function(o,s,e,t,p,c,d){"use strict";p.exports="/abbotsford/customer-app/assets/node_modules/@expo-google-fonts/poppins/500Medium/Poppins_500Medium.bf59c687bc6d3a70204d3944082c5cc0.ttf"},1144,[]);
43
+ __d(function(o,s,e,t,p,d,f){"use strict";p.exports="/abbotsford/customer-app/assets/node_modules/@expo-google-fonts/poppins/600SemiBold/Poppins_600SemiBold.6f1520d107205975713ba09df778f93f.ttf"},1145,[]);
44
+ __d(function(o,s,t,d,e,p,n){"use strict";e.exports="/abbotsford/customer-app/assets/node_modules/@expo-google-fonts/poppins/700Bold/Poppins_700Bold.08c20a487911694291bd8c5de41315ad.ttf"},1146,[]);
abbotsford/customer-app/_expo/static/js/web/basket-b6d5d5daeda35a03cd8137d4a926f820.js ADDED
@@ -0,0 +1 @@
 
 
1
+ __d(function(g,_r,_i,_a,_m,_e,d){"use strict";function e(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(_e,'__esModule',{value:!0}),Object.defineProperty(_e,"default",{enumerable:!0,get:function(){return v}});var l=_r(d[0]),t=_r(d[1]),a=_r(d[2]),n=e(a),o=_r(d[3]),r=_r(d[4]),s=e(_r(d[5])),i=_r(d[6]),u=_r(d[7]),c=_r(d[8]),h=_r(d[9]),m=_r(d[10]),b=_r(d[11]),y=_r(d[12]),j=_r(d[13]),x=_r(d[14]),k=_r(d[15]),p=_r(d[16]),f=_r(d[17]);function v(){const e=(0,b.useBasket)(),v=(0,b.useRestaurant)(e.restaurantId??void 0),w=(0,b.useAllMenu)(e.restaurantId??void 0),C=(0,b.useCustomer)(),S=(0,b.useOrders)(v?.id),T=(0,b.useStore)(e=>e.setLineQty),B=(0,b.useStore)(e=>e.overrideLine),P=(0,b.useStore)(e=>e.startBasket),I=(0,b.useNow)(15e3),[O,$]=(0,a.useState)(null),[N,M]=(0,a.useState)(!1),[F,L]=(0,a.useState)(''),[z]=(0,a.useState)(()=>(0,r.startForm)()),[A,R]=(0,a.useState)(''),[Y,D]=(0,a.useState)(C.phone??''),[E,_]=(0,a.useState)(C.email??''),[q,H]=(0,a.useState)(C.name&&'Guest'!==C.name?C.name:''),[G,V]=(0,a.useState)(!1),K=(0,b.useOrderAtTable)(e.restaurantId??void 0),Q=(0,p.useTakeawayMenu)(l=>e.restaurantId?l.byVenue[e.restaurantId]:void 0);n.default.useEffect(()=>{K||'table'!==e.mode||b.useStore.setState(e=>({basket:{...e.basket,mode:'takeaway',tableNo:void 0}}))},[K,e.mode]);const[U,J]=(0,a.useState)(null),[W,X]=(0,a.useState)(!1),Z=(0,a.useMemo)(()=>(0,y.linesFromBasket)(e,w,C.allergies),[e,w,C.allergies]);if(!v||!e.lines.length)return(0,f.jsxs)(i.Screen,{title:"Your basket",children:[(0,f.jsx)(i.Muted,{children:"Your basket is empty."}),(0,f.jsx)(i.Button,{label:"Browse restaurants",onPress:()=>t.router.replace('/customer')})]});const ee=K&&'table'===e.mode,le=(0,h.takeawaySlots)(v,S,I),te=Z.reduce((e,l)=>e+l.unitPrice*l.qty,0),ae=Z.some(e=>e.contains.length&&!e.overridden),ne=e.lines.filter(e=>{const l=w.find(l=>l.id===e.itemId);return!l||l.soldOut||!l.signOff||!ee&&'on'!==(0,p.takeawayAvail)(l,Q)}),oe=!ee&&!O,re=!ee&&v.settings.takeawayPaused,se=(0,x.ukPhone)(Y),ie=q.trim().length>=2&&'guest'!==q.trim().toLowerCase(),de=ee||(0,p.takesCardTakeaway)(v,k.IS_ISOLATED_VENUE),ue=!G&&de&&!ae&&!ne.length&&N&&!oe&&!re&&(ee||ie&&se.ok&&(0,x.emailOk)(E)),ce=async()=>{V(!0);try{const e=await b.repo.orders.placeFromBasket({slotTime:ee?void 0:O,tip:0,notes:F,phone:ee?void 0:se.pretty,email:ee?void 0:E.trim()||void 0,customerName:ee?void 0:q.trim()});(0,r.rememberGuard)(e.id,(0,r.guardFor)({...z,hp:A})),t.router.replace(`/customer/order/${e.id}`)}finally{V(!1)}},he=e.lines.find(e=>e.key===U),me=he?Z[e.lines.indexOf(he)]:void 0;return(0,f.jsxs)(i.Screen,{title:"Your basket",subtitle:`${v.name} \xb7 ${ee?`${(0,l.tableNumbers)(e.tableNo)} (order at table)`:'Takeaway \u2014 collection'}`,footer:(0,f.jsxs)(s.default,{style:{gap:8},children:[(0,f.jsxs)(i.Row,{style:{justifyContent:'space-between'},children:[(0,f.jsx)(i.T,{weight:"semibold",children:"Subtotal"}),(0,f.jsx)(i.T,{weight:"bold",size:20,colour:j.colours.gold,children:(0,c.gbp)(te)})]}),de?ae?(0,f.jsx)(i.T,{size:14,colour:j.colours.red,children:"Resolve the blocked allergy item(s) before continuing."}):N?oe&&!re?(0,f.jsx)(i.T,{size:14,colour:j.colours.amber,children:"Choose a collection time."}):ee||ie?ee||se.ok?null:(0,f.jsx)(i.T,{size:14,colour:j.colours.amber,children:"Add your mobile number."}):(0,f.jsx)(i.T,{size:14,colour:j.colours.amber,children:"Add your name for the order."}):(0,f.jsx)(i.T,{size:14,colour:j.colours.amber,children:"Confirm your allergies to continue."}):(0,f.jsx)(i.T,{size:14,colour:j.colours.amber,children:"Online takeaway orders aren\u2019t available for this restaurant. Please ring them to order."}),ee?(0,f.jsx)(i.Button,{label:"Send order to the kitchen",disabled:!ue,onPress:()=>ce(),testID:"send-table-order"}):(0,f.jsx)(i.Button,{label:G?'Saving your order\u2026':`Continue to card payment \xb7 ${(0,c.gbp)(te)}`,disabled:!ue,onPress:()=>ce(),testID:"checkout"}),ee?null:(0,f.jsx)(i.Muted,{children:"You pay by card on the restaurant\u2019s secure checkout. Your order goes to the kitchen once it\u2019s paid. You have 15 minutes to pay."})]}),children:[(ee||e.tableNo,null),ee?(0,f.jsx)(i.Banner,{kind:"success",title:`${(0,l.tableNumbers)(e.tableNo)}`,children:"Ordered food goes to the kitchen straight away; you pay at the end (split the bill if you like)."}):null,v.fictional?null:(0,f.jsx)(i.AllergenNotice,{phone:v.phone}),Z.map((l,t)=>{const a=e.lines[t],n=l.contains.length&&!l.overridden;return(0,f.jsxs)(i.Card,{highlight:l.contains.length?j.colours.red:l.may.length?j.colours.amber:void 0,children:[(0,f.jsxs)(i.Row,{style:{justifyContent:'space-between',alignItems:'flex-start'},children:[(0,f.jsxs)(s.default,{style:{flex:1,paddingRight:8},children:[(0,f.jsx)(i.T,{weight:"semibold",children:l.name}),l.choices.length?(0,f.jsx)(i.Muted,{children:l.choices.join(' \xb7 ')}):null,l.notes?(0,f.jsxs)(i.Muted,{children:["Note: ",l.notes]}):null]}),(0,f.jsx)(i.T,{weight:"semibold",children:(0,c.gbp)(l.unitPrice*l.qty)})]}),n?(0,f.jsxs)(i.Banner,{kind:"danger",title:`BLOCKED \u2014 contains ${l.contains.map(u.allergenLabel).join(', ')}`,children:[(0,f.jsx)(i.T,{size:14,colour:"#FFE3DF",children:`Conflicts with your declared ${C.allergies.filter(e=>l.contains.includes(e.allergen)).map(e=>`${(0,u.allergenLabel)(e.allergen)} (${(0,u.severityLabel)(e.severity)})`).join(', ')}.`}),(0,f.jsxs)(i.Row,{gap:8,style:{marginTop:6},children:[(0,f.jsx)(i.Button,{small:!0,kind:"secondary",label:"Remove",onPress:()=>T(a.key,0)}),(0,f.jsx)(i.Button,{small:!0,kind:"danger",label:"Override\u2026",onPress:()=>{X(!1),J(a.key)}})]})]}):l.contains.length?(0,f.jsx)(i.Banner,{kind:"danger",title:`Allergy override recorded \u2014 contains ${l.contains.map(u.allergenLabel).join(', ')}`,children:"The kitchen will get an allergy alert that must be acknowledged, and staff will check with you at handover."}):null,l.may.length?(0,f.jsx)(i.Banner,{kind:"warn",title:`May contain ${l.may.map(u.allergenLabel).join(', ')}`,children:"Cross-contact risk (e.g. shared fryer). Please check with staff."}):null,ne.includes(a)?(0,f.jsx)(i.Badge,{kind:"amber",label:!ee&&Q&&w.find(e=>e.id===a.itemId)&&'sold-out'===(0,p.takeawayAvail)(w.find(e=>e.id===a.itemId),Q)?'Sold out \u2014 please remove':'Not available for takeaway \u2014 please remove'}):null,(0,f.jsxs)(i.Row,{style:{justifyContent:'space-between'},children:[(0,f.jsx)(i.Button,{small:!0,kind:"ghost",label:"Remove",onPress:()=>T(a.key,0)}),(0,f.jsx)(i.Stepper,{value:a.qty,onChange:e=>T(a.key,e),min:1,label:l.name})]})]},a.key)}),(0,f.jsx)(i.Button,{kind:"ghost",label:"Add more items",onPress:()=>t.router.push(`/customer/${v.id}`)}),ee?null:(0,f.jsxs)(i.Card,{children:[(0,f.jsxs)(i.H2,{children:["Collection time \u2014 ",(0,m.niceDate)(I)]}),re?(0,f.jsx)(i.Banner,{kind:"warn",title:"Takeaway paused",children:"The restaurant has paused takeaway slots for now. Please try again later or book a table."}):0===le.length?(0,f.jsx)(i.Banner,{kind:"warn",children:"No collection slots left today."}):(0,f.jsxs)(f.Fragment,{children:[(0,f.jsxs)(i.Muted,{children:["15-minute slots, max ",v.settings.slotCap," orders each so the kitchen isn\u2019t overloaded."]}),(0,f.jsx)(i.Row,{wrap:!0,gap:6,children:le.slice(0,16).map(e=>(0,f.jsx)(i.Chip,{label:e.label,sub:e.full?'Full':e.cap-e.taken+" left",disabled:e.full,selected:O===e.time.toISOString(),onPress:()=>$(e.time.toISOString())},e.label))})]})]}),(0,f.jsxs)(i.Card,{highlight:N?void 0:j.colours.amber,children:[(0,f.jsx)(i.H2,{children:"Confirm allergies for this order"}),(0,f.jsx)(i.Row,{wrap:!0,gap:6,children:C.allergies.length?C.allergies.map(e=>(0,f.jsx)(i.Badge,{kind:"red",label:`${(0,u.allergenLabel)(e.allergen)} \u2014 ${(0,u.severityLabel)(e.severity)}`},e.allergen)):(0,f.jsx)(i.Muted,{children:"No allergies declared on your profile."})}),(0,f.jsx)(i.Toggle,{label:C.allergies.length?'Yes, these are correct for everyone this order is for':'I confirm no one in this order has a food allergy',value:N,onChange:M}),(0,f.jsx)(i.Button,{small:!0,kind:"ghost",label:"Edit allergies in profile",onPress:()=>t.router.push('/customer/profile')})]}),ee?null:(0,f.jsxs)(i.Card,{children:[(0,f.jsx)(i.H2,{children:"Your details"}),(0,f.jsx)(i.Field,{testID:"order-name",label:"Name for the order",value:q,onChangeText:H,autoComplete:"name",placeholder:"e.g. Sam Smith"}),q&&!ie?(0,f.jsx)(i.T,{size:13,colour:j.colours.amber,children:"Please add your name."}):null,(0,f.jsx)(i.Field,{testID:"order-phone",label:"Mobile number (needed for collection)",value:Y,onChangeText:D,keyboardType:"phone-pad",autoComplete:"tel",placeholder:"e.g. 07700 900123"}),!se.ok&&Y?(0,f.jsx)(i.T,{size:13,colour:j.colours.amber,children:se.error}):null,(0,f.jsx)(i.Field,{label:"Email (optional)",value:E,onChangeText:_,keyboardType:"email-address",autoCapitalize:"none",placeholder:"you@example.com"}),(0,x.emailOk)(E)?null:(0,f.jsx)(i.T,{size:13,colour:j.colours.amber,children:"That email doesn\u2019t look quite right. Check it, or leave it blank."}),(0,f.jsx)(i.Muted,{children:"Your order confirmation and collection time are shown here. Text messages are not connected."})]}),(0,f.jsx)(i.Field,{label:"Order notes (optional)",value:F,onChangeText:L,placeholder:"e.g. cutlery please"}),ee?(0,f.jsx)(i.Button,{small:!0,kind:"ghost",label:"Switch to takeaway instead",onPress:()=>P(v.id,'takeaway')}):null,(0,f.jsxs)(i.Sheet,{visible:!!he,onClose:()=>J(null),title:"Allergy override",children:[me?(0,f.jsx)(i.Banner,{kind:"danger",title:`${me.name} contains ${me.contains.map(u.allergenLabel).join(', ')}`,children:"Only continue if this item is for someone without this allergy, or you have spoken to staff."}):null,(0,f.jsx)(i.Toggle,{label:"I understand and want to add it anyway",value:W,onChange:X}),(0,f.jsx)(i.Button,{kind:"danger",disabled:!W,label:"Confirm override",onPress:()=>{he&&me&&B(he.key,me.contains),J(null)}})]}),(0,f.jsx)(o.Honeypot,{value:A,onChange:R})]})}},790,[812,805,31,815,816,128,818,819,820,821,822,823,881,825,827,5,836,25]);
abbotsford/customer-app/_expo/static/js/web/book-34e99aaf0197899dc09c20d6bb54139f.js ADDED
@@ -0,0 +1,4 @@
 
 
 
 
 
1
+ __d(function(g,_r,_i,_a,m,_e,d){"use strict";Object.defineProperty(_e,'__esModule',{value:!0}),Object.defineProperty(_e,"default",{enumerable:!0,get:function(){return A}});var e,t=_r(d[0]),o=_r(d[1]),n=_r(d[2]),s=_r(d[3]),l=_r(d[4]),i=_r(d[5]),a=_r(d[6]),r=_r(d[7]),u=(e=r)&&e.__esModule?e:{default:e},c=_r(d[8]),h=_r(d[9]),p=_r(d[10]),b=_r(d[11]),f=_r(d[12]),y=_r(d[13]),x=_r(d[14]),k=_r(d[15]),j=_r(d[16]),v=_r(d[17]),S=_r(d[18]),w=_r(d[19]),T=_r(d[20]),C=_r(d[21]),D=_r(d[22]),$=_r(d[23]),P=_r(d[24]),M=_r(d[25]),B=_r(d[26]),O=_r(d[27]);function A(){const{rid:e,date:r}=(0,s.useLocalSearchParams)(),A=(0,j.useRestaurant)(e),N=(0,j.useCustomer)(),z=(0,j.useBookings)(e),I=(0,j.useEvents)(e),R=(0,j.useNow)(6e4),[q]=(0,l.useState)(()=>(0,a.startForm)()),[F,L]=(0,l.useState)(''),[E,H]=(0,l.useState)(2),[W,_]=(0,l.useState)(0),Y=Math.min(W,Math.max(0,E-1)),[U,G]=(0,l.useState)(r??(0,k.ymd)(R)),[Q,V]=(0,l.useState)(null),[J,K]=(0,l.useState)(N.name),[X,Z]=(0,l.useState)(N.phone??''),[ee,te]=(0,l.useState)(N.email??''),[oe,ne]=(0,l.useState)(!1),[se,le]=(0,l.useState)(''),[ie,ae]=(0,l.useState)(!1),[re,de]=(0,l.useState)([]),[ue,ce]=(0,l.useState)(!1),he=[...N.allergies,...re.filter(e=>!N.allergies.some(t=>t.allergen===e)).map(e=>({allergen:e,severity:'allergy'}))],[me,ge]=(0,l.useState)(null),pe=(0,C.useBlocks)(e=>e.blocks);(0,v.usePublicDayStore)(e=>e.n);const be=e?(0,v.publicDay)(e,U):null,fe=be?[...be.bookings,...z.filter(e=>e.date!==U)]:z,ye=be?[...pe.filter(t=>t.rid!==e||t.date!==U),...be.blocks]:pe,xe=(0,D.usePlan)(e),[ke,je]=(0,l.useState)((0,P.emptyNeeds)()),ve=!0===ke.dog,Se=ve?ke.dogs:0;if(!A)return(0,O.jsx)(b.Screen,{title:"Not found",children:(0,O.jsx)(b.T,{children:"Restaurant not found."})});const we=A.settings,Te=(0,k.parseYmd)(U),Ce=(0,x.onlinePartyBounds)(A),De=(0,C.blocksOn)(ye,A.id,U),$e=fe.filter(e=>e.date===U),Pe=xe.areas.filter(e=>e.dogs),Me=(0,M.dogSetUp)(xe),Be=e=>(0,$.freeTablesAt)(xe,$e,E,new Date(`${U}${(0,t.tableNumbers)(e)}:00`),(0,$.turnFor)(E,we.turnMins),we.turnMins,{dog:!0,closed:(0,C.closedAreasAt)(ye,A.id,U,e)}),Oe=(0,x.bookingSlots)(A,Te,e=>fe.filter(t=>t.date===U&&t.time===e&&!['cancelled','noshow'].includes(t.status)).reduce((e,t)=>e+t.partySize,0),E,R,e=>fe.filter(t=>t.date===U&&t.time===e&&!['cancelled','noshow'].includes(t.status)).length).map(e=>{const t=(0,C.blockAt)(ye,A.id,U,e.time),o=ve&&Me&&e.available&&!t&&(!Be(e.time).length||!(0,P.dogTimeOk)(A,fe,U,e.time,Se));return{...e,blocked:!!t,noDog:o,available:e.available&&!t&&!o}}),Ae=Oe.some(e=>e.available),Ne=(0,c.depositOf)(we),ze=(0,c.depositDue)(Ne,E,Y),Ie=ze>0?'deposit':'none',Re=(0,c.depositWords)(Ne,E,A.name,Y),qe=I.filter(e=>e.date===U),Fe=(0,T.guestPhone)(X),Le=(0,T.emailOk)(ee),Ee=(0,P.needsMissing)(ke,N.allergies),He=!!Q&&ie&&!Ee.length&&J.trim().length>1&&Fe.ok&&Le,We=async()=>{const e=(0,P.needsPatch)(ke,N.allergies),t=ve&&Me?Be(Q).map(e=>e.table):[],o=ve?ke.tableReq.find(e=>t.includes(e))??t[0]:void 0,n=await j.repo.bookings.create({restaurantId:A.id,customerId:N.id,name:J,partySize:E,...Y?{children:Y}:{},date:U,time:Q,notes:se.trim(),security:Ie,depositPaid:0,...ze?{depositDue:ze,depositPolicy:Re.join(' '),depositRefundable:Ne.refundable,depositCutoffHours:Ne.cutoffHours}:{},phone:Fe.pretty,email:ee.trim()||void 0,source:'online',...e,...Oe.find(e=>e.time===Q)?.drinksOnly?{drinksOnly:!0}:{},allergies:e.allergies??he,...o?{table:o}:{}});(0,a.rememberGuard)(n.id,(0,a.guardFor)({...q,hp:F})),ge(n)},Ye=(0,j.useStore)(e=>me?e.bookings.find(e=>e.id===me.id)?.ref:void 0),Ue=e=>(0,w.waMeLink)(A.settings.whatsapp,(0,w.guestWhatsAppText)({name:e.name,ref:Ye??e.ref,date:e.date,time:e.time,partySize:e.partySize},A.name));if(me){const e='pending'===me.status;return(0,O.jsxs)(b.Screen,{title:e?'Booking request received':'Booking confirmed',subtitle:A.name,children:[(0,O.jsx)(b.Banner,{kind:e?'info':'success',title:`Reference ${Ye??me.ref}`,children:`${me.partySize} people \xb7 ${(0,k.niceDateYear)((0,k.parseYmd)(me.date))} at ${me.time}`}),e?(0,O.jsx)(b.Banner,{kind:"warn",title:"The team will confirm shortly",children:"For larger parties and special requests, a member of the team checks your booking first. Contact the venue if you need an update."}):null,(0,O.jsxs)(b.Card,{children:[(0,O.jsxs)(b.T,{children:["Name: ",me.name]}),(0,O.jsxs)(b.T,{children:["Mobile: ",me.phone]}),me.email?(0,O.jsxs)(b.T,{children:["Email: ",me.email]}):null,(0,O.jsxs)(b.T,{children:["Allergies shared with the restaurant: ",me.allergies.length?me.allergies.map(e=>`${(0,f.allergenLabel)(e.allergen)} (${(0,f.severityLabel)(e.severity)})`).join(', '):'none']}),me.notes?(0,O.jsxs)(b.T,{children:["Notes: ",me.notes]}):null,me.dog?(0,O.jsxs)(b.T,{children:["\ud83d\udc15 Dog coming too",me.table?` \xb7 dog-friendly table ${me.table}`:'']}):null,me.holds?.length?(0,O.jsxs)(b.T,{children:["Reserved: ",me.holds.map(e=>`${e.qty} \xd7 ${'item'===e.kind?(A.settings.reservables??M.ANCHORAGE_RESERVABLES).find(t=>t.id===e.id)?.name??'item':e.id}`).join(', ')," (the kitchen confirms it)"]}):null,me.tableReq?.length?(0,O.jsxs)(b.T,{children:["Table requested: ",me.tableReq.map(e=>`${(0,t.tableNumbers)(e)}`).join(' or ')," (not guaranteed, but we\u2019ll do our best)"]}):null,'deposit'===me.security&&me.depositDue?(0,O.jsxs)(b.T,{weight:"semibold",children:["Deposit due: ",(0,y.gbp)(me.depositDue),". ",A.name," will tell you how to pay it."]}):null,'deposit'===me.security&&me.depositPolicy?(0,O.jsx)(b.Muted,{children:me.depositPolicy}):null,(0,O.jsx)(b.Muted,{children:"Your booking details are shown above. If you need confirmation, contact the venue and quote your reference."}),(0,O.jsxs)(b.Muted,{children:["Need to change or cancel? Call ",A.phone," and quote ",Ye??me.ref,"."]})]}),Ue(me)?(0,O.jsxs)(u.default,{style:{gap:4},children:[(0,O.jsx)(b.Button,{kind:"secondary",label:"\ud83d\udcac Message us on WhatsApp",testID:"guest-whatsapp",onPress:()=>{const e=Ue(me);e&&(0,w.openWhatsApp)(e)}}),(0,O.jsx)(b.Muted,{size:13,children:"Opens WhatsApp with your booking details typed in. You can change the message before you send it."})]}):null,(0,O.jsx)(b.Button,{label:"Back to restaurant",onPress:()=>s.router.replace(`/customer/${A.id}`)})]})}return(0,O.jsxs)(b.Screen,{title:"Book a table",subtitle:A.name,footer:(0,O.jsx)(b.Button,{label:Ee.length?Ee[0]:E>(we.autoAcceptUpTo??7)?'Send booking request':'Confirm booking',disabled:!He,onPress:()=>We(),testID:"confirm-booking"}),children:[(0,O.jsx)(P.FirstQuestions,{rid:A.id,value:ke,onChange:e=>{e.dog===ke.dog&&e.dogs===ke.dogs||V(null),je(e)},party:E,audience:"guest",profile:N.allergies}),(0,O.jsxs)(b.Card,{children:[(0,O.jsxs)(u.default,{style:{gap:6,alignItems:'center'},children:[(0,O.jsx)(b.H2,{children:"Party size"}),(0,O.jsx)(o.PartySizeInput,{value:E,onChange:e=>{H(e),V(null)},min:Ce.min,max:Ce.max,label:"Party size",testID:"party-size"})]}),(0,O.jsx)(h.ChildrenCount,{guest:!0,party:E,value:Y,onChange:_,depositsOn:Ne.on&&Ne.perPersonPence>0,testID:"book-children"}),ze?(0,O.jsx)(b.Banner,{kind:"info",title:Y?`Deposit: ${(0,y.gbp)(ze)} for ${E-Y} adults (children free)`:`Deposit: ${(0,y.gbp)(ze)} for ${E} guests`,children:(0,O.jsx)(u.default,{style:{gap:4},children:Re.map(e=>(0,O.jsx)(b.T,{size:13,children:e},e))})}):Ne.on&&Ne.perPersonPence>0?(0,O.jsxs)(b.Muted,{children:["No deposit for fewer than ",Ne.fromParty," guests."]}):null,E>(we.autoAcceptUpTo??7)?(0,O.jsxs)(b.Muted,{children:["For ",E," people the team checks the booking first, then texts you to confirm."]}):null,ve&&Me?(0,O.jsxs)(b.Muted,{children:["Dogs are welcome in the ",Pe.map(e=>`${e.name}${e.outdoor?' (outdoors, weather permitting)':''}`).join(' and ')||'dog-friendly tables',". We\u2019ll only show times with a dog-friendly table",A.settings.maxDogsPerSlot?' and room for your dog':'',"."]}):null]}),(0,O.jsxs)(b.Card,{children:[(0,O.jsx)(b.H2,{children:"Date"}),(0,O.jsx)(B.CustomerDatePicker,{r:A,today:R,value:U,events:I,onChange:e=>{G(e),V(null)}}),qe.map(e=>(0,O.jsx)(b.Banner,{kind:"demo",title:e.title,children:e.description},e.id))]}),(0,O.jsxs)(b.Card,{children:[(0,O.jsx)(b.H2,{children:"Time"}),0===Oe.length?(0,O.jsx)(b.Muted,{children:"Closed on this day (per listed kitchen hours)."}):(0,O.jsx)(b.Row,{wrap:!0,gap:6,children:Oe.map(e=>(0,O.jsx)(b.Chip,{testID:`book-slot-${e.time}`,label:e.time,sub:e.available?e.drinksOnly?'Drinks only':void 0:e.blocked?'Unavailable':e.noDog?'No dog table':e.left<E||null!=e.partiesLeft&&e.partiesLeft<1?'Full':'\u2014',disabled:!e.available,selected:Q===e.time,onPress:()=>V(e.time)},e.time))}),De.length>0&&Oe.some(e=>e.blocked)?(0,O.jsx)(b.Banner,{kind:"info",title:Ae?'Some times aren\u2019t available online':'Online booking isn\u2019t available for this time',children:`We\u2019re not taking online bookings ${De.map(e=>`${e.from}\u2013${e.to}`).join(', ')} on ${(0,k.niceDate)(Te)}. Please give us a ring on ${A.phone??"the restaurant"} and we\u2019ll do our best to fit you in.`}):null,(()=>{const e=(0,n.lastFoodOn)(A,U);return e&&Oe.some(e=>e.drinksOnly)?(0,O.jsx)(b.Banner,{kind:"info",title:`Last food orders ${(0,n.fmt12)(e.time)}${'kitchen closes'!==e.reason?` (${e.reason})`:''}`,children:"Times marked \u201cDrinks only\u201d are after the kitchen\u2019s last food orders that day: you\u2019re welcome for drinks, but we can\u2019t serve food."}):null})(),ve&&Oe.some(e=>e.noDog)?(0,O.jsx)(b.Banner,{kind:"info",title:"Some times are full for dogs",children:`Times marked "No dog table" are full in the ${Pe.map(e=>e.name).join(' and ')}${A.settings.maxDogsPerSlot?' or already have the most dogs we can look after':''}${(0,C.closedAreasAt)(ye,A.id,U,Q??'12:00').size?', or the garden is closed for weather':''}. We\u2019d love to see you both, so please try one of the other times shown.`}):null,(0,O.jsx)(b.Muted,{children:(0,x.bookingLimitsHint)(A)})]}),(0,O.jsx)(P.MoreQuestions,{rid:A.id,r:A,value:ke,onChange:je,party:E,date:U,time:Q,today:(0,k.ymd)(R),bookings:fe,audience:"guest",showTables:!0}),(0,O.jsxs)(b.Card,{highlight:ie?void 0:S.colours.amber,children:[(0,O.jsx)(b.Field,{label:"Notes (optional)",value:se,onChangeText:le,placeholder:p.NOTES_PLACEHOLDER,multiline:!0,numberOfLines:3,testID:"book-notes"}),(0,O.jsx)(b.Toggle,{label:"I confirm the allergy information for this booking",value:ie,onChange:ae}),(0,O.jsx)(b.Muted,{children:"Table requests aren\u2019t guaranteed, but we\u2019ll do our best. Nothing here is charged now; reserved dishes are paid on the night."})]}),(0,O.jsxs)(b.Card,{children:[(0,O.jsx)(b.H2,{children:"Your details"}),(0,O.jsx)(b.Field,{label:"Name for the booking",value:J,onChangeText:K}),(0,O.jsx)(b.Field,{testID:"book-phone",label:"Mobile number (needed to book)",value:X,onChangeText:Z,onBlur:()=>ne(!0),keyboardType:"phone-pad",autoComplete:"tel",placeholder:"e.g. 07700 900123"}),Fe.ok||!oe&&!X?null:(0,O.jsx)(b.T,{size:13,colour:S.colours.amber,children:Fe.error}),(0,O.jsx)(b.Field,{testID:"book-email",label:"Email (optional)",value:ee,onChangeText:te,keyboardType:"email-address",autoCapitalize:"none",autoComplete:"email",placeholder:"you@example.com"}),Le?null:(0,O.jsx)(b.T,{size:13,colour:S.colours.amber,children:"That email doesn\u2019t look quite right. Check it, or leave it blank."}),(0,O.jsxs)(b.Muted,{children:["We\u2019ll text you a confirmation",ee.trim()?' and email it too':'',", with how to change or cancel. We only use your number for this booking."]})]}),(0,O.jsx)(i.Honeypot,{value:F,onChange:L})]})}},778,[812,813,814,805,31,815,816,128,14,809,817,818,819,820,821,822,823,824,825,826,827,828,829,830,831,832,810,25]);
2
+ __d(function(g,r,i,a,m,_e,d){"use strict";Object.defineProperty(_e,'__esModule',{value:!0}),Object.defineProperty(_e,"maxChildren",{enumerable:!0,get:function(){return u}}),_e.ChildrenCount=function({party:e,value:t,onChange:o,depositsOn:h,testID:c="children-count",guest:p}){const f=u(e);if(f<1)return null;const x=Math.min(t,f);return(0,s.jsxs)(n.default,{style:{gap:6,alignItems:'center',width:'100%'},testID:c,children:[(0,s.jsx)(l.T,{size:17,weight:"semibold",center:!0,children:p?`How many of the ${e} are children?`:`Children in the ${e}`}),(0,s.jsx)(l.Stepper,{value:x,onChange:e=>o(Math.max(0,Math.min(f,e))),min:0,max:f,label:"children",testID:`${c}-stepper`,format:e=>e?String(e):'None'}),h?(0,s.jsx)(l.Muted,{center:!0,children:"Children never pay a deposit."}):null]})},r(d[0]);var e,t=r(d[1]),n=(e=t)&&e.__esModule?e:{default:e},l=r(d[2]),s=r(d[3]);const u=e=>Math.max(0,Math.round(Number(e)||0)-1)},809,[31,128,818,25]);
3
+ __d(function(g,_r,_i,a,_m,_e,_d){"use strict";function e(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(_e,'__esModule',{value:!0}),_e.CustomerDatePicker=function({r:e,today:m,value:D,events:x,onChange:f}){const p=(0,n.ymd)(m),j=(0,r.lastBookableDay)(p,e),[C,w]=(0,t.useState)(!1),[Y,k]=(0,t.useState)((0,i.slashDay)(D)),[I,P]=(0,t.useState)(D);I!==D&&(P(D),k((0,i.slashDay)(D)));const T=new Date(m);T.setHours(12,0,0,0);const $=Array.from({length:b},(e,t)=>{const s=new Date(T);return s.setDate(T.getDate()+t),s}).filter(e=>(0,n.ymd)(e)<=j),v=t=>!!(0,o.hoursFor)(e,t),F=(0,n.parseYmd)(D),[L,M]=(0,t.useState)(()=>({y:F.getFullYear(),m:F.getMonth()})),S=(new Date(L.y,L.m,1,12).getDay()+6)%7,R=new Date(L.y,L.m+1,0).getDate(),A=[...Array.from({length:S},()=>null),...Array.from({length:R},(e,t)=>new Date(L.y,L.m,t+1,12))];for(;A.length%7;)A.push(null);const z=(0,n.parseYmd)(j),W=L.y>m.getFullYear()||L.y===m.getFullYear()&&L.m>m.getMonth(),B=L.y<z.getFullYear()||L.y===z.getFullYear()&&L.m<z.getMonth(),H=e=>M(({y:t,m:s})=>{const l=new Date(t,s+e,1);return{y:l.getFullYear(),m:l.getMonth()}}),_=Y===(0,i.slashDay)(D)?null:(0,r.typedBookDateProblem)(Y,p,e),O=e=>{f(e),w(!1)},G=(e,t)=>0===t?'Today':1===t?'Tomorrow':`${(0,n.dayShort)(e)} ${e.getDate()}`,N=$.some(e=>(0,n.ymd)(e)===D);return(0,h.jsxs)(l.default,{testID:"cust-date",style:{gap:10,alignItems:'center',width:'100%'},children:[(0,h.jsx)(l.default,{accessible:!0,accessibilityLiveRegion:"polite",testID:"cust-date-chosen",children:(0,h.jsx)(d.T,{center:!0,weight:"semibold",colour:c.colours.goldLight,children:`Booking for ${(0,n.niceDateYear)(F)}${v(F)?'':' (closed that day)'}`})}),(0,h.jsxs)(d.Row,{wrap:!0,gap:6,style:{justifyContent:'center'},children:[$.map((e,t)=>{const s=(0,n.ymd)(e),l=x.some(e=>e.date===s);return(0,h.jsx)(d.Chip,{testID:`cust-day-${s}`,label:G(e,t),sub:v(e)?l?'\u2605 event':void 0:'Closed',disabled:!v(e),selected:D===s,accessibilityLabel:`${(0,n.niceDate)(e)}${v(e)?l?', event':'':', closed'}`,onPress:()=>O(s)},s)}),N?null:(0,h.jsx)(d.Chip,{label:(0,n.niceDate)(F),sub:v(F)?void 0:'Closed',selected:!0,onPress:()=>w(!0),accessibilityLabel:`Chosen: ${(0,n.niceDateYear)(F)}. Opens the calendar`})]}),(0,h.jsxs)(l.default,{style:{width:'100%',maxWidth:360,gap:4},children:[(0,h.jsx)(d.Field,{label:"Any other date (DD/MM/YYYY)",testID:"cust-date-typed",value:Y,placeholder:"24/12/2026",keyboardType:"numbers-and-punctuation",maxLength:10,autoCapitalize:"none",autoCorrect:!1,style:{textAlign:'center'},accessibilityLabel:"Booking date, typed as day, month and four-digit year",onChangeText:t=>{const s=(0,i.slashDate)(t,Y);k(s);const l=(0,i.dayFromSlash)(s);l&&!(0,r.typedBookDateProblem)(s,p,e)&&f(l)}}),_&&Y.length>=10?(0,h.jsx)(d.T,{center:!0,size:15,colour:c.colours.amber,testID:"cust-date-problem",children:_}):null]}),(0,h.jsx)(d.Button,{kind:"secondary",label:C?'Hide calendar':'\ud83d\udcc5 Pick a date from a calendar',testID:"cust-date-cal",style:{minHeight:48},accessibilityLabel:C?'Hide the calendar':'Pick a date from a month calendar',onPress:()=>{C||M({y:F.getFullYear(),m:F.getMonth()}),w(!C)}}),C?(0,h.jsxs)(l.default,{testID:"cust-calendar",style:{borderWidth:1,borderColor:c.colours.border,borderRadius:14,padding:10,gap:6,backgroundColor:c.colours.surface2,width:'100%',maxWidth:420},children:[(0,h.jsx)(l.default,{style:{alignItems:'flex-end'},children:(0,h.jsx)(u.GoldClose,{label:"Close the calendar",testID:"cust-calendar-close",onPress:()=>w(!1),size:"sm"})}),(0,h.jsxs)(d.Row,{style:{justifyContent:'space-between',alignItems:'center'},children:[(0,h.jsx)(s.default,{accessibilityRole:"button",accessibilityLabel:"Previous month",accessibilityState:{disabled:!W},disabled:!W,onPress:()=>H(-1),style:{minWidth:48,minHeight:48,alignItems:'center',justifyContent:'center',opacity:W?1:.3},children:(0,h.jsx)(d.T,{size:22,colour:c.colours.gold,children:"\u2039"})}),(0,h.jsxs)(d.T,{center:!0,weight:"semibold",accessibilityRole:"header",children:[(0,n.monthLong)(L.m)," ",L.y]}),(0,h.jsx)(s.default,{accessibilityRole:"button",accessibilityLabel:"Next month",accessibilityState:{disabled:!B},disabled:!B,onPress:()=>H(1),style:{minWidth:48,minHeight:48,alignItems:'center',justifyContent:'center',opacity:B?1:.3},children:(0,h.jsx)(d.T,{size:22,colour:c.colours.gold,children:"\u203a"})})]}),(0,h.jsx)(l.default,{style:{flexDirection:'row'},importantForAccessibility:"no-hide-descendants",children:y.map(e=>(0,h.jsx)(d.T,{size:12,colour:c.colours.muted,center:!0,style:{flex:1},children:e},e))}),Array.from({length:A.length/7},(e,t)=>(0,h.jsx)(l.default,{style:{flexDirection:'row',gap:4},children:A.slice(7*t,7*t+7).map((e,t)=>{if(!e)return(0,h.jsx)(l.default,{style:{flex:1,height:44}},t);const o=(0,n.ymd)(e),i=o<p||o>j,r=o===D,u=!v(e);return(0,h.jsx)(s.default,{testID:`cust-cal-${o}`,accessibilityRole:"button",accessibilityLabel:`${(0,n.niceDateYear)(e)}${i?', not bookable online':u?', closed':''}`,accessibilityState:{disabled:i||u,selected:r},disabled:i||u,onPress:()=>O(o),style:{flex:1,height:44,borderRadius:10,alignItems:'center',justifyContent:'center',borderWidth:o===p?1.5:0,borderColor:c.colours.gold,backgroundColor:r?c.colours.gold:'transparent',opacity:i?.3:1},children:(0,h.jsx)(d.T,{size:15,center:!0,weight:r?'bold':'regular',colour:r?c.colours.onGold:u?c.colours.muted:c.colours.text,style:u&&!i?{textDecorationLine:'line-through'}:void 0,children:e.getDate()})},t)})},t)),(0,h.jsxs)(d.Muted,{center:!0,children:["Crossed-out days: closed. ",(0,r.bookAheadUnlimited)(e)?`You can book up to ${(0,i.slashDay)(j)}.`:`Online booking is open up to ${(0,i.slashDay)(j)}.`]})]}):null]})};var t=_r(_d[0]),s=e(_r(_d[1])),l=e(_r(_d[2])),o=_r(_d[3]),n=_r(_d[4]),i=_r(_d[5]),r=_r(_d[6]),c=_r(_d[7]),d=_r(_d[8]),u=_r(_d[9]),h=_r(_d[10]);const y=['Mon','Tue','Wed','Thu','Fri','Sat','Sun'],b=14},810,[31,264,128,833,822,834,811,825,818,835,25]);
4
+ __d(function(g,_r,i,a,_m,e,_d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"SERVER_MAX_DAYS_AHEAD",{enumerable:!0,get:function(){return n}}),e.bookAheadDays=r,Object.defineProperty(e,"bookAheadUnlimited",{enumerable:!0,get:function(){return o}}),Object.defineProperty(e,"lastBookableDay",{enumerable:!0,get:function(){return u}}),e.typedBookDateProblem=function(n,r,o){const s=(n??'').trim();if(!s)return'Type a date as DD/MM/YYYY, for example 24/12/2026.';const l=(0,t.dayFromSlash)(s);if(!l)return'That isn\u2019t a date yet. Type it as DD/MM/YYYY, for example 24/12/2026.';if(l<r)return'That date has passed. Pick today or a later date.';const c=u(r,o);if(l>c){const[t,n,r]=c.split('-');return`Online booking is open up to ${r}/${n}/${t}. For later dates, please call us.`}return null};var t=_r(_d[0]);const n=366;function r(t){const r=Number(t?.settings?.onlineBookDaysAhead);return Number.isFinite(r)&&r>=1?Math.min(Math.round(r),n):n}const o=t=>r(t)>=n,s=(t,n)=>{const r=new Date(t+'T12:00:00Z');return r.setUTCDate(r.getUTCDate()+n),r.toISOString().slice(0,10)},u=(t,n)=>s(t,r(n))},811,[834]);