Files
loyaly_cutomerweb/src/features/engagement/components/AttributionNote.tsx
2026-09-25 16:31:10 +05:30

19 lines
578 B
TypeScript

'use client';
import {Text} from '@astryxdesign/core/Text';
import {ATTRIBUTION_NOTE, type Attribution} from '@/features/engagement/types/engagement';
/**
* The disclosure beside every attributed figure. Renders NOTHING when the
* basis is `observed`, so a real attribution backend retires it with no copy
* change. The basis is read off the payload, never hardcoded.
*/
export function AttributionNote({basis}: {basis: Attribution}) {
if (basis === 'observed') return null;
return (
<Text size="xsm" color="secondary">
{ATTRIBUTION_NOTE}
</Text>
);
}