Add stable keys for special groups and SSL sync agent hooks.

English keys on store/website specials stay unique per business; domain-admin can trigger dashboard SSL sync.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
Alireza Hassani
2026-08-03 00:06:44 +03:30
co-authored by Cursor
parent 43e3912662
commit f233665d13
15 changed files with 263 additions and 6 deletions
+9
View File
@@ -0,0 +1,9 @@
/** English stable key for website special group lookups (e.g. top-selling). */
export const SPECIAL_GROUP_KEY_PATTERN = /^[a-zA-Z][a-zA-Z0-9_-]*$/;
export const SPECIAL_GROUP_KEY_MESSAGE =
'key must be English letters, numbers, hyphens, or underscores';
export function normalizeSpecialGroupKey(raw: string): string {
return raw.trim();
}