diff options
| author | pml68 <contact@pml68.me> | 2024-08-30 00:06:33 +0200 |
|---|---|---|
| committer | pml68 <contact@pml68.me> | 2024-08-30 01:05:13 +0200 |
| commit | efb9dbd8072becbf3d34e74e737287b982432164 (patch) | |
| tree | 183bbc5a1c7ba7b558542843a58f1d60e6ce5267 /src/types | |
| parent | feat: initial commit (diff) | |
| download | iced-builder-efb9dbd8072becbf3d34e74e737287b982432164.tar.gz | |
feat: add usable state logic
Diffstat (limited to 'src/types')
| -rw-r--r-- | src/types/mod.rs | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/src/types/mod.rs b/src/types/mod.rs new file mode 100644 index 0000000..69df615 --- /dev/null +++ b/src/types/mod.rs @@ -0,0 +1,28 @@ +use iced::{Font, Length}; + +pub struct DesignerState { + pub designer_content: Vec<RenderedElement>, + pub designer_page: DesignerPage, +} + +pub struct RenderedElement { + pub id: String, + pub children: Vec<RenderedElement>, + pub name: ElementName, + pub props: Vec<Prop>, +} + +pub enum ElementName {} + +pub enum Prop { + String(String, String), + Decimal(String, i32), + Float(String, f32), + Font(String, Font), + Length(String, Length), +} + +pub enum DesignerPage { + Designer, + CodeView, +} |
