Skip to content

Commit

Permalink
fix(www): use querySelector now that element is dynamically created (
Browse files Browse the repository at this point in the history
  • Loading branch information
sbruens authored Oct 4, 2023
1 parent 64cf473 commit 813fbba
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/www/app/app.ts
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ export class App {
private quitApplication: () => void,
document = window.document
) {
this.feedbackViewEl = rootEl.$.feedbackView;
this.feedbackViewEl = rootEl.shadowRoot.querySelector('#feedbackView');
this.localize = this.rootEl.localize.bind(this.rootEl);

this.syncServersToUI();
Expand Down Expand Up @@ -497,15 +497,15 @@ export class App {
return;
}
const {feedback, category, email} = formData;
this.rootEl.$.feedbackView.submitting = true;
this.feedbackViewEl.submitting = true;
try {
await this.errorReporter.report(feedback, category, email);
this.rootEl.$.feedbackView.submitting = false;
this.rootEl.$.feedbackView.resetForm();
this.feedbackViewEl.submitting = false;
this.feedbackViewEl.resetForm();
this.changeToDefaultPage();
this.rootEl.showToast(this.rootEl.localize('feedback-thanks'));
} catch (e) {
this.rootEl.$.feedbackView.submitting = false;
this.feedbackViewEl.submitting = false;
this.showLocalizedError(new errors.FeedbackSubmissionError());
}
}
Expand Down

0 comments on commit 813fbba

Please sign in to comment.