refactor: canonicalize TypeScript and Tailwind syntax
This commit is contained in:
@@ -7,7 +7,7 @@ import { todayString } from "@/utils/date";
|
||||
* Business fact: `role === "assistant"` means the message is from AI.
|
||||
*/
|
||||
export function localMessagesToUi(
|
||||
records: ReadonlyArray<{
|
||||
records: readonly {
|
||||
id?: string;
|
||||
type?: string;
|
||||
content: string;
|
||||
@@ -16,7 +16,7 @@ export function localMessagesToUi(
|
||||
audioUrl?: string | null;
|
||||
image?: { type: string | null; url: string | null };
|
||||
lockDetail?: ChatLockDetailData;
|
||||
}>,
|
||||
}[],
|
||||
): UiMessage[] {
|
||||
return records.map((m) => ({
|
||||
...(m.id ? { id: m.id } : {}),
|
||||
|
||||
@@ -97,7 +97,7 @@ function createTestPaymentMachine(
|
||||
createOrderSpy: CreateOrderSpy;
|
||||
createOrderError: Error;
|
||||
orderStatus: "pending" | "paid" | "failed";
|
||||
orderStatuses: Array<"pending" | "paid" | "failed">;
|
||||
orderStatuses: ("pending" | "paid" | "failed")[];
|
||||
}> = {},
|
||||
) {
|
||||
const createOrderSpy = overrides.createOrderSpy ?? vi.fn<CreateOrderSpy>();
|
||||
|
||||
Reference in New Issue
Block a user