Conversation
feat: optimize charts style Signed-off-by: yingxuan <zhanglujia.zlj@digital-engine.com> Co-authored-by: yingxuan <zhanglujia.zlj@digital-engine.com>
Signed-off-by: 杨家乐 <yjl516914@digital-engine.com> Co-authored-by: 杨家乐 <yjl516914@digital-engine.com>
Signed-off-by: 杨家乐 <yjl516914@digital-engine.com>
Signed-off-by: 杨家乐 <yjl516914@digital-engine.com>
Signed-off-by: 杨家乐 <yjl516914@digital-engine.com>
Signed-off-by: 杨家乐 <yjl516914@digital-engine.com>
Allow viewing blacklist details dialog even with single item
- Restructure blacklist UI with separate applications, urls, tags, priorities fields - Fix priorities type conversion from string to int for backend compatibility - Add duplicate combination validation for service/task type/feature - Improve data preservation when updating blacklist fields - Sync blacklist updates to preheats/new.tsx
Signed-off-by: 杨家乐 <yjl516914@digital-engine.com>
Signed-off-by: 杨家乐 <yjl516914@digital-engine.com>
- Remove Dragonfly dual push skill implementation plan - Remove test-push.md documentation
- 批量修复Git提交作者信息脚本 - 双仓库安全分支同步脚本 - 配置文件用于仓库管理
- Add /scripts to gitignore for local development scripts
- Remove Git management scripts as they should be local only - Keep scripts in .gitignore for future local development
为"Add cluster"按钮文本添加 paddingTop 以改善垂直对齐效果
Signed-off-by: 杨佳乐 <yjl516914@digital-engine.com>
Signed-off-by: 杨佳乐 <yjl516914@digital-engine.com>
Signed-off-by: 槿花 <yangjiale@U-0FL67Y02-2001.local>
Signed-off-by: 槿花 <yangjiale@U-0FL67Y02-2001.local>
Signed-off-by: 槿花 <yangjiale@U-0FL67Y02-2001.local>
There was a problem hiding this comment.
Pull request overview
This PR introduces cluster blacklist/blocklist configuration in the cluster create/edit flows and surfaces the resulting configuration on the cluster information page, along with related UI polish and expanded Cypress coverage/CI updates.
Changes:
- Add a new Cluster “Blocklist/Blacklist” editor component and send
block_listin create/edit cluster payloads. - Render cluster blacklist details in the Cluster Information page and add styling for the new section.
- Expand Cypress E2E coverage and adjust CI/workflows (Node 20, Cypress split, config tweaks); includes assorted UI alignment/chart refactors.
Reviewed changes
Copilot reviewed 35 out of 36 changed files in this pull request and generated 13 comments.
Show a summary per file
| File | Description |
|---|---|
| test-dual-push.md | Adds a local dual-repo push test note (appears unrelated to feature). |
| src/lib/api.ts | Extends cluster response types to include block_list. |
| src/index.css | Adds new palette CSS variables (error/disabled/button hover). |
| src/components/users/index.tsx | Wraps button label text for alignment. |
| src/components/resource/task/clear/index.tsx | Wraps toggle/button labels; minor formatting fixes. |
| src/components/resource/persistent-cache-task/show.tsx | Wraps delete button label for alignment. |
| src/components/resource/persistent-cache-task/analytics/index.tsx | Refactors analytics aggregation + chart options/gradients. |
| src/components/resource/persistent-cache-task/analytics/index.module.css | Adjusts layout sizing for analytics visuals. |
| src/components/loading-button.tsx | Wraps button text for alignment. |
| src/components/job/preheats/new.tsx | UI layout refactor for URL inputs; wraps button labels; formatting cleanup. |
| src/components/job/preheats/index.tsx | Wraps “add preheat” label for alignment. |
| src/components/gc/job/index.tsx | Wraps button labels; formatting-only change in ternary indentation. |
| src/components/gc/audit/index.tsx | Wraps button labels for alignment. |
| src/components/developer/tokens/index.tsx | Wraps “Add Personal access tokens” label for alignment. |
| src/components/clusters/seed-peers/index.tsx | Wraps delete-inactive label for alignment. |
| src/components/clusters/schedulers/index.tsx | Wraps delete-inactive label; minor formatting. |
| src/components/clusters/peers/index.tsx | Refactors chart options/palettes; wraps action button labels. |
| src/components/clusters/new.tsx | Adds blacklist ref + payload injection; renders new blacklist editor. |
| src/components/clusters/information.tsx | Adds blacklist table rendering to cluster info page; wraps action labels. |
| src/components/clusters/information.module.css | Adds dedicated styling for the blacklist section/table. |
| src/components/clusters/index.tsx | Wraps “Add cluster” label for alignment. |
| src/components/clusters/edit.tsx | Adds blacklist ref + payload injection; renders blacklist editor for editing. |
| src/components/clusters/blacklist.tsx | New blacklist editor component (Autocomplete-based) with URL/priority handling. |
| package.json | Adds engines constraints (Node/Yarn). |
| cypress/fixtures/clusters/cluster/empty-cluster.json | Adds empty-cluster fixture for cluster info tests. |
| cypress/e2e/menu/menu.cy.ts | Makes menu navigation test more robust by expanding/collapsing sidebar. |
| cypress/e2e/clusters/information.cy.ts | Adds E2E coverage for cluster information page scenarios. |
| cypress/e2e/clusters/cluster.cy.ts | Updates tests to reflect commented-out seed-peer cluster ID UI and clipboard checks. |
| cypress/e2e/clusters/blacklist.cy.ts | Adds comprehensive E2E coverage for blacklist create/edit flows. |
| cypress/e2e/clusters/blacklist-detail.cy.ts | Adds E2E coverage for blacklist rendering on detail page. |
| cypress.config.ts | Updates Cypress runtime config (timeouts, retries, viewport, video). |
| .gitignore | Adds /scripts ignore entry. |
| .github/workflows/release.yml | Updates workflow Node version to 20.x. |
| .github/workflows/lint.yaml | Updates workflow Node version to 20.x. |
| .github/workflows/e2e.yaml | Updates workflow Node version to 20.x; increases split containers and sets split env. |
| .github/workflows/ci.yaml | Updates workflow Node version to 20.x; removes build dependency on test job. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Signed-off-by: yangjiale <yjl516914@digital-engine.com>
Codecov Report❌ Patch coverage is ❌ Your patch check has failed because the patch coverage (66.94%) is below the target coverage (90.00%). You can increase the patch coverage or adjust the target coverage. Additional details and impacted files@@ Coverage Diff @@
## main #681 +/- ##
===========================================
- Coverage 96.49% 46.87% -49.62%
===========================================
Files 52 53 +1
Lines 5785 6110 +325
Branches 1854 1944 +90
===========================================
- Hits 5582 2864 -2718
- Misses 187 3239 +3052
+ Partials 16 7 -9
🚀 New features to boost your workflow:
|
Signed-off-by: yangjiale <yjl516914@digital-engine.com>
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 34 out of 35 changed files in this pull request and generated 8 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| blacklist.map((item, index) => { | ||
| const duplicateInfo = getDuplicateInfo(); | ||
| const duplicateError = duplicateInfo.get(index); | ||
| const isSubConfigDownload = item.subConfig === 'download'; |
There was a problem hiding this comment.
getDuplicateInfo() is recomputed inside the .map() for every blacklist row, making rendering O(n^2). Compute duplicates once per render (e.g., with useMemo based on blacklist) and reuse it for each row.
| const blacklistData = reverseBlacklistFromData( | ||
| cluster?.peer_cluster_config || {}, | ||
| cluster?.seed_peer_cluster_config || {}, |
There was a problem hiding this comment.
blacklistData is recomputed on every render, so the useMemo for groupBlacklistData will also rerun every render because the dependency identity changes. Consider memoizing blacklistData (e.g., useMemo keyed on cluster.peer_cluster_config.block_list / cluster.seed_peer_cluster_config.block_list) or moving the reverseBlacklistFromData(...) call inside the groupBlacklistData memo.
| const blacklistData = reverseBlacklistFromData( | |
| cluster?.peer_cluster_config || {}, | |
| cluster?.seed_peer_cluster_config || {}, | |
| const blacklistData = useMemo( | |
| () => | |
| reverseBlacklistFromData( | |
| cluster?.peer_cluster_config || {}, | |
| cluster?.seed_peer_cluster_config || {}, | |
| ), | |
| [cluster?.peer_cluster_config?.block_list, cluster?.seed_peer_cluster_config?.block_list], |
| seed_peer_cluster_config: { | ||
| load_limit: number; | ||
| block_list?: Record<string, any>; | ||
| }; |
There was a problem hiding this comment.
block_list is typed as Record<string, any>, which defeats type-safety for a key config surface and makes downstream usage error-prone. Prefer a structured type (or at least Record<string, unknown> with runtime narrowing) that reflects the expected task/persistent_* -> download/upload -> { applications, urls, tags, priorities } shape.
| peer_cluster_config: { | ||
| load_limit: number; | ||
| block_list?: Record<string, any>; | ||
| }; |
There was a problem hiding this comment.
block_list is typed as Record<string, any>, which removes compile-time guarantees for this config structure. Prefer a dedicated type (or unknown with narrowing) so UI code can safely read applications/urls/tags/priorities without relying on any.
Signed-off-by: yangjiale <yjl516914@digital-engine.com>
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 34 out of 35 changed files in this pull request and generated 6 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Signed-off-by: yangjiale <yjl516914@digital-engine.com>
Description
Related Issue
Motivation and Context
Screenshots (if appropriate):
Types of changes
Checklist