Skip to content

Commit cf44454

Browse files
authored
fix: inline chat lower level than findwidget (#4251)
1 parent 47aace4 commit cf44454

2 files changed

Lines changed: 7 additions & 2 deletions

File tree

packages/ai-native/src/browser/widget/inline-chat/inline-content-widget.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import React, { useCallback, useEffect, useMemo, useState } from 'react';
22

33
import { Autowired, INJECTOR_TOKEN, Injectable, Injector } from '@opensumi/di';
4-
import { IAIInlineChatService, StackingLevelStr, useInjectable } from '@opensumi/ide-core-browser';
4+
import { IAIInlineChatService, StackingLevel, useInjectable } from '@opensumi/ide-core-browser';
55
import { AIAction } from '@opensumi/ide-core-browser/lib/components/ai-native';
66
import { InteractiveInput } from '@opensumi/ide-core-browser/lib/components/ai-native/interactive-input/index';
77
import { MenuNode } from '@opensumi/ide-core-browser/lib/menu/next/base';
@@ -261,7 +261,7 @@ export class AIInlineContentWidget extends ReactInlineContentWidget {
261261
override getDomNode(): HTMLElement {
262262
const domNode = super.getDomNode();
263263
requestAnimationFrame(() => {
264-
domNode.style.zIndex = StackingLevelStr.OverlayTop;
264+
domNode.style.zIndex = (StackingLevel.FindWidget - 1).toString();
265265
});
266266
return domNode;
267267
}

packages/core-browser/src/design/rule.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,11 @@ export const StackingLevel = Object.freeze({
3535

3636
EditorFloatingContainer: 20,
3737

38+
/**
39+
* Find 控件的 zIndex 是 25
40+
*/
41+
FindWidget: 25,
42+
3843
// #region 中级弹窗区域
3944
Popup: 100,
4045
// #endregion

0 commit comments

Comments
 (0)