Commit Graph

2622 Commits

Author SHA1 Message Date
Dennis Kobert 50ef6e15cb
Use glob syntax for Cargo.toml (#3489)
* Use glob syntax for Cargo.toml

* Readd nested crates to workspace members and reduce the list of default members
2026-03-05 10:20:41 +00:00
Keavon Chambers ead914ec2b
Fix regression where Vello doesn't render new document opened after closing all documents (#3849)
* Fix regression where Vello doesn't render new document opened after closing all documents

* Remove last_svg_canvas and do this logic in the frontend
2026-03-05 09:54:31 +00:00
Keavon Chambers 8a1dfb9d8f
Refactor messages.ts by removing class-transformer and JS classes (#3858)
* Fix gamma correction with HTML-based editable Text tool text

* Migrate simple, undecorated classes to types

* Remove TupleToVec2 transformation

* Remove @Transform from tooltips

* Cleanup: replace value.toString() with String(value) everywhere

* Convert documentId from string to bigint

* Migrate the rest of the easy @Transform/@Type decorations

* Migrate FillChoice

* Migrate WidgetDiffUpdate

* Migrate WidgetInstance

* Migrate away from classes that extend WidgetProps

* Remove class-transformer and all classes in messages.ts

* Migrate UI layout passing

* Remove dead code

* Remove unnecessary export and readonly prefixes

* Remove HSVA type

* Break out Color, Gradient, and FillChoice functions into a utility-functions file

* Move widget helper functions from messages.ts into a new utility-functions file; restructure type imports

* Reduce internal type defs

* Rename JsMessage to FrontendMessage

* Code review fixes

* Fix other usages

* Tidying up
2026-03-05 01:43:21 -08:00
Keavon Chambers f00a15a4c9
Clean up Gradient and Color classes in TS by removing their methods (#3857) 2026-03-04 02:39:07 -08:00
Keavon Chambers 5834ee9ce4
Clean up generic widget handling code in the frontend (#3856)
* Clean up WidgetSpan component code to avoid the giant if-chain for choosing a widget

* Improve typing support
2026-03-04 01:00:09 -08:00
Keavon Chambers 8a75c0c1e1
Add layer locked toggle icon and context menu entry to node graph (#3855)
* Add layer locked toggle icon and context menu entry to node graph

* Simplify logic
2026-03-04 06:30:04 +00:00
Mohan 54a02dedd5
Fix thumbnails not being updated for layers when they become empty (#3624)
* fix: thumbnail render for empty layers

* removed self import

* fix: rename

* Cleanup

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2026-03-03 06:45:19 +00:00
Keavon Chambers 7cc3097acd
Make the Outline render mode draw with consistent stroke thickness at any viewport zoom (#3848)
* Remove dead code for now-retired SVG implementation

* Implement viewport zoom compensation for thickness
2026-03-02 20:13:05 -08:00
Keavon Chambers a8b5203d6c
Clean up code for drawing overlays to accept sRGB hex codes instead of Color structs (#3839)
* Clean up code for drawing overlays to accept sRGB hex codes instead of Color structs

* Consolidate hex code parsing functions
2026-02-27 14:08:58 -08:00
Keavon Chambers 9ecbfb7110
New nodes: RGBA to Color, HSVA to Color, Hex to Color, and Read Gradient (#3838)
* New nodes: RGBA to Color, HSVA to Color, Hex to Color, and Read Gradient

* Simplify
2026-02-26 18:22:04 -08:00
Keavon Chambers f1cbc4b396
Make the node graph use Table<GradientStops> instead of GradientStops (#3837)
* Switch from GradientStops to Table<GradientStops> in all nodes

* Remove TaggedValue::ColorNotInTable

* Fix bug

Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>

* Add migrations

* Fix default gradient on empty table

* Update demo artwork

---------

Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
2026-02-26 14:07:31 -08:00
Keavon Chambers 81c73d11ff
Clean up duplicated code used for recursively flattening graphic types (#3836)
* Reduce recusive flattening algorithm duplication

* Generalize further

* Avoid code duplication in the 'Flatten Path' node

* Avoid cloning

* Include intermediate levels of alpha blending composition
2026-02-26 05:36:23 -08:00
Keavon Chambers cde7d5f951
New nodes: Colors to Gradient, Flatten Color, and Flatten Gradient (#3835)
* New nodes: Colors to Gradient, Flatten Color, and Flatten Gradient

* Fix Data panel not showing GradientStops

* Fix wrong category
2026-02-26 03:44:12 -08:00
Timon da7437c023
Reimplement notice file generation for third-party licenses through Rust, now with CEF credits (#3808) 2026-02-26 11:12:28 +00:00
Keavon Chambers 4090f6c980 Tweak short-term roadmap details 2026-02-25 21:40:36 -08:00
Keavon Chambers e62771845f
Add an in-viewport color picker to the Gradient tool when double-clicking a color stop (#3834)
* Hide batched blocked debug print messages

* Implement the color picker on double-clicking stops

* Code review
2026-02-25 21:03:12 -08:00
Keavon Chambers 82cf8eb369
Upgrade Linebender and related dependencies (#3819)
Co-authored-by: Timon <me@timon.zip>
2026-02-25 19:10:57 +00:00
Keavon Chambers 8117ddcdb3
Add Gradient tool control bar buttons, Reverse Stops and Reverse Direction (#3830)
* Add Gradient tool control bar buttons, Reverse Stops and Reverse Direction

* Consolidate reused gradient line updating code
2026-02-25 00:48:21 -08:00
Keavon Chambers b4679b0675
Improve Gradient tool dragging behavior and make hints reactive to current interaction state (#3828)
* Improve Gradient tool dragging behavior and make hints reactive to current interaction state

* Reduce code duplication for drawing stops

* Fix coordinate system issue when PTZ'ing document during drag or autopan
2026-02-24 22:17:29 -08:00
Keavon Chambers 4a6cdffd84
Add draggable diamond midpoint gizmos to the Gradient tool (#3826) 2026-02-24 20:25:15 -08:00
Dennis Kobert 7250b091d5
Fix the UI scaling factor invalidating the render cache (#3818)
* Fix ui scaling messing up render cache

* Review

---------

Co-authored-by: Timon <me@timon.zip>
2026-02-24 12:41:42 +00:00
Dennis Kobert 65ca8610eb
Split CI job to run on dedicated runners for web and native build (#3812)
* Split ci job to run on dedicated runners for web and native build

* Trigger CI

* Update labels

* Update comment text

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2026-02-24 09:37:00 +00:00
Kulcode 3b91d02fff
Add snapping to endpoints and stops in the Gradient tool (#3732)
* snapping

* Cleanup

* fix

* Fix snapping failing sometimes on newly drawn gradient lines

* Code cleanup

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2026-02-24 04:48:28 +00:00
Keavon Chambers 691d965bcf
Add support for gradients with midpoints and add draggable diamonds to the color picker dialog (#3813)
* Refactor GradientStops to use struct-of-arrays and include midpoint

* Implement interaction and rendering

* Make color picker saturation-value color picking snap to original position and show both axis lines

Make color picker saturation-value color picking snap to original position and show both axis lines

* Add graphite:midpoint attribute to SVG exports

* Add graphite:midpoint parsing to SVG importer
2026-02-23 19:21:51 -08:00
Dennis Kobert a1c1039ea1
Fix path tool overlays (#3810)
* Add vector data to merge function

Use destructuring to avoid issues like this in the future

* Remove unnecessary explict copying
2026-02-23 09:17:00 +00:00
Keavon Chambers 71b4c98de7 Fix logarithmic spiral not drawing if Inner Radius is 0 2026-02-22 13:48:19 -08:00
Keavon Chambers 9f2c8713ff
Add the SVG Preview render mode in place of the Vello option in the preferences (#3797)
* Remove Vello from preferences

* Add the Render Mode: SVG Preview radio button

* Remove SVG outline renderer

* Add a tooltip explaination when disabled in unsupported browsers

* Fix Eyedropper tool to support Outline render mode

* Use #[allow(clippy::too_many_arguments)] instead of tuple

* Rerun nodegraph when max render area is changed

---------

Co-authored-by: Dennis Kobert <dennis@kobert.dev>
2026-02-22 20:27:26 +00:00
Timon a2d3b3f410
Desktop: Make shutdown more robust and fix panic caused by invalid viewport scale (#3783)
* Fix panic caused by invalid viewport scale

* Make shutdown more robust
2026-02-22 17:28:35 +00:00
Jill Chhagnani 9d83998463
Fix missing crash dialog for panics thrown inside requestAnimationFrame loop (#3788)
* add crash dialog in RAF path

* removed panic!()

* removed redundant string allocationa dn duplication between function

* fixed allocation

* removed bloated code
2026-02-22 17:27:23 +00:00
Dennis Kobert 0531769c41
Cache Vello render output as stitchable textures (#3722)
* WIP render caching

* Hook up render cache to render pipeline

* Fixed offsets

* Initial cleanup

* Integrate cache with context invalidation

* Cleanup

* Improve rounding and reduce tile size to fix vello not rendering

* Include pointer position in cache key

* Avoid unwraps and zero sized textures

* Destroy textures after blitting to surface

* Fix context dependencies

* Exclude footprint from render params

* Batch animation frame messages

* Add vello max render size to preference dialogue

* Remove unused import

* Reorder vello preference

* Clean up preferences dialog

* Apply review suggestions

* Cap max render region size

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2026-02-22 10:12:50 +00:00
Keavon Chambers 5aca75dcbd Simplify breadcrumb trail buttons widget styling 2026-02-20 22:50:05 -08:00
Keavon Chambers 7ca6470656
Rename the repeat nodes to replace "Instance" terminology with "Repeat" (#3794)
* WIP

* Move the Mirror node from the module 'vector' to 'graphic'

* Update demo art

* Fix failing tests

Fix tests
2026-02-20 22:10:59 -08:00
Keavon Chambers 5a1503fc98 New node: Flatten Raster 2026-02-20 13:35:12 -08:00
Dennis Kobert ba177c4c5d
Generalize the 'Map Vector' node as 'Map' with support for all graphical types (#3793)
* Rename Map Vector to Map

* Fix compilation errors

* Move to the Graphic module and add Read {Graphic, Raster, Color} nodes

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2026-02-20 21:33:02 +00:00
Keavon Chambers bd1c54907d
Rename nodes from "Instance ___" -> "Read ___" and "Instance Map" -> "Map Vector" (#3792)
* Rename nodes from "Instance ___" -> "Read ___" and "Instance Map" -> "Map Vector"

* Update leftover references and demo artwork

* Simplify logic

* Fix test
2026-02-20 08:52:36 +00:00
Keavon Chambers da278e0264 New node: Map Points
Also resolves #3217
2026-02-19 14:37:35 -08:00
Keavon Chambers 258748ec51
Swap the default placement order of Fill and Stroke nodes in layers (#3789) 2026-02-19 13:15:11 -08:00
Timon 3f999bf231
Desktop: Add "Disable UI Acceleration" to preferences (#3774)
* Deskltop: Add Disable UI Accelaration preference

* Fixup

* Fix typo

* Code review and update strings

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2026-02-19 01:54:01 +00:00
Keavon Chambers 6824f55929 Add hover style to checkboxes when their corresponding labels are hovered 2026-02-18 17:37:34 -08:00
Dennis Kobert e1357c5c34
Improve CI times and make merge queue only trigger one CI run (#3755)
* Split ci job into multiple jobs running on github runners

* Add permission to build steps

* Try running rust build on selfhosted runner

* Disable nix setup for self hosted runner

* Revert build and only run lint + web build + rust fmt on gh runners

* Only build rust tests and ignore branding for frontend lint

* Provide stub ts types for running linter without building wasm bundle

* Manually install wasm-opt + use cargo-binstall

* Only build with shaders for master builds

* Revert splitting of lint job

* Attempt to build with shaders

* Explicitly install linux target

* Move frontend build back to self hosted runner

* Remove whitespace changes

* Remove explicit build step
2026-02-18 22:22:47 +00:00
Ayush Amawate 9bf3605b85
Add F2 shortcut for renaming the selected layer (#3641)
* add keyboard shortcuts for renaming layers

* apply reviewed suggestions

* Add todo comment

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2026-02-18 12:05:04 +00:00
Kulcode b433ddd007
Add button in Properties panel to select the node connected to an exposed parameter (#3720)
* Navigation-Shortcut

* Fix as rec

* cleanup

* Update labels

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2026-02-18 10:25:02 +00:00
Keavon Chambers 5d5993bcca
Fix opacity not being included in alpha of Fill type when converted from Table<Color> (#3785)
* Fix opacity not being included in alpha of Fill type when converted from Table<Color>

* Avoid unwrap, I guess
2026-02-18 09:21:02 +00:00
Jatin Bharti e5827f2b81
Fix crash opening File > Export if it previously was set to the bounds of a now-deleted artboard (#3577)
fix : Crash loading export dialogue
2026-02-17 23:24:13 -08:00
Aniket giri f801ed72bb
Clean up DocumentMessageHandler by breaking out several lengthy handlers into helper functions (#3568)
refactor(document): extract large match arms into helper methods

Part of #2740 - Code quality refactors.

This commit addresses the 'Match statements' section of the tracking
issue by extracting three large match arms from process_message() into
dedicated helper methods:

- handle_group_selected_layers: Handles layer grouping in both artboard
  and non-artboard workflows (~50 lines extracted)
- handle_move_selected_layers_to: Handles layer movement with proper
  transform preservation (~85 lines extracted)
- handle_nudge_selected_layers: Handles keyboard nudging with optional
  resize mode (~75 lines extracted)

The main match statement in DocumentMessageHandler is now ~210 lines
shorter and more readable. Logic and behavior remain unchanged.
2026-02-17 22:01:32 +00:00
Timon 3571c0d577
Fix Vello canvas on web not being transparent by using premultiplied alpha mode (#3770)
Fix canvas not being transparent by using Premultiplied alpha mode
2026-02-17 20:48:16 +00:00
Kulcode 2fe0cf7a4c
Fix holding Ctrl in the graph not allowing for selecting nodes unless some are in a layer (#3778)
* Fix

* Fix-2

* Formatting

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2026-02-17 20:20:57 +00:00
blue linden 3b1a51b393
Comment the GH Actions run link on `!build` comments for easier troubleshooting (#3392)
* Comment on `!build` requests with the Actions run ID for easier troubleshooting

* Update the triggering comment instead of making another one for the build link

* Make sure the workflow doesn't fail if the triggering comment was deleted.

* Post comment on build/upload failure

* Don't post a build link comment separately if the OG is deleted

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2026-02-17 01:10:47 +00:00
Ashish Mohapatra 723f7b14ea
Respect artboard clipping when computing canvas scrollbars (#3387) 2026-02-17 00:32:33 +00:00
Kulcode ed20f4ac9b
Fix outline rendering mode to draw shapes as black or white based on contrast with their artboard's color (#3724)
* contrast

* Update

* error corrected

* changes

* Fix

* fix-2

* cleanup-2

* Formatting

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2026-02-16 23:38:12 +00:00