slider: Remove thumb tooltip (#1582)

This commit is contained in:
Nico Gründel 2025-11-13 01:33:37 +01:00 committed by GitHub
parent c62bb8b6a1
commit 3ef1ce3d3e
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -1,6 +1,6 @@
use std::ops::Range;
use crate::{h_flex, tooltip::Tooltip, ActiveTheme, AxisExt, StyledExt};
use crate::{h_flex, ActiveTheme, AxisExt, StyledExt};
use gpui::{
canvas, div, prelude::FluentBuilder as _, px, Along, App, AppContext as _, Axis, Background,
Bounds, Context, Corners, DragMoveEvent, Empty, Entity, EntityId, EventEmitter, Hsla,
@ -428,9 +428,7 @@ impl Slider {
window: &mut Window,
cx: &mut App,
) -> impl gpui::IntoElement {
let state = self.state.read(cx);
let entity_id = self.state.entity_id();
let value = state.value;
let axis = self.axis;
let id = ("slider-thumb", is_start as u32);
@ -491,13 +489,6 @@ impl Slider {
}
},
))
.tooltip(move |window, cx| {
Tooltip::new(format!(
"{}",
if is_start { value.start() } else { value.end() }
))
.build(window, cx)
})
}
}