1#![doc(
2 html_logo_url = "https://freyaui.dev/logo.svg",
3 html_favicon_url = "https://freyaui.dev/logo.svg"
4)]
5#![cfg_attr(feature = "docs", feature(doc_cfg))]
6pub mod prelude {
98 pub use freya_core::prelude::*;
99 pub use freya_edit::{
100 Clipboard,
101 ClipboardError,
102 };
103 #[cfg_attr(feature = "docs", doc(cfg(feature = "winit")))]
104 #[cfg(feature = "winit")]
105 pub use freya_winit::{
106 WindowDragExt,
107 WinitPlatformExt,
108 config::{
109 CloseDecision,
110 LaunchConfig,
111 WindowConfig,
112 },
113 renderer::{
114 NativeEvent,
115 RendererContext,
116 },
117 };
118
119 pub use crate::components::*;
120
121 #[cfg_attr(feature = "docs", doc(cfg(feature = "winit")))]
122 #[cfg(feature = "winit")]
123 pub fn launch(launch_config: LaunchConfig) {
124 #[cfg(feature = "devtools")]
125 let launch_config = launch_config.with_plugin(freya_devtools::DevtoolsPlugin::default());
126 #[cfg(debug_assertions)]
127 let launch_config = launch_config
128 .with_plugin(freya_performance_plugin::PerformanceOverlayPlugin::default());
129 freya_winit::launch(launch_config)
130 }
131
132 #[cfg_attr(feature = "docs", doc(cfg(feature = "router")))]
133 #[cfg(feature = "router")]
134 pub use freya_router;
135 pub use torin::{
136 alignment::Alignment,
137 content::Content,
138 direction::Direction,
139 gaps::Gaps,
140 geometry::{
141 Area,
142 CursorPoint,
143 Size2D,
144 },
145 position::Position,
146 size::Size,
147 visible_size::VisibleSize,
148 };
149}
150pub mod elements {
151 pub use freya_core::elements::*;
152}
153
154pub mod components {
155 #[cfg_attr(feature = "docs", doc(cfg(feature = "gif")))]
156 #[cfg(feature = "gif")]
157 pub use freya_components::gif_viewer::*;
158 #[cfg_attr(feature = "docs", doc(cfg(feature = "markdown")))]
159 #[cfg(feature = "markdown")]
160 pub use freya_components::markdown::*;
161 cfg_if::cfg_if! {
162 if #[cfg(feature = "router")] {
163 #[cfg_attr(feature = "docs", doc(cfg(feature = "router")))]
164 pub use freya_components::activable_route::*;
165 pub use freya_components::link::*;
166 pub use freya_components::native_router::*;
167 pub use freya_components::animated_router::*;
168 }
169 }
170 #[cfg_attr(feature = "docs", doc(cfg(feature = "remote-asset")))]
171 #[cfg(feature = "remote-asset")]
172 pub use freya_components::Uri;
173 #[cfg_attr(feature = "docs", doc(cfg(feature = "calendar")))]
174 #[cfg(feature = "calendar")]
175 pub use freya_components::calendar::*;
176 #[cfg(feature = "titlebar")]
177 pub use freya_components::titlebar::*;
178 pub use freya_components::{
179 accordion::*,
180 activable::*,
181 activable_context::*,
182 attached::*,
183 button::*,
184 canvas::*,
185 card::*,
186 checkbox::*,
187 chip::*,
188 color_picker::*,
189 context_menu::*,
190 cursor_area::*,
191 define_theme,
192 drag_drop::*,
193 draggable_canvas::*,
194 element_expansions::*,
195 floating_tab::*,
196 gallery,
197 get_theme,
198 icons::{
199 arrow::*,
200 tick::*,
201 },
202 image_viewer::*,
203 input::*,
204 loader::*,
205 menu::*,
206 overflowed_content::*,
207 popup::*,
208 portal::*,
209 progressbar::*,
210 radio_item::*,
211 resizable_container::*,
212 scrollviews::*,
213 segmented_button::*,
214 select::*,
215 selectable_text::*,
216 sidebar::*,
217 skeleton::*,
218 slider::*,
219 switch::*,
220 table::*,
221 theming::{
222 component_themes::{
223 ColorsSheet,
224 Theme,
225 },
226 extensions::*,
227 hooks::*,
228 macros::Preference,
229 themes::*,
230 },
231 tile::*,
232 tooltip::*,
233 typography::*,
234 };
235}
236
237pub mod text_edit {
238 pub use freya_edit::*;
239}
240
241pub mod clipboard {
242 pub use freya_clipboard::prelude::*;
243}
244
245pub mod animation {
246 pub use freya_animation::prelude::*;
247}
248
249#[cfg_attr(feature = "docs", doc(cfg(feature = "plot")))]
250#[cfg(feature = "plot")]
251pub mod plot {
252 pub use freya_plotters_backend::*;
253 pub use plotters;
254}
255
256#[cfg_attr(feature = "docs", doc(cfg(feature = "router")))]
257#[cfg(feature = "router")]
258pub mod router {
259 pub use freya_router::prelude::*;
260}
261
262#[cfg_attr(feature = "docs", doc(cfg(feature = "i18n")))]
263#[cfg(feature = "i18n")]
264pub mod i18n {
265 pub use freya_i18n::prelude::*;
266}
267
268#[cfg_attr(feature = "docs", doc(cfg(feature = "engine")))]
269#[cfg(feature = "engine")]
270pub mod engine {
271 pub use freya_engine::*;
272}
273
274#[cfg_attr(feature = "docs", doc(cfg(feature = "winit")))]
275#[cfg(feature = "winit")]
276pub mod winit {
277 pub use freya_winit::winit::*;
278}
279
280pub mod helpers {
281 pub use freya_core::helpers::*;
282}
283
284#[cfg_attr(feature = "docs", doc(cfg(feature = "tray")))]
285#[cfg(feature = "tray")]
286pub mod tray {
287 pub use freya_winit::tray::*;
288}
289
290#[cfg_attr(feature = "docs", doc(cfg(feature = "sdk")))]
291#[cfg(feature = "sdk")]
292pub mod sdk {
293 pub use freya_sdk::prelude::*;
294}
295
296#[cfg_attr(feature = "docs", doc(cfg(feature = "material-design")))]
297#[cfg(feature = "material-design")]
298pub mod material_design {
299 pub use freya_material_design::prelude::*;
300}
301
302#[cfg_attr(feature = "docs", doc(cfg(feature = "icons")))]
303#[cfg(feature = "icons")]
304pub mod icons {
305 pub use freya_icons::*;
306}
307
308#[cfg(feature = "radio")]
310#[cfg_attr(feature = "docs", doc(cfg(feature = "radio")))]
311pub mod radio {
312 pub use freya_radio::prelude::*;
313}
314
315#[cfg(feature = "query")]
317#[cfg_attr(feature = "docs", doc(cfg(feature = "query")))]
318pub mod query {
319 pub use freya_query::prelude::*;
320}
321
322#[cfg(feature = "webview")]
324#[cfg_attr(feature = "docs", doc(cfg(feature = "webview")))]
325pub mod webview {
326 pub use freya_webview::prelude::*;
327}
328
329#[cfg(feature = "terminal")]
331#[cfg_attr(feature = "docs", doc(cfg(feature = "terminal")))]
332pub mod terminal {
333 pub use freya_terminal::prelude::*;
334}
335
336#[cfg(feature = "code-editor")]
338#[cfg_attr(feature = "docs", doc(cfg(feature = "code-editor")))]
339pub mod code_editor {
340 pub use freya_code_editor::prelude::*;
341}
342
343#[cfg(feature = "camera")]
345#[cfg_attr(feature = "docs", doc(cfg(feature = "camera")))]
346pub mod camera {
347 pub use freya_camera::{
348 init,
349 nokhwa,
350 prelude::*,
351 };
352}
353
354#[cfg(feature = "performance")]
355#[cfg_attr(feature = "docs", doc(cfg(feature = "performance")))]
356pub mod performance {
357 pub use freya_performance_plugin::*;
358}
359
360#[cfg(target_os = "android")]
361pub mod android {
362 pub use freya_android::*;
363}
364
365#[cfg(doc)]
366pub mod _docs;