Replace typescript compiler with native tsgo compiler

This commit is contained in:
Jamie
2026-03-18 11:26:18 -07:00
committed by GitHub
parent 5e6af4708b
commit c90ca2b4e0
207 changed files with 1819 additions and 1270 deletions

View File

@@ -71,23 +71,26 @@ export default {
// eslint-disable-next-line react/function-component-definition
const Template: StoryFn<PropsType> = args => {
const [attachment, setAttachment] = useState<string | undefined>();
const saveAttachment = useCallback(({ data }: { data?: Uint8Array }) => {
if (!data) {
setAttachment(undefined);
return;
}
const blob = new Blob([data], {
type: 'image/png',
});
setAttachment(oldURL => {
if (oldURL) {
URL.revokeObjectURL(oldURL);
const saveAttachment = useCallback(
({ data }: { data?: Uint8Array<ArrayBuffer> }) => {
if (!data) {
setAttachment(undefined);
return;
}
return URL.createObjectURL(blob);
});
}, []);
const blob = new Blob([data], {
type: 'image/png',
});
setAttachment(oldURL => {
if (oldURL) {
URL.revokeObjectURL(oldURL);
}
return URL.createObjectURL(blob);
});
},
[]
);
return (
<>