Commit Graph
39 Commits
Author SHA1 Message Date
JoeAllen 96865c0588 perf: 深度优化消息内存占用
- 消息缓冲 Vec → VecDeque:原来溢出时 drain(0..n) 每条消息 O(n)
  搬移,高频消息下产生大量拷贝;环形缓冲均摊 O(1),并按配置上限
  预分配避免反复扩容
- connection_id/topic/payload 改 Arc<str>:引擎侧主题驻留
  (10k 上限,超出整体重建),同主题数千条记录只存一份;
  消息列表每帧克隆最多 300 条用于渲染,payload 共享后零拷贝
- 单条 payload 历史保留上限 256KB(retained_payload,UTF-8
  边界安全截断),超大报文不再长期占据环形缓冲;消息行显示
  「已截断」徽章;发布记录改用实际发送字节(修 Base64/Hex
  历史内容与真实报文不一致的隐患)
- live 测试适配 Arc<str>;补截断边界单元测试(22 个 lib 测试 +
  2 个 live 测试通过)
2026-09-29 01:07:32 +08:00
JoeAllen 88a8652d7b feat: 接入自建 Sentry 错误上报
- DSN 指向 rustrak 自建 Sentry(项目 8),release 标记 mqttx@版本
- panic 路径:sentry-panic 链式钩子捕获 + 外层钩子 flush 5s,
  确保 panic=abort 终止进程前事件送出
- 存储层 elog! 持久化错误同步 capture_message 上报
- 传输用 reqwest+rustls,避免 openssl 依赖
2026-09-29 00:30:23 +08:00
JoeAllen bc49d1839c feat: OTA 改为静默下载 + 安装需用户确认
- 下载落到数据目录 updates/ 暂存区(退出不丢失),校验后等待安装
- 启动自动检查:静默检查+下载,完成后弹「更新就绪」对话框,
  由用户选择 立即安装(重启) 或 下次启动安装
- main 在进入 UI 前检测暂存区并完成自替换(下次启动安装路径)
- 设置对话框:下载完成后进入「待安装」状态,提供两个安装时机按钮
- install_and_restart 拆分为 download_and_stage / load_staged / install_staged
2026-09-29 00:22:35 +08:00
JoeAllen bf6d165854 feat: OTA 自更新(Gitea Release 为更新源)
Release / Meta (push) Canceled after 0s
Release / Test (push) Canceled after 0s
Release / Build (ubuntu-latest) (push) Canceled after 0s
Release / Publish package (push) Canceled after 0s
- update.rs:检查最新 Release(latest 端点+列表回退)、版本比较、
  平台产物挑选(含 .sha256 侧车)、下载进度、sha256 校验、
  自替换(改名 .old → 换入新 exe → 拉起新进程)、启动清理遗留
- 设置 → 关于:检查更新按钮、发现新版本提示、下载进度条(Progress)、
  失败重试;自动检查更新开关真正生效(启动后台检查并弹通知)
- 版本 1.0.0 → 1.0.1(首个带 OTA 的发布版本)
- 顺手修 clippy 遗留警告(is_none_or、合并 if)
2026-09-28 23:44:56 +08:00
JoeAllen 262bc265d8 ci: release 工作流仅保留 Linux 构建(当前 runner 无 windows-latest 标签)
Release / Meta (push) Canceled after 0s
Release / Test (push) Canceled after 0s
Release / Build (ubuntu-latest) (push) Canceled after 0s
Release / Publish package (push) Canceled after 0s
Windows 产物改由本地 publish-gitea 脚本上传;runner 就绪后可恢复矩阵。
2026-09-28 23:08:01 +08:00
JoeAllen 4e70741f55 feat: Linear 风格 UI 主题(近黑/纯白扁平调色板、靛蓝主色、14px 密度与 6px 圆角)
Release / Meta (push) Canceled after 0s
Release / Test (push) Canceled after 0s
Release / Build (ubuntu-latest) (push) Canceled after 0s
Release / Build (windows-latest) (push) Canceled after 0s
Release / Publish package (push) Canceled after 0s
2026-09-28 22:49:56 +08:00
JoeAllen cd6b6f3201 feat: 预设管理页与发布面板内联变量绑定(占位符提取、快捷改值、渲染预览) 2026-09-28 22:34:02 +08:00
JoeAllen 085d7c5589 feat: 补齐预设与变量注入(遗嘱模板注入、v5 文本属性注入、删除预设二次确认) 2026-09-28 19:04:41 +08:00
JoeAllen f8ce93f0dd fix: 修复 UI 审查问题(图标资产全量化、主区布局贴顶、订阅数据保护与 28 项交互缺陷) 2026-09-28 18:40:58 +08:00
JoeAllen c1c4fc011e feat: GPUI 版补齐 MQTTX 基础功能对标(分组/SSL证书/订阅增强/消息流控制/设置与日志) 2026-09-28 14:41:15 +08:00
JoeAllen bf6937b776 feat: 重写为 GPUI 原生桌面应用并接入 Gitea 软件包发布
- gpui-kit 0.6 原生 UI:连接管理、消息流/日志、发布预设、全局变量、
  设置、阿里云连接预设、原生 Logo
- MQTT 5.0/3.1.1 引擎(rumqttc,TCP/TLS/WS/WSS),独立 tokio runtime
  + 事件泵,真实 broker 端到端测试
- 连接表单:保存前可一键测试连接(宽松校验,自动生成临时 Client ID),
  高级属性(认证/MQTT 5 属性/遗嘱)按需折叠显示,WS 路径仅 WS/WSS 显示
- bug 修复:Hex 奇数长度显式报错、测试连接唯一 Client ID、Base64/Hex
  发布发送真实字节、v5 发布记录携带 Content-Type/用户属性、预设应用
  清除旧 Content-Type、模板时间基准统一;补 8 个单元测试
- Gitea 发布:Generic Package 上传脚本(bash/PowerShell)+ Actions
  release 工作流(tag 触发,双平台构建),README 使用说明
2026-09-28 11:39:47 +08:00
JoeAllen 0152a10ee6 feat: 阿里云 MQTT 连接预设、连接分组与 MQTT 3.1.1 支持
- 后端引入 rumqttc v4 客户端,支持 MQTT 3.1.1 连接/发布/订阅,协议版本随连接下发
- 连接表单:阿里云预设管理(分组、导入导出、去抖自动保存),退出云模式需确认,mqtts 时端口跟随 8883
- 连接列表:分组列就地编辑(输入即创建),空分组提示优化
- 导入按内容去重并提示跳过数量,导出提示含明文密钥
- 调试日志密码脱敏;修复多处取消弹窗的 unhandled rejection
2026-09-04 01:45:19 +08:00
JoeAllen 8a2c63e575 feat: 集成 visual-json 可视化 JSON 编辑/查看并更新品牌图标
- 发送面板 Payload 增加「文本 / JSON 可视化」切换,可视化编辑实时回写
- 消息流 JSON 消息改为只读可视化查看,拦截双击/删除/右键等编辑入口
- visual-json 主题跟随应用亮/暗 comfort 色板
- 更新应用图标与启动页 logo(mqttx.svg + Tauri 各尺寸图标)
2026-08-24 13:41:08 +08:00
Joe Allen 72a388a092 chore: 删除 pipeline.yml 2026-08-20 16:39:09 +08:00
Joe Allen 41929dc7c2 ci: 添加云效流水线配置 (pipeline.yml)
- lint 阶段:pnpm 安装 + vue-tsc 类型检查
- build-linux 阶段:Tauri 系统依赖 + Rust 安装 + pnpm tauri build
- 支持 TAURI_SIGNING_KEY 签名更新构件
- release 阶段(标签触发):生成更新 JSON 元数据
2026-08-20 15:58:39 +08:00
Joe Allen 9f6870440b chore: 取消跟踪 dsh-usage 目录 2026-08-20 15:49:53 +08:00
Joe Allen e2d829630e docs: 更新 README.md 为项目完整文档 2026-08-20 15:26:49 +08:00
Joe Allen f5a702fab1 feat: 添加 Tauri 自动更新器插件支持 (updater plugin)
- 添加 tauri-plugin-updater / tauri-plugin-process Rust 依赖
- 注册 updater 和 process 插件到 Tauri 构建器
- 配置 tauri.conf.json 更新器端点与公钥占位
- 添加 @tauri-apps/plugin-updater / plugin-process npm 依赖
- 创建 useUpdater composable(静默检查、手动检查、下载进度、安装重启)
- 在 AppLayout 标题栏集成更新交互 UI(下载按钮、进度条、安装状态)
- 添加 .pnpm-store 到 .gitignore
2026-08-20 15:16:23 +08:00
Joe Allen 77724e13a1 fix: restore rust-toolchain.toml 2026-08-20 13:54:56 +08:00
Joe Allen 56f162c9a4 feat: add Chinese language support for NSIS and MSI installers
- NSIS: SimpChinese + English
- WiX (MSI): zh-CN + en-US
2026-08-20 13:54:37 +08:00
Joe Allen 6ee84e59b2 fix: use nightly-x86_64-pc-windows-gnu toolchain 2026-08-20 10:16:37 +08:00
Joe Allen f43bdaf1d2 ci: switch Rust to nightly toolchain
- rust-toolchain.toml: channel = nightly
- Add x86_64-pc-windows-gnu target for local mingw64 build
- Fix CI workflow YAML syntax error
2026-08-20 10:08:17 +08:00
Joe Allen 25d9900880 fix: TypeScript errors in CI
- ContextMenu: remove unused cleanup variable (never assigned, TS 6 infer as never)
- GlobalVariableManager: add explicit boolean type to event handler param
- LogPanel: use openPath instead of deprecated open from @tauri-apps/plugin-opener
2026-08-20 09:29:34 +08:00
Joe Allen 49f06f59fa ci: add GitHub Actions workflow
- Frontend: type-check + build (ubuntu-latest)
- Rust: cargo check + clippy (ubuntu-latest)
- Tauri build: Windows (MSVC) + Linux, on push to main
- Upload build artifacts
- rust-toolchain.toml for consistent Rust version
2026-08-20 09:07:36 +08:00
Joe Allen 8407f5daef feat: pinable & draggable preset tabs
- Optional: only presets you pin appear as tabs (click + 添加)
- Pinable: + button opens dropdown to select which presets to pin
- Draggable: drag grip (⠿) to reorder tabs via HTML5 drag & drop
- Unpin: hover tab shows × button to remove it
- Independent editor state per pinned preset
- Drag visual feedback: opacity, border highlight
2026-08-19 11:57:34 +08:00
Joe Allen 1d0c77796d feat: preset tabs for quick switching
- Replace dropdown with tab bar: each preset is a tab
- Click a tab to load that preset's topic/payload/QoS/Retain
- Per-preset independent editor state (variables, v5 props preserved)
- Variables and v5 properties are maintained per-tab, not shared
- Close button on active tab to deselect (when multiple presets)
- Auto-select first preset on load
- Send button shows current preset name
2026-08-19 11:35:59 +08:00
Joe Allen 6646c37722 feat: batch preset send mode
- Toggle between single and batch mode with a button
- Batch mode: multi-select presets, shows selected preset list
- Batch send: sends all selected presets sequentially with progress
- Progress indicators: pending → sending (spinner) → success (✓) / error (✗)
- Single mode: unchanged UX with topic/payload/QoS/Retain editors
- Both modes share variable bindings and v5 properties
2026-08-19 11:31:58 +08:00
Joe Allen 47de6452b4 fix: dark mode color variables
- Override --el-color-white to dark bg to prevent white text on colored backgrounds
- Add comprehensive Element Plus dark mode variables (input, table, tag, dialog, select, checkbox, switch, etc.)
- Fix hardcoded color: #fff in SendPanel toggle-badge to use CSS variable
- Add missing --el-bg-color-page, --el-fill-color-dark, --el-fill-color-blank
2026-08-19 11:05:21 +08:00
Joe Allen f07eaae99c feat: theme follows system preference by default
- No saved preference → use prefers-color-scheme media query
- User clicks toggle → save explicit preference to localStorage
- Listen for system theme changes (OS-level toggle) when no explicit preference
- applyTheme() helper to keep isDark ref and DOM in sync
2026-08-19 11:03:07 +08:00
Joe Allen 7821272bcd fix: hover preview mouse following
- Fixed Chinese variable name that caused JS runtime error (预估Width → estimatedWidth-like logic)
- Proper viewport boundary detection with flip-to-left and flip-to-top
- Uses maxHeight prop instead of hardcoded 360
- Cleaner position calculation with Math.min/Math.max clamping
2026-08-18 19:54:31 +08:00
Joe Allen 9042659fbf feat: hover preview for send panel payload input
- Wrapped payload textarea in HoverPreview
- Shows full formatted JSON on hover (600ms delay)
- Helps when template is too long for the 2-row textarea
2026-08-18 19:47:21 +08:00
Joe Allen 3c04af9532 feat: hover preview for truncated JSON content
New HoverPreview component shows a floating tooltip with full
content on mouse hover (400ms delay). Applied to:
- MessageStream: collapsed + expanded payload views
- PresetList: payload preview in table
- LogPanel: details section

The popup follows the mouse cursor, auto-positions within viewport,
and supports monospace code formatting with scroll for long content.
2026-08-18 19:29:12 +08:00
Joe Allen 85e31e2f96 feat: visual comfort improvements
- Soft color palette with warm earth tones (green-primary, warm neutrals)
- Dark mode support with theme toggle in header (persisted in localStorage)
- Reduced contrast: softer borders, subtle shadows, muted colors
- Custom scrollbar, focus rings, button/input/dialog styling
- Better typography: line-height 1.6, optimized font stack
- ELement Plus theme overrides for consistent comfort styling
- All styles in src/styles/comfort.css with CSS custom properties
2026-08-18 16:37:36 +08:00
Joe Allen 85b7c6b31b feat: message cards expanded by default
Change toggle logic from 'expanded set' (collapsed by default)
to 'collapsed set' (expanded by default). Users can collapse
individual messages with the toggle button.
2026-08-18 14:59:22 +08:00
Joe Allen 6ced5c8444 feat: global right-click control + topic tree context menu
- UseContextMenu composable: global right-click prevention
  - PROD: prevent default browser context menu everywhere
  - DEV: allow native context menu for debugging
- ContextMenu component: reusable custom right-click menu
- TopicTree: right-click nodes for copy topic / subscribe / unsubscribe / filter
  - Copy topic to clipboard
  - Subscribe with QoS 0/1/2
  - Unsubscribe with confirmation
  - Filter by topic
2026-08-18 14:58:31 +08:00
Joe Allen 7f6a4f84d8 feat: auto-format JSON display everywhere
- Shared prettyJson/truncate/isJson utility in src/utils/format.ts
- MessageStream: collapsed preview + expanded view both auto-format JSON
- LogPanel: log details with JSON content auto-formatted
- PresetList: payload preview auto-formatted
- Deduplicated isJson/formatPayload logic
2026-08-18 14:56:00 +08:00
Joe Allen 9b7094dcf2 fix: auto-resubscribe persisted subscriptions on reconnect
The topic tree subscriptions were persisted in localStorage but
never re-subscribed when the connection was re-established. Now
when mqtt:status fires with 'connected', all saved subscriptions
for that connection are automatically re-subscribed.
2026-08-18 14:52:20 +08:00
Joe Allen adc49577b4 chore: remove build artifacts from tracking 2026-08-18 14:33:05 +08:00
Joe Allen 154fb15130 feat: initial MQTT v5 debugging tool
- Tauri v2 + Vue 3 + TypeScript + Element Plus
- Connection management (CRUD + enable/disable/test)
- Preset system with {{variable}} placeholders
- Dashboard with live message scrolling + topic tree
- Payload inspector (JSON/Hex/Base64/Plain)
- Protocol-level logging (file + UI dual channel)
- Global variable manager with localStorage persistence
- MQTT v5 property support (user properties, content type, etc.)
- SubAck result tracking with subscribe_tracked API
2026-08-18 14:32:57 +08:00