Skip to main content

egui_elements/components/
mod.rs

1//! Higher-level composites built on the themed widgets.
2//!
3//! Every item here is feature-gated:
4//!
5//! | Type | Feature | Notes |
6//! |------|---------|-------|
7//! | [`SecureInputField`] | `secure-types` | Masked field with Lucide show/hide; optional QR fill on Linux/Windows |
8//! | [`CredentialsForm`] | `secure-types` | Username / password / confirm + optional virtual keyboard |
9//! | [`VirtualKeyboard`] | `secure-types` | On-screen keyboard writing into a `SecureString` |
10//! | [`QrImage`] | `qr-image` | Encode text as a PNG QR `egui::Image` |
11//! | [`QRScanner`] | `qr-scanner` | Overlay that captures the monitor and decodes a QR (Linux and Windows) |
12//!
13//! `secure-types` and `qr-scanner` also enable `lucide`. `qr-scanner` also
14//! pulls in `secure-types` (decoded payload is a `SecureString`). Enabling
15//! `qr-scanner` on an unsupported target compiles the crate but does not
16//! export [`QRScanner`].
17
18#[cfg(feature = "secure-types")]
19mod input_field;
20
21#[cfg(all(
22   feature = "qr-scanner",
23   any(target_os = "linux", target_os = "windows")
24))]
25mod qr_scanner;
26
27#[cfg(feature = "secure-types")]
28mod virtual_keyboard;
29
30#[cfg(feature = "qr-image")]
31mod qr_image;
32
33#[cfg(feature = "secure-types")]
34mod credentials_form;
35
36#[cfg(feature = "secure-types")]
37pub use secure_types;
38
39#[cfg(feature = "secure-types")]
40pub use input_field::SecureInputField;
41
42#[cfg(all(
43   feature = "qr-scanner",
44   any(target_os = "linux", target_os = "windows")
45))]
46pub use qr_scanner::QRScanner;
47
48#[cfg(feature = "secure-types")]
49pub use virtual_keyboard::VirtualKeyboard;
50
51#[cfg(feature = "qr-image")]
52pub use qr_image::QrImage;
53
54#[cfg(feature = "secure-types")]
55pub use credentials_form::CredentialsForm;