Skip to content

Commit

Permalink
Allow clicking on work card in chapter view to get back to the work page
Browse files Browse the repository at this point in the history
  • Loading branch information
ChiriVulpes committed Jan 1, 2025
1 parent c889714 commit 88180f2
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/ui/view/ChapterView.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import EndpointChapterGet from "endpoint/chapter/EndpointChapterGet"
import EndpointChapterGetPaged from "endpoint/chapter/EndpointChapterGetPaged"
import EndpointWorkGet from "endpoint/work/EndpointWorkGet"
import quilt from "lang/en-nz"
import Link from "ui/component/core/Link"
import Work from "ui/component/Work"
import PaginatedView from "ui/view/shared/component/PaginatedView"
import ViewDefinition from "ui/view/shared/component/ViewDefinition"
Expand All @@ -23,7 +24,8 @@ export default ViewDefinition({
delete workData.synopsis
delete workData.custom_tags

const work = await Work(workData, author)
const work = await Link(`/work/${author?.vanity}/${workData.vanity}`)
.and(Work, workData, author)
work
.viewTransition("work-view-work")
.style("view-type-chapter-work")
Expand Down

0 comments on commit 88180f2

Please sign in to comment.