Upgrade to Blitz v0.2.0 (#4731)

* Bump Rust CI version to 1.88

Signed-off-by: Nico Burns <nico@nicoburns.com>

* Upgrade to Blitz v0.2.0

Signed-off-by: Nico Burns <nico@nicoburns.com>

* Native: enable clipboard and file_dialog support by default

* Fix clippy errors

Signed-off-by: Nico Burns <nico@nicoburns.com>

* See if cargo update magically fixes build

Signed-off-by: Nico Burns <nico@nicoburns.com>

* Fix compile err

Signed-off-by: Nico Burns <nico@nicoburns.com>

* Remove unused wasm-opt dep

* Fix wgpu_child_window example

Signed-off-by: Nico Burns <nico@nicoburns.com>

* Update blitz-shell

Signed-off-by: Nico Burns <nico@nicoburns.com>

* cargo fmt

Signed-off-by: Nico Burns <nico@nicoburns.com>

* Allow clippy lint

Signed-off-by: Nico Burns <nico@nicoburns.com>

* CI: Bump pinned nightly version

Signed-off-by: Nico Burns <nico@nicoburns.com>

* Allow clippy lint in whole module

Signed-off-by: Nico Burns <nico@nicoburns.com>

* Fix more clippy lints

Signed-off-by: Nico Burns <nico@nicoburns.com>

* Use Rust 1.90 for clippy

Signed-off-by: Nico Burns <nico@nicoburns.com>

* cargo update --ignore-rust-version

* revert cargo updates

Signed-off-by: Nico Burns <nico@nicoburns.com>

* Revert another silly clippy lint

---------

Signed-off-by: Nico Burns <nico@nicoburns.com>
This commit is contained in:
Nico Burns authored and GitHub committed 2025-10-07 11:18:59 -07:00
1 parent 0b1f2fc8c2
commit 9359446017
26 files changed
+1029 -807

No files matched your search

-1
View File
@@ -106,7 +106,6 @@ tracing-subscriber = { version = "0.3.19", features = [
] }
console-subscriber = { version = "0.4.1", optional = true }
tracing = { workspace = true }
wasm-opt = { version = "0.116.1", optional = true }
ansi-to-tui = { workspace = true }
ansi-to-html = { workspace = true }
path-absolutize = { workspace = true }
+1
View File
@@ -98,6 +98,7 @@ fn merge_profiles(target: &mut Profiles, new: Profiles) {
}
}
#[allow(deprecated)]
if let Some(new_doc) = new.doc {
if target.doc.is_none() {
target.doc = Some(new_doc);
+1 -5
View File
@@ -193,11 +193,7 @@ pub(crate) fn post_create(path: &Path, vcs: &Vcs) -> Result<()> {
};
let mut toml = toml.parse::<toml_edit::DocumentMut>().map_err(|e| {
anyhow::anyhow!(
"failed to parse toml at {}: {}",
toml_path.display(),
e.to_string()
)
anyhow::anyhow!("failed to parse toml at {}: {}", toml_path.display(), e)
})?;
toml.as_table_mut().fmt();
+2 -2
View File
@@ -14,7 +14,7 @@ use crate::IncrementalRendererConfig;
pub(crate) type ContextProviders =
Arc<Vec<Box<dyn Fn() -> Box<dyn std::any::Any> + Send + Sync + 'static>>>;
/// A ServeConfig is used to configure how to serve a Dioxus application. It contains information about how to serve static assets, and what content to render with [`dioxus-ssr`].
/// A ServeConfig is used to configure how to serve a Dioxus application. It contains information about how to serve static assets, and what content to render with [`dioxus_ssr`].
#[derive(Clone, Default)]
pub struct ServeConfigBuilder {
pub(crate) root_id: Option<&'static str>,
@@ -491,7 +491,7 @@ pub enum StreamingMode {
OutOfOrder,
}
/// Used to configure how to serve a Dioxus application. It contains information about how to serve static assets, and what content to render with [`dioxus-ssr`].
/// Used to configure how to serve a Dioxus application. It contains information about how to serve static assets, and what content to render with [`dioxus_ssr`].
/// See [`ServeConfigBuilder`] to create a ServeConfig
#[derive(Clone)]
pub struct ServeConfig {
+3
View File
@@ -1,3 +1,6 @@
//! Generational box errors
#![allow(clippy::uninlined_format_args, reason = "causes compile error")]
use std::error::Error;
use std::fmt::Debug;
use std::fmt::Display;
+1 -1
View File
@@ -34,7 +34,7 @@ pub(crate) enum RwLockStorageEntryData {
impl Debug for RwLockStorageEntryData {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match self {
Self::Reference(location) => write!(f, "Reference({:?})", location),
Self::Reference(location) => write!(f, "Reference({location:?})"),
Self::Rc(_) => write!(f, "Rc"),
Self::Data(_) => write!(f, "Data"),
Self::Empty => write!(f, "Empty"),
+3 -1
View File
@@ -10,7 +10,9 @@ homepage = "https://dioxuslabs.com/learn/0.6/getting_started"
keywords = ["dom", "ui", "gui", "react"]
[features]
default = ["accessibility", "hot-reload", "tracing", "net", "html", "svg", "system-fonts"]
default = ["accessibility", "hot-reload", "tracing", "net", "html", "svg", "system-fonts", "clipboard", "file_dialog"]
clipboard = ["blitz-shell/clipboard"]
file_dialog = ["blitz-shell/file_dialog"]
svg = ["blitz-dom/svg", "blitz-paint/svg"]
net = ["dep:tokio", "dep:blitz-net"]
html = ["dep:blitz-html"]
+6 -2
View File
@@ -6,7 +6,7 @@ use anyrender::WindowRenderer;
pub use anyrender_vello::{
wgpu::{Features, Limits},
CustomPaintSource, VelloWindowRenderer as InnerRenderer,
CustomPaintSource, VelloRendererOptions, VelloWindowRenderer as InnerRenderer,
};
pub fn use_wgpu<T: CustomPaintSource>(create_source: impl FnOnce() -> T) -> u64 {
@@ -45,7 +45,11 @@ impl DioxusNativeWindowRenderer {
}
pub fn with_features_and_limits(features: Option<Features>, limits: Option<Limits>) -> Self {
let vello_renderer = InnerRenderer::with_features_and_limits(features, limits);
let vello_renderer = InnerRenderer::with_options(VelloRendererOptions {
features,
limits,
..Default::default()
});
Self::with_inner_renderer(vello_renderer)
}
+1 -3
View File
@@ -18,9 +18,7 @@ mod link_handler;
#[doc(inline)]
pub use dioxus_native_dom::*;
pub use anyrender_vello::{
wgpu_context::DeviceHandle, CustomPaintCtx, CustomPaintSource, TextureHandle,
};
pub use anyrender_vello::{CustomPaintCtx, CustomPaintSource, DeviceHandle, TextureHandle};
use assets::DioxusNativeNetProvider;
pub use dioxus_application::{DioxusNativeApplication, DioxusNativeEvent};
pub use dioxus_renderer::{use_wgpu, DioxusNativeWindowRenderer, Features, Limits};