feeef 0.12.2 → 0.12.3
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.
|
@@ -35,6 +35,11 @@ export interface StoreTemplateEntity {
|
|
|
35
35
|
updateAvailable?: boolean;
|
|
36
36
|
installedReleaseId?: string | null;
|
|
37
37
|
latestRelease?: StoreTemplateReleaseEntity | null;
|
|
38
|
+
ratingAvg?: number;
|
|
39
|
+
ratingCount?: number;
|
|
40
|
+
featured?: boolean;
|
|
41
|
+
salesClosed?: boolean;
|
|
42
|
+
moderationStatus?: 'approved' | 'pending' | 'rejected';
|
|
38
43
|
createdAt: any;
|
|
39
44
|
updatedAt: any | null;
|
|
40
45
|
deletedAt: any | null;
|
|
@@ -81,6 +86,7 @@ export interface StoreTemplateCreateInput {
|
|
|
81
86
|
discount?: number | null;
|
|
82
87
|
license?: string | null;
|
|
83
88
|
parentId?: string | null;
|
|
89
|
+
salesClosed?: boolean;
|
|
84
90
|
}
|
|
85
91
|
export interface StoreTemplateUpdateInput {
|
|
86
92
|
title?: string;
|
|
@@ -97,6 +103,8 @@ export interface StoreTemplateUpdateInput {
|
|
|
97
103
|
schema?: Record<string, unknown>;
|
|
98
104
|
data?: Record<string, unknown>;
|
|
99
105
|
policy?: TemplateComponentPolicy;
|
|
106
|
+
/** Author can close sales; `featured` / `moderationStatus` remain admin-only. */
|
|
107
|
+
salesClosed?: boolean;
|
|
100
108
|
}
|
|
101
109
|
/** One row in `store_template_locales`. */
|
|
102
110
|
export interface StoreTemplateLocaleEntity {
|
|
@@ -55,6 +55,50 @@ export declare class StoreTemplatesRepository extends ModelRepository<StoreTempl
|
|
|
55
55
|
}): Promise<StoreTemplateReleaseEntity>;
|
|
56
56
|
/** Author publishes a new immutable release. */
|
|
57
57
|
createRelease(templateId: string, input: StoreTemplateReleaseCreateInput): Promise<StoreTemplateReleaseEntity>;
|
|
58
|
+
/** Public render payload for historical / marketing preview (no auth required for public listings). */
|
|
59
|
+
renderRelease(templateId: string, releaseId: string): Promise<{
|
|
60
|
+
storeTemplateId: string;
|
|
61
|
+
releaseId: string;
|
|
62
|
+
version: string;
|
|
63
|
+
changelog: string | null;
|
|
64
|
+
data: Record<string, unknown>;
|
|
65
|
+
schema?: Record<string, unknown>;
|
|
66
|
+
}>;
|
|
67
|
+
listReviews(templateId: string, options?: {
|
|
68
|
+
page?: number;
|
|
69
|
+
limit?: number;
|
|
70
|
+
}): Promise<{
|
|
71
|
+
data: Array<Record<string, unknown>>;
|
|
72
|
+
meta: {
|
|
73
|
+
total: number;
|
|
74
|
+
page: number;
|
|
75
|
+
limit: number;
|
|
76
|
+
};
|
|
77
|
+
ratingAvg: number;
|
|
78
|
+
ratingCount: number;
|
|
79
|
+
}>;
|
|
80
|
+
upsertReview(options: {
|
|
81
|
+
templateId: string;
|
|
82
|
+
storeId: string;
|
|
83
|
+
rating: number;
|
|
84
|
+
body?: string | null;
|
|
85
|
+
}): Promise<{
|
|
86
|
+
review: Record<string, unknown>;
|
|
87
|
+
ratingAvg: number;
|
|
88
|
+
ratingCount: number;
|
|
89
|
+
}>;
|
|
90
|
+
earnings(): Promise<{
|
|
91
|
+
totalSales: number;
|
|
92
|
+
totalAuthorAmount: number;
|
|
93
|
+
totalPlatformAmount: number;
|
|
94
|
+
byTemplate: Array<{
|
|
95
|
+
storeTemplateId: string;
|
|
96
|
+
title: string;
|
|
97
|
+
sales: number;
|
|
98
|
+
authorAmount: number;
|
|
99
|
+
platformAmount: number;
|
|
100
|
+
}>;
|
|
101
|
+
}>;
|
|
58
102
|
/** GET locales bundle (`defaultLocale`, `locales`, `messages`). */
|
|
59
103
|
listLocales(templateId: string): Promise<StoreTemplateLocalesBundle>;
|
|
60
104
|
/** Create one locale row. */
|