feat: add 'progress' rank icon (#2858)

This pull request allows users to replace the rank level with the rank progress
by setting the `rank_icon` query to `progress`.
This commit is contained in:
Rick Staa
2023-06-19 12:58:02 +02:00
committed by GitHub
parent 62080c019c
commit a362af0ebc
8 changed files with 40 additions and 5 deletions
+1 -1
View File
@@ -328,7 +328,7 @@ const renderStatsCard = (stats = {}, options = {}) => {
<circle class="rank-circle-rim" cx="-10" cy="8" r="40" />
<circle class="rank-circle" cx="-10" cy="8" r="40" />
<g class="rank-text">
${rankIcon(rank_icon, rank?.level)}
${rankIcon(rank_icon, rank?.level, progress)}
</g>
</g>`;
+1 -1
View File
@@ -1,5 +1,5 @@
type ThemeNames = keyof typeof import("../../themes/index.js");
type RankIcon = "default" | "github";
type RankIcon = "default" | "github" | "progress";
export type CommonOptions = {
title_color: string;