Add a reusable website link generator and polish static image cards.

Editors can pick product, store, blog, portfolio, or video category links, and image cards expose compact info/link actions without dumping URLs in the footer.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
Alireza Hassani
2026-08-17 00:30:01 +03:30
co-authored by Cursor
parent b9024ad77a
commit e0e68de30f
15 changed files with 1164 additions and 77 deletions
@@ -10,6 +10,7 @@ interface SearchableSelectProps {
value: string
onChange: (value: string) => void
placeholder?: string
allowEmpty?: boolean
}
function categoryLabel(cat: FlatCategory, isFa: boolean) {
@@ -28,6 +29,7 @@ export function SearchableSelect({
value,
onChange,
placeholder,
allowEmpty = true,
}: SearchableSelectProps) {
const t = useT()
const { locale } = useLocale()
@@ -104,15 +106,17 @@ export function SearchableSelect({
{open && (
<ul className={styles.dropdown} role="listbox">
<li>
<button
type="button"
className={`${styles.option} ${value === '' ? styles.optionSelected : ''}`}
onClick={() => selectOption('')}
>
{t('categories.select.none')}
</button>
</li>
{allowEmpty ? (
<li>
<button
type="button"
className={`${styles.option} ${value === '' ? styles.optionSelected : ''}`}
onClick={() => selectOption('')}
>
{t('categories.select.none')}
</button>
</li>
) : null}
{filtered.length === 0 ? (
<li className={styles.noResults}>{t('categories.select.empty')}</li>
) : (