From 4bf54201407a0d2d2ffbc19c9dc7619d390e1ef0 Mon Sep 17 00:00:00 2001 From: SethBurkart123 Date: Mon, 2 Dec 2024 12:17:28 +1100 Subject: [PATCH] fix(eventManager): not triggering for already created elements' --- src/SEQTA.ts | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/SEQTA.ts b/src/SEQTA.ts index b7b0e22..888776b 100644 --- a/src/SEQTA.ts +++ b/src/SEQTA.ts @@ -688,9 +688,6 @@ function SortMessagePageItems(messagesParentElement: any) { } async function LoadPageElements(): Promise { - await AddBetterSEQTAElements(); - const sublink: string | undefined = window.location.href.split('/')[4]; - eventManager.register('messagesAdded', { elementType: 'div', className: 'messages', @@ -727,7 +724,11 @@ async function LoadPageElements(): Promise { className: 'assessmentsWrapper', }, handleAssessments); } - + + await AddBetterSEQTAElements(); + const sublink: string | undefined = window.location.href.split('/')[4]; + + await handleSublink(sublink); }