Skip to content

Commit 936407b

Browse files
committed
feat: get theme author profile picture
1 parent b3e7fa8 commit 936407b

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/services/themeService.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ const getGitHubThemeData = async (apiTheme: ApiTheme) => {
1616
const meta = await (await fetch(metaUrl)).json();
1717

1818
const contentUrl = `${cdnUrl}/${themeId}/${meta.version}`;
19+
1920
// fetch contents
2021
const displayFile = 'display.png';
2122
const settingsFile = 'settings.json';
@@ -28,7 +29,8 @@ const getGitHubThemeData = async (apiTheme: ApiTheme) => {
2829
const cssStylesUrl = `${contentUrl}/${cssStylesFile}`;
2930

3031
// todo: fetch from github url (can use jsdelivr cache too)
31-
const authorImg = '';
32+
33+
const authorImg = `https://avatars.githubusercontent.com/${meta.author}`
3234

3335
// todo: explore whether tags should be stored in database or via meta.json on github
3436
const tags = ['beta'];

0 commit comments

Comments
 (0)