class ProfilePreferencesResetDialog extends WindozDialogContent { actions = [ { label: 'Cancel', onclick: this.cancel.bind(this), severity: 'secondary', role: 'cancel' }, { label: 'Reset', onclick: this.reset.bind(this), severity: 'danger', role: 'reset' } ] cancel() { this.commit(false); } reset() { app.User.preferences = {}; app.User.savePreferences(); this.commit(true); } } app.registerClass('ProfilePreferencesResetDialog',ProfilePreferencesResetDialog);