hypercross c524dd5867 refactor: implement base/modifier separation for variable reactivity
Introduce a distinction between base values (set via `/set` or
declarations) and active modifiers (applied via tags). This ensures
tag transitions and numeric modifiers are calculated correctly during
cascades.

- Refactor `VariableView` to use a flat list with hover popups for
  declarations and active modifiers.
- Update `command-dispatcher` to use `getCombined` for accurate
  value lookups and `setBase` for variable updates.
- Update `var-reactivity` to manage `baseValues`, `activeMods`, and
  `sourceActivations` separately.
- Export new utility functions for accessing combined values,
  modifiers, and declaration expressions.
2026-07-13 10:10:47 +08:00
2026-02-28 17:40:02 +08:00
2026-03-31 16:20:42 +08:00
2026-03-15 11:44:23 +08:00
2026-03-01 11:38:19 +08:00
2026-07-09 14:14:45 +08:00
2026-03-01 09:49:01 +08:00

TTTK — Tabletop Toolkit

A TTRPG content preview and compilation tool based on solid.js and rsbuild. Write markdown, preview in browser.

快速开始

# 无需安装,直接使用
npx tttk serve ./content

文档导航

文档 说明
📖 CLI 使用说明 CLI 安装、命令和用法
📦 npm npx tttk serve ./content
🛠️ 开发指南 项目结构、开发规范和构建
📝 Markdown 编写说明 Markdown 语法和组件用法
📊 CSV 编写说明 CSV 文件格式、字段定义、变量语法
🤖 MCP 服务器说明 AI 助手集成、卡牌生成工具

功能概览

  • CLI 工具: tttk serve 预览模式 和 tttk compile 编译模式
  • Markdown 解析: 支持指令语法、YAML 标签、mermaid 图表
  • TTRPG 组件: 骰子、表格、卡牌、标记、命令追踪器等

核心组件

组件 语法 说明
🎲 骰子 :dice[2d6+d8] 掷骰并记录结果
📊 表格 :table[./data.csv] 标签页式表格
🃏 卡牌 :md-deck[./cards.csv] 卡牌布局
📍 标记 :md-pin[A]{x=40 y=40} 图片标记
📋 追踪器 :md-commander 命令历史和状态追踪

技术栈

  • 前端: Solid.js 1.9+
  • 构建: Rsbuild
  • 样式: Tailwind CSS 4
  • Markdown: marked + marked-directive
  • 测试: Jest

许可证

MIT

S
Description
No description provided
Readme MIT
1.5 MiB
Languages
TypeScript 99.3%
CSS 0.4%
JavaScript 0.3%