@hobenakicoffee/libraries 1.12.0 → 1.14.0

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hobenakicoffee/libraries",
3
- "version": "1.12.0",
3
+ "version": "1.14.0",
4
4
  "type": "module",
5
5
  "types": "src/index.ts",
6
6
  "exports": {
@@ -137,6 +137,69 @@ export type Database = {
137
137
  },
138
138
  ];
139
139
  };
140
+ conversation_participants: {
141
+ Row: {
142
+ conversation_id: string;
143
+ joined_at: string;
144
+ last_read_at: string | null;
145
+ profile_id: string;
146
+ };
147
+ Insert: {
148
+ conversation_id: string;
149
+ joined_at?: string;
150
+ last_read_at?: string | null;
151
+ profile_id: string;
152
+ };
153
+ Update: {
154
+ conversation_id?: string;
155
+ joined_at?: string;
156
+ last_read_at?: string | null;
157
+ profile_id?: string;
158
+ };
159
+ Relationships: [
160
+ {
161
+ foreignKeyName: "conversation_participants_conversation_id_fkey";
162
+ columns: ["conversation_id"];
163
+ isOneToOne: false;
164
+ referencedRelation: "conversations";
165
+ referencedColumns: ["id"];
166
+ },
167
+ {
168
+ foreignKeyName: "conversation_participants_profile_id_fkey";
169
+ columns: ["profile_id"];
170
+ isOneToOne: false;
171
+ referencedRelation: "profiles";
172
+ referencedColumns: ["id"];
173
+ },
174
+ ];
175
+ };
176
+ conversations: {
177
+ Row: {
178
+ created_at: string;
179
+ id: string;
180
+ last_message_at: string | null;
181
+ last_message_preview: string | null;
182
+ name: string | null;
183
+ type: string;
184
+ };
185
+ Insert: {
186
+ created_at?: string;
187
+ id?: string;
188
+ last_message_at?: string | null;
189
+ last_message_preview?: string | null;
190
+ name?: string | null;
191
+ type?: string;
192
+ };
193
+ Update: {
194
+ created_at?: string;
195
+ id?: string;
196
+ last_message_at?: string | null;
197
+ last_message_preview?: string | null;
198
+ name?: string | null;
199
+ type?: string;
200
+ };
201
+ Relationships: [];
202
+ };
140
203
  follows: {
141
204
  Row: {
142
205
  created_at: string | null;
@@ -268,6 +331,45 @@ export type Database = {
268
331
  };
269
332
  Relationships: [];
270
333
  };
334
+ messages: {
335
+ Row: {
336
+ content: string;
337
+ conversation_id: string;
338
+ created_at: string;
339
+ id: number;
340
+ sender_id: string;
341
+ };
342
+ Insert: {
343
+ content: string;
344
+ conversation_id: string;
345
+ created_at?: string;
346
+ id?: number;
347
+ sender_id: string;
348
+ };
349
+ Update: {
350
+ content?: string;
351
+ conversation_id?: string;
352
+ created_at?: string;
353
+ id?: number;
354
+ sender_id?: string;
355
+ };
356
+ Relationships: [
357
+ {
358
+ foreignKeyName: "messages_conversation_id_fkey";
359
+ columns: ["conversation_id"];
360
+ isOneToOne: false;
361
+ referencedRelation: "conversations";
362
+ referencedColumns: ["id"];
363
+ },
364
+ {
365
+ foreignKeyName: "messages_sender_id_fkey";
366
+ columns: ["sender_id"];
367
+ isOneToOne: false;
368
+ referencedRelation: "profiles";
369
+ referencedColumns: ["id"];
370
+ },
371
+ ];
372
+ };
271
373
  payout_methods: {
272
374
  Row: {
273
375
  created_at: string;
@@ -388,8 +490,10 @@ export type Database = {
388
490
  first_supported_at: string | null;
389
491
  id: string;
390
492
  identity_hash: string;
493
+ is_monthly: boolean;
391
494
  last_supported_at: string | null;
392
495
  last_supported_service: string | null;
496
+ metadata: Json;
393
497
  name: string;
394
498
  social_platform:
395
499
  | Database["public"]["Enums"]["supporter_platform_enum"]
@@ -405,8 +509,10 @@ export type Database = {
405
509
  first_supported_at?: string | null;
406
510
  id?: string;
407
511
  identity_hash: string;
512
+ is_monthly?: boolean;
408
513
  last_supported_at?: string | null;
409
514
  last_supported_service?: string | null;
515
+ metadata?: Json;
410
516
  name: string;
411
517
  social_platform?:
412
518
  | Database["public"]["Enums"]["supporter_platform_enum"]
@@ -422,8 +528,10 @@ export type Database = {
422
528
  first_supported_at?: string | null;
423
529
  id?: string;
424
530
  identity_hash?: string;
531
+ is_monthly?: boolean;
425
532
  last_supported_at?: string | null;
426
533
  last_supported_service?: string | null;
534
+ metadata?: Json;
427
535
  name?: string;
428
536
  social_platform?:
429
537
  | Database["public"]["Enums"]["supporter_platform_enum"]
@@ -690,6 +798,18 @@ export type Database = {
690
798
  follow_user: { Args: { target_user_id: string }; Returns: undefined };
691
799
  get_followers: { Args: { target_user_id: string }; Returns: string[] };
692
800
  get_following: { Args: { target_user_id: string }; Returns: string[] };
801
+ get_popular_content: {
802
+ Args: { p_creator_id: string; p_from_date: string; p_to_date: string };
803
+ Returns: {
804
+ service: string;
805
+ support_count: number;
806
+ total_amount: number;
807
+ }[];
808
+ };
809
+ get_total_supports_count: {
810
+ Args: { p_creator_id: string; p_from_date: string; p_to_date: string };
811
+ Returns: number;
812
+ };
693
813
  handle_successful_payment: {
694
814
  Args: {
695
815
  p_amount: number;
@@ -721,6 +841,7 @@ export type Database = {
721
841
  p_amount?: number;
722
842
  p_creator_id: string;
723
843
  p_identity_hash: string;
844
+ p_metadata?: Json;
724
845
  p_name: string;
725
846
  p_service_type?: string;
726
847
  p_social_platform?: Database["public"]["Enums"]["supporter_platform_enum"];