PageSourceSearch

https://www.lonelyplanet.de/assets/FilterRadioGroup-BEGF8ni1.js

js lonelyplanet.de collected 2026-10-02 10:51:21 UTC 8,574 bytes, 1 lines download raw bytes

1(function(){try{var e=typeof window<`u`?window:typeof global<`u`?global:typeof globalThis<`u`?globalThis:typeof self<`u`?self:{};e.SENTRY_RELEASE={id:`512517e5b0868e14196a136fc0d98aa7a05ade09`}}catch{}})();import{i as e}from"./chunk-CtkuQOXa.js";import{t}from"./react-C7rgnzeN.js";import{t as n}from"./jsx-runtime-BuWSiX9l.js";import{d as r}from"./Link-BRWZU0BM.js";import{t as i}from"./compiler-runtime-CNkqIYfP.js";import{t as a}from"./Sprinkles-PhxluG4W.js";import{a as o,c as s,f as c,i as l,l as u,m as d,n as f,o as p,p as m,r as h,s as g,t as _}from"./dist-DEmcG7j5.js";var v=e(t(),1),y=e(n(),1),b=`rovingFocusGroup.onEntryFocus`,ee={bubbles:!1,cancelable:!0},x=`RovingFocusGroup`,[S,C,w]=f(x),[T,E]=d(x,[w]),[te,D]=T(x),O=v.forwardRef((e,t)=>(0,y.jsx)(S.Provider,{scope:e.__scopeRovingFocusGroup,children:(0,y.jsx)(S.Slot,{scope:e.__scopeRovingFocusGroup,children:(0,y.jsx)(k,{...e,ref:t})})}));O.displayName=x;var k=v.forwardRef((e,t)=>{let{__scopeRovingFocusGroup:n,orientation:r,loop:i=!1,dir:a,currentTabStopId:o,defaultCurrentTabStopId:l,onCurrentTabStopIdChange:d,onEntryFocus:f,preventScrollOnEntryFocus:h=!1,..._}=e,x=v.useRef(null),S=c(t,x),w=p(a),[T=null,E]=g({prop:o,defaultProp:l,onChange:d}),[D,O]=v.useState(!1),k=s(f),A=C(n),j=v.useRef(!1),[M,N]=v.useState(0);return v.useEffect(()=>{let e=x.current;if(e)return e.addEventListener(b,k),()=>e.removeEventListener(b,k)},[k]),(0,y.jsx)(te,{scope:n,orientation:r,dir:w,loop:i,currentTabStopId:T,onItemFocus:v.useCallback(e=>E(e),[E]),onItemShiftTab:v.useCallback(()=>O(!0),[]),onFocusableItemAdd:v.useCallback(()=>N(e=>e+1),[]),onFocusableItemRemove:v.useCallback(()=>N(e=>e-1),[]),children:(0,y.jsx)(u.div,{tabIndex:D||M===0?-1:0,"data-orientation":r,..._,ref:S,style:{outline:`none`,...e.style},onMouseDown:m(e.onMouseDown,()=>{j.current=!0}),onFocus:m(e.onFocus,e=>{let t=!j.current;if(e.target===e.currentTarget&&t&&!D){let t=new CustomEvent(b,ee);if(e.currentTarget.dispatchEvent(t),!t.defaultPrevented){let e=A().filter(e=>e.focusable);P([e.find(e=>e.active),e.find(e=>e.id===T),...e].filter(Boolean).map(e=>e.ref.current),h)}}j.current=!1}),onBlur:m(e.onBlur,()=>O(!1))})})}),A=`RovingFocusGroupItem`,j=v.forwardRef((e,t)=>{let{__scopeRovingFocusGroup:n,focusable:r=!0,active:i=!1,tabStopId:a,...o}=e,s=h(),c=a||s,l=D(A,n),d=l.currentTabStopId===c,f=C(n),{onFocusableItemAdd:p,onFocusableItemRemove:g}=l;return v.useEffect(()=>{if(r)return p(),()=>g()},[r,p,g]),(0,y.jsx)(S.ItemSlot,{scope:n,id:c,focusable:r,active:i,children:(0,y.jsx)(u.span,{tabIndex:d?0:-1,"data-orientation":l.orientation,...o,ref:t,onMouseDown:m(e.onMouseDown,e=>{r?l.onItemFocus(c):e.preventDefault()}),onFocus:m(e.onFocus,()=>l.onItemFocus(c)),onKeyDown:m(e.onKeyDown,e=>{if(e.key===`Tab`&&e.shiftKey){l.onItemShiftTab();return}if(e.target!==e.currentTarget)return;let t=ne(e,l.orientation,l.dir);if(t!==void 0){if(e.metaKey||e.ctrlKey||e.altKey||e.shiftKey)return;e.preventDefault();let n=f().filter(e=>e.focusable).map(e=>e.ref.current);if(t===`last`)n.reverse();else if(t===`prev`||t===`next`){t===`prev`&&n.reverse();let r=n.indexOf(e.currentTarget);n=l.loop?re(n,r+1):n.slice(r+1)}setTimeout(()=>P(n))}})})})});j.displayName=A;var M={ArrowLeft:`prev`,ArrowUp:`prev`,ArrowRight:`next`,ArrowDown:`next`,PageUp:`first`,Home:`first`,PageDown:`last`,End:`last`};function N(e,t){return t===`rtl`?e===`ArrowLeft`?`ArrowRight`:e===`ArrowRight`?`ArrowLeft`:e:e}function ne(e,t,n){let r=N(e.key,n);if(!(t===`vertical`&&[`ArrowLeft`,`ArrowRight`].includes(r))&&!(t===`horizontal`&&[`ArrowUp`,`ArrowDown`].includes(r)))return M[r]}function P(e,t=!1){let n=document.activeElement;for(let r of e)if(r===n||(r.focus({preventScroll:t}),document.activeElement!==n))return}function re(e,t){return e.map((n,r)=>e[(t+r)%e.length])}var ie=O,F=j;function I(e){let[t,n]=v.useState(void 0);return o(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});let t=new ResizeObserver(t=>{if(!Array.isArray(t)||!t.length)return;let r=t[0],i,a;if(`borderBoxSize`in r){let e=r.borderBoxSize,t=Array.isArray(e)?e[0]:e;i=t.inlineSize,a=t.blockSize}else i=e.offsetWidth,a=e.offsetHeight;n({width:i,height:a})});return t.observe(e,{box:`border-box`}),()=>t.unobserve(e)}else n(void 0)},[e]),t}var L=`Radio`,[ae,R]=d(L),[oe,se]=ae(L),z=v.forwardRef((e,t)=>
1{let{__scopeRadio:n,name:r,checked:i=!1,required:a,disabled:o,value:s=`on`,onCheck:l,form:d,...f}=e,[p,h]=v.useState(null),g=c(t,e=>h(e)),_=v.useRef(!1),b=p?d||!!p.closest(`form`):!0;return(0,y.jsxs)(oe,{scope:n,checked:i,disabled:o,children:[(0,y.jsx)(u.button,{type:`button`,role:`radio`,"aria-checked":i,"data-state":U(i),"data-disabled":o?``:void 0,disabled:o,value:s,...f,ref:g,onClick:m(e.onClick,e=>{i||l?.(),b&&(_.current=e.isPropagationStopped(),_.current||e.stopPropagation())})}),b&&(0,y.jsx)(H,{control:p,bubbles:!_.current,name:r,value:s,checked:i,required:a,disabled:o,form:d,style:{transform:`translateX(-100%)`}})]})});z.displayName=L;var B=`RadioIndicator`,V=v.forwardRef((e,t)=>{let{__scopeRadio:n,forceMount:r,...i}=e,a=se(B,n);return(0,y.jsx)(l,{present:r||a.checked,children:(0,y.jsx)(u.span,{"data-state":U(a.checked),"data-disabled":a.disabled?``:void 0,...i,ref:t})})});V.displayName=B;var H=e=>{let{control:t,checked:n,bubbles:r=!0,...i}=e,a=v.useRef(null),o=_(n),s=I(t);return v.useEffect(()=>{let e=a.current,t=window.HTMLInputElement.prototype,i=Object.getOwnPropertyDescriptor(t,`checked`).set;if(o!==n&&i){let t=new Event(`click`,{bubbles:r});i.call(e,n),e.dispatchEvent(t)}},[o,n,r]),(0,y.jsx)(`input`,{type:`radio`,"aria-hidden":!0,defaultChecked:n,...i,tabIndex:-1,ref:a,style:{...e.style,...s,position:`absolute`,pointerEvents:`none`,opacity:0,margin:0}})};function U(e){return e?`checked`:`unchecked`}var W=[`ArrowUp`,`ArrowDown`,`ArrowLeft`,`ArrowRight`],G=`RadioGroup`,[ce,le]=d(G,[E,R]),K=E(),q=R(),[ue,de]=ce(G),J=v.forwardRef((e,t)=>{let{__scopeRadioGroup:n,name:r,defaultValue:i,value:a,required:o=!1,disabled:s=!1,orientation:c,dir:l,loop:d=!0,onValueChange:f,...m}=e,h=K(n),_=p(l),[v,b]=g({prop:a,defaultProp:i,onChange:f});return(0,y.jsx)(ue,{scope:n,name:r,required:o,disabled:s,value:v,onValueChange:b,children:(0,y.jsx)(ie,{asChild:!0,...h,orientation:c,dir:_,loop:d,children:(0,y.jsx)(u.div,{role:`radiogroup`,"aria-required":o,"aria-orientation":c,"data-disabled":s?``:void 0,dir:_,...m,ref:t})})})});J.displayName=G;var Y=`RadioGroupItem`,X=v.forwardRef((e,t)=>{let{__scopeRadioGroup:n,disabled:r,...i}=e,a=de(Y,n),o=a.disabled||r,s=K(n),l=q(n),u=v.useRef(null),d=c(t,u),f=a.value===i.value,p=v.useRef(!1);return v.useEffect(()=>{let e=e=>{W.includes(e.key)&&(p.current=!0)},t=()=>p.current=!1;return document.addEventListener(`keydown`,e),document.addEventListener(`keyup`,t),()=>{document.removeEventListener(`keydown`,e),document.removeEventListener(`keyup`,t)}},[]),(0,y.jsx)(F,{asChild:!0,...s,focusable:!o,active:f,children:(0,y.jsx)(z,{disabled:o,required:a.required,checked:f,...l,...i,name:a.name,ref:d,onCheck:()=>a.onValueChange(i.value),onKeyDown:m(e=>{e.key===`Enter`&&e.preventDefault()}),onFocus:m(i.onFocus,()=>{p.current&&u.current?.click()})})})});X.displayName=Y;var fe=`RadioGroupIndicator`,Z=v.forwardRef((e,t)=>{let{__scopeRadioGroup:n,...r}=e;return(0,y.jsx)(V,{...q(n),...r,ref:t})});Z.displayName=fe;var pe=J,me=X,Q=Z,he=`uh8v3c1 uh8v3c0 _1pxbvgp0 tjg09fd8 _1pxbvgpk qwgf4b2w qwgf4b3n _1pxbvgp44 qwgf4b7n _1pxbvgp58 _1pxbvgp6s`,ge=`uh8v3c3 uh8v3c2 qwgf4b2l qwgf4b3b _1pxbvgp58 qwgf4bay`,_e=`uh8v3c5 uh8v3c4 tjg09f2o qwgf4b1o qwgf4b3u _1pxbvgp5c qwgf4b9d qwgf4baz`,ve=`uh8v3c7 uh8v3c6 qwgf4b2l`,ye=e(i(),1);function $(e,t){let n=(0,ye.c)(20),i,o,s,c;n[0]===e?(i=n[1],o=n[2],s=n[3],c=n[4]):({values:c,onChange:i,renderPoiIndicator:o,...s}=e,n[0]=e,n[1]=i,n[2]=o,n[3]=s,n[4]=c);let l=(0,v.useId)(),u;n[5]===Symbol.for(`react.memo_cache_sentinel`)?(u={maxWidth:`100%`,overflowX:`auto`,position:`relative`},n[5]=u):u=n[5];let d;if(n[6]!==l||n[7]!==o||n[8]!==c){let e;n[10]!==l||n[11]!==o?(e=e=>(0,y.jsxs)(me,{className:ge,id:`${l}-${e}`,value:e,children:[o?.(e),(0,y.jsx)(a.label,{className:ve,htmlFor:`${l}-${e}`,children:e}),(0,y.jsx)(Q,{className:_e})]},e),n[10]=l,n[11]=o,n[12]=e):e=n[12],d=c.map(e),n[6]=l,n[7]=o,n[8]=c,n[9]=d}else d=n[9];let f;n[13]===d?f=n[14]:(f=(0,y.jsx)(a.div,{className:he,children:d}),n[13]=d,n[14]=f);let p;return n[15]!==t||n[16]!==i||n[17]!==s||n[18]!==f?(p=(0,y.jsx)(r,{_sprinkles:u,as:pe,orientation:`horizontal`,onValueChange:i,...s,ref:t,children:f}),n[15]=t,n[16]=i,n[17]=s,n[18]=f,n[19]=p):p=n[19],p}$.displayName=`LonelyPlanetFilterRadioGroup`;var be=(0,v.forwardRef)($);export{be as t};

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