* Initial plan
* feat: preserve image width/height when generating swipe images
Save width and height in ImageGenerationAttachmentProps when creating
MediaAttachment objects, and apply saved dimensions when generating
image swipes. Falls back to current extension settings if not specified.
Co-authored-by: Cohee1207 <18619528+Cohee1207@users.noreply.github.com>
* fix: validate dimension override with Number.isInteger and skip setTypeSpecificDimensions when override is present
Co-authored-by: Cohee1207 <18619528+Cohee1207@users.noreply.github.com>
* fix: call restoreOriginalDimensions when setTypeSpecificDimensions was used
Co-authored-by: Cohee1207 <18619528+Cohee1207@users.noreply.github.com>
* Contain the logic to setTypeSpecificDimensions
* Diff clean-up
* feat: enhance prompt refinement with negative input and saved resolution options
* fix: Only save image dimensions when running from command
* Fix wording in refine prompt dialog
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: Cohee1207 <18619528+Cohee1207@users.noreply.github.com>
* Initial plan
* Overhaul /bgcol command: Oklab color space, dominant color extraction, full theme palette generation
- Create ThemeGenerator module in public/scripts/util/ with:
- Oklab color space conversions (sRGB ↔ Oklab ↔ LCH)
- Chroma-weighted dominant color extraction (vivid over muddy averages)
- Color theory palette: complementary, analogous, triadic hue relationships
- WCAG contrast ratio enforcement (≥3.5:1 for all text colors)
- Replace old setAvgBG with new implementation using ThemeGenerator
- Save generated theme as "Generated - <background name>" instead of overwriting
- Update command help string to reflect production-ready status
Co-authored-by: Cohee1207 <18619528+Cohee1207@users.noreply.github.com>
* Extract hue shift constants for clarity (code review feedback)
Co-authored-by: Cohee1207 <18619528+Cohee1207@users.noreply.github.com>
* Add name and bg arguments to /bgcol command
- Add `name` named argument to override the generated theme name
- Add `bg` named argument with enum provider listing available backgrounds
from /api/backgrounds/all to override the current background
Co-authored-by: Cohee1207 <18619528+Cohee1207@users.noreply.github.com>
* Improve types, add enum provider, reduce transparency
* Adjust alpha channel for better readability
* Refactor ThemeGenerator to work directly in Oklch, removing intermediate Oklab conversions
Replaced srgbToOklab/oklabToSrgb + oklabToLCH/lchToOklab with direct
srgbToOklch/oklchToSrgb functions. All color manipulations now use
{L, C, h} directly without converting through {a, b} intermediates.
The ensureContrast function now takes (L, C, h) parameters instead of
an Oklab object.
Co-authored-by: Cohee1207 <18619528+Cohee1207@users.noreply.github.com>
* Add custom background URL check and enhance theme generation logic
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: Cohee1207 <18619528+Cohee1207@users.noreply.github.com>
* create and export updateWorldInfoSettings
* Add WorldInfoSettings type and refactor updateWorldInfoSettings function
---------
Co-authored-by: Cohee <18619528+Cohee1207@users.noreply.github.com>
* Implement Gemini thought signatures
* Implement streaming support for Gemini thought signatures
* Implement OR support for Gemini thought signatures
* Remove unnecessary extraction of thought sigs from response parts
* Update thought sig comments to remove explicit Gemini mention
* Fix thought_signature naming convention in message.extra
* Add thought_signatures to ReasoningMessageExtra typedef
* Prevent thought sigs being sent to incompatible endpoints
* Move signatures to populateChatHistory, update for consistent casing
* Code clean-up
* Only send thought signatures if target model and API match original
* Implement content-hash thought signature mapping
* Change the data model + split for text/functions
* Don't include signature to invocations if the model doesn't match
* Fix function description
* Remove misleading comment
* Handle OpenRouter signatures
* Improve message extra types
* Prevent modifying original invocations when removing signatures
* Fix return of openrouter non-streaming signatures
* Remove redundant array check
---------
Co-authored-by: Cohee <18619528+Cohee1207@users.noreply.github.com>
* Separate prompt-building functionality from request-sending functionality
* removing logs and clarifying comments
* separating parameter construction functionality to allow ConnectionManagerRequestService to use all other preset parameters
* fixing chat completion issues, adding documentation to new functions.
* Improving ConnectionManagerRequestService errors. Adding parseReasoningFromString option to override reasoning template.
* Adjusting TextCompletionService prompt formatting
* linting
* Use settingsToUpdate to convert from OAI preset to OAI settings.
* lint
* throw errors when profile ID not found
* Fix missed instances of global completion settings being used (CC and TC), replaced with optional argument. Specified typing for ChatCompletionSettings and TextCompletionSettings.
* Adjusting parameters of parseReasoningFromString and adding getReasoningTemplateByName
* using messages.role as a fallback for custom requests, fixing newline removal.
* parameters => settings
I like how it sounds better
* ditto
* You know I had to do it to 'em
* Update getCustomTokenBans
* Fix calculateLogitBias
* Fix param attributes
* Fix type checks
* Less strict role type on ChatCompletionMessage
* Add missing space
* fixing getChatCompletionModel to use an arbitrary chat completion settings object
* Fixing issues with preset overriding custom data passed.
* Pass model to createGenerationParameters externally
* Unify seed param handling for CHUTES
* Fix non-existing CC source
* Use strict comparison
* Use global settings as a base for generation parameters creation
* removing unnecessary handling of preset fields
* don't pass preset prompts, use the passed payload override messages
* refactoring text generation prompt building of last line
* Pass model to getReasoningEffort
* Pass model name to canPerformToolCalls
* Pass model to createTextGenGenerationData
---------
Co-authored-by: qvink <qvink@users.noreply.github.com>
Co-authored-by: Cohee <18619528+Cohee1207@users.noreply.github.com>
* Migrate group metadata to group chat files
* Skip migration if chat already has metadata
* Fix active group not being set on group conversion
* Improve types in createGroup
* Fix padding in hotswap group avatars
* Fix centering of empty hotswap avatar
* Added automatic backups of migrated data
* Fix 'OVERWRITE' for GC
* Fix metadata parsing order in migration
* Remove color accents from regular migration logs
* Always set gen_id in converted message
* Clone messages before conversion
* Reduce size of add/remove buttons
* Fix group chat file size calculation
* Preserve media playback state when running appendMediaToMessage
* Better selector specificity
* Fix local variable name
* Move typedef to global.d.ts
* Check for readyState on save/restore
* Only check for currentSrc on restoration callback
* Add captioning for video attachments
* Unify error toast titles
* Add MEDIA_SOURCE enum and update media handling to include source information
* Unify attachment handling logic
* Add error handling for auto-captioning failures
* Use string formatting for console error
* Multiple file uploads
* mes_img_wrapper
* mes_video_wrapper
* Named export instead of function wrapper
* Update public/scripts/chats.js
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
* Fix optional chaining for message extra
* Preserve existing files with paste
* Improve swipe message extras clean-up
* Clean-up: Add chat_backgrounds to known images
* Add ensureMessageMediaIsArray to getContext
* Fix compatibility warning
* Update to media array
* Move de-dupe check logic
* Fix comment
* Fix clean-up logic
* Improve typing
* `feat/multi-file` Added a toggle between the old gallery and new image list. (#4722)
* Added "Toggle Gallery" button.
Added `getContainerInfo`.
* Refactor
* Change checkbox toggle to select
* Ensure media_display is set correctly only if any image_swipes were migrated
* Rename function
* Support Date in parseTimestamp
* Add type to main chat array
* Add media display reload prompt
---------
Co-authored-by: user <user@exmaple.com>
Co-authored-by: Cohee <18619528+Cohee1207@users.noreply.github.com>
* Use a single wrapper block for media
* Fix type annotation
* Fix video display in list mode
* Refactor saveImageToMessage to include title in media object
* Use named constants in migrateMediaToArray
* Update img control styles
* Fix error container state
* Refactor onImageSwiped
* Remove redundant event handler
* Refactor expandMessageMedia
* Use shared function for display handling, fix notice logic
* Enhance ChatMessage and ChatMessageExtra types
* Refactor media display reload logic
* Improve styling for media containers
* Adjust spacing in file form styles
* Fix scroll handling in appendMediaToMessage
* Reduce flicker in appendMediaToMessage
* Extract scrollOnMediaLoad func
* Improve scroll behavior in gallery display
* Improve delegation for click events
* Add file d&d handler to #form_sheld
* Improve scroll adjust for slow connections
* Adjust debounce timeout
* Add messageMedia enum provider
---------
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
Co-authored-by: DeclineThyself <FallenHaze@tutamail.com>
Co-authored-by: user <user@exmaple.com>
* Fix TS1038 errors
"A 'declare' modifier cannot be used in an already ambient context."
* Fix TS1040 errors
"'async' modifier cannot be used in an ambient context."
* Fix TS2371 errors
"A parameter initializer is only allowed in a function or constructor
implementation."
* Fix TS2430 errors
"Interface 'ColorPickerEvent' incorrectly extends interface
'ChangeEvent<HTMLElement, any, any, any>'".
The issue here is that the "ColorPickerEvent" objects provided by
toolcool-color-picker.js are vanilla JS CustomEvent objects, not JQuery
event objects. We need to mangle the types here a bit to make JQuery
happy. (At runtime, JQuery is happy to pass along the vanilla Event
object; JQuery's types just don't reflect this.)
* Remove variable and type exports
---------
Co-authored-by: Cohee <18619528+Cohee1207@users.noreply.github.com>
* TC/AF: Add Story String position
* Update public/scripts/power-user.js
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* Add before/after anchors as story string params
* Move autofix story string at settings load
* Substitute in story string wrappers
* Only add an auto-newline after story string if wrap is enabled
* Do not init names_force_groups with default value
* Update default settings
* Auto-delete obsolete fields from instruct templates
* Update default templates
* Remove newline from GLM-4 prefix
* Format as one line
* Remove auto-fix leftovers from renderStoryString
* Remove pointless reassignments in autoFixMissingField
* Update KoboldAI template
* Add info hint for Story String sequences
* Update default templates
* Reformat extractMessageFromData
* Fix condition in autoFixStoryString
* Update tooltip text for Story String Sequences
---------
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* remove unnecessary arg passage from WI helper funcs
* remove some typescript red from script.js
* hide in shame
* Add JSDoc to helper functions
* Fix fav_ch_checked not updating
* Move PWA mode match to firstLoadInit
* Fix more type errors and deprecations
* Fix the rest of type errors in script.js
---------
Co-authored-by: RossAscends <124905043+RossAscends@users.noreply.github.com>