{"version":3,"file":"BottomNav.BwlSqLLu.mjs","names":["useMemo","useRef","useState"],"sources":["https:/framerusercontent.com/modules/0Hpta5EAWtpVWEWJ3id1/05RfvQ5ku1E3Ucqqh1ux/BottomNav.js"],"sourcesContent":["import{jsx as _jsx,jsxs as _jsxs}from\"react/jsx-runtime\";import{useEffect,useMemo,useRef,useState}from\"react\";import{addPropertyControls,ControlType,RenderTarget}from\"framer\";import{motion}from\"framer-motion\";// ============================================================\n// CONFIG\n// ============================================================\n// เพิ่มจากเดิมนิดเดียว\nconst NAV_WIDTH=154;// เพิ่มความสูงกรอบขาวนิดเดียว\nconst NAV_HEIGHT=50;// เพิ่มช่องว่างรอบกรอบดำจาก 4 → 5\nconst TRACK_PADDING=5;// ยังเห็นพร้อมกัน 3 ไอคอน\nconst VISIBLE_ITEMS=3;// 50 - (5 × 2) = 40\n// กรอบดำยังคง 40 × 40 เหมือนเดิม\nconst ACTIVE_SIZE=NAV_HEIGHT-TRACK_PADDING*2;const LONG_PRESS_MS=180;// ไม่ใช้งาน 10 วินาที\n// กลับไปเลื่อนให้เห็นหน้าปัจจุบัน\nconst AUTO_RETURN_MS=1e4;// ============================================================\n// PATHS\n// ============================================================\nconst SCHOOL_FEED_PATH=\"/schoolfeed\";const ROOMS_PATH=\"/rooms\";const STUDENT_HELP_PATH=\"/studenthelp\";// ============================================================\n// FIRST VISIT HINT\n// ============================================================\nconst NAV_HINT_KEY=\"popschool_bottom_nav_swipe_hint_v1\";// ============================================================\n// HELPERS\n// ============================================================\nfunction clamp(value,min,max){return Math.min(Math.max(value,min),max);}function getPageFromPath(pathname){let path=(pathname||\"/\").toLowerCase().replace(/\\/+$/,\"\");if(!path){path=\"/\";}// ========================================================\n// SCHOOL\n// ========================================================\nif(path===\"/\"){return\"school\";}// ========================================================\n// POP\n// ========================================================\nif(path===\"/popbook\"||path.endsWith(\"/popbook\")){return\"pop\";}// ========================================================\n// RANKING\n// ========================================================\nif(path===\"/ranking\"||path.endsWith(\"/ranking\")){return\"ranking\";}// ========================================================\n// SCHOOL FEED\n// ========================================================\nif(path===\"/schoolfeed\"||path.endsWith(\"/schoolfeed\")||path===\"/school-feed\"||path.endsWith(\"/school-feed\")||path===\"/feed\"||path.endsWith(\"/feed\")){return\"schoolfeed\";}// ========================================================\n// MAP\n// ========================================================\nif(path===\"/map\"||path.endsWith(\"/map\")){return\"map\";}// ========================================================\n// ROOMS\n// ========================================================\nif(path===\"/rooms\"||path.endsWith(\"/rooms\")){return\"rooms\";}// ========================================================\n// STUDENT HELP\n// ========================================================\nif(path===\"/studenthelp\"||path.endsWith(\"/studenthelp\")||path===\"/student-help\"||path.endsWith(\"/student-help\")||path===\"/popcare\"||path.endsWith(\"/popcare\")||path===\"/care\"||path.endsWith(\"/care\")){return\"studenthelp\";}return null;}// ============================================================\n// HOME ICON\n// ============================================================\nfunction HomeIcon(){return /*#__PURE__*/_jsx(\"svg\",{width:\"20\",height:\"20\",viewBox:\"0 0 24 24\",fill:\"none\",style:{display:\"block\"},children:/*#__PURE__*/_jsx(\"path\",{d:\"M3.8 10.5L12 3.8L20.2 10.5V19.1C20.2 19.76 19.66 20.3 19 20.3H14.7V14.2H9.3V20.3H5C4.34 20.3 3.8 19.76 3.8 19.1V10.5Z\",stroke:\"currentColor\",strokeWidth:\"1.9\",strokeLinejoin:\"round\"})});}// ============================================================\n// POP ICON\n// ============================================================\nfunction PopIcon(){return /*#__PURE__*/_jsxs(\"svg\",{width:\"20\",height:\"20\",viewBox:\"0 0 24 24\",fill:\"none\",style:{display:\"block\"},children:[/*#__PURE__*/_jsx(\"rect\",{x:\"4.8\",y:\"3.6\",width:\"14.4\",height:\"16.8\",rx:\"3.4\",stroke:\"currentColor\",strokeWidth:\"1.85\"}),/*#__PURE__*/_jsx(\"path\",{d:\"M9.2 8.4H14.9\",stroke:\"currentColor\",strokeWidth:\"1.7\",strokeLinecap:\"round\"}),/*#__PURE__*/_jsx(\"path\",{d:\"M9.2 12H14\",stroke:\"currentColor\",strokeWidth:\"1.7\",strokeLinecap:\"round\"}),/*#__PURE__*/_jsx(\"path\",{d:\"M9.2 15.6H12.6\",stroke:\"currentColor\",strokeWidth:\"1.7\",strokeLinecap:\"round\"})]});}// ============================================================\n// RANKING ICON\n// ============================================================\nfunction RankingIcon(){return /*#__PURE__*/_jsxs(\"svg\",{width:\"20\",height:\"20\",viewBox:\"0 0 24 24\",fill:\"none\",style:{display:\"block\"},children:[/*#__PURE__*/_jsx(\"rect\",{x:\"3.6\",y:\"12.2\",width:\"4.6\",height:\"8\",rx:\"1.2\",stroke:\"currentColor\",strokeWidth:\"1.75\"}),/*#__PURE__*/_jsx(\"rect\",{x:\"9.7\",y:\"4.7\",width:\"4.6\",height:\"15.5\",rx:\"1.2\",stroke:\"currentColor\",strokeWidth:\"1.75\"}),/*#__PURE__*/_jsx(\"rect\",{x:\"15.8\",y:\"8.8\",width:\"4.6\",height:\"11.4\",rx:\"1.2\",stroke:\"currentColor\",strokeWidth:\"1.75\"})]});}// ============================================================\n// SCHOOL FEED ICON\n// ไอคอนที่ 4\n// ============================================================\nfunction SchoolFeedIcon(){return /*#__PURE__*/_jsxs(\"svg\",{width:\"20\",height:\"20\",viewBox:\"0 0 24 24\",fill:\"none\",style:{display:\"block\"},children:[/*#__PURE__*/_jsx(\"rect\",{x:\"3.4\",y:\"3.4\",width:\"7\",height:\"7\",rx:\"2\",stroke:\"currentColor\",strokeWidth:\"1.8\"}),/*#__PURE__*/_jsx(\"rect\",{x:\"13.6\",y:\"3.4\",width:\"7\",height:\"7\",rx:\"2\",stroke:\"currentColor\",strokeWidth:\"1.8\"}),/*#__PURE__*/_jsx(\"rect\",{x:\"3.4\",y:\"13.6\",width:\"7\",height:\"7\",rx:\"2\",stroke:\"currentColor\",strokeWidth:\"1.8\"}),/*#__PURE__*/_jsx(\"rect\",{x:\"13.6\",y:\"13.6\",width:\"7\",height:\"7\",rx:\"2\",stroke:\"currentColor\",strokeWidth:\"1.8\"})]});}// ============================================================\n// MAP ICON\n// ============================================================\nfunction MapIcon(){return /*#__PURE__*/_jsxs(\"svg\",{width:\"20\",height:\"20\",viewBox:\"0 0 24 24\",fill:\"none\",style:{display:\"block\"},children:[/*#__PURE__*/_jsx(\"path\",{d:\"M12 21C12 21 19 15.7 19 9.6C19 5.95 15.87 3 12 3C8.13 3 5 5.95 5 9.6C5 15.7 12 21 12 21Z\",stroke:\"currentColor\",strokeWidth:\"1.9\",strokeLinejoin:\"round\"}),/*#__PURE__*/_jsx(\"circle\",{cx:\"12\",cy:\"9.5\",r:\"2.25\",fill:\"currentColor\"})]});}// ============================================================\n// ROOMS ICON\n// ============================================================\nfunction RoomsIcon(){return /*#__PURE__*/_jsxs(\"svg\",{width:\"20\",height:\"20\",viewBox:\"0 0 24 24\",fill:\"none\",style:{display:\"block\"},children:[/*#__PURE__*/_jsx(\"path\",{d:\"M5.1 5.1H14.4C15.67 5.1 16.7 6.13 16.7 7.4V12.1C16.7 13.37 15.67 14.4 14.4 14.4H9.2L5.1 17.3V14.4C3.83 14.4 2.8 13.37 2.8 12.1V7.4C2.8 6.13 3.83 5.1 5.1 5.1Z\",stroke:\"currentColor\",strokeWidth:\"1.75\",strokeLinejoin:\"round\"}),/*#__PURE__*/_jsx(\"path\",{d:\"M17.1 9.2H18.8C20.12 9.2 21.2 10.28 21.2 11.6V15.7C21.2 17.02 20.12 18.1 18.8 18.1V20.4L15.6 18.1H11.9\",stroke:\"currentColor\",strokeWidth:\"1.75\",strokeLinecap:\"round\",strokeLinejoin:\"round\"}),/*#__PURE__*/_jsx(\"circle\",{cx:\"7\",cy:\"9.7\",r:\"1\",fill:\"currentColor\"}),/*#__PURE__*/_jsx(\"circle\",{cx:\"10\",cy:\"9.7\",r:\"1\",fill:\"currentColor\"}),/*#__PURE__*/_jsx(\"circle\",{cx:\"13\",cy:\"9.7\",r:\"1\",fill:\"currentColor\"})]});}// ============================================================\n// STUDENT HELP ICON\n// ============================================================\nfunction StudentHelpIcon(){return /*#__PURE__*/_jsxs(\"svg\",{width:\"20\",height:\"20\",viewBox:\"0 0 24 24\",fill:\"none\",style:{display:\"block\"},children:[/*#__PURE__*/_jsx(\"path\",{d:\"M12 20.1C12 20.1 4.2 15.4 4.2 9.35C4.2 6.65 6.13 4.8 8.55 4.8C10.02 4.8 11.22 5.55 12 6.72C12.78 5.55 13.98 4.8 15.45 4.8C17.87 4.8 19.8 6.65 19.8 9.35C19.8 15.4 12 20.1 12 20.1Z\",stroke:\"currentColor\",strokeWidth:\"1.8\",strokeLinejoin:\"round\"}),/*#__PURE__*/_jsx(\"path\",{d:\"M9 11.9H11L12.1 9.5L13.45 14.1L14.45 11.9H16\",stroke:\"currentColor\",strokeWidth:\"1.55\",strokeLinecap:\"round\",strokeLinejoin:\"round\"})]});}// ============================================================\n// ICON SELECTOR\n// ============================================================\nfunction getIcon(id){if(id===\"school\"){return /*#__PURE__*/_jsx(HomeIcon,{});}if(id===\"pop\"){return /*#__PURE__*/_jsx(PopIcon,{});}if(id===\"ranking\"){return /*#__PURE__*/_jsx(RankingIcon,{});}if(id===\"schoolfeed\"){return /*#__PURE__*/_jsx(SchoolFeedIcon,{});}if(id===\"map\"){return /*#__PURE__*/_jsx(MapIcon,{});}if(id===\"rooms\"){return /*#__PURE__*/_jsx(RoomsIcon,{});}return /*#__PURE__*/_jsx(StudentHelpIcon,{});}// ============================================================\n// MAIN\n// ============================================================\nexport default function BottomNav({previewPage=\"pop\"}){// ========================================================\n// ITEMS\n//\n// ลำดับ:\n// 1 โรงเรียน\n// 2 POP\n// 3 อันดับ\n// 4 ฟีด\n// 5 แผนที่\n// 6 ห้อง\n// 7 ศูนย์ช่วยเหลือ\n// ========================================================\nconst items=useMemo(()=>[{id:\"school\",label:\"โรงเรียน\",path:\"/\"},{id:\"pop\",label:\"POP\",path:\"/popbook\"},{id:\"ranking\",label:\"อันดับ\",path:\"/ranking\"},{id:\"schoolfeed\",label:\"ฟีด\",path:SCHOOL_FEED_PATH},{id:\"map\",label:\"แผนที่\",path:\"/map\"},{id:\"rooms\",label:\"ห้อง\",path:ROOMS_PATH},{id:\"studenthelp\",label:\"ศูนย์ช่วยเหลือ\",path:STUDENT_HELP_PATH}],[]);// ========================================================\n// INDEX HELPERS\n// ========================================================\nfunction getIndexFromPage(page){const index=items.findIndex(item=>item.id===page);return index>=0?index:0;}function readCurrentIndex(){if(typeof window===\"undefined\"){return getIndexFromPage(previewPage);}const page=getPageFromPath(window.location.pathname);if(!page){return getIndexFromPage(previewPage);}return getIndexFromPage(page);}// ========================================================\n// INITIAL\n// ========================================================\nconst initialIndexRef=useRef(null);if(initialIndexRef.current===null){initialIndexRef.current=readCurrentIndex();}const initialIndex=initialIndexRef.current;// ========================================================\n// REFS\n// ========================================================\nconst navRef=useRef(null);const scrollRef=useRef(null);const linkRefs=useRef([]);const longPressTimer=useRef(null);const autoReturnTimer=useRef(null);const hintTimers=useRef([]);const draggingRef=useRef(false);const suppressClickRef=useRef(false);const nativeSwipeRef=useRef(false);const pointerStartX=useRef(0);const latestPointerX=useRef(0);const realIndexRef=useRef(initialIndex);const pendingIndexRef=useRef(null);const routeInitializedRef=useRef(false);// ========================================================\n// STATE\n// ========================================================\nconst[visualIndex,setVisualIndex]=useState(initialIndex);const[dragging,setDragging]=useState(false);const[dragX,setDragX]=useState(0);const[viewportTrackWidth,setViewportTrackWidth]=useState(NAV_WIDTH-TRACK_PADDING*2);const[hintVisible,setHintVisible]=useState(false);// ========================================================\n// CALCULATIONS\n//\n// 154 - padding 10 = 144\n// 144 / 3 = 48px ต่อช่อง\n//\n// active = 40px\n//\n// ระยะเพิ่มขึ้นจากเดิมนิดเดียว\n// ========================================================\nconst slotWidth=viewportTrackWidth/VISIBLE_ITEMS;const totalTrackWidth=slotWidth*items.length;const contentWidth=totalTrackWidth+TRACK_PADDING*2;function getIndicatorX(index){return index*slotWidth+(slotWidth-ACTIVE_SIZE)/2;}const targetX=getIndicatorX(visualIndex);const pillX=dragging?dragX:targetX;const activeItem=items[clamp(visualIndex,0,items.length-1)];// ========================================================\n// MEASURE\n// ========================================================\nuseEffect(()=>{const nav=navRef.current;if(!nav){return;}function measure(){const element=navRef.current;if(!element){return;}const rect=element.getBoundingClientRect();setViewportTrackWidth(Math.max(1,rect.width-TRACK_PADDING*2));}measure();if(typeof ResizeObserver===\"undefined\"){window.addEventListener(\"resize\",measure);return()=>{window.removeEventListener(\"resize\",measure);};}const observer=new ResizeObserver(measure);observer.observe(nav);return()=>{observer.disconnect();};},[]);// ========================================================\n// SCROLL INDEX INTO VIEW\n// ========================================================\nfunction scrollIndexIntoView(index,behavior=\"smooth\"){const scroller=scrollRef.current;if(!scroller){return;}const itemCenter=TRACK_PADDING+index*slotWidth+slotWidth/2;const wantedLeft=itemCenter-scroller.clientWidth/2;const maxLeft=Math.max(0,scroller.scrollWidth-scroller.clientWidth);const finalLeft=clamp(wantedLeft,0,maxLeft);try{scroller.scrollTo({left:finalLeft,behavior});}catch{scroller.scrollLeft=finalLeft;}}// ========================================================\n// AUTO RETURN\n// ========================================================\nfunction clearAutoReturn(){if(autoReturnTimer.current!==null){window.clearTimeout(autoReturnTimer.current);autoReturnTimer.current=null;}}function scheduleAutoReturn(){clearAutoReturn();const isCanvas=RenderTarget.current()===RenderTarget.canvas;if(isCanvas||typeof window===\"undefined\"){return;}autoReturnTimer.current=window.setTimeout(()=>{if(draggingRef.current){scheduleAutoReturn();return;}scrollIndexIntoView(realIndexRef.current,\"smooth\");autoReturnTimer.current=null;},AUTO_RETURN_MS);}// ========================================================\n// ROUTE SYNC\n// ========================================================\nuseEffect(()=>{const isCanvas=RenderTarget.current()===RenderTarget.canvas;if(isCanvas){const index=getIndexFromPage(previewPage);realIndexRef.current=index;setVisualIndex(index);window.setTimeout(()=>{scrollIndexIntoView(index,\"auto\");},0);return;}function syncRoute(){if(draggingRef.current){return;}try{const page=getPageFromPath(window.location.pathname);if(!page){return;}const index=getIndexFromPage(page);if(pendingIndexRef.current!==null&&index!==pendingIndexRef.current){return;}if(pendingIndexRef.current===index){pendingIndexRef.current=null;}if(!routeInitializedRef.current){routeInitializedRef.current=true;realIndexRef.current=index;setVisualIndex(index);window.setTimeout(()=>{scrollIndexIntoView(index,\"auto\");},0);return;}if(index===realIndexRef.current){return;}realIndexRef.current=index;setVisualIndex(index);clearAutoReturn();scrollIndexIntoView(index,\"smooth\");}catch{}}syncRoute();window.addEventListener(\"popstate\",syncRoute);const timer=window.setInterval(syncRoute,350);return()=>{window.removeEventListener(\"popstate\",syncRoute);window.clearInterval(timer);};},[previewPage,items,slotWidth]);// ========================================================\n// FIRST VISIT HINT\n// ========================================================\nuseEffect(()=>{const isCanvas=RenderTarget.current()===RenderTarget.canvas;if(isCanvas||typeof window===\"undefined\"){return;}let alreadySeen=false;try{alreadySeen=localStorage.getItem(NAV_HINT_KEY)===\"1\";}catch{}if(alreadySeen){return;}try{localStorage.setItem(NAV_HINT_KEY,\"1\");}catch{}setHintVisible(true);const demoTimer=window.setTimeout(()=>{const scroller=scrollRef.current;if(!scroller){return;}const current=scroller.scrollLeft;const maxLeft=Math.max(0,scroller.scrollWidth-scroller.clientWidth);let demoLeft=current+slotWidth*.85;if(demoLeft>maxLeft){demoLeft=Math.max(0,current-slotWidth*.85);}try{scroller.scrollTo({left:demoLeft,behavior:\"smooth\"});}catch{scroller.scrollLeft=demoLeft;}},650);const returnTimer=window.setTimeout(()=>{scrollIndexIntoView(realIndexRef.current,\"smooth\");},1500);const hideTimer=window.setTimeout(()=>{setHintVisible(false);},3400);hintTimers.current=[demoTimer,returnTimer,hideTimer];return()=>{hintTimers.current.forEach(timer=>window.clearTimeout(timer));hintTimers.current=[];};},[slotWidth]);// ========================================================\n// CLEANUP\n// ========================================================\nuseEffect(()=>{return()=>{if(longPressTimer.current!==null){window.clearTimeout(longPressTimer.current);}clearAutoReturn();hintTimers.current.forEach(timer=>window.clearTimeout(timer));};},[]);// ========================================================\n// CANCEL LONG PRESS\n// ========================================================\nfunction cancelLongPress(){if(longPressTimer.current!==null){window.clearTimeout(longPressTimer.current);longPressTimer.current=null;}}// ========================================================\n// AUTO SCROLL WHILE DRAGGING\n// ========================================================\nfunction autoScrollDuringDrag(clientX){const nav=navRef.current;const scroller=scrollRef.current;if(!nav||!scroller){return;}const rect=nav.getBoundingClientRect();const edgeSize=28;const maxScroll=Math.max(0,scroller.scrollWidth-scroller.clientWidth);if(clientX>rect.right-edgeSize){scroller.scrollLeft=clamp(scroller.scrollLeft+8,0,maxScroll);}else if(clientX<rect.left+edgeSize){scroller.scrollLeft=clamp(scroller.scrollLeft-8,0,maxScroll);}}// ========================================================\n// ACTIVE DRAG POSITION\n// ========================================================\nfunction getDragPosition(clientX){const nav=navRef.current;const scroller=scrollRef.current;if(!nav||!scroller){return{x:getIndicatorX(visualIndex),index:visualIndex};}const rect=nav.getBoundingClientRect();const contentX=clientX-rect.left+scroller.scrollLeft-TRACK_PADDING;const wantedX=contentX-ACTIVE_SIZE/2;const maxX=Math.max(0,totalTrackWidth-ACTIVE_SIZE);const x=clamp(wantedX,0,maxX);const indicatorCenter=x+ACTIVE_SIZE/2;const index=clamp(Math.floor(indicatorCenter/slotWidth),0,items.length-1);return{x,index};}function updateDrag(clientX){autoScrollDuringDrag(clientX);const result=getDragPosition(clientX);setDragX(result.x);setVisualIndex(result.index);return result;}// ========================================================\n// POINTER DOWN\n// ========================================================\nfunction handlePointerDown(event){if(event.pointerType===\"mouse\"&&event.button!==0){return;}clearAutoReturn();pointerStartX.current=event.clientX;latestPointerX.current=event.clientX;nativeSwipeRef.current=false;cancelLongPress();longPressTimer.current=window.setTimeout(()=>{draggingRef.current=true;suppressClickRef.current=true;setDragging(true);updateDrag(latestPointerX.current);try{event.currentTarget.setPointerCapture(event.pointerId);}catch{}try{if(navigator.vibrate){navigator.vibrate(8);}}catch{}},LONG_PRESS_MS);}// ========================================================\n// POINTER MOVE\n// ========================================================\nfunction handlePointerMove(event){latestPointerX.current=event.clientX;const distance=Math.abs(event.clientX-pointerStartX.current);// ====================================================\n// FREE SWIPE\n// ====================================================\nif(!draggingRef.current){if(distance>8){nativeSwipeRef.current=true;cancelLongPress();clearAutoReturn();setHintVisible(false);}return;}// ====================================================\n// LONG PRESS DRAG\n// ====================================================\nevent.preventDefault();clearAutoReturn();updateDrag(event.clientX);}// ========================================================\n// NAVIGATE\n// ========================================================\nfunction navigateTo(index){const item=items[index];if(!item){return;}pendingIndexRef.current=index;setVisualIndex(index);scrollIndexIntoView(index,\"smooth\");const link=linkRefs.current[index];if(link){link.click();}}// ========================================================\n// POINTER UP\n// ========================================================\nfunction handlePointerUp(event){cancelLongPress();// ====================================================\n// FREE SWIPE END\n// ====================================================\nif(!draggingRef.current){if(nativeSwipeRef.current){suppressClickRef.current=true;scheduleAutoReturn();window.setTimeout(()=>{suppressClickRef.current=false;nativeSwipeRef.current=false;},180);}else{scheduleAutoReturn();}return;}// ====================================================\n// LONG PRESS DRAG END\n// ====================================================\nevent.preventDefault();event.stopPropagation();const result=updateDrag(event.clientX);const index=result.index;draggingRef.current=false;setDragging(false);suppressClickRef.current=true;setVisualIndex(index);setDragX(getIndicatorX(index));try{event.currentTarget.releasePointerCapture(event.pointerId);}catch{}// ====================================================\n// CURRENT PAGE\n// ====================================================\nif(index===realIndexRef.current){scrollIndexIntoView(index,\"smooth\");scheduleAutoReturn();window.setTimeout(()=>{suppressClickRef.current=false;},180);return;}// ====================================================\n// NEW PAGE\n// ====================================================\nwindow.setTimeout(()=>{suppressClickRef.current=false;navigateTo(index);},100);}// ========================================================\n// POINTER CANCEL\n// ========================================================\nfunction handlePointerCancel(){cancelLongPress();draggingRef.current=false;suppressClickRef.current=false;nativeSwipeRef.current=false;setDragging(false);setVisualIndex(realIndexRef.current);setDragX(getIndicatorX(realIndexRef.current));scheduleAutoReturn();}// ========================================================\n// NORMAL CLICK\n// ========================================================\nfunction handleClick(event,index){if(suppressClickRef.current||nativeSwipeRef.current){event.preventDefault();event.stopPropagation();return;}setHintVisible(false);clearAutoReturn();// ====================================================\n// CURRENT PAGE\n// ====================================================\nif(index===realIndexRef.current){event.preventDefault();setVisualIndex(index);scrollIndexIntoView(index,\"smooth\");scheduleAutoReturn();return;}// ====================================================\n// NEW PAGE\n// ====================================================\npendingIndexRef.current=index;setVisualIndex(index);scrollIndexIntoView(index,\"smooth\");}// ========================================================\n// USER SCROLL\n// ========================================================\nfunction handleScroll(){if(nativeSwipeRef.current){setHintVisible(false);}}// ========================================================\n// WHEEL / TRACKPAD\n// ========================================================\nfunction handleWheel(event){const scroller=scrollRef.current;if(!scroller){return;}clearAutoReturn();setHintVisible(false);// trackpad แนวนอน\nif(Math.abs(event.deltaX)>=Math.abs(event.deltaY)){scheduleAutoReturn();return;}// mouse wheel แนวตั้ง\n// แปลงเป็นแนวนอน\nif(Math.abs(event.deltaY)>0){event.preventDefault();scroller.scrollLeft+=event.deltaY;}scheduleAutoReturn();}// ========================================================\n// NAV INTERACTION\n// ========================================================\nfunction handleNavPointerEnter(){clearAutoReturn();}function handleNavPointerLeave(){if(!draggingRef.current){scheduleAutoReturn();}}// ========================================================\n// UI\n// ========================================================\nreturn /*#__PURE__*/_jsxs(\"div\",{style:{width:\"100%\",height:78,position:\"relative\",display:\"flex\",alignItems:\"flex-start\",justifyContent:\"flex-end\",boxSizing:\"border-box\",padding:\"max(10px, env(safe-area-inset-top)) 12px 0 12px\",pointerEvents:\"none\",fontFamily:'\"Noto Sans Thai\",\"LINE Seed Sans TH\",\"IBM Plex Sans Thai\",-apple-system,BlinkMacSystemFont,sans-serif'},children:[hintVisible&&/*#__PURE__*/_jsx(motion.div,{initial:{opacity:0,y:-4,scale:.94},animate:{opacity:1,y:0,scale:1},transition:{duration:.25,ease:[.22,1,.36,1]},style:{position:\"absolute\",top:63,right:18,zIndex:30,padding:\"6px 9px\",borderRadius:999,background:\"#111111\",color:\"#FFFFFF\",fontSize:9,lineHeight:1,fontWeight:800,letterSpacing:\"-0.01em\",// ไม่มีเงา\nboxShadow:\"none\",filter:\"none\",pointerEvents:\"none\",whiteSpace:\"nowrap\"},children:\"เลื่อนซ้าย–ขวาได้ ↔\"}),/*#__PURE__*/_jsx(motion.div,{ref:navRef,onPointerEnter:handleNavPointerEnter,onPointerLeave:handleNavPointerLeave,initial:{opacity:0,y:-5,scale:.98},animate:{opacity:1,y:0,scale:1},transition:{duration:.28,ease:[.22,1,.36,1]},style:{position:\"relative\",width:NAV_WIDTH,height:NAV_HEIGHT,flexShrink:0,overflow:\"hidden\",borderRadius:18,boxSizing:\"border-box\",pointerEvents:\"auto\",userSelect:\"none\",WebkitUserSelect:\"none\",// =================================================\n// กรอบขาว\n// =================================================\nbackground:\"rgba(250,250,249,.96)\",border:\"1px solid rgba(235,235,232,.96)\",// =================================================\n// ไม่มีเงาเลย\n// =================================================\nboxShadow:\"none\",filter:\"none\",// ยังคง blur เบา ๆ ของกระจก\n// แต่ไม่ใช่เงา\nbackdropFilter:\"blur(20px)\",WebkitBackdropFilter:\"blur(20px)\"},children:/*#__PURE__*/_jsx(\"div\",{ref:scrollRef,className:\"popschool-bottom-nav-scroll\",onScroll:handleScroll,onWheel:handleWheel,style:{position:\"absolute\",inset:0,zIndex:2,overflowX:\"auto\",overflowY:\"hidden\",WebkitOverflowScrolling:\"touch\",overscrollBehaviorX:\"contain\",touchAction:dragging?\"none\":\"pan-x\"},children:/*#__PURE__*/_jsxs(\"div\",{style:{position:\"relative\",width:contentWidth,height:NAV_HEIGHT,minWidth:contentWidth,boxSizing:\"border-box\"},children:[/*#__PURE__*/_jsx(\"div\",{style:{position:\"absolute\",top:TRACK_PADDING,left:TRACK_PADDING,width:totalTrackWidth,height:NAV_HEIGHT-TRACK_PADDING*2,zIndex:1,display:\"grid\",gridTemplateColumns:`repeat(${items.length}, ${slotWidth}px)`,columnGap:0,gap:0,pointerEvents:\"none\"},children:items.map(item=>/*#__PURE__*/_jsx(\"div\",{style:{width:slotWidth,height:\"100%\",margin:0,padding:0,display:\"flex\",alignItems:\"center\",justifyContent:\"center\",color:\"rgba(17,17,17,.38)\"},children:getIcon(item.id)},item.id))}),/*#__PURE__*/_jsx(\"div\",{style:{position:\"absolute\",top:TRACK_PADDING,left:TRACK_PADDING,width:totalTrackWidth,height:ACTIVE_SIZE,zIndex:2,pointerEvents:\"none\"},children:/*#__PURE__*/_jsx(motion.div,{initial:false,animate:{x:pillX,scale:dragging?1.03:1},transition:dragging?{x:{duration:.035},scale:{type:\"spring\",stiffness:500,damping:30}}:{type:\"spring\",stiffness:500,damping:38,mass:.72},style:{position:\"absolute\",top:0,left:0,width:ACTIVE_SIZE,height:ACTIVE_SIZE,borderRadius:14,background:\"#111111\",// =============================\n// ไม่มีเงาพื้นหลังดำ\n// =============================\nboxShadow:\"none\",filter:\"none\",border:\"none\",outline:\"none\",display:\"flex\",alignItems:\"center\",justifyContent:\"center\",willChange:\"transform\"},children:/*#__PURE__*/_jsx(motion.div,{initial:{opacity:0,scale:.9},animate:{opacity:1,scale:dragging?1.06:1},transition:{duration:.1},style:{color:\"#FFFFFF\",display:\"flex\",alignItems:\"center\",justifyContent:\"center\",boxShadow:\"none\",filter:\"none\"},children:getIcon(activeItem.id)},activeItem.id)})}),/*#__PURE__*/_jsx(\"div\",{style:{position:\"absolute\",top:TRACK_PADDING,left:TRACK_PADDING,width:totalTrackWidth,height:ACTIVE_SIZE,zIndex:5,display:\"grid\",gridTemplateColumns:`repeat(${items.length}, ${slotWidth}px)`,columnGap:0,gap:0},children:items.map((item,index)=>/*#__PURE__*/_jsx(\"a\",{ref:element=>{linkRefs.current[index]=element;},href:item.path,\"aria-label\":item.label,title:item.label,draggable:false,onDragStart:event=>{event.preventDefault();},onPointerDown:handlePointerDown,onPointerMove:handlePointerMove,onPointerUp:handlePointerUp,onPointerCancel:handlePointerCancel,onClick:event=>handleClick(event,index),style:{display:\"block\",width:slotWidth,height:\"100%\",margin:0,padding:0,borderRadius:14,background:\"transparent\",textDecoration:\"none\",outline:\"none\",boxShadow:\"none\",cursor:dragging?\"grabbing\":\"pointer\",WebkitTapHighlightColor:\"transparent\",userSelect:\"none\",WebkitUserSelect:\"none\",touchAction:dragging?\"none\":\"pan-x\"}},item.id))})]})})}),/*#__PURE__*/_jsx(\"style\",{children:`\n                .popschool-bottom-nav-scroll {\n                    scrollbar-width: none;\n                    -ms-overflow-style: none;\n                    box-shadow: none !important;\n                }\n\n                .popschool-bottom-nav-scroll::-webkit-scrollbar {\n                    display: none;\n                    width: 0;\n                    height: 0;\n                }\n\n                .popschool-bottom-nav-scroll * {\n                    -webkit-tap-highlight-color: transparent;\n                }\n            `})]});}// ============================================================\n// FRAMER PROPERTY CONTROLS\n// ============================================================\naddPropertyControls(BottomNav,{previewPage:{type:ControlType.Enum,title:\"หน้าปัจจุบัน\",options:[\"school\",\"pop\",\"ranking\",\"schoolfeed\",\"map\",\"rooms\",\"studenthelp\"],optionTitles:[\"โรงเรียน\",\"POP\",\"อันดับ\",\"ฟีด\",\"แผนที่\",\"ห้อง\",\"ศูนย์ช่วยเหลือ\"],defaultValue:\"pop\"}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"BottomNav\",\"slots\":[],\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./BottomNav.map"],"mappings":"gRAoBA,SAAS,EAAM,EAAM,EAAI,EAAI,CAAC,OAAO,KAAK,IAAI,KAAK,IAAI,EAAM,CAAG,EAAE,CAAG,CAAE,CAAC,SAAS,EAAgB,EAAS,CAAC,IAAI,GAAM,GAAU,IAAA,CAAK,YAAY,CAAC,CAAC,QAAQ,OAAO,EAAE,EAqByD,MArBvD,CAAU,IAAK,IAGjL,IAAO,IAAW,SAGlB,IAAO,YAAY,EAAK,SAAS,UAAU,EAAS,MAGpD,IAAO,YAAY,EAAK,SAAS,UAAU,EAAS,UAGpD,IAAO,eAAe,EAAK,SAAS,aAAa,GAAG,IAAO,gBAAgB,EAAK,SAAS,cAAc,GAAG,IAAO,SAAS,EAAK,SAAS,OAAO,EAAS,aAGxJ,IAAO,QAAQ,EAAK,SAAS,MAAM,EAA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