♻️ Migra #[builder_fn] a #[builder_impl]
Sustituye las ~400 anotaciones `#[builder_fn]` método a método por un único `#[builder_impl]` por `impl`/`trait`, en 74 ficheros de pagetop y sus extensiones (admin, bootsier, menu, user).
This commit is contained in:
parent
c34dc02357
commit
1be3d88888
74 changed files with 104 additions and 394 deletions
|
|
@ -32,18 +32,18 @@ const EXTRA_WIDTH: &str = "bootsier.container.width";
|
|||
/// .with_prop(PropsOp::add_classes(class::Border::with(ScaleSize::One)))
|
||||
/// .with_prop(PropsOp::add_classes(class::Rounded::new()));
|
||||
/// ```
|
||||
#[builder_impl]
|
||||
pub trait ContainerBootsier {
|
||||
/// Establece el comportamiento del ancho para el contenedor.
|
||||
///
|
||||
/// Determina si el contenedor aplica los anchos máximos predefinidos para cada punto de
|
||||
/// ruptura, o si ocupa siempre el 100% del ancho disponible, o lo hace hasta un ancho máximo
|
||||
/// explícito. Ver [`Width`] para las variantes disponibles.
|
||||
#[builder_fn]
|
||||
fn with_width(self, width: Width) -> Self;
|
||||
}
|
||||
|
||||
#[builder_impl]
|
||||
impl ContainerBootsier for Container {
|
||||
#[builder_fn]
|
||||
fn with_width(mut self, width: Width) -> Self {
|
||||
self.alter_prop(PropsOp::set_extra(EXTRA_WIDTH, width));
|
||||
self
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue