mirror of
https://github.com/storytold/artcraft.git
synced 2026-11-05 01:38:44 +00:00
rich html notes
This commit is contained in:
1 parent
c9311be7a5
commit
9a2fe511a2
2 files changed
+9
-2
No files matched your search
@@ -38,6 +38,7 @@ export interface BetaKey {
|
||||
product: string;
|
||||
token: string;
|
||||
maybe_note?: string;
|
||||
maybe_note_html?: string;
|
||||
}
|
||||
|
||||
export interface ListBetaKeysRequest {}
|
||||
|
||||
@@ -200,7 +200,8 @@ export default function BetaKeysListPage() {
|
||||
header: "Note",
|
||||
cell: info => {
|
||||
const note = info.getValue();
|
||||
const { token } = info.row.original;
|
||||
const { token, maybe_note_html } = info.row.original;
|
||||
|
||||
// eslint-disable-next-line react-hooks/rules-of-hooks
|
||||
const [localNote, setLocalNote] = useState(note);
|
||||
|
||||
@@ -229,7 +230,12 @@ export default function BetaKeysListPage() {
|
||||
</div>
|
||||
) : (
|
||||
<div className="d-flex gap-1 align-items-start note-cell">
|
||||
<span className="me-3">{note || "-"}</span>
|
||||
<span
|
||||
className="me-3"
|
||||
dangerouslySetInnerHTML={{
|
||||
__html: maybe_note_html || "-",
|
||||
}}
|
||||
></span>
|
||||
<Button
|
||||
label="Edit"
|
||||
onClick={() => handleEditStart(token, note || "")}
|
||||
|
||||
Reference in new issue
Block a user