ui: change to ts & tsx

This commit is contained in:
undefined committed 2021-10-11 23:33:54 +08:00
1 parent 36cce6d1bd
commit d10fec361c
29 files changed
+165 -221

No files matched your search

@@ -235,16 +235,6 @@ const page = new NamedPage('problem_files', () => {
await pjax.request({ push: false });
}
$(document).on('click', '[name="problem-sidebar__rejudge"]', (ev) => {
ev.preventDefault();
new ConfirmDialog({
$body: tpl.typoMsg(i18n('Confirm rejudge this problem?')),
}).open().then((action) => {
if (action !== 'yes') return;
$(ev.currentTarget).closest('form').trigger('submit');
});
});
if ($('[name="upload_testdata"]').length) {
$(document).on('click', '.problem-files-testdata .col--name', (ev) => handleEdit('testdata', ev));
$(document).on('click', '.problem-files-additional_file .col--name', (ev) => handleEdit('additional_file', ev));