1const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/JobHuntingWidgets-cnBaxjLB.js","assets/animation-CddyXVCz.js","assets/react-vendor-CbN3pvl2.js","assets/index-CGKNpi9E.js","assets/supabase-iKSPld20.js","assets/docgen-Bp8WKBAE.js","assets/query-DPqpbKNH.js","assets/index-D2PKCkk9.css","assets/BuildingProfileWidgets-D17CO5JF.js","assets/ManagingPortfolioWidgets-B88vVRHB.js","assets/BrowsingWidgets-NBt-UUt7.js"])))=>i.map(i=>d[i]); 2import{r as p,j as e,R as m}from"./animation-CddyXVCz.js";import{s as y,n as z,u as R,B as j,_ as x,a as M}from"./index-CGKNpi9E.js";async function k(s){try{if(!y)return null;const{data:t,error:r}=await y.rpc("get_or_create_user_mode",{p_user_id:s}).single();return r?(console.error("Error getting user mode:",r),null):t}catch(t){return console.error("Error in getUserMode:",t),null}}async function N(s,t){try{if(!y)return null;const{data:r,error:a}=await y.from("user_modes").update({...t,last_changed:new Date().toISOString()}).eq("user_id",s).select().single();return a?(console.error("Error updating user mode:",a),null):r}catch(r){return console.error("Error in updateUserMode:",r),null}}async function O(s,t){return N(s,{current_mode:t})}async function T(s,t){try{const r=await k(s);if(!r)return null;const a=r.dismissed_suggestions||[];return a.includes(t)?r:N(s,{dismissed_suggestions:[...a,t]})}catch(r){return console.error("Error in dismissSuggestion:",r),null}}async function L(s,t){return N(s,{suggestions_enabled:t})}async function W(s){var t,r,a;try{const u=await k(s);if(!u||!u.suggestions_enabled)return null;const c=new Date;if(c.setDate(c.getDate()-7),!y)return null;const{count:d}=await y.from("job_search_cache").select("*",{count:"exact",head:!0}).eq("user_id",s).gte("created_at",c.toISOString());if(d&&d>=5){const i="job_hunting_high_activity";if(!((t=u.dismissed_suggestions)!=null&&t.includes(i)))return{suggested_mode:"job_hunting",reason:`You've searched for jobs ${d} times this week`,confidence:Math.min(d/10,1),trigger:i}}const{data:h}=await y.from("profiles").select("profile_data").eq("id",s).single();if(h&&h.profile_data){const i=z(h.profile_data);let o=0;if(i.fullName&&(o+=20),i.headline&&(o+=20),i.summary&&(o+=20),i.experience&&i.experience.length>0&&(o+=20),i.skills&&i.skills.length>0&&(o+=20),o<70){const g="building_profile_incomplete";if(!((r=u.dismissed_suggestions)!=null&&r.includes(g)))return{suggested_mode:"building_profile",reason:`Your profile is ${o}% complete`,confidence:(70-o)/70,trigger:g}}}try{const{data:i,error:o}=await y.from("public_portfolios").select("is_public").eq("user_id",s).maybeSingle();if(o)return console.warn("[suggestMode] Portfolio query error (non-blocking):",o),null;if(i!=null&&i.is_public){const{data:g,error:_}=await y.from("public_portfolios").select("view_count").eq("user_id",s).maybeSingle();if(_)return console.warn("[suggestMode] Portfolio view count error (non-blocking):",_),null;const l=(g==null?void 0:g.view_count)||0;if(l>=10){const b="managing_portfolio_active";if(!((a=u.dismissed_suggestions)!=null&&a.includes(b)))return{suggested_mode:"managing_portfolio",reason:`Your portfolio has ${l} views`,confidence:Math.min(l/50,1),trigger:b}}}}catch(i){console.warn("[suggestMode] Portfolio check failed (non-blocking):",i)}return null}catch(u){return console.error("Error in suggestMode:",u),null}}function S(){var E;const{state:s}=R(),t=(E=s.session)==null?void 0:E.user,[r,a]=p.useState(null),[u,c]=p.useState(!0),[d,h]=p.useState(null),[i,o]=p.useState(null),g=p.useCallback(async()=>{if(t!=null&&t.id)try{c(!0),h(null);const n=await k(t.id);if(a(n),n!=null&&n.suggestions_enabled){const f=await W(t.id);o(f)}}catch(n){h(n instanceof Error?n.message:"Failed to load mode"),console.error("Error loading mode:",n)}finally{c(!1)}},[t==null?void 0:t.id]);p.useEffect(()=>{if(!(t!=null&&t.id)){const n=new Date;a({id:"guest",user_id:"guest",current_mode:"browsing",suggestions_enabled:!1,dismissed_suggestions:[],last_changed:n,created_at:n,updated_at:n}),c(!1);return}g()},[t==null?void 0:t.id,g]);const _=p.useCallback(async n=>{if(t!=null&&t.id)try{c(!0),h(null);const f=await O(t.id,n);if(f)a(f),o(null);else throw new Error("Failed to update mode")}catch(f){h(f instanceof Error?f.message:"Failed to change mode"),console.error("Error changing mode:",f)}finally{c(!1)}},[t==null?void 0:t.id]),l=p.useCallback(async()=>
2{if(!(!(t!=null&&t.id)||!i))try{const n=await T(t.id,i.trigger);n&&(a(n),o(null))}catch(n){console.error("Error dismissing suggestion:",n)}},[t==null?void 0:t.id,i]),b=p.useCallback(async n=>{if(t!=null&&t.id)try{const f=await L(t.id,n);f&&(a(f),n||o(null))}catch(f){console.error("Error toggling suggestions:",f)}},[t==null?void 0:t.id]),P=p.useCallback(async()=>{await g()},[g]),C=p.useCallback(async()=>{if(!(!(t!=null&&t.id)||!(r!=null&&r.suggestions_enabled)))try{const n=await W(t.id);o(n)}catch(n){console.error("Error checking suggestions:",n)}},[t==null?void 0:t.id,r==null?void 0:r.suggestions_enabled]);return{mode:r,isLoading:u,error:d,suggestion:i,changeMode:_,dismissCurrentSuggestion:l,enableSuggestions:b,refreshMode:P,checkForSuggestions:C}}const I={job_hunting:[{id:"applications-stats",type:"stat",modes:["job_hunting"],priority:1,title:"Applications",description:"Track your active applications"},{id:"recent-applications",type:"feed",modes:["job_hunting"],priority:2,title:"Recent Activity",description:"Your recent application activity"},{id:"saved-jobs",type:"stat",modes:["job_hunting"],priority:3,title:"Saved Jobs",description:"Jobs you want to review"},{id:"recent-searches",type:"feed",modes:["job_hunting"],priority:4,title:"Recent Searches",description:"Your job search history"},{id:"quick-actions",type:"action",modes:["job_hunting"],priority:5,title:"Quick Actions",description:"Common job hunting tasks"}],building_profile:[{id:"profile-completeness",type:"stat",modes:["building_profile"],priority:1,title:"Profile Completeness",description:"Your progress"},{id:"next-steps",type:"checklist",modes:["building_profile"],priority:2,title:"Next Steps",description:"Complete your profile"},{id:"profile-benefits",type:"suggestion",modes:["building_profile"],priority:3,title:"Why Complete Your Profile?",description:"Benefits of a complete profile"}],managing_portfolio:[{id:"portfolio-analytics",type:"stat",modes:["managing_portfolio"],priority:1,title:"Analytics",description:"Portfolio performance"},{id:"portfolio-site",type:"stat",modes:["managing_portfolio"],priority:2,title:"Your Portfolio Site",description:"Site status and links"},{id:"recent-updates",type:"feed",modes:["managing_portfolio"],priority:3,title:"Recent Updates",description:"Your latest changes"},{id:"portfolio-actions",type:"action",modes:["managing_portfolio"],priority:4,title:"Customize",description:"Portfolio customization"}],browsing:[{id:"what-to-do",type:"action",modes:["browsing"],priority:1,title:"What would you like to do today?",description:"Choose your focus"},{id:"quick-stats",type:"stat",modes:["browsing"],priority:2,title:"Quick Stats",description:"Your activity overview"},{id:"suggestions",type:"suggestion",modes:["browsing"],priority:3,title:"Personalized Suggestions",description:"Based on your activity"}]};function $(s){return I[s].sort((t,r)=>t.priority-r.priority)}const v=({children:s,className:t="",onClick:r})=>e.jsxs("div",{onClick:r,className:` 3 relative backdrop-blur-md 4 bg-white/50 dark:bg-slate-800/50 5 border border-[var(--border-default)]/50 6 rounded-xl 7 p-6 8 shadow-sm hover:shadow-lg hover:-translate-y-0.5 9 transition-all duration-base 10 min-w-0 11 ${r?"cursor-pointer hover:border-[var(--color-accent)]/30":""} 12 ${t} 13 `,children:[e.jsx("div",{className:"absolute inset-0 rounded-xl bg-gradient-to-br from-white/40 to-transparent dark:from-white/5 dark:to-transparent pointer-events-none"}),e.jsx("div",{className:"relative z-10 min-w-0",children:s})]}),ce=({title:s,subtitle:t,icon:r,action:a})=>e.jsxs("div",{className:"flex items-start justify-between mb-4",children:[e.jsxs("div",{className:"flex items-center gap-3",children:[r&&e.jsx("div",{className:"text-2xl",children:r}),e.jsxs("div",{children:[e.jsx("h3",{className:"text-lg font-semibold text-gray-900 dark:text-white",children:s}),t&&e.jsx("p",{className:"text-sm text-gray-600 dark:text-gray-400 mt-1",children:t})]})]}),a&&e.jsx("div",{children:a})]}),ge=({icon:s="ð",title:t,description:r,action:a})=>e.jsxs("div",{className:"flex flex-col items-center justify-center py-8 text-center",children:[e.jsx("div",{className:"text-5xl mb-3",children:s}),e.jsx("h4",{className:"text-base font-medium text-gray-900 dark:text-white mb-1",children:t}),e.jsx("p",{className:"text-sm text-gray-600 dark:text-gray-400 mb-4 max-w-sm",children:r}),a]}),A=({className:s=""})=>e.jsxs("div",{className:`space-y-4 animate-pulse ${s}`,children:[e.jsxs("div",{className:"flex items-center gap-3 mb-6",children:[e.jsx("div",{className:"w-10 h-10 rounded-lg bg-gray-200 dark:bg-slate-700"}),e.jsxs("div",{className:"space-y-2",children:[e.jsx("div",{className:"w-32 h-4 rounded bg-gray-200 dark:bg-slate-700"}),e.jsx("div",{className:"w-24 h-3 rounded bg-gray-100 dark:bg-slate-800"})]})]}),e.jsxs("div",{className:"space-y-3",children:[e.jsx("div",{className:"w-full h-4 rounded bg-gray-100 dark:bg-slate-800"}),e.jsx("div",{className:"w-full h-4 rounded bg-gray-100 dark:bg-slate-800"}),e.jsx("div",{className:"w-3/4 h-4 rounded bg-gray-100 dark:bg-slate-800"})]})]}),ue=({message:s,onRetry:t})=>e.jsxs("div",{className:"flex flex-col items-center justify-center py-8 text-center",children:[e.jsx("div",{className:"text-4xl mb-3",children:"â ï¸"}),e.jsx("h4",{className:"text-base font-medium text-gray-900 dark:text-white mb-1",children:"Something went wrong"}),e.jsx("p",{className:"text-sm text-gray-600 dark:text-gray-400 mb-4",children:s}),t&&e.jsx(j,{onClick:t,variant:"primary",size:"md",className:"h-auto",children:"Try Again"})]}
13),w={job_hunting:{id:"job_hunting",icon:"ð¯",label:"Job Hunting",description:"Find and apply to jobs",color:"#5A67D8"},building_profile:{id:"building_profile",icon:"ð",label:"Building Profile",description:"Set up your career story",color:"#10B981"},managing_portfolio:{id:"managing_portfolio",icon:"ð",label:"Managing Portfolio",description:"Update your website",color:"#8B5CF6"},browsing:{id:"browsing",icon:"ð",label:"Just Browsing",description:"Explore at your pace",color:"#6B7280"}},B=()=>{const{suggestion:s,changeMode:t,dismissCurrentSuggestion:r}=S();if(!s)return null;const a=w[s.suggested_mode];return e.jsx("div",{className:"bg-gradient-to-r from-blue-50 to-blue-600 dark:from-blue-900/20 dark:to-blue-600/20 border border-blue-200 dark:border-blue-800 rounded-xl p-4 mb-6 animate-fadeInDown",children:e.jsxs("div",{className:"flex items-start gap-4",children:[e.jsx("span",{className:"text-4xl flex-shrink-0",children:a.icon}),e.jsxs("div",{className:"flex-1",children:[e.jsxs("h4",{className:"text-base font-semibold text-gray-900 dark:text-white mb-1",children:["Switch to ",a.label,"?"]}),e.jsx("p",{className:"text-sm text-gray-700 dark:text-gray-300 mb-3",children:s.reason}),e.jsxs("div",{className:"flex items-center gap-3",children:[e.jsx(j,{onClick:()=>t(s.suggested_mode),variant:"primary",size:"sm",children:"Switch Mode"}),e.jsx(j,{onClick:r,variant:"ghost",size:"sm",className:"text-gray-600 dark:text-gray-400 hover:text-gray-900 dark:hover:text-white",children:"Dismiss"})]})]}),e.jsx(j,{onClick:r,variant:"ghost",size:"sm",className:"p-1 text-gray-400 hover:text-gray-600 dark:hover:text-gray-300","aria-label":"Close",children:e.jsx("svg",{className:"w-5 h-5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:e.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M6 18L18 6M6 6l12 12"})})})]})})},V=m.lazy(()=>x(()=>import("./JobHuntingWidgets-cnBaxjLB.js"),__vite__mapDeps([0,1,2,3,4,5,6,7])).then(s=>({default:s.ApplicationsStatsWidget}))),Y=m.lazy(()=>x(()=>import("./JobHuntingWidgets-cnBaxjLB.js"),__vite__mapDeps([0,1,2,3,4,5,6,7])).then(s=>({default:s.SavedJobsWidget}))),U=m.lazy(()=>x(()=>import("./JobHuntingWidgets-cnBaxjLB.js"),__vite__mapDeps([0,1,2,3,4,5,6,7])).then(s=>({default:s.RecentSearchesWidget}))),q=m.lazy(()=>x(()=>import("./JobHuntingWidgets-cnBaxjLB.js"),__vite__mapDeps([0,1,2,3,4,5,6,7])).then(s=>({default:s.QuickActionsWidget}))),F=m.lazy(()=>x(()=>import("./JobHuntingWidgets-cnBaxjLB.js"),__vite__mapDeps([0,1,2,3,4,5,6,7])).then(s=>({default:s.RecentApplicationsWidget}))),J=m.lazy(()=>x(()=>import("./BuildingProfileWidgets-D17CO5JF.js"),__vite__mapDeps([8,3,1,2,4,5,6,7])).then(s=>({default:s.ProfileCompletenessWidget}))),Q=m.lazy(()=>x(()=>import("./BuildingProfileWidgets-D17CO5JF.js"),__vite__mapDeps([8,3,1,2,4,5,6,7])).then(s=>({default:s.NextStepsWidget}))),G=m.lazy(()=>x(()=>import("./BuildingProfileWidgets-D17CO5JF.js"),__vite__mapDeps([8,3,1,2,4,5,6,7])).then(s=>({default:s.ProfileBenefitsWidget}))),H=m.lazy(()=>x(()=>import("./ManagingPortfolioWidgets-B88vVRHB.js"),__vite__mapDeps([9,1,2,3,4,5,6,7])).then(s=>({default:s.PortfolioAnalyticsWidget}))),K=m.lazy(()=>x(()=>import("./ManagingPortfolioWidgets-B88vVRHB.js"),__vite__mapDeps([9,1,2,3,4,5,6,7])).then(s=>({default:s.PortfolioSiteWidget}))),X=m.lazy(()=>x(()=>import("./ManagingPortfolioWidgets-B88vVRHB.js"),__vite__mapDeps([9,1,2,3,4,5,6,7])).then(s=>({default:s.RecentUpdatesWidget}))),Z=m.lazy(()=>x(()=>import("./ManagingPortfolioWidgets-B88vVRHB.js"),__vite__mapDeps([9,1,2,3,4,5,6,7])).then(s=>({default:s.PortfolioActionsWidget}))),ee=m.lazy(()=>x(()=>import("./BrowsingWidgets-NBt-UUt7.js"),__vite__mapDeps([10,1,2,3,4,5,6,7])).then(s=>({default:s.WhatToDoWidget}))),te=m.lazy(()=>x(()=>import("./BrowsingWidgets-NBt-UUt7.js"),__vite__mapDeps([10,1,2,3,4,5,6,7])).then(s=>({default:s.QuickStatsWidget}))),se=m.lazy(()=>x(()=>import("./BrowsingWidgets-NBt-UUt7.js"),__vite__mapDeps([10,1,2,3,4,5,6,7])).then(s=>({default:s.PersonalizedSuggestionsWidget}))),re={"applications-stats":V,"saved-jobs":Y,"recent-searches":U,"quick-actions":q,"recent-applications":F,"profile-completeness":J,"next-steps":Q,"profile-benefits":G,"portfolio-analytics":H,"portfolio-site":K,"recent-updates":X,"portfolio-actions":Z,"what-to-do":ee,"quick-stats":te,suggestions:se};function ie(s){return re[s]||null}const oe=({className:s=""})=>{const{mode:t,isLoading:r,error:a}=S();if(r)return e.jsx("div",{className:`space-y-6 ${s}`,children:e.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-6",children:[1,2,3].map(d=>e.jsx(v,{children:e.jsx(A,{})},d))})});if(a||!t)return e.jsx("div",{className:`space-y-6 ${s}`,children:e.jsx(v,{children:e.jsxs("div",{className:"text-center py-8",children:[e.jsx("div",{className:"text-4xl mb-3",children:"â ï¸"}),e.jsx("h4",{className:"text-base font-medium text-gray-900 dark:text-white mb-1",children:"Unable to load dashboard"}),e.jsx("p",{className:"text-sm text-gray-600 dark:text-gray-400",children:a||"Please try refreshing the page"})]})})});const u=(t==null?void 0:t.current_mode)??"exploring",c=$(u);return e.jsxs("div",{className:`space-y-6 ${s}`,children:[e.jsx(B,{}),e.jsxs("div",{className:"relative overflow-hidden rounded-2xl bg-white dark:bg-gray-900 border border-gray-200 dark:border-gray-800 shadow-sm",children:[e.jsx("div",{className:"absolute top-0 right-0 w-96 h-96 bg-gradient-to-br from-blue-500/5 via-purple-500/3 to-transparent roun
13ded-full blur-3xl pointer-events-none -translate-y-1/2 translate-x-1/3"}),e.jsx("div",{className:"relative px-8 py-8 min-w-0",children:e.jsxs("div",{className:"flex items-center justify-between gap-4 min-w-0",children:[e.jsxs("div",{className:"flex-1 min-w-0 overflow-hidden",children:[e.jsxs("div",{className:"flex items-center gap-3 mb-2",children:[e.jsx("span",{className:"text-3xl",children:"ð"}),e.jsx("h2",{className:"text-3xl font-bold text-gray-900 dark:text-white tracking-tight",children:"Welcome back!"})]}),e.jsx("p",{className:"text-lg text-gray-600 dark:text-gray-400 max-w-2xl break-words",children:ae(u)})]}),e.jsx("div",{className:"hidden lg:flex flex-shrink-0 items-center gap-3 px-6 py-3 rounded-xl bg-blue-50 dark:bg-blue-900/20 border border-blue-200 dark:border-blue-800",children:e.jsxs("div",{className:"text-right",children:[e.jsx("div",{className:"text-xs font-semibold text-blue-600 dark:text-blue-400 mb-1",children:"Current Focus"}),e.jsx("div",{className:"text-lg font-bold text-blue-700 dark:text-blue-300 capitalize",children:u.replace("_"," ")})]})})]})})]}),e.jsx("div",{"data-testid":"dashboard-widget-grid",className:"grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-6 min-w-0",children:c.map((d,h)=>{const i=ie(d.id),o=`${h*30}ms`,g={"--stagger-delay":o,animationDelay:o};return i?e.jsx("div",{className:"animate-fade-in-up opacity-0 min-w-0",style:g,children:e.jsx(p.Suspense,{fallback:e.jsx(v,{children:e.jsx(A,{})}),children:e.jsx(i,{})})},d.id):e.jsx("div",{className:"animate-fade-in-up opacity-0 min-w-0",style:g,children:e.jsx(v,{children:e.jsxs("div",{className:"text-center py-8",children:[e.jsx("div",{className:"text-4xl mb-3",children:"ð§"}),e.jsx("h4",{className:"text-base font-medium text-gray-900 dark:text-white mb-1",children:d.title||d.id}),e.jsx("p",{className:"text-xs text-gray-500 dark:text-gray-500 mt-2",children:"Coming soon"})]})})},d.id)})}),c.length===0&&e.jsx(v,{children:e.jsxs("div",{className:"text-center py-12",children:[e.jsx("div",{className:"text-5xl mb-3",children:"ð"}),e.jsx("h4",{className:"text-lg font-medium text-gray-900 dark:text-white mb-1",children:"No widgets configured"}),e.jsx("p",{className:"text-sm text-gray-600 dark:text-gray-400",children:"Widgets for this mode will be added soon"})]})})]})};function ae(s){return{job_hunting:"Track applications, search jobs, and manage your job search",building_profile:"Set up your career story and unlock AI features",managing_portfolio:"Update your professional website and showcase your work",browsing:"Explore CareerDiary at your own pace"}[s]||"Your personalized dashboard"}const ne=({className:s="",variant:t="compact"})=>{const{mode:r,isLoading:a,changeMode:u}=S(),[c,d]=p.useState(!1),h=p.useRef(null);if(M(h,()=>d(!1)),a||!r)return e.jsx("div",{className:`animate-pulse bg-gray-200 dark:bg-gray-700 rounded-full h-10 w-32 ${s}`});const i=Array.isArray(r)?r[0]:r;if(!i||!i.current_mode)return console.warn("[ModeSelector] Invalid mode object:",JSON.stringify(r)),null;const o=w[i.current_mode];if(!o)return console.warn(`[ModeSelector] Missing metadata for mode: "${i.current_mode}"`,JSON.stringify(i)),null;const g=Object.values(w).filter(l=>l.id!==i.current_mode),_=async l=>{d(!1),await u(l)};return t==="compact"?e.jsxs("div",{className:`relative ${s}`,ref:h,children:[e.jsxs(j,{onClick:()=>d(!c),variant:"ghost",size:"sm",className:` 14 flex items-center gap-2 px-3 py-2 15 bg-white dark:bg-slate-800 16 border border-gray-200 dark:border-slate-700 17 rounded-full 18 hover:shadow-md hover:border-gray-300 dark:hover:border-slate-600 19 transition-all duration-base 20 text-sm font-medium 21 text-gray-700 dark:text-gray-200 h-auto 22 `,"aria-label":"Select mode","aria-expanded":c,rightIcon:e.jsx("svg",{className:`w-4 h-4 transition-transform ${c?"rotate-180":""}`,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:e.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M19 9l-7 7-7-7"})}),children:[e.jsx("span",{className:"text-lg",children:(o==null?void 0:o.icon)||"ð¯"}),e.jsx("span",{className:"hidden sm:inline",children:(o==null?void 0:o.label)||"Loading..."})]}),c&&e.jsxs("div",{className:` 23 absolute top-full right-0 mt-2 w-64 24 bg-white dark:bg-slate-800 25 border border-gray-200 dark:border-slate-700 26 rounded-xl shadow-xl 27 py-2 z-50 28 animate-fadeIn 29 `,children:[e.jsx("div",{className:"px-3 py-2 border-b border-gray-100 dark:border-slate-700",children:e.jsx("p",{className:"text-xs font-semibold text-gray-500 dark:text-gray-400 uppercase tracking-wide",children:"Switch Mode"})}),g.map(l=>e.jsxs(j,{onClick:()=>_(l.id),variant:"ghost",size:"md",className:` 30 w-full flex items-center gap-3 px-3 py-3 31 hover:bg-gray-50 dark:hover:bg-slate-700 32 transition-colors 33 text-left justify-start h-auto border-none 34 `,children:[e.jsx("span",{className:"text-2xl",children:l.icon}),e.jsxs("div",{className:"flex-1",children:[e.jsx("p",{className:"text-sm font-medium text-gray-900 dark:text-white",children:l.label}),e.jsx("p",{className:"text-xs text-gray-500 dark:text-gray-400",children:l.description})]})]},l.id)),e.jsx("div",{className:"px-3 py-2 mt-2 border-t border-gray-100 dark:border-slate-700",children:e.jsx("p",{className:"text-xs text-gray-500 dark:text-gray-400",children:"ð¡ Your dashboard adapts to your chosen mode"})})]})]}):e.jsxs("div",{className:`space-y-3 ${s}`,children:[e.jsx("h3",{className:"text-lg font-semibold text-gray-900 dark:text-white",children:"Choose Your Mode"}),e.jsx("p",{className:"text-sm text-gray-600 dark:text-gray-400",children:"Select the mode that best matches what you want to do today"}),e.jsx("div",{className:"grid grid-cols-1 sm:grid-cols-2 gap-3",children:Object.values(w).map(l
34=>{const b=r.current_mode===l.id;return e.jsx(j,{onClick:()=>!b&&_(l.id),disabled:b,variant:"ghost",className:` 35 flex flex-col items-start gap-2 p-4 36 border rounded-xl 37 transition-all duration-base 38 h-auto justify-start border-none 39 ${b?"border-blue-500 bg-blue-50 dark:bg-blue-900/20":"border-gray-200 dark:border-slate-700 hover:border-gray-300 dark:hover:border-slate-600 hover:shadow-md"} 40 ${b?"cursor-default":"cursor-pointer"} 41 `,children:e.jsxs("div",{className:"flex items-center gap-3 w-full",children:[e.jsx("span",{className:"text-3xl",children:l.icon}),e.jsxs("div",{className:"flex-1 text-left",children:[e.jsx("p",{className:"text-sm font-semibold text-gray-900 dark:text-white",children:l.label}),e.jsx("p",{className:"text-xs text-gray-600 dark:text-gray-400",children:l.description})]}),b&&e.jsx("svg",{className:"w-5 h-5 text-blue-500",fill:"currentColor",viewBox:"0 0 20 20",children:e.jsx("path",{fillRule:"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zm3.707-9.293a1 1 0 00-1.414-1.414L9 10.586 7.707 9.293a1 1 0 00-1.414 1.414l2 2a1 1 0 001.414 0l4-4z",clipRule:"evenodd"})})]})},l.id)})})]})},D=()=>e.jsxs("div",{className:"min-h-screen bg-gray-50 dark:bg-gray-900",children:[e.jsx("header",{className:"bg-white dark:bg-slate-800 border-b border-gray-200 dark:border-slate-700",children:e.jsx("div",{className:"max-w-7xl mx-auto px-4 sm:px-6 lg:px-8 py-4",children:e.jsxs("div",{className:"flex items-center justify-between",children:[e.jsxs("div",{children:[e.jsx("h1",{className:"text-2xl font-bold text-gray-900 dark:text-white",children:"CareerDiary"}),e.jsx("p",{className:"text-sm text-gray-600 dark:text-gray-400 mt-1",children:"Adaptive Dashboard Demo"})]}),e.jsx(ne,{variant:"compact"})]})})}),e.jsx("main",{className:"max-w-7xl mx-auto px-4 sm:px-6 lg:px-8 py-8",children:e.jsx(oe,{})}),e.jsx("footer",{className:"mt-12 py-6 border-t border-gray-200 dark:border-slate-700",children:e.jsx("div",{className:"max-w-7xl mx-auto px-4 sm:px-6 lg:px-8",children:e.jsx("p",{className:"text-center text-sm text-gray-600 dark:text-gray-400",children:"CAR-233: Widget System Architecture Demo"})})})]}),me=Object.freeze(Object.defineProperty({__proto__:null,DashboardDemo:D,default:D},Symbol.toStringTag,{value:"Module"}));export{me as D,w as M,v as W,A as a,ue as b,ge as c,ce as d};
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.