mirror of
https://github.com/microsoft/vscode.git
synced 2025-12-24 12:19:20 +00:00
Misc PR feedback for chatWidget (#191432)
* Use cached width first to prevent trip to dom * remove irrelevant dispose call * fix CSS of inputbox to align it to Quick Pick
This commit is contained in:
committed by
GitHub
parent
d87941aa32
commit
1a99420d57
@@ -537,7 +537,6 @@ export class ChatWidget extends Disposable implements IChatWidget {
|
|||||||
const mutableDisposable = this._register(new MutableDisposable());
|
const mutableDisposable = this._register(new MutableDisposable());
|
||||||
this._register(this.tree.onDidScroll((e) => {
|
this._register(this.tree.onDidScroll((e) => {
|
||||||
mutableDisposable.value = dom.scheduleAtNextAnimationFrame(() => {
|
mutableDisposable.value = dom.scheduleAtNextAnimationFrame(() => {
|
||||||
mutableDisposable.dispose();
|
|
||||||
if (!e.scrollTopChanged || e.heightChanged || e.scrollHeightChanged) {
|
if (!e.scrollTopChanged || e.heightChanged || e.scrollHeightChanged) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@@ -548,8 +547,9 @@ export class ChatWidget extends Disposable implements IChatWidget {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const newHeight = Math.min(renderHeight + diff, maxHeight);
|
const newHeight = Math.min(renderHeight + diff, maxHeight);
|
||||||
const inputPartHeight = this.inputPart.layout(newHeight, this.container.offsetWidth);
|
const width = this.bodyDimension?.width ?? this.container.offsetWidth;
|
||||||
this.layout(newHeight + inputPartHeight, this.container.offsetWidth);
|
const inputPartHeight = this.inputPart.layout(newHeight, width);
|
||||||
|
this.layout(newHeight + inputPartHeight, width);
|
||||||
});
|
});
|
||||||
}));
|
}));
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -426,6 +426,7 @@
|
|||||||
|
|
||||||
.quick-input-widget .interactive-session .interactive-input-and-execute-toolbar {
|
.quick-input-widget .interactive-session .interactive-input-and-execute-toolbar {
|
||||||
margin: 0;
|
margin: 0;
|
||||||
|
border-radius: 2px;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* #endregion */
|
/* #endregion */
|
||||||
|
|||||||
Reference in New Issue
Block a user