♻️ (pagetop): Deshabilita menús con with_disabled()
Cambia `link_disabled()`, `link_blank_disabled()` y `button_disabled()` de `nav::Item` y `dropdown::Item` por `with_disabled(bool)`, como en Button.
This commit is contained in:
parent
5d6852382a
commit
f1fd34f974
12 changed files with 123 additions and 93 deletions
|
|
@ -25,7 +25,7 @@ use crate::prelude::*;
|
|||
/// .with_item(dropdown::Item::link(Lc::n("Action"), "/action"))
|
||||
/// .with_item(dropdown::Item::link(Lc::n("Another"), "/another")),
|
||||
/// ))
|
||||
/// .with_item(nav::Item::link_disabled(Lc::n("Disabled"), "#"));
|
||||
/// .with_item(nav::Item::link(Lc::n("Disabled"), "#").with_disabled(true));
|
||||
/// ```
|
||||
#[derive(AutoDefault, Clone, Debug, Getters)]
|
||||
pub struct Nav {
|
||||
|
|
@ -237,7 +237,7 @@ impl Nav {
|
|||
/// nav.with_item(nav::Item::link("Inicio", "/"));
|
||||
/// nav.with_item(TypedOp::AddMany(vec![
|
||||
/// nav::Item::link(...),
|
||||
/// nav::Item::link_disabled(...),
|
||||
/// nav::Item::link(...).with_disabled(true),
|
||||
/// ]));
|
||||
/// ```
|
||||
pub fn with_item(mut self, op: impl Into<TypedOp<nav::Item>>) -> Self {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue