@wix/auto_sdk_portfolio_projects 1.0.33 → 1.0.35
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/build/cjs/index.d.ts +9 -23
- package/build/cjs/index.js +62 -1
- package/build/cjs/index.js.map +1 -1
- package/build/cjs/index.typings.d.ts +48 -1
- package/build/cjs/index.typings.js +43 -0
- package/build/cjs/index.typings.js.map +1 -1
- package/build/cjs/meta.d.ts +42 -1
- package/build/cjs/meta.js.map +1 -1
- package/build/es/index.d.mts +9 -23
- package/build/es/index.mjs +62 -1
- package/build/es/index.mjs.map +1 -1
- package/build/es/index.typings.d.mts +48 -1
- package/build/es/index.typings.mjs +42 -0
- package/build/es/index.typings.mjs.map +1 -1
- package/build/es/meta.d.mts +42 -1
- package/build/es/meta.mjs.map +1 -1
- package/build/internal/cjs/index.d.ts +9 -23
- package/build/internal/cjs/index.js +62 -1
- package/build/internal/cjs/index.js.map +1 -1
- package/build/internal/cjs/index.typings.d.ts +48 -1
- package/build/internal/cjs/index.typings.js +43 -0
- package/build/internal/cjs/index.typings.js.map +1 -1
- package/build/internal/cjs/meta.d.ts +42 -1
- package/build/internal/cjs/meta.js.map +1 -1
- package/build/internal/es/index.d.mts +9 -23
- package/build/internal/es/index.mjs +62 -1
- package/build/internal/es/index.mjs.map +1 -1
- package/build/internal/es/index.typings.d.mts +48 -1
- package/build/internal/es/index.typings.mjs +42 -0
- package/build/internal/es/index.typings.mjs.map +1 -1
- package/build/internal/es/meta.d.mts +42 -1
- package/build/internal/es/meta.mjs.map +1 -1
- package/package.json +3 -3
|
@@ -386,6 +386,10 @@ interface MetaSiteSpecialEvent extends MetaSiteSpecialEventPayloadOneOf {
|
|
|
386
386
|
wixelAssigned?: WixelAssigned;
|
|
387
387
|
/** Emitted when Wixel is detached. */
|
|
388
388
|
wixelUnassigned?: WixelUnassigned;
|
|
389
|
+
/** Emitted when StudioTwo is attached. */
|
|
390
|
+
studioTwoAssigned?: StudioTwoAssigned;
|
|
391
|
+
/** Emitted when StudioTwo is detached. */
|
|
392
|
+
studioTwoUnassigned?: StudioTwoUnassigned;
|
|
389
393
|
/**
|
|
390
394
|
* A meta site id.
|
|
391
395
|
* @format GUID
|
|
@@ -456,6 +460,10 @@ interface MetaSiteSpecialEventPayloadOneOf {
|
|
|
456
460
|
wixelAssigned?: WixelAssigned;
|
|
457
461
|
/** Emitted when Wixel is detached. */
|
|
458
462
|
wixelUnassigned?: WixelUnassigned;
|
|
463
|
+
/** Emitted when StudioTwo is attached. */
|
|
464
|
+
studioTwoAssigned?: StudioTwoAssigned;
|
|
465
|
+
/** Emitted when StudioTwo is detached. */
|
|
466
|
+
studioTwoUnassigned?: StudioTwoUnassigned;
|
|
459
467
|
}
|
|
460
468
|
interface Asset {
|
|
461
469
|
/**
|
|
@@ -808,6 +816,12 @@ interface WixelAssigned {
|
|
|
808
816
|
/** Unassigned Wixel */
|
|
809
817
|
interface WixelUnassigned {
|
|
810
818
|
}
|
|
819
|
+
/** Assigned StudioTwo */
|
|
820
|
+
interface StudioTwoAssigned {
|
|
821
|
+
}
|
|
822
|
+
/** Unassigned StudioTwo */
|
|
823
|
+
interface StudioTwoUnassigned {
|
|
824
|
+
}
|
|
811
825
|
interface Empty {
|
|
812
826
|
}
|
|
813
827
|
interface MessageEnvelope {
|
|
@@ -1358,6 +1372,33 @@ interface EntityDeletedEvent {
|
|
|
1358
1372
|
interface ActionEvent {
|
|
1359
1373
|
body?: string;
|
|
1360
1374
|
}
|
|
1375
|
+
interface GetAdjacentProjectInfoRequest {
|
|
1376
|
+
/**
|
|
1377
|
+
* Collection ID to search within
|
|
1378
|
+
* @format GUID
|
|
1379
|
+
*/
|
|
1380
|
+
collectionId?: string;
|
|
1381
|
+
/** Current project's sort order for finding adjacent projects */
|
|
1382
|
+
currentSortOrder?: number;
|
|
1383
|
+
}
|
|
1384
|
+
interface GetAdjacentProjectInfoResponse {
|
|
1385
|
+
/** Previous project info (optional) */
|
|
1386
|
+
previousProject?: ProjectInfo;
|
|
1387
|
+
/** Next project info (optional) */
|
|
1388
|
+
nextProject?: ProjectInfo;
|
|
1389
|
+
}
|
|
1390
|
+
interface ProjectInfo {
|
|
1391
|
+
/**
|
|
1392
|
+
* Project ID
|
|
1393
|
+
* @format GUID
|
|
1394
|
+
*/
|
|
1395
|
+
projectId?: string;
|
|
1396
|
+
/**
|
|
1397
|
+
* Project slug
|
|
1398
|
+
* @maxLength 256
|
|
1399
|
+
*/
|
|
1400
|
+
slug?: string;
|
|
1401
|
+
}
|
|
1361
1402
|
interface BaseEventMetadata {
|
|
1362
1403
|
/**
|
|
1363
1404
|
* App instance ID.
|
|
@@ -1679,6 +1720,12 @@ interface ProjectsQueryBuilder {
|
|
|
1679
1720
|
skipTo: (cursor: string) => ProjectsQueryBuilder;
|
|
1680
1721
|
find: () => Promise<ProjectsQueryResult>;
|
|
1681
1722
|
}
|
|
1723
|
+
/**
|
|
1724
|
+
* @hidden
|
|
1725
|
+
* @fqn com.wixpress.portfolio.projects.ProjectsService.QueryProjects
|
|
1726
|
+
* @requiredField query
|
|
1727
|
+
*/
|
|
1728
|
+
declare function typedQueryProjects(query: QueryV2, options?: QueryProjectsOptions): Promise<NonNullablePaths<QueryProjectsResponse, `projects` | `projects.${number}.coverImage.focalPoint.x` | `projects.${number}.coverImage.focalPoint.y` | `projects.${number}.seoData.settings.preventAutoRedirect` | `projects.${number}.watermark.position` | `projects.${number}.watermark.size` | `projects.${number}.watermark.opacity` | `projects.${number}.watermark.imageUrl` | `projects.${number}.watermark.enabled`, 6>>;
|
|
1682
1729
|
/**
|
|
1683
1730
|
* Deprecated - please use ProjectsInCollectionsService.UpdateProjectOrderInCollection instead
|
|
1684
1731
|
* our Client still use it
|
|
@@ -1723,4 +1770,4 @@ interface QueryProjectsWithCollectionInfoOptions {
|
|
|
1723
1770
|
includePageUrl?: boolean | null;
|
|
1724
1771
|
}
|
|
1725
1772
|
|
|
1726
|
-
export { type ActionEvent, type App, type ApplicationError, type Asset, type BaseEventMetadata, type BulkActionMetadata, type BulkUpdateProjectsOptions, type BulkUpdateProjectsRequest, type BulkUpdateProjectsResponse, type BulkUpdateProjectsResult, type CreateNewPortfolioAppRequest, type CreateNewPortfolioAppResponse, type CreateProjectRequest, type CreateProjectResponse, type CursorPaging, type Cursors, type CustomTag, type DeleteContext, type DeleteProjectRequest, type DeleteProjectResponse, DeleteStatus, type DeleteStatusWithLiterals, type DeletedProjectRestored, type DetailsLink, type DomainEvent, type DomainEventBodyOneOf, type Empty, type EntityCreatedEvent, type EntityDeletedEvent, type EntityUpdatedEvent, type EventMetadata, type File, type GetProjectOptions, type GetProjectPageDataRequest, type GetProjectPageDataResponse, type GetProjectRequest, type GetProjectResponse, type IdentificationData, type IdentificationDataIdOneOf, type Image, ImageType, type ImageTypeWithLiterals, type InvalidateCache, type InvalidateCacheGetByOneOf, type ItemMetadata, type Keyword, type ListProjectsOptions, type ListProjectsRequest, type ListProjectsResponse, type MaskedProject, type MenuSettingUpdatedEvent, type MessageEnvelope, type MetaSiteSpecialEvent, type MetaSiteSpecialEventPayloadOneOf, Namespace, type NamespaceChanged, type NamespaceWithLiterals, type OdeditorAssigned, type OdeditorUnassigned, type Page, type Paging, type PagingMetadataV2, type PicassoAssigned, type PicassoUnassigned, type Point, Position, type PositionWithLiterals, type Project, type ProjectCoverOneOf, type ProjectCreatedEnvelope, type ProjectDeletedEnvelope, type ProjectDetail, type ProjectDetailValueOneOf, type ProjectSlug, type ProjectSource, type ProjectUpdatedEnvelope, type ProjectsInCollections, type ProjectsQueryBuilder, type ProjectsQueryResult, type QueryProjectWithCollectionInfoRequest, type QueryProjectWithCollectionInfoResponse, type QueryProjectsOptions, type QueryProjectsRequest, type QueryProjectsResponse, type QueryProjectsWithCollectionInfoOptions, type QueryV2, type QueryV2PagingMethodOneOf, type RestoreInfo, type RestoreProjectFromTrashBinRequest, type RestoreProjectFromTrashBinResponse, type SeoSchema, type ServiceProvisioned, type ServiceRemoved, type Settings, type SiteCreated, SiteCreatedContext, type SiteCreatedContextWithLiterals, type SiteDeleted, type SiteHardDeleted, type SiteMarkedAsTemplate, type SiteMarkedAsWixSite, type SitePublished, type SitePurgedExternally, type SiteRenamed, type SiteTransferred, type SiteUndeleted, type SiteUnpublished, type SiteUrlChanged, SortOrder, type SortOrderWithLiterals, type Sorting, State, type StateWithLiterals, type StudioAssigned, type StudioUnassigned, type SyncProjectWithCollectionMappings, SyncStatus, type SyncStatusWithLiterals, type Tag, type URI, type UnsharpMasking, type UpdateProject, type UpdateProjectOrderInCollectionIdentifiers, type UpdateProjectOrderInCollectionRequest, type UpdateProjectOrderInCollectionResponse, type UpdateProjectRequest, type UpdateProjectResponse, type Video, type VideoResolution, type Watermark, WebhookIdentityType, type WebhookIdentityTypeWithLiterals, type WixelAssigned, type WixelUnassigned, bulkUpdateProjects, createProject, deleteProject, getProject, listProjects, onProjectCreated, onProjectDeleted, onProjectUpdated, queryProjects, queryProjectsWithCollectionInfo, updateProject, updateProjectOrderInCollection };
|
|
1773
|
+
export { type ActionEvent, type App, type ApplicationError, type Asset, type BaseEventMetadata, type BulkActionMetadata, type BulkUpdateProjectsOptions, type BulkUpdateProjectsRequest, type BulkUpdateProjectsResponse, type BulkUpdateProjectsResult, type CreateNewPortfolioAppRequest, type CreateNewPortfolioAppResponse, type CreateProjectRequest, type CreateProjectResponse, type CursorPaging, type Cursors, type CustomTag, type DeleteContext, type DeleteProjectRequest, type DeleteProjectResponse, DeleteStatus, type DeleteStatusWithLiterals, type DeletedProjectRestored, type DetailsLink, type DomainEvent, type DomainEventBodyOneOf, type Empty, type EntityCreatedEvent, type EntityDeletedEvent, type EntityUpdatedEvent, type EventMetadata, type File, type GetAdjacentProjectInfoRequest, type GetAdjacentProjectInfoResponse, type GetProjectOptions, type GetProjectPageDataRequest, type GetProjectPageDataResponse, type GetProjectRequest, type GetProjectResponse, type IdentificationData, type IdentificationDataIdOneOf, type Image, ImageType, type ImageTypeWithLiterals, type InvalidateCache, type InvalidateCacheGetByOneOf, type ItemMetadata, type Keyword, type ListProjectsOptions, type ListProjectsRequest, type ListProjectsResponse, type MaskedProject, type MenuSettingUpdatedEvent, type MessageEnvelope, type MetaSiteSpecialEvent, type MetaSiteSpecialEventPayloadOneOf, Namespace, type NamespaceChanged, type NamespaceWithLiterals, type OdeditorAssigned, type OdeditorUnassigned, type Page, type Paging, type PagingMetadataV2, type PicassoAssigned, type PicassoUnassigned, type Point, Position, type PositionWithLiterals, type Project, type ProjectCoverOneOf, type ProjectCreatedEnvelope, type ProjectDeletedEnvelope, type ProjectDetail, type ProjectDetailValueOneOf, type ProjectInfo, type ProjectSlug, type ProjectSource, type ProjectUpdatedEnvelope, type ProjectsInCollections, type ProjectsQueryBuilder, type ProjectsQueryResult, type QueryProjectWithCollectionInfoRequest, type QueryProjectWithCollectionInfoResponse, type QueryProjectsOptions, type QueryProjectsRequest, type QueryProjectsResponse, type QueryProjectsWithCollectionInfoOptions, type QueryV2, type QueryV2PagingMethodOneOf, type RestoreInfo, type RestoreProjectFromTrashBinRequest, type RestoreProjectFromTrashBinResponse, type SeoSchema, type ServiceProvisioned, type ServiceRemoved, type Settings, type SiteCreated, SiteCreatedContext, type SiteCreatedContextWithLiterals, type SiteDeleted, type SiteHardDeleted, type SiteMarkedAsTemplate, type SiteMarkedAsWixSite, type SitePublished, type SitePurgedExternally, type SiteRenamed, type SiteTransferred, type SiteUndeleted, type SiteUnpublished, type SiteUrlChanged, SortOrder, type SortOrderWithLiterals, type Sorting, State, type StateWithLiterals, type StudioAssigned, type StudioTwoAssigned, type StudioTwoUnassigned, type StudioUnassigned, type SyncProjectWithCollectionMappings, SyncStatus, type SyncStatusWithLiterals, type Tag, type URI, type UnsharpMasking, type UpdateProject, type UpdateProjectOrderInCollectionIdentifiers, type UpdateProjectOrderInCollectionRequest, type UpdateProjectOrderInCollectionResponse, type UpdateProjectRequest, type UpdateProjectResponse, type Video, type VideoResolution, type Watermark, WebhookIdentityType, type WebhookIdentityTypeWithLiterals, type WixelAssigned, type WixelUnassigned, bulkUpdateProjects, createProject, deleteProject, getProject, listProjects, onProjectCreated, onProjectDeleted, onProjectUpdated, queryProjects, queryProjectsWithCollectionInfo, typedQueryProjects, updateProject, updateProjectOrderInCollection };
|
|
@@ -1097,6 +1097,47 @@ function queryProjects2(options) {
|
|
|
1097
1097
|
transformationPaths: {}
|
|
1098
1098
|
});
|
|
1099
1099
|
}
|
|
1100
|
+
async function typedQueryProjects(query, options) {
|
|
1101
|
+
const { httpClient, sideEffects } = arguments[2];
|
|
1102
|
+
const payload = renameKeysFromSDKRequestToRESTRequest({
|
|
1103
|
+
query,
|
|
1104
|
+
...options
|
|
1105
|
+
});
|
|
1106
|
+
const reqOpts = queryProjects(payload);
|
|
1107
|
+
sideEffects?.onSiteCall?.();
|
|
1108
|
+
try {
|
|
1109
|
+
const result = await httpClient.request(reqOpts);
|
|
1110
|
+
sideEffects?.onSuccess?.(result);
|
|
1111
|
+
return renameKeysFromRESTResponseToSDKResponse(
|
|
1112
|
+
transformPaths2(result.data, [
|
|
1113
|
+
{
|
|
1114
|
+
transformFn: transformRESTPageURLV2ToSDKPageURLV2,
|
|
1115
|
+
paths: [{ path: "projects.url" }]
|
|
1116
|
+
},
|
|
1117
|
+
{
|
|
1118
|
+
transformFn: transformRESTImageToSDKImage,
|
|
1119
|
+
paths: [{ path: "projects.coverImage.imageInfo" }]
|
|
1120
|
+
},
|
|
1121
|
+
{
|
|
1122
|
+
transformFn: transformRESTVideoV2ToSDKVideoV2,
|
|
1123
|
+
paths: [{ path: "projects.coverVideo.videoInfo" }]
|
|
1124
|
+
}
|
|
1125
|
+
])
|
|
1126
|
+
);
|
|
1127
|
+
} catch (err) {
|
|
1128
|
+
const transformedError = sdkTransformError(
|
|
1129
|
+
err,
|
|
1130
|
+
{
|
|
1131
|
+
spreadPathsToArguments: {},
|
|
1132
|
+
explicitPathsToArguments: { query: "$[0]" },
|
|
1133
|
+
singleArgumentUnchanged: false
|
|
1134
|
+
},
|
|
1135
|
+
["query", "options"]
|
|
1136
|
+
);
|
|
1137
|
+
sideEffects?.onError?.(err);
|
|
1138
|
+
throw transformedError;
|
|
1139
|
+
}
|
|
1140
|
+
}
|
|
1100
1141
|
async function updateProjectOrderInCollection2(identifiers, sortOrder) {
|
|
1101
1142
|
const { httpClient, sideEffects } = arguments[2];
|
|
1102
1143
|
const payload = renameKeysFromSDKRequestToRESTRequest({
|
|
@@ -1217,6 +1258,7 @@ export {
|
|
|
1217
1258
|
listProjects2 as listProjects,
|
|
1218
1259
|
queryProjects2 as queryProjects,
|
|
1219
1260
|
queryProjectsWithCollectionInfo2 as queryProjectsWithCollectionInfo,
|
|
1261
|
+
typedQueryProjects,
|
|
1220
1262
|
updateProject2 as updateProject,
|
|
1221
1263
|
updateProjectOrderInCollection2 as updateProjectOrderInCollection
|
|
1222
1264
|
};
|