Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[pull] master from anuraghazra:master #74

Closed
wants to merge 156 commits into from
Closed
Show file tree
Hide file tree
Changes from 12 commits
Commits
Show all changes
156 commits
Select commit Hold shift + click to select a range
5f20e6c
add holi_theme (#2539)
mohamedhassan279 Feb 25, 2023
a6ff0fa
Add one_dark_pro (#2507)
b3dyk Feb 25, 2023
f3f7a48
fix: fix JSON themes bug. (#2544)
catelinemnemosyne Feb 25, 2023
55a303b
Add auto-labelling for documentation updates (#2526)
Zo-Bro-23 Feb 25, 2023
91345ed
ci: fix unsafe directory bug (#2518)
rickstaa Feb 25, 2023
8898d01
Update readme.md (#2414)
raphaelricardo10 Feb 25, 2023
a3c6f87
test: update snapshots (#2519)
rickstaa Feb 25, 2023
2ab8b85
fix: for issue #2534 (#2536)
md-rehman Feb 25, 2023
1d528da
Add option to deploy using other services (#2525)
Zo-Bro-23 Feb 25, 2023
82224fa
ci: update e2e tests (#2548)
rickstaa Feb 25, 2023
d5fbfb4
ci: fix a bug in the theme preview action (#2549)
rickstaa Feb 25, 2023
252c2b4
refactor: format code (#2550)
rickstaa Feb 26, 2023
d60d53c
refactor: update languages JSON (#2554)
github-actions[bot] Mar 1, 2023
8849b5f
Preview theme workflow fix (#2557)
Zo-Bro-23 Mar 1, 2023
a1c3c6a
ci: preview theme workflow fix (#2559)
Zo-Bro-23 Mar 1, 2023
9ec2c83
refactor: fix code comments and change 'up' rate limit (#2560)
rickstaa Mar 2, 2023
7bc8f19
Preview action fix (#2561)
Zo-Bro-23 Mar 2, 2023
9767710
ci: fix theme preview action (#2563)
rickstaa Mar 3, 2023
1e61f9f
fix theme preview (#2564)
rickstaa Mar 3, 2023
ed18914
ci: fixes theme preview action (#2566)
rickstaa Mar 5, 2023
b93aee3
ci: improve theme preview action (#2572)
rickstaa Mar 6, 2023
c5063b9
Added "Shadow" set (Red, Green, Blue, transparent BG) (#2529)
Etanarvazac Mar 8, 2023
2bd9d45
ci: fix theme docs generate bug (#2573)
rickstaa Mar 9, 2023
3299829
update my theme (#2576)
eduardozaniboni Mar 14, 2023
b928f51
refactor: update languages JSON (#2596)
github-actions[bot] Mar 31, 2023
d8244a7
Add format stats option (#2155)
CaedenPH Apr 1, 2023
4d1d83d
add github_dark_dimmed theme (#2594)
fabianocouto Apr 1, 2023
879937c
feat(RankIcon): add rank_icon option (#2628)
fabianocouto Apr 24, 2023
aec73d2
Updated the custom error there was a Typo. (#2618)
LokeshXs Apr 24, 2023
be0d966
Fix typos inside wakatime test name (#2617)
qwerty541 Apr 24, 2023
da5f82f
removed redundant comparison (#957)
qwerty541 Apr 25, 2023
8aacec0
dev (#1782)
qwerty541 Apr 25, 2023
21a9ba4
fix path to powered by vercel image (#1792)
qwerty541 Apr 25, 2023
da46a50
Synchonize cache seconds min value inside docs translations with main…
qwerty541 Apr 25, 2023
5577bbf
New top language algorithm implementation (#1732)
kitswas Apr 25, 2023
f5f0a79
feat: improve CONTRIBUTING.md (#2609)
rickstaa Apr 28, 2023
fd64333
docs: update give logo (#2605)
rickstaa Apr 28, 2023
30a45d3
Fixed typo in word color inside README (#2652)
qwerty541 Apr 28, 2023
6eebfe3
Fixed docs typo inside src/common/utils.js (#2651)
qwerty541 Apr 28, 2023
a82a617
Fixed several typos inside preview theme script (#2650)
qwerty541 Apr 28, 2023
31d1ab4
Fixed todo inside stats card data fetcher (#2649)
qwerty541 Apr 28, 2023
3bd6519
docs: fix README language card usage order (#2659)
rickstaa Apr 29, 2023
2f4279e
Fixed vscode type error in get card colors function (#2660)
qwerty541 Apr 30, 2023
cb99414
Show no activity error in compact layout of wakatime card (#2662)
qwerty541 May 1, 2023
a4d6fe1
Fixed card constructor docstring to resolve vscode type errors (#2674)
qwerty541 May 3, 2023
0dc3531
Fixed wakatime create text node func docstring to resolve vscode type…
qwerty541 May 4, 2023
311204f
Fixed docstring for several wakatime card gen functions to resolve mu…
qwerty541 May 5, 2023
c6dab8b
Fixed docstring for stats card create text node function to resolve t…
qwerty541 May 5, 2023
c656f3d
Update codecov action version to resolve github action deprecation wa…
qwerty541 May 5, 2023
d306bec
Add PRs cache cleaning workflow (#2661)
qwerty541 May 5, 2023
2619c12
build(deps): bump yaml from 2.1.3 to 2.2.2 (#2644)
dependabot[bot] May 5, 2023
a340900
fix(wakatime-fetcher): add default range to prevent user not found er…
fabianocouto May 5, 2023
0c2fe4e
Cover with test changes in #2662 pull request (#2673)
qwerty541 May 6, 2023
0caa4c5
test: fix mistaken pageInfo.endCursor keys (#2657)
Rongronggg9 May 6, 2023
688f4e4
docs: update wakatime user (#2697)
rickstaa May 6, 2023
6f449a1
Fixed docstring for get styles function to resolve vscode type errors…
qwerty541 May 7, 2023
15436e2
Fixed axios imports inside docstrings to resolve vscode type errors (…
qwerty541 May 7, 2023
ce116e2
Fixed typos inside bug report issue template (#2706)
qwerty541 May 8, 2023
550b88c
Update wakatime user inside docs translations (#2705)
qwerty541 May 8, 2023
8ff5a3b
Fixed docstring for create language text node function (#2704)
qwerty541 May 8, 2023
daa1977
Fixed docstring for wakatime card recalculate percentages function (#…
qwerty541 May 9, 2023
c5e7f7b
add pie chart layout to language card (#2099)
arndom May 9, 2023
4b19453
Fixed docstring for create donut language node function (#2713)
qwerty541 May 10, 2023
1f4a2c4
Add missing argument to create compact lang node function to resolve …
qwerty541 May 11, 2023
ff9839b
Top languages card pie layout (#2709)
qwerty541 May 11, 2023
d59a805
Docs: add missing top languages card layouts. (#2717)
qwerty541 May 13, 2023
6d45f89
Top languages card render test: move repeated code into helper functi…
qwerty541 May 13, 2023
7ec1a76
Docs (translations): add missing top languages card layouts. (#2728)
qwerty541 May 17, 2023
f9427b2
Top languages card donut vertical layout (#2701)
qwerty541 May 19, 2023
c8d5eda
Docs (translations): add top languages card donut vertical layout (#2…
qwerty541 May 22, 2023
ff2e02b
Docs: fix top languages card available layouts number (#2738)
qwerty541 May 22, 2023
c96e84a
Ranking System v2 (#1186)
francois-rozet May 26, 2023
73b0a91
Improve ukrainian translation of langcard.title (#2756)
qwerty541 May 29, 2023
275c1fc
Show notice about no languages data instead of empty card (#2755)
qwerty541 May 29, 2023
e0b3d83
refactor: update languages JSON (#2760)
github-actions[bot] May 31, 2023
c301289
fix: Make WakaTime card compatible with new API (#2707)
rickstaa Jun 2, 2023
1a2a82c
test: add new ranking to e2e test (#2750)
rickstaa Jun 2, 2023
98b0477
Fixed layout toLowerCase bug (#2770)
qwerty541 Jun 5, 2023
1e0183d
Conver with test changes in #2755 pull request (#2766)
qwerty541 Jun 5, 2023
14fe4cf
Remove redundant async notation from several top languages card tests…
qwerty541 Jun 5, 2023
fa4d7ee
Cover with test changes in #2770 pull request (#2775)
qwerty541 Jun 6, 2023
cec5ee3
ci: add top themes and labels to 'top issues dashboard' action (#2711)
rickstaa Jun 6, 2023
894f2e2
Different default languages count for different languages card layout…
qwerty541 Jun 6, 2023
a8ecd3d
chore: added new dono link (#2779)
anuraghazra Jun 6, 2023
bdef1cc
Add note about private contributions into readme (#2776)
qwerty541 Jun 6, 2023
31ffe56
docs: improve readme links (#2696)
rickstaa Jun 7, 2023
f2841e0
fix: fix stats contributed to translations (#2708)
rickstaa Jun 7, 2023
4044a0b
Use compact layout default langs count when hide_progress param was s…
qwerty541 Jun 7, 2023
dfe0766
Fix docstring for noCodingActivityNode function (#2781)
qwerty541 Jun 7, 2023
606775c
Fix no languages data node function docstring (#2782)
qwerty541 Jun 7, 2023
0fe51cd
docs: fix some typos (#2783)
rickstaa Jun 7, 2023
b9200c6
feat: remove 'include_private' (#2736)
rickstaa Jun 7, 2023
7053a03
Docs: fixed small typo inside readme in keep fork up to date section …
qwerty541 Jun 8, 2023
38c8a7a
Resolved dependabot vulnerability alert about json5 package (#2788)
qwerty541 Jun 8, 2023
3e66189
feat: add CACHE_SECONDS environment variable (#2266)
rickstaa Jun 9, 2023
b5f5bef
Remove redundant ask for theme screenshot from CONTRIBUTING.md (#2797)
qwerty541 Jun 9, 2023
3416ae1
Fix clampValue function docstring (#2796)
qwerty541 Jun 9, 2023
7a302f6
Docs: add warning about top languages card behavior. (#2789)
qwerty541 Jun 9, 2023
44c268e
Update readme.md about maxDuration (#2792)
ForsakenRei Jun 9, 2023
ec5b110
docs: add package debug steps to contribution guidelines (#2798)
rickstaa Jun 10, 2023
4eda5cd
Beautify themes contribution note inside CONTRIBUTING.md (#2800)
qwerty541 Jun 10, 2023
c506ecc
Explain our themes PRs merging policy inside CONTRIBUTING.md (#2801)
qwerty541 Jun 10, 2023
a775176
Remove restrictedContributionsCount from GraphQL query and tests (#2799)
qwerty541 Jun 10, 2023
5696c96
Docs: fixed table of contents aligment (#2795)
qwerty541 Jun 11, 2023
fec686a
ci: fix top-issues action (#2803)
rickstaa Jun 11, 2023
a664532
docs: add FAQ to readme (#2804)
rickstaa Jun 11, 2023
9105c74
docs: add PAT permission to docs (#2805)
rickstaa Jun 11, 2023
9520baa
Docs: rename wakatime stats card section (#2807)
qwerty541 Jun 11, 2023
dc60ea9
Docs: set correct separation symbol between translations links (#2806)
qwerty541 Jun 11, 2023
041ef07
Added neon theme (#2579)
anirban12d Jun 11, 2023
2704e25
Add yzhang.markdown-all-in-one to recommended workspace extensions (#…
qwerty541 Jun 11, 2023
92a9d85
docs(theme): Auto update theme readme (#2810)
rickstaa Jun 11, 2023
faf0c25
Update automated themes preview workflow contributions guideline (#2808)
qwerty541 Jun 11, 2023
a967581
Docs (translations): Regenerated tables of contents using yzhang.mark…
qwerty541 Jun 12, 2023
5218e34
Remove duplicate from .gitignore (#2814)
qwerty541 Jun 12, 2023
99d560f
Add vscode settings for yzhang.markdown-all-in-one extension (#2813)
qwerty541 Jun 12, 2023
768721f
Improve pull requests labeler (#2812)
qwerty541 Jun 12, 2023
66e5492
Add finer ranking levels (#2762)
francois-rozet Jun 12, 2023
9831d25
test: update 2e2 rank values (#2816)
rickstaa Jun 13, 2023
c4035a5
Use node 18.x in continuous integration (#2819)
qwerty541 Jun 14, 2023
d5a4dbd
Specify node version inside package.json (#2823)
qwerty541 Jun 15, 2023
1474a3a
Use default json import (#2820)
qwerty541 Jun 15, 2023
c86cc72
Specify node version for NVM (node version manager) users (#2824)
qwerty541 Jun 15, 2023
1bb65dd
Added pr reviews to stats (#1404)
Marcholio Jun 15, 2023
89e37aa
refactor: add PR review translations (#2825)
rickstaa Jun 15, 2023
632549d
Revert "Use default json import (#2820)" (#2829)
rickstaa Jun 15, 2023
22a12e1
ci: increase top-issues-action list size (#2826)
rickstaa Jun 15, 2023
7a89cee
Stats card: Reorder total reviews count position (#2834)
qwerty541 Jun 16, 2023
3831d18
Stats card: Change total reviews label and add missing translations (…
qwerty541 Jun 16, 2023
05efc28
Docs: make discussion link clickable (#2831)
qwerty541 Jun 16, 2023
4db78d7
Docs: improve GitHub media feature HTML example formatting (#2830)
qwerty541 Jun 16, 2023
99aca1b
Fixed docstring for trimTopLanguages function (#2833)
qwerty541 Jun 16, 2023
1997328
Top langs card: Increase maximum languages count to 20 (#2832)
qwerty541 Jun 16, 2023
a43fb81
Add missing bracket inside CONTRIBUTING.md notice (#2842)
qwerty541 Jun 17, 2023
331fa11
Docs: Increase maximum languages count to 20 (#2843)
qwerty541 Jun 17, 2023
c5d4bcb
Docs: make important notice link clickable (#2841)
qwerty541 Jun 17, 2023
6cbb08e
Stats card: remove duplicate hide option default value from render fu…
qwerty541 Jun 17, 2023
b70b089
Stats card: migrate from show_total_reviews to show option (resolves …
qwerty541 Jun 17, 2023
2e65a2e
Docs: fix broken demos link (#2848)
qwerty541 Jun 17, 2023
eebaa44
CI: Add missing bracket inside theme preview workflow warning (#2847)
qwerty541 Jun 17, 2023
03b0ba0
Wakatime card: add missing translations (resolves #2839) (#2850)
qwerty541 Jun 18, 2023
a5260cb
feat: improve locale translation not found error (#2853)
rickstaa Jun 19, 2023
92518e3
Stats card: show started and answered discussions stats (#2849)
qwerty541 Jun 19, 2023
d727d17
Docs: fix link for extra pins card options (#2855)
qwerty541 Jun 19, 2023
9a1cbaf
Set prettier as workspace default formatter (#2854)
qwerty541 Jun 19, 2023
62080c0
Remove several redundant number -> string -> number conversions (#2856)
qwerty541 Jun 19, 2023
a362af0
feat: add 'progress' rank icon (#2858)
rickstaa Jun 19, 2023
697c3e5
Docs: change example wakatime profile (#2861)
qwerty541 Jun 20, 2023
ae6e2cc
CI: improve pull requests labeler (#2863)
qwerty541 Jun 20, 2023
de093e8
Docs: improve GitHub media feature example HTML formatting (#2862)
qwerty541 Jun 20, 2023
2642fc5
add percentile rank icon (#2859)
rickstaa Jun 20, 2023
de431b9
Use stable axios version 1.x.x (#2873)
qwerty541 Jun 22, 2023
f282ce4
Docs: improve quick align tip section (#2865)
qwerty541 Jun 22, 2023
a48d653
Fixed resizing of stats card when all metrics except rank are hidden …
iwbc-mzk Jun 22, 2023
e5f1399
docs: remove progress rank icon example (#2876)
rickstaa Jun 22, 2023
5486e2c
Increase e2e tests timeout secs (#2878)
qwerty541 Jun 23, 2023
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
1 change: 1 addition & 0 deletions .github/labeler.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
themes: themes/index.js
doc-translation: docs/*
card-i18n: src/translations.js
documentation: readme.md
4 changes: 4 additions & 0 deletions .github/workflows/generate-theme-doc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,10 @@ jobs:
node-version: ${{ matrix.node-version }}
cache: npm

# Fix the unsafe repo error which was introduced by the CVE-2022-24765 git patches.
- name: Fix unsafe repo error
run: git config --global --add safe.directory ${{ github.workspace }}

- name: npm install, generate readme
run: |
npm ci
Expand Down
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,5 @@ vercel_token
# IDE
.vscode
*.code-workspace

.vercel
15 changes: 15 additions & 0 deletions express.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
import statsCard from "./api/index.js";
import repoCard from "./api/pin.js";
import langCard from "./api/top-langs.js";
import wakatimeCard from "./api/wakatime.js";
import express from "express";
import dotenv from "dotenv";

dotenv.config();
const app = express();
app.listen(process.env.port || 9000);

app.get("/", statsCard);
app.get("/pin", repoCard);
app.get("/top-langs", langCard);
app.get("/wakatime", wakatimeCard);
27 changes: 24 additions & 3 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,9 @@ Visit <https://indiafightscorona.giveindia.org> and make a small donation to hel
- [Repo Card Exclusive Options](#repo-card-exclusive-options)
- [Language Card Exclusive Options](#language-card-exclusive-options)
- [Wakatime Card Exclusive Option](#wakatime-card-exclusive-options)
- [Deploy Yourself](#deploy-on-your-own-vercel-instance)
- [Deploy Yourself](#deploy-on-your-own)
- [On Vercel](#on-vercel)
- [On other platforms](#on-other-platforms)
- [Keep your fork up to date](#keep-your-fork-up-to-date)

# GitHub Stats Card
Expand Down Expand Up @@ -133,7 +135,7 @@ You can add the count of all your private contributions to the total commits cou

### Showing icons

To enable icons, you can pass `show_icons=true` in the query param, like so:
To enable icons, you can pass `&show_icons=true` in the query param, like so:

```md
![Anurag's GitHub stats](https://github-readme-stats.vercel.app/api?username=anuraghazra&show_icons=true)
Expand Down Expand Up @@ -509,7 +511,9 @@ By default, GitHub does not lay out the cards side by side. To do that, you can
</a>
```

## Deploy on your own Vercel instance
## Deploy on your own

### On Vercel

#### :film_projector: [Check Out Step By Step Video Tutorial By @codeSTACKr](https://youtu.be/n6d4KHSKqGk?t=107)

Expand Down Expand Up @@ -546,6 +550,23 @@ Since the GitHub API only allows 5k requests per hour, my `https://github-readme

</details>

### On other platforms

> **Warning**
> This way of using GRS is not officially supported and was added to cater to some particular use cases where Vercel could not be used (e.g. #2341). The support for this method, therefore, is limited.

<details>
<summary><b>:hammer_and_wrench: Step-by-step guide for deploying on other platforms</b></summary>

1. Fork or clone this repo as per your needs
2. Add `express` to the dependencies section of `package.json`
https://github.com/anuraghazra/github-readme-stats/blob/ba7c2f8b55eac8452e479c8bd38b044d204d0424/package.json#L54-L61
3. Run `npm i` if needed (initial setup)
4. Run `node express.js` to start the server, or set the entry point to `express.js` in `package.json` if you're deploying on a managed service
https://github.com/anuraghazra/github-readme-stats/blob/ba7c2f8b55eac8452e479c8bd38b044d204d0424/package.json#L11
5. You're done 🎉
</details>

### Keep your fork up to date

You can keep your fork, and thus your private Vercel instance up to date with the upstream using GitHubs' [Sync Fork button](https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/working-with-forks/syncing-a-fork). You can also use the [pull](https://github.com/wei/pull) package created by [@wei](https://github.com/wei) to automate this process.
Expand Down
9 changes: 5 additions & 4 deletions scripts/preview-theme.js
Original file line number Diff line number Diff line change
Expand Up @@ -298,12 +298,13 @@ const themeNameAlreadyExists = (name) => {
return themes[name] !== undefined;
};

const DRY_RUN = process.env.DRY_RUN === "true" || false;

/**
* Main function.
*/
export const run = async (prNumber) => {
try {
const dryRun = process.env.DRY_RUN === "true" || false;
debug("Retrieve action information from context...");
debug(`Context: ${inspect(github.context)}`);
let commentBody = `
Expand Down Expand Up @@ -513,7 +514,7 @@ export const run = async (prNumber) => {
// Create or update theme-preview comment.
debug("Create or update theme-preview comment...");
let comment_url;
if (!dryRun) {
if (!DRY_RUN) {
comment_url = await upsertComment(octokit, {
comment_id: comment?.id,
issue_number: pullRequestId,
Expand All @@ -535,7 +536,7 @@ export const run = async (prNumber) => {
const reviewReason = themesValid
? undefined
: INVALID_REVIEW_COMMENT(comment_url);
if (!dryRun) {
if (!DRY_RUN) {
await addReview(
octokit,
pullRequestId,
Expand All @@ -558,7 +559,7 @@ export const run = async (prNumber) => {
}
} catch (error) {
debug("Set review state to `REQUEST_CHANGES` and add `invalid` label...");
if (!dryRun) {
if (!DRY_RUN) {
await addReview(
octokit,
pullRequestId,
Expand Down
3 changes: 1 addition & 2 deletions src/cards/top-languages-card.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import {
import { langCardLocales } from "../translations.js";

const DEFAULT_CARD_WIDTH = 300;
const MIN_CARD_WIDTH = 230;
const MIN_CARD_WIDTH = 280;
const DEFAULT_LANGS_COUNT = 5;
const DEFAULT_LANG_COLOR = "#858585";
const CARD_PADDING = 25;
Expand Down Expand Up @@ -317,7 +317,6 @@ const renderTopLanguages = (topLangs, options = {}) => {

let finalLayout = "";
if (layout === "compact" || hide_progress == true) {
width = width + 50; // padding
height =
calculateCompactLayoutHeight(langs.length) + (hide_progress ? -25 : 0);

Expand Down
26 changes: 25 additions & 1 deletion src/cards/wakatime-card.js
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,7 @@ const createTextNode = ({
// @ts-ignore
name: label,
progressBarBackgroundColor,
delay: staggerDelay + 300,
});

return `
Expand Down Expand Up @@ -276,11 +277,12 @@ const renderWakatimeCard = (stats = {}, options = { hide: [] }) => {
} else {
finalLayout = flexLayout({
items: filteredLanguages.length
? filteredLanguages.map((language) => {
? filteredLanguages.map((language, index) => {
return createTextNode({
id: language.name,
label: language.name,
value: language.text,
index: index,
percent: language.percent,
// @ts-ignore
progressBarColor: titleColor,
Expand Down Expand Up @@ -321,7 +323,29 @@ const renderWakatimeCard = (stats = {}, options = { hide: [] }) => {
card.setCSS(
`
${cssStyles}
@keyframes slideInAnimation {
from {
width: 0;
}
to {
width: calc(100%-100px);
}
}
@keyframes growWidthAnimation {
from {
width: 0;
}
to {
width: 100%;
}
}
.lang-name { font: 400 11px 'Segoe UI', Ubuntu, Sans-Serif; fill: ${textColor} }
#rect-mask rect{
animation: slideInAnimation 1s ease-in-out forwards;
}
.lang-progress{
animation: growWidthAnimation 0.6s ease-in-out forwards;
}
`,
);

Expand Down
44 changes: 44 additions & 0 deletions tests/__snapshots__/renderWakatimeCard.test.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,29 @@ exports[`Test Render Wakatime Card should render correctly with compact layout 1
}


@keyframes slideInAnimation {
from {
width: 0;
}
to {
width: calc(100%-100px);
}
}
@keyframes growWidthAnimation {
from {
width: 0;
}
to {
width: 100%;
}
}
.lang-name { font: 400 11px 'Segoe UI', Ubuntu, Sans-Serif; fill: #434d58 }
#rect-mask rect{
animation: slideInAnimation 1s ease-in-out forwards;
}
.lang-progress{
animation: growWidthAnimation 0.6s ease-in-out forwards;
}



Expand Down Expand Up @@ -227,7 +249,29 @@ exports[`Test Render Wakatime Card should render correctly with compact layout w
}


@keyframes slideInAnimation {
from {
width: 0;
}
to {
width: calc(100%-100px);
}
}
@keyframes growWidthAnimation {
from {
width: 0;
}
to {
width: 100%;
}
}
.lang-name { font: 400 11px 'Segoe UI', Ubuntu, Sans-Serif; fill: #434d58 }
#rect-mask rect{
animation: slideInAnimation 1s ease-in-out forwards;
}
.lang-progress{
animation: growWidthAnimation 0.6s ease-in-out forwards;
}



Expand Down
6 changes: 3 additions & 3 deletions tests/e2e/e2e.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,14 @@ const REPO = "curly-fiesta";
const USER = "catelinemnemosyne";
const STATS_DATA = {
name: "Cateline Mnemosyne",
totalPRs: 1,
totalCommits: 7,
totalPRs: 2,
totalCommits: 8,
totalIssues: 1,
totalStars: 1,
contributedTo: 1,
rank: {
level: "A+",
score: 50.893750297869225,
score: 50.88831151384285,
},
};

Expand Down
6 changes: 3 additions & 3 deletions tests/renderTopLanguages.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -216,23 +216,23 @@ describe("Test renderTopLanguages", () => {
);
expect(queryAllByTestId(document.body, "lang-progress")[0]).toHaveAttribute(
"width",
"120",
"100",
);

expect(queryAllByTestId(document.body, "lang-name")[1]).toHaveTextContent(
"javascript 40.00%",
);
expect(queryAllByTestId(document.body, "lang-progress")[1]).toHaveAttribute(
"width",
"120",
"100",
);

expect(queryAllByTestId(document.body, "lang-name")[2]).toHaveTextContent(
"css 20.00%",
);
expect(queryAllByTestId(document.body, "lang-progress")[2]).toHaveAttribute(
"width",
"60",
"50",
);
});

Expand Down
14 changes: 14 additions & 0 deletions themes/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -374,13 +374,27 @@ export const themes = {
border_color: "170F0C",
bg_color: "170F0C",
},
one_dark_pro: {
title_color: "61AFEF",
text_color: "E5C06E",
icon_color: "C678DD",
border_color: "3B4048",
bg_color: "23272E",
},
rose: {
title_color: "8d192b",
text_color: "862931",
icon_color: "B71F36",
border_color: "e9d8d4",
bg_color: "e9d8d4",
},
holi_theme: {
title_color: "5FABEE",
text_color: "D6E7FF",
icon_color: "5FABEE",
border_color: "85A4C0",
bg_color: "030314",
},
};

export default themes;