diff --git a/src/uxcore/api/rating.ts b/src/uxcore/api/rating.ts index 72a0dff..84471aa 100644 --- a/src/uxcore/api/rating.ts +++ b/src/uxcore/api/rating.ts @@ -5,7 +5,13 @@ export const rateRequest = async ( ) => { // Geo enrichment is best-effort: a failed /api/user lookup must not // abort the vote itself. - let userData: any = {}; + type TUserGeo = { + country?: string; + region?: string; + city?: string; + ip?: string; + }; + let userData: TUserGeo = {}; try { userData = await fetch('/api/user').then(data => data.json()); } catch { diff --git a/src/uxcore/components/OffsecBiasView/OffsecBiasView.tsx b/src/uxcore/components/OffsecBiasView/OffsecBiasView.tsx index 19c4330..87f2359 100644 --- a/src/uxcore/components/OffsecBiasView/OffsecBiasView.tsx +++ b/src/uxcore/components/OffsecBiasView/OffsecBiasView.tsx @@ -1,4 +1,5 @@ import { OffsecBiasCard, OffsecBiasContent } from '@uxcore/data/biasOffsec'; +import cn from 'classnames'; import KemmioCredit from './KemmioCredit'; @@ -231,9 +232,9 @@ const CardBody = ({ card }: { card: OffsecBiasCard }) => { {card.items.map((item, i) => (
{item.flagged && } @@ -296,7 +297,7 @@ const OffsecBiasView = ({ content }: OffsecBiasViewProps) => {
{before.tag} -
+
@@ -306,13 +307,15 @@ const OffsecBiasView = ({ content }: OffsecBiasViewProps) => {
- + {after.tag}
diff --git a/src/uxcore/layouts/OngoingLayout/OngoingLayout.module.scss b/src/uxcore/layouts/OngoingLayout/OngoingLayout.module.scss index afe077d..3c9d325 100644 --- a/src/uxcore/layouts/OngoingLayout/OngoingLayout.module.scss +++ b/src/uxcore/layouts/OngoingLayout/OngoingLayout.module.scss @@ -1,4 +1,6 @@ $white: #fafafa; +// Error red shared with the UXCP DecisionTable error surface. +$error-red: #fb1717; .ongoing { background-color: $white; @@ -254,7 +256,9 @@ $white: #fafafa; .submitError { text-align: center; - color: #fb1717; + // Same error red the UXCP DecisionTable error surface uses — reuse, not + // a new invented color. + color: $error-red; font-size: 16px; line-height: 150%; margin-top: 16px;