clean up prelude (#4416)
* clear away prelude on dioxus * clippy * wip - drop prelude from dioxus-html * docs clippy * wip * more fixe * delete all preludes * doc... * better export * merge some imports * fewer global imports * global incremental renderer * fix cargo doc
This commit is contained in:
1 parent
54d465a7b5
commit
4f1d039bad
140 files changed
+374
-477
No files matched your search
@@ -1,8 +1,8 @@
|
||||
#![allow(non_upper_case_globals)]
|
||||
#![allow(deprecated)]
|
||||
|
||||
use dioxus_core::prelude::IntoAttributeValue;
|
||||
use dioxus_core::HasAttributes;
|
||||
use dioxus_core::IntoAttributeValue;
|
||||
use dioxus_html_internal_macro::impl_extension_attributes;
|
||||
|
||||
use crate::AttributeDescription;
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
#![allow(non_upper_case_globals)]
|
||||
|
||||
use dioxus_core::prelude::IntoAttributeValue;
|
||||
use dioxus_core::HasAttributes;
|
||||
use dioxus_core::IntoAttributeValue;
|
||||
#[cfg(feature = "hot-reload-context")]
|
||||
use dioxus_core_types::HotReloadingContext;
|
||||
use dioxus_html_internal_macro::impl_extension_attributes;
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
use crate::geometry::{ClientPoint, Coordinates, ElementPoint, PagePoint, ScreenPoint};
|
||||
use crate::input_data::{MouseButton, MouseButtonSet};
|
||||
use crate::prelude::*;
|
||||
use crate::*;
|
||||
|
||||
use dioxus_core::Event;
|
||||
use keyboard_types::Modifiers;
|
||||
|
||||
@@ -2,7 +2,7 @@ use dioxus_core::Event;
|
||||
use keyboard_types::{Code, Key, Location, Modifiers};
|
||||
use std::fmt::Debug;
|
||||
|
||||
use crate::prelude::ModifiersInteraction;
|
||||
use crate::ModifiersInteraction;
|
||||
|
||||
#[cfg(feature = "serialize")]
|
||||
fn resilient_deserialize_code<'de, D>(deserializer: D) -> Result<Code, D::Error>
|
||||
|
||||
@@ -25,7 +25,7 @@ macro_rules! impl_event {
|
||||
#[doc(alias = $js_name)]
|
||||
)?
|
||||
#[inline]
|
||||
pub fn $name<__Marker>(mut _f: impl ::dioxus_core::prelude::SuperInto<::dioxus_core::ListenerCallback<$data>, __Marker>) -> ::dioxus_core::Attribute {
|
||||
pub fn $name<__Marker>(mut _f: impl ::dioxus_core::SuperInto<::dioxus_core::ListenerCallback<$data>, __Marker>) -> ::dioxus_core::Attribute {
|
||||
let event_handler = _f.super_into();
|
||||
::dioxus_core::Attribute::new(
|
||||
impl_event!(@name $name $($js_name)?),
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
use crate::geometry::{ClientPoint, Coordinates, ElementPoint, PagePoint, ScreenPoint};
|
||||
use crate::input_data::{MouseButton, MouseButtonSet};
|
||||
use crate::prelude::*;
|
||||
use crate::*;
|
||||
use dioxus_core::Event;
|
||||
use keyboard_types::Modifiers;
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
use dioxus_core::Event;
|
||||
use keyboard_types::Modifiers;
|
||||
|
||||
use crate::{geometry::*, input_data::*, prelude::*};
|
||||
use crate::{geometry::*, input_data::*, *};
|
||||
|
||||
/// A synthetic event that wraps a web-style [`PointerEvent`](https://developer.mozilla.org/en-US/docs/Web/API/PointerEvent)
|
||||
pub type PointerEvent = Event<PointerData>;
|
||||
|
||||
@@ -2,7 +2,7 @@ use dioxus_core::Event;
|
||||
use keyboard_types::Modifiers;
|
||||
|
||||
use crate::geometry::*;
|
||||
use crate::prelude::{InteractionLocation, ModifiersInteraction};
|
||||
use crate::{InteractionLocation, ModifiersInteraction};
|
||||
|
||||
pub type TouchEvent = Event<TouchData>;
|
||||
pub struct TouchData {
|
||||
|
||||
@@ -1,9 +1,12 @@
|
||||
use dioxus_core::Event;
|
||||
use keyboard_types::Modifiers;
|
||||
use std::fmt::Formatter;
|
||||
|
||||
use crate::geometry::*;
|
||||
use crate::input_data::{MouseButton, MouseButtonSet};
|
||||
use crate::prelude::*;
|
||||
use crate::{geometry::*, InteractionLocation, ModifiersInteraction, PointerInteraction};
|
||||
use crate::{
|
||||
input_data::{MouseButton, MouseButtonSet},
|
||||
InteractionElementOffset,
|
||||
};
|
||||
|
||||
use super::HasMouseData;
|
||||
|
||||
|
||||
@@ -41,15 +41,17 @@ pub use elements::*;
|
||||
pub use events::*;
|
||||
pub use render_template::*;
|
||||
|
||||
pub use crate::attribute_groups::{GlobalAttributesExtension, SvgAttributesExtension};
|
||||
pub use crate::elements::extensions::*;
|
||||
pub use crate::point_interaction::*;
|
||||
pub use keyboard_types::{self, Code, Key, Location, Modifiers};
|
||||
|
||||
pub mod traits {
|
||||
pub use crate::events::*;
|
||||
pub use crate::point_interaction::*;
|
||||
}
|
||||
|
||||
pub mod extensions {
|
||||
pub use crate::attribute_groups::{GlobalAttributesExtension, SvgAttributesExtension};
|
||||
pub use crate::elements::extensions::*;
|
||||
}
|
||||
|
||||
pub mod prelude {
|
||||
pub use crate::attribute_groups::{GlobalAttributesExtension, SvgAttributesExtension};
|
||||
pub use crate::elements::extensions::*;
|
||||
pub use crate::events::*;
|
||||
pub use crate::point_interaction::*;
|
||||
pub use keyboard_types::{self, Code, Key, Location, Modifiers};
|
||||
}
|
||||
Reference in new issue
Block a user