@pageproof/sdk-pr 453.0.1658972759303 → 455.0.1660188791264

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/CHANGELOG.md CHANGED
@@ -1,5 +1,23 @@
1
1
  # Changelog
2
2
 
3
+ ## 2.0.0-beta.296
4
+
5
+ Released on the 11th of August 2022.
6
+
7
+ - [[PP-2627](https://goto.pageproof.dev/PP-2627)] Added support for `Approved with changes` decision. See [TeamProofFeatures.allowedDecisions](https://docs.pageproof.tech/@pageproof/sdk/beta/class/src/models/TeamProofFeatures.js~TeamProofFeatures.html#instance-member-allowedDecisions) and [TeamFeatures.update](https://docs.pageproof.tech/@pageproof/sdk/beta/class/src/api/admin/TeamFeatures.js~TeamFeatures.html#instance-method-update).
8
+
9
+ ## 2.0.0-beta.295
10
+
11
+ Released on the 5th of August 2022.
12
+
13
+ - [[PP-2345](https://goto.pageproof.dev/PP-2345)] Added support for creating proofs with checklists.
14
+
15
+ ## 2.0.0-beta.294
16
+
17
+ Released on the 26th of July 2022.
18
+
19
+ - [[PP-3452](https://goto.pageproof.dev/PP-3452)] Added support for accessing a file's import URL. See [File.importUrl](https://docs.pageproof.tech/@pageproof/sdk/beta/class/src/models/File.js~File.html#instance-member-importUrl).
20
+
3
21
  ## 2.0.0-beta.293
4
22
 
5
23
  Released on the 31st of May 2022.
@@ -177,29 +177,29 @@ declare class Proofs extends API {
177
177
  *
178
178
  * @see {@link Proofs.start}
179
179
  *
180
- * @param {{ name: string, tags?: string[], dueDate?: Date | string, messageToReviewers?: string, workflow?: { id: string }, workflowTemplate?: { id: string }, checklist?: { templateId?: string, isRequiredForFinalApproval?: boolean, shouldOpenOnProofLoad?: boolean }, file?: { id: string }, group?: { id: string }, previousProof?: { id: string }, team?: { slug: string }, reference?: string, customTools?: any, integrationReferences: any[], reminders?: Reminder[], owners?: { email?: string, id?: string }[], canDownload?: boolean, start?: boolean }} options The options
180
+ * @param {{ name: string, tags?: string[], dueDate?: Date | string, messageToReviewers?: string, workflow?: { id: string }, workflowTemplate?: { id: string }, checklist?: { templateId?: string, isRequiredForFinalApproval?: boolean, shouldOpenOnProofLoad?: boolean }, file?: { id: string }, group?: { id: string }, previousProof?: { id: string }, team?: { slug: string }, reference?: string, customTools?: any, integrationReferences?: any[], reminders?: Reminder[], owners?: { email?: string, id?: string }[], canDownload?: boolean, start?: boolean }} options The options
181
181
  *
182
182
  * @param options.name The name of the proof
183
- * @param options.tags The tags to add to the proof (defaults to no tags)
184
- * @param options.dueDate The due date of the proof (defaults to 3 days in the future)
185
- * @param options.messageToReviewers The message to reviewers
186
- * @param options.workflow.id The workflow id to assign to the proof
187
- * @param options.workflowTemplate.id The workflow template id to duplicate and assign to the proof
188
- * @param options.checklist.templateId The checklist template id to be used to create a checklist for the proof
189
- * @param options.checklist.isRequiredForFinalApproval Whether the checklist must be completed before final approval can be given
190
- * @param options.checklist.shouldOpenOnProofLoad Whether the checklist should be opened automatically when the proof is loaded
191
- * @param options.file.id The file id to assign to the proof
192
- * @param options.group.id The proof group id to add the proof to
193
- * @param options.previousProof.id The proof id of the previous proof to attach this new version to
194
- * @param options.team.slug The team slug (user-friendly identifier)
195
- * @param options.reference The proof reference to add the proof to (to integration with other applications)
196
- * @param options.customTools Any custom tools to expose on the proofing screen
197
- * @param options.integrationReferences The integration references to attach to the proof
198
- * @param options.reminders The proof reminders to add the proof to (to nudge users)
199
- * @param options.owners The users to assign as owners for the proof (if omitted and a new version, the previous version's owners are inherited, otherwise, the user creating the proof is assigned as the only owner)
200
- * @param options.canDownload Whether the file attached to the proof can be download
201
- * @param options.isPublic Whether the proof is publicly accessible
202
- * @param options.start Whether to immediately start the proof (sends invitation emails to reviewers in the workflow)
183
+ * @param [options.tags] The tags to add to the proof (defaults to no tags)
184
+ * @param [options.dueDate] The due date of the proof (defaults to 3 days in the future)
185
+ * @param [options.messageToReviewers] The message to reviewers
186
+ * @param [options.workflow.id] The workflow id to assign to the proof
187
+ * @param [options.workflowTemplate.id] The workflow template id to duplicate and assign to the proof
188
+ * @param [options.checklist.templateId] The checklist template id to be used to create a checklist for the proof
189
+ * @param [options.checklist.isRequiredForFinalApproval] Whether the checklist must be completed before final approval can be given
190
+ * @param [options.checklist.shouldOpenOnProofLoad] Whether the checklist should be opened automatically when the proof is loaded
191
+ * @param [options.file.id] The file id to assign to the proof
192
+ * @param [options.group.id] The proof group id to add the proof to
193
+ * @param [options.previousProof.id] The proof id of the previous proof to attach this new version to
194
+ * @param [options.team.slug] The team slug (user-friendly identifier)
195
+ * @param [options.reference] The proof reference to add the proof to (to integration with other applications)
196
+ * @param [options.customTools] Any custom tools to expose on the proofing screen
197
+ * @param [options.integrationReferences] The integration references to attach to the proof
198
+ * @param [options.reminders] The proof reminders to add the proof to (to nudge users)
199
+ * @param [options.owners] The users to assign as owners for the proof (if omitted and a new version, the previous version's owners are inherited, otherwise, the user creating the proof is assigned as the only owner)
200
+ * @param [options.canDownload] Whether the file attached to the proof can be download
201
+ * @param [options.isPublic] Whether the proof is publicly accessible
202
+ * @param [options.start] Whether to immediately start the proof (sends invitation emails to reviewers in the workflow)
203
203
  * @returns {Promise<Proof>}
204
204
  */
205
205
  create({ name, tags, dueDate, messageToReviewers, workflow, workflowTemplate, checklist, file, group, previousProof, team, reference, customTools, integrationReferences, reminders, owners, canDownload, isPublic, start, }: {
@@ -232,7 +232,7 @@ declare class Proofs extends API {
232
232
  };
233
233
  reference?: string;
234
234
  customTools?: any;
235
- integrationReferences: any[];
235
+ integrationReferences?: any[];
236
236
  reminders?: any[];
237
237
  owners?: {
238
238
  email?: string;
@@ -37,6 +37,7 @@ declare class TeamFeatures extends API {
37
37
  * @param {boolean} options.proofs.publicProofs Whether the public proofs feature is enabled.
38
38
  * @param {boolean} options.proofs.defaultIsPublic The default value for whether a proof is public on the proof setup page.
39
39
  * @param {boolean} options.proofs.messageToOwners Whether reviewers can send a message to the proof owners.
40
+ * @param {Decision|Array<Decision>} options.proofs.allowedDecisions The proof decision or array of proof decisions that allowed to the reviewer.
40
41
  * @returns {Promise}
41
42
  */
42
43
  update({ emails, comments, proofs, }: {
@@ -58,6 +59,7 @@ declare class TeamFeatures extends API {
58
59
  publicProofs: boolean;
59
60
  defaultIsPublic: boolean;
60
61
  messageToOwners: boolean;
62
+ allowedDecisions: Decision | Decision[];
61
63
  };
62
64
  }): Promise<any>;
63
65
  /**
@@ -75,6 +75,7 @@ var TeamFeatures = function (_API) {
75
75
  * @param {boolean} options.proofs.publicProofs Whether the public proofs feature is enabled.
76
76
  * @param {boolean} options.proofs.defaultIsPublic The default value for whether a proof is public on the proof setup page.
77
77
  * @param {boolean} options.proofs.messageToOwners Whether reviewers can send a message to the proof owners.
78
+ * @param {Decision|Array<Decision>} options.proofs.allowedDecisions The proof decision or array of proof decisions that allowed to the reviewer.
78
79
  * @returns {Promise}
79
80
  */
80
81
 
@@ -97,6 +98,7 @@ var TeamFeatures = function (_API) {
97
98
  var publicProofs = proofs && proofs.publicProofs;
98
99
  var defaultProofIsPublic = proofs && proofs.defaultIsPublic;
99
100
  var messageToOwners = proofs && proofs.messageToOwners;
101
+ var allowedDecisions = proofs && proofs.allowedDecisions && [].concat(proofs.allowedDecisions);
100
102
  return this.client.request('admin.team.features.update', {
101
103
  displayComments: displayComments,
102
104
  displayTeamName: displayTeamName,
@@ -110,7 +112,8 @@ var TeamFeatures = function (_API) {
110
112
  proofReference: proofReference,
111
113
  publicProofs: publicProofs,
112
114
  defaultProofIsPublic: defaultProofIsPublic,
113
- messageToOwners: messageToOwners
115
+ messageToOwners: messageToOwners,
116
+ allowedDecisions: allowedDecisions
114
117
  });
115
118
  };
116
119
 
@@ -69,6 +69,12 @@ declare class File {
69
69
  * @type {object|null}
70
70
  */
71
71
  adobeExportData: object | null;
72
+ /**
73
+ * If the file was created by importing from an external URL, this will be that URL.
74
+ *
75
+ * @type {string|null}
76
+ */
77
+ importUrl: string | null;
72
78
  /** @private */
73
79
  fromFile(fileData: any): File;
74
80
  /** @private */
@@ -1 +1 @@
1
- "use strict";exports.__esModule=true;var _transform=require("./transform");var _transform2=_interopRequireDefault(_transform);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function")}}var fileSchema={id:"FileId",name:"Name",blocks:"Chunks",size:"Size",downloadable:"Downloadable",assignedTo:"AssignedTo",assignedType:"AssignedType",status:"Status",message:"Message",adobeExportData:function adobeExportData(data){var exportData=data.AdobeExportData;if(exportData&&exportData.length){try{return JSON.parse(exportData)}catch(err){}}return null},sourceMetadata:function sourceMetadata(data){var sourceMetadata=data.SourceMetadata;if(sourceMetadata&&sourceMetadata.length){try{return JSON.parse(sourceMetadata)}catch(err){}}return null}};var commentAttachmentSchema={id:"FileId",name:"Name",blocks:"Chunks",assignedTo:"CommentId",assignedType:function assignedType(){return"attachment"},status:"Status",message:function message(){return""}};var File=function(){function File(){_classCallCheck(this,File)}File.prototype.fromFile=function fromFile(fileData){(0,_transform2.default)(this,fileSchema,fileData);return this};File.prototype.fromCommentAttachment=function fromCommentAttachment(commentAttachmentData){(0,_transform2.default)(this,commentAttachmentSchema,commentAttachmentData);return this};return File}();exports.default=File;
1
+ "use strict";exports.__esModule=true;var _transform=require("./transform");var _transform2=_interopRequireDefault(_transform);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function")}}var fileSchema={id:"FileId",name:"Name",blocks:"Chunks",size:"Size",downloadable:"Downloadable",assignedTo:"AssignedTo",assignedType:"AssignedType",status:"Status",message:"Message",adobeExportData:function adobeExportData(data){var exportData=data.AdobeExportData;if(exportData&&exportData.length){try{return JSON.parse(exportData)}catch(err){}}return null},sourceMetadata:function sourceMetadata(data){var sourceMetadata=data.SourceMetadata;if(sourceMetadata&&sourceMetadata.length){try{return JSON.parse(sourceMetadata)}catch(err){}}return null},importUrl:"ImportURL"};var commentAttachmentSchema={id:"FileId",name:"Name",blocks:"Chunks",assignedTo:"CommentId",assignedType:function assignedType(){return"attachment"},status:"Status",message:function message(){return""}};var File=function(){function File(){_classCallCheck(this,File)}File.prototype.fromFile=function fromFile(fileData){(0,_transform2.default)(this,fileSchema,fileData);return this};File.prototype.fromCommentAttachment=function fromCommentAttachment(commentAttachmentData){(0,_transform2.default)(this,commentAttachmentSchema,commentAttachmentData);return this};return File}();exports.default=File;
@@ -26,6 +26,12 @@ declare class TeamProofFeatures {
26
26
  * @type {boolean}
27
27
  */
28
28
  messageToOwners: boolean;
29
+ /**
30
+ * Array of proof decisions that allowed to the reviewer.
31
+ *
32
+ * @type {Array<Decision>}
33
+ */
34
+ allowedDecisions: Array<Decision>;
29
35
  /** @private */
30
36
  fromTeamProofFeatures(teamProofFeaturesData: any): TeamProofFeatures;
31
37
  }
@@ -1 +1 @@
1
- "use strict";exports.__esModule=true;var _transform=require("./transform");var _transform2=_interopRequireDefault(_transform);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function")}}var TeamProofFeatureSchema={reference:"ProofReference",publicProofs:"PublicProofs",defaultIsPublic:"DefaultProofIsPublic",messageToOwners:"MessageToOwners"};var TeamProofFeatures=function(){function TeamProofFeatures(){_classCallCheck(this,TeamProofFeatures)}TeamProofFeatures.prototype.fromTeamProofFeatures=function fromTeamProofFeatures(teamProofFeaturesData){(0,_transform2.default)(this,TeamProofFeatureSchema,teamProofFeaturesData);return this};return TeamProofFeatures}();exports.default=TeamProofFeatures;
1
+ "use strict";exports.__esModule=true;var _transform=require("./transform");var _transform2=_interopRequireDefault(_transform);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function")}}var TeamProofFeatureSchema={reference:"ProofReference",publicProofs:"PublicProofs",defaultIsPublic:"DefaultProofIsPublic",messageToOwners:"MessageToOwners",allowedDecisions:"AllowedDecisions"};var TeamProofFeatures=function(){function TeamProofFeatures(){_classCallCheck(this,TeamProofFeatures)}TeamProofFeatures.prototype.fromTeamProofFeatures=function fromTeamProofFeatures(teamProofFeaturesData){(0,_transform2.default)(this,TeamProofFeatureSchema,teamProofFeaturesData);return this};return TeamProofFeatures}();exports.default=TeamProofFeatures;
@@ -853,7 +853,7 @@
853
853
  "version": 2,
854
854
  "method": "POST",
855
855
  "path": "/api/admin/settings",
856
- "body": ["displayComments", "generalComments", "editComments", "proofReference", "displayTeamName", "emailTitleTextColor", "emailLinkTextColor", "emailButtonBackgroundColor", "emailButtonTextColor", "disableReplyingToCommentsInStatuses", "publicProofs", "defaultProofIsPublic", "messageToOwners"]
856
+ "body": ["displayComments", "generalComments", "editComments", "proofReference", "displayTeamName", "emailTitleTextColor", "emailLinkTextColor", "emailButtonBackgroundColor", "emailButtonTextColor", "disableReplyingToCommentsInStatuses", "publicProofs", "defaultProofIsPublic", "messageToOwners", "allowedDecisions"]
857
857
  },
858
858
  "admin.team.features.sender-email.set": {
859
859
  "version": 2,