mirror of
https://github.com/open-webui/open-webui
synced 2024-11-16 05:24:02 +00:00
refac: chat controls size
This commit is contained in:
parent
580ad46036
commit
8fc178ae91
@ -289,11 +289,11 @@
|
|||||||
if (controlPane && !$mobile) {
|
if (controlPane && !$mobile) {
|
||||||
try {
|
try {
|
||||||
if (value) {
|
if (value) {
|
||||||
controlPane.resize(
|
const currentSize = controlPane.getSize();
|
||||||
parseInt(localStorage.getItem('chat-controls-size') || '35')
|
|
||||||
? parseInt(localStorage.getItem('chat-controls-size') || '35')
|
if (currentSize === 0) {
|
||||||
: 35
|
controlPane.resize(parseInt(localStorage?.chatControlsSize ?? '30'));
|
||||||
);
|
}
|
||||||
} else {
|
} else {
|
||||||
controlPane.resize(0);
|
controlPane.resize(0);
|
||||||
}
|
}
|
||||||
|
@ -123,9 +123,7 @@
|
|||||||
<Pane
|
<Pane
|
||||||
bind:pane
|
bind:pane
|
||||||
defaultSize={$showControls
|
defaultSize={$showControls
|
||||||
? parseInt(localStorage.getItem('chat-controls-size') || '35')
|
? controlPane.resize(parseInt(localStorage?.chatControlsSize ?? '30'))
|
||||||
? parseInt(localStorage.getItem('chat-controls-size') || '35')
|
|
||||||
: 35
|
|
||||||
: 0}
|
: 0}
|
||||||
onResize={(size) => {
|
onResize={(size) => {
|
||||||
if (size === 0) {
|
if (size === 0) {
|
||||||
|
Loading…
Reference in New Issue
Block a user