diff --git a/apps/backend/server.js b/apps/backend/server.js index eaaf23a..48a9ac3 100644 --- a/apps/backend/server.js +++ b/apps/backend/server.js @@ -744,16 +744,8 @@ function extractCip(text) { return CARD_TEXT_PATTERNS.some(pattern => pattern.test(upper)); }; - // Try to find barcodes first (typically numeric-heavy) - // TSI barcodes are usually numeric or alphanumeric with mostly numbers - const numericMatches = cleaned.match(/\d{10,30}/g) || []; - for (const match of numericMatches) { - if (match.length >= 10 && match.length <= 30) { - return match.toUpperCase(); - } - } - - // Try exact 16-char alphanumeric match, but filter card text + // TSI barcodes are alphanumeric like "803401INURO0890417003211T11" + // Prioritize full alphanumeric matches (8-30 chars) before pure numeric const exact = cleaned.match(/[A-Z0-9]{16}/i); if (exact) { const candidate = exact[0].toUpperCase(); @@ -762,7 +754,6 @@ function extractCip(text) { } } - // Fallback: 8–30 alphanumeric chars, filter card text const looseMatches = cleaned.match(/[A-Z0-9]{8,30}/gi) || []; for (const match of looseMatches) { const candidate = match.toUpperCase(); diff --git a/apps/frontend/public/farmaclic_logo_home.png b/apps/frontend/public/farmaclic_logo_home.png new file mode 100644 index 0000000..5a3eb28 Binary files /dev/null and b/apps/frontend/public/farmaclic_logo_home.png differ diff --git a/apps/frontend/src/views/HomeView.jsx b/apps/frontend/src/views/HomeView.jsx index 9cbfc59..fe2cb1d 100644 --- a/apps/frontend/src/views/HomeView.jsx +++ b/apps/frontend/src/views/HomeView.jsx @@ -6,7 +6,7 @@ function HomeView({ onScanClick, onSearchClick }) {
- FarmaClic + FarmaClic FarmaClic

Encuentra tus medicamentos en farmacias cercanas