Open History to see the last commit
1/* eslint-disable @typescript-eslint/no-unnecessary-condition */
2import * as React from 'react'
3import type { Invoice } from '../utils/mockTodos'
4β
5export function InvoiceFields({
6 invoice,
7 disabled,
8}: {
9 invoice: Invoice
10 disabled?: boolean
11}) {
12 return (
13 <div className="space-y-2">
14 <h2 className="font-bold text-lg">
15 <input
16 name="title"
17 defaultValue={invoice?.title}
18 placeholder="Invoice Title"
19 className="border border-opacity-50 rounded-sm p-2 w-full"
20 disabled={disabled}
21 />
22 </h2>
23 <div>
24 <textarea
25 name="body"
26 defaultValue={invoice?.body}
27 rows={6}
28 placeholder="Invoice Body..."
29 className="border border-opacity-50 p-2 rounded-sm w-full"
30 disabled={disabled}
31 />
32 </div>
33 </div>
34 )
35}