Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
0bf2f53
feat: add package timeline
43081j Mar 20, 2026
97e094a
feat: add package size and dependency changes
43081j Mar 20, 2026
245cb32
feat: add license changes
43081j Mar 20, 2026
28bb82d
feat: add esm change
43081j Mar 20, 2026
b27f2b9
chore: rework design to subbranch version info
43081j Mar 20, 2026
482d29e
Merge branch 'main' into jg/going-back-in-time
43081j Mar 23, 2026
949c209
feat: rework to use an api
43081j Mar 23, 2026
cdca660
fix: split up dependency count and install size
43081j Mar 23, 2026
f1ccaa8
fix: catch some errors
43081j Mar 23, 2026
06878f0
feat: a big ol' rework
43081j Mar 23, 2026
68690ad
feat: add trust/provenance
43081j Mar 23, 2026
24e9bad
[autofix.ci] apply automated fixes
autofix-ci[bot] Mar 23, 2026
dc1ee22
test: add tests, run format
43081j Mar 23, 2026
1972967
chore: fix some pr comments
43081j Mar 23, 2026
03f2a54
fix: add initial load error message
43081j Mar 23, 2026
8b72a0d
test: restore stubs
43081j Mar 23, 2026
6ebe882
chore: use i18n
43081j Mar 23, 2026
99ab9e0
chore: update schema
43081j Mar 23, 2026
7decccd
Update server/api/registry/timeline/[...pkg].get.ts
ghostdevv Mar 25, 2026
09cd493
Merge branch 'main' into jg/going-back-in-time
ghostdevv Mar 25, 2026
d458cfe
fix: link to package page instead of timeline
43081j Mar 25, 2026
de53377
Merge branch 'main' into jg/going-back-in-time
43081j Apr 7, 2026
58297e1
fix: enable passQuery for timeline API
43081j Apr 7, 2026
a6f78e8
Apply suggestions from code review
43081j Apr 7, 2026
d2628db
[autofix.ci] apply automated fixes
autofix-ci[bot] Apr 7, 2026
dfef742
feat: load sizes in pages
43081j Apr 7, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions app/components/AppFooter.vue
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,10 @@ const closeModal = () => modalRef.value?.close?.()
<kbd class="kbd">f</kbd>
<span>{{ $t('shortcuts.open_diff') }}</span>
</li>
<li class="flex gap-2 items-center">
<kbd class="kbd">t</kbd>
<span>{{ $t('shortcuts.open_timeline') }}</span>
</li>
<li class="flex gap-2 items-center">
<kbd class="kbd">c</kbd>
<span>{{ $t('shortcuts.compare_from_package') }}</span>
Expand Down
25 changes: 24 additions & 1 deletion app/components/Package/Header.vue
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ const props = defineProps<{
latestVersion?: SlimVersion | null
provenanceData?: ProvenanceDetails | null
provenanceStatus?: string | null
page: 'main' | 'docs' | 'code' | 'diff'
page: 'main' | 'docs' | 'code' | 'diff' | 'timeline'
versionUrlPattern: string
}>()

Expand Down Expand Up @@ -162,12 +162,26 @@ const diffLink = computed((): RouteLocationRaw | null => {
return diffRoute(props.pkg.name, props.resolvedVersion, props.latestVersion.version)
})

const timelineLink = computed((): RouteLocationRaw | null => {
if (props.pkg == null || props.resolvedVersion == null) return null
const split = props.pkg.name.split('/')
return {
name: 'timeline',
params: {
org: split.length === 2 ? split[0] : undefined,
packageName: split.length === 2 ? split[1]! : split[0]!,
version: props.resolvedVersion,
},
}
})

useShortcuts({
'.': () => codeLink.value,
'm': () => mainLink.value,
'd': () => docsLink.value,
'c': () => props.pkg && { name: 'compare' as const, query: { packages: props.pkg.name } },
'f': () => diffLink.value,
't': () => timelineLink.value,
})
</script>

Expand Down Expand Up @@ -330,6 +344,15 @@ useShortcuts({
>
{{ $t('compare.compare_versions') }}
</LinkBase>
<LinkBase
v-if="timelineLink"
:to="timelineLink"
aria-keyshortcuts="t"
class="decoration-none border-b-2 p-1 hover:border-accent/50 focus-visible:[outline-offset:-2px]!"
:class="page === 'timeline' ? 'border-accent text-accent!' : 'border-transparent'"
>
{{ $t('package.links.timeline') }}
</LinkBase>
</nav>
</div>
</div>
Expand Down
8 changes: 8 additions & 0 deletions app/composables/npm/usePackage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -86,12 +86,20 @@ export function transformPackument(
const trustLevel = getTrustLevel(version)
const hasProvenance = trustLevel !== 'none'

// Normalize license: some versions use { type: "MIT" } instead of "MIT"
let versionLicense = version.license
if (versionLicense && typeof versionLicense === 'object' && 'type' in versionLicense) {
versionLicense = (versionLicense as { type: string }).type
}

filteredVersions[v] = {
hasProvenance,
trustLevel,
version: version.version,
deprecated: version.deprecated,
tags: version.tags as string[],
license: typeof versionLicense === 'string' ? versionLicense : undefined,
type: typeof version.type === 'string' ? version.type : undefined,
}
}
}
Expand Down
Loading
Loading