Merge Boundary UI OSS branch 'main' at commit 54d5d349

This commit is contained in:
github-team-secure-boundary committed 2023-01-20 00:53:33 +00:00
commit 4a63e9ed40
4 files changed
+26 -8

No files matched your search

+8 -2
View File
@@ -32,12 +32,18 @@
<Rose::Form as |form|>
<form.radioGroup
@name='theme'
@selectedValue={{this.session.data.theme}}
@selectedValue={{or
this.session.data.theme
'system-default-theme'
}}
@changed={{route-action 'toggleTheme'}}
as |radioGroup|
>
<dropdown.item>
<radioGroup.radio @label={{t 'themes.system'}} />
<radioGroup.radio
@label={{t 'themes.system'}}
@value='system-default-theme'
/>
</dropdown.item>
<dropdown.item>
<radioGroup.radio
@@ -350,8 +350,11 @@ module('Acceptance | authentication', function (hooks) {
assert.notOk(getRootElement().classList.contains('rose-theme-light'));
assert.ok(getRootElement().classList.contains('rose-theme-dark'));
// toggle system default
await click('[name="theme"][value=""]');
assert.notOk(currentSession().get('data.theme'));
await click('[name="theme"][value="system-default-theme"]');
assert.strictEqual(
currentSession().get('data.theme'),
'system-default-theme'
);
assert.notOk(getRootElement().classList.contains('rose-theme-light'));
assert.notOk(getRootElement().classList.contains('rose-theme-dark'));
});
+8 -2
View File
@@ -55,12 +55,18 @@
<Rose::Form as |form|>
<form.radioGroup
@name='theme'
@selectedValue={{this.session.data.theme}}
@selectedValue={{or
this.session.data.theme
'system-default-theme'
}}
@changed={{route-action 'toggleTheme'}}
as |radioGroup|
>
<dropdown.item>
<radioGroup.radio @label={{t 'themes.system'}} />
<radioGroup.radio
@label={{t 'themes.system'}}
@value='system-default-theme'
/>
</dropdown.item>
<dropdown.item>
<radioGroup.radio
@@ -242,8 +242,11 @@ module('Acceptance | authentication', function (hooks) {
assert.notOk(getRootElement().classList.contains('rose-theme-light'));
assert.ok(getRootElement().classList.contains('rose-theme-dark'));
// toggle system default
await click('[name="theme"][value=""]');
assert.notOk(currentSession().get('data.theme'));
await click('[name="theme"][value="system-default-theme"]');
assert.strictEqual(
currentSession().get('data.theme'),
'system-default-theme'
);
assert.notOk(getRootElement().classList.contains('rose-theme-light'));
assert.notOk(getRootElement().classList.contains('rose-theme-dark'));
});