diff --git a/crates/ui-contract/Cargo.toml b/crates/ui-contract/Cargo.toml new file mode 100644 index 000000000..52f06d3c6 --- /dev/null +++ b/crates/ui-contract/Cargo.toml @@ -0,0 +1,93 @@ +[package] +name = "craft-ui-contract" +version.workspace = true +edition.workspace = true +license.workspace = true +repository.workspace = true +rust-version.workspace = true +description = "Runtime, style, fonts, primitives, the component contract, layout and the test kit of the craft UI library, on egui" + +[lib] +# Every test lives in the `it` integration binary. +test = false + +[lints] +workspace = true + +[features] +default = [] +# `craft_ui::testing`: the fixture and suite runner. +testing = ["dep:libtest-mimic"] +# `craft_ui::testing::snapshot`: stories rendered to images offscreen (desktop only). +snapshot = ["testing", "dep:egui_kittest", "dep:image"] +# Draw colour glyphs (COLR, sbix, CBDT), e.g. colour emoji. +color_fonts = ["dep:epaint", "epaint/color_fonts"] +# Find installed fonts for characters the app's faces lack (desktop only). +system_fonts = ["dep:fontique"] + +[dependencies] +craft-behavior = { workspace = true } +# `Intent::Access` and the AccessKit action requests the key stage routes. +accesskit = "0.25" +craft-keymap = { workspace = true, features = ["egui"] } +craft-theme = { workspace = true } +craft-ui-macros = { workspace = true } +egui = { workspace = true } +libtest-mimic = { version = "0.8", optional = true } +craft-host = { workspace = true } +# `WindowSystem` and `restore::Store`, which viewport mounts place windows through. +# `ui`: the window crate's egui side builds once, the same for the runtime, the shell's `app` and the apps. +craft-window = { workspace = true, features = ["ui"] } +# `quit`, which `runtime::windows::logic` routes a root close through. +craft-quit = { workspace = true } +craft-i18n = { workspace = true, features = ["collate"] } +log = "0.4" +smallvec = { workspace = true } +inventory = "0.3.25" +serde = { workspace = true } + +# `fonts`: character maps and variation axes of faces, and inflating egui's default fonts, stored deflated. +skrifa = { version = "0.44", default-features = false, features = ["std"] } +flate2 = { version = "1", default-features = false, features = ["rust_backend"] } +# The installed font folders, for the on-demand font candidates (`fonts::SystemCandidates`). +craft-font-catalog = { workspace = true, default-features = false } +# The craft-fonts faces (`fonts::EmbeddedFace`, `fonts::ServedFace`). +craft-fonts-build = { workspace = true } +# Only `color_fonts` reads it: the feature turns on epaint's colour glyphs. +epaint = { version = "0.37", default-features = false, optional = true } + +# Icon rasterising; the version egui_extras's `svg` feature uses, so apps build one copy. +resvg = { version = "0.45.1", default-features = false } +# `std::time::Instant` on native; the browser clock on wasm, where `Instant::now` panics. +web-time = "1.1" + +[target.'cfg(not(target_arch = "wasm32"))'.dependencies] +# The versions egui_system_font_provider 0.37 uses. +fontique = { version = "0.11.1", default-features = false, features = ["system", "fontconfig-dlopen"], optional = true } +# `testing::snapshot`: egui's wgpu test renderer, which prefers a software adapter, and PNG output. +egui_kittest = { version = "0.37", features = ["wgpu"], optional = true } +image = { version = "0.25", default-features = false, features = ["png"], optional = true } + +# build.rs reads icons/icons.toml and deflates the suite's default fonts (Inter, egui's faces) for `fonts::deflated_default_definitions`. +[build-dependencies] +toml = { version = "1.1", default-features = false, features = ["std", "parse", "serde"] } +flate2 = { version = "1", default-features = false, features = ["rust_backend"] } +epaint_default_fonts = "0.37" + +[dev-dependencies] +craft-ui-contract = { path = ".", features = ["testing"] } +craft-behavior = { workspace = true } +craft-fonts-build = { workspace = true } +craft-host = { workspace = true } +craft-keymap = { workspace = true, features = ["egui"] } +craft-theme = { workspace = true } +craft-ui-test-kit = { workspace = true } +craft-window = { workspace = true } +egui = { workspace = true } +proc-macro2 = "1" +syn = { version = "2", features = ["full"] } + +[[test]] +name = "it" +path = "tests/it/main.rs" +harness = false diff --git a/crates/ui-contract/build.rs b/crates/ui-contract/build.rs new file mode 100644 index 000000000..24450a548 --- /dev/null +++ b/crates/ui-contract/build.rs @@ -0,0 +1,250 @@ +//! Generates `primitives::icon::IconSet` and the embedded SVG catalog from `icons/icons.toml`. + +use std::collections::BTreeSet; +use std::fmt::Write as _; +use std::path::Path; + +use toml::{Table, Value}; + +struct Set { + id: String, + title: String, + licence: String, + stroke_width: Option, + /// The base set: every icon has a file in it, and the other sets fall back to it. + base: bool, + /// The set `IconSet::default()` names. + default: bool, +} + +struct Entry { + name: String, + directional: bool, + /// One file stem per set, in set order; `None` where a non-base set has no file. + files: Vec>, +} + +fn main() { + let root = std::env::var("CARGO_MANIFEST_DIR").expect("CARGO_MANIFEST_DIR"); + let dir = Path::new(&root).join("icons"); + println!("cargo::rerun-if-changed=icons"); + let text = std::fs::read_to_string(dir.join("icons.toml")).expect("read icons/icons.toml"); + let manifest: Table = text.parse().unwrap_or_else(|e| panic!("icons/icons.toml: {e}")); + let sets = sets(&manifest); + let icons = icons(&manifest, &sets); + check_files(&dir, &sets, &icons); + let out = std::env::var("OUT_DIR").expect("OUT_DIR"); + std::fs::write(Path::new(&out).join("icons.rs"), generate(&root, &sets, &icons)).expect("write icons.rs"); + deflate_egui_fonts(Path::new(&out)); +} + +/// Deflate egui's default fonts and the suite's interface face into `OUT_DIR/egui_fonts/` for `fonts::deflated_default_definitions`: +/// egui's `default_fonts` feature embeds the same files uncompressed (1.4 MB), more than a web +/// build's size budget allows. +fn deflate_egui_fonts(out: &Path) { + use std::io::Write as _; + let dir = out.join("egui_fonts"); + let fonts = [ + ("Hack-Regular", epaint_default_fonts::HACK_REGULAR), + ("egui-icons", epaint_default_fonts::EGUI_ICONS), + ("Ubuntu-Light", epaint_default_fonts::UBUNTU_LIGHT), + ]; + // The suite's interface face (Inter, subset to Latin, Greek and Cyrillic; fonts/inter/OFL.txt). + println!("cargo::rerun-if-changed=fonts/inter"); + let inter: Vec<(&str, Vec)> = ["Inter-Regular", "Inter-SemiBold"] + .into_iter() + .map(|name| (name, std::fs::read(format!("fonts/inter/{name}.ttf")).unwrap_or_else(|e| panic!("fonts/inter/{name}.ttf: {e}")))) + .collect(); + std::fs::create_dir_all(&dir).expect("create egui_fonts"); + for (name, bytes) in fonts.into_iter().chain(inter.iter().map(|(name, bytes)| (*name, bytes.as_slice()))) { + let mut z = flate2::write::DeflateEncoder::new(Vec::new(), flate2::Compression::best()); + z.write_all(bytes).expect("deflate"); + std::fs::write(dir.join(format!("{name}.ttf.deflate")), z.finish().expect("deflate")).expect("write egui font"); + } +} + +fn str_field<'a>(table: &'a Table, key: &str, what: &str) -> &'a str { + table.get(key).and_then(Value::as_str).unwrap_or_else(|| panic!("icons/icons.toml: {what} has no string `{key}`")) +} + +fn sets(manifest: &Table) -> Vec { + let list = manifest.get("set").and_then(Value::as_array).expect("icons/icons.toml: no [[set]] tables"); + let sets: Vec = list + .iter() + .map(|value| { + let table = value.as_table().expect("icons/icons.toml: [[set]] is not a table"); + let id = str_field(table, "id", "a [[set]]").to_owned(); + assert!(is_slug(&id, '_'), "icons/icons.toml: set id `{id}` is not lower-case ascii"); + let what = format!("set `{id}`"); + let stroke_width = match str_field(table, "kind", &what) { + "stroke" => Some( + table.get("stroke_width").and_then(Value::as_float).unwrap_or_else(|| panic!("icons/icons.toml: {what} has no `stroke_width`")), + ), + "fill" => None, + other => panic!("icons/icons.toml: {what} has kind `{other}`, not `stroke` or `fill`"), + }; + Set { + title: str_field(table, "title", &what).to_owned(), + licence: str_field(table, "licence", &what).to_owned(), + stroke_width, + base: table.get("base").and_then(Value::as_bool).unwrap_or(false), + default: table.get("default").and_then(Value::as_bool).unwrap_or(false), + id, + } + }) + .collect(); + assert!(!sets.is_empty(), "icons/icons.toml: no sets"); + assert_eq!(sets.iter().filter(|s| s.base).count(), 1, "icons/icons.toml: exactly one [[set]] must have `base = true`"); + assert_eq!(sets.iter().filter(|s| s.default).count(), 1, "icons/icons.toml: exactly one [[set]] must have `default = true`"); + sets +} + +/// The icons sorted by name, so the catalog looks one up by binary search. +fn icons(manifest: &Table, sets: &[Set]) -> Vec { + let list = manifest.get("icon").and_then(Value::as_array).expect("icons/icons.toml: no [[icon]] tables"); + let mut seen = BTreeSet::new(); + let mut entries: Vec = list + .iter() + .map(|value| { + let table = value.as_table().expect("icons/icons.toml: [[icon]] is not a table"); + let name = str_field(table, "name", "an [[icon]]").to_owned(); + assert!(is_slug(&name, '_'), "icons/icons.toml: icon name `{name}` is not lower-case ascii with underscores"); + assert!(seen.insert(name.clone()), "icons/icons.toml: icon `{name}` is listed twice"); + let directional = table + .get("directional") + .and_then(Value::as_bool) + .unwrap_or_else(|| panic!("icons/icons.toml: icon `{name}` has no `directional = true|false`")); + let files = sets + .iter() + .map(|set| { + let file = table.get(&set.id).and_then(Value::as_str); + assert!(file.is_some() || !set.base, "icon `{name}` has no file in the base set `{}`", set.id); + if let Some(file) = file { + assert!(is_slug(file, '-'), "icon `{name}`: file `{file}` in set `{}` is not a plain file stem", set.id); + } + file.map(str::to_owned) + }) + .collect(); + Entry { name, directional, files } + }) + .collect(); + entries.sort_by(|a, b| a.name.cmp(&b.name)); + entries +} + +/// Every listed file exists, and every set folder holds only listed files and its licence. +fn check_files(dir: &Path, sets: &[Set], icons: &[Entry]) { + for (index, set) in sets.iter().enumerate() { + let folder = dir.join(&set.id); + for icon in icons { + if let Some(file) = &icon.files[index] { + let path = folder.join(format!("{file}.svg")); + assert!(path.is_file(), "icon `{}` is missing from set `{}`: no file {}", icon.name, set.id, path.display()); + } + } + let listed: BTreeSet = icons.iter().filter_map(|icon| icon.files[index].as_ref()).map(|file| format!("{file}.svg")).collect(); + let entries = std::fs::read_dir(&folder).unwrap_or_else(|e| panic!("read {}: {e}", folder.display())); + for entry in entries { + let file = entry.expect("read icon folder entry").file_name().to_string_lossy().into_owned(); + assert!(file == "LICENSE" || listed.contains(&file), "set `{}` holds {file}, which icons.toml does not list", set.id); + } + assert!(folder.join("LICENSE").is_file(), "set `{}` has no LICENSE file", set.id); + } +} + +fn is_slug(s: &str, separator: char) -> bool { + s.starts_with(|c: char| c.is_ascii_lowercase()) && s.chars().all(|c| c.is_ascii_lowercase() || c.is_ascii_digit() || c == separator) +} + +fn camel(s: &str) -> String { + s.split(['_', '-']).map(|word| word[..1].to_ascii_uppercase() + &word[1..]).collect() +} + +fn generate(root: &str, sets: &[Set], icons: &[Entry]) -> String { + let mut out = String::new(); + let n = icons.len(); + let base = sets.iter().find(|s| s.base).expect("a base set"); + + let _ = writeln!(out, "/// The names of the catalog's icons, sorted: the manifest's `[[icon]]` names."); + let _ = + writeln!(out, "pub(super) const NAMES: [&str; {n}] = [{}];\n", icons.iter().map(|i| format!("{:?}", i.name)).collect::>().join(", ")); + let _ = writeln!( + out, + "/// Whether each icon points along the reading direction, by index in `NAMES`.\npub(super) const DIRECTIONAL: [bool; {n}] = [{}];\n", + icons.iter().map(|i| i.directional.to_string()).collect::>().join(", ") + ); + + out.push_str("/// An icon set. The base set draws every icon; the others are packs that draw the icons they have and fall back to the base set for the rest.\n"); + out.push_str("#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, Default)]\n#[non_exhaustive]\npub enum IconSet {\n"); + for set in sets { + if set.default { + out.push_str(" #[default]\n"); + } + let _ = writeln!(out, " /// {}, {}.\n {},", set.title, set.licence, camel(&set.id)); + } + out.push_str("}\n\nimpl IconSet {\n /// Every set, in manifest order.\n"); + let _ = writeln!( + out, + " pub const ALL: [IconSet; {}] = [{}];\n", + sets.len(), + sets.iter().map(|s| format!("IconSet::{}", camel(&s.id))).collect::>().join(", ") + ); + let _ = writeln!( + out, + " /// The base set: it draws every icon, and the other sets fall back to it.\n pub const BASE: IconSet = IconSet::{};\n", + camel(&base.id) + ); + set_fn(&mut out, sets, "The folder name under `crates/ui-contract/icons/`.", "id", "&'static str", |s| format!("{:?}", s.id)); + set_fn(&mut out, sets, "The set's name for display.", "title", "&'static str", |s| format!("{:?}", s.title)); + set_fn(&mut out, sets, "The set's own stroke width in view-box units; `None` for a set drawn with fills.", "stroke_width", "Option", |s| { + s.stroke_width.map_or("None".to_owned(), |w| format!("Some({w:?})")) + }); + out.push_str("}\n\n"); + + out.push_str("/// The SVG document of the icon at `index` in `NAMES` for `set`, and whether the set draws it from its own file.\n"); + out.push_str("pub(super) const fn svg(index: usize, set: IconSet) -> (&'static [u8], bool) {\n match set {\n"); + for set in sets { + let upper = set.id.to_ascii_uppercase(); + if set.base { + let _ = writeln!(out, " IconSet::{} => ({upper}[index], true),", camel(&set.id)); + } else { + let _ = writeln!( + out, + " IconSet::{} => match {upper}[index] {{\n Some(bytes) => (bytes, true),\n None => ({}[index], false),\n }},", + camel(&set.id), + base.id.to_ascii_uppercase() + ); + } + } + out.push_str(" }\n}\n"); + + for (index, set) in sets.iter().enumerate() { + if set.base { + let _ = writeln!(out, "\nconst {}: [&[u8]; {n}] = [", set.id.to_ascii_uppercase()); + } else { + let _ = writeln!(out, "\nconst {}: [Option<&[u8]>; {n}] = [", set.id.to_ascii_uppercase()); + } + for icon in icons { + match (&icon.files[index], set.base) { + (Some(file), true) => { + let _ = writeln!(out, " include_bytes!({:?}),", format!("{root}/icons/{}/{file}.svg", set.id)); + } + (Some(file), false) => { + let _ = writeln!(out, " Some(include_bytes!({:?})),", format!("{root}/icons/{}/{file}.svg", set.id)); + } + (None, _) => out.push_str(" None,\n"), + } + } + out.push_str("];\n"); + } + out +} + +/// A `const fn` of `IconSet` with one match arm per set. +fn set_fn(out: &mut String, sets: &[Set], doc: &str, func: &str, ty: &str, value: fn(&Set) -> String) { + let _ = writeln!(out, " /// {doc}\n pub const fn {func}(self) -> {ty} {{\n match self {{"); + for set in sets { + let _ = writeln!(out, " IconSet::{} => {},", camel(&set.id), value(set)); + } + out.push_str(" }\n }\n\n"); +} diff --git a/crates/ui-contract/fonts/inter/Inter-Regular.ttf b/crates/ui-contract/fonts/inter/Inter-Regular.ttf new file mode 100644 index 000000000..6ca326fe2 Binary files /dev/null and b/crates/ui-contract/fonts/inter/Inter-Regular.ttf differ diff --git a/crates/ui-contract/fonts/inter/Inter-SemiBold.ttf b/crates/ui-contract/fonts/inter/Inter-SemiBold.ttf new file mode 100644 index 000000000..3cb705106 Binary files /dev/null and b/crates/ui-contract/fonts/inter/Inter-SemiBold.ttf differ diff --git a/crates/ui-contract/fonts/inter/OFL.txt b/crates/ui-contract/fonts/inter/OFL.txt new file mode 100644 index 000000000..9b2ca37b3 --- /dev/null +++ b/crates/ui-contract/fonts/inter/OFL.txt @@ -0,0 +1,92 @@ +Copyright (c) 2016 The Inter Project Authors (https://github.com/rsms/inter) + +This Font Software is licensed under the SIL Open Font License, Version 1.1. +This license is copied below, and is also available with a FAQ at: +http://scripts.sil.org/OFL + +----------------------------------------------------------- +SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007 +----------------------------------------------------------- + +PREAMBLE +The goals of the Open Font License (OFL) are to stimulate worldwide +development of collaborative font projects, to support the font creation +efforts of academic and linguistic communities, and to provide a free and +open framework in which fonts may be shared and improved in partnership +with others. + +The OFL allows the licensed fonts to be used, studied, modified and +redistributed freely as long as they are not sold by themselves. The +fonts, including any derivative works, can be bundled, embedded, +redistributed and/or sold with any software provided that any reserved +names are not used by derivative works. The fonts and derivatives, +however, cannot be released under any other type of license. The +requirement for fonts to remain under this license does not apply +to any document created using the fonts or their derivatives. + +DEFINITIONS +"Font Software" refers to the set of files released by the Copyright +Holder(s) under this license and clearly marked as such. This may +include source files, build scripts and documentation. + +"Reserved Font Name" refers to any names specified as such after the +copyright statement(s). + +"Original Version" refers to the collection of Font Software components as +distributed by the Copyright Holder(s). + +"Modified Version" refers to any derivative made by adding to, deleting, +or substituting -- in part or in whole -- any of the components of the +Original Version, by changing formats or by porting the Font Software to a +new environment. + +"Author" refers to any designer, engineer, programmer, technical +writer or other person who contributed to the Font Software. + +PERMISSION AND CONDITIONS +Permission is hereby granted, free of charge, to any person obtaining +a copy of the Font Software, to use, study, copy, merge, embed, modify, +redistribute, and sell modified and unmodified copies of the Font +Software, subject to the following conditions: + +1) Neither the Font Software nor any of its individual components, +in Original or Modified Versions, may be sold by itself. + +2) Original or Modified Versions of the Font Software may be bundled, +redistributed and/or sold with any software, provided that each copy +contains the above copyright notice and this license. These can be +included either as stand-alone text files, human-readable headers or +in the appropriate machine-readable metadata fields within text or +binary files as long as those fields can be easily viewed by the user. + +3) No Modified Version of the Font Software may use the Reserved Font +Name(s) unless explicit written permission is granted by the corresponding +Copyright Holder. This restriction only applies to the primary font name as +presented to the users. + +4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font +Software shall not be used to promote, endorse or advertise any +Modified Version, except to acknowledge the contribution(s) of the +Copyright Holder(s) and the Author(s) or with their explicit written +permission. + +5) The Font Software, modified or unmodified, in part or in whole, +must be distributed entirely under this license, and must not be +distributed under any other license. The requirement for fonts to +remain under this license does not apply to any document created +using the Font Software. + +TERMINATION +This license becomes null and void if any of the above conditions are +not met. + +DISCLAIMER +THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT +OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE +COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL +DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM +OTHER DEALINGS IN THE FONT SOFTWARE. diff --git a/crates/ui-contract/icons/ATTRIBUTION.md b/crates/ui-contract/icons/ATTRIBUTION.md new file mode 100644 index 000000000..69b3c581c --- /dev/null +++ b/crates/ui-contract/icons/ATTRIBUTION.md @@ -0,0 +1,25 @@ +# Icon sources + +Each folder holds only the files `icons.toml` lists, unchanged from the pinned source (exception: the drawings named below the table), and the set's licence as `LICENSE`. To add an icon, copy its file from the same commit. + +| Folder | Set | Licence | Source (tag, commit) | Files taken from | +|---|---|---|---|---| +| `lucide/` | [Lucide](https://lucide.dev) | ISC | [lucide-icons/lucide](https://github.com/lucide-icons/lucide) `1.63.0`, `2ca268e74888d3506b3319fb8f94aaaaf70ceca9` | `icons/` | +| `phosphor/` | [Phosphor](https://phosphoricons.com), regular weight | MIT | [phosphor-icons/core](https://github.com/phosphor-icons/core) `v2.0.8`, `d42782b2abe747d904b971ccab48b182a1455f86` | `assets/regular/` | +| `carbon/` | [IBM Carbon](https://carbondesignsystem.com/elements/icons/library/) | Apache-2.0 | [carbon-design-system/carbon](https://github.com/carbon-design-system/carbon) `v11.119.0` (`@carbon/icons` 11.91.0), `571cd549545dd156e11f06fd046eb14efa6a61c3` | `packages/icons/src/svg/32/` | +| `tabler/` | [Tabler Icons](https://tabler.io/icons), outline | MIT | [tabler/tabler-icons](https://github.com/tabler/tabler-icons) `v3.50.0`, `6904efd245391ad396df17654738f52f6da8c40e` | `icons/outline/` | + +Carbon's licence file is the repository's root `LICENSE` (the icons package has none of its own). + +Every set folder's files come from the npm package of the version in the table (`@phosphor-icons/core` 2.0.8, `lucide-static` 1.63.0, `@carbon/icons` 11.91.0, `@tabler/icons` 3.50.0), the same releases as the tags above. Phosphor files are `regular` weight, except `star-filled.svg`, which is Phosphor's `fill` weight (`star-fill.svg`), and `panel-right.svg`, which is Phosphor's `sidebar-simple` mirrored. + +`phosphor/` also holds drawings made for the suite, for glyphs the pinned Phosphor release lacks. They follow Phosphor's regular style (256 view box, 16-unit round-capped strokes, some converted to filled outlines), take their shapes from PhotoCraft's glyphs, and carry the suite's own licence: + +- `bandage-sparkle`, `brush-replace`, `clip-below`, `clip-release`, `convert-point`, `direct-select`, `eraser-background`, `eraser-magic`, `font-similar` +- `distribute-*`, `symmetry-*`, `painting-symmetry` (the symmetry glyphs follow PhotoCraft's axis icons) +- `lasso`, `lasso-magnetic`, `lasso-select`, `layer-mask`, `lollipop`, `marquee-column`, `marquee-row`, `pen-add-anchor`, `pen-curvature`, `pen-delete-anchor`, `pen-freeform`, `quick-selection` (the pen nib and the quick-selection brush follow Lucide's `pen-tool` and `paintbrush`, ISC) +- `gradient-linear`, `gradient-radial`, `gradient-angle`, `gradient-reflected`, `gradient-diamond`, `fx` (the layer-style button) +- `stroke-align-*`, `stroke-cap-*`, `stroke-join-*`, `route-straight`, `route-elbow`, `route-curved` (the stroke editor's and connector bar's segments; the other packs have no matching glyph and draw these) +- `sync-lock`, `mark-in`, `mark-out`, `insert-clip`, `overwrite-clip`, `lift-clip`, `extract-clip` (the timeline's lock and edit glyphs, after Premiere Pro's), `keyframe-linear`, `keyframe-bezier`, `keyframe-auto-bezier`, `keyframe-hold`, `keyframe-ease-in`, `keyframe-ease-out` (keyframe nodes after After Effects' shapes: diamond, square for Bezier, circle for Auto Bezier) +- `key-linear`, `key-linear-filled`, `key-hold`, `key-bezier`, `key-auto-bezier`, `key-continuous-bezier`, `key-ease-in`, `key-ease-out`, `keyframe-easy-ease` (the timeline's single keyframe marks and the graph editor's Easy Ease button, after FilmCraft's diamond, square and circle and After Effects' keys; solid shapes except the outline diamond and the rings) +- `font-variable`, `scaling`, `slice-select`, `square-dashed-mouse-pointer`, `text-warp`, `triangle-right`, `type-mask`, `type-mask-vertical` diff --git a/crates/ui-contract/icons/carbon/LICENSE b/crates/ui-contract/icons/carbon/LICENSE new file mode 100644 index 000000000..78e09cfab --- /dev/null +++ b/crates/ui-contract/icons/carbon/LICENSE @@ -0,0 +1,201 @@ + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "{}" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright 2015 IBM Corp. + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. diff --git a/crates/ui-contract/icons/carbon/add--alt.svg b/crates/ui-contract/icons/carbon/add--alt.svg new file mode 100644 index 000000000..a608d98ea --- /dev/null +++ b/crates/ui-contract/icons/carbon/add--alt.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/add.svg b/crates/ui-contract/icons/carbon/add.svg new file mode 100644 index 000000000..05379194b --- /dev/null +++ b/crates/ui-contract/icons/carbon/add.svg @@ -0,0 +1,10 @@ + + + + + + + diff --git a/crates/ui-contract/icons/carbon/align--horizontal-center.svg b/crates/ui-contract/icons/carbon/align--horizontal-center.svg new file mode 100644 index 000000000..f7ba2598a --- /dev/null +++ b/crates/ui-contract/icons/carbon/align--horizontal-center.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/align--horizontal-left.svg b/crates/ui-contract/icons/carbon/align--horizontal-left.svg new file mode 100644 index 000000000..405f9137c --- /dev/null +++ b/crates/ui-contract/icons/carbon/align--horizontal-left.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/align--horizontal-right.svg b/crates/ui-contract/icons/carbon/align--horizontal-right.svg new file mode 100644 index 000000000..2424913ae --- /dev/null +++ b/crates/ui-contract/icons/carbon/align--horizontal-right.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/align--vertical-bottom.svg b/crates/ui-contract/icons/carbon/align--vertical-bottom.svg new file mode 100644 index 000000000..a0599724f --- /dev/null +++ b/crates/ui-contract/icons/carbon/align--vertical-bottom.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/align--vertical-center.svg b/crates/ui-contract/icons/carbon/align--vertical-center.svg new file mode 100644 index 000000000..d713fad3c --- /dev/null +++ b/crates/ui-contract/icons/carbon/align--vertical-center.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/align--vertical-top.svg b/crates/ui-contract/icons/carbon/align--vertical-top.svg new file mode 100644 index 000000000..8a07918ac --- /dev/null +++ b/crates/ui-contract/icons/carbon/align--vertical-top.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/application--web.svg b/crates/ui-contract/icons/carbon/application--web.svg new file mode 100644 index 000000000..aa573b030 --- /dev/null +++ b/crates/ui-contract/icons/carbon/application--web.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/arrow--left.svg b/crates/ui-contract/icons/carbon/arrow--left.svg new file mode 100644 index 000000000..b28953cd1 --- /dev/null +++ b/crates/ui-contract/icons/carbon/arrow--left.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/arrows--horizontal.svg b/crates/ui-contract/icons/carbon/arrows--horizontal.svg new file mode 100644 index 000000000..7c8137e2d --- /dev/null +++ b/crates/ui-contract/icons/carbon/arrows--horizontal.svg @@ -0,0 +1 @@ +arrows--horizontal \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/arrows--vertical.svg b/crates/ui-contract/icons/carbon/arrows--vertical.svg new file mode 100644 index 000000000..696b690bd --- /dev/null +++ b/crates/ui-contract/icons/carbon/arrows--vertical.svg @@ -0,0 +1,12 @@ + + + + +arrows--vertical + + + + diff --git a/crates/ui-contract/icons/carbon/bookmark.svg b/crates/ui-contract/icons/carbon/bookmark.svg new file mode 100644 index 000000000..bbf2e2398 --- /dev/null +++ b/crates/ui-contract/icons/carbon/bookmark.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/calendar.svg b/crates/ui-contract/icons/carbon/calendar.svg new file mode 100644 index 000000000..9cef06692 --- /dev/null +++ b/crates/ui-contract/icons/carbon/calendar.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/chart--line.svg b/crates/ui-contract/icons/carbon/chart--line.svg new file mode 100644 index 000000000..c0c423adf --- /dev/null +++ b/crates/ui-contract/icons/carbon/chart--line.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/chat.svg b/crates/ui-contract/icons/carbon/chat.svg new file mode 100644 index 000000000..7c7151676 --- /dev/null +++ b/crates/ui-contract/icons/carbon/chat.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/checkmark--outline.svg b/crates/ui-contract/icons/carbon/checkmark--outline.svg new file mode 100644 index 000000000..18cdcda60 --- /dev/null +++ b/crates/ui-contract/icons/carbon/checkmark--outline.svg @@ -0,0 +1,12 @@ + + + + + + + + diff --git a/crates/ui-contract/icons/carbon/checkmark.svg b/crates/ui-contract/icons/carbon/checkmark.svg new file mode 100644 index 000000000..a9dff47b8 --- /dev/null +++ b/crates/ui-contract/icons/carbon/checkmark.svg @@ -0,0 +1,11 @@ + + + + + + + diff --git a/crates/ui-contract/icons/carbon/chevron--down.svg b/crates/ui-contract/icons/carbon/chevron--down.svg new file mode 100644 index 000000000..ffe7566d6 --- /dev/null +++ b/crates/ui-contract/icons/carbon/chevron--down.svg @@ -0,0 +1,10 @@ + + + + + + + diff --git a/crates/ui-contract/icons/carbon/chevron--left.svg b/crates/ui-contract/icons/carbon/chevron--left.svg new file mode 100644 index 000000000..797cab18c --- /dev/null +++ b/crates/ui-contract/icons/carbon/chevron--left.svg @@ -0,0 +1,10 @@ + + + + + + + diff --git a/crates/ui-contract/icons/carbon/chevron--right.svg b/crates/ui-contract/icons/carbon/chevron--right.svg new file mode 100644 index 000000000..3706c88db --- /dev/null +++ b/crates/ui-contract/icons/carbon/chevron--right.svg @@ -0,0 +1,10 @@ + + + + + + + diff --git a/crates/ui-contract/icons/carbon/chevron--up.svg b/crates/ui-contract/icons/carbon/chevron--up.svg new file mode 100644 index 000000000..6cbc79897 --- /dev/null +++ b/crates/ui-contract/icons/carbon/chevron--up.svg @@ -0,0 +1,10 @@ + + + + + + + diff --git a/crates/ui-contract/icons/carbon/circle--outline.svg b/crates/ui-contract/icons/carbon/circle--outline.svg new file mode 100644 index 000000000..573bc634a --- /dev/null +++ b/crates/ui-contract/icons/carbon/circle--outline.svg @@ -0,0 +1,16 @@ + + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/circle-dash.svg b/crates/ui-contract/icons/carbon/circle-dash.svg new file mode 100644 index 000000000..a90083c94 --- /dev/null +++ b/crates/ui-contract/icons/carbon/circle-dash.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/clean.svg b/crates/ui-contract/icons/carbon/clean.svg new file mode 100644 index 000000000..b8c17976c --- /dev/null +++ b/crates/ui-contract/icons/carbon/clean.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/close--outline.svg b/crates/ui-contract/icons/carbon/close--outline.svg new file mode 100644 index 000000000..88be13364 --- /dev/null +++ b/crates/ui-contract/icons/carbon/close--outline.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/close.svg b/crates/ui-contract/icons/carbon/close.svg new file mode 100644 index 000000000..620fa14fa --- /dev/null +++ b/crates/ui-contract/icons/carbon/close.svg @@ -0,0 +1,14 @@ + + + + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/cloud.svg b/crates/ui-contract/icons/carbon/cloud.svg new file mode 100644 index 000000000..664e6f8dd --- /dev/null +++ b/crates/ui-contract/icons/carbon/cloud.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/color-palette.svg b/crates/ui-contract/icons/carbon/color-palette.svg new file mode 100644 index 000000000..793bd8156 --- /dev/null +++ b/crates/ui-contract/icons/carbon/color-palette.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/compass.svg b/crates/ui-contract/icons/carbon/compass.svg new file mode 100644 index 000000000..2e7a74bb0 --- /dev/null +++ b/crates/ui-contract/icons/carbon/compass.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/contrast.svg b/crates/ui-contract/icons/carbon/contrast.svg new file mode 100644 index 000000000..903b06596 --- /dev/null +++ b/crates/ui-contract/icons/carbon/contrast.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/copy.svg b/crates/ui-contract/icons/carbon/copy.svg new file mode 100644 index 000000000..c154b169a --- /dev/null +++ b/crates/ui-contract/icons/carbon/copy.svg @@ -0,0 +1 @@ +copy \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/crop.svg b/crates/ui-contract/icons/carbon/crop.svg new file mode 100644 index 000000000..001157c5b --- /dev/null +++ b/crates/ui-contract/icons/carbon/crop.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/cube.svg b/crates/ui-contract/icons/carbon/cube.svg new file mode 100644 index 000000000..87bf86fec --- /dev/null +++ b/crates/ui-contract/icons/carbon/cube.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/cursor--2.svg b/crates/ui-contract/icons/carbon/cursor--2.svg new file mode 100644 index 000000000..e22f5e7b4 --- /dev/null +++ b/crates/ui-contract/icons/carbon/cursor--2.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/curved-line--solid.svg b/crates/ui-contract/icons/carbon/curved-line--solid.svg new file mode 100644 index 000000000..4a1d8932e --- /dev/null +++ b/crates/ui-contract/icons/carbon/curved-line--solid.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/cut.svg b/crates/ui-contract/icons/carbon/cut.svg new file mode 100644 index 000000000..2be447dc1 --- /dev/null +++ b/crates/ui-contract/icons/carbon/cut.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/diamond--outline.svg b/crates/ui-contract/icons/carbon/diamond--outline.svg new file mode 100644 index 000000000..b8b0dc7fb --- /dev/null +++ b/crates/ui-contract/icons/carbon/diamond--outline.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/document--add.svg b/crates/ui-contract/icons/carbon/document--add.svg new file mode 100644 index 000000000..93497d079 --- /dev/null +++ b/crates/ui-contract/icons/carbon/document--add.svg @@ -0,0 +1,12 @@ + + + + + + + + diff --git a/crates/ui-contract/icons/carbon/document.svg b/crates/ui-contract/icons/carbon/document.svg new file mode 100644 index 000000000..185ece4d5 --- /dev/null +++ b/crates/ui-contract/icons/carbon/document.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/double-chevron--left.svg b/crates/ui-contract/icons/carbon/double-chevron--left.svg new file mode 100644 index 000000000..4d19bd482 --- /dev/null +++ b/crates/ui-contract/icons/carbon/double-chevron--left.svg @@ -0,0 +1,12 @@ + + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/double-chevron--right.svg b/crates/ui-contract/icons/carbon/double-chevron--right.svg new file mode 100644 index 000000000..205ad1fd1 --- /dev/null +++ b/crates/ui-contract/icons/carbon/double-chevron--right.svg @@ -0,0 +1,12 @@ + + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/earth.svg b/crates/ui-contract/icons/carbon/earth.svg new file mode 100644 index 000000000..65df2fc8f --- /dev/null +++ b/crates/ui-contract/icons/carbon/earth.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/edit.svg b/crates/ui-contract/icons/carbon/edit.svg new file mode 100644 index 000000000..cf496b6c2 --- /dev/null +++ b/crates/ui-contract/icons/carbon/edit.svg @@ -0,0 +1,13 @@ + + + + +edit + + + + diff --git a/crates/ui-contract/icons/carbon/email.svg b/crates/ui-contract/icons/carbon/email.svg new file mode 100644 index 000000000..7a22846e0 --- /dev/null +++ b/crates/ui-contract/icons/carbon/email.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/erase.svg b/crates/ui-contract/icons/carbon/erase.svg new file mode 100644 index 000000000..8ddc9bf57 --- /dev/null +++ b/crates/ui-contract/icons/carbon/erase.svg @@ -0,0 +1 @@ +erase \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/error--outline.svg b/crates/ui-contract/icons/carbon/error--outline.svg new file mode 100644 index 000000000..d7d25c65c --- /dev/null +++ b/crates/ui-contract/icons/carbon/error--outline.svg @@ -0,0 +1,12 @@ + + + + + + + + diff --git a/crates/ui-contract/icons/carbon/eyedropper.svg b/crates/ui-contract/icons/carbon/eyedropper.svg new file mode 100644 index 000000000..694490528 --- /dev/null +++ b/crates/ui-contract/icons/carbon/eyedropper.svg @@ -0,0 +1 @@ +eyedropper \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/filter.svg b/crates/ui-contract/icons/carbon/filter.svg new file mode 100644 index 000000000..ba85d34a9 --- /dev/null +++ b/crates/ui-contract/icons/carbon/filter.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/fire.svg b/crates/ui-contract/icons/carbon/fire.svg new file mode 100644 index 000000000..274847175 --- /dev/null +++ b/crates/ui-contract/icons/carbon/fire.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/flag.svg b/crates/ui-contract/icons/carbon/flag.svg new file mode 100644 index 000000000..8fdc9f255 --- /dev/null +++ b/crates/ui-contract/icons/carbon/flag.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/folder--add.svg b/crates/ui-contract/icons/carbon/folder--add.svg new file mode 100644 index 000000000..c5a66aa32 --- /dev/null +++ b/crates/ui-contract/icons/carbon/folder--add.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/folder--open.svg b/crates/ui-contract/icons/carbon/folder--open.svg new file mode 100644 index 000000000..79cbaca35 --- /dev/null +++ b/crates/ui-contract/icons/carbon/folder--open.svg @@ -0,0 +1,11 @@ + + + + + + + diff --git a/crates/ui-contract/icons/carbon/folder.svg b/crates/ui-contract/icons/carbon/folder.svg new file mode 100644 index 000000000..e48c8652b --- /dev/null +++ b/crates/ui-contract/icons/carbon/folder.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/gradient.svg b/crates/ui-contract/icons/carbon/gradient.svg new file mode 100644 index 000000000..5e8ecf6b2 --- /dev/null +++ b/crates/ui-contract/icons/carbon/gradient.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/grid.svg b/crates/ui-contract/icons/carbon/grid.svg new file mode 100644 index 000000000..292b3c5b3 --- /dev/null +++ b/crates/ui-contract/icons/carbon/grid.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/headphones.svg b/crates/ui-contract/icons/carbon/headphones.svg new file mode 100644 index 000000000..0a6fbc1f3 --- /dev/null +++ b/crates/ui-contract/icons/carbon/headphones.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/home.svg b/crates/ui-contract/icons/carbon/home.svg new file mode 100644 index 000000000..203eff8f0 --- /dev/null +++ b/crates/ui-contract/icons/carbon/home.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/image.svg b/crates/ui-contract/icons/carbon/image.svg new file mode 100644 index 000000000..a309b0a5c --- /dev/null +++ b/crates/ui-contract/icons/carbon/image.svg @@ -0,0 +1 @@ +image \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/information.svg b/crates/ui-contract/icons/carbon/information.svg new file mode 100644 index 000000000..b239698c9 --- /dev/null +++ b/crates/ui-contract/icons/carbon/information.svg @@ -0,0 +1,13 @@ + + + + + + + + + diff --git a/crates/ui-contract/icons/carbon/intersect.svg b/crates/ui-contract/icons/carbon/intersect.svg new file mode 100644 index 000000000..9eeb4cc31 --- /dev/null +++ b/crates/ui-contract/icons/carbon/intersect.svg @@ -0,0 +1,13 @@ + + + + + + + + + diff --git a/crates/ui-contract/icons/carbon/keyboard.svg b/crates/ui-contract/icons/carbon/keyboard.svg new file mode 100644 index 000000000..5d61e263f --- /dev/null +++ b/crates/ui-contract/icons/carbon/keyboard.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/lasso.svg b/crates/ui-contract/icons/carbon/lasso.svg new file mode 100644 index 000000000..abbf055cb --- /dev/null +++ b/crates/ui-contract/icons/carbon/lasso.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/launch.svg b/crates/ui-contract/icons/carbon/launch.svg new file mode 100644 index 000000000..3a51bfad6 --- /dev/null +++ b/crates/ui-contract/icons/carbon/launch.svg @@ -0,0 +1,12 @@ + + + + + + + + diff --git a/crates/ui-contract/icons/carbon/layers.svg b/crates/ui-contract/icons/carbon/layers.svg new file mode 100644 index 000000000..1a909fb4f --- /dev/null +++ b/crates/ui-contract/icons/carbon/layers.svg @@ -0,0 +1,13 @@ + + + + + + + + + diff --git a/crates/ui-contract/icons/carbon/link.svg b/crates/ui-contract/icons/carbon/link.svg new file mode 100644 index 000000000..1faf4ac8a --- /dev/null +++ b/crates/ui-contract/icons/carbon/link.svg @@ -0,0 +1 @@ +link \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/list--bulleted.svg b/crates/ui-contract/icons/carbon/list--bulleted.svg new file mode 100644 index 000000000..62648319c --- /dev/null +++ b/crates/ui-contract/icons/carbon/list--bulleted.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/location--current.svg b/crates/ui-contract/icons/carbon/location--current.svg new file mode 100644 index 000000000..3625b51a6 --- /dev/null +++ b/crates/ui-contract/icons/carbon/location--current.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/locked.svg b/crates/ui-contract/icons/carbon/locked.svg new file mode 100644 index 000000000..b89f9e28b --- /dev/null +++ b/crates/ui-contract/icons/carbon/locked.svg @@ -0,0 +1 @@ +locked \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/magic-wand.svg b/crates/ui-contract/icons/carbon/magic-wand.svg new file mode 100644 index 000000000..9c515976d --- /dev/null +++ b/crates/ui-contract/icons/carbon/magic-wand.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/maximize.svg b/crates/ui-contract/icons/carbon/maximize.svg new file mode 100644 index 000000000..20762a8ae --- /dev/null +++ b/crates/ui-contract/icons/carbon/maximize.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/menu.svg b/crates/ui-contract/icons/carbon/menu.svg new file mode 100644 index 000000000..a466a697c --- /dev/null +++ b/crates/ui-contract/icons/carbon/menu.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/meter.svg b/crates/ui-contract/icons/carbon/meter.svg new file mode 100644 index 000000000..61e9faa95 --- /dev/null +++ b/crates/ui-contract/icons/carbon/meter.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/misuse.svg b/crates/ui-contract/icons/carbon/misuse.svg new file mode 100644 index 000000000..81acf153f --- /dev/null +++ b/crates/ui-contract/icons/carbon/misuse.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/moon.svg b/crates/ui-contract/icons/carbon/moon.svg new file mode 100644 index 000000000..294d8c8ce --- /dev/null +++ b/crates/ui-contract/icons/carbon/moon.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/move.svg b/crates/ui-contract/icons/carbon/move.svg new file mode 100644 index 000000000..099c534a7 --- /dev/null +++ b/crates/ui-contract/icons/carbon/move.svg @@ -0,0 +1 @@ +move \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/open-panel--right.svg b/crates/ui-contract/icons/carbon/open-panel--right.svg new file mode 100644 index 000000000..eb6d59424 --- /dev/null +++ b/crates/ui-contract/icons/carbon/open-panel--right.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/overflow-menu--horizontal.svg b/crates/ui-contract/icons/carbon/overflow-menu--horizontal.svg new file mode 100644 index 000000000..1f7770897 --- /dev/null +++ b/crates/ui-contract/icons/carbon/overflow-menu--horizontal.svg @@ -0,0 +1,13 @@ + + + + +overflow-menu--horizontal + + + + + diff --git a/crates/ui-contract/icons/carbon/paint-brush.svg b/crates/ui-contract/icons/carbon/paint-brush.svg new file mode 100644 index 000000000..8f1957945 --- /dev/null +++ b/crates/ui-contract/icons/carbon/paint-brush.svg @@ -0,0 +1 @@ +paint-brush \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/pause.svg b/crates/ui-contract/icons/carbon/pause.svg new file mode 100644 index 000000000..b5df375f4 --- /dev/null +++ b/crates/ui-contract/icons/carbon/pause.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/pen--fountain.svg b/crates/ui-contract/icons/carbon/pen--fountain.svg new file mode 100644 index 000000000..3b6812ea3 --- /dev/null +++ b/crates/ui-contract/icons/carbon/pen--fountain.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/pentagon--outline.svg b/crates/ui-contract/icons/carbon/pentagon--outline.svg new file mode 100644 index 000000000..1d03f0eba --- /dev/null +++ b/crates/ui-contract/icons/carbon/pentagon--outline.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/play.svg b/crates/ui-contract/icons/carbon/play.svg new file mode 100644 index 000000000..6cb933dd1 --- /dev/null +++ b/crates/ui-contract/icons/carbon/play.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/radio-button--checked.svg b/crates/ui-contract/icons/carbon/radio-button--checked.svg new file mode 100644 index 000000000..6de952151 --- /dev/null +++ b/crates/ui-contract/icons/carbon/radio-button--checked.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/rain-drop.svg b/crates/ui-contract/icons/carbon/rain-drop.svg new file mode 100644 index 000000000..bb6925670 --- /dev/null +++ b/crates/ui-contract/icons/carbon/rain-drop.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/redo.svg b/crates/ui-contract/icons/carbon/redo.svg new file mode 100644 index 000000000..7db11dfa5 --- /dev/null +++ b/crates/ui-contract/icons/carbon/redo.svg @@ -0,0 +1,11 @@ + + + + + + + diff --git a/crates/ui-contract/icons/carbon/renew.svg b/crates/ui-contract/icons/carbon/renew.svg new file mode 100644 index 000000000..521195752 --- /dev/null +++ b/crates/ui-contract/icons/carbon/renew.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/rotate--clockwise.svg b/crates/ui-contract/icons/carbon/rotate--clockwise.svg new file mode 100644 index 000000000..dcc4ac925 --- /dev/null +++ b/crates/ui-contract/icons/carbon/rotate--clockwise.svg @@ -0,0 +1 @@ +rotate--clockwise \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/rotate--counterclockwise.svg b/crates/ui-contract/icons/carbon/rotate--counterclockwise.svg new file mode 100644 index 000000000..6ec9eacc2 --- /dev/null +++ b/crates/ui-contract/icons/carbon/rotate--counterclockwise.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/ruler.svg b/crates/ui-contract/icons/carbon/ruler.svg new file mode 100644 index 000000000..b90d3e005 --- /dev/null +++ b/crates/ui-contract/icons/carbon/ruler.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/save.svg b/crates/ui-contract/icons/carbon/save.svg new file mode 100644 index 000000000..5aa51cf41 --- /dev/null +++ b/crates/ui-contract/icons/carbon/save.svg @@ -0,0 +1 @@ +save \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/scan--alt.svg b/crates/ui-contract/icons/carbon/scan--alt.svg new file mode 100644 index 000000000..3ea257f0d --- /dev/null +++ b/crates/ui-contract/icons/carbon/scan--alt.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/scan.svg b/crates/ui-contract/icons/carbon/scan.svg new file mode 100644 index 000000000..e9494637a --- /dev/null +++ b/crates/ui-contract/icons/carbon/scan.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/screen.svg b/crates/ui-contract/icons/carbon/screen.svg new file mode 100644 index 000000000..37f48e66d --- /dev/null +++ b/crates/ui-contract/icons/carbon/screen.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/search.svg b/crates/ui-contract/icons/carbon/search.svg new file mode 100644 index 000000000..d3cf7aee2 --- /dev/null +++ b/crates/ui-contract/icons/carbon/search.svg @@ -0,0 +1,11 @@ + + + + + + + diff --git a/crates/ui-contract/icons/carbon/select--01.svg b/crates/ui-contract/icons/carbon/select--01.svg new file mode 100644 index 000000000..ed29dd9e6 --- /dev/null +++ b/crates/ui-contract/icons/carbon/select--01.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/settings--adjust.svg b/crates/ui-contract/icons/carbon/settings--adjust.svg new file mode 100644 index 000000000..b90d96be8 --- /dev/null +++ b/crates/ui-contract/icons/carbon/settings--adjust.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/settings.svg b/crates/ui-contract/icons/carbon/settings.svg new file mode 100644 index 000000000..600ce511a --- /dev/null +++ b/crates/ui-contract/icons/carbon/settings.svg @@ -0,0 +1 @@ +settings \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/skip--back.svg b/crates/ui-contract/icons/carbon/skip--back.svg new file mode 100644 index 000000000..b25fa4291 --- /dev/null +++ b/crates/ui-contract/icons/carbon/skip--back.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/skip--forward.svg b/crates/ui-contract/icons/carbon/skip--forward.svg new file mode 100644 index 000000000..e636860d0 --- /dev/null +++ b/crates/ui-contract/icons/carbon/skip--forward.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/sort--ascending.svg b/crates/ui-contract/icons/carbon/sort--ascending.svg new file mode 100644 index 000000000..cc487a36c --- /dev/null +++ b/crates/ui-contract/icons/carbon/sort--ascending.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/sort--descending.svg b/crates/ui-contract/icons/carbon/sort--descending.svg new file mode 100644 index 000000000..e30291e55 --- /dev/null +++ b/crates/ui-contract/icons/carbon/sort--descending.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/square--outline.svg b/crates/ui-contract/icons/carbon/square--outline.svg new file mode 100644 index 000000000..6c69683f1 --- /dev/null +++ b/crates/ui-contract/icons/carbon/square--outline.svg @@ -0,0 +1,16 @@ + + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/stamp.svg b/crates/ui-contract/icons/carbon/stamp.svg new file mode 100644 index 000000000..83d8f34cf --- /dev/null +++ b/crates/ui-contract/icons/carbon/stamp.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/star.svg b/crates/ui-contract/icons/carbon/star.svg new file mode 100644 index 000000000..1b5feae0c --- /dev/null +++ b/crates/ui-contract/icons/carbon/star.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/subtract.svg b/crates/ui-contract/icons/carbon/subtract.svg new file mode 100644 index 000000000..f967d102e --- /dev/null +++ b/crates/ui-contract/icons/carbon/subtract.svg @@ -0,0 +1,10 @@ + + + + + + + diff --git a/crates/ui-contract/icons/carbon/sun.svg b/crates/ui-contract/icons/carbon/sun.svg new file mode 100644 index 000000000..56669351d --- /dev/null +++ b/crates/ui-contract/icons/carbon/sun.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/target.svg b/crates/ui-contract/icons/carbon/target.svg new file mode 100644 index 000000000..d2be09455 --- /dev/null +++ b/crates/ui-contract/icons/carbon/target.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/template.svg b/crates/ui-contract/icons/carbon/template.svg new file mode 100644 index 000000000..1a9ce2dab --- /dev/null +++ b/crates/ui-contract/icons/carbon/template.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/text--align--center.svg b/crates/ui-contract/icons/carbon/text--align--center.svg new file mode 100644 index 000000000..8b19ead80 --- /dev/null +++ b/crates/ui-contract/icons/carbon/text--align--center.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/text--align--justify.svg b/crates/ui-contract/icons/carbon/text--align--justify.svg new file mode 100644 index 000000000..6182bf603 --- /dev/null +++ b/crates/ui-contract/icons/carbon/text--align--justify.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/text--align--left.svg b/crates/ui-contract/icons/carbon/text--align--left.svg new file mode 100644 index 000000000..742794e85 --- /dev/null +++ b/crates/ui-contract/icons/carbon/text--align--left.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/text--align--right.svg b/crates/ui-contract/icons/carbon/text--align--right.svg new file mode 100644 index 000000000..6d9d347ce --- /dev/null +++ b/crates/ui-contract/icons/carbon/text--align--right.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/text--font.svg b/crates/ui-contract/icons/carbon/text--font.svg new file mode 100644 index 000000000..16cc0a4c9 --- /dev/null +++ b/crates/ui-contract/icons/carbon/text--font.svg @@ -0,0 +1,12 @@ + + + + + + + + diff --git a/crates/ui-contract/icons/carbon/thumbs-down.svg b/crates/ui-contract/icons/carbon/thumbs-down.svg new file mode 100644 index 000000000..1ca79cfb4 --- /dev/null +++ b/crates/ui-contract/icons/carbon/thumbs-down.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/thumbs-up.svg b/crates/ui-contract/icons/carbon/thumbs-up.svg new file mode 100644 index 000000000..72e678225 --- /dev/null +++ b/crates/ui-contract/icons/carbon/thumbs-up.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/time.svg b/crates/ui-contract/icons/carbon/time.svg new file mode 100644 index 000000000..b1b898804 --- /dev/null +++ b/crates/ui-contract/icons/carbon/time.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/toggle-off.svg b/crates/ui-contract/icons/carbon/toggle-off.svg new file mode 100644 index 000000000..54ff5d3d8 --- /dev/null +++ b/crates/ui-contract/icons/carbon/toggle-off.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/toggle-on.svg b/crates/ui-contract/icons/carbon/toggle-on.svg new file mode 100644 index 000000000..cdf300c84 --- /dev/null +++ b/crates/ui-contract/icons/carbon/toggle-on.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/touch--1.svg b/crates/ui-contract/icons/carbon/touch--1.svg new file mode 100644 index 000000000..76cc1ca47 --- /dev/null +++ b/crates/ui-contract/icons/carbon/touch--1.svg @@ -0,0 +1 @@ +touch-1 \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/trash-can.svg b/crates/ui-contract/icons/carbon/trash-can.svg new file mode 100644 index 000000000..a26b22788 --- /dev/null +++ b/crates/ui-contract/icons/carbon/trash-can.svg @@ -0,0 +1 @@ +trash-can \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/triangle--outline.svg b/crates/ui-contract/icons/carbon/triangle--outline.svg new file mode 100644 index 000000000..32d0e1fc0 --- /dev/null +++ b/crates/ui-contract/icons/carbon/triangle--outline.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/undo.svg b/crates/ui-contract/icons/carbon/undo.svg new file mode 100644 index 000000000..bbe62bb60 --- /dev/null +++ b/crates/ui-contract/icons/carbon/undo.svg @@ -0,0 +1,11 @@ + + + + + + + diff --git a/crates/ui-contract/icons/carbon/unlink.svg b/crates/ui-contract/icons/carbon/unlink.svg new file mode 100644 index 000000000..e0eb6b6d2 --- /dev/null +++ b/crates/ui-contract/icons/carbon/unlink.svg @@ -0,0 +1 @@ +unlink \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/unlocked.svg b/crates/ui-contract/icons/carbon/unlocked.svg new file mode 100644 index 000000000..66a3659ef --- /dev/null +++ b/crates/ui-contract/icons/carbon/unlocked.svg @@ -0,0 +1 @@ +unlocked \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/view--matrix.svg b/crates/ui-contract/icons/carbon/view--matrix.svg new file mode 100644 index 000000000..495127040 --- /dev/null +++ b/crates/ui-contract/icons/carbon/view--matrix.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/view--off.svg b/crates/ui-contract/icons/carbon/view--off.svg new file mode 100644 index 000000000..ff325ca94 --- /dev/null +++ b/crates/ui-contract/icons/carbon/view--off.svg @@ -0,0 +1 @@ +view--off \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/view.svg b/crates/ui-contract/icons/carbon/view.svg new file mode 100644 index 000000000..07fee6d6d --- /dev/null +++ b/crates/ui-contract/icons/carbon/view.svg @@ -0,0 +1 @@ +view \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/volume--mute.svg b/crates/ui-contract/icons/carbon/volume--mute.svg new file mode 100644 index 000000000..06c112c35 --- /dev/null +++ b/crates/ui-contract/icons/carbon/volume--mute.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/warning--alt.svg b/crates/ui-contract/icons/carbon/warning--alt.svg new file mode 100644 index 000000000..1d3ca7ea9 --- /dev/null +++ b/crates/ui-contract/icons/carbon/warning--alt.svg @@ -0,0 +1,13 @@ + + + + + + + + + diff --git a/crates/ui-contract/icons/carbon/warning--diamond.svg b/crates/ui-contract/icons/carbon/warning--diamond.svg new file mode 100644 index 000000000..96c766a6d --- /dev/null +++ b/crates/ui-contract/icons/carbon/warning--diamond.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/carbon/zoom--in.svg b/crates/ui-contract/icons/carbon/zoom--in.svg new file mode 100644 index 000000000..b484d3398 --- /dev/null +++ b/crates/ui-contract/icons/carbon/zoom--in.svg @@ -0,0 +1,12 @@ + + + + + + + + diff --git a/crates/ui-contract/icons/icons.toml b/crates/ui-contract/icons/icons.toml new file mode 100644 index 000000000..8a220d970 --- /dev/null +++ b/crates/ui-contract/icons/icons.toml @@ -0,0 +1,1834 @@ +# The suite's icons by meaning, and each candidate set's file for them (without `.svg`). +# +# `build.rs` turns this into `craft_ui::icons::Icon` and `IconSet`. The `base` set (Phosphor) has a +# file for every name; a name without one fails the build. Every other set is a pack: it lists the +# names it has and may omit the rest, and `Icon::svg` returns the base set's file for an omitted +# name. A file a set folder holds but no icon lists fails the build. Sources and licences: +# ATTRIBUTION.md. +# +# `default`: the set `IconSet::default()` is; exactly one set has it. +# `directional`: mirrored in a right-to-left interface (arrows of reading order, undo, redo). +# `kind`: "stroke" sets get their stroke width rewritten to the suite's drawn width; "fill" sets +# render as drawn. `stroke_width` is the set's own width in view-box units. + +[[set]] +id = "lucide" +title = "Lucide" +licence = "ISC" +kind = "stroke" +stroke_width = 2.0 +default = true + +[[set]] +id = "phosphor" +title = "Phosphor (regular)" +licence = "MIT" +kind = "fill" +base = true + +[[set]] +id = "carbon" +title = "IBM Carbon" +licence = "Apache-2.0" +kind = "fill" + +[[set]] +id = "tabler" +title = "Tabler (outline)" +licence = "MIT" +kind = "stroke" +stroke_width = 2.0 + +[[icon]] +name = "close" +directional = false +lucide = "x" +phosphor = "x" +carbon = "close" +tabler = "x" + +[[icon]] +name = "chevron_down" +directional = false +lucide = "chevron-down" +phosphor = "caret-down" +carbon = "chevron--down" +tabler = "chevron-down" + +[[icon]] +name = "chevron_up" +directional = false +lucide = "chevron-up" +phosphor = "caret-up" +carbon = "chevron--up" +tabler = "chevron-up" + +[[icon]] +name = "chevron_left" +directional = true +lucide = "chevron-left" +phosphor = "caret-left" +carbon = "chevron--left" +tabler = "chevron-left" + +[[icon]] +name = "chevron_right" +directional = true +lucide = "chevron-right" +phosphor = "caret-right" +carbon = "chevron--right" +tabler = "chevron-right" + +[[icon]] +name = "chevrons_left" +directional = true +lucide = "chevrons-left" +phosphor = "caret-double-left" +carbon = "double-chevron--left" +tabler = "chevrons-left" + +[[icon]] +name = "chevrons_right" +directional = true +lucide = "chevrons-right" +phosphor = "caret-double-right" +carbon = "double-chevron--right" +tabler = "chevrons-right" + +[[icon]] +name = "more" +directional = false +lucide = "ellipsis" +phosphor = "dots-three" +carbon = "overflow-menu--horizontal" +tabler = "dots" + +[[icon]] +name = "menu" +directional = false +lucide = "menu" +phosphor = "list" +carbon = "menu" +tabler = "menu-2" + +[[icon]] +name = "plus" +directional = false +lucide = "plus" +phosphor = "plus" +carbon = "add" +tabler = "plus" + +[[icon]] +name = "minus" +directional = false +lucide = "minus" +phosphor = "minus" +carbon = "subtract" +tabler = "minus" + +[[icon]] +name = "check" +directional = false +lucide = "check" +phosphor = "check" +carbon = "checkmark" +tabler = "check" + +[[icon]] +name = "search" +directional = false +lucide = "search" +phosphor = "magnifying-glass" +carbon = "search" +tabler = "search" + +[[icon]] +name = "zoom_in" +directional = false +lucide = "zoom-in" +phosphor = "magnifying-glass-plus" +carbon = "zoom--in" +tabler = "zoom-in" + +[[icon]] +name = "settings" +directional = false +lucide = "settings" +phosphor = "gear" +carbon = "settings" +tabler = "settings" + +[[icon]] +name = "trash" +directional = false +lucide = "trash" +phosphor = "trash" +carbon = "trash-can" +tabler = "trash" + +[[icon]] +name = "copy" +directional = false +lucide = "copy" +phosphor = "copy" +carbon = "copy" +tabler = "copy" + +[[icon]] +name = "save" +directional = false +lucide = "save" +phosphor = "floppy-disk" +carbon = "save" +tabler = "device-floppy" + +[[icon]] +name = "folder_open" +directional = false +lucide = "folder-open" +phosphor = "folder-open" +carbon = "folder--open" +tabler = "folder-open" + +[[icon]] +name = "new_file" +directional = false +lucide = "file-plus" +phosphor = "file-plus" +carbon = "document--add" +tabler = "file-plus" + +[[icon]] +name = "undo" +directional = true +lucide = "undo-2" +phosphor = "arrow-u-up-left" +carbon = "undo" +tabler = "arrow-back-up" + +[[icon]] +name = "redo" +directional = true +lucide = "redo-2" +phosphor = "arrow-u-up-right" +carbon = "redo" +tabler = "arrow-forward-up" + +[[icon]] +name = "eye" +directional = false +lucide = "eye" +phosphor = "eye" +carbon = "view" +tabler = "eye" + +[[icon]] +name = "eye_off" +directional = false +lucide = "eye-off" +phosphor = "eye-slash" +carbon = "view--off" +tabler = "eye-off" + +[[icon]] +name = "lock" +directional = false +lucide = "lock" +phosphor = "lock" +carbon = "locked" +tabler = "lock" + +[[icon]] +name = "lock_open" +directional = false +lucide = "lock-open" +phosphor = "lock-open" +carbon = "unlocked" +tabler = "lock-open" + +[[icon]] +name = "layers" +directional = false +lucide = "layers" +phosphor = "stack" +carbon = "layers" +tabler = "stack-2" + +[[icon]] +name = "link" +directional = false +lucide = "link" +phosphor = "link" +carbon = "link" +tabler = "link" + +[[icon]] +name = "unlink" +directional = false +lucide = "unlink" +phosphor = "link-break" +carbon = "unlink" +tabler = "link-off" + +[[icon]] +name = "float" +directional = false +lucide = "external-link" +phosphor = "arrow-square-out" +carbon = "launch" +tabler = "external-link" + +[[icon]] +name = "open" +directional = false +lucide = "external-link" +phosphor = "arrow-square-out" +carbon = "launch" +tabler = "external-link" + +[[icon]] +name = "image" +directional = false +lucide = "image" +phosphor = "image" +carbon = "image" +tabler = "photo" + +[[icon]] +name = "text" +directional = false +lucide = "type" +phosphor = "text-t" +carbon = "text--font" +tabler = "typography" + +[[icon]] +name = "font_variable" +directional = false +phosphor = "font-variable" + +[[icon]] +name = "text_warp" +directional = false +phosphor = "text-warp" + +[[icon]] +name = "type_mask" +directional = false +phosphor = "type-mask" + +[[icon]] +name = "type_mask_vertical" +directional = false +phosphor = "type-mask-vertical" + +[[icon]] +name = "square" +directional = false +lucide = "square" +phosphor = "square" +carbon = "square--outline" +tabler = "square" + +[[icon]] +name = "circle" +directional = false +lucide = "circle" +phosphor = "circle" +carbon = "circle--outline" +tabler = "circle" + +[[icon]] +name = "move" +directional = false +lucide = "move" +phosphor = "arrows-out-cardinal" +carbon = "move" +tabler = "arrows-move" + +[[icon]] +name = "hand" +directional = false +lucide = "hand" +phosphor = "hand" +carbon = "touch--1" +tabler = "hand-stop" + +[[icon]] +name = "rotate_cw" +directional = false +lucide = "rotate-cw" +phosphor = "arrow-clockwise" +carbon = "rotate--clockwise" +tabler = "rotate-clockwise" + +[[icon]] +name = "brush" +directional = false +lucide = "brush" +phosphor = "paint-brush" +carbon = "paint-brush" +tabler = "brush" + +[[icon]] +name = "pencil" +directional = false +lucide = "pencil" +phosphor = "pencil-simple" +carbon = "edit" +tabler = "pencil" + +[[icon]] +name = "eraser" +directional = false +lucide = "eraser" +phosphor = "eraser" +carbon = "erase" +tabler = "eraser" + +[[icon]] +name = "eyedropper" +directional = false +lucide = "pipette" +phosphor = "eyedropper" +carbon = "eyedropper" +tabler = "color-picker" + +[[icon]] +name = "eyedropper_black" +directional = false +lucide = "eyedropper-black" +phosphor = "eyedropper-black" + +[[icon]] +name = "eyedropper_gray" +directional = false +lucide = "eyedropper-gray" +phosphor = "eyedropper-gray" + +[[icon]] +name = "eyedropper_white" +directional = false +lucide = "eyedropper-white" +phosphor = "eyedropper-white" + +[[icon]] +name = "info" +directional = false +lucide = "info" +phosphor = "info" +carbon = "information" +tabler = "info-circle" + +[[icon]] +name = "warning" +directional = false +lucide = "triangle-alert" +phosphor = "warning" +carbon = "warning--alt" +tabler = "alert-triangle" + +[[icon]] +name = "web_colors" +directional = false +lucide = "box" +phosphor = "cube" +carbon = "cube" +tabler = "cube" + +[[icon]] +name = "success" +directional = false +lucide = "circle-check" +phosphor = "check-circle" +carbon = "checkmark--outline" +tabler = "circle-check" + +[[icon]] +name = "error" +directional = false +lucide = "circle-alert" +phosphor = "warning-circle" +carbon = "error--outline" +tabler = "alert-circle" + +[[icon]] +name = "swap_colors" +directional = false +lucide = "arrow-left-right" +phosphor = "swap" +carbon = "arrows--horizontal" +tabler = "arrows-exchange" + +[[icon]] +name = "default_colors" +directional = false +lucide = "squares-subtract" +phosphor = "subtract-square" +carbon = "intersect" +tabler = "layers-subtract" + +[[icon]] +name = "adjustment_layer" +directional = false +lucide = "contrast" +phosphor = "circle-half" +carbon = "contrast" +tabler = "contrast-2" + +[[icon]] +name = "align_center" +directional = false +lucide = "align-center" +phosphor = "text-align-center" +carbon = "text--align--center" +tabler = "align-center" + +[[icon]] +name = "align_justify" +directional = false +lucide = "align-justify" +phosphor = "text-align-justify" +carbon = "text--align--justify" +tabler = "align-justified" + +[[icon]] +name = "align_left" +directional = false +lucide = "align-left" +phosphor = "text-align-left" +carbon = "text--align--left" +tabler = "align-left" + +[[icon]] +name = "align_right" +directional = false +lucide = "align-right" +phosphor = "text-align-right" +carbon = "text--align--right" +tabler = "align-right" + +[[icon]] +name = "align_edge_bottom" +directional = false +lucide = "align-end-horizontal" +phosphor = "align-bottom" +carbon = "align--vertical-bottom" +tabler = "layout-align-bottom" # near: one box instead of two + +[[icon]] +name = "align_edge_hcenter" +directional = false +lucide = "align-center-vertical" +phosphor = "align-center-horizontal" +carbon = "align--horizontal-center" +tabler = "layout-align-center" # near: one box instead of two + +[[icon]] +name = "align_edge_left" +directional = false +lucide = "align-start-vertical" +phosphor = "align-left" +carbon = "align--horizontal-left" +tabler = "layout-align-left" # near: one box instead of two + +[[icon]] +name = "align_edge_right" +directional = false +lucide = "align-end-vertical" +phosphor = "align-right" +carbon = "align--horizontal-right" +tabler = "layout-align-right" # near: one box instead of two + +[[icon]] +name = "align_edge_top" +directional = false +lucide = "align-start-horizontal" +phosphor = "align-top" +carbon = "align--vertical-top" +tabler = "layout-align-top" # near: one box instead of two + +[[icon]] +name = "align_edge_vcenter" +directional = false +lucide = "align-center-horizontal" +phosphor = "align-center-vertical" +carbon = "align--vertical-center" +tabler = "layout-align-middle" # near: one box instead of two + +[[icon]] +name = "app_window" +directional = false +lucide = "app-window" +phosphor = "app-window" +carbon = "application--web" # near: browser window with address bar +tabler = "app-window" + +[[icon]] +name = "swap_horizontal" +directional = false +lucide = "arrow-left-right" +phosphor = "arrows-left-right" +carbon = "arrows--horizontal" +tabler = "arrows-exchange" + +[[icon]] +name = "swap_vertical" +directional = false +lucide = "arrow-up-down" +phosphor = "arrows-down-up" +carbon = "arrows--vertical" +tabler = "arrows-down-up" + +[[icon]] +name = "ban" +directional = false +lucide = "ban" +phosphor = "prohibit" +carbon = "misuse" # near: circle with X, not slash +tabler = "ban" + +[[icon]] +name = "flag" +directional = false +lucide = "flag" +phosphor = "flag" +carbon = "flag" +tabler = "flag" + +[[icon]] +name = "refresh" +directional = false +lucide = "refresh-cw" +phosphor = "arrows-clockwise" +carbon = "renew" +tabler = "refresh" + +[[icon]] +name = "marquee_ellipse" +directional = false +lucide = "circle-dashed" +phosphor = "circle-dashed" +carbon = "circle-dash" +tabler = "circle-dashed" + +[[icon]] +name = "target" +directional = false +lucide = "circle-dot" +phosphor = "radio-button" +carbon = "radio-button--checked" +tabler = "circle-dot" + +[[icon]] +name = "clock" +directional = false +lucide = "clock" +phosphor = "clock" +carbon = "time" +tabler = "clock" + +[[icon]] +name = "cloud" +directional = false +lucide = "cloud" +phosphor = "cloud" +carbon = "cloud" +tabler = "cloud" + +[[icon]] +name = "compass" +directional = false +lucide = "compass" +phosphor = "compass" +carbon = "compass" +tabler = "compass" + +[[icon]] +name = "contrast" +directional = false +lucide = "contrast" +phosphor = "circle-half" +carbon = "contrast" +tabler = "contrast-2" + +[[icon]] +name = "crop" +directional = false +lucide = "crop" +phosphor = "crop" +carbon = "crop" +tabler = "crop" + +[[icon]] +name = "diamond" +directional = false +lucide = "diamond" +phosphor = "diamond" +carbon = "diamond--outline" +tabler = "diamond" + +[[icon]] +name = "distribute_bottom" +directional = false +phosphor = "distribute-bottom" + +[[icon]] +name = "distribute_hcenter" +directional = false +phosphor = "distribute-hcenter" + +[[icon]] +name = "distribute_horizontal" +directional = false +phosphor = "distribute-horizontal" + +[[icon]] +name = "distribute_left" +directional = false +phosphor = "distribute-left" + +[[icon]] +name = "distribute_right" +directional = false +phosphor = "distribute-right" + +[[icon]] +name = "distribute_top" +directional = false +phosphor = "distribute-top" + +[[icon]] +name = "distribute_vcenter" +directional = false +phosphor = "distribute-vcenter" + +[[icon]] +name = "distribute_vertical" +directional = false +phosphor = "distribute-vertical" + +[[icon]] +name = "droplet" +directional = false +lucide = "droplet" +phosphor = "drop" +carbon = "rain-drop" # near: drop with inner highlight +tabler = "droplet" + +[[icon]] +name = "ellipse_dashed" +directional = false +lucide = "circle-dashed" # near: dashed circle, not ellipse +phosphor = "circle-dashed" # near: dashed circle, not ellipse +carbon = "circle-dash" # near: dashed circle, not ellipse +tabler = "circle-dashed" # near: dashed circle, not ellipse + +[[icon]] +name = "rect_dashed" +directional = false +lucide = "square-dashed" +phosphor = "selection" +carbon = "select--01" # near: dashed square with crosshair +tabler = "square-dashed" + +[[icon]] +name = "file" +directional = false +lucide = "file" +phosphor = "file" +carbon = "document" +tabler = "file" + +[[icon]] +name = "flame" +directional = false +lucide = "flame" +phosphor = "flame" +carbon = "fire" +tabler = "flame" + +[[icon]] +name = "folder" +directional = false +lucide = "folder" +phosphor = "folder" +carbon = "folder" +tabler = "folder" + +[[icon]] +name = "new_folder" +directional = false +lucide = "folder-plus" +phosphor = "folder-plus" +carbon = "folder--add" +tabler = "folder-plus" + +[[icon]] +name = "gauge" +directional = false +lucide = "gauge" +phosphor = "gauge" +carbon = "meter" +tabler = "gauge" + +[[icon]] +name = "grid_small" +directional = false +lucide = "grid-2x2" +phosphor = "grid-four" +carbon = "grid" +tabler = "layout-grid" + +[[icon]] +name = "grid" +directional = false +lucide = "grid-3x3" +phosphor = "grid-nine" +carbon = "view--matrix" # near: nine cells inside brackets +tabler = "grid-3x3" + +[[icon]] +name = "home" +directional = false +lucide = "house" +phosphor = "house" +carbon = "home" +tabler = "home" + +[[icon]] +name = "maximize_2" +directional = false +lucide = "maximize-2" +phosphor = "arrows-out-simple" +carbon = "maximize" +tabler = "arrows-diagonal" + +[[icon]] +name = "scaling" +directional = false +phosphor = "scaling" + +[[icon]] +name = "note" +directional = false +lucide = "message-square" +phosphor = "chat" +carbon = "chat" +tabler = "message" + +[[icon]] +name = "monitor" +directional = false +lucide = "monitor" +phosphor = "monitor" +carbon = "screen" +tabler = "device-desktop" + +[[icon]] +name = "moon" +directional = false +lucide = "moon" +phosphor = "moon" +carbon = "moon" +tabler = "moon" + +[[icon]] +name = "mouse_pointer_2" +directional = false +lucide = "mouse-pointer-2" +phosphor = "cursor" +carbon = "cursor--2" +tabler = "pointer" + +[[icon]] +name = "navigation" +directional = false +lucide = "navigation" +phosphor = "navigation-arrow" +carbon = "location--current" # near: arrow in a circle +tabler = "navigation" + +[[icon]] +name = "painting_symmetry" +directional = false +phosphor = "painting-symmetry" + +[[icon]] +name = "palette" +directional = false +lucide = "palette" +phosphor = "palette" +carbon = "color-palette" +tabler = "palette" + +[[icon]] +name = "panels_top_left" +directional = false +lucide = "panels-top-left" +phosphor = "layout" # near: generic layout +carbon = "template" # near: generic layout +tabler = "layout-2" # near: generic layout + +[[icon]] +name = "pause" +directional = false +lucide = "pause" +phosphor = "pause" +carbon = "pause" +tabler = "player-pause" + +[[icon]] +name = "pen_tool" +directional = false +lucide = "pen-tool" +phosphor = "pen-nib" +carbon = "pen--fountain" +tabler = "vector-bezier-2" # near: bezier curve, no pen nib + +[[icon]] +name = "pentagon" +directional = false +lucide = "pentagon" +phosphor = "polygon" +carbon = "pentagon--outline" +tabler = "pentagon" + +[[icon]] +name = "play" +directional = false +lucide = "play" +phosphor = "play" +carbon = "play" +tabler = "player-play" + +[[icon]] +name = "pointer" +directional = false +lucide = "pointer" +phosphor = "hand-pointing" +carbon = "touch--1" +tabler = "hand-finger" + +[[icon]] +name = "ruler" +directional = false +lucide = "ruler" +phosphor = "ruler" +carbon = "ruler" +tabler = "ruler" + +[[icon]] +name = "sampler" +directional = false +lucide = "crosshair" +phosphor = "crosshair" +carbon = "target" # near: rings without ticks +tabler = "crosshair" + +[[icon]] +name = "scan" +directional = false +lucide = "scan" +phosphor = "scan" +carbon = "scan" +tabler = "scan" + +[[icon]] +name = "scan_line" +directional = false +lucide = "scan-line" +phosphor = "scan" # near: frame without line +carbon = "scan--alt" # near: frame without line +tabler = "line-scan" + +[[icon]] +name = "scissors" +directional = false +lucide = "scissors" +phosphor = "scissors" +carbon = "cut" +tabler = "scissors" + +[[icon]] +name = "slice_knife" +directional = false +lucide = "slice" +phosphor = "knife" # near: kitchen knife +carbon = "cut" # near: scissors, not blade +tabler = "slice" + +[[icon]] +name = "slice_select" +directional = false +phosphor = "slice-select" + +[[icon]] +name = "adjustments" +directional = false +lucide = "sliders-horizontal" +phosphor = "sliders-horizontal" +carbon = "settings--adjust" +tabler = "adjustments-horizontal" + +[[icon]] +name = "spline" +directional = false +lucide = "spline" +phosphor = "bezier-curve" +carbon = "curved-line--solid" # near: plain curve without nodes +tabler = "vector-spline" + +[[icon]] +name = "marquee_rect" +directional = false +lucide = "square-dashed" +phosphor = "selection" +carbon = "select--01" # near: dashed square with crosshair +tabler = "square-dashed" + +[[icon]] +name = "lasso" +directional = false +lucide = "lasso" +phosphor = "lasso" +carbon = "lasso" +tabler = "lasso" + +[[icon]] +name = "lasso_magnetic" +directional = false +phosphor = "lasso-magnetic" + +[[icon]] +name = "lasso_select" +directional = false +lucide = "lasso-select" +phosphor = "lasso-select" + +[[icon]] +name = "layer_mask" +directional = false +phosphor = "layer-mask" + +[[icon]] +name = "lollipop" +directional = false +lucide = "lollipop" +phosphor = "lollipop" +tabler = "lollipop" + +[[icon]] +name = "marquee_column" +directional = false +phosphor = "marquee-column" + +[[icon]] +name = "marquee_row" +directional = false +phosphor = "marquee-row" + +[[icon]] +name = "panel_right" +directional = false +lucide = "panel-right" +phosphor = "panel-right" +carbon = "open-panel--right" +tabler = "layout-sidebar-right" + +[[icon]] +name = "pen_add_anchor" +directional = false +phosphor = "pen-add-anchor" + +[[icon]] +name = "pen_curvature" +directional = false +phosphor = "pen-curvature" + +[[icon]] +name = "pen_delete_anchor" +directional = false +phosphor = "pen-delete-anchor" + +[[icon]] +name = "pen_freeform" +directional = false +phosphor = "pen-freeform" + +[[icon]] +name = "quick_selection" +directional = false +phosphor = "quick-selection" + +[[icon]] +name = "object_select" +directional = false +phosphor = "square-dashed-mouse-pointer" + +[[icon]] +name = "new_layer" +directional = false +lucide = "square-plus" +phosphor = "plus-square" +carbon = "add--alt" # near: plus in a circle, not square +tabler = "square-plus" + +[[icon]] +name = "squares_subtract" +directional = false +lucide = "squares-intersect" +phosphor = "intersect-square" +carbon = "intersect" +tabler = "layers-intersect" + +[[icon]] +name = "stamp" +directional = false +lucide = "stamp" +phosphor = "stamp" +carbon = "stamp" +tabler = "rubber-stamp" + +[[icon]] +name = "star" +directional = false +lucide = "star" +phosphor = "star" +carbon = "star" +tabler = "star" + +[[icon]] +name = "star_filled" +directional = false +phosphor = "star-filled" + +[[icon]] +name = "sun" +directional = false +lucide = "sun" +phosphor = "sun" +carbon = "sun" +tabler = "sun" + +[[icon]] +name = "swatch_book" +directional = false +lucide = "swatch-book" +phosphor = "swatches" +carbon = "color-palette" # near: palette, not swatch book +tabler = "color-swatch" + +[[icon]] +name = "symmetry_diagonal" +directional = false +phosphor = "symmetry-diagonal" + +[[icon]] +name = "symmetry_dual" +directional = false +phosphor = "symmetry-dual" + +[[icon]] +name = "symmetry_horizontal" +directional = false +phosphor = "symmetry-horizontal" + +[[icon]] +name = "symmetry_vertical" +directional = false +phosphor = "symmetry-vertical" + +[[icon]] +name = "toggle_left" +directional = true +lucide = "toggle-left" +phosphor = "toggle-left" +carbon = "toggle-off" +tabler = "toggle-left" + +[[icon]] +name = "toggle_right" +directional = true +lucide = "toggle-right" +phosphor = "toggle-right" +carbon = "toggle-on" +tabler = "toggle-right" + +[[icon]] +name = "triangle" +directional = false +lucide = "triangle" +phosphor = "triangle" +carbon = "triangle--outline" +tabler = "triangle" + +[[icon]] +name = "triangle_right" +directional = false +phosphor = "triangle-right" + +[[icon]] +name = "wand" +directional = false +lucide = "wand" +phosphor = "magic-wand" # near: with sparkles +carbon = "magic-wand" # near: with sparkles +tabler = "wand" + +[[icon]] +name = "wand_sparkles" +directional = false +lucide = "wand-sparkles" +phosphor = "magic-wand" +carbon = "magic-wand" +tabler = "wand" # near: wand without sparkles + +[[icon]] +name = "artboard" +directional = false +lucide = "frame" # near: frame with guide lines, no ticks +phosphor = "frame-corners" # near: corner brackets only +tabler = "artboard" + +[[icon]] +name = "bandage" +directional = false +lucide = "bandage" +phosphor = "bandaids" # near: two crossed plasters +tabler = "bandage" + +[[icon]] +name = "blend" +directional = false +lucide = "blend" +phosphor = "intersect" +tabler = "blend-mode" + +[[icon]] +name = "brush_cleaning" +directional = false +lucide = "brush-cleaning" +phosphor = "broom" # near: broom without brush +carbon = "clean" # near: broom without brush + +[[icon]] +name = "frame_placeholder" +directional = false +lucide = "square-x" # near: box with small X, not corner to corner +phosphor = "x-square" # near: box with small X, not corner to corner +tabler = "square-x" # near: box with small X, not corner to corner + +[[icon]] +name = "gradient" +directional = false +phosphor = "gradient" +carbon = "gradient" + +[[icon]] +name = "paint_bucket" +directional = false +lucide = "paint-bucket" +phosphor = "paint-bucket" +tabler = "bucket-droplet" + +[[icon]] +name = "perspective_crop" +directional = false +phosphor = "perspective" # near: trapezoid, no crop marks +tabler = "perspective" # near: trapezoid, no crop marks + +[[icon]] +name = "orientation_landscape" +directional = false +lucide = "rectangle-horizontal" +phosphor = "rectangle" +tabler = "rectangle" + +[[icon]] +name = "orientation_portrait" +directional = false +lucide = "rectangle-vertical" +phosphor = "rectangle" # near: rectangle turned 90 degrees +tabler = "rectangle-vertical" + +[[icon]] +name = "slash" +directional = false +lucide = "slash" +phosphor = "line-segment" # near: adds end nodes +tabler = "slash" + +[[icon]] +name = "sparkles" +directional = false +lucide = "sparkles" +phosphor = "sparkle" +tabler = "sparkles" + +[[icon]] +name = "text_cursor" +directional = false +lucide = "text-cursor" +phosphor = "cursor-text" +tabler = "cursor-text" + +[[icon]] +name = "bandage_sparkle" +directional = false +phosphor = "bandage-sparkle" # drawn in Phosphor's style: no match in any set + +[[icon]] +name = "brush_replace" +directional = false +phosphor = "brush-replace" # drawn in Phosphor's style: no match in any set + +[[icon]] +name = "clip_below" +directional = false +phosphor = "clip-below" # drawn in Phosphor's style: no match in any set + +[[icon]] +name = "clip_release" +directional = false +phosphor = "clip-release" # drawn in Phosphor's style: no match in any set + +[[icon]] +name = "convert_point" +directional = false +phosphor = "convert-point" # drawn in Phosphor's style: no match in any set + +[[icon]] +name = "direct_select" +directional = false +phosphor = "direct-select" # drawn in Phosphor's style: no match in any set + +[[icon]] +name = "eraser_background" +directional = false +phosphor = "eraser-background" # drawn in Phosphor's style: no match in any set + +[[icon]] +name = "eraser_magic" +directional = false +phosphor = "eraser-magic" # drawn in Phosphor's style: no match in any set + +[[icon]] +name = "font_similar" +directional = false +phosphor = "font-similar" # drawn in Phosphor's style: no match in any set + +[[icon]] +name = "layout_grid" +directional = false +lucide = "layout-grid" +phosphor = "squares-four" +carbon = "grid" # the 2 by 2 outline: the 3 by 3 apps glyph fills its square at 12 px +tabler = "layout-grid" + +[[icon]] +name = "list" +directional = false +lucide = "list" +phosphor = "list-bullets" +carbon = "list--bulleted" +tabler = "list" + +[[icon]] +name = "gradient_linear" +directional = false +phosphor = "gradient-linear" # drawn in Phosphor's style: no match in any set + +[[icon]] +name = "gradient_radial" +directional = false +phosphor = "gradient-radial" # drawn in Phosphor's style: no match in any set + +[[icon]] +name = "gradient_angle" +directional = false +phosphor = "gradient-angle" # drawn in Phosphor's style: no match in any set + +[[icon]] +name = "gradient_reflected" +directional = false +phosphor = "gradient-reflected" # drawn in Phosphor's style: no match in any set + +[[icon]] +name = "gradient_diamond" +directional = false +phosphor = "gradient-diamond" # drawn in Phosphor's style: no match in any set + +[[icon]] +name = "fx" +directional = false +phosphor = "fx" # drawn in Phosphor's style: no match in any set + +[[icon]] +name = "rectangle" +directional = false +lucide = "rectangle-horizontal" +phosphor = "rectangle" +tabler = "rectangle" + +[[icon]] +name = "text_bold" +directional = false +lucide = "bold" +phosphor = "text-b" +tabler = "bold" + +[[icon]] +name = "text_italic" +directional = false +lucide = "italic" +phosphor = "text-italic" +tabler = "italic" + +[[icon]] +name = "text_underline" +directional = false +lucide = "underline" +phosphor = "text-underline" +tabler = "underline" + +[[icon]] +name = "text_strikethrough" +directional = false +lucide = "strikethrough" +phosphor = "text-strikethrough" +tabler = "strikethrough" + +[[icon]] +name = "text_superscript" +directional = false +lucide = "superscript" +phosphor = "text-t" # near: no superscript in Phosphor +tabler = "superscript" + +[[icon]] +name = "text_subscript" +directional = false +lucide = "subscript" +phosphor = "text-t" # near: no subscript in Phosphor +tabler = "subscript" + +[[icon]] +name = "text_all_caps" +directional = false +lucide = "case-upper" +phosphor = "text-t" # near: no capitals mark in Phosphor +tabler = "letter-case-upper" + +[[icon]] +name = "text_small_caps" +directional = false +lucide = "case-sensitive" +phosphor = "text-t" # near: no capitals mark in Phosphor +tabler = "letter-case" + +[[icon]] +name = "ligature" +directional = false +lucide = "ligature" +phosphor = "text-t" # near: no ligature in Phosphor + +[[icon]] +name = "pilcrow" +directional = false +lucide = "pilcrow" +phosphor = "paragraph" +tabler = "pilcrow" + +[[icon]] +name = "pilcrow_left" +directional = false +lucide = "pilcrow-left" +phosphor = "paragraph" # near: no direction in Phosphor +tabler = "pilcrow-left" + +[[icon]] +name = "pilcrow_right" +directional = false +lucide = "pilcrow-right" +phosphor = "paragraph" # near: no direction in Phosphor +tabler = "pilcrow-right" + +[[icon]] +name = "calendar" +directional = false +lucide = "calendar" +phosphor = "calendar" +carbon = "calendar" +tabler = "calendar" + +[[icon]] +name = "funnel" +directional = false +lucide = "funnel" +phosphor = "funnel" +carbon = "filter" +tabler = "filter" + +[[icon]] +name = "chart_line" +directional = false +lucide = "chart-line" +phosphor = "chart-line" +carbon = "chart--line" +tabler = "chart-line" + +[[icon]] +name = "split" +directional = false +lucide = "split" +phosphor = "arrows-split" +tabler = "arrows-split" + +[[icon]] +name = "split_cross" +directional = false +lucide = "grid-2x2" +phosphor = "squares-four" + +[[icon]] +name = "split_vertical" +directional = false +lucide = "square-split-horizontal" +phosphor = "square-split-horizontal" + +[[icon]] +name = "split_horizontal" +directional = false +lucide = "square-split-vertical" +phosphor = "square-split-vertical" + +[[icon]] +name = "stroke_align_inside" +directional = false +phosphor = "stroke-align-inside" + +[[icon]] +name = "stroke_align_center" +directional = false +phosphor = "stroke-align-center" + +[[icon]] +name = "stroke_align_outside" +directional = false +phosphor = "stroke-align-outside" + +[[icon]] +name = "stroke_cap_butt" +directional = false +phosphor = "stroke-cap-butt" + +[[icon]] +name = "stroke_cap_round" +directional = false +phosphor = "stroke-cap-round" + +[[icon]] +name = "stroke_cap_square" +directional = false +phosphor = "stroke-cap-square" + +[[icon]] +name = "stroke_join_miter" +directional = false +phosphor = "stroke-join-miter" + +[[icon]] +name = "stroke_join_round" +directional = false +phosphor = "stroke-join-round" + +[[icon]] +name = "stroke_join_bevel" +directional = false +phosphor = "stroke-join-bevel" + +[[icon]] +name = "route_straight" +directional = false +phosphor = "route-straight" + +[[icon]] +name = "route_elbow" +directional = false +phosphor = "route-elbow" + +[[icon]] +name = "route_curved" +directional = false +phosphor = "route-curved" + +[[icon]] +name = "square_plus" +directional = false +lucide = "square-plus" +phosphor = "plus-square" +carbon = "add--alt" # near: plus in a circle, not square +tabler = "square-plus" + +[[icon]] +name = "undo_2" +directional = true +lucide = "undo-2" +phosphor = "arrow-bend-up-left" +carbon = "undo" +tabler = "arrow-back-up" + +# Fixed on screen: the canvas does not mirror in right-to-left, so these must not either +# (Liquify's Twirl Counterclockwise and Push Left). +[[icon]] +name = "rotate_ccw" +directional = false +lucide = "rotate-ccw" +phosphor = "arrow-counter-clockwise" +carbon = "rotate--counterclockwise" +tabler = "rotate" + +[[icon]] +name = "arrow_left_fixed" +directional = false +lucide = "arrow-left" +phosphor = "arrow-left" +carbon = "arrow--left" +tabler = "arrow-left" + +[[icon]] +name = "track_mute" +directional = false +lucide = "volume-off" +phosphor = "speaker-simple-slash" +carbon = "volume--mute" +tabler = "volume-off" + +[[icon]] +name = "solo" +directional = false +lucide = "headphones" +phosphor = "headphones" +carbon = "headphones" +tabler = "headphones" + +[[icon]] +name = "sync_lock" +directional = false +phosphor = "sync-lock" + +[[icon]] +name = "snap" +directional = false +lucide = "magnet" +phosphor = "magnet" +tabler = "magnet" + +[[icon]] +name = "linked_selection" +directional = false +lucide = "link-2" +phosphor = "link-simple-horizontal" +carbon = "link" +tabler = "link" + +[[icon]] +name = "mark_in" +directional = false +phosphor = "mark-in" + +[[icon]] +name = "mark_out" +directional = false +phosphor = "mark-out" + +[[icon]] +name = "step_back" +directional = false +lucide = "step-back" +phosphor = "skip-back" +carbon = "skip--back" +tabler = "player-skip-back" + +[[icon]] +name = "step_forward" +directional = false +lucide = "step-forward" +phosphor = "skip-forward" +carbon = "skip--forward" +tabler = "player-skip-forward" + +[[icon]] +name = "insert_clip" +directional = false +phosphor = "insert-clip" + +[[icon]] +name = "overwrite_clip" +directional = false +phosphor = "overwrite-clip" + +[[icon]] +name = "lift_clip" +directional = false +phosphor = "lift-clip" + +[[icon]] +name = "extract_clip" +directional = false +phosphor = "extract-clip" + +[[icon]] +name = "keyframe_linear" +directional = false +phosphor = "keyframe-linear" + +[[icon]] +name = "keyframe_bezier" +directional = false +phosphor = "keyframe-bezier" + +[[icon]] +name = "keyframe_auto_bezier" +directional = false +phosphor = "keyframe-auto-bezier" + +[[icon]] +name = "keyframe_hold" +directional = false +phosphor = "keyframe-hold" + +[[icon]] +name = "keyframe_ease_in" +directional = false +phosphor = "keyframe-ease-in" + +[[icon]] +name = "keyframe_ease_out" +directional = false +phosphor = "keyframe-ease-out" + +[[icon]] +name = "thumbs_up" +directional = false +lucide = "thumbs-up" +phosphor = "thumbs-up" +carbon = "thumbs-up" +tabler = "thumb-up" + +[[icon]] +name = "thumbs_down" +directional = false +lucide = "thumbs-down" +phosphor = "thumbs-down" +carbon = "thumbs-down" +tabler = "thumb-down" + +[[icon]] +name = "x_circle" +directional = false +lucide = "circle-x" +phosphor = "x-circle" +carbon = "close--outline" +tabler = "circle-x" + +[[icon]] +name = "warning_diamond" +directional = false +phosphor = "warning-diamond" +carbon = "warning--diamond" + +[[icon]] +name = "sort_ascending" +directional = false +lucide = "arrow-up-narrow-wide" +phosphor = "sort-ascending" +carbon = "sort--ascending" +tabler = "sort-ascending" + +[[icon]] +name = "sort_descending" +directional = false +lucide = "arrow-down-wide-narrow" +phosphor = "sort-descending" +carbon = "sort--descending" +tabler = "sort-descending" + +[[icon]] +name = "globe" +directional = false +lucide = "globe" +phosphor = "globe" +carbon = "earth" +tabler = "world" + +[[icon]] +name = "bookmark" +directional = false +lucide = "bookmark" +phosphor = "bookmark-simple" +carbon = "bookmark" +tabler = "bookmark" + +[[icon]] +name = "mail" +directional = false +lucide = "mail" +phosphor = "envelope-simple" +carbon = "email" +tabler = "mail" + +[[icon]] +name = "key_linear" +directional = false +phosphor = "key-linear" + +[[icon]] +name = "key_linear_filled" +directional = false +phosphor = "key-linear-filled" + +[[icon]] +name = "key_hold" +directional = false +phosphor = "key-hold" + +[[icon]] +name = "key_bezier" +directional = false +phosphor = "key-bezier" + +[[icon]] +name = "key_auto_bezier" +directional = false +phosphor = "key-auto-bezier" + +[[icon]] +name = "key_continuous_bezier" +directional = false +phosphor = "key-continuous-bezier" + +[[icon]] +name = "key_ease_in" +directional = false +phosphor = "key-ease-in" + +[[icon]] +name = "key_ease_out" +directional = false +phosphor = "key-ease-out" + +[[icon]] +name = "keyframe_easy_ease" +directional = false +phosphor = "keyframe-easy-ease" + +[[icon]] +name = "keyboard" +directional = false +lucide = "keyboard" +phosphor = "keyboard" +carbon = "keyboard" +tabler = "keyboard" diff --git a/crates/ui-contract/icons/lucide/LICENSE b/crates/ui-contract/icons/lucide/LICENSE new file mode 100644 index 000000000..718bb3f0e --- /dev/null +++ b/crates/ui-contract/icons/lucide/LICENSE @@ -0,0 +1,43 @@ +ISC License + +Copyright (c) 2026 Lucide Icons and Contributors + +Permission to use, copy, modify, and/or distribute this software for any +purpose with or without fee is hereby granted, provided that the above +copyright notice and this permission notice appear in all copies. + +THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + +--- + +The following Lucide icons are derived from the Feather project: + +airplay, alert-circle, alert-octagon, alert-triangle, aperture, arrow-down-circle, arrow-down-left, arrow-down-right, arrow-down, arrow-left-circle, arrow-left, arrow-right-circle, arrow-right, arrow-up-circle, arrow-up-left, arrow-up-right, arrow-up, at-sign, calendar, cast, check, chevron-down, chevron-left, chevron-right, chevron-up, chevrons-down, chevrons-left, chevrons-right, chevrons-up, circle, clipboard, clock, code, columns, command, compass, corner-down-left, corner-down-right, corner-left-down, corner-left-up, corner-right-down, corner-right-up, corner-up-left, corner-up-right, crosshair, database, divide-circle, divide-square, dollar-sign, download, external-link, feather, frown, hash, headphones, help-circle, info, italic, key, layout, life-buoy, link-2, link, loader, lock, log-in, log-out, maximize, meh, minimize, minimize-2, minus-circle, minus-square, minus, monitor, moon, more-horizontal, more-vertical, move, music, navigation-2, navigation, octagon, pause-circle, percent, plus-circle, plus-square, plus, power, radio, rss, search, server, share, shopping-bag, sidebar, smartphone, smile, square, table-2, tablet, target, terminal, trash-2, trash, triangle, tv, type, upload, x-circle, x-octagon, x-square, x, zoom-in, zoom-out + +The MIT License (MIT) (for the icons listed above) + +Copyright (c) 2013-present Cole Bemis + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/crates/ui-contract/icons/lucide/align-center-horizontal.svg b/crates/ui-contract/icons/lucide/align-center-horizontal.svg new file mode 100644 index 000000000..acec5c35f --- /dev/null +++ b/crates/ui-contract/icons/lucide/align-center-horizontal.svg @@ -0,0 +1,19 @@ + + + + + + + + diff --git a/crates/ui-contract/icons/lucide/align-center-vertical.svg b/crates/ui-contract/icons/lucide/align-center-vertical.svg new file mode 100644 index 000000000..d7b155f58 --- /dev/null +++ b/crates/ui-contract/icons/lucide/align-center-vertical.svg @@ -0,0 +1,19 @@ + + + + + + + + diff --git a/crates/ui-contract/icons/lucide/align-center.svg b/crates/ui-contract/icons/lucide/align-center.svg new file mode 100644 index 000000000..b82f7f88e --- /dev/null +++ b/crates/ui-contract/icons/lucide/align-center.svg @@ -0,0 +1,17 @@ + + + + + + diff --git a/crates/ui-contract/icons/lucide/align-end-horizontal.svg b/crates/ui-contract/icons/lucide/align-end-horizontal.svg new file mode 100644 index 000000000..7a8647fe6 --- /dev/null +++ b/crates/ui-contract/icons/lucide/align-end-horizontal.svg @@ -0,0 +1,17 @@ + + + + + + diff --git a/crates/ui-contract/icons/lucide/align-end-vertical.svg b/crates/ui-contract/icons/lucide/align-end-vertical.svg new file mode 100644 index 000000000..621d994f6 --- /dev/null +++ b/crates/ui-contract/icons/lucide/align-end-vertical.svg @@ -0,0 +1,17 @@ + + + + + + diff --git a/crates/ui-contract/icons/lucide/align-justify.svg b/crates/ui-contract/icons/lucide/align-justify.svg new file mode 100644 index 000000000..052c61c45 --- /dev/null +++ b/crates/ui-contract/icons/lucide/align-justify.svg @@ -0,0 +1,17 @@ + + + + + + diff --git a/crates/ui-contract/icons/lucide/align-left.svg b/crates/ui-contract/icons/lucide/align-left.svg new file mode 100644 index 000000000..91dc2e639 --- /dev/null +++ b/crates/ui-contract/icons/lucide/align-left.svg @@ -0,0 +1,17 @@ + + + + + + diff --git a/crates/ui-contract/icons/lucide/align-right.svg b/crates/ui-contract/icons/lucide/align-right.svg new file mode 100644 index 000000000..9b0196fa6 --- /dev/null +++ b/crates/ui-contract/icons/lucide/align-right.svg @@ -0,0 +1,17 @@ + + + + + + diff --git a/crates/ui-contract/icons/lucide/align-start-horizontal.svg b/crates/ui-contract/icons/lucide/align-start-horizontal.svg new file mode 100644 index 000000000..fa3aed2ad --- /dev/null +++ b/crates/ui-contract/icons/lucide/align-start-horizontal.svg @@ -0,0 +1,17 @@ + + + + + + diff --git a/crates/ui-contract/icons/lucide/align-start-vertical.svg b/crates/ui-contract/icons/lucide/align-start-vertical.svg new file mode 100644 index 000000000..af863842d --- /dev/null +++ b/crates/ui-contract/icons/lucide/align-start-vertical.svg @@ -0,0 +1,17 @@ + + + + + + diff --git a/crates/ui-contract/icons/lucide/app-window.svg b/crates/ui-contract/icons/lucide/app-window.svg new file mode 100644 index 000000000..569104d27 --- /dev/null +++ b/crates/ui-contract/icons/lucide/app-window.svg @@ -0,0 +1,18 @@ + + + + + + + diff --git a/crates/ui-contract/icons/lucide/arrow-down-wide-narrow.svg b/crates/ui-contract/icons/lucide/arrow-down-wide-narrow.svg new file mode 100644 index 000000000..dbd60ba2c --- /dev/null +++ b/crates/ui-contract/icons/lucide/arrow-down-wide-narrow.svg @@ -0,0 +1,19 @@ + + + + + + + + diff --git a/crates/ui-contract/icons/lucide/arrow-left-right.svg b/crates/ui-contract/icons/lucide/arrow-left-right.svg new file mode 100644 index 000000000..acf2cb39a --- /dev/null +++ b/crates/ui-contract/icons/lucide/arrow-left-right.svg @@ -0,0 +1,16 @@ + + + + + + diff --git a/crates/ui-contract/icons/lucide/arrow-left.svg b/crates/ui-contract/icons/lucide/arrow-left.svg new file mode 100644 index 000000000..4d2135976 --- /dev/null +++ b/crates/ui-contract/icons/lucide/arrow-left.svg @@ -0,0 +1,16 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/arrow-up-down.svg b/crates/ui-contract/icons/lucide/arrow-up-down.svg new file mode 100644 index 000000000..c8d7f2fe0 --- /dev/null +++ b/crates/ui-contract/icons/lucide/arrow-up-down.svg @@ -0,0 +1,16 @@ + + + + + + diff --git a/crates/ui-contract/icons/lucide/arrow-up-narrow-wide.svg b/crates/ui-contract/icons/lucide/arrow-up-narrow-wide.svg new file mode 100644 index 000000000..8e903aecb --- /dev/null +++ b/crates/ui-contract/icons/lucide/arrow-up-narrow-wide.svg @@ -0,0 +1,19 @@ + + + + + + + + diff --git a/crates/ui-contract/icons/lucide/ban.svg b/crates/ui-contract/icons/lucide/ban.svg new file mode 100644 index 000000000..e22eaa2f7 --- /dev/null +++ b/crates/ui-contract/icons/lucide/ban.svg @@ -0,0 +1,16 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/bandage.svg b/crates/ui-contract/icons/lucide/bandage.svg new file mode 100644 index 000000000..e043dec1e --- /dev/null +++ b/crates/ui-contract/icons/lucide/bandage.svg @@ -0,0 +1,21 @@ + + + + + + + + + + diff --git a/crates/ui-contract/icons/lucide/blend.svg b/crates/ui-contract/icons/lucide/blend.svg new file mode 100644 index 000000000..018fc4a0c --- /dev/null +++ b/crates/ui-contract/icons/lucide/blend.svg @@ -0,0 +1,16 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/bold.svg b/crates/ui-contract/icons/lucide/bold.svg new file mode 100644 index 000000000..1e51bba6f --- /dev/null +++ b/crates/ui-contract/icons/lucide/bold.svg @@ -0,0 +1,13 @@ + + + diff --git a/crates/ui-contract/icons/lucide/bookmark.svg b/crates/ui-contract/icons/lucide/bookmark.svg new file mode 100644 index 000000000..d5f846d4d --- /dev/null +++ b/crates/ui-contract/icons/lucide/bookmark.svg @@ -0,0 +1,15 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/box.svg b/crates/ui-contract/icons/lucide/box.svg new file mode 100644 index 000000000..218c722b4 --- /dev/null +++ b/crates/ui-contract/icons/lucide/box.svg @@ -0,0 +1,17 @@ + + + + + + diff --git a/crates/ui-contract/icons/lucide/brush-cleaning.svg b/crates/ui-contract/icons/lucide/brush-cleaning.svg new file mode 100644 index 000000000..91437f2a4 --- /dev/null +++ b/crates/ui-contract/icons/lucide/brush-cleaning.svg @@ -0,0 +1,18 @@ + + + + + + + diff --git a/crates/ui-contract/icons/lucide/brush.svg b/crates/ui-contract/icons/lucide/brush.svg new file mode 100644 index 000000000..772cc2898 --- /dev/null +++ b/crates/ui-contract/icons/lucide/brush.svg @@ -0,0 +1,15 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/calendar.svg b/crates/ui-contract/icons/lucide/calendar.svg new file mode 100644 index 000000000..7a5ae8ec9 --- /dev/null +++ b/crates/ui-contract/icons/lucide/calendar.svg @@ -0,0 +1,18 @@ + + + + + + + diff --git a/crates/ui-contract/icons/lucide/case-sensitive.svg b/crates/ui-contract/icons/lucide/case-sensitive.svg new file mode 100644 index 000000000..522701800 --- /dev/null +++ b/crates/ui-contract/icons/lucide/case-sensitive.svg @@ -0,0 +1,16 @@ + + + + + + diff --git a/crates/ui-contract/icons/lucide/case-upper.svg b/crates/ui-contract/icons/lucide/case-upper.svg new file mode 100644 index 000000000..0d2c9585a --- /dev/null +++ b/crates/ui-contract/icons/lucide/case-upper.svg @@ -0,0 +1,15 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/chart-line.svg b/crates/ui-contract/icons/lucide/chart-line.svg new file mode 100644 index 000000000..25e6914c6 --- /dev/null +++ b/crates/ui-contract/icons/lucide/chart-line.svg @@ -0,0 +1,16 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/check.svg b/crates/ui-contract/icons/lucide/check.svg new file mode 100644 index 000000000..5abe15274 --- /dev/null +++ b/crates/ui-contract/icons/lucide/check.svg @@ -0,0 +1,13 @@ + + + diff --git a/crates/ui-contract/icons/lucide/chevron-down.svg b/crates/ui-contract/icons/lucide/chevron-down.svg new file mode 100644 index 000000000..e70d30b88 --- /dev/null +++ b/crates/ui-contract/icons/lucide/chevron-down.svg @@ -0,0 +1,13 @@ + + + diff --git a/crates/ui-contract/icons/lucide/chevron-left.svg b/crates/ui-contract/icons/lucide/chevron-left.svg new file mode 100644 index 000000000..056d5abc0 --- /dev/null +++ b/crates/ui-contract/icons/lucide/chevron-left.svg @@ -0,0 +1,13 @@ + + + diff --git a/crates/ui-contract/icons/lucide/chevron-right.svg b/crates/ui-contract/icons/lucide/chevron-right.svg new file mode 100644 index 000000000..db62a0c20 --- /dev/null +++ b/crates/ui-contract/icons/lucide/chevron-right.svg @@ -0,0 +1,13 @@ + + + diff --git a/crates/ui-contract/icons/lucide/chevron-up.svg b/crates/ui-contract/icons/lucide/chevron-up.svg new file mode 100644 index 000000000..b011f7721 --- /dev/null +++ b/crates/ui-contract/icons/lucide/chevron-up.svg @@ -0,0 +1,13 @@ + + + diff --git a/crates/ui-contract/icons/lucide/chevrons-left.svg b/crates/ui-contract/icons/lucide/chevrons-left.svg new file mode 100644 index 000000000..94b37487c --- /dev/null +++ b/crates/ui-contract/icons/lucide/chevrons-left.svg @@ -0,0 +1,14 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/chevrons-right.svg b/crates/ui-contract/icons/lucide/chevrons-right.svg new file mode 100644 index 000000000..0d2d8ec9c --- /dev/null +++ b/crates/ui-contract/icons/lucide/chevrons-right.svg @@ -0,0 +1,14 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/circle-alert.svg b/crates/ui-contract/icons/lucide/circle-alert.svg new file mode 100644 index 000000000..578d25c02 --- /dev/null +++ b/crates/ui-contract/icons/lucide/circle-alert.svg @@ -0,0 +1,15 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/circle-check.svg b/crates/ui-contract/icons/lucide/circle-check.svg new file mode 100644 index 000000000..14e45c58c --- /dev/null +++ b/crates/ui-contract/icons/lucide/circle-check.svg @@ -0,0 +1,14 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/circle-dashed.svg b/crates/ui-contract/icons/lucide/circle-dashed.svg new file mode 100644 index 000000000..bee58bf32 --- /dev/null +++ b/crates/ui-contract/icons/lucide/circle-dashed.svg @@ -0,0 +1,22 @@ + + + + + + + + + + + diff --git a/crates/ui-contract/icons/lucide/circle-dot.svg b/crates/ui-contract/icons/lucide/circle-dot.svg new file mode 100644 index 000000000..4f99f8f74 --- /dev/null +++ b/crates/ui-contract/icons/lucide/circle-dot.svg @@ -0,0 +1,16 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/circle-x.svg b/crates/ui-contract/icons/lucide/circle-x.svg new file mode 100644 index 000000000..46681b993 --- /dev/null +++ b/crates/ui-contract/icons/lucide/circle-x.svg @@ -0,0 +1,17 @@ + + + + + + diff --git a/crates/ui-contract/icons/lucide/circle.svg b/crates/ui-contract/icons/lucide/circle.svg new file mode 100644 index 000000000..1717bb4ba --- /dev/null +++ b/crates/ui-contract/icons/lucide/circle.svg @@ -0,0 +1,13 @@ + + + diff --git a/crates/ui-contract/icons/lucide/clock.svg b/crates/ui-contract/icons/lucide/clock.svg new file mode 100644 index 000000000..cd2e84e98 --- /dev/null +++ b/crates/ui-contract/icons/lucide/clock.svg @@ -0,0 +1,16 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/cloud.svg b/crates/ui-contract/icons/lucide/cloud.svg new file mode 100644 index 000000000..0d8e86715 --- /dev/null +++ b/crates/ui-contract/icons/lucide/cloud.svg @@ -0,0 +1,15 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/compass.svg b/crates/ui-contract/icons/lucide/compass.svg new file mode 100644 index 000000000..ab58f72f4 --- /dev/null +++ b/crates/ui-contract/icons/lucide/compass.svg @@ -0,0 +1,16 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/contrast.svg b/crates/ui-contract/icons/lucide/contrast.svg new file mode 100644 index 000000000..267451e1c --- /dev/null +++ b/crates/ui-contract/icons/lucide/contrast.svg @@ -0,0 +1,16 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/copy.svg b/crates/ui-contract/icons/lucide/copy.svg new file mode 100644 index 000000000..f62ce99c1 --- /dev/null +++ b/crates/ui-contract/icons/lucide/copy.svg @@ -0,0 +1,14 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/crop.svg b/crates/ui-contract/icons/lucide/crop.svg new file mode 100644 index 000000000..7409b81ed --- /dev/null +++ b/crates/ui-contract/icons/lucide/crop.svg @@ -0,0 +1,16 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/crosshair.svg b/crates/ui-contract/icons/lucide/crosshair.svg new file mode 100644 index 000000000..76b05f357 --- /dev/null +++ b/crates/ui-contract/icons/lucide/crosshair.svg @@ -0,0 +1,19 @@ + + + + + + + + diff --git a/crates/ui-contract/icons/lucide/diamond.svg b/crates/ui-contract/icons/lucide/diamond.svg new file mode 100644 index 000000000..2d659515b --- /dev/null +++ b/crates/ui-contract/icons/lucide/diamond.svg @@ -0,0 +1,15 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/droplet.svg b/crates/ui-contract/icons/lucide/droplet.svg new file mode 100644 index 000000000..960bc5666 --- /dev/null +++ b/crates/ui-contract/icons/lucide/droplet.svg @@ -0,0 +1,15 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/ellipsis.svg b/crates/ui-contract/icons/lucide/ellipsis.svg new file mode 100644 index 000000000..68456c39b --- /dev/null +++ b/crates/ui-contract/icons/lucide/ellipsis.svg @@ -0,0 +1,15 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/eraser.svg b/crates/ui-contract/icons/lucide/eraser.svg new file mode 100644 index 000000000..6abb6fdda --- /dev/null +++ b/crates/ui-contract/icons/lucide/eraser.svg @@ -0,0 +1,14 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/external-link.svg b/crates/ui-contract/icons/lucide/external-link.svg new file mode 100644 index 000000000..a73a9ba28 --- /dev/null +++ b/crates/ui-contract/icons/lucide/external-link.svg @@ -0,0 +1,15 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/eye-off.svg b/crates/ui-contract/icons/lucide/eye-off.svg new file mode 100644 index 000000000..0083aaa87 --- /dev/null +++ b/crates/ui-contract/icons/lucide/eye-off.svg @@ -0,0 +1,16 @@ + + + + + + diff --git a/crates/ui-contract/icons/lucide/eye.svg b/crates/ui-contract/icons/lucide/eye.svg new file mode 100644 index 000000000..e5e78706b --- /dev/null +++ b/crates/ui-contract/icons/lucide/eye.svg @@ -0,0 +1,14 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/eyedropper-black.svg b/crates/ui-contract/icons/lucide/eyedropper-black.svg new file mode 100644 index 000000000..3acc2afdd --- /dev/null +++ b/crates/ui-contract/icons/lucide/eyedropper-black.svg @@ -0,0 +1,15 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/eyedropper-gray.svg b/crates/ui-contract/icons/lucide/eyedropper-gray.svg new file mode 100644 index 000000000..809687739 --- /dev/null +++ b/crates/ui-contract/icons/lucide/eyedropper-gray.svg @@ -0,0 +1,16 @@ + + + + + + diff --git a/crates/ui-contract/icons/lucide/eyedropper-white.svg b/crates/ui-contract/icons/lucide/eyedropper-white.svg new file mode 100644 index 000000000..19f7d4c37 --- /dev/null +++ b/crates/ui-contract/icons/lucide/eyedropper-white.svg @@ -0,0 +1,15 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/file-plus.svg b/crates/ui-contract/icons/lucide/file-plus.svg new file mode 100644 index 000000000..fe4715be0 --- /dev/null +++ b/crates/ui-contract/icons/lucide/file-plus.svg @@ -0,0 +1,16 @@ + + + + + + diff --git a/crates/ui-contract/icons/lucide/file.svg b/crates/ui-contract/icons/lucide/file.svg new file mode 100644 index 000000000..8c490248b --- /dev/null +++ b/crates/ui-contract/icons/lucide/file.svg @@ -0,0 +1,16 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/flag.svg b/crates/ui-contract/icons/lucide/flag.svg new file mode 100644 index 000000000..7a15001d6 --- /dev/null +++ b/crates/ui-contract/icons/lucide/flag.svg @@ -0,0 +1,13 @@ + + + diff --git a/crates/ui-contract/icons/lucide/flame.svg b/crates/ui-contract/icons/lucide/flame.svg new file mode 100644 index 000000000..00892bf49 --- /dev/null +++ b/crates/ui-contract/icons/lucide/flame.svg @@ -0,0 +1,15 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/folder-open.svg b/crates/ui-contract/icons/lucide/folder-open.svg new file mode 100644 index 000000000..b01f60fcb --- /dev/null +++ b/crates/ui-contract/icons/lucide/folder-open.svg @@ -0,0 +1,13 @@ + + + diff --git a/crates/ui-contract/icons/lucide/folder-plus.svg b/crates/ui-contract/icons/lucide/folder-plus.svg new file mode 100644 index 000000000..7257b18cb --- /dev/null +++ b/crates/ui-contract/icons/lucide/folder-plus.svg @@ -0,0 +1,17 @@ + + + + + + diff --git a/crates/ui-contract/icons/lucide/folder.svg b/crates/ui-contract/icons/lucide/folder.svg new file mode 100644 index 000000000..01f58e0cf --- /dev/null +++ b/crates/ui-contract/icons/lucide/folder.svg @@ -0,0 +1,15 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/frame.svg b/crates/ui-contract/icons/lucide/frame.svg new file mode 100644 index 000000000..4d4deeb04 --- /dev/null +++ b/crates/ui-contract/icons/lucide/frame.svg @@ -0,0 +1,18 @@ + + + + + + + diff --git a/crates/ui-contract/icons/lucide/funnel.svg b/crates/ui-contract/icons/lucide/funnel.svg new file mode 100644 index 000000000..e4a498693 --- /dev/null +++ b/crates/ui-contract/icons/lucide/funnel.svg @@ -0,0 +1,15 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/gauge.svg b/crates/ui-contract/icons/lucide/gauge.svg new file mode 100644 index 000000000..5467bc42c --- /dev/null +++ b/crates/ui-contract/icons/lucide/gauge.svg @@ -0,0 +1,16 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/globe.svg b/crates/ui-contract/icons/lucide/globe.svg new file mode 100644 index 000000000..5300da56d --- /dev/null +++ b/crates/ui-contract/icons/lucide/globe.svg @@ -0,0 +1,17 @@ + + + + + + diff --git a/crates/ui-contract/icons/lucide/grid-2x2.svg b/crates/ui-contract/icons/lucide/grid-2x2.svg new file mode 100644 index 000000000..7452854f9 --- /dev/null +++ b/crates/ui-contract/icons/lucide/grid-2x2.svg @@ -0,0 +1,17 @@ + + + + + + diff --git a/crates/ui-contract/icons/lucide/grid-3x3.svg b/crates/ui-contract/icons/lucide/grid-3x3.svg new file mode 100644 index 000000000..5cb8c2351 --- /dev/null +++ b/crates/ui-contract/icons/lucide/grid-3x3.svg @@ -0,0 +1,19 @@ + + + + + + + + diff --git a/crates/ui-contract/icons/lucide/hand.svg b/crates/ui-contract/icons/lucide/hand.svg new file mode 100644 index 000000000..30af90469 --- /dev/null +++ b/crates/ui-contract/icons/lucide/hand.svg @@ -0,0 +1,16 @@ + + + + + + diff --git a/crates/ui-contract/icons/lucide/headphones.svg b/crates/ui-contract/icons/lucide/headphones.svg new file mode 100644 index 000000000..a5e67588d --- /dev/null +++ b/crates/ui-contract/icons/lucide/headphones.svg @@ -0,0 +1,15 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/house.svg b/crates/ui-contract/icons/lucide/house.svg new file mode 100644 index 000000000..67c08533d --- /dev/null +++ b/crates/ui-contract/icons/lucide/house.svg @@ -0,0 +1,16 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/image.svg b/crates/ui-contract/icons/lucide/image.svg new file mode 100644 index 000000000..3241134c0 --- /dev/null +++ b/crates/ui-contract/icons/lucide/image.svg @@ -0,0 +1,15 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/info.svg b/crates/ui-contract/icons/lucide/info.svg new file mode 100644 index 000000000..2a46eac2b --- /dev/null +++ b/crates/ui-contract/icons/lucide/info.svg @@ -0,0 +1,15 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/italic.svg b/crates/ui-contract/icons/lucide/italic.svg new file mode 100644 index 000000000..f20663e14 --- /dev/null +++ b/crates/ui-contract/icons/lucide/italic.svg @@ -0,0 +1,15 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/keyboard.svg b/crates/ui-contract/icons/lucide/keyboard.svg new file mode 100644 index 000000000..7203fcf4b --- /dev/null +++ b/crates/ui-contract/icons/lucide/keyboard.svg @@ -0,0 +1,23 @@ + + + + + + + + + + + + diff --git a/crates/ui-contract/icons/lucide/lasso-select.svg b/crates/ui-contract/icons/lucide/lasso-select.svg new file mode 100644 index 000000000..a40549843 --- /dev/null +++ b/crates/ui-contract/icons/lucide/lasso-select.svg @@ -0,0 +1,19 @@ + + + + + + + + diff --git a/crates/ui-contract/icons/lucide/lasso.svg b/crates/ui-contract/icons/lucide/lasso.svg new file mode 100644 index 000000000..22426975f --- /dev/null +++ b/crates/ui-contract/icons/lucide/lasso.svg @@ -0,0 +1,17 @@ + + + + + + diff --git a/crates/ui-contract/icons/lucide/layers.svg b/crates/ui-contract/icons/lucide/layers.svg new file mode 100644 index 000000000..a3b69ae31 --- /dev/null +++ b/crates/ui-contract/icons/lucide/layers.svg @@ -0,0 +1,15 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/layout-grid.svg b/crates/ui-contract/icons/lucide/layout-grid.svg new file mode 100644 index 000000000..94f400810 --- /dev/null +++ b/crates/ui-contract/icons/lucide/layout-grid.svg @@ -0,0 +1,18 @@ + + + + + + + diff --git a/crates/ui-contract/icons/lucide/ligature.svg b/crates/ui-contract/icons/lucide/ligature.svg new file mode 100644 index 000000000..68fee8cde --- /dev/null +++ b/crates/ui-contract/icons/lucide/ligature.svg @@ -0,0 +1,17 @@ + + + + + + + diff --git a/crates/ui-contract/icons/lucide/link-2.svg b/crates/ui-contract/icons/lucide/link-2.svg new file mode 100644 index 000000000..be893a378 --- /dev/null +++ b/crates/ui-contract/icons/lucide/link-2.svg @@ -0,0 +1,17 @@ + + + + + + diff --git a/crates/ui-contract/icons/lucide/link.svg b/crates/ui-contract/icons/lucide/link.svg new file mode 100644 index 000000000..645e746a8 --- /dev/null +++ b/crates/ui-contract/icons/lucide/link.svg @@ -0,0 +1,14 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/list.svg b/crates/ui-contract/icons/lucide/list.svg new file mode 100644 index 000000000..3b4d14f0e --- /dev/null +++ b/crates/ui-contract/icons/lucide/list.svg @@ -0,0 +1,20 @@ + + + + + + + + + diff --git a/crates/ui-contract/icons/lucide/lock-open.svg b/crates/ui-contract/icons/lucide/lock-open.svg new file mode 100644 index 000000000..b23671285 --- /dev/null +++ b/crates/ui-contract/icons/lucide/lock-open.svg @@ -0,0 +1,14 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/lock.svg b/crates/ui-contract/icons/lucide/lock.svg new file mode 100644 index 000000000..b2b32d129 --- /dev/null +++ b/crates/ui-contract/icons/lucide/lock.svg @@ -0,0 +1,14 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/lollipop.svg b/crates/ui-contract/icons/lucide/lollipop.svg new file mode 100644 index 000000000..4d246d6a1 --- /dev/null +++ b/crates/ui-contract/icons/lucide/lollipop.svg @@ -0,0 +1,17 @@ + + + + + + diff --git a/crates/ui-contract/icons/lucide/magnet.svg b/crates/ui-contract/icons/lucide/magnet.svg new file mode 100644 index 000000000..e7257010f --- /dev/null +++ b/crates/ui-contract/icons/lucide/magnet.svg @@ -0,0 +1,17 @@ + + + + + + diff --git a/crates/ui-contract/icons/lucide/mail.svg b/crates/ui-contract/icons/lucide/mail.svg new file mode 100644 index 000000000..c600810b9 --- /dev/null +++ b/crates/ui-contract/icons/lucide/mail.svg @@ -0,0 +1,16 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/maximize-2.svg b/crates/ui-contract/icons/lucide/maximize-2.svg new file mode 100644 index 000000000..ce85efe90 --- /dev/null +++ b/crates/ui-contract/icons/lucide/maximize-2.svg @@ -0,0 +1,18 @@ + + + + + + + diff --git a/crates/ui-contract/icons/lucide/menu.svg b/crates/ui-contract/icons/lucide/menu.svg new file mode 100644 index 000000000..febcf86f5 --- /dev/null +++ b/crates/ui-contract/icons/lucide/menu.svg @@ -0,0 +1,17 @@ + + + + + + diff --git a/crates/ui-contract/icons/lucide/message-square.svg b/crates/ui-contract/icons/lucide/message-square.svg new file mode 100644 index 000000000..fb80d19ce --- /dev/null +++ b/crates/ui-contract/icons/lucide/message-square.svg @@ -0,0 +1,15 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/minus.svg b/crates/ui-contract/icons/lucide/minus.svg new file mode 100644 index 000000000..75093e27c --- /dev/null +++ b/crates/ui-contract/icons/lucide/minus.svg @@ -0,0 +1,13 @@ + + + diff --git a/crates/ui-contract/icons/lucide/monitor.svg b/crates/ui-contract/icons/lucide/monitor.svg new file mode 100644 index 000000000..a52d86dfe --- /dev/null +++ b/crates/ui-contract/icons/lucide/monitor.svg @@ -0,0 +1,17 @@ + + + + + + diff --git a/crates/ui-contract/icons/lucide/moon.svg b/crates/ui-contract/icons/lucide/moon.svg new file mode 100644 index 000000000..450a30e2b --- /dev/null +++ b/crates/ui-contract/icons/lucide/moon.svg @@ -0,0 +1,15 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/mouse-pointer-2.svg b/crates/ui-contract/icons/lucide/mouse-pointer-2.svg new file mode 100644 index 000000000..4ec905b78 --- /dev/null +++ b/crates/ui-contract/icons/lucide/mouse-pointer-2.svg @@ -0,0 +1,15 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/move.svg b/crates/ui-contract/icons/lucide/move.svg new file mode 100644 index 000000000..d78876f71 --- /dev/null +++ b/crates/ui-contract/icons/lucide/move.svg @@ -0,0 +1,18 @@ + + + + + + + + diff --git a/crates/ui-contract/icons/lucide/navigation.svg b/crates/ui-contract/icons/lucide/navigation.svg new file mode 100644 index 000000000..8cf8e8a42 --- /dev/null +++ b/crates/ui-contract/icons/lucide/navigation.svg @@ -0,0 +1,15 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/paint-bucket.svg b/crates/ui-contract/icons/lucide/paint-bucket.svg new file mode 100644 index 000000000..6546dd879 --- /dev/null +++ b/crates/ui-contract/icons/lucide/paint-bucket.svg @@ -0,0 +1,18 @@ + + + + + + + diff --git a/crates/ui-contract/icons/lucide/palette.svg b/crates/ui-contract/icons/lucide/palette.svg new file mode 100644 index 000000000..38e37e421 --- /dev/null +++ b/crates/ui-contract/icons/lucide/palette.svg @@ -0,0 +1,19 @@ + + + + + + + + diff --git a/crates/ui-contract/icons/lucide/panel-right.svg b/crates/ui-contract/icons/lucide/panel-right.svg new file mode 100644 index 000000000..d4b3bec57 --- /dev/null +++ b/crates/ui-contract/icons/lucide/panel-right.svg @@ -0,0 +1,16 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/panels-top-left.svg b/crates/ui-contract/icons/lucide/panels-top-left.svg new file mode 100644 index 000000000..248acfb31 --- /dev/null +++ b/crates/ui-contract/icons/lucide/panels-top-left.svg @@ -0,0 +1,17 @@ + + + + + + diff --git a/crates/ui-contract/icons/lucide/pause.svg b/crates/ui-contract/icons/lucide/pause.svg new file mode 100644 index 000000000..6c4379530 --- /dev/null +++ b/crates/ui-contract/icons/lucide/pause.svg @@ -0,0 +1,16 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/pen-tool.svg b/crates/ui-contract/icons/lucide/pen-tool.svg new file mode 100644 index 000000000..9dbadd938 --- /dev/null +++ b/crates/ui-contract/icons/lucide/pen-tool.svg @@ -0,0 +1,18 @@ + + + + + + + diff --git a/crates/ui-contract/icons/lucide/pencil.svg b/crates/ui-contract/icons/lucide/pencil.svg new file mode 100644 index 000000000..7384498e8 --- /dev/null +++ b/crates/ui-contract/icons/lucide/pencil.svg @@ -0,0 +1,14 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/pentagon.svg b/crates/ui-contract/icons/lucide/pentagon.svg new file mode 100644 index 000000000..476de7e04 --- /dev/null +++ b/crates/ui-contract/icons/lucide/pentagon.svg @@ -0,0 +1,15 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/pilcrow-left.svg b/crates/ui-contract/icons/lucide/pilcrow-left.svg new file mode 100644 index 000000000..4a2ff32a4 --- /dev/null +++ b/crates/ui-contract/icons/lucide/pilcrow-left.svg @@ -0,0 +1,17 @@ + + + + + + + diff --git a/crates/ui-contract/icons/lucide/pilcrow-right.svg b/crates/ui-contract/icons/lucide/pilcrow-right.svg new file mode 100644 index 000000000..9c09eb396 --- /dev/null +++ b/crates/ui-contract/icons/lucide/pilcrow-right.svg @@ -0,0 +1,17 @@ + + + + + + + diff --git a/crates/ui-contract/icons/lucide/pilcrow.svg b/crates/ui-contract/icons/lucide/pilcrow.svg new file mode 100644 index 000000000..b290942ba --- /dev/null +++ b/crates/ui-contract/icons/lucide/pilcrow.svg @@ -0,0 +1,15 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/pipette.svg b/crates/ui-contract/icons/lucide/pipette.svg new file mode 100644 index 000000000..2a5e13634 --- /dev/null +++ b/crates/ui-contract/icons/lucide/pipette.svg @@ -0,0 +1,15 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/play.svg b/crates/ui-contract/icons/lucide/play.svg new file mode 100644 index 000000000..e728259c8 --- /dev/null +++ b/crates/ui-contract/icons/lucide/play.svg @@ -0,0 +1,15 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/plus.svg b/crates/ui-contract/icons/lucide/plus.svg new file mode 100644 index 000000000..41f92bb93 --- /dev/null +++ b/crates/ui-contract/icons/lucide/plus.svg @@ -0,0 +1,14 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/pointer.svg b/crates/ui-contract/icons/lucide/pointer.svg new file mode 100644 index 000000000..b71adb803 --- /dev/null +++ b/crates/ui-contract/icons/lucide/pointer.svg @@ -0,0 +1,19 @@ + + + + + + + + diff --git a/crates/ui-contract/icons/lucide/rectangle-horizontal.svg b/crates/ui-contract/icons/lucide/rectangle-horizontal.svg new file mode 100644 index 000000000..1eef2889d --- /dev/null +++ b/crates/ui-contract/icons/lucide/rectangle-horizontal.svg @@ -0,0 +1,15 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/rectangle-vertical.svg b/crates/ui-contract/icons/lucide/rectangle-vertical.svg new file mode 100644 index 000000000..add4375ff --- /dev/null +++ b/crates/ui-contract/icons/lucide/rectangle-vertical.svg @@ -0,0 +1,15 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/redo-2.svg b/crates/ui-contract/icons/lucide/redo-2.svg new file mode 100644 index 000000000..72371c8d3 --- /dev/null +++ b/crates/ui-contract/icons/lucide/redo-2.svg @@ -0,0 +1,14 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/refresh-cw.svg b/crates/ui-contract/icons/lucide/refresh-cw.svg new file mode 100644 index 000000000..c27b3a967 --- /dev/null +++ b/crates/ui-contract/icons/lucide/refresh-cw.svg @@ -0,0 +1,16 @@ + + + + + + diff --git a/crates/ui-contract/icons/lucide/rotate-ccw.svg b/crates/ui-contract/icons/lucide/rotate-ccw.svg new file mode 100644 index 000000000..a79b7574c --- /dev/null +++ b/crates/ui-contract/icons/lucide/rotate-ccw.svg @@ -0,0 +1,16 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/rotate-cw.svg b/crates/ui-contract/icons/lucide/rotate-cw.svg new file mode 100644 index 000000000..6795f1576 --- /dev/null +++ b/crates/ui-contract/icons/lucide/rotate-cw.svg @@ -0,0 +1,14 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/ruler.svg b/crates/ui-contract/icons/lucide/ruler.svg new file mode 100644 index 000000000..5701dff14 --- /dev/null +++ b/crates/ui-contract/icons/lucide/ruler.svg @@ -0,0 +1,19 @@ + + + + + + + + diff --git a/crates/ui-contract/icons/lucide/save.svg b/crates/ui-contract/icons/lucide/save.svg new file mode 100644 index 000000000..07af07083 --- /dev/null +++ b/crates/ui-contract/icons/lucide/save.svg @@ -0,0 +1,15 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/scan-line.svg b/crates/ui-contract/icons/lucide/scan-line.svg new file mode 100644 index 000000000..a96000339 --- /dev/null +++ b/crates/ui-contract/icons/lucide/scan-line.svg @@ -0,0 +1,19 @@ + + + + + + + + diff --git a/crates/ui-contract/icons/lucide/scan.svg b/crates/ui-contract/icons/lucide/scan.svg new file mode 100644 index 000000000..4174cf348 --- /dev/null +++ b/crates/ui-contract/icons/lucide/scan.svg @@ -0,0 +1,18 @@ + + + + + + + diff --git a/crates/ui-contract/icons/lucide/scissors.svg b/crates/ui-contract/icons/lucide/scissors.svg new file mode 100644 index 000000000..55dca3057 --- /dev/null +++ b/crates/ui-contract/icons/lucide/scissors.svg @@ -0,0 +1,19 @@ + + + + + + + + diff --git a/crates/ui-contract/icons/lucide/search.svg b/crates/ui-contract/icons/lucide/search.svg new file mode 100644 index 000000000..03e442a54 --- /dev/null +++ b/crates/ui-contract/icons/lucide/search.svg @@ -0,0 +1,14 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/settings.svg b/crates/ui-contract/icons/lucide/settings.svg new file mode 100644 index 000000000..4c6263af9 --- /dev/null +++ b/crates/ui-contract/icons/lucide/settings.svg @@ -0,0 +1,14 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/slash.svg b/crates/ui-contract/icons/lucide/slash.svg new file mode 100644 index 000000000..cd36905a7 --- /dev/null +++ b/crates/ui-contract/icons/lucide/slash.svg @@ -0,0 +1,15 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/slice.svg b/crates/ui-contract/icons/lucide/slice.svg new file mode 100644 index 000000000..34fc6cd19 --- /dev/null +++ b/crates/ui-contract/icons/lucide/slice.svg @@ -0,0 +1,15 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/sliders-horizontal.svg b/crates/ui-contract/icons/lucide/sliders-horizontal.svg new file mode 100644 index 000000000..a3d47611d --- /dev/null +++ b/crates/ui-contract/icons/lucide/sliders-horizontal.svg @@ -0,0 +1,23 @@ + + + + + + + + + + + + diff --git a/crates/ui-contract/icons/lucide/sparkles.svg b/crates/ui-contract/icons/lucide/sparkles.svg new file mode 100644 index 000000000..a920dfd4f --- /dev/null +++ b/crates/ui-contract/icons/lucide/sparkles.svg @@ -0,0 +1,18 @@ + + + + + + + diff --git a/crates/ui-contract/icons/lucide/spline.svg b/crates/ui-contract/icons/lucide/spline.svg new file mode 100644 index 000000000..1929911e2 --- /dev/null +++ b/crates/ui-contract/icons/lucide/spline.svg @@ -0,0 +1,17 @@ + + + + + + diff --git a/crates/ui-contract/icons/lucide/split.svg b/crates/ui-contract/icons/lucide/split.svg new file mode 100644 index 000000000..db91ae2a3 --- /dev/null +++ b/crates/ui-contract/icons/lucide/split.svg @@ -0,0 +1,18 @@ + + + + + + + diff --git a/crates/ui-contract/icons/lucide/square-dashed.svg b/crates/ui-contract/icons/lucide/square-dashed.svg new file mode 100644 index 000000000..d3cb843b9 --- /dev/null +++ b/crates/ui-contract/icons/lucide/square-dashed.svg @@ -0,0 +1,26 @@ + + + + + + + + + + + + + + + diff --git a/crates/ui-contract/icons/lucide/square-plus.svg b/crates/ui-contract/icons/lucide/square-plus.svg new file mode 100644 index 000000000..f1b5c5260 --- /dev/null +++ b/crates/ui-contract/icons/lucide/square-plus.svg @@ -0,0 +1,17 @@ + + + + + + diff --git a/crates/ui-contract/icons/lucide/square-split-horizontal.svg b/crates/ui-contract/icons/lucide/square-split-horizontal.svg new file mode 100644 index 000000000..90157f9d1 --- /dev/null +++ b/crates/ui-contract/icons/lucide/square-split-horizontal.svg @@ -0,0 +1,17 @@ + + + + + + diff --git a/crates/ui-contract/icons/lucide/square-split-vertical.svg b/crates/ui-contract/icons/lucide/square-split-vertical.svg new file mode 100644 index 000000000..729f54661 --- /dev/null +++ b/crates/ui-contract/icons/lucide/square-split-vertical.svg @@ -0,0 +1,17 @@ + + + + + + diff --git a/crates/ui-contract/icons/lucide/square-x.svg b/crates/ui-contract/icons/lucide/square-x.svg new file mode 100644 index 000000000..ba59c9445 --- /dev/null +++ b/crates/ui-contract/icons/lucide/square-x.svg @@ -0,0 +1,17 @@ + + + + + + diff --git a/crates/ui-contract/icons/lucide/square.svg b/crates/ui-contract/icons/lucide/square.svg new file mode 100644 index 000000000..786273355 --- /dev/null +++ b/crates/ui-contract/icons/lucide/square.svg @@ -0,0 +1,13 @@ + + + diff --git a/crates/ui-contract/icons/lucide/squares-intersect.svg b/crates/ui-contract/icons/lucide/squares-intersect.svg new file mode 100644 index 000000000..069bf8315 --- /dev/null +++ b/crates/ui-contract/icons/lucide/squares-intersect.svg @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + diff --git a/crates/ui-contract/icons/lucide/squares-subtract.svg b/crates/ui-contract/icons/lucide/squares-subtract.svg new file mode 100644 index 000000000..8dbd9db10 --- /dev/null +++ b/crates/ui-contract/icons/lucide/squares-subtract.svg @@ -0,0 +1,18 @@ + + + + + + + + diff --git a/crates/ui-contract/icons/lucide/stamp.svg b/crates/ui-contract/icons/lucide/stamp.svg new file mode 100644 index 000000000..1dc3840e3 --- /dev/null +++ b/crates/ui-contract/icons/lucide/stamp.svg @@ -0,0 +1,17 @@ + + + + + + diff --git a/crates/ui-contract/icons/lucide/star.svg b/crates/ui-contract/icons/lucide/star.svg new file mode 100644 index 000000000..e43ab643b --- /dev/null +++ b/crates/ui-contract/icons/lucide/star.svg @@ -0,0 +1,15 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/step-back.svg b/crates/ui-contract/icons/lucide/step-back.svg new file mode 100644 index 000000000..c7e85c7d6 --- /dev/null +++ b/crates/ui-contract/icons/lucide/step-back.svg @@ -0,0 +1,16 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/step-forward.svg b/crates/ui-contract/icons/lucide/step-forward.svg new file mode 100644 index 000000000..8b94756a4 --- /dev/null +++ b/crates/ui-contract/icons/lucide/step-forward.svg @@ -0,0 +1,16 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/strikethrough.svg b/crates/ui-contract/icons/lucide/strikethrough.svg new file mode 100644 index 000000000..a6f226503 --- /dev/null +++ b/crates/ui-contract/icons/lucide/strikethrough.svg @@ -0,0 +1,15 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/subscript.svg b/crates/ui-contract/icons/lucide/subscript.svg new file mode 100644 index 000000000..b20115289 --- /dev/null +++ b/crates/ui-contract/icons/lucide/subscript.svg @@ -0,0 +1,15 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/sun.svg b/crates/ui-contract/icons/lucide/sun.svg new file mode 100644 index 000000000..4d536c15b --- /dev/null +++ b/crates/ui-contract/icons/lucide/sun.svg @@ -0,0 +1,23 @@ + + + + + + + + + + + + diff --git a/crates/ui-contract/icons/lucide/superscript.svg b/crates/ui-contract/icons/lucide/superscript.svg new file mode 100644 index 000000000..b07c36a97 --- /dev/null +++ b/crates/ui-contract/icons/lucide/superscript.svg @@ -0,0 +1,15 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/swatch-book.svg b/crates/ui-contract/icons/lucide/swatch-book.svg new file mode 100644 index 000000000..907bd3de2 --- /dev/null +++ b/crates/ui-contract/icons/lucide/swatch-book.svg @@ -0,0 +1,18 @@ + + + + + + + diff --git a/crates/ui-contract/icons/lucide/text-cursor.svg b/crates/ui-contract/icons/lucide/text-cursor.svg new file mode 100644 index 000000000..b44c0e066 --- /dev/null +++ b/crates/ui-contract/icons/lucide/text-cursor.svg @@ -0,0 +1,17 @@ + + + + + + diff --git a/crates/ui-contract/icons/lucide/thumbs-down.svg b/crates/ui-contract/icons/lucide/thumbs-down.svg new file mode 100644 index 000000000..c247fbce9 --- /dev/null +++ b/crates/ui-contract/icons/lucide/thumbs-down.svg @@ -0,0 +1,16 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/thumbs-up.svg b/crates/ui-contract/icons/lucide/thumbs-up.svg new file mode 100644 index 000000000..3d76301d1 --- /dev/null +++ b/crates/ui-contract/icons/lucide/thumbs-up.svg @@ -0,0 +1,16 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/toggle-left.svg b/crates/ui-contract/icons/lucide/toggle-left.svg new file mode 100644 index 000000000..9942a9a86 --- /dev/null +++ b/crates/ui-contract/icons/lucide/toggle-left.svg @@ -0,0 +1,16 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/toggle-right.svg b/crates/ui-contract/icons/lucide/toggle-right.svg new file mode 100644 index 000000000..d91820340 --- /dev/null +++ b/crates/ui-contract/icons/lucide/toggle-right.svg @@ -0,0 +1,16 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/trash.svg b/crates/ui-contract/icons/lucide/trash.svg new file mode 100644 index 000000000..e8cb0edf3 --- /dev/null +++ b/crates/ui-contract/icons/lucide/trash.svg @@ -0,0 +1,17 @@ + + + + + + + diff --git a/crates/ui-contract/icons/lucide/triangle-alert.svg b/crates/ui-contract/icons/lucide/triangle-alert.svg new file mode 100644 index 000000000..3232fb062 --- /dev/null +++ b/crates/ui-contract/icons/lucide/triangle-alert.svg @@ -0,0 +1,15 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/triangle.svg b/crates/ui-contract/icons/lucide/triangle.svg new file mode 100644 index 000000000..1ea770074 --- /dev/null +++ b/crates/ui-contract/icons/lucide/triangle.svg @@ -0,0 +1,15 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/type.svg b/crates/ui-contract/icons/lucide/type.svg new file mode 100644 index 000000000..8f269e72e --- /dev/null +++ b/crates/ui-contract/icons/lucide/type.svg @@ -0,0 +1,15 @@ + + + + + diff --git a/crates/ui-contract/icons/lucide/underline.svg b/crates/ui-contract/icons/lucide/underline.svg new file mode 100644 index 000000000..3d7f422cc --- /dev/null +++ b/crates/ui-contract/icons/lucide/underline.svg @@ -0,0 +1,14 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/undo-2.svg b/crates/ui-contract/icons/lucide/undo-2.svg new file mode 100644 index 000000000..3e93594c0 --- /dev/null +++ b/crates/ui-contract/icons/lucide/undo-2.svg @@ -0,0 +1,14 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/unlink.svg b/crates/ui-contract/icons/lucide/unlink.svg new file mode 100644 index 000000000..a89aa2f1c --- /dev/null +++ b/crates/ui-contract/icons/lucide/unlink.svg @@ -0,0 +1,18 @@ + + + + + + + + diff --git a/crates/ui-contract/icons/lucide/volume-off.svg b/crates/ui-contract/icons/lucide/volume-off.svg new file mode 100644 index 000000000..76676a0db --- /dev/null +++ b/crates/ui-contract/icons/lucide/volume-off.svg @@ -0,0 +1,19 @@ + + + + + + + + diff --git a/crates/ui-contract/icons/lucide/wand-sparkles.svg b/crates/ui-contract/icons/lucide/wand-sparkles.svg new file mode 100644 index 000000000..3d5855eba --- /dev/null +++ b/crates/ui-contract/icons/lucide/wand-sparkles.svg @@ -0,0 +1,22 @@ + + + + + + + + + + + diff --git a/crates/ui-contract/icons/lucide/wand.svg b/crates/ui-contract/icons/lucide/wand.svg new file mode 100644 index 000000000..9ab82d11d --- /dev/null +++ b/crates/ui-contract/icons/lucide/wand.svg @@ -0,0 +1,23 @@ + + + + + + + + + + + + diff --git a/crates/ui-contract/icons/lucide/x.svg b/crates/ui-contract/icons/lucide/x.svg new file mode 100644 index 000000000..e31794349 --- /dev/null +++ b/crates/ui-contract/icons/lucide/x.svg @@ -0,0 +1,14 @@ + + + + diff --git a/crates/ui-contract/icons/lucide/zoom-in.svg b/crates/ui-contract/icons/lucide/zoom-in.svg new file mode 100644 index 000000000..11173c0e1 --- /dev/null +++ b/crates/ui-contract/icons/lucide/zoom-in.svg @@ -0,0 +1,16 @@ + + + + + + diff --git a/crates/ui-contract/icons/phosphor/LICENSE b/crates/ui-contract/icons/phosphor/LICENSE new file mode 100644 index 000000000..78c981081 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2023 Phosphor Icons + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/crates/ui-contract/icons/phosphor/align-bottom.svg b/crates/ui-contract/icons/phosphor/align-bottom.svg new file mode 100644 index 000000000..35b316457 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/align-bottom.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/align-center-horizontal.svg b/crates/ui-contract/icons/phosphor/align-center-horizontal.svg new file mode 100644 index 000000000..3f7e77fd8 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/align-center-horizontal.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/align-center-vertical.svg b/crates/ui-contract/icons/phosphor/align-center-vertical.svg new file mode 100644 index 000000000..a52acfa9d --- /dev/null +++ b/crates/ui-contract/icons/phosphor/align-center-vertical.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/align-left.svg b/crates/ui-contract/icons/phosphor/align-left.svg new file mode 100644 index 000000000..ed23187d7 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/align-left.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/align-right.svg b/crates/ui-contract/icons/phosphor/align-right.svg new file mode 100644 index 000000000..dd9edbccc --- /dev/null +++ b/crates/ui-contract/icons/phosphor/align-right.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/align-top.svg b/crates/ui-contract/icons/phosphor/align-top.svg new file mode 100644 index 000000000..8c85fdcf4 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/align-top.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/app-window.svg b/crates/ui-contract/icons/phosphor/app-window.svg new file mode 100644 index 000000000..e2ac7d67c --- /dev/null +++ b/crates/ui-contract/icons/phosphor/app-window.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/arrow-bend-up-left.svg b/crates/ui-contract/icons/phosphor/arrow-bend-up-left.svg new file mode 100644 index 000000000..c6ce0a10e --- /dev/null +++ b/crates/ui-contract/icons/phosphor/arrow-bend-up-left.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/arrow-clockwise.svg b/crates/ui-contract/icons/phosphor/arrow-clockwise.svg new file mode 100644 index 000000000..42d1e4867 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/arrow-clockwise.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/arrow-counter-clockwise.svg b/crates/ui-contract/icons/phosphor/arrow-counter-clockwise.svg new file mode 100644 index 000000000..5c6b67d9c --- /dev/null +++ b/crates/ui-contract/icons/phosphor/arrow-counter-clockwise.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/arrow-left.svg b/crates/ui-contract/icons/phosphor/arrow-left.svg new file mode 100644 index 000000000..0d0558ab2 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/arrow-left.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/arrow-square-out.svg b/crates/ui-contract/icons/phosphor/arrow-square-out.svg new file mode 100644 index 000000000..e46b33802 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/arrow-square-out.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/arrow-u-up-left.svg b/crates/ui-contract/icons/phosphor/arrow-u-up-left.svg new file mode 100644 index 000000000..72326c2d7 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/arrow-u-up-left.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/arrow-u-up-right.svg b/crates/ui-contract/icons/phosphor/arrow-u-up-right.svg new file mode 100644 index 000000000..7a94b87d6 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/arrow-u-up-right.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/arrows-clockwise.svg b/crates/ui-contract/icons/phosphor/arrows-clockwise.svg new file mode 100644 index 000000000..1561ad604 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/arrows-clockwise.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/arrows-down-up.svg b/crates/ui-contract/icons/phosphor/arrows-down-up.svg new file mode 100644 index 000000000..b9c507f12 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/arrows-down-up.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/arrows-left-right.svg b/crates/ui-contract/icons/phosphor/arrows-left-right.svg new file mode 100644 index 000000000..138d08716 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/arrows-left-right.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/arrows-out-cardinal.svg b/crates/ui-contract/icons/phosphor/arrows-out-cardinal.svg new file mode 100644 index 000000000..7cee67258 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/arrows-out-cardinal.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/arrows-out-simple.svg b/crates/ui-contract/icons/phosphor/arrows-out-simple.svg new file mode 100644 index 000000000..359b13fb4 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/arrows-out-simple.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/arrows-split.svg b/crates/ui-contract/icons/phosphor/arrows-split.svg new file mode 100644 index 000000000..678e0b3e6 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/arrows-split.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/bandage-sparkle.svg b/crates/ui-contract/icons/phosphor/bandage-sparkle.svg new file mode 100644 index 000000000..757ccc4f3 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/bandage-sparkle.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/bandaids.svg b/crates/ui-contract/icons/phosphor/bandaids.svg new file mode 100644 index 000000000..69a0de0e2 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/bandaids.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/bezier-curve.svg b/crates/ui-contract/icons/phosphor/bezier-curve.svg new file mode 100644 index 000000000..a57146dbc --- /dev/null +++ b/crates/ui-contract/icons/phosphor/bezier-curve.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/bookmark-simple.svg b/crates/ui-contract/icons/phosphor/bookmark-simple.svg new file mode 100644 index 000000000..8429ae980 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/bookmark-simple.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/broom.svg b/crates/ui-contract/icons/phosphor/broom.svg new file mode 100644 index 000000000..f678fa0c8 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/broom.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/brush-replace.svg b/crates/ui-contract/icons/phosphor/brush-replace.svg new file mode 100644 index 000000000..94c83a09b --- /dev/null +++ b/crates/ui-contract/icons/phosphor/brush-replace.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/calendar.svg b/crates/ui-contract/icons/phosphor/calendar.svg new file mode 100644 index 000000000..791b71462 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/calendar.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/caret-double-left.svg b/crates/ui-contract/icons/phosphor/caret-double-left.svg new file mode 100644 index 000000000..764587354 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/caret-double-left.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/caret-double-right.svg b/crates/ui-contract/icons/phosphor/caret-double-right.svg new file mode 100644 index 000000000..1ae4648d6 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/caret-double-right.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/caret-down.svg b/crates/ui-contract/icons/phosphor/caret-down.svg new file mode 100644 index 000000000..c6e84e840 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/caret-down.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/caret-left.svg b/crates/ui-contract/icons/phosphor/caret-left.svg new file mode 100644 index 000000000..c68102c99 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/caret-left.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/caret-right.svg b/crates/ui-contract/icons/phosphor/caret-right.svg new file mode 100644 index 000000000..d73dd5d9d --- /dev/null +++ b/crates/ui-contract/icons/phosphor/caret-right.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/caret-up.svg b/crates/ui-contract/icons/phosphor/caret-up.svg new file mode 100644 index 000000000..75b39aa07 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/caret-up.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/chart-line.svg b/crates/ui-contract/icons/phosphor/chart-line.svg new file mode 100644 index 000000000..b3fe67a54 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/chart-line.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/chat.svg b/crates/ui-contract/icons/phosphor/chat.svg new file mode 100644 index 000000000..91245979c --- /dev/null +++ b/crates/ui-contract/icons/phosphor/chat.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/check-circle.svg b/crates/ui-contract/icons/phosphor/check-circle.svg new file mode 100644 index 000000000..eb406097b --- /dev/null +++ b/crates/ui-contract/icons/phosphor/check-circle.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/check.svg b/crates/ui-contract/icons/phosphor/check.svg new file mode 100644 index 000000000..04b2e2422 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/check.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/circle-dashed.svg b/crates/ui-contract/icons/phosphor/circle-dashed.svg new file mode 100644 index 000000000..a7f42626b --- /dev/null +++ b/crates/ui-contract/icons/phosphor/circle-dashed.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/circle-half.svg b/crates/ui-contract/icons/phosphor/circle-half.svg new file mode 100644 index 000000000..7c8d2d45b --- /dev/null +++ b/crates/ui-contract/icons/phosphor/circle-half.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/circle.svg b/crates/ui-contract/icons/phosphor/circle.svg new file mode 100644 index 000000000..e7b12e1a0 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/circle.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/clip-below.svg b/crates/ui-contract/icons/phosphor/clip-below.svg new file mode 100644 index 000000000..8081eb3cc --- /dev/null +++ b/crates/ui-contract/icons/phosphor/clip-below.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/clip-release.svg b/crates/ui-contract/icons/phosphor/clip-release.svg new file mode 100644 index 000000000..515835811 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/clip-release.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/clock.svg b/crates/ui-contract/icons/phosphor/clock.svg new file mode 100644 index 000000000..decf49eea --- /dev/null +++ b/crates/ui-contract/icons/phosphor/clock.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/cloud.svg b/crates/ui-contract/icons/phosphor/cloud.svg new file mode 100644 index 000000000..3aa44d4a4 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/cloud.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/compass.svg b/crates/ui-contract/icons/phosphor/compass.svg new file mode 100644 index 000000000..ebea40bbe --- /dev/null +++ b/crates/ui-contract/icons/phosphor/compass.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/convert-point.svg b/crates/ui-contract/icons/phosphor/convert-point.svg new file mode 100644 index 000000000..0b05e0597 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/convert-point.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/copy.svg b/crates/ui-contract/icons/phosphor/copy.svg new file mode 100644 index 000000000..8f3dd2ec9 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/copy.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/crop.svg b/crates/ui-contract/icons/phosphor/crop.svg new file mode 100644 index 000000000..bd465b886 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/crop.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/crosshair.svg b/crates/ui-contract/icons/phosphor/crosshair.svg new file mode 100644 index 000000000..29d504da5 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/crosshair.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/cube.svg b/crates/ui-contract/icons/phosphor/cube.svg new file mode 100644 index 000000000..13375d440 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/cube.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/cursor-text.svg b/crates/ui-contract/icons/phosphor/cursor-text.svg new file mode 100644 index 000000000..ec5a34a29 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/cursor-text.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/cursor.svg b/crates/ui-contract/icons/phosphor/cursor.svg new file mode 100644 index 000000000..7d28334ec --- /dev/null +++ b/crates/ui-contract/icons/phosphor/cursor.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/diamond.svg b/crates/ui-contract/icons/phosphor/diamond.svg new file mode 100644 index 000000000..8c8902cde --- /dev/null +++ b/crates/ui-contract/icons/phosphor/diamond.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/direct-select.svg b/crates/ui-contract/icons/phosphor/direct-select.svg new file mode 100644 index 000000000..6b4fd57df --- /dev/null +++ b/crates/ui-contract/icons/phosphor/direct-select.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/distribute-bottom.svg b/crates/ui-contract/icons/phosphor/distribute-bottom.svg new file mode 100644 index 000000000..f9a854919 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/distribute-bottom.svg @@ -0,0 +1 @@ + diff --git a/crates/ui-contract/icons/phosphor/distribute-hcenter.svg b/crates/ui-contract/icons/phosphor/distribute-hcenter.svg new file mode 100644 index 000000000..22c0c30b1 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/distribute-hcenter.svg @@ -0,0 +1 @@ + diff --git a/crates/ui-contract/icons/phosphor/distribute-horizontal.svg b/crates/ui-contract/icons/phosphor/distribute-horizontal.svg new file mode 100644 index 000000000..ada0a3e84 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/distribute-horizontal.svg @@ -0,0 +1 @@ + diff --git a/crates/ui-contract/icons/phosphor/distribute-left.svg b/crates/ui-contract/icons/phosphor/distribute-left.svg new file mode 100644 index 000000000..f6ec6610b --- /dev/null +++ b/crates/ui-contract/icons/phosphor/distribute-left.svg @@ -0,0 +1 @@ + diff --git a/crates/ui-contract/icons/phosphor/distribute-right.svg b/crates/ui-contract/icons/phosphor/distribute-right.svg new file mode 100644 index 000000000..3f1704d58 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/distribute-right.svg @@ -0,0 +1 @@ + diff --git a/crates/ui-contract/icons/phosphor/distribute-top.svg b/crates/ui-contract/icons/phosphor/distribute-top.svg new file mode 100644 index 000000000..18c669069 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/distribute-top.svg @@ -0,0 +1 @@ + diff --git a/crates/ui-contract/icons/phosphor/distribute-vcenter.svg b/crates/ui-contract/icons/phosphor/distribute-vcenter.svg new file mode 100644 index 000000000..356bf16ec --- /dev/null +++ b/crates/ui-contract/icons/phosphor/distribute-vcenter.svg @@ -0,0 +1 @@ + diff --git a/crates/ui-contract/icons/phosphor/distribute-vertical.svg b/crates/ui-contract/icons/phosphor/distribute-vertical.svg new file mode 100644 index 000000000..89400491c --- /dev/null +++ b/crates/ui-contract/icons/phosphor/distribute-vertical.svg @@ -0,0 +1 @@ + diff --git a/crates/ui-contract/icons/phosphor/dots-three.svg b/crates/ui-contract/icons/phosphor/dots-three.svg new file mode 100644 index 000000000..291944d55 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/dots-three.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/drop.svg b/crates/ui-contract/icons/phosphor/drop.svg new file mode 100644 index 000000000..8b2b27550 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/drop.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/envelope-simple.svg b/crates/ui-contract/icons/phosphor/envelope-simple.svg new file mode 100644 index 000000000..f77d510bd --- /dev/null +++ b/crates/ui-contract/icons/phosphor/envelope-simple.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/eraser-background.svg b/crates/ui-contract/icons/phosphor/eraser-background.svg new file mode 100644 index 000000000..683e00d71 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/eraser-background.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/eraser-magic.svg b/crates/ui-contract/icons/phosphor/eraser-magic.svg new file mode 100644 index 000000000..7a16ef7f6 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/eraser-magic.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/eraser.svg b/crates/ui-contract/icons/phosphor/eraser.svg new file mode 100644 index 000000000..fe2c45a2a --- /dev/null +++ b/crates/ui-contract/icons/phosphor/eraser.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/extract-clip.svg b/crates/ui-contract/icons/phosphor/extract-clip.svg new file mode 100644 index 000000000..69ec4c2cc --- /dev/null +++ b/crates/ui-contract/icons/phosphor/extract-clip.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/eye-slash.svg b/crates/ui-contract/icons/phosphor/eye-slash.svg new file mode 100644 index 000000000..7efa1c5fd --- /dev/null +++ b/crates/ui-contract/icons/phosphor/eye-slash.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/eye.svg b/crates/ui-contract/icons/phosphor/eye.svg new file mode 100644 index 000000000..f6f8230f4 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/eye.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/eyedropper-black.svg b/crates/ui-contract/icons/phosphor/eyedropper-black.svg new file mode 100644 index 000000000..3da438bb0 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/eyedropper-black.svg @@ -0,0 +1 @@ + diff --git a/crates/ui-contract/icons/phosphor/eyedropper-gray.svg b/crates/ui-contract/icons/phosphor/eyedropper-gray.svg new file mode 100644 index 000000000..a05f8fbdf --- /dev/null +++ b/crates/ui-contract/icons/phosphor/eyedropper-gray.svg @@ -0,0 +1 @@ + diff --git a/crates/ui-contract/icons/phosphor/eyedropper-white.svg b/crates/ui-contract/icons/phosphor/eyedropper-white.svg new file mode 100644 index 000000000..3fbb9cd54 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/eyedropper-white.svg @@ -0,0 +1 @@ + diff --git a/crates/ui-contract/icons/phosphor/eyedropper.svg b/crates/ui-contract/icons/phosphor/eyedropper.svg new file mode 100644 index 000000000..6f84dc2f9 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/eyedropper.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/file-plus.svg b/crates/ui-contract/icons/phosphor/file-plus.svg new file mode 100644 index 000000000..8e2717198 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/file-plus.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/file.svg b/crates/ui-contract/icons/phosphor/file.svg new file mode 100644 index 000000000..f2e762932 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/file.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/flag.svg b/crates/ui-contract/icons/phosphor/flag.svg new file mode 100644 index 000000000..6281e88de --- /dev/null +++ b/crates/ui-contract/icons/phosphor/flag.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/flame.svg b/crates/ui-contract/icons/phosphor/flame.svg new file mode 100644 index 000000000..c028787e3 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/flame.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/floppy-disk.svg b/crates/ui-contract/icons/phosphor/floppy-disk.svg new file mode 100644 index 000000000..1e9d68832 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/floppy-disk.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/folder-open.svg b/crates/ui-contract/icons/phosphor/folder-open.svg new file mode 100644 index 000000000..9d5c9c1ac --- /dev/null +++ b/crates/ui-contract/icons/phosphor/folder-open.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/folder-plus.svg b/crates/ui-contract/icons/phosphor/folder-plus.svg new file mode 100644 index 000000000..3ea2fea46 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/folder-plus.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/folder.svg b/crates/ui-contract/icons/phosphor/folder.svg new file mode 100644 index 000000000..df7437525 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/folder.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/font-similar.svg b/crates/ui-contract/icons/phosphor/font-similar.svg new file mode 100644 index 000000000..8a852beb5 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/font-similar.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/font-variable.svg b/crates/ui-contract/icons/phosphor/font-variable.svg new file mode 100644 index 000000000..73df51741 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/font-variable.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/frame-corners.svg b/crates/ui-contract/icons/phosphor/frame-corners.svg new file mode 100644 index 000000000..e61580a0e --- /dev/null +++ b/crates/ui-contract/icons/phosphor/frame-corners.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/funnel.svg b/crates/ui-contract/icons/phosphor/funnel.svg new file mode 100644 index 000000000..53545255a --- /dev/null +++ b/crates/ui-contract/icons/phosphor/funnel.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/fx.svg b/crates/ui-contract/icons/phosphor/fx.svg new file mode 100644 index 000000000..7c3293531 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/fx.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/gauge.svg b/crates/ui-contract/icons/phosphor/gauge.svg new file mode 100644 index 000000000..d1c183dd6 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/gauge.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/gear.svg b/crates/ui-contract/icons/phosphor/gear.svg new file mode 100644 index 000000000..a7e5860f1 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/gear.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/globe.svg b/crates/ui-contract/icons/phosphor/globe.svg new file mode 100644 index 000000000..a025613b6 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/globe.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/gradient-angle.svg b/crates/ui-contract/icons/phosphor/gradient-angle.svg new file mode 100644 index 000000000..a58f44e39 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/gradient-angle.svg @@ -0,0 +1 @@ + diff --git a/crates/ui-contract/icons/phosphor/gradient-diamond.svg b/crates/ui-contract/icons/phosphor/gradient-diamond.svg new file mode 100644 index 000000000..15f3131da --- /dev/null +++ b/crates/ui-contract/icons/phosphor/gradient-diamond.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/gradient-linear.svg b/crates/ui-contract/icons/phosphor/gradient-linear.svg new file mode 100644 index 000000000..e1c9ab7cc --- /dev/null +++ b/crates/ui-contract/icons/phosphor/gradient-linear.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/gradient-radial.svg b/crates/ui-contract/icons/phosphor/gradient-radial.svg new file mode 100644 index 000000000..b82b86703 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/gradient-radial.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/gradient-reflected.svg b/crates/ui-contract/icons/phosphor/gradient-reflected.svg new file mode 100644 index 000000000..03624184a --- /dev/null +++ b/crates/ui-contract/icons/phosphor/gradient-reflected.svg @@ -0,0 +1 @@ + diff --git a/crates/ui-contract/icons/phosphor/gradient.svg b/crates/ui-contract/icons/phosphor/gradient.svg new file mode 100644 index 000000000..533cf18c1 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/gradient.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/grid-four.svg b/crates/ui-contract/icons/phosphor/grid-four.svg new file mode 100644 index 000000000..5b1781430 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/grid-four.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/grid-nine.svg b/crates/ui-contract/icons/phosphor/grid-nine.svg new file mode 100644 index 000000000..0519b58cc --- /dev/null +++ b/crates/ui-contract/icons/phosphor/grid-nine.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/hand-pointing.svg b/crates/ui-contract/icons/phosphor/hand-pointing.svg new file mode 100644 index 000000000..57e90a507 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/hand-pointing.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/hand.svg b/crates/ui-contract/icons/phosphor/hand.svg new file mode 100644 index 000000000..ad361bc1d --- /dev/null +++ b/crates/ui-contract/icons/phosphor/hand.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/headphones.svg b/crates/ui-contract/icons/phosphor/headphones.svg new file mode 100644 index 000000000..7df553007 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/headphones.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/house.svg b/crates/ui-contract/icons/phosphor/house.svg new file mode 100644 index 000000000..3c6d2db65 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/house.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/image.svg b/crates/ui-contract/icons/phosphor/image.svg new file mode 100644 index 000000000..0e3fd4e46 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/image.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/info.svg b/crates/ui-contract/icons/phosphor/info.svg new file mode 100644 index 000000000..96369e212 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/info.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/insert-clip.svg b/crates/ui-contract/icons/phosphor/insert-clip.svg new file mode 100644 index 000000000..7c78b945c --- /dev/null +++ b/crates/ui-contract/icons/phosphor/insert-clip.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/intersect-square.svg b/crates/ui-contract/icons/phosphor/intersect-square.svg new file mode 100644 index 000000000..04ecc42cd --- /dev/null +++ b/crates/ui-contract/icons/phosphor/intersect-square.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/intersect.svg b/crates/ui-contract/icons/phosphor/intersect.svg new file mode 100644 index 000000000..009382584 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/intersect.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/key-auto-bezier.svg b/crates/ui-contract/icons/phosphor/key-auto-bezier.svg new file mode 100644 index 000000000..f7157f79a --- /dev/null +++ b/crates/ui-contract/icons/phosphor/key-auto-bezier.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/key-bezier.svg b/crates/ui-contract/icons/phosphor/key-bezier.svg new file mode 100644 index 000000000..dab257acd --- /dev/null +++ b/crates/ui-contract/icons/phosphor/key-bezier.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/key-continuous-bezier.svg b/crates/ui-contract/icons/phosphor/key-continuous-bezier.svg new file mode 100644 index 000000000..3971e7da2 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/key-continuous-bezier.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/key-ease-in.svg b/crates/ui-contract/icons/phosphor/key-ease-in.svg new file mode 100644 index 000000000..74ad3dd1c --- /dev/null +++ b/crates/ui-contract/icons/phosphor/key-ease-in.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/key-ease-out.svg b/crates/ui-contract/icons/phosphor/key-ease-out.svg new file mode 100644 index 000000000..03e12ac79 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/key-ease-out.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/key-hold.svg b/crates/ui-contract/icons/phosphor/key-hold.svg new file mode 100644 index 000000000..1f0748d6e --- /dev/null +++ b/crates/ui-contract/icons/phosphor/key-hold.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/key-linear-filled.svg b/crates/ui-contract/icons/phosphor/key-linear-filled.svg new file mode 100644 index 000000000..d59bdab9c --- /dev/null +++ b/crates/ui-contract/icons/phosphor/key-linear-filled.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/key-linear.svg b/crates/ui-contract/icons/phosphor/key-linear.svg new file mode 100644 index 000000000..df32fe574 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/key-linear.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/keyboard.svg b/crates/ui-contract/icons/phosphor/keyboard.svg new file mode 100644 index 000000000..f1dbc695a --- /dev/null +++ b/crates/ui-contract/icons/phosphor/keyboard.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/keyframe-auto-bezier.svg b/crates/ui-contract/icons/phosphor/keyframe-auto-bezier.svg new file mode 100644 index 000000000..bee75a527 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/keyframe-auto-bezier.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/keyframe-bezier.svg b/crates/ui-contract/icons/phosphor/keyframe-bezier.svg new file mode 100644 index 000000000..ef9b7e563 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/keyframe-bezier.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/keyframe-ease-in.svg b/crates/ui-contract/icons/phosphor/keyframe-ease-in.svg new file mode 100644 index 000000000..e048e79f6 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/keyframe-ease-in.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/keyframe-ease-out.svg b/crates/ui-contract/icons/phosphor/keyframe-ease-out.svg new file mode 100644 index 000000000..c6d007806 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/keyframe-ease-out.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/keyframe-easy-ease.svg b/crates/ui-contract/icons/phosphor/keyframe-easy-ease.svg new file mode 100644 index 000000000..ecb25d585 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/keyframe-easy-ease.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/keyframe-hold.svg b/crates/ui-contract/icons/phosphor/keyframe-hold.svg new file mode 100644 index 000000000..711e47cee --- /dev/null +++ b/crates/ui-contract/icons/phosphor/keyframe-hold.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/keyframe-linear.svg b/crates/ui-contract/icons/phosphor/keyframe-linear.svg new file mode 100644 index 000000000..8ad3fead1 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/keyframe-linear.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/knife.svg b/crates/ui-contract/icons/phosphor/knife.svg new file mode 100644 index 000000000..bf9efa311 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/knife.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/lasso-magnetic.svg b/crates/ui-contract/icons/phosphor/lasso-magnetic.svg new file mode 100644 index 000000000..36b6a5ea4 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/lasso-magnetic.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/lasso-select.svg b/crates/ui-contract/icons/phosphor/lasso-select.svg new file mode 100644 index 000000000..481a02bf0 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/lasso-select.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/lasso.svg b/crates/ui-contract/icons/phosphor/lasso.svg new file mode 100644 index 000000000..d7367ec3a --- /dev/null +++ b/crates/ui-contract/icons/phosphor/lasso.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/layer-mask.svg b/crates/ui-contract/icons/phosphor/layer-mask.svg new file mode 100644 index 000000000..8ca3a98a9 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/layer-mask.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/layout.svg b/crates/ui-contract/icons/phosphor/layout.svg new file mode 100644 index 000000000..482aa5e20 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/layout.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/lift-clip.svg b/crates/ui-contract/icons/phosphor/lift-clip.svg new file mode 100644 index 000000000..061d70562 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/lift-clip.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/line-segment.svg b/crates/ui-contract/icons/phosphor/line-segment.svg new file mode 100644 index 000000000..6fc78411c --- /dev/null +++ b/crates/ui-contract/icons/phosphor/line-segment.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/link-break.svg b/crates/ui-contract/icons/phosphor/link-break.svg new file mode 100644 index 000000000..4a902bd60 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/link-break.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/link-simple-horizontal.svg b/crates/ui-contract/icons/phosphor/link-simple-horizontal.svg new file mode 100644 index 000000000..11a636c5c --- /dev/null +++ b/crates/ui-contract/icons/phosphor/link-simple-horizontal.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/link.svg b/crates/ui-contract/icons/phosphor/link.svg new file mode 100644 index 000000000..e217ac2ab --- /dev/null +++ b/crates/ui-contract/icons/phosphor/link.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/list-bullets.svg b/crates/ui-contract/icons/phosphor/list-bullets.svg new file mode 100644 index 000000000..afc160090 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/list-bullets.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/list.svg b/crates/ui-contract/icons/phosphor/list.svg new file mode 100644 index 000000000..88254fb07 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/list.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/lock-open.svg b/crates/ui-contract/icons/phosphor/lock-open.svg new file mode 100644 index 000000000..97bbc0321 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/lock-open.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/lock.svg b/crates/ui-contract/icons/phosphor/lock.svg new file mode 100644 index 000000000..07201fd8a --- /dev/null +++ b/crates/ui-contract/icons/phosphor/lock.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/lollipop.svg b/crates/ui-contract/icons/phosphor/lollipop.svg new file mode 100644 index 000000000..636df95ff --- /dev/null +++ b/crates/ui-contract/icons/phosphor/lollipop.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/magic-wand.svg b/crates/ui-contract/icons/phosphor/magic-wand.svg new file mode 100644 index 000000000..d0af8a508 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/magic-wand.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/magnet.svg b/crates/ui-contract/icons/phosphor/magnet.svg new file mode 100644 index 000000000..b3af59804 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/magnet.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/magnifying-glass-plus.svg b/crates/ui-contract/icons/phosphor/magnifying-glass-plus.svg new file mode 100644 index 000000000..73f0bd545 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/magnifying-glass-plus.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/magnifying-glass.svg b/crates/ui-contract/icons/phosphor/magnifying-glass.svg new file mode 100644 index 000000000..2bdda5896 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/magnifying-glass.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/mark-in.svg b/crates/ui-contract/icons/phosphor/mark-in.svg new file mode 100644 index 000000000..2a233b86d --- /dev/null +++ b/crates/ui-contract/icons/phosphor/mark-in.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/mark-out.svg b/crates/ui-contract/icons/phosphor/mark-out.svg new file mode 100644 index 000000000..50e8b79a3 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/mark-out.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/marquee-column.svg b/crates/ui-contract/icons/phosphor/marquee-column.svg new file mode 100644 index 000000000..3842bf69c --- /dev/null +++ b/crates/ui-contract/icons/phosphor/marquee-column.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/marquee-row.svg b/crates/ui-contract/icons/phosphor/marquee-row.svg new file mode 100644 index 000000000..fe4b995cb --- /dev/null +++ b/crates/ui-contract/icons/phosphor/marquee-row.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/minus.svg b/crates/ui-contract/icons/phosphor/minus.svg new file mode 100644 index 000000000..f9b076327 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/minus.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/monitor.svg b/crates/ui-contract/icons/phosphor/monitor.svg new file mode 100644 index 000000000..e5d6d00e5 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/monitor.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/moon.svg b/crates/ui-contract/icons/phosphor/moon.svg new file mode 100644 index 000000000..20fca6341 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/moon.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/navigation-arrow.svg b/crates/ui-contract/icons/phosphor/navigation-arrow.svg new file mode 100644 index 000000000..0d78837ab --- /dev/null +++ b/crates/ui-contract/icons/phosphor/navigation-arrow.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/overwrite-clip.svg b/crates/ui-contract/icons/phosphor/overwrite-clip.svg new file mode 100644 index 000000000..56edec7aa --- /dev/null +++ b/crates/ui-contract/icons/phosphor/overwrite-clip.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/paint-brush.svg b/crates/ui-contract/icons/phosphor/paint-brush.svg new file mode 100644 index 000000000..6745c7113 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/paint-brush.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/paint-bucket.svg b/crates/ui-contract/icons/phosphor/paint-bucket.svg new file mode 100644 index 000000000..7bc10babc --- /dev/null +++ b/crates/ui-contract/icons/phosphor/paint-bucket.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/painting-symmetry.svg b/crates/ui-contract/icons/phosphor/painting-symmetry.svg new file mode 100644 index 000000000..cf3b7fd39 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/painting-symmetry.svg @@ -0,0 +1 @@ + diff --git a/crates/ui-contract/icons/phosphor/palette.svg b/crates/ui-contract/icons/phosphor/palette.svg new file mode 100644 index 000000000..5ae77da1c --- /dev/null +++ b/crates/ui-contract/icons/phosphor/palette.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/panel-right.svg b/crates/ui-contract/icons/phosphor/panel-right.svg new file mode 100644 index 000000000..bf7448fc3 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/panel-right.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/paragraph.svg b/crates/ui-contract/icons/phosphor/paragraph.svg new file mode 100644 index 000000000..56c5c5619 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/paragraph.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/pause.svg b/crates/ui-contract/icons/phosphor/pause.svg new file mode 100644 index 000000000..587cde6eb --- /dev/null +++ b/crates/ui-contract/icons/phosphor/pause.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/pen-add-anchor.svg b/crates/ui-contract/icons/phosphor/pen-add-anchor.svg new file mode 100644 index 000000000..9bde7ea25 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/pen-add-anchor.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/pen-curvature.svg b/crates/ui-contract/icons/phosphor/pen-curvature.svg new file mode 100644 index 000000000..160bb3969 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/pen-curvature.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/pen-delete-anchor.svg b/crates/ui-contract/icons/phosphor/pen-delete-anchor.svg new file mode 100644 index 000000000..4c5183601 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/pen-delete-anchor.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/pen-freeform.svg b/crates/ui-contract/icons/phosphor/pen-freeform.svg new file mode 100644 index 000000000..1dddc860e --- /dev/null +++ b/crates/ui-contract/icons/phosphor/pen-freeform.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/pen-nib.svg b/crates/ui-contract/icons/phosphor/pen-nib.svg new file mode 100644 index 000000000..18df31df1 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/pen-nib.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/pencil-simple.svg b/crates/ui-contract/icons/phosphor/pencil-simple.svg new file mode 100644 index 000000000..2641b0cc9 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/pencil-simple.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/perspective.svg b/crates/ui-contract/icons/phosphor/perspective.svg new file mode 100644 index 000000000..1593864b8 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/perspective.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/play.svg b/crates/ui-contract/icons/phosphor/play.svg new file mode 100644 index 000000000..162db543d --- /dev/null +++ b/crates/ui-contract/icons/phosphor/play.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/plus-square.svg b/crates/ui-contract/icons/phosphor/plus-square.svg new file mode 100644 index 000000000..47112c905 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/plus-square.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/plus.svg b/crates/ui-contract/icons/phosphor/plus.svg new file mode 100644 index 000000000..25ad5e322 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/plus.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/polygon.svg b/crates/ui-contract/icons/phosphor/polygon.svg new file mode 100644 index 000000000..5f49505b6 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/polygon.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/prohibit.svg b/crates/ui-contract/icons/phosphor/prohibit.svg new file mode 100644 index 000000000..eb8d2e3e9 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/prohibit.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/quick-selection.svg b/crates/ui-contract/icons/phosphor/quick-selection.svg new file mode 100644 index 000000000..7f29cc807 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/quick-selection.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/radio-button.svg b/crates/ui-contract/icons/phosphor/radio-button.svg new file mode 100644 index 000000000..0c0bb8957 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/radio-button.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/rectangle.svg b/crates/ui-contract/icons/phosphor/rectangle.svg new file mode 100644 index 000000000..2660e0b98 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/rectangle.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/route-curved.svg b/crates/ui-contract/icons/phosphor/route-curved.svg new file mode 100644 index 000000000..bb517f33d --- /dev/null +++ b/crates/ui-contract/icons/phosphor/route-curved.svg @@ -0,0 +1 @@ + diff --git a/crates/ui-contract/icons/phosphor/route-elbow.svg b/crates/ui-contract/icons/phosphor/route-elbow.svg new file mode 100644 index 000000000..3b729c231 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/route-elbow.svg @@ -0,0 +1 @@ + diff --git a/crates/ui-contract/icons/phosphor/route-straight.svg b/crates/ui-contract/icons/phosphor/route-straight.svg new file mode 100644 index 000000000..49e194b2b --- /dev/null +++ b/crates/ui-contract/icons/phosphor/route-straight.svg @@ -0,0 +1 @@ + diff --git a/crates/ui-contract/icons/phosphor/ruler.svg b/crates/ui-contract/icons/phosphor/ruler.svg new file mode 100644 index 000000000..839a58cac --- /dev/null +++ b/crates/ui-contract/icons/phosphor/ruler.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/scaling.svg b/crates/ui-contract/icons/phosphor/scaling.svg new file mode 100644 index 000000000..8dbbdb238 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/scaling.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/scan.svg b/crates/ui-contract/icons/phosphor/scan.svg new file mode 100644 index 000000000..419c68b2e --- /dev/null +++ b/crates/ui-contract/icons/phosphor/scan.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/scissors.svg b/crates/ui-contract/icons/phosphor/scissors.svg new file mode 100644 index 000000000..9800e6c8b --- /dev/null +++ b/crates/ui-contract/icons/phosphor/scissors.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/selection.svg b/crates/ui-contract/icons/phosphor/selection.svg new file mode 100644 index 000000000..de152123d --- /dev/null +++ b/crates/ui-contract/icons/phosphor/selection.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/skip-back.svg b/crates/ui-contract/icons/phosphor/skip-back.svg new file mode 100644 index 000000000..bd08633d2 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/skip-back.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/skip-forward.svg b/crates/ui-contract/icons/phosphor/skip-forward.svg new file mode 100644 index 000000000..5715e6c78 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/skip-forward.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/slice-select.svg b/crates/ui-contract/icons/phosphor/slice-select.svg new file mode 100644 index 000000000..d7628c17c --- /dev/null +++ b/crates/ui-contract/icons/phosphor/slice-select.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/sliders-horizontal.svg b/crates/ui-contract/icons/phosphor/sliders-horizontal.svg new file mode 100644 index 000000000..4aa2aa343 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/sliders-horizontal.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/sort-ascending.svg b/crates/ui-contract/icons/phosphor/sort-ascending.svg new file mode 100644 index 000000000..6ba80baff --- /dev/null +++ b/crates/ui-contract/icons/phosphor/sort-ascending.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/sort-descending.svg b/crates/ui-contract/icons/phosphor/sort-descending.svg new file mode 100644 index 000000000..e14a9ba23 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/sort-descending.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/sparkle.svg b/crates/ui-contract/icons/phosphor/sparkle.svg new file mode 100644 index 000000000..43639cc77 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/sparkle.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/speaker-simple-slash.svg b/crates/ui-contract/icons/phosphor/speaker-simple-slash.svg new file mode 100644 index 000000000..ef448e19f --- /dev/null +++ b/crates/ui-contract/icons/phosphor/speaker-simple-slash.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/square-dashed-mouse-pointer.svg b/crates/ui-contract/icons/phosphor/square-dashed-mouse-pointer.svg new file mode 100644 index 000000000..fb8470016 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/square-dashed-mouse-pointer.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/square-split-horizontal.svg b/crates/ui-contract/icons/phosphor/square-split-horizontal.svg new file mode 100644 index 000000000..3527ca733 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/square-split-horizontal.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/square-split-vertical.svg b/crates/ui-contract/icons/phosphor/square-split-vertical.svg new file mode 100644 index 000000000..86e9b6088 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/square-split-vertical.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/square.svg b/crates/ui-contract/icons/phosphor/square.svg new file mode 100644 index 000000000..043710bb3 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/square.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/squares-four.svg b/crates/ui-contract/icons/phosphor/squares-four.svg new file mode 100644 index 000000000..64789418c --- /dev/null +++ b/crates/ui-contract/icons/phosphor/squares-four.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/stack.svg b/crates/ui-contract/icons/phosphor/stack.svg new file mode 100644 index 000000000..53259174c --- /dev/null +++ b/crates/ui-contract/icons/phosphor/stack.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/stamp.svg b/crates/ui-contract/icons/phosphor/stamp.svg new file mode 100644 index 000000000..249b3a780 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/stamp.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/star-filled.svg b/crates/ui-contract/icons/phosphor/star-filled.svg new file mode 100644 index 000000000..6a74ee50e --- /dev/null +++ b/crates/ui-contract/icons/phosphor/star-filled.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/star.svg b/crates/ui-contract/icons/phosphor/star.svg new file mode 100644 index 000000000..69a5b5b2b --- /dev/null +++ b/crates/ui-contract/icons/phosphor/star.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/stroke-align-center.svg b/crates/ui-contract/icons/phosphor/stroke-align-center.svg new file mode 100644 index 000000000..7a8c34bee --- /dev/null +++ b/crates/ui-contract/icons/phosphor/stroke-align-center.svg @@ -0,0 +1 @@ + diff --git a/crates/ui-contract/icons/phosphor/stroke-align-inside.svg b/crates/ui-contract/icons/phosphor/stroke-align-inside.svg new file mode 100644 index 000000000..09c1be3f6 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/stroke-align-inside.svg @@ -0,0 +1 @@ + diff --git a/crates/ui-contract/icons/phosphor/stroke-align-outside.svg b/crates/ui-contract/icons/phosphor/stroke-align-outside.svg new file mode 100644 index 000000000..20975bee9 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/stroke-align-outside.svg @@ -0,0 +1 @@ + diff --git a/crates/ui-contract/icons/phosphor/stroke-cap-butt.svg b/crates/ui-contract/icons/phosphor/stroke-cap-butt.svg new file mode 100644 index 000000000..0c8eb40a8 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/stroke-cap-butt.svg @@ -0,0 +1 @@ + diff --git a/crates/ui-contract/icons/phosphor/stroke-cap-round.svg b/crates/ui-contract/icons/phosphor/stroke-cap-round.svg new file mode 100644 index 000000000..5b7ddff8a --- /dev/null +++ b/crates/ui-contract/icons/phosphor/stroke-cap-round.svg @@ -0,0 +1 @@ + diff --git a/crates/ui-contract/icons/phosphor/stroke-cap-square.svg b/crates/ui-contract/icons/phosphor/stroke-cap-square.svg new file mode 100644 index 000000000..4917292fd --- /dev/null +++ b/crates/ui-contract/icons/phosphor/stroke-cap-square.svg @@ -0,0 +1 @@ + diff --git a/crates/ui-contract/icons/phosphor/stroke-join-bevel.svg b/crates/ui-contract/icons/phosphor/stroke-join-bevel.svg new file mode 100644 index 000000000..d28bf02d5 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/stroke-join-bevel.svg @@ -0,0 +1 @@ + diff --git a/crates/ui-contract/icons/phosphor/stroke-join-miter.svg b/crates/ui-contract/icons/phosphor/stroke-join-miter.svg new file mode 100644 index 000000000..0329f2cd1 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/stroke-join-miter.svg @@ -0,0 +1 @@ + diff --git a/crates/ui-contract/icons/phosphor/stroke-join-round.svg b/crates/ui-contract/icons/phosphor/stroke-join-round.svg new file mode 100644 index 000000000..d8058551d --- /dev/null +++ b/crates/ui-contract/icons/phosphor/stroke-join-round.svg @@ -0,0 +1 @@ + diff --git a/crates/ui-contract/icons/phosphor/subtract-square.svg b/crates/ui-contract/icons/phosphor/subtract-square.svg new file mode 100644 index 000000000..5a30c0ed8 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/subtract-square.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/sun.svg b/crates/ui-contract/icons/phosphor/sun.svg new file mode 100644 index 000000000..2a97d0169 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/sun.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/swap.svg b/crates/ui-contract/icons/phosphor/swap.svg new file mode 100644 index 000000000..940fe80e9 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/swap.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/swatches.svg b/crates/ui-contract/icons/phosphor/swatches.svg new file mode 100644 index 000000000..e9068a0f4 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/swatches.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/symmetry-diagonal.svg b/crates/ui-contract/icons/phosphor/symmetry-diagonal.svg new file mode 100644 index 000000000..51fff7b9f --- /dev/null +++ b/crates/ui-contract/icons/phosphor/symmetry-diagonal.svg @@ -0,0 +1 @@ + diff --git a/crates/ui-contract/icons/phosphor/symmetry-dual.svg b/crates/ui-contract/icons/phosphor/symmetry-dual.svg new file mode 100644 index 000000000..88d274946 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/symmetry-dual.svg @@ -0,0 +1 @@ + diff --git a/crates/ui-contract/icons/phosphor/symmetry-horizontal.svg b/crates/ui-contract/icons/phosphor/symmetry-horizontal.svg new file mode 100644 index 000000000..045feb3e3 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/symmetry-horizontal.svg @@ -0,0 +1 @@ + diff --git a/crates/ui-contract/icons/phosphor/symmetry-vertical.svg b/crates/ui-contract/icons/phosphor/symmetry-vertical.svg new file mode 100644 index 000000000..a4314ac3f --- /dev/null +++ b/crates/ui-contract/icons/phosphor/symmetry-vertical.svg @@ -0,0 +1 @@ + diff --git a/crates/ui-contract/icons/phosphor/sync-lock.svg b/crates/ui-contract/icons/phosphor/sync-lock.svg new file mode 100644 index 000000000..8a6059e2d --- /dev/null +++ b/crates/ui-contract/icons/phosphor/sync-lock.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/text-align-center.svg b/crates/ui-contract/icons/phosphor/text-align-center.svg new file mode 100644 index 000000000..dc3d9def0 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/text-align-center.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/text-align-justify.svg b/crates/ui-contract/icons/phosphor/text-align-justify.svg new file mode 100644 index 000000000..97f3dd091 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/text-align-justify.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/text-align-left.svg b/crates/ui-contract/icons/phosphor/text-align-left.svg new file mode 100644 index 000000000..2a0e54ebd --- /dev/null +++ b/crates/ui-contract/icons/phosphor/text-align-left.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/text-align-right.svg b/crates/ui-contract/icons/phosphor/text-align-right.svg new file mode 100644 index 000000000..5682c43dc --- /dev/null +++ b/crates/ui-contract/icons/phosphor/text-align-right.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/text-b.svg b/crates/ui-contract/icons/phosphor/text-b.svg new file mode 100644 index 000000000..c46b062cc --- /dev/null +++ b/crates/ui-contract/icons/phosphor/text-b.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/text-italic.svg b/crates/ui-contract/icons/phosphor/text-italic.svg new file mode 100644 index 000000000..a737f2dc2 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/text-italic.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/text-strikethrough.svg b/crates/ui-contract/icons/phosphor/text-strikethrough.svg new file mode 100644 index 000000000..6bc3debf1 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/text-strikethrough.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/text-t.svg b/crates/ui-contract/icons/phosphor/text-t.svg new file mode 100644 index 000000000..3d23f5062 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/text-t.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/text-underline.svg b/crates/ui-contract/icons/phosphor/text-underline.svg new file mode 100644 index 000000000..9aa328dcd --- /dev/null +++ b/crates/ui-contract/icons/phosphor/text-underline.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/text-warp.svg b/crates/ui-contract/icons/phosphor/text-warp.svg new file mode 100644 index 000000000..d85ca0bfe --- /dev/null +++ b/crates/ui-contract/icons/phosphor/text-warp.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/thumbs-down.svg b/crates/ui-contract/icons/phosphor/thumbs-down.svg new file mode 100644 index 000000000..c2d170c8b --- /dev/null +++ b/crates/ui-contract/icons/phosphor/thumbs-down.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/thumbs-up.svg b/crates/ui-contract/icons/phosphor/thumbs-up.svg new file mode 100644 index 000000000..6f2ef57fd --- /dev/null +++ b/crates/ui-contract/icons/phosphor/thumbs-up.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/toggle-left.svg b/crates/ui-contract/icons/phosphor/toggle-left.svg new file mode 100644 index 000000000..d47fc73d6 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/toggle-left.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/toggle-right.svg b/crates/ui-contract/icons/phosphor/toggle-right.svg new file mode 100644 index 000000000..4c880030f --- /dev/null +++ b/crates/ui-contract/icons/phosphor/toggle-right.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/trash.svg b/crates/ui-contract/icons/phosphor/trash.svg new file mode 100644 index 000000000..9f963931a --- /dev/null +++ b/crates/ui-contract/icons/phosphor/trash.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/triangle-right.svg b/crates/ui-contract/icons/phosphor/triangle-right.svg new file mode 100644 index 000000000..9f0c4be22 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/triangle-right.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/triangle.svg b/crates/ui-contract/icons/phosphor/triangle.svg new file mode 100644 index 000000000..cb2b49d77 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/triangle.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/type-mask-vertical.svg b/crates/ui-contract/icons/phosphor/type-mask-vertical.svg new file mode 100644 index 000000000..c937995ad --- /dev/null +++ b/crates/ui-contract/icons/phosphor/type-mask-vertical.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/type-mask.svg b/crates/ui-contract/icons/phosphor/type-mask.svg new file mode 100644 index 000000000..66b21d554 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/type-mask.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/warning-circle.svg b/crates/ui-contract/icons/phosphor/warning-circle.svg new file mode 100644 index 000000000..fbfeb9eff --- /dev/null +++ b/crates/ui-contract/icons/phosphor/warning-circle.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/warning-diamond.svg b/crates/ui-contract/icons/phosphor/warning-diamond.svg new file mode 100644 index 000000000..e3bf004ee --- /dev/null +++ b/crates/ui-contract/icons/phosphor/warning-diamond.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/warning.svg b/crates/ui-contract/icons/phosphor/warning.svg new file mode 100644 index 000000000..1915993bb --- /dev/null +++ b/crates/ui-contract/icons/phosphor/warning.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/x-circle.svg b/crates/ui-contract/icons/phosphor/x-circle.svg new file mode 100644 index 000000000..672fb6926 --- /dev/null +++ b/crates/ui-contract/icons/phosphor/x-circle.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/x-square.svg b/crates/ui-contract/icons/phosphor/x-square.svg new file mode 100644 index 000000000..ab5b1c4ed --- /dev/null +++ b/crates/ui-contract/icons/phosphor/x-square.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/phosphor/x.svg b/crates/ui-contract/icons/phosphor/x.svg new file mode 100644 index 000000000..2ee41d11c --- /dev/null +++ b/crates/ui-contract/icons/phosphor/x.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/LICENSE b/crates/ui-contract/icons/tabler/LICENSE new file mode 100644 index 000000000..3e82379da --- /dev/null +++ b/crates/ui-contract/icons/tabler/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2020-2026 Paweł Kuna + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/crates/ui-contract/icons/tabler/adjustments-horizontal.svg b/crates/ui-contract/icons/tabler/adjustments-horizontal.svg new file mode 100644 index 000000000..63c96228d --- /dev/null +++ b/crates/ui-contract/icons/tabler/adjustments-horizontal.svg @@ -0,0 +1,23 @@ + + + + + + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/alert-circle.svg b/crates/ui-contract/icons/tabler/alert-circle.svg new file mode 100644 index 000000000..94d2396d6 --- /dev/null +++ b/crates/ui-contract/icons/tabler/alert-circle.svg @@ -0,0 +1,21 @@ + + + + + + diff --git a/crates/ui-contract/icons/tabler/alert-triangle.svg b/crates/ui-contract/icons/tabler/alert-triangle.svg new file mode 100644 index 000000000..3caf0c6f7 --- /dev/null +++ b/crates/ui-contract/icons/tabler/alert-triangle.svg @@ -0,0 +1,21 @@ + + + + + + diff --git a/crates/ui-contract/icons/tabler/align-center.svg b/crates/ui-contract/icons/tabler/align-center.svg new file mode 100644 index 000000000..fefe3acd2 --- /dev/null +++ b/crates/ui-contract/icons/tabler/align-center.svg @@ -0,0 +1,17 @@ + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/align-justified.svg b/crates/ui-contract/icons/tabler/align-justified.svg new file mode 100644 index 000000000..0bb9a8d2d --- /dev/null +++ b/crates/ui-contract/icons/tabler/align-justified.svg @@ -0,0 +1,17 @@ + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/align-left.svg b/crates/ui-contract/icons/tabler/align-left.svg new file mode 100644 index 000000000..7565c79dd --- /dev/null +++ b/crates/ui-contract/icons/tabler/align-left.svg @@ -0,0 +1,17 @@ + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/align-right.svg b/crates/ui-contract/icons/tabler/align-right.svg new file mode 100644 index 000000000..420931fa8 --- /dev/null +++ b/crates/ui-contract/icons/tabler/align-right.svg @@ -0,0 +1,17 @@ + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/app-window.svg b/crates/ui-contract/icons/tabler/app-window.svg new file mode 100644 index 000000000..d0c7518c5 --- /dev/null +++ b/crates/ui-contract/icons/tabler/app-window.svg @@ -0,0 +1,17 @@ + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/arrow-back-up.svg b/crates/ui-contract/icons/tabler/arrow-back-up.svg new file mode 100644 index 000000000..8febf9bbf --- /dev/null +++ b/crates/ui-contract/icons/tabler/arrow-back-up.svg @@ -0,0 +1,20 @@ + + + + + diff --git a/crates/ui-contract/icons/tabler/arrow-forward-up.svg b/crates/ui-contract/icons/tabler/arrow-forward-up.svg new file mode 100644 index 000000000..a785b1e21 --- /dev/null +++ b/crates/ui-contract/icons/tabler/arrow-forward-up.svg @@ -0,0 +1,20 @@ + + + + + diff --git a/crates/ui-contract/icons/tabler/arrow-left.svg b/crates/ui-contract/icons/tabler/arrow-left.svg new file mode 100644 index 000000000..4e22df038 --- /dev/null +++ b/crates/ui-contract/icons/tabler/arrow-left.svg @@ -0,0 +1,17 @@ + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/arrows-diagonal.svg b/crates/ui-contract/icons/tabler/arrows-diagonal.svg new file mode 100644 index 000000000..58f96cdc2 --- /dev/null +++ b/crates/ui-contract/icons/tabler/arrows-diagonal.svg @@ -0,0 +1,18 @@ + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/arrows-down-up.svg b/crates/ui-contract/icons/tabler/arrows-down-up.svg new file mode 100644 index 000000000..15e49d224 --- /dev/null +++ b/crates/ui-contract/icons/tabler/arrows-down-up.svg @@ -0,0 +1,22 @@ + + + + + + + diff --git a/crates/ui-contract/icons/tabler/arrows-exchange.svg b/crates/ui-contract/icons/tabler/arrows-exchange.svg new file mode 100644 index 000000000..90113e107 --- /dev/null +++ b/crates/ui-contract/icons/tabler/arrows-exchange.svg @@ -0,0 +1,20 @@ + + + + + diff --git a/crates/ui-contract/icons/tabler/arrows-move.svg b/crates/ui-contract/icons/tabler/arrows-move.svg new file mode 100644 index 000000000..bdda4f871 --- /dev/null +++ b/crates/ui-contract/icons/tabler/arrows-move.svg @@ -0,0 +1,26 @@ + + + + + + + + + + + diff --git a/crates/ui-contract/icons/tabler/arrows-split.svg b/crates/ui-contract/icons/tabler/arrows-split.svg new file mode 100644 index 000000000..2f9796a94 --- /dev/null +++ b/crates/ui-contract/icons/tabler/arrows-split.svg @@ -0,0 +1,18 @@ + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/artboard.svg b/crates/ui-contract/icons/tabler/artboard.svg new file mode 100644 index 000000000..9ecfc9454 --- /dev/null +++ b/crates/ui-contract/icons/tabler/artboard.svg @@ -0,0 +1,23 @@ + + + + + + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/ban.svg b/crates/ui-contract/icons/tabler/ban.svg new file mode 100644 index 000000000..44d28f89a --- /dev/null +++ b/crates/ui-contract/icons/tabler/ban.svg @@ -0,0 +1,16 @@ + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/bandage.svg b/crates/ui-contract/icons/tabler/bandage.svg new file mode 100644 index 000000000..a5d414c4a --- /dev/null +++ b/crates/ui-contract/icons/tabler/bandage.svg @@ -0,0 +1,19 @@ + + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/blend-mode.svg b/crates/ui-contract/icons/tabler/blend-mode.svg new file mode 100644 index 000000000..307aa47e0 --- /dev/null +++ b/crates/ui-contract/icons/tabler/blend-mode.svg @@ -0,0 +1,16 @@ + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/bold.svg b/crates/ui-contract/icons/tabler/bold.svg new file mode 100644 index 000000000..e91efdc6a --- /dev/null +++ b/crates/ui-contract/icons/tabler/bold.svg @@ -0,0 +1,16 @@ + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/bookmark.svg b/crates/ui-contract/icons/tabler/bookmark.svg new file mode 100644 index 000000000..5cfc6e471 --- /dev/null +++ b/crates/ui-contract/icons/tabler/bookmark.svg @@ -0,0 +1,15 @@ + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/brush.svg b/crates/ui-contract/icons/tabler/brush.svg new file mode 100644 index 000000000..e3d14f80b --- /dev/null +++ b/crates/ui-contract/icons/tabler/brush.svg @@ -0,0 +1,22 @@ + + + + + + + diff --git a/crates/ui-contract/icons/tabler/bucket-droplet.svg b/crates/ui-contract/icons/tabler/bucket-droplet.svg new file mode 100644 index 000000000..5d0d546fc --- /dev/null +++ b/crates/ui-contract/icons/tabler/bucket-droplet.svg @@ -0,0 +1,17 @@ + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/calendar.svg b/crates/ui-contract/icons/tabler/calendar.svg new file mode 100644 index 000000000..cf31525af --- /dev/null +++ b/crates/ui-contract/icons/tabler/calendar.svg @@ -0,0 +1,20 @@ + + + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/chart-line.svg b/crates/ui-contract/icons/tabler/chart-line.svg new file mode 100644 index 000000000..c75e61a80 --- /dev/null +++ b/crates/ui-contract/icons/tabler/chart-line.svg @@ -0,0 +1,16 @@ + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/check.svg b/crates/ui-contract/icons/tabler/check.svg new file mode 100644 index 000000000..8457c5561 --- /dev/null +++ b/crates/ui-contract/icons/tabler/check.svg @@ -0,0 +1,19 @@ + + + + diff --git a/crates/ui-contract/icons/tabler/chevron-down.svg b/crates/ui-contract/icons/tabler/chevron-down.svg new file mode 100644 index 000000000..40a36b132 --- /dev/null +++ b/crates/ui-contract/icons/tabler/chevron-down.svg @@ -0,0 +1,19 @@ + + + + diff --git a/crates/ui-contract/icons/tabler/chevron-left.svg b/crates/ui-contract/icons/tabler/chevron-left.svg new file mode 100644 index 000000000..9daf46694 --- /dev/null +++ b/crates/ui-contract/icons/tabler/chevron-left.svg @@ -0,0 +1,19 @@ + + + + diff --git a/crates/ui-contract/icons/tabler/chevron-right.svg b/crates/ui-contract/icons/tabler/chevron-right.svg new file mode 100644 index 000000000..91195257d --- /dev/null +++ b/crates/ui-contract/icons/tabler/chevron-right.svg @@ -0,0 +1,19 @@ + + + + diff --git a/crates/ui-contract/icons/tabler/chevron-up.svg b/crates/ui-contract/icons/tabler/chevron-up.svg new file mode 100644 index 000000000..cf582c5d9 --- /dev/null +++ b/crates/ui-contract/icons/tabler/chevron-up.svg @@ -0,0 +1,19 @@ + + + + diff --git a/crates/ui-contract/icons/tabler/chevrons-left.svg b/crates/ui-contract/icons/tabler/chevrons-left.svg new file mode 100644 index 000000000..ea405955f --- /dev/null +++ b/crates/ui-contract/icons/tabler/chevrons-left.svg @@ -0,0 +1,20 @@ + + + + + diff --git a/crates/ui-contract/icons/tabler/chevrons-right.svg b/crates/ui-contract/icons/tabler/chevrons-right.svg new file mode 100644 index 000000000..16e5326a6 --- /dev/null +++ b/crates/ui-contract/icons/tabler/chevrons-right.svg @@ -0,0 +1,20 @@ + + + + + diff --git a/crates/ui-contract/icons/tabler/circle-check.svg b/crates/ui-contract/icons/tabler/circle-check.svg new file mode 100644 index 000000000..7b794b954 --- /dev/null +++ b/crates/ui-contract/icons/tabler/circle-check.svg @@ -0,0 +1,20 @@ + + + + + diff --git a/crates/ui-contract/icons/tabler/circle-dashed.svg b/crates/ui-contract/icons/tabler/circle-dashed.svg new file mode 100644 index 000000000..4151e7f57 --- /dev/null +++ b/crates/ui-contract/icons/tabler/circle-dashed.svg @@ -0,0 +1,22 @@ + + + + + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/circle-dot.svg b/crates/ui-contract/icons/tabler/circle-dot.svg new file mode 100644 index 000000000..9f67e39bb --- /dev/null +++ b/crates/ui-contract/icons/tabler/circle-dot.svg @@ -0,0 +1,16 @@ + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/circle-x.svg b/crates/ui-contract/icons/tabler/circle-x.svg new file mode 100644 index 000000000..286c54d44 --- /dev/null +++ b/crates/ui-contract/icons/tabler/circle-x.svg @@ -0,0 +1,16 @@ + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/circle.svg b/crates/ui-contract/icons/tabler/circle.svg new file mode 100644 index 000000000..e3f3c7c6d --- /dev/null +++ b/crates/ui-contract/icons/tabler/circle.svg @@ -0,0 +1,19 @@ + + + + diff --git a/crates/ui-contract/icons/tabler/clock.svg b/crates/ui-contract/icons/tabler/clock.svg new file mode 100644 index 000000000..905df5ecb --- /dev/null +++ b/crates/ui-contract/icons/tabler/clock.svg @@ -0,0 +1,16 @@ + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/cloud.svg b/crates/ui-contract/icons/tabler/cloud.svg new file mode 100644 index 000000000..81cc0efa5 --- /dev/null +++ b/crates/ui-contract/icons/tabler/cloud.svg @@ -0,0 +1,15 @@ + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/color-picker.svg b/crates/ui-contract/icons/tabler/color-picker.svg new file mode 100644 index 000000000..3fce6c890 --- /dev/null +++ b/crates/ui-contract/icons/tabler/color-picker.svg @@ -0,0 +1,20 @@ + + + + + diff --git a/crates/ui-contract/icons/tabler/color-swatch.svg b/crates/ui-contract/icons/tabler/color-swatch.svg new file mode 100644 index 000000000..6c86b4831 --- /dev/null +++ b/crates/ui-contract/icons/tabler/color-swatch.svg @@ -0,0 +1,18 @@ + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/compass.svg b/crates/ui-contract/icons/tabler/compass.svg new file mode 100644 index 000000000..19addb787 --- /dev/null +++ b/crates/ui-contract/icons/tabler/compass.svg @@ -0,0 +1,20 @@ + + + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/contrast-2.svg b/crates/ui-contract/icons/tabler/contrast-2.svg new file mode 100644 index 000000000..5f39f4b9f --- /dev/null +++ b/crates/ui-contract/icons/tabler/contrast-2.svg @@ -0,0 +1,16 @@ + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/copy.svg b/crates/ui-contract/icons/tabler/copy.svg new file mode 100644 index 000000000..155727277 --- /dev/null +++ b/crates/ui-contract/icons/tabler/copy.svg @@ -0,0 +1,20 @@ + + + + + diff --git a/crates/ui-contract/icons/tabler/crop.svg b/crates/ui-contract/icons/tabler/crop.svg new file mode 100644 index 000000000..b16cb6782 --- /dev/null +++ b/crates/ui-contract/icons/tabler/crop.svg @@ -0,0 +1,16 @@ + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/crosshair.svg b/crates/ui-contract/icons/tabler/crosshair.svg new file mode 100644 index 000000000..638cac100 --- /dev/null +++ b/crates/ui-contract/icons/tabler/crosshair.svg @@ -0,0 +1,20 @@ + + + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/cube.svg b/crates/ui-contract/icons/tabler/cube.svg new file mode 100644 index 000000000..2f87eb799 --- /dev/null +++ b/crates/ui-contract/icons/tabler/cube.svg @@ -0,0 +1,18 @@ + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/cursor-text.svg b/crates/ui-contract/icons/tabler/cursor-text.svg new file mode 100644 index 000000000..50bc22a23 --- /dev/null +++ b/crates/ui-contract/icons/tabler/cursor-text.svg @@ -0,0 +1,17 @@ + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/device-desktop.svg b/crates/ui-contract/icons/tabler/device-desktop.svg new file mode 100644 index 000000000..20a675c49 --- /dev/null +++ b/crates/ui-contract/icons/tabler/device-desktop.svg @@ -0,0 +1,18 @@ + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/device-floppy.svg b/crates/ui-contract/icons/tabler/device-floppy.svg new file mode 100644 index 000000000..46cda8370 --- /dev/null +++ b/crates/ui-contract/icons/tabler/device-floppy.svg @@ -0,0 +1,21 @@ + + + + + + diff --git a/crates/ui-contract/icons/tabler/diamond.svg b/crates/ui-contract/icons/tabler/diamond.svg new file mode 100644 index 000000000..08bc139aa --- /dev/null +++ b/crates/ui-contract/icons/tabler/diamond.svg @@ -0,0 +1,16 @@ + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/dots.svg b/crates/ui-contract/icons/tabler/dots.svg new file mode 100644 index 000000000..087e7355a --- /dev/null +++ b/crates/ui-contract/icons/tabler/dots.svg @@ -0,0 +1,21 @@ + + + + + + diff --git a/crates/ui-contract/icons/tabler/droplet.svg b/crates/ui-contract/icons/tabler/droplet.svg new file mode 100644 index 000000000..1b087d615 --- /dev/null +++ b/crates/ui-contract/icons/tabler/droplet.svg @@ -0,0 +1,15 @@ + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/eraser.svg b/crates/ui-contract/icons/tabler/eraser.svg new file mode 100644 index 000000000..fdfd80014 --- /dev/null +++ b/crates/ui-contract/icons/tabler/eraser.svg @@ -0,0 +1,20 @@ + + + + + diff --git a/crates/ui-contract/icons/tabler/external-link.svg b/crates/ui-contract/icons/tabler/external-link.svg new file mode 100644 index 000000000..c9bd21fd3 --- /dev/null +++ b/crates/ui-contract/icons/tabler/external-link.svg @@ -0,0 +1,21 @@ + + + + + + diff --git a/crates/ui-contract/icons/tabler/eye-off.svg b/crates/ui-contract/icons/tabler/eye-off.svg new file mode 100644 index 000000000..2002e01e0 --- /dev/null +++ b/crates/ui-contract/icons/tabler/eye-off.svg @@ -0,0 +1,21 @@ + + + + + + diff --git a/crates/ui-contract/icons/tabler/eye.svg b/crates/ui-contract/icons/tabler/eye.svg new file mode 100644 index 000000000..5a0a21ddc --- /dev/null +++ b/crates/ui-contract/icons/tabler/eye.svg @@ -0,0 +1,20 @@ + + + + + diff --git a/crates/ui-contract/icons/tabler/file-plus.svg b/crates/ui-contract/icons/tabler/file-plus.svg new file mode 100644 index 000000000..de68a7f06 --- /dev/null +++ b/crates/ui-contract/icons/tabler/file-plus.svg @@ -0,0 +1,22 @@ + + + + + + + diff --git a/crates/ui-contract/icons/tabler/file.svg b/crates/ui-contract/icons/tabler/file.svg new file mode 100644 index 000000000..73df9841e --- /dev/null +++ b/crates/ui-contract/icons/tabler/file.svg @@ -0,0 +1,16 @@ + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/filter.svg b/crates/ui-contract/icons/tabler/filter.svg new file mode 100644 index 000000000..f8c0eaee0 --- /dev/null +++ b/crates/ui-contract/icons/tabler/filter.svg @@ -0,0 +1,15 @@ + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/flag.svg b/crates/ui-contract/icons/tabler/flag.svg new file mode 100644 index 000000000..28e1393b0 --- /dev/null +++ b/crates/ui-contract/icons/tabler/flag.svg @@ -0,0 +1,16 @@ + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/flame.svg b/crates/ui-contract/icons/tabler/flame.svg new file mode 100644 index 000000000..039ef2e53 --- /dev/null +++ b/crates/ui-contract/icons/tabler/flame.svg @@ -0,0 +1,15 @@ + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/folder-open.svg b/crates/ui-contract/icons/tabler/folder-open.svg new file mode 100644 index 000000000..e7255d0e6 --- /dev/null +++ b/crates/ui-contract/icons/tabler/folder-open.svg @@ -0,0 +1,19 @@ + + + + diff --git a/crates/ui-contract/icons/tabler/folder-plus.svg b/crates/ui-contract/icons/tabler/folder-plus.svg new file mode 100644 index 000000000..ac2c78cee --- /dev/null +++ b/crates/ui-contract/icons/tabler/folder-plus.svg @@ -0,0 +1,17 @@ + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/folder.svg b/crates/ui-contract/icons/tabler/folder.svg new file mode 100644 index 000000000..8f71ca64b --- /dev/null +++ b/crates/ui-contract/icons/tabler/folder.svg @@ -0,0 +1,15 @@ + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/gauge.svg b/crates/ui-contract/icons/tabler/gauge.svg new file mode 100644 index 000000000..22ccc6976 --- /dev/null +++ b/crates/ui-contract/icons/tabler/gauge.svg @@ -0,0 +1,18 @@ + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/grid-3x3.svg b/crates/ui-contract/icons/tabler/grid-3x3.svg new file mode 100644 index 000000000..8007a7df5 --- /dev/null +++ b/crates/ui-contract/icons/tabler/grid-3x3.svg @@ -0,0 +1,18 @@ + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/hand-finger.svg b/crates/ui-contract/icons/tabler/hand-finger.svg new file mode 100644 index 000000000..6dfff7a23 --- /dev/null +++ b/crates/ui-contract/icons/tabler/hand-finger.svg @@ -0,0 +1,18 @@ + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/hand-stop.svg b/crates/ui-contract/icons/tabler/hand-stop.svg new file mode 100644 index 000000000..6721da0c2 --- /dev/null +++ b/crates/ui-contract/icons/tabler/hand-stop.svg @@ -0,0 +1,22 @@ + + + + + + + diff --git a/crates/ui-contract/icons/tabler/headphones.svg b/crates/ui-contract/icons/tabler/headphones.svg new file mode 100644 index 000000000..debb3402c --- /dev/null +++ b/crates/ui-contract/icons/tabler/headphones.svg @@ -0,0 +1,17 @@ + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/home.svg b/crates/ui-contract/icons/tabler/home.svg new file mode 100644 index 000000000..3d738af7f --- /dev/null +++ b/crates/ui-contract/icons/tabler/home.svg @@ -0,0 +1,17 @@ + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/info-circle.svg b/crates/ui-contract/icons/tabler/info-circle.svg new file mode 100644 index 000000000..bfa465ea1 --- /dev/null +++ b/crates/ui-contract/icons/tabler/info-circle.svg @@ -0,0 +1,21 @@ + + + + + + diff --git a/crates/ui-contract/icons/tabler/italic.svg b/crates/ui-contract/icons/tabler/italic.svg new file mode 100644 index 000000000..b21ae26f2 --- /dev/null +++ b/crates/ui-contract/icons/tabler/italic.svg @@ -0,0 +1,17 @@ + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/keyboard.svg b/crates/ui-contract/icons/tabler/keyboard.svg new file mode 100644 index 000000000..a66ecb277 --- /dev/null +++ b/crates/ui-contract/icons/tabler/keyboard.svg @@ -0,0 +1,22 @@ + + + + + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/lasso.svg b/crates/ui-contract/icons/tabler/lasso.svg new file mode 100644 index 000000000..75dac374d --- /dev/null +++ b/crates/ui-contract/icons/tabler/lasso.svg @@ -0,0 +1,17 @@ + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/layers-intersect.svg b/crates/ui-contract/icons/tabler/layers-intersect.svg new file mode 100644 index 000000000..2402520c3 --- /dev/null +++ b/crates/ui-contract/icons/tabler/layers-intersect.svg @@ -0,0 +1,16 @@ + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/layers-subtract.svg b/crates/ui-contract/icons/tabler/layers-subtract.svg new file mode 100644 index 000000000..b2b97dc44 --- /dev/null +++ b/crates/ui-contract/icons/tabler/layers-subtract.svg @@ -0,0 +1,20 @@ + + + + + diff --git a/crates/ui-contract/icons/tabler/layout-2.svg b/crates/ui-contract/icons/tabler/layout-2.svg new file mode 100644 index 000000000..e43ecf74c --- /dev/null +++ b/crates/ui-contract/icons/tabler/layout-2.svg @@ -0,0 +1,18 @@ + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/layout-align-bottom.svg b/crates/ui-contract/icons/tabler/layout-align-bottom.svg new file mode 100644 index 000000000..5f2951c8d --- /dev/null +++ b/crates/ui-contract/icons/tabler/layout-align-bottom.svg @@ -0,0 +1,16 @@ + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/layout-align-center.svg b/crates/ui-contract/icons/tabler/layout-align-center.svg new file mode 100644 index 000000000..8ec56d612 --- /dev/null +++ b/crates/ui-contract/icons/tabler/layout-align-center.svg @@ -0,0 +1,17 @@ + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/layout-align-left.svg b/crates/ui-contract/icons/tabler/layout-align-left.svg new file mode 100644 index 000000000..34c69fdaf --- /dev/null +++ b/crates/ui-contract/icons/tabler/layout-align-left.svg @@ -0,0 +1,16 @@ + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/layout-align-middle.svg b/crates/ui-contract/icons/tabler/layout-align-middle.svg new file mode 100644 index 000000000..70c46279b --- /dev/null +++ b/crates/ui-contract/icons/tabler/layout-align-middle.svg @@ -0,0 +1,17 @@ + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/layout-align-right.svg b/crates/ui-contract/icons/tabler/layout-align-right.svg new file mode 100644 index 000000000..bd067b544 --- /dev/null +++ b/crates/ui-contract/icons/tabler/layout-align-right.svg @@ -0,0 +1,16 @@ + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/layout-align-top.svg b/crates/ui-contract/icons/tabler/layout-align-top.svg new file mode 100644 index 000000000..f4811a927 --- /dev/null +++ b/crates/ui-contract/icons/tabler/layout-align-top.svg @@ -0,0 +1,16 @@ + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/layout-grid.svg b/crates/ui-contract/icons/tabler/layout-grid.svg new file mode 100644 index 000000000..7e070bc8a --- /dev/null +++ b/crates/ui-contract/icons/tabler/layout-grid.svg @@ -0,0 +1,18 @@ + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/layout-sidebar-right.svg b/crates/ui-contract/icons/tabler/layout-sidebar-right.svg new file mode 100644 index 000000000..407d44fb1 --- /dev/null +++ b/crates/ui-contract/icons/tabler/layout-sidebar-right.svg @@ -0,0 +1,16 @@ + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/letter-case-upper.svg b/crates/ui-contract/icons/tabler/letter-case-upper.svg new file mode 100644 index 000000000..cf2a9e567 --- /dev/null +++ b/crates/ui-contract/icons/tabler/letter-case-upper.svg @@ -0,0 +1,18 @@ + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/letter-case.svg b/crates/ui-contract/icons/tabler/letter-case.svg new file mode 100644 index 000000000..bf0ecd6d2 --- /dev/null +++ b/crates/ui-contract/icons/tabler/letter-case.svg @@ -0,0 +1,18 @@ + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/line-scan.svg b/crates/ui-contract/icons/tabler/line-scan.svg new file mode 100644 index 000000000..e7ebfcf1e --- /dev/null +++ b/crates/ui-contract/icons/tabler/line-scan.svg @@ -0,0 +1,19 @@ + + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/link-off.svg b/crates/ui-contract/icons/tabler/link-off.svg new file mode 100644 index 000000000..0b73e5851 --- /dev/null +++ b/crates/ui-contract/icons/tabler/link-off.svg @@ -0,0 +1,22 @@ + + + + + + + diff --git a/crates/ui-contract/icons/tabler/link.svg b/crates/ui-contract/icons/tabler/link.svg new file mode 100644 index 000000000..4e4ef78d0 --- /dev/null +++ b/crates/ui-contract/icons/tabler/link.svg @@ -0,0 +1,21 @@ + + + + + + diff --git a/crates/ui-contract/icons/tabler/list.svg b/crates/ui-contract/icons/tabler/list.svg new file mode 100644 index 000000000..f941edae0 --- /dev/null +++ b/crates/ui-contract/icons/tabler/list.svg @@ -0,0 +1,20 @@ + + + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/lock-open.svg b/crates/ui-contract/icons/tabler/lock-open.svg new file mode 100644 index 000000000..a73093957 --- /dev/null +++ b/crates/ui-contract/icons/tabler/lock-open.svg @@ -0,0 +1,21 @@ + + + + + + diff --git a/crates/ui-contract/icons/tabler/lock.svg b/crates/ui-contract/icons/tabler/lock.svg new file mode 100644 index 000000000..f66fe54b5 --- /dev/null +++ b/crates/ui-contract/icons/tabler/lock.svg @@ -0,0 +1,21 @@ + + + + + + diff --git a/crates/ui-contract/icons/tabler/lollipop.svg b/crates/ui-contract/icons/tabler/lollipop.svg new file mode 100644 index 000000000..3744341c6 --- /dev/null +++ b/crates/ui-contract/icons/tabler/lollipop.svg @@ -0,0 +1,20 @@ + + + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/magnet.svg b/crates/ui-contract/icons/tabler/magnet.svg new file mode 100644 index 000000000..a0a6d21cf --- /dev/null +++ b/crates/ui-contract/icons/tabler/magnet.svg @@ -0,0 +1,17 @@ + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/mail.svg b/crates/ui-contract/icons/tabler/mail.svg new file mode 100644 index 000000000..fe44e6b74 --- /dev/null +++ b/crates/ui-contract/icons/tabler/mail.svg @@ -0,0 +1,16 @@ + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/menu-2.svg b/crates/ui-contract/icons/tabler/menu-2.svg new file mode 100644 index 000000000..93895f05b --- /dev/null +++ b/crates/ui-contract/icons/tabler/menu-2.svg @@ -0,0 +1,17 @@ + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/message.svg b/crates/ui-contract/icons/tabler/message.svg new file mode 100644 index 000000000..5bad41ef0 --- /dev/null +++ b/crates/ui-contract/icons/tabler/message.svg @@ -0,0 +1,17 @@ + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/minus.svg b/crates/ui-contract/icons/tabler/minus.svg new file mode 100644 index 000000000..361d40ae1 --- /dev/null +++ b/crates/ui-contract/icons/tabler/minus.svg @@ -0,0 +1,19 @@ + + + + diff --git a/crates/ui-contract/icons/tabler/moon.svg b/crates/ui-contract/icons/tabler/moon.svg new file mode 100644 index 000000000..e9995cf40 --- /dev/null +++ b/crates/ui-contract/icons/tabler/moon.svg @@ -0,0 +1,15 @@ + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/navigation.svg b/crates/ui-contract/icons/tabler/navigation.svg new file mode 100644 index 000000000..3fb30f940 --- /dev/null +++ b/crates/ui-contract/icons/tabler/navigation.svg @@ -0,0 +1,15 @@ + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/palette.svg b/crates/ui-contract/icons/tabler/palette.svg new file mode 100644 index 000000000..437803601 --- /dev/null +++ b/crates/ui-contract/icons/tabler/palette.svg @@ -0,0 +1,18 @@ + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/pencil.svg b/crates/ui-contract/icons/tabler/pencil.svg new file mode 100644 index 000000000..122a4d76f --- /dev/null +++ b/crates/ui-contract/icons/tabler/pencil.svg @@ -0,0 +1,20 @@ + + + + + diff --git a/crates/ui-contract/icons/tabler/pentagon.svg b/crates/ui-contract/icons/tabler/pentagon.svg new file mode 100644 index 000000000..57a63728a --- /dev/null +++ b/crates/ui-contract/icons/tabler/pentagon.svg @@ -0,0 +1,15 @@ + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/perspective.svg b/crates/ui-contract/icons/tabler/perspective.svg new file mode 100644 index 000000000..cf090341e --- /dev/null +++ b/crates/ui-contract/icons/tabler/perspective.svg @@ -0,0 +1,15 @@ + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/photo.svg b/crates/ui-contract/icons/tabler/photo.svg new file mode 100644 index 000000000..2ea87764d --- /dev/null +++ b/crates/ui-contract/icons/tabler/photo.svg @@ -0,0 +1,22 @@ + + + + + + + diff --git a/crates/ui-contract/icons/tabler/pilcrow-left.svg b/crates/ui-contract/icons/tabler/pilcrow-left.svg new file mode 100644 index 000000000..952bea31b --- /dev/null +++ b/crates/ui-contract/icons/tabler/pilcrow-left.svg @@ -0,0 +1,19 @@ + + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/pilcrow-right.svg b/crates/ui-contract/icons/tabler/pilcrow-right.svg new file mode 100644 index 000000000..c432c5cbc --- /dev/null +++ b/crates/ui-contract/icons/tabler/pilcrow-right.svg @@ -0,0 +1,19 @@ + + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/pilcrow.svg b/crates/ui-contract/icons/tabler/pilcrow.svg new file mode 100644 index 000000000..cb32d1c34 --- /dev/null +++ b/crates/ui-contract/icons/tabler/pilcrow.svg @@ -0,0 +1,17 @@ + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/player-pause.svg b/crates/ui-contract/icons/tabler/player-pause.svg new file mode 100644 index 000000000..9dc0892f7 --- /dev/null +++ b/crates/ui-contract/icons/tabler/player-pause.svg @@ -0,0 +1,16 @@ + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/player-play.svg b/crates/ui-contract/icons/tabler/player-play.svg new file mode 100644 index 000000000..27c4723ce --- /dev/null +++ b/crates/ui-contract/icons/tabler/player-play.svg @@ -0,0 +1,15 @@ + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/player-skip-back.svg b/crates/ui-contract/icons/tabler/player-skip-back.svg new file mode 100644 index 000000000..9ba45f441 --- /dev/null +++ b/crates/ui-contract/icons/tabler/player-skip-back.svg @@ -0,0 +1,16 @@ + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/player-skip-forward.svg b/crates/ui-contract/icons/tabler/player-skip-forward.svg new file mode 100644 index 000000000..347da6fe2 --- /dev/null +++ b/crates/ui-contract/icons/tabler/player-skip-forward.svg @@ -0,0 +1,16 @@ + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/plus.svg b/crates/ui-contract/icons/tabler/plus.svg new file mode 100644 index 000000000..388566402 --- /dev/null +++ b/crates/ui-contract/icons/tabler/plus.svg @@ -0,0 +1,20 @@ + + + + + diff --git a/crates/ui-contract/icons/tabler/pointer.svg b/crates/ui-contract/icons/tabler/pointer.svg new file mode 100644 index 000000000..e104e4b22 --- /dev/null +++ b/crates/ui-contract/icons/tabler/pointer.svg @@ -0,0 +1,15 @@ + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/rectangle-vertical.svg b/crates/ui-contract/icons/tabler/rectangle-vertical.svg new file mode 100644 index 000000000..eed7b0da5 --- /dev/null +++ b/crates/ui-contract/icons/tabler/rectangle-vertical.svg @@ -0,0 +1,15 @@ + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/rectangle.svg b/crates/ui-contract/icons/tabler/rectangle.svg new file mode 100644 index 000000000..d9d8a3d0a --- /dev/null +++ b/crates/ui-contract/icons/tabler/rectangle.svg @@ -0,0 +1,15 @@ + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/refresh.svg b/crates/ui-contract/icons/tabler/refresh.svg new file mode 100644 index 000000000..f5afc15a1 --- /dev/null +++ b/crates/ui-contract/icons/tabler/refresh.svg @@ -0,0 +1,16 @@ + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/rotate-clockwise.svg b/crates/ui-contract/icons/tabler/rotate-clockwise.svg new file mode 100644 index 000000000..779335983 --- /dev/null +++ b/crates/ui-contract/icons/tabler/rotate-clockwise.svg @@ -0,0 +1,19 @@ + + + + diff --git a/crates/ui-contract/icons/tabler/rotate.svg b/crates/ui-contract/icons/tabler/rotate.svg new file mode 100644 index 000000000..3c35a1471 --- /dev/null +++ b/crates/ui-contract/icons/tabler/rotate.svg @@ -0,0 +1,15 @@ + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/rubber-stamp.svg b/crates/ui-contract/icons/tabler/rubber-stamp.svg new file mode 100644 index 000000000..0d0689adc --- /dev/null +++ b/crates/ui-contract/icons/tabler/rubber-stamp.svg @@ -0,0 +1,16 @@ + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/ruler.svg b/crates/ui-contract/icons/tabler/ruler.svg new file mode 100644 index 000000000..3a169372b --- /dev/null +++ b/crates/ui-contract/icons/tabler/ruler.svg @@ -0,0 +1,21 @@ + + + + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/scan.svg b/crates/ui-contract/icons/tabler/scan.svg new file mode 100644 index 000000000..3615b284d --- /dev/null +++ b/crates/ui-contract/icons/tabler/scan.svg @@ -0,0 +1,19 @@ + + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/scissors.svg b/crates/ui-contract/icons/tabler/scissors.svg new file mode 100644 index 000000000..0e7b562cf --- /dev/null +++ b/crates/ui-contract/icons/tabler/scissors.svg @@ -0,0 +1,18 @@ + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/search.svg b/crates/ui-contract/icons/tabler/search.svg new file mode 100644 index 000000000..e894f9620 --- /dev/null +++ b/crates/ui-contract/icons/tabler/search.svg @@ -0,0 +1,20 @@ + + + + + diff --git a/crates/ui-contract/icons/tabler/settings.svg b/crates/ui-contract/icons/tabler/settings.svg new file mode 100644 index 000000000..c94891403 --- /dev/null +++ b/crates/ui-contract/icons/tabler/settings.svg @@ -0,0 +1,20 @@ + + + + + diff --git a/crates/ui-contract/icons/tabler/slash.svg b/crates/ui-contract/icons/tabler/slash.svg new file mode 100644 index 000000000..923f65676 --- /dev/null +++ b/crates/ui-contract/icons/tabler/slash.svg @@ -0,0 +1,15 @@ + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/slice.svg b/crates/ui-contract/icons/tabler/slice.svg new file mode 100644 index 000000000..678bbfc14 --- /dev/null +++ b/crates/ui-contract/icons/tabler/slice.svg @@ -0,0 +1,15 @@ + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/sort-ascending.svg b/crates/ui-contract/icons/tabler/sort-ascending.svg new file mode 100644 index 000000000..b886f2323 --- /dev/null +++ b/crates/ui-contract/icons/tabler/sort-ascending.svg @@ -0,0 +1,19 @@ + + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/sort-descending.svg b/crates/ui-contract/icons/tabler/sort-descending.svg new file mode 100644 index 000000000..4cbe1be3d --- /dev/null +++ b/crates/ui-contract/icons/tabler/sort-descending.svg @@ -0,0 +1,19 @@ + + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/sparkles.svg b/crates/ui-contract/icons/tabler/sparkles.svg new file mode 100644 index 000000000..65698da5e --- /dev/null +++ b/crates/ui-contract/icons/tabler/sparkles.svg @@ -0,0 +1,15 @@ + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/square-dashed.svg b/crates/ui-contract/icons/tabler/square-dashed.svg new file mode 100644 index 000000000..58ee3783b --- /dev/null +++ b/crates/ui-contract/icons/tabler/square-dashed.svg @@ -0,0 +1,26 @@ + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/square-plus.svg b/crates/ui-contract/icons/tabler/square-plus.svg new file mode 100644 index 000000000..0216dc3ff --- /dev/null +++ b/crates/ui-contract/icons/tabler/square-plus.svg @@ -0,0 +1,17 @@ + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/square-x.svg b/crates/ui-contract/icons/tabler/square-x.svg new file mode 100644 index 000000000..b395918b0 --- /dev/null +++ b/crates/ui-contract/icons/tabler/square-x.svg @@ -0,0 +1,16 @@ + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/square.svg b/crates/ui-contract/icons/tabler/square.svg new file mode 100644 index 000000000..0bf9820b4 --- /dev/null +++ b/crates/ui-contract/icons/tabler/square.svg @@ -0,0 +1,19 @@ + + + + diff --git a/crates/ui-contract/icons/tabler/stack-2.svg b/crates/ui-contract/icons/tabler/stack-2.svg new file mode 100644 index 000000000..d9fec3bc7 --- /dev/null +++ b/crates/ui-contract/icons/tabler/stack-2.svg @@ -0,0 +1,21 @@ + + + + + + diff --git a/crates/ui-contract/icons/tabler/star.svg b/crates/ui-contract/icons/tabler/star.svg new file mode 100644 index 000000000..44173bbc1 --- /dev/null +++ b/crates/ui-contract/icons/tabler/star.svg @@ -0,0 +1,15 @@ + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/strikethrough.svg b/crates/ui-contract/icons/tabler/strikethrough.svg new file mode 100644 index 000000000..18458a681 --- /dev/null +++ b/crates/ui-contract/icons/tabler/strikethrough.svg @@ -0,0 +1,16 @@ + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/subscript.svg b/crates/ui-contract/icons/tabler/subscript.svg new file mode 100644 index 000000000..27cb6f757 --- /dev/null +++ b/crates/ui-contract/icons/tabler/subscript.svg @@ -0,0 +1,16 @@ + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/sun.svg b/crates/ui-contract/icons/tabler/sun.svg new file mode 100644 index 000000000..9332aad99 --- /dev/null +++ b/crates/ui-contract/icons/tabler/sun.svg @@ -0,0 +1,16 @@ + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/superscript.svg b/crates/ui-contract/icons/tabler/superscript.svg new file mode 100644 index 000000000..49aacb169 --- /dev/null +++ b/crates/ui-contract/icons/tabler/superscript.svg @@ -0,0 +1,16 @@ + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/thumb-down.svg b/crates/ui-contract/icons/tabler/thumb-down.svg new file mode 100644 index 000000000..3db432586 --- /dev/null +++ b/crates/ui-contract/icons/tabler/thumb-down.svg @@ -0,0 +1,15 @@ + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/thumb-up.svg b/crates/ui-contract/icons/tabler/thumb-up.svg new file mode 100644 index 000000000..b0f595501 --- /dev/null +++ b/crates/ui-contract/icons/tabler/thumb-up.svg @@ -0,0 +1,15 @@ + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/toggle-left.svg b/crates/ui-contract/icons/tabler/toggle-left.svg new file mode 100644 index 000000000..f57dacb8f --- /dev/null +++ b/crates/ui-contract/icons/tabler/toggle-left.svg @@ -0,0 +1,16 @@ + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/toggle-right.svg b/crates/ui-contract/icons/tabler/toggle-right.svg new file mode 100644 index 000000000..6890dd304 --- /dev/null +++ b/crates/ui-contract/icons/tabler/toggle-right.svg @@ -0,0 +1,16 @@ + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/trash.svg b/crates/ui-contract/icons/tabler/trash.svg new file mode 100644 index 000000000..71afd76d1 --- /dev/null +++ b/crates/ui-contract/icons/tabler/trash.svg @@ -0,0 +1,23 @@ + + + + + + + + diff --git a/crates/ui-contract/icons/tabler/triangle.svg b/crates/ui-contract/icons/tabler/triangle.svg new file mode 100644 index 000000000..7606c23c7 --- /dev/null +++ b/crates/ui-contract/icons/tabler/triangle.svg @@ -0,0 +1,15 @@ + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/typography.svg b/crates/ui-contract/icons/tabler/typography.svg new file mode 100644 index 000000000..455e26398 --- /dev/null +++ b/crates/ui-contract/icons/tabler/typography.svg @@ -0,0 +1,23 @@ + + + + + + + + diff --git a/crates/ui-contract/icons/tabler/underline.svg b/crates/ui-contract/icons/tabler/underline.svg new file mode 100644 index 000000000..7d2b39452 --- /dev/null +++ b/crates/ui-contract/icons/tabler/underline.svg @@ -0,0 +1,16 @@ + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/vector-bezier-2.svg b/crates/ui-contract/icons/tabler/vector-bezier-2.svg new file mode 100644 index 000000000..c15de072e --- /dev/null +++ b/crates/ui-contract/icons/tabler/vector-bezier-2.svg @@ -0,0 +1,21 @@ + + + + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/vector-spline.svg b/crates/ui-contract/icons/tabler/vector-spline.svg new file mode 100644 index 000000000..02f9b3b12 --- /dev/null +++ b/crates/ui-contract/icons/tabler/vector-spline.svg @@ -0,0 +1,17 @@ + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/volume-off.svg b/crates/ui-contract/icons/tabler/volume-off.svg new file mode 100644 index 000000000..6f0fd0d7c --- /dev/null +++ b/crates/ui-contract/icons/tabler/volume-off.svg @@ -0,0 +1,18 @@ + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/wand.svg b/crates/ui-contract/icons/tabler/wand.svg new file mode 100644 index 000000000..2c72414c3 --- /dev/null +++ b/crates/ui-contract/icons/tabler/wand.svg @@ -0,0 +1,18 @@ + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/world.svg b/crates/ui-contract/icons/tabler/world.svg new file mode 100644 index 000000000..b3e2cf759 --- /dev/null +++ b/crates/ui-contract/icons/tabler/world.svg @@ -0,0 +1,19 @@ + + + + + + + + \ No newline at end of file diff --git a/crates/ui-contract/icons/tabler/x.svg b/crates/ui-contract/icons/tabler/x.svg new file mode 100644 index 000000000..d038c3d97 --- /dev/null +++ b/crates/ui-contract/icons/tabler/x.svg @@ -0,0 +1,20 @@ + + + + + diff --git a/crates/ui-contract/icons/tabler/zoom-in.svg b/crates/ui-contract/icons/tabler/zoom-in.svg new file mode 100644 index 000000000..e1e505ae6 --- /dev/null +++ b/crates/ui-contract/icons/tabler/zoom-in.svg @@ -0,0 +1,22 @@ + + + + + + + diff --git a/crates/ui-contract/src/contract/body.rs b/crates/ui-contract/src/contract/body.rs new file mode 100644 index 000000000..51ef64208 --- /dev/null +++ b/crates/ui-contract/src/contract/body.rs @@ -0,0 +1,167 @@ +//! The body step (16.3): the regions of a container (header, body with its scroll region, footer), open and +//! gate state, scroll offset, move and resize, and the zoomed canvas body. + +use super::cx::BodyCx; +use super::overlay::PlacementChange; +use crate::runtime::memory::SaveKey; +use crate::runtime::motion::Presence; +use crate::runtime::overlay::CloseReason; +use crate::runtime::windows::ResizeEdge; +use craft_behavior::ScrollPos; +use egui::{Rect, Ui, Vec2}; + +mod hooks; +mod inherit; +mod open; +mod pane; +mod placement; +mod presses; +mod regions; +mod reorder; +mod scroll; +mod size; +mod window; + +pub(crate) use placement::shown_placement; +#[doc(hidden)] +pub use regions::pad_of; +#[doc(hidden)] +pub use reorder::REORDER_BAND; +#[cfg(feature = "testing")] +pub(crate) use window::MOVE_BAND; +use window::WindowMode; + +/// What the scroll region and the regions measured last pass. +#[derive(Clone, Default)] +struct BodyView { + extent: (f32, f32), + view: Option<[f32; 4]>, +} + +pub(super) struct BodyHooks<'b> { + pub(super) body: &'b mut dyn FnMut(&mut Ui, &mut BodyCx<'_>), + /// The body's size from this pass's measuring run; `None` inside the measuring run itself. + measured_body: Option, + /// The header's size from this pass's measuring run; `None` without a header or inside the measuring run. + measured_header: Option, + measured_footer: Vec2, + /// The end region's size from this pass's measuring run; `None` without one or inside the measuring run. + measured_end: Option, + /// The trailing controls box as the measuring run found it; `None` in the measuring run and without a record this pass. + measured_controls: Option, + /// The measuring run measures a closed layer whose exit fade still shows it as if it were open. + shown_closed: bool, + /// A record of this pass may serve instead of a measuring run: in a real pass's step 5 and in a sizing pass, not + /// in `measure_in`, which measures the content it is given. + reuse: bool, + /// `open` and `presence` were read by the real pass's stage and stand for the measuring run: the run's own peek + /// stage cannot see a slot the real stage holds. + open_given: bool, + /// The gap between an inline header and the body, and between a header and its trailing region. + region_gap: f32, + /// The space between a stacked header and the body (`HeaderRegion::gap`), zero without one. + header_gap: f32, + /// The least width of the content, from `ContainerProps::least_width`. + least_width: f32, + /// How far the widest region wants to exceed the width the room allows, from this pass's measure. + overflow: f32, + /// The room the mount offers, in which a content-sized body runs. + room: Vec2, + open: bool, + open_at_read: bool, + open_bound: bool, + gate: Option, + gate_at_read: Option, + close: bool, + /// Why the container closes this pass, the first reason given. + reason: Option, + /// The container is closed and its layer is fading out: the body shows as it was and nothing is written. + exiting: bool, + offset: ScrollPos, + offset_at_read: ScrollPos, + /// The offset this pass shows, as step 4 left it: what decides which out-of-view children run, in a measuring + /// run (which lays the content out from offset zero) as in the real run. + view_offset: ScrollPos, + scroll_bound: bool, + moved: bool, + last: BodyView, + /// This pass's sizes, recorded at step 17. + body_size: Option, + header_size: Option, + footer_size: Option, + end_size: Option, + controls_size: Option, + extent: Option, + view: Option, + save: Option, + layer: bool, + /// How open the body is: 0 to 1, animating when the container's `Collapse` does. + presence: Presence, + /// The distance one arrow press moves or resizes a window in its keyboard mode. + nudge: f32, + /// The window mode the container is in, and what Escape restores. + mode: WindowMode, + /// The edge an edge pane's grip sits on this pass, with the least extent it gives; none for other mounts. + pane_grip: Option<(ResizeEdge, f32)>, + /// The placement changes of this pass, delivered to `Container::placement_changed` at the end of the update. + reports: Vec, + /// The host gives the container a rect of its own size: a full window, an OS viewport or a layer the user sized. + fixed: bool, + /// The axes (horizontal, vertical) the container is given: it fills them, and its own container was given them + /// too or it is shown at a rect. Along the others it sizes from its content. + given: (bool, bool), + /// A bottom-anchored region is following the end of its content. + follows_end: bool, +} + +impl<'b> BodyHooks<'b> { + pub(super) fn new(body: &'b mut dyn FnMut(&mut Ui, &mut BodyCx<'_>)) -> Self { + BodyHooks { + body, + measured_body: None, + measured_header: None, + measured_footer: Vec2::ZERO, + measured_end: None, + measured_controls: None, + shown_closed: false, + reuse: false, + open_given: false, + region_gap: 0.0, + header_gap: 0.0, + least_width: 0.0, + overflow: 0.0, + room: Vec2::ZERO, + open: true, + open_at_read: true, + open_bound: false, + gate: None, + gate_at_read: None, + close: false, + reason: None, + exiting: false, + offset: ScrollPos::default(), + offset_at_read: ScrollPos::default(), + view_offset: ScrollPos::default(), + scroll_bound: false, + moved: false, + last: BodyView::default(), + body_size: None, + header_size: None, + footer_size: None, + end_size: None, + controls_size: None, + extent: None, + view: None, + save: None, + layer: false, + presence: Presence { t: 1.0, visible: true, exiting: false }, + nudge: 0.0, + mode: WindowMode::default(), + pane_grip: None, + reports: Vec::new(), + fixed: false, + given: (false, false), + follows_end: false, + } + } +} diff --git a/crates/ui-contract/src/contract/body/hooks.rs b/crates/ui-contract/src/contract/body/hooks.rs new file mode 100644 index 000000000..0ed2194a0 --- /dev/null +++ b/crates/ui-contract/src/contract/body/hooks.rs @@ -0,0 +1,1019 @@ +//! The body step's `ShapeHooks`: the pipeline's calls into a container's body. + +use super::inherit::{BodyScope, register_instances}; +use super::open::open_now; +use super::placement::{Placement, measure_layer, overlay_of, shown_placement}; +use super::regions::{ + RegionFrame, RegionSizes, footer_in_end, gap_of, header_gap_of, label_extra_of, least_of, pad_of, paint_rules, rect_of, shared_labels, + shared_line, +}; +use super::reorder::REORDER_BAND; +use super::scroll::{Jumps, ScrollState, jump_frame, overflow_inset, scroll_of}; +use super::window::{WindowMode, os_window, window_instance}; +use super::{BodyHooks, BodyView}; +use crate::contract::cx::{BodyCx, BodyOwner}; +use crate::contract::label::{self, LabelIn}; +use crate::contract::run::{Measuring, ShapeHooks, ShowAt}; +use crate::contract::{Container, Cx, DragBand, Gap, Internal, Mount, Notch, PartsCx, SetPosition, Sizing, ValueOf}; +use crate::layout::{self}; +use crate::primitives::Surface; +use crate::runtime::access::scope; +use crate::runtime::access::{self, Politeness, Role}; +use crate::runtime::commands; +use crate::runtime::egui::{alloc, areas, child, memory as store, response, style, viewports}; +use crate::runtime::env::{AppValues, ArenaId, Env}; +use crate::runtime::focus::FocusPolicy; +use crate::runtime::memory::{MemoryStage, sub}; +use crate::runtime::motion::{Driver, Presence, spec}; +use crate::runtime::overlay::CloseReason; +use crate::runtime::{keys, layout_memory, pointer, wheel}; +use crate::style::ComponentStyle as _; +use crate::style::{Corners, StyleCx, SurfaceKind, scroll_bar_look, surface_style}; +use craft_behavior::layout_memory::measure_tolerance; +use craft_behavior::{CancelRule, CursorIcon, EditEvent, KeyRole, Mixed, Roving, ScrollPos, ScrollSpan, WheelNotch, WheelRoom, WheelTaker}; +use egui::{Context, CornerRadius, Id, Pos2, Rect, Shape, Ui, UiBuilder, Vec2}; +use std::any::Any; +use std::sync::Arc; + +impl ShapeHooks for BodyHooks<'_> { + fn shape(&self) -> crate::contract::steps::ShapeKind { + crate::contract::steps::ShapeKind::Body + } + + fn regions(&self, id: Id) -> Vec<(Id, Vec2)> { + [ + ("body", self.body_size), + ("header", self.header_size), + ("footer", self.footer_size), + ("end", self.end_size), + ("controls", self.controls_size), + ("extent", self.extent), + ] + .into_iter() + .filter_map(|(key, took)| took.map(|took| (sub(id, key), took))) + .collect() + } + + fn in_flow(&self, comp: &C) -> bool { + !matches!(comp.props(Internal::new()).mount, Mount::Layer(_) | Mount::FullWindow | Mount::Viewport { .. }) + } + + fn host(&mut self, comp: &C, at: crate::contract::run::HostCx<'_>) -> Box { + let mounted = crate::contract::mount::host(comp.props(Internal::new()), &at, self.open, at.label); + if mounted.exiting { + self.exiting = true; + self.open = true; + } + mounted.host + } + + /// A container that is an instance of its command scope sees itself in its own context's chain, so a focused + /// container (a canvas) is the instance its chords and the commands it takes reach. + fn instance_scope(&self, comp: &C) -> Option { + comp.props(Internal::new()).command_scope + } + + fn dismissed(&mut self, comp: &mut C, cx: &mut Cx<'_, C>, why: CloseReason) { + self.close = true; + self.open = false; + comp.closed(why); + self.write_open(comp, cx); + } + + /// The scope of a layer, full-window or viewport mount is the host's (one scope per layer, from `Overlay.focus`; + /// a full-window mount's overlay carries `props.focus`); `Inline` and `Pane` containers push `props.focus`. + fn focus(&self, comp: &C) -> Option { + let props = comp.props(Internal::new()); + if matches!(props.mount, Mount::Layer(_) | Mount::Viewport { .. }) { + debug_assert!( + props.focus == FocusPolicy::NONE, + "a layer or viewport mount takes its focus scope from `Overlay.focus`, not `ContainerProps.focus`" + ); + return None; + } + if matches!(props.mount, Mount::FullWindow) { + return None; + } + (props.focus != FocusPolicy::NONE).then_some(props.focus) + } + + fn arena(&self, comp: &C) -> bool { + comp.props(Internal::new()).arena + } + + fn expanded(&self, comp: &C) -> Option { + comp.props(Internal::new()).collapse.map(|_| self.open) + } + + fn roving(&self, comp: &C) -> Option { + comp.props(Internal::new()).roving + } + + fn key_role(&self, comp: &C) -> KeyRole { + KeyRole::new().reorderable(comp.props(Internal::new()).header.is_some_and(|header| header.band == DragBand::Reorder)) + } + + fn position(&self, comp: &C) -> Option { + comp.props(Internal::new()).position + } + + fn live(&self, comp: &C) -> Option { + comp.props(Internal::new()).live + } + + fn scrolls(&self, comp: &C) -> (bool, bool) { + scroll_of(comp.props(Internal::new())).map_or((false, false), |scroll| (scroll.vertical_on(), scroll.horizontal_on())) + } + + fn read(&mut self, comp: &mut C, stage: &mut MemoryStage, id: Id, env: &Env) { + let ctx = stage.ctx().clone(); + let props = comp.props(Internal::new()).clone(); + let props = &props; + let scroll = scroll_of(props); + let collapse = props.collapse; + let save = props.save.clone(); + self.save = save.clone(); + // The overlay host decides a layer's Escape; so does a full-window mount's. + self.layer = matches!(props.mount, Mount::Layer(_) | Mount::Viewport { .. } | Mount::FullWindow); + self.region_gap = gap_of(&env.tokens, Gap::Tight); + self.header_gap = header_gap_of(props, &env.tokens); + self.least_width = least_of(&env.tokens, props.least_width); + let quiet = stage.is_peek() || crate::runtime::measure::active(&ctx); + if !matches!(props.mount, Mount::Inline | Mount::Pane(_)) + && let Some(why) = if quiet { crate::runtime::overlay::peek_close(&ctx, id) } else { crate::runtime::overlay::take_close(&ctx, id) } + { + self.close = true; + self.reason = Some(why); + } + self.open_bound = comp.open().is_some(); + self.open = open_now(comp, stage, id, props); + self.open_at_read = self.open; + self.presence = match collapse { + Some(collapse) if collapse.animated => { + Driver { stage: &*stage, base: id, policy: env.motion }.presence("collapse", self.open, spec::OPEN_RISE) + } + _ => Presence { t: f32::from(u8::from(self.open)), visible: self.open, exiting: false }, + }; + self.mode = stage.session::(sub(id, "window_mode")).clone(); + self.fixed = match &props.mount { + Mount::FullWindow => true, + Mount::Viewport { .. } if viewports::available(&ctx) => true, + Mount::Layer(_) | Mount::Viewport { .. } => { + let placement = overlay_of(props).map_or_else(Placement::default, |overlay| { + let screen = crate::contract::overlay::screen_for(&ctx, &env, overlay); + shown_placement(&ctx, id, save.as_ref(), overlay, screen, env.tokens.space.inset.screen) + }); + placement.pos.is_some() && placement.size.is_some() + } + _ => false, + }; + self.last = stage.recall::(sub(id, "view")); + let Some(scroll) = scroll else { return }; + self.scroll_bound = comp.scroll().is_some(); + let held = match comp.scroll() { + Some(bind) => match bind.get() { + Some(Mixed::Same(pos)) => pos, + _ => ScrollPos::default(), + }, + None => { + let state = stage.session::(sub(id, "scroll")); + ScrollPos { x: state.offset.0, y: state.offset.1 } + } + }; + self.offset = held; + self.offset_at_read = held; + let rtl = env.direction.is_rtl(); + let view = self.last.view.map_or(Vec2::ZERO, |view| rect_of(view).size()); + // Step 4 applies, in order, the scroll bar and AccessKit moves of the last pass (`scroll_input`), this pass's + // wheel share and the reveal request queued last pass. + let frame = jump_frame(&ctx); + let jump = store::Service::::run(&ctx, |jumps| { + jumps.0.retain(|(.., queued)| queued + 1 >= frame); + let at = jumps.0.iter().position(|(owner, ..)| *owner == id)?; + Some(if quiet { jumps.0[at].1 } else { jumps.0.remove(at).1 }) + }); + if let Some(jump) = jump { + self.offset = jump; + self.moved = true; + } + if let Some(share) = if quiet { wheel::peek(&ctx, id) } else { wheel::take(&ctx, id) } { + let sign = if rtl { 1.0 } else { -1.0 }; + self.offset.x += f64::from(sign * share.scroll.x); + self.offset.y -= f64::from(share.scroll.y); + self.moved = true; + } + if let (Some(rect), Some(view_rect)) = + (if quiet { crate::contract::peek_reveal(&ctx, id) } else { crate::contract::take_reveal(&ctx, id) }, self.last.view.map(rect_of)) + { + // A view with no extent on an axis shows nothing there: no offset reveals into it. + let into = |low: f32, high: f32, view_low: f32, view_high: f32| { + if view_high <= view_low { + 0.0 + } else if low < view_low { + low - view_low + } else if high > view_high { + high - view_high + } else { + 0.0 + } + }; + self.offset.y += f64::from(into(rect.min.y, rect.max.y, view_rect.min.y, view_rect.max.y)); + let dx = into(rect.min.x, rect.max.x, view_rect.min.x, view_rect.max.x); + self.offset.x += f64::from(if rtl { -dx } else { dx }); + self.moved = true; + } + let moves = if quiet { crate::contract::steps::peek_scroll_moves(&ctx, id) } else { crate::contract::steps::take_scroll_moves(&ctx, id) }; + for mv in moves { + let (visible, extent, offset, vertical) = if scroll.vertical_on() { + (view.y, self.last.extent.1, self.offset.y, true) + } else { + (view.x, self.last.extent.0, self.offset.x, false) + }; + let span = ScrollSpan::new(0.0..f64::from(extent).max(f64::from(visible)), offset..offset + f64::from(visible)); + if let Some(range) = craft_behavior::scroll::jump(&span, mv) { + if vertical { + self.offset.y = range.start; + } else { + self.offset.x = range.start; + } + self.moved = true; + } + } + let follows = stage.session::(sub(id, "scroll")).follow_end.unwrap_or(true); + self.follows_end = scroll.anchor == crate::contract::ScrollAnchor::End && follows; + if self.follows_end && !self.moved { + self.offset.y = f64::from((self.last.extent.1 - view.y).max(0.0)); + } + self.clamp_offset(scroll, view); + self.view_offset = self.offset; + } + + fn overflow(&self) -> f32 { + self.overflow + } + + fn extent(&mut self, comp: &C, ui: &Ui, at: ShowAt, id: Id, scx: &StyleCx<'_>) -> Vec2 { + let props = comp.props(Internal::new()); + self.room = self.mount_room(props, ui, id, at); + self.given = self.given_axes(props, &Env::of(ui), at); + let measured = self.measured_body.unwrap_or(Vec2::ZERO); + let body = if self.presence.visible { Vec2::new(measured.x, measured.y * self.presence.t) } else { Vec2::ZERO }; + let room = self.room.x - 2.0 * pad_of(scx.tokens, props.pad); + let width = if self.measured_body.is_some() { self.shared_width(room, props) } else { 0.0 }; + self.overflow = self.wanted_width(props).map_or(0.0, |wanted| (wanted - room.max(0.0)).max(0.0)); + let (header, end) = (self.measured_header.unwrap_or(Vec2::ZERO), self.measured_end.unwrap_or(Vec2::ZERO)); + let height = self.regions_size(props, body, header, self.measured_footer, end).y; + Vec2::new(width, height) + Vec2::splat(2.0 * pad_of(scx.tokens, props.pad)) + } + + /// The regions run once in an invisible sizing pass over the room, as `content` runs them, and the container takes + /// what they took: nothing an earlier pass recorded counts. Along an axis the body scrolls on it takes at most + /// the room. What the regions took is recorded for the rest of the pass; a record this pass already holds serves + /// instead when the room still allows it (`reusable`). + fn measured_extent(&mut self, comp: &mut C, at: &Measuring<'_, '_>, cx: &mut Cx<'_, C>) -> Vec2 { + let props = comp.props(Internal::new()).clone(); + // A mount outside the flow takes no room in a parent's sizing pass, so its regions run only when it is + // measured itself. + if !matches!(props.mount, Mount::Inline) && at.ui.is_sizing_pass() { + return self.extent(comp, at.ui, at.at, cx.core.id, at.scx); + } + let (id, ctx) = (cx.core.id, at.ui.ctx().clone()); + let open = if self.open_given { self.open } else { open_now(comp, &mut *cx.core.memory, id, &props) }; + self.open = open || self.shown_closed; + self.open_at_read = self.open; + // An animated collapse shows a share of the full body height, so the body is measured while any of it shows. + let shows = self.open || (props.collapse.is_some_and(|collapse| collapse.animated) && self.presence.visible); + self.presence = Presence { t: f32::from(u8::from(shows)), visible: shows, exiting: false }; + self.measured_body = None; + self.measured_header = None; + self.measured_footer = Vec2::ZERO; + self.measured_end = None; + self.measured_controls = None; + // The measuring run lays a scrolling body's content out at the width the real run of this pass gives it: beside + // the bars the content extent the view keeps asks for, so the records it leaves serve that run. + self.last = BodyView { extent: self.last.extent, ..BodyView::default() }; + self.offset = ScrollPos::default(); + self.region_gap = gap_of(&at.env.tokens, Gap::Tight); + self.header_gap = header_gap_of(&props, &at.env.tokens); + self.least_width = least_of(&at.env.tokens, props.least_width); + self.room = match at.width { + Some(width) => Vec2::new(width, props.room_height.unwrap_or(f32::INFINITY)), + None => self.mount_room(&props, at.ui, id, at.at), + }; + self.given = self.given_axes(&props, at.env, at.at); + // A body that fills the main axis of the body it sits in is measured and shown at its share of it. The first + // sweep of that body's measuring run only counts it: its contents run in the second sweep, at the share. + let (x, y) = (craft_behavior::Axis::X, craft_behavior::Axis::Y); + // A container placed at an explicit rect is no flow child of that body: it takes its rect, not a share. + let flows = matches!(at.at, ShowAt::Flow); + if flows + && at.ui.is_sizing_pass() + && ((self.given.0 && crate::layout::counting_fills(at.ui, x)) || (self.given.1 && crate::layout::counting_fills(at.ui, y))) + { + return Vec2::ZERO; + } + if let Some(share) = crate::layout::fill_share(at.ui, x).filter(|_| flows && self.given.0) { + self.room.x = share; + } + if let Some(share) = crate::layout::fill_share(at.ui, y).filter(|_| flows && self.given.1) { + self.room.y = share; + } + // A body that fills both axes its parent gives it takes the room, whatever its contents take: a parent's + // measuring run does not run them. It measures them in its own real run. + if at.ui.is_sizing_pass() && self.given == (true, true) && self.room.is_finite() { + return self.room; + } + let pad = Vec2::splat(2.0 * pad_of(at.scx.tokens, props.pad)); + let vertical = scroll_of(&props).is_some_and(|scroll| scroll.vertical_on()); + let tolerance = measure_tolerance(crate::runtime::egui::scale::pixels_per_point(&ctx)); + // A record a run of this pass left serves as before; a kept one serves only while the inputs it was measured + // under hold. + let key = self.measure_key(&props, at.env, at.width); + let reused = (self.reuse || at.ui.is_sizing_pass()) + .then(|| { + let found = layout_memory::run_found(&ctx, id); + let serves = found || layout_memory::kept_serves(&ctx, id, &key); + serves.then(|| self.reusable(&props, &ctx, id, pad, tolerance)).flatten().map(|took| (took, found)) + }) + .flatten(); + let took = match reused { + Some((took, found)) => { + if found { + layout_memory::kept_also_under(&ctx, id, key); + } + took + } + None => { + #[cfg(feature = "testing")] + crate::runtime::measure::count_body(&ctx, id); + layout_memory::begin_measure(&ctx, id); + let available = match at.at { + ShowAt::Rect(rect) => rect, + // Not the cursor: in a right-to-left layout it extends to -inf along the line. + ShowAt::Flow => at.ui.available_rect_before_wrap(), + }; + let origin = available.min; + // Along an axis with no room limit the content grows away from its start edge: in a right-to-left + // layout that edge is the right one, so the measuring rect is as wide as a scrolling region and + // ends where the room does, as the real run's region does. + let rect = if self.room.x.is_infinite() && at.env.direction.is_rtl() && available.max.x.is_finite() { + Rect::from_min_max( + Pos2::new(available.max.x - crate::contract::MAX_EXTENT, origin.y), + Pos2::new(available.max.x, origin.y + self.room.y), + ) + } else { + Rect::from_min_size(origin, self.room) + }; + cx.core.rect = rect; + cx.core.flow = craft_behavior::Flow::new(rect, at.env.direction.is_rtl()); + cx.core.content_rect = cx.core.flow.inset(cx.style.metrics().padding); + let builder = UiBuilder::new().layer_id(measure_layer(&props, id, at.ui)).max_rect(rect).sizing_pass().invisible(); + // The regions take explicit scope ids under `id`, so every component in them gets the id the real run + // gives it and the records it leaves match. + let mut measure_ui = Ui::new(ctx.clone(), sub(id, "measure"), builder); + let installed = Env::install_for(&measure_ui, at.env.clone()); + let mut values = AppValues::default(); + comp.content_env(cx, &mut values); + self.content(comp, &mut measure_ui, at.env, cx, &values); + Env::restore(&ctx, installed); + let record = |key: Id, took: Vec2| layout_memory::emit_record(&ctx, key, layout_memory::Measured::new(self.room, took)); + record(id, self.body_size.unwrap_or(Vec2::ZERO)); + for (key, size) in + [("header", self.header_size), ("footer", self.footer_size), ("end", self.end_size), ("controls", self.controls_size)] + { + if let Some(size) = size { + record(sub(id, key), size); + } + } + layout_memory::end_measure(&ctx, id, key); + let body = if self.open { self.body_size.unwrap_or(Vec2::ZERO) } else { Vec2::ZERO }; + let (header, footer, end) = + (self.header_size.unwrap_or(Vec2::ZERO), self.footer_size.unwrap_or(Vec2::ZERO), self.end_size.unwrap_or(Vec2::ZERO)); + self.regions_size(&props, body, header, footer, end) + pad + } + }; + // A layer hung from an opener is at least as wide as the opener its overlay asks for, in the measuring run too, + // so the rows of a content-sized list inside it are placed at that width. + let took = Vec2::new(overlay_of(&props).map_or(took.x, |overlay| took.x.max(crate::contract::overlay::opener_floor(overlay))), took.y); + self.overflow = (took.x - self.room.x).max(0.0); + // A body wider than the room overflows it, or scrolls along it; either way the container keeps to the room. + Vec2::new(took.x.min(self.room.x), if vertical { took.y.min(self.room.y) } else { took.y }) + } + + /// A real pass places the container by what its measuring run in this pass found: the record a measuring run of + /// an enclosing container left when the room still allows it, else a measuring run of its own now. A closed + /// layer that no longer shows runs none. + fn pass_extent(&mut self, comp: &mut C, at: &Measuring<'_, '_>, style: &C::Style, shown: Option>>) -> Vec2 { + let props = comp.props(Internal::new()).clone(); + let (ctx, id) = (at.ui.ctx().clone(), at.resolved.id); + let layer = matches!(props.mount, Mount::Layer(_) | Mount::FullWindow | Mount::Viewport { .. }); + let fading = layer && !self.open && crate::runtime::motion::layer_fading(&ctx, sub(id, "presence")); + if !layer || self.open || fading { + let mut stage = MemoryStage::open_peek(&ctx, id); + let mut fresh = BodyHooks::new(&mut *self.body); + fresh.read(comp, &mut stage, id, at.env); + // A peek stage holds no session scroll state: the measuring run decides by the offset this pass shows. + fresh.view_offset = self.view_offset; + fresh.open = self.open; + fresh.open_at_read = self.open; + fresh.presence = self.presence; + fresh.open_given = true; + fresh.shown_closed = fading; + fresh.reuse = true; + crate::contract::run::measured_extent(comp, &mut fresh, at, &mut stage, style, shown); + } + let took = |key: Id| layout_memory::measured(&ctx, key).map(|measured| measured.took); + self.measured_body = took(id); + self.measured_header = props.header.and_then(|_| took(sub(id, "header"))); + self.measured_footer = props.footer.as_ref().and_then(|_| took(sub(id, "footer"))).unwrap_or(Vec2::ZERO); + self.measured_end = props.end.as_ref().and_then(|_| took(sub(id, "end"))); + self.measured_controls = took(sub(id, "controls")); + self.extent(comp, at.ui, at.at, id, at.scx) + } + + fn sized(&self, comp: &C, ui: &Ui, id: Id, size: Vec2) -> Vec2 { + let props = comp.props(Internal::new()); + match self.sizing(props) { + Sizing::Fill => { + let room = crate::layout::flow_room(ui); + // The available rect, not at least it: a fill child that took the whole room in an earlier pass (a + // content-sized layer offers its whole room before the footer is known) must not keep its remembered + // size once the room is less. Along an axis it is not given it takes its measured size. Along the main + // axis of the body it sits in it takes its share of what its siblings leave. + let axis = |room: f32, given: bool, along: craft_behavior::Axis, measured: f32| { + if !(room.is_finite() && given) { + return measured; + } + match crate::layout::main_fill(ui, id, along) { + crate::layout::MainFill::Measuring => 0.0, + crate::layout::MainFill::Share(share) => share, + crate::layout::MainFill::Room => room, + } + }; + Vec2::new(axis(room.x, self.given.0, craft_behavior::Axis::X, size.x), axis(room.y, self.given.1, craft_behavior::Axis::Y, size.y)) + } + Sizing::FillWidth => { + let room = crate::layout::flow_fill_room(ui).x; + // A fill-width child held in a content column is not given the width (it never sets the column's + // width) but shows across the column. + // It widens to the column it is held in, never past it, and only where it is shown: its measure never + // sets the column's width. + let held = !self.given.0 && self.held(props, &Env::of(ui)); + let room = if held { room.min(crate::layout::flow_room(ui).x) } else { room }; + let across = self.given.0 || held; + let width = if room.is_finite() && across { + match crate::layout::main_fill(ui, id, craft_behavior::Axis::X) { + crate::layout::MainFill::Measuring => 0.0, + crate::layout::MainFill::Share(share) => share, + crate::layout::MainFill::Room => size.x.max(room), + } + } else { + size.x + }; + Vec2::new(width, size.y) + } + Sizing::Content => size, + } + } + + fn fills_width(&self, comp: &C) -> bool { + self.sizing(comp.props(Internal::new())) != Sizing::Content + } + + fn fills_width_only(&self, comp: &C) -> bool { + self.sizing(comp.props(Internal::new())) == Sizing::FillWidth + } + + fn on_line(&self, comp: &C) -> bool { + matches!(comp.props(Internal::new()).layout, layout::BodyLayout::Row { wrap: false, .. }) + } + + fn parts(&mut self, comp: &mut C, rect: Rect, pcx: &mut PartsCx<'_, C>) { + let props = comp.props(Internal::new()).clone(); + let ctx = pcx.ui.ctx().clone(); + let rtl = pcx.flow.is_rtl(); + let tokens = pcx.tokens; + let inner = pcx.content_rect.shrink(pad_of(tokens, props.pad)); + let room = self.room_size(rect, inner); + let regions = self.regions(&props, inner, pad_of(tokens, props.pad), room, rtl, self.measured_sizes()); + let scroll = scroll_of(&props); + if self.open && scroll.is_some() { + let view = regions.body; + self.view = Some(view); + if let Some(scroll) = scroll { + self.clamp_offset(scroll, view.size()); + } + for (bar, span) in self.scroll_geometry(&props, view, rtl, tokens) { + pcx.scroll(bar.key, bar.track, bar.axis, span); + } + if let Some(scroll) = scroll { + let notch = match scroll.notch { + Notch::Lines(lines) => WheelNotch::Points(lines * tokens.tokens().typography.body.line_height), + Notch::ViewShare(share) => WheelNotch::ViewShare(share), + }; + // A region takes an axis only while its content overflows there, and hands the wheel on at its ends. + let max = self.max_offset(view.size()); + let (vertical, horizontal) = (scroll.vertical_on() && max.y > 0.0, scroll.horizontal_on() && max.x > 0.0); + let (before, after) = ( + Vec2::new(self.offset.x as f32, self.offset.y as f32), + Vec2::new((max.x - self.offset.x) as f32, (max.y - self.offset.y) as f32), + ); + // A positive wheel moves the offset back on y, and on x in left-to-right flow. + let (positive, negative) = if rtl { (Vec2::new(after.x, before.y), Vec2::new(before.x, after.y)) } else { (before, after) }; + if vertical || horizontal { + wheel::register( + &ctx, + WheelTaker::new(pcx.id, view) + .vertical(vertical) + .horizontal(horizontal) + .scrolls(true) + .gated(crate::runtime::env::Env::of(pcx.ui).wheel_gated) + .notch(notch) + .room(WheelRoom::new(positive, negative)), + ); + } + } + } + self.nudge = gap_of(tokens, Gap::Row); + // The reorder band lies under the header's own parts and children: its default priority loses to theirs, so + // their buttons keep their clicks. + if props.header.is_some_and(|header| header.band == DragBand::Reorder) && regions.header.height() > 0.0 { + pcx.part(REORDER_BAND, regions.header) + .sense(craft_behavior::Sense::DRAG) + .cursor(CursorIcon::Grab) + .drag_cursor(CursorIcon::Grabbing) + .pointer_only("Alt+Up and Alt+Down move the section"); + } + Self::move_parts(&props, ®ions, rect, pcx); + self.pane_grip = Self::pane_grip(&props, rect, pcx); + } + + fn sensed(&mut self, comp: &mut C, cx: &mut Cx<'_, C>) { + self.reorder_keys(comp.props(Internal::new()), cx); + } + + fn updated(&mut self, comp: &mut C, cx: &mut Cx<'_, C>) { + use crate::contract::Pointer as _; + let props = comp.props(Internal::new()); + let (scroll, layer) = (scroll_of(props), matches!(props.mount, Mount::Layer(_) | Mount::Viewport { .. })); + // The OS asked a viewport mount's window to close: the container closes at step 15. + if matches!(props.mount, Mount::Viewport { .. }) && crate::runtime::windows::take_close_request(cx.core.memory.ctx(), cx.core.id) { + self.close = true; + self.reason = self.reason.or(Some(CloseReason::Requested)); + } + if scroll.is_some() { + self.scroll_input(props, cx); + } + // AccessKit Expand, Collapse and Click reach a collapsible container as an activation: it folds or unfolds. + if props.collapse.is_some() && cx.activation().is_some_and(|activation| activation.by_key) { + self.open = !self.open; + } + self.band_double(cx); + self.surface_press(comp.sense().contains(craft_behavior::Sense::SURFACE), cx); + let band = props.header.is_some_and(|header| header.band == DragBand::Move); + if (band || matches!(props.mount, Mount::Viewport { .. } | Mount::Window { .. })) + && let Some(viewport) = os_window(props, cx.core.memory.ctx(), cx.core.id) + { + self.window_os(viewport, cx); + self.window_movable(cx); + } + self.pane_drag(props, cx); + if layer && !(matches!(props.mount, Mount::Viewport { .. }) && viewports::available(cx.core.memory.ctx())) { + self.window_keys(props, cx); + self.window_drag(props, cx); + } + self.window_placed(props, cx); + for change in std::mem::take(&mut self.reports) { + comp.placement_changed(&change); + } + } + + fn content(&mut self, comp: &mut C, ui: &mut Ui, env: &Env, cx: &mut Cx<'_, C>, values: &AppValues) { + let props = comp.props(Internal::new()).clone(); + let (id, ctx, rect) = (cx.core.id, cx.core.ctx.clone(), cx.core.rect); + let rtl = env.direction.is_rtl(); + let node = matches!(C::ROLE, Role::Node(_)); + let scroll = scroll_of(&props); + let pad = pad_of(&env.tokens, props.pad); + let inner = cx.core.content_rect.shrink(pad); + let room = self.room_size(rect, inner); + let mut regions = self.regions(&props, inner, pad, room, rtl, self.measured_sizes()); + // A layer's surface casts its shadow past the layer's own clip: it paints under the whole window. So does a popup + // surface at the top of a layer a control owns (`Menu::inline`). + let mut surface_painter = ui.painter().clone(); + let popup_in_layer = matches!(props.surface, Some(SurfaceKind::Popup)) && crate::runtime::overlay::drawing_parent(ui.ctx()).is_some(); + if matches!(props.mount, Mount::Layer(_)) || popup_in_layer { + surface_painter.set_clip_rect(ui.ctx().content_rect()); + } + let surface_slot = surface_painter.add(Shape::Noop); + let band_slot = ui.painter().add(Shape::Noop); + // A measuring run lays out and measures: it registers no instance, focus body, scroll region or body layer, + // and claims no room in a parent flow. + let real = !ui.is_sizing_pass(); + // Only a container that declares its value a gate (a group box) gates its content; a radio group whose value + // is a bool does not. + // A mixed gate reads as off, and its check box shows the mixed face. + self.gate = cx.shown.as_deref().filter(|_| props.gates).and_then(|value| (value as &dyn Any).downcast_ref::()).copied(); + let gate_mixed = props.gates && cx.mixed; + self.gate = self.gate.or(gate_mixed.then_some(false)); + self.gate_at_read = self.gate; + let window = window_instance(&props, id).filter(|window| *window != id); + if real { + register_instances(&ctx, &props, id, window); + } + let region_env = env.derive(|scoped| self.scope_regions(scoped, &props, cx, window, values, real)); + let body_id = sub(id, "body"); + let owner = BodyOwner::new(cx.style, gap_of(&env.tokens, props.body_gap)); + let frame = RegionFrame { id, rtl, node, env: ®ion_env }; + let (resolved, env_view) = (cx.core.resolved, region_env.view()); + let mut open = self.open; + let mut gate = self.gate; + let mut close: Option = None; + let field_message = if props.label.is_some() { scope::last_message(&ctx, id) } else { None }; + // B1 header + if props.header.is_some() { + let mut bcx = BodyCx::new(body_id, env_view, resolved, regions.header, &mut *cx.core.memory, &mut open, gate.as_mut()) + .with_gate_mixed(gate_mixed) + .with_field_message(field_message.clone()) + .with_owner(owner); + let trailing = props.header.is_some_and(|header| header.trailing); + let inset = props.header.map_or(0.0, |header| pad_of(&env.tokens, header.inset)); + close = close.or(self.header_region(comp, ui, &mut bcx, &frame, regions.header, trailing, inset)); + } + let animated = props.collapse.is_some_and(|collapse| collapse.animated); + let is_open = open || (animated && self.presence.visible); + let enabled = gate.unwrap_or(true); + // What the body and the end region share: gate, size, roving group and commands. The body adds its arena, + // transform and scroll owner; the end region lies outside them. + let line_env = region_env.derive_local(|scoped| { + scoped.enabled &= enabled; + if let Some(size) = props.child_size { + scoped.size = size; + } + if props.roving.is_some() { + scoped.roving = Some(crate::contract::steps::body_group(id)); + } + }); + let end_frame = RegionFrame { id, rtl, node, env: &line_env }; + // A footer in the end region is part of a column sized from its content: a fill-width child takes its + // measured width there and shows across the column, so it never sets the column's width. + let footer_env = if footer_in_end(&props) { region_env.derive_local(|scoped| scoped.content_column = true) } else { region_env.clone() }; + if real { + crate::runtime::focus::begin_body(&ctx); + } + // A held fill-width container is part of the content column it sits in: its own stack is one too. + let (sizing, held) = (self.sizing(&props), self.held(&props, env)); + let content_column = (sizing == Sizing::Content || held || !self.given.0) && matches!(props.layout, layout::BodyLayout::Stack); + let gap = Vec2::splat(gap_of(&env.tokens, props.body_gap)); + let layout_id = sub(id, "layout"); + // The body is measured in the line the real run gives it: what the header and the end region leave. The + // measuring run places it once both have measured, so its end region runs first (its content never depends + // on the body); the real run places it from what they took and keeps reading order. + if !real && is_open && props.end.is_some() { + let mut end_cx = BodyCx::new(body_id, line_env.view(), resolved, regions.end, &mut *cx.core.memory, &mut open, gate.as_mut()) + .with_field_message(field_message.clone()) + .with_owner(owner); + close = close.or(self.end_region(comp, ui, &mut end_cx, &end_frame, &props, regions.end)); + } + let beside = + if real { self.measured_sizes() } else { RegionSizes { header: self.header_size, footer: self.measured_footer, end: self.end_size } }; + if !real { + regions.body = self.regions(&props, inner, pad, room, rtl, beside).body; + } + let line = shared_line(&props, beside); + // B2 label: the control gets the rect the label leaves; the label column adds to the container's extent. + let mut body_rect = regions.body; + let mut label_input = None; + if let Some(side) = props.label.as_ref() { + let resolved = cx.core.resolved; + let input = LabelIn { + scope: id, + owner: id, + parent: node.then_some(id), + row: regions.body, + room: if self.sizing(&props) == Sizing::Content { + layout::ambient_room(&ctx).map_or(room.x, |offered| room.x.max(offered)) + } else { + regions.body.width() + }, + content_row: false, + text: resolved.label_value, + side, + help: props.help.as_ref(), + enabled: resolved.enabled, + size: resolved.size, + control_min: scope::measured_control_min(&ctx, id), + leaf: false, + }; + body_rect = label::run(ui, env, &input).control; + label_input = Some(input); + } + let label_extra = label_extra_of(regions.body, body_rect); + let body_env = line_env.derive_local(|scoped| { + let label_width = label_extra.x; + self.scope_body(scoped, &props, id, BodyScope { room, real, sizing, content_column, scroll, label_width }); + }); + // B3 body, if open, under the body env; the gate is read after the header changed it. + if is_open { + let mut bcx = BodyCx::new(body_id, body_env.view(), resolved, body_rect, &mut *cx.core.memory, &mut open, gate.as_mut()) + .with_field_message(field_message.clone()) + .with_owner(owner); + // While the body opens or closes, it shows only the part of its last height that the presence reaches. + let reveal_clip = (animated && self.presence.t < 1.0).then(|| { + Rect::from_min_max( + body_rect.min, + Pos2::new(body_rect.max.x, body_rect.min.y + self.measured_body.map_or(0.0, |size| size.y) * self.presence.t), + ) + }); + let (layout, body) = (&props.layout, &mut *self.body); + let label_column = props.label_column; + let mut run = |parent: &mut Ui, at: Rect, bcx: &mut BodyCx<'_>| -> Option { + let mut body_ui = alloc::child(parent, { + let builder = UiBuilder::new().max_rect(at).layout(child::column_layout(rtl)).scope_id(body_id); + if node { access::with_parent(builder, id) } else { builder } + }); + style::set_item_spacing(&mut body_ui, gap); + if let Some(clip) = reveal_clip { + body_ui.set_clip_rect(clip.intersect(body_ui.clip_rect())); + } + let installed = Env::install_for(&body_ui, body_env.clone()); + let mut group_extent = None; + // The size the body took: a scrolling body takes the visible part of its content, since its region + // is a child that allocates nothing in `body_ui`. + let took = match scroll { + Some(scroll) => { + let off = self.offset; + let big = crate::contract::MAX_EXTENT; + let bar = scroll_bar_look(&body_env.tokens).thickness; + let inset = overflow_inset(scroll, Vec2::new(self.last.extent.0, self.last.extent.1), at.size(), bar); + let seen = Rect::from_min_max( + Pos2::new(if rtl { at.min.x + inset.x } else { at.min.x }, at.min.y), + Pos2::new(if rtl { at.max.x } else { at.max.x - inset.x }, at.max.y - inset.y), + ); + let (width, height) = + (if scroll.horizontal_on() { big } else { seen.width() }, if scroll.vertical_on() { big } else { seen.height() }); + let x = if scroll.horizontal_on() { off.x as f32 } else { 0.0 }; + let min_x = if rtl { seen.max.x - width + x } else { seen.min.x - x }; + let max = Rect::from_min_size(Pos2::new(min_x, seen.min.y - off.y as f32), Vec2::new(width, height)); + let layout_of = *body_ui.layout(); + let mut region_ui = + alloc::child(&mut body_ui, UiBuilder::new().scope_id(sub(id, "scroll_region")).layout(layout_of).max_rect(max)); + region_ui.set_clip_rect(at.intersect(body_ui.clip_rect())); + // The view this pass shows, where this run lays the content out. + let shown = self.view_offset; + let shift = Vec2::new( + if scroll.horizontal_on() { (shown.x - off.x) as f32 * if rtl { -1.0 } else { 1.0 } } else { 0.0 }, + if scroll.vertical_on() { (shown.y - off.y) as f32 } else { 0.0 }, + ); + let view = crate::runtime::lazy::View { owner: id, rect: seen.translate(shift) }; + let region_env = Env::install_for(®ion_ui, body_env.derive_local(|scoped| scoped.lazy = Some(view))); + layout::run_body(&mut region_ui, layout_id, layout, gap, |ui| { + shared_labels(ui, id, label_column, room.x, &mut group_extent, |ui| body(ui, bcx)) + }); + Env::restore(&ctx, region_env); + let extent = region_ui.min_rect().size(); + if real { + crate::runtime::egui::widgets::note_scroll_region(&ctx, region_ui.clip_rect(), region_ui.min_rect().intersect(max)); + } + self.extent = Some(extent); + // Along an axis it scrolls the body took what the view shows; along the other it took its content. + let took = extent + overflow_inset(scroll, extent, at.size(), bar); + Some(Vec2::new( + if scroll.horizontal_on() { took.x.min(at.width()) } else { took.x }, + if scroll.vertical_on() { took.y.min(at.height()) } else { took.y }, + )) + } + // A row that places its block itself asks for its children's width, not the room it spans. + None => { + let (_, natural) = layout::run_body_measured(&mut body_ui, layout_id, layout, gap, line, |ui| { + shared_labels(ui, id, label_column, room.x, &mut group_extent, |ui| body(ui, bcx)) + }); + natural.map(|width| Vec2::new(width, body_ui.min_rect().height())) + } + }; + Env::restore(&ctx, installed); + let took = took.unwrap_or_else(|| body_ui.min_rect().size()); + // A content-sized column of rows takes, in a measuring run, the width they take at the group's widest + // label: the rows measured before the widest one measured against a narrower column. + let stacked = matches!(layout, layout::BodyLayout::Stack) && !self.given.0; + Some(match group_extent.filter(|_| stacked && !real) { + Some(width) => Vec2::new(took.x.max(width), took.y), + None => took, + }) + }; + self.body_size = match props.transform { + // The measuring run lays the body out on the layer the real run shows it on. + Some(_) if !real => { + let builder = UiBuilder::new().layer_id(areas::body_layer(ui.layer_id(), id)).max_rect(body_rect); + run(&mut alloc::child(ui, builder), body_rect, &mut bcx) + } + Some(transform) => { + let parent = ui.layer_id(); + let layer = areas::body_layer(parent, id); + let tf = areas::body_transform(body_rect.min, transform.scale, transform.offset); + if props.arena { + crate::primitives::sensing::set_layer(&ctx, ArenaId::new(id), layer); + } + let forward = areas::Forward { + id: sub(id, "transform"), + sense: response::to_egui(cx.core.root_sense), + rect: rect.intersect(ui.clip_rect()), + }; + let body_layer = areas::BodyLayer { + parent, + layer, + transform: tf, + at: body_rect.min, + clip: body_rect.intersect(ui.clip_rect()), + forward: Some(forward), + }; + areas::show_body_layer(&ctx, body_layer, |area_ui| run(area_ui, body_rect, &mut bcx)) + } + None => run(ui, body_rect, &mut bcx), + }; + close = close.or(bcx.close_requested()); + // A measuring run decided the label before the control reported its minimum width: it decides again + // from the minimum this run recorded, so the extent it measures is the one the real run lays out. + let mut label_extra = label_extra; + if let (false, Some(input)) = (real, label_input.as_mut()) { + input.control_min = scope::open_control_min(&ctx, id); + // The footer starts under the control column this decision gives, not the one before the control + // reported its minimum. + body_rect = label::control_after(ui, env, input); + label_extra = label_extra_of(regions.body, body_rect); + } + if let Some(size) = &mut self.body_size { + // A body beside its label in a content-sized column of rows reports how far it reaches past the label + // column, so that column's container measures its rows at the widest label. + if let (false, true, Some(side)) = (real, env.content.0, props.label.as_ref().filter(|_| label_extra.x > 0.0 && label_extra.y <= 0.0)) + { + let column = if matches!(side.kind, label::LabelKind::Glyph(_)) { layout::GLYPHS } else { layout::LABELS }; + layout::report_beyond(&ctx, std::slice::from_ref(&column), label::label_gap(env) + size.x); + } + *size += label_extra; + } + self.view = Some(body_rect); + if real && props.end.is_some() { + let mut end_cx = BodyCx::new(body_id, line_env.view(), resolved, regions.end, &mut *cx.core.memory, &mut open, gate.as_mut()) + .with_field_message(field_message.clone()) + .with_owner(owner); + close = close.or(self.end_region(comp, ui, &mut end_cx, &end_frame, &props, regions.end)); + } + } else { + // A collapsed body keeps its last full size in layout memory, so opening it again places by that size + // and asks for no discard pass. + self.body_size = if props.collapse.is_some() { None } else { Some(Vec2::ZERO) }; + } + // The label scope covers the body only: footer controls are not the field's controls. + // A measuring run registers no control, so it leaves the facts the real run records alone. + if props.label.is_some() { + if real { + scope::finish(&ctx, id, None); + } else { + scope::discard(&ctx, id); + } + } + // B4 footer: under the control column of a label-scoped container, which starts where the label step put + // the control. + if props.footer.is_some() { + let (mut footer_rect, offset) = self.place_footer(&props, &mut regions, inner, body_rect, rtl); + // The region's height counts the gap (it is part of what the footer took), so the content starts below it. + let lead = props.footer.and_then(|footer| footer.gap).map_or(0.0, |gap| gap_of(&env.tokens, gap)); + footer_rect.min.y += lead; + footer_rect.max.y = footer_rect.max.y.max(footer_rect.min.y); + let mut bcx = BodyCx::new(body_id, env_view, resolved, footer_rect, &mut *cx.core.memory, &mut open, gate.as_mut()) + .with_field_message(field_message) + .with_owner(owner); + let mut footer_ui = alloc::child(ui, frame.region("footer", footer_rect)); + let installed = Env::install_for(&footer_ui, footer_env); + comp.footer(&mut footer_ui, &mut bcx); + Env::restore(&ctx, installed); + close = close.or(bcx.close_requested()); + let mut took = self.region_size(&footer_ui); + // The footer's width counts from the container's edge, past the column it starts after. + if took.x > 0.0 { + took.x += offset; + } + if took.y > 0.0 { + took.y += lead; + } + self.footer_size = Some(took); + } + self.open = open; + self.gate = gate; + if close.is_some() { + self.close = true; + self.reason = self.reason.or(close); + } + if is_open && scroll.is_some() { + self.paint_scroll_bars(ui, cx, &props, rtl, env); + } + // The surface at the final rect, then the rules. + if let Some(kind) = props.surface { + let shapes = Surface::shapes(&surface_style(&env.tokens, kind), None, rect, Corners::All, env.direction, ctx.pixels_per_point()); + surface_painter.set(surface_slot, Shape::Vec(shapes)); + } + if let Some(kind) = props.header.and_then(|header| header.fill) { + let style = surface_style(&env.tokens, props.surface.unwrap_or(SurfaceKind::Panel)); + let radius = CornerRadius { sw: 0, se: 0, ..style.radius }; + ui.painter().set(band_slot, Shape::rect_filled(regions.header, radius, surface_style(&env.tokens, kind).fill)); + } + paint_rules(ui, &props, env, inner, ®ions); + } + + fn settle(&mut self, comp: &mut C, cx: &mut Cx<'_, C>) { + use crate::contract::Edit as _; + if self.gate != self.gate_at_read + && let Some(gate) = self.gate + && let Ok(value) = (Box::new(gate) as Box).downcast::>() + { + cx.set(*value); + // A viewport mount settles once per child pass: the baseline moves so a change applies once. + self.gate_at_read = self.gate; + } + let id = cx.core.id; + let (collapsible, policy) = { + let props = comp.props(Internal::new()); + (props.collapse.is_some(), props.focus) + }; + // A collapse is the user's own toggle: Escape never folds an inline container, only closes one with an open state. + let closable = !collapsible && comp.open().is_some(); + // The focus inside the scope runs the scope's Escape step; with nothing focused, the window's untaken Escape + // closes a scope whose rule is `Close`. + if !self.layer + && closable + && policy.cancel != CancelRule::Ignore + && match crate::runtime::focus::focus_in_scope(&cx.core.ctx, id) { + Some(true) => matches!( + keys::scope_escape(&cx.core.ctx, policy.cancel, pointer::press_captured(&cx.core.ctx), false), + Some(craft_behavior::focus::EscapeStep::CloseScope) + ), + Some(false) => false, + None => policy.cancel == CancelRule::Close && keys::take_window_cancel(&cx.core.ctx), + } + { + self.close = true; + self.reason = self.reason.or(Some(CloseReason::Escape)); + } + if self.exiting { + // The container closed already; the fade only keeps its body on screen. + self.open = self.open_at_read; + self.close = false; + } + if self.close { + self.open = false; + comp.closed(self.reason.take().unwrap_or(CloseReason::Requested)); + } + self.write_open(comp, cx); + if self.offset != self.offset_at_read { + match comp.scroll() { + Some(mut bind) => { + let (label, doc_key) = (cx.core.label_arc(), cx.core.resolved.doc_key); + bind.apply(&EditEvent::set(Mixed::Same(self.offset_at_read), self.offset, label, doc_key)); + } + None => { + let state = cx.core.memory.session::(sub(cx.core.id, "scroll")); + state.offset = (self.offset.x, self.offset.y); + } + } + self.offset_at_read = self.offset; + } + } + + fn record(&mut self, stage: &mut MemoryStage, ctx: &Context, id: Id) { + if let Some(size) = self.body_size { + crate::contract::steps::record_size(ctx, id, size); + } + if let Some(size) = self.header_size { + crate::contract::steps::record_size(ctx, sub(id, "header"), size); + } + if let Some(size) = self.footer_size { + crate::contract::steps::record_size(ctx, sub(id, "footer"), size); + } + if let Some(size) = self.end_size { + crate::contract::steps::record_size(ctx, sub(id, "end"), size); + } + if let Some(size) = self.controls_size { + crate::contract::steps::record_size(ctx, sub(id, "controls"), size); + } + if self.extent.is_some() || self.view.is_some() { + let view = stage.shown::(sub(id, "view")); + if let Some(extent) = self.extent { + // A bottom-anchored region that follows the end shows the rows that arrived this pass in this + // frame: the repeated pass starts from the new extent. + if self.follows_end && !self.moved && (extent.y - view.extent.1).abs() > 0.5 { + layout_memory::ask_discard(ctx); + } + view.extent = (extent.x, extent.y); + } + view.view = self.view.map(|view| [view.min.x, view.min.y, view.max.x, view.max.y]); + } + if *stage.session::(sub(id, "window_mode")) != self.mode { + *stage.session::(sub(id, "window_mode")) = self.mode.clone(); + } + if self.moved { + let at_end = self.last.view.map(rect_of).is_some_and(|view| self.offset.y >= f64::from(self.last.extent.1 - view.height()) - 0.5); + stage.session::(sub(id, "scroll")).follow_end = Some(at_end); + } + } +} diff --git a/crates/ui-contract/src/contract/body/inherit.rs b/crates/ui-contract/src/contract/body/inherit.rs new file mode 100644 index 000000000..0d9ac25e3 --- /dev/null +++ b/crates/ui-contract/src/contract/body/inherit.rs @@ -0,0 +1,113 @@ +//! What a container's regions and body inherit from the env, and the command scopes it joins. + +use super::BodyHooks; +use super::reorder::REORDER_SCOPE; +use crate::contract::{Container, ContainerProps, Cx, DragBand, Scroll, Sizing}; +use crate::runtime::commands::{self, CommandSet as _, WindowCommand}; +use crate::runtime::env::{AppValues, ArenaId, Scoped}; +use crate::style::{ComponentStyle as _, SurfaceKind}; +use craft_i18n::Direction; +use egui::{Context, Id, Vec2}; + +/// What a container's body env needs from the pass that built it. +pub(super) struct BodyScope { + pub(super) room: Vec2, + pub(super) real: bool, + pub(super) sizing: Sizing, + pub(super) content_column: bool, + pub(super) scroll: Option, + /// The width a side label beside the body took from the container's row. + pub(super) label_width: f32, +} + +/// The surface a container paints under its regions: its props' surface, else its style's in its current state. +pub(super) fn own_surface(props: &ContainerProps, cx: &Cx<'_, C>) -> Option { + props.surface.or_else(|| cx.style.surface().and_then(|look| look.kind_in(&cx.core.state))) +} + +/// Registers the container as an instance of its command scope and of the window scope of its window. +pub(super) fn register_instances(ctx: &Context, props: &ContainerProps, id: Id, window: Option) { + if let Some(scope) = props.command_scope { + commands::register_instance(ctx, scope, id); + } + if let Some(window) = window { + commands::register_instance(ctx, WindowCommand::SCOPE, window); + } +} + +impl BodyHooks<'_> { + /// What the container's regions inherit from the env: its enabled state, window and reorder commands, values, axis, + /// ink and theme. + pub(super) fn scope_regions( + &self, + scoped: &mut Scoped, + props: &ContainerProps, + cx: &Cx<'_, C>, + window: Option, + values: &AppValues, + real: bool, + ) { + let (id, ctx) = (cx.core.id, &cx.core.ctx); + // The container's own `enabled(false)` greys everything inside it, as a scope would. + scoped.enabled &= cx.core.resolved.enabled; + if let Some(window) = window { + scoped.commands = scoped.commands.pushed(WindowCommand::SCOPE, window); + } + scoped.values.extend(values); + if cx.core.resolved.ltr_axis { + scoped.direction = Direction::Ltr; + } + scoped.ink = cx.core.ink; + scoped.surface = SurfaceKind::under(own_surface(props, cx), scoped.surface); + scoped.start_room(); + // Along a width the container takes from its content, its regions measure at their content widths: a child + // that fills takes what it needs, not the whole room. + if !real && !self.given.0 { + scoped.content_column = true; + } + if props.header.is_some_and(|header| header.band == DragBand::Reorder) { + scoped.commands = scoped.commands.pushed(REORDER_SCOPE, id); + } + // A host env (a layer's) does not carry the push the container's own context made. + if let Some(scope) = props.command_scope + && scoped.commands.innermost(scope.name()) != Some(id) + { + scoped.commands = scoped.commands.pushed(scope, id); + } + if let Some(theme) = &props.theme { + theme.apply(ctx, scoped); + } + } + + /// What the body inherits on top of the line's env: arena, transform, the room it is offered and its scroll axes. + pub(super) fn scope_body(&self, scoped: &mut Scoped, props: &ContainerProps, id: Id, body: BodyScope) { + let BodyScope { room, real, sizing, content_column, scroll, label_width } = body; + if props.arena { + scoped.arena = Some(ArenaId::new(id)); + } + scoped.transform = props.transform; + scoped.content_column = content_column; + scoped.row_room = None; + scoped.row_line = None; + // A body with a room height of its own gives that height to the children that fill it. + scoped.content = (!self.given.0, !self.given.1 && props.room_height.is_none()); + // A content-sized container offers its children, in the real run, the width this pass measured it at: a + // child that fits itself into its room (a bar moving items into "More") fits the width the container + // takes, not the room it could have taken. A fill container that is not given the width still takes at + // least the room (`regions`), so it offers the room. + // A side label's column is not the body's: the children are offered what is left beside it. + scoped.offered = (!self.given.0 && room.x.is_finite()).then(|| { + let offered = + if real && sizing == Sizing::Content { self.wanted_width(props).map_or(room.x, |wanted| wanted.min(room.x)) } else { room.x }; + (offered - label_width).max(0.0) + }); + match scroll { + Some(scroll) => { + scoped.scroll_owner = Some(id); + scoped.unbounded = (scroll.horizontal_on(), scroll.vertical_on()); + } + // A container that sized an axis itself (a rect it was shown at, a fixed layer) bounds the room along it. + None => scoped.unbounded = (scoped.unbounded.0 && !self.room.x.is_finite(), scoped.unbounded.1 && !self.room.y.is_finite()), + } + } +} diff --git a/crates/ui-contract/src/contract/body/open.rs b/crates/ui-contract/src/contract/body/open.rs new file mode 100644 index 000000000..e2ff8c952 --- /dev/null +++ b/crates/ui-contract/src/contract/body/open.rs @@ -0,0 +1,54 @@ +//! A container's open state: its session slot, the binding it reads and the write-back when it changed. + +use super::BodyHooks; +use super::placement::opener_of; +use crate::contract::{Container, ContainerProps, Cx, Internal}; +use crate::runtime::memory::{MemoryStage, SaveKey, sub}; +use craft_behavior::{EditEvent, Mixed}; +use egui::Id; +use serde::{Deserialize, Serialize}; + +/// The open state a container with no `Container::open` binding keeps: for the session, or saved under `save`. +#[derive(Clone, Default, Serialize, Deserialize)] +struct OpenState(Option); + +fn open_slot<'s>(stage: &'s mut MemoryStage, id: Id, save: Option<&SaveKey>) -> &'s mut OpenState { + match save { + Some(key) => stage.saved::(key), + None => stage.session::(sub(id, "open")), + } +} + +/// Whether the container is open this pass: its binding, else its opener's state, else its slot. +pub(super) fn open_now(comp: &mut C, stage: &mut MemoryStage, id: Id, props: &ContainerProps) -> bool { + let initially_open = props.collapse.is_none_or(|collapse| collapse.initially_open); + match comp.open() { + Some(bind) => matches!(bind.get(), Some(Mixed::Same(true))), + None => match opener_of(props) { + Some(opener) => crate::contract::overlay::opener_open(stage, opener), + None => *open_slot(stage, id, props.save.as_ref()).0.get_or_insert(initially_open), + }, + } +} + +impl BodyHooks<'_> { + /// Writes the open state when it changed since it was read: to the binding, else to the session slot. + pub(super) fn write_open(&mut self, comp: &mut C, cx: &mut Cx<'_, C>) { + if self.open == self.open_at_read { + return; + } + let id = cx.core.id; + let opener = opener_of(comp.props(Internal::new())).cloned(); + match comp.open() { + Some(mut bind) => { + let (label, doc_key) = (cx.core.label_arc(), cx.core.resolved.doc_key); + bind.apply(&EditEvent::set(Mixed::Same(self.open_at_read), self.open, label, doc_key)); + } + None => match &opener { + Some(opener) => crate::contract::overlay::set_opener_open(&mut *cx.core.memory, opener, self.open), + None => open_slot(&mut *cx.core.memory, id, self.save.as_ref()).0 = Some(self.open), + }, + } + self.open_at_read = self.open; + } +} diff --git a/crates/ui-contract/src/contract/body/pane.rs b/crates/ui-contract/src/contract/body/pane.rs new file mode 100644 index 000000000..c7e26c204 --- /dev/null +++ b/crates/ui-contract/src/contract/body/pane.rs @@ -0,0 +1,109 @@ +//! The grip of an edge pane and its drag. + +use super::BodyHooks; +use crate::contract::mount::{PaneGrip, pane_extent_id, pane_grip_id}; +use crate::contract::overlay::{PlacementChange, PlacementKind}; +use crate::contract::{Container, ContainerProps, Cx, Mount, PaneEdge, PartsCx}; +use crate::runtime::layout_memory; +use crate::runtime::windows::ResizeEdge; +use craft_behavior::{CursorIcon, GesturePhase, HitLevel, HitPriority, PartKey, PressPhase}; +use egui::{Pos2, Rect, Vec2}; + +/// The grip on an edge pane's inner edge. +const PANE_GRIP: PartKey = PartKey::new("pane_grip"); + +impl BodyHooks<'_> { + /// The grip of an edge pane (`Mount::Pane`) on its inner edge, the edge toward the centre, inside the pane: dragging + /// it gives the pane a new extent along its edge (`pane_drag`). A pane its caller lays out (`ShellPane::at`) and the + /// central pane have none. Returns the edge the grip sits on and the least extent it gives. + pub(super) fn pane_grip(props: &ContainerProps, rect: Rect, pcx: &mut PartsCx<'_, C>) -> Option<(ResizeEdge, f32)> { + let Mount::Pane(pane) = &props.mount else { return None }; + let rtl = pcx.flow.is_rtl(); + let edge = match pane.edge { + _ if pane.at.is_some() => return None, + PaneEdge::Start if rtl => ResizeEdge::Left, + PaneEdge::Start => ResizeEdge::Right, + PaneEdge::End if rtl => ResizeEdge::Right, + PaneEdge::End => ResizeEdge::Left, + PaneEdge::Top => ResizeEdge::Bottom, + PaneEdge::Bottom => ResizeEdge::Top, + _ => return None, + }; + let tokens = pcx.tokens.tokens(); + let (handle, least) = (tokens.size.handle.sm, tokens.size.pane.least); + let (grip, cursor) = match edge { + ResizeEdge::Left => (Rect::from_min_max(rect.min, Pos2::new(rect.min.x + handle, rect.max.y)), CursorIcon::ResizeHorizontal), + ResizeEdge::Right => (Rect::from_min_max(Pos2::new(rect.max.x - handle, rect.min.y), rect.max), CursorIcon::ResizeHorizontal), + ResizeEdge::Top => (Rect::from_min_max(rect.min, Pos2::new(rect.max.x, rect.min.y + handle)), CursorIcon::ResizeVertical), + _ => (Rect::from_min_max(Pos2::new(rect.min.x, rect.max.y - handle), rect.max), CursorIcon::ResizeVertical), + }; + pcx.part(PANE_GRIP, grip) + .sense(craft_behavior::Sense::DRAG) + .priority(HitPriority::new(HitLevel::Edge, 0)) + .cursor(cursor) + .pointer_only("no command resizes a docked pane; its extent is the app's layout"); + Some((edge, least)) + } + + /// A drag of an edge pane's grip: the pane's extent follows the pointer, at least the least extent, and each step + /// is reported as a `PlacementKind::Size` change of the pane's rect. While the gesture runs the pane host shows its + /// extent (`PaneGrip`); at the commit a pane with no fixed extent keeps it in pane memory, and one whose caller fixes + /// the extent shows the caller's from the next pass. Escape, which cancels the press, restores the extent. + pub(super) fn pane_drag(&mut self, props: &ContainerProps, cx: &mut Cx<'_, C>) { + let (Mount::Pane(pane), Some((edge, least))) = (&props.mount, self.pane_grip) else { return }; + let Some(phase) = cx.core.results.get(&(PANE_GRIP, None)).map(|result| result.press.phase) else { return }; + let (origin, pos, gesture) = match phase { + PressPhase::DragStart { start, pos, .. } => (start.origin, Some(pos), GesturePhase::Begin), + PressPhase::Drag { start, pos, .. } => (start.origin, Some(pos), GesturePhase::Update), + PressPhase::Release { start, pos, .. } => (start.origin, Some(pos), GesturePhase::Commit), + PressPhase::Cancel { start, .. } => (start.origin, None, GesturePhase::Cancel), + _ => return, + }; + let (ctx, id, rect) = (cx.core.ctx.clone(), cx.core.id, cx.core.rect); + let horizontal = matches!(edge, ResizeEdge::Left | ResizeEdge::Right); + let along = |size: Vec2| if horizontal { size.x } else { size.y }; + let slot = cx.core.memory.shown::(pane_grip_id(id)); + let shown = slot.extent; + let began = match slot.began { + Some(began) if gesture != GesturePhase::Begin => began, + _ => along(rect.size()), + }; + let moved = pos.map_or(0.0, |pos| match edge { + ResizeEdge::Right => pos.x - origin.x, + ResizeEdge::Left => origin.x - pos.x, + ResizeEdge::Bottom => pos.y - origin.y, + _ => origin.y - pos.y, + }); + let extent = (began + moved).max(least); + let resized = |extent: f32| match edge { + ResizeEdge::Right => Rect::from_min_size(rect.min, Vec2::new(extent, rect.height())), + ResizeEdge::Left => Rect::from_min_max(Pos2::new(rect.max.x - extent, rect.min.y), rect.max), + ResizeEdge::Bottom => Rect::from_min_size(rect.min, Vec2::new(rect.width(), extent)), + _ => Rect::from_min_max(Pos2::new(rect.min.x, rect.max.y - extent), rect.max), + }; + let change = |rect: Rect, phase: GesturePhase| PlacementChange { rect, phase, pointer: pos, kind: PlacementKind::Size(edge) }; + if gesture == GesturePhase::Begin { + self.reports.push(change(resized(began), GesturePhase::Begin)); + } + let (phase, extent) = match gesture { + GesturePhase::Begin => (GesturePhase::Update, extent), + GesturePhase::Cancel => (GesturePhase::Cancel, began), + phase => (phase, extent), + }; + self.reports.push(change(resized(extent), phase)); + *slot = if matches!(phase, GesturePhase::Commit | GesturePhase::Cancel) { + PaneGrip::default() + } else { + PaneGrip { began: Some(began), extent: Some(extent) } + }; + if phase == GesturePhase::Commit && pane.extent.is_none() { + let size = rect.size(); + layout_memory::record(&ctx, pane_extent_id(id), if horizontal { Vec2::new(extent, size.y) } else { Vec2::new(size.x, extent) }); + } + // The pane showed this pass at the extent of the last step: a commit or cancel that lands elsewhere shows in + // the frame's discard pass. + if matches!(phase, GesturePhase::Commit | GesturePhase::Cancel) && shown.is_some_and(|shown| (shown - extent).abs() > 0.5) { + layout_memory::ask_discard(&ctx); + } + } +} diff --git a/crates/ui-contract/src/contract/body/placement.rs b/crates/ui-contract/src/contract/body/placement.rs new file mode 100644 index 000000000..52404b250 --- /dev/null +++ b/crates/ui-contract/src/contract/body/placement.rs @@ -0,0 +1,143 @@ +//! Where a container on a layer sits: its remembered placement and the overlay and opener of its mount. + +use crate::contract::overlay::{OverlayFit, Place}; +use crate::contract::{ContainerProps, Mount}; +use crate::runtime::egui::areas; +use crate::runtime::memory::{MemoryStage, SaveKey, sub}; +use crate::runtime::windows::{self}; +use egui::{Context, Id, Pos2, Rect, Ui, Vec2}; +use serde::{Deserialize, Serialize}; + +/// Where a container on a layer sits and how large the user made it. +#[derive(Clone, Default, Serialize, Deserialize, PartialEq)] +pub(crate) struct Placement { + pub pos: Option<[f32; 2]>, + pub size: Option<[f32; 2]>, +} + +impl Placement { + /// The placement that puts the layer at `rect`. + pub(super) fn at(rect: Rect) -> Placement { + Placement { pos: Some(rect.min.into()), size: Some(rect.size().into()) } + } + + /// The placement that puts the layer's top left at `pos` and leaves its size to its content. + fn at_pos(pos: Pos2) -> Placement { + Placement { pos: Some(pos.into()), size: None } + } + + /// The placement the caller of `overlay` gives, when it places the layer. + fn given(overlay: &crate::contract::Overlay) -> Option { + overlay.placed.map(Placement::at).or_else(|| overlay.placed_at.map(Placement::at_pos)) + } + + /// The rect it names, taking the position and size it lacks from `rect`. + pub(super) fn rect_over(&self, rect: Rect) -> Rect { + Rect::from_min_size(self.pos.map_or(rect.min, Pos2::from), self.size.map_or(rect.size(), Vec2::from)) + } +} + +pub(crate) fn placement_id(id: Id) -> Id { + sub(id, "placement") +} + +/// The one store of a layer's placement: the saved tier when `save` is set, else shown memory. A layer whose overlay +/// is `placed` has the caller's rect instead: the slot reads it and writes nothing, since the caller owns the +/// placement and learns of the user's changes from `PlacementChange` reports. +pub(super) struct PlacementSlot<'s> { + stage: &'s mut MemoryStage, + id: Id, + save: Option<&'s SaveKey>, + controlled: Option, +} + +impl<'s> PlacementSlot<'s> { + pub(super) fn new(stage: &'s mut MemoryStage, id: Id, save: Option<&'s SaveKey>, overlay: &crate::contract::Overlay) -> Self { + PlacementSlot { stage, id, save, controlled: Placement::given(overlay) } + } + + fn stored(&mut self) -> &mut Placement { + match self.save { + Some(key) => self.stage.saved::(key), + None => self.stage.shown::(placement_id(self.id)), + } + } + + pub(super) fn read(&mut self) -> Placement { + match &self.controlled { + Some(placement) => placement.clone(), + None => self.stored().clone(), + } + } + + pub(super) fn write(&mut self, placement: Placement) { + if self.controlled.is_none() { + *self.stored() = placement; + } + } +} + +/// The placement of `id` as the last pass left it, read without opening a stage: the layer host places by it before +/// the container's own pass runs. +fn placement_of(ctx: &Context, id: Id, save: Option<&SaveKey>) -> Placement { + match save { + Some(key) => MemoryStage::peek_saved(ctx, key), + None => MemoryStage::peek(ctx, placement_id(id)), + } +} + +/// The placement a layer is shown at: the caller's `placed` rect or `placed_at` position, else the saved or session placement, else for a +/// floating resizable layer with a default size (`Overlay::size`) that size, within the screen less `screen_inset` on +/// each side, centred or at the overlay's float position. A saved size and position win over the default. +pub(crate) fn shown_placement( + ctx: &Context, + id: Id, + save: Option<&SaveKey>, + overlay: &crate::contract::Overlay, + screen: Rect, + screen_inset: f32, +) -> Placement { + if let Some(given) = Placement::given(overlay) { + return given; + } + let mut placement = placement_of(ctx, id, save); + let (Some(default), Place::Float(float), true) = (overlay.size, &overlay.place, overlay.fit == OverlayFit::Resizable) else { + return placement; + }; + if placement.size.is_some() { + return placement; + } + let room = (screen.size() - Vec2::splat(2.0 * screen_inset)).max(Vec2::ZERO); + let least = overlay.size_limits.min.min(room); + let size = default.max(least).min(overlay.size_limits.max.unwrap_or(Vec2::INFINITY)).min(room); + let pos = placement.pos.map(Pos2::from).or(float.pos).unwrap_or_else(|| screen.center() - size / 2.0); + let pos = Pos2::new(pos.x.min(screen.right() - size.x).max(screen.left()), pos.y.min(screen.bottom() - size.y).max(screen.top())); + placement.pos = Some(pos.into()); + placement.size = Some(size.into()); + placement +} + +/// The overlay a layer-like mount shows its container in. +pub(super) fn overlay_of(props: &ContainerProps) -> Option<&crate::contract::Overlay> { + match &props.mount { + Mount::Layer(overlay) | Mount::Viewport { fallback: overlay, .. } => Some(overlay), + _ => None, + } +} + +/// The layer a measuring run lays the regions out on: the one the real run shows them on, since egui keeps a +/// region's `Ui` on one layer per pass. A viewport's own window keeps its widgets apart, so it measures on the parent's. +pub(super) fn measure_layer(props: &ContainerProps, id: Id, ui: &Ui) -> areas::Layer { + let area = sub(id, "area"); + match &props.mount { + Mount::Viewport { .. } if windows::WindowHost::of(ui.ctx()).viewports_available() => ui.layer_id(), + Mount::Layer(overlay) | Mount::Viewport { fallback: overlay, .. } => areas::layer_of(overlay.rank.tier(), area), + Mount::FullWindow => areas::layer_of(crate::contract::mount::full_window_overlay(props.focus).rank.tier(), area), + _ => ui.layer_id(), + } +} + +/// The opener of a layer-like mount's overlay: a container with no `open` binding takes its open state from it. +pub(super) fn opener_of(props: &ContainerProps) -> Option<&crate::contract::overlay::Opener> { + overlay_of(props)?.opener.as_ref() +} diff --git a/crates/ui-contract/src/contract/body/presses.rs b/crates/ui-contract/src/contract/body/presses.rs new file mode 100644 index 000000000..72a0816e3 --- /dev/null +++ b/crates/ui-contract/src/contract/body/presses.rs @@ -0,0 +1,83 @@ +//! What a container's hooks read of this pass's presses: on its surface, on its parts and the move band's double click. + +use super::BodyHooks; +use super::window::MOVE_BAND; +use crate::contract::cx::BodyCx; +use crate::contract::{Container, Cx}; +use crate::runtime::egui::areas; +use crate::runtime::memory::sub; +use crate::runtime::pointer; +use craft_behavior::{Cursor, CursorPriority, PartRef, PressState}; + +/// Whether the second press of a double click went down on the container's move band in this pass. +#[derive(Clone, Default)] +struct BandDouble(bool); + +/// Whether the primary press of this pass went down on the container's own surface (`Sense::SURFACE`). +#[derive(Clone, Default)] +struct SurfacePress(bool); + +impl BodyCx<'_> { + /// Whether the second press of a double click went down on the container's move band in this pass. The body step + /// only reports it; the container decides what it means (a title bar maximizes the window, a floating frame + /// minimizes it). A band double click that the container never reads does nothing. A measuring run sees none: the + /// record it would read is last pass's, and a container that latches it would report the click twice. + pub fn band_double_pressed(&self) -> bool { + !self.memory.is_peek() && self.memory.recall::(sub(self.id, "band_double")).0 + } + + /// The press state of the container's own part `part` in this pass, the same in a measuring run and in the real + /// run: the container's press machine steps before the measuring run, from the parts it declared last pass (a + /// part declared first this pass reads idle). Idle for a container that has not stepped. + pub fn part_press(&self, part: impl Into) -> PressState { + crate::primitives::sensing::part_press(self.memory.ctx(), self.resolved.id, part.into()).press + } + + /// Whether the primary press of this pass went down on the container's own surface, for a root that senses + /// `Sense::SURFACE`: inside its rect, on its layer, where none of its children or parts takes the press. The + /// container decides what it means (a dock group focuses its panel, as Photoshop does); it is no click and moves + /// no focus by itself. + pub fn surface_pressed(&self) -> bool { + self.memory.recall::(sub(self.id, "surface_press")).0 + } + + /// Requests `cursor` at `priority` for this pass, in the cursor service the parts' and components' requests go + /// to: the highest priority of the pass wins, the later request on a tie. A body that learns something only after + /// its children ran (a drag its panes report as refused) sets the cursor in the same pass. A measuring run + /// requests nothing. + pub fn cursor(&mut self, cursor: impl Into, priority: CursorPriority) { + if !self.memory.is_peek() { + crate::runtime::cursor::request(self.memory.ctx(), cursor.into(), priority); + } + } +} + +impl BodyHooks<'_> { + /// Records for the container's hooks whether this pass's primary press went down on its own surface + /// (`BodyCx::surface_pressed`): no shape of last pass under the press takes it, and the press lies in the + /// container's rect on its layer. + pub(super) fn surface_press(&self, sensed: bool, cx: &mut Cx<'_, C>) { + let ctx = cx.core.ctx.clone(); + let pressed = sensed && { + let pass = pointer::pass_pointer(&ctx); + pass.frame.as_ref().and_then(|frame| frame.press).filter(|press| press.button == craft_behavior::PointerButton::Primary).is_some_and( + |press| { + let layer = cx.core.response.layer_id; + let at = areas::layer_map(&ctx, layer).map_or(press.origin, |map| map.to_layer(press.origin)); + areas::layer_at(&ctx, press.origin) == Some(layer) + && cx.core.rect.contains(at) + && pointer::press_winner(&ctx, press.origin, pass.press_targets).is_none() + }, + ) + }; + cx.core.memory.shown::(sub(sub(cx.core.id, "body"), "surface_press")).0 = pressed; + } + + /// Records for the container's header hooks whether the second press of a double click went down on the move + /// band in this pass (`BodyCx::band_double_pressed`). + pub(super) fn band_double(&self, cx: &mut Cx<'_, C>) { + let Some(band) = cx.core.results.get(&(MOVE_BAND, None)) else { return }; + let double = band.press.double_pressed(); + cx.core.memory.shown::(sub(sub(cx.core.id, "body"), "band_double")).0 = double; + } +} diff --git a/crates/ui-contract/src/contract/body/regions.rs b/crates/ui-contract/src/contract/body/regions.rs new file mode 100644 index 000000000..5047db1bc --- /dev/null +++ b/crates/ui-contract/src/contract/body/regions.rs @@ -0,0 +1,392 @@ +//! Where the header, body, footer and end regions sit inside the container, and the rules between them. + +use super::BodyHooks; +use crate::contract::cx::BodyCx; +use crate::contract::{Container, ContainerProps, FooterPlace, Gap, LeastWidth, Pad, Sizing}; +use crate::layout::ColumnGroup; +use crate::primitives::Rule; +use crate::runtime::access::{self}; +use crate::runtime::egui::{alloc, child, style}; +use crate::runtime::env::Env; +use crate::runtime::memory::sub; +use crate::runtime::overlay::CloseReason; +use crate::style::{RuleKind, UiTokens, rule_look}; +use egui::{Align, Id, Layout, Pos2, Rect, Ui, UiBuilder, Vec2}; + +/// Whether the footer sits in the end region: it asks to, and the container has one. +pub(super) fn footer_in_end(props: &ContainerProps) -> bool { + props.end.is_some() && props.footer.is_some_and(|footer| footer.place.in_end()) +} + +/// Whether the end region takes the full height under the header: it asks to, or the footer sits in it. +pub(super) fn end_full_height(props: &ContainerProps) -> bool { + props.end.is_some_and(|end| end.full_height) || footer_in_end(props) +} + +/// The line a body shares with an inline header or an end region beside it, from what they took (`sizes`): as high +/// as the taller of the two. `None` for a body that shares no line. +pub(super) fn shared_line(props: &ContainerProps, sizes: RegionSizes) -> Option { + let header = props.header.filter(|header| header.inline).and(sizes.header).map(|took| took.y); + let end = props.end.filter(|_| !end_full_height(props)).and(sizes.end).map(|took| took.y); + header.into_iter().chain(end).reduce(f32::max).filter(|line| *line > 0.0) +} + +#[doc(hidden)] +pub fn pad_of(tokens: &UiTokens, pad: Pad) -> f32 { + let pads = &tokens.tokens().space.pad; + match pad { + Pad::Control => pads.control, + Pad::Regular => pads.regular, + Pad::Roomy => pads.roomy, + _ => 0.0, + } +} + +/// The space `props`' stacked header leaves before the body: its `HeaderRegion::gap`, none without one. +pub(super) fn header_gap_of(props: &ContainerProps, tokens: &UiTokens) -> f32 { + props.header.and_then(|header| header.gap).map_or(0.0, |gap| gap_of(tokens, gap)) +} + +impl Gap { + /// The gap in points, in the tokens `ui` shows with: for a host that decides how many children fit in a row. + pub fn points(self, ui: &Ui) -> f32 { + gap_of(&Env::of(ui).tokens, self) + } +} + +pub(super) fn gap_of(tokens: &UiTokens, gap: Gap) -> f32 { + let gaps = &tokens.tokens().space.gap; + match gap { + Gap::None => 0.0, + Gap::Tight => gaps.tight, + Gap::Stack => gaps.stack, + Gap::Item => gaps.item, + Gap::Section => gaps.section, + Gap::CardColumn => gaps.card_column, + Gap::CardRow => gaps.card_row, + _ => gaps.row, + } +} + +pub(super) fn least_of(tokens: &UiTokens, least: Option) -> f32 { + match least { + Some(LeastWidth::Popup) => tokens.tokens().size.popup_min, + None => 0.0, + } +} + +pub(super) fn rect_of(parts: [f32; 4]) -> Rect { + Rect::from_min_max(Pos2::new(parts[0], parts[1]), Pos2::new(parts[2], parts[3])) +} + +/// The regions of a container inside its rect. +pub(super) struct Regions { + pub(super) header: Rect, + pub(super) body: Rect, + /// The end region: the line's end edge, as high as the line or, full height, from under the header to the + /// container's bottom, less a footer placed in it. + pub(super) end: Rect, + footer: Rect, +} + +/// The sizes of the header, footer and end region that the regions are placed from (zero or `None` for a region the +/// container lacks or that has not measured). +#[derive(Clone, Copy)] +pub(super) struct RegionSizes { + pub(super) header: Option, + pub(super) footer: Vec2, + pub(super) end: Option, +} + +/// What every region of a container shares: its id, direction, whether it is an AccessKit node and its env. +pub(super) struct RegionFrame<'e> { + pub(super) id: Id, + pub(super) rtl: bool, + pub(super) node: bool, + pub(super) env: &'e Env, +} + +impl RegionFrame<'_> { + /// The ui builder of the region `name` in `rect`. + pub(super) fn region(&self, name: &'static str, rect: Rect) -> UiBuilder { + let builder = UiBuilder::new().max_rect(rect).layout(child::column_layout(self.rtl)).scope_id(sub(self.id, name)); + if self.node { access::with_parent(builder, self.id) } else { builder } + } +} + +/// The divider rules above and under the header and above the footer. +pub(super) fn paint_rules(ui: &mut Ui, props: &ContainerProps, env: &Env, inner: Rect, regions: &Regions) { + let rule = rule_look(&env.tokens, RuleKind::Divider); + let ppp = ui.ctx().pixels_per_point(); + let draw_rule = |from: f32, to: f32, y: f32| ui.painter().extend(Rule::shapes(&rule, Pos2::new(from, y), Pos2::new(to, y), ppp)); + if props.header.is_some_and(|header| header.rule_above) { + draw_rule(inner.min.x, inner.max.x, regions.header.min.y); + } + if props.header.is_some_and(|header| header.rule && !header.inline) { + draw_rule(inner.min.x, inner.max.x, regions.header.max.y); + } + // A footer across the container rules the whole width; one beside or in the end region rules its own. + match props.footer.filter(|footer| footer.rule) { + Some(footer) if footer.place == FooterPlace::EndTop && footer_in_end(props) => { + draw_rule(regions.footer.min.x, regions.footer.max.x, regions.footer.max.y); + } + Some(_) if end_full_height(props) => draw_rule(regions.footer.min.x, regions.footer.max.x, regions.footer.min.y), + Some(_) => draw_rule(inner.min.x, inner.max.x, regions.footer.min.y), + None => {} + } +} + +impl BodyHooks<'_> { + /// The footer's rect and how far its left edge lies past the container's, under the control column of a + /// label-scoped container; along an axis the room leaves unbounded, the footer follows the body and the end region. + pub(super) fn place_footer(&self, props: &ContainerProps, regions: &mut Regions, inner: Rect, body_rect: Rect, rtl: bool) -> (Rect, f32) { + // Along an axis the room leaves unbounded (a measuring run) the footer follows the body and the end region + // it ran after; along a bounded axis it sits at the far edge. + if !inner.max.y.is_finite() && !footer_in_end(props) { + let mut bottom = regions.body.min.y + self.body_size.map_or(0.0, |size| size.y); + if props.end.is_some() && !end_full_height(props) { + bottom = bottom.max(regions.end.min.y + self.end_size.map_or(0.0, |size| size.y)); + } + regions.footer.min.y = bottom; + regions.footer.max.y = bottom + self.measured_footer.y; + } + let mut footer_rect = regions.footer; + if props.label.is_some() { + if rtl { + footer_rect.max.x = body_rect.max.x.clamp(footer_rect.min.x, footer_rect.max.x); + } else { + footer_rect.min.x = body_rect.min.x.clamp(footer_rect.min.x, footer_rect.max.x); + } + } + let offset = if rtl { regions.footer.max.x - footer_rect.max.x } else { footer_rect.min.x - regions.footer.min.x }; + (footer_rect, offset) + } +} + +impl<'b> BodyHooks<'b> { + /// The header region (B1): the trailing controls take the end edge first (in call order, as a box at the edge) + /// and the header fills what they leave. Records the header's size and returns the close it asked for. + pub(super) fn header_region( + &mut self, + comp: &mut C, + ui: &mut Ui, + bcx: &mut BodyCx<'_>, + frame: &RegionFrame<'_>, + header: Rect, + trailing: bool, + inset: f32, + ) -> Option { + let ctx = ui.ctx().clone(); + let (id, rtl) = (frame.id, frame.rtl); + let mut header_rect = header.shrink2(Vec2::new(inset, 0.0)); + let mut controls = Vec2::ZERO; + if trailing { + // The controls keep their call order (first at the start of their box); the box sits at the end edge. + let layout = if rtl { Layout::right_to_left(Align::Center) } else { Layout::left_to_right(Align::Center) }; + // The box is as wide as the measuring run found it, at the end edge; in the measuring run it spans the header. + let room = match self.measured_controls.map(|measured| measured.x).filter(|_| header.width().is_finite()) { + Some(width) if rtl => Rect::from_min_max(header.min, Pos2::new((header.min.x + width).min(header.max.x), header.max.y)), + Some(width) => Rect::from_min_max(Pos2::new((header.max.x - width).max(header.min.x), header.min.y), header.max), + None => header, + }; + let builder = UiBuilder::new().max_rect(room).layout(layout).scope_id(sub(id, "controls")); + let builder = if frame.node { access::with_parent(builder, id) } else { builder }; + let mut controls_ui = alloc::child(ui, builder); + // The same spacing in the measuring run and the placing run, whatever the parent's item spacing is. + style::set_item_spacing(&mut controls_ui, Vec2::splat(gap_of(&frame.env.tokens, Gap::Item))); + let installed = Env::install_for(&controls_ui, frame.env.clone()); + comp.controls(&mut controls_ui, bcx); + Env::restore(&ctx, installed); + controls = controls_ui.min_rect().size(); + self.controls_size = Some(controls); + if controls.x > 0.0 { + let cut = controls.x + self.region_gap; + if rtl { + header_rect.min.x = (header_rect.min.x + cut).min(header_rect.max.x); + } else { + header_rect.max.x = (header_rect.max.x - cut).max(header_rect.min.x); + } + } + } + let mut header_ui = alloc::child(ui, frame.region("header", header_rect)); + let installed = Env::install_for(&header_ui, frame.env.clone()); + comp.header(&mut header_ui, bcx); + Env::restore(&ctx, installed); + let mut took = self.region_size(&header_ui); + if controls.x > 0.0 { + took.x += controls.x + self.region_gap; + } + took.y = took.y.max(controls.y); + took.x += 2.0 * inset; + self.header_size = Some(took); + bcx.close_requested() + } + + /// The end region: its content runs in reading order, so its roving order is its order on the line; the region + /// is as wide as it measured, so the last child sits at the end edge. On the line it is centred; a full-height + /// region starts at its top. Records the region's size and returns the close it asked for. + pub(super) fn end_region( + &mut self, + comp: &mut C, + ui: &mut Ui, + bcx: &mut BodyCx<'_>, + frame: &RegionFrame<'_>, + props: &ContainerProps, + end: Rect, + ) -> Option { + let cross = if end_full_height(props) { Align::Min } else { Align::Center }; + let layout = if frame.rtl { Layout::right_to_left(cross) } else { Layout::left_to_right(cross) }; + let builder = UiBuilder::new().max_rect(end).layout(layout).scope_id(sub(frame.id, "end")); + let builder = if frame.node { access::with_parent(builder, frame.id) } else { builder }; + let mut end_ui = alloc::child(ui, builder); + let installed = Env::install_for(&end_ui, frame.env.clone()); + comp.end(&mut end_ui, bcx); + Env::restore(ui.ctx(), installed); + self.end_size = Some(self.region_size(&end_ui)); + bcx.close_requested() + } + + /// The space under a stacked header `header_h` high: `HeaderRegion::gap` while the body shows, scaled by its presence. + pub(super) fn header_space(&self, header_h: f32) -> f32 { + if header_h > 0.0 { self.header_gap * self.presence.t } else { 0.0 } + } + + /// The regions inside `inner` (the rect minus padding and the padding tier), placed from `sizes`. A header with a + /// band spreads over the `bleed` the padding leaves around `inner` at the top and the sides. + pub(super) fn regions(&self, props: &ContainerProps, inner: Rect, bleed: f32, room: Vec2, rtl: bool, sizes: RegionSizes) -> Regions { + let inline = props.header.is_some_and(|header| header.inline); + let (in_end, full) = (footer_in_end(props), end_full_height(props)); + let header_h = if props.header.is_some() { sizes.header.unwrap_or(Vec2::ZERO).y } else { 0.0 }; + let footer_h = if props.footer.is_some() { sizes.footer.y } else { 0.0 }; + // A footer in the end region takes no band across the container: it stacks with the end region's content. + let across_h = if in_end { 0.0 } else { footer_h }; + let end_h = sizes.end.map_or(0.0, |end| end.y) + if in_end { footer_h } else { 0.0 }; + // An inline header takes no height of its own: the line is as high as the taller of header and body. + let stacked_h = if inline { 0.0 } else { header_h + self.header_space(header_h) }; + let top = inner.min.y + stacked_h; + // Along an axis the container is not given, its body is offered the room the container was offered and the + // container takes what the body took. + let content_sized = self.sizing(props) == Sizing::Content; + let content_y = content_sized || ((self.sizing(props) == Sizing::Fill || !inner.max.y.is_finite()) && !self.given.1); + let (bottom, footer_top) = if content_y { + let body_room = (room.y - stacked_h - across_h).max(0.0); + // A body that fills records the band it was given, which may predate the footer's measure: the line is + // never taller than the room less header and footer, so the footer stays inside the room. + let body_h = (self.measured_body.map_or(0.0, |size| size.y) * self.presence.t).min(body_room); + let line_h = if inline { body_h.max(header_h) } else { body_h }; + // A full-height end region stands beside the footer too, so only the part of it under the line counts. + let end_line = if full { (end_h - across_h).max(0.0) } else { end_h }; + (top + body_room, top + line_h.max(end_line).min(body_room)) + } else { + // A fill-width body is offered the room the parent gives this pass, never the height its content took last + // pass: a collection that scrolls takes its rows up to that room, and from zero it would stay at zero. + // An inline header shares the line with the body, so the body is offered that line: as high as the tallest of + // header, end region and the body this pass measured, at most the room. + let body_room = (room.y - stacked_h - across_h).max(0.0); + let offered = (self.sizing(props) == Sizing::FillWidth && room.y.is_finite()).then(|| { + let line = if inline && self.measured_body.is_some() { + header_h.max(end_h).max(self.measured_body.map_or(0.0, |size| size.y)).min(body_room) + } else { + body_room + }; + top + line + }); + (offered.unwrap_or(inner.max.y - across_h), inner.max.y - across_h) + }; + let width = if content_sized { + self.shared_width(room.x, props) + } else if !self.given.0 { + self.shared_width(room.x, props).max(inner.width()) + } else { + inner.width() + }; + let (left, right) = if rtl { (inner.max.x - width, inner.max.x) } else { (inner.min.x, inner.min.x + width) }; + let band = |top: f32, bottom: f32| Rect::from_min_max(Pos2::new(left, top), Pos2::new(right, bottom.max(top))); + let header = band(inner.min.y, if props.header.is_some() { inner.min.y + header_h.max(0.0) } else { inner.min.y }); + let mut body = band(top, bottom); + let header = if inline { + // The header keeps the width it measured, none when it measured nothing; before its first measure it + // takes the whole line. The body takes the rest. + let head_w = sizes.header.map_or(width, |took| took.x.min(width)); + let cut = if head_w > 0.0 { (head_w + self.region_gap).min(width) } else { 0.0 }; + if rtl { + body.max.x = right - cut; + Rect::from_min_max(Pos2::new(right - head_w, header.min.y), header.max) + } else { + body.min.x = left + cut; + Rect::from_min_max(header.min, Pos2::new(left + head_w, header.max.y)) + } + } else { + header + }; + // The end region keeps the width it measured (with a footer in it, the wider of the two) and takes the end + // edge; the body takes the rest. Before its first measure it spans the line and the body keeps its width. + let measured = props.end.and(sizes.end).map(|end| { + let footer_w = if in_end { sizes.footer.x } else { 0.0 }; + end.x.max(footer_w).min(width) + }); + let taken = measured.unwrap_or(0.0); + let cut = if taken > 0.0 { taken + self.region_gap } else { 0.0 }; + let end_w = measured.unwrap_or(width); + let end_bottom = if full { footer_top + across_h } else { footer_top }; + let mut end = if rtl { + Rect::from_min_max(Pos2::new(left, top), Pos2::new(left + end_w, end_bottom.max(top))) + } else { + Rect::from_min_max(Pos2::new(right - end_w, top), Pos2::new(right, end_bottom.max(top))) + }; + if rtl { + body.min.x = (body.min.x + cut).min(body.max.x); + } else { + body.max.x = (body.max.x - cut).max(body.min.x); + } + let footer = match props.footer.map(|footer| footer.place) { + Some(FooterPlace::EndTop) if in_end => { + let footer = Rect::from_min_max(end.min, Pos2::new(end.max.x, (end.min.y + footer_h).min(end.max.y))); + end.min.y = footer.max.y; + footer + } + _ if in_end => { + let footer = Rect::from_min_max(Pos2::new(end.min.x, (end.max.y - footer_h).max(end.min.y)), end.max); + end.max.y = footer.min.y; + footer + } + // Beside a full-height end region the footer lies under the body only. + _ if full && props.end.is_some() => Rect::from_min_max(Pos2::new(body.min.x, footer_top), Pos2::new(body.max.x, footer_top + footer_h)), + _ => band(footer_top, footer_top + footer_h), + }; + let header = if props.header.is_some_and(|header| header.fill.is_some()) { + Rect::from_min_max(header.min - Vec2::splat(bleed), Pos2::new(header.max.x + bleed, header.max.y - bleed)) + } else { + header + }; + Regions { header, body, end, footer } + } +} + +/// The extent a label takes from `body` by placing the control at `control`. The label takes its column either by +/// narrowing the control's rect or by shifting it along the row, which a content-sized row (unbounded to the end) +/// does; the extent grows by whichever of the two is finite. +pub(super) fn label_extra_of(body: Rect, control: Rect) -> Vec2 { + let taken = |amount: f32| if amount.is_finite() { amount.max(0.0) } else { 0.0 }; + (body.size() - control.size()).max(Vec2::ZERO).max(Vec2::new( + taken(control.min.x - body.min.x).max(taken(body.max.x - control.max.x)), + taken(control.min.y - body.min.y).max(taken(body.max.y - control.max.y)), + )) +} + +/// Runs `body` in a column group named `labels` under the container `id` when `shared` is set, so the labelled +/// rows directly inside share the widest label. Otherwise the body runs behind a barrier: the labelled rows of a +/// nested container read no group of the container around it. In a measuring run, `extent` takes the width the +/// group's rows take at the widest label (`ColumnGroup::scope_measured`). +pub(super) fn shared_labels(ui: &mut Ui, id: Id, shared: bool, room: f32, extent: &mut Option, body: impl FnOnce(&mut Ui) -> R) -> R { + if shared { + let (result, took) = ColumnGroup::scope_measured(ui, sub(id, "labels"), |ui, group| { + group.offer(room); + body(ui) + }); + *extent = took; + result + } else { + ColumnGroup::barrier(ui, body) + } +} diff --git a/crates/ui-contract/src/contract/body/reorder.rs b/crates/ui-contract/src/contract/body/reorder.rs new file mode 100644 index 000000000..0d9924bf9 --- /dev/null +++ b/crates/ui-contract/src/contract/body/reorder.rs @@ -0,0 +1,37 @@ +//! The reorder band: a section header that moves its section with Alt+Up and Alt+Down. + +use super::BodyHooks; +use crate::contract::{Container, ContainerProps, Cx, DragBand}; +use crate::runtime::commands; +use crate::runtime::keys; +use craft_behavior::{Intent, PartKey}; +use craft_keymap::{Chord, Key, Mods}; + +#[doc(hidden)] +pub const REORDER_BAND: PartKey = PartKey::new("reorder_band"); + +/// The scope a container with a reorder band joins in its regions' command chain: no command belongs to it, so the +/// chain tells `commands::focus_within` that focus is inside the container. +pub(super) const REORDER_SCOPE: commands::CommandScope = commands::CommandScope::new("reorder"); + +impl BodyHooks<'_> { + /// Alt+Up and Alt+Down while focus is anywhere in a section whose header is a reorder band. A section has no stop of + /// its own, so the keys would reach the stops in its header: the container holds the chords for itself and turns + /// them into `Intent::MoveItem` for its own update. + pub(super) fn reorder_keys(&mut self, props: &ContainerProps, cx: &mut Cx<'_, C>) { + if !props.header.is_some_and(|header| header.band == DragBand::Reorder) { + return; + } + let (id, ctx) = (cx.core.id, cx.core.ctx.clone()); + let within = commands::focus_within(&ctx, id); + for (key, toward_end) in [(Key::Up, false), (Key::Down, true)] { + let chord = Chord::new(Mods::ALT, key); + if within { + keys::capture(&ctx, id, chord); + } + while keys::take_claimed(&ctx, id, chord) { + cx.core.intents.push(Intent::move_item(toward_end)); + } + } + } +} diff --git a/crates/ui-contract/src/contract/body/scroll.rs b/crates/ui-contract/src/contract/body/scroll.rs new file mode 100644 index 000000000..5852d2fae --- /dev/null +++ b/crates/ui-contract/src/contract/body/scroll.rs @@ -0,0 +1,213 @@ +//! The body's scroll region: its offset and jumps, the scroll bars, their input and AccessKit scroll actions. + +use super::BodyHooks; +use super::inherit::own_surface; +use super::placement::overlay_of; +use super::regions::rect_of; +use crate::contract::{Container, ContainerProps, Cx, Scroll}; +use crate::primitives::{HiddenContent, ScrollBar}; +use crate::runtime::egui::pass; +use crate::runtime::egui::{memory as store, repaint, sizing}; +use crate::runtime::env::Env; +use crate::style::{SurfaceKind, UiTokens, scroll_bar_look, surface_style}; +use craft_behavior::{Axis, PartKey, ScrollPos, ScrollSpan}; +use egui::{Context, Id, Pos2, Rect, Ui, Vec2}; + +const SCROLL_Y: PartKey = PartKey::new("body_scroll_y"); + +const SCROLL_X: PartKey = PartKey::new("body_scroll_x"); + +/// The scroll offset a container with no `Component::scroll` binding keeps for the session. +#[derive(Clone, Default)] +pub(super) struct ScrollState { + pub(super) offset: (f64, f64), + /// A bottom-anchored region follows the end while nothing moved it away. + pub(super) follow_end: Option, +} + +/// The offsets `scroll_input` moved scroll bodies to, with the frame that queued each, for step 4 of each body's next +/// pass. An entry no body took in that frame or the next belongs to a body that is no longer shown: it is dropped. +#[derive(Default)] +pub(super) struct Jumps(pub(super) Vec<(Id, ScrollPos, u64)>); + +/// The frame a jump is queued and taken in: the root's, since one store serves the bodies of every viewport. +pub(super) fn jump_frame(ctx: &Context) -> u64 { + pass::root_frame_nr(ctx) +} + +/// The room the scroll bars of `scroll` take from a view of `view` over content of `extent`: `bar` across the view +/// for each axis whose content overflows it. +pub(super) fn overflow_inset(scroll: Scroll, extent: Vec2, view: Vec2, bar: f32) -> Vec2 { + Vec2::new( + if scroll.vertical_on() && f64::from(extent.y) > f64::from(view.y) + 0.5 { bar } else { 0.0 }, + if scroll.horizontal_on() && f64::from(extent.x) > f64::from(view.x) + 0.5 { bar } else { 0.0 }, + ) +} + +/// The scroll region of a container: its own, or for a layer the vertical one that takes the overflow of any fit +/// (none when the body is one collection, which owns the scroll, or the overlay turns its body scroll off). A +/// container whose body is one collection has no scroll of its own, whatever its constructor set. +pub(super) fn scroll_of(props: &ContainerProps) -> Option { + if props.collection_body { + return None; + } + props.scroll.or_else(|| overlay_of(props).filter(|overlay| overlay.body_scroll).map(|_| Scroll::vertical())) +} + +/// One axis of a scroll region: its track and its span. +pub(super) struct Bar { + pub(super) key: PartKey, + pub(super) axis: Axis, + pub(super) track: Rect, +} + +impl BodyHooks<'_> { + /// The edge fades and the scroll bars over the body. The fades blend the content into the surface it sits on. + pub(super) fn paint_scroll_bars(&self, ui: &mut Ui, cx: &Cx<'_, C>, props: &ContainerProps, rtl: bool, env: &Env) { + let tokens = &*env.tokens; + let look = scroll_bar_look(tokens); + if let Some(view) = self.view + && let Some(scroll) = scroll_of(props) + { + let (ex, ey) = self.last.extent; + let content = Vec2::new(if scroll.horizontal_on() { ex } else { view.width() }, if scroll.vertical_on() { ey } else { view.height() }); + let offset = Vec2::new(self.offset.x as f32, self.offset.y as f32); + let background = surface_style(tokens, SurfaceKind::under(own_surface(props, cx), env.surface)).fill; + ui.painter().extend(ScrollBar::fades(&look, view, HiddenContent::new(content, view.size(), offset, rtl), background)); + } + if let Some(view) = self.view { + for (bar, span) in self.scroll_geometry(props, view, rtl, tokens) { + let overflow = span.content.end - span.content.start > span.visible.end - span.visible.start; + if !overflow { + continue; + } + let length = match bar.axis { + Axis::X => bar.track.width(), + _ => bar.track.height(), + }; + let (at, len) = craft_behavior::scroll::thumb(&span, length, look.min_thumb); + let thumb = crate::contract::cx::thumb_rect(bar.track, bar.axis, rtl, at, len); + let enabled = cx.core.resolved.enabled; + let state = crate::contract::steps::part_state( + cx.core.results.get(&(bar.key, Some(crate::contract::cx::THUMB))).unwrap_or(&crate::primitives::PartResult::IDLE), + enabled, + None, + ); + ui.painter().extend(ScrollBar::shapes(&look, bar.track, thumb, &state)); + } + } + } + + /// Thumb drags, track presses and AccessKit scroll actions. They move the view at step 4 of the next pass, as the + /// wheel does there, and that pass repeats this frame: the pass that paints an offset is the one whose step 4 set + /// it, so the content laid out for the view (out-of-view children skip their run, `runtime::lazy`) is the content + /// shown. A pass that repeats a frame carries no input, and a press held since the frame's first pass adds nothing + /// there. + pub(super) fn scroll_input(&self, props: &ContainerProps, cx: &mut Cx<'_, C>) { + use crate::contract::Pointer as _; + let Some(scroll) = scroll_of(props) else { return }; + let ctx = cx.core.ctx.clone(); + if ctx.current_pass_index() > 0 { + return; + } + let mut offset = self.offset; + if let Some(range) = cx.scroll_moved(SCROLL_Y) { + offset.y = range.start; + } + if let Some(range) = cx.scroll_moved(SCROLL_X) { + offset.x = range.start; + } + self.access_scroll(scroll, &mut offset, cx); + let view = self.last.view.map_or(Vec2::ZERO, |view| rect_of(view).size()); + let offset = self.clamped(scroll, view, offset); + if offset != self.offset { + let id = cx.core.id; + let frame = jump_frame(&ctx); + store::Service::::run(&ctx, |jumps| { + jumps.0.retain(|(owner, _, queued)| *owner != id && queued + 1 >= frame); + jumps.0.push((id, offset, frame)); + }); + // A bound offset reaches the app in the repeated pass. + sizing::request_discard(&ctx, sizing::Rerun::HeldUpdate); + if !ctx.will_discard() { + repaint::request(&ctx); + } + } + } + + /// AccessKit scroll actions aimed at the container's node, applied to `offset`: a page along an axis, or an offset. + fn access_scroll(&self, scroll: Scroll, offset: &mut ScrollPos, cx: &mut Cx<'_, C>) { + use craft_behavior::{AccessAction as Action, AccessData as ActionData}; + let rtl = cx.core.env.direction().is_rtl(); + let view = self.last.view.map_or(Vec2::ZERO, |view| rect_of(view).size()); + while let Some(request) = cx.core.intents.take_scroll_access(false) { + let (vertical, toward_end) = match request.action { + Action::ScrollUp => (true, false), + Action::ScrollDown => (true, true), + Action::ScrollLeft => (false, rtl), + Action::ScrollRight => (false, !rtl), + _ => { + if let Some(ActionData::SetScrollOffset(point)) = request.data { + *offset = ScrollPos { x: point.x, y: point.y }; + } + continue; + } + }; + let (visible, extent, at) = if vertical { (view.y, self.last.extent.1, offset.y) } else { (view.x, self.last.extent.0, offset.x) }; + let span = ScrollSpan::new(0.0..f64::from(extent).max(f64::from(visible)), at..at + f64::from(visible)); + let start = craft_behavior::scroll::page(&span, toward_end).start; + if vertical { + offset.y = start; + } else { + offset.x = start; + } + *offset = self.clamped(scroll, view, *offset); + } + } +} + +impl<'b> BodyHooks<'b> { + pub(super) fn scroll_geometry(&self, props: &ContainerProps, view: Rect, rtl: bool, tokens: &UiTokens) -> Vec<(Bar, ScrollSpan)> { + let Some(scroll) = scroll_of(props) else { return Vec::new() }; + let thickness = scroll_bar_look(tokens).thickness; + let (v_on, h_on) = (scroll.vertical_on(), scroll.horizontal_on()); + let (ex, ey) = self.last.extent; + let mut bars = Vec::new(); + if v_on { + let track = if rtl { + Rect::from_min_max(view.min, Pos2::new(view.min.x + thickness, view.max.y)) + } else { + Rect::from_min_max(Pos2::new(view.max.x - thickness, view.min.y), view.max) + }; + let content = f64::from(ey).max(f64::from(view.height())); + let span = ScrollSpan::new(0.0..content, self.offset.y..self.offset.y + f64::from(view.height())); + bars.push((Bar { key: SCROLL_Y, axis: Axis::Y, track }, span)); + } + if h_on { + let track = Rect::from_min_max( + Pos2::new(view.min.x, view.max.y - thickness), + Pos2::new(view.max.x - if v_on { thickness } else { 0.0 }, view.max.y), + ); + let content = f64::from(ex).max(f64::from(view.width())); + let span = ScrollSpan::new(0.0..content, self.offset.x..self.offset.x + f64::from(view.width())); + bars.push((Bar { key: SCROLL_X, axis: Axis::X, track }, span)); + } + bars + } + + pub(super) fn max_offset(&self, view: Vec2) -> ScrollPos { + ScrollPos { x: f64::from((self.last.extent.0 - view.x).max(0.0)), y: f64::from((self.last.extent.1 - view.y).max(0.0)) } + } + + pub(super) fn clamp_offset(&mut self, scroll: Scroll, view: Vec2) { + self.offset = self.clamped(scroll, view, self.offset); + } + + fn clamped(&self, scroll: Scroll, view: Vec2, offset: ScrollPos) -> ScrollPos { + let max = self.max_offset(view); + ScrollPos { + x: if scroll.horizontal_on() { offset.x.clamp(0.0, max.x) } else { 0.0 }, + y: if scroll.vertical_on() { offset.y.clamp(0.0, max.y) } else { 0.0 }, + } + } +} diff --git a/crates/ui-contract/src/contract/body/size.rs b/crates/ui-contract/src/contract/body/size.rs new file mode 100644 index 000000000..9cc452a45 --- /dev/null +++ b/crates/ui-contract/src/contract/body/size.rs @@ -0,0 +1,220 @@ +//! How big a container is: its sizing, the room its mount offers and the sizes its regions took. + +use super::BodyHooks; +use super::placement::overlay_of; +use super::regions::{RegionSizes, end_full_height, footer_in_end}; +use crate::contract::run::ShowAt; +use crate::contract::{ContainerProps, Mount, Sizing}; +use crate::runtime::egui::areas; +use crate::runtime::env::Env; +use crate::runtime::layout_memory; +use crate::runtime::memory::sub; +use egui::{Context, Id, Rect, Ui, Vec2}; + +/// The inputs a body's measuring run measures under. A later pass offering the same takes the body's kept +/// transcript (`layout_memory::kept_serves`); its real run checks that the content is the same. +#[derive(PartialEq)] +pub(super) struct MeasureKey { + props: u64, + room: Vec2, + given: (bool, bool), + width: Option, + /// Whether the body shows, and how much of it an animated collapse shows. + shows: (bool, f32), + /// The content extent the view keeps, which decides the scroll bars' inset. + extent: (f32, f32), + env: EnvFacts, +} + +/// What a body's measure reads of its env besides the room. +#[derive(PartialEq)] +struct EnvFacts { + style: crate::style::EnvKey, + words: u64, + size: craft_theme::ControlSize, + enabled: bool, + text_direction: crate::runtime::env::Direction, + content: (bool, bool), + content_column: bool, + unbounded: (bool, bool), + row_room: Option, + row_line: Option, + offered: Option, + grid: Option, +} + +impl<'b> BodyHooks<'b> { + /// The inputs this body's measuring run measures under, once `measured_extent` has its room. + pub(super) fn measure_key(&self, props: &ContainerProps, env: &Env, width: Option) -> MeasureKey { + MeasureKey { + props: props.measure_fingerprint(), + room: self.room, + given: self.given, + width, + shows: (self.open, self.presence.t), + extent: self.last.extent, + env: EnvFacts { + style: env.key, + words: env.words.generation(), + size: env.size, + enabled: env.enabled, + text_direction: env.text_direction, + content: env.content, + content_column: env.content_column, + unbounded: env.unbounded, + row_room: env.row_room, + row_line: env.row_line, + offered: env.offered, + grid: env.grid, + }, + } + } + + /// How the container's size follows its content here: a pane or a rect the host gives is filled; a layer sizes + /// from its content until the user sizes it; an inline container follows its props. + pub(super) fn sizing(&self, props: &ContainerProps) -> Sizing { + match &props.mount { + Mount::Pane(_) | Mount::Window { .. } => Sizing::Fill, + Mount::Layer(_) | Mount::Viewport { .. } | Mount::FullWindow if self.fixed => Sizing::Fill, + Mount::Layer(_) | Mount::Viewport { .. } => Sizing::Content, + _ => props.sizing, + } + } + + /// Whether the container fills the width of a content-sized column it sits in: the column holds it at its measured + /// width and shows it across the width the column settles on (step 6). + pub(super) fn held(&self, props: &ContainerProps, env: &Env) -> bool { + env.content_column && matches!(props.mount, Mount::Inline) && self.sizing(props) != Sizing::Content + } + + /// The axes the container is given where `env` is its parent's: a rect it is shown at gives both; an inline + /// container that fills an axis takes the room only where its parent was given that axis. + pub(super) fn given_axes(&self, props: &ContainerProps, env: &Env, at: ShowAt) -> (bool, bool) { + let sizing = self.sizing(props); + let (x, y) = (sizing != Sizing::Content, sizing == Sizing::Fill); + match (at, &props.mount) { + (ShowAt::Rect(_), _) => (true, true), + (ShowAt::Flow, Mount::Inline) => (x && !env.content.0 && !self.held(props, env), y && !env.content.1), + (ShowAt::Flow, _) => (x, y), + } + } + + /// What the regions took together, padding included, from the records a measuring run left in this pass, when they + /// serve a run offered `self.room`: on each axis the room equals the recorded one, or the container is not given + /// that axis, took less than the recorded room (the room did not bound it) and fits in the room now. + pub(super) fn reusable(&self, props: &ContainerProps, ctx: &Context, id: Id, pad: Vec2, tolerance: f32) -> Option { + let body = layout_memory::measured(ctx, id)?; + let region = + |key: &str, has: bool| if has { layout_memory::measured(ctx, sub(id, key)).map_or(Vec2::ZERO, |region| region.took) } else { Vec2::ZERO }; + let (header, footer, end) = + (region("header", props.header.is_some()), region("footer", props.footer.is_some()), region("end", props.end.is_some())); + let fits = |now: f32, was: f32, given: bool, took: f32| layout_memory::Measured::serves(now, was, given, took, tolerance); + let full = self.regions_size(props, body.took, header, footer, end) + pad; + if !(fits(self.room.x, body.room.x, self.given.0, full.x) && fits(self.room.y, body.room.y, self.given.1, full.y)) { + return None; + } + let body = if self.open { body.took } else { Vec2::ZERO }; + Some(self.regions_size(props, body, header, footer, end) + pad) + } + + /// What a header, footer or end region took: what its content allocated. + pub(super) fn region_size(&self, ui: &Ui) -> Vec2 { + ui.min_rect().size() + } + + /// The size the regions take together, from what the body, header, footer and end region took (zero for a region + /// the container lacks or that took the whole room). An inline header shares the line; a footer in the end region + /// stacks with its content; a full-height end region stands beside the body and the footer. + pub(super) fn regions_size(&self, props: &ContainerProps, body: Vec2, header: Vec2, footer: Vec2, end: Vec2) -> Vec2 { + let in_end = footer_in_end(props); + let end = if in_end { Vec2::new(end.x.max(footer.x), end.y + footer.y) } else { end }; + let across = if in_end { Vec2::ZERO } else { footer }; + let gap = |width: f32| if width > 0.0 { width + self.region_gap } else { 0.0 }; + let inline = props.header.is_some_and(|header| header.inline); + // The line: the body with an inline header before it. + let line = if inline { Vec2::new(body.x + gap(header.x), body.y.max(header.y)) } else { body }; + let (width, height) = if end_full_height(props) { + (line.x.max(across.x) + gap(end.x), (line.y + across.y).max(end.y)) + } else { + ((line.x + gap(end.x)).max(across.x), line.y.max(end.y) + across.y) + }; + if inline { Vec2::new(width, height) } else { Vec2::new(width.max(header.x), height + header.y + self.header_space(header.y)) } + } + + /// The width the regions ask for in a content-sized container: what they took together in this pass's measuring run. + pub(super) fn wanted_width(&self, props: &ContainerProps) -> Option { + self.measured_body.map(|body| { + let (header, end) = (self.measured_header.unwrap_or(Vec2::ZERO), self.measured_end.unwrap_or(Vec2::ZERO)); + let wanted = self.regions_size(props, body, header, self.measured_footer, end).x.max(self.least_width); + overlay_of(props).map_or(wanted, |overlay| wanted.max(crate::contract::overlay::opener_floor(overlay))) + }) + } + + /// The width the header, body and footer share in a content-sized container: the widest region's, at most the + /// room; the whole room before any pass. + pub(super) fn shared_width(&self, room: f32, props: &ContainerProps) -> f32 { + self.wanted_width(props).map_or(room.max(0.0), |wanted| wanted.min(room.max(0.0))) + } + + /// The sizes the regions are placed from before any of them ran in this run: the measuring run's. + pub(super) fn measured_sizes(&self) -> RegionSizes { + RegionSizes { header: self.measured_header, footer: self.measured_footer, end: self.measured_end } + } + + /// The room a content-sized body runs in: what the mount offers, less the padding. + pub(super) fn room_size(&self, rect: Rect, inner: Rect) -> Vec2 { + self.room - (inner.min - rect.min) * 2.0 + } + + /// The room the mount offers: a layer's room, unless the host gives it a rect of its own size, else the rect the + /// container is shown at, else the room of the flow. + pub(super) fn mount_room(&self, props: &ContainerProps, ui: &Ui, id: Id, at: ShowAt) -> Vec2 { + match (overlay_of(props), self.fixed) { + (Some(overlay), false) => { + let env = Env::of(ui); + let contained = crate::contract::overlay::region_for(&env, overlay).is_some(); + let overlay = &if contained { overlay.in_region() } else { overlay.clone() }; + let room = Self::layer_room(ui.ctx(), &env, overlay).size(); + // An anchored layer's body runs in the room the anchor leaves on the side it takes, as the host + // offers it: a body taller than that scrolls instead of covering the anchor. + let ctx = ui.ctx(); + let own = Rect::from_min_max(ui.cursor().min, ui.cursor().min); + let rtl = Env::of(ui).direction.is_rtl(); + match crate::contract::overlay::measuring_room( + ctx, + id, + overlay, + own, + areas::layer_to_screen(ctx, ui.layer_id()), + Env::of(ui).tokens.space.pad.regular, + rtl, + ) { + Some(side) => side.min(room), + None => room, + } + } + _ => match at { + ShowAt::Rect(rect) => rect.size(), + ShowAt::Flow => { + let room = crate::layout::flow_room(ui); + let room = Vec2::new(room.x, props.room_height.unwrap_or(room.y)); + // In a row that wraps, a body too wide for the rest of the line moves to the next one: it measures + // in the whole line, so its allocation carries its width and the row can wrap it. + let layout = ui.layout(); + if layout.main_wrap && layout.is_horizontal() { Vec2::new(room.x.max(ui.available_size().x), room.y) } else { room } + } + }, + } + } + + /// The room a layer offers its content: the safe rect (the region of a contained layer), or the share of it the overlay caps its content at. + fn layer_room(ctx: &Context, env: &Env, overlay: &crate::contract::Overlay) -> Rect { + let bounds = crate::contract::overlay::screen_for(ctx, env, overlay); + match overlay.fit { + crate::contract::overlay::OverlayFit::ContentCapped(share) => { + Rect::from_min_size(bounds.min, Vec2::new(bounds.width() * share.x, bounds.height() * share.y)) + } + _ => bounds, + } + } +} diff --git a/crates/ui-contract/src/contract/body/window.rs b/crates/ui-contract/src/contract/body/window.rs new file mode 100644 index 000000000..230428b3a --- /dev/null +++ b/crates/ui-contract/src/contract/body/window.rs @@ -0,0 +1,448 @@ +//! Move and resize of a layer or OS window: the move band, the grips, the keyboard mode, limits and OS window facts. + +use super::BodyHooks; +use super::placement::{Placement, PlacementSlot, overlay_of}; +use super::regions::Regions; +use crate::contract::overlay::{PlacementChange, PlacementKind}; +use crate::contract::{Container, ContainerProps, Cx, Mount, PartsCx}; +use crate::runtime::commands::{self, CommandSet as _, WindowCommand}; +use crate::runtime::egui::pass; +use crate::runtime::egui::{input, viewports}; +use crate::runtime::memory::sub; +use crate::runtime::windows::{self, ResizeEdge, WindowAction, WindowHit}; +use crate::runtime::{keys, pointer}; +use crate::style::ComponentStyle as _; +use craft_behavior::{CursorIcon, GesturePhase, HitLevel, HitPriority, PartKey, PressPhase}; +use craft_host::target::{Caps, WindowChrome, WindowState}; +use craft_keymap::{Chord, Key, Mods}; +use egui::{Context, Id, Pos2, Rect, Vec2, ViewportId}; + +pub(crate) const MOVE_BAND: PartKey = PartKey::new("move_band"); + +const GRIP: PartKey = PartKey::new("resize_grip"); + +/// Which move and resize parts of the body step stand for the OS window of `viewport` (16.3, 21.2): the one rule +/// every move band and grip of an OS window reads. Both need a frame the app draws (the chrome is not `Native`). The +/// band stands on a maximized window too, so its double click restores the window and a drag is the platform's (it +/// restores and moves); the grips stand only on a window that is neither maximized nor full screen. The parts stand +/// whether or not a hit-test sink is installed: the sink reads them as the window's exclusive parts. +#[derive(Clone, Copy)] +struct WindowParts { + band: bool, + grips: bool, +} + +impl WindowParts { + /// The parts of a layer or a full-window mount, which move the container and never the OS window. + const LAYER: WindowParts = WindowParts { band: true, grips: true }; + + fn of(ctx: &Context, viewport: ViewportId) -> WindowParts { + let window = windows::shell_of(ctx, viewport).window; + let framed_by_app = window.chrome != WindowChrome::Native; + let sized_by_os = matches!(window.state, WindowState::Maximized | WindowState::Fullscreen); + WindowParts { band: framed_by_app && window.state != WindowState::Fullscreen, grips: framed_by_app && !sized_by_os } + } +} + +/// Whether the platform answers the hit test of `viewport`'s undecorated window itself, as it does for a window whose +/// hit-test sink is installed (`WindowHost::install_hit_sink`): it takes the move, edge and caption hits from the +/// window's exclusive parts, so a press on the move band or a grip never reaches the app as a move. +fn answered_by_platform(ctx: &Context, viewport: ViewportId) -> bool { + let shell = windows::shell_of(ctx, viewport); + shell.caps.contains(Caps::OS_RESIZES_UNDECORATED) && shell.window.chrome == WindowChrome::Integrated && windows::hit_sink_installed(ctx, viewport) +} + +/// The viewport of the OS window a container's move and resize parts act on: a viewport mount's own window, the +/// window a `Window`, `Pane` or `Inline` container is shown in. A layer (also a viewport mount's fallback layer) +/// and a full-window mount are not an OS window of their own. +pub(super) fn os_window(props: &ContainerProps, ctx: &Context, id: Id) -> Option { + match &props.mount { + Mount::Viewport { .. } if viewports::available(ctx) => Some(viewports::viewport_id(id)), + Mount::Window { .. } | Mount::Pane(_) | Mount::Inline => Some(pass::current_viewport(ctx)), + Mount::Viewport { .. } | Mount::Layer(_) | Mount::FullWindow => None, + } +} + +/// The floor of a resizable layer's size: the larger of the style minimum and the overlay's least size. +fn window_min(props: &ContainerProps, style_min: Vec2) -> Vec2 { + overlay_of(props).map_or(style_min, |overlay| style_min.max(overlay.size_limits.min)) +} + +/// The instance id of the `window` command scope a movable or resizable layer container holds (16.3), whatever +/// scope its own commands use: the container's id when it publishes the window scope itself, else a sub-id. +pub(super) fn window_instance(props: &ContainerProps, id: Id) -> Option { + let overlay = overlay_of(props)?; + (overlay.movable || overlay.resize.grips).then(|| if props.command_scope == Some(WindowCommand::SCOPE) { id } else { sub(id, "window") }) +} + +/// The keyboard mode of a floating container (16.3): arrows move or resize it until Enter or Escape. +#[derive(Clone, Copy, PartialEq)] +enum WindowModeKind { + Move, + Size, +} + +/// A container's window gesture, the keyboard mode or a pointer drag, with the placement Escape restores and the +/// rect the layer had when the gesture began. Kept in session memory. +#[derive(Clone, Default, PartialEq)] +pub(super) struct WindowMode { + kind: Option, + restore: Placement, + began: Option, +} + +/// The outer rect of a viewport mount's OS window as the container last learnt it: the window's placement, which the +/// container keeps as a layer keeps its own. +#[derive(Clone, Default)] +struct WindowPlaced(Option); + +/// The edge or corner a resize from `before` to `after` moved: on each axis whose length changed, the side that moved, +/// or the far side (bottom, end of the screen's x) when both did. +fn resized_edge(before: Rect, after: Rect) -> Option { + let vertical = (before.height() != after.height()).then(|| before.top() != after.top() && before.bottom() == after.bottom()); + let horizontal = (before.width() != after.width()).then(|| before.left() != after.left() && before.right() == after.right()); + Some(match (vertical, horizontal) { + (None, None) => return None, + (Some(true), None) => ResizeEdge::Top, + (Some(false), None) => ResizeEdge::Bottom, + (None, Some(true)) => ResizeEdge::Left, + (None, Some(false)) => ResizeEdge::Right, + (Some(true), Some(true)) => ResizeEdge::TopLeft, + (Some(true), Some(false)) => ResizeEdge::TopRight, + (Some(false), Some(true)) => ResizeEdge::BottomLeft, + (Some(false), Some(false)) => ResizeEdge::BottomRight, + }) +} + +/// What every change of a layer's rect keeps to: the least and most size, and the rect it stays inside. +struct Limits { + min: Vec2, + max: Vec2, + bounds: Option, +} + +impl Limits { + fn new(overlay: &crate::contract::Overlay, min: Vec2) -> Limits { + Limits { min, max: overlay.size_limits.max.unwrap_or(Vec2::INFINITY).max(min), bounds: overlay.bounds } + } + + /// `rect` moved by `delta`, kept inside the bounds. + fn moved(&self, rect: Rect, delta: Vec2) -> Rect { + let rect = rect.translate(delta); + let Some(bounds) = self.bounds else { return rect }; + let keep = |low: f32, high: f32, bounds_low: f32, bounds_high: f32| low.min(bounds_high - (high - low)).max(bounds_low) - low; + rect.translate(Vec2::new(keep(rect.min.x, rect.max.x, bounds.min.x, bounds.max.x), keep(rect.min.y, rect.max.y, bounds.min.y, bounds.max.y))) + } + + /// `rect` with the edges `dx` and `dy` (-1: low edge, 1: high edge, 0: none) moved by `delta`, within the size + /// limits and the bounds. The opposite edge stays. + fn resized(&self, rect: Rect, dx: i8, dy: i8, delta: Vec2) -> Rect { + let axis = |low: f32, high: f32, edge: i8, delta: f32, min: f32, max: f32, bounds: Option<(f32, f32)>| { + let (bounds_low, bounds_high) = bounds.unwrap_or((f32::NEG_INFINITY, f32::INFINITY)); + match edge { + -1 => ((low + delta).max((high - max).max(bounds_low)).min(high - min), high), + 1 => (low, (high + delta).min((low + max).min(bounds_high)).max(low + min)), + _ => (low, high), + } + }; + let (left, right) = axis(rect.min.x, rect.max.x, dx, delta.x, self.min.x, self.max.x, self.bounds.map(|bounds| (bounds.min.x, bounds.max.x))); + let (top, bottom) = axis(rect.min.y, rect.max.y, dy, delta.y, self.min.y, self.max.y, self.bounds.map(|bounds| (bounds.min.y, bounds.max.y))); + Rect::from_min_max(Pos2::new(left, top), Pos2::new(right, bottom)) + } +} + +/// The edge or corner the grip with direction (`dx`, `dy`) of `GRIPS` sits on. +fn edge_of(dx: i8, dy: i8) -> ResizeEdge { + match (dx, dy) { + (-1, 0) => ResizeEdge::Left, + (1, 0) => ResizeEdge::Right, + (0, -1) => ResizeEdge::Top, + (-1, -1) => ResizeEdge::TopLeft, + (1, -1) => ResizeEdge::TopRight, + (-1, 1) => ResizeEdge::BottomLeft, + (1, 1) => ResizeEdge::BottomRight, + _ => ResizeEdge::Bottom, + } +} + +/// The arrow chords, with and without Shift, a window mode holds, with the direction each moves. +const MODE_ARROWS: [(Key, [i8; 2]); 4] = [(Key::Left, [-1, 0]), (Key::Right, [1, 0]), (Key::Up, [0, -1]), (Key::Down, [0, 1])]; + +/// The eight edge and corner grips of a resizable layer, in the order of `GRIPS`: which edges each moves. +const GRIPS: [(i8, i8, CursorIcon); 8] = [ + (-1, 0, CursorIcon::ResizeHorizontal), + (1, 0, CursorIcon::ResizeHorizontal), + (0, -1, CursorIcon::ResizeVertical), + (0, 1, CursorIcon::ResizeVertical), + (-1, -1, CursorIcon::ResizeNwSe), + (1, 1, CursorIcon::ResizeNwSe), + (1, -1, CursorIcon::ResizeNeSw), + (-1, 1, CursorIcon::ResizeNeSw), +]; + +impl BodyHooks<'_> { + /// The `window.Move` and `window.Size` commands and the keys of the mode they start (16.3): arrows move or + /// resize by a step (Shift: four steps), Enter, the command again or a primary press keeps the placement, Escape + /// restores it, and focus leaving the container ends the mode. The mode holds its chords through the key stage, so no + /// component under focus sees them. Each step is reported as a `PlacementKind::Keyboard` change. + pub(super) fn window_keys(&mut self, props: &ContainerProps, cx: &mut Cx<'_, C>) { + let (id, ctx) = (cx.core.id, cx.core.ctx.clone()); + let (Some(window), Some(overlay)) = (window_instance(props, id), overlay_of(props)) else { return }; + let limits = Limits::new(overlay, window_min(props, cx.style.metrics().min_size)); + let rect = cx.core.rect; + let mut slot = PlacementSlot::new(&mut *cx.core.memory, id, self.save.as_ref(), overlay); + let current = slot.read(); + let step = |rect: Rect, phase: GesturePhase| PlacementChange { rect, phase, pointer: None, kind: PlacementKind::Keyboard }; + let started = commands::take_for_instance(&ctx, Some(window), false, WindowCommand::from_ref).map(|(command, _)| command); + let mut mode = self.mode.clone(); + if let Some(command) = started { + let kind = match command { + WindowCommand::Move => WindowModeKind::Move, + _ => WindowModeKind::Size, + }; + if mode.kind.is_some() { + self.reports.push(step(current.rect_over(rect), GesturePhase::Commit)); + } + if mode.kind == Some(kind) { + mode = WindowMode::default(); + } else { + mode = WindowMode { kind: Some(kind), restore: current.clone(), began: Some(current.rect_over(rect)) }; + self.reports.push(step(current.rect_over(rect), GesturePhase::Begin)); + } + } + // A primary press ends the mode and keeps the placement reached, like Enter. + let pressed = || pointer::with_frame(&ctx, |frame, _| frame.is_some_and(|frame| frame.press.is_some())); + if mode.kind.is_some() && (!commands::focus_within(&ctx, id) || pressed()) { + self.reports.push(step(current.rect_over(rect), GesturePhase::Commit)); + mode = WindowMode::default(); + } + if let Some(kind) = mode.kind { + let unit = self.nudge; + let mut placement = current; + for (key, direction) in MODE_ARROWS { + for (mods, scale) in [(Mods::NONE, 1.0), (Mods::SHIFT, 4.0)] { + let chord = Chord::new(mods, key); + keys::capture(&ctx, id, chord); + while keys::take_claimed(&ctx, id, chord) { + let delta = Vec2::new(f32::from(direction[0]), f32::from(direction[1])) * unit * scale; + let before = placement.rect_over(rect); + let next = match kind { + WindowModeKind::Move => limits.moved(before, delta), + WindowModeKind::Size => limits.resized(before, 1, 1, delta), + }; + placement = Placement::at(next); + self.reports.push(step(next, GesturePhase::Update)); + } + } + } + for key in [Key::Enter, Key::Escape] { + let chord = Chord::new(Mods::NONE, key); + keys::capture(&ctx, id, chord); + if keys::take_claimed(&ctx, id, chord) { + if key == Key::Escape { + placement = mode.restore.clone(); + self.reports.push(step(mode.began.unwrap_or(rect), GesturePhase::Cancel)); + } else { + self.reports.push(step(placement.rect_over(rect), GesturePhase::Commit)); + } + mode = WindowMode::default(); + } + } + slot.write(placement); + } + self.mode = mode; + } + + /// A drag of the move band or a grip of a layer (not an OS window): the layer follows the pointer within the + /// limits, and each step is reported. Escape, which cancels the press, restores the placement from before. + pub(super) fn window_drag(&mut self, props: &ContainerProps, cx: &mut Cx<'_, C>) { + let Some(overlay) = overlay_of(props) else { return }; + // A band that moves the window below starts the OS move of the window the layer is shown in. + if overlay.moves_window { + let viewport = pass::current_viewport(&cx.core.ctx); + self.window_os(viewport, cx); + return; + } + let id = cx.core.id; + let limits = Limits::new(overlay, window_min(props, cx.style.metrics().min_size)); + let rect = cx.core.rect; + // A part the container did not declare this pass (no band, no grips) has no result. + let phase = |key: (PartKey, Option)| cx.core.results.get(&key).map(|result| result.press.phase); + let mut pressed = vec![(None, phase((MOVE_BAND, None)))]; + pressed.extend((0..GRIPS.len()).map(|index| (Some(index), phase((GRIP, Some(index as u64)))))); + let Some((grip, phase)) = pressed.into_iter().find_map(|(grip, phase)| match phase? { + phase @ (PressPhase::DragStart { .. } | PressPhase::Drag { .. } | PressPhase::Release { .. } | PressPhase::Cancel { .. }) => { + Some((grip, phase)) + } + _ => None, + }) else { + return; + }; + let mut slot = PlacementSlot::new(&mut *cx.core.memory, id, self.save.as_ref(), overlay); + let current = slot.read(); + let (origin, pos, gesture) = match phase { + PressPhase::DragStart { start, pos, .. } => { + self.mode.began = Some(current.rect_over(rect)); + self.mode.restore = current.clone(); + (start.origin, Some(pos), GesturePhase::Begin) + } + PressPhase::Drag { start, pos, .. } => (start.origin, Some(pos), GesturePhase::Update), + PressPhase::Release { start, pos, .. } => (start.origin, Some(pos), GesturePhase::Commit), + PressPhase::Cancel { start, .. } => (start.origin, None, GesturePhase::Cancel), + _ => return, + }; + let Some(began) = self.mode.began else { return }; + let (dx, dy, _) = grip.map_or((0, 0, CursorIcon::Grab), |index| GRIPS[index]); + let kind = if grip.is_some() { PlacementKind::Size(edge_of(dx, dy)) } else { PlacementKind::Move }; + let next = match pos { + Some(pos) if grip.is_some() => limits.resized(began, dx, dy, pos - origin), + Some(pos) => limits.moved(began, pos - origin), + None => began, + }; + let change = |rect: Rect, phase: GesturePhase| PlacementChange { rect, phase, pointer: pos, kind }; + if gesture == GesturePhase::Begin { + self.reports.push(change(began, GesturePhase::Begin)); + } + self.reports.push(change(next, if gesture == GesturePhase::Begin { GesturePhase::Update } else { gesture })); + // A move leaves a content-sized layer its size; a resize fixes both. + slot.write(match (gesture, grip) { + (GesturePhase::Cancel, _) => self.mode.restore.clone(), + (_, Some(_)) => Placement::at(next), + (_, None) => Placement { pos: Some(next.min.into()), size: current.size }, + }); + if matches!(gesture, GesturePhase::Commit | GesturePhase::Cancel) { + self.mode.began = None; + } + } + + /// A press on the move band or a grip of a container in an OS window starts the OS move or resize. Where the + /// platform answers the hit test (`answered_by_platform`), the parts stand for its sink only. + pub(super) fn window_os(&self, viewport: ViewportId, cx: &Cx<'_, C>) { + if answered_by_platform(&cx.core.ctx, viewport) { + return; + } + // The parts stand only by `WindowParts`, and the results of a part not registered this pass are gone. + let started = + |key: (PartKey, Option)| cx.core.results.get(&key).is_some_and(|result| matches!(result.press.phase, PressPhase::DragStart { .. })); + if started((MOVE_BAND, None)) { + windows::act(&cx.core.ctx, viewport, WindowAction::StartMove); + } + for (index, (dx, dy, _)) in GRIPS.into_iter().enumerate() { + if started((GRIP, Some(index as u64))) { + windows::act(&cx.core.ctx, viewport, WindowAction::StartResize(edge_of(dx, dy))); + } + } + } + + /// A viewport mount in an OS window reports the window's moves and resizes from its facts, through the + /// `placement_changed` a layer reports its own through: one `Commit` per change, as the platform tells no gesture + /// phase. The first facts are the window's placement, not a change. + pub(super) fn window_placed(&mut self, props: &ContainerProps, cx: &mut Cx<'_, C>) { + if !matches!(props.mount, Mount::Viewport { .. }) { + return; + } + let Some(viewport) = os_window(props, &cx.core.ctx, cx.core.id) else { return }; + let Some(facts) = windows::WindowHost::of(&cx.core.ctx).facts(viewport) else { return }; + let now = facts.outer.unwrap_or(facts.inner); + let placed = &mut cx.core.memory.shown::(sub(sub(cx.core.id, "body"), "window_placed")).0; + let Some(before) = placed.replace(now).filter(|before| *before != now) else { return }; + let kind = resized_edge(before, now).map_or(PlacementKind::Move, PlacementKind::Size); + self.reports.push(PlacementChange { rect: now, phase: GesturePhase::Commit, pointer: None, kind }); + } + + /// The move band and the grips (16.3). A layer's move and resize the layer; those of an OS window (`os_window`) + /// stand by `WindowParts` and join the window's exclusive list, which the hit-test sink reads. A layer's parts never + /// join it, or the sink would move the OS window from a dialog inside it, except the band of a layer that moves the + /// window it is shown in (`Overlay::moves_window`): that band is a drag area of the window. + pub(super) fn move_parts(props: &ContainerProps, regions: &Regions, rect: Rect, pcx: &mut PartsCx<'_, C>) { + let ctx = pcx.ui.ctx().clone(); + let handle = pcx.tokens.tokens().size.handle.sm; + let reason = "the Move and Size commands of the window command set do the same"; + let os = os_window(props, &ctx, pcx.id); + let stands = os.map_or(WindowParts::LAYER, |viewport| WindowParts::of(&ctx, viewport)); + let exclusive = |hit: WindowHit| os.is_some().then_some(hit); + let moves_window = matches!(&props.mount, Mount::Layer(overlay) | Mount::Viewport { fallback: overlay, .. } if overlay.moves_window); + // A layer moves when its overlay says so; other mounts follow the header's band. + let movable = match &props.mount { + // A band that moves the window below follows the rule of the window's own band (a title bar's); where the + // platform answers the hit test, the sink reads it from the exclusive list. + _ if moves_window => WindowParts::of(&ctx, pass::current_viewport(&ctx)).band, + Mount::Layer(overlay) | Mount::Viewport { fallback: overlay, .. } => overlay.movable && stands.band, + _ => props.header.is_some_and(|header| header.band == crate::contract::DragBand::Move) && stands.band, + }; + let band = move_band(props, regions, rect); + if props.header.is_some() && movable && band.is_positive() { + // The band lies under the line's own parts and children, like the reorder band, so they keep their presses. + let part = pcx + .part(MOVE_BAND, band) + .sense(craft_behavior::Sense::DRAG) + .cursor(CursorIcon::Grab) + .drag_cursor(CursorIcon::Grabbing) + .pointer_only(reason); + if let Some(hit) = exclusive(WindowHit::Move).or(moves_window.then_some(WindowHit::Move)) { + part.exclusive(hit); + } + } + // The grips of a layer straddle its edge; those of a window lie inside it, where the window has pixels. They + // stack above the body (`over`), so a root in the body never covers their inner half (8.3). + let (grips, inset) = match &props.mount { + Mount::Layer(overlay) | Mount::Viewport { fallback: overlay, .. } => (overlay.resize.grips, 0.0), + Mount::Window { resize } => (resize.grips, handle / 2.0), + _ => (false, 0.0), + }; + if !grips || !stands.grips { + return; + } + for (index, (dx, dy, cursor)) in GRIPS.into_iter().enumerate() { + let along = |edge: i8, low: f32, high: f32| match edge { + -1 => (low - handle / 2.0 + inset, low + handle / 2.0 + inset), + 1 => (high - handle / 2.0 - inset, high + handle / 2.0 - inset), + _ => (low + handle / 2.0 + inset, high - handle / 2.0 - inset), + }; + let (x0, x1) = along(dx, rect.min.x, rect.max.x); + let (y0, y1) = along(dy, rect.min.y, rect.max.y); + let level = if dx != 0 && dy != 0 { HitLevel::Handle } else { HitLevel::Edge }; + let part = pcx + .part(GRIP.at(index as u64), Rect::from_min_max(Pos2::new(x0, y0), Pos2::new(x1, y1))) + .sense(craft_behavior::Sense::DRAG) + .priority(HitPriority::new(level, 0)) + .cursor(cursor) + .pointer_only(reason) + .over(); + if let Some(hit) = exclusive(WindowHit::Resize(edge_of(dx, dy))) { + part.exclusive(hit); + } + } + } + + /// Tells the platform whether the OS may move the container's OS window from where the pointer is (21.2 + /// `WindowDrag`; macOS `NSWindow.movable`): only where a press would go to the move band under the press-target + /// rule (8.3), so a press on a control over the band never drags the window. Bands of one window combine: any band + /// that would take the press allows the move. A pass with no band writes nothing; `AppShell` writes `false` for a + /// pass with no title bar. + pub(super) fn window_movable(&self, cx: &Cx<'_, C>) { + let Some(band) = cx.core.results.get(&(MOVE_BAND, None)) else { return }; + let ctx = &cx.core.ctx; + let takes_press = band.hovered + && pointer::pass_pointer(ctx).hover.is_some_and(|at| { + let (click, drag) = input::hit_targets(ctx); + pointer::press_winner(ctx, at, pointer::PressTargets { click, drag }) + .is_some_and(|(winner, root)| root == cx.core.id && winner.part.is_some_and(|part| part.key == MOVE_BAND)) + }); + let this_pass = viewports::pass_number(ctx); + let allowed = viewports::movable_record(ctx).is_some_and(|(pass, movable)| pass == this_pass && movable); + viewports::write_movable(ctx, allowed || takes_press); + } +} + +/// The move band of a container whose header drags: an inline header's band spans the header's whole line (header, +/// body and end region), beneath the line's children, so every free point of the line drags; a header on a line of +/// its own is the band. +fn move_band(props: &ContainerProps, regions: &Regions, rect: Rect) -> Rect { + if !props.header.is_some_and(|header| header.inline) { + return regions.header; + } + let line = regions.header.union(regions.body); + let line = if props.end.is_some() { line.union(regions.end) } else { line }; + line.intersect(rect) +} diff --git a/crates/ui-contract/src/contract/collection.rs b/crates/ui-contract/src/contract/collection.rs new file mode 100644 index 000000000..48de584cb --- /dev/null +++ b/crates/ui-contract/src/contract/collection.rs @@ -0,0 +1,12 @@ +//! Chapter 17: collection props, columns, row state and the events and response a collection reports. + +mod columns; +mod events; +mod props; +mod response; + +pub use columns::{ColumnAlign, ColumnKind, ColumnSort, ColumnSpec, ToggleColumn}; +pub use events::{CollectionEvent, ColumnEvent, ContextMenuRequest, HeaderMenuRequest, ListDrag, OpenChange, Rename, ReorderMove, ToggleEdit}; +pub use props::{ActivateOn, CollectionProps, DragPayload, ItemKeys, LeadOnOpen, LeadSource, ReorderRule, RowState, SelectMode, SpaceAction}; +pub(crate) use response::Gestures; +pub use response::{CollectionResponse, ShownRow}; diff --git a/crates/ui-contract/src/contract/collection/columns.rs b/crates/ui-contract/src/contract/collection/columns.rs new file mode 100644 index 000000000..6ebe25b1c --- /dev/null +++ b/crates/ui-contract/src/contract/collection/columns.rs @@ -0,0 +1,187 @@ +//! A collection's columns: kinds, specs, alignment, toggle columns and the sort. + +use crate::runtime::env::Label; +use craft_behavior::{ColumnKey, ColumnWidth}; + +/// A toggle column: its cells flip by click, and a drag across them sweeps one value over all of them. +#[derive(Clone, Copy, Debug, Default, PartialEq, Eq)] +#[non_exhaustive] +pub struct ToggleColumn { + /// A drag across the cells sets them all to the first cell's new value. + pub sweepable: bool, + /// Turning a cell on turns every other cell of the column off (solo). + pub exclusive: bool, +} + +impl ToggleColumn { + /// A sweepable toggle column (eye, lock, mute). + pub const fn sweepable() -> Self { + ToggleColumn { sweepable: true, exclusive: false } + } + + /// An exclusive toggle column: one cell is on at a time, and a drag does not sweep. + pub const fn exclusive() -> Self { + ToggleColumn { sweepable: false, exclusive: true } + } +} + +/// What a column's cells are. +#[derive(Clone, Copy, Debug, PartialEq, Eq)] +#[non_exhaustive] +pub enum ColumnKind { + /// Content the item paints. + Content, + /// A toggle the collection flips. + Toggle(ToggleColumn), +} + +/// One column of a collection. +#[derive(Clone, Debug)] +#[non_exhaustive] +pub struct ColumnSpec { + /// The column's stable key. + pub key: ColumnKey, + /// The header text. + pub header: Label, + /// How wide the column is. + pub width: ColumnWidth, + /// The user can drag the header's edge. + pub resizable: bool, + /// Activating the header reports `Sort`. + pub sortable: bool, + /// The user can move the column. + pub movable: bool, + /// The column stays in view while the others scroll. + pub frozen: bool, + /// What the cells are. + pub kind: ColumnKind, + /// Where the cells' content sits in the column. + pub align: ColumnAlign, + /// The cells' figures are tabular, so a column of numbers lines up. + pub tabular: bool, + /// The first press on the header sorts descending: sizes, dates and ratings, where the largest comes first. + pub first_descending: bool, + /// The icon the column's cells show: the name of a cell that has no header text. + pub icon: Option, +} + +/// Where a column's content sits. +#[derive(Clone, Copy, Debug, Default, PartialEq, Eq)] +pub enum ColumnAlign { + /// At the start edge. + #[default] + Start, + /// At the end edge. + End, +} + +impl ColumnSpec { + /// A content column with a header and a width; the other settings off. + pub fn new(key: ColumnKey, header: impl Into