Skip to content
Snippets Groups Projects
Commit 4725a8dc authored by James Cahill's avatar James Cahill Committed by Paul Melnikow
Browse files

Refactor the rest of [PyPI] to use static previews (#2752)

* Refactor the rest of [PyPI] to use static previews

* v1.0.0 -> 1.0.0 to match what's passed to render function
parent ef184294
No related branches found
No related tags found
No related merge requests found
......@@ -20,7 +20,9 @@ module.exports = class PypiFormat extends PypiBase {
return [
{
title: 'PyPI - Format',
previewUrl: 'Django',
pattern: ':packageName',
namedParams: { packageName: 'Django' },
staticPreview: this.render({ hasWheel: true }),
keywords: ['python'],
},
]
......
......@@ -19,7 +19,7 @@ module.exports = class PypiLicense extends PypiBase {
title: 'PyPI - License',
pattern: ':packageName',
namedParams: { packageName: 'Django' },
staticPreview: { label: 'license', message: 'BSD', color: 'lightgrey' },
staticPreview: this.render({ licenses: ['BSD'] }),
keywords: ['python'],
},
]
......
......@@ -20,7 +20,9 @@ module.exports = class PypiStatus extends PypiBase {
return [
{
title: 'PyPI - Status',
previewUrl: 'Django',
pattern: ':packageName',
namedParams: { packageName: 'Django' },
staticPreview: this.render({ status: 'stable' }),
keywords: ['python'],
},
]
......
......@@ -20,7 +20,9 @@ module.exports = class PypiVersion extends PypiBase {
return [
{
title: 'PyPI',
previewUrl: 'nine',
pattern: ':packageName',
namedParams: { packageName: 'nine' },
staticPreview: this.render({ version: '1.0.0' }),
keywords: ['python'],
},
]
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment