diff --git a/backend/Dockerfile b/backend/Dockerfile index bd9f1e0..b501298 100644 --- a/backend/Dockerfile +++ b/backend/Dockerfile @@ -21,7 +21,7 @@ COPY --chown=node:node backend/src ./src # stat/leer los archivos; copiar con `--chmod=644 … /dir/` deja el propio # directorio en 0644 y nginx falla con "Permission denied". Por eso se fijan # los permisos explícitamente después del COPY. -COPY frontend/checada.html frontend/panel.html frontend/becario.html /usr/share/nginx/html/ +COPY frontend/checada.html frontend/panel.html frontend/becario.html frontend/theme.js /usr/share/nginx/html/ RUN chmod 755 /usr/share/nginx/html && chmod 644 /usr/share/nginx/html/*.html COPY --chmod=644 backend/nginx-default.conf /etc/nginx/http.d/default.conf COPY --chmod=755 backend/docker-entrypoint.sh /docker-entrypoint.sh diff --git a/frontend/becario.html b/frontend/becario.html index e708c4e..6924582 100644 --- a/frontend/becario.html +++ b/frontend/becario.html @@ -7,6 +7,7 @@ +
@@ -29,12 +30,9 @@ async function apiFetch(path, options = {}) { return data; } -const COLORS = { - bg: "#EEF1F4", surface: "#FFFFFF", ink: "#1F2933", inkSoft: "#616E7C", - border: "#DDE2E7", primary: "#2A6FB0", success: "#2E7D5B", successBg: "#E7F3EC", - warn: "#B7791F", warnBg: "#FBF2E1", danger: "#C0392B", dangerBg: "#FBEBE9", chip: "#F0F2F5", -}; -const FONT = "-apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif"; +// Base visual compartida (theme.js), ligada al flavor 'becario'. +const { COLORS, FONT, SPACE, RADIUS, makeUI } = Theme; +const { Btn, Card, Input, Badge, Field, Estado } = makeUI("becario"); function fmtDT(iso) { if (!iso) return "—"; @@ -45,28 +43,6 @@ function fmtDT(iso) { const fmtHoras = (h) => `${(h ?? 0).toLocaleString("es-MX", { maximumFractionDigits: 1 })} h`; function localToIso(v) { return v ? new Date(v).toISOString() : null; } -const inputStyle = { - width: "100%", padding: "12px 14px", borderRadius: "10px", border: `1px solid ${COLORS.border}`, - fontSize: "16px", fontFamily: FONT, color: COLORS.ink, boxSizing: "border-box", outline: "none", -}; -const Input = (p) => ; -const Btn = ({ children, onClick, variant = "primary", disabled, type = "button" }) => { - const V = { primary: COLORS.primary, success: COLORS.success, ghost: "transparent", danger: COLORS.danger }[variant]; - const ghost = variant === "ghost"; - return ; -}; -const Card = ({ children, style }) => ( -