Conversation
以三列剧本演示替换编辑式长文首页:五类场景六套预设剧本复刻 /thread-chat 的分支、来源高亮、树导航与 @artifact 回流交互, 演示为纯前端内容,不调用模型、不写用户数据。移除首页 GitHub 链接,保留真实开始使用入口与法律链接。另修复 lib/axiom server.ts 的 prefer-const 使 lint 零 error。 Generated with [Devin](https://devin.ai) Co-Authored-By: Devin <158243242+devin-ai-integration[bot]@users.noreply.github.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars. ⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Advanced Run ID: Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
- 剧本改为三段式:逐字划选 → 深色提问气泡内打字 → 提交后才开列、
出下划线与脚注
- 列头对齐真实 /thread-chat:主线「锚定+主线+子树计数」,分支列
「面包屑+L{n}+标题+子树/⇄切换/收起」三按钮;收起真实关列,切换在
兄弟分支间轮换,子树按钮导航到子分支
- 场景标签改为居中分段式大 Tabs;演示窗口加高(clamp 620–820px)
Generated with [Devin](https://devin.ai)
Co-Authored-By: Devin <158243242+devin-ai-integration[bot]@users.noreply.github.com>
- 锚点未划选前是纯文本(无下划线/底色);划选中 .sel 前缀带下划线 逐字推进,提交后才定住并加脚注 - .sel 末尾插零宽标记 selend,划选章光标目标跟随选区末尾,呈现 拖选效果;划选减速到 1 字/40ms 让过程可见 - 划选气泡改在 .ld 根级渲染(z-index 45),setInterval 实测锚点 坐标跟随;脱离列 overflow 裁剪与层叠,列滑入/相邻列不再盖住 (此前用 rAF 在页面不可见时被节流导致整章不渲染) Generated with [Devin](https://devin.ai) Co-Authored-By: Devin <158243242+devin-ai-integration[bot]@users.noreply.github.com>
- 锚点未提交前是纯文本(参与正常划选);提交后才可点击, 点击只定位/恢复对应分支列,不再弹提问气泡 - 剧本划选改为拖蓝选区(.sel 与 ::selection 同色), 提交步去掉 selecting:点提交瞬间气泡关闭、锚点落定下划线 - 提交后 thread 列延迟 ~1.4s 出现(OPEN_DELAY_MS), 延迟期间不推进章节、不预滚动;减少动态偏好下立即出现 - 提问气泡输入框改为真实 textarea:可 focus(border 高亮)、 可改写;改写后提交开出用户自己的分支列 - 演示界面支持真实文本划选:拖选任意消息文本 → 弹气泡 → 输入任意问题 → 延迟开出手动分支列(引用原句 + 本地示例回答), 列插在父列右侧,子树/切换/收起按钮同样可用 Generated with [Devin](https://devin.ai) Co-Authored-By: Devin <158243242+devin-ai-integration[bot]@users.noreply.github.com>
六套场景的全部 AI 回复从 3~4 段扩到 5~7 段,补充分层结构、 具体例子、边界取舍和反向注意事项,更接近真实回答的信息密度; 锚点位置不变,手动分支的本地示例回答同步加长。 Generated with [Devin](https://devin.ai) Co-Authored-By: Devin <158243242+devin-ai-integration[bot]@users.noreply.github.com>
每节只保留序号圆点 + 章节名,横条占空间且信息冗余; 未用到的 progress prop 一并移除。 Generated with [Devin](https://devin.ai) Co-Authored-By: Devin <158243242+devin-ai-integration[bot]@users.noreply.github.com>
强调「在子话题里继续开分支」的嵌套追问体验; 页面 meta description 同步保持一致。 Generated with [Devin](https://devin.ai) Co-Authored-By: Devin <158243242+devin-ai-integration[bot]@users.noreply.github.com>
.demoSection 突破 .main 的 1180px 正文栏宽,最多用满 1440px,三列演示窗口更宽更贴近真实产品比例; 移动端 100vw-32px 与正文等宽,不产生横向溢出。 Generated with [Devin](https://devin.ai) Co-Authored-By: Devin <158243242+devin-ai-integration[bot]@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
为什么改
首页需要让访客在注册前直观看懂 ThreadChat 的核心价值:从回答里的一句话开分支、主线与分支并排阅读、通过分支树找回来路、再用 @artifact 把结论带回主线。本 PR 先撤销历史 PR #127 的首页实现(revert 提交
857049ba),再在旧基线上重新实现——不是搬回旧代码。改了什么
/重排:导航 → Hero(「一款能开分叉的 AI」)→ 场景交互演示 → 功能解释 → FAQ(9 问)→ 底部 CTA → 法律链接/thread-chat:奶黄色纸面 token、三列布局、分支深度色、划选锚点 + 脚注、来源横幅、继承上文提示、Artifact 卡片、composer 胶囊3a2ada3):演示窗口里的文本可以真实拖选 —— 选完浮出提问气泡(引用原句 + 真实 textarea:focus 高亮、可输入、Enter/Esc),点「带着问题开分支」后 ~1.4s 在父列右侧开出用户自己的分支列(本地示例回答,不调用模型);剧本气泡的输入框同样可改写,改写后提交也走手动分支。已提交锚点点击只定位/恢复列,不再弹气泡;提交后列延迟出现(模拟开分支间隔),提交瞬间气泡即关闭、锚点落定下划线。bdd6524+389b814):锚点平时是纯文本;光标移到锚点后随选区末尾(零宽selend标记)拖动,.sel下划线逐字「画」出;划满浮出深色提问气泡(引用 + 输入框逐字打字 + 提交按钮);点击「带着问题开分支」后才展开分支列、锚点才定住下划线与脚注。气泡渲染在.ld根级(z-index 45、setInterval 实测跟随),不被相邻列裁剪或盖住bdd6524):主线「锚定 + 主线 + 子树计数」,分支列「面包屑 + L{n} 徽标 + 标题 + 子树/⇄切换/收起」;收起真实关闭该列,⇄切换在兄弟分支间轮换,子树按钮定位/展开子分支use-demo-player:视图由 (场景, 章节, 揭示进度) 折叠派生,任意章节可直达完整状态;支持播放/暂停/重播/章节跳转;视口驱动自动播放;尊重prefers-reduced-motion@→ 弹层选择(鼠标 + ↑/↓/Enter/Escape)→ 引用胶囊 → 发送 → 主线继续回答/start-chat,保留/privacy、/terms.ld作用域(landing-demo.css),不污染.tcopenspec/changes/replace-home-with-interactive-demo/lib/axiom/server.tsprefer-const(let queue→const queue,无行为变化),使 lint 零 error没有引入哪些误解
实际验证
pnpm typecheck✅(0 错误)pnpm lint✅(0 error;剩 3 个既有 warning,与本变更无关)pnpm build✅(/为静态页 ○)pnpm openspec:validate✅(39 passed,含新 change)localhost:4049):/tmp/tc-shots/(home-1, home-final, demo-frame, tech-picker, tech-final-2, mobile-1, mobile-top, mobile-bottom)限制
/thread-chat源码 token/DOM 复刻)交付标识
637a363(origin/main)+ revert857049brefactor-home-page23e8ad0+bdd6524+389b814+3a2ada3Generated with Devin