feat(project-editor): adopt Toggle/SectionCard in homepage and widgets sections
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
@@ -1,14 +1,13 @@
|
||||
@if (homePage()) {
|
||||
<section class="editor-section-card">
|
||||
<h2>{{ 'builder.homepage' | translate }}</h2>
|
||||
<app-section-card [title]="'builder.homepage' | translate">
|
||||
<div cdkDropList class="sortable-list" (cdkDropListDropped)="drop($event)">
|
||||
@for (section of sections(); track section.id) {
|
||||
<div class="sortable-item" cdkDrag>
|
||||
<div class="editor-grid four compact">
|
||||
<strong>{{ section.id }}</strong>
|
||||
<label>
|
||||
<label class="toggle-row">
|
||||
<app-toggle [ngModel]="section.visible !== false" (ngModelChange)="updateSection(section.id, 'visible', $event)" [ariaLabel]="'builder.visible' | translate" />
|
||||
<span>{{ 'builder.visible' | translate }}</span>
|
||||
<input type="checkbox" [checked]="section.visible !== false" (change)="updateSection(section.id, 'visible', $any($event.target).checked)" />
|
||||
<small class="field-desc">{{ 'builder.sectionVisibleDesc' | translate }}</small>
|
||||
</label>
|
||||
<label>
|
||||
@@ -30,5 +29,5 @@
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
</section>
|
||||
</app-section-card>
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user