fix(core): missing lit component props (#13482)

Close [AI-413](https://linear.app/affine-design/issue/AI-413)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **Bug Fixes**
* Chat messages now scroll vertically, preventing content from being cut
off.
* Chat actions are no longer displayed or fetched, reducing unnecessary
loading.
* Peek view chat composer behavior is aligned with the main chat,
ensuring consistent feature availability across views.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
This commit is contained in:
Wu Yue
2025-08-13 16:57:51 +08:00
committed by GitHub
parent dd9d8adbf8
commit c2f3018eb7
2 changed files with 8 additions and 2 deletions

View File

@@ -90,7 +90,7 @@ export class PlaygroundChat extends SignalWatcher(
ai-chat-messages {
flex: 1;
overflow-y: hidden;
overflow-y: auto;
}
.chat-panel-hints {
@@ -211,6 +211,10 @@ export class PlaygroundChat extends SignalWatcher(
});
}
get showActions() {
return false;
}
private readonly _initPanel = async () => {
const userId = (await AIProvider.userInfo)?.id;
if (!userId) return;
@@ -240,7 +244,7 @@ export class PlaygroundChat extends SignalWatcher(
this.doc.id
)
: Promise.resolve([]),
this.doc.id
this.doc.id && this.showActions
? AIProvider.histories.actions(this.doc.workspace.id, this.doc.id)
: Promise.resolve([]),
]);
@@ -369,6 +373,7 @@ export class PlaygroundChat extends SignalWatcher(
.notificationService=${this.notificationService}
.aiToolsConfigService=${this.aiToolsConfigService}
.affineWorkspaceDialogService=${this.affineWorkspaceDialogService}
.affineFeatureFlagService=${this.affineFeatureFlagService}
></ai-chat-composer>
</div>`;
}

View File

@@ -614,6 +614,7 @@ export class AIChatBlockPeekView extends LitElement {
.affineWorkspaceDialogService=${this.affineWorkspaceDialogService}
.notificationService=${notificationService}
.aiToolsConfigService=${this.aiToolsConfigService}
.affineFeatureFlagService=${this.affineFeatureFlagService}
.onChatSuccess=${this._onChatSuccess}
.trackOptions=${{
where: 'ai-chat-block',