@valiantys/atlassian-app-frontend 3.1.0-alpha-4 → 3.1.0-alpha-5

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.
@@ -0,0 +1 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("../../../../util-jira-v3-api/src/lib/jira-server-info/index.cjs.js"),r=class r{constructor(t){this.fetchSvc=t}async getServerInfo(){return this.fetchSvc.fetch({url:this.fetchSvc.route`/rest/api/3/serverInfo`,method:"GET"})}async switchAtlassianApiUrlToUseSiteUrl(t){const s=(await this.getServerInfo()).baseUrl;return i.switchAtlassianApiUrlToUseSiteUrl(s,t)}};r.serverInfoUrl="/rest/api/3/serverInfo";let e=r;exports.JiraServerInfoService=e;
@@ -0,0 +1,21 @@
1
+ import { switchAtlassianApiUrlToUseSiteUrl as i } from "../../../../util-jira-v3-api/src/lib/jira-server-info/index.es.js";
2
+ const s = class s {
3
+ constructor(t) {
4
+ this.fetchSvc = t;
5
+ }
6
+ async getServerInfo() {
7
+ return this.fetchSvc.fetch({
8
+ url: this.fetchSvc.route`/rest/api/3/serverInfo`,
9
+ method: "GET"
10
+ });
11
+ }
12
+ async switchAtlassianApiUrlToUseSiteUrl(t) {
13
+ const r = (await this.getServerInfo()).baseUrl;
14
+ return i(r, t);
15
+ }
16
+ };
17
+ s.serverInfoUrl = "/rest/api/3/serverInfo";
18
+ let e = s;
19
+ export {
20
+ e as JiraServerInfoService
21
+ };
@@ -0,0 +1,366 @@
1
+ {
2
+ "metadata": {
3
+ "toolPackage": "@microsoft/api-extractor",
4
+ "toolVersion": "7.52.8",
5
+ "schemaVersion": 1011,
6
+ "oldestForwardsCompatibleVersion": 1001,
7
+ "tsdocConfig": {
8
+ "$schema": "https://developer.microsoft.com/json-schemas/tsdoc/v0/tsdoc.schema.json",
9
+ "noStandardTags": true,
10
+ "tagDefinitions": [
11
+ {
12
+ "tagName": "@alpha",
13
+ "syntaxKind": "modifier"
14
+ },
15
+ {
16
+ "tagName": "@beta",
17
+ "syntaxKind": "modifier"
18
+ },
19
+ {
20
+ "tagName": "@defaultValue",
21
+ "syntaxKind": "block"
22
+ },
23
+ {
24
+ "tagName": "@decorator",
25
+ "syntaxKind": "block",
26
+ "allowMultiple": true
27
+ },
28
+ {
29
+ "tagName": "@deprecated",
30
+ "syntaxKind": "block"
31
+ },
32
+ {
33
+ "tagName": "@eventProperty",
34
+ "syntaxKind": "modifier"
35
+ },
36
+ {
37
+ "tagName": "@example",
38
+ "syntaxKind": "block",
39
+ "allowMultiple": true
40
+ },
41
+ {
42
+ "tagName": "@experimental",
43
+ "syntaxKind": "modifier"
44
+ },
45
+ {
46
+ "tagName": "@inheritDoc",
47
+ "syntaxKind": "inline"
48
+ },
49
+ {
50
+ "tagName": "@internal",
51
+ "syntaxKind": "modifier"
52
+ },
53
+ {
54
+ "tagName": "@label",
55
+ "syntaxKind": "inline"
56
+ },
57
+ {
58
+ "tagName": "@link",
59
+ "syntaxKind": "inline",
60
+ "allowMultiple": true
61
+ },
62
+ {
63
+ "tagName": "@override",
64
+ "syntaxKind": "modifier"
65
+ },
66
+ {
67
+ "tagName": "@packageDocumentation",
68
+ "syntaxKind": "modifier"
69
+ },
70
+ {
71
+ "tagName": "@param",
72
+ "syntaxKind": "block",
73
+ "allowMultiple": true
74
+ },
75
+ {
76
+ "tagName": "@privateRemarks",
77
+ "syntaxKind": "block"
78
+ },
79
+ {
80
+ "tagName": "@public",
81
+ "syntaxKind": "modifier"
82
+ },
83
+ {
84
+ "tagName": "@readonly",
85
+ "syntaxKind": "modifier"
86
+ },
87
+ {
88
+ "tagName": "@remarks",
89
+ "syntaxKind": "block"
90
+ },
91
+ {
92
+ "tagName": "@returns",
93
+ "syntaxKind": "block"
94
+ },
95
+ {
96
+ "tagName": "@sealed",
97
+ "syntaxKind": "modifier"
98
+ },
99
+ {
100
+ "tagName": "@see",
101
+ "syntaxKind": "block"
102
+ },
103
+ {
104
+ "tagName": "@throws",
105
+ "syntaxKind": "block",
106
+ "allowMultiple": true
107
+ },
108
+ {
109
+ "tagName": "@typeParam",
110
+ "syntaxKind": "block",
111
+ "allowMultiple": true
112
+ },
113
+ {
114
+ "tagName": "@virtual",
115
+ "syntaxKind": "modifier"
116
+ },
117
+ {
118
+ "tagName": "@betaDocumentation",
119
+ "syntaxKind": "modifier"
120
+ },
121
+ {
122
+ "tagName": "@internalRemarks",
123
+ "syntaxKind": "block"
124
+ },
125
+ {
126
+ "tagName": "@preapproved",
127
+ "syntaxKind": "modifier"
128
+ }
129
+ ],
130
+ "supportForTags": {
131
+ "@alpha": true,
132
+ "@beta": true,
133
+ "@defaultValue": true,
134
+ "@decorator": true,
135
+ "@deprecated": true,
136
+ "@eventProperty": true,
137
+ "@example": true,
138
+ "@experimental": true,
139
+ "@inheritDoc": true,
140
+ "@internal": true,
141
+ "@label": true,
142
+ "@link": true,
143
+ "@override": true,
144
+ "@packageDocumentation": true,
145
+ "@param": true,
146
+ "@privateRemarks": true,
147
+ "@public": true,
148
+ "@readonly": true,
149
+ "@remarks": true,
150
+ "@returns": true,
151
+ "@sealed": true,
152
+ "@see": true,
153
+ "@throws": true,
154
+ "@typeParam": true,
155
+ "@virtual": true,
156
+ "@betaDocumentation": true,
157
+ "@internalRemarks": true,
158
+ "@preapproved": true
159
+ },
160
+ "reportUnsupportedHtmlElements": false
161
+ }
162
+ },
163
+ "kind": "Package",
164
+ "canonicalReference": "@valiantys/atlassian-app-frontend!",
165
+ "docComment": "",
166
+ "name": "@valiantys/atlassian-app-frontend",
167
+ "preserveMemberOrder": false,
168
+ "members": [
169
+ {
170
+ "kind": "EntryPoint",
171
+ "canonicalReference": "@valiantys/atlassian-app-frontend!",
172
+ "name": "",
173
+ "preserveMemberOrder": false,
174
+ "members": [
175
+ {
176
+ "kind": "Class",
177
+ "canonicalReference": "@valiantys/atlassian-app-frontend!JiraServerInfoService:class",
178
+ "docComment": "",
179
+ "excerptTokens": [
180
+ {
181
+ "kind": "Content",
182
+ "text": "export declare class JiraServerInfoService "
183
+ }
184
+ ],
185
+ "fileUrlPath": "../../jira/shared/data-access-serverinfo/src/lib/jira-server-info-service.d.ts",
186
+ "releaseTag": "Public",
187
+ "isAbstract": false,
188
+ "name": "JiraServerInfoService",
189
+ "preserveMemberOrder": false,
190
+ "members": [
191
+ {
192
+ "kind": "Constructor",
193
+ "canonicalReference": "@valiantys/atlassian-app-frontend!JiraServerInfoService:constructor(1)",
194
+ "docComment": "/**\n * Constructs a new instance of the `JiraServerInfoService` class\n */\n",
195
+ "excerptTokens": [
196
+ {
197
+ "kind": "Content",
198
+ "text": "constructor(fetchSvc: "
199
+ },
200
+ {
201
+ "kind": "Reference",
202
+ "text": "AtlassianProductFetchService",
203
+ "canonicalReference": "@valiantys/atlassian-app-frontend!~AtlassianProductFetchService:interface"
204
+ },
205
+ {
206
+ "kind": "Content",
207
+ "text": "<'jira'>"
208
+ },
209
+ {
210
+ "kind": "Content",
211
+ "text": ");"
212
+ }
213
+ ],
214
+ "releaseTag": "Public",
215
+ "isProtected": false,
216
+ "overloadIndex": 1,
217
+ "parameters": [
218
+ {
219
+ "parameterName": "fetchSvc",
220
+ "parameterTypeTokenRange": {
221
+ "startIndex": 1,
222
+ "endIndex": 3
223
+ },
224
+ "isOptional": false
225
+ }
226
+ ]
227
+ },
228
+ {
229
+ "kind": "Method",
230
+ "canonicalReference": "@valiantys/atlassian-app-frontend!JiraServerInfoService#getServerInfo:member(1)",
231
+ "docComment": "",
232
+ "excerptTokens": [
233
+ {
234
+ "kind": "Content",
235
+ "text": "getServerInfo(): "
236
+ },
237
+ {
238
+ "kind": "Reference",
239
+ "text": "Promise",
240
+ "canonicalReference": "!Promise:interface"
241
+ },
242
+ {
243
+ "kind": "Content",
244
+ "text": "<"
245
+ },
246
+ {
247
+ "kind": "Reference",
248
+ "text": "JiraServerInfo",
249
+ "canonicalReference": "@valiantys/atlassian-app-frontend!~JiraServerInfo:interface"
250
+ },
251
+ {
252
+ "kind": "Content",
253
+ "text": ">"
254
+ },
255
+ {
256
+ "kind": "Content",
257
+ "text": ";"
258
+ }
259
+ ],
260
+ "isStatic": false,
261
+ "returnTypeTokenRange": {
262
+ "startIndex": 1,
263
+ "endIndex": 5
264
+ },
265
+ "releaseTag": "Public",
266
+ "isProtected": false,
267
+ "overloadIndex": 1,
268
+ "parameters": [],
269
+ "isOptional": false,
270
+ "isAbstract": false,
271
+ "name": "getServerInfo"
272
+ },
273
+ {
274
+ "kind": "Property",
275
+ "canonicalReference": "@valiantys/atlassian-app-frontend!JiraServerInfoService.serverInfoUrl:member",
276
+ "docComment": "",
277
+ "excerptTokens": [
278
+ {
279
+ "kind": "Content",
280
+ "text": "static readonly serverInfoUrl = "
281
+ },
282
+ {
283
+ "kind": "Content",
284
+ "text": "\"/rest/api/3/serverInfo\""
285
+ },
286
+ {
287
+ "kind": "Content",
288
+ "text": ";"
289
+ }
290
+ ],
291
+ "isReadonly": true,
292
+ "isOptional": false,
293
+ "releaseTag": "Public",
294
+ "name": "serverInfoUrl",
295
+ "propertyTypeTokenRange": {
296
+ "startIndex": 0,
297
+ "endIndex": 0
298
+ },
299
+ "initializerTokenRange": {
300
+ "startIndex": 1,
301
+ "endIndex": 2
302
+ },
303
+ "isStatic": true,
304
+ "isProtected": false,
305
+ "isAbstract": false
306
+ },
307
+ {
308
+ "kind": "Method",
309
+ "canonicalReference": "@valiantys/atlassian-app-frontend!JiraServerInfoService#switchAtlassianApiUrlToUseSiteUrl:member(1)",
310
+ "docComment": "",
311
+ "excerptTokens": [
312
+ {
313
+ "kind": "Content",
314
+ "text": "switchAtlassianApiUrlToUseSiteUrl(apiDotAtlassianUrl: "
315
+ },
316
+ {
317
+ "kind": "Content",
318
+ "text": "string"
319
+ },
320
+ {
321
+ "kind": "Content",
322
+ "text": "): "
323
+ },
324
+ {
325
+ "kind": "Reference",
326
+ "text": "Promise",
327
+ "canonicalReference": "!Promise:interface"
328
+ },
329
+ {
330
+ "kind": "Content",
331
+ "text": "<string>"
332
+ },
333
+ {
334
+ "kind": "Content",
335
+ "text": ";"
336
+ }
337
+ ],
338
+ "isStatic": false,
339
+ "returnTypeTokenRange": {
340
+ "startIndex": 3,
341
+ "endIndex": 5
342
+ },
343
+ "releaseTag": "Public",
344
+ "isProtected": false,
345
+ "overloadIndex": 1,
346
+ "parameters": [
347
+ {
348
+ "parameterName": "apiDotAtlassianUrl",
349
+ "parameterTypeTokenRange": {
350
+ "startIndex": 1,
351
+ "endIndex": 2
352
+ },
353
+ "isOptional": false
354
+ }
355
+ ],
356
+ "isOptional": false,
357
+ "isAbstract": false,
358
+ "name": "switchAtlassianApiUrlToUseSiteUrl"
359
+ }
360
+ ],
361
+ "implementsTokenRanges": []
362
+ }
363
+ ]
364
+ }
365
+ ]
366
+ }
@@ -0,0 +1,23 @@
1
+ ## API Report File for "@valiantys/atlassian-app-frontend"
2
+
3
+ > Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/).
4
+
5
+ ```ts
6
+
7
+ // @public (undocumented)
8
+ export class JiraServerInfoService {
9
+ // Warning: (ae-forgotten-export) The symbol "AtlassianProductFetchService" needs to be exported by the entry point data-access-serverinfo.d.ts
10
+ constructor(fetchSvc: AtlassianProductFetchService<'jira'>);
11
+ // Warning: (ae-forgotten-export) The symbol "JiraServerInfo" needs to be exported by the entry point data-access-serverinfo.d.ts
12
+ //
13
+ // (undocumented)
14
+ getServerInfo(): Promise<JiraServerInfo>;
15
+ // (undocumented)
16
+ static readonly serverInfoUrl = "/rest/api/3/serverInfo";
17
+ // (undocumented)
18
+ switchAtlassianApiUrlToUseSiteUrl(apiDotAtlassianUrl: string): Promise<string>;
19
+ }
20
+
21
+ // (No @packageDocumentation comment for this package)
22
+
23
+ ```
@@ -0,0 +1 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../atlassian/jira/shared/data-access-serverinfo/src/lib/jira-server-info-service/index.cjs.js");exports.JiraServerInfoService=e.JiraServerInfoService;
@@ -0,0 +1,61 @@
1
+ declare type APIResponse = Pick<Response, 'json' | 'text' | 'ok' | 'status' | 'statusText' | 'headers'>;
2
+
3
+ declare interface AtlassianProductFetchService<P extends Product> {
4
+ productType: P;
5
+ fetch: FetchSignature;
6
+ route: (template: TemplateStringsArray, ...parameters: (string | number | URLSearchParams | FetchRoute)[]) => FetchRoute;
7
+ rawFetch: RequestProductMethod;
8
+ fullUrl: (path: string) => string;
9
+ }
10
+
11
+ declare type FetchMethod = 'POST' | 'GET' | 'PUT' | 'DELETE' | 'PATCH';
12
+
13
+ declare interface FetchRequest {
14
+ method: FetchMethod;
15
+ url: FetchRoute;
16
+ responseType?: 'json' | 'text';
17
+ allowExperimental?: boolean;
18
+ }
19
+
20
+ declare type FetchRoute = {
21
+ readonly value: string;
22
+ };
23
+
24
+ declare type FetchSignature = <T>(request: FetchRequest, body?: any) => Promise<T>;
25
+
26
+ declare interface HealthCheckResult {
27
+ description: string;
28
+ name: string;
29
+ passed: boolean;
30
+ }
31
+
32
+ declare interface JiraServerInfo {
33
+ baseUrl: string;
34
+ buildDate: string;
35
+ buildNumber: number;
36
+ deploymentType: string;
37
+ displayUrl: string;
38
+ displayUrlConfluence: string;
39
+ displayUrlServicedeskHelpCenter: string;
40
+ healthChecks: HealthCheckResult[];
41
+ scmInfo: string;
42
+ serverTime: string;
43
+ serverTimeZone: string;
44
+ serverTitle: string;
45
+ version: string;
46
+ versionNumbers: number[];
47
+ }
48
+
49
+ export declare class JiraServerInfoService {
50
+ private fetchSvc;
51
+ static readonly serverInfoUrl = "/rest/api/3/serverInfo";
52
+ constructor(fetchSvc: AtlassianProductFetchService<'jira'>);
53
+ getServerInfo(): Promise<JiraServerInfo>;
54
+ switchAtlassianApiUrlToUseSiteUrl(apiDotAtlassianUrl: string): Promise<string>;
55
+ }
56
+
57
+ declare type Product = 'jira' | 'bitbucket' | 'confluence' | 'connected-data';
58
+
59
+ declare type RequestProductMethod = (url: FetchRoute, init: RequestInit) => Promise<APIResponse>;
60
+
61
+ export { }
@@ -0,0 +1,4 @@
1
+ import { JiraServerInfoService as o } from "../atlassian/jira/shared/data-access-serverinfo/src/lib/jira-server-info-service/index.es.js";
2
+ export {
3
+ o as JiraServerInfoService
4
+ };
@@ -0,0 +1,11 @@
1
+ // This file is read by tools that parse documentation comments conforming to the TSDoc standard.
2
+ // It should be published with your NPM package. It should not be tracked by Git.
3
+ {
4
+ "tsdocVersion": "0.12",
5
+ "toolPackages": [
6
+ {
7
+ "packageName": "@microsoft/api-extractor",
8
+ "packageVersion": "7.52.8"
9
+ }
10
+ ]
11
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@valiantys/atlassian-app-frontend",
3
- "version": "3.1.0-alpha-4",
3
+ "version": "3.1.0-alpha-5",
4
4
  "description": "This library provides an Atlassian Forge Custom UI wrapper component that handles all the setup necessary to support an app that can run deployed or in standalone mode",
5
5
  "exports": {
6
6
  "./atlassian-app": {
@@ -53,6 +53,11 @@
53
53
  "require": "./data-access-resources/index.cjs.js",
54
54
  "types": "./data-access-resources/index.d.ts"
55
55
  },
56
+ "./data-access-serverinfo": {
57
+ "import": "./data-access-serverinfo/index.es.js",
58
+ "require": "./data-access-serverinfo/index.cjs.js",
59
+ "types": "./data-access-serverinfo/index.d.ts"
60
+ },
56
61
  "./data-access-workspaces": {
57
62
  "import": "./data-access-workspaces/index.es.js",
58
63
  "require": "./data-access-workspaces/index.cjs.js",