mirror of
https://github.com/discourse/discourse.git
synced 2025-03-03 03:45:25 +08:00

This commit refactors the Wizard component code in preparation for moving it to the 'static' directory for Embroider route-splitting. It also includes a number of general improvements and simplifications. Extracted from https://github.com/discourse/discourse/pull/23678 Co-authored-by: Godfrey Chan <godfreykfc@gmail.com>
25 lines
665 B
Handlebars
25 lines
665 B
Handlebars
<label class="wizard-container__label">
|
|
<PluginOutlet
|
|
@name="wizard-checkbox"
|
|
@outletArgs={{hash disabled=this.field.disabled}}
|
|
>
|
|
<Input
|
|
@type="checkbox"
|
|
disabled={{this.field.disabled}}
|
|
class="wizard-container__checkbox"
|
|
@checked={{this.field.value}}
|
|
/>
|
|
<span class="wizard-container__checkbox-slider"></span>
|
|
{{#if this.field.icon}}
|
|
{{d-icon this.field.icon}}
|
|
{{/if}}
|
|
<span class="wizard-container__checkbox-label">
|
|
{{this.field.placeholder}}
|
|
</span>
|
|
</PluginOutlet>
|
|
|
|
<PluginOutlet
|
|
@name="below-wizard-checkbox"
|
|
@outletArgs={{hash disabled=this.field.disabled}}
|
|
/>
|
|
</label> |