mirror of
https://github.com/zadam/trilium.git
synced 2025-10-20 23:29:02 +02:00
chore(react): clean up
This commit is contained in:
parent
f8b563704f
commit
04913394c6
@ -9,6 +9,7 @@ import ReactBasicWidget from "../react/ReactBasicWidget.js";
|
||||
import froca from "../../services/froca.js";
|
||||
import tree from "../../services/tree.js";
|
||||
import FBranch from "../../entities/fbranch.js";
|
||||
import Button from "../react/Button.jsx";
|
||||
|
||||
interface BranchPrefixDialogProps {
|
||||
branch?: FBranch;
|
||||
@ -35,7 +36,7 @@ function BranchPrefixDialogComponent({ branch }: BranchPrefixDialogProps) {
|
||||
onShown={() => branchInput.current?.focus()}
|
||||
onSubmit={onSubmit}
|
||||
helpPageId="TBwsyfadTA18"
|
||||
footer={<button class="btn btn-primary btn-sm">{t("branch_prefix.save")}</button>}
|
||||
footer={<Button text={t("branch_prefix.save")} />}
|
||||
>
|
||||
<div class="form-group">
|
||||
<label for="branch-prefix-input">{t("branch_prefix.prefix")}</label>
|
||||
|
@ -1,11 +1,10 @@
|
||||
import { useEffect, useRef } from "preact/hooks";
|
||||
import shortcuts from "../../services/shortcuts";
|
||||
import { useRef } from "preact/hooks";
|
||||
|
||||
interface ButtonProps {
|
||||
text: string;
|
||||
className?: string;
|
||||
keyboardShortcut?: string;
|
||||
onClick: () => void;
|
||||
onClick?: () => void;
|
||||
}
|
||||
|
||||
export default function Button({ className, text, onClick, keyboardShortcut }: ButtonProps) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user