diff --git a/docs/content/changelog/CHANGELOG.md b/docs/content/changelog/CHANGELOG.md index d1487322..e24f4be7 100644 --- a/docs/content/changelog/CHANGELOG.md +++ b/docs/content/changelog/CHANGELOG.md @@ -3,6 +3,7 @@ ## [3.1.0] - (Upcoming release) - [#77](https://github.com/estruyf/vscode-front-matter/issues/77): Dashboard grouping pages functionality integrated +- [#87](https://github.com/estruyf/vscode-front-matter/issues/87): Fix issue with autofocus and command palette ## [3.0.2] - 2021-08-31 diff --git a/docs/pages/showcase/index.tsx b/docs/pages/showcase/index.tsx index f56e7318..66493ea6 100644 --- a/docs/pages/showcase/index.tsx +++ b/docs/pages/showcase/index.tsx @@ -25,6 +25,12 @@ const toBase64 = (str: string) => ? Buffer.from(str).toString('base64') : window.btoa(str); +const sortTitle = (a: { title: string }, b: { title: string }) => { + if (a.title < b.title) return -1; + if (a.title > b.title) return 1; + return 0; +}; + export default function Home({ showcases }: any) { const { t: strings } = useTranslation(); @@ -43,7 +49,7 @@ export default function Home({ showcases }: any) {
- {showcases.filter((showcase: any) => showcase.image).map((showcase: any) => ( + {showcases.filter((showcase: any) => showcase.image).sort(sortTitle).map((showcase: any) => (