chore(react): clean up

This commit is contained in:
Elian Doran 2025-08-03 19:50:39 +03:00
parent f8b563704f
commit 04913394c6
No known key found for this signature in database
2 changed files with 4 additions and 4 deletions

View File

@ -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> &nbsp;

View File

@ -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) {