mirror of
https://github.com/Microsoft/vscode
synced 2024-08-28 05:19:39 +00:00
Fix layout issues in inline chat (#214013)
* clamp followup height to three lines fixes https://github.com/microsoft/vscode-copilot/issues/5522 * follow up question should not define the widget of the chat input part
This commit is contained in:
parent
302d71ff5b
commit
e33013da3f
|
@ -530,6 +530,8 @@ export class ChatInputPart extends Disposable implements IHistoryNavigationWidge
|
|||
|
||||
const inputEditorHeight = Math.min(data.inputPartEditorHeight, height - data.followupsHeight - data.inputPartVerticalPadding);
|
||||
|
||||
this.followupsContainer.style.width = `${width}px`;
|
||||
|
||||
this._inputPartHeight = data.followupsHeight + inputEditorHeight + data.inputPartVerticalPadding + data.inputEditorBorder + data.implicitContextHeight;
|
||||
|
||||
const initialEditorScrollWidth = this._inputEditor.getScrollWidth();
|
||||
|
|
|
@ -555,6 +555,12 @@
|
|||
display: block;
|
||||
color: var(--vscode-textLink-foreground);
|
||||
font-size: 12px;
|
||||
|
||||
/* clamp to max 3 lines */
|
||||
display: -webkit-box;
|
||||
-webkit-line-clamp: 3;
|
||||
-webkit-box-orient: vertical;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.interactive-session .interactive-input-part .interactive-input-followups .interactive-session-followups code {
|
||||
|
|
|
@ -136,7 +136,7 @@ export class InlineChatContentWidget implements IContentWidget {
|
|||
const maxHeight = this._widget.input.inputEditor.getOption(EditorOption.lineHeight) * 5;
|
||||
const inputEditorHeight = this._widget.contentHeight;
|
||||
|
||||
this._widget.layout(Math.min(maxHeight, inputEditorHeight), 360);
|
||||
this._widget.layout(Math.min(maxHeight, inputEditorHeight), 390);
|
||||
|
||||
// const actualHeight = this._widget.inputPartHeight;
|
||||
// return new dom.Dimension(width, actualHeight);
|
||||
|
|
Loading…
Reference in a new issue