feat(mindspace): 公开页分享组件、workspace 路径与 Plaza 发布增强

- 新增 public share widget 与 workspace relative path 解析
- 增强 publications/chat-plaza 发布链路与缩略图 demo
- 补充 schema、cover 检查脚本与回归测试

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
john
2026-07-05 23:14:41 +08:00
parent 69be1e5293
commit e2ad3bf62b
39 changed files with 2184 additions and 256 deletions
+4
View File
@@ -72,6 +72,7 @@ CREATE TABLE IF NOT EXISTS h5_assets (
mime_type VARCHAR(128) NOT NULL,
original_filename VARCHAR(255) NOT NULL,
display_name VARCHAR(255) NOT NULL,
workspace_relative_path VARCHAR(512) NULL,
current_version_id CHAR(36) NULL,
size_bytes BIGINT NOT NULL DEFAULT 0,
checksum CHAR(64) NOT NULL,
@@ -85,6 +86,7 @@ CREATE TABLE IF NOT EXISTS h5_assets (
KEY idx_h5_assets_category (user_id, category_id, updated_at),
KEY idx_h5_assets_parent (user_id, parent_id),
KEY idx_h5_assets_checksum (user_id, checksum),
KEY idx_h5_assets_workspace_path (user_id, workspace_relative_path, updated_at),
CONSTRAINT fk_h5_asset_user FOREIGN KEY (user_id) REFERENCES h5_users(id) ON DELETE CASCADE,
CONSTRAINT fk_h5_asset_space FOREIGN KEY (space_id) REFERENCES h5_user_spaces(id) ON DELETE CASCADE,
CONSTRAINT fk_h5_asset_category FOREIGN KEY (category_id) REFERENCES h5_space_categories(id) ON DELETE CASCADE,
@@ -150,6 +152,7 @@ CREATE TABLE IF NOT EXISTS h5_page_records (
page_type VARCHAR(32) NOT NULL DEFAULT 'article',
template_id VARCHAR(64) NOT NULL DEFAULT 'editorial',
draft_content_ref VARCHAR(512) NULL,
workspace_relative_path VARCHAR(512) NULL,
current_version_id CHAR(36) NULL,
current_publish_id CHAR(36) NULL,
status ENUM('draft', 'reviewing', 'risk_found', 'ready', 'published', 'protected', 'expired', 'offline', 'deleted') NOT NULL DEFAULT 'draft',
@@ -160,6 +163,7 @@ CREATE TABLE IF NOT EXISTS h5_page_records (
KEY idx_h5_pages_user_status (user_id, status, updated_at),
KEY idx_h5_pages_category (user_id, category_id, updated_at),
KEY idx_h5_pages_source_session (user_id, source_session_id),
KEY idx_h5_pages_workspace_path (user_id, workspace_relative_path, updated_at),
CONSTRAINT fk_h5_page_user FOREIGN KEY (user_id) REFERENCES h5_users(id) ON DELETE CASCADE,
CONSTRAINT fk_h5_page_space FOREIGN KEY (space_id) REFERENCES h5_user_spaces(id) ON DELETE CASCADE,
CONSTRAINT fk_h5_page_category FOREIGN KEY (category_id) REFERENCES h5_space_categories(id) ON DELETE CASCADE,