mirror of
https://github.com/zadam/trilium.git
synced 2025-12-23 00:29:59 +01:00
chore(react/ribbon): react to add new label/relation even when not shown
This commit is contained in:
@@ -1,11 +1,14 @@
|
||||
import { useTriliumEvents } from "../react/hooks";
|
||||
import AttributeEditor from "./components/AttributeEditor";
|
||||
import { TabContext } from "./ribbon-interface";
|
||||
|
||||
export default function OwnedAttributesTab({ note, ...restProps }: TabContext) {
|
||||
export default function OwnedAttributesTab({ note, hidden, activate, ...restProps }: TabContext) {
|
||||
useTriliumEvents([ "addNewLabel", "addNewRelation" ], activate);
|
||||
|
||||
return (
|
||||
<div className="attribute-list">
|
||||
{ note && (
|
||||
<AttributeEditor note={note} {...restProps} />
|
||||
<AttributeEditor note={note} {...restProps} hidden={hidden} />
|
||||
)}
|
||||
</div>
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user