ui: Add Chip component (#34521)
Possibly the simplest component in our set, but a nice one to have so we can standardize how it looks across the app. Release Notes: - N/A
This commit is contained in:
parent
ee4b9a27a2
commit
59d524427e
7 changed files with 124 additions and 40 deletions
|
@ -24,7 +24,7 @@ use settings::Settings;
|
|||
use strum::IntoEnumIterator as _;
|
||||
use theme::ThemeSettings;
|
||||
use ui::{
|
||||
CheckboxWithLabel, ContextMenu, PopoverMenu, ScrollableHandle, Scrollbar, ScrollbarState,
|
||||
CheckboxWithLabel, Chip, ContextMenu, PopoverMenu, ScrollableHandle, Scrollbar, ScrollbarState,
|
||||
ToggleButton, Tooltip, prelude::*,
|
||||
};
|
||||
use vim_mode_setting::VimModeSetting;
|
||||
|
@ -759,20 +759,7 @@ impl ExtensionsPage {
|
|||
_ => {}
|
||||
}
|
||||
|
||||
Some(
|
||||
div()
|
||||
.px_1()
|
||||
.border_1()
|
||||
.rounded_sm()
|
||||
.border_color(cx.theme().colors().border)
|
||||
.bg(cx.theme().colors().element_background)
|
||||
.child(
|
||||
Label::new(extension_provides_label(
|
||||
*provides,
|
||||
))
|
||||
.size(LabelSize::XSmall),
|
||||
),
|
||||
)
|
||||
Some(Chip::new(extension_provides_label(*provides)))
|
||||
})
|
||||
.collect::<Vec<_>>(),
|
||||
),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue