Skip to content

Commit

Permalink
Merge pull request galaxyproject#19041 from jmchilton/toolshed_fixes
Browse files Browse the repository at this point in the history
UI Improvements for Tool Shed 2.0
  • Loading branch information
mvdbeek authored Oct 23, 2024
2 parents 051c5ab + 93df8de commit e6d1b30
Show file tree
Hide file tree
Showing 3 changed files with 80 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ const categoryName = computed(() => {
const query = graphql(/* GraphQL */ `
query repositoriesByCategory($categoryId: String, $cursor: String) {
relayRepositoriesForCategory(encodedId: $categoryId, sort: UPDATE_TIME_DESC, first: 10, after: $cursor) {
relayRepositoriesForCategory(encodedId: $categoryId, sort: NAME_ASC, first: 10, after: $cursor) {
edges {
cursor
node {
Expand Down
6 changes: 3 additions & 3 deletions lib/tool_shed/webapp/frontend/src/gql/gql.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ const documents = {
types.RecentRepositoryUpdatesDocument,
"\n query repositoriesByOwner($username: String, $cursor: String) {\n relayRepositoriesForOwner(username: $username, sort: UPDATE_TIME_DESC, first: 10, after: $cursor) {\n edges {\n cursor\n node {\n ...RepositoryListItemFragment\n }\n }\n pageInfo {\n endCursor\n hasNextPage\n }\n }\n }\n":
types.RepositoriesByOwnerDocument,
"\n query repositoriesByCategory($categoryId: String, $cursor: String) {\n relayRepositoriesForCategory(encodedId: $categoryId, sort: UPDATE_TIME_DESC, first: 10, after: $cursor) {\n edges {\n cursor\n node {\n ...RepositoryListItemFragment\n }\n }\n pageInfo {\n endCursor\n hasNextPage\n }\n }\n }\n":
"\n query repositoriesByCategory($categoryId: String, $cursor: String) {\n relayRepositoriesForCategory(encodedId: $categoryId, sort: NAME_ASC, first: 10, after: $cursor) {\n edges {\n cursor\n node {\n ...RepositoryListItemFragment\n }\n }\n pageInfo {\n endCursor\n hasNextPage\n }\n }\n }\n":
types.RepositoriesByCategoryDocument,
"\n fragment RepositoryListItemFragment on RelayRepository {\n encodedId\n name\n user {\n username\n }\n description\n type\n updateTime\n homepageUrl\n remoteRepositoryUrl\n }\n":
types.RepositoryListItemFragmentFragmentDoc,
Expand Down Expand Up @@ -65,8 +65,8 @@ export function graphql(
* The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.
*/
export function graphql(
source: "\n query repositoriesByCategory($categoryId: String, $cursor: String) {\n relayRepositoriesForCategory(encodedId: $categoryId, sort: UPDATE_TIME_DESC, first: 10, after: $cursor) {\n edges {\n cursor\n node {\n ...RepositoryListItemFragment\n }\n }\n pageInfo {\n endCursor\n hasNextPage\n }\n }\n }\n"
): (typeof documents)["\n query repositoriesByCategory($categoryId: String, $cursor: String) {\n relayRepositoriesForCategory(encodedId: $categoryId, sort: UPDATE_TIME_DESC, first: 10, after: $cursor) {\n edges {\n cursor\n node {\n ...RepositoryListItemFragment\n }\n }\n pageInfo {\n endCursor\n hasNextPage\n }\n }\n }\n"]
source: "\n query repositoriesByCategory($categoryId: String, $cursor: String) {\n relayRepositoriesForCategory(encodedId: $categoryId, sort: NAME_ASC, first: 10, after: $cursor) {\n edges {\n cursor\n node {\n ...RepositoryListItemFragment\n }\n }\n pageInfo {\n endCursor\n hasNextPage\n }\n }\n }\n"
): (typeof documents)["\n query repositoriesByCategory($categoryId: String, $cursor: String) {\n relayRepositoriesForCategory(encodedId: $categoryId, sort: NAME_ASC, first: 10, after: $cursor) {\n edges {\n cursor\n node {\n ...RepositoryListItemFragment\n }\n }\n pageInfo {\n endCursor\n hasNextPage\n }\n }\n }\n"]
/**
* The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.
*/
Expand Down
77 changes: 76 additions & 1 deletion lib/tool_shed/webapp/frontend/src/gql/graphql.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,27 @@ export type Scalars = {
DateTime: any
}

export type BooleanFilter = {
eq?: InputMaybe<Scalars["Boolean"]>
in?: InputMaybe<Array<InputMaybe<Scalars["Boolean"]>>>
nEq?: InputMaybe<Scalars["Boolean"]>
notIn?: InputMaybe<Array<InputMaybe<Scalars["Boolean"]>>>
}

export type DefaultDateTimeScalarFilter = {
eq?: InputMaybe<Scalars["DateTime"]>
in?: InputMaybe<Array<InputMaybe<Scalars["DateTime"]>>>
nEq?: InputMaybe<Scalars["DateTime"]>
notIn?: InputMaybe<Array<InputMaybe<Scalars["DateTime"]>>>
}

export type IdFilter = {
eq?: InputMaybe<Scalars["ID"]>
in?: InputMaybe<Array<InputMaybe<Scalars["ID"]>>>
nEq?: InputMaybe<Scalars["ID"]>
notIn?: InputMaybe<Array<InputMaybe<Scalars["ID"]>>>
}

/** An object with an ID */
export type Node = {
/** The ID of the object */
Expand Down Expand Up @@ -61,6 +82,7 @@ export type QueryNodeArgs = {
export type QueryRelayCategoriesArgs = {
after?: InputMaybe<Scalars["String"]>
before?: InputMaybe<Scalars["String"]>
filter?: InputMaybe<RelayCategoryFilter>
first?: InputMaybe<Scalars["Int"]>
last?: InputMaybe<Scalars["Int"]>
sort?: InputMaybe<Array<InputMaybe<RelayCategorySortEnum>>>
Expand All @@ -69,6 +91,7 @@ export type QueryRelayCategoriesArgs = {
export type QueryRelayRepositoriesArgs = {
after?: InputMaybe<Scalars["String"]>
before?: InputMaybe<Scalars["String"]>
filter?: InputMaybe<RelayRepositoryFilter>
first?: InputMaybe<Scalars["Int"]>
last?: InputMaybe<Scalars["Int"]>
sort?: InputMaybe<Array<InputMaybe<RelayRepositorySortEnum>>>
Expand All @@ -78,6 +101,7 @@ export type QueryRelayRepositoriesForCategoryArgs = {
after?: InputMaybe<Scalars["String"]>
before?: InputMaybe<Scalars["String"]>
encodedId?: InputMaybe<Scalars["String"]>
filter?: InputMaybe<RelayRepositoryFilter>
first?: InputMaybe<Scalars["Int"]>
id?: InputMaybe<Scalars["Int"]>
last?: InputMaybe<Scalars["Int"]>
Expand All @@ -87,6 +111,7 @@ export type QueryRelayRepositoriesForCategoryArgs = {
export type QueryRelayRepositoriesForOwnerArgs = {
after?: InputMaybe<Scalars["String"]>
before?: InputMaybe<Scalars["String"]>
filter?: InputMaybe<RelayRepositoryFilter>
first?: InputMaybe<Scalars["Int"]>
last?: InputMaybe<Scalars["Int"]>
sort?: InputMaybe<Array<InputMaybe<RelayRepositorySortEnum>>>
Expand All @@ -96,6 +121,7 @@ export type QueryRelayRepositoriesForOwnerArgs = {
export type QueryRelayRevisionsArgs = {
after?: InputMaybe<Scalars["String"]>
before?: InputMaybe<Scalars["String"]>
filter?: InputMaybe<RelayRepositoryMetadataFilter>
first?: InputMaybe<Scalars["Int"]>
last?: InputMaybe<Scalars["Int"]>
sort?: InputMaybe<Array<InputMaybe<RelayRepositoryMetadataSortEnum>>>
Expand All @@ -104,6 +130,7 @@ export type QueryRelayRevisionsArgs = {
export type QueryRelayUsersArgs = {
after?: InputMaybe<Scalars["String"]>
before?: InputMaybe<Scalars["String"]>
filter?: InputMaybe<RelayUserFilter>
first?: InputMaybe<Scalars["Int"]>
last?: InputMaybe<Scalars["Int"]>
sort?: InputMaybe<Array<InputMaybe<RelayUserSortEnum>>>
Expand Down Expand Up @@ -138,6 +165,17 @@ export type RelayCategoryEdge = {
node?: Maybe<RelayCategory>
}

export type RelayCategoryFilter = {
and?: InputMaybe<Array<InputMaybe<RelayCategoryFilter>>>
createTime?: InputMaybe<DefaultDateTimeScalarFilter>
deleted?: InputMaybe<BooleanFilter>
description?: InputMaybe<StringFilter>
id?: InputMaybe<IdFilter>
name?: InputMaybe<StringFilter>
or?: InputMaybe<Array<InputMaybe<RelayCategoryFilter>>>
updateTime?: InputMaybe<DefaultDateTimeScalarFilter>
}

/** An enumeration. */
export enum RelayCategorySortEnum {
CreateTimeAsc = "CREATE_TIME_ASC",
Expand Down Expand Up @@ -187,6 +225,20 @@ export type RelayRepositoryEdge = {
node?: Maybe<RelayRepository>
}

export type RelayRepositoryFilter = {
and?: InputMaybe<Array<InputMaybe<RelayRepositoryFilter>>>
createTime?: InputMaybe<DefaultDateTimeScalarFilter>
description?: InputMaybe<StringFilter>
homepageUrl?: InputMaybe<StringFilter>
id?: InputMaybe<IdFilter>
longDescription?: InputMaybe<StringFilter>
name?: InputMaybe<StringFilter>
or?: InputMaybe<Array<InputMaybe<RelayRepositoryFilter>>>
remoteRepositoryUrl?: InputMaybe<StringFilter>
type?: InputMaybe<StringFilter>
updateTime?: InputMaybe<DefaultDateTimeScalarFilter>
}

export type RelayRepositoryMetadata = Node & {
__typename?: "RelayRepositoryMetadata"
changesetRevision: Scalars["String"]
Expand Down Expand Up @@ -217,6 +269,12 @@ export type RelayRepositoryMetadataEdge = {
node?: Maybe<RelayRepositoryMetadata>
}

export type RelayRepositoryMetadataFilter = {
and?: InputMaybe<Array<InputMaybe<RelayRepositoryMetadataFilter>>>
id?: InputMaybe<IdFilter>
or?: InputMaybe<Array<InputMaybe<RelayRepositoryMetadataFilter>>>
}

/** An enumeration. */
export enum RelayRepositoryMetadataSortEnum {
IdAsc = "ID_ASC",
Expand Down Expand Up @@ -269,6 +327,13 @@ export type RelayUserEdge = {
node?: Maybe<RelayUser>
}

export type RelayUserFilter = {
and?: InputMaybe<Array<InputMaybe<RelayUserFilter>>>
id?: InputMaybe<IdFilter>
or?: InputMaybe<Array<InputMaybe<RelayUserFilter>>>
username?: InputMaybe<StringFilter>
}

/** An enumeration. */
export enum RelayUserSortEnum {
IdAsc = "ID_ASC",
Expand Down Expand Up @@ -327,6 +392,16 @@ export type SimpleUser = {
username: Scalars["String"]
}

export type StringFilter = {
eq?: InputMaybe<Scalars["String"]>
ilike?: InputMaybe<Scalars["String"]>
in?: InputMaybe<Array<InputMaybe<Scalars["String"]>>>
like?: InputMaybe<Scalars["String"]>
nEq?: InputMaybe<Scalars["String"]>
notIn?: InputMaybe<Array<InputMaybe<Scalars["String"]>>>
notlike?: InputMaybe<Scalars["String"]>
}

export type RecentlyCreatedRepositoriesQueryVariables = Exact<{ [key: string]: never }>

export type RecentlyCreatedRepositoriesQuery = {
Expand Down Expand Up @@ -760,7 +835,7 @@ export const RepositoriesByCategoryDocument = {
{
kind: "Argument",
name: { kind: "Name", value: "sort" },
value: { kind: "EnumValue", value: "UPDATE_TIME_DESC" },
value: { kind: "EnumValue", value: "NAME_ASC" },
},
{
kind: "Argument",
Expand Down

0 comments on commit e6d1b30

Please sign in to comment.