npm package diff
Package: @forge/util
Versions: 1.4.10-next.0 - 1.4.10-next.0-experimental-effab31
File: package/packages/ari/chunk-DP5RQ3DH.mjs
Index: package/packages/ari/chunk-DP5RQ3DH.mjs
===================================================================
--- package/packages/ari/chunk-DP5RQ3DH.mjs
+++ package/packages/ari/chunk-DP5RQ3DH.mjs
@@ -0,0 +1,70 @@
+import {
+ SalesforceSalesforceRemoteLinkAriResourceOwner,
+ SalesforceSalesforceRemoteLinkAriResourceType
+} from "./chunk-UM6AQHHT.mjs";
+import {
+ RegisteredAri
+} from "./chunk-AB4PPISI.mjs";
+import {
+ AriParser
+} from "./chunk-S7RIZVFI.mjs";
+
+// src/salesforce.salesforce/remote-link/manifest.ts
+var salesforceSalesforceRemoteLinkAriStaticOpts = {
+ qualifier: "ari",
+ platformQualifier: "third-party",
+ cloudId: new RegExp("^$"),
+ // eslint-disable-line no-useless-escape
+ resourceOwner: SalesforceSalesforceRemoteLinkAriResourceOwner,
+ resourceType: SalesforceSalesforceRemoteLinkAriResourceType,
+ resourceIdSlug: "org/{orgId}/opportunity/{opportunityId}",
+ resourceIdSegmentFormats: {
+ orgId: /[!a-zA-Z0-9\-_.~@:;{}=]+(\/[!a-zA-Z0-9\-_.~@:;{}=]+)*/,
+ // eslint-disable-line no-useless-escape
+ opportunityId: /[!a-zA-Z0-9\-_.~@:;{}=]+(\/[!a-zA-Z0-9\-_.~@:;{}=]+)*/
+ // eslint-disable-line no-useless-escape
+ }
+};
+
+// src/salesforce.salesforce/remote-link/index.ts
+var SalesforceSalesforceRemoteLinkAri = class _SalesforceSalesforceRemoteLinkAri extends RegisteredAri {
+ constructor(opts) {
+ super(opts);
+ this._orgId = opts.resourceIdSegmentValues.orgId, this._opportunityId = opts.resourceIdSegmentValues.opportunityId;
+ }
+ get orgId() {
+ return this._orgId;
+ }
+ get opportunityId() {
+ return this._opportunityId;
+ }
+ static create(opts) {
+ let derivedOpts = {
+ qualifier: salesforceSalesforceRemoteLinkAriStaticOpts.qualifier,
+ platformQualifier: salesforceSalesforceRemoteLinkAriStaticOpts.platformQualifier,
+ cloudId: void 0,
+ resourceOwner: salesforceSalesforceRemoteLinkAriStaticOpts.resourceOwner,
+ resourceType: salesforceSalesforceRemoteLinkAriStaticOpts.resourceType,
+ resourceId: `org/${opts.orgId}/opportunity/${opts.opportunityId}`,
+ resourceIdSegmentValues: {
+ orgId: opts.orgId,
+ opportunityId: opts.opportunityId
+ }
+ }, ariOpts = AriParser.fromOpts(derivedOpts, salesforceSalesforceRemoteLinkAriStaticOpts);
+ return new _SalesforceSalesforceRemoteLinkAri(ariOpts);
+ }
+ static parse(maybeAri) {
+ let opts = AriParser.fromString(maybeAri, salesforceSalesforceRemoteLinkAriStaticOpts);
+ return new _SalesforceSalesforceRemoteLinkAri(opts);
+ }
+ getVariables() {
+ return {
+ orgId: this.orgId,
+ opportunityId: this.opportunityId
+ };
+ }
+};
+
+export {
+ SalesforceSalesforceRemoteLinkAri
+};