From 002de14a99468937f783ff521994641447c971b5 Mon Sep 17 00:00:00 2001 From: Adrian Klingen Date: Tue, 7 May 2024 17:54:29 +0200 Subject: [PATCH 1/2] Add importer cata warning --- ui/core/components/importers.ts | 126 +++++++++++++++++++------------- 1 file changed, 76 insertions(+), 50 deletions(-) diff --git a/ui/core/components/importers.ts b/ui/core/components/importers.ts index 94dd646670..23d80f3645 100644 --- a/ui/core/components/importers.ts +++ b/ui/core/components/importers.ts @@ -1,27 +1,19 @@ +import { JsonObject } from '@protobuf-ts/runtime'; + import { IndividualSimUI } from '../individual_sim_ui'; -import { SimUI } from '../sim_ui'; -import { TypedEvent } from '../typed_event'; -import { - Class, - EquipmentSpec, - ItemSlot, - Glyphs, - ItemSpec, - Profession, - Race, - Spec, -} from '../proto/common'; +import { Class, EquipmentSpec, Glyphs, ItemSlot, ItemSpec, Profession, Race, Spec } from '../proto/common'; import { IndividualSimSettings } from '../proto/ui'; import { Database } from '../proto_utils/database'; -import { classNames, nameToClass, nameToRace, nameToProfession } from '../proto_utils/names'; +import { classNames, nameToClass, nameToProfession, nameToRace } from '../proto_utils/names'; +import { SimSettingCategories } from '../sim'; +import { SimUI } from '../sim_ui'; import { classGlyphsConfig, talentSpellIdsToTalentString } from '../talents/factory'; import { GlyphConfig } from '../talents/glyphs_picker'; -import { BaseModal } from './base_modal'; +import { TypedEvent } from '../typed_event'; import { buf2hex, getEnumValues } from '../utils'; -import { JsonObject } from '@protobuf-ts/runtime'; -import { SimSettingCategories } from '../sim'; +import { BaseModal } from './base_modal'; -declare var pako: any; +declare let pako: any; export abstract class Importer extends BaseModal { protected readonly textElem: HTMLTextAreaElement; @@ -39,13 +31,16 @@ export abstract class Importer extends BaseModal { `; this.footer!.innerHTML = ` - ${this.includeFile ? ` + ${ + this.includeFile + ? ` - ` : '' + ` + : '' }