This commit is contained in:
seb
2026-10-08 21:20:40 +02:00
parent f91c50ef69
commit 6578f7d1ac

View File

@@ -127,9 +127,9 @@ export default class ChatDrawer extends PureComponent {
this.updateGutterClass(this.state.isOpen); this.updateGutterClass(this.state.isOpen);
if (this.state.isOpen) { if (this.state.isOpen) {
if (chatAutomat.state.pendingInput != null) { if (chatAutomat.state.pendingInput != null) {
this.focusInputAtEnd(150); this.focusInputAtEnd(0);
} else { } else {
this.focusInput(150); this.focusInput(0);
} }
} }
void this.loadModelSettings(); void this.loadModelSettings();
@@ -169,9 +169,9 @@ export default class ChatDrawer extends PureComponent {
chatAutomat.setState({ pendingInput: null }); chatAutomat.setState({ pendingInput: null });
} }
}); });
this.focusInputAtEnd(150); this.focusInputAtEnd(0);
} else if (!wasOpen && willOpen) { } else if (!wasOpen && willOpen) {
this.focusInput(150); this.focusInput(0);
} }
return patch; return patch;
}); });
@@ -1625,6 +1625,7 @@ export default class ChatDrawer extends PureComponent {
open={isOpen} open={isOpen}
onClose={this.handleClose} onClose={this.handleClose}
disableScrollLock disableScrollLock
transitionDuration={0}
ModalProps={{ ModalProps={{
disableScrollLock: true, disableScrollLock: true,
disableEnforceFocus: true, disableEnforceFocus: true,
@@ -1633,6 +1634,7 @@ export default class ChatDrawer extends PureComponent {
zIndex: theme.zIndex.modal + 10, zIndex: theme.zIndex.modal + 10,
'& .MuiBackdrop-root': { '& .MuiBackdrop-root': {
backgroundColor: DIALOG_FOG, backgroundColor: DIALOG_FOG,
transition: 'none !important',
}, },
'& .MuiDrawer-paper': { '& .MuiDrawer-paper': {
width: { xs: '100vw', sm: `${totalWidth}px` }, width: { xs: '100vw', sm: `${totalWidth}px` },
@@ -1642,12 +1644,13 @@ export default class ChatDrawer extends PureComponent {
boxShadow: SHADOW_DRAWER, boxShadow: SHADOW_DRAWER,
position: 'fixed', position: 'fixed',
overflow: 'visible', overflow: 'visible',
transition: isResizing ? 'none !important' : undefined, transition: 'none !important',
}, },
})} })}
slotProps={{ slotProps={{
transition: { transition: {
onEntered: () => this.focusInput(20), timeout: 0,
onEntered: () => this.focusInput(0),
}, },
paper: { paper: {
sx: { sx: {
@@ -1658,7 +1661,7 @@ export default class ChatDrawer extends PureComponent {
boxShadow: SHADOW_DRAWER, boxShadow: SHADOW_DRAWER,
position: 'fixed', position: 'fixed',
overflow: 'visible', overflow: 'visible',
transition: isResizing ? 'none !important' : undefined, transition: 'none !important',
}, },
}, },
}} }}