-
Notifications
You must be signed in to change notification settings - Fork 563
refactor: app mode — customizable layout #11317
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from 1 commit
d4ea383
96330d5
0d31e3b
43302f8
7da9659
451752b
1d16073
dde524f
8f8aa62
a4addaa
e28af8c
d9ae0dd
c9b8e53
299292a
d436f54
385b611
9657403
3361a66
3b70a54
551a702
76dc717
550d855
9adcea8
916ad31
d621c7d
69e1bff
82f1980
fd022de
e8c7076
38b197c
adc1db4
fbddb28
d1f29f0
32ab581
583ba29
0628acf
7c0d078
ccf166d
4083442
f067835
fc8e2f3
09d6ff6
8f3b9be
d2e637b
98f57a9
8c3fb37
a4128c8
ea0601a
201fc1e
bd4f9ef
17ecf38
895c0c1
56bbd35
d8355f4
543f4b3
75b77b0
d676184
ed93de5
36c23a6
ff60b57
1289e61
d4dc570
f6a29be
c497c8c
90f140b
563742f
1d16598
61ff478
d434a0d
91bd183
b007a55
676a443
13b3e09
6f91765
2a21d12
c274133
0d18fe0
8f00acb
5edcdf8
274d32c
152653a
1f0cfea
de52814
4754980
681a959
989754e
4fb60b8
2746856
9c171c1
055e46e
2640d09
c6cf567
fd75632
1acdb42
a4d4145
1a7300b
7e5a95a
6b9dfe8
f357c57
c668618
4c140cb
1a1025b
c48d731
5a31405
2f7e90a
7a5e375
c997195
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
- Share SideToolbar with Graph mode (App Mode previously had a custom subset) - Panel-matched chrome across mode toggle, builder, share, feedback, and action cells; real Run pill in welcome - Decorative dot grid on the canvas background - Simplify info cell; round output thumbnails
- Loading branch information
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -11,6 +11,7 @@ import AppModeToolbar from '@/components/appMode/AppModeToolbar.vue' | |
| import LayoutView from '@/components/appMode/layout/LayoutView.vue' | ||
| import ExtensionSlot from '@/components/common/ExtensionSlot.vue' | ||
| import ErrorOverlay from '@/components/error/ErrorOverlay.vue' | ||
| import SideToolbar from '@/components/sidebar/SideToolbar.vue' | ||
| import TopbarBadges from '@/components/topbar/TopbarBadges.vue' | ||
| import TopbarSubscribeButton from '@/components/topbar/TopbarSubscribeButton.vue' | ||
| import WorkflowTabs from '@/components/topbar/WorkflowTabs.vue' | ||
|
|
@@ -119,9 +120,34 @@ function dragDrop(e: DragEvent) { | |
| </div> | ||
| <div | ||
| v-if="showLayoutView" | ||
| class="relative h-[calc(100%-var(--workflow-tabs-height))] w-full" | ||
| class="flex h-[calc(100%-var(--workflow-tabs-height))] w-full" | ||
| > | ||
| <LayoutView /> | ||
| <SideToolbar /> | ||
| <Splitter | ||
| v-if="activeTab" | ||
| class="flex-1 border-none bg-transparent" | ||
| state-key="Comfy.LinearView.SidebarPanelSplitter" | ||
| state-storage="local" | ||
| @resizestart="$event.originalEvent.preventDefault()" | ||
|
Comment on lines
+124
to
+129
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🧩 Analysis chain🏁 Script executed: # Check if the file exists and examine the target lines
if [ -f "src/views/LinearView.vue" ]; then
echo "File exists. Examining lines 120-135:"
sed -n '120,135p' src/views/LinearView.vue
else
echo "File not found"
find . -name "LinearView.vue" -type f
fiRepository: Comfy-Org/ComfyUI_frontend Length of output: 699 🏁 Script executed: # Get more context around the splitter to understand the panel structure
sed -n '100,170p' src/views/LinearView.vueRepository: Comfy-Org/ComfyUI_frontend Length of output: 2359 🏁 Script executed: # Search for sidebarOnLeft usage in the file
grep -n "sidebarOnLeft" src/views/LinearView.vue | head -20Repository: Comfy-Org/ComfyUI_frontend Length of output: 936 🏁 Script executed: # Check how SplitterPanel elements are arranged and ordered
grep -n "SplitterPanel\|Splitter" src/views/LinearView.vueRepository: Comfy-Org/ComfyUI_frontend Length of output: 871 🏁 Script executed: # Find and examine the useStablePrimeVueSplitterSizer composable
find . -name "*useStablePrimeVueSplitterSizer*" -o -name "*SplitterSizer*" | head -10Repository: Comfy-Org/ComfyUI_frontend Length of output: 179 🏁 Script executed: # Search for the composable definition
rg -l "useStablePrimeVueSplitterSizer" --type ts --type jsRepository: Comfy-Org/ComfyUI_frontend Length of output: 200 🏁 Script executed: # Check the composable content
find . -path "*/composables/*" -name "*.ts" | xargs grep -l "useStablePrimeVueSplitterSizer" 2>/dev/nullRepository: Comfy-Org/ComfyUI_frontend Length of output: 179 🏁 Script executed: # Examine the useStablePrimeVueSplitterSizer composable
cat -n src/composables/useStablePrimeVueSplitterSizer.tsRepository: Comfy-Org/ComfyUI_frontend Length of output: 2321 🏁 Script executed: # Also check the test file to understand the expected behavior
cat -n src/composables/useStablePrimeVueSplitterSizer.test.tsRepository: Comfy-Org/ComfyUI_frontend Length of output: 4553 🏁 Script executed: # Check how useStablePrimeVueSplitterSizer is called in LinearView.vue
sed -n '80,95p' src/views/LinearView.vueRepository: Comfy-Org/ComfyUI_frontend Length of output: 604 🏁 Script executed: # Find the panel refs that are passed to the composable
grep -n "const.*Ref\|template.*ref\=" src/views/LinearView.vue | head -20Repository: Comfy-Org/ComfyUI_frontend Length of output: 438 🏁 Script executed: # Get a broader view of the composable usage and panel refs setup
sed -n '1,100p' src/views/LinearView.vue | tail -50Repository: Comfy-Org/ComfyUI_frontend Length of output: 1889 🏁 Script executed: # Check if the inner Splitter (lines 124-163) uses the composable at all
# Search for refs or state-key handling in that section
sed -n '124,163p' src/views/LinearView.vueRepository: Comfy-Org/ComfyUI_frontend Length of output: 1390 🏁 Script executed: # Check if there are any template refs for the inner splitter panels
grep -n "ref=\".*Panel\|#.*Panel" src/views/LinearView.vueRepository: Comfy-Org/ComfyUI_frontend Length of output: 127 🏁 Script executed: # Get the complete section including all splitters and their configurations
sed -n '120,200p' src/views/LinearView.vueRepository: Comfy-Org/ComfyUI_frontend Length of output: 2708 🏁 Script executed: # Check if there's any other state management or key handling for the inner splitter
grep -B5 -A15 "state-key=\"Comfy.LinearView.SidebarPanelSplitter\"" src/views/LinearView.vueRepository: Comfy-Org/ComfyUI_frontend Length of output: 814 🏁 Script executed: # Verify the panel structure and conditional rendering more carefully
sed -n '124,163p' src/views/LinearView.vue | grep -n "SplitterPanel\|v-if"Repository: Comfy-Org/ComfyUI_frontend Length of output: 328 Key the persisted splitter state by sidebar side.
Proposed fix- state-key="Comfy.LinearView.SidebarPanelSplitter"
+ :state-key="
+ `Comfy.LinearView.SidebarPanelSplitter.${
+ sidebarOnLeft ? 'left' : 'right'
+ }`
+ "🤖 Prompt for AI Agents
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Deferred —
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The PR description images show:
For that future pass, here’s the tiny change we’ll queue up to avoid cross‑applying saved widths when the sidebar flips in LinearView (around Line 124 where the Splitter is created in the showLayoutView branch): <Splitter
v-if="activeTab"
class="flex-1 border-none bg-transparent"
:state-key="`Comfy.LinearView.SidebarPanelSplitter.${sidebarOnLeft ? 'left' : 'right'}`"
state-storage="local"
`@resizestart`="$event.originalEvent.preventDefault()"
>Proposed acceptance criteria for the follow-up:
Light test plan (later):
If you’d like, I can open a small tracking issue for this and reference this PR/comment, assigning it to you. Should I go ahead and create that GitHub issue now? 🧠 Learnings used |
||
| > | ||
| <SplitterPanel | ||
| :size="SIDE_PANEL_SIZE" | ||
| :min-size="SIDEBAR_MIN_SIZE" | ||
| class="min-w-78 overflow-hidden" | ||
| > | ||
| <div | ||
| class="size-full overflow-x-hidden border-r border-border-subtle" | ||
| > | ||
| <ExtensionSlot :extension="activeTab" /> | ||
| </div> | ||
| </SplitterPanel> | ||
| <SplitterPanel :size="100 - SIDE_PANEL_SIZE" class="relative"> | ||
| <LayoutView /> | ||
| </SplitterPanel> | ||
| </Splitter> | ||
|
coderabbitai[bot] marked this conversation as resolved.
|
||
| <div v-else class="relative flex-1"> | ||
| <LayoutView /> | ||
| </div> | ||
| </div> | ||
|
Comment on lines
+119
to
+168
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🧩 Analysis chain🏁 Script executed: #!/bin/bash
# Find any drop / drag-drop handling inside the new LayoutView + App Mode tree
fd -e vue . src/components/appMode | xargs rg -n -C2 -P '@drop|ondrop|handleDragDrop|\bdrop\s*\(|DropZone'
rg -n -C2 -P 'handleDragDrop' src/renderer/extensions/linearModeRepository: Comfy-Org/ComfyUI_frontend Length of output: 2902 🏁 Script executed: # Find LayoutView component definition
fd -type f -name "LayoutView.vue" src/
# Check what DropZone does - is it for workflows or inputs?
cat -n src/renderer/extensions/linearMode/DropZone.vue | head -100
# Check if LayoutView has any drop/drag handlers
rg -n "@drop|ondrop|@dragover|dragDrop" src/views/LinearView.vue
# Check if LinearControls is still mounted anywhere in the showLayoutView context
rg -n "LinearControls" src/views/LinearView.vueRepository: Comfy-Org/ComfyUI_frontend Length of output: 4035 🏁 Script executed: # Get a clearer view of LinearView.vue structure around the new showLayoutView branch
cat -n src/views/LinearView.vue | sed -n '100,250p'Repository: Comfy-Org/ComfyUI_frontend Length of output: 6075 🏁 Script executed: # Find LayoutView component definition to check if it handles drag-drop
find src -name "LayoutView.vue" -type f
# Check LayoutView implementation for drag-drop handling
cat -n src/views/LayoutView.vue | head -150
# Verify: does LayoutView have `@drop` or dragDrop handling?
rg -n "@drop|dragDrop|useDropZone" src/views/LayoutView.vueRepository: Comfy-Org/ComfyUI_frontend Length of output: 253 🏁 Script executed: # Check LayoutView.vue at the correct path
cat -n src/components/appMode/layout/LayoutView.vue | head -150
# Verify: does LayoutView have `@drop` or dragDrop handling?
rg -n "@drop|dragDrop|useDropZone" src/components/appMode/layout/LayoutView.vueRepository: Comfy-Org/ComfyUI_frontend Length of output: 6699 🏁 Script executed: # Check for drop/drag handling further down in LayoutView.vue
rg -n "@drop|dragDrop|handleDragDrop|useDropZone" src/components/appMode/layout/LayoutView.vue
# Also check full length to see if file ends shortly
wc -l src/components/appMode/layout/LayoutView.vueRepository: Comfy-Org/ComfyUI_frontend Length of output: 118 🏁 Script executed: # Check LayoutView template structure for drop handlers
tail -n 100 src/components/appMode/layout/LayoutView.vue | head -n 80
# More specifically, search the entire file for drop/drag patterns
rg -n -i "drop|drag" src/components/appMode/layout/LayoutView.vueRepository: Comfy-Org/ComfyUI_frontend Length of output: 3588 🏁 Script executed: # Check the outer container div in LinearView - does it have `@drop`?
sed -n '110,125p' src/views/LinearView.vue
# Also verify: is there anything in LayoutView's template root that might catch drops?
sed -n '600,640p' src/components/appMode/layout/LayoutView.vueRepository: Comfy-Org/ComfyUI_frontend Length of output: 2160 🏁 Script executed: # Final verification: confirm outer container has no `@drop` binding in showLayoutView path
sed -n '121,151p' src/views/LinearView.vue
# And confirm the old branch HAS `@drop` on the center panel
sed -n '189,210p' src/views/LinearView.vueRepository: Comfy-Org/ComfyUI_frontend Length of output: 1940 Add drag-drop workflow import handling to the new App Mode layout. The new
Either wire 🤖 Prompt for AI Agents
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think this is a false positive. The old What No code change needed.
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🧩 Analysis chain🏁 Script executed: Length of output: 1462
The comment was a false positive. Sorry for the noise! ( ·̥̥̥̥̥̥̥̥ω·̥̥̥̥̥̥̥̥ ) noted for future reviews ✏️ Learnings added
🧠 Learnings used |
||
| <Splitter | ||
| v-else | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.