Skip to content

refactor: 重构和简化 design token#1673

Draft
Seeridia wants to merge 4 commits into
devfrom
refactor-design-token
Draft

refactor: 重构和简化 design token#1673
Seeridia wants to merge 4 commits into
devfrom
refactor-design-token

Conversation

@Seeridia
Copy link
Copy Markdown
Collaborator

@Seeridia Seeridia commented Apr 5, 2026

Draft

正在推进 design token 的简化和整理

Copilot AI review requested due to automatic review settings April 5, 2026 03:47
@changeset-bot
Copy link
Copy Markdown

changeset-bot Bot commented Apr 5, 2026

⚠️ No Changeset found

Latest commit: 7c35a85

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@Seeridia Seeridia marked this pull request as draft April 5, 2026 03:47
@pkg-pr-new
Copy link
Copy Markdown

pkg-pr-new Bot commented Apr 5, 2026

Open in StackBlitz

pnpm add https://pkg.pr.new/cherry-markdown@1673
npm i https://pkg.pr.new/cherry-markdown@1673
yarn add https://pkg.pr.new/cherry-markdown@1673.tgz

commit: 7c35a85

@cherry-markdown-bot
Copy link
Copy Markdown
Collaborator

cherry-markdown-bot commented Apr 5, 2026

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

该 PR 主要在 cherry-markdown 的 Sass 体系中重构/简化 design tokens:引入更清晰的“新语义命名层”,把部分组件变量拆分到独立文件,并将大量 @import 迁移到 Sass module 体系(@forward + sass:meta.load-css),同时更新各主题对新语义变量的覆盖方式。

Changes:

  • variables/semantic.scss 中新增“新语义命名层”token,并提供部分旧变量兼容映射
  • 将 table/accordion/panel/shortcut-panel 等组件变量拆分到 variables/components/* 并统一转发
  • 将样式入口与主题/Prism 引入方式从 @import 迁移到 @forward + meta.load-css,并调整 Rollup 样式构建方式

Reviewed changes

Copilot reviewed 26 out of 26 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
packages/cherry-markdown/src/sass/variables/semantic.scss 新增新语义 token 层 + 旧变量兼容映射,并替换多处引用到新 token
packages/cherry-markdown/src/sass/variables/index.scss 使用 @forward 统一导出 base/semantic/open-color 与组件变量集合
packages/cherry-markdown/src/sass/variables/base.scss 新增 --radius-xs 等基础 token
packages/cherry-markdown/src/sass/variables/components/index.scss 聚合转发组件级变量文件
packages/cherry-markdown/src/sass/variables/components/table.scss 新增 table 相关变量定义
packages/cherry-markdown/src/sass/variables/components/accordion.scss 新增 accordion 相关变量定义(从 semantic 中拆出)
packages/cherry-markdown/src/sass/variables/components/panel.scss 新增 panel 语义变量定义(支撑新的 panel token 结构)
packages/cherry-markdown/src/sass/variables/components/shortcut-panel.scss 新增快捷键面板相关变量定义(从组件样式中拆出)
packages/cherry-markdown/src/sass/themes/index.scss @forward 聚合各主题文件
packages/cherry-markdown/src/sass/themes/default.scss 主题改为覆盖新语义变量,并保留旧变量别名
packages/cherry-markdown/src/sass/themes/dark.scss 同上:覆盖新语义变量 + 旧变量别名;同步更新部分 token 使用
packages/cherry-markdown/src/sass/themes/abyss.scss 同上:覆盖新语义变量 + 旧变量别名;同步更新注释/命名
packages/cherry-markdown/src/sass/themes/green.scss 同上:覆盖新语义变量 + 旧变量别名;补充 TOC/Accordion 变量块
packages/cherry-markdown/src/sass/themes/red.scss 同上:覆盖新语义变量 + 旧变量别名;补充 TOC/Accordion 变量块
packages/cherry-markdown/src/sass/themes/gray.scss 同上:覆盖新语义变量 + 旧变量别名;整理变量分区
packages/cherry-markdown/src/sass/themes/violet.scss 同上:覆盖新语义变量 + 旧变量别名;补充 TOC/Accordion 变量块
packages/cherry-markdown/src/sass/themes/blue.scss 同上:覆盖新语义变量 + 旧变量别名;补充 TOC/Accordion 变量块与 panel token 结构
packages/cherry-markdown/src/sass/index.scss 样式入口改用 meta.load-css 引入 cherry 样式
packages/cherry-markdown/src/sass/cherry.scss meta.load-css 统一加载各子样式,并将多处旧 token 引用替换为新 token
packages/cherry-markdown/src/sass/markdown.scss 使用新语义背景/边框/文字 token;Prism 引入改用 meta.load-css;panel token 结构重构
packages/cherry-markdown/src/sass/markdown_pure.scss 纯 markdown 入口改用 meta.load-css 引入 variables/markdown/themes 聚合
packages/cherry-markdown/src/sass/previewer.scss 多处 token 引用替换为新语义 token;图片工具气泡样式由 @extend 改为显式声明
packages/cherry-markdown/src/sass/components/shortcut_key_config.scss 移除变量定义(改由 variables/components/shortcut-panel 提供);更新 hover/active token
packages/cherry-markdown/src/sass/codemirror-v6-fixes.scss gutter 样式改用新语义边框/背景 token
packages/cherry-markdown/src/sass/bubble_formula.scss 多处边框/文字/背景 token 更新为新语义 token
packages/cherry-markdown/build/rollup.styles.config.js 样式构建改为自定义 Sass 编译并输出 asset(替代 rollup-plugin-scss 用法)

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +39 to +40
--color-brand-primary: var(--primary-color);
--color-brand-primary-hover: var(--color-primary-hover);
Copy link

Copilot AI Apr 5, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

--color-brand-primary-hover is set up as a new semantic token (and is overridden per-theme), but hover behaviors in this variables layer are still driven by --color-primary-hover/--color-link-hover, which currently resolve to --primary-color (non-hover). As a result, theme-specific hover colors won’t propagate to things like link hover (via --color-text-link-hover). Consider making --color-link-hover / --color-primary-hover derive from --color-brand-primary-hover (or removing the extra indirection) so theme overrides are actually consumed.

Copilot uses AI. Check for mistakes.

--accordion-summary-bg: var(--primary-color);
--accordion-summary-color: var(--oc-white);
--accordion-summary-hover-bg: var(--color-primary-hover);
Copy link

Copilot AI Apr 5, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

--accordion-summary-hover-bg is wired to --color-primary-hover, but that token isn’t overridden by the themes in this PR (themes override --color-brand-primary-hover instead). This means accordion hover colors won’t follow the theme’s intended hover color. Prefer referencing --color-brand-primary-hover here, or update the semantic mapping so --color-primary-hover always tracks the theme hover token.

Suggested change
--accordion-summary-hover-bg: var(--color-primary-hover);
--accordion-summary-hover-bg: var(--color-brand-primary-hover);

Copilot uses AI. Check for mistakes.
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Apr 5, 2026

Size Change: -4.32 kB (-0.06%)

Total Size: 7.83 MB

📦 View Changed
Filename Size Change
packages/cherry-markdown/dist/cherry-markdown.core.js 673 kB +10 B (0%)
packages/cherry-markdown/dist/cherry-markdown.css 34.7 kB -611 B (-1.73%)
packages/cherry-markdown/dist/cherry-markdown.esm.js 1.65 MB +5 B (0%)
packages/cherry-markdown/dist/cherry-markdown.js 3.31 MB +14 B (0%)
packages/cherry-markdown/dist/cherry-markdown.markdown.css 19.1 kB -1.61 kB (-7.76%)
packages/cherry-markdown/dist/cherry-markdown.markdown.min.css 13.2 kB -1.17 kB (-8.18%)
packages/cherry-markdown/dist/cherry-markdown.min.css 26.9 kB -967 B (-3.48%)
packages/cherry-markdown/dist/cherry-markdown.stream.esm.js 482 kB +6 B (0%)
packages/cherry-markdown/dist/cherry-markdown.stream.js 482 kB +6 B (0%)
ℹ️ View Unchanged
Filename Size
packages/cherry-markdown/dist/addons/advance/cherry-codeblock-echarts-plugin.esm.js 29.6 kB
packages/cherry-markdown/dist/addons/advance/cherry-codeblock-echarts-plugin.js 29.7 kB
packages/cherry-markdown/dist/addons/advance/cherry-table-echarts-plugin.esm.js 49.3 kB
packages/cherry-markdown/dist/addons/advance/cherry-table-echarts-plugin.js 49.4 kB
packages/cherry-markdown/dist/addons/advance/cherry-tapd-checklist-plugin.esm.js 22.4 kB
packages/cherry-markdown/dist/addons/advance/cherry-tapd-checklist-plugin.js 22.5 kB
packages/cherry-markdown/dist/addons/advance/cherry-tapd-html-tag-plugin.esm.js 22.3 kB
packages/cherry-markdown/dist/addons/advance/cherry-tapd-html-tag-plugin.js 22.4 kB
packages/cherry-markdown/dist/addons/advance/cherry-tapd-table-plugin.esm.js 25.4 kB
packages/cherry-markdown/dist/addons/advance/cherry-tapd-table-plugin.js 25.5 kB
packages/cherry-markdown/dist/addons/cherry-code-block-mermaid-plugin.esm.js 23.2 kB
packages/cherry-markdown/dist/addons/cherry-code-block-mermaid-plugin.js 23.3 kB
packages/cherry-markdown/dist/addons/cherry-code-block-plantuml-plugin.esm.js 24.7 kB
packages/cherry-markdown/dist/addons/cherry-code-block-plantuml-plugin.js 24.8 kB
packages/cherry-markdown/dist/cherry-markdown.core.d.ts 106 B
packages/cherry-markdown/dist/cherry-markdown.d.ts 101 B
packages/cherry-markdown/dist/cherry-markdown.engine.core.d.ts 116 B
packages/cherry-markdown/dist/cherry-markdown.engine.core.esm.d.ts 116 B
packages/cherry-markdown/dist/cherry-markdown.engine.core.esm.js 301 kB
packages/cherry-markdown/dist/cherry-markdown.engine.core.js 301 kB
packages/cherry-markdown/dist/cherry-markdown.esm.d.ts 101 B
packages/cherry-markdown/dist/cherry-markdown.stream.d.ts 100 B
packages/cherry-markdown/dist/cherry-markdown.stream.esm.d.ts 100 B
packages/cherry-markdown/dist/types/addons/advance/cherry-codeblock-echarts-plugin.d.ts 186 B
packages/cherry-markdown/dist/types/addons/advance/cherry-table-echarts-plugin.d.ts 1.73 kB
packages/cherry-markdown/dist/types/addons/advance/cherry-tapd-checklist-plugin.d.ts 323 B
packages/cherry-markdown/dist/types/addons/advance/cherry-tapd-html-tag-plugin.d.ts 494 B
packages/cherry-markdown/dist/types/addons/advance/cherry-tapd-table-plugin.d.ts 1.15 kB
packages/cherry-markdown/dist/types/addons/cherry-code-block-mermaid-plugin.d.ts 1.45 kB
packages/cherry-markdown/dist/types/addons/cherry-code-block-plantuml-plugin.d.ts 160 B
packages/cherry-markdown/dist/types/Cherry.config.d.ts 122 B
packages/cherry-markdown/dist/types/Cherry.d.ts 4.58 kB
packages/cherry-markdown/dist/types/CherryStatic.d.ts 547 B
packages/cherry-markdown/dist/types/CherryStream.d.ts 1.59 kB
packages/cherry-markdown/dist/types/core/HookCenter.d.ts 789 B
packages/cherry-markdown/dist/types/core/hooks/AiFlowAutoClose.d.ts 370 B
packages/cherry-markdown/dist/types/core/hooks/AutoLink.d.ts 948 B
packages/cherry-markdown/dist/types/core/hooks/BackgroundColor.d.ts 189 B
packages/cherry-markdown/dist/types/core/hooks/Blockquote.d.ts 195 B
packages/cherry-markdown/dist/types/core/hooks/Br.d.ts 193 B
packages/cherry-markdown/dist/types/core/hooks/CodeBlock.d.ts 1.66 kB
packages/cherry-markdown/dist/types/core/hooks/Color.d.ts 183 B
packages/cherry-markdown/dist/types/core/hooks/CommentReference.d.ts 665 B
packages/cherry-markdown/dist/types/core/hooks/Detail.d.ts 328 B
packages/cherry-markdown/dist/types/core/hooks/Emoji.config.d.ts 9.31 kB
packages/cherry-markdown/dist/types/core/hooks/Emoji.d.ts 9.36 kB
packages/cherry-markdown/dist/types/core/hooks/Emphasis.d.ts 263 B
packages/cherry-markdown/dist/types/core/hooks/Footnote.d.ts 307 B
packages/cherry-markdown/dist/types/core/hooks/FrontMatter.d.ts 192 B
packages/cherry-markdown/dist/types/core/hooks/Header.d.ts 605 B
packages/cherry-markdown/dist/types/core/hooks/HighLight.d.ts 157 B
packages/cherry-markdown/dist/types/core/hooks/Hr.d.ts 223 B
packages/cherry-markdown/dist/types/core/hooks/HtmlBlock.d.ts 313 B
packages/cherry-markdown/dist/types/core/hooks/Image.d.ts 325 B
packages/cherry-markdown/dist/types/core/hooks/InlineCode.d.ts 181 B
packages/cherry-markdown/dist/types/core/hooks/InlineMath.d.ts 707 B
packages/cherry-markdown/dist/types/core/hooks/Link.d.ts 582 B
packages/cherry-markdown/dist/types/core/hooks/List.d.ts 347 B
packages/cherry-markdown/dist/types/core/hooks/MathBlock.d.ts 461 B
packages/cherry-markdown/dist/types/core/hooks/Panel.d.ts 436 B
packages/cherry-markdown/dist/types/core/hooks/Paragraph.d.ts 664 B
packages/cherry-markdown/dist/types/core/hooks/Ruby.d.ts 154 B
packages/cherry-markdown/dist/types/core/hooks/Size.d.ts 176 B
packages/cherry-markdown/dist/types/core/hooks/Space.d.ts 199 B
packages/cherry-markdown/dist/types/core/hooks/Strikethrough.d.ts 241 B
packages/cherry-markdown/dist/types/core/hooks/Sub.d.ts 179 B
packages/cherry-markdown/dist/types/core/hooks/Suggester.d.ts 2.23 kB
packages/cherry-markdown/dist/types/core/hooks/SuggestList.d.ts 158 B
packages/cherry-markdown/dist/types/core/hooks/Sup.d.ts 179 B
packages/cherry-markdown/dist/types/core/hooks/Table.d.ts 554 B
packages/cherry-markdown/dist/types/core/hooks/Toc.d.ts 974 B
packages/cherry-markdown/dist/types/core/hooks/Transfer.d.ts 175 B
packages/cherry-markdown/dist/types/core/hooks/Underline.d.ts 156 B
packages/cherry-markdown/dist/types/core/HooksConfig.d.ts 523 B
packages/cherry-markdown/dist/types/core/ParagraphBase.d.ts 1.36 kB
packages/cherry-markdown/dist/types/core/SyntaxBase.d.ts 956 B
packages/cherry-markdown/dist/types/Editor.d.ts 5.68 kB
packages/cherry-markdown/dist/types/Engine.d.ts 1.52 kB
packages/cherry-markdown/dist/types/Event.d.ts 531 B
packages/cherry-markdown/dist/types/Factory.d.ts 1.02 kB
packages/cherry-markdown/dist/types/index.core.d.ts 122 B
packages/cherry-markdown/dist/types/index.d.ts 82 B
packages/cherry-markdown/dist/types/index.engine.core.d.ts 377 B
packages/cherry-markdown/dist/types/index.engine.d.ts 93 B
packages/cherry-markdown/dist/types/index.stream.d.ts 107 B
packages/cherry-markdown/dist/types/libs/rawdeflate.d.ts 87 B
packages/cherry-markdown/dist/types/locales/en_US.d.ts 1.11 kB
packages/cherry-markdown/dist/types/locales/index.d.ts 141 B
packages/cherry-markdown/dist/types/locales/ru_RU.d.ts 1.11 kB
packages/cherry-markdown/dist/types/locales/zh_CN.d.ts 1.12 kB
packages/cherry-markdown/dist/types/Logger.d.ts 441 B
packages/cherry-markdown/dist/types/Previewer.d.ts 2.81 kB
packages/cherry-markdown/dist/types/Sanitizer.d.ts 69 B
packages/cherry-markdown/dist/types/toolbars/Bubble.d.ts 1.02 kB
packages/cherry-markdown/dist/types/toolbars/BubbleFormula.d.ts 1.38 kB
packages/cherry-markdown/dist/types/toolbars/BubbleTable.d.ts 329 B
packages/cherry-markdown/dist/types/toolbars/FloatMenu.d.ts 783 B
packages/cherry-markdown/dist/types/toolbars/HiddenToolbar.d.ts 226 B
packages/cherry-markdown/dist/types/toolbars/HookCenter.d.ts 512 B
packages/cherry-markdown/dist/types/toolbars/hooks/Align.d.ts 191 B
packages/cherry-markdown/dist/types/toolbars/hooks/Audio.d.ts 322 B
packages/cherry-markdown/dist/types/toolbars/hooks/Bold.d.ts 455 B
packages/cherry-markdown/dist/types/toolbars/hooks/Br.d.ts 318 B
packages/cherry-markdown/dist/types/toolbars/hooks/ChangeLocale.d.ts 252 B
packages/cherry-markdown/dist/types/toolbars/hooks/CheckList.d.ts 353 B
packages/cherry-markdown/dist/types/toolbars/hooks/Code.d.ts 398 B
packages/cherry-markdown/dist/types/toolbars/hooks/CodeTheme.d.ts 451 B
packages/cherry-markdown/dist/types/toolbars/hooks/Color.d.ts 2.11 kB
packages/cherry-markdown/dist/types/toolbars/hooks/Copy.d.ts 697 B
packages/cherry-markdown/dist/types/toolbars/hooks/CursorPosition.d.ts 207 B
packages/cherry-markdown/dist/types/toolbars/hooks/Detail.d.ts 324 B
packages/cherry-markdown/dist/types/toolbars/hooks/DrawIo.d.ts 420 B
packages/cherry-markdown/dist/types/toolbars/hooks/Export.d.ts 195 B
packages/cherry-markdown/dist/types/toolbars/hooks/File.d.ts 319 B
packages/cherry-markdown/dist/types/toolbars/hooks/Formula.d.ts 459 B
packages/cherry-markdown/dist/types/toolbars/hooks/FullScreen.d.ts 206 B
packages/cherry-markdown/dist/types/toolbars/hooks/Graph.d.ts 736 B
packages/cherry-markdown/dist/types/toolbars/hooks/H1.d.ts 390 B
packages/cherry-markdown/dist/types/toolbars/hooks/H2.d.ts 391 B
packages/cherry-markdown/dist/types/toolbars/hooks/H3.d.ts 391 B
packages/cherry-markdown/dist/types/toolbars/hooks/Header.d.ts 505 B
packages/cherry-markdown/dist/types/toolbars/hooks/Hr.d.ts 322 B
packages/cherry-markdown/dist/types/toolbars/hooks/Image.d.ts 345 B
packages/cherry-markdown/dist/types/toolbars/hooks/InlineCode.d.ts 436 B
packages/cherry-markdown/dist/types/toolbars/hooks/Insert.d.ts 473 B
packages/cherry-markdown/dist/types/toolbars/hooks/Italic.d.ts 463 B
packages/cherry-markdown/dist/types/toolbars/hooks/Justify.d.ts 163 B
packages/cherry-markdown/dist/types/toolbars/hooks/Link.d.ts 347 B
packages/cherry-markdown/dist/types/toolbars/hooks/List.d.ts 488 B
packages/cherry-markdown/dist/types/toolbars/hooks/MobilePreview.d.ts 316 B
packages/cherry-markdown/dist/types/toolbars/hooks/Ol.d.ts 349 B
packages/cherry-markdown/dist/types/toolbars/hooks/Panel.d.ts 475 B
packages/cherry-markdown/dist/types/toolbars/hooks/Pdf.d.ts 318 B
packages/cherry-markdown/dist/types/toolbars/hooks/ProTable.d.ts 561 B
packages/cherry-markdown/dist/types/toolbars/hooks/Publish.d.ts 390 B
packages/cherry-markdown/dist/types/toolbars/hooks/QuickTable.d.ts 440 B
packages/cherry-markdown/dist/types/toolbars/hooks/Quote.d.ts 245 B
packages/cherry-markdown/dist/types/toolbars/hooks/Redo.d.ts 263 B
packages/cherry-markdown/dist/types/toolbars/hooks/Ruby.d.ts 447 B
packages/cherry-markdown/dist/types/toolbars/hooks/Search.d.ts 369 B
packages/cherry-markdown/dist/types/toolbars/hooks/Settings.d.ts 753 B
packages/cherry-markdown/dist/types/toolbars/hooks/ShortcutKey.d.ts 442 B
packages/cherry-markdown/dist/types/toolbars/hooks/Size.d.ts 300 B
packages/cherry-markdown/dist/types/toolbars/hooks/Split.d.ts 319 B
packages/cherry-markdown/dist/types/toolbars/hooks/Strikethrough.d.ts 405 B
packages/cherry-markdown/dist/types/toolbars/hooks/Sub.d.ts 372 B
packages/cherry-markdown/dist/types/toolbars/hooks/Sup.d.ts 372 B
packages/cherry-markdown/dist/types/toolbars/hooks/SwitchModel.d.ts 285 B
packages/cherry-markdown/dist/types/toolbars/hooks/Table.d.ts 364 B
packages/cherry-markdown/dist/types/toolbars/hooks/Theme.d.ts 465 B
packages/cherry-markdown/dist/types/toolbars/hooks/Toc.d.ts 320 B
packages/cherry-markdown/dist/types/toolbars/hooks/TogglePreview.d.ts 342 B
packages/cherry-markdown/dist/types/toolbars/hooks/Ul.d.ts 350 B
packages/cherry-markdown/dist/types/toolbars/hooks/Underline.d.ts 403 B
packages/cherry-markdown/dist/types/toolbars/hooks/Undo.d.ts 244 B
packages/cherry-markdown/dist/types/toolbars/hooks/Video.d.ts 322 B
packages/cherry-markdown/dist/types/toolbars/hooks/Word.d.ts 318 B
packages/cherry-markdown/dist/types/toolbars/hooks/WordCount.d.ts 376 B
packages/cherry-markdown/dist/types/toolbars/MenuBase.d.ts 2.79 kB
packages/cherry-markdown/dist/types/toolbars/PreviewerBubble.d.ts 2.73 kB
packages/cherry-markdown/dist/types/toolbars/ShortcutKeyConfigPanel.d.ts 1.38 kB
packages/cherry-markdown/dist/types/toolbars/Sidebar.d.ts 224 B
packages/cherry-markdown/dist/types/toolbars/Toc.d.ts 384 B
packages/cherry-markdown/dist/types/toolbars/Toolbar.d.ts 2.24 kB
packages/cherry-markdown/dist/types/toolbars/ToolbarRight.d.ts 156 B
packages/cherry-markdown/dist/types/UrlCache.d.ts 529 B
packages/cherry-markdown/dist/types/utils/async-render-handler.d.ts 346 B
packages/cherry-markdown/dist/types/utils/autoindent.d.ts 239 B
packages/cherry-markdown/dist/types/utils/cm-search-replace.d.ts 1.75 kB
packages/cherry-markdown/dist/types/utils/code-preview-language-setting.d.ts 169 B
packages/cherry-markdown/dist/types/utils/codeBlockContentHandler.d.ts 949 B
packages/cherry-markdown/dist/types/utils/color.d.ts 205 B
packages/cherry-markdown/dist/types/utils/config.d.ts 984 B
packages/cherry-markdown/dist/types/utils/copy.d.ts 577 B
packages/cherry-markdown/dist/types/utils/dialog.d.ts 195 B
packages/cherry-markdown/dist/types/utils/dom.d.ts 650 B
packages/cherry-markdown/dist/types/utils/downloadUtil.d.ts 426 B
packages/cherry-markdown/dist/types/utils/env.d.ts 482 B
packages/cherry-markdown/dist/types/utils/error.d.ts 185 B
packages/cherry-markdown/dist/types/utils/event.d.ts 440 B
packages/cherry-markdown/dist/types/utils/export.d.ts 422 B
packages/cherry-markdown/dist/types/utils/exportWord.d.ts 424 B
packages/cherry-markdown/dist/types/utils/file.d.ts 848 B
packages/cherry-markdown/dist/types/utils/footnoteHoverHandler.d.ts 889 B
packages/cherry-markdown/dist/types/utils/formulaUtilsHandler.d.ts 638 B
packages/cherry-markdown/dist/types/utils/htmlparser.d.ts 1.55 kB
packages/cherry-markdown/dist/types/utils/image.d.ts 440 B
packages/cherry-markdown/dist/types/utils/imgSizeHandler.d.ts 912 B
packages/cherry-markdown/dist/types/utils/imgToolHandler.d.ts 316 B
packages/cherry-markdown/dist/types/utils/lazyLoadImg.d.ts 2.64 kB
packages/cherry-markdown/dist/types/utils/lineFeed.d.ts 720 B
packages/cherry-markdown/dist/types/utils/listContentHandler.d.ts 634 B
packages/cherry-markdown/dist/types/utils/lookbehind-replace.d.ts 381 B
packages/cherry-markdown/dist/types/utils/LRUCache.d.ts 554 B
packages/cherry-markdown/dist/types/utils/mathjax.d.ts 218 B
packages/cherry-markdown/dist/types/utils/myersDiff.d.ts 906 B
packages/cherry-markdown/dist/types/utils/pasteHelper.d.ts 934 B
packages/cherry-markdown/dist/types/utils/platformTransform.d.ts 152 B
packages/cherry-markdown/dist/types/utils/recount-pos.d.ts 259 B
packages/cherry-markdown/dist/types/utils/regexp.d.ts 1.58 kB
packages/cherry-markdown/dist/types/utils/sanitize.d.ts 423 B
packages/cherry-markdown/dist/types/utils/shortcutKey.d.ts 543 B
packages/cherry-markdown/dist/types/utils/svgUtils.d.ts 650 B
packages/cherry-markdown/dist/types/utils/tableContentHandler.d.ts 3.25 kB

compressed-size-action

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 34 out of 34 changed files in this pull request and generated 1 comment.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +48 to +52
buildStart() {
if (watch) {
const files = Array.isArray(watch) ? watch : [watch];
files.forEach((file) => this.addWatchFile(file));
}
Copy link

Copilot AI Apr 5, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

createSassAssetPlugin only registers the optional watch list, but it doesn’t add watch entries for the actual Sass dependency graph (partials loaded via @use/@forward/meta.load-css). In rollup --watch, edits to imported SCSS may not trigger a rebuild unless they’re manually listed. Consider collecting dependencies from the Sass compile result (e.g., loaded URLs/files) and calling this.addWatchFile for each of them (or expanding the provided watch to all .scss files).

Copilot uses AI. Check for mistakes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants