feat(project-editor): finish field descriptions + enum dropdowns across all sections
Some checks failed
Architecture Governance / architecture (push) Has been cancelled

Wires up the remaining editor sections (theme, header, footer, homepage,
widgets, features, languages, navigation) with the description text and
dropdown UX started for General/Branding:

- Every enum-backed field is now a <select> with a description per option,
  not free text: theme.mode, the new site-wide layout.type (previously had
  no editor at all - added to the Theme section, and added to that
  section's reset-scope), homepage section layout.strategy, and
  catalog.navigationMode (also previously unedited, added to Features).
- Every other field (colors, header toggles, footer contact/company fields,
  widget props, feature flags, language add, nav link label/url/visible)
  gets a one-line plain-language description under its label via the new
  *Desc i18n keys (en/ru/hy) prepared earlier.
- Genuinely open text (widget layout variant strings, JSON props) stays
  free text, description-only, per the existing widgetLayoutDesc/widgetJsonDesc
  wording - not force-fit into a dropdown.

Verified: tsc --noEmit and ng build both clean.
This commit is contained in:
sdarbinyan
2026-07-15 00:45:41 +04:00
parent ac83c4f57f
commit 170243a480
13 changed files with 202 additions and 59 deletions

View File

@@ -2,14 +2,14 @@
<section class="editor-section-card">
<h2>{{ 'builder.footer' | translate }}</h2>
<div class="editor-grid two">
<label><span>{{ 'builder.companyName' | translate }}</span><input type="text" [ngModel]="bootstrap.company.companyName" (ngModelChange)="updateCompanyName($event)" /></label>
<label><span>{{ 'builder.address' | translate }}</span><input type="text" [ngModel]="bootstrap.company.address.street || ''" (ngModelChange)="updateAddress($event)" /></label>
<label><span>{{ 'builder.phone' | translate }}</span><input type="text" [ngModel]="bootstrap.company.contacts.phone || ''" (ngModelChange)="updatePhone($event)" /></label>
<label><span>{{ 'builder.email' | translate }}</span><input type="text" [ngModel]="bootstrap.company.contacts.email" (ngModelChange)="updateEmail($event)" /></label>
<label class="full"><span>{{ 'builder.copyright' | translate }}</span><input type="text" [ngModel]="copyrightValue()" (ngModelChange)="updateCopyright($event)" /></label>
<label class="full"><span>{{ 'builder.paymentIcons' | translate }}</span><textarea rows="4" [ngModel]="paymentIconsValue()" (ngModelChange)="updatePaymentIcons($event)"></textarea></label>
<label class="full"><span>{{ 'builder.socialLinks' | translate }}</span><textarea rows="4" [ngModel]="socialLinksValue()" (ngModelChange)="updateSocialLinks($event)"></textarea></label>
<label class="full"><span>{{ 'builder.staticPages' | translate }}</span><input type="text" [ngModel]="staticPagesValue()" (ngModelChange)="updateStaticPages($event)" /></label>
<label><span>{{ 'builder.companyName' | translate }}</span><small class="field-desc">{{ 'builder.companyNameDesc' | translate }}</small><input type="text" [ngModel]="bootstrap.company.companyName" (ngModelChange)="updateCompanyName($event)" /></label>
<label><span>{{ 'builder.address' | translate }}</span><small class="field-desc">{{ 'builder.addressDesc' | translate }}</small><input type="text" [ngModel]="bootstrap.company.address.street || ''" (ngModelChange)="updateAddress($event)" /></label>
<label><span>{{ 'builder.phone' | translate }}</span><small class="field-desc">{{ 'builder.phoneDesc' | translate }}</small><input type="text" [ngModel]="bootstrap.company.contacts.phone || ''" (ngModelChange)="updatePhone($event)" /></label>
<label><span>{{ 'builder.email' | translate }}</span><small class="field-desc">{{ 'builder.emailDesc' | translate }}</small><input type="text" [ngModel]="bootstrap.company.contacts.email" (ngModelChange)="updateEmail($event)" /></label>
<label class="full"><span>{{ 'builder.copyright' | translate }}</span><small class="field-desc">{{ 'builder.copyrightDesc' | translate }}</small><input type="text" [ngModel]="copyrightValue()" (ngModelChange)="updateCopyright($event)" /></label>
<label class="full"><span>{{ 'builder.paymentIcons' | translate }}</span><small class="field-desc">{{ 'builder.paymentIconsDesc' | translate }}</small><textarea rows="4" [ngModel]="paymentIconsValue()" (ngModelChange)="updatePaymentIcons($event)"></textarea></label>
<label class="full"><span>{{ 'builder.socialLinks' | translate }}</span><small class="field-desc">{{ 'builder.socialLinksDesc' | translate }}</small><textarea rows="4" [ngModel]="socialLinksValue()" (ngModelChange)="updateSocialLinks($event)"></textarea></label>
<label class="full"><span>{{ 'builder.staticPages' | translate }}</span><small class="field-desc">{{ 'builder.staticPagesFieldDesc' | translate }}</small><input type="text" [ngModel]="staticPagesValue()" (ngModelChange)="updateStaticPages($event)" /></label>
</div>
</section>
}