mirror of
https://github.com/bitbaum/diplodoctor.git
synced 2026-12-04 04:27:21 +01:00
Record notes, appointment/medicine notes and the new-report text now use a shared TextBox wrapping @bitbaum/chatkit's DictationField, with the voice going to /api/transcribe like Ask. Claude-Session: https://claude.ai/code/session_019MDtmv368Y2D3TuQq8dZ6A Co-authored-by: Claude <noreply@anthropic.com>
16 lines
645 B
TypeScript
16 lines
645 B
TypeScript
"use client";
|
|
|
|
import { DictationField, type DictationFieldProps } from "@bitbaum/chatkit/react";
|
|
import "@bitbaum/chatkit/styles.css";
|
|
import { API } from "@/lib/routes";
|
|
|
|
/**
|
|
* Every box a person types words into, outside the Ask chat: chatkit's
|
|
* DictationField, so it has the same microphone as the chat (fleet rule "the
|
|
* experience belongs to the package"). The take goes to /api/transcribe, which
|
|
* keeps nothing; the words land in the box to read and edit like typed ones.
|
|
*/
|
|
export function TextBox(props: DictationFieldProps) {
|
|
return <DictationField voice={{ transcribeUrl: API.transcribe, prefer: "server" }} {...props} />;
|
|
}
|