use super::style::{
CompactScrollbarStyle, ScrollbarStyle, SignalScrollbarStyle, StandardScrollbarStyle,
};
use super::theme::ScrollbarTheme;
use crate::tokens::{BuiltinSet, Tokens, TokenTheme};
pub struct ScrollbarSettings {
pub theme: Box<dyn ScrollbarTheme>,
pub style: Box<dyn ScrollbarStyle>,
}
impl Default for ScrollbarSettings {
fn default() -> Self {
Self::standard()
}
}
impl ScrollbarSettings {
pub fn standard() -> Self {
Self {
theme: Box::new(TokenTheme::new(Tokens::builtin(BuiltinSet::Dark))),
style: Box::new(StandardScrollbarStyle),
}
}
pub fn compact() -> Self {
Self {
theme: Box::new(TokenTheme::new(Tokens::builtin(BuiltinSet::Dark))),
style: Box::new(CompactScrollbarStyle),
}
}
pub fn signal() -> Self {
Self {
theme: Box::new(TokenTheme::new(Tokens::builtin(BuiltinSet::Dark))),
style: Box::new(SignalScrollbarStyle),
}
}
}