@wix/auto_sdk_pro-gallery_pro-gallery 1.0.8 → 1.0.10

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 (134) hide show
  1. package/build/index.d.mts +213 -0
  2. package/build/index.d.ts +213 -0
  3. package/build/index.js +1847 -0
  4. package/build/index.js.map +1 -0
  5. package/build/index.mjs +1796 -0
  6. package/build/index.mjs.map +1 -0
  7. package/build/internal/index.d.mts +213 -0
  8. package/build/internal/index.d.ts +213 -0
  9. package/build/internal/index.js +1847 -0
  10. package/build/internal/index.js.map +1 -0
  11. package/build/internal/index.mjs +1796 -0
  12. package/build/internal/index.mjs.map +1 -0
  13. package/build/internal/meta.d.mts +498 -0
  14. package/build/internal/meta.d.ts +498 -0
  15. package/build/internal/meta.js +1054 -0
  16. package/build/internal/meta.js.map +1 -0
  17. package/build/internal/meta.mjs +1016 -0
  18. package/build/internal/meta.mjs.map +1 -0
  19. package/build/{es/src/pro-gallery-v2-gallery-pro-gallery.types.d.ts → internal/pro-gallery-v2-gallery-pro-gallery.universal-CExTgtbV.d.mts} +399 -208
  20. package/build/{cjs/src/pro-gallery-v2-gallery-pro-gallery.types.d.ts → internal/pro-gallery-v2-gallery-pro-gallery.universal-CExTgtbV.d.ts} +399 -208
  21. package/build/meta.d.mts +498 -0
  22. package/build/meta.d.ts +498 -0
  23. package/build/meta.js +1054 -0
  24. package/build/meta.js.map +1 -0
  25. package/build/meta.mjs +1016 -0
  26. package/build/meta.mjs.map +1 -0
  27. package/build/{internal/cjs/src/pro-gallery-v2-gallery-pro-gallery.types.d.ts → pro-gallery-v2-gallery-pro-gallery.universal-CExTgtbV.d.mts} +399 -208
  28. package/build/{internal/es/src/pro-gallery-v2-gallery-pro-gallery.types.d.ts → pro-gallery-v2-gallery-pro-gallery.universal-CExTgtbV.d.ts} +399 -208
  29. package/package.json +13 -12
  30. package/build/cjs/index.d.ts +0 -1
  31. package/build/cjs/index.js +0 -18
  32. package/build/cjs/index.js.map +0 -1
  33. package/build/cjs/index.typings.d.ts +0 -1
  34. package/build/cjs/index.typings.js +0 -18
  35. package/build/cjs/index.typings.js.map +0 -1
  36. package/build/cjs/meta.d.ts +0 -1
  37. package/build/cjs/meta.js +0 -18
  38. package/build/cjs/meta.js.map +0 -1
  39. package/build/cjs/src/pro-gallery-v2-gallery-pro-gallery.context.d.ts +0 -56
  40. package/build/cjs/src/pro-gallery-v2-gallery-pro-gallery.context.js +0 -69
  41. package/build/cjs/src/pro-gallery-v2-gallery-pro-gallery.context.js.map +0 -1
  42. package/build/cjs/src/pro-gallery-v2-gallery-pro-gallery.http.d.ts +0 -90
  43. package/build/cjs/src/pro-gallery-v2-gallery-pro-gallery.http.js +0 -875
  44. package/build/cjs/src/pro-gallery-v2-gallery-pro-gallery.http.js.map +0 -1
  45. package/build/cjs/src/pro-gallery-v2-gallery-pro-gallery.meta.d.ts +0 -47
  46. package/build/cjs/src/pro-gallery-v2-gallery-pro-gallery.meta.js +0 -256
  47. package/build/cjs/src/pro-gallery-v2-gallery-pro-gallery.meta.js.map +0 -1
  48. package/build/cjs/src/pro-gallery-v2-gallery-pro-gallery.public.d.ts +0 -167
  49. package/build/cjs/src/pro-gallery-v2-gallery-pro-gallery.public.js +0 -309
  50. package/build/cjs/src/pro-gallery-v2-gallery-pro-gallery.public.js.map +0 -1
  51. package/build/cjs/src/pro-gallery-v2-gallery-pro-gallery.types.js +0 -103
  52. package/build/cjs/src/pro-gallery-v2-gallery-pro-gallery.types.js.map +0 -1
  53. package/build/cjs/src/pro-gallery-v2-gallery-pro-gallery.universal.d.ts +0 -1830
  54. package/build/cjs/src/pro-gallery-v2-gallery-pro-gallery.universal.js +0 -850
  55. package/build/cjs/src/pro-gallery-v2-gallery-pro-gallery.universal.js.map +0 -1
  56. package/build/es/index.d.ts +0 -1
  57. package/build/es/index.js +0 -2
  58. package/build/es/index.js.map +0 -1
  59. package/build/es/index.typings.d.ts +0 -1
  60. package/build/es/index.typings.js +0 -2
  61. package/build/es/index.typings.js.map +0 -1
  62. package/build/es/meta.d.ts +0 -1
  63. package/build/es/meta.js +0 -2
  64. package/build/es/meta.js.map +0 -1
  65. package/build/es/package.json +0 -3
  66. package/build/es/src/pro-gallery-v2-gallery-pro-gallery.context.d.ts +0 -56
  67. package/build/es/src/pro-gallery-v2-gallery-pro-gallery.context.js +0 -56
  68. package/build/es/src/pro-gallery-v2-gallery-pro-gallery.context.js.map +0 -1
  69. package/build/es/src/pro-gallery-v2-gallery-pro-gallery.http.d.ts +0 -90
  70. package/build/es/src/pro-gallery-v2-gallery-pro-gallery.http.js +0 -860
  71. package/build/es/src/pro-gallery-v2-gallery-pro-gallery.http.js.map +0 -1
  72. package/build/es/src/pro-gallery-v2-gallery-pro-gallery.meta.d.ts +0 -47
  73. package/build/es/src/pro-gallery-v2-gallery-pro-gallery.meta.js +0 -218
  74. package/build/es/src/pro-gallery-v2-gallery-pro-gallery.meta.js.map +0 -1
  75. package/build/es/src/pro-gallery-v2-gallery-pro-gallery.public.d.ts +0 -167
  76. package/build/es/src/pro-gallery-v2-gallery-pro-gallery.public.js +0 -284
  77. package/build/es/src/pro-gallery-v2-gallery-pro-gallery.public.js.map +0 -1
  78. package/build/es/src/pro-gallery-v2-gallery-pro-gallery.types.js +0 -100
  79. package/build/es/src/pro-gallery-v2-gallery-pro-gallery.types.js.map +0 -1
  80. package/build/es/src/pro-gallery-v2-gallery-pro-gallery.universal.d.ts +0 -1830
  81. package/build/es/src/pro-gallery-v2-gallery-pro-gallery.universal.js +0 -812
  82. package/build/es/src/pro-gallery-v2-gallery-pro-gallery.universal.js.map +0 -1
  83. package/build/internal/cjs/index.d.ts +0 -1
  84. package/build/internal/cjs/index.js +0 -18
  85. package/build/internal/cjs/index.js.map +0 -1
  86. package/build/internal/cjs/index.typings.d.ts +0 -1
  87. package/build/internal/cjs/index.typings.js +0 -18
  88. package/build/internal/cjs/index.typings.js.map +0 -1
  89. package/build/internal/cjs/meta.d.ts +0 -1
  90. package/build/internal/cjs/meta.js +0 -18
  91. package/build/internal/cjs/meta.js.map +0 -1
  92. package/build/internal/cjs/src/pro-gallery-v2-gallery-pro-gallery.context.d.ts +0 -56
  93. package/build/internal/cjs/src/pro-gallery-v2-gallery-pro-gallery.context.js +0 -69
  94. package/build/internal/cjs/src/pro-gallery-v2-gallery-pro-gallery.context.js.map +0 -1
  95. package/build/internal/cjs/src/pro-gallery-v2-gallery-pro-gallery.http.d.ts +0 -90
  96. package/build/internal/cjs/src/pro-gallery-v2-gallery-pro-gallery.http.js +0 -875
  97. package/build/internal/cjs/src/pro-gallery-v2-gallery-pro-gallery.http.js.map +0 -1
  98. package/build/internal/cjs/src/pro-gallery-v2-gallery-pro-gallery.meta.d.ts +0 -47
  99. package/build/internal/cjs/src/pro-gallery-v2-gallery-pro-gallery.meta.js +0 -256
  100. package/build/internal/cjs/src/pro-gallery-v2-gallery-pro-gallery.meta.js.map +0 -1
  101. package/build/internal/cjs/src/pro-gallery-v2-gallery-pro-gallery.public.d.ts +0 -167
  102. package/build/internal/cjs/src/pro-gallery-v2-gallery-pro-gallery.public.js +0 -309
  103. package/build/internal/cjs/src/pro-gallery-v2-gallery-pro-gallery.public.js.map +0 -1
  104. package/build/internal/cjs/src/pro-gallery-v2-gallery-pro-gallery.types.js +0 -103
  105. package/build/internal/cjs/src/pro-gallery-v2-gallery-pro-gallery.types.js.map +0 -1
  106. package/build/internal/cjs/src/pro-gallery-v2-gallery-pro-gallery.universal.d.ts +0 -1830
  107. package/build/internal/cjs/src/pro-gallery-v2-gallery-pro-gallery.universal.js +0 -850
  108. package/build/internal/cjs/src/pro-gallery-v2-gallery-pro-gallery.universal.js.map +0 -1
  109. package/build/internal/es/index.d.ts +0 -1
  110. package/build/internal/es/index.js +0 -2
  111. package/build/internal/es/index.js.map +0 -1
  112. package/build/internal/es/index.typings.d.ts +0 -1
  113. package/build/internal/es/index.typings.js +0 -2
  114. package/build/internal/es/index.typings.js.map +0 -1
  115. package/build/internal/es/meta.d.ts +0 -1
  116. package/build/internal/es/meta.js +0 -2
  117. package/build/internal/es/meta.js.map +0 -1
  118. package/build/internal/es/src/pro-gallery-v2-gallery-pro-gallery.context.d.ts +0 -56
  119. package/build/internal/es/src/pro-gallery-v2-gallery-pro-gallery.context.js +0 -56
  120. package/build/internal/es/src/pro-gallery-v2-gallery-pro-gallery.context.js.map +0 -1
  121. package/build/internal/es/src/pro-gallery-v2-gallery-pro-gallery.http.d.ts +0 -90
  122. package/build/internal/es/src/pro-gallery-v2-gallery-pro-gallery.http.js +0 -860
  123. package/build/internal/es/src/pro-gallery-v2-gallery-pro-gallery.http.js.map +0 -1
  124. package/build/internal/es/src/pro-gallery-v2-gallery-pro-gallery.meta.d.ts +0 -47
  125. package/build/internal/es/src/pro-gallery-v2-gallery-pro-gallery.meta.js +0 -218
  126. package/build/internal/es/src/pro-gallery-v2-gallery-pro-gallery.meta.js.map +0 -1
  127. package/build/internal/es/src/pro-gallery-v2-gallery-pro-gallery.public.d.ts +0 -167
  128. package/build/internal/es/src/pro-gallery-v2-gallery-pro-gallery.public.js +0 -284
  129. package/build/internal/es/src/pro-gallery-v2-gallery-pro-gallery.public.js.map +0 -1
  130. package/build/internal/es/src/pro-gallery-v2-gallery-pro-gallery.types.js +0 -100
  131. package/build/internal/es/src/pro-gallery-v2-gallery-pro-gallery.types.js.map +0 -1
  132. package/build/internal/es/src/pro-gallery-v2-gallery-pro-gallery.universal.d.ts +0 -1830
  133. package/build/internal/es/src/pro-gallery-v2-gallery-pro-gallery.universal.js +0 -812
  134. package/build/internal/es/src/pro-gallery-v2-gallery-pro-gallery.universal.js.map +0 -1
@@ -0,0 +1,1847 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __export = (target, all) => {
7
+ for (var name in all)
8
+ __defProp(target, name, { get: all[name], enumerable: true });
9
+ };
10
+ var __copyProps = (to, from, except, desc) => {
11
+ if (from && typeof from === "object" || typeof from === "function") {
12
+ for (let key of __getOwnPropNames(from))
13
+ if (!__hasOwnProp.call(to, key) && key !== except)
14
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
15
+ }
16
+ return to;
17
+ };
18
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
+
20
+ // index.ts
21
+ var index_exports = {};
22
+ __export(index_exports, {
23
+ Enum: () => Enum,
24
+ ImageType: () => ImageType,
25
+ LinkRel: () => LinkRel,
26
+ LinkType: () => LinkType,
27
+ RCLabel: () => RCLabel,
28
+ SearchIndexingNotificationState: () => SearchIndexingNotificationState,
29
+ State: () => State,
30
+ Type: () => Type,
31
+ VideoType: () => VideoType,
32
+ WebhookIdentityType: () => WebhookIdentityType,
33
+ bulkDeleteGalleryItems: () => bulkDeleteGalleryItems4,
34
+ createGallery: () => createGallery4,
35
+ createGalleryItem: () => createGalleryItem4,
36
+ deleteGallery: () => deleteGallery4,
37
+ deleteGalleryItem: () => deleteGalleryItem4,
38
+ deleteGalleryItems: () => deleteGalleryItems4,
39
+ getGallery: () => getGallery4,
40
+ getGalleryItem: () => getGalleryItem4,
41
+ listGalleries: () => listGalleries4,
42
+ listGalleryItems: () => listGalleryItems4,
43
+ onGalleryCreated: () => onGalleryCreated2,
44
+ onGalleryDeleted: () => onGalleryDeleted2,
45
+ onGalleryItemCreated: () => onGalleryItemCreated2,
46
+ onGalleryItemDeleted: () => onGalleryItemDeleted2,
47
+ onGalleryItemUpdated: () => onGalleryItemUpdated2,
48
+ onGalleryUpdated: () => onGalleryUpdated2,
49
+ updateGallery: () => updateGallery4,
50
+ updateGalleryItem: () => updateGalleryItem4
51
+ });
52
+ module.exports = __toCommonJS(index_exports);
53
+
54
+ // src/pro-gallery-v2-gallery-pro-gallery.public.ts
55
+ var import_rename_all_nested_keys2 = require("@wix/sdk-runtime/rename-all-nested-keys");
56
+ var import_float3 = require("@wix/sdk-runtime/transformations/float");
57
+ var import_image3 = require("@wix/sdk-runtime/transformations/image");
58
+ var import_timestamp3 = require("@wix/sdk-runtime/transformations/timestamp");
59
+ var import_transform_paths3 = require("@wix/sdk-runtime/transformations/transform-paths");
60
+ var import_video_v23 = require("@wix/sdk-runtime/transformations/video-v2");
61
+ var import_sdk_types = require("@wix/sdk-types");
62
+
63
+ // src/pro-gallery-v2-gallery-pro-gallery.universal.ts
64
+ var import_transform_error = require("@wix/sdk-runtime/transform-error");
65
+ var import_rename_all_nested_keys = require("@wix/sdk-runtime/rename-all-nested-keys");
66
+
67
+ // src/pro-gallery-v2-gallery-pro-gallery.http.ts
68
+ var import_rest_modules = require("@wix/sdk-runtime/rest-modules");
69
+ var import_float = require("@wix/sdk-runtime/transformations/float");
70
+ var import_float2 = require("@wix/sdk-runtime/transformations/float");
71
+ var import_timestamp = require("@wix/sdk-runtime/transformations/timestamp");
72
+ var import_timestamp2 = require("@wix/sdk-runtime/transformations/timestamp");
73
+ var import_field_mask = require("@wix/sdk-runtime/transformations/field-mask");
74
+ var import_transform_paths = require("@wix/sdk-runtime/transformations/transform-paths");
75
+ var import_rest_modules2 = require("@wix/sdk-runtime/rest-modules");
76
+ function resolveComWixpressExposureProgalleryProGalleryUrl(opts) {
77
+ const domainToMappings = {
78
+ _: [
79
+ {
80
+ srcPath: "/_api/pro-gallery-server",
81
+ destPath: ""
82
+ }
83
+ ],
84
+ "manage._base_domain_": [
85
+ {
86
+ srcPath: "/_api/pro-gallery-server",
87
+ destPath: ""
88
+ }
89
+ ],
90
+ "www._base_domain_": [
91
+ {
92
+ srcPath: "/_api/pro-gallery-server",
93
+ destPath: ""
94
+ }
95
+ ],
96
+ "editor._base_domain_": [
97
+ {
98
+ srcPath: "/_api/pro-gallery-server",
99
+ destPath: ""
100
+ }
101
+ ],
102
+ "blocks._base_domain_": [
103
+ {
104
+ srcPath: "/_api/pro-gallery-server",
105
+ destPath: ""
106
+ }
107
+ ],
108
+ "create.editorx": [
109
+ {
110
+ srcPath: "/_api/pro-gallery-server",
111
+ destPath: ""
112
+ }
113
+ ],
114
+ "progallery.wixapps.net": [
115
+ {
116
+ srcPath: "/_api/pro-gallery-server",
117
+ destPath: ""
118
+ }
119
+ ],
120
+ "www.wixapis.com": [
121
+ {
122
+ srcPath: "/progallery",
123
+ destPath: ""
124
+ }
125
+ ],
126
+ "*.dev.wix-code.com": [
127
+ {
128
+ srcPath: "/_api/pro-gallery-server",
129
+ destPath: ""
130
+ }
131
+ ],
132
+ "api._api_base_domain_": [
133
+ {
134
+ srcPath: "/prime-server-proxy",
135
+ destPath: ""
136
+ }
137
+ ]
138
+ };
139
+ return (0, import_rest_modules2.resolveUrl)(Object.assign(opts, { domainToMappings }));
140
+ }
141
+ var PACKAGE_NAME = "@wix/auto_sdk_pro-gallery_pro-gallery";
142
+ function listGalleries(payload) {
143
+ function __listGalleries({ host }) {
144
+ const serializedData = (0, import_transform_paths.transformPaths)(payload, [
145
+ {
146
+ transformFn: import_field_mask.transformSDKFieldMaskToRESTFieldMask,
147
+ paths: [{ path: "fields" }]
148
+ }
149
+ ]);
150
+ const metadata = {
151
+ entityFqdn: "wix.pro_gallery.v2.gallery",
152
+ method: "GET",
153
+ methodFqn: "com.wixpress.exposure.progallery.ProGallery.ListGalleries",
154
+ packageName: PACKAGE_NAME,
155
+ url: resolveComWixpressExposureProgalleryProGalleryUrl({
156
+ protoPath: "/v2/galleries",
157
+ data: serializedData,
158
+ host
159
+ }),
160
+ params: (0, import_rest_modules.toURLSearchParams)(serializedData),
161
+ transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
162
+ {
163
+ transformFn: import_float2.transformRESTFloatToSDKFloat,
164
+ paths: [
165
+ { path: "galleries.sortOrder" },
166
+ { path: "galleries.items.sortOrder" },
167
+ { path: "galleries.items.image.focalPoint.x" },
168
+ { path: "galleries.items.image.focalPoint.y" },
169
+ { path: "galleries.items.secondaryMedia.image.focalPoint.x" },
170
+ { path: "galleries.items.secondaryMedia.image.focalPoint.y" },
171
+ { path: "galleries.items.image.unsharpMasking.amount" },
172
+ { path: "galleries.items.image.unsharpMasking.radius" },
173
+ { path: "galleries.items.image.unsharpMasking.threshold" },
174
+ {
175
+ path: "galleries.items.secondaryMedia.image.unsharpMasking.amount"
176
+ },
177
+ {
178
+ path: "galleries.items.secondaryMedia.image.unsharpMasking.radius"
179
+ },
180
+ {
181
+ path: "galleries.items.secondaryMedia.image.unsharpMasking.threshold"
182
+ }
183
+ ]
184
+ },
185
+ {
186
+ transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
187
+ paths: [
188
+ { path: "galleries.createdDate" },
189
+ { path: "galleries.items.createdDate" },
190
+ { path: "galleries.items.updatedDate" },
191
+ { path: "galleries.items.image.imageInfo.urlExpirationDate" },
192
+ { path: "galleries.items.video.videoInfo.urlExpirationDate" },
193
+ {
194
+ path: "galleries.items.video.videoInfo.resolutions.poster.urlExpirationDate"
195
+ },
196
+ {
197
+ path: "galleries.items.video.videoInfo.posters.urlExpirationDate"
198
+ },
199
+ {
200
+ path: "galleries.items.secondaryMedia.image.imageInfo.urlExpirationDate"
201
+ }
202
+ ]
203
+ }
204
+ ])
205
+ };
206
+ return metadata;
207
+ }
208
+ return __listGalleries;
209
+ }
210
+ function getGallery(payload) {
211
+ function __getGallery({ host }) {
212
+ const metadata = {
213
+ entityFqdn: "wix.pro_gallery.v2.gallery",
214
+ method: "GET",
215
+ methodFqn: "com.wixpress.exposure.progallery.ProGallery.GetGallery",
216
+ packageName: PACKAGE_NAME,
217
+ url: resolveComWixpressExposureProgalleryProGalleryUrl({
218
+ protoPath: "/v2/galleries/{galleryId}",
219
+ data: payload,
220
+ host
221
+ }),
222
+ params: (0, import_rest_modules.toURLSearchParams)(payload),
223
+ transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
224
+ {
225
+ transformFn: import_float2.transformRESTFloatToSDKFloat,
226
+ paths: [
227
+ { path: "gallery.sortOrder" },
228
+ { path: "gallery.items.sortOrder" },
229
+ { path: "gallery.items.image.focalPoint.x" },
230
+ { path: "gallery.items.image.focalPoint.y" },
231
+ { path: "gallery.items.secondaryMedia.image.focalPoint.x" },
232
+ { path: "gallery.items.secondaryMedia.image.focalPoint.y" },
233
+ { path: "gallery.items.image.unsharpMasking.amount" },
234
+ { path: "gallery.items.image.unsharpMasking.radius" },
235
+ { path: "gallery.items.image.unsharpMasking.threshold" },
236
+ {
237
+ path: "gallery.items.secondaryMedia.image.unsharpMasking.amount"
238
+ },
239
+ {
240
+ path: "gallery.items.secondaryMedia.image.unsharpMasking.radius"
241
+ },
242
+ {
243
+ path: "gallery.items.secondaryMedia.image.unsharpMasking.threshold"
244
+ }
245
+ ]
246
+ },
247
+ {
248
+ transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
249
+ paths: [
250
+ { path: "gallery.createdDate" },
251
+ { path: "gallery.items.createdDate" },
252
+ { path: "gallery.items.updatedDate" },
253
+ { path: "gallery.items.image.imageInfo.urlExpirationDate" },
254
+ { path: "gallery.items.video.videoInfo.urlExpirationDate" },
255
+ {
256
+ path: "gallery.items.video.videoInfo.resolutions.poster.urlExpirationDate"
257
+ },
258
+ {
259
+ path: "gallery.items.video.videoInfo.posters.urlExpirationDate"
260
+ },
261
+ {
262
+ path: "gallery.items.secondaryMedia.image.imageInfo.urlExpirationDate"
263
+ }
264
+ ]
265
+ }
266
+ ])
267
+ };
268
+ return metadata;
269
+ }
270
+ return __getGallery;
271
+ }
272
+ function listGalleryItems(payload) {
273
+ function __listGalleryItems({ host }) {
274
+ const metadata = {
275
+ entityFqdn: "wix.pro_gallery.v2.gallery",
276
+ method: "GET",
277
+ methodFqn: "com.wixpress.exposure.progallery.ProGallery.ListGalleryItems",
278
+ packageName: PACKAGE_NAME,
279
+ url: resolveComWixpressExposureProgalleryProGalleryUrl({
280
+ protoPath: "/v2/galleries/{galleryId}/items",
281
+ data: payload,
282
+ host
283
+ }),
284
+ params: (0, import_rest_modules.toURLSearchParams)(payload),
285
+ transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
286
+ {
287
+ transformFn: import_float2.transformRESTFloatToSDKFloat,
288
+ paths: [
289
+ { path: "items.sortOrder" },
290
+ { path: "items.image.focalPoint.x" },
291
+ { path: "items.image.focalPoint.y" },
292
+ { path: "items.secondaryMedia.image.focalPoint.x" },
293
+ { path: "items.secondaryMedia.image.focalPoint.y" },
294
+ { path: "items.image.unsharpMasking.amount" },
295
+ { path: "items.image.unsharpMasking.radius" },
296
+ { path: "items.image.unsharpMasking.threshold" },
297
+ { path: "items.secondaryMedia.image.unsharpMasking.amount" },
298
+ { path: "items.secondaryMedia.image.unsharpMasking.radius" },
299
+ { path: "items.secondaryMedia.image.unsharpMasking.threshold" }
300
+ ]
301
+ },
302
+ {
303
+ transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
304
+ paths: [
305
+ { path: "items.createdDate" },
306
+ { path: "items.updatedDate" },
307
+ { path: "items.image.imageInfo.urlExpirationDate" },
308
+ { path: "items.video.videoInfo.urlExpirationDate" },
309
+ {
310
+ path: "items.video.videoInfo.resolutions.poster.urlExpirationDate"
311
+ },
312
+ { path: "items.video.videoInfo.posters.urlExpirationDate" },
313
+ {
314
+ path: "items.secondaryMedia.image.imageInfo.urlExpirationDate"
315
+ }
316
+ ]
317
+ }
318
+ ])
319
+ };
320
+ return metadata;
321
+ }
322
+ return __listGalleryItems;
323
+ }
324
+ function getGalleryItem(payload) {
325
+ function __getGalleryItem({ host }) {
326
+ const metadata = {
327
+ entityFqdn: "wix.pro_gallery.v2.gallery",
328
+ method: "GET",
329
+ methodFqn: "com.wixpress.exposure.progallery.ProGallery.GetGalleryItem",
330
+ packageName: PACKAGE_NAME,
331
+ url: resolveComWixpressExposureProgalleryProGalleryUrl({
332
+ protoPath: "/v2/galleries/{galleryId}/items/{itemId}",
333
+ data: payload,
334
+ host
335
+ }),
336
+ params: (0, import_rest_modules.toURLSearchParams)(payload),
337
+ transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
338
+ {
339
+ transformFn: import_float2.transformRESTFloatToSDKFloat,
340
+ paths: [
341
+ { path: "item.sortOrder" },
342
+ { path: "item.image.focalPoint.x" },
343
+ { path: "item.image.focalPoint.y" },
344
+ { path: "item.secondaryMedia.image.focalPoint.x" },
345
+ { path: "item.secondaryMedia.image.focalPoint.y" },
346
+ { path: "item.image.unsharpMasking.amount" },
347
+ { path: "item.image.unsharpMasking.radius" },
348
+ { path: "item.image.unsharpMasking.threshold" },
349
+ { path: "item.secondaryMedia.image.unsharpMasking.amount" },
350
+ { path: "item.secondaryMedia.image.unsharpMasking.radius" },
351
+ { path: "item.secondaryMedia.image.unsharpMasking.threshold" }
352
+ ]
353
+ },
354
+ {
355
+ transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
356
+ paths: [
357
+ { path: "item.createdDate" },
358
+ { path: "item.updatedDate" },
359
+ { path: "item.image.imageInfo.urlExpirationDate" },
360
+ { path: "item.video.videoInfo.urlExpirationDate" },
361
+ {
362
+ path: "item.video.videoInfo.resolutions.poster.urlExpirationDate"
363
+ },
364
+ { path: "item.video.videoInfo.posters.urlExpirationDate" },
365
+ { path: "item.secondaryMedia.image.imageInfo.urlExpirationDate" }
366
+ ]
367
+ }
368
+ ])
369
+ };
370
+ return metadata;
371
+ }
372
+ return __getGalleryItem;
373
+ }
374
+ function createGallery(payload) {
375
+ function __createGallery({ host }) {
376
+ const serializedData = (0, import_transform_paths.transformPaths)(payload, [
377
+ {
378
+ transformFn: import_float.transformSDKFloatToRESTFloat,
379
+ paths: [
380
+ { path: "gallery.sortOrder" },
381
+ { path: "gallery.items.sortOrder" },
382
+ { path: "gallery.items.image.focalPoint.x" },
383
+ { path: "gallery.items.image.focalPoint.y" },
384
+ { path: "gallery.items.secondaryMedia.image.focalPoint.x" },
385
+ { path: "gallery.items.secondaryMedia.image.focalPoint.y" },
386
+ { path: "gallery.items.image.unsharpMasking.amount" },
387
+ { path: "gallery.items.image.unsharpMasking.radius" },
388
+ { path: "gallery.items.image.unsharpMasking.threshold" },
389
+ { path: "gallery.items.secondaryMedia.image.unsharpMasking.amount" },
390
+ { path: "gallery.items.secondaryMedia.image.unsharpMasking.radius" },
391
+ {
392
+ path: "gallery.items.secondaryMedia.image.unsharpMasking.threshold"
393
+ }
394
+ ]
395
+ },
396
+ {
397
+ transformFn: import_timestamp.transformSDKTimestampToRESTTimestamp,
398
+ paths: [
399
+ { path: "gallery.createdDate" },
400
+ { path: "gallery.items.createdDate" },
401
+ { path: "gallery.items.updatedDate" },
402
+ { path: "gallery.items.image.imageInfo.urlExpirationDate" },
403
+ { path: "gallery.items.video.videoInfo.urlExpirationDate" },
404
+ {
405
+ path: "gallery.items.video.videoInfo.resolutions.poster.urlExpirationDate"
406
+ },
407
+ { path: "gallery.items.video.videoInfo.posters.urlExpirationDate" },
408
+ {
409
+ path: "gallery.items.secondaryMedia.image.imageInfo.urlExpirationDate"
410
+ }
411
+ ]
412
+ }
413
+ ]);
414
+ const metadata = {
415
+ entityFqdn: "wix.pro_gallery.v2.gallery",
416
+ method: "POST",
417
+ methodFqn: "com.wixpress.exposure.progallery.ProGallery.CreateGallery",
418
+ packageName: PACKAGE_NAME,
419
+ url: resolveComWixpressExposureProgalleryProGalleryUrl({
420
+ protoPath: "/v2/galleries",
421
+ data: serializedData,
422
+ host
423
+ }),
424
+ data: serializedData,
425
+ transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
426
+ {
427
+ transformFn: import_float2.transformRESTFloatToSDKFloat,
428
+ paths: [
429
+ { path: "gallery.sortOrder" },
430
+ { path: "gallery.items.sortOrder" },
431
+ { path: "gallery.items.image.focalPoint.x" },
432
+ { path: "gallery.items.image.focalPoint.y" },
433
+ { path: "gallery.items.secondaryMedia.image.focalPoint.x" },
434
+ { path: "gallery.items.secondaryMedia.image.focalPoint.y" },
435
+ { path: "gallery.items.image.unsharpMasking.amount" },
436
+ { path: "gallery.items.image.unsharpMasking.radius" },
437
+ { path: "gallery.items.image.unsharpMasking.threshold" },
438
+ {
439
+ path: "gallery.items.secondaryMedia.image.unsharpMasking.amount"
440
+ },
441
+ {
442
+ path: "gallery.items.secondaryMedia.image.unsharpMasking.radius"
443
+ },
444
+ {
445
+ path: "gallery.items.secondaryMedia.image.unsharpMasking.threshold"
446
+ }
447
+ ]
448
+ },
449
+ {
450
+ transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
451
+ paths: [
452
+ { path: "gallery.createdDate" },
453
+ { path: "gallery.items.createdDate" },
454
+ { path: "gallery.items.updatedDate" },
455
+ { path: "gallery.items.image.imageInfo.urlExpirationDate" },
456
+ { path: "gallery.items.video.videoInfo.urlExpirationDate" },
457
+ {
458
+ path: "gallery.items.video.videoInfo.resolutions.poster.urlExpirationDate"
459
+ },
460
+ {
461
+ path: "gallery.items.video.videoInfo.posters.urlExpirationDate"
462
+ },
463
+ {
464
+ path: "gallery.items.secondaryMedia.image.imageInfo.urlExpirationDate"
465
+ }
466
+ ]
467
+ }
468
+ ])
469
+ };
470
+ return metadata;
471
+ }
472
+ return __createGallery;
473
+ }
474
+ function updateGallery(payload) {
475
+ function __updateGallery({ host }) {
476
+ const serializedData = (0, import_transform_paths.transformPaths)(payload, [
477
+ {
478
+ transformFn: import_float.transformSDKFloatToRESTFloat,
479
+ paths: [
480
+ { path: "gallery.sortOrder" },
481
+ { path: "gallery.items.sortOrder" },
482
+ { path: "gallery.items.image.focalPoint.x" },
483
+ { path: "gallery.items.image.focalPoint.y" },
484
+ { path: "gallery.items.secondaryMedia.image.focalPoint.x" },
485
+ { path: "gallery.items.secondaryMedia.image.focalPoint.y" },
486
+ { path: "gallery.items.image.unsharpMasking.amount" },
487
+ { path: "gallery.items.image.unsharpMasking.radius" },
488
+ { path: "gallery.items.image.unsharpMasking.threshold" },
489
+ { path: "gallery.items.secondaryMedia.image.unsharpMasking.amount" },
490
+ { path: "gallery.items.secondaryMedia.image.unsharpMasking.radius" },
491
+ {
492
+ path: "gallery.items.secondaryMedia.image.unsharpMasking.threshold"
493
+ }
494
+ ]
495
+ },
496
+ {
497
+ transformFn: import_timestamp.transformSDKTimestampToRESTTimestamp,
498
+ paths: [
499
+ { path: "gallery.createdDate" },
500
+ { path: "gallery.items.createdDate" },
501
+ { path: "gallery.items.updatedDate" },
502
+ { path: "gallery.items.image.imageInfo.urlExpirationDate" },
503
+ { path: "gallery.items.video.videoInfo.urlExpirationDate" },
504
+ {
505
+ path: "gallery.items.video.videoInfo.resolutions.poster.urlExpirationDate"
506
+ },
507
+ { path: "gallery.items.video.videoInfo.posters.urlExpirationDate" },
508
+ {
509
+ path: "gallery.items.secondaryMedia.image.imageInfo.urlExpirationDate"
510
+ }
511
+ ]
512
+ }
513
+ ]);
514
+ const metadata = {
515
+ entityFqdn: "wix.pro_gallery.v2.gallery",
516
+ method: "PATCH",
517
+ methodFqn: "com.wixpress.exposure.progallery.ProGallery.UpdateGallery",
518
+ packageName: PACKAGE_NAME,
519
+ url: resolveComWixpressExposureProgalleryProGalleryUrl({
520
+ protoPath: "/v2/galleries/{gallery.id}",
521
+ data: serializedData,
522
+ host
523
+ }),
524
+ data: serializedData,
525
+ transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
526
+ {
527
+ transformFn: import_float2.transformRESTFloatToSDKFloat,
528
+ paths: [
529
+ { path: "gallery.sortOrder" },
530
+ { path: "gallery.items.sortOrder" },
531
+ { path: "gallery.items.image.focalPoint.x" },
532
+ { path: "gallery.items.image.focalPoint.y" },
533
+ { path: "gallery.items.secondaryMedia.image.focalPoint.x" },
534
+ { path: "gallery.items.secondaryMedia.image.focalPoint.y" },
535
+ { path: "gallery.items.image.unsharpMasking.amount" },
536
+ { path: "gallery.items.image.unsharpMasking.radius" },
537
+ { path: "gallery.items.image.unsharpMasking.threshold" },
538
+ {
539
+ path: "gallery.items.secondaryMedia.image.unsharpMasking.amount"
540
+ },
541
+ {
542
+ path: "gallery.items.secondaryMedia.image.unsharpMasking.radius"
543
+ },
544
+ {
545
+ path: "gallery.items.secondaryMedia.image.unsharpMasking.threshold"
546
+ }
547
+ ]
548
+ },
549
+ {
550
+ transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
551
+ paths: [
552
+ { path: "gallery.createdDate" },
553
+ { path: "gallery.items.createdDate" },
554
+ { path: "gallery.items.updatedDate" },
555
+ { path: "gallery.items.image.imageInfo.urlExpirationDate" },
556
+ { path: "gallery.items.video.videoInfo.urlExpirationDate" },
557
+ {
558
+ path: "gallery.items.video.videoInfo.resolutions.poster.urlExpirationDate"
559
+ },
560
+ {
561
+ path: "gallery.items.video.videoInfo.posters.urlExpirationDate"
562
+ },
563
+ {
564
+ path: "gallery.items.secondaryMedia.image.imageInfo.urlExpirationDate"
565
+ }
566
+ ]
567
+ }
568
+ ])
569
+ };
570
+ return metadata;
571
+ }
572
+ return __updateGallery;
573
+ }
574
+ function deleteGallery(payload) {
575
+ function __deleteGallery({ host }) {
576
+ const metadata = {
577
+ entityFqdn: "wix.pro_gallery.v2.gallery",
578
+ method: "DELETE",
579
+ methodFqn: "com.wixpress.exposure.progallery.ProGallery.DeleteGallery",
580
+ packageName: PACKAGE_NAME,
581
+ url: resolveComWixpressExposureProgalleryProGalleryUrl({
582
+ protoPath: "/v2/galleries/{galleryId}",
583
+ data: payload,
584
+ host
585
+ }),
586
+ params: (0, import_rest_modules.toURLSearchParams)(payload)
587
+ };
588
+ return metadata;
589
+ }
590
+ return __deleteGallery;
591
+ }
592
+ function deleteGalleryItems(payload) {
593
+ function __deleteGalleryItems({ host }) {
594
+ const metadata = {
595
+ entityFqdn: "wix.pro_gallery.v2.gallery",
596
+ method: "DELETE",
597
+ methodFqn: "com.wixpress.exposure.progallery.ProGallery.DeleteGalleryItems",
598
+ packageName: PACKAGE_NAME,
599
+ url: resolveComWixpressExposureProgalleryProGalleryUrl({
600
+ protoPath: "/v2/galleries/{galleryId}/items",
601
+ data: payload,
602
+ host
603
+ }),
604
+ params: (0, import_rest_modules.toURLSearchParams)(payload),
605
+ transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
606
+ {
607
+ transformFn: import_float2.transformRESTFloatToSDKFloat,
608
+ paths: [
609
+ { path: "gallery.sortOrder" },
610
+ { path: "gallery.items.sortOrder" },
611
+ { path: "gallery.items.image.focalPoint.x" },
612
+ { path: "gallery.items.image.focalPoint.y" },
613
+ { path: "gallery.items.secondaryMedia.image.focalPoint.x" },
614
+ { path: "gallery.items.secondaryMedia.image.focalPoint.y" },
615
+ { path: "gallery.items.image.unsharpMasking.amount" },
616
+ { path: "gallery.items.image.unsharpMasking.radius" },
617
+ { path: "gallery.items.image.unsharpMasking.threshold" },
618
+ {
619
+ path: "gallery.items.secondaryMedia.image.unsharpMasking.amount"
620
+ },
621
+ {
622
+ path: "gallery.items.secondaryMedia.image.unsharpMasking.radius"
623
+ },
624
+ {
625
+ path: "gallery.items.secondaryMedia.image.unsharpMasking.threshold"
626
+ }
627
+ ]
628
+ },
629
+ {
630
+ transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
631
+ paths: [
632
+ { path: "gallery.createdDate" },
633
+ { path: "gallery.items.createdDate" },
634
+ { path: "gallery.items.updatedDate" },
635
+ { path: "gallery.items.image.imageInfo.urlExpirationDate" },
636
+ { path: "gallery.items.video.videoInfo.urlExpirationDate" },
637
+ {
638
+ path: "gallery.items.video.videoInfo.resolutions.poster.urlExpirationDate"
639
+ },
640
+ {
641
+ path: "gallery.items.video.videoInfo.posters.urlExpirationDate"
642
+ },
643
+ {
644
+ path: "gallery.items.secondaryMedia.image.imageInfo.urlExpirationDate"
645
+ }
646
+ ]
647
+ }
648
+ ])
649
+ };
650
+ return metadata;
651
+ }
652
+ return __deleteGalleryItems;
653
+ }
654
+ function bulkDeleteGalleryItems(payload) {
655
+ function __bulkDeleteGalleryItems({ host }) {
656
+ const metadata = {
657
+ entityFqdn: "wix.pro_gallery.v2.gallery",
658
+ method: "POST",
659
+ methodFqn: "com.wixpress.exposure.progallery.ProGallery.BulkDeleteGalleryItems",
660
+ packageName: PACKAGE_NAME,
661
+ url: resolveComWixpressExposureProgalleryProGalleryUrl({
662
+ protoPath: "/v2/galleries/{galleryId}/items/delete",
663
+ data: payload,
664
+ host
665
+ }),
666
+ data: payload
667
+ };
668
+ return metadata;
669
+ }
670
+ return __bulkDeleteGalleryItems;
671
+ }
672
+ function createGalleryItem(payload) {
673
+ function __createGalleryItem({ host }) {
674
+ const serializedData = (0, import_transform_paths.transformPaths)(payload, [
675
+ {
676
+ transformFn: import_float.transformSDKFloatToRESTFloat,
677
+ paths: [
678
+ { path: "item.sortOrder" },
679
+ { path: "item.image.focalPoint.x" },
680
+ { path: "item.image.focalPoint.y" },
681
+ { path: "item.secondaryMedia.image.focalPoint.x" },
682
+ { path: "item.secondaryMedia.image.focalPoint.y" },
683
+ { path: "item.image.unsharpMasking.amount" },
684
+ { path: "item.image.unsharpMasking.radius" },
685
+ { path: "item.image.unsharpMasking.threshold" },
686
+ { path: "item.secondaryMedia.image.unsharpMasking.amount" },
687
+ { path: "item.secondaryMedia.image.unsharpMasking.radius" },
688
+ { path: "item.secondaryMedia.image.unsharpMasking.threshold" }
689
+ ]
690
+ },
691
+ {
692
+ transformFn: import_timestamp.transformSDKTimestampToRESTTimestamp,
693
+ paths: [
694
+ { path: "item.createdDate" },
695
+ { path: "item.updatedDate" },
696
+ { path: "item.image.imageInfo.urlExpirationDate" },
697
+ { path: "item.video.videoInfo.urlExpirationDate" },
698
+ { path: "item.video.videoInfo.resolutions.poster.urlExpirationDate" },
699
+ { path: "item.video.videoInfo.posters.urlExpirationDate" },
700
+ { path: "item.secondaryMedia.image.imageInfo.urlExpirationDate" }
701
+ ]
702
+ }
703
+ ]);
704
+ const metadata = {
705
+ entityFqdn: "wix.pro_gallery.v2.gallery",
706
+ method: "POST",
707
+ methodFqn: "com.wixpress.exposure.progallery.ProGallery.CreateGalleryItem",
708
+ packageName: PACKAGE_NAME,
709
+ url: resolveComWixpressExposureProgalleryProGalleryUrl({
710
+ protoPath: "/v2/galleries/{galleryId}/items",
711
+ data: serializedData,
712
+ host
713
+ }),
714
+ data: serializedData,
715
+ transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
716
+ {
717
+ transformFn: import_float2.transformRESTFloatToSDKFloat,
718
+ paths: [
719
+ { path: "item.sortOrder" },
720
+ { path: "item.image.focalPoint.x" },
721
+ { path: "item.image.focalPoint.y" },
722
+ { path: "item.secondaryMedia.image.focalPoint.x" },
723
+ { path: "item.secondaryMedia.image.focalPoint.y" },
724
+ { path: "item.image.unsharpMasking.amount" },
725
+ { path: "item.image.unsharpMasking.radius" },
726
+ { path: "item.image.unsharpMasking.threshold" },
727
+ { path: "item.secondaryMedia.image.unsharpMasking.amount" },
728
+ { path: "item.secondaryMedia.image.unsharpMasking.radius" },
729
+ { path: "item.secondaryMedia.image.unsharpMasking.threshold" }
730
+ ]
731
+ },
732
+ {
733
+ transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
734
+ paths: [
735
+ { path: "item.createdDate" },
736
+ { path: "item.updatedDate" },
737
+ { path: "item.image.imageInfo.urlExpirationDate" },
738
+ { path: "item.video.videoInfo.urlExpirationDate" },
739
+ {
740
+ path: "item.video.videoInfo.resolutions.poster.urlExpirationDate"
741
+ },
742
+ { path: "item.video.videoInfo.posters.urlExpirationDate" },
743
+ { path: "item.secondaryMedia.image.imageInfo.urlExpirationDate" }
744
+ ]
745
+ }
746
+ ])
747
+ };
748
+ return metadata;
749
+ }
750
+ return __createGalleryItem;
751
+ }
752
+ function updateGalleryItem(payload) {
753
+ function __updateGalleryItem({ host }) {
754
+ const serializedData = (0, import_transform_paths.transformPaths)(payload, [
755
+ {
756
+ transformFn: import_float.transformSDKFloatToRESTFloat,
757
+ paths: [
758
+ { path: "item.sortOrder" },
759
+ { path: "item.image.focalPoint.x" },
760
+ { path: "item.image.focalPoint.y" },
761
+ { path: "item.secondaryMedia.image.focalPoint.x" },
762
+ { path: "item.secondaryMedia.image.focalPoint.y" },
763
+ { path: "item.image.unsharpMasking.amount" },
764
+ { path: "item.image.unsharpMasking.radius" },
765
+ { path: "item.image.unsharpMasking.threshold" },
766
+ { path: "item.secondaryMedia.image.unsharpMasking.amount" },
767
+ { path: "item.secondaryMedia.image.unsharpMasking.radius" },
768
+ { path: "item.secondaryMedia.image.unsharpMasking.threshold" }
769
+ ]
770
+ },
771
+ {
772
+ transformFn: import_timestamp.transformSDKTimestampToRESTTimestamp,
773
+ paths: [
774
+ { path: "item.createdDate" },
775
+ { path: "item.updatedDate" },
776
+ { path: "item.image.imageInfo.urlExpirationDate" },
777
+ { path: "item.video.videoInfo.urlExpirationDate" },
778
+ { path: "item.video.videoInfo.resolutions.poster.urlExpirationDate" },
779
+ { path: "item.video.videoInfo.posters.urlExpirationDate" },
780
+ { path: "item.secondaryMedia.image.imageInfo.urlExpirationDate" }
781
+ ]
782
+ }
783
+ ]);
784
+ const metadata = {
785
+ entityFqdn: "wix.pro_gallery.v2.gallery",
786
+ method: "PATCH",
787
+ methodFqn: "com.wixpress.exposure.progallery.ProGallery.UpdateGalleryItem",
788
+ packageName: PACKAGE_NAME,
789
+ url: resolveComWixpressExposureProgalleryProGalleryUrl({
790
+ protoPath: "/v2/galleries/{galleryId}/items/{item.id}",
791
+ data: serializedData,
792
+ host
793
+ }),
794
+ data: serializedData,
795
+ transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
796
+ {
797
+ transformFn: import_float2.transformRESTFloatToSDKFloat,
798
+ paths: [
799
+ { path: "item.sortOrder" },
800
+ { path: "item.image.focalPoint.x" },
801
+ { path: "item.image.focalPoint.y" },
802
+ { path: "item.secondaryMedia.image.focalPoint.x" },
803
+ { path: "item.secondaryMedia.image.focalPoint.y" },
804
+ { path: "item.image.unsharpMasking.amount" },
805
+ { path: "item.image.unsharpMasking.radius" },
806
+ { path: "item.image.unsharpMasking.threshold" },
807
+ { path: "item.secondaryMedia.image.unsharpMasking.amount" },
808
+ { path: "item.secondaryMedia.image.unsharpMasking.radius" },
809
+ { path: "item.secondaryMedia.image.unsharpMasking.threshold" }
810
+ ]
811
+ },
812
+ {
813
+ transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
814
+ paths: [
815
+ { path: "item.createdDate" },
816
+ { path: "item.updatedDate" },
817
+ { path: "item.image.imageInfo.urlExpirationDate" },
818
+ { path: "item.video.videoInfo.urlExpirationDate" },
819
+ {
820
+ path: "item.video.videoInfo.resolutions.poster.urlExpirationDate"
821
+ },
822
+ { path: "item.video.videoInfo.posters.urlExpirationDate" },
823
+ { path: "item.secondaryMedia.image.imageInfo.urlExpirationDate" }
824
+ ]
825
+ }
826
+ ])
827
+ };
828
+ return metadata;
829
+ }
830
+ return __updateGalleryItem;
831
+ }
832
+ function deleteGalleryItem(payload) {
833
+ function __deleteGalleryItem({ host }) {
834
+ const metadata = {
835
+ entityFqdn: "wix.pro_gallery.v2.gallery",
836
+ method: "DELETE",
837
+ methodFqn: "com.wixpress.exposure.progallery.ProGallery.DeleteGalleryItem",
838
+ packageName: PACKAGE_NAME,
839
+ url: resolveComWixpressExposureProgalleryProGalleryUrl({
840
+ protoPath: "/v2/galleries/{galleryId}/items/{itemId}",
841
+ data: payload,
842
+ host
843
+ }),
844
+ params: (0, import_rest_modules.toURLSearchParams)(payload)
845
+ };
846
+ return metadata;
847
+ }
848
+ return __deleteGalleryItem;
849
+ }
850
+
851
+ // src/pro-gallery-v2-gallery-pro-gallery.universal.ts
852
+ var import_image = require("@wix/sdk-runtime/transformations/image");
853
+ var import_image2 = require("@wix/sdk-runtime/transformations/image");
854
+ var import_video_v2 = require("@wix/sdk-runtime/transformations/video-v2");
855
+ var import_video_v22 = require("@wix/sdk-runtime/transformations/video-v2");
856
+ var import_transform_paths2 = require("@wix/sdk-runtime/transformations/transform-paths");
857
+ var LinkType = /* @__PURE__ */ ((LinkType2) => {
858
+ LinkType2["UNDEFINED"] = "UNDEFINED";
859
+ LinkType2["EXTERNAL"] = "EXTERNAL";
860
+ LinkType2["INTERNAL"] = "INTERNAL";
861
+ return LinkType2;
862
+ })(LinkType || {});
863
+ var LinkRel = /* @__PURE__ */ ((LinkRel2) => {
864
+ LinkRel2["unknown_link_rel"] = "unknown_link_rel";
865
+ LinkRel2["nofollow"] = "nofollow";
866
+ LinkRel2["noopener"] = "noopener";
867
+ LinkRel2["noreferrer"] = "noreferrer";
868
+ LinkRel2["sponsored"] = "sponsored";
869
+ return LinkRel2;
870
+ })(LinkRel || {});
871
+ var Type = /* @__PURE__ */ ((Type2) => {
872
+ Type2["UNDEFINED"] = "UNDEFINED";
873
+ Type2["IMAGE"] = "IMAGE";
874
+ Type2["VIDEO"] = "VIDEO";
875
+ Type2["TEXT"] = "TEXT";
876
+ return Type2;
877
+ })(Type || {});
878
+ var ImageType = /* @__PURE__ */ ((ImageType2) => {
879
+ ImageType2["UNDEFINED"] = "UNDEFINED";
880
+ ImageType2["WIX_MEDIA"] = "WIX_MEDIA";
881
+ ImageType2["EXTERNAL"] = "EXTERNAL";
882
+ return ImageType2;
883
+ })(ImageType || {});
884
+ var VideoType = /* @__PURE__ */ ((VideoType2) => {
885
+ VideoType2["UNDEFINED"] = "UNDEFINED";
886
+ VideoType2["WIX_MEDIA"] = "WIX_MEDIA";
887
+ VideoType2["YOUTUBE"] = "YOUTUBE";
888
+ VideoType2["VIMEO"] = "VIMEO";
889
+ return VideoType2;
890
+ })(VideoType || {});
891
+ var RCLabel = /* @__PURE__ */ ((RCLabel2) => {
892
+ RCLabel2["UNKNOWN"] = "UNKNOWN";
893
+ RCLabel2["RELEASE_MANAGER"] = "RELEASE_MANAGER";
894
+ RCLabel2["BLOCKS"] = "BLOCKS";
895
+ RCLabel2["WIX_CLI"] = "WIX_CLI";
896
+ RCLabel2["MOBILE_APP_BUILDER"] = "MOBILE_APP_BUILDER";
897
+ RCLabel2["SEO"] = "SEO";
898
+ RCLabel2["FEEDBACK"] = "FEEDBACK";
899
+ RCLabel2["ACCESSIBILITY"] = "ACCESSIBILITY";
900
+ return RCLabel2;
901
+ })(RCLabel || {});
902
+ var WebhookIdentityType = /* @__PURE__ */ ((WebhookIdentityType2) => {
903
+ WebhookIdentityType2["UNKNOWN"] = "UNKNOWN";
904
+ WebhookIdentityType2["ANONYMOUS_VISITOR"] = "ANONYMOUS_VISITOR";
905
+ WebhookIdentityType2["MEMBER"] = "MEMBER";
906
+ WebhookIdentityType2["WIX_USER"] = "WIX_USER";
907
+ WebhookIdentityType2["APP"] = "APP";
908
+ return WebhookIdentityType2;
909
+ })(WebhookIdentityType || {});
910
+ var State = /* @__PURE__ */ ((State2) => {
911
+ State2["UNDEFINED"] = "UNDEFINED";
912
+ State2["SAVED"] = "SAVED";
913
+ State2["PUBLISHED"] = "PUBLISHED";
914
+ return State2;
915
+ })(State || {});
916
+ var Enum = /* @__PURE__ */ ((Enum2) => {
917
+ Enum2["UNKNOWN"] = "UNKNOWN";
918
+ Enum2["PROTECTED"] = "PROTECTED";
919
+ Enum2["PRIVATE"] = "PRIVATE";
920
+ Enum2["PUBLIC"] = "PUBLIC";
921
+ Enum2["UNCHANGED"] = "UNCHANGED";
922
+ Enum2["GROUP_PROTECTED"] = "GROUP_PROTECTED";
923
+ return Enum2;
924
+ })(Enum || {});
925
+ var SearchIndexingNotificationState = /* @__PURE__ */ ((SearchIndexingNotificationState2) => {
926
+ SearchIndexingNotificationState2["Unknown"] = "Unknown";
927
+ SearchIndexingNotificationState2["Off"] = "Off";
928
+ SearchIndexingNotificationState2["On"] = "On";
929
+ return SearchIndexingNotificationState2;
930
+ })(SearchIndexingNotificationState || {});
931
+ async function listGalleries2(options) {
932
+ const { httpClient, sideEffects } = arguments[1];
933
+ const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
934
+ itemLimit: options?.itemLimit,
935
+ offset: options?.offset,
936
+ limit: options?.limit
937
+ });
938
+ const reqOpts = listGalleries(payload);
939
+ sideEffects?.onSiteCall?.();
940
+ try {
941
+ const result = await httpClient.request(reqOpts);
942
+ sideEffects?.onSuccess?.(result);
943
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
944
+ (0, import_transform_paths2.transformPaths)(result.data, [
945
+ {
946
+ transformFn: import_image2.transformRESTImageToSDKImage,
947
+ paths: [
948
+ { path: "galleries.items.image.imageInfo" },
949
+ { path: "galleries.items.secondaryMedia.image.imageInfo" }
950
+ ]
951
+ },
952
+ {
953
+ transformFn: import_video_v22.transformRESTVideoV2ToSDKVideoV2,
954
+ paths: [{ path: "galleries.items.video.videoInfo" }]
955
+ }
956
+ ])
957
+ );
958
+ } catch (err) {
959
+ const transformedError = (0, import_transform_error.transformError)(
960
+ err,
961
+ {
962
+ spreadPathsToArguments: {},
963
+ explicitPathsToArguments: {
964
+ itemLimit: "$[0].itemLimit",
965
+ offset: "$[0].offset",
966
+ limit: "$[0].limit"
967
+ },
968
+ singleArgumentUnchanged: false
969
+ },
970
+ ["options"]
971
+ );
972
+ sideEffects?.onError?.(err);
973
+ throw transformedError;
974
+ }
975
+ }
976
+ async function getGallery2(galleryId, options) {
977
+ const { httpClient, sideEffects } = arguments[2];
978
+ const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
979
+ galleryId,
980
+ itemOffset: options?.itemOffset,
981
+ itemLimit: options?.itemLimit
982
+ });
983
+ const reqOpts = getGallery(payload);
984
+ sideEffects?.onSiteCall?.();
985
+ try {
986
+ const result = await httpClient.request(reqOpts);
987
+ sideEffects?.onSuccess?.(result);
988
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
989
+ (0, import_transform_paths2.transformPaths)(result.data, [
990
+ {
991
+ transformFn: import_image2.transformRESTImageToSDKImage,
992
+ paths: [
993
+ { path: "gallery.items.image.imageInfo" },
994
+ { path: "gallery.items.secondaryMedia.image.imageInfo" }
995
+ ]
996
+ },
997
+ {
998
+ transformFn: import_video_v22.transformRESTVideoV2ToSDKVideoV2,
999
+ paths: [{ path: "gallery.items.video.videoInfo" }]
1000
+ }
1001
+ ])
1002
+ )?.gallery;
1003
+ } catch (err) {
1004
+ const transformedError = (0, import_transform_error.transformError)(
1005
+ err,
1006
+ {
1007
+ spreadPathsToArguments: {},
1008
+ explicitPathsToArguments: {
1009
+ galleryId: "$[0]",
1010
+ itemOffset: "$[1].itemOffset",
1011
+ itemLimit: "$[1].itemLimit"
1012
+ },
1013
+ singleArgumentUnchanged: false
1014
+ },
1015
+ ["galleryId", "options"]
1016
+ );
1017
+ sideEffects?.onError?.(err);
1018
+ throw transformedError;
1019
+ }
1020
+ }
1021
+ async function listGalleryItems2(galleryId, options) {
1022
+ const { httpClient, sideEffects } = arguments[2];
1023
+ const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
1024
+ galleryId,
1025
+ itemOffset: options?.itemOffset,
1026
+ itemLimit: options?.itemLimit
1027
+ });
1028
+ const reqOpts = listGalleryItems(payload);
1029
+ sideEffects?.onSiteCall?.();
1030
+ try {
1031
+ const result = await httpClient.request(reqOpts);
1032
+ sideEffects?.onSuccess?.(result);
1033
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
1034
+ (0, import_transform_paths2.transformPaths)(result.data, [
1035
+ {
1036
+ transformFn: import_image2.transformRESTImageToSDKImage,
1037
+ paths: [
1038
+ { path: "items.image.imageInfo" },
1039
+ { path: "items.secondaryMedia.image.imageInfo" }
1040
+ ]
1041
+ },
1042
+ {
1043
+ transformFn: import_video_v22.transformRESTVideoV2ToSDKVideoV2,
1044
+ paths: [{ path: "items.video.videoInfo" }]
1045
+ }
1046
+ ])
1047
+ );
1048
+ } catch (err) {
1049
+ const transformedError = (0, import_transform_error.transformError)(
1050
+ err,
1051
+ {
1052
+ spreadPathsToArguments: {},
1053
+ explicitPathsToArguments: {
1054
+ galleryId: "$[0]",
1055
+ itemOffset: "$[1].itemOffset",
1056
+ itemLimit: "$[1].itemLimit"
1057
+ },
1058
+ singleArgumentUnchanged: false
1059
+ },
1060
+ ["galleryId", "options"]
1061
+ );
1062
+ sideEffects?.onError?.(err);
1063
+ throw transformedError;
1064
+ }
1065
+ }
1066
+ async function getGalleryItem2(identifiers) {
1067
+ const { httpClient, sideEffects } = arguments[1];
1068
+ const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
1069
+ galleryId: identifiers?.galleryId,
1070
+ itemId: identifiers?.itemId
1071
+ });
1072
+ const reqOpts = getGalleryItem(payload);
1073
+ sideEffects?.onSiteCall?.();
1074
+ try {
1075
+ const result = await httpClient.request(reqOpts);
1076
+ sideEffects?.onSuccess?.(result);
1077
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
1078
+ (0, import_transform_paths2.transformPaths)(result.data, [
1079
+ {
1080
+ transformFn: import_image2.transformRESTImageToSDKImage,
1081
+ paths: [
1082
+ { path: "item.image.imageInfo" },
1083
+ { path: "item.secondaryMedia.image.imageInfo" }
1084
+ ]
1085
+ },
1086
+ {
1087
+ transformFn: import_video_v22.transformRESTVideoV2ToSDKVideoV2,
1088
+ paths: [{ path: "item.video.videoInfo" }]
1089
+ }
1090
+ ])
1091
+ )?.item;
1092
+ } catch (err) {
1093
+ const transformedError = (0, import_transform_error.transformError)(
1094
+ err,
1095
+ {
1096
+ spreadPathsToArguments: {},
1097
+ explicitPathsToArguments: {
1098
+ galleryId: "$[0].galleryId",
1099
+ itemId: "$[0].itemId"
1100
+ },
1101
+ singleArgumentUnchanged: false
1102
+ },
1103
+ ["identifiers"]
1104
+ );
1105
+ sideEffects?.onError?.(err);
1106
+ throw transformedError;
1107
+ }
1108
+ }
1109
+ async function createGallery2(options) {
1110
+ const { httpClient, sideEffects } = arguments[1];
1111
+ const payload = (0, import_transform_paths2.transformPaths)(
1112
+ (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
1113
+ gallery: options?.gallery,
1114
+ cloneFromGalleryId: options?.cloneFromGalleryId
1115
+ }),
1116
+ [
1117
+ {
1118
+ transformFn: import_image.transformSDKImageToRESTImage,
1119
+ paths: [
1120
+ { path: "gallery.items.image.imageInfo" },
1121
+ { path: "gallery.items.secondaryMedia.image.imageInfo" }
1122
+ ]
1123
+ },
1124
+ {
1125
+ transformFn: import_video_v2.transformSDKVideoV2ToRESTVideoV2,
1126
+ paths: [{ path: "gallery.items.video.videoInfo" }]
1127
+ }
1128
+ ]
1129
+ );
1130
+ const reqOpts = createGallery(payload);
1131
+ sideEffects?.onSiteCall?.();
1132
+ try {
1133
+ const result = await httpClient.request(reqOpts);
1134
+ sideEffects?.onSuccess?.(result);
1135
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
1136
+ (0, import_transform_paths2.transformPaths)(result.data, [
1137
+ {
1138
+ transformFn: import_image2.transformRESTImageToSDKImage,
1139
+ paths: [
1140
+ { path: "gallery.items.image.imageInfo" },
1141
+ { path: "gallery.items.secondaryMedia.image.imageInfo" }
1142
+ ]
1143
+ },
1144
+ {
1145
+ transformFn: import_video_v22.transformRESTVideoV2ToSDKVideoV2,
1146
+ paths: [{ path: "gallery.items.video.videoInfo" }]
1147
+ }
1148
+ ])
1149
+ )?.gallery;
1150
+ } catch (err) {
1151
+ const transformedError = (0, import_transform_error.transformError)(
1152
+ err,
1153
+ {
1154
+ spreadPathsToArguments: {},
1155
+ explicitPathsToArguments: {
1156
+ gallery: "$[0].gallery",
1157
+ cloneFromGalleryId: "$[0].cloneFromGalleryId"
1158
+ },
1159
+ singleArgumentUnchanged: false
1160
+ },
1161
+ ["options"]
1162
+ );
1163
+ sideEffects?.onError?.(err);
1164
+ throw transformedError;
1165
+ }
1166
+ }
1167
+ async function updateGallery2(_id, gallery) {
1168
+ const { httpClient, sideEffects } = arguments[2];
1169
+ const payload = (0, import_transform_paths2.transformPaths)(
1170
+ (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({ gallery: { ...gallery, id: _id } }),
1171
+ [
1172
+ {
1173
+ transformFn: import_image.transformSDKImageToRESTImage,
1174
+ paths: [
1175
+ { path: "gallery.items.image.imageInfo" },
1176
+ { path: "gallery.items.secondaryMedia.image.imageInfo" }
1177
+ ]
1178
+ },
1179
+ {
1180
+ transformFn: import_video_v2.transformSDKVideoV2ToRESTVideoV2,
1181
+ paths: [{ path: "gallery.items.video.videoInfo" }]
1182
+ }
1183
+ ]
1184
+ );
1185
+ const reqOpts = updateGallery(payload);
1186
+ sideEffects?.onSiteCall?.();
1187
+ try {
1188
+ const result = await httpClient.request(reqOpts);
1189
+ sideEffects?.onSuccess?.(result);
1190
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
1191
+ (0, import_transform_paths2.transformPaths)(result.data, [
1192
+ {
1193
+ transformFn: import_image2.transformRESTImageToSDKImage,
1194
+ paths: [
1195
+ { path: "gallery.items.image.imageInfo" },
1196
+ { path: "gallery.items.secondaryMedia.image.imageInfo" }
1197
+ ]
1198
+ },
1199
+ {
1200
+ transformFn: import_video_v22.transformRESTVideoV2ToSDKVideoV2,
1201
+ paths: [{ path: "gallery.items.video.videoInfo" }]
1202
+ }
1203
+ ])
1204
+ )?.gallery;
1205
+ } catch (err) {
1206
+ const transformedError = (0, import_transform_error.transformError)(
1207
+ err,
1208
+ {
1209
+ spreadPathsToArguments: { gallery: "$[1]" },
1210
+ explicitPathsToArguments: { "gallery.id": "$[0]" },
1211
+ singleArgumentUnchanged: false
1212
+ },
1213
+ ["_id", "gallery"]
1214
+ );
1215
+ sideEffects?.onError?.(err);
1216
+ throw transformedError;
1217
+ }
1218
+ }
1219
+ async function deleteGallery2(galleryId) {
1220
+ const { httpClient, sideEffects } = arguments[1];
1221
+ const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
1222
+ galleryId
1223
+ });
1224
+ const reqOpts = deleteGallery(payload);
1225
+ sideEffects?.onSiteCall?.();
1226
+ try {
1227
+ const result = await httpClient.request(reqOpts);
1228
+ sideEffects?.onSuccess?.(result);
1229
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(result.data);
1230
+ } catch (err) {
1231
+ const transformedError = (0, import_transform_error.transformError)(
1232
+ err,
1233
+ {
1234
+ spreadPathsToArguments: {},
1235
+ explicitPathsToArguments: { galleryId: "$[0]" },
1236
+ singleArgumentUnchanged: false
1237
+ },
1238
+ ["galleryId"]
1239
+ );
1240
+ sideEffects?.onError?.(err);
1241
+ throw transformedError;
1242
+ }
1243
+ }
1244
+ async function deleteGalleryItems2(galleryId, options) {
1245
+ const { httpClient, sideEffects } = arguments[2];
1246
+ const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
1247
+ galleryId,
1248
+ itemsIds: options?.itemsIds
1249
+ });
1250
+ const reqOpts = deleteGalleryItems(payload);
1251
+ sideEffects?.onSiteCall?.();
1252
+ try {
1253
+ const result = await httpClient.request(reqOpts);
1254
+ sideEffects?.onSuccess?.(result);
1255
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
1256
+ (0, import_transform_paths2.transformPaths)(result.data, [
1257
+ {
1258
+ transformFn: import_image2.transformRESTImageToSDKImage,
1259
+ paths: [
1260
+ { path: "gallery.items.image.imageInfo" },
1261
+ { path: "gallery.items.secondaryMedia.image.imageInfo" }
1262
+ ]
1263
+ },
1264
+ {
1265
+ transformFn: import_video_v22.transformRESTVideoV2ToSDKVideoV2,
1266
+ paths: [{ path: "gallery.items.video.videoInfo" }]
1267
+ }
1268
+ ])
1269
+ );
1270
+ } catch (err) {
1271
+ const transformedError = (0, import_transform_error.transformError)(
1272
+ err,
1273
+ {
1274
+ spreadPathsToArguments: {},
1275
+ explicitPathsToArguments: {
1276
+ galleryId: "$[0]",
1277
+ itemsIds: "$[1].itemsIds"
1278
+ },
1279
+ singleArgumentUnchanged: false
1280
+ },
1281
+ ["galleryId", "options"]
1282
+ );
1283
+ sideEffects?.onError?.(err);
1284
+ throw transformedError;
1285
+ }
1286
+ }
1287
+ async function bulkDeleteGalleryItems2(galleryId, itemIds) {
1288
+ const { httpClient, sideEffects } = arguments[2];
1289
+ const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
1290
+ galleryId,
1291
+ itemIds
1292
+ });
1293
+ const reqOpts = bulkDeleteGalleryItems(payload);
1294
+ sideEffects?.onSiteCall?.();
1295
+ try {
1296
+ const result = await httpClient.request(reqOpts);
1297
+ sideEffects?.onSuccess?.(result);
1298
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(result.data);
1299
+ } catch (err) {
1300
+ const transformedError = (0, import_transform_error.transformError)(
1301
+ err,
1302
+ {
1303
+ spreadPathsToArguments: {},
1304
+ explicitPathsToArguments: { galleryId: "$[0]", itemIds: "$[1]" },
1305
+ singleArgumentUnchanged: false
1306
+ },
1307
+ ["galleryId", "itemIds"]
1308
+ );
1309
+ sideEffects?.onError?.(err);
1310
+ throw transformedError;
1311
+ }
1312
+ }
1313
+ async function createGalleryItem2(galleryId, item) {
1314
+ const { httpClient, sideEffects } = arguments[2];
1315
+ const payload = (0, import_transform_paths2.transformPaths)(
1316
+ (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({ galleryId, item }),
1317
+ [
1318
+ {
1319
+ transformFn: import_image.transformSDKImageToRESTImage,
1320
+ paths: [
1321
+ { path: "item.image.imageInfo" },
1322
+ { path: "item.secondaryMedia.image.imageInfo" }
1323
+ ]
1324
+ },
1325
+ {
1326
+ transformFn: import_video_v2.transformSDKVideoV2ToRESTVideoV2,
1327
+ paths: [{ path: "item.video.videoInfo" }]
1328
+ }
1329
+ ]
1330
+ );
1331
+ const reqOpts = createGalleryItem(payload);
1332
+ sideEffects?.onSiteCall?.();
1333
+ try {
1334
+ const result = await httpClient.request(reqOpts);
1335
+ sideEffects?.onSuccess?.(result);
1336
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
1337
+ (0, import_transform_paths2.transformPaths)(result.data, [
1338
+ {
1339
+ transformFn: import_image2.transformRESTImageToSDKImage,
1340
+ paths: [
1341
+ { path: "item.image.imageInfo" },
1342
+ { path: "item.secondaryMedia.image.imageInfo" }
1343
+ ]
1344
+ },
1345
+ {
1346
+ transformFn: import_video_v22.transformRESTVideoV2ToSDKVideoV2,
1347
+ paths: [{ path: "item.video.videoInfo" }]
1348
+ }
1349
+ ])
1350
+ )?.item;
1351
+ } catch (err) {
1352
+ const transformedError = (0, import_transform_error.transformError)(
1353
+ err,
1354
+ {
1355
+ spreadPathsToArguments: {},
1356
+ explicitPathsToArguments: { galleryId: "$[0]", item: "$[1]" },
1357
+ singleArgumentUnchanged: false
1358
+ },
1359
+ ["galleryId", "item"]
1360
+ );
1361
+ sideEffects?.onError?.(err);
1362
+ throw transformedError;
1363
+ }
1364
+ }
1365
+ async function updateGalleryItem2(identifiers, item) {
1366
+ const { httpClient, sideEffects } = arguments[2];
1367
+ const payload = (0, import_transform_paths2.transformPaths)(
1368
+ (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
1369
+ galleryId: identifiers?.galleryId,
1370
+ item: { ...item, id: identifiers?.itemId }
1371
+ }),
1372
+ [
1373
+ {
1374
+ transformFn: import_image.transformSDKImageToRESTImage,
1375
+ paths: [
1376
+ { path: "item.image.imageInfo" },
1377
+ { path: "item.secondaryMedia.image.imageInfo" }
1378
+ ]
1379
+ },
1380
+ {
1381
+ transformFn: import_video_v2.transformSDKVideoV2ToRESTVideoV2,
1382
+ paths: [{ path: "item.video.videoInfo" }]
1383
+ }
1384
+ ]
1385
+ );
1386
+ const reqOpts = updateGalleryItem(payload);
1387
+ sideEffects?.onSiteCall?.();
1388
+ try {
1389
+ const result = await httpClient.request(reqOpts);
1390
+ sideEffects?.onSuccess?.(result);
1391
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
1392
+ (0, import_transform_paths2.transformPaths)(result.data, [
1393
+ {
1394
+ transformFn: import_image2.transformRESTImageToSDKImage,
1395
+ paths: [
1396
+ { path: "item.image.imageInfo" },
1397
+ { path: "item.secondaryMedia.image.imageInfo" }
1398
+ ]
1399
+ },
1400
+ {
1401
+ transformFn: import_video_v22.transformRESTVideoV2ToSDKVideoV2,
1402
+ paths: [{ path: "item.video.videoInfo" }]
1403
+ }
1404
+ ])
1405
+ )?.item;
1406
+ } catch (err) {
1407
+ const transformedError = (0, import_transform_error.transformError)(
1408
+ err,
1409
+ {
1410
+ spreadPathsToArguments: { item: "$[1]" },
1411
+ explicitPathsToArguments: {
1412
+ galleryId: "$[0].galleryId",
1413
+ "item.id": "$[0].itemId"
1414
+ },
1415
+ singleArgumentUnchanged: false
1416
+ },
1417
+ ["identifiers", "item"]
1418
+ );
1419
+ sideEffects?.onError?.(err);
1420
+ throw transformedError;
1421
+ }
1422
+ }
1423
+ async function deleteGalleryItem2(identifiers) {
1424
+ const { httpClient, sideEffects } = arguments[1];
1425
+ const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
1426
+ galleryId: identifiers?.galleryId,
1427
+ itemId: identifiers?.itemId
1428
+ });
1429
+ const reqOpts = deleteGalleryItem(payload);
1430
+ sideEffects?.onSiteCall?.();
1431
+ try {
1432
+ const result = await httpClient.request(reqOpts);
1433
+ sideEffects?.onSuccess?.(result);
1434
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(result.data);
1435
+ } catch (err) {
1436
+ const transformedError = (0, import_transform_error.transformError)(
1437
+ err,
1438
+ {
1439
+ spreadPathsToArguments: {},
1440
+ explicitPathsToArguments: {
1441
+ galleryId: "$[0].galleryId",
1442
+ itemId: "$[0].itemId"
1443
+ },
1444
+ singleArgumentUnchanged: false
1445
+ },
1446
+ ["identifiers"]
1447
+ );
1448
+ sideEffects?.onError?.(err);
1449
+ throw transformedError;
1450
+ }
1451
+ }
1452
+
1453
+ // src/pro-gallery-v2-gallery-pro-gallery.public.ts
1454
+ function listGalleries3(httpClient) {
1455
+ return (options) => listGalleries2(
1456
+ options,
1457
+ // @ts-ignore
1458
+ { httpClient }
1459
+ );
1460
+ }
1461
+ function getGallery3(httpClient) {
1462
+ return (galleryId, options) => getGallery2(
1463
+ galleryId,
1464
+ options,
1465
+ // @ts-ignore
1466
+ { httpClient }
1467
+ );
1468
+ }
1469
+ function listGalleryItems3(httpClient) {
1470
+ return (galleryId, options) => listGalleryItems2(
1471
+ galleryId,
1472
+ options,
1473
+ // @ts-ignore
1474
+ { httpClient }
1475
+ );
1476
+ }
1477
+ function getGalleryItem3(httpClient) {
1478
+ return (identifiers) => getGalleryItem2(
1479
+ identifiers,
1480
+ // @ts-ignore
1481
+ { httpClient }
1482
+ );
1483
+ }
1484
+ function createGallery3(httpClient) {
1485
+ return (options) => createGallery2(
1486
+ options,
1487
+ // @ts-ignore
1488
+ { httpClient }
1489
+ );
1490
+ }
1491
+ function updateGallery3(httpClient) {
1492
+ return (_id, gallery) => updateGallery2(
1493
+ _id,
1494
+ gallery,
1495
+ // @ts-ignore
1496
+ { httpClient }
1497
+ );
1498
+ }
1499
+ function deleteGallery3(httpClient) {
1500
+ return (galleryId) => deleteGallery2(
1501
+ galleryId,
1502
+ // @ts-ignore
1503
+ { httpClient }
1504
+ );
1505
+ }
1506
+ function deleteGalleryItems3(httpClient) {
1507
+ return (galleryId, options) => deleteGalleryItems2(
1508
+ galleryId,
1509
+ options,
1510
+ // @ts-ignore
1511
+ { httpClient }
1512
+ );
1513
+ }
1514
+ function bulkDeleteGalleryItems3(httpClient) {
1515
+ return (galleryId, itemIds) => bulkDeleteGalleryItems2(
1516
+ galleryId,
1517
+ itemIds,
1518
+ // @ts-ignore
1519
+ { httpClient }
1520
+ );
1521
+ }
1522
+ function createGalleryItem3(httpClient) {
1523
+ return (galleryId, item) => createGalleryItem2(
1524
+ galleryId,
1525
+ item,
1526
+ // @ts-ignore
1527
+ { httpClient }
1528
+ );
1529
+ }
1530
+ function updateGalleryItem3(httpClient) {
1531
+ return (identifiers, item) => updateGalleryItem2(
1532
+ identifiers,
1533
+ item,
1534
+ // @ts-ignore
1535
+ { httpClient }
1536
+ );
1537
+ }
1538
+ function deleteGalleryItem3(httpClient) {
1539
+ return (identifiers) => deleteGalleryItem2(
1540
+ identifiers,
1541
+ // @ts-ignore
1542
+ { httpClient }
1543
+ );
1544
+ }
1545
+ var onGalleryCreated = (0, import_sdk_types.EventDefinition)(
1546
+ "wix.pro_gallery.gallery_v2_created",
1547
+ true,
1548
+ (event) => (0, import_rename_all_nested_keys2.renameKeysFromRESTResponseToSDKResponse)(
1549
+ (0, import_transform_paths3.transformPaths)(event, [
1550
+ {
1551
+ transformFn: import_float3.transformRESTFloatToSDKFloat,
1552
+ paths: [
1553
+ { path: "entity.sortOrder" },
1554
+ { path: "entity.items.sortOrder" },
1555
+ { path: "entity.items.image.focalPoint.x" },
1556
+ { path: "entity.items.image.focalPoint.y" },
1557
+ { path: "entity.items.secondaryMedia.image.focalPoint.x" },
1558
+ { path: "entity.items.secondaryMedia.image.focalPoint.y" },
1559
+ { path: "entity.items.image.unsharpMasking.amount" },
1560
+ { path: "entity.items.image.unsharpMasking.radius" },
1561
+ { path: "entity.items.image.unsharpMasking.threshold" },
1562
+ { path: "entity.items.secondaryMedia.image.unsharpMasking.amount" },
1563
+ { path: "entity.items.secondaryMedia.image.unsharpMasking.radius" },
1564
+ {
1565
+ path: "entity.items.secondaryMedia.image.unsharpMasking.threshold"
1566
+ }
1567
+ ]
1568
+ },
1569
+ {
1570
+ transformFn: import_timestamp3.transformRESTTimestampToSDKTimestamp,
1571
+ paths: [
1572
+ { path: "entity.createdDate" },
1573
+ { path: "entity.items.createdDate" },
1574
+ { path: "entity.items.updatedDate" },
1575
+ { path: "metadata.eventTime" }
1576
+ ]
1577
+ },
1578
+ {
1579
+ transformFn: import_image3.transformRESTImageToSDKImage,
1580
+ paths: [
1581
+ { path: "entity.items.image.imageInfo" },
1582
+ { path: "entity.items.secondaryMedia.image.imageInfo" }
1583
+ ]
1584
+ },
1585
+ {
1586
+ transformFn: import_video_v23.transformRESTVideoV2ToSDKVideoV2,
1587
+ paths: [{ path: "entity.items.video.videoInfo" }]
1588
+ }
1589
+ ])
1590
+ )
1591
+ )();
1592
+ var onGalleryDeleted = (0, import_sdk_types.EventDefinition)(
1593
+ "wix.pro_gallery.gallery_v2_deleted",
1594
+ true,
1595
+ (event) => (0, import_rename_all_nested_keys2.renameKeysFromRESTResponseToSDKResponse)(
1596
+ (0, import_transform_paths3.transformPaths)(event, [
1597
+ {
1598
+ transformFn: import_float3.transformRESTFloatToSDKFloat,
1599
+ paths: [
1600
+ { path: "undefined.sortOrder" },
1601
+ { path: "undefined.items.sortOrder" },
1602
+ { path: "undefined.items.image.focalPoint.x" },
1603
+ { path: "undefined.items.image.focalPoint.y" },
1604
+ { path: "undefined.items.secondaryMedia.image.focalPoint.x" },
1605
+ { path: "undefined.items.secondaryMedia.image.focalPoint.y" },
1606
+ { path: "undefined.items.image.unsharpMasking.amount" },
1607
+ { path: "undefined.items.image.unsharpMasking.radius" },
1608
+ { path: "undefined.items.image.unsharpMasking.threshold" },
1609
+ {
1610
+ path: "undefined.items.secondaryMedia.image.unsharpMasking.amount"
1611
+ },
1612
+ {
1613
+ path: "undefined.items.secondaryMedia.image.unsharpMasking.radius"
1614
+ },
1615
+ {
1616
+ path: "undefined.items.secondaryMedia.image.unsharpMasking.threshold"
1617
+ }
1618
+ ]
1619
+ },
1620
+ {
1621
+ transformFn: import_timestamp3.transformRESTTimestampToSDKTimestamp,
1622
+ paths: [
1623
+ { path: "undefined.createdDate" },
1624
+ { path: "undefined.items.createdDate" },
1625
+ { path: "undefined.items.updatedDate" },
1626
+ { path: "metadata.eventTime" }
1627
+ ]
1628
+ },
1629
+ {
1630
+ transformFn: import_image3.transformRESTImageToSDKImage,
1631
+ paths: [
1632
+ { path: "undefined.items.image.imageInfo" },
1633
+ { path: "undefined.items.secondaryMedia.image.imageInfo" }
1634
+ ]
1635
+ },
1636
+ {
1637
+ transformFn: import_video_v23.transformRESTVideoV2ToSDKVideoV2,
1638
+ paths: [{ path: "undefined.items.video.videoInfo" }]
1639
+ }
1640
+ ])
1641
+ )
1642
+ )();
1643
+ var onGalleryItemCreated = (0, import_sdk_types.EventDefinition)(
1644
+ "wix.pro_gallery.gallery_v2_gallery_item_created",
1645
+ true,
1646
+ (event) => (0, import_rename_all_nested_keys2.renameKeysFromRESTResponseToSDKResponse)(
1647
+ (0, import_transform_paths3.transformPaths)(event, [
1648
+ {
1649
+ transformFn: import_float3.transformRESTFloatToSDKFloat,
1650
+ paths: [
1651
+ { path: "data.item.sortOrder" },
1652
+ { path: "data.item.image.focalPoint.x" },
1653
+ { path: "data.item.image.focalPoint.y" },
1654
+ { path: "data.item.secondaryMedia.image.focalPoint.x" },
1655
+ { path: "data.item.secondaryMedia.image.focalPoint.y" },
1656
+ { path: "data.item.image.unsharpMasking.amount" },
1657
+ { path: "data.item.image.unsharpMasking.radius" },
1658
+ { path: "data.item.image.unsharpMasking.threshold" },
1659
+ { path: "data.item.secondaryMedia.image.unsharpMasking.amount" },
1660
+ { path: "data.item.secondaryMedia.image.unsharpMasking.radius" },
1661
+ { path: "data.item.secondaryMedia.image.unsharpMasking.threshold" }
1662
+ ]
1663
+ },
1664
+ {
1665
+ transformFn: import_timestamp3.transformRESTTimestampToSDKTimestamp,
1666
+ paths: [
1667
+ { path: "data.item.createdDate" },
1668
+ { path: "data.item.updatedDate" },
1669
+ { path: "metadata.eventTime" }
1670
+ ]
1671
+ },
1672
+ {
1673
+ transformFn: import_image3.transformRESTImageToSDKImage,
1674
+ paths: [
1675
+ { path: "data.item.image.imageInfo" },
1676
+ { path: "data.item.secondaryMedia.image.imageInfo" }
1677
+ ]
1678
+ },
1679
+ {
1680
+ transformFn: import_video_v23.transformRESTVideoV2ToSDKVideoV2,
1681
+ paths: [{ path: "data.item.video.videoInfo" }]
1682
+ }
1683
+ ])
1684
+ )
1685
+ )();
1686
+ var onGalleryItemDeleted = (0, import_sdk_types.EventDefinition)(
1687
+ "wix.pro_gallery.gallery_v2_gallery_item_deleted",
1688
+ true,
1689
+ (event) => (0, import_rename_all_nested_keys2.renameKeysFromRESTResponseToSDKResponse)(
1690
+ (0, import_transform_paths3.transformPaths)(event, [
1691
+ {
1692
+ transformFn: import_timestamp3.transformRESTTimestampToSDKTimestamp,
1693
+ paths: [{ path: "metadata.eventTime" }]
1694
+ }
1695
+ ])
1696
+ )
1697
+ )();
1698
+ var onGalleryItemUpdated = (0, import_sdk_types.EventDefinition)(
1699
+ "wix.pro_gallery.gallery_v2_gallery_item_updated",
1700
+ true,
1701
+ (event) => (0, import_rename_all_nested_keys2.renameKeysFromRESTResponseToSDKResponse)(
1702
+ (0, import_transform_paths3.transformPaths)(event, [
1703
+ {
1704
+ transformFn: import_float3.transformRESTFloatToSDKFloat,
1705
+ paths: [
1706
+ { path: "data.updatedItem.sortOrder" },
1707
+ { path: "data.updatedItem.image.focalPoint.x" },
1708
+ { path: "data.updatedItem.image.focalPoint.y" },
1709
+ { path: "data.updatedItem.secondaryMedia.image.focalPoint.x" },
1710
+ { path: "data.updatedItem.secondaryMedia.image.focalPoint.y" },
1711
+ { path: "data.updatedItem.image.unsharpMasking.amount" },
1712
+ { path: "data.updatedItem.image.unsharpMasking.radius" },
1713
+ { path: "data.updatedItem.image.unsharpMasking.threshold" },
1714
+ {
1715
+ path: "data.updatedItem.secondaryMedia.image.unsharpMasking.amount"
1716
+ },
1717
+ {
1718
+ path: "data.updatedItem.secondaryMedia.image.unsharpMasking.radius"
1719
+ },
1720
+ {
1721
+ path: "data.updatedItem.secondaryMedia.image.unsharpMasking.threshold"
1722
+ }
1723
+ ]
1724
+ },
1725
+ {
1726
+ transformFn: import_timestamp3.transformRESTTimestampToSDKTimestamp,
1727
+ paths: [
1728
+ { path: "data.updatedItem.createdDate" },
1729
+ { path: "data.updatedItem.updatedDate" },
1730
+ { path: "metadata.eventTime" }
1731
+ ]
1732
+ },
1733
+ {
1734
+ transformFn: import_image3.transformRESTImageToSDKImage,
1735
+ paths: [
1736
+ { path: "data.updatedItem.image.imageInfo" },
1737
+ { path: "data.updatedItem.secondaryMedia.image.imageInfo" }
1738
+ ]
1739
+ },
1740
+ {
1741
+ transformFn: import_video_v23.transformRESTVideoV2ToSDKVideoV2,
1742
+ paths: [{ path: "data.updatedItem.video.videoInfo" }]
1743
+ }
1744
+ ])
1745
+ )
1746
+ )();
1747
+ var onGalleryUpdated = (0, import_sdk_types.EventDefinition)(
1748
+ "wix.pro_gallery.gallery_v2_updated",
1749
+ true,
1750
+ (event) => (0, import_rename_all_nested_keys2.renameKeysFromRESTResponseToSDKResponse)(
1751
+ (0, import_transform_paths3.transformPaths)(event, [
1752
+ {
1753
+ transformFn: import_float3.transformRESTFloatToSDKFloat,
1754
+ paths: [
1755
+ { path: "entity.sortOrder" },
1756
+ { path: "entity.items.sortOrder" },
1757
+ { path: "entity.items.image.focalPoint.x" },
1758
+ { path: "entity.items.image.focalPoint.y" },
1759
+ { path: "entity.items.secondaryMedia.image.focalPoint.x" },
1760
+ { path: "entity.items.secondaryMedia.image.focalPoint.y" },
1761
+ { path: "entity.items.image.unsharpMasking.amount" },
1762
+ { path: "entity.items.image.unsharpMasking.radius" },
1763
+ { path: "entity.items.image.unsharpMasking.threshold" },
1764
+ { path: "entity.items.secondaryMedia.image.unsharpMasking.amount" },
1765
+ { path: "entity.items.secondaryMedia.image.unsharpMasking.radius" },
1766
+ {
1767
+ path: "entity.items.secondaryMedia.image.unsharpMasking.threshold"
1768
+ }
1769
+ ]
1770
+ },
1771
+ {
1772
+ transformFn: import_timestamp3.transformRESTTimestampToSDKTimestamp,
1773
+ paths: [
1774
+ { path: "entity.createdDate" },
1775
+ { path: "entity.items.createdDate" },
1776
+ { path: "entity.items.updatedDate" },
1777
+ { path: "metadata.eventTime" }
1778
+ ]
1779
+ },
1780
+ {
1781
+ transformFn: import_image3.transformRESTImageToSDKImage,
1782
+ paths: [
1783
+ { path: "entity.items.image.imageInfo" },
1784
+ { path: "entity.items.secondaryMedia.image.imageInfo" }
1785
+ ]
1786
+ },
1787
+ {
1788
+ transformFn: import_video_v23.transformRESTVideoV2ToSDKVideoV2,
1789
+ paths: [{ path: "entity.items.video.videoInfo" }]
1790
+ }
1791
+ ])
1792
+ )
1793
+ )();
1794
+
1795
+ // src/pro-gallery-v2-gallery-pro-gallery.context.ts
1796
+ var import_rest_modules3 = require("@wix/sdk-runtime/rest-modules");
1797
+ var import_event_definition_modules = require("@wix/sdk-runtime/event-definition-modules");
1798
+ var listGalleries4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(listGalleries3);
1799
+ var getGallery4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(getGallery3);
1800
+ var listGalleryItems4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(listGalleryItems3);
1801
+ var getGalleryItem4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(getGalleryItem3);
1802
+ var createGallery4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(createGallery3);
1803
+ var updateGallery4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(updateGallery3);
1804
+ var deleteGallery4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(deleteGallery3);
1805
+ var deleteGalleryItems4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(deleteGalleryItems3);
1806
+ var bulkDeleteGalleryItems4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(bulkDeleteGalleryItems3);
1807
+ var createGalleryItem4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(createGalleryItem3);
1808
+ var updateGalleryItem4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(updateGalleryItem3);
1809
+ var deleteGalleryItem4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(deleteGalleryItem3);
1810
+ var onGalleryCreated2 = (0, import_event_definition_modules.createEventModule)(onGalleryCreated);
1811
+ var onGalleryDeleted2 = (0, import_event_definition_modules.createEventModule)(onGalleryDeleted);
1812
+ var onGalleryItemCreated2 = (0, import_event_definition_modules.createEventModule)(onGalleryItemCreated);
1813
+ var onGalleryItemDeleted2 = (0, import_event_definition_modules.createEventModule)(onGalleryItemDeleted);
1814
+ var onGalleryItemUpdated2 = (0, import_event_definition_modules.createEventModule)(onGalleryItemUpdated);
1815
+ var onGalleryUpdated2 = (0, import_event_definition_modules.createEventModule)(onGalleryUpdated);
1816
+ // Annotate the CommonJS export names for ESM import in node:
1817
+ 0 && (module.exports = {
1818
+ Enum,
1819
+ ImageType,
1820
+ LinkRel,
1821
+ LinkType,
1822
+ RCLabel,
1823
+ SearchIndexingNotificationState,
1824
+ State,
1825
+ Type,
1826
+ VideoType,
1827
+ WebhookIdentityType,
1828
+ bulkDeleteGalleryItems,
1829
+ createGallery,
1830
+ createGalleryItem,
1831
+ deleteGallery,
1832
+ deleteGalleryItem,
1833
+ deleteGalleryItems,
1834
+ getGallery,
1835
+ getGalleryItem,
1836
+ listGalleries,
1837
+ listGalleryItems,
1838
+ onGalleryCreated,
1839
+ onGalleryDeleted,
1840
+ onGalleryItemCreated,
1841
+ onGalleryItemDeleted,
1842
+ onGalleryItemUpdated,
1843
+ onGalleryUpdated,
1844
+ updateGallery,
1845
+ updateGalleryItem
1846
+ });
1847
+ //# sourceMappingURL=index.js.map