@qrush/types 2.1.72 → 2.1.74

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.
package/README.md CHANGED
@@ -5,7 +5,7 @@ Shared TypeScript types for the QRush ecosystem. This package provides type defi
5
5
  ## Installation
6
6
 
7
7
  ```bash
8
- npm install @qrush/types
8
+ bun add @qrush/types
9
9
  ```
10
10
 
11
11
  ## Usage
@@ -1,6 +1,6 @@
1
1
  import type { Timestamp } from '@firebase/firestore';
2
2
  export type ConnectionStatus = 'pending' | 'accepted' | 'none';
3
- export type ConnectionOrigin = 'connection_request' | 'qr_scan' | 'block';
3
+ export type ConnectionOrigin = 'connection_request' | 'qr_scan' | 'block' | 'lfg_request';
4
4
  export interface IConnectionEventContext {
5
5
  eventUID: string;
6
6
  eventName: string;
package/dist/Social.d.ts CHANGED
@@ -16,6 +16,21 @@ export interface ISocialProfileVisibility {
16
16
  partyDrugsConsumption: FieldVisibility;
17
17
  hardDrugsConsumption: FieldVisibility;
18
18
  }
19
+ export type PrivacyTier = 'public_full' | 'public_restricted' | 'private' | 'custom';
20
+ export interface ICustomPrivacyRules {
21
+ ageRange?: {
22
+ min: number;
23
+ max: number;
24
+ } | null;
25
+ gender?: ('male' | 'female' | 'diverse')[] | null;
26
+ minAccountAgeDays?: number | null;
27
+ onlyVerified?: boolean;
28
+ }
29
+ export interface IPrivacySettings {
30
+ tier: PrivacyTier;
31
+ onlyVerified?: boolean;
32
+ customRules?: ICustomPrivacyRules;
33
+ }
19
34
  export interface ISocialProfile {
20
35
  bio?: string;
21
36
  images?: string[];
@@ -35,26 +50,19 @@ export interface ISocialProfile {
35
50
  partyDrugs?: string;
36
51
  hardDrugs?: string;
37
52
  };
38
- socialProfileStatus?: SocialProfileStatus;
39
- trustScore?: number;
40
- hasTrustBadge?: boolean;
41
- trustSignals?: ITrustSignals;
53
+ privacySettings?: IPrivacySettings;
42
54
  visibility: ISocialProfileVisibility;
43
55
  }
44
- export interface ISocialUserEntry {
56
+ export interface ISocialEntry {
45
57
  name: string;
46
58
  avatarURL: string;
47
- listVisibility: FieldVisibility;
48
59
  createdAt: Timestamp;
49
- /** Present on weeklyGoingUsers entries */
50
60
  userUID?: string;
51
61
  /** Day of week for weekly entries */
52
62
  day?: string;
53
63
  /** Resolved occurrence date (YYYY-MM-DD) for weekly entries */
54
64
  occurrenceDate?: string;
55
- hasSocialProfile?: boolean;
56
- socialProfileStatus?: SocialProfileStatus;
57
- hasTrustBadge?: boolean;
65
+ type: 'going' | 'interested';
58
66
  citySlug?: string;
59
67
  entityId?: string;
60
68
  entityType?: SocialEntityType;
@@ -64,6 +72,25 @@ export interface ISocialUserEntry {
64
72
  entityStartTime?: Timestamp;
65
73
  /** Flat boolean for efficient Firestore indexing (avoids != null on map field) */
66
74
  hasLookingFor?: boolean;
75
+ privacyTier: PrivacyTier;
76
+ isVerified: boolean;
77
+ onlyVerified?: boolean;
78
+ gender?: string;
79
+ birthday?: Timestamp;
80
+ accountCreatedAt?: Timestamp;
81
+ customRules?: ICustomPrivacyRules;
82
+ }
83
+ export interface IFilteredEntry {
84
+ id: string;
85
+ name: string;
86
+ avatarURL: string;
87
+ isVerified: boolean;
88
+ type: 'going' | 'interested';
89
+ visibility: 'clear' | 'anonymous';
90
+ lookingFor?: ILookingFor;
91
+ hasLookingFor?: boolean;
92
+ entryRef?: string;
93
+ isOwnEntry?: boolean;
67
94
  }
68
95
  export type SocialAction = 'going' | 'interested';
69
96
  export type SocialEntityType = 'event' | 'location' | 'weekly';
@@ -90,25 +117,7 @@ export interface IUpdateLookingForRequest {
90
117
  export interface IUpdateLookingForResponse {
91
118
  success: boolean;
92
119
  }
93
- export type SocialProfileStatus = 'none' | 'basic' | 'full';
94
120
  export type EntryVisibility = 'clear' | 'blurred' | 'hidden';
95
- export type ListVisibility = 'all' | 'contacts' | 'hidden';
96
- export declare const TRUST_THRESHOLDS: {
97
- readonly UNBLURRED_ACCESS: 5;
98
- readonly TRUSTED_BADGE: 10;
99
- };
100
- export type TrustSignal = 'phone_verified' | 'profile_image' | 'bio_filled' | 'social_fields_3' | 'social_fields_5' | 'connections_1' | 'connections_3' | 'qrush_plus' | 'promo_redeemed' | 'account_age_7d' | 'account_age_30d' | 'social_actions_3';
101
- export interface ITrustSignals {
102
- phoneVerified: boolean;
103
- hasProfileImage: boolean;
104
- hasBio: boolean;
105
- socialFieldsCount: number;
106
- acceptedContactsCount: number;
107
- isQrushPlusSubscriber: boolean;
108
- promoRedemptionCount: number;
109
- accountAgeDays: number;
110
- socialActionsCount: number;
111
- }
112
121
  export interface ILookingFor {
113
122
  preset?: 'group' | 'dance_partner' | 'going_together';
114
123
  text?: string;
package/dist/Social.js CHANGED
@@ -1,4 +1 @@
1
- export const TRUST_THRESHOLDS = {
2
- UNBLURRED_ACCESS: 5,
3
- TRUSTED_BADGE: 10,
4
- };
1
+ export {};
package/dist/Users.d.ts CHANGED
@@ -1,6 +1,5 @@
1
1
  import type { DocumentReference, FieldValue, Timestamp } from '@firebase/firestore';
2
2
  import { FireQueryDocSnapshotRef } from './CustomDocType.js';
3
- import type { SocialProfileStatus } from './Social.js';
4
3
  export type Maybe<T> = T | null | undefined;
5
4
  export type IFireUser = {
6
5
  phone?: Phone;
@@ -17,7 +16,6 @@ export type IFireUser = {
17
16
  attendedEvents: DocumentReference[];
18
17
  /** @deprecated replace with group collection query on goingUsers */
19
18
  attendingEvent: string | null;
20
- listVisibility?: 'all' | 'contacts' | 'hidden';
21
19
  sharingToken: SharingToken | null;
22
20
  notificationTokens: string[];
23
21
  markedForDeletion: boolean;
@@ -29,10 +27,13 @@ export type IFireUser = {
29
27
  profileImageUrl?: string;
30
28
  totalSavings: number;
31
29
  redemptionIds?: string[];
32
- trustScore?: number;
33
- socialProfileStatus?: SocialProfileStatus;
34
- hasTrustBadge?: boolean;
35
30
  isQrushPlus?: boolean;
31
+ hasSocialProfile?: boolean;
32
+ isVerified?: boolean;
33
+ xp?: number;
34
+ deviceIds?: string[];
35
+ genderChangedAt?: Timestamp;
36
+ birthdayChangedAt?: Timestamp;
36
37
  };
37
38
  export type UserRole = 'user' | 'staff' | 'team' | 'admin';
38
39
  export type UserAvatar = {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@qrush/types",
3
- "version": "2.1.72",
3
+ "version": "2.1.74",
4
4
  "description": "Shared TypeScript types for the QRush ecosystem",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",