bothouse-dsh 0.1.64 → 0.1.66

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Binary file
Binary file
Binary file
Binary file
Binary file
@@ -4,6 +4,9 @@
4
4
  import { readFileSync } from 'node:fs';
5
5
 
6
6
  export const AVATARS = ['orange', 'whale', 'dragon', 'rainbow', 'lanxi', 'grok'];
7
+ // #602: the vendors' own icons, the default set for members without an avatar (user 2026-11-10
8
+ // 「默认是各家原本的图标,内置另一套娘化图标」); served beside the slugs above, see avatars/README.md.
9
+ export const BRAND_AVATARS = ['brand-claude', 'brand-openai', 'brand-deepseek', 'brand-gemini', 'brand-grok', 'brand-minimax'];
7
10
  /** Longest avatar URL a cloud-web bot may announce (common browser URL limit; not from the user). */
8
11
  export const MAX_AVATAR_URL = 2048;
9
12
 
@@ -17,6 +20,6 @@ export function checkAvatar(value, { allowUrl = false } = {}) {
17
20
 
18
21
  /** PNG bytes of a built-in avatar, or undefined for an unknown slug. */
19
22
  export function avatarImage(slug) {
20
- if (!AVATARS.includes(slug)) return undefined;
23
+ if (!AVATARS.includes(slug) && !BRAND_AVATARS.includes(slug)) return undefined;
21
24
  return readFileSync(new URL(`./avatars/${slug}.png`, import.meta.url));
22
25
  }