Skip to content

Commit

Permalink
Merge pull request #2985 from responsible-ai-collaborative/staging
Browse files Browse the repository at this point in the history
Deploy to Production
  • Loading branch information
kepae authored Jul 19, 2024
2 parents 3bdd8e5 + 03968d5 commit f9c5e8c
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 8 deletions.
22 changes: 15 additions & 7 deletions site/gatsby-site/src/components/cite/IncidentStatsCard.js
Original file line number Diff line number Diff line change
Expand Up @@ -51,16 +51,24 @@ const IncidentStatsCard = ({
<Trans>Incident Stats</Trans>
</h4>
</Card.Header>
<Card.Body className="grid max-w-full p-5 grid-cols-2 lg:grid-cols-1fr-3fr">
{STATS.map((stat) => (
<div className="p-0 m-0 grid max-w-full grid-cols-2 lg:grid-cols-1fr-3fr [&>*:nth-child(4n)]:bg-gray-50">
{STATS.map((stat, i) => (
<Fragment key={stat.key}>
<div className="pr-4 my-0.5">{stat.label}</div>
<div>{stats[stat.key]}</div>
<div
className={`p-4 bg-gray-100 border-1 ${i == 0 ? 'border-t-0' : ''} border-gray-200`}
>
{stat.label}
</div>
<div className={`p-4 border-1 ${i == 0 ? 'border-t-0' : ''} border-gray-200`}>
{stats[stat.key]}
</div>
</Fragment>
))}

<div className="pr-4 my-0.5">Applied Taxonomies</div>
<div>
<div className={`p-4 bg-gray-100 border-1 border-gray-200 rounded-bl`}>
Applied Taxonomies
</div>
<div className={`p-4 border-1 border-gray-200 border-b-0 rounded-br`}>
{taxonomiesWithClassifications.map((t, i) => {
const color = { CSETv1: 'orange', GMF: 'blue' }[t] || 'gray';

Expand All @@ -81,7 +89,7 @@ const IncidentStatsCard = ({
);
})}
</div>
</Card.Body>
</div>
</Card>
);
};
Expand Down
2 changes: 1 addition & 1 deletion site/gatsby-site/src/components/forms/QuickAddForm.js
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ const QuickAddForm = ({ className = '' }) => {
const url = new URL(values.url);

const quickAdd = {
incident_id: '0',
incident_id: 0,
date_submitted: format(new Date(), 'yyyy-MM-dd'),
source_domain: getSourceDomain(url),
url: url.href,
Expand Down

0 comments on commit f9c5e8c

Please sign in to comment.