The Portainer host keeps failing on `npm ci` inside the build stage (both Alpine+libc6-compat and Debian slim exited 1 without ever surfacing the real error to us). For a dev showcase this isn't worth chasing — the dev machine is the source of truth for the built output anyway. - Dockerfile: drop the Node build stage. Image is just nginx:1.27.3-alpine with /dist copied in. No npm inside the container. - docker-compose.yml: drop the production hardening (read_only, tmpfs, security_opt, resource caps) and the container_name. Dev-only, don't inhibit things. - .gitignore / .dockerignore: stop ignoring dist/ — it's committed now. - README: document the `npm run build && commit && push` release flow and note what to reinstate when this graduates to real production. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
1 line
1.3 KiB
JavaScript
1 line
1.3 KiB
JavaScript
import{$ as e,C as t,L as n,o as r,r as i,tt as a,u as o,x as s}from"./runtime-core.esm-bundler-CjdnoyKJ.js";import{t as c}from"./i18n-Dy4LSDvO.js";var l=[`aria-label`,`aria-pressed`,`onClick`],u={__name:`LanguageSwitcher`,props:{floating:{type:Boolean,default:!1},tone:{type:String,default:`paper`,validator:e=>[`paper`,`cream`,`brand`].includes(e)}},setup(u){let d=u,{locale:f,setLocale:p,availableLocales:m}=c(),h={paper:{container:`border border-line bg-paper`,active:`bg-brand text-accent`,inactive:`text-muted hover:text-brand`},cream:{container:`border border-line-strong bg-paper`,active:`bg-brand text-accent`,inactive:`text-muted hover:text-brand`},brand:{container:`border border-cream-line bg-cream-wash`,active:`bg-accent text-brand`,inactive:`text-cream hover:text-accent`}},g=r(()=>h[d.tone]);return(r,c)=>(s(),o(`div`,{role:`group`,"aria-label":`Language`,class:e([`inline-flex items-center p-1 gap-0.5 rounded-pill font-sans`,g.value.container,u.floating?`fixed top-6 right-6 z-[60] shadow-sm`:``])},[(s(!0),o(i,null,t(n(m),t=>(s(),o(`button`,{key:t.code,type:`button`,"aria-label":t.name,"aria-pressed":n(f)===t.code,class:e([`px-2.5 py-1 text-[11px] font-bold tracking-eyebrow rounded-pill transition-colors duration-base`,n(f)===t.code?g.value.active:g.value.inactive]),onClick:e=>n(p)(t.code)},a(t.label),11,l))),128))],2))}};export{u as t}; |