fix: the Kanban's login fits the window, the menus are the mockup's again
All checks were successful
Build and deploy / Validate source (push) Successful in 6s
Build and deploy / Integration suite on a real stack (push) Successful in 3m31s
Build and deploy / Secret scan and release gate (push) Successful in 5s
Build and deploy / Publish images (push) Successful in 1m8s
All checks were successful
Build and deploy / Validate source (push) Successful in 6s
Build and deploy / Integration suite on a real stack (push) Successful in 3m31s
Build and deploy / Secret scan and release gate (push) Successful in 5s
Build and deploy / Publish images (push) Successful in 1m8s
- Sign-in: the page is the window's height, never scrolls; the sheet rolling under the marks is the design's (docs/design/folha-sapo-flor.svg). - The account, refresh and order menus had lost their look with the old panel's rules; they are popovers again. The account menu leaves the theme to the rail's button, right above it. - Números: panels of a row share their height; rework's lists by printer and waiting fold under a line. - Cotações: the chips of the mockup (Têxtil, UV, Folha, Avulsa, Com ressalva), no field of its own; a customer from the top search shows as a tag that takes the filter off. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -601,7 +601,8 @@ function showTab(name){
|
||||
}
|
||||
function render(){
|
||||
$('who').textContent=ME?(ME.name||ME.email):'';
|
||||
$('who-role').textContent=ME?(ROLE_NAMES[ME.role]||ME.role)+' · '+ME.email:'';
|
||||
$('who-role').textContent=ME?(ROLE_NAMES[ME.role]||ME.role)+', '+ME.email:'';
|
||||
$('who-initials').textContent=ME?initialsOf(ME.name||ME.email):'';
|
||||
$('initials').textContent=ME?initialsOf(ME.name||ME.email):'·';
|
||||
$('badge-quotes').textContent=board.pending_total?String(board.pending_total):'';
|
||||
$('badge-payments').textContent=board.payment_issues_total?String(board.payment_issues_total):'';
|
||||
@@ -2012,11 +2013,9 @@ const ICON_SUN='M6.75 10a3.25 3.25 0 1 0 6.5 0a3.25 3.25 0 1 0 -6.5 0 M10 2v1.75
|
||||
const ICON_MOON='M16.25 12.25A6.75 6.75 0 0 1 7.75 3.75a6.75 6.75 0 1 0 8.5 8.5z';
|
||||
function paintThemeToggle(){
|
||||
const light=kanbanTheme.get()==='light', label=light?'Mudar para o modo escuro':'Mudar para o modo claro';
|
||||
for(const id of ['theme-rail','theme-toggle'])$(id).querySelector('path').setAttribute('d',light?ICON_MOON:ICON_SUN);
|
||||
$('theme-rail').querySelector('path').setAttribute('d',light?ICON_MOON:ICON_SUN);
|
||||
$('theme-rail').setAttribute('aria-label',label);$('theme-rail').title=label;
|
||||
$('theme-toggle').querySelector('span').textContent=light?'Modo escuro':'Modo claro';
|
||||
}
|
||||
$('theme-toggle').onclick=()=>{$('account-menu').hidden=true;kanbanTheme.toggle();paintThemeToggle();};
|
||||
$('theme-rail').onclick=()=>{kanbanTheme.toggle();paintThemeToggle();};
|
||||
paintThemeToggle();
|
||||
$('account').onclick=e=>{e.stopPropagation();const m=$('account-menu');m.hidden=!m.hidden;
|
||||
@@ -2163,7 +2162,7 @@ async function loadStats(){
|
||||
const house=node('tr',undefined,'total');const hc=node('td');hc.append(meter(rw.house.percent,rw.house.goal_percent));
|
||||
house.append(node('td','Total da casa'),node('td',metres(rw.house.metres),'r'),hc);
|
||||
$('stats-rework').replaceChildren(...reworkRows,house);
|
||||
$('stats-rework-film').textContent='Sobre '+metres(rw.film_metres)+' impressos. Meta de '+share(rw.goal_percent)+' por causa e '+share(rw.house.goal_percent)+' no total.';
|
||||
$('stats-rework-film').textContent='Do impresso ('+metres(rw.film_metres)+'), contra a meta de '+share(rw.goal_percent);
|
||||
const pending=$('stats-rework-pending-pill');pending.hidden=!rw.pending.length;
|
||||
pending.replaceChildren(node('span',undefined,'dot'),plural(rw.pending.length,'aguardando autorização','aguardando autorização'));
|
||||
const printers=rw.by_printer.map(p=>{const tr=node('tr');tr.append(node('td',p.who),node('td',metres(p.metres),'r'));return tr;});
|
||||
@@ -2270,14 +2269,18 @@ function renderQuotes(){
|
||||
b.append(node('span',String(count??0),'n'));
|
||||
b.onclick=()=>{quoteKind=key;quotePage=1;quoteFitting=0;currentQuote=null;loadQuotes().catch(e=>say(e.message,true));};return b;}));
|
||||
// Product, layout and warning: each toggles; the two of a pair exclude each other.
|
||||
const toggles=[['product','textil','Têxtil'],['product','uv','UV'],['layout','folha','Folha montada'],
|
||||
['layout','avulsa','Artes avulsas'],['flag','ressalva','Com ressalva']];
|
||||
const toggles=[['product','textil','Têxtil'],['product','uv','UV'],['layout','folha','Folha'],
|
||||
['layout','avulsa','Avulsa'],['flag','ressalva','Com ressalva']];
|
||||
const value={product:quoteProduct,layout:quoteLayout,flag:quoteFlag};
|
||||
$('quote-chips').replaceChildren(...toggles.map(([group,key,label])=>{
|
||||
const b=node('button',label,'tg'+(value[group]===key?' on':''));b.type='button';b.setAttribute('aria-pressed',String(value[group]===key));
|
||||
b.onclick=()=>{const next=value[group]===key?'':key;
|
||||
if(group==='product')quoteProduct=next;else if(group==='layout')quoteLayout=next;else quoteFlag=next;
|
||||
quotePage=1;quoteFitting=0;loadQuotes().catch(e=>say(e.message,true));};return b;}));
|
||||
// A customer opened from the top search: the list is theirs until the tag goes.
|
||||
if(quoteQuery){const tag=node('button',quoteQuery,'ftag');tag.type='button';tag.setAttribute('aria-label','Tirar o filtro '+quoteQuery);
|
||||
const x=node('span',undefined,'x');x.append(xIcon());tag.append(x);
|
||||
tag.onclick=()=>{quoteQuery='';quotePage=1;quoteFitting=0;loadQuotes().catch(e=>say(e.message,true));};$('quote-chips').append(tag);}
|
||||
if(!currentQuote||(!quoteRows.some(q=>q.id===currentQuote.id)&¤tQuote.status==='pending_review'))currentQuote=quoteRows[0]||null;
|
||||
else currentQuote=quoteRows.find(q=>q.id===currentQuote.id)||currentQuote;
|
||||
const list=quoteRows.map(q=>{
|
||||
@@ -2753,8 +2756,6 @@ function mercadoPagoCheck(r){
|
||||
// ---- Wiring --------------------------------------------------------------
|
||||
|
||||
for(const b of document.querySelectorAll('[data-tab]'))b.onclick=()=>showTab(b.dataset.tab);
|
||||
$('quote-q').oninput=e=>{clearTimeout(quoteTimer);quoteTimer=setTimeout(()=>{
|
||||
quoteQuery=e.target.value.trim();quotePage=1;loadQuotes().catch(err=>say(err.message,true));},300);};
|
||||
|
||||
// ---- Search: orders (any stage) and unpaid quotes ---------------------------
|
||||
|
||||
@@ -2801,7 +2802,7 @@ function quoteHit(q){
|
||||
q.draft.items.map(i=>SHORT[i.mode]).join(' + ')+' · '+metres(quoteMetres(q))+' · '+ago(q.created_at),
|
||||
q.approved?'Aguardando pagamento':'A revisar',q.approved?'':'warn',()=>{
|
||||
// Opens Cotações filtered to this customer, with this quote selected.
|
||||
quoteKind=q.approved?'approved':'pending';quoteQuery=q.draft.customer.mail;$('quote-q').value=quoteQuery;
|
||||
quoteKind=q.approved?'approved':'pending';quoteQuery=q.draft.customer.mail;
|
||||
quoteProduct=quoteLayout=quoteFlag='';quotePage=1;currentQuote=q;showTab('quotes');});
|
||||
}
|
||||
$('search').oninput=e=>{
|
||||
|
||||
Reference in New Issue
Block a user