extensions_ui : Scroll to top on filter change (#27305)
Closes #27100 https://github.com/user-attachments/assets/0fc1409d-01c1-4caa-a2ed-762c8951930f Release Notes: - N/A
This commit is contained in:
parent
d96a50b029
commit
044eb7b990
1 changed files with 6 additions and 5 deletions
|
@ -12,9 +12,9 @@ use editor::{Editor, EditorElement, EditorStyle};
|
||||||
use extension_host::{ExtensionManifest, ExtensionOperation, ExtensionStore};
|
use extension_host::{ExtensionManifest, ExtensionOperation, ExtensionStore};
|
||||||
use fuzzy::{match_strings, StringMatchCandidate};
|
use fuzzy::{match_strings, StringMatchCandidate};
|
||||||
use gpui::{
|
use gpui::{
|
||||||
actions, uniform_list, Action, App, ClipboardItem, Context, Entity, EventEmitter, Flatten,
|
actions, point, uniform_list, Action, App, ClipboardItem, Context, Entity, EventEmitter,
|
||||||
Focusable, InteractiveElement, KeyContext, ParentElement, Render, Styled, Task, TextStyle,
|
Flatten, Focusable, InteractiveElement, KeyContext, ParentElement, Render, Styled, Task,
|
||||||
UniformListScrollHandle, WeakEntity, Window,
|
TextStyle, UniformListScrollHandle, WeakEntity, Window,
|
||||||
};
|
};
|
||||||
use num_format::{Locale, ToFormattedString};
|
use num_format::{Locale, ToFormattedString};
|
||||||
use project::DirectoryLister;
|
use project::DirectoryLister;
|
||||||
|
@ -23,8 +23,8 @@ use settings::Settings;
|
||||||
use strum::IntoEnumIterator as _;
|
use strum::IntoEnumIterator as _;
|
||||||
use theme::ThemeSettings;
|
use theme::ThemeSettings;
|
||||||
use ui::{
|
use ui::{
|
||||||
prelude::*, CheckboxWithLabel, ContextMenu, PopoverMenu, Scrollbar, ScrollbarState,
|
prelude::*, CheckboxWithLabel, ContextMenu, PopoverMenu, ScrollableHandle, Scrollbar,
|
||||||
ToggleButton, Tooltip,
|
ScrollbarState, ToggleButton, Tooltip,
|
||||||
};
|
};
|
||||||
use vim_mode_setting::VimModeSetting;
|
use vim_mode_setting::VimModeSetting;
|
||||||
use workspace::{
|
use workspace::{
|
||||||
|
@ -413,6 +413,7 @@ impl ExtensionsPage {
|
||||||
})
|
})
|
||||||
.map(|(ix, _)| ix),
|
.map(|(ix, _)| ix),
|
||||||
);
|
);
|
||||||
|
self.list.set_offset(point(px(0.), px(0.)));
|
||||||
cx.notify();
|
cx.notify();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue