Skip to content

Commit fd0af44

Browse files
authored
Revert "fix: avoid extra gaps between attachments in chat input part (microsoft#242497)" (microsoft#242577)
* Revert "fix: render chat implicit context widget even if there are no real attachments (microsoft#242574)" This reverts commit 8d53e80. * Revert "fix: avoid extra gaps between attachments in chat input part (microsoft#242497)" This reverts commit 21d13f4.
1 parent 8d53e80 commit fd0af44

File tree

2 files changed

+3
-7
lines changed

2 files changed

+3
-7
lines changed

src/vs/workbench/contrib/chat/browser/chatInputPart.ts

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -992,9 +992,7 @@ export class ChatInputPart extends Disposable implements IHistoryNavigationWidge
992992
const hoverDelegate = store.add(createInstantHoverDelegate());
993993

994994
const attachments = [...this.attachmentModel.attachments.entries()];
995-
const hasAttachments = Boolean(attachments.length) || Boolean(this.implicitContext?.value) || !this.instructionAttachmentsPart.empty;
996-
dom.setVisibility(Boolean(hasAttachments || (this.addFilesToolbar && !this.addFilesToolbar.isEmpty())), this.attachmentsContainer);
997-
dom.setVisibility(hasAttachments, this.attachedContextContainer);
995+
dom.setVisibility(Boolean(attachments.length) || (this.addFilesToolbar && !this.addFilesToolbar.isEmpty()) || Boolean(this.implicitContext?.value) || !this.instructionAttachmentsPart.empty, this.attachmentsContainer);
998996
if (!attachments.length) {
999997
this._indexOfLastAttachedContextDeletedWithKeyboard = -1;
1000998
}
@@ -1413,8 +1411,6 @@ export class ChatInputPart extends Disposable implements IHistoryNavigationWidge
14131411

14141412
async renderChatRelatedFiles(chatEditingSession: IChatEditingSession, anchor: HTMLElement) {
14151413
dom.clearNode(anchor);
1416-
dom.setVisibility(Boolean(chatEditingSession.workingSet.size), anchor);
1417-
14181414
const hoverDelegate = getDefaultHoverDelegate('element');
14191415
for (const [uri, metadata] of chatEditingSession.workingSet) {
14201416
if (metadata.state !== WorkingSetEntryState.Suggested) {

src/vs/workbench/contrib/chat/browser/media/chat.css

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -700,7 +700,7 @@ have to be updated for changes to the rules above, or to support more deeply nes
700700
flex-wrap: wrap;
701701
align-items: center;
702702
gap: 4px;
703-
max-width: 100%;
703+
width: 100%;
704704
}
705705

706706
.chat-related-files .monaco-button-dropdown .monaco-text-button {
@@ -1193,7 +1193,7 @@ have to be updated for changes to the rules above, or to support more deeply nes
11931193
flex-wrap: wrap;
11941194
cursor: default;
11951195
gap: 4px;
1196-
max-width: 100%;
1196+
width: 100%;
11971197
}
11981198

11991199
.interactive-session .interactive-input-part.compact .chat-attached-context {

0 commit comments

Comments
 (0)