-
Notifications
You must be signed in to change notification settings - Fork 447
Implement subgraph publishing #5139
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
Merged
Merged
Changes from all commits
Commits
Show all changes
46 commits
Select commit
Hold shift + click to select a range
6187e7a
Implement subgraph publishing
AustinMroz e152668
Add missing null check
AustinMroz 68a848b
Fix subgraph blueprint display in workflows tab
AustinMroz a73560d
Fix demotion of subgraph blueprints on reload
AustinMroz 3b389a6
Update locales [skip ci]
invalid-email-address 7ef287c
Update blueprint def on save, cleanup
AustinMroz 7eb732a
Fix skipped tracking on subgraph publish
AustinMroz 44ff3f9
Fix failing vite tests
AustinMroz 2ac34da
Make blueprint breadcrumb badge clickable
AustinMroz bae864f
Add confirmation for overwrite on publish
AustinMroz b6a1db8
Simplify blueprint badge naming
AustinMroz f57c0e5
Swap to promise.allSettled when fetching subgraphs
AustinMroz a8f2fda
Navigate into subgraph on blueprint edit
AustinMroz 5cf5a30
Revert mission of value in blueprint breadcrumb
AustinMroz 4ca6fcc
Misc code quality fixes
AustinMroz 03222eb
Set subgraphNode title on blueprint add.
AustinMroz 55cb9f2
Add "Delete Blueprint" option to breadcrumb
AustinMroz bd9797a
Extract subgraph load code as function
AustinMroz b4eabe9
Fix subgraphs appearing in library after refresh
AustinMroz 48cdf7b
Add delete button and confirmation for deletion
AustinMroz a943e8b
Use more specific warning for blueprint deletion
AustinMroz 91730ea
At success toast on subgraph publish
AustinMroz 2fec269
Don't apply subgraph context menu to normal nodes
AustinMroz 8c1b167
Remove hardcoded subgraphs path
AustinMroz aff0940
Fix nodeDef update on save
AustinMroz 559a7eb
Fix SaveAs with subgraph blueprints
AustinMroz 879b342
Remove ugly serialize/deserialize
AustinMroz cecad6c
Improve error specificity
AustinMroz a8ce2c9
Framework for user defined blueprint descriptions
AustinMroz 383a65e
Cleanup breadcrumb dropdown options
AustinMroz 7c567d8
Move blueprint renaming into blueprint load
AustinMroz a2bf4e2
Move saveAs prompt into workflow class
AustinMroz 1fa9ab6
Fix tests by making subgraphBlueprint internal
AustinMroz 035529f
Add tests for subgraph blueprints
AustinMroz 12c1a56
Rewrite confirmation dialog
AustinMroz 9bb69c0
Fix overwrite on publish new subgraph
AustinMroz 1c3bbd1
When editing blueprint, tint background blue
AustinMroz 3349b25
Fix blueprint tint at low LOD
AustinMroz 23dccb8
Set node source for blueprints to Blueprint
AustinMroz 540a104
Fix publish test
AustinMroz 2d21b1f
Fix multiple nits
AustinMroz 744219f
Further cleanup: error handling, and comments
AustinMroz 3fdb599
Fixing failing test cases
AustinMroz 4b7ca90
Fix temporary marking on publish.
AustinMroz 5475c5a
Block unloading subgraph blueprints
AustinMroz 415775b
Merge main into austin/subgraph-publishing
AustinMroz File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
37 changes: 37 additions & 0 deletions
37
src/components/graph/selectionToolbox/SaveToSubgraphLibrary.vue
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,37 @@ | ||
| <template> | ||
| <Button | ||
| v-show="isVisible" | ||
| v-tooltip.top="{ | ||
| value: t('commands.Comfy_PublishSubgraph.label'), | ||
| showDelay: 1000 | ||
| }" | ||
| severity="secondary" | ||
| text | ||
| @click="() => commandStore.execute('Comfy.PublishSubgraph')" | ||
| > | ||
| <template #icon> | ||
| <i-lucide:book-open /> | ||
| </template> | ||
| </Button> | ||
| </template> | ||
|
|
||
| <script setup lang="ts"> | ||
| import Button from 'primevue/button' | ||
| import { computed } from 'vue' | ||
| import { useI18n } from 'vue-i18n' | ||
|
|
||
| import { SubgraphNode } from '@/lib/litegraph/src/litegraph' | ||
| import { useCommandStore } from '@/stores/commandStore' | ||
| import { useCanvasStore } from '@/stores/graphStore' | ||
|
|
||
| const { t } = useI18n() | ||
| const commandStore = useCommandStore() | ||
| const canvasStore = useCanvasStore() | ||
|
|
||
| const isVisible = computed(() => { | ||
| return ( | ||
| canvasStore.selectedItems?.length === 1 && | ||
| canvasStore.selectedItems[0] instanceof SubgraphNode | ||
| ) | ||
| }) | ||
| </script> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.