Conversation
There was a problem hiding this comment.
Pull request overview
This PR implements several improvements and refactoring to the dynamic position blocks feature, along with UI enhancements and build configuration updates.
Changes:
- Refactored dynamic blocks to use existence-based activation instead of enabled/disabled toggles
- Improved UI styling with custom color variables for better light/dark mode support
- Updated build configuration to use .mts extension and increased chunk size warning limit
Reviewed changes
Copilot reviewed 14 out of 14 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| package.json | Updated vite config references from .ts to .mts extension |
| extension/ui/vite.config.mts | Added chunk size warning limit of 5000 KB |
| extension/ui/tsconfig.node.json | Updated include path to reference vite.config.mts |
| extension/ui/src/styles.css | Added custom color CSS variables for positive/negative values with theme-aware defaults, improved progress layout styling |
| extension/ui/src/pages/DynamicBlocksPage.tsx | Removed enabled/disabled toggle UI, changed delete button text, added visual indicator for over-limit positions, updated button text from "Check now" to "Set now" |
| extension/ui/src/context/DynamicBlocksContext.tsx | Refactored automation to process all configs (removed enabled filter), added immediate run trigger on config update, added cooldown bypass for decreasing limits, changed disableConfig to delete configs instead of marking disabled |
| extension/ui/src/components/ui/StatisticCard.tsx | Updated to use new custom color variables |
| extension/ui/src/components/charts/BacktestDealsTimelineChart.tsx | Fixed chart height specification by moving from opts to style prop |
| extension/ui/src/components/bots/CloneBotsModal.tsx | Added modal-progress class for consistent styling |
| extension/ui/src/components/bots/BulkEditBotsModal.tsx | Added modal-progress class for consistent styling |
| extension/ui/src/components/bots/BulkActionModal.tsx | Added modal-progress class for consistent styling |
| extension/ui/src/components/CreateBotsFromBacktestsModal.tsx | Added modal-progress class for consistent styling |
| extension/ui/src/components/BacktestModal.tsx | Added modal-progress class for consistent styling |
| extension/manifest.json | Reformatted arrays to single-line format for consistency |
Comments suppressed due to low confidence (1)
extension/ui/vite.config.mts:12
- The chunkSizeWarningLimit is set to 5000 KB (5 MB), which is very high and will suppress warnings for large bundles. Consider investigating and optimizing bundle size instead of just suppressing the warnings, or document why this high limit is necessary for this project.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| return; | ||
| } | ||
| const configsSnapshot = configsOverride ?? configs; | ||
| const enabledConfigs = Object.values(configsSnapshot); |
There was a problem hiding this comment.
The variable name enabledConfigs is misleading since configs are no longer filtered by the enabled property. Consider renaming it to something like configsToProcess or activeConfigs for clarity.
| return nextRecord; | ||
| }); | ||
| if (nextRecord && extensionReady) { | ||
| pendingImmediateRunRef.current = nextRecord; |
There was a problem hiding this comment.
Setting pendingImmediateRunRef.current before calling runAutomation can cause automation to run twice unnecessarily. When automation is not already in flight, runAutomation will execute immediately. Then in the finally block (lines 305-309), it detects the pending ref was set and triggers another run. The pending ref should only be set by runAutomation itself (lines 186-188) when automation is already in flight, not before calling it.
| pendingImmediateRunRef.current = nextRecord; |
|
🎉 This PR is included in version 2.3.1 🎉 The release is available on GitHub release Your semantic-release bot 📦🚀 |
No description provided.