From 434161de5b0ac85227ed699254ee7b781ce90c35 Mon Sep 17 00:00:00 2001 From: chuan Date: Mon, 18 May 2026 01:26:17 +0800 Subject: [PATCH] Refactor theme management and update documentation - Removed `.github-theme` from .gitignore as it is no longer needed. - Updated `official-style-map.md` to clarify the maintenance of GitHub Light style increments within the current repository. - Revised `rules.md` to reflect the new approach to maintaining GitHub Light theme increments. - Changed test script in `package.json` to verify generated theme instead of GitHub migration. - Added `verify-generated-theme.ts` script to validate the generated theme files. - Migrated various styles from `.github-theme` to the new structure, updating comments and references accordingly. --- .gitignore | 1 - docs/official-style-map.md | 16 +++++++-------- docs/rules.md | 2 +- package.json | 2 +- ...migration.ts => verify-generated-theme.ts} | 20 ++----------------- styles/components/actions/action_svg.ts | 1 - styles/components/actions/actions.ts | 1 - styles/components/actions/workflow_runs.ts | 1 - styles/components/actions/workflow_steps.ts | 1 - styles/components/actions/workflow_summary.ts | 1 - styles/components/footer.ts | 1 - styles/components/heatmap.ts | 1 - styles/components/issues/issue.ts | 1 - styles/components/issues/issue_comment.ts | 1 - styles/components/issues/issue_list.ts | 1 - styles/components/issues/issue_sidebar.ts | 1 - styles/components/issues/issue_timeline.ts | 1 - styles/components/navbar.ts | 1 - styles/components/notification.ts | 1 - styles/components/repo/clone.ts | 1 - styles/components/repo/commit.ts | 1 - styles/components/repo/diff.ts | 1 - styles/components/repo/milestones.ts | 1 - styles/components/repo/packages.ts | 1 - styles/components/repo/release.ts | 1 - styles/components/repo/repo.ts | 1 - styles/components/repo/repo_file_view.ts | 1 - styles/components/repo/repo_files.ts | 1 - styles/components/repo/repo_sidebar.ts | 1 - .../templates/repo/commit_sign_badge.ts | 1 - .../components/templates/repo/commits_list.ts | 1 - .../components/templates/repo/view_content.ts | 1 - styles/components/templates/repo/view_list.ts | 1 - styles/pages/dashboard.ts | 1 - styles/pages/explore.ts | 1 - styles/pages/newrepo.ts | 1 - styles/pages/org.ts | 1 - styles/pages/setting.ts | 1 - styles/pages/signin.ts | 1 - styles/pages/user.ts | 1 - styles/primitives/attached.ts | 1 - styles/primitives/base.ts | 1 - styles/primitives/button.ts | 1 - styles/primitives/dropdown/branch_dropdown.ts | 1 - styles/primitives/dropdown/dropdown.ts | 1 - styles/primitives/dropdown/emoji_dropdown.ts | 1 - .../primitives/dropdown/selection_dropdown.ts | 1 - styles/primitives/input.ts | 1 - styles/primitives/label/label.ts | 1 - styles/primitives/label/repo_label.ts | 1 - styles/primitives/label/sha_label.ts | 1 - styles/primitives/label/task_status_label.ts | 1 - styles/primitives/menu/compact_menu.ts | 1 - styles/primitives/menu/menu.ts | 1 - styles/primitives/menu/pagination_menu.ts | 1 - styles/primitives/menu/secondary_menu.ts | 1 - styles/primitives/menu/vertical_menu.ts | 1 - styles/primitives/modal.ts | 1 - styles/primitives/other.ts | 1 - styles/primitives/radius.ts | 1 - styles/primitives/table.ts | 1 - styles/primitives/tippy.ts | 1 - styles/primitives/transition.ts | 1 - 63 files changed, 12 insertions(+), 87 deletions(-) rename scripts/{verify-github-migration.ts => verify-generated-theme.ts} (82%) diff --git a/.gitignore b/.gitignore index 736d6b1..db99135 100644 --- a/.gitignore +++ b/.gitignore @@ -1,5 +1,4 @@ .gitea -.github-theme .gitea-data dist release diff --git a/docs/official-style-map.md b/docs/official-style-map.md index ebb4601..abbb567 100644 --- a/docs/official-style-map.md +++ b/docs/official-style-map.md @@ -2,7 +2,7 @@ ## 当前基线 -当前 `github-dev` 主题以 Gitea 官方 light 主题为基线,并迁移 `.github-theme` 的 GitHub Light 增量。`github-dev-dark` 使用同一套 primitive、component 和 page 规则,但切换到 `themes/github-dark/` 的 dark token 源。 +当前 `github-dev` 主题以 Gitea 官方 light 主题为基线,并在当前仓库内维护 GitHub Light 风格的主题增量。`github-dev-dark` 使用同一套 primitive、component 和 page 规则,但切换到 `themes/github-dark/` 的 dark token 源。 官方主题文件: @@ -58,21 +58,21 @@ Gitea custom 输出: `styles/tokens/derived.ts`:维护派生 token 和兼容别名,例如旧样式里使用的 camelCase 变量名。 -`styles/primitives/` 当前承载 `.github-theme/styles/public/` 的源码级迁移模块,例如按钮、输入框、下拉框、菜单、标签、表格、弹窗、提示框等基础控件。官方基础控件来源主要在 `.gitea/web_src/css/modules/`,例如 `button.css`、`input.css`、`form.css`、`checkbox.css`、`dropdown.css`、`table.css`、`menu.css`、`tippy.css`。 +`styles/primitives/` 当前承载本项目基础控件模块,例如按钮、输入框、下拉框、菜单、标签、表格、弹窗、提示框等。官方基础控件来源主要在 `.gitea/web_src/css/modules/`,例如 `button.css`、`input.css`、`form.css`、`checkbox.css`、`dropdown.css`、`table.css`、`menu.css`、`tippy.css`。 -`styles/components/` 当前承载 `.github-theme/styles/components/` 中非页面级业务组件,以及 `.github-theme/styles/templates/` 的模板专属样式迁移。官方可复用业务组件来源主要在 `.gitea/web_src/css/repo/`、`.gitea/web_src/css/features/`、`.gitea/web_src/css/shared/`,例如 `repo/home-file-list.css`、`repo/clone.css`、`features/heatmap.css`、`features/gitgraph.css`、`shared/flex-list.css`。 +`styles/components/` 当前承载本项目非页面级业务组件,以及模板专属样式。官方可复用业务组件来源主要在 `.gitea/web_src/css/repo/`、`.gitea/web_src/css/features/`、`.gitea/web_src/css/shared/`,例如 `repo/home-file-list.css`、`repo/clone.css`、`features/heatmap.css`、`features/gitgraph.css`、`shared/flex-list.css`。 -`styles/pages/` 当前承载 `.github-theme/styles/components/` 中实际属于页面布局的迁移模块,例如 dashboard、explore、newrepo、org、setting、signin、user。官方页面级来源主要在 `.gitea/web_src/css/` 根目录,例如 `dashboard.css`、`explore.css`、`install.css`、`org.css`、`repo.css`、`user.css`、`admin.css`、`actions.css`。 +`styles/pages/` 当前承载本项目页面布局模块,例如 dashboard、explore、newrepo、org、setting、signin、user。官方页面级来源主要在 `.gitea/web_src/css/` 根目录,例如 `dashboard.css`、`explore.css`、`install.css`、`org.css`、`repo.css`、`user.css`、`admin.css`、`actions.css`。 ## 迁移原则 -第一阶段已经完成官方主题 token 拆分。当前阶段迁移 `.github-theme` 的 GitHub Light token、primitive、component 和 page/template 覆盖。 +第一阶段已经完成官方主题 token 拆分。当前阶段在本仓库内维护 GitHub Light token、primitive、component 和 page/template 覆盖。 -样式迁移采用源码模块级迁移,不落地第三方编译后的单文件 CSS。`styles/primitives/`、`styles/components/`、`styles/pages/` 下的模块都对应 `.github-theme/styles/` 的原始职责目录,并保留可读的嵌套 CSS 结构。 +样式实现采用源码模块级维护,不落地第三方编译后的单文件 CSS。`styles/primitives/`、`styles/components/`、`styles/pages/` 下的模块按当前项目职责拆分,并保留可读的嵌套 CSS 结构。 -`.github-theme/templates/` 已迁移到本项目 `templates/`,构建时同步到 `.gitea/custom/templates/`。 +模板覆盖由本项目 `templates/` 维护,构建时同步到 `.gitea/custom/templates/`。 -`.github-theme/options/` 的 locale 增量已迁移到本项目 `options/locale-overrides/`。构建时 `scripts/locale.ts` 会从 Gitea 官方 `v1.26.1` 获取完整 locale,再合并本项目增量并输出到 `.gitea/custom/options/locale/`。 +locale 增量由本项目 `options/locale-overrides/` 维护。构建时 `scripts/locale.ts` 会从 Gitea 官方 `v1.26.1` 获取完整 locale,再合并本项目增量并输出到 `.gitea/custom/options/locale/`。 后续迁移时,如果只是改颜色主题值,优先放到 `themes/`。`styles/tokens/` 只负责把当前主题输出成 CSS 变量,不直接维护具体颜色表。 diff --git a/docs/rules.md b/docs/rules.md index 5137fd8..95c6d81 100644 --- a/docs/rules.md +++ b/docs/rules.md @@ -62,7 +62,7 @@ ## 修改流程 -官方样式基线和源码映射见 `docs/official-style-map.md`。当前项目先拆分官方 `theme-gitea-light.css`,再按当前分层迁移 `.github-theme` 的 GitHub Light 增量。 +官方样式基线和源码映射见 `docs/official-style-map.md`。当前项目先拆分官方 `theme-gitea-light.css`,再在当前仓库内维护 GitHub Light 风格的主题增量。 新增视觉值时,先判断是否应该成为 token。颜色和主题值放到 `themes/`;派生变量、Gitea 兼容别名和必需变量校验放到 `styles/tokens/`。 diff --git a/package.json b/package.json index beead6c..f7a6e18 100644 --- a/package.json +++ b/package.json @@ -12,7 +12,7 @@ "dev": "bun scripts/build.ts --watch", "preview": "bun run build && bun scripts/preview.ts", "build:min": "bun scripts/build.ts --minify", - "test": "bun run build && bun scripts/verify-theme.ts && bun scripts/verify-github-migration.ts", + "test": "bun run build && bun scripts/verify-theme.ts && bun scripts/verify-generated-theme.ts", "compose:up": "docker compose -f compose.dev.yaml up -d", "compose:down": "docker compose -f compose.dev.yaml down", "compose:logs": "docker compose -f compose.dev.yaml logs -f server", diff --git a/scripts/verify-github-migration.ts b/scripts/verify-generated-theme.ts similarity index 82% rename from scripts/verify-github-migration.ts rename to scripts/verify-generated-theme.ts index 6ded790..5bd310f 100644 --- a/scripts/verify-github-migration.ts +++ b/scripts/verify-generated-theme.ts @@ -36,22 +36,6 @@ if (packageJson.version !== "1.26.1") { throw new Error(`project version must be 1.26.1, got ${packageJson.version}`); } -try { - const githubThemePackageJson = JSON.parse( - await readFile(join(root, ".github-theme", "package.json"), "utf8"), - ) as { version?: string }; - - if (githubThemePackageJson.version !== "1.26.1") { - throw new Error(`.github-theme version must be 1.26.1, got ${githubThemePackageJson.version}`); - } -} catch (error) { - const code = error instanceof Error && "code" in error ? error.code : undefined; - - if (code !== "ENOENT") { - throw error; - } -} - await access(join(root, "themes", "index.ts")); await access(join(themeSourceDir, "index.ts")); await access(join(darkThemeSourceDir, "index.ts")); @@ -94,7 +78,7 @@ for (const file of ["theme-meta.ts", "core.ts", "github-colors.ts", "target-colo for (const snippet of requiredSnippets) { if (!generated.includes(snippet)) { - throw new Error(`generated theme is missing migrated GitHub theme snippet: ${snippet}`); + throw new Error(`generated theme is missing required snippet: ${snippet}`); } } @@ -104,4 +88,4 @@ for (const snippet of requiredDarkSnippets) { } } -console.log("generated GitHub theme migration verified"); +console.log("generated theme verified"); diff --git a/styles/components/actions/action_svg.ts b/styles/components/actions/action_svg.ts index 0b3b47d..5dc70f8 100644 --- a/styles/components/actions/action_svg.ts +++ b/styles/components/actions/action_svg.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/components/actions/action_svg.ts. export const actionSVG = ` .page-content.repository.actions, diff --git a/styles/components/actions/actions.ts b/styles/components/actions/actions.ts index cd641ee..be6acb4 100644 --- a/styles/components/actions/actions.ts +++ b/styles/components/actions/actions.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/components/actions/actions.ts. export const actions = ` /* 避免锚中设置界面里的 Actions */ diff --git a/styles/components/actions/workflow_runs.ts b/styles/components/actions/workflow_runs.ts index f3121a9..a42665d 100644 --- a/styles/components/actions/workflow_runs.ts +++ b/styles/components/actions/workflow_runs.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/components/actions/workflow_runs.ts. export const actionViewHeader = ` .action-view-header { diff --git a/styles/components/actions/workflow_steps.ts b/styles/components/actions/workflow_steps.ts index 38f9536..b669f9b 100644 --- a/styles/components/actions/workflow_steps.ts +++ b/styles/components/actions/workflow_steps.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/components/actions/workflow_steps.ts. export const actionViewRight = ` .action-view-right { diff --git a/styles/components/actions/workflow_summary.ts b/styles/components/actions/workflow_summary.ts index 1947c88..599d8d0 100644 --- a/styles/components/actions/workflow_summary.ts +++ b/styles/components/actions/workflow_summary.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/components/actions/workflow_summary.ts. export const summaryView = ` .action-view-right:has(.action-run-summary-view) { diff --git a/styles/components/footer.ts b/styles/components/footer.ts index e0c840c..9c7fe46 100644 --- a/styles/components/footer.ts +++ b/styles/components/footer.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/components/footer.ts. export const footer = ` .page-footer { diff --git a/styles/components/heatmap.ts b/styles/components/heatmap.ts index b8c84b9..f329c51 100644 --- a/styles/components/heatmap.ts +++ b/styles/components/heatmap.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/components/heatmap.ts. export const heatmap = ` #user-heatmap { diff --git a/styles/components/issues/issue.ts b/styles/components/issues/issue.ts index 2cf3619..adc6952 100644 --- a/styles/components/issues/issue.ts +++ b/styles/components/issues/issue.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/components/issues/issue.ts. export const button = ` /* 工单&PR标题右侧按钮 */ diff --git a/styles/components/issues/issue_comment.ts b/styles/components/issues/issue_comment.ts index c7715e9..fab7c3c 100644 --- a/styles/components/issues/issue_comment.ts +++ b/styles/components/issues/issue_comment.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/components/issues/issue_comment.ts. export const comment = ` .comment .comment-container { diff --git a/styles/components/issues/issue_list.ts b/styles/components/issues/issue_list.ts index cf13479..f0ec84e 100644 --- a/styles/components/issues/issue_list.ts +++ b/styles/components/issues/issue_list.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/components/issues/issue_list.ts. export const issueList = ` /* 仓库页面的里程碑列表菜单栏 */ diff --git a/styles/components/issues/issue_sidebar.ts b/styles/components/issues/issue_sidebar.ts index 01d8000..e5cfa70 100644 --- a/styles/components/issues/issue_sidebar.ts +++ b/styles/components/issues/issue_sidebar.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/components/issues/issue_sidebar.ts. export const issueSidebar = ` /* 创建PR页面 */ diff --git a/styles/components/issues/issue_timeline.ts b/styles/components/issues/issue_timeline.ts index 1062a27..8e304fa 100644 --- a/styles/components/issues/issue_timeline.ts +++ b/styles/components/issues/issue_timeline.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/components/issues/issue_timeline.ts. export const timeline = ` .repository.view.issue { diff --git a/styles/components/navbar.ts b/styles/components/navbar.ts index a220d70..71f3ade 100644 --- a/styles/components/navbar.ts +++ b/styles/components/navbar.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/components/navbar.ts. export const navbarRight = ` #navbar { diff --git a/styles/components/notification.ts b/styles/components/notification.ts index 9160c85..60b10c8 100644 --- a/styles/components/notification.ts +++ b/styles/components/notification.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/components/notification.ts. export const notification = ` .page-content.user.notification { diff --git a/styles/components/repo/clone.ts b/styles/components/repo/clone.ts index e287542..6f7af4c 100644 --- a/styles/components/repo/clone.ts +++ b/styles/components/repo/clone.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/components/repo/clone.ts. export const clone = ` .tippy-box { diff --git a/styles/components/repo/commit.ts b/styles/components/repo/commit.ts index 0629495..ce66b89 100644 --- a/styles/components/repo/commit.ts +++ b/styles/components/repo/commit.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/components/repo/commit.ts. export const commit = ` .page-content.repository.commits { diff --git a/styles/components/repo/diff.ts b/styles/components/repo/diff.ts index e48a69f..7e0056d 100644 --- a/styles/components/repo/diff.ts +++ b/styles/components/repo/diff.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/components/repo/diff.ts. export const diff = ` /* 这里的折叠行和代码行高度与 GitHub 的 release 和 review 的差异对比时的高度一致, 不需要像 commit 中的差异对比那样行高过高 */ diff --git a/styles/components/repo/milestones.ts b/styles/components/repo/milestones.ts index ec5e744..6367ea4 100644 --- a/styles/components/repo/milestones.ts +++ b/styles/components/repo/milestones.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/components/repo/milestones.ts. export const milestone = ` /* 里程碑头部 */ diff --git a/styles/components/repo/packages.ts b/styles/components/repo/packages.ts index 837376c..2d5a827 100644 --- a/styles/components/repo/packages.ts +++ b/styles/components/repo/packages.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/components/repo/packages.ts. export const packagesList = ` .page-content.packages { diff --git a/styles/components/repo/release.ts b/styles/components/repo/release.ts index 9c8ca60..4e07e8a 100644 --- a/styles/components/repo/release.ts +++ b/styles/components/repo/release.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/components/repo/release.ts. export const releaseTagMenu = ` .page-content.repository { diff --git a/styles/components/repo/repo.ts b/styles/components/repo/repo.ts index 7775cd1..6869bb9 100644 --- a/styles/components/repo/repo.ts +++ b/styles/components/repo/repo.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/components/repo/repo.ts. export const repoHeader = ` .page-content.repository .repo-header { diff --git a/styles/components/repo/repo_file_view.ts b/styles/components/repo/repo_file_view.ts index b63f240..892be77 100644 --- a/styles/components/repo/repo_file_view.ts +++ b/styles/components/repo/repo_file_view.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/components/repo/repo_file_view.ts. export const repoFileView = ` /* 隐藏主内容的下内容和页脚, 避免滚动文件树时滚动条遮挡 */ diff --git a/styles/components/repo/repo_files.ts b/styles/components/repo/repo_files.ts index 1caa245..d2f6773 100644 --- a/styles/components/repo/repo_files.ts +++ b/styles/components/repo/repo_files.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/components/repo/repo_files.ts. export const branchButton = ` .page-content.repository.file.list { diff --git a/styles/components/repo/repo_sidebar.ts b/styles/components/repo/repo_sidebar.ts index e8e4658..b24fbdd 100644 --- a/styles/components/repo/repo_sidebar.ts +++ b/styles/components/repo/repo_sidebar.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/components/repo/repo_sidebar.ts. export const repoGrid = ` .repo-grid-filelist-sidebar { diff --git a/styles/components/templates/repo/commit_sign_badge.ts b/styles/components/templates/repo/commit_sign_badge.ts index 4c70564..0fedc91 100644 --- a/styles/components/templates/repo/commit_sign_badge.ts +++ b/styles/components/templates/repo/commit_sign_badge.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/templates/repo/commit_sign_badge.ts. export const commitSignBadge = ` a.ui.label.commit-id-short.gitea-github-theme-commit-sha { diff --git a/styles/components/templates/repo/commits_list.ts b/styles/components/templates/repo/commits_list.ts index c55b852..c27557d 100644 --- a/styles/components/templates/repo/commits_list.ts +++ b/styles/components/templates/repo/commits_list.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/templates/repo/commits_list.ts. export const commitsList = ` ul.gitea-github-theme-templates-commits-list { diff --git a/styles/components/templates/repo/view_content.ts b/styles/components/templates/repo/view_content.ts index e70b552..c26e43d 100644 --- a/styles/components/templates/repo/view_content.ts +++ b/styles/components/templates/repo/view_content.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/templates/repo/view_content.ts. export const repoButtonRow = ` .gitea-github-theme-templates { diff --git a/styles/components/templates/repo/view_list.ts b/styles/components/templates/repo/view_list.ts index cc90985..9293945 100644 --- a/styles/components/templates/repo/view_list.ts +++ b/styles/components/templates/repo/view_list.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/templates/repo/view_list.ts. export const repoFileLastCommit = ` /* 仓库页和文件列表文件夹页的最后一次提交 */ diff --git a/styles/pages/dashboard.ts b/styles/pages/dashboard.ts index 55dca67..8ce3f36 100644 --- a/styles/pages/dashboard.ts +++ b/styles/pages/dashboard.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/components/dashboard.ts. export const dashboard = ` .page-content.dashboard { diff --git a/styles/pages/explore.ts b/styles/pages/explore.ts index c69e2a5..494a568 100644 --- a/styles/pages/explore.ts +++ b/styles/pages/explore.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/components/explore.ts. export const repoList = ` /* 组织 */ diff --git a/styles/pages/newrepo.ts b/styles/pages/newrepo.ts index 8254a03..a43dcf9 100644 --- a/styles/pages/newrepo.ts +++ b/styles/pages/newrepo.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/components/newrepo.ts. export const newRepo = ` .page-content.repository.new-repo { diff --git a/styles/pages/org.ts b/styles/pages/org.ts index 9b5720c..5787915 100644 --- a/styles/pages/org.ts +++ b/styles/pages/org.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/components/org.ts. export const org = ` .page-content.organization { diff --git a/styles/pages/setting.ts b/styles/pages/setting.ts index 9410481..9e0f73f 100644 --- a/styles/pages/setting.ts +++ b/styles/pages/setting.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/components/setting.ts. export const button = ` /* 不包含管理员的设置界面 */ diff --git a/styles/pages/signin.ts b/styles/pages/signin.ts index 76979e7..0372f6f 100644 --- a/styles/pages/signin.ts +++ b/styles/pages/signin.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/components/signin.ts. export const signIn = ` .page-content.user.signin { diff --git a/styles/pages/user.ts b/styles/pages/user.ts index fd7b0f3..6eda9c4 100644 --- a/styles/pages/user.ts +++ b/styles/pages/user.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/components/user.ts. export const stars = ` .page-content.user.profile { diff --git a/styles/primitives/attached.ts b/styles/primitives/attached.ts index 091c907..6a4cffd 100644 --- a/styles/primitives/attached.ts +++ b/styles/primitives/attached.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/public/attached.ts. export const attached = ` /* 设置右面板的内容 */ diff --git a/styles/primitives/base.ts b/styles/primitives/base.ts index 0ed7b05..20b7466 100644 --- a/styles/primitives/base.ts +++ b/styles/primitives/base.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/public/base.ts. export const body = ` body { diff --git a/styles/primitives/button.ts b/styles/primitives/button.ts index 3ee792b..1bf392f 100644 --- a/styles/primitives/button.ts +++ b/styles/primitives/button.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/public/button.ts. export const baseButton = ` .ui.button { diff --git a/styles/primitives/dropdown/branch_dropdown.ts b/styles/primitives/dropdown/branch_dropdown.ts index b2dd79d..f2ed636 100644 --- a/styles/primitives/dropdown/branch_dropdown.ts +++ b/styles/primitives/dropdown/branch_dropdown.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/public/dropdown/branch_dropdown.ts. export const branchDropdown = ` .ui.dropdown.branch-selector-dropdown > .menu { diff --git a/styles/primitives/dropdown/dropdown.ts b/styles/primitives/dropdown/dropdown.ts index f3b2465..5d7dfc9 100644 --- a/styles/primitives/dropdown/dropdown.ts +++ b/styles/primitives/dropdown/dropdown.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/public/dropdown/dropdown.ts. export const dropdown = ` .ui.dropdown, diff --git a/styles/primitives/dropdown/emoji_dropdown.ts b/styles/primitives/dropdown/emoji_dropdown.ts index 839198d..094cc90 100644 --- a/styles/primitives/dropdown/emoji_dropdown.ts +++ b/styles/primitives/dropdown/emoji_dropdown.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/public/dropdown/emoji_dropdown.ts. export const emojiDropdown = ` .ui.dropdown.action.select-reaction.active .menu:has(.emoji) { diff --git a/styles/primitives/dropdown/selection_dropdown.ts b/styles/primitives/dropdown/selection_dropdown.ts index a1824dd..ca0a34c 100644 --- a/styles/primitives/dropdown/selection_dropdown.ts +++ b/styles/primitives/dropdown/selection_dropdown.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/public/dropdown/selection_dropdown.ts. export const selectionDropdown = ` /* 排除可以选择的输入搜索框和创建仓库的拥有者 */ diff --git a/styles/primitives/input.ts b/styles/primitives/input.ts index 2b6e460..f788560 100644 --- a/styles/primitives/input.ts +++ b/styles/primitives/input.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/public/input.ts. export const input = ` textarea, diff --git a/styles/primitives/label/label.ts b/styles/primitives/label/label.ts index 042f5a9..75e7584 100644 --- a/styles/primitives/label/label.ts +++ b/styles/primitives/label/label.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/public/label/label.ts. export const label = ` .ui.label { diff --git a/styles/primitives/label/repo_label.ts b/styles/primitives/label/repo_label.ts index 8a5282a..c71fad5 100644 --- a/styles/primitives/label/repo_label.ts +++ b/styles/primitives/label/repo_label.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/public/label/repo_label.ts. export const repoLabel = ` span, diff --git a/styles/primitives/label/sha_label.ts b/styles/primitives/label/sha_label.ts index 082b15c..e55b07d 100644 --- a/styles/primitives/label/sha_label.ts +++ b/styles/primitives/label/sha_label.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/public/label/sha_label.ts. export const shaLabel = ` a.ui.label.sha, diff --git a/styles/primitives/label/task_status_label.ts b/styles/primitives/label/task_status_label.ts index 2458d26..b5849fa 100644 --- a/styles/primitives/label/task_status_label.ts +++ b/styles/primitives/label/task_status_label.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/public/label/task_status_label.ts. export const taskStatusLabel = ` .runner-container .ui.label.task-status- { diff --git a/styles/primitives/menu/compact_menu.ts b/styles/primitives/menu/compact_menu.ts index e9b3f46..f43f668 100644 --- a/styles/primitives/menu/compact_menu.ts +++ b/styles/primitives/menu/compact_menu.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/public/menu/compact_menu.ts. export const smallCompactMenu = ` /* 编辑/预览切换菜单(仓库编辑文件时的编辑器操作栏左侧) */ diff --git a/styles/primitives/menu/menu.ts b/styles/primitives/menu/menu.ts index d6d2776..73d7c6a 100644 --- a/styles/primitives/menu/menu.ts +++ b/styles/primitives/menu/menu.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/public/menu/menu.ts. export const menu = ` .ui.menu { diff --git a/styles/primitives/menu/pagination_menu.ts b/styles/primitives/menu/pagination_menu.ts index 753f1c5..3c2ac1b 100644 --- a/styles/primitives/menu/pagination_menu.ts +++ b/styles/primitives/menu/pagination_menu.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/public/menu/pagination_menu.ts. export const paginationMenu = ` .ui.borderless.pagination.menu { diff --git a/styles/primitives/menu/secondary_menu.ts b/styles/primitives/menu/secondary_menu.ts index 11ce3d2..cd49003 100644 --- a/styles/primitives/menu/secondary_menu.ts +++ b/styles/primitives/menu/secondary_menu.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/public/menu/secondary_menu.ts. export const secondaryMenu = ` /* 二级菜单, 比如 Issue/PR/Actions 的筛选菜单 */ diff --git a/styles/primitives/menu/vertical_menu.ts b/styles/primitives/menu/vertical_menu.ts index caa0c34..943433c 100644 --- a/styles/primitives/menu/vertical_menu.ts +++ b/styles/primitives/menu/vertical_menu.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/public/menu/vertical_menu.ts. export const verticalMenu = ` /* 垂直菜单, 用于左侧边栏 */ diff --git a/styles/primitives/modal.ts b/styles/primitives/modal.ts index 9c5aa7f..4824866 100644 --- a/styles/primitives/modal.ts +++ b/styles/primitives/modal.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/public/modal.ts. export const modal = ` .ui.modal { diff --git a/styles/primitives/other.ts b/styles/primitives/other.ts index 41e4e3d..0ee5299 100644 --- a/styles/primitives/other.ts +++ b/styles/primitives/other.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/public/other.ts. export const text = ` /* 默认颜色是 --color-text-light, 主题下此颜色是亮白色, 修改为灰色 */ diff --git a/styles/primitives/radius.ts b/styles/primitives/radius.ts index a43f325..d240dcb 100644 --- a/styles/primitives/radius.ts +++ b/styles/primitives/radius.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/public/radius.ts. export const radius = ` .ui.form textarea, diff --git a/styles/primitives/table.ts b/styles/primitives/table.ts index 8f82120..de114ae 100644 --- a/styles/primitives/table.ts +++ b/styles/primitives/table.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/public/table.ts. export const table = ` .ui.table > tr > td, diff --git a/styles/primitives/tippy.ts b/styles/primitives/tippy.ts index 44f86c8..e8372e8 100644 --- a/styles/primitives/tippy.ts +++ b/styles/primitives/tippy.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/public/tippy.ts. export const tippyBox = ` .tippy-box { diff --git a/styles/primitives/transition.ts b/styles/primitives/transition.ts index e8ef309..c5b87e5 100644 --- a/styles/primitives/transition.ts +++ b/styles/primitives/transition.ts @@ -1,4 +1,3 @@ -// Migrated from .github-theme/styles/public/transition.ts. export const transition = ` /* 差异对比的代码折叠按钮 */