mirror of
https://github.com/yewprint/yewprint
synced 2024-11-21 19:13:05 +00:00
Tree: fix node not visibly disabled
This commit is contained in:
parent
e5b5a5585a
commit
b01e006371
2 changed files with 6 additions and 2 deletions
|
@ -307,7 +307,8 @@ impl Component for TreeNode {
|
|||
html! {
|
||||
<li class={classes!(
|
||||
"bp3-tree-node",
|
||||
ctx.props().is_selected.then_some("bp3-tree-node-selected")
|
||||
ctx.props().is_selected.then_some("bp3-tree-node-selected"),
|
||||
ctx.props().disabled.then_some("bp3-disabled"),
|
||||
)}>
|
||||
<div
|
||||
class="bp3-tree-node-content"
|
||||
|
@ -328,6 +329,8 @@ impl Component for TreeNode {
|
|||
)}
|
||||
icon={Icon::ChevronRight}
|
||||
onclick={self.handler_caret_click.clone()}
|
||||
aria_hidden=true
|
||||
tab_index={-1}
|
||||
/>
|
||||
}
|
||||
} else {
|
||||
|
|
|
@ -71,7 +71,8 @@ impl Component for Example {
|
|||
icon: Icon::Tag,
|
||||
icon_intent: Some(Intent::Primary),
|
||||
label: "Outer file".into(),
|
||||
secondary_label: Some(html!(<Icon icon={Icon::EyeOpen} />)),
|
||||
secondary_label: Some(html!(<Icon icon={Icon::Lock} />)),
|
||||
disabled: true,
|
||||
data: 3,
|
||||
..Default::default()
|
||||
}),
|
||||
|
|
Loading…
Reference in a new issue