Spiegel von
https://github.com/paviliondev/discourse-custom-wizard.git
synchronisiert 2024-11-10 04:12:53 +01:00
improved admin side settings UI
Dieser Commit ist enthalten in:
Ursprung
800795047a
Commit
176cd7489a
4 geänderte Dateien mit 36 neuen und 21 gelöschten Zeilen
|
@ -219,10 +219,9 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
|
||||||
{{/if}}
|
|
||||||
|
|
||||||
{{#if validations}}
|
{{#if validations}}
|
||||||
{{wizard-realtime-validation-settings field=field validations=validations}}
|
{{wizard-realtime-validation-settings field=field validations=validations}}
|
||||||
{{/if}}
|
{{/if}}
|
||||||
|
</div>
|
||||||
|
{{/if}}
|
||||||
{{/if}}
|
{{/if}}
|
||||||
|
|
|
@ -6,15 +6,17 @@
|
||||||
{{input type="checkbox" checked=props.status }}
|
{{input type="checkbox" checked=props.status }}
|
||||||
{{i18n (concat 'admin.wizard.field.validations.' name) }}
|
{{i18n (concat 'admin.wizard.field.validations.' name) }}
|
||||||
</span>
|
</span>
|
||||||
<div class="setting full">
|
<div class="validation-container">
|
||||||
|
<div class="validation-section">
|
||||||
<span class="setting-label">{{i18n 'admin.wizard.field.validations.categories'}}</span>
|
<span class="setting-label">{{i18n 'admin.wizard.field.validations.categories'}}</span>
|
||||||
<div class="setting-value">
|
<div class="setting-value">
|
||||||
{{category-selector
|
{{category-selector
|
||||||
categories=(get this (concat 'validationBuffer.' name '.categories'))
|
categories=(get this (concat 'validationBuffer.' name '.categories'))
|
||||||
onChange=(action 'updateValidationCategories' name props) }}
|
onChange=(action 'updateValidationCategories' name props)
|
||||||
|
class="wizard" }}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="setting full">
|
<div class="validation-section">
|
||||||
<span class="setting-label">{{i18n 'admin.wizard.field.validations.date_after'}}</span>
|
<span class="setting-label">{{i18n 'admin.wizard.field.validations.date_after'}}</span>
|
||||||
<div class="setting-value">
|
<div class="setting-value">
|
||||||
{{date-picker-past
|
{{date-picker-past
|
||||||
|
@ -23,10 +25,12 @@
|
||||||
onSelect=(action (mut props.date_after))}}
|
onSelect=(action (mut props.date_after))}}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div class="validation-section">
|
||||||
|
<span class="setting-label">{{i18n 'admin.wizard.field.validations.position'}}</span>
|
||||||
|
<div class="setting-value">
|
||||||
{{radio-button name=(concat name field.id) value="above" selection=props.position}} {{i18n 'admin.wizard.field.validations.above'}}
|
{{radio-button name=(concat name field.id) value="above" selection=props.position}} {{i18n 'admin.wizard.field.validations.above'}}
|
||||||
</div>
|
|
||||||
<div>
|
|
||||||
{{radio-button name=(concat name field.id) value="below" selection=props.position}} {{i18n 'admin.wizard.field.validations.below'}}
|
{{radio-button name=(concat name field.id) value="below" selection=props.position}} {{i18n 'admin.wizard.field.validations.below'}}
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
{{/each-in}}
|
{{/each-in}}
|
||||||
|
|
|
@ -643,3 +643,14 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.validation-container {
|
||||||
|
display: flex;
|
||||||
|
.validation-section {
|
||||||
|
width: 250px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.wizard.category-selector {
|
||||||
|
width: 200px !important;
|
||||||
|
}
|
||||||
|
|
|
@ -179,6 +179,7 @@ en:
|
||||||
validations:
|
validations:
|
||||||
header: "Realtime Validation Settings"
|
header: "Realtime Validation Settings"
|
||||||
similar_topics: "Similar Topics"
|
similar_topics: "Similar Topics"
|
||||||
|
position: "Position"
|
||||||
above: "Above"
|
above: "Above"
|
||||||
below: "Below"
|
below: "Below"
|
||||||
categories: "Categories"
|
categories: "Categories"
|
||||||
|
|
Laden …
In neuem Issue referenzieren