From d61ec772a3a9f8d23949737478982418f63f00a1 Mon Sep 17 00:00:00 2001 From: DragonnZhang <731557579@qq.com> Date: Tue, 10 Feb 2026 18:47:30 +0800 Subject: [PATCH] Refactor code structure for improved readability and maintainability --- .prettierignore | 1 + .../cli/src/services/insight/templates/insightTemplate.ts | 6 ++---- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/.prettierignore b/.prettierignore index f4330b7e6..c9ae7e56a 100644 --- a/.prettierignore +++ b/.prettierignore @@ -18,3 +18,4 @@ eslint.config.js gha-creds-*.json junit.xml Thumbs.db +packages/cli/src/services/insight/templates/insightTemplate.ts diff --git a/packages/cli/src/services/insight/templates/insightTemplate.ts b/packages/cli/src/services/insight/templates/insightTemplate.ts index 13ca138c2..c5da21945 100644 --- a/packages/cli/src/services/insight/templates/insightTemplate.ts +++ b/packages/cli/src/services/insight/templates/insightTemplate.ts @@ -6,7 +6,5 @@ * This file is code-generated; do not edit manually. */ -export const INSIGHT_JS = - '(function(e,k){"use strict";function z({data:t,dateRangeStr:l}){const{totalMessages:n,totalSessions:a}=t;return e.createElement("header",{className:"mb-8 space-y-3 text-center"},e.createElement("h1",{className:"text-3xl font-semibold text-slate-900 md:text-4xl"},"Qwen Code Insights"),e.createElement("p",{className:"text-sm text-slate-600"},n?`${n} messages across ${a} sessions`:"Your personalized coding journey and patterns",l&&` | ${l}`))}function M({data:t}){const{totalMessages:l=0,totalLinesAdded:n=0,totalLinesRemoved:a=0,totalFiles:r=0}=t,i=Object.keys(t.heatmap||{});let s=0;if(i.length>0){const d=i.map(x=>new Date(x)).map(x=>x.getTime()),p=new Date(Math.min(...d)),g=new Date(Math.max(...d)),f=Math.abs(g.getTime()-p.getTime());s=Math.ceil(f/(1e3*60*60*24))+1}const c=s>0?Math.round(l/s):0;return e.createElement("div",{className:"stats-row"},e.createElement("div",{className:"stat"},e.createElement("div",{className:"stat-value"},l),e.createElement("div",{className:"stat-label"},"Messages")),e.createElement("div",{className:"stat"},e.createElement("div",{className:"stat-value"},"+",n,"/-",a),e.createElement("div",{className:"stat-label"},"Lines")),e.createElement("div",{className:"stat"},e.createElement("div",{className:"stat-value"},r),e.createElement("div",{className:"stat-label"},"Files")),e.createElement("div",{className:"stat"},e.createElement("div",{className:"stat-value"},s),e.createElement("div",{className:"stat-label"},"Days")),e.createElement("div",{className:"stat"},e.createElement("div",{className:"stat-value"},c),e.createElement("div",{className:"stat-label"},"Msgs/Day")))}function I({insights:t}){return e.createElement("div",{className:"grid gap-4 md:grid-cols-2 md:gap-6"},e.createElement(O,{activeHours:t.activeHours,cardClass:"glass-card p-6",sectionTitleClass:"text-lg font-semibold tracking-tight text-slate-900"}))}function O({activeHours:t,cardClass:l,sectionTitleClass:n}){const r=[{label:"Morning",time:"06:00 - 12:00",hours:[6,7,8,9,10,11],color:"#fbbf24"},{label:"Afternoon",time:"12:00 - 18:00",hours:[12,13,14,15,16,17],color:"#0ea5e9"},{label:"Evening",time:"18:00 - 00:00",hours:[18,19,20,21,22,23],color:"#6366f1"},{label:"Night",time:"00:00 - 06:00",hours:[0,1,2,3,4,5],color:"#475569"}].map(s=>{const c=s.hours.reduce((o,d)=>o+(t[d]||0),0);return{...s,total:c}}),i=Math.max(...r.map(s=>s.total));return e.createElement("div",{className:`${l} h-full flex flex-col min-h-[320px]`},e.createElement("div",{className:"flex items-center justify-between mb-4"},e.createElement("h3",{className:n},"Active Hours")),e.createElement("div",{className:"flex-1 flex flex-col justify-center gap-4"},r.map(s=>e.createElement("div",{key:s.label,className:"space-y-2"},e.createElement("div",{className:"flex justify-between items-center text-sm"},e.createElement("div",{className:"flex items-center gap-2"},e.createElement("span",{className:"rounded-full",style:{width:"12px",height:"12px",backgroundColor:s.color}}),e.createElement("span",{className:"font-medium text-slate-700"},s.label),e.createElement("span",{className:"text-xs text-slate-400 hidden xl:inline"},s.time)),e.createElement("span",{className:"font-semibold text-slate-900"},s.total)),e.createElement("div",{className:"w-full rounded-full overflow-hidden",style:{height:"12px",backgroundColor:"#e2e8f0"}},e.createElement("div",{className:"h-full rounded-full",style:{width:`${i>0?s.total/i*100:0}%`,backgroundColor:s.color}}))))))}function q({heatmap:t}){return e.createElement("div",{className:"glass-card p-6 mt-4 md:mt-6"},e.createElement("div",{className:"flex items-center justify-between"},e.createElement("h3",{className:"text-lg font-semibold tracking-tight text-slate-900"},"Activity Heatmap"),e.createElement("span",{className:"text-xs font-semibold text-slate-500"},"Past year")),e.createElement("div",{className:"heatmap-container"},e.createElement("div",{className:"min-w-[720px] rounded-xl bg-white/70"},e.createElement(j,{heatmapData:t}))))}function j({heatmapData:t}){const i=new Date,s=new Date(i);s.setFullYear(i.getFullYear()-1);const c=[],o=new Date(s);for(;o<=i;)c.push(new Date(o)),o.setDate(o.getDate()+1);const d=[0,2,4,10,20],p=["#e2e8f0","#a5d8ff","#74c0fc","#339af0","#1c7ed6"];function g(E){if(E===0)return p[0];for(let u=d.length-1;u>=1;u--)if(E>=d[u])return p[u];return p[1]}const f=50,x=20,V=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],S=s.getDay(),T=[];let D=-1,W=-100;return c.forEach((E,u)=>{const v=u+S,C=Math.floor(v/7),y=f+C*16,N=E.getMonth();N!==D&&(y-W>30&&(T.push({x:y,text:V[N]}),W=y),D=N)}),e.createElement("svg",{className:"heatmap-svg",width:1e3,height:150,viewBox:"0 0 1000 150"},c.map((E,u)=>{const v=u+S,C=Math.floor(v/7),y=E.getDay(),N=f+C*16,Z=x+y*16,w=E.toISOString().split("T")[0],A=t[w]||0,R=g(A);return e.createElement("rect",{key:w,className:"heatmap-day",x:N,y:Z,width:14,height:14,rx:"2",fill:R,"data-date":w,"data-count":A},e.createElement("title",null,w,": ",A," activities"))}),T.map((E,u)=>e.createElement("text",{key:u,x:E.x,y:"15",fontSize:"12",fill:"#64748b"},E.text)),e.createElement("text",{x:f,y:110,fontSize:"12",fill:"#64748b"},"Less"),p.map((E,u)=>{const v=f+40+u*16;return e.createElement("rect",{key:u,x:v,y:120,width:"10",height:"10",rx:"2",fill:E})}),e.createElement("text",{x:f+40+p.length*16+5,y:129,fontSize:"12",fill:"#64748b",width:14},"More"))}function m({children:t}){if(!t||typeof t!="string")return t;const l=t.split(/(\\*\\*.*?\\*\\*)/g);return e.createElement(e.Fragment,null,l.map((n,a)=>n.startsWith("**")&&n.endsWith("**")&&n.length>=4?e.createElement("strong",{key:a},n.slice(2,-2)):n))}function b({text:t,label:l="Copy"}){const[n,a]=e.useState(!1),r=()=>{navigator.clipboard.writeText(t).then(()=>{a(!0),setTimeout(()=>a(!1),2e3)})};return e.createElement("button",{className:"copy-btn",onClick:r},n?"Copied!":l)}function F({qualitative:t}){const{atAGlance:l}=t;return l?e.createElement("div",{className:"at-a-glance"},e.createElement("div",{className:"glance-title"},"At a Glance"),e.createElement("div",{className:"glance-sections"},e.createElement("div",{className:"glance-section"},e.createElement("strong",null,"What\'s working:")," ",e.createElement(m,null,l.whats_working),e.createElement("a",{href:"#section-wins",className:"see-more"},"Impressive Things You Did →")),e.createElement("div",{className:"glance-section"},e.createElement("strong",null,"What\'s hindering you:")," ",e.createElement(m,null,l.whats_hindering),e.createElement("a",{href:"#section-friction",className:"see-more"},"Where Things Go Wrong →")),e.createElement("div",{className:"glance-section"},e.createElement("strong",null,"Quick wins to try:")," ",e.createElement(m,null,l.quick_wins),e.createElement("a",{href:"#section-features",className:"see-more"},"Features to Try →")),e.createElement("div",{className:"glance-section"},e.createElement("strong",null,"Ambitious workflows:")," ",e.createElement(m,null,l.ambitious_workflows),e.createElement("a",{href:"#section-horizon",className:"see-more"},"On the Horizon →")))):null}function H(){return e.createElement("nav",{className:"nav-toc"},e.createElement("a",{href:"#section-work"},"What You Work On"),e.createElement("a",{href:"#section-usage"},"How You Use QC"),e.createElement("a",{href:"#section-wins"},"Impressive Things"),e.createElement("a",{href:"#section-friction"},"Where Things Go Wrong"),e.createElement("a",{href:"#section-features"},"Features to Try"),e.createElement("a",{href:"#section-patterns"},"New Usage Patterns"),e.createElement("a",{href:"#section-horizon"},"On the Horizon"))}function Q({qualitative:t,topGoals:l,topTools:n}){const{projectAreas:a}=t,r=Array.isArray(n)?Object.fromEntries(n):n;return e.createElement(e.Fragment,null,e.createElement("h2",{id:"section-work",className:"text-xl font-semibold text-slate-900 mt-8 mb-4"},"What You Work On"),Array.isArray(a==null?void 0:a.areas)&&a.areas.length>0&&e.createElement("div",{className:"project-areas mb-6"},a.areas.map((i,s)=>e.createElement("div",{key:s,className:"project-area"},e.createElement("div",{className:"area-header"},e.createElement("span",{className:"area-name"},i.name),e.createElement("span",{className:"area-count"},"~",i.session_count," sessions")),e.createElement("div",{className:"area-desc"},e.createElement(m,null,i.description))))),e.createElement("div",{style:{display:"grid",gridTemplateColumns:"repeat(2, 1fr)",gap:"24px",marginBottom:"24px"}},l&&Object.keys(l).length>0&&e.createElement(h,{data:l,title:"What You Wanted",color:"#0ea5e9"}),r&&Object.keys(r).length>0&&e.createElement(h,{data:r,title:"Top Tools Used",color:"#6366f1"})))}function P({qualitative:t,insights:l}){const{interactionStyle:n}=t;return n?e.createElement(e.Fragment,null,e.createElement("h2",{id:"section-usage",className:"text-xl font-semibold text-slate-900 mt-8 mb-4"},"How You Use Qwen Code"),e.createElement("div",{className:"narrative"},e.createElement("p",null,e.createElement(m,null,n.narrative)),n.key_pattern&&e.createElement("div",{className:"key-insight"},e.createElement("strong",null,"Key pattern:")," ",e.createElement(m,null,n.key_pattern))),e.createElement(I,{insights:l}),e.createElement(q,{heatmap:l.heatmap})):null}function $({qualitative:t,primarySuccess:l,outcomes:n}){const{impressiveWorkflows:a}=t;return a?e.createElement(e.Fragment,null,e.createElement("h2",{id:"section-wins",className:"text-xl font-semibold text-slate-900 mt-8 mb-4"},"Impressive Things You Did"),a.intro&&e.createElement("p",{className:"section-intro"},e.createElement(m,null,a.intro)),e.createElement("div",{className:"big-wins"},Array.isArray(a.impressive_workflows)&&a.impressive_workflows.map((r,i)=>e.createElement("div",{key:i,className:"big-win"},e.createElement("div",{className:"big-win-title"},r.title),e.createElement("div",{className:"big-win-desc"},e.createElement(m,null,r.description))))),e.createElement("div",{style:{display:"grid",gridTemplateColumns:"repeat(2, 1fr)",gap:"24px",marginTop:"24px",marginBottom:"24px"}},l&&Object.keys(l).length>0&&e.createElement(h,{data:l,title:"What Helped Most (Qwen\'s Capabilities)",color:"#3b82f6",allowedKeys:["fast_accurate_search","correct_code_edits","good_explanations","proactive_help","multi_file_changes","good_debugging"]}),n&&Object.keys(n).length>0&&e.createElement(h,{data:n,title:"Outcomes",color:"#8b5cf6",allowedKeys:["fully_achieved","mostly_achieved","partially_achieved","not_achieved","unclear_from_transcript"]}))):null}function B(t){return t==="unclear_from_transcript"?"Unclear":t.split("_").map(l=>l.charAt(0).toUpperCase()+l.slice(1)).join(" ")}function h({data:t,title:l,color:n="#3b82f6",allowedKeys:a=null}){if(!t||Object.keys(t).length===0)return null;let r=Object.entries(t);if(a&&(r=r.filter(([s])=>a.includes(s))),r.sort((s,c)=>c[1]-s[1]),r.length===0)return null;const i=Math.max(...r.map(([,s])=>s));return e.createElement("div",{className:"bar-chart-card",style:{flex:1,minWidth:0,backgroundColor:"#ffffff",borderRadius:"12px",padding:"20px",boxShadow:"0 1px 3px rgba(0, 0, 0, 0.08)",border:"1px solid #e2e8f0"}},e.createElement("h3",{style:{fontSize:"13px",fontWeight:700,color:"#64748b",marginTop:0,marginBottom:"16px",textTransform:"uppercase",letterSpacing:"0.5px"}},l),e.createElement("div",{className:"bar-chart",style:{display:"flex",flexDirection:"column",gap:"10px"}},r.map(([s,c])=>{const o=i>0?c/i*100:0;return e.createElement("div",{key:s,className:"bar-row",style:{display:"flex",alignItems:"center",gap:"12px"}},e.createElement("div",{className:"bar-label",style:{width:"130px",fontSize:"13px",color:"#475569",textAlign:"left",flexShrink:0,whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis"}},B(s)),e.createElement("div",{className:"bar-wrapper",style:{flex:1,display:"flex",alignItems:"center",gap:"10px",minWidth:0}},e.createElement("div",{className:"bar-bg",style:{flex:1,height:"8px",backgroundColor:"#f1f5f9",borderRadius:"4px",overflow:"hidden"}},e.createElement("div",{className:"bar-fill",style:{width:`${o}%`,height:"100%",backgroundColor:n,borderRadius:"4px",transition:"width 0.3s ease"}})),e.createElement("span",{className:"bar-value",style:{fontSize:"13px",fontWeight:600,color:"#475569",minWidth:"24px",textAlign:"right"}},c)))})))}function Y({qualitative:t,satisfaction:l,friction:n}){const{frictionPoints:a}=t;return a?e.createElement(e.Fragment,null,e.createElement("h2",{id:"section-friction",className:"text-xl font-semibold text-slate-900 mt-8 mb-4"},"Where Things Go Wrong"),a.intro&&e.createElement("p",{className:"section-intro"},e.createElement(m,null,a.intro)),e.createElement("div",{className:"friction-categories"},Array.isArray(a.categories)&&a.categories.map((r,i)=>e.createElement("div",{key:i,className:"friction-category"},e.createElement("div",{className:"friction-title"},r.category),e.createElement("div",{className:"friction-desc"},e.createElement(m,null,r.description)),Array.isArray(r.examples)&&r.examples.length>0&&e.createElement("ul",{className:"friction-examples"},r.examples.map((s,c)=>e.createElement("li",{key:c},e.createElement(m,null,s))))))),e.createElement("div",{style:{display:"grid",gridTemplateColumns:"repeat(2, 1fr)",gap:"24px",marginTop:"24px",marginBottom:"24px"}},n&&Object.keys(n).length>0&&e.createElement(h,{data:n,title:"Primary Friction Types",color:"#ef4444",allowedKeys:["misunderstood_request","wrong_approach","buggy_code","user_rejected_action","excessive_changes"]}),l&&Object.keys(l).length>0&&e.createElement(h,{data:l,title:"Inferred Satisfaction (model-estimated)",color:"#10b981",allowedKeys:["happy","satisfied","likely_satisfied","dissatisfied","frustrated"]}))):null}function G({additions:t}){const[l,n]=e.useState(new Array(t.length).fill(!0)),[a,r]=e.useState(!1),i=o=>{const d=l.map((p,g)=>g===o?!p:p);n(d)},s=()=>{const o=t.filter((d,p)=>l[p]).map(d=>d.addition).join(`\n\n`);o&&navigator.clipboard.writeText(o).then(()=>{r(!0),setTimeout(()=>r(!1),2e3)})},c=l.filter(Boolean).length;return e.createElement("div",{className:"qwen-md-section"},e.createElement("h3",null,"Suggested QWEN.md Additions"),e.createElement("p",{className:"text-xs text-slate-500 mb-3"},"Just copy this into Qwen Code to add it to your QWEN.md."),e.createElement("div",{className:"qwen-md-actions",style:{marginBottom:"12px"}},e.createElement("button",{className:`copy-all-btn ${a?"copied":""}`,onClick:s,disabled:c===0},a?"Copied All!":`Copy All Checked (${c})`)),t.map((o,d)=>e.createElement("div",{key:d,className:"qwen-md-item"},e.createElement("input",{type:"checkbox",checked:l[d],onChange:()=>i(d),className:"cmd-checkbox"}),e.createElement("div",{style:{flex:1}},e.createElement("code",{className:"cmd-code"},o.addition),e.createElement("div",{className:"cmd-why"},e.createElement(m,null,o.why))),e.createElement(b,{text:o.addition}))))}function L({qualitative:t}){const{improvements:l}=t;return l?e.createElement(e.Fragment,null,e.createElement("h2",{id:"section-features",className:"text-xl font-semibold text-slate-900 mt-8 mb-4"},"Existing QC Features to Try"),Array.isArray(l.Qwen_md_additions)&&l.Qwen_md_additions.length>0&&e.createElement(G,{additions:l.Qwen_md_additions}),e.createElement("p",{className:"text-xs text-slate-500 mb-3"},"Just copy this into Qwen Code and it\'ll set it up for you."),e.createElement("div",{className:"features-section"},Array.isArray(l.features_to_try)&&l.features_to_try.map((n,a)=>e.createElement("div",{key:a,className:"feature-card"},e.createElement("div",{className:"feature-title"},n.feature),e.createElement("div",{className:"feature-oneliner"},e.createElement(m,null,n.one_liner)),e.createElement("div",{className:"feature-why"},e.createElement("strong",null,"Why for you:")," ",e.createElement(m,null,n.why_for_you)),e.createElement("div",{className:"feature-examples"},e.createElement("div",{className:"feature-example"},e.createElement("div",{className:"example-code-row"},e.createElement("code",{className:"example-code"},n.example_code),e.createElement(b,{text:n.example_code}))))))),e.createElement("h2",{id:"section-patterns",className:"text-xl font-semibold text-slate-900 mt-8 mb-4"},"New Ways to Use Qwen Code"),e.createElement("p",{className:"text-xs text-slate-500 mb-3"},"Just copy this into Qwen Code and it\'ll walk you through it."),e.createElement("div",{className:"patterns-section"},Array.isArray(l.usage_patterns)&&l.usage_patterns.map((n,a)=>e.createElement("div",{key:a,className:"pattern-card"},e.createElement("div",{className:"pattern-title"},n.title),e.createElement("div",{className:"pattern-summary"},e.createElement(m,null,n.suggestion)),e.createElement("div",{className:"pattern-detail"},e.createElement(m,null,n.detail)),e.createElement("div",{className:"copyable-prompt-section"},e.createElement("div",{className:"prompt-label"},"Paste into Qwen Code:"),e.createElement("div",{className:"copyable-prompt-row"},e.createElement("code",{className:"copyable-prompt"},n.copyable_prompt),e.createElement(b,{text:n.copyable_prompt}))))))):null}function U({qualitative:t}){const{futureOpportunities:l}=t;return l?e.createElement(e.Fragment,null,e.createElement("h2",{id:"section-horizon",className:"text-xl font-semibold text-slate-900 mt-8 mb-4"},"On the Horizon"),l.intro&&e.createElement("p",{className:"section-intro"},e.createElement(m,null,l.intro)),e.createElement("div",{className:"horizon-section"},Array.isArray(l.opportunities)&&l.opportunities.map((n,a)=>e.createElement("div",{key:a,className:"horizon-card"},e.createElement("div",{className:"horizon-title"},n.title),e.createElement("div",{className:"horizon-possible"},e.createElement(m,null,n.whats_possible)),e.createElement("div",{className:"horizon-tip"},e.createElement("strong",null,"Getting started:")," ",e.createElement(m,null,n.how_to_try)),e.createElement("div",{className:"pattern-prompt"},e.createElement("div",{className:"prompt-label"},"Paste into Qwen Code:"),e.createElement("div",{style:{display:"flex",alignItems:"flex-start",gap:"8px"}},e.createElement("code",{style:{flex:1}},n.copyable_prompt),e.createElement(b,{text:n.copyable_prompt}))))))):null}function K({qualitative:t}){const{memorableMoment:l}=t;return l?e.createElement("div",{className:"fun-ending"},e.createElement("div",{className:"fun-headline"},\'"\',l.headline,\'"\'),e.createElement("div",{className:"fun-detail"},e.createElement(m,null,l.detail))):null}function J({data:t}){if(!t)return e.createElement("div",{className:"text-center text-slate-600"},"No insight data available");const l=Object.keys(t.heatmap||{});let n="";if(l.length>0){const r=l.map(o=>new Date(o)).map(o=>o.getTime()),i=new Date(Math.min(...r)),s=new Date(Math.max(...r)),c=o=>o.toISOString().split("T")[0];n=`${c(i)} to ${c(s)}`}return e.createElement("div",null,e.createElement(z,{data:t,dateRangeStr:n}),t.qualitative&&e.createElement(e.Fragment,null,e.createElement(F,{qualitative:t.qualitative}),e.createElement(H,null)),e.createElement(M,{data:t}),t.qualitative&&e.createElement(e.Fragment,null,e.createElement(Q,{qualitative:t.qualitative,topGoals:t.topGoals,topTools:t.topTools})),t.qualitative&&e.createElement(e.Fragment,null,e.createElement(P,{qualitative:t.qualitative,insights:t})),t.qualitative&&e.createElement(e.Fragment,null,e.createElement($,{qualitative:t.qualitative,primarySuccess:t.primarySuccess,outcomes:t.outcomes}),e.createElement(Y,{qualitative:t.qualitative,satisfaction:t.satisfaction,friction:t.friction}),e.createElement(L,{qualitative:t.qualitative}),e.createElement(U,{qualitative:t.qualitative}),e.createElement(K,{qualitative:t.qualitative})),e.createElement(X,null))}function X(){const[t,l]=e.useState(!1),n=async()=>{const a=document.getElementById("container");if(!a||!window.html2canvas){alert("Export functionality is not available.");return}l(!0);try{const i=(await window.html2canvas(a,{scale:2,useCORS:!0,logging:!1})).toDataURL("image/png"),s=document.createElement("a");s.href=i,s.download=`qwen-insights-${new Date().toISOString().slice(0,10)}.png`,s.click()}catch(r){console.error("Export error:",r),alert("Failed to export image. Please try again.")}finally{l(!1)}};return e.createElement("div",{className:"mt-6 flex justify-center"},e.createElement("button",{onClick:n,disabled:t,className:"group inline-flex items-center gap-2 rounded-full bg-slate-900 px-5 py-3 text-sm font-semibold text-white shadow-soft transition focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-slate-400 hover:-translate-y-[1px] hover:shadow-lg active:translate-y-[1px] disabled:opacity-50"},t?"Exporting...":"Export as Image",e.createElement("span",{className:"text-slate-200 transition group-hover:translate-x-0.5"},"→")))}const _=document.getElementById("react-root");_&&window.INSIGHT_DATA&&k?k.createRoot(_).render(e.createElement(J,{data:window.INSIGHT_DATA})):console.error("Failed to mount React app:",{container:!!_,data:!!window.INSIGHT_DATA,ReactDOM:!!k})})(React,ReactDOM);'; -export const INSIGHT_CSS = - '*,:before,:after,::backdrop{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: #3b82f680;--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }*,:before,:after{box-sizing:border-box;border:0 solid #e5e7eb}:before,:after{--tw-content: ""}html,:host{-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;font-feature-settings:normal;font-variation-settings:normal;-webkit-tap-highlight-color:transparent;font-family:ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji";line-height:1.5}body{line-height:inherit;margin:0;background-image:linear-gradient(to bottom right,var(--tw-gradient-stops));--tw-gradient-from: #f8fafc var(--tw-gradient-from-position);--tw-gradient-to: #f1f5f9 var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), #fff var(--tw-gradient-via-position), var(--tw-gradient-to);--tw-text-opacity: 1;min-height:100vh;color:rgb(15 23 42 / var(--tw-text-opacity, 1));-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.glass-card{--tw-border-opacity: 1;border-width:1px;border-color:rgb(226 232 240 / var(--tw-border-opacity, 1));--tw-shadow: 0 10px 40px #0f172a14;--tw-shadow-colored: 0 10px 40px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow);--tw-backdrop-blur: blur(8px);backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);background-color:#fff9;border-radius:1rem}.col-span-2{grid-column:span 2 / span 2}.mx-auto{margin-left:auto;margin-right:auto}.mb-8{margin-bottom:2rem}.ml-2{margin-left:.5rem}.mt-1{margin-top:.25rem}.mt-2{margin-top:.5rem}.mt-4{margin-top:1rem}.mt-6{margin-top:1.5rem}.block{display:block}.flex{display:flex}.inline-flex{display:inline-flex}.grid{display:grid}.h-56{height:14rem}.h-full{height:100%}.min-h-screen{min-height:100vh}.w-full{width:100%}.min-w-\\[720px\\]{min-width:720px}.max-w-6xl{max-width:72rem}.grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}.flex-col{flex-direction:column}.items-start{align-items:flex-start}.items-center{align-items:center}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.gap-1{gap:.25rem}.gap-2{gap:.5rem}.gap-3{gap:.75rem}.gap-4{gap:1rem}.space-y-3>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.75rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.75rem * var(--tw-space-y-reverse))}.space-y-4>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(1rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(1rem * var(--tw-space-y-reverse))}.divide-y>:not([hidden])~:not([hidden]){--tw-divide-y-reverse: 0;border-top-width:calc(1px * calc(1 - var(--tw-divide-y-reverse)));border-bottom-width:calc(1px * var(--tw-divide-y-reverse))}.divide-slate-200>:not([hidden])~:not([hidden]){--tw-divide-opacity: 1;border-color:rgb(226 232 240 / var(--tw-divide-opacity, 1))}.overflow-x-auto{overflow-x:auto}.rounded-full{border-radius:9999px}.rounded-xl{border-radius:1.25rem}.border{border-width:1px}.border-slate-100{--tw-border-opacity: 1;border-color:rgb(241 245 249 / var(--tw-border-opacity, 1))}.bg-emerald-50{--tw-bg-opacity: 1;background-color:rgb(236 253 245 / var(--tw-bg-opacity, 1))}.bg-slate-100{--tw-bg-opacity: 1;background-color:rgb(241 245 249 / var(--tw-bg-opacity, 1))}.bg-slate-50{--tw-bg-opacity: 1;background-color:rgb(248 250 252 / var(--tw-bg-opacity, 1))}.bg-slate-900{--tw-bg-opacity: 1;background-color:rgb(15 23 42 / var(--tw-bg-opacity, 1))}.bg-white\\/70{background-color:#ffffff73}.bg-gradient-to-br{background-image:linear-gradient(to bottom right,var(--tw-gradient-stops))}.from-slate-50{--tw-gradient-from: #f8fafc var(--tw-gradient-from-position);--tw-gradient-to: #f8fafc00 var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to)}.via-white{--tw-gradient-to: #ffffff00 var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), #ffffff var(--tw-gradient-via-position), var(--tw-gradient-to)}.to-slate-100{--tw-gradient-to: #f1f5f9 var(--tw-gradient-to-position)}.p-4{padding:1rem}.p-6{padding:1.5rem}.px-3{padding-left:.75rem;padding-right:.75rem}.px-4{padding-left:1rem;padding-right:1rem}.px-5{padding-left:1.25rem;padding-right:1.25rem}.px-6{padding-left:1.5rem;padding-right:1.5rem}.px-8{padding-left:2rem;padding-right:2rem}.py-1{padding-top:.25rem;padding-bottom:.25rem}.py-10{padding-top:2.5rem;padding-bottom:2.5rem}.py-2{padding-top:.5rem;padding-bottom:.5rem}.py-3{padding-top:.75rem;padding-bottom:.75rem}.py-6{padding-top:1.5rem;padding-bottom:1.5rem}.text-left{text-align:left}.text-center{text-align:center}.text-2xl{font-size:1.5rem;line-height:2rem}.text-3xl{font-size:1.875rem;line-height:2.25rem}.text-4xl{font-size:2.25rem;line-height:2.5rem}.text-base{font-size:1rem;line-height:1.5rem}.text-lg{font-size:1.125rem;line-height:1.75rem}.text-sm{font-size:.875rem;line-height:1.25rem}.text-xl{font-size:1.25rem;line-height:1.75rem}.text-xs{font-size:.75rem;line-height:1rem}.font-bold{font-weight:700}.font-medium{font-weight:500}.font-semibold{font-weight:600}.uppercase{text-transform:uppercase}.tracking-\\[0\\.2em\\]{letter-spacing:.2em}.tracking-tight{letter-spacing:-.025em}.tracking-wide{letter-spacing:.025em}.text-emerald-700{--tw-text-opacity: 1;color:rgb(4 120 87 / var(--tw-text-opacity, 1))}.text-rose-700{--tw-text-opacity: 1;color:rgb(190 18 60 / var(--tw-text-opacity, 1))}.text-slate-200{--tw-text-opacity: 1;color:rgb(226 232 240 / var(--tw-text-opacity, 1))}.text-slate-400{--tw-text-opacity: 1;color:rgb(148 163 184 / var(--tw-text-opacity, 1))}.text-slate-500{--tw-text-opacity: 1;color:rgb(100 116 139 / var(--tw-text-opacity, 1))}.text-slate-600{--tw-text-opacity: 1;color:rgb(71 85 105 / var(--tw-text-opacity, 1))}.text-slate-700{--tw-text-opacity: 1;color:rgb(51 65 85 / var(--tw-text-opacity, 1))}.text-slate-900{--tw-text-opacity: 1;color:rgb(15 23 42 / var(--tw-text-opacity, 1))}.text-white{--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity, 1))}.shadow-inner{--tw-shadow: inset 0 2px 4px 0 #0000000d;--tw-shadow-colored: inset 0 2px 4px 0 var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-soft{--tw-shadow: 0 10px 40px #0f172a14;--tw-shadow-colored: 0 10px 40px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-slate-100{--tw-shadow-color: #f1f5f9;--tw-shadow: var(--tw-shadow-colored)}.transition{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-duration:.15s;transition-timing-function:cubic-bezier(.4,0,.2,1)}.hover\\:-translate-y-\\[1px\\]:hover{--tw-translate-y: -1px;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.hover\\:shadow-lg:hover{--tw-shadow: 0 10px 15px -3px #0000001a, 0 4px 6px -4px #0000001a;--tw-shadow-colored: 0 10px 15px -3px var(--tw-shadow-color), 0 4px 6px -4px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.focus-visible\\:outline:focus-visible{outline-style:solid}.focus-visible\\:outline-2:focus-visible{outline-width:2px}.focus-visible\\:outline-offset-2:focus-visible{outline-offset:2px}.focus-visible\\:outline-slate-400:focus-visible{outline-color:#94a3b8}.active\\:translate-y-\\[1px\\]:active{--tw-translate-y: 1px;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.group:hover .group-hover\\:translate-x-0\\.5{--tw-translate-x: .125rem;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}@media (min-width: 768px){.md\\:mt-6{margin-top:1.5rem}.md\\:grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}.md\\:gap-6{gap:1.5rem}.md\\:py-12{padding-top:3rem;padding-bottom:3rem}.md\\:text-4xl{font-size:2.25rem;line-height:2.5rem}}.heatmap-container{width:100%;overflow-x:auto}.heatmap-svg{min-width:720px}.heatmap-day{cursor:pointer}.heatmap-day:hover{stroke:#00000024;stroke-width:1px}.heatmap-legend{display:flex;align-items:center;gap:4px;font-size:12px;color:#64748b;margin-top:8px}.heatmap-legend-item{width:10px;height:10px;border-radius:2px}.nav-toc{display:flex;flex-wrap:wrap;gap:8px;margin:24px 0 32px;padding:16px;background:#fff;border-radius:8px;border:1px solid #e2e8f0}.nav-toc a{font-size:12px;color:#64748b;text-decoration:none;padding:6px 12px;border-radius:6px;background:#f1f5f9;transition:all .15s}.nav-toc a:hover{background:#e2e8f0;color:#334155}.at-a-glance{background:linear-gradient(135deg,#fef3c7,#fde68a);border:1px solid #f59e0b;border-radius:12px;padding:20px 24px;margin-bottom:32px}.glance-title{font-size:16px;font-weight:700;color:#92400e;margin-bottom:16px}.glance-sections{display:flex;flex-direction:column;gap:12px}.glance-section{font-size:14px;color:#78350f;line-height:1.6}.glance-section strong{color:#92400e;font-weight:700}.see-more{color:#b45309;text-decoration:none;font-size:13px;white-space:nowrap;margin-left:4px}.see-more:hover{text-decoration:underline}.project-areas{display:flex;flex-direction:column;gap:12px;margin-bottom:32px}.project-area{background:#fff;border:1px solid #e2e8f0;border-radius:8px;padding:16px}.area-header{display:flex;justify-content:space-between;align-items:center;margin-bottom:8px}.area-name{font-weight:600;font-size:15px;color:#0f172a}.area-count{font-size:12px;color:#64748b;background:#f1f5f9;padding:2px 8px;border-radius:4px}.area-desc{font-size:14px;color:#475569;line-height:1.5}.narrative{background:#fff;border:1px solid #e2e8f0;border-radius:8px;padding:20px;margin-bottom:24px}.narrative p{margin-top:0;margin-bottom:12px;font-size:14px;color:#475569;line-height:1.7}.key-insight{background:#f0fdf4;border:1px solid #bbf7d0;border-radius:8px;padding:12px 16px;margin-top:12px;font-size:14px;color:#166534}.section-intro{font-size:14px;color:#64748b;margin-bottom:16px}.big-wins{display:flex;flex-direction:column;gap:12px;margin-bottom:24px}.big-win{background:#f0fdf4;border:1px solid #bbf7d0;border-radius:8px;padding:16px}.big-win-title{font-weight:600;font-size:15px;color:#166534;margin-bottom:8px}.big-win-desc{font-size:14px;color:#15803d;line-height:1.5}.friction-categories{display:flex;flex-direction:column;gap:16px;margin-bottom:24px}.friction-category{background:#fef2f2;border:1px solid #fca5a5;border-radius:8px;padding:16px}.friction-title{font-weight:600;font-size:15px;color:#991b1b;margin-bottom:6px}.friction-desc{font-size:13px;color:#7f1d1d;margin-bottom:10px}.friction-examples{margin:0 0 0 10px;padding:0;font-size:13px;color:#334155;list-style-type:disc}.friction-examples li{margin-bottom:4px}.qwen-md-section{background:#eff6ff;border:1px solid #bfdbfe;border-radius:8px;padding:12px;margin-bottom:20px}.qwen-md-section h3{font-size:13px;font-weight:600;color:#1e40af;margin:0 0 8px}.qwen-md-actions{margin-bottom:8px;padding-bottom:8px;border-bottom:1px solid #dbeafe}.copy-all-btn{background:#2563eb;color:#fff;border:none;border-radius:4px;padding:4px 10px;font-size:11px;cursor:pointer;font-weight:500;transition:all .2s}.copy-all-btn:hover{background:#1d4ed8}.copy-all-btn.copied{background:#16a34a}.qwen-md-item{display:flex;flex-wrap:wrap;align-items:flex-start;gap:8px;padding:8px 0;border-bottom:1px solid #dbeafe}.qwen-md-item:last-child{border-bottom:none}.cmd-checkbox{margin-top:2px}.cmd-code{background:#fff;padding:6px 10px;border-radius:4px;font-size:11px;color:#1e40af;border:1px solid #bfdbfe;font-family:monospace;display:block;white-space:pre-wrap;word-break:break-word;flex:1}.cmd-why{font-size:11px;color:#64748b;width:100%;padding-left:20px;margin-top:4px}.features-section,.patterns-section{display:flex;flex-direction:column;gap:12px;margin:16px 0}.feature-card{background:#f0fdf4;border:1px solid #86efac;border-radius:8px;padding:16px}.pattern-card{background:#f0f9ff;border:1px solid #7dd3fc;border-radius:8px;padding:16px}.feature-title,.pattern-title{font-weight:600;font-size:15px;color:#0f172a;margin-bottom:6px}.feature-oneliner,.pattern-summary{font-size:14px;color:#475569;margin-bottom:8px}.feature-why,.pattern-detail{font-size:13px;color:#334155;line-height:1.5}.feature-examples{margin-top:12px}.feature-example{padding:8px 0;border-top:1px solid #d1fae5}.feature-example:first-child{border-top:none}.example-code-row,.copyable-prompt-row{display:flex;align-items:flex-start;gap:8px}.example-code{flex:1;background:#f1f5f9;padding:8px 12px;border-radius:4px;font-family:monospace;font-size:12px;color:#334155;overflow-x:auto;white-space:pre-wrap}.copyable-prompt-section{margin-top:12px;padding-top:12px;border-top:1px solid #e2e8f0}.copyable-prompt{flex:1;background:#f8fafc;padding:10px 12px;border-radius:4px;font-family:monospace;font-size:12px;color:#334155;border:1px solid #e2e8f0;white-space:pre-wrap;line-height:1.5}.prompt-label{font-size:11px;font-weight:600;text-transform:uppercase;color:#64748b;margin-bottom:6px}.copy-btn{background:#e2e8f0;border:none;border-radius:4px;padding:4px 8px;font-size:11px;cursor:pointer;color:#475569;flex-shrink:0;transition:all .2s}.copy-btn:hover{background:#cbd5e1}.horizon-section{display:flex;flex-direction:column;gap:16px}.horizon-card{background:linear-gradient(135deg,#faf5ff,#f5f3ff);border:1px solid #c4b5fd;border-radius:8px;padding:16px}.horizon-title{font-weight:600;font-size:15px;color:#5b21b6;margin-bottom:8px}.horizon-possible{font-size:14px;color:#334155;margin-bottom:10px;line-height:1.5}.horizon-tip{font-size:13px;color:#6b21a8;background:#fff9;padding:8px 12px;border-radius:4px}.pattern-prompt{background:#f8fafc;padding:12px;border-radius:6px;margin-top:12px;border:1px solid #e2e8f0;display:flex;flex-direction:column;gap:8px}.pattern-prompt code{font-family:monospace;font-size:12px;color:#334155;display:block;white-space:pre-wrap}.fun-ending{background:linear-gradient(135deg,#fef3c7,#fde68a);border:1px solid #fbbf24;border-radius:12px;padding:24px;margin-top:40px;text-align:center}.fun-headline{font-size:18px;font-weight:600;color:#78350f;margin-bottom:8px}.fun-detail{font-size:14px;color:#92400e}.stats-row{display:flex;gap:24px;margin-bottom:40px;padding:20px 0;border-top:1px solid #e2e8f0;border-bottom:1px solid #e2e8f0;flex-wrap:wrap}.stat{text-align:center}.stat-value{font-size:24px;font-weight:700;color:#0f172a}.stat-label{font-size:11px;color:#64748b;text-transform:uppercase}@media (max-width: 640px){.stats-row{justify-content:center}}'; +export const INSIGHT_JS = "(function(e,k){\"use strict\";function z({data:t,dateRangeStr:l}){const{totalMessages:n,totalSessions:a}=t;return e.createElement(\"header\",{className:\"mb-8 space-y-3 text-center\"},e.createElement(\"h1\",{className:\"text-3xl font-semibold text-slate-900 md:text-4xl\"},\"Qwen Code Insights\"),e.createElement(\"p\",{className:\"text-sm text-slate-600\"},n?`${n} messages across ${a} sessions`:\"Your personalized coding journey and patterns\",l&&` | ${l}`))}function M({data:t}){const{totalMessages:l=0,totalLinesAdded:n=0,totalLinesRemoved:a=0,totalFiles:r=0}=t,i=Object.keys(t.heatmap||{});let s=0;if(i.length>0){const d=i.map(x=>new Date(x)).map(x=>x.getTime()),p=new Date(Math.min(...d)),g=new Date(Math.max(...d)),f=Math.abs(g.getTime()-p.getTime());s=Math.ceil(f/(1e3*60*60*24))+1}const c=s>0?Math.round(l/s):0;return e.createElement(\"div\",{className:\"stats-row\"},e.createElement(\"div\",{className:\"stat\"},e.createElement(\"div\",{className:\"stat-value\"},l),e.createElement(\"div\",{className:\"stat-label\"},\"Messages\")),e.createElement(\"div\",{className:\"stat\"},e.createElement(\"div\",{className:\"stat-value\"},\"+\",n,\"/-\",a),e.createElement(\"div\",{className:\"stat-label\"},\"Lines\")),e.createElement(\"div\",{className:\"stat\"},e.createElement(\"div\",{className:\"stat-value\"},r),e.createElement(\"div\",{className:\"stat-label\"},\"Files\")),e.createElement(\"div\",{className:\"stat\"},e.createElement(\"div\",{className:\"stat-value\"},s),e.createElement(\"div\",{className:\"stat-label\"},\"Days\")),e.createElement(\"div\",{className:\"stat\"},e.createElement(\"div\",{className:\"stat-value\"},c),e.createElement(\"div\",{className:\"stat-label\"},\"Msgs/Day\")))}function I({insights:t}){return e.createElement(\"div\",{className:\"grid gap-4 md:grid-cols-2 md:gap-6\"},e.createElement(O,{activeHours:t.activeHours,cardClass:\"glass-card p-6\",sectionTitleClass:\"text-lg font-semibold tracking-tight text-slate-900\"}))}function O({activeHours:t,cardClass:l,sectionTitleClass:n}){const r=[{label:\"Morning\",time:\"06:00 - 12:00\",hours:[6,7,8,9,10,11],color:\"#fbbf24\"},{label:\"Afternoon\",time:\"12:00 - 18:00\",hours:[12,13,14,15,16,17],color:\"#0ea5e9\"},{label:\"Evening\",time:\"18:00 - 00:00\",hours:[18,19,20,21,22,23],color:\"#6366f1\"},{label:\"Night\",time:\"00:00 - 06:00\",hours:[0,1,2,3,4,5],color:\"#475569\"}].map(s=>{const c=s.hours.reduce((o,d)=>o+(t[d]||0),0);return{...s,total:c}}),i=Math.max(...r.map(s=>s.total));return e.createElement(\"div\",{className:`${l} h-full flex flex-col min-h-[320px]`},e.createElement(\"div\",{className:\"flex items-center justify-between mb-4\"},e.createElement(\"h3\",{className:n},\"Active Hours\")),e.createElement(\"div\",{className:\"flex-1 flex flex-col justify-center gap-4\"},r.map(s=>e.createElement(\"div\",{key:s.label,className:\"space-y-2\"},e.createElement(\"div\",{className:\"flex justify-between items-center text-sm\"},e.createElement(\"div\",{className:\"flex items-center gap-2\"},e.createElement(\"span\",{className:\"rounded-full\",style:{width:\"12px\",height:\"12px\",backgroundColor:s.color}}),e.createElement(\"span\",{className:\"font-medium text-slate-700\"},s.label),e.createElement(\"span\",{className:\"text-xs text-slate-400 hidden xl:inline\"},s.time)),e.createElement(\"span\",{className:\"font-semibold text-slate-900\"},s.total)),e.createElement(\"div\",{className:\"w-full rounded-full overflow-hidden\",style:{height:\"12px\",backgroundColor:\"#e2e8f0\"}},e.createElement(\"div\",{className:\"h-full rounded-full\",style:{width:`${i>0?s.total/i*100:0}%`,backgroundColor:s.color}}))))))}function q({heatmap:t}){return e.createElement(\"div\",{className:\"glass-card p-6 mt-4 md:mt-6\"},e.createElement(\"div\",{className:\"flex items-center justify-between\"},e.createElement(\"h3\",{className:\"text-lg font-semibold tracking-tight text-slate-900\"},\"Activity Heatmap\"),e.createElement(\"span\",{className:\"text-xs font-semibold text-slate-500\"},\"Past year\")),e.createElement(\"div\",{className:\"heatmap-container\"},e.createElement(\"div\",{className:\"min-w-[720px] rounded-xl bg-white/70\"},e.createElement(j,{heatmapData:t}))))}function j({heatmapData:t}){const i=new Date,s=new Date(i);s.setFullYear(i.getFullYear()-1);const c=[],o=new Date(s);for(;o<=i;)c.push(new Date(o)),o.setDate(o.getDate()+1);const d=[0,2,4,10,20],p=[\"#e2e8f0\",\"#a5d8ff\",\"#74c0fc\",\"#339af0\",\"#1c7ed6\"];function g(E){if(E===0)return p[0];for(let u=d.length-1;u>=1;u--)if(E>=d[u])return p[u];return p[1]}const f=50,x=20,V=[\"Jan\",\"Feb\",\"Mar\",\"Apr\",\"May\",\"Jun\",\"Jul\",\"Aug\",\"Sep\",\"Oct\",\"Nov\",\"Dec\"],S=s.getDay(),T=[];let D=-1,W=-100;return c.forEach((E,u)=>{const v=u+S,C=Math.floor(v/7),y=f+C*16,N=E.getMonth();N!==D&&(y-W>30&&(T.push({x:y,text:V[N]}),W=y),D=N)}),e.createElement(\"svg\",{className:\"heatmap-svg\",width:1e3,height:150,viewBox:\"0 0 1000 150\"},c.map((E,u)=>{const v=u+S,C=Math.floor(v/7),y=E.getDay(),N=f+C*16,Z=x+y*16,w=E.toISOString().split(\"T\")[0],A=t[w]||0,R=g(A);return e.createElement(\"rect\",{key:w,className:\"heatmap-day\",x:N,y:Z,width:14,height:14,rx:\"2\",fill:R,\"data-date\":w,\"data-count\":A},e.createElement(\"title\",null,w,\": \",A,\" activities\"))}),T.map((E,u)=>e.createElement(\"text\",{key:u,x:E.x,y:\"15\",fontSize:\"12\",fill:\"#64748b\"},E.text)),e.createElement(\"text\",{x:f,y:110,fontSize:\"12\",fill:\"#64748b\"},\"Less\"),p.map((E,u)=>{const v=f+40+u*16;return e.createElement(\"rect\",{key:u,x:v,y:120,width:\"10\",height:\"10\",rx:\"2\",fill:E})}),e.createElement(\"text\",{x:f+40+p.length*16+5,y:129,fontSize:\"12\",fill:\"#64748b\",width:14},\"More\"))}function m({children:t}){if(!t||typeof t!=\"string\")return t;const l=t.split(/(\\*\\*.*?\\*\\*)/g);return e.createElement(e.Fragment,null,l.map((n,a)=>n.startsWith(\"**\")&&n.endsWith(\"**\")&&n.length>=4?e.createElement(\"strong\",{key:a},n.slice(2,-2)):n))}function b({text:t,label:l=\"Copy\"}){const[n,a]=e.useState(!1),r=()=>{navigator.clipboard.writeText(t).then(()=>{a(!0),setTimeout(()=>a(!1),2e3)})};return e.createElement(\"button\",{className:\"copy-btn\",onClick:r},n?\"Copied!\":l)}function F({qualitative:t}){const{atAGlance:l}=t;return l?e.createElement(\"div\",{className:\"at-a-glance\"},e.createElement(\"div\",{className:\"glance-title\"},\"At a Glance\"),e.createElement(\"div\",{className:\"glance-sections\"},e.createElement(\"div\",{className:\"glance-section\"},e.createElement(\"strong\",null,\"What's working:\"),\" \",e.createElement(m,null,l.whats_working),e.createElement(\"a\",{href:\"#section-wins\",className:\"see-more\"},\"Impressive Things You Did →\")),e.createElement(\"div\",{className:\"glance-section\"},e.createElement(\"strong\",null,\"What's hindering you:\"),\" \",e.createElement(m,null,l.whats_hindering),e.createElement(\"a\",{href:\"#section-friction\",className:\"see-more\"},\"Where Things Go Wrong →\")),e.createElement(\"div\",{className:\"glance-section\"},e.createElement(\"strong\",null,\"Quick wins to try:\"),\" \",e.createElement(m,null,l.quick_wins),e.createElement(\"a\",{href:\"#section-features\",className:\"see-more\"},\"Features to Try →\")),e.createElement(\"div\",{className:\"glance-section\"},e.createElement(\"strong\",null,\"Ambitious workflows:\"),\" \",e.createElement(m,null,l.ambitious_workflows),e.createElement(\"a\",{href:\"#section-horizon\",className:\"see-more\"},\"On the Horizon →\")))):null}function H(){return e.createElement(\"nav\",{className:\"nav-toc\"},e.createElement(\"a\",{href:\"#section-work\"},\"What You Work On\"),e.createElement(\"a\",{href:\"#section-usage\"},\"How You Use QC\"),e.createElement(\"a\",{href:\"#section-wins\"},\"Impressive Things\"),e.createElement(\"a\",{href:\"#section-friction\"},\"Where Things Go Wrong\"),e.createElement(\"a\",{href:\"#section-features\"},\"Features to Try\"),e.createElement(\"a\",{href:\"#section-patterns\"},\"New Usage Patterns\"),e.createElement(\"a\",{href:\"#section-horizon\"},\"On the Horizon\"))}function Q({qualitative:t,topGoals:l,topTools:n}){const{projectAreas:a}=t,r=Array.isArray(n)?Object.fromEntries(n):n;return e.createElement(e.Fragment,null,e.createElement(\"h2\",{id:\"section-work\",className:\"text-xl font-semibold text-slate-900 mt-8 mb-4\"},\"What You Work On\"),Array.isArray(a==null?void 0:a.areas)&&a.areas.length>0&&e.createElement(\"div\",{className:\"project-areas mb-6\"},a.areas.map((i,s)=>e.createElement(\"div\",{key:s,className:\"project-area\"},e.createElement(\"div\",{className:\"area-header\"},e.createElement(\"span\",{className:\"area-name\"},i.name),e.createElement(\"span\",{className:\"area-count\"},\"~\",i.session_count,\" sessions\")),e.createElement(\"div\",{className:\"area-desc\"},e.createElement(m,null,i.description))))),e.createElement(\"div\",{style:{display:\"grid\",gridTemplateColumns:\"repeat(2, 1fr)\",gap:\"24px\",marginBottom:\"24px\"}},l&&Object.keys(l).length>0&&e.createElement(h,{data:l,title:\"What You Wanted\",color:\"#0ea5e9\"}),r&&Object.keys(r).length>0&&e.createElement(h,{data:r,title:\"Top Tools Used\",color:\"#6366f1\"})))}function P({qualitative:t,insights:l}){const{interactionStyle:n}=t;return n?e.createElement(e.Fragment,null,e.createElement(\"h2\",{id:\"section-usage\",className:\"text-xl font-semibold text-slate-900 mt-8 mb-4\"},\"How You Use Qwen Code\"),e.createElement(\"div\",{className:\"narrative\"},e.createElement(\"p\",null,e.createElement(m,null,n.narrative)),n.key_pattern&&e.createElement(\"div\",{className:\"key-insight\"},e.createElement(\"strong\",null,\"Key pattern:\"),\" \",e.createElement(m,null,n.key_pattern))),e.createElement(I,{insights:l}),e.createElement(q,{heatmap:l.heatmap})):null}function $({qualitative:t,primarySuccess:l,outcomes:n}){const{impressiveWorkflows:a}=t;return a?e.createElement(e.Fragment,null,e.createElement(\"h2\",{id:\"section-wins\",className:\"text-xl font-semibold text-slate-900 mt-8 mb-4\"},\"Impressive Things You Did\"),a.intro&&e.createElement(\"p\",{className:\"section-intro\"},e.createElement(m,null,a.intro)),e.createElement(\"div\",{className:\"big-wins\"},Array.isArray(a.impressive_workflows)&&a.impressive_workflows.map((r,i)=>e.createElement(\"div\",{key:i,className:\"big-win\"},e.createElement(\"div\",{className:\"big-win-title\"},r.title),e.createElement(\"div\",{className:\"big-win-desc\"},e.createElement(m,null,r.description))))),e.createElement(\"div\",{style:{display:\"grid\",gridTemplateColumns:\"repeat(2, 1fr)\",gap:\"24px\",marginTop:\"24px\",marginBottom:\"24px\"}},l&&Object.keys(l).length>0&&e.createElement(h,{data:l,title:\"What Helped Most (Qwen's Capabilities)\",color:\"#3b82f6\",allowedKeys:[\"fast_accurate_search\",\"correct_code_edits\",\"good_explanations\",\"proactive_help\",\"multi_file_changes\",\"good_debugging\"]}),n&&Object.keys(n).length>0&&e.createElement(h,{data:n,title:\"Outcomes\",color:\"#8b5cf6\",allowedKeys:[\"fully_achieved\",\"mostly_achieved\",\"partially_achieved\",\"not_achieved\",\"unclear_from_transcript\"]}))):null}function B(t){return t===\"unclear_from_transcript\"?\"Unclear\":t.split(\"_\").map(l=>l.charAt(0).toUpperCase()+l.slice(1)).join(\" \")}function h({data:t,title:l,color:n=\"#3b82f6\",allowedKeys:a=null}){if(!t||Object.keys(t).length===0)return null;let r=Object.entries(t);if(a&&(r=r.filter(([s])=>a.includes(s))),r.sort((s,c)=>c[1]-s[1]),r.length===0)return null;const i=Math.max(...r.map(([,s])=>s));return e.createElement(\"div\",{className:\"bar-chart-card\",style:{flex:1,minWidth:0,backgroundColor:\"#ffffff\",borderRadius:\"12px\",padding:\"20px\",boxShadow:\"0 1px 3px rgba(0, 0, 0, 0.08)\",border:\"1px solid #e2e8f0\"}},e.createElement(\"h3\",{style:{fontSize:\"13px\",fontWeight:700,color:\"#64748b\",marginTop:0,marginBottom:\"16px\",textTransform:\"uppercase\",letterSpacing:\"0.5px\"}},l),e.createElement(\"div\",{className:\"bar-chart\",style:{display:\"flex\",flexDirection:\"column\",gap:\"10px\"}},r.map(([s,c])=>{const o=i>0?c/i*100:0;return e.createElement(\"div\",{key:s,className:\"bar-row\",style:{display:\"flex\",alignItems:\"center\",gap:\"12px\"}},e.createElement(\"div\",{className:\"bar-label\",style:{width:\"130px\",fontSize:\"13px\",color:\"#475569\",textAlign:\"left\",flexShrink:0,whiteSpace:\"nowrap\",overflow:\"hidden\",textOverflow:\"ellipsis\"}},B(s)),e.createElement(\"div\",{className:\"bar-wrapper\",style:{flex:1,display:\"flex\",alignItems:\"center\",gap:\"10px\",minWidth:0}},e.createElement(\"div\",{className:\"bar-bg\",style:{flex:1,height:\"8px\",backgroundColor:\"#f1f5f9\",borderRadius:\"4px\",overflow:\"hidden\"}},e.createElement(\"div\",{className:\"bar-fill\",style:{width:`${o}%`,height:\"100%\",backgroundColor:n,borderRadius:\"4px\",transition:\"width 0.3s ease\"}})),e.createElement(\"span\",{className:\"bar-value\",style:{fontSize:\"13px\",fontWeight:600,color:\"#475569\",minWidth:\"24px\",textAlign:\"right\"}},c)))})))}function Y({qualitative:t,satisfaction:l,friction:n}){const{frictionPoints:a}=t;return a?e.createElement(e.Fragment,null,e.createElement(\"h2\",{id:\"section-friction\",className:\"text-xl font-semibold text-slate-900 mt-8 mb-4\"},\"Where Things Go Wrong\"),a.intro&&e.createElement(\"p\",{className:\"section-intro\"},e.createElement(m,null,a.intro)),e.createElement(\"div\",{className:\"friction-categories\"},Array.isArray(a.categories)&&a.categories.map((r,i)=>e.createElement(\"div\",{key:i,className:\"friction-category\"},e.createElement(\"div\",{className:\"friction-title\"},r.category),e.createElement(\"div\",{className:\"friction-desc\"},e.createElement(m,null,r.description)),Array.isArray(r.examples)&&r.examples.length>0&&e.createElement(\"ul\",{className:\"friction-examples\"},r.examples.map((s,c)=>e.createElement(\"li\",{key:c},e.createElement(m,null,s))))))),e.createElement(\"div\",{style:{display:\"grid\",gridTemplateColumns:\"repeat(2, 1fr)\",gap:\"24px\",marginTop:\"24px\",marginBottom:\"24px\"}},n&&Object.keys(n).length>0&&e.createElement(h,{data:n,title:\"Primary Friction Types\",color:\"#ef4444\",allowedKeys:[\"misunderstood_request\",\"wrong_approach\",\"buggy_code\",\"user_rejected_action\",\"excessive_changes\"]}),l&&Object.keys(l).length>0&&e.createElement(h,{data:l,title:\"Inferred Satisfaction (model-estimated)\",color:\"#10b981\",allowedKeys:[\"happy\",\"satisfied\",\"likely_satisfied\",\"dissatisfied\",\"frustrated\"]}))):null}function G({additions:t}){const[l,n]=e.useState(new Array(t.length).fill(!0)),[a,r]=e.useState(!1),i=o=>{const d=l.map((p,g)=>g===o?!p:p);n(d)},s=()=>{const o=t.filter((d,p)=>l[p]).map(d=>d.addition).join(`\n\n`);o&&navigator.clipboard.writeText(o).then(()=>{r(!0),setTimeout(()=>r(!1),2e3)})},c=l.filter(Boolean).length;return e.createElement(\"div\",{className:\"qwen-md-section\"},e.createElement(\"h3\",null,\"Suggested QWEN.md Additions\"),e.createElement(\"p\",{className:\"text-xs text-slate-500 mb-3\"},\"Just copy this into Qwen Code to add it to your QWEN.md.\"),e.createElement(\"div\",{className:\"qwen-md-actions\",style:{marginBottom:\"12px\"}},e.createElement(\"button\",{className:`copy-all-btn ${a?\"copied\":\"\"}`,onClick:s,disabled:c===0},a?\"Copied All!\":`Copy All Checked (${c})`)),t.map((o,d)=>e.createElement(\"div\",{key:d,className:\"qwen-md-item\"},e.createElement(\"input\",{type:\"checkbox\",checked:l[d],onChange:()=>i(d),className:\"cmd-checkbox\"}),e.createElement(\"div\",{style:{flex:1}},e.createElement(\"code\",{className:\"cmd-code\"},o.addition),e.createElement(\"div\",{className:\"cmd-why\"},e.createElement(m,null,o.why))),e.createElement(b,{text:o.addition}))))}function L({qualitative:t}){const{improvements:l}=t;return l?e.createElement(e.Fragment,null,e.createElement(\"h2\",{id:\"section-features\",className:\"text-xl font-semibold text-slate-900 mt-8 mb-4\"},\"Existing QC Features to Try\"),Array.isArray(l.Qwen_md_additions)&&l.Qwen_md_additions.length>0&&e.createElement(G,{additions:l.Qwen_md_additions}),e.createElement(\"p\",{className:\"text-xs text-slate-500 mb-3\"},\"Just copy this into Qwen Code and it'll set it up for you.\"),e.createElement(\"div\",{className:\"features-section\"},Array.isArray(l.features_to_try)&&l.features_to_try.map((n,a)=>e.createElement(\"div\",{key:a,className:\"feature-card\"},e.createElement(\"div\",{className:\"feature-title\"},n.feature),e.createElement(\"div\",{className:\"feature-oneliner\"},e.createElement(m,null,n.one_liner)),e.createElement(\"div\",{className:\"feature-why\"},e.createElement(\"strong\",null,\"Why for you:\"),\" \",e.createElement(m,null,n.why_for_you)),e.createElement(\"div\",{className:\"feature-examples\"},e.createElement(\"div\",{className:\"feature-example\"},e.createElement(\"div\",{className:\"example-code-row\"},e.createElement(\"code\",{className:\"example-code\"},n.example_code),e.createElement(b,{text:n.example_code}))))))),e.createElement(\"h2\",{id:\"section-patterns\",className:\"text-xl font-semibold text-slate-900 mt-8 mb-4\"},\"New Ways to Use Qwen Code\"),e.createElement(\"p\",{className:\"text-xs text-slate-500 mb-3\"},\"Just copy this into Qwen Code and it'll walk you through it.\"),e.createElement(\"div\",{className:\"patterns-section\"},Array.isArray(l.usage_patterns)&&l.usage_patterns.map((n,a)=>e.createElement(\"div\",{key:a,className:\"pattern-card\"},e.createElement(\"div\",{className:\"pattern-title\"},n.title),e.createElement(\"div\",{className:\"pattern-summary\"},e.createElement(m,null,n.suggestion)),e.createElement(\"div\",{className:\"pattern-detail\"},e.createElement(m,null,n.detail)),e.createElement(\"div\",{className:\"copyable-prompt-section\"},e.createElement(\"div\",{className:\"prompt-label\"},\"Paste into Qwen Code:\"),e.createElement(\"div\",{className:\"copyable-prompt-row\"},e.createElement(\"code\",{className:\"copyable-prompt\"},n.copyable_prompt),e.createElement(b,{text:n.copyable_prompt}))))))):null}function U({qualitative:t}){const{futureOpportunities:l}=t;return l?e.createElement(e.Fragment,null,e.createElement(\"h2\",{id:\"section-horizon\",className:\"text-xl font-semibold text-slate-900 mt-8 mb-4\"},\"On the Horizon\"),l.intro&&e.createElement(\"p\",{className:\"section-intro\"},e.createElement(m,null,l.intro)),e.createElement(\"div\",{className:\"horizon-section\"},Array.isArray(l.opportunities)&&l.opportunities.map((n,a)=>e.createElement(\"div\",{key:a,className:\"horizon-card\"},e.createElement(\"div\",{className:\"horizon-title\"},n.title),e.createElement(\"div\",{className:\"horizon-possible\"},e.createElement(m,null,n.whats_possible)),e.createElement(\"div\",{className:\"horizon-tip\"},e.createElement(\"strong\",null,\"Getting started:\"),\" \",e.createElement(m,null,n.how_to_try)),e.createElement(\"div\",{className:\"pattern-prompt\"},e.createElement(\"div\",{className:\"prompt-label\"},\"Paste into Qwen Code:\"),e.createElement(\"div\",{style:{display:\"flex\",alignItems:\"flex-start\",gap:\"8px\"}},e.createElement(\"code\",{style:{flex:1}},n.copyable_prompt),e.createElement(b,{text:n.copyable_prompt}))))))):null}function K({qualitative:t}){const{memorableMoment:l}=t;return l?e.createElement(\"div\",{className:\"fun-ending\"},e.createElement(\"div\",{className:\"fun-headline\"},'\"',l.headline,'\"'),e.createElement(\"div\",{className:\"fun-detail\"},e.createElement(m,null,l.detail))):null}function J({data:t}){if(!t)return e.createElement(\"div\",{className:\"text-center text-slate-600\"},\"No insight data available\");const l=Object.keys(t.heatmap||{});let n=\"\";if(l.length>0){const r=l.map(o=>new Date(o)).map(o=>o.getTime()),i=new Date(Math.min(...r)),s=new Date(Math.max(...r)),c=o=>o.toISOString().split(\"T\")[0];n=`${c(i)} to ${c(s)}`}return e.createElement(\"div\",null,e.createElement(z,{data:t,dateRangeStr:n}),t.qualitative&&e.createElement(e.Fragment,null,e.createElement(F,{qualitative:t.qualitative}),e.createElement(H,null)),e.createElement(M,{data:t}),t.qualitative&&e.createElement(e.Fragment,null,e.createElement(Q,{qualitative:t.qualitative,topGoals:t.topGoals,topTools:t.topTools})),t.qualitative&&e.createElement(e.Fragment,null,e.createElement(P,{qualitative:t.qualitative,insights:t})),t.qualitative&&e.createElement(e.Fragment,null,e.createElement($,{qualitative:t.qualitative,primarySuccess:t.primarySuccess,outcomes:t.outcomes}),e.createElement(Y,{qualitative:t.qualitative,satisfaction:t.satisfaction,friction:t.friction}),e.createElement(L,{qualitative:t.qualitative}),e.createElement(U,{qualitative:t.qualitative}),e.createElement(K,{qualitative:t.qualitative})),e.createElement(X,null))}function X(){const[t,l]=e.useState(!1),n=async()=>{const a=document.getElementById(\"container\");if(!a||!window.html2canvas){alert(\"Export functionality is not available.\");return}l(!0);try{const i=(await window.html2canvas(a,{scale:2,useCORS:!0,logging:!1})).toDataURL(\"image/png\"),s=document.createElement(\"a\");s.href=i,s.download=`qwen-insights-${new Date().toISOString().slice(0,10)}.png`,s.click()}catch(r){console.error(\"Export error:\",r),alert(\"Failed to export image. Please try again.\")}finally{l(!1)}};return e.createElement(\"div\",{className:\"mt-6 flex justify-center\"},e.createElement(\"button\",{onClick:n,disabled:t,className:\"group inline-flex items-center gap-2 rounded-full bg-slate-900 px-5 py-3 text-sm font-semibold text-white shadow-soft transition focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-slate-400 hover:-translate-y-[1px] hover:shadow-lg active:translate-y-[1px] disabled:opacity-50\"},t?\"Exporting...\":\"Export as Image\",e.createElement(\"span\",{className:\"text-slate-200 transition group-hover:translate-x-0.5\"},\"→\")))}const _=document.getElementById(\"react-root\");_&&window.INSIGHT_DATA&&k?k.createRoot(_).render(e.createElement(J,{data:window.INSIGHT_DATA})):console.error(\"Failed to mount React app:\",{container:!!_,data:!!window.INSIGHT_DATA,ReactDOM:!!k})})(React,ReactDOM);"; +export const INSIGHT_CSS = "*,:before,:after,::backdrop{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: #3b82f680;--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }*,:before,:after{box-sizing:border-box;border:0 solid #e5e7eb}:before,:after{--tw-content: \"\"}html,:host{-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;font-feature-settings:normal;font-variation-settings:normal;-webkit-tap-highlight-color:transparent;font-family:ui-sans-serif,system-ui,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\",Segoe UI Symbol,\"Noto Color Emoji\";line-height:1.5}body{line-height:inherit;margin:0;background-image:linear-gradient(to bottom right,var(--tw-gradient-stops));--tw-gradient-from: #f8fafc var(--tw-gradient-from-position);--tw-gradient-to: #f1f5f9 var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), #fff var(--tw-gradient-via-position), var(--tw-gradient-to);--tw-text-opacity: 1;min-height:100vh;color:rgb(15 23 42 / var(--tw-text-opacity, 1));-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.glass-card{--tw-border-opacity: 1;border-width:1px;border-color:rgb(226 232 240 / var(--tw-border-opacity, 1));--tw-shadow: 0 10px 40px #0f172a14;--tw-shadow-colored: 0 10px 40px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow);--tw-backdrop-blur: blur(8px);backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);background-color:#fff9;border-radius:1rem}.col-span-2{grid-column:span 2 / span 2}.mx-auto{margin-left:auto;margin-right:auto}.mb-8{margin-bottom:2rem}.ml-2{margin-left:.5rem}.mt-1{margin-top:.25rem}.mt-2{margin-top:.5rem}.mt-4{margin-top:1rem}.mt-6{margin-top:1.5rem}.block{display:block}.flex{display:flex}.inline-flex{display:inline-flex}.grid{display:grid}.h-56{height:14rem}.h-full{height:100%}.min-h-screen{min-height:100vh}.w-full{width:100%}.min-w-\\[720px\\]{min-width:720px}.max-w-6xl{max-width:72rem}.grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}.flex-col{flex-direction:column}.items-start{align-items:flex-start}.items-center{align-items:center}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.gap-1{gap:.25rem}.gap-2{gap:.5rem}.gap-3{gap:.75rem}.gap-4{gap:1rem}.space-y-3>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.75rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.75rem * var(--tw-space-y-reverse))}.space-y-4>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(1rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(1rem * var(--tw-space-y-reverse))}.divide-y>:not([hidden])~:not([hidden]){--tw-divide-y-reverse: 0;border-top-width:calc(1px * calc(1 - var(--tw-divide-y-reverse)));border-bottom-width:calc(1px * var(--tw-divide-y-reverse))}.divide-slate-200>:not([hidden])~:not([hidden]){--tw-divide-opacity: 1;border-color:rgb(226 232 240 / var(--tw-divide-opacity, 1))}.overflow-x-auto{overflow-x:auto}.rounded-full{border-radius:9999px}.rounded-xl{border-radius:1.25rem}.border{border-width:1px}.border-slate-100{--tw-border-opacity: 1;border-color:rgb(241 245 249 / var(--tw-border-opacity, 1))}.bg-emerald-50{--tw-bg-opacity: 1;background-color:rgb(236 253 245 / var(--tw-bg-opacity, 1))}.bg-slate-100{--tw-bg-opacity: 1;background-color:rgb(241 245 249 / var(--tw-bg-opacity, 1))}.bg-slate-50{--tw-bg-opacity: 1;background-color:rgb(248 250 252 / var(--tw-bg-opacity, 1))}.bg-slate-900{--tw-bg-opacity: 1;background-color:rgb(15 23 42 / var(--tw-bg-opacity, 1))}.bg-white\\/70{background-color:#ffffff73}.bg-gradient-to-br{background-image:linear-gradient(to bottom right,var(--tw-gradient-stops))}.from-slate-50{--tw-gradient-from: #f8fafc var(--tw-gradient-from-position);--tw-gradient-to: #f8fafc00 var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to)}.via-white{--tw-gradient-to: #ffffff00 var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), #ffffff var(--tw-gradient-via-position), var(--tw-gradient-to)}.to-slate-100{--tw-gradient-to: #f1f5f9 var(--tw-gradient-to-position)}.p-4{padding:1rem}.p-6{padding:1.5rem}.px-3{padding-left:.75rem;padding-right:.75rem}.px-4{padding-left:1rem;padding-right:1rem}.px-5{padding-left:1.25rem;padding-right:1.25rem}.px-6{padding-left:1.5rem;padding-right:1.5rem}.px-8{padding-left:2rem;padding-right:2rem}.py-1{padding-top:.25rem;padding-bottom:.25rem}.py-10{padding-top:2.5rem;padding-bottom:2.5rem}.py-2{padding-top:.5rem;padding-bottom:.5rem}.py-3{padding-top:.75rem;padding-bottom:.75rem}.py-6{padding-top:1.5rem;padding-bottom:1.5rem}.text-left{text-align:left}.text-center{text-align:center}.text-2xl{font-size:1.5rem;line-height:2rem}.text-3xl{font-size:1.875rem;line-height:2.25rem}.text-4xl{font-size:2.25rem;line-height:2.5rem}.text-base{font-size:1rem;line-height:1.5rem}.text-lg{font-size:1.125rem;line-height:1.75rem}.text-sm{font-size:.875rem;line-height:1.25rem}.text-xl{font-size:1.25rem;line-height:1.75rem}.text-xs{font-size:.75rem;line-height:1rem}.font-bold{font-weight:700}.font-medium{font-weight:500}.font-semibold{font-weight:600}.uppercase{text-transform:uppercase}.tracking-\\[0\\.2em\\]{letter-spacing:.2em}.tracking-tight{letter-spacing:-.025em}.tracking-wide{letter-spacing:.025em}.text-emerald-700{--tw-text-opacity: 1;color:rgb(4 120 87 / var(--tw-text-opacity, 1))}.text-rose-700{--tw-text-opacity: 1;color:rgb(190 18 60 / var(--tw-text-opacity, 1))}.text-slate-200{--tw-text-opacity: 1;color:rgb(226 232 240 / var(--tw-text-opacity, 1))}.text-slate-400{--tw-text-opacity: 1;color:rgb(148 163 184 / var(--tw-text-opacity, 1))}.text-slate-500{--tw-text-opacity: 1;color:rgb(100 116 139 / var(--tw-text-opacity, 1))}.text-slate-600{--tw-text-opacity: 1;color:rgb(71 85 105 / var(--tw-text-opacity, 1))}.text-slate-700{--tw-text-opacity: 1;color:rgb(51 65 85 / var(--tw-text-opacity, 1))}.text-slate-900{--tw-text-opacity: 1;color:rgb(15 23 42 / var(--tw-text-opacity, 1))}.text-white{--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity, 1))}.shadow-inner{--tw-shadow: inset 0 2px 4px 0 #0000000d;--tw-shadow-colored: inset 0 2px 4px 0 var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-soft{--tw-shadow: 0 10px 40px #0f172a14;--tw-shadow-colored: 0 10px 40px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-slate-100{--tw-shadow-color: #f1f5f9;--tw-shadow: var(--tw-shadow-colored)}.transition{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-duration:.15s;transition-timing-function:cubic-bezier(.4,0,.2,1)}.hover\\:-translate-y-\\[1px\\]:hover{--tw-translate-y: -1px;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.hover\\:shadow-lg:hover{--tw-shadow: 0 10px 15px -3px #0000001a, 0 4px 6px -4px #0000001a;--tw-shadow-colored: 0 10px 15px -3px var(--tw-shadow-color), 0 4px 6px -4px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.focus-visible\\:outline:focus-visible{outline-style:solid}.focus-visible\\:outline-2:focus-visible{outline-width:2px}.focus-visible\\:outline-offset-2:focus-visible{outline-offset:2px}.focus-visible\\:outline-slate-400:focus-visible{outline-color:#94a3b8}.active\\:translate-y-\\[1px\\]:active{--tw-translate-y: 1px;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.group:hover .group-hover\\:translate-x-0\\.5{--tw-translate-x: .125rem;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}@media (min-width: 768px){.md\\:mt-6{margin-top:1.5rem}.md\\:grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}.md\\:gap-6{gap:1.5rem}.md\\:py-12{padding-top:3rem;padding-bottom:3rem}.md\\:text-4xl{font-size:2.25rem;line-height:2.5rem}}.heatmap-container{width:100%;overflow-x:auto}.heatmap-svg{min-width:720px}.heatmap-day{cursor:pointer}.heatmap-day:hover{stroke:#00000024;stroke-width:1px}.heatmap-legend{display:flex;align-items:center;gap:4px;font-size:12px;color:#64748b;margin-top:8px}.heatmap-legend-item{width:10px;height:10px;border-radius:2px}.nav-toc{display:flex;flex-wrap:wrap;gap:8px;margin:24px 0 32px;padding:16px;background:#fff;border-radius:8px;border:1px solid #e2e8f0}.nav-toc a{font-size:12px;color:#64748b;text-decoration:none;padding:6px 12px;border-radius:6px;background:#f1f5f9;transition:all .15s}.nav-toc a:hover{background:#e2e8f0;color:#334155}.at-a-glance{background:linear-gradient(135deg,#fef3c7,#fde68a);border:1px solid #f59e0b;border-radius:12px;padding:20px 24px;margin-bottom:32px}.glance-title{font-size:16px;font-weight:700;color:#92400e;margin-bottom:16px}.glance-sections{display:flex;flex-direction:column;gap:12px}.glance-section{font-size:14px;color:#78350f;line-height:1.6}.glance-section strong{color:#92400e;font-weight:700}.see-more{color:#b45309;text-decoration:none;font-size:13px;white-space:nowrap;margin-left:4px}.see-more:hover{text-decoration:underline}.project-areas{display:flex;flex-direction:column;gap:12px;margin-bottom:32px}.project-area{background:#fff;border:1px solid #e2e8f0;border-radius:8px;padding:16px}.area-header{display:flex;justify-content:space-between;align-items:center;margin-bottom:8px}.area-name{font-weight:600;font-size:15px;color:#0f172a}.area-count{font-size:12px;color:#64748b;background:#f1f5f9;padding:2px 8px;border-radius:4px}.area-desc{font-size:14px;color:#475569;line-height:1.5}.narrative{background:#fff;border:1px solid #e2e8f0;border-radius:8px;padding:20px;margin-bottom:24px}.narrative p{margin-top:0;margin-bottom:12px;font-size:14px;color:#475569;line-height:1.7}.key-insight{background:#f0fdf4;border:1px solid #bbf7d0;border-radius:8px;padding:12px 16px;margin-top:12px;font-size:14px;color:#166534}.section-intro{font-size:14px;color:#64748b;margin-bottom:16px}.big-wins{display:flex;flex-direction:column;gap:12px;margin-bottom:24px}.big-win{background:#f0fdf4;border:1px solid #bbf7d0;border-radius:8px;padding:16px}.big-win-title{font-weight:600;font-size:15px;color:#166534;margin-bottom:8px}.big-win-desc{font-size:14px;color:#15803d;line-height:1.5}.friction-categories{display:flex;flex-direction:column;gap:16px;margin-bottom:24px}.friction-category{background:#fef2f2;border:1px solid #fca5a5;border-radius:8px;padding:16px}.friction-title{font-weight:600;font-size:15px;color:#991b1b;margin-bottom:6px}.friction-desc{font-size:13px;color:#7f1d1d;margin-bottom:10px}.friction-examples{margin:0 0 0 10px;padding:0;font-size:13px;color:#334155;list-style-type:disc}.friction-examples li{margin-bottom:4px}.qwen-md-section{background:#eff6ff;border:1px solid #bfdbfe;border-radius:8px;padding:12px;margin-bottom:20px}.qwen-md-section h3{font-size:13px;font-weight:600;color:#1e40af;margin:0 0 8px}.qwen-md-actions{margin-bottom:8px;padding-bottom:8px;border-bottom:1px solid #dbeafe}.copy-all-btn{background:#2563eb;color:#fff;border:none;border-radius:4px;padding:4px 10px;font-size:11px;cursor:pointer;font-weight:500;transition:all .2s}.copy-all-btn:hover{background:#1d4ed8}.copy-all-btn.copied{background:#16a34a}.qwen-md-item{display:flex;flex-wrap:wrap;align-items:flex-start;gap:8px;padding:8px 0;border-bottom:1px solid #dbeafe}.qwen-md-item:last-child{border-bottom:none}.cmd-checkbox{margin-top:2px}.cmd-code{background:#fff;padding:6px 10px;border-radius:4px;font-size:11px;color:#1e40af;border:1px solid #bfdbfe;font-family:monospace;display:block;white-space:pre-wrap;word-break:break-word;flex:1}.cmd-why{font-size:11px;color:#64748b;width:100%;padding-left:20px;margin-top:4px}.features-section,.patterns-section{display:flex;flex-direction:column;gap:12px;margin:16px 0}.feature-card{background:#f0fdf4;border:1px solid #86efac;border-radius:8px;padding:16px}.pattern-card{background:#f0f9ff;border:1px solid #7dd3fc;border-radius:8px;padding:16px}.feature-title,.pattern-title{font-weight:600;font-size:15px;color:#0f172a;margin-bottom:6px}.feature-oneliner,.pattern-summary{font-size:14px;color:#475569;margin-bottom:8px}.feature-why,.pattern-detail{font-size:13px;color:#334155;line-height:1.5}.feature-examples{margin-top:12px}.feature-example{padding:8px 0;border-top:1px solid #d1fae5}.feature-example:first-child{border-top:none}.example-code-row,.copyable-prompt-row{display:flex;align-items:flex-start;gap:8px}.example-code{flex:1;background:#f1f5f9;padding:8px 12px;border-radius:4px;font-family:monospace;font-size:12px;color:#334155;overflow-x:auto;white-space:pre-wrap}.copyable-prompt-section{margin-top:12px;padding-top:12px;border-top:1px solid #e2e8f0}.copyable-prompt{flex:1;background:#f8fafc;padding:10px 12px;border-radius:4px;font-family:monospace;font-size:12px;color:#334155;border:1px solid #e2e8f0;white-space:pre-wrap;line-height:1.5}.prompt-label{font-size:11px;font-weight:600;text-transform:uppercase;color:#64748b;margin-bottom:6px}.copy-btn{background:#e2e8f0;border:none;border-radius:4px;padding:4px 8px;font-size:11px;cursor:pointer;color:#475569;flex-shrink:0;transition:all .2s}.copy-btn:hover{background:#cbd5e1}.horizon-section{display:flex;flex-direction:column;gap:16px}.horizon-card{background:linear-gradient(135deg,#faf5ff,#f5f3ff);border:1px solid #c4b5fd;border-radius:8px;padding:16px}.horizon-title{font-weight:600;font-size:15px;color:#5b21b6;margin-bottom:8px}.horizon-possible{font-size:14px;color:#334155;margin-bottom:10px;line-height:1.5}.horizon-tip{font-size:13px;color:#6b21a8;background:#fff9;padding:8px 12px;border-radius:4px}.pattern-prompt{background:#f8fafc;padding:12px;border-radius:6px;margin-top:12px;border:1px solid #e2e8f0;display:flex;flex-direction:column;gap:8px}.pattern-prompt code{font-family:monospace;font-size:12px;color:#334155;display:block;white-space:pre-wrap}.fun-ending{background:linear-gradient(135deg,#fef3c7,#fde68a);border:1px solid #fbbf24;border-radius:12px;padding:24px;margin-top:40px;text-align:center}.fun-headline{font-size:18px;font-weight:600;color:#78350f;margin-bottom:8px}.fun-detail{font-size:14px;color:#92400e}.stats-row{display:flex;gap:24px;margin-bottom:40px;padding:20px 0;border-top:1px solid #e2e8f0;border-bottom:1px solid #e2e8f0;flex-wrap:wrap}.stat{text-align:center}.stat-value{font-size:24px;font-weight:700;color:#0f172a}.stat-label{font-size:11px;color:#64748b;text-transform:uppercase}@media (max-width: 640px){.stats-row{justify-content:center}}";