Tucker McKnight <tucker@pangolin.lan> | Tue Dec 09 2025
Make the branches dropdown work on new repos page
0 1 2 3
import { type ReposConfiguration } from "../../src/configTypes.ts"
import path from 'path'
export const NavHelper = (reposConfig: ReposConfiguration, slugify: Function, repoName: string, branchName: string) => {
const reposPath = reposConfig.path || ""0 1 2
import { type ReposConfiguration } from "../../src/configTypes.ts"
export const NavHelper = (reposConfig: ReposConfiguration, slugify: Function, repoName: string, branchName: string) => {
const reposPath = reposConfig.path || ""27 28 29 30 31
repoCurrentBranchHome: () => {
return currentBranchPath
},
repoCurrentBranchFiles: () => {
return `${currentBranchPath}/files`
},27 28 29 30 31 32 33 34
repoCurrentBranchHome: () => {
return currentBranchPath
},
repoBranchHome: (branchName: string) => {
return `${rootBasePathBranches}/${slugify(branchName)}`
},
repoCurrentBranchFiles: () => {
return `${currentBranchPath}/files`
},24 25 26 27 28
<title>${repo.name}</title>
<link rel="stylesheet" href="/css/design-board.css">
<link href="https://unpkg.com/prismjs@1.20.0/themes/prism.css" rel="stylesheet" />
</head>
<body>
<div class="container">24 25 26 27 28 29 30 31
<title>${repo.name}</title>
<link rel="stylesheet" href="/css/design-board.css">
<link href="https://unpkg.com/prismjs@1.20.0/themes/prism.css" rel="stylesheet" />
<script>
window.branches = ${JSON.stringify(repo.branches)};
</script>
</head>
<body>
<div class="container">