🚚 Rename macro AssignHandle to BindHandle
This commit is contained in:
parent
a03472a2bc
commit
dc4210bcb8
13 changed files with 15 additions and 15 deletions
|
|
@ -1,6 +1,6 @@
|
|||
use pagetop::prelude::*;
|
||||
|
||||
#[derive(AssignHandle)]
|
||||
#[derive(BindHandle)]
|
||||
struct Drust;
|
||||
|
||||
impl ModuleTrait for Drust {
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
use pagetop::prelude::*;
|
||||
|
||||
#[derive(AssignHandle)]
|
||||
#[derive(BindHandle)]
|
||||
struct HelloName;
|
||||
|
||||
impl ModuleTrait for HelloName {
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
use pagetop::prelude::*;
|
||||
|
||||
#[derive(AssignHandle)]
|
||||
#[derive(BindHandle)]
|
||||
struct HelloWorld;
|
||||
|
||||
impl ModuleTrait for HelloWorld {
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ static_locales!(LOCALES_ADMIN);
|
|||
|
||||
mod summary;
|
||||
|
||||
#[derive(AssignHandle)]
|
||||
#[derive(BindHandle)]
|
||||
pub struct Admin;
|
||||
|
||||
impl ModuleTrait for Admin {
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ static_locales!(LOCALES_BOOTSIER);
|
|||
|
||||
static_files!(bootsier);
|
||||
|
||||
#[derive(AssignHandle)]
|
||||
#[derive(BindHandle)]
|
||||
pub struct Bootsier;
|
||||
|
||||
impl ModuleTrait for Bootsier {
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@ use pagetop::prelude::*;
|
|||
|
||||
static_files!(bulmix);
|
||||
|
||||
#[derive(AssignHandle)]
|
||||
#[derive(BindHandle)]
|
||||
pub struct Bulmix;
|
||||
|
||||
impl ModuleTrait for Bulmix {
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ static_locales!(LOCALES_HOMEDEMO);
|
|||
|
||||
static_files!(homedemo);
|
||||
|
||||
#[derive(AssignHandle)]
|
||||
#[derive(BindHandle)]
|
||||
pub struct HomeDemo;
|
||||
|
||||
impl ModuleTrait for HomeDemo {
|
||||
|
|
|
|||
|
|
@ -128,8 +128,8 @@ pub fn base_handle_derive(input: TokenStream) -> TokenStream {
|
|||
impl_handle(input, quote! { crate })
|
||||
}
|
||||
|
||||
#[proc_macro_derive(AssignHandle, attributes(handle))]
|
||||
pub fn assign_handle_derive(input: TokenStream) -> TokenStream {
|
||||
#[proc_macro_derive(BindHandle, attributes(handle))]
|
||||
pub fn bind_handle_derive(input: TokenStream) -> TokenStream {
|
||||
impl_handle(input, quote! { pagetop })
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ static_locales!(LOCALES_NODE);
|
|||
//mod entity;
|
||||
mod migration;
|
||||
|
||||
#[derive(AssignHandle)]
|
||||
#[derive(BindHandle)]
|
||||
pub struct Node;
|
||||
|
||||
impl ModuleTrait for Node {
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ static_locales!(LOCALES_USER);
|
|||
|
||||
mod migration;
|
||||
|
||||
#[derive(AssignHandle)]
|
||||
#[derive(BindHandle)]
|
||||
pub struct User;
|
||||
|
||||
impl ModuleTrait for User {
|
||||
|
|
|
|||
|
|
@ -44,7 +44,7 @@
|
|||
//! ```rust
|
||||
//! use pagetop::prelude::*;
|
||||
//!
|
||||
//! #[derive(AssignHandle)]
|
||||
//! #[derive(BindHandle)]
|
||||
//! struct HelloWorld;
|
||||
//!
|
||||
//! impl ModuleTrait for HelloWorld {
|
||||
|
|
@ -108,7 +108,7 @@ pub use paste::paste;
|
|||
/// customized default values.
|
||||
pub use smart_default::SmartDefault;
|
||||
|
||||
pub use pagetop_macros::{fn_builder, main, test, AssignHandle, ComponentClasses};
|
||||
pub use pagetop_macros::{fn_builder, main, test, BindHandle, ComponentClasses};
|
||||
|
||||
pub(crate) use pagetop_macros::BaseHandle;
|
||||
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@ pub use crate::{Handle, HashMapResources, ImplementHandle, LazyStatic, Weight};
|
|||
|
||||
// Functions and macro helpers.
|
||||
pub use crate::util;
|
||||
pub use crate::{kv, AssignHandle, ComponentClasses};
|
||||
pub use crate::{kv, BindHandle, ComponentClasses};
|
||||
|
||||
// MACROS.
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
use pagetop::prelude::*;
|
||||
|
||||
#[derive(AssignHandle)]
|
||||
#[derive(BindHandle)]
|
||||
struct HealthCheck;
|
||||
|
||||
impl ModuleTrait for HealthCheck {}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue