#![warn(missing_debug_implementations)]
#![deny(missing_docs)]
mod badge;
mod button;
mod callout;
mod card;
mod checkbox;
mod collapsing;
mod flash;
mod indicator;
mod input;
mod log_bar;
mod menu;
mod modal;
mod multi_terminal;
mod pairing;
mod pill;
mod popover;
mod progress_bar;
mod segmented;
mod select;
mod slider;
mod spinner;
mod switch;
mod tabs;
mod text_area;
mod theme;
mod theme_switcher;
mod toast;
pub use badge::{Badge, BadgeTone};
pub use button::{Button, ButtonSize};
pub use callout::{Callout, CalloutTone};
pub use card::Card;
pub use checkbox::Checkbox;
pub use collapsing::CollapsingSection;
pub use flash::{flash_error, flash_success, FlashKind, ResponseFlashExt, FLASH_DURATION};
pub use indicator::{Indicator, IndicatorState};
pub use input::TextInput;
pub use log_bar::{LogBar, LogEntry, LogKind};
pub use menu::{Menu, MenuItem};
pub use modal::Modal;
pub use multi_terminal::{
LineKind, MultiTerminal, TerminalEvent, TerminalLine, TerminalPane, TerminalStatus,
};
pub use pairing::{PairItem, Pairing};
pub use pill::StatusPill;
pub use popover::{Popover, PopoverSide};
pub use progress_bar::ProgressBar;
pub use segmented::SegmentedButton;
pub use select::Select;
pub use slider::Slider;
pub use spinner::Spinner;
pub use switch::Switch;
pub use tabs::TabBar;
pub use text_area::TextArea;
pub use theme::{Accent, BuiltInTheme, Palette, Theme, Typography};
pub use theme_switcher::ThemeSwitcher;
pub use toast::{Toast, Toasts};
pub use egui;
#[track_caller]
pub fn request_repaint_at_rate(ctx: &egui::Context, hz: f32) {
let pd = ctx.input(|i| i.predicted_dt);
if let Ok(d) = std::time::Duration::try_from_secs_f32(1.0 / hz + pd) {
ctx.request_repaint_after(d);
}
}