@atlaskit/link-client-extension 6.1.1 → 7.0.0

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.
Files changed (25) hide show
  1. package/CHANGELOG.md +26 -0
  2. package/dist/types/entry-points/data-source-client-extension-mocks.d.ts +1 -1
  3. package/dist/types/index.d.ts +1 -1
  4. package/package.json +7 -15
  5. package/use-data-source-client-extension/mocks/package.json +1 -8
  6. package/use-data-source-client-extension/package.json +1 -8
  7. package/use-data-source-client-extension/types/package.json +1 -8
  8. package/use-smart-link-client-extension/package.json +1 -8
  9. package/dist/types-ts4.5/entry-points/data-source-client-extension-mocks.d.ts +0 -6
  10. package/dist/types-ts4.5/entry-points/data-source-response-types.d.ts +0 -1
  11. package/dist/types-ts4.5/entry-points/use-data-source-client-extension.d.ts +0 -1
  12. package/dist/types-ts4.5/entry-points/use-smart-link-client-extension.d.ts +0 -1
  13. package/dist/types-ts4.5/index.d.ts +0 -13
  14. package/dist/types-ts4.5/services/use-data-source-client-extension/index.d.ts +0 -13
  15. package/dist/types-ts4.5/services/use-data-source-client-extension/mockActionsDiscoveryEmptyResponse.d.ts +0 -2
  16. package/dist/types-ts4.5/services/use-data-source-client-extension/mockActionsDiscoveryResponse.d.ts +0 -2
  17. package/dist/types-ts4.5/services/use-data-source-client-extension/mockDatasourceDataNoActionsResponse.d.ts +0 -2
  18. package/dist/types-ts4.5/services/use-data-source-client-extension/mockDatasourceDataResponse.d.ts +0 -2
  19. package/dist/types-ts4.5/services/use-data-source-client-extension/mockDatasourceDetailsResponse.d.ts +0 -2
  20. package/dist/types-ts4.5/services/use-data-source-client-extension/mockExecuteActionResponse.d.ts +0 -2
  21. package/dist/types-ts4.5/services/use-data-source-client-extension/mockExecuteActionResponseFailure.d.ts +0 -2
  22. package/dist/types-ts4.5/services/use-data-source-client-extension/mocks.d.ts +0 -2
  23. package/dist/types-ts4.5/services/use-data-source-client-extension/types.d.ts +0 -13
  24. package/dist/types-ts4.5/services/use-resolver-url/index.d.ts +0 -2
  25. package/dist/types-ts4.5/services/use-smart-link-client-extension/index.d.ts +0 -13
package/CHANGELOG.md CHANGED
@@ -1,5 +1,31 @@
1
1
  # @atlaskit/link-client-extension
2
2
 
3
+ ## 7.0.0
4
+
5
+ ### Major Changes
6
+
7
+ - [`f2dc9097319f0`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/f2dc9097319f0) - ###
8
+ Dropped support for _legacy_ Typescript 4 types. **Typescript 5 is now the new minimum**.
9
+
10
+ Removes the `typesVersions` property and `dist/types-ts4.5` directory from the dist.
11
+
12
+ Types are now exclusively via the `"types": "dist/types/index.d.ts"` property.
13
+
14
+ ```diff
15
+ - "typesVersions": {
16
+ - ">=4.5 <4.9": {
17
+ - "*": [
18
+ - "dist/types-ts4.5/*",
19
+ - "dist/types-ts4.5/index.d.ts"
20
+ - ]
21
+ - }
22
+ - },
23
+ ```
24
+
25
+ ### Patch Changes
26
+
27
+ - Updated dependencies
28
+
3
29
  ## 6.1.1
4
30
 
5
31
  ### Patch Changes
@@ -2,5 +2,5 @@ export { mockActionsDiscoveryEmptyResponse } from '../services/use-data-source-c
2
2
  export { mockActionsDiscoveryResponse } from '../services/use-data-source-client-extension/mockActionsDiscoveryResponse';
3
3
  export { mockDatasourceDataNoActionsResponse } from '../services/use-data-source-client-extension/mockDatasourceDataNoActionsResponse';
4
4
  export { mockDatasourceDataResponse } from '../services/use-data-source-client-extension/mockDatasourceDataResponse';
5
- export { mockDatasourceDetailsResponse as mockDatasourceResponse, mockDatasourceDetailsResponse } from '../services/use-data-source-client-extension/mockDatasourceDetailsResponse';
5
+ export { mockDatasourceDetailsResponse as mockDatasourceResponse, mockDatasourceDetailsResponse, } from '../services/use-data-source-client-extension/mockDatasourceDetailsResponse';
6
6
  export { mockDatasourceDataResponseWithSchema } from '../services/use-data-source-client-extension/mocks';
@@ -7,7 +7,7 @@ export { mockActionsDiscoveryEmptyResponse } from './services/use-data-source-cl
7
7
  export { mockActionsDiscoveryResponse } from './services/use-data-source-client-extension/mockActionsDiscoveryResponse';
8
8
  export { mockDatasourceDataNoActionsResponse } from './services/use-data-source-client-extension/mockDatasourceDataNoActionsResponse';
9
9
  export { mockDatasourceDataResponse } from './services/use-data-source-client-extension/mockDatasourceDataResponse';
10
- export { mockDatasourceDetailsResponse as mockDatasourceResponse, mockDatasourceDetailsResponse } from './services/use-data-source-client-extension/mockDatasourceDetailsResponse';
10
+ export { mockDatasourceDetailsResponse as mockDatasourceResponse, mockDatasourceDetailsResponse, } from './services/use-data-source-client-extension/mockDatasourceDetailsResponse';
11
11
  export { mockDatasourceDataResponseWithSchema } from './services/use-data-source-client-extension/mocks';
12
12
  /** @deprecated use @atlaskit/link-client-extension/use-data-source-client-extension/types */
13
13
  export type { JsonLdDatasourceResponse, DatasourceResolveResponse, } from './services/use-data-source-client-extension/types';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/link-client-extension",
3
- "version": "6.1.1",
3
+ "version": "7.0.0",
4
4
  "description": "Extension methods for linking platform client",
5
5
  "author": "Atlassian Pty Ltd",
6
6
  "license": "Apache-2.0",
@@ -25,30 +25,22 @@
25
25
  "module": "dist/esm/index.js",
26
26
  "module:es2019": "dist/es2019/index.js",
27
27
  "types": "dist/types/index.d.ts",
28
- "typesVersions": {
29
- ">=4.5 <4.9": {
30
- "*": [
31
- "dist/types-ts4.5/*",
32
- "dist/types-ts4.5/index.d.ts"
33
- ]
34
- }
35
- },
36
28
  "sideEffects": false,
37
29
  "atlaskit:src": "src/index.ts",
38
30
  "dependencies": {
39
- "@atlaskit/json-ld-types": "^1.5.0",
40
- "@atlaskit/linking-common": "^9.12.0",
41
- "@atlaskit/linking-types": "^14.4.0",
42
- "@atlaskit/platform-feature-flags": "^1.1.0",
31
+ "@atlaskit/json-ld-types": "^2.0.0",
32
+ "@atlaskit/linking-common": "^10.0.0",
33
+ "@atlaskit/linking-types": "^15.0.0",
34
+ "@atlaskit/platform-feature-flags": "^2.0.0",
43
35
  "@babel/runtime": "^7.0.0",
44
36
  "lru_map": "^0.4.1"
45
37
  },
46
38
  "peerDependencies": {
47
- "@atlaskit/link-provider": "^4.4.0",
39
+ "@atlaskit/link-provider": "^5.0.0",
48
40
  "react": "^18.2.0"
49
41
  },
50
42
  "devDependencies": {
51
- "@atlaskit/link-test-helpers": "^10.4.0",
43
+ "@atlaskit/link-test-helpers": "^11.0.0",
52
44
  "@atlassian/feature-flags-test-utils": "^1.1.0",
53
45
  "@atlassian/react-compiler-gating": "workspace:^",
54
46
  "@atlassian/structured-docs-types": "workspace:^",
@@ -4,12 +4,5 @@
4
4
  "module": "../../dist/esm/entry-points/data-source-client-extension-mocks.js",
5
5
  "module:es2019": "../../dist/es2019/entry-points/data-source-client-extension-mocks.js",
6
6
  "sideEffects": false,
7
- "types": "../../dist/types/entry-points/data-source-client-extension-mocks.d.ts",
8
- "typesVersions": {
9
- ">=4.5 <5.9": {
10
- "*": [
11
- "../../dist/types-ts4.5/entry-points/data-source-client-extension-mocks.d.ts"
12
- ]
13
- }
14
- }
7
+ "types": "../../dist/types/entry-points/data-source-client-extension-mocks.d.ts"
15
8
  }
@@ -4,12 +4,5 @@
4
4
  "module": "../dist/esm/entry-points/use-data-source-client-extension.js",
5
5
  "module:es2019": "../dist/es2019/entry-points/use-data-source-client-extension.js",
6
6
  "sideEffects": false,
7
- "types": "../dist/types/entry-points/use-data-source-client-extension.d.ts",
8
- "typesVersions": {
9
- ">=4.5 <5.9": {
10
- "*": [
11
- "../dist/types-ts4.5/entry-points/use-data-source-client-extension.d.ts"
12
- ]
13
- }
14
- }
7
+ "types": "../dist/types/entry-points/use-data-source-client-extension.d.ts"
15
8
  }
@@ -4,12 +4,5 @@
4
4
  "module": "../../dist/esm/entry-points/data-source-response-types.js",
5
5
  "module:es2019": "../../dist/es2019/entry-points/data-source-response-types.js",
6
6
  "sideEffects": false,
7
- "types": "../../dist/types/entry-points/data-source-response-types.d.ts",
8
- "typesVersions": {
9
- ">=4.5 <5.9": {
10
- "*": [
11
- "../../dist/types-ts4.5/entry-points/data-source-response-types.d.ts"
12
- ]
13
- }
14
- }
7
+ "types": "../../dist/types/entry-points/data-source-response-types.d.ts"
15
8
  }
@@ -4,12 +4,5 @@
4
4
  "module": "../dist/esm/entry-points/use-smart-link-client-extension.js",
5
5
  "module:es2019": "../dist/es2019/entry-points/use-smart-link-client-extension.js",
6
6
  "sideEffects": false,
7
- "types": "../dist/types/entry-points/use-smart-link-client-extension.d.ts",
8
- "typesVersions": {
9
- ">=4.5 <5.9": {
10
- "*": [
11
- "../dist/types-ts4.5/entry-points/use-smart-link-client-extension.d.ts"
12
- ]
13
- }
14
- }
7
+ "types": "../dist/types/entry-points/use-smart-link-client-extension.d.ts"
15
8
  }
@@ -1,6 +0,0 @@
1
- export { mockActionsDiscoveryEmptyResponse } from '../services/use-data-source-client-extension/mockActionsDiscoveryEmptyResponse';
2
- export { mockActionsDiscoveryResponse } from '../services/use-data-source-client-extension/mockActionsDiscoveryResponse';
3
- export { mockDatasourceDataNoActionsResponse } from '../services/use-data-source-client-extension/mockDatasourceDataNoActionsResponse';
4
- export { mockDatasourceDataResponse } from '../services/use-data-source-client-extension/mockDatasourceDataResponse';
5
- export { mockDatasourceDetailsResponse as mockDatasourceResponse, mockDatasourceDetailsResponse } from '../services/use-data-source-client-extension/mockDatasourceDetailsResponse';
6
- export { mockDatasourceDataResponseWithSchema } from '../services/use-data-source-client-extension/mocks';
@@ -1 +0,0 @@
1
- export type { JsonLdDatasourceResponse, DatasourceResolveResponse, } from '../services/use-data-source-client-extension/types';
@@ -1 +0,0 @@
1
- export { DEFAULT_GET_DATASOURCE_DATA_PAGE_SIZE, useDatasourceClientExtension, } from '../services/use-data-source-client-extension';
@@ -1 +0,0 @@
1
- export { useSmartLinkClientExtension } from '../services/use-smart-link-client-extension';
@@ -1,13 +0,0 @@
1
- /** @deprecated use @atlaskit/link-client-extension/use-smart-link-client-extension */
2
- export { useSmartLinkClientExtension } from './services/use-smart-link-client-extension';
3
- /** @deprecated use @atlaskit/link-client-extension/use-data-source-client-extension */
4
- export { DEFAULT_GET_DATASOURCE_DATA_PAGE_SIZE, useDatasourceClientExtension, } from './services/use-data-source-client-extension';
5
- /** @deprecated use @atlaskit/link-client-extension/data-source-client-extension/mocks */
6
- export { mockActionsDiscoveryEmptyResponse } from './services/use-data-source-client-extension/mockActionsDiscoveryEmptyResponse';
7
- export { mockActionsDiscoveryResponse } from './services/use-data-source-client-extension/mockActionsDiscoveryResponse';
8
- export { mockDatasourceDataNoActionsResponse } from './services/use-data-source-client-extension/mockDatasourceDataNoActionsResponse';
9
- export { mockDatasourceDataResponse } from './services/use-data-source-client-extension/mockDatasourceDataResponse';
10
- export { mockDatasourceDetailsResponse as mockDatasourceResponse, mockDatasourceDetailsResponse } from './services/use-data-source-client-extension/mockDatasourceDetailsResponse';
11
- export { mockDatasourceDataResponseWithSchema } from './services/use-data-source-client-extension/mocks';
12
- /** @deprecated use @atlaskit/link-client-extension/use-data-source-client-extension/types */
13
- export type { JsonLdDatasourceResponse, DatasourceResolveResponse, } from './services/use-data-source-client-extension/types';
@@ -1,13 +0,0 @@
1
- import { LRUMap } from 'lru_map';
2
- import type { ActionsDiscoveryRequest, ActionsDiscoveryResponse, ActionsServiceDiscoveryResponse, AtomicActionExecuteRequest, AtomicActionExecuteResponse, DatasourceDataRequest, DatasourceDataResponse, DatasourceDetailsRequest, DatasourceDetailsResponse } from '@atlaskit/linking-types';
3
- export declare const datasourceDetailsResponsePromiseCache: LRUMap<string, Promise<DatasourceDetailsResponse>>;
4
- export declare const datasourceDataResponsePromiseCache: LRUMap<string, Promise<DatasourceDataResponse>>;
5
- export declare const datasourceActionsPermissionsPromiseCache: LRUMap<string, Promise<ActionsServiceDiscoveryResponse>>;
6
- export declare const DEFAULT_GET_DATASOURCE_DATA_PAGE_SIZE = 20;
7
- export declare const useDatasourceClientExtension: () => {
8
- executeAtomicAction: (data: AtomicActionExecuteRequest) => Promise<AtomicActionExecuteResponse<unknown>>;
9
- getDatasourceActionsAndPermissions: (data: ActionsDiscoveryRequest, force?: boolean) => Promise<ActionsDiscoveryResponse>;
10
- getDatasourceData: (datasourceId: string, data: DatasourceDataRequest, force?: boolean) => Promise<DatasourceDataResponse>;
11
- getDatasourceDetails: (datasourceId: string, data: DatasourceDetailsRequest, force?: boolean) => Promise<DatasourceDetailsResponse>;
12
- invalidateDatasourceDataCacheByAri: (ari: string) => void;
13
- };
@@ -1,2 +0,0 @@
1
- import { type ActionsServiceDiscoveryResponse } from '@atlaskit/linking-types';
2
- export declare const mockActionsDiscoveryEmptyResponse: ActionsServiceDiscoveryResponse;
@@ -1,2 +0,0 @@
1
- import { type ActionsDiscoveryResponse } from '@atlaskit/linking-types';
2
- export declare const mockActionsDiscoveryResponse: ActionsDiscoveryResponse;
@@ -1,2 +0,0 @@
1
- import { type DatasourceDataResponse } from '@atlaskit/linking-types';
2
- export declare const mockDatasourceDataNoActionsResponse: DatasourceDataResponse;
@@ -1,2 +0,0 @@
1
- import { type DatasourceDataResponse } from '@atlaskit/linking-types';
2
- export declare const mockDatasourceDataResponse: DatasourceDataResponse;
@@ -1,2 +0,0 @@
1
- import { type DatasourceDetailsResponse } from '@atlaskit/linking-types';
2
- export declare const mockDatasourceDetailsResponse: DatasourceDetailsResponse;
@@ -1,2 +0,0 @@
1
- import { type AtomicActionExecuteResponse } from '@atlaskit/linking-types';
2
- export declare const mockExecuteActionResponse: AtomicActionExecuteResponse;
@@ -1,2 +0,0 @@
1
- import { type AtomicActionExecuteResponse } from '@atlaskit/linking-types';
2
- export declare const mockExecuteActionResponseFailure: AtomicActionExecuteResponse;
@@ -1,2 +0,0 @@
1
- import { type DatasourceDataResponse } from '@atlaskit/linking-types';
2
- export declare const mockDatasourceDataResponseWithSchema: DatasourceDataResponse;
@@ -1,13 +0,0 @@
1
- import { type JsonLd } from '@atlaskit/json-ld-types';
2
- import type { DatasourceParameters } from '@atlaskit/linking-types';
3
- export interface JsonLdDatasourceResponse extends JsonLd.Response {
4
- datasources?: DatasourceResolveResponse[];
5
- }
6
- export type DatasourceResolveResponse = {
7
- ari?: string;
8
- description?: string;
9
- id: string;
10
- key?: string;
11
- name?: string;
12
- parameters: DatasourceParameters;
13
- };
@@ -1,2 +0,0 @@
1
- import type { CardClient } from '@atlaskit/link-provider';
2
- export declare const useResolverUrl: (cardClient: CardClient) => string;
@@ -1,13 +0,0 @@
1
- import type { CardClient } from '@atlaskit/link-provider';
2
- import { type InvokeRequest, type InvokeResponse } from '@atlaskit/linking-types/smart-link-actions';
3
- /**
4
- * useSmartLinkClientExtension
5
- *
6
- * This hook extends the usage of @atlaskit/link-provider CardClient
7
- * for smart links.
8
- *
9
- * @param cardClient
10
- */
11
- export declare const useSmartLinkClientExtension: (cardClient: CardClient) => {
12
- invoke: (data: InvokeRequest) => Promise<InvokeResponse>;
13
- };