Skip to content

Commit 992c3d9

Browse files
committed
🐛 Fix zindex of source/action picker
1 parent 3cafbf2 commit 992c3d9

File tree

1 file changed

+12
-2
lines changed

1 file changed

+12
-2
lines changed

denops/fall/main/picker.ts

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -174,6 +174,10 @@ async function internalStart(
174174
const sourcePickerStyle = getSourcePickerStyleConfig(conf.style);
175175
const actionPickerStyle = getActionPickerStylConfig(conf.style);
176176

177+
const sourcePickerZindex = sourcePickerStyle.layout?.zindex ?? 50;
178+
const actionPickerZindex = actionPickerStyle.layout?.zindex ??
179+
(sourcePickerZindex + 1);
180+
177181
const sourceStream = await source.stream({ cmdline });
178182
await using sourcePicker = await Picker.fromStream(
179183
sourceStream,
@@ -186,7 +190,10 @@ async function internalStart(
186190
title: " " + `${source.name} ${cmdline}`.trim() + " ",
187191
selectable: true,
188192
restoreContext: options.restoreContext,
189-
layout: sourcePickerStyle.layout,
193+
layout: {
194+
...sourcePickerStyle.layout,
195+
zindex: sourcePickerZindex,
196+
},
190197
query: sourcePickerStyle.query,
191198
},
192199
);
@@ -207,7 +214,10 @@ async function internalStart(
207214
actionPreviewers,
208215
{
209216
...(pickerOptions.options ?? {}),
210-
layout: actionPickerStyle.layout,
217+
layout: {
218+
...actionPickerStyle.layout,
219+
zindex: actionPickerZindex,
220+
},
211221
query: actionPickerStyle.query,
212222
},
213223
);

0 commit comments

Comments
 (0)