run prettier formatting
Signed-off-by: Fredrik Adelöw <freben@gmail.com>
This commit is contained in:
@@ -159,15 +159,13 @@ export const WorkflowRunsTable = ({
|
||||
config.getOptionalConfigArray('integrations.github') ?? [],
|
||||
)[0].host;
|
||||
const [owner, repo] = (projectName ?? '/').split('/');
|
||||
const [
|
||||
{ runs, ...tableProps },
|
||||
{ retry, setPage, setPageSize },
|
||||
] = useWorkflowRuns({
|
||||
hostname,
|
||||
owner,
|
||||
repo,
|
||||
branch,
|
||||
});
|
||||
const [{ runs, ...tableProps }, { retry, setPage, setPageSize }] =
|
||||
useWorkflowRuns({
|
||||
hostname,
|
||||
owner,
|
||||
repo,
|
||||
branch,
|
||||
});
|
||||
|
||||
const githubHost = hostname || 'github.com';
|
||||
|
||||
|
||||
@@ -57,9 +57,12 @@ export function useWorkflowRuns({
|
||||
const [page, setPage] = useState(0);
|
||||
const [pageSize, setPageSize] = useState(initialPageSize);
|
||||
|
||||
const { loading, value: runs, retry, error } = useAsyncRetry<
|
||||
WorkflowRun[]
|
||||
>(async () => {
|
||||
const {
|
||||
loading,
|
||||
value: runs,
|
||||
retry,
|
||||
error,
|
||||
} = useAsyncRetry<WorkflowRun[]>(async () => {
|
||||
// GitHub API pagination count starts from 1
|
||||
const workflowRunsData = await api.listWorkflowRuns({
|
||||
hostname,
|
||||
|
||||
@@ -56,14 +56,17 @@ export const EntityLatestGithubActionRunCard = githubActionsPlugin.provide(
|
||||
}),
|
||||
);
|
||||
|
||||
export const EntityLatestGithubActionsForBranchCard = githubActionsPlugin.provide(
|
||||
createComponentExtension({
|
||||
component: {
|
||||
lazy: () =>
|
||||
import('./components/Cards').then(m => m.LatestWorkflowsForBranchCard),
|
||||
},
|
||||
}),
|
||||
);
|
||||
export const EntityLatestGithubActionsForBranchCard =
|
||||
githubActionsPlugin.provide(
|
||||
createComponentExtension({
|
||||
component: {
|
||||
lazy: () =>
|
||||
import('./components/Cards').then(
|
||||
m => m.LatestWorkflowsForBranchCard,
|
||||
),
|
||||
},
|
||||
}),
|
||||
);
|
||||
|
||||
export const EntityRecentGithubActionsRunsCard = githubActionsPlugin.provide(
|
||||
createComponentExtension({
|
||||
|
||||
Reference in New Issue
Block a user