fix: preserve undocumented Mocuba fields and hide internal office source names in QA

This commit is contained in:
2026-11-21 21:12:34 +02:00
parent a4ecc8a5a9
commit b20feeb72e
17 changed files with 805 additions and 8 deletions
@@ -147,8 +147,7 @@ export function LocationList({
{!location.coordinates.length && (
<p>Coordenadas não documentadas.</p>
)}
{(publicReference(location.source_reference) ||
location.source_date) && (
{publicReference(location.source_reference) && (
<p className="text-sm">
{publicReference(location.source_reference) && (
<>
@@ -158,11 +157,12 @@ export function LocationList({
/>
</>
)}
{location.source_date && (
<> · Data: {location.source_date}</>
)}
</p>
)}
<p className="text-sm">
Data da fonte:{' '}
{location.source_date?.trim() || 'Não documentada'}
</p>
{uniquePresentation(location.boundaries ?? [], (b) =>
JSON.stringify([
b.geometry_id,
+1 -1
View File
@@ -28,7 +28,7 @@ export function publicReference(
return text;
}
if (
/(?:[A-Z]:[\\/]|\\\\|file:\/\/|(?:^|[\s/])(?:outputs|resources|storage|vendor|node_modules|docs|tests|app)[\\/]|\b(?:localhost|127\.0\.0\.\d|0\.0\.0\.0)\b|\.(?:tsx?|jsx?|py|php|sql|md|json|log|cjs|mjs)(?:\b|$)|\b(?:MASTER|AUD|QA|REQ|ME|PN)[-_ ](?:[A-Z]*\d|[A-Z0-9]{6,})|\bgit\s+(?:commit|branch|diff)\b)/i.test(
/(?:[A-Z]:[\\/]|\\\\|file:\/\/|(?:^|[\s/])(?:outputs|resources|storage|vendor|node_modules|docs|tests|app)[\\/]|\b(?:localhost|127\.0\.0\.\d|0\.0\.0\.0)\b|\.(?:tsx?|jsx?|py|php|sql|md|json|log|cjs|mjs|docx?|xlsx?|xlsm|emf)(?:\b|$)|\b(?:MASTER|AUD|QA|REQ|ME|PN)[-_ ](?:[A-Z]*\d|[A-Z0-9]{6,})|\bgit\s+(?:commit|branch|diff)\b)/i.test(
text,
)
)