Commit Graph
68 Commits
Author SHA1 Message Date
JaredTherriault 2c53fa8dfd Fix image loading in Extra Networks 2024-04-21 16:04:44 -07:00
JaredTherriault 6cbd1440f1 video_preview polish
-Enable controls on video preview
-Account for file paths deeper than 3 folders
-Rename some variables for clarity
2024-04-18 22:38:04 -07:00
JaredTherriault 8c0920657c Add agnostic VideoControls
-Create VideoControls script for agnostic control of video elements
-Update classes to use VideoControls where appropriate
-Create jnodes_image_drawer_payload payload for drag and drop from image drawer to upload nodes
-Add href to fileInfo on imageElement creation to facilitate payload
2024-04-18 22:36:33 -07:00
JaredTherriault b1a44cf0cc Add playbackRate video option, improve menu widget options
-Add option for playback rate (speed)
-Add hotkeys for changing playback rate ( , and . )
-Add labeled number input widget
-Inherit labeled widget types from base class
-Add option for onchange to above base class
-Clamp numbers when setting numeric values on videos
-Add some helper functions to video elements
-Remove bPropagateOnChange, roll functionality into forEachElement delegate
-Add widgetType parameter to inform the widget type to be created
-Removed unnecessary and incorrect comments
2024-04-18 17:58:33 -07:00
JaredTherriault a514999008 video_preview improvements
-Add ogg support
-Set video parameters before load (fixes autoplay)
-Remove unnecessary OR
-Rename preview widget
-Remove widget video typing (not necessary)
2024-04-18 13:58:27 -07:00
JaredTherriault 4890108b8f Remove unnecessary include 2024-04-18 13:55:28 -07:00
JaredTherriault e6b546c99a Fix indefinite recursion bug with handleFile, add ogg support for video metadata 2024-04-18 10:37:27 -07:00
JaredTherriault ebd1b837d6 Add function to hide tooltip in imageElements and hide tooltip on drag start 2024-04-18 10:35:48 -07:00
JaredTherriault 2eb479473a Add loadFileFromURL to Utilities.js 2024-04-18 10:35:23 -07:00
JaredTherriault f0e9347640 Major video update, ConfigSettings improvements, js async cancellation, load optimizations
-Roll UiSettings into SettingsManager
-Account for ConfigSettings that are objects by loading default values then loading config value son top
-Set ConfigSetting values using JSON.stringify
-Separate flyout generation into generic function
-Add video settings flyout in subfolderexplorer contexts
-Add option to control slider range value label fractional digits
-Update default slider range values to reflect 1-100 values rather than 0-1
-Rename ImageDrawerContext description to tooltip
-Update 'flex' alignment to 'normal' in context toolbars
-Automatically cancel async js operations when switching contexts
-blur or unfocus toolbar buttons on click to avoid accidental clearing or refreshing
-Get setting_ModelCardAspectRatio value as number
-Implement method to avoid lazy loading of images
-Lay some groundwork for unimplemented cancellation requests for python tasks
-Separated image list and search variables and functions to a separate script, ImageListAndSearch
-Update extra networks toolbar buttons to have a bespoke class and use specific cursor styles
-Update ImageElements 'complete' to 'bComplete' to differentiate from the img property
-Add lastSeekTime property initialization to img element
-Don't run onload if image element is already bComplete
-Sort and execute search after image is loaded (if requested). This allows search and sort to work with all of the meta data in the image.
-Click videos to pause/play
-Double click videos to toggle fullscreen
-Mute videos based on video options
-Set video volume from video options flyout
-Use scrollwheel on video to seek forward or back (seek direction depends on video options)
-Update imports
2024-04-17 14:58:59 -07:00
JaredTherriault 8b261e444c Hod ctrl+shift to pan quickly around the graph
This functionality existed before with just shift, but shift alone is used for many things in the graph. Instead, ctrl+shift will pan the graph at an accelerated rate.
2024-04-17 14:26:13 -07:00
JaredTherriault befb7f5093 Observer improvements
-Lower playbackThreshold to avoid flickering
-Only unload videos, not images
2024-04-17 13:08:30 -07:00
JaredTherriault 4e9364c9bb Get number value as number in textAreaFontControl 2024-04-15 21:06:59 -07:00
JaredTherriault 2f1df610bd Always highlight video upload node on drag over because firefox 2024-04-15 21:06:22 -07:00
JaredTherriault df777ff7cb Edit file types for video upload node 2024-04-15 21:05:40 -07:00
JaredTherriault 3f487f6b3c Fix issue with synced string load button not pasting in text properly 2024-04-15 21:05:11 -07:00
JaredTherriault 5bba287f29 Add CSS rules for specific flyout class 2024-04-15 21:04:11 -07:00
JaredTherriault 342044c1b5 Make video options more robust
-Add options for useWheelSeek, invertWheelSeek, and defaultVolume
-Add video info class to facilitate tooltips and callbacks
2024-04-15 21:03:35 -07:00
JaredTherriault 979327fa9b Reduce unnecessary returns 2024-04-15 21:01:59 -07:00
JaredTherriault 9b5611e45e Unload videos when they are unobserved and restore playback time when they are observed and loaded 2024-04-15 21:01:18 -07:00
JaredTherriault c234a1b973 Add key events for videos and getElementUnderPointer 2024-04-15 20:59:52 -07:00
JaredTherriault 174edbbba6 Generify flyout creation, widget clipping improvements
-Add option to prepend value label to slider range widget factory
-Iteratively generify flyout code so it can be more easily separated from the imagedrawer
-Separated flyout generation into its own function in SettingsManager
-Attempt to mitigate issue with the height and width being too low and clipping drawer widgets
2024-04-10 20:42:37 -07:00
JaredTherriault 678550c042 Unify Video Options, add labeled checkbox factory
-Make ConfigSetting getValue and setValue functions private
-Add labeled checkbox/toggle factory
-Update some checkboxes to use the factory, probably exist some more
-Unify video options (needs an interface to interact with though)
-Preload metadata for videos now that we lazy load them
-Made some names more clear
2024-04-10 17:38:51 -07:00
JaredTherriault 9150a0beb4 Settling on consistent font experience in Lora picker 2024-04-10 16:14:46 -07:00
JaredTherriault ba50521a85 And drawer width, refactor drawer location/anchor, code cleanup
-Separate DrawerSize into DrawerWidth and DrawerHeight
-Change Drawer Location to Drawer Anchor, now 'top-left', 'bottom-left', 'top-right', 'bottom-right'
-Add height and width to context cache class
-Image width and contained text size now based on drawer width
-Cap model info box at 90% in model contexts
-Made flyout options into a table
-Flyout button now circular border with an eyeball emoji (denoting 'view options')
-Moved DrawerAnchor widget creation to UISettings.js so UI Settings and view options flyout are now using the same widget and underlying functions
-Moved some inlined CSS out to CSS file to better facilitate different drawer anchors
-Anchor close button and flyout button to the right side of the screen when the Drawer anchor is right-affined
2024-04-10 15:09:48 -07:00
JaredTherriault 33c12309f5 Sizing, anchoring and aspect ratio updates, linter adherence,
-Update img-sz to column-count var
-Minimum width in left and right mode is now fit to the content inside of it
-Fixed anchoring of sizing menu flyout in top and bottom modes
-Made all images and videos a uniform width based on the column count and max-size
-Add error handling in ImageAndVideoObserver, remove aspect ratio patch
-Add helper function to create labeled sliders or ranges
-linter adherence updates
-Add aspect ratio slider for model contexts, affects model card aspect ratio
-Add class name to extra network cards
-Fix font scaling on model cards
-Improve info box anchoring and sizing on model cards
-Improve CSS declarations
-Fix auto aspect ratio for image and video placeholders
2024-04-09 21:06:56 -07:00
JaredTherriault d3cc0ee315 Skip PreviewImage nodes when adding images to the feed 2024-04-09 16:28:07 -07:00
JaredTherriault 9eeb74b92a Disable tooltips when hovering images if a mouse button / touch is held 2024-04-09 12:12:27 -07:00
JaredTherriault a4f716e7c9 Drag and drop lora/embeddings onto canvas or textarea
-Added drag functions to lora and embeddings buttons to allow dropping loras into the canvas to create a node or either model type into textareas to insert the model as text ("<lora>" or "embedding"). the drop caret is misleading - click or make a selection first in the taget textarea then drag the button into it to insert at a specific location.
-Move undo-able text insertion to textareas into its own utility function
-Clean up imports
2024-04-08 19:43:41 -07:00
JaredTherriault 3db0dc5247 Load image and video data only when needed for the current folder in view 2024-03-30 18:37:10 -07:00
JaredTherriault 469bfd4dbc Update comment 2024-03-30 15:01:35 -07:00
JaredTherriault 4602523b9a Rename 'size' to 'dimensions' in file info, add 'file_size' to file info, 2024-03-29 21:59:17 -07:00
JaredTherriault 18b75766d0 Re-add ImageDrawer script 2024-03-29 21:10:51 -07:00
JaredTherriault 7ee5672414 Capitalize ImageDrawer script 2024-03-29 21:10:33 -07:00
JaredTherriault ccdb779860 Isolate VideoOptions class, create config instance of it 2024-03-29 21:09:53 -07:00
JaredTherriault 713c2daedb Spinner rename 2024-03-29 20:01:37 -07:00
JaredTherriault 5a6623c7b3 Basic video support in image list, backend organizational improvements, image loading optimizations, drag and drop lora into graph
-Change some names for clarity and capitalization linter
-Add SettingsManager to handle Config Settings
-Move some Utilities to SettingsManager
-Added images and videos are observed when they are added to the image list and unobserved when removed
-Add video support in feed and other image lists
-Optimized local image/video loading (for input and output folders and the like)
-Restore last subfolder selection on refresh of folder explorer context if possible
-Add batching code path for image loading (unused for now, needs tuning)
-Add option to drag and drop loras into graph to create lora node automatically
-Images now load in on demand (lazy loading) rather than all at once
-Try/Catch reading of image metadata
-Disable drag/drop for image href, fix issue where dragging image makes redundant toolbar button
-Add UiSettings script to handle adding UI Settings
2024-03-29 20:01:21 -07:00
JaredTherriault e1953e94ab Adjust observer threshold, add lazy loading of images and videos when intersecting, unobserve images after being lazy loaded, only observe videos 2024-03-28 16:45:10 -07:00
JaredTherriault 16cfc47454 Make shiftToDragFaster use events script 2024-03-28 13:08:32 -07:00
JaredTherriault 6604399233 Removed non-standard code from try-catches 2024-03-28 12:56:24 -07:00
JaredTherriault 4bd5a84fff Add events class for global event handlers and observer class for image list optimization 2024-03-28 12:30:27 -07:00
JaredTherriault 9624fe47ef support undo when the user clicks the button manually, not during auto-load 2024-03-20 16:15:10 -07:00
JaredTherriault a41e90b58d Save backup file when saving synced text 2024-03-13 20:20:02 -07:00
JaredTherriault f7341c53a1 Improve drag and drop onto video upload node, remove unnecessary IS_CHANGED calls 2024-03-10 19:32:27 -07:00
JaredTherriault a656406eea relative paths support, synced string literal undo support, fix disappearing scrollbar
-Allow for relative paths and absolute paths in nodes that use paths (relative to the ComfyUI folder, so 'JNodes/input' without a leading slash)
-Add util to ascertain if an element is visible in the viewport
-Fix disappearing scrollbar in imageDrawer
-Add undo support for loading text in synced string literal node
2024-03-06 17:15:59 -08:00
JaredTherriault 0d730461e0 Update regex patterns, make unique extension identifiers, add copy ability for all image metadata keys
Update regex patterns, make unique extension identifiers, add copy ability for all image metadata keys
2024-02-24 17:02:19 -08:00
JaredTherriault 115d052931 Lay more groundwork for model config saving, add id to ImageElement buttonToolbar element 2024-02-10 22:03:25 -08:00
JaredTherriault b42afb1771 Fix search bar width 2024-02-10 20:56:59 -08:00
JaredTherriault 8745071432 Fix tooltip on webp images
Fix tooltip on webp images
2024-02-04 13:06:10 -08:00
JaredTherriault c7ed83fb30 Subfolder selection in subfolder contexts, search and replace text improvements, wider tooltip
-Made tooltip wider to accommodate longer values. Set it back with bUseWideTooltip  = false in ImageElements.js. Will eventually make this user-editable from the UI.
-JNodes_PromptEditor has become JNodes_SearchAndReplaceFromFile. Make sure you update your workflows, all two of you using it.
-Added JNodes_SearchAndReplaceFromList and JNodes_SearchAndReplace nodes to complement.
-Added JNodes_SplitAndJoin (originally for removing extra spaces and commas, but can be used to reduce anything you have too many of in a string) and JNodes_TrimAndStrip for removing leading and trailing whitespace.
-Split RemoveCommentedText out of ParseWildcards. Now the comment tokens are user-editable too.
-Added UI option for a custom batch commenting token (was previously hard-coded to '#')
-Removed 'unknown' placeholder text on some nodes
-Added subfolder selection support for SubFolderExplorer contexts. Now subfolders can be chosen in contexts like 'input' and 'output'. You can also choose to display items within a subfolder's subfolders. Make sure you're not trying to display too many items at once or the browser will crash.
-Added backend function to save user-configured model information so the end user can eventually override a lora or embedding's display name, tags, trained words and weight presets. The UI for this is not yet built.
-Added a nullptr check when checking to see if an object is empty.
-Removed setSearchTermsOnElement since it's superfluous. It takes fewer characters to just set it directly.
-Some search terms and some metadata are set now when an imageElement is first created rather than waiting for the image within to actually load. This allows sorting and search to work more properly as contexts are switched, but searching metadata obviously still won't work until the images are loaded. But you can search filename, subfolder and type until then.
2024-02-03 09:37:49 -08:00