File tree Expand file tree Collapse file tree 20 files changed +63
-19
lines changed Expand file tree Collapse file tree 20 files changed +63
-19
lines changed Original file line number Diff line number Diff line change 1
1
themes : themes/index.js
2
2
doc-translation : docs/*
3
- card-i18n : src/translations.js
3
+ card-i18n : src/assets/ translations.js
Original file line number Diff line number Diff line change 9
9
renderError ,
10
10
} from "../src/common/utils.js" ;
11
11
import { fetchStats } from "../src/fetchers/stats-fetcher.js" ;
12
- import { isLocaleAvailable } from "../src/translations.js" ;
12
+ import { isLocaleAvailable } from "../src/assets/ translations.js" ;
13
13
14
14
dotenv . config ( ) ;
15
15
Original file line number Diff line number Diff line change 7
7
renderError ,
8
8
} from "../src/common/utils.js" ;
9
9
import { fetchRepo } from "../src/fetchers/repo-fetcher.js" ;
10
- import { isLocaleAvailable } from "../src/translations.js" ;
10
+ import { isLocaleAvailable } from "../src/assets/ translations.js" ;
11
11
12
12
export default async ( req , res ) => {
13
13
const {
Original file line number Diff line number Diff line change 9
9
renderError ,
10
10
} from "../src/common/utils.js" ;
11
11
import { fetchTopLanguages } from "../src/fetchers/top-languages-fetcher.js" ;
12
- import { isLocaleAvailable } from "../src/translations.js" ;
12
+ import { isLocaleAvailable } from "../src/assets/ translations.js" ;
13
13
14
14
dotenv . config ( ) ;
15
15
Original file line number Diff line number Diff line change 8
8
renderError ,
9
9
} from "../src/common/utils.js" ;
10
10
import { fetchWakatimeStats } from "../src/fetchers/wakatime-fetcher.js" ;
11
- import { isLocaleAvailable } from "../src/translations.js" ;
11
+ import { isLocaleAvailable } from "../src/assets/ translations.js" ;
12
12
13
13
dotenv . config ( ) ;
14
14
Original file line number Diff line number Diff line change 1
1
{
2
2
"name" : " github-readme-stats" ,
3
3
"version" : " 1.0.0" ,
4
- "description" : " Dynamically generate stats for your github readmes" ,
5
- "main" : " index.js" ,
4
+ "description" : " Dynamically generate stats for your GitHub readme" ,
5
+ "keywords" : [
6
+ " github-readme-stats" ,
7
+ " readme-stats" ,
8
+ " cards" ,
9
+ " card-generator"
10
+ ],
11
+ "main" : " src/index.js" ,
6
12
"type" : " module" ,
13
+ "homepage" : " https://github.com/anuraghazra/github-readme-stats" ,
14
+ "bugs" : {
15
+ "url" : " https://github.com/anuraghazra/github-readme-stats/issues"
16
+ },
17
+ "repository" : {
18
+ "type" : " git" ,
19
+ "url" : " https://github.com/anuraghazra/github-readme-stats.git"
20
+ },
7
21
"scripts" : {
8
22
"test" : " node --experimental-vm-modules node_modules/jest/bin/jest.js --coverage" ,
9
23
"test:watch" : " node --experimental-vm-modules node_modules/jest/bin/jest.js --watch" ,
Original file line number Diff line number Diff line change 1
- import { encodeHTML } from "./common/utils.js" ;
1
+ import { encodeHTML } from ".. /common/utils.js" ;
2
2
3
3
const statCardLocales = ( { name, apostrophe } ) => {
4
4
const encodedName = encodeHTML ( name ) ;
Original file line number Diff line number Diff line change @@ -11,7 +11,7 @@ import {
11
11
parseEmojis ,
12
12
wrapTextMultiline ,
13
13
} from "../common/utils.js" ;
14
- import { repoCardLocales } from "../translations.js" ;
14
+ import { repoCardLocales } from "../assets/ translations.js" ;
15
15
16
16
/**
17
17
* @param {string } label
Original file line number Diff line number Diff line change 9
9
kFormatter ,
10
10
measureText ,
11
11
} from "../common/utils.js" ;
12
- import { getStyles } from "../getStyles.js" ;
13
- import { statCardLocales } from "../translations.js" ;
12
+ import { getStyles } from "../common/ getStyles.js" ;
13
+ import { statCardLocales } from "../assets/ translations.js" ;
14
14
15
15
/**
16
16
* Create a stats card text item.
Original file line number Diff line number Diff line change @@ -10,7 +10,7 @@ import {
10
10
lowercaseTrim ,
11
11
measureText ,
12
12
} from "../common/utils.js" ;
13
- import { langCardLocales } from "../translations.js" ;
13
+ import { langCardLocales } from "../assets/ translations.js" ;
14
14
15
15
const DEFAULT_CARD_WIDTH = 300 ;
16
16
const MIN_CARD_WIDTH = 230 ;
Original file line number Diff line number Diff line change 8
8
getCardColors ,
9
9
lowercaseTrim ,
10
10
} from "../common/utils.js" ;
11
- import { getStyles } from "../getStyles.js" ;
12
- import { wakatimeCardLocales } from "../translations.js" ;
11
+ import { getStyles } from "../common/ getStyles.js" ;
12
+ import { wakatimeCardLocales } from "../assets/ translations.js" ;
13
13
14
14
/** Import language colors.
15
15
*
Original file line number Diff line number Diff line change 1
- import { getAnimations } from ".. /getStyles.js" ;
1
+ import { getAnimations } from "./getStyles.js" ;
2
2
import { encodeHTML , flexLayout } from "./utils.js" ;
3
3
4
4
class Card {
File renamed without changes.
Original file line number Diff line number Diff line change
1
+ export { blacklist } from "./blacklist.js" ;
2
+ export { Card } from "./Card.js" ;
3
+ export { createProgressNode } from "./createProgressNode.js" ;
4
+ export { getStyles , getAnimations } from "./getStyles.js" ;
5
+ export { i18n } from "./i18n.js" ;
6
+ export { icons } from "./icons.js" ;
7
+ export { retryer } from "./retryer.js" ;
8
+ export {
9
+ renderError ,
10
+ kFormatter ,
11
+ encodeHTML ,
12
+ isValidHexColor ,
13
+ request ,
14
+ parseArray ,
15
+ parseBoolean ,
16
+ fallbackColor ,
17
+ flexLayout ,
18
+ getCardColors ,
19
+ clampValue ,
20
+ wrapTextMultiline ,
21
+ measureText ,
22
+ logger ,
23
+ CONSTANTS ,
24
+ CustomError ,
25
+ MissingParamError ,
26
+ lowercaseTrim ,
27
+ chunkArray ,
28
+ parseEmojis ,
29
+ } from "./utils.js" ;
File renamed without changes.
Original file line number Diff line number Diff line change 2
2
import axios from "axios" ;
3
3
import * as dotenv from "dotenv" ;
4
4
import githubUsernameRegex from "github-username-regex" ;
5
- import { calculateRank } from ".. /calculateRank.js" ;
5
+ import { calculateRank } from "./helpers /calculateRank.js" ;
6
6
import { retryer } from "../common/retryer.js" ;
7
7
import {
8
8
CustomError ,
Original file line number Diff line number Diff line change
1
+ export * from "./common/index.js" ;
Original file line number Diff line number Diff line change @@ -2,7 +2,7 @@ import { jest } from "@jest/globals";
2
2
import axios from "axios" ;
3
3
import MockAdapter from "axios-mock-adapter" ;
4
4
import api from "../api/index.js" ;
5
- import { calculateRank } from "../src/calculateRank.js" ;
5
+ import { calculateRank } from "../src/fetchers/helpers/ calculateRank.js" ;
6
6
import { renderStatsCard } from "../src/cards/stats-card.js" ;
7
7
import { CONSTANTS , renderError } from "../src/common/utils.js" ;
8
8
Original file line number Diff line number Diff line change 1
1
import "@testing-library/jest-dom" ;
2
- import { calculateRank } from "../src/calculateRank.js" ;
2
+ import { calculateRank } from "../src/fetchers/helpers/ calculateRank.js" ;
3
3
4
4
describe ( "Test calculateRank" , ( ) => {
5
5
it ( "should calculate rank correctly" , ( ) => {
Original file line number Diff line number Diff line change 1
1
import "@testing-library/jest-dom" ;
2
2
import axios from "axios" ;
3
3
import MockAdapter from "axios-mock-adapter" ;
4
- import { calculateRank } from "../src/calculateRank.js" ;
4
+ import { calculateRank } from "../src/fetchers/helpers/ calculateRank.js" ;
5
5
import { fetchStats } from "../src/fetchers/stats-fetcher.js" ;
6
6
7
7
const data = {
You can’t perform that action at this time.
0 commit comments