@atlaskit/rovo-agent-selector 2.1.0 → 3.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.
- package/CHANGELOG.md +33 -1
- package/package.json +9 -16
- package/rovo-agent-selector/package.json +1 -8
- package/types/package.json +1 -8
- package/dist/types-ts4.5/common/utils/generate-mock-agent-edges/index.d.ts +0 -10
- package/dist/types-ts4.5/common/utils/use-suspenseless-refetch/index.d.ts +0 -45
- package/dist/types-ts4.5/entry-points/rovo-agent-selector.d.ts +0 -1
- package/dist/types-ts4.5/entry-points/types.d.ts +0 -1
- package/dist/types-ts4.5/index.d.ts +0 -2
- package/dist/types-ts4.5/ui/rovo-agent-selector/__generated__/rovoAgentSelectorInternal_AtlaskitRovoAgentSelectorPaginationQuery.graphql.d.ts +0 -35
- package/dist/types-ts4.5/ui/rovo-agent-selector/__generated__/rovoAgentSelector_AtlaskitRovoAgentSelector.graphql.d.ts +0 -32
- package/dist/types-ts4.5/ui/rovo-agent-selector/__generated__/testRovoAgentSelectorQuery.graphql.d.ts +0 -21
- package/dist/types-ts4.5/ui/rovo-agent-selector/index.d.ts +0 -7
- package/dist/types-ts4.5/ui/rovo-agent-selector/messages.d.ts +0 -18
- package/dist/types-ts4.5/ui/rovo-agent-selector/types.d.ts +0 -41
package/CHANGELOG.md
CHANGED
|
@@ -1,10 +1,42 @@
|
|
|
1
1
|
# @atlaskit/rovo-agent-selector
|
|
2
2
|
|
|
3
|
+
## 3.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
|
+
|
|
29
|
+
## 2.1.1
|
|
30
|
+
|
|
31
|
+
### Patch Changes
|
|
32
|
+
|
|
33
|
+
- Updated dependencies
|
|
34
|
+
|
|
3
35
|
## 2.1.0
|
|
4
36
|
|
|
5
37
|
### Minor Changes
|
|
6
38
|
|
|
7
|
-
- [`
|
|
39
|
+
- [`ebab8f80bfc40`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/ebab8f80bfc40) -
|
|
8
40
|
Autofix: add explicit package exports (barrel removal)
|
|
9
41
|
|
|
10
42
|
## 2.0.1
|
package/package.json
CHANGED
|
@@ -11,25 +11,17 @@
|
|
|
11
11
|
"module": "dist/esm/index.js",
|
|
12
12
|
"module:es2019": "dist/es2019/index.js",
|
|
13
13
|
"types": "dist/types/index.d.ts",
|
|
14
|
-
"typesVersions": {
|
|
15
|
-
">=4.5 <5.9": {
|
|
16
|
-
"*": [
|
|
17
|
-
"dist/types-ts4.5/*",
|
|
18
|
-
"dist/types-ts4.5/index.d.ts"
|
|
19
|
-
]
|
|
20
|
-
}
|
|
21
|
-
},
|
|
22
14
|
"sideEffects": [
|
|
23
15
|
"*.compiled.css"
|
|
24
16
|
],
|
|
25
17
|
"atlaskit:src": "src/index.ts",
|
|
26
18
|
"dependencies": {
|
|
27
|
-
"@atlaskit/css": "^0.
|
|
28
|
-
"@atlaskit/form": "^
|
|
29
|
-
"@atlaskit/platform-feature-flags": "^
|
|
30
|
-
"@atlaskit/primitives": "^
|
|
31
|
-
"@atlaskit/rovo-agent-components": "^
|
|
32
|
-
"@atlaskit/select": "^
|
|
19
|
+
"@atlaskit/css": "^1.0.0",
|
|
20
|
+
"@atlaskit/form": "^16.0.0",
|
|
21
|
+
"@atlaskit/platform-feature-flags": "^2.0.0",
|
|
22
|
+
"@atlaskit/primitives": "^20.0.0",
|
|
23
|
+
"@atlaskit/rovo-agent-components": "^6.0.0",
|
|
24
|
+
"@atlaskit/select": "^22.0.0",
|
|
33
25
|
"@babel/runtime": "^7.0.0",
|
|
34
26
|
"@compiled/react": "^0.20.0",
|
|
35
27
|
"react-relay": "^20.1.1",
|
|
@@ -44,7 +36,8 @@
|
|
|
44
36
|
"@af/suppress-react-warnings": "workspace:^",
|
|
45
37
|
"@af/visual-regression": "workspace:^",
|
|
46
38
|
"@atlaskit/ssr": "workspace:^",
|
|
47
|
-
"@atlassian/testing-library": "^0.
|
|
39
|
+
"@atlassian/testing-library": "^0.6.0",
|
|
40
|
+
"react": "^18.2.0",
|
|
48
41
|
"react-dom": "^18.2.0",
|
|
49
42
|
"react-intl": "^6.6.2",
|
|
50
43
|
"react-magnetic-di": "^3.1.4",
|
|
@@ -89,7 +82,7 @@
|
|
|
89
82
|
}
|
|
90
83
|
},
|
|
91
84
|
"name": "@atlaskit/rovo-agent-selector",
|
|
92
|
-
"version": "
|
|
85
|
+
"version": "3.0.0",
|
|
93
86
|
"description": "rovo agent selector",
|
|
94
87
|
"author": "Atlassian Pty Ltd",
|
|
95
88
|
"license": "Apache-2.0",
|
|
@@ -6,12 +6,5 @@
|
|
|
6
6
|
"sideEffects": [
|
|
7
7
|
"*.compiled.css"
|
|
8
8
|
],
|
|
9
|
-
"types": "../dist/types/entry-points/rovo-agent-selector.d.ts"
|
|
10
|
-
"typesVersions": {
|
|
11
|
-
">=4.5 <5.9": {
|
|
12
|
-
"*": [
|
|
13
|
-
"../dist/types-ts4.5/entry-points/rovo-agent-selector.d.ts"
|
|
14
|
-
]
|
|
15
|
-
}
|
|
16
|
-
}
|
|
9
|
+
"types": "../dist/types/entry-points/rovo-agent-selector.d.ts"
|
|
17
10
|
}
|
package/types/package.json
CHANGED
|
@@ -6,12 +6,5 @@
|
|
|
6
6
|
"sideEffects": [
|
|
7
7
|
"*.compiled.css"
|
|
8
8
|
],
|
|
9
|
-
"types": "../dist/types/entry-points/types.d.ts"
|
|
10
|
-
"typesVersions": {
|
|
11
|
-
">=4.5 <5.9": {
|
|
12
|
-
"*": [
|
|
13
|
-
"../dist/types-ts4.5/entry-points/types.d.ts"
|
|
14
|
-
]
|
|
15
|
-
}
|
|
16
|
-
}
|
|
9
|
+
"types": "../dist/types/entry-points/types.d.ts"
|
|
17
10
|
}
|
|
@@ -1,45 +0,0 @@
|
|
|
1
|
-
import type { KeyType } from 'react-relay/relay-hooks/helpers';
|
|
2
|
-
import type { RefetchFnDynamic } from 'react-relay/relay-hooks/useRefetchableFragmentNode';
|
|
3
|
-
import type { Subscription } from 'relay-runtime/lib/network/RelayObservable';
|
|
4
|
-
import type { GraphQLTaggedNode } from 'relay-runtime/lib/query/RelayModernGraphQLTag';
|
|
5
|
-
import type { CacheConfig, FetchQueryFetchPolicy, OperationType, Variables } from 'relay-runtime/lib/util/RelayRuntimeTypes';
|
|
6
|
-
type SuspenselessRefetchHookStatelessOptions = {
|
|
7
|
-
setIsLoading?: (newIsLoading: boolean) => void;
|
|
8
|
-
setLastFetchError?: (errorOrNull: Error | null) => void;
|
|
9
|
-
fetchPolicy?: FetchQueryFetchPolicy;
|
|
10
|
-
networkCacheConfig?: CacheConfig;
|
|
11
|
-
};
|
|
12
|
-
export type SuspenselessRefetchFunction<TVariables extends Variables> = (variables: TVariables, options?: {
|
|
13
|
-
onComplete?: () => void;
|
|
14
|
-
}) => Subscription;
|
|
15
|
-
/**
|
|
16
|
-
* Given a refetch function from useRefetchableFragment or usePaginationFragment,
|
|
17
|
-
* returns a new refetch function which will not trigger suspense; and will update
|
|
18
|
-
* local component state for isLoading and lastFetchError as required if setters
|
|
19
|
-
* are supplied.
|
|
20
|
-
*
|
|
21
|
-
* See unit test.js for an example usage in a Relay context.
|
|
22
|
-
*/
|
|
23
|
-
export declare const useSuspenselessRefetchStateless: <TQuery extends OperationType, TKey extends KeyType | null>(query: GraphQLTaggedNode, refetch: RefetchFnDynamic<TQuery, TKey>, { setIsLoading, setLastFetchError, fetchPolicy, networkCacheConfig, }?: SuspenselessRefetchHookStatelessOptions) => SuspenselessRefetchFunction<TQuery["variables"]>;
|
|
24
|
-
type SuspenselessRefetchHookOptions = {
|
|
25
|
-
fetchPolicy?: FetchQueryFetchPolicy;
|
|
26
|
-
networkCacheConfig?: CacheConfig;
|
|
27
|
-
};
|
|
28
|
-
export type SuspenselessRefetchHookReturn<TVariables extends Variables> = [
|
|
29
|
-
SuspenselessRefetchFunction<TVariables>,
|
|
30
|
-
boolean,
|
|
31
|
-
Error | null
|
|
32
|
-
];
|
|
33
|
-
/**
|
|
34
|
-
* Given a refetch function from useRefetchableFragment or usePaginationFragment,
|
|
35
|
-
* returns a new refetch function which will not trigger suspense; Also supplies
|
|
36
|
-
* component state variables:
|
|
37
|
-
* - isLoading: true whenever there's a network request in-progress triggered by the resulting refetch function
|
|
38
|
-
* - lastFetchError: set to any network error resulting from a failed refetch. Cleared to null on a successfull refetch.
|
|
39
|
-
*
|
|
40
|
-
* See unit test.js of the stateless version for an example usage in a Relay context.
|
|
41
|
-
*
|
|
42
|
-
* @returns a tuple (array) containing: the new refetch function, and the aformentioned component state `isLoading` and `lastFetchError`
|
|
43
|
-
*/
|
|
44
|
-
export declare const useSuspenselessRefetch: <TQuery extends OperationType, TKey extends KeyType | null>(query: GraphQLTaggedNode, refetch: RefetchFnDynamic<TQuery, TKey>, options?: SuspenselessRefetchHookOptions) => SuspenselessRefetchHookReturn<TQuery["variables"]>;
|
|
45
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { RovoAgentSelector } from '../ui/rovo-agent-selector/index';
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export type { AgentOption } from '../ui/rovo-agent-selector/types';
|
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @generated SignedSource<<2d585f3ae5be298989545215bd25a826>>
|
|
3
|
-
* @relayHash 10df1400fe5f08dbb71223dbeb55d5d0
|
|
4
|
-
* @lightSyntaxTransform
|
|
5
|
-
* @nogrep
|
|
6
|
-
* @codegen-command: yarn relay
|
|
7
|
-
*/
|
|
8
|
-
import type { ConcreteRequest } from 'relay-runtime';
|
|
9
|
-
import type { FragmentRefs } from "relay-runtime";
|
|
10
|
-
export type AgentStudioAgentQueryInput = {
|
|
11
|
-
includeDraftAgents?: boolean | null | undefined;
|
|
12
|
-
name?: string | null | undefined;
|
|
13
|
-
onlyEditableAgents?: boolean | null | undefined;
|
|
14
|
-
onlyFavouriteAgents?: boolean | null | undefined;
|
|
15
|
-
onlyMyAgents?: boolean | null | undefined;
|
|
16
|
-
onlyPublishedEditableAgents?: boolean | null | undefined;
|
|
17
|
-
onlyTemplateAgents?: boolean | null | undefined;
|
|
18
|
-
onlyUnpublishedAgents?: boolean | null | undefined;
|
|
19
|
-
onlyVerifiedAgents?: boolean | null | undefined;
|
|
20
|
-
};
|
|
21
|
-
export type rovoAgentSelectorInternal_AtlaskitRovoAgentSelectorPaginationQuery$variables = {
|
|
22
|
-
after?: string | null | undefined;
|
|
23
|
-
cloudIdString: string;
|
|
24
|
-
first?: number | null | undefined;
|
|
25
|
-
input?: AgentStudioAgentQueryInput | null | undefined;
|
|
26
|
-
};
|
|
27
|
-
export type rovoAgentSelectorInternal_AtlaskitRovoAgentSelectorPaginationQuery$data = {
|
|
28
|
-
readonly " $fragmentSpreads": FragmentRefs<"rovoAgentSelector_AtlaskitRovoAgentSelector">;
|
|
29
|
-
};
|
|
30
|
-
export type rovoAgentSelectorInternal_AtlaskitRovoAgentSelectorPaginationQuery = {
|
|
31
|
-
response: rovoAgentSelectorInternal_AtlaskitRovoAgentSelectorPaginationQuery$data;
|
|
32
|
-
variables: rovoAgentSelectorInternal_AtlaskitRovoAgentSelectorPaginationQuery$variables;
|
|
33
|
-
};
|
|
34
|
-
declare const node: ConcreteRequest;
|
|
35
|
-
export default node;
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @generated SignedSource<<6d84c2ef6fe3d714ec9001eb7671b9ee>>
|
|
3
|
-
* @lightSyntaxTransform
|
|
4
|
-
* @nogrep
|
|
5
|
-
* @codegen-command: yarn relay
|
|
6
|
-
*/
|
|
7
|
-
import type { ReaderFragment } from 'relay-runtime';
|
|
8
|
-
import type { FragmentRefs } from "relay-runtime";
|
|
9
|
-
export type rovoAgentSelector_AtlaskitRovoAgentSelector$data = {
|
|
10
|
-
readonly agentStudio_getAgents: {
|
|
11
|
-
readonly edges: ReadonlyArray<{
|
|
12
|
-
readonly node: {
|
|
13
|
-
readonly creatorType: string | null | undefined;
|
|
14
|
-
readonly externalConfigReference: string | null | undefined;
|
|
15
|
-
readonly id: string;
|
|
16
|
-
readonly identityAccountId: string | null | undefined;
|
|
17
|
-
readonly name: string | null | undefined;
|
|
18
|
-
} | null | undefined;
|
|
19
|
-
}>;
|
|
20
|
-
readonly pageInfo: {
|
|
21
|
-
readonly endCursor: string | null | undefined;
|
|
22
|
-
readonly hasNextPage: boolean;
|
|
23
|
-
};
|
|
24
|
-
} | null | undefined;
|
|
25
|
-
readonly " $fragmentType": "rovoAgentSelector_AtlaskitRovoAgentSelector";
|
|
26
|
-
};
|
|
27
|
-
export type rovoAgentSelector_AtlaskitRovoAgentSelector$key = {
|
|
28
|
-
readonly " $data"?: rovoAgentSelector_AtlaskitRovoAgentSelector$data;
|
|
29
|
-
readonly " $fragmentSpreads": FragmentRefs<"rovoAgentSelector_AtlaskitRovoAgentSelector">;
|
|
30
|
-
};
|
|
31
|
-
declare const node: ReaderFragment;
|
|
32
|
-
export default node;
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @generated SignedSource<<c045475d115285e64394cca68e4b92eb>>
|
|
3
|
-
* @relayHash 54ab0255fb3bd1dd34e81712bb7cbca7
|
|
4
|
-
* @lightSyntaxTransform
|
|
5
|
-
* @nogrep
|
|
6
|
-
* @codegen-command: yarn relay
|
|
7
|
-
*/
|
|
8
|
-
import type { ConcreteRequest } from 'relay-runtime';
|
|
9
|
-
import type { FragmentRefs } from "relay-runtime";
|
|
10
|
-
export type testRovoAgentSelectorQuery$variables = {
|
|
11
|
-
cloudIdString: string;
|
|
12
|
-
};
|
|
13
|
-
export type testRovoAgentSelectorQuery$data = {
|
|
14
|
-
readonly " $fragmentSpreads": FragmentRefs<"rovoAgentSelector_AtlaskitRovoAgentSelector">;
|
|
15
|
-
};
|
|
16
|
-
export type testRovoAgentSelectorQuery = {
|
|
17
|
-
response: testRovoAgentSelectorQuery$data;
|
|
18
|
-
variables: testRovoAgentSelectorQuery$variables;
|
|
19
|
-
};
|
|
20
|
-
declare const node: ConcreteRequest;
|
|
21
|
-
export default node;
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @jsxRuntime classic
|
|
3
|
-
* @jsx jsx
|
|
4
|
-
*/
|
|
5
|
-
import type { RovoAgentSelectorProps } from './types';
|
|
6
|
-
export declare const AGENT_SELECT_ID = "rovo-agent-select";
|
|
7
|
-
export declare function RovoAgentSelector({ testId, isFeatureEnabled: isFeatureEnabledOverride, fragmentReference, cloudId, selectedAgent, onChange, isLoading: isLoadingOverride, }: RovoAgentSelectorProps): JSX.Element | null;
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
declare const messages: {
|
|
2
|
-
selectorLabel: {
|
|
3
|
-
id: string;
|
|
4
|
-
defaultMessage: string;
|
|
5
|
-
description: string;
|
|
6
|
-
};
|
|
7
|
-
rovoAgentPlaceholder: {
|
|
8
|
-
id: string;
|
|
9
|
-
defaultMessage: string;
|
|
10
|
-
description: string;
|
|
11
|
-
};
|
|
12
|
-
noOptionsMessage: {
|
|
13
|
-
id: string;
|
|
14
|
-
defaultMessage: string;
|
|
15
|
-
description: string;
|
|
16
|
-
};
|
|
17
|
-
};
|
|
18
|
-
export default messages;
|
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
import type { rovoAgentSelector_AtlaskitRovoAgentSelector$key } from './__generated__/rovoAgentSelector_AtlaskitRovoAgentSelector.graphql';
|
|
2
|
-
export type AgentOption = {
|
|
3
|
-
label: string;
|
|
4
|
-
value: string;
|
|
5
|
-
externalConfigReference?: string;
|
|
6
|
-
identityAccountId?: string;
|
|
7
|
-
isForgeAgent: boolean;
|
|
8
|
-
};
|
|
9
|
-
export interface RovoAgentSelectorProps {
|
|
10
|
-
/**
|
|
11
|
-
* A `testId` prop is provided for specified elements, which is a unique
|
|
12
|
-
* string that appears as a data attribute `data-testid` in the rendered code,
|
|
13
|
-
* serving as a hook for automated tests
|
|
14
|
-
*/
|
|
15
|
-
testId?: string;
|
|
16
|
-
/**
|
|
17
|
-
* Override the feature gate check. When provided, this value will be used
|
|
18
|
-
* instead of checking the feature gate. Useful for testing and development.
|
|
19
|
-
*/
|
|
20
|
-
isFeatureEnabled?: boolean;
|
|
21
|
-
/**
|
|
22
|
-
* GraphQL fragment reference for fetching agents
|
|
23
|
-
*/
|
|
24
|
-
fragmentReference: rovoAgentSelector_AtlaskitRovoAgentSelector$key;
|
|
25
|
-
/**
|
|
26
|
-
* Cloud ID for refetching agents
|
|
27
|
-
*/
|
|
28
|
-
cloudId: string;
|
|
29
|
-
/**
|
|
30
|
-
* Currently selected agent (optional)
|
|
31
|
-
*/
|
|
32
|
-
selectedAgent?: AgentOption | null;
|
|
33
|
-
/**
|
|
34
|
-
* Callback when an agent is selected
|
|
35
|
-
*/
|
|
36
|
-
onChange?: (agent: AgentOption | null) => void;
|
|
37
|
-
/**
|
|
38
|
-
* Whether the selector is in a loading state
|
|
39
|
-
*/
|
|
40
|
-
isLoading?: boolean;
|
|
41
|
-
}
|