Skip to content

Commit

Permalink
Remove unused imports from the blitz crate
Browse files Browse the repository at this point in the history
  • Loading branch information
nicoburns committed Jul 23, 2024
1 parent 27df581 commit 8fe6dfb
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 43 deletions.
26 changes: 1 addition & 25 deletions packages/blitz/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,36 +8,12 @@ default = ["tracing"]
tracing = ["dep:tracing"]

[dependencies]
slab = "0.4.9"
blitz-dom = { path = "../dom" }
style = { workspace = true, features = ["servo"] }
euclid = { version = "0.22", features = ["serde"] }
selectors = { workspace = true }
taffy = { workspace = true }
parley = { workspace = true }
tokio = { workspace = true, features = ["full"] }
tracing = { workspace = true, optional = true }
vello = { workspace = true }
wgpu = { workspace = true }

app_units = "0.7.3"
atomic_refcell = { version = "0.1.13", features = ["serde"] }
fxhash = "0.2.1"
html5ever = { workspace = true }
string_cache = "0.8.7"
futures-util = "0.3.29"
raw-window-handle = "0.6.0"
blitz-dom = { path = "../dom" }
image = "0.25"

# futures-util = "0.3.29"
# raw-window-handle = "0.5.0"
# guts pulled from blitz
# we'll need to make these more compatible with servo
# lightningcss = "1.0.0-alpha.39"
# cssparser = "0.33.0"
# tao = "0.24.0"
# glazier = { git = "https://github.com/linebender/glazier/" }
# style = { git = "https://github.com/servo/servo.git", features = ["servo"] }

[dev-dependencies]
webbrowser = "0.8.12"
30 changes: 12 additions & 18 deletions packages/blitz/src/renderer/render.rs
Original file line number Diff line number Diff line change
@@ -1,25 +1,15 @@
use std::sync::Arc;

use super::multicolor_rounded_rect::{Edge, ElementFrame};
use crate::{
devtools::Devtools,
util::{GradientSlice, StyloGradient, ToVelloColor},
};
use blitz_dom::{
node::{NodeData, TextNodeData},
Node,
};
use blitz_dom::{
node::{TextBrush, TextInputData},
Document,
};
use html5ever::local_name;
use image::{imageops::FilterType, DynamicImage};
use parley::layout::PositionedLayoutItem;
use blitz_dom::node::{NodeData, TextBrush, TextInputData, TextNodeData};
use blitz_dom::{local_name, Document, Node};

use style::{
dom::TElement,
values::{generics::image::GradientFlags, specified::position::HorizontalPositionKeyword},
};
use style::{
properties::generated::longhands::visibility::computed_value::T as StyloVisibility,
properties::{style_structs::Outline, ComputedValues},
values::{
Expand All @@ -28,23 +18,27 @@ use style::{
},
generics::{
color::Color as StyloColor,
image::{EndingShape, GenericGradient, GenericGradientItem, GenericImage},
image::{
EndingShape, GenericGradient, GenericGradientItem, GenericImage, GradientFlags,
},
position::GenericPosition,
NonNegative,
},
specified::{position::VerticalPositionKeyword, BorderStyle, OutlineStyle},
specified::position::{HorizontalPositionKeyword, VerticalPositionKeyword},
specified::{BorderStyle, OutlineStyle},
},
OwnedSlice,
};

use image::{imageops::FilterType, DynamicImage};
use parley::layout::PositionedLayoutItem;
use taffy::prelude::Layout;
use vello::{
kurbo::{Affine, Point, Rect, Shape, Stroke, Vec2},
peniko::{self, Color, Fill},
Scene,
};

use super::multicolor_rounded_rect::{Edge, ElementFrame};

/// Draw the current tree to current render surface
/// Eventually we'll want the surface itself to be passed into the render function, along with things like the viewport
///
Expand Down

0 comments on commit 8fe6dfb

Please sign in to comment.