@forge/util
2.0.12.0.1-experimental-7890858
packages/ari/chunk-XAT5VHDB.mjs+
packages/ari/chunk-XAT5VHDB.mjsNew file+71
Index: package/packages/ari/chunk-XAT5VHDB.mjs
===================================================================
--- package/packages/ari/chunk-XAT5VHDB.mjs
+++ package/packages/ari/chunk-XAT5VHDB.mjs
@@ -0,0 +1,71 @@
+import {
+ MercuryChangeProposalsViewAriResourceOwner,
+ MercuryChangeProposalsViewAriResourceType
+} from "./chunk-KT4TZM4O.mjs";
+import {
+ RegisteredAri
+} from "./chunk-AB4PPISI.mjs";
+import {
+ AriParser
+} from "./chunk-S7RIZVFI.mjs";
+
+// src/mercury/change-proposals-view/manifest.ts
+var mercuryChangeProposalsViewAriStaticOpts = {
+ qualifier: "ari",
+ platformQualifier: "cloud",
+ cloudId: new RegExp("^[a-zA-Z0-9_\\-.]{1,255}$"),
+ resourceOwner: MercuryChangeProposalsViewAriResourceOwner,
+ resourceType: MercuryChangeProposalsViewAriResourceType,
+ resourceIdSlug: "workspace/{workspaceId}/{changeProposalsViewId}",
+ resourceIdSegmentFormats: {
+ workspaceId: /[a-zA-Z0-9\-]+/,
+ // eslint-disable-line no-useless-escape
+ changeProposalsViewId: /[0-9a-f]{8}-[0-9a-f]{4}-[0-5][0-9a-f]{3}-[089ab][0-9a-f]{3}-[0-9a-f]{12}/
+ }
+};
+
+// src/mercury/change-proposals-view/index.ts
+var MercuryChangeProposalsViewAri = class _MercuryChangeProposalsViewAri extends RegisteredAri {
+ constructor(opts) {
+ super(opts), this._siteId = opts.cloudId || "", this._workspaceId = opts.resourceIdSegmentValues.workspaceId, this._changeProposalsViewId = opts.resourceIdSegmentValues.changeProposalsViewId;
+ }
+ get siteId() {
+ return this._siteId;
+ }
+ get workspaceId() {
+ return this._workspaceId;
+ }
+ get changeProposalsViewId() {
+ return this._changeProposalsViewId;
+ }
+ static create(opts) {
+ let derivedOpts = {
+ qualifier: mercuryChangeProposalsViewAriStaticOpts.qualifier,
+ platformQualifier: mercuryChangeProposalsViewAriStaticOpts.platformQualifier,
+ cloudId: opts.siteId,
+ resourceOwner: mercuryChangeProposalsViewAriStaticOpts.resourceOwner,
+ resourceType: mercuryChangeProposalsViewAriStaticOpts.resourceType,
+ resourceId: `workspace/${opts.workspaceId}/${opts.changeProposalsViewId}`,
+ resourceIdSegmentValues: {
+ workspaceId: opts.workspaceId,
+ changeProposalsViewId: opts.changeProposalsViewId
+ }
+ }, ariOpts = AriParser.fromOpts(derivedOpts, mercuryChangeProposalsViewAriStaticOpts);
+ return new _MercuryChangeProposalsViewAri(ariOpts);
+ }
+ static parse(maybeAri) {
+ let opts = AriParser.fromString(maybeAri, mercuryChangeProposalsViewAriStaticOpts);
+ return new _MercuryChangeProposalsViewAri(opts);
+ }
+ getVariables() {
+ return {
+ siteId: this.siteId,
+ workspaceId: this.workspaceId,
+ changeProposalsViewId: this.changeProposalsViewId
+ };
+ }
+};
+
+export {
+ MercuryChangeProposalsViewAri
+};