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

Refactor CSS files in src/screens/OrgContribution (Fixs : #2520) #2674

Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
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
114 changes: 67 additions & 47 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@
"sass": "^1.80.7",
"tsx": "^4.19.1",
"vite-plugin-svgr": "^4.2.0",
"vitest": "^2.1.5",
"vitest": "^2.1.8",
"whatwg-fetch": "^3.6.20"
},
"resolutions": {
Expand Down
7 changes: 0 additions & 7 deletions src/components/ContriStats/ContriStats.module.css

This file was deleted.

19 changes: 13 additions & 6 deletions src/components/ContriStats/ContriStats.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import React from 'react';
import { useTranslation } from 'react-i18next';

import styles from './ContriStats.module.css';
import styles from '../../style/app.module.css';

interface InterfaceContriStatsProps {
id: string;
Expand All @@ -13,27 +13,34 @@ interface InterfaceContriStatsProps {
/**
* A component that displays contribution statistics.
*
* @param props - The properties passed to the component, including `recentAmount`, `highestAmount`, and `totalAmount`.
* @param recentAmount - The most recent contribution amount.
* @param highestAmount - The highest contribution amount.
* @param totalAmount - The total contribution amount.
*
* @returns JSX.Element - The rendered component displaying the contribution stats.
*/
function ContriStats(props: InterfaceContriStatsProps): JSX.Element {
function ContriStats({
recentAmount,
highestAmount,
totalAmount,
}: InterfaceContriStatsProps): JSX.Element {
const { t } = useTranslation('translation', {
keyPrefix: 'contriStats',
});

return (
<>
<p className={styles.fonts}>
{t('recentContribution')}: $&nbsp;<span>{props.recentAmount}</span>
{t('recentContribution')}: $&nbsp;<span>{recentAmount}</span>
</p>
<p className={styles.fonts}>
{t('highestContribution')}: $&nbsp;<span>{props.highestAmount}</span>
{t('highestContribution')}: $&nbsp;<span>{highestAmount}</span>
</p>
<p className={styles.fonts}>
{t('totalContribution')}: $&nbsp;<span>{props.totalAmount}</span>
{t('totalContribution')}: $&nbsp;<span>{totalAmount}</span>
</p>
</>
);
}

export default ContriStats;
22 changes: 0 additions & 22 deletions src/components/OrgContriCards/OrgContriCards.module.css

This file was deleted.

2 changes: 1 addition & 1 deletion src/components/OrgContriCards/OrgContriCards.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import Row from 'react-bootstrap/Row';
import Col from 'react-bootstrap/Col';
import { useTranslation } from 'react-i18next';

import styles from './OrgContriCards.module.css';
import styles from '../../style/app.module.css';

/**
* Props for the OrgContriCards component
Expand Down
Loading
Loading