Commit Graph
57 Commits
Author SHA1 Message Date
Leandro Jofré e8a75c3329 Feat/Link sampler selection lock to TC API Type (#4782)
* Update - Revert connection profile change TC commands load order

This change was made to prevent preset tied samplers from breaking, such thing doesn't exist anymore.

* Update - Unlink preset renaming logic from sampler selection lock

* Update - Link TC sampler selection lock to API Type

* Fix - Clean comments

* Update - Use localforage selectedSamplers and data selectsampler as main sampler selection storage

* Fix - ESLint errors

* Update - Change lock tooltip with correct description

* Fix - Move and await sampler select localforage initializer to finish

Tried to move it to the most reasonable place possible that allowed to make an await.

* Fix - Make loadTextGenSettings async to load API selected samplers
2025-11-21 01:57:23 +02:00
Leandro JofréandCohee 0d9a72becc Add option to keep manually selected samplers on API Type switch (#4692)
* Feat - Save and load manually selected samplers per preset

* Fix - Sync sampler popup with selected sampler state settings

* Fix - Prevent breaking visualization after disabling keep selected samplers

* Fix - ESLint errors in samplerSelect.js

* Fix - ESLint errors in textgen-settings.js

* Docs - Write JSDocs for new methods in textgen-settings.js

* Update - Make the reset button work individually per preset

* Fix - Trailing whitespace at the end of class selector

* Fix - Update tooltip information for force samplers toggle

* Fix - Prevent calling isSamplerManualPriorityEnabled a bajillion times

* Fix - Unbrick switch from manually-forced to non-manually-forced preset

This prevents samplers non controlled by [data-tg-type] from being sent to the shadow realm if they were previously hidden by [data-tg-samplers]. is_preset_switch is just to prevent breaking muscle memmory of users not using force manually selected samplers.

* Fix - Load manually selected samplers on connection profile switch

Changing preset does not update samplers ONLY IF force manually selection is disabled. Changing API before preset would update the samplers, but using the settings of the previous preset, due to preset being changed AFTER the API.

* Fix - Switch API Type controls in the API Connections panel

* Fix - ESLint errors in textgen-settings.js

* Fix - Update sampler selection only with textgenerationwebui as main API selected

* Styles - Change the sampler selection lock button icon to an actual lock.

* Fix - Await for sampler selection reset to finish

* Update - Normalize function name

* Update - Preserve manual sampler selections on preset renaming

* Fix - Properly reset sampler manual selections

* Update - Ensure selection reset displays API specific samplers

* Fix - ESLint errors

* Fix - Avoid modifying non-existent data

* Update - Move manual sampler control methods to samplerSelect.js

* Fix - Break circular file dependency between textgen-settings.js and samplerSelect.js

setting_names was unavailable during page load, throwing an error and preventing ST from loading.

* Update menu layout

* Remove pointless await

* Update param naming to camelCase

---------

Co-authored-by: Cohee <18619528+Cohee1207@users.noreply.github.com>
2025-11-19 22:56:15 +02:00
Wolfsblvt 81367629fe Feat: Improve multiline input handling in popups (#4756)
* feat: improve multiline input handling in popups

- Added Ctrl+Enter requirement for submission in multiline input popups to prevent accidental sends
- Exported PopupUtils class for external use

* refactor: remove redundant higher/different rows from input popups

- Removed rows: 2 from callGenericPopup calls where default behavior is sufficient
- Increased rows from 2 to 4 in caption extension for better multiline input experience
2025-11-12 21:20:13 +02:00
Cohee aaad129d1b Add missing props to ConnectionProfile typedef 2025-10-10 20:43:11 +03:00
bmen25124 d48a3639ed Added "custom_prompt_post_processing" to custom-request (#4639) 2025-10-10 20:37:23 +03:00
WolfsblvtandCohee df2dee8482 Fix make /profile await the for an actual successful API connection (#4589)
* fix: add connection status check after profile switch in connection manager

Fixes #4262

* feat: add timeout parameter to connection manager await functionality & catch timout error

* Add rejectOnTimeout option to waitUntilCondition

---------

Co-authored-by: Cohee <18619528+Cohee1207@users.noreply.github.com>
2025-10-03 20:43:35 +03:00
TosdandCohee 57e363cae6 feat: Regex Presets (#4468)
* Work in progress

* feat: save confirmation

* Fix eslint, add typedef

* Add slash command and compatibility with profiles

* Move UI label up

* Null safety

* Fix duplicate block title

* i18n: zh-CN translation

* Adjust debugger styles

* Move presets block down

* Do not generate id twice for new entries

* Add missing translations

* Simplify settings migration logic

* Fix type comment

* Add missing keys

---------

Co-authored-by: Cohee <18619528+Cohee1207@users.noreply.github.com>
2025-09-08 12:35:14 +03:00
Cohee 8d2b9d2dab Secrets manager (#4131)
* Secret manager (now for real)

* Refactor secret manager dialog

* Add error handling to secrets migration

* Adjust default value

* Add secret-id slash command

* Add secret management slash commands

* Improve type definitions

* Improve compatibility of UUID generator

* Add copy buttons to manager view

* Improve compatibility with Vertex AI service account
- Changed to input since textarea can't be used with datalist
- Unblock regular key placeholder
- Save email as a key label
- Interrupt validation if the input is a UUID (autocompleted)

* Add optional label input for secret values in key manager dialog

* Update masking rules

* /secret-id: make the arg "required" (it's not)
2025-06-11 21:26:19 +03:00
Cohee 4c3bb1aede PPP command and connection profiles (#4079)
* Add PPP command

* Add PPP to connection profiles
2025-06-01 18:15:06 +03:00
Cohee cf2671c6d7 Merge branch 'staging' into reasoning-template 2025-03-16 22:51:28 +02:00
Cohee d314752547 Add reasoning template to connection profiles 2025-03-16 22:39:43 +02:00
bmen25124 d42a81f97c New connection manager events, ConnectionManagerRequestService (#3603) 2025-03-16 16:58:34 +02:00
Cohee 6f0f32d83d Add a second row to profile editing name 2025-03-09 16:59:58 +02:00
Cohee 7845994315 Add 'start-reply-with' to Connection Profiles (#3632)
* Connection Profiles: Add support for 'start-reply-with' command and allow empty values for 'stop-strings' command

* Add handling for empty profile values in makeFancyProfile function

* Fix application of empty values

* Handle undefined values

* Improve argument validation

* Replace || with &&

* I got it right this time, swear

* Who wrote this?
2025-03-09 16:55:49 +02:00
Cohee fad4e4e75e Add command and profile for custom stop strings 2025-01-27 22:30:35 +02:00
Yokayo 1d5cf8d25c Work on translation 2025-01-12 00:42:58 +07:00
Cohee e6d8f0a33e unvendor: Replace Fuse 2024-10-16 22:15:38 +03:00
Yokayo 78a287e7f5 Resolve conflict 2024-09-28 21:31:13 +07:00
Yokayo bb76649478 Update tl 2024-09-28 20:47:37 +07:00
Cohee eccf253afd Show Included settings in view order 2024-09-27 01:01:49 +03:00
Cohee 50fd3a2028 Remove new class 2024-09-27 00:46:03 +03:00
Cohee 4167fe3d2b Add Save and Update 2024-09-27 00:44:58 +03:00
Cohee dbca950aad Add margin from all sides 2024-09-26 23:40:44 +03:00
Cohee 7c4d8b8d7a Fix a bug with splice 2024-09-26 23:36:38 +03:00
Cohee bb82198496 Place omitted on a separate line 2024-09-26 23:34:42 +03:00
Cohee d8806060a7 Use compact template syntax 2024-09-26 23:34:03 +03:00
Cohee cd6e0747a5 Fix margin on Hint 2024-09-25 14:35:28 +00:00
Cohee 0646a47b81 Add ability to omit settings from Connection Profiles 2024-09-25 14:23:43 +00:00
Cohee 583cc4b097 Add renaming of profiles + use alphabetical sorting 2024-09-23 20:19:18 +03:00
Cohee d0657161a1 Merge branch 'staging' into sysprompt-divorce 2024-09-19 23:14:40 +03:00
Cohee 9197ed7fce Fix connection profile for CC setting incorrect source by preset 2024-09-19 23:12:33 +03:00
Cohee 0bc6a572c6 Add slash commands and connection profiles support 2024-09-17 12:14:13 +00:00
Cohee 4e84120981 Consistent error logging 2024-09-08 13:32:56 +03:00
Cohee f926d9abd7 Execute profile commands callbacks directly 2024-09-08 13:31:32 +03:00
Cohee 85ebf3116e Add link to the doc 2024-09-08 09:27:03 +03:00
Wolfsblvt c765057684 Disable buttons on <None> option 2024-09-08 01:18:44 +02:00
Cohee 44ddec88fe Rename extension manifest 2024-09-08 01:35:59 +03:00
Cohee 6aa9608b8e Forgor the spinner 2024-09-08 01:21:04 +03:00
Cohee 38751d4fe2 Replace details view toggle with a button 2024-09-08 01:19:52 +03:00
Cohee d99dfb9168 Add spinner to indicate profile application 2024-09-07 23:53:22 +03:00
Cohee 10ddf77948 Await for profiles loading before continuing 2024-09-07 21:33:31 +03:00
Cohee 739d0c95c3 Require unique names for profiles 2024-09-07 21:21:46 +03:00
Cohee 827fce4542 Move string utils to shared module 2024-09-07 21:19:33 +03:00
Cohee 70ff35b4c3 Use consistent icons 2024-09-07 21:11:06 +03:00
Cohee 00f6941e93 Fix review comments 2024-09-07 21:08:37 +03:00
Wolfsblvt 7e64d216c3 Fix type not returning profile name 2024-09-07 19:32:58 +02:00
Cohee 4fd7828a9b Add /profile-get command 2024-09-07 17:13:32 +03:00
Cohee 065daa7599 Add commands to list, create, update profiles 2024-09-07 14:56:30 +03:00
Cohee bcac8c065b Add command for switching profiles 2024-09-07 13:58:46 +03:00
Cohee 6d9c64f38e Add dynamic i18n to profile views 2024-09-07 13:36:21 +03:00