New IDs, finish Submit Translation page and begin BIG TS.

This commit is contained in:
2026-01-13 19:15:47 +01:00
parent baaef17a1b
commit 86b70562bc
16 changed files with 323 additions and 65 deletions

20
ts/submissions/index.ts Normal file
View File

@@ -0,0 +1,20 @@
import {type Can_Upload_Detail, during_upload, I} from "./globals";
import {Upload} from "./class-upload";
import {DropContainer} from "./class-drop-container";
document.addEventListener('DOMContentLoaded', () => {
if( !document.getElementById( 'fileInput' ) ) // Check if exists.
// @ts-ignore
I.drop_container = new DropContainer( document.getElementById( 'file-container' ) as HTMLElement, document.getElementById( 'file-container-text' ) as HTMLElement );
// @ts-ignore
document.addEventListener( 'can_upload', (e: CustomEvent<Can_Upload_Detail> ) => {
const { file } = e.detail;
if( !during_upload ) // @ts-ignore
I.upload = new Upload( file );
});
})