import{o as s}from"./rolldown-runtime-iuO8RvI4.js";import{Tu as a}from"./shared-0-C4kdVF7Y.js";import{Mi as e,ki as t}from"./vendor-frame-CwiylG4Y.js";import{Jp as r,Xl as n,k as o,nl as i}from"./shared-1-3-6x7RKF.js";import{nn as l,rn as d}from"./vendor-all-2-BJdkbLSj.js";import{$ as m,R as c}from"./shared-frame-DbQbH4Yr.js";import{al as h,ks as f,wa as x}from"./shared-4-6CEyRAHb.js";import{Tt as j}from"./shared-7-VxUxSmVa.js";var u=s(e()),p=t(),v=(0,u.memo)(({saffronSearchEnabled:s,onDismiss:a,onStartNewChat:e,onNever:t})=>{const r=d();return(0,p.jsx)(x,{variant:"neutral",icon:(0,p.jsx)(m,{name:"ChatAdd",size:"md"}),className:"w-full mb-3 !items-start",children:(0,p.jsxs)("div",{className:"flex w-full items-start justify-between gap-4",children:[(0,p.jsxs)("div",{className:"flex min-w-0 flex-col gap-0.5",children:[(0,p.jsx)("div",{className:"font-bold",children:(0,p.jsx)(l,{defaultMessage:"Longer chats draw down your usage faster",id:"+qUX/WZTjT"})}),(0,p.jsx)("div",{className:"text-text-300",children:s?(0,p.jsx)(l,{defaultMessage:"Claude can search past conversations, so you won\u2019t lose the thread.",id:"TWDnT/16To"}):(0,p.jsx)(l,{defaultMessage:"You can ask Claude to summarize this conversation first, then paste into a new one.",id:"cmzXoKdwPd"})})]}),(0,p.jsxs)("div",{className:"flex shrink-0 flex-col items-end gap-2",children:[(0,p.jsxs)("div",{className:"flex gap-2",children:[(0,p.jsx)(c,{variant:"secondary",onClick:a,children:r.formatMessage({defaultMessage:"Not now",id:"dUCA4Khx0S"})}),(0,p.jsx)(c,{variant:"primary",onClick:e,children:r.formatMessage({defaultMessage:"Start new chat",id:"KcA+xo4hhh"})})]}),(0,p.jsx)(h,{onClick:t,className:"text-xs text-text-400",children:(0,p.jsx)(l,{defaultMessage:"Don\u2019t show again",id:"MWjOMpKsd7"})})]})]})})}),w=(0,u.memo)(({enabled:s,onDismiss:e,onAction:t})=>{const l=a(),d=i(),m=r(),{dismiss:c}=n(),{conversation:h}=f(),x=o(s=>h?.id?s.pathUuidsByConversation[h.id]?.length??0:0),w=(0,u.useCallback)(()=>{t({action:"start_new_chat"}),l.push(d?`/project/${d}`:"/new")},[t,d,l]),g=(0,u.useCallback)(()=>{c(j),e()},[c,e]);return!s||x<50?null:(0,p.jsx)(v,{saffronSearchEnabled:m,onDismiss:e,onStartNewChat:w,onNever:g})});export{w as LongConversationChatBanner};