feat: new Tehrani brand logo, custom button audience, trim dashboard

- Replace the crown logo with logo.svg / logo_bk.svg across both frontends;
  regenerate favicons and PWA icons via scripts/generate-brand-icons.cjs
- Custom button: admin chooses whether it shows before login or only after
- Dashboard: drop the survey-majority banner, hide the custom-order row

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
mahmood
2026-11-14 16:53:25 +03:30
co-authored by Cursor
parent 0f6ad79ae7
commit de13445109
37 changed files with 428 additions and 105 deletions
@@ -24,18 +24,23 @@ export class PublicSliderController {
return Array.isArray(value) ? value : [];
}
/** Custom button on the profile dashboard (ثابت‌ها → دکمه سفارشی). */
/**
* Custom button on the profile dashboard (ثابت‌ها → دکمه سفارشی).
* `audience`: 'all' = signed out too, 'loggedIn' = only after login. Rows
* saved before the field existed were shown to everyone, so they read 'all'.
*/
@Get('custom-button')
async getCustomButton() {
const value = await this.misc.getConst('custom_button');
if (!value || typeof value !== 'object' || Array.isArray(value)) {
return { enabled: false, title: '', link: '' };
return { enabled: false, title: '', link: '', audience: 'all' };
}
const row = value as Record<string, unknown>;
return {
enabled: Boolean(row.enabled),
title: String(row.title ?? ''),
link: String(row.link ?? ''),
audience: row.audience === 'loggedIn' ? 'loggedIn' : 'all',
};
}
}