Wrap serialized gradient stops in a new GradientRamp struct and unify FillChoice (#4400)

* Introduce the GradientRamp exchange struct as the serialized TaggedValue::Gradient payload

* Unify FillChoice and FillChoiceUI into one enum generic over color format, carrying GradientRamp stops

* Rename the TaggedValue::Gradient variant to GradientRamp to match its payload

* Move the Color variant into the tagged_value macro list since its stored and wire forms match
This commit is contained in:
Keavon Chambers
2026-09-15 14:38:39 +02:00
committed by Dennis Kobert
parent a0df7c2513
commit 57c01ed413
32 changed files with 411 additions and 288 deletions
+2 -2
View File
@@ -2,10 +2,10 @@ import { writable } from "svelte/store";
import type { Writable } from "svelte/store";
import type { SubscriptionsRouter } from "/src/subscriptions-router";
import { patchLayout } from "/src/utility-functions/widgets";
import type { FillChoiceUI, Layout } from "/wrapper/pkg/graphite_wasm_wrapper";
import type { FillChoice, Layout, SRGBA8 } from "/wrapper/pkg/graphite_wasm_wrapper";
export type ColorPickerCallbacks = {
onColorChanged?: (value: FillChoiceUI) => void;
onColorChanged?: (value: FillChoice<SRGBA8>) => void;
onStartTransaction?: () => void;
onCommitTransaction?: () => void;
};