npm package diff
Package: @forge/util
Versions: 1.4.10-next.0 - 1.4.10-next.0-experimental-effab31
File: package/packages/ari/chunk-JUELWM4I.mjs
Index: package/packages/ari/chunk-JUELWM4I.mjs
===================================================================
--- package/packages/ari/chunk-JUELWM4I.mjs
+++ package/packages/ari/chunk-JUELWM4I.mjs
@@ -1,87 +0,0 @@
-import {
- JiraEntityPropertyAriResourceOwner,
- JiraEntityPropertyAriResourceType
-} from "./chunk-WVAVMODN.mjs";
-import {
- RegisteredAri
-} from "./chunk-CLQNXEWF.mjs";
-import {
- AriParser
-} from "./chunk-HNZGDVUS.mjs";
-
-// src/jira/entity-property/manifest.ts
-var jiraEntityPropertyAriStaticOpts = {
- qualifier: "ari",
- platformQualifier: "cloud",
- cloudId: new RegExp("^[a-zA-Z0-9-]+$"),
- resourceOwner: JiraEntityPropertyAriResourceOwner,
- resourceType: JiraEntityPropertyAriResourceType,
- resourceIdSlug: "activation/{activationId}/{entityType}/{entityId}/{propertyKey}",
- resourceIdSegmentFormats: {
- activationId: /[a-zA-Z0-9\-]+/,
- // eslint-disable-line no-useless-escape
- entityType: /[!a-zA-Z0-9\-_.~@:{}=]+(\/[!a-zA-Z0-9\-_.~@:{}=]+)*/,
- // eslint-disable-line no-useless-escape
- entityId: /[0-9]+/,
- // eslint-disable-line no-useless-escape
- propertyKey: /[!a-zA-Z0-9\-_.~@:{}=]+(\/[!a-zA-Z0-9\-_.~@:{}=]+)*/
- // eslint-disable-line no-useless-escape
- }
-};
-
-// src/jira/entity-property/index.ts
-var JiraEntityPropertyAri = class _JiraEntityPropertyAri extends RegisteredAri {
- constructor(opts) {
- super(opts);
- this._siteId = opts.cloudId || "", this._activationId = opts.resourceIdSegmentValues.activationId, this._entityType = opts.resourceIdSegmentValues.entityType, this._entityId = opts.resourceIdSegmentValues.entityId, this._propertyKey = opts.resourceIdSegmentValues.propertyKey;
- }
- get siteId() {
- return this._siteId;
- }
- get activationId() {
- return this._activationId;
- }
- get entityType() {
- return this._entityType;
- }
- get entityId() {
- return this._entityId;
- }
- get propertyKey() {
- return this._propertyKey;
- }
- static create(opts) {
- let derivedOpts = {
- qualifier: jiraEntityPropertyAriStaticOpts.qualifier,
- platformQualifier: jiraEntityPropertyAriStaticOpts.platformQualifier,
- cloudId: opts.siteId,
- resourceOwner: jiraEntityPropertyAriStaticOpts.resourceOwner,
- resourceType: jiraEntityPropertyAriStaticOpts.resourceType,
- resourceId: `activation/${opts.activationId}/${opts.entityType}/${opts.entityId}/${opts.propertyKey}`,
- resourceIdSegmentValues: {
- activationId: opts.activationId,
- entityType: opts.entityType,
- entityId: opts.entityId,
- propertyKey: opts.propertyKey
- }
- }, ariOpts = AriParser.fromOpts(derivedOpts, jiraEntityPropertyAriStaticOpts);
- return new _JiraEntityPropertyAri(ariOpts);
- }
- static parse(maybeAri) {
- let opts = AriParser.fromString(maybeAri, jiraEntityPropertyAriStaticOpts);
- return new _JiraEntityPropertyAri(opts);
- }
- getVariables() {
- return {
- siteId: this.siteId,
- activationId: this.activationId,
- entityType: this.entityType,
- entityId: this.entityId,
- propertyKey: this.propertyKey
- };
- }
-};
-
-export {
- JiraEntityPropertyAri
-};