@simonarcher/fika-types 1.0.63 → 1.0.64

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.
Files changed (2) hide show
  1. package/dist/shop.d.ts +52 -0
  2. package/package.json +1 -1
package/dist/shop.d.ts CHANGED
@@ -5,6 +5,7 @@ export type MenuItemDrinkType = "Filter" | "ColdBrew" | "Specialty" | "Iced" | "
5
5
  export type MenuItemFoodType = "Breakfast" | "Lunch" | "Pastry" | "Snack" | "Sweets" | "Sandwiches" | "Other";
6
6
  export type MenuItemType = MenuItemDrinkType | MenuItemFoodType;
7
7
  export type MenuItemCategory = "drink" | "food";
8
+ export type SpecialtyTier = 'specialty' | 'quality' | 'everyday';
8
9
  export interface MenuItem {
9
10
  id: string;
10
11
  productId?: string;
@@ -190,6 +191,18 @@ export type ShopData = {
190
191
  communityStats?: ShopCommunityStats;
191
192
  spotifyPlaylistId?: string;
192
193
  paymentOptions?: ShopPaymentOptions;
194
+ /**
195
+ * --------- NEW FOR SPECIALTY SCORING (all optional/merge-friendly) ----------
196
+ */
197
+ roasterRefs?: RoasterRef[];
198
+ houseRoasted?: boolean;
199
+ brewMethods?: string[];
200
+ menuKeywords?: string[];
201
+ events?: string[];
202
+ sustainability?: Array<'direct trade' | 'traceable' | 'organic' | 'b-corp' | string>;
203
+ baristaAchievements?: BaristaAchievement[];
204
+ signals?: SpecialtySignals;
205
+ specialty?: SpecialtyMeta;
193
206
  };
194
207
  export interface ShopCommunityStats {
195
208
  totalCheckIns: number;
@@ -448,4 +461,43 @@ export interface PublicShopData extends Omit<ShopData, 'analytics' | 'googleRati
448
461
  spotifyPlaylistId?: string;
449
462
  address?: string;
450
463
  }
464
+ export type SpecialtyOverride = {
465
+ score: number;
466
+ reason?: string;
467
+ byUserId?: string;
468
+ at?: number;
469
+ };
470
+ export type SpecialtyMeta = {
471
+ score?: number;
472
+ tier?: SpecialtyTier;
473
+ verified?: boolean;
474
+ override?: SpecialtyOverride | null;
475
+ explanations?: string[];
476
+ updatedAt?: number;
477
+ };
478
+ export type SpecialtySemanticSignals = {
479
+ keywordHits?: number;
480
+ keywordDensity?: number;
481
+ sources?: Array<'website' | 'ig' | 'menu' | 'other'>;
482
+ };
483
+ export type SpecialtyCrowdSignals = {
484
+ votes?: number;
485
+ specialtyVotes?: number;
486
+ avgCraftRating?: number;
487
+ };
488
+ export type SpecialtySignals = {
489
+ semantic?: SpecialtySemanticSignals;
490
+ crowd?: SpecialtyCrowdSignals;
491
+ };
492
+ export type RoasterRef = {
493
+ id: string;
494
+ displayName?: string;
495
+ tierHint?: 1 | 2 | 3;
496
+ };
497
+ export type CommunitySignal = 'cupping' | 'training' | 'education' | 'origin talk' | 'sustainability' | 'direct trade' | 'traceable';
498
+ export type BaristaAchievement = {
499
+ title: string;
500
+ year?: number;
501
+ notes?: string;
502
+ };
451
503
  export {};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@simonarcher/fika-types",
3
- "version": "1.0.63",
3
+ "version": "1.0.64",
4
4
  "description": "Shared TypeScript types for Fika projects",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",