#import "~/graphql_shared/fragments/epic.fragment.graphql"
#import "~/graphql_shared/fragments/label.fragment.graphql"

query ListEpics(
  $fullPath: ID!
  $boardId: BoardsEpicBoardID!
  $id: BoardsEpicListID
  $after: String
  $first: Int
) {
  group(fullPath: $fullPath) {
    epicBoard(id: $boardId) {
      lists(id: $id) {
        nodes {
          id
          epics(first: $first, after: $after) {
            edges {
              node {
                ...EpicNode
                relativePosition
                referencePath: reference(full: true)
                confidential
                labels {
                  nodes {
                    ...Label
                  }
                }
              }
            }
            pageInfo {
              endCursor
              hasNextPage
            }
          }
        }
      }
    }
  }
}
