lint fix and formatted
linter / quality (push) Successful in 1m20s
tests / ci (8.4) (push) Successful in 1m20s

This commit is contained in:
2026-04-11 16:37:58 +02:00
parent 23a66852a6
commit e5d11c940b
38 changed files with 339 additions and 261 deletions
+86 -72
View File
@@ -141,7 +141,8 @@ const selectedBranchRepositoryConnection = computed(
);
const selectedBranchRepositoryHasPersonalAccess = computed(
() => selectedBranchRepositoryConnection.value?.has_personal_access ?? false,
() =>
selectedBranchRepositoryConnection.value?.has_personal_access ?? false,
);
const initializeBranchCreationForm = (): void => {
@@ -174,7 +175,11 @@ watch(
() => branchCreationForm.repository_connection_id,
() => branchCreationForm.branch_name,
],
([isOpen, repositoryConnectionId, branchName], _previousValues, onCleanup) => {
(
[isOpen, repositoryConnectionId, branchName],
_previousValues,
onCleanup,
) => {
if (!isOpen) {
return;
}
@@ -412,7 +417,7 @@ const formatDateTime = (value: string): string => {
:disabled="
!canEditTicket || form.processing
"
class="rounded-md border border-input bg-background px-3 py-2 text-sm shadow-xs transition-[color,box-shadow] outline-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-60"
class="border-input bg-background shadow-xs focus-visible:border-ring focus-visible:ring-ring/50 rounded-md border px-3 py-2 text-sm outline-none transition-[color,box-shadow] focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-60"
>
<option
v-for="ticketType in ticketTypes"
@@ -437,7 +442,7 @@ const formatDateTime = (value: string): string => {
:disabled="
!canEditTicket || form.processing
"
class="rounded-md border border-input bg-background px-3 py-2 text-sm shadow-xs transition-[color,box-shadow] outline-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-60"
class="border-input bg-background shadow-xs focus-visible:border-ring focus-visible:ring-ring/50 rounded-md border px-3 py-2 text-sm outline-none transition-[color,box-shadow] focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-60"
>
<option
v-for="ticketPriority in ticketPriorities"
@@ -465,7 +470,7 @@ const formatDateTime = (value: string): string => {
:disabled="
!canEditTicket || form.processing
"
class="rounded-md border border-input bg-background px-3 py-2 text-sm shadow-xs transition-[color,box-shadow] outline-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-60"
class="border-input bg-background shadow-xs focus-visible:border-ring focus-visible:ring-ring/50 rounded-md border px-3 py-2 text-sm outline-none transition-[color,box-shadow] focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-60"
>
<option value="">No parent ticket</option>
<option
@@ -492,7 +497,7 @@ const formatDateTime = (value: string): string => {
:disabled="
!canEditTicket || form.processing
"
class="rounded-md border border-input bg-background px-3 py-2 text-sm shadow-xs transition-[color,box-shadow] outline-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-60"
class="border-input bg-background shadow-xs focus-visible:border-ring focus-visible:ring-ring/50 rounded-md border px-3 py-2 text-sm outline-none transition-[color,box-shadow] focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-60"
/>
<InputError
:message="form.errors.description"
@@ -510,14 +515,16 @@ const formatDateTime = (value: string): string => {
:disabled="
!canEditTicket || form.processing
"
class="rounded-md border border-input bg-background px-3 py-2 text-sm shadow-xs transition-[color,box-shadow] outline-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-60"
class="border-input bg-background shadow-xs focus-visible:border-ring focus-visible:ring-ring/50 rounded-md border px-3 py-2 text-sm outline-none transition-[color,box-shadow] focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-60"
/>
<InputError
:message="form.errors.acceptance_criteria"
/>
</div>
<div class="grid gap-3 rounded-xl border border-border p-4">
<div
class="border-border grid gap-3 rounded-xl border p-4"
>
<div class="flex items-center gap-3">
<input
id="is_blocked"
@@ -526,7 +533,7 @@ const formatDateTime = (value: string): string => {
:disabled="
!canEditTicket || form.processing
"
class="size-4 rounded border-input text-primary focus:ring-ring"
class="border-input text-primary focus:ring-ring size-4 rounded"
/>
<Label for="is_blocked">
Mark ticket as blocked
@@ -544,7 +551,7 @@ const formatDateTime = (value: string): string => {
:disabled="
!canEditTicket || form.processing
"
class="rounded-md border border-input bg-background px-3 py-2 text-sm shadow-xs transition-[color,box-shadow] outline-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-60"
class="border-input bg-background shadow-xs focus-visible:border-ring focus-visible:ring-ring/50 rounded-md border px-3 py-2 text-sm outline-none transition-[color,box-shadow] focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-60"
placeholder="Describe what currently blocks progress on this ticket."
/>
<InputError
@@ -558,7 +565,7 @@ const formatDateTime = (value: string): string => {
<h3 class="text-sm font-semibold">
Custom fields
</h3>
<p class="text-sm text-muted-foreground">
<p class="text-muted-foreground text-sm">
Project-configured fields can be tracked
directly on the ticket.
</p>
@@ -566,7 +573,7 @@ const formatDateTime = (value: string): string => {
<div
v-if="ticketFieldDefinitions.length === 0"
class="rounded-xl border border-dashed border-border px-4 py-6 text-sm text-muted-foreground"
class="border-border text-muted-foreground rounded-xl border border-dashed px-4 py-6 text-sm"
>
No custom fields are configured for this
project yet.
@@ -600,7 +607,7 @@ const formatDateTime = (value: string): string => {
!canEditTicket ||
form.processing
"
class="rounded-md border border-input bg-background px-3 py-2 text-sm shadow-xs transition-[color,box-shadow] outline-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-60"
class="border-input bg-background shadow-xs focus-visible:border-ring focus-visible:ring-ring/50 rounded-md border px-3 py-2 text-sm outline-none transition-[color,box-shadow] focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-60"
>
<option value="">Unassigned</option>
<option
@@ -664,9 +671,9 @@ const formatDateTime = (value: string): string => {
<div class="space-y-1.5">
<CardTitle>Branches</CardTitle>
<CardDescription>
Matching branches are discovered from
linked repositories when the branch name
starts with this ticket key.
Matching branches are discovered from linked
repositories when the branch name starts
with this ticket key.
</CardDescription>
</div>
@@ -699,7 +706,9 @@ const formatDateTime = (value: string): string => {
@submit.prevent="submitBranchCreation"
>
<div class="grid gap-2">
<Label for="repository_connection_id">
<Label
for="repository_connection_id"
>
Repository
</Label>
<select
@@ -710,11 +719,13 @@ const formatDateTime = (value: string): string => {
:disabled="
branchCreationForm.processing
"
class="rounded-md border border-input bg-background px-3 py-2 text-sm shadow-xs transition-[color,box-shadow] outline-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-60"
class="border-input bg-background shadow-xs focus-visible:border-ring focus-visible:ring-ring/50 rounded-md border px-3 py-2 text-sm outline-none transition-[color,box-shadow] focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-60"
>
<option
v-for="repositoryConnection in linkedRepositoryConnections"
:key="repositoryConnection.id"
:key="
repositoryConnection.id
"
:value="
String(
repositoryConnection.id,
@@ -764,9 +775,7 @@ const formatDateTime = (value: string): string => {
: 'border-amber-200 bg-amber-50 text-amber-900 dark:border-amber-900/70 dark:bg-amber-950/40 dark:text-amber-100'
"
>
<div
class="flex items-start gap-3"
>
<div class="flex items-start gap-3">
<CheckCircle2
v-if="
branchNameValidation?.is_valid
@@ -784,8 +793,8 @@ const formatDateTime = (value: string): string => {
{{
isCheckingBranchName
? 'Checking whether this branch name is valid and still available...'
: branchNameValidation?.message ??
'Select a linked repository to validate the branch name.'
: (branchNameValidation?.message ??
'Select a linked repository to validate the branch name.')
}}
</p>
</div>
@@ -797,10 +806,10 @@ const formatDateTime = (value: string): string => {
selectedBranchRepositoryConnection !==
null
"
class="rounded-xl border border-dashed border-border px-4 py-4"
class="border-border rounded-xl border border-dashed px-4 py-4"
>
<p
class="text-sm text-muted-foreground"
class="text-muted-foreground text-sm"
>
You can only create branches in
repositories that match one of
@@ -814,9 +823,7 @@ const formatDateTime = (value: string): string => {
class="mt-3"
>
<Link
:href="
editGitConnections()
"
:href="editGitConnections()"
>
Open Git connections
</Link>
@@ -828,8 +835,7 @@ const formatDateTime = (value: string): string => {
type="button"
variant="secondary"
@click="
isCreateBranchDialogOpen =
false
isCreateBranchDialogOpen = false
"
>
Cancel
@@ -855,7 +861,7 @@ const formatDateTime = (value: string): string => {
<CardContent class="space-y-4">
<div
v-if="visibleRepositoryBranches.length === 0"
class="rounded-xl border border-dashed border-border px-4 py-6 text-sm text-muted-foreground"
class="border-border text-muted-foreground rounded-xl border border-dashed px-4 py-6 text-sm"
>
No matching branches were found across the
linked repositories you can access.
@@ -865,9 +871,10 @@ const formatDateTime = (value: string): string => {
<div
v-for="repositoryBranch in visibleRepositoryBranches"
:key="
repositoryBranch.repository_connection.id
repositoryBranch.repository_connection
.id
"
class="rounded-xl border border-border px-4 py-4"
class="border-border rounded-xl border px-4 py-4"
>
<div
class="flex flex-wrap items-center gap-2"
@@ -889,7 +896,7 @@ const formatDateTime = (value: string): string => {
</div>
<p
class="mt-2 text-sm text-muted-foreground"
class="text-muted-foreground mt-2 text-sm"
>
{{
repositoryBranch
@@ -906,14 +913,18 @@ const formatDateTime = (value: string): string => {
class="mt-3 space-y-3"
>
<p
class="text-sm text-muted-foreground"
class="text-muted-foreground text-sm"
>
Connect a matching Git account in
your user settings to inspect
branches for this repository.
</p>
<Button as-child variant="outline" size="sm">
<Button
as-child
variant="outline"
size="sm"
>
<Link :href="editGitConnections()">
Open Git connections
</Link>
@@ -927,7 +938,10 @@ const formatDateTime = (value: string): string => {
{{ repositoryBranch.error }}
</div>
<div v-else class="mt-3 flex flex-wrap gap-2">
<div
v-else
class="mt-3 flex flex-wrap gap-2"
>
<Badge
v-for="branch in repositoryBranch.branches"
:key="branch.name"
@@ -964,7 +978,7 @@ const formatDateTime = (value: string): string => {
ticket: ticket.id,
})
"
class="grid gap-4 rounded-xl border border-dashed border-border p-4"
class="border-border grid gap-4 rounded-xl border border-dashed p-4"
v-slot="{ errors, processing }"
>
<div class="grid gap-2">
@@ -974,7 +988,7 @@ const formatDateTime = (value: string): string => {
<select
id="ticket_link_type_id"
name="ticket_link_type_id"
class="rounded-md border border-input bg-background px-3 py-2 text-sm shadow-xs transition-[color,box-shadow] outline-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50"
class="border-input bg-background shadow-xs focus-visible:border-ring focus-visible:ring-ring/50 rounded-md border px-3 py-2 text-sm outline-none transition-[color,box-shadow] focus-visible:ring-[3px]"
>
<option
v-for="ticketLinkType in ticketLinkTypes"
@@ -996,7 +1010,7 @@ const formatDateTime = (value: string): string => {
<select
id="linked_ticket_id"
name="linked_ticket_id"
class="rounded-md border border-input bg-background px-3 py-2 text-sm shadow-xs transition-[color,box-shadow] outline-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50"
class="border-input bg-background shadow-xs focus-visible:border-ring focus-visible:ring-ring/50 rounded-md border px-3 py-2 text-sm outline-none transition-[color,box-shadow] focus-visible:ring-[3px]"
>
<option
v-for="ticketLinkOption in ticketLinkOptions"
@@ -1013,17 +1027,14 @@ const formatDateTime = (value: string): string => {
/>
</div>
<Button
type="submit"
:disabled="processing"
>
<Button type="submit" :disabled="processing">
Save link
</Button>
</Form>
<div
v-if="linkedTickets.length === 0"
class="rounded-xl border border-dashed border-border px-4 py-6 text-sm text-muted-foreground"
class="border-border text-muted-foreground rounded-xl border border-dashed px-4 py-6 text-sm"
>
No ticket links are configured for this ticket
yet.
@@ -1033,9 +1044,11 @@ const formatDateTime = (value: string): string => {
<div
v-for="linkedTicket in linkedTickets"
:key="linkedTicket.id"
class="rounded-xl border border-border px-4 py-4"
class="border-border rounded-xl border px-4 py-4"
>
<div class="flex flex-wrap items-center gap-2">
<div
class="flex flex-wrap items-center gap-2"
>
<Badge variant="secondary">
{{
linkedTicket.ticket_link_type
@@ -1050,7 +1063,7 @@ const formatDateTime = (value: string): string => {
.linked_ticket.id,
})
"
class="font-medium text-foreground transition hover:text-primary"
class="text-foreground hover:text-primary font-medium transition"
>
{{
linkedTicket.linked_ticket
@@ -1058,7 +1071,9 @@ const formatDateTime = (value: string): string => {
}}
</Link>
</div>
<p class="mt-2 text-sm text-muted-foreground">
<p
class="text-muted-foreground mt-2 text-sm"
>
{{ linkedTicket.linked_ticket.title }}
</p>
@@ -1069,8 +1084,7 @@ const formatDateTime = (value: string): string => {
{
project: project.id,
ticket: ticket.id,
ticketLink:
linkedTicket.id,
ticketLink: linkedTicket.id,
},
)
"
@@ -1106,7 +1120,7 @@ const formatDateTime = (value: string): string => {
v-if="
visibleRepositoryPullRequests.length === 0
"
class="rounded-xl border border-dashed border-border px-4 py-6 text-sm text-muted-foreground"
class="border-border text-muted-foreground rounded-xl border border-dashed px-4 py-6 text-sm"
>
No matching pull requests were found across the
linked repositories you can access.
@@ -1119,7 +1133,7 @@ const formatDateTime = (value: string): string => {
repositoryPullRequest
.repository_connection.id
"
class="rounded-xl border border-border px-4 py-4"
class="border-border rounded-xl border px-4 py-4"
>
<div
class="flex flex-wrap items-center gap-2"
@@ -1141,7 +1155,7 @@ const formatDateTime = (value: string): string => {
</div>
<p
class="mt-2 text-sm text-muted-foreground"
class="text-muted-foreground mt-2 text-sm"
>
{{
repositoryPullRequest
@@ -1158,14 +1172,18 @@ const formatDateTime = (value: string): string => {
class="mt-3 space-y-3"
>
<p
class="text-sm text-muted-foreground"
class="text-muted-foreground text-sm"
>
Connect a matching Git account in
your user settings to inspect pull
requests for this repository.
</p>
<Button as-child variant="outline" size="sm">
<Button
as-child
variant="outline"
size="sm"
>
<Link :href="editGitConnections()">
Open Git connections
</Link>
@@ -1183,7 +1201,7 @@ const formatDateTime = (value: string): string => {
<div
v-for="pullRequest in repositoryPullRequest.pull_requests"
:key="pullRequest.html_url"
class="rounded-xl border border-border/70 px-4 py-3"
class="border-border/70 rounded-xl border px-4 py-3"
>
<div
class="flex flex-wrap items-center gap-2"
@@ -1192,26 +1210,22 @@ const formatDateTime = (value: string): string => {
#{{ pullRequest.number }}
</Badge>
<Badge variant="secondary">
{{
pullRequest.status
}}
{{ pullRequest.status }}
</Badge>
<a
:href="pullRequest.html_url"
target="_blank"
rel="noreferrer"
class="font-medium text-foreground transition hover:text-primary"
class="text-foreground hover:text-primary font-medium transition"
>
{{ pullRequest.title }}
</a>
</div>
<p
class="mt-2 text-sm text-muted-foreground"
class="text-muted-foreground mt-2 text-sm"
>
Source branch:
{{
pullRequest.source_branch
}}
{{ pullRequest.source_branch }}
</p>
</div>
</div>
@@ -1232,7 +1246,7 @@ const formatDateTime = (value: string): string => {
<CardContent>
<div
v-if="childTicketTree.length === 0"
class="rounded-xl border border-dashed border-border px-4 py-6 text-sm text-muted-foreground"
class="border-border text-muted-foreground rounded-xl border border-dashed px-4 py-6 text-sm"
>
No child tickets are assigned to this ticket
yet.
@@ -1260,7 +1274,7 @@ const formatDateTime = (value: string): string => {
v-if="
(ticket.worklog_entries?.length ?? 0) === 0
"
class="rounded-xl border border-dashed border-border px-4 py-6 text-sm text-muted-foreground"
class="border-border text-muted-foreground rounded-xl border border-dashed px-4 py-6 text-sm"
>
No worklog entries exist for this ticket yet.
</div>
@@ -1269,7 +1283,7 @@ const formatDateTime = (value: string): string => {
<div
v-for="worklogEntry in ticket.worklog_entries"
:key="worklogEntry.id"
class="rounded-xl border border-border px-4 py-4"
class="border-border rounded-xl border px-4 py-4"
>
<div
class="flex flex-wrap items-center gap-2"
@@ -1278,7 +1292,7 @@ const formatDateTime = (value: string): string => {
{{ worklogEntry.entry_type }}
</Badge>
<span
class="text-sm font-medium text-foreground"
class="text-foreground text-sm font-medium"
>
{{
worklogEntry.actor?.name ??
@@ -1286,11 +1300,11 @@ const formatDateTime = (value: string): string => {
}}
</span>
</div>
<p class="mt-3 text-sm text-foreground">
<p class="text-foreground mt-3 text-sm">
{{ worklogEntry.summary }}
</p>
<p
class="mt-2 text-xs text-muted-foreground"
class="text-muted-foreground mt-2 text-xs"
>
{{
formatDateTime(