Replace Table<Table<Graphic>> with Table<Artboard> where Artboard is a type boundary newtype (#4093)

Replace Table<Table<Graphic>> with Table<Artboard> with Artboard as a type boundary newtype
This commit is contained in:
Keavon Chambers
2026-05-01 21:57:50 -07:00
committed by GitHub
parent 9943af5248
commit a0d5f418d9
16 changed files with 134 additions and 86 deletions

View File

@@ -3,7 +3,7 @@ use core_types::transform::Footprint;
use core_types::{CacheHash, CloneVarArgs, Color, Context, Ctx, ExtractAll, ExtractAnimationTime, ExtractPointerPosition, ExtractRealTime, OwnedContextImpl};
use glam::{DAffine2, DVec2};
use graphic_types::vector_types::GradientStops;
use graphic_types::{Graphic, Vector};
use graphic_types::{Artboard, Graphic, Vector};
use raster_types::{CPU, GPU, Raster};
const DAY: f64 = 1000. * 3600. * 24.;
@@ -78,7 +78,7 @@ async fn quantize_real_time<T>(
Context -> Table<Raster<CPU>>,
Context -> Table<Raster<GPU>>,
Context -> Table<Color>,
Context -> Table<Table<Graphic>>,
Context -> Table<Artboard>,
Context -> Table<GradientStops>,
Context -> Table<String>,
Context -> Table<f64>,
@@ -118,7 +118,7 @@ async fn quantize_animation_time<T>(
Context -> Table<Raster<CPU>>,
Context -> Table<Raster<GPU>>,
Context -> Table<Color>,
Context -> Table<Table<Graphic>>,
Context -> Table<Artboard>,
Context -> Table<GradientStops>,
Context -> Table<String>,
Context -> Table<f64>,

View File

@@ -6,7 +6,7 @@ use core_types::uuid::NodeId;
use core_types::{Color, OwnedContextImpl};
use glam::{DAffine2, DVec2};
use graphic_types::vector_types::GradientStops;
use graphic_types::{Graphic, Vector};
use graphic_types::{Artboard, Graphic, Vector};
use raster_types::{CPU, GPU, Raster};
/// Filters out what should be unused components of the context based on the specified requirements.
@@ -35,7 +35,7 @@ async fn context_modification<T>(
Context -> Table<Raster<CPU>>,
Context -> Table<Raster<GPU>>,
Context -> Table<Color>,
Context -> Table<Table<Graphic>>,
Context -> Table<Artboard>,
Context -> Table<GradientStops>,
)]
value: impl Node<Context<'static>, Output = T>,