Pantalla: Historial de Alertas
Identificador: SCR-ALT-003
Modulo: MTS-ALT-001 - Alertas y Notificaciones
Version: 1.0.0
Fecha: 2025-12-05
Autor: MobileUxUiDrone (Eight of Eight)
Estado: Especificado
| Atributo |
Valor |
| Nombre |
Historial de Alertas |
| Proposito |
Mostrar lista historica de todas las alertas pasadas con filtros |
| Tipo |
Full Screen (lista scrolleable) |
| Acceso |
Centro de notificaciones > Historial |
| Prioridad |
Media |
2. Wireframe ASCII
2.1. Estado: Lista con Historial
+------------------------------------------+
| [<] Historial de Alertas [Filter]| <- Top App Bar
+------------------------------------------+
| |
| +------------------------------------+ |
| | [Calendar] Dic 2025 [v] | | <- Date filter
| +------------------------------------+ |
| |
| Hoy, 5 de Diciembre | <- Section header
| +------------------------------------+ |
| | [v] 20:00 Medicinas de la noche ||
| | Metformina, Losartan || <- Confirmed
| | Tomada a las 20:05 ||
| +------------------------------------+ |
| |
| +------------------------------------+ |
| | [v] 14:00 Medicinas del almuerzo ||
| | Metformina ||
| | Tomada a las 14:15 ||
| +------------------------------------+ |
| |
| +------------------------------------+ |
| | [!] 08:00 Medicinas del desayuno ||
| | Insulina, Metformina || <- Has critical
| | Tomada a las 08:45 (tarde) ||
| +------------------------------------+ |
| |
| Ayer, 4 de Diciembre |
| +------------------------------------+ |
| | [v] 20:00 Medicinas de la noche ||
| | Metformina, Losartan ||
| | Tomada a las 20:00 ||
| +------------------------------------+ |
| |
| +------------------------------------+ |
| | [X] 14:00 Medicinas del almuerzo ||
| | Metformina || <- Omitted
| | Omitida - Efectos secundarios ||
| +------------------------------------+ |
| |
| [Cargar mas...] | <- Pagination
| |
+------------------------------------------+
| [Home] [Pills] [Calendar] [Stats] [More] |
+------------------------------------------+
2.2. Estado: Con Filtros Activos
+------------------------------------------+
| [<] Historial de Alertas [Filter]|
+------------------------------------------+
| |
| Filtros activos: |
| +----------+ +------------+ +------+ |
| |Omitidas X| |Insulina X| |Dic X| | <- Active filters
| +----------+ +------------+ +------+ |
| |
| 3 alertas encontradas | <- Results count
| |
| 4 de Diciembre |
| +------------------------------------+ |
| | [X] 14:00 Insulina ||
| | Omitida - No disponible ||
| +------------------------------------+ |
| |
| 2 de Diciembre |
| +------------------------------------+ |
| | [X] 08:00 Insulina ||
| | Omitida - Se me olvido ||
| +------------------------------------+ |
| |
| 28 de Noviembre |
| +------------------------------------+ |
| | [X] 08:00 Insulina ||
| | Omitida - Efectos secundarios ||
| +------------------------------------+ |
| |
| +------------------------------------+ |
| | [Limpiar filtros] | |
| +------------------------------------+ |
| |
+------------------------------------------+
2.3. Estado: Vacio (Sin Historial)
+------------------------------------------+
| [<] Historial de Alertas [Filter]|
+------------------------------------------+
| |
| |
| |
| +----------------+ |
| | | |
| | [Ilustracion | |
| | Calendario] | |
| | | |
| +----------------+ |
| |
| No hay alertas registradas |
| |
| Tu historial de alertas aparecera |
| aqui cuando comiences a usar |
| la aplicacion |
| |
| |
| |
+------------------------------------------+
2.4. Panel de Filtros (Bottom Sheet)
+------------------------------------------+
| Filtrar historial [X] |
+------------------------------------------+
| |
| Estado: |
| +----------+ +----------+ +----------+ |
| | Todas | |Confirmadas| | Omitidas| |
| +----------+ +----------+ +----------+ |
| |
| Periodo: |
| +----------+ +----------+ +----------+ |
| | Hoy | | Semana | | Mes | |
| +----------+ +----------+ +----------+ |
| +------------------------------------+ |
| | Personalizado... | |
| +------------------------------------+ |
| |
| Medicamento: |
| +------------------------------------+ |
| | Todos los medicamentos [v] | |
| +------------------------------------+ |
| |
| Incluir: |
| [x] Alertas criticas |
| [x] Alertas normales |
| [ ] Alertas pospuestas |
| |
| +------------------------------------+ |
| | [Aplicar filtros] | |
| +------------------------------------+ |
| |
+------------------------------------------+
3. Componentes UI
3.1. Top App Bar
| Propiedad |
Valor |
| Componente |
CMP-NAV-002 (Top App Bar) |
| Variante |
regular |
| Titulo |
"Historial de Alertas" |
| Leading |
Back arrow |
| Trailing |
Filter icon (badge si hay filtros activos) |
3.2. Date Filter Bar
| Propiedad |
Valor |
| Componente |
CMP-INP-005 (Date Selector) |
| Variante |
month-picker |
| Default |
Mes actual |
| Icono |
Calendar |
| Propiedad |
Valor |
| Texto |
"Hoy, 5 de Diciembre" / "Ayer" / Fecha |
| Tipografia |
lg, medium weight |
| Sticky |
Si (se mantiene al scroll) |
3.4. Alert History Card
| Propiedad |
Valor |
| Componente |
CMP-CRD-005 (History Card) |
| Variante |
compact |
| Touch target |
Full card tappable |
Elementos por card:
| Elemento |
Descripcion |
| Status icon |
Checkmark (verde), X (rojo), Clock (amarillo) |
| Hora |
Hora programada |
| Nombre evento |
"Medicinas del desayuno" |
| Medicamentos |
Lista compacta de nombres |
| Resultado |
"Tomada a las 08:05" / "Omitida - Razon" |
| Badge |
"Tarde" si overdue, "Critica" si aplica |
Estados visuales de la card:
| Estado |
Icono |
Color border |
| Confirmada |
Checkmark |
success.main |
| Confirmada tarde |
Checkmark + badge |
warning.main |
| Omitida |
X |
error.main |
| Pospuesta |
Clock |
neutral.400 |
3.5. Filter Chips
| Propiedad |
Valor |
| Componente |
CMP-INP-006 (Chip) |
| Variante |
filter |
| Dismissible |
Si (X para remover) |
| Propiedad |
Valor |
| Componente |
CMP-BTN-003 (Text Button) |
| Label |
"Cargar mas..." |
| Loading state |
Spinner mientras carga |
4. Comportamientos
4.1. Gestos
| Gesto |
Elemento |
Accion |
| Tap |
History Card |
Abrir SCR-ALT-002 en modo historial |
| Tap |
Filter icon |
Abrir panel de filtros |
| Tap |
Filter chip X |
Remover ese filtro |
| Tap |
Cargar mas |
Fetch siguiente pagina |
| Pull Down |
Lista |
Refresh datos |
| Swipe Left |
Card |
Revelar "Exportar" / "Compartir" |
4.2. Paginacion
| Parametro |
Valor |
| Page size |
20 alertas |
| Infinite scroll |
Si (trigger a 80% scroll) |
| Cache |
Ultimos 3 meses en cache |
4.3. Filtrado
flowchart TD
A[Usuario abre filtros] --> B[Selecciona criterios]
B --> C[Tap Aplicar]
C --> D{Hay resultados?}
D -->|Si| E[Mostrar lista filtrada]
D -->|No| F[Mostrar empty state con sugerencia]
E --> G[Mostrar chips activos]
G --> H{Usuario remueve chip?}
H -->|Si| I[Re-filtrar sin ese criterio]
H -->|No| J[Mantener filtros]
I --> D
5. Estados y Transiciones
5.1. Diagrama de Estados
stateDiagram-v2
[*] --> Loading: Abrir pantalla
Loading --> Empty: Sin historial
Loading --> Loaded: Con historial
Loading --> Error: Fallo carga
Loaded --> Filtering: Abrir filtros
Filtering --> Loaded: Aplicar/Cancelar
Loaded --> LoadingMore: Scroll al final
LoadingMore --> Loaded: Mas datos
Error --> Loading: Reintentar
6. Datos Requeridos
interface AlertHistoryData {
alerts: AlertHistoryItem[];
total_count: number;
has_more: boolean;
filters_applied: AlertFilters;
date_range: { from: Date; to: Date };
}
interface AlertHistoryItem {
id: string;
event_id: string;
event_name: string;
scheduled_time: Date;
status: 'CONFIRMED' | 'OMITTED' | 'SNOOZED' | 'ESCALATED';
completed_at?: Date;
was_overdue: boolean;
overdue_minutes?: number;
medications: string[]; // Solo nombres para vista compacta
omit_reason?: OmitReason;
note?: string;
confirmed_by?: 'PATIENT' | 'CARER';
has_critical: boolean;
}
interface AlertFilters {
status?: ('CONFIRMED' | 'OMITTED' | 'SNOOZED')[];
medication_id?: string;
date_from?: Date;
date_to?: Date;
include_critical?: boolean;
include_normal?: boolean;
}
6.2. Output Events
| Evento |
Payload |
Destino |
| onAlertTap |
alert_id |
SCR-ALT-002 (history mode) |
| onFilterChange |
filters |
Refresh list |
| onLoadMore |
page_number |
API |
| onExport |
date_range, format |
Generate export |
| onRefresh |
- |
Reload data |
7. Accesibilidad
7.1. Labels y Hints
| Elemento |
accessibilityLabel |
accessibilityHint |
| Pantalla |
"Historial de alertas" |
- |
| Filter button |
"Filtrar historial" |
"Abre opciones de filtrado" |
| Date picker |
"Seleccionar mes, {mes actual}" |
"Toca para cambiar el periodo" |
| History card |
"{evento}, {hora}, {estado}" |
"Toca para ver detalles" |
| Filter chip |
"Filtro: {nombre}. Doble tap para remover" |
- |
| Cargar mas |
"Cargar mas alertas" |
"Carga las siguientes 20 alertas" |
7.2. Orden de Foco
- Back button
- Filter button
- Date picker
- Chips de filtro activos (si hay)
- Primera section header
- Primera history card
- ... (continua por fecha)
- Cargar mas (si visible)
7.3. Screen Reader Announcements
| Evento |
Anuncio |
| Lista cargada |
"{N} alertas en el historial" |
| Filtros aplicados |
"Mostrando {N} alertas filtradas" |
| Mas cargados |
"{N} alertas adicionales cargadas" |
| Sin resultados |
"No hay alertas con estos filtros" |
7.4. Contraste y Tamanos
| Elemento |
Min Size |
Contraste |
| Section header |
16sp |
4.5:1 |
| Card event name |
16sp |
4.5:1 |
| Card details |
14sp |
4.5:1 |
| Status icon |
24x24dp |
3:1 |
| Touch target cards |
56dp height |
- |
8. Retension de Datos
| Tier |
Retencion historial |
| Free |
90 dias |
| Pro |
1 ano |
| Perfect |
6 anos (HIPAA compliant) |
9. Metricas
9.1. Analytics Events
| Evento |
Parametros |
| history_view |
date_range, filter_count |
| history_filter |
filter_type, filter_value |
| history_item_tap |
alert_id, alert_status |
| history_export |
format, date_range |
| history_load_more |
page_number |
10. Referencias
Documento generado por MobileUxUiDrone (Eight of Eight)