convex-cms 0.0.16 → 0.0.17
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/admin/dist/types/admin/src/components/ui/field.d.ts +1 -1
- package/admin/dist/types/admin/src/lib/cmsExports.d.ts +6 -6
- package/admin/dist/types/admin/src/lib/cmsExports.d.ts.map +1 -1
- package/admin/src/lib/cmsExports.ts +8 -8
- package/admin-dist/assets/index-DagpgVMo.js +104 -0
- package/admin-dist/embed/favicon.ico +0 -0
- package/admin-dist/embed/index.js +30961 -0
- package/admin-dist/embed/index.js.map +1 -0
- package/admin-dist/index.html +1 -1
- package/package.json +12 -5
- package/admin/dist/types/src/client/admin/bulk.d.ts +0 -79
- package/admin/dist/types/src/client/admin/bulk.d.ts.map +0 -1
- package/admin/dist/types/src/client/admin/contentLock.d.ts +0 -118
- package/admin/dist/types/src/client/admin/contentLock.d.ts.map +0 -1
- package/admin/dist/types/src/client/admin/contentTypes.d.ts +0 -1627
- package/admin/dist/types/src/client/admin/contentTypes.d.ts.map +0 -1
- package/admin/dist/types/src/client/admin/dashboard.d.ts +0 -16
- package/admin/dist/types/src/client/admin/dashboard.d.ts.map +0 -1
- package/admin/dist/types/src/client/admin/entries.d.ts +0 -357
- package/admin/dist/types/src/client/admin/entries.d.ts.map +0 -1
- package/admin/dist/types/src/client/admin/index.d.ts +0 -7502
- package/admin/dist/types/src/client/admin/index.d.ts.map +0 -1
- package/admin/dist/types/src/client/admin/media.d.ts +0 -1038
- package/admin/dist/types/src/client/admin/media.d.ts.map +0 -1
- package/admin/dist/types/src/client/admin/settings.d.ts +0 -50
- package/admin/dist/types/src/client/admin/settings.d.ts.map +0 -1
- package/admin/dist/types/src/client/admin/taxonomies.d.ts +0 -339
- package/admin/dist/types/src/client/admin/taxonomies.d.ts.map +0 -1
- package/admin/dist/types/src/client/admin/trash.d.ts +0 -90
- package/admin/dist/types/src/client/admin/trash.d.ts.map +0 -1
- package/admin/dist/types/src/client/admin/types.d.ts +0 -594
- package/admin/dist/types/src/client/admin/types.d.ts.map +0 -1
- package/admin/dist/types/src/client/admin/users.d.ts +0 -58
- package/admin/dist/types/src/client/admin/users.d.ts.map +0 -1
- package/admin/dist/types/src/client/admin/validators.d.ts +0 -7732
- package/admin/dist/types/src/client/admin/validators.d.ts.map +0 -1
- package/admin/dist/types/src/client/admin/versions.d.ts +0 -106
- package/admin/dist/types/src/client/admin/versions.d.ts.map +0 -1
- package/admin/dist/types/src/client/adminConfig.d.ts +0 -125
- package/admin/dist/types/src/client/adminConfig.d.ts.map +0 -1
- package/admin/dist/types/src/client/config.d.ts +0 -155
- package/admin/dist/types/src/client/config.d.ts.map +0 -1
- package/admin/dist/types/src/client/field-types.d.ts +0 -55
- package/admin/dist/types/src/client/field-types.d.ts.map +0 -1
- package/admin/dist/types/src/client/fields.d.ts +0 -70
- package/admin/dist/types/src/client/fields.d.ts.map +0 -1
- package/admin/dist/types/src/client/registry.d.ts +0 -77
- package/admin/dist/types/src/client/registry.d.ts.map +0 -1
- package/admin/dist/types/src/client/schema/defineContentType.d.ts +0 -233
- package/admin/dist/types/src/client/schema/defineContentType.d.ts.map +0 -1
- package/admin/dist/types/src/client/schema/types.d.ts +0 -540
- package/admin/dist/types/src/client/schema/types.d.ts.map +0 -1
- package/admin/dist/types/src/client/types.d.ts +0 -449
- package/admin/dist/types/src/client/types.d.ts.map +0 -1
- package/admin/dist/types/src/client/utils/toSlug.d.ts +0 -60
- package/admin/dist/types/src/client/utils/toSlug.d.ts.map +0 -1
- package/admin/dist/types/src/client/workflows.d.ts +0 -51
- package/admin/dist/types/src/client/workflows.d.ts.map +0 -1
- package/admin/dist/types/src/component/_generated/component.d.ts +0 -4813
- package/admin/dist/types/src/component/_generated/component.d.ts.map +0 -1
- package/admin/dist/types/src/component/_generated/dataModel.d.ts +0 -46
- package/admin/dist/types/src/component/_generated/dataModel.d.ts.map +0 -1
- package/admin/dist/types/src/component/_generated/server.d.ts +0 -121
- package/admin/dist/types/src/component/_generated/server.d.ts.map +0 -1
- package/admin/dist/types/src/component/contentEntryMutations.d.ts +0 -551
- package/admin/dist/types/src/component/contentEntryMutations.d.ts.map +0 -1
- package/admin/dist/types/src/component/contentLock.d.ts +0 -328
- package/admin/dist/types/src/component/contentLock.d.ts.map +0 -1
- package/admin/dist/types/src/component/contentTypeMutations.d.ts +0 -1253
- package/admin/dist/types/src/component/contentTypeMutations.d.ts.map +0 -1
- package/admin/dist/types/src/component/documentTypes.d.ts +0 -186
- package/admin/dist/types/src/component/documentTypes.d.ts.map +0 -1
- package/admin/dist/types/src/component/eventEmitter.d.ts +0 -309
- package/admin/dist/types/src/component/eventEmitter.d.ts.map +0 -1
- package/admin/dist/types/src/component/lib/errors.d.ts +0 -306
- package/admin/dist/types/src/component/lib/errors.d.ts.map +0 -1
- package/admin/dist/types/src/component/lib/metadataExtractor.d.ts +0 -245
- package/admin/dist/types/src/component/lib/metadataExtractor.d.ts.map +0 -1
- package/admin/dist/types/src/component/lib/mutationAuth.d.ts +0 -95
- package/admin/dist/types/src/component/lib/mutationAuth.d.ts.map +0 -1
- package/admin/dist/types/src/component/lib/slugGenerator.d.ts +0 -71
- package/admin/dist/types/src/component/lib/slugGenerator.d.ts.map +0 -1
- package/admin/dist/types/src/component/lib/slugUniqueness.d.ts +0 -131
- package/admin/dist/types/src/component/lib/slugUniqueness.d.ts.map +0 -1
- package/admin/dist/types/src/component/lib/softDelete.d.ts +0 -18
- package/admin/dist/types/src/component/lib/softDelete.d.ts.map +0 -1
- package/admin/dist/types/src/component/localeFields.d.ts +0 -508
- package/admin/dist/types/src/component/localeFields.d.ts.map +0 -1
- package/admin/dist/types/src/component/mediaAssetMutations.d.ts +0 -282
- package/admin/dist/types/src/component/mediaAssetMutations.d.ts.map +0 -1
- package/admin/dist/types/src/component/schema.d.ts +0 -5248
- package/admin/dist/types/src/component/schema.d.ts.map +0 -1
- package/admin/dist/types/src/component/validation.d.ts +0 -407
- package/admin/dist/types/src/component/validation.d.ts.map +0 -1
- package/admin/dist/types/src/component/validators.d.ts +0 -5722
- package/admin/dist/types/src/component/validators.d.ts.map +0 -1
- package/admin/dist/types/src/react/index.d.ts +0 -493
- package/admin/dist/types/src/react/index.d.ts.map +0 -1
- package/admin-dist/assets/index-DTgANhXL.js +0 -104
|
@@ -1,306 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Centralized Error Handling Module
|
|
3
|
-
*
|
|
4
|
-
* Provides structured error codes, error classes, and helper functions
|
|
5
|
-
* for consistent error handling across all mutation files.
|
|
6
|
-
*
|
|
7
|
-
* Error Format:
|
|
8
|
-
* - code: Machine-readable error code (e.g., "CONTENT_TYPE_NOT_FOUND")
|
|
9
|
-
* - category: Error category for routing (e.g., "NOT_FOUND", "DELETED")
|
|
10
|
-
* - message: Human-readable description
|
|
11
|
-
* - context: Additional data for debugging (resource IDs, states, etc.)
|
|
12
|
-
*/
|
|
13
|
-
/**
|
|
14
|
-
* High-level error categories for routing and handling.
|
|
15
|
-
*/
|
|
16
|
-
export type ErrorCategory = "NOT_FOUND" | "DELETED" | "INACTIVE" | "STATE_CONFLICT" | "VALIDATION" | "PERMISSION" | "LOCK_CONFLICT" | "REFERENCE_CONFLICT" | "LIMIT_EXCEEDED" | "INTERNAL";
|
|
17
|
-
/**
|
|
18
|
-
* Content Type Error Codes
|
|
19
|
-
*/
|
|
20
|
-
export declare const ContentTypeErrorCodes: {
|
|
21
|
-
readonly NOT_FOUND: "CONTENT_TYPE_NOT_FOUND";
|
|
22
|
-
readonly DELETED: "CONTENT_TYPE_DELETED";
|
|
23
|
-
readonly INACTIVE: "CONTENT_TYPE_INACTIVE";
|
|
24
|
-
readonly NAME_INVALID: "CONTENT_TYPE_NAME_INVALID";
|
|
25
|
-
readonly NAME_DUPLICATE: "CONTENT_TYPE_NAME_DUPLICATE";
|
|
26
|
-
readonly FIELD_VALIDATION_FAILED: "CONTENT_TYPE_FIELD_VALIDATION_FAILED";
|
|
27
|
-
readonly SLUG_FIELD_INVALID: "CONTENT_TYPE_SLUG_FIELD_INVALID";
|
|
28
|
-
readonly TITLE_FIELD_INVALID: "CONTENT_TYPE_TITLE_FIELD_INVALID";
|
|
29
|
-
readonly HAS_ENTRIES: "CONTENT_TYPE_HAS_ENTRIES";
|
|
30
|
-
readonly BREAKING_CHANGE: "CONTENT_TYPE_BREAKING_CHANGE";
|
|
31
|
-
};
|
|
32
|
-
/**
|
|
33
|
-
* Content Entry Error Codes
|
|
34
|
-
*/
|
|
35
|
-
export declare const ContentEntryErrorCodes: {
|
|
36
|
-
readonly NOT_FOUND: "CONTENT_ENTRY_NOT_FOUND";
|
|
37
|
-
readonly DELETED: "CONTENT_ENTRY_DELETED";
|
|
38
|
-
readonly NOT_DELETED: "CONTENT_ENTRY_NOT_DELETED";
|
|
39
|
-
readonly ALREADY_PUBLISHED: "CONTENT_ENTRY_ALREADY_PUBLISHED";
|
|
40
|
-
readonly NOT_PUBLISHED: "CONTENT_ENTRY_NOT_PUBLISHED";
|
|
41
|
-
readonly ARCHIVED: "CONTENT_ENTRY_ARCHIVED";
|
|
42
|
-
readonly VALIDATION_FAILED: "CONTENT_ENTRY_VALIDATION_FAILED";
|
|
43
|
-
readonly SLUG_CONFLICT: "CONTENT_ENTRY_SLUG_CONFLICT";
|
|
44
|
-
readonly LOCKED: "CONTENT_ENTRY_LOCKED";
|
|
45
|
-
readonly CREATE_FAILED: "CONTENT_ENTRY_CREATE_FAILED";
|
|
46
|
-
readonly UPDATE_FAILED: "CONTENT_ENTRY_UPDATE_FAILED";
|
|
47
|
-
};
|
|
48
|
-
/**
|
|
49
|
-
* Media Asset Error Codes
|
|
50
|
-
*/
|
|
51
|
-
export declare const MediaAssetErrorCodes: {
|
|
52
|
-
readonly NOT_FOUND: "MEDIA_ASSET_NOT_FOUND";
|
|
53
|
-
readonly DELETED: "MEDIA_ASSET_DELETED";
|
|
54
|
-
readonly NOT_DELETED: "MEDIA_ASSET_NOT_DELETED";
|
|
55
|
-
readonly HAS_REFERENCES: "MEDIA_ASSET_HAS_REFERENCES";
|
|
56
|
-
readonly CREATE_FAILED: "MEDIA_ASSET_CREATE_FAILED";
|
|
57
|
-
readonly UPDATE_FAILED: "MEDIA_ASSET_UPDATE_FAILED";
|
|
58
|
-
readonly UPLOAD_INVALID: "MEDIA_ASSET_UPLOAD_INVALID";
|
|
59
|
-
};
|
|
60
|
-
/**
|
|
61
|
-
* Media Folder Error Codes
|
|
62
|
-
*/
|
|
63
|
-
export declare const MediaFolderErrorCodes: {
|
|
64
|
-
readonly NOT_FOUND: "MEDIA_FOLDER_NOT_FOUND";
|
|
65
|
-
readonly DELETED: "MEDIA_FOLDER_DELETED";
|
|
66
|
-
readonly NOT_DELETED: "MEDIA_FOLDER_NOT_DELETED";
|
|
67
|
-
readonly NAME_INVALID: "MEDIA_FOLDER_NAME_INVALID";
|
|
68
|
-
readonly NAME_DUPLICATE: "MEDIA_FOLDER_NAME_DUPLICATE";
|
|
69
|
-
readonly DEPTH_EXCEEDED: "MEDIA_FOLDER_DEPTH_EXCEEDED";
|
|
70
|
-
readonly PATH_TOO_LONG: "MEDIA_FOLDER_PATH_TOO_LONG";
|
|
71
|
-
readonly HAS_CONTENTS: "MEDIA_FOLDER_HAS_CONTENTS";
|
|
72
|
-
readonly CIRCULAR_MOVE: "MEDIA_FOLDER_CIRCULAR_MOVE";
|
|
73
|
-
readonly PARENT_DELETED: "MEDIA_FOLDER_PARENT_DELETED";
|
|
74
|
-
readonly CREATE_FAILED: "MEDIA_FOLDER_CREATE_FAILED";
|
|
75
|
-
};
|
|
76
|
-
/**
|
|
77
|
-
* Version Error Codes
|
|
78
|
-
*/
|
|
79
|
-
export declare const VersionErrorCodes: {
|
|
80
|
-
readonly NOT_FOUND: "VERSION_NOT_FOUND";
|
|
81
|
-
readonly ENTRY_NOT_FOUND: "VERSION_ENTRY_NOT_FOUND";
|
|
82
|
-
readonly ENTRY_DELETED: "VERSION_ENTRY_DELETED";
|
|
83
|
-
readonly MISMATCH: "VERSION_MISMATCH";
|
|
84
|
-
readonly ROLLBACK_FAILED: "VERSION_ROLLBACK_FAILED";
|
|
85
|
-
};
|
|
86
|
-
/**
|
|
87
|
-
* General Error Codes
|
|
88
|
-
*/
|
|
89
|
-
export declare const GeneralErrorCodes: {
|
|
90
|
-
readonly BATCH_SIZE_EXCEEDED: "BATCH_SIZE_EXCEEDED";
|
|
91
|
-
readonly PERMISSION_DENIED: "PERMISSION_DENIED";
|
|
92
|
-
readonly INTERNAL_ERROR: "INTERNAL_ERROR";
|
|
93
|
-
};
|
|
94
|
-
/**
|
|
95
|
-
* Union type of all error codes from all categories.
|
|
96
|
-
* Use the specific error code objects (ContentTypeErrorCodes, etc.) to access values.
|
|
97
|
-
*/
|
|
98
|
-
export type ErrorCode = (typeof ContentTypeErrorCodes)[keyof typeof ContentTypeErrorCodes] | (typeof ContentEntryErrorCodes)[keyof typeof ContentEntryErrorCodes] | (typeof MediaAssetErrorCodes)[keyof typeof MediaAssetErrorCodes] | (typeof MediaFolderErrorCodes)[keyof typeof MediaFolderErrorCodes] | (typeof VersionErrorCodes)[keyof typeof VersionErrorCodes] | (typeof GeneralErrorCodes)[keyof typeof GeneralErrorCodes];
|
|
99
|
-
/**
|
|
100
|
-
* Combined object containing all error codes for reference.
|
|
101
|
-
* Note: Due to key collisions (e.g., NOT_FOUND exists in multiple categories),
|
|
102
|
-
* use the specific error code objects for accessing values in code.
|
|
103
|
-
* This object is primarily useful for listing all possible error code values.
|
|
104
|
-
*/
|
|
105
|
-
export declare const ErrorCodes: {
|
|
106
|
-
readonly CONTENT_TYPE_NOT_FOUND: "CONTENT_TYPE_NOT_FOUND";
|
|
107
|
-
readonly CONTENT_TYPE_DELETED: "CONTENT_TYPE_DELETED";
|
|
108
|
-
readonly CONTENT_TYPE_INACTIVE: "CONTENT_TYPE_INACTIVE";
|
|
109
|
-
readonly CONTENT_TYPE_NAME_INVALID: "CONTENT_TYPE_NAME_INVALID";
|
|
110
|
-
readonly CONTENT_TYPE_NAME_DUPLICATE: "CONTENT_TYPE_NAME_DUPLICATE";
|
|
111
|
-
readonly CONTENT_TYPE_FIELD_VALIDATION_FAILED: "CONTENT_TYPE_FIELD_VALIDATION_FAILED";
|
|
112
|
-
readonly CONTENT_TYPE_SLUG_FIELD_INVALID: "CONTENT_TYPE_SLUG_FIELD_INVALID";
|
|
113
|
-
readonly CONTENT_TYPE_TITLE_FIELD_INVALID: "CONTENT_TYPE_TITLE_FIELD_INVALID";
|
|
114
|
-
readonly CONTENT_TYPE_HAS_ENTRIES: "CONTENT_TYPE_HAS_ENTRIES";
|
|
115
|
-
readonly CONTENT_TYPE_BREAKING_CHANGE: "CONTENT_TYPE_BREAKING_CHANGE";
|
|
116
|
-
readonly CONTENT_ENTRY_NOT_FOUND: "CONTENT_ENTRY_NOT_FOUND";
|
|
117
|
-
readonly CONTENT_ENTRY_DELETED: "CONTENT_ENTRY_DELETED";
|
|
118
|
-
readonly CONTENT_ENTRY_NOT_DELETED: "CONTENT_ENTRY_NOT_DELETED";
|
|
119
|
-
readonly CONTENT_ENTRY_ALREADY_PUBLISHED: "CONTENT_ENTRY_ALREADY_PUBLISHED";
|
|
120
|
-
readonly CONTENT_ENTRY_NOT_PUBLISHED: "CONTENT_ENTRY_NOT_PUBLISHED";
|
|
121
|
-
readonly CONTENT_ENTRY_ARCHIVED: "CONTENT_ENTRY_ARCHIVED";
|
|
122
|
-
readonly CONTENT_ENTRY_VALIDATION_FAILED: "CONTENT_ENTRY_VALIDATION_FAILED";
|
|
123
|
-
readonly CONTENT_ENTRY_SLUG_CONFLICT: "CONTENT_ENTRY_SLUG_CONFLICT";
|
|
124
|
-
readonly CONTENT_ENTRY_LOCKED: "CONTENT_ENTRY_LOCKED";
|
|
125
|
-
readonly CONTENT_ENTRY_CREATE_FAILED: "CONTENT_ENTRY_CREATE_FAILED";
|
|
126
|
-
readonly CONTENT_ENTRY_UPDATE_FAILED: "CONTENT_ENTRY_UPDATE_FAILED";
|
|
127
|
-
readonly MEDIA_ASSET_NOT_FOUND: "MEDIA_ASSET_NOT_FOUND";
|
|
128
|
-
readonly MEDIA_ASSET_DELETED: "MEDIA_ASSET_DELETED";
|
|
129
|
-
readonly MEDIA_ASSET_NOT_DELETED: "MEDIA_ASSET_NOT_DELETED";
|
|
130
|
-
readonly MEDIA_ASSET_HAS_REFERENCES: "MEDIA_ASSET_HAS_REFERENCES";
|
|
131
|
-
readonly MEDIA_ASSET_CREATE_FAILED: "MEDIA_ASSET_CREATE_FAILED";
|
|
132
|
-
readonly MEDIA_ASSET_UPDATE_FAILED: "MEDIA_ASSET_UPDATE_FAILED";
|
|
133
|
-
readonly MEDIA_ASSET_UPLOAD_INVALID: "MEDIA_ASSET_UPLOAD_INVALID";
|
|
134
|
-
readonly MEDIA_FOLDER_NOT_FOUND: "MEDIA_FOLDER_NOT_FOUND";
|
|
135
|
-
readonly MEDIA_FOLDER_DELETED: "MEDIA_FOLDER_DELETED";
|
|
136
|
-
readonly MEDIA_FOLDER_NOT_DELETED: "MEDIA_FOLDER_NOT_DELETED";
|
|
137
|
-
readonly MEDIA_FOLDER_NAME_INVALID: "MEDIA_FOLDER_NAME_INVALID";
|
|
138
|
-
readonly MEDIA_FOLDER_NAME_DUPLICATE: "MEDIA_FOLDER_NAME_DUPLICATE";
|
|
139
|
-
readonly MEDIA_FOLDER_DEPTH_EXCEEDED: "MEDIA_FOLDER_DEPTH_EXCEEDED";
|
|
140
|
-
readonly MEDIA_FOLDER_PATH_TOO_LONG: "MEDIA_FOLDER_PATH_TOO_LONG";
|
|
141
|
-
readonly MEDIA_FOLDER_HAS_CONTENTS: "MEDIA_FOLDER_HAS_CONTENTS";
|
|
142
|
-
readonly MEDIA_FOLDER_CIRCULAR_MOVE: "MEDIA_FOLDER_CIRCULAR_MOVE";
|
|
143
|
-
readonly MEDIA_FOLDER_PARENT_DELETED: "MEDIA_FOLDER_PARENT_DELETED";
|
|
144
|
-
readonly MEDIA_FOLDER_CREATE_FAILED: "MEDIA_FOLDER_CREATE_FAILED";
|
|
145
|
-
readonly VERSION_NOT_FOUND: "VERSION_NOT_FOUND";
|
|
146
|
-
readonly VERSION_ENTRY_NOT_FOUND: "VERSION_ENTRY_NOT_FOUND";
|
|
147
|
-
readonly VERSION_ENTRY_DELETED: "VERSION_ENTRY_DELETED";
|
|
148
|
-
readonly VERSION_MISMATCH: "VERSION_MISMATCH";
|
|
149
|
-
readonly VERSION_ROLLBACK_FAILED: "VERSION_ROLLBACK_FAILED";
|
|
150
|
-
readonly BATCH_SIZE_EXCEEDED: "BATCH_SIZE_EXCEEDED";
|
|
151
|
-
readonly PERMISSION_DENIED: "PERMISSION_DENIED";
|
|
152
|
-
readonly INTERNAL_ERROR: "INTERNAL_ERROR";
|
|
153
|
-
};
|
|
154
|
-
/**
|
|
155
|
-
* Context for resource-related errors
|
|
156
|
-
*/
|
|
157
|
-
export interface ResourceErrorContext {
|
|
158
|
-
resourceType: "contentType" | "contentEntry" | "mediaAsset" | "mediaFolder" | "version";
|
|
159
|
-
resourceId?: string;
|
|
160
|
-
resourceName?: string;
|
|
161
|
-
currentState?: string;
|
|
162
|
-
expectedState?: string;
|
|
163
|
-
}
|
|
164
|
-
/**
|
|
165
|
-
* Context for validation errors
|
|
166
|
-
*/
|
|
167
|
-
export interface ValidationErrorContext {
|
|
168
|
-
fields?: Array<{
|
|
169
|
-
field: string;
|
|
170
|
-
message: string;
|
|
171
|
-
code?: string;
|
|
172
|
-
}>;
|
|
173
|
-
details?: string;
|
|
174
|
-
}
|
|
175
|
-
/**
|
|
176
|
-
* Context for lock-related errors
|
|
177
|
-
*/
|
|
178
|
-
export interface LockErrorContext {
|
|
179
|
-
lockedBy?: string;
|
|
180
|
-
lockedAt?: number;
|
|
181
|
-
currentUser?: string;
|
|
182
|
-
}
|
|
183
|
-
/**
|
|
184
|
-
* Context for reference-related errors
|
|
185
|
-
*/
|
|
186
|
-
export interface ReferenceErrorContext {
|
|
187
|
-
referencingResources?: Array<{
|
|
188
|
-
type: string;
|
|
189
|
-
id: string;
|
|
190
|
-
name?: string;
|
|
191
|
-
}>;
|
|
192
|
-
referenceCount?: number;
|
|
193
|
-
}
|
|
194
|
-
/**
|
|
195
|
-
* Union type for all error contexts
|
|
196
|
-
*/
|
|
197
|
-
export type CMSErrorContext = ResourceErrorContext | ValidationErrorContext | LockErrorContext | ReferenceErrorContext | Record<string, unknown>;
|
|
198
|
-
/**
|
|
199
|
-
* Custom error class for CMS operations.
|
|
200
|
-
*
|
|
201
|
-
* Provides structured error information including:
|
|
202
|
-
* - Machine-readable error code
|
|
203
|
-
* - Error category for routing
|
|
204
|
-
* - Human-readable message
|
|
205
|
-
* - Additional context for debugging
|
|
206
|
-
*
|
|
207
|
-
* @example
|
|
208
|
-
* ```typescript
|
|
209
|
-
* throw new CMSError(
|
|
210
|
-
* ErrorCodes.CONTENT_TYPE_NOT_FOUND,
|
|
211
|
-
* "NOT_FOUND",
|
|
212
|
-
* `Content type not found: ${id}`,
|
|
213
|
-
* { resourceType: "contentType", resourceId: id }
|
|
214
|
-
* );
|
|
215
|
-
* ```
|
|
216
|
-
*/
|
|
217
|
-
export declare class CMSError extends Error {
|
|
218
|
-
readonly code: ErrorCode;
|
|
219
|
-
readonly category: ErrorCategory;
|
|
220
|
-
readonly context?: CMSErrorContext;
|
|
221
|
-
constructor(code: ErrorCode, category: ErrorCategory, message: string, context?: CMSErrorContext);
|
|
222
|
-
/**
|
|
223
|
-
* Convert error to a plain object for serialization.
|
|
224
|
-
*/
|
|
225
|
-
toJSON(): {
|
|
226
|
-
name: string;
|
|
227
|
-
code: ErrorCode;
|
|
228
|
-
category: ErrorCategory;
|
|
229
|
-
message: string;
|
|
230
|
-
context?: CMSErrorContext;
|
|
231
|
-
};
|
|
232
|
-
}
|
|
233
|
-
export declare function contentTypeNotFound(id: string): CMSError;
|
|
234
|
-
export declare function contentTypeDeleted(id: string, name?: string): CMSError;
|
|
235
|
-
export declare function contentTypeInactive(id: string, name?: string): CMSError;
|
|
236
|
-
export declare function contentTypeNameInvalid(name: string): CMSError;
|
|
237
|
-
export declare function contentTypeNameDuplicate(name: string): CMSError;
|
|
238
|
-
export declare function contentTypeFieldValidationFailed(errors: Array<{
|
|
239
|
-
fieldName: string;
|
|
240
|
-
message: string;
|
|
241
|
-
code?: string;
|
|
242
|
-
}>): CMSError;
|
|
243
|
-
export declare function contentTypeSlugFieldInvalid(slugField: string, availableFields: string[]): CMSError;
|
|
244
|
-
export declare function contentTypeTitleFieldInvalid(titleField: string, availableFields: string[]): CMSError;
|
|
245
|
-
export declare function contentTypeHasEntries(id: string, name: string, entryCount: number): CMSError;
|
|
246
|
-
export declare function contentTypeBreakingChange(breakingChanges: Array<{
|
|
247
|
-
type: string;
|
|
248
|
-
fieldName: string;
|
|
249
|
-
message: string;
|
|
250
|
-
affectedEntriesCount: number;
|
|
251
|
-
}>): CMSError;
|
|
252
|
-
export declare function contentEntryNotFound(id: string): CMSError;
|
|
253
|
-
export declare function contentEntryDeleted(id: string): CMSError;
|
|
254
|
-
export declare function contentEntryNotDeleted(id: string): CMSError;
|
|
255
|
-
export declare function contentEntryAlreadyPublished(id: string): CMSError;
|
|
256
|
-
export declare function contentEntryNotPublished(id: string, currentStatus: string): CMSError;
|
|
257
|
-
export declare function contentEntryArchived(id: string): CMSError;
|
|
258
|
-
export declare function contentEntryValidationFailed(errors: Array<{
|
|
259
|
-
field: string;
|
|
260
|
-
message: string;
|
|
261
|
-
}>): CMSError;
|
|
262
|
-
export declare function contentEntryLocked(entryId: string, lockedBy: string, lockedAt: number, currentUser?: string): CMSError;
|
|
263
|
-
export declare function contentEntryCreateFailed(contentTypeId: string): CMSError;
|
|
264
|
-
export declare function contentEntryUpdateFailed(id: string): CMSError;
|
|
265
|
-
export declare function mediaAssetNotFound(id: string): CMSError;
|
|
266
|
-
export declare function mediaAssetDeleted(id: string): CMSError;
|
|
267
|
-
export declare function mediaAssetNotDeleted(id: string): CMSError;
|
|
268
|
-
export declare function mediaAssetHasReferences(id: string, references: Array<{
|
|
269
|
-
type: string;
|
|
270
|
-
id: string;
|
|
271
|
-
name?: string;
|
|
272
|
-
}>): CMSError;
|
|
273
|
-
export declare function mediaAssetCreateFailed(): CMSError;
|
|
274
|
-
export declare function mediaAssetUpdateFailed(id: string): CMSError;
|
|
275
|
-
export declare function mediaFolderNotFound(id: string): CMSError;
|
|
276
|
-
export declare function mediaFolderDeleted(id: string): CMSError;
|
|
277
|
-
export declare function mediaFolderNotDeleted(id: string): CMSError;
|
|
278
|
-
export declare function mediaFolderNameInvalid(name: string, reason: string): CMSError;
|
|
279
|
-
export declare function mediaFolderNameDuplicate(name: string, parentPath?: string): CMSError;
|
|
280
|
-
export declare function mediaFolderDepthExceeded(maxDepth: number, currentDepth: number): CMSError;
|
|
281
|
-
export declare function mediaFolderPathTooLong(maxLength: number, pathLength: number): CMSError;
|
|
282
|
-
export declare function mediaFolderHasContents(id: string, folderCount: number, assetCount: number): CMSError;
|
|
283
|
-
export declare function mediaFolderCircularMove(id: string): CMSError;
|
|
284
|
-
export declare function mediaFolderParentDeleted(id: string, parentId: string): CMSError;
|
|
285
|
-
export declare function mediaFolderCreateFailed(): CMSError;
|
|
286
|
-
export declare function versionNotFound(entryId: string, versionNumber: number): CMSError;
|
|
287
|
-
export declare function versionEntryNotFound(entryId: string): CMSError;
|
|
288
|
-
export declare function versionEntryDeleted(entryId: string): CMSError;
|
|
289
|
-
export declare function versionMismatch(entryId: string, versionId: string): CMSError;
|
|
290
|
-
export declare function versionRollbackFailed(entryId: string): CMSError;
|
|
291
|
-
export declare function batchSizeExceeded(maxSize: number, requestedSize: number): CMSError;
|
|
292
|
-
export declare function permissionDenied(action: string, resource: string): CMSError;
|
|
293
|
-
export declare function internalError(message: string): CMSError;
|
|
294
|
-
/**
|
|
295
|
-
* Type guard to check if an error is a CMSError.
|
|
296
|
-
*/
|
|
297
|
-
export declare function isCMSError(error: unknown): error is CMSError;
|
|
298
|
-
/**
|
|
299
|
-
* Type guard to check if an error has a specific error code.
|
|
300
|
-
*/
|
|
301
|
-
export declare function hasErrorCode(error: unknown, code: ErrorCode): boolean;
|
|
302
|
-
/**
|
|
303
|
-
* Type guard to check if an error is in a specific category.
|
|
304
|
-
*/
|
|
305
|
-
export declare function isErrorCategory(error: unknown, category: ErrorCategory): boolean;
|
|
306
|
-
//# sourceMappingURL=errors.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"errors.d.ts","sourceRoot":"","sources":["../../../../../../src/component/lib/errors.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAMH;;GAEG;AACH,MAAM,MAAM,aAAa,GACrB,WAAW,GACX,SAAS,GACT,UAAU,GACV,gBAAgB,GAChB,YAAY,GACZ,YAAY,GACZ,eAAe,GACf,oBAAoB,GACpB,gBAAgB,GAChB,UAAU,CAAC;AAMf;;GAEG;AACH,eAAO,MAAM,qBAAqB;;;;;;;;;;;CAWxB,CAAC;AAEX;;GAEG;AACH,eAAO,MAAM,sBAAsB;;;;;;;;;;;;CAYzB,CAAC;AAEX;;GAEG;AACH,eAAO,MAAM,oBAAoB;;;;;;;;CAQvB,CAAC;AAEX;;GAEG;AACH,eAAO,MAAM,qBAAqB;;;;;;;;;;;;CAYxB,CAAC;AAEX;;GAEG;AACH,eAAO,MAAM,iBAAiB;;;;;;CAMpB,CAAC;AAEX;;GAEG;AACH,eAAO,MAAM,iBAAiB;;;;CAIpB,CAAC;AAEX;;;GAGG;AACH,MAAM,MAAM,SAAS,GACjB,CAAC,OAAO,qBAAqB,CAAC,CAAC,MAAM,OAAO,qBAAqB,CAAC,GAClE,CAAC,OAAO,sBAAsB,CAAC,CAAC,MAAM,OAAO,sBAAsB,CAAC,GACpE,CAAC,OAAO,oBAAoB,CAAC,CAAC,MAAM,OAAO,oBAAoB,CAAC,GAChE,CAAC,OAAO,qBAAqB,CAAC,CAAC,MAAM,OAAO,qBAAqB,CAAC,GAClE,CAAC,OAAO,iBAAiB,CAAC,CAAC,MAAM,OAAO,iBAAiB,CAAC,GAC1D,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AE,MAAM,GAAG,QAAQ,CAO/E;AAED,wBAAgB,uBAAuB,IAAI,QAAQ,CAOlD;AAMD,wBAAgB,eAAe,CAAC,OAAO,EAAE,MAAM,EAAE,aAAa,EAAE,MAAM,GAAG,QAAQ,CAOhF;AAED,wBAAgB,oBAAoB,CAAC,OAAO,EAAE,MAAM,GAAG,QAAQ,CAO9D;AAED,wBAAgB,mBAAmB,CAAC,OAAO,EAAE,MAAM,GAAG,QAAQ,CAO7D;AAED,wBAAgB,eAAe,CAAC,OAAO,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,GAAG,QAAQ,CAO5E;AAED,wBAAgB,qBAAqB,CAAC,OAAO,EAAE,MAAM,GAAG,QAAQ,CAO/D;AAMD,wBAAgB,iBAAiB,CAAC,OAAO,EAAE,MAAM,EAAE,aAAa,EAAE,MAAM,GAAG,QAAQ,CAOlF;AAED,wBAAgB,gBAAgB,CAAC,MAAM,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,GAAG,QAAQ,CAO3E;AAED,wBAAgB,aAAa,CAAC,OAAO,EAAE,MAAM,GAAG,QAAQ,CAOvD;AAMD;;GAEG;AACH,wBAAgB,UAAU,CAAC,KAAK,EAAE,OAAO,GAAG,KAAK,IAAI,QAAQ,CAE5D;AAED;;GAEG;AACH,wBAAgB,YAAY,CAAC,KAAK,EAAE,OAAO,EAAE,IAAI,EAAE,SAAS,GAAG,OAAO,CAErE;AAED;;GAEG;AACH,wBAAgB,eAAe,CAAC,KAAK,EAAE,OAAO,EAAE,QAAQ,EAAE,aAAa,GAAG,OAAO,CAEhF"}
|
|
@@ -1,245 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Media Metadata Extractor
|
|
3
|
-
*
|
|
4
|
-
* Internal utility functions for extracting and normalizing metadata from uploaded files.
|
|
5
|
-
* This module provides type-safe metadata extraction based on file MIME types.
|
|
6
|
-
*
|
|
7
|
-
* Since Convex functions don't have direct file access (files are in storage),
|
|
8
|
-
* this extractor works with:
|
|
9
|
-
* 1. Client-provided metadata (dimensions, duration from browser APIs)
|
|
10
|
-
* 2. MIME type analysis for capability detection
|
|
11
|
-
* 3. Filename analysis for additional hints
|
|
12
|
-
*
|
|
13
|
-
* The extractor normalizes and validates this information into a structured format
|
|
14
|
-
* that can be stored in the media asset's metadata field.
|
|
15
|
-
*/
|
|
16
|
-
/**
|
|
17
|
-
* Base metadata properties common to all media types.
|
|
18
|
-
*/
|
|
19
|
-
export interface BaseMetadata {
|
|
20
|
-
/** Original filename */
|
|
21
|
-
filename: string;
|
|
22
|
-
/** MIME type of the file */
|
|
23
|
-
mimeType: string;
|
|
24
|
-
/** File size in bytes */
|
|
25
|
-
size: number;
|
|
26
|
-
/** Classified media type */
|
|
27
|
-
mediaType: "image" | "video" | "audio" | "document" | "other";
|
|
28
|
-
/** File extension (lowercase, without dot) */
|
|
29
|
-
extension: string;
|
|
30
|
-
/** Whether this file type is typically web-compatible */
|
|
31
|
-
isWebCompatible: boolean;
|
|
32
|
-
}
|
|
33
|
-
/**
|
|
34
|
-
* Extended metadata for image files.
|
|
35
|
-
*/
|
|
36
|
-
export interface ImageMetadata extends BaseMetadata {
|
|
37
|
-
mediaType: "image";
|
|
38
|
-
/** Width in pixels */
|
|
39
|
-
width?: number;
|
|
40
|
-
/** Height in pixels */
|
|
41
|
-
height?: number;
|
|
42
|
-
/** Aspect ratio (width / height) */
|
|
43
|
-
aspectRatio?: number;
|
|
44
|
-
/** Whether the format supports transparency */
|
|
45
|
-
supportsTransparency: boolean;
|
|
46
|
-
/** Whether this is a vector format (infinitely scalable) */
|
|
47
|
-
isVector: boolean;
|
|
48
|
-
/** Whether this format supports animation */
|
|
49
|
-
supportsAnimation: boolean;
|
|
50
|
-
/** Suggested image optimization format */
|
|
51
|
-
suggestedFormat?: "webp" | "avif" | "jpeg" | "png" | "svg";
|
|
52
|
-
}
|
|
53
|
-
/**
|
|
54
|
-
* Extended metadata for video files.
|
|
55
|
-
*/
|
|
56
|
-
export interface VideoMetadata extends BaseMetadata {
|
|
57
|
-
mediaType: "video";
|
|
58
|
-
/** Width in pixels */
|
|
59
|
-
width?: number;
|
|
60
|
-
/** Height in pixels */
|
|
61
|
-
height?: number;
|
|
62
|
-
/** Aspect ratio (width / height) */
|
|
63
|
-
aspectRatio?: number;
|
|
64
|
-
/** Duration in seconds */
|
|
65
|
-
duration?: number;
|
|
66
|
-
/** Duration formatted as HH:MM:SS */
|
|
67
|
-
durationFormatted?: string;
|
|
68
|
-
/** Video codec (if known) */
|
|
69
|
-
codec?: string;
|
|
70
|
-
/** Whether the format is widely supported in browsers */
|
|
71
|
-
hasBroadBrowserSupport: boolean;
|
|
72
|
-
}
|
|
73
|
-
/**
|
|
74
|
-
* Extended metadata for audio files.
|
|
75
|
-
*/
|
|
76
|
-
export interface AudioMetadata extends BaseMetadata {
|
|
77
|
-
mediaType: "audio";
|
|
78
|
-
/** Duration in seconds */
|
|
79
|
-
duration?: number;
|
|
80
|
-
/** Duration formatted as HH:MM:SS */
|
|
81
|
-
durationFormatted?: string;
|
|
82
|
-
/** Audio codec (if known) */
|
|
83
|
-
codec?: string;
|
|
84
|
-
/** Whether the format is widely supported in browsers */
|
|
85
|
-
hasBroadBrowserSupport: boolean;
|
|
86
|
-
}
|
|
87
|
-
/**
|
|
88
|
-
* Extended metadata for document files.
|
|
89
|
-
*/
|
|
90
|
-
export interface DocumentMetadata extends BaseMetadata {
|
|
91
|
-
mediaType: "document";
|
|
92
|
-
/** Page count (if known, typically from PDF) */
|
|
93
|
-
pageCount?: number;
|
|
94
|
-
/** Document category */
|
|
95
|
-
documentCategory: "pdf" | "word" | "spreadsheet" | "presentation" | "text" | "other";
|
|
96
|
-
/** Whether the document can be previewed in browser */
|
|
97
|
-
canPreviewInBrowser: boolean;
|
|
98
|
-
}
|
|
99
|
-
/**
|
|
100
|
-
* Metadata for unrecognized file types.
|
|
101
|
-
*/
|
|
102
|
-
export interface OtherMetadata extends BaseMetadata {
|
|
103
|
-
mediaType: "other";
|
|
104
|
-
}
|
|
105
|
-
/**
|
|
106
|
-
* Union type for all possible metadata shapes.
|
|
107
|
-
*/
|
|
108
|
-
export type ExtractedMetadata = ImageMetadata | VideoMetadata | AudioMetadata | DocumentMetadata | OtherMetadata;
|
|
109
|
-
/**
|
|
110
|
-
* Input parameters for metadata extraction.
|
|
111
|
-
*/
|
|
112
|
-
export interface MetadataExtractionInput {
|
|
113
|
-
/** Original filename */
|
|
114
|
-
filename: string;
|
|
115
|
-
/** MIME type of the file */
|
|
116
|
-
mimeType: string;
|
|
117
|
-
/** File size in bytes */
|
|
118
|
-
size: number;
|
|
119
|
-
/** Optional width in pixels (for images/videos, from client) */
|
|
120
|
-
width?: number;
|
|
121
|
-
/** Optional height in pixels (for images/videos, from client) */
|
|
122
|
-
height?: number;
|
|
123
|
-
/** Optional duration in seconds (for audio/video, from client) */
|
|
124
|
-
duration?: number;
|
|
125
|
-
/** Optional page count (for documents, from client) */
|
|
126
|
-
pageCount?: number;
|
|
127
|
-
}
|
|
128
|
-
/**
|
|
129
|
-
* Extracts the file extension from a filename.
|
|
130
|
-
*
|
|
131
|
-
* @param filename - The filename to extract the extension from
|
|
132
|
-
* @returns The lowercase extension without the dot, or empty string if none
|
|
133
|
-
*/
|
|
134
|
-
export declare function extractExtension(filename: string): string;
|
|
135
|
-
/**
|
|
136
|
-
* Classifies a MIME type into a media category.
|
|
137
|
-
*
|
|
138
|
-
* @param mimeType - The MIME type to classify
|
|
139
|
-
* @returns The media type category
|
|
140
|
-
*/
|
|
141
|
-
export declare function classifyMimeType(mimeType: string): "image" | "video" | "audio" | "document" | "other";
|
|
142
|
-
/**
|
|
143
|
-
* Calculates aspect ratio from dimensions.
|
|
144
|
-
*
|
|
145
|
-
* @param width - Width in pixels
|
|
146
|
-
* @param height - Height in pixels
|
|
147
|
-
* @returns Aspect ratio rounded to 3 decimal places, or undefined if invalid
|
|
148
|
-
*/
|
|
149
|
-
export declare function calculateAspectRatio(width?: number, height?: number): number | undefined;
|
|
150
|
-
/**
|
|
151
|
-
* Formats duration in seconds to HH:MM:SS format.
|
|
152
|
-
*
|
|
153
|
-
* @param seconds - Duration in seconds
|
|
154
|
-
* @returns Formatted duration string, or undefined if invalid
|
|
155
|
-
*/
|
|
156
|
-
export declare function formatDuration(seconds?: number): string | undefined;
|
|
157
|
-
/**
|
|
158
|
-
* Determines the optimal image format for web delivery.
|
|
159
|
-
*
|
|
160
|
-
* @param mimeType - Original MIME type
|
|
161
|
-
* @param supportsTransparency - Whether transparency is needed
|
|
162
|
-
* @returns Suggested format for optimization
|
|
163
|
-
*/
|
|
164
|
-
export declare function suggestImageFormat(mimeType: string, supportsTransparency: boolean): "webp" | "avif" | "jpeg" | "png" | "svg" | undefined;
|
|
165
|
-
/**
|
|
166
|
-
* Categorizes document MIME types into subcategories.
|
|
167
|
-
*
|
|
168
|
-
* @param mimeType - The document MIME type
|
|
169
|
-
* @returns Document category
|
|
170
|
-
*/
|
|
171
|
-
export declare function categorizeDocument(mimeType: string): "pdf" | "word" | "spreadsheet" | "presentation" | "text" | "other";
|
|
172
|
-
/**
|
|
173
|
-
* Determines if a document can be previewed in the browser.
|
|
174
|
-
*
|
|
175
|
-
* @param mimeType - The document MIME type
|
|
176
|
-
* @returns Whether the document can be previewed
|
|
177
|
-
*/
|
|
178
|
-
export declare function canPreviewDocument(mimeType: string): boolean;
|
|
179
|
-
/**
|
|
180
|
-
* Extracts and normalizes metadata from uploaded file information.
|
|
181
|
-
*
|
|
182
|
-
* This is the main function to call for metadata extraction. It analyzes
|
|
183
|
-
* the MIME type, filename, and any provided dimensions/duration to build
|
|
184
|
-
* a comprehensive metadata object specific to the file type.
|
|
185
|
-
*
|
|
186
|
-
* @param input - The file information to extract metadata from
|
|
187
|
-
* @returns Structured metadata object with type-specific properties
|
|
188
|
-
*
|
|
189
|
-
* @example
|
|
190
|
-
* ```typescript
|
|
191
|
-
* // Image with dimensions from browser
|
|
192
|
-
* const imageMetadata = extractMetadata({
|
|
193
|
-
* filename: "photo.jpg",
|
|
194
|
-
* mimeType: "image/jpeg",
|
|
195
|
-
* size: 500000,
|
|
196
|
-
* width: 1920,
|
|
197
|
-
* height: 1080,
|
|
198
|
-
* });
|
|
199
|
-
* // Returns ImageMetadata with aspectRatio, suggestedFormat, etc.
|
|
200
|
-
*
|
|
201
|
-
* // Video with duration from browser
|
|
202
|
-
* const videoMetadata = extractMetadata({
|
|
203
|
-
* filename: "clip.mp4",
|
|
204
|
-
* mimeType: "video/mp4",
|
|
205
|
-
* size: 10000000,
|
|
206
|
-
* width: 1920,
|
|
207
|
-
* height: 1080,
|
|
208
|
-
* duration: 120,
|
|
209
|
-
* });
|
|
210
|
-
* // Returns VideoMetadata with durationFormatted, hasBroadBrowserSupport, etc.
|
|
211
|
-
*
|
|
212
|
-
* // Document
|
|
213
|
-
* const docMetadata = extractMetadata({
|
|
214
|
-
* filename: "report.pdf",
|
|
215
|
-
* mimeType: "application/pdf",
|
|
216
|
-
* size: 2000000,
|
|
217
|
-
* pageCount: 15,
|
|
218
|
-
* });
|
|
219
|
-
* // Returns DocumentMetadata with documentCategory, canPreviewInBrowser, etc.
|
|
220
|
-
* ```
|
|
221
|
-
*/
|
|
222
|
-
export declare function extractMetadata(input: MetadataExtractionInput): ExtractedMetadata;
|
|
223
|
-
/**
|
|
224
|
-
* Validates that dimensions are positive integers.
|
|
225
|
-
*
|
|
226
|
-
* @param width - Width to validate
|
|
227
|
-
* @param height - Height to validate
|
|
228
|
-
* @returns Whether both dimensions are valid
|
|
229
|
-
*/
|
|
230
|
-
export declare function validateDimensions(width?: number, height?: number): boolean;
|
|
231
|
-
/**
|
|
232
|
-
* Validates that duration is a non-negative number.
|
|
233
|
-
*
|
|
234
|
-
* @param duration - Duration to validate
|
|
235
|
-
* @returns Whether the duration is valid
|
|
236
|
-
*/
|
|
237
|
-
export declare function validateDuration(duration?: number): boolean;
|
|
238
|
-
/**
|
|
239
|
-
* Validates that file size is a positive integer.
|
|
240
|
-
*
|
|
241
|
-
* @param size - File size to validate
|
|
242
|
-
* @returns Whether the size is valid
|
|
243
|
-
*/
|
|
244
|
-
export declare function validateFileSize(size: number): boolean;
|
|
245
|
-
//# sourceMappingURL=metadataExtractor.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"metadataExtractor.d.ts","sourceRoot":"","sources":["../../../../../../src/component/lib/metadataExtractor.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAMH;;GAEG;AACH,MAAM,WAAW,YAAY;IAC3B,wBAAwB;IACxB,QAAQ,EAAE,MAAM,CAAC;IACjB,4BAA4B;IAC5B,QAAQ,EAAE,MAAM,CAAC;IACjB,yBAAyB;IACzB,IAAI,EAAE,MAAM,CAAC;IACb,4BAA4B;IAC5B,SAAS,EAAE,OAAO,GAAG,OAAO,GAAG,OAAO,GAAG,UAAU,GAAG,OAAO,CAAC;IAC9D,8CAA8C;IAC9C,SAAS,EAAE,MAAM,CAAC;IAClB,yDAAyD;IACzD,eAAe,EAAE,OAAO,CAAC;CAC1B;AAED;;GAEG;AACH,MAAM,WAAW,aAAc,SAAQ,YAAY;IACjD,SAAS,EAAE,OAAO,CAAC;IACnB,sBAAsB;IACtB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,uBAAuB;IACvB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,oCAAoC;IACpC,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,+CAA+C;IAC/C,oBAAoB,EAAE,OAAO,CAAC;IAC9B,4DAA4D;IAC5D,QAAQ,EAAE,OAAO,CAAC;IAClB,6CAA6C;IAC7C,iBAAiB,EAAE,OAAO,CAAC;IAC3B,0CAA0C;IAC1C,eAAe,CAAC,EAAE,MAAM,GAAG,MAAM,GAAG,MAAM,GAAG,KAAK,GAAG,KAAK,CAAC;CAC5D;AAED;;GAEG;AACH,MAAM,WAAW,aAAc,SAAQ,YAAY;IACjD,SAAS,EAAE,OAAO,CAAC;IACnB,sBAAsB;IACtB,KAAK,CAAC,EA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AgB,kBAAkB,CAAC,KAAK,CAAC,EAAE,MAAM,EAAE,MAAM,CAAC,EAAE,MAAM,GAAG,OAAO,CAY3E;AAED;;;;;GAKG;AACH,wBAAgB,gBAAgB,CAAC,QAAQ,CAAC,EAAE,MAAM,GAAG,OAAO,CAK3D;AAED;;;;;GAKG;AACH,wBAAgB,gBAAgB,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAEtD"}
|
|
@@ -1,95 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Mutation-Level Authorization Helper
|
|
3
|
-
*
|
|
4
|
-
* Provides defense-in-depth authorization for component mutations.
|
|
5
|
-
* When auth context is provided, mutations verify the role has permission.
|
|
6
|
-
*
|
|
7
|
-
* This complements the client wrapper's authorization:
|
|
8
|
-
* - Client wrapper: Primary authorization layer (runs hooks, RBAC)
|
|
9
|
-
* - Mutation auth: Secondary validation layer (pure RBAC check)
|
|
10
|
-
*
|
|
11
|
-
* @example
|
|
12
|
-
* ```typescript
|
|
13
|
-
* import { requireMutationAuth } from "./lib/mutationAuth.js";
|
|
14
|
-
*
|
|
15
|
-
* export const createEntry = mutation({
|
|
16
|
-
* args: {
|
|
17
|
-
* ...createContentEntryArgs.fields,
|
|
18
|
-
* _auth: v.optional(mutationAuthContext),
|
|
19
|
-
* },
|
|
20
|
-
* handler: async (ctx, args) => {
|
|
21
|
-
* requireMutationAuth(args._auth, "contentEntries", "create");
|
|
22
|
-
* // ... mutation logic
|
|
23
|
-
* },
|
|
24
|
-
* });
|
|
25
|
-
* ```
|
|
26
|
-
*/
|
|
27
|
-
import type { MutationAuthContext } from "../validators.js";
|
|
28
|
-
import { type Resource, type Action, type RoleDefinition } from "../roles.js";
|
|
29
|
-
/**
|
|
30
|
-
* Options for mutation authorization check.
|
|
31
|
-
*/
|
|
32
|
-
export interface MutationAuthOptions {
|
|
33
|
-
/**
|
|
34
|
-
* Custom role definitions to include in permission checks.
|
|
35
|
-
* These are in addition to the default roles (admin, editor, author, viewer).
|
|
36
|
-
*/
|
|
37
|
-
customRoles?: Record<string, RoleDefinition>;
|
|
38
|
-
}
|
|
39
|
-
/**
|
|
40
|
-
* Verify the auth context has permission for the requested operation.
|
|
41
|
-
*
|
|
42
|
-
* This function:
|
|
43
|
-
* 1. If `_auth` is undefined, does nothing (backwards compatible)
|
|
44
|
-
* 2. If `_auth` is provided, checks the role has permission
|
|
45
|
-
* 3. Throws CMSError with PERMISSION_DENIED if check fails
|
|
46
|
-
*
|
|
47
|
-
* For ownership-scoped permissions (e.g., author editing their own content):
|
|
48
|
-
* - If the role only has "own" scope, verifies resourceOwnerId matches userId
|
|
49
|
-
* - If the role has "all" scope, ownership is not checked
|
|
50
|
-
*
|
|
51
|
-
* @param auth - The auth context from mutation args (may be undefined)
|
|
52
|
-
* @param resource - The resource being accessed (e.g., "contentEntries")
|
|
53
|
-
* @param action - The action being performed (e.g., "create", "update")
|
|
54
|
-
* @param options - Optional configuration including custom roles
|
|
55
|
-
* @throws CMSError with code PERMISSION_DENIED if authorization fails
|
|
56
|
-
*
|
|
57
|
-
* @example
|
|
58
|
-
* ```typescript
|
|
59
|
-
* // Basic usage - check if role can create content entries
|
|
60
|
-
* requireMutationAuth(args._auth, "contentEntries", "create");
|
|
61
|
-
*
|
|
62
|
-
* // For update/delete - include resource owner for "own" scope check
|
|
63
|
-
* const entry = await ctx.db.get(args.id);
|
|
64
|
-
* requireMutationAuth(
|
|
65
|
-
* { ...args._auth, resourceOwnerId: entry.createdBy },
|
|
66
|
-
* "contentEntries",
|
|
67
|
-
* "update"
|
|
68
|
-
* );
|
|
69
|
-
* ```
|
|
70
|
-
*/
|
|
71
|
-
export declare function requireMutationAuth(auth: MutationAuthContext | undefined, resource: Resource, action: Action, options?: MutationAuthOptions): void;
|
|
72
|
-
/**
|
|
73
|
-
* Check if auth context has permission without throwing.
|
|
74
|
-
*
|
|
75
|
-
* Useful for conditional logic based on permissions.
|
|
76
|
-
*
|
|
77
|
-
* @param auth - The auth context from mutation args
|
|
78
|
-
* @param resource - The resource being accessed
|
|
79
|
-
* @param action - The action being performed
|
|
80
|
-
* @param options - Optional configuration including custom roles
|
|
81
|
-
* @returns true if authorized, false otherwise
|
|
82
|
-
*/
|
|
83
|
-
export declare function hasMutationAuth(auth: MutationAuthContext | undefined, resource: Resource, action: Action, options?: MutationAuthOptions): boolean;
|
|
84
|
-
/**
|
|
85
|
-
* Augment auth context with resource owner information.
|
|
86
|
-
*
|
|
87
|
-
* Use this when you have an auth context and need to add ownership info
|
|
88
|
-
* for permission checks on existing resources.
|
|
89
|
-
*
|
|
90
|
-
* @param auth - The original auth context
|
|
91
|
-
* @param resourceOwnerId - The owner of the resource being accessed
|
|
92
|
-
* @returns Auth context with resourceOwnerId set
|
|
93
|
-
*/
|
|
94
|
-
export declare function withResourceOwner(auth: MutationAuthContext | undefined, resourceOwnerId: string | undefined): MutationAuthContext | undefined;
|
|
95
|
-
//# sourceMappingURL=mutationAuth.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"mutationAuth.d.ts","sourceRoot":"","sources":["../../../../../../src/component/lib/mutationAuth.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;GAyBG;AAEH,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,kBAAkB,CAAC;AAC5D,OAAO,EAAiB,KAAK,QAAQ,EAAE,KAAK,MAAM,EAAE,KAAK,cAAc,EAAE,MAAM,aAAa,CAAC;AAG7F;;GAEG;AACH,MAAM,WAAW,mBAAmB;IAClC;;;OAGG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,cAAc,CAAC,CAAC;CAC9C;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AACH,wBAAgB,mBAAmB,CACjC,IAAI,EAAE,mBAAmB,GAAG,SAAS,EACrC,QAAQ,EAAE,QAAQ,EAClB,MAAM,EAAE,MAAM,EACd,OAAO,CAAC,EAAE,mBAAmB,GAC5B,IAAI,CAoDN;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,eAAe,CAC7B,IAAI,EAAE,mBAAmB,GAAG,SAAS,EACrC,QAAQ,EAAE,QAAQ,EAClB,MAAM,EAAE,MAAM,EACd,OAAO,CAAC,EAAE,mBAAmB,GAC5B,OAAO,CA6BT;AAED;;;;;;;;;GASG;AACH,wBAAgB,iBAAiB,CAC/B,IAAI,EAAE,mBAAmB,GAAG,SAAS,EACrC,eAAe,EAAE,MAAM,GAAG,SAAS,GAClC,mBAAmB,GAAG,SAAS,CAKjC"}
|