dsh-long-message-fold:把 DSH Web 里的超长用户消息折叠起来

constraint21 维护的客户端插件 dsh-long-message-fold,遮罩 shipped 的 PlainUserText 渲染器,把超长 user 消息正文折叠成 360px 预览高度、底部 mask-image 渐隐,并给出「展开全文 · N 行 / 收起」切换;短消息布局不变。折叠与否靠 useLayoutEffect + ResizeObserver 实测溢出(内联态取 getBoundingClientRect().height,块态取 scrollHeight),避免误伤 QueueDock 预览与 submission echo 的单行 nowrap 场景。装上即生效,无开关;参数为 client.js 顶部的 MAX_HEIGHT(360)、FADE_HEIGHT(48)、REMEMBER_LIMIT(400)、OBSERVE_MIN_CHARS(120)。安装走 DSH Plugin Manager 的 install_bundle,target 为 github:constraint21/dsh-long-message-fold,或在 git clone 后指向本地绝对路径,也可用 plugin_manager action: remove_bundle 卸载。依赖 slot conversation.user.text.node 与 Client 包 @deepseek-ai/dsh-client-ui-conversation,仅在 web 平台注册,MIT 许可,包名 @local/dsh-long-message-fold,private: true。

阅读全文