PageSourceSearch

https://wiki4fit.com/_next/static/chunks/pages/dashboard/app/nutrition-109adaec963f70cc.js

js wiki4fit.com collected 2026-09-24 14:02:54 UTC 23,545 bytes, 1 lines download raw bytes

1!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},t=(new e.Error).stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="39ef5dc7-0f43-4f78-9e39-6f5ed7a74ac1",e._sentryDebugIdIdentifier="sentry-dbid-39ef5dc7-0f43-4f78-9e39-6f5ed7a74ac1")}catch(e){}}(),(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7405],{971:(e,t,a)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/dashboard/app/nutrition",function(){return a(22046)}])},4424:(e,t,a)=>{"use strict";a.d(t,{A:()=>s});let s=(0,a(74892).A)("chevron-left",[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]])},4722:(e,t,a)=>{"use strict";a.d(t,{A:()=>s});let s=(0,a(74892).A)("image",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",ry:"2",key:"1m3agn"}],["circle",{cx:"9",cy:"9",r:"2",key:"af1f0g"}],["path",{d:"m21 15-3.086-3.086a2 2 0 0 0-2.828 0L6 21",key:"1xmnt7"}]])},8365:(e,t,a)=>{"use strict";a.d(t,{A:()=>s});let s=(0,a(74892).A)("plus",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]])},8947:(e,t,a)=>{"use strict";a.d(t,{A:()=>d});var s=a(23798),n=a(4424),l=a(76553),i=a(21462),r=a(66790);function o(e){let{direction:t,label:a,hidden:i,top:o,onClick:d}=e;return i?null:(0,s.jsx)("button",{type:"button","aria-label":a,"data-testid":"shelf-arrow-".concat(t),onClick:d,className:(0,r.cn)("absolute z-10 hidden h-9 w-9 -translate-y-1/2 items-center justify-center rounded-full bg-black/60 text-white opacity-0 shadow-lg transition-opacity duration-150 hover:bg-black/80 focus-visible:opacity-100 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-brand md:inline-flex","group-hover/carousel:opacity-100",o,"left"===t?"left-0":"right-0"),children:"left"===t?(0,s.jsx)(n.A,{size:20,strokeWidth:2.5}):(0,s.jsx)(l.A,{size:20,strokeWidth:2.5})})}function d(e){let{children:t,arrowTop:a="top-[112px] md:top-[150px]",onScroll:n,scrollerTestId:l,labels:d={previous:"Ver anteriores",next:"Ver mais"},className:c}=e,u=(0,i.useRef)(null),[x,p]=(0,i.useState)({atStart:!0,atEnd:!0}),h=(0,i.useCallback)(()=>{let e=u.current;if(!e)return;let t=e.scrollWidth-e.clientWidth;p({atStart:e.scrollLeft<=1,atEnd:e.scrollLeft>=t-1})},[]);function f(e){let t=u.current;t&&t.scrollBy({left:e*t.clientWidth*.9,behavior:"smooth"})}return(0,i.useEffect)(()=>(h(),window.addEventListener("resize",h),()=>window.removeEventListener("resize",h)),[h,t]),(0,s.jsxs)("div",{className:(0,r.cn)("group/carousel relative",c),children:[(0,s.jsx)("div",{ref:u,onScroll:()=>{h(),null==n||n()},"data-testid":l,className:"-mx-5 overflow-x-auto overscroll-x-contain px-5 [scrollbar-width:none] [-ms-overflow-style:none] [&::-webkit-scrollbar]:hidden",children:t}),(0,s.jsx)(o,{direction:"left",label:d.previous,hidden:x.atStart,top:a,onClick:()=>f(-1)}),(0,s.jsx)(o,{direction:"right",label:d.next,hidden:x.atEnd,top:a,onClick:()=>f(1)})]})}},12477:(e,t,a)=>{"use strict";a.d(t,{A:()=>l});var s=a(23798),n=a(66790);function l(e){let{title:t,subtitle:a,actions:l,breadcrumb:i,className:r}=e;return(0,s.jsxs)("header",{className:(0,n.cn)("font-sans",r),children:[i&&(0,s.jsx)("div",{className:"mb-2.5",children:i}),(0,s.jsxs)("div",{className:"flex flex-col items-start gap-3 sm:flex-row sm:justify-between sm:gap-4",children:[(0,s.jsxs)("div",{className:"flex flex-col gap-[3px]",children:[(0,s.jsx)("h1",{className:"text-[24px] font-extrabold leading-[1.2] tracking-tight text-fg",children:t}),a&&(0,s.jsx)("p",{className:"text-[14px] text-fg-muted",children:a})]}),l&&(0,s.jsx)("div",{className:"flex shrink-0 flex-wrap items-center gap-1.5 sm:pt-1",children:l})]})]})}},22046:(e,t,a)=>{"use strict";a.r(t),a.d(t,{default:()=>Z});var s=a(23798),n=a(14114),l=a(14377),i=a(66580),r=a(68015),o=a(8365),d=a(65022),c=a(89122),u=a(21462),x=a(13644),p=a(72833);let h="Sem objetivo";var f=a(8947),m=a(80198),g=a(83076),b=a(13121),v=a(78155),j=a(43082);function N(){let{rootMargin:e="0px",once:t=!1}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},[a,s]=(0,u.useState)(null),[n,l]=(0,u.useState)(!1);return(0,u.useEffect)(()=>
1{if(!a||t&&n)return;let s=new IntersectionObserver(e=>{var a,n;let i=null!=(n=null==(a=e[0])?void 0:a.isIntersecting)&&n;l(i),i&&t&&s.disconnect()},{rootMargin:e});return s.observe(a),()=>s.disconnect()},[a,e,t,n]),{ref:s,inView:n}}var y=a(99303),w=a(70451);function k(e){let{diet:t,canReorder:a,onEdit:n,onDelete:i}=e,{setNodeRef:r,transform:o,transition:d,listeners:c,attributes:u,isDragging:x}=(0,l.gl)({id:"diet:".concat(t.id),disabled:!a});return(0,s.jsx)(y.A,{ref:r,diet:t,editable:!0,onEdit:n,onDelete:i,ghosting:x,dragListeners:a?c:null,style:{transform:w.Ks.Transform.toString(o),transition:d},...u})}function A(e){var t;let{scope:a,goalKey:i,studentId:r,assignment:o,total:d,search:c,editable:x,reorderable:p=!0,onEdit:h,onDelete:w}=e,A=(0,g.d)(),E=(0,j.J)(),{ref:S,inView:M}=N({rootMargin:"400px",once:!0}),{ref:C,inView:z}=N({rootMargin:"200px"}),P=(0,v.r)({scope:a,goalKey:i,studentId:r,assignment:o,search:c,enabled:M}),{fetchNextPage:D,hasNextPage:I,isFetchingNextPage:_}=P;(0,u.useEffect)(()=>{z&&I&&!_&&D()},[z,I,_,D]);let L=(0,u.useMemo)(()=>{var e,t;return null!=(t=null==(e=P.data)?void 0:e.pages.flatMap(e=>e.data))?t:[]},[P.data]),[T,W]=(0,u.useState)([]);(0,u.useEffect)(()=>W(L),[L]);let[F,q]=(0,u.useState)(null),R=(0,b.w6)(),O=x&&p&&!c&&!I&&T.length>1,V=F&&null!=(t=T.find(e=>"diet:".concat(e.id)===F))?t:null,K=!M||P.isLoading&&0===T.length,B=(0,s.jsx)("div",{ref:S,children:(0,s.jsx)(f.A,{scrollerTestId:"shelf-scroller",labels:{previous:"Ver planos anteriores",next:"Ver mais planos"},children:K?(0,s.jsx)("div",{className:"flex flex-nowrap gap-3 pb-1",children:Array.from({length:Math.max(1,Math.min(d,6))}).map((e,t)=>(0,s.jsx)(m.A,{width:150,height:225,rounded:"md",className:"shrink-0"},t))}):(0,s.jsx)(l.gB,{items:T.map(e=>"diet:".concat(e.id)),strategy:l.m$,children:(0,s.jsxs)("div",{className:"flex snap-x flex-nowrap gap-3 pb-1 md:snap-none",children:[T.map(e=>x?(0,s.jsx)(k,{diet:e,canReorder:O,onEdit:()=>null==h?void 0:h(e),onDelete:()=>null==w?void 0:w(e)},e.id):(0,s.jsx)(y.A,{diet:e,editable:!1,onEdit:h?()=>h(e):void 0},e.id)),I&&(0,s.jsx)("div",{ref:C,"data-testid":"shelf-load-more",className:"flex w-[150px] shrink-0 items-center justify-center md:w-[200px]",children:(0,s.jsx)(m.A,{width:150,height:225,rounded:"md"})})]})})})});return x?(0,s.jsxs)(n.Mp,{sensors:E,collisionDetection:n.fp,onDragStart:function(e){q(String(e.active.id))},onDragEnd:function(e){q(null);let{active:t,over:a}=e;if(!a||t.id===a.id)return;let s=Number(String(t.id).slice(5)),n=Number(String(a.id).slice(5)),i=T.findIndex(e=>e.id===s),r=T.findIndex(e=>e.id===n);if(i<0||r<0||i===r)return;let o=(0,l.be)(T,i,r);W(o),R.mutate({items:o.map((e,t)=>({id:e.id,position:t}))},{onError:()=>{W(T),A.error("N\xe3o foi poss\xedvel reordenar os planos.")}})},onDragCancel:()=>q(null),children:[B,(0,s.jsx)(n.Hd,{dropAnimation:{duration:220,easing:"cubic-bezier(0.18, 0.67, 0.6, 1.22)"},children:V?(0,s.jsx)(y.A,{diet:V,editable:!0,isOverlay:!0}):null})]}):B}function E(e){let{goalKey:t,label:a,total:n,search:l,onEdit:i}=e;return(0,s.jsxs)("div",{className:"flex flex-col gap-3",children:[(0,s.jsx)("h3",{className:"m-0 text-sm font-semibold uppercase tracking-wider text-fg-muted",children:a||h}),(0,s.jsx)(A,{scope:"shared",goalKey:t,total:n,search:l,editable:!1,onEdit:i})]})}var S=a(53554),M=a(66790),C=a(31755);function z(e){let{shelfId:t,goalKey:a,label:n,total:i,search:r,canReorderShelves:o,onEdit:d,onDelete:c}=e,{setNodeRef:u,transform:x,transition:p,listeners:f,attributes:m,isDragging:g}=(0,l.gl)({id:t,disabled:!o}),b=n||h;return(0,s.jsxs)("div",{ref:u,style:{transform:w.Ks.Transform.toString(x),transition:p},className:(0,M.cn)("flex flex-col gap-3",g&&"opacity-30"),"data-testid":"goal-shelf","data-goal-key":a,...m,children:[(0,s.jsxs)("div",{className:"flex items-center gap-2",children:[o&&(0,s.jsx)("button",{type:"button","aria-label":"Arrastar categoria ".concat(b),"data-testid":"goal-shelf-grip",className:(0,M.cn)("relative inline-flex h-7 w-7 cursor-grab items-center justify-center rounded-md bg-transparent text-fg-subtle transition-colors hover:bg-surface-muted hover:text-fg focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-brand active:cursor-grabbing",C.RB,C.HR),...f,children:(0,s.jsx)(S.A,{size:14,strokeWidth:2})}),(0,s.jsx)("h3",{className:"m-0 text-sm font-semibold uppercase tracking-wider text-fg-muted",children:b})]}),(0,s.jsx)(A,{scope:"own",goalKey:a,total:i,search:r,editable:!0,onEdit:d,onDelete:c})]})}var P=a(2940),D=a.n(P),I=a(74251);function _(e){let{studentId:t,name:a,total:n,onEdit:l,onDelete:i}=e;return(0,s.jsxs)("div",{className:"flex flex-col gap-3","data-testid":"student-shelf","data-student-id":t,children:[(0,s.jsxs)("div",{className:"flex items-baseline gap-2",children:[(0,s.jsx)(D(),{href:"/dashboard/app/students/".concat(t,"?from=").concat((0,I.Kq)("nutrition",null,"students")),className:"m-0 text-sm font-semibold uppercase tracking-wider text-fg-muted no-underline hover:text-fg",children:a}),(0,s.jsxs)("span",{className:"text-xs text-fg-subtle",children:[n," ",1===n?"plano":"planos"]})]}),(0,s.jsx)(A,{scope:"own",studentId:t,total:n,search:"",editable:!0,reorderable:!1,onEdit:l,onDelete:i})]})}var L=a(94950),T=a(82163),W=a(13248),F=a(36765),q=a(57537),R=a(12477),O=a(35945),V=a(64099),K=a(6524),B=a(50092),G=a(92310),H=a(84301);let J=e=>{let t=(0,n.TT)(e);return t.length>0?t:(0,n.fp)(e)},U=["catalog","students"];function Z(){let[e,t]=(0,u.useState)(!1);return((0,u.useEffect)(()=>t(!0),[]),e)?(0,s.jsx)(x.A,{title:"Planos alimentares",children:(0,s.jsx)(X,{})}):null}function X(){var e,t,a,x,f,v,N,y,w,k,S,M,C;let P=(0,g.d)(),D=(0,H.al)(),[Z,X]=(0,c.ZA)("tab",c.tU),Y=U.includes(Z)?Z:"catalog",[ee,et]=(0,c.ZA)("q",c.tU.withDefault("")),ea=(0,G.d)(null!=ee?ee:"",300),es=(0,K.G)({scope:"shared",search:ea}),en=(0,K.G)({scope:"own",search:ea}),el=(0,B.M)({search:"students"===Y?ea:""}),ei=(0,b.PB)(),er=(0,b.aU)(),[eo,ed]=(0,u.useState)(!1),[ec,eu]=(0,u.useState)(null),[ex,ep]=(0,u.useState)(!1),[eh,ef]=(0,u.useState)(null),em=(null!=(w=null==(t=en.data)||null==(e=t.pages[0])?void 0:e.totalDiets)?w:0)+(null!=(k=null==(x=es.data)||null==(a=x.pages[0])?void 0:a.totalDiets)?k:0),eg=(0,u.useMemo)(()=>{var e,t;return null!=(t=null==(e=es.data)?void 0:e.pages.flatMap(e=>e.data))?t:[]},[es.data]),eb=(0,u.useMemo)(()=>{var e,t;return null!=(t=null==(e=en.data)?void 0:e.pages.flatMap(e=>e.data))?t:[]},[en.data]),[ev,ej]=(0,u.useState)([]);(0,u.useEffect)(()=>ej(eb),[eb]);let[eN,ey]=(0,u.useState)(null),ew=(0,j.J)(),ek=(0,u.useMemo)(()=>{var e,t;return null!=(t=null==(e=el.data)?void 0:e.pages.flatMap(e=>e.data))?t:[]},[el.data]),eA=null!=(S=null==(v=el.data)||null==(f=v.pages[0])?void 0:f.total)?S:0,eE=null!=(M=null==(y=el.data)||null==(N=y.pages[0])?void 0:N.unassignedTotal)?M:0,eS="catalog"===Y,eM=eS?en.isLoading||es.isLoading:el.isLoading,eC=eS?en.isError||es.isError:el.isError,ez=eS?eg.length>0||ev.length>0:ek.length>0||eE>0;function eP(){eu(null),ep(!1),ed(!0)}function eD(e){eu(e.id),ep(e.isShared),ed(!0)}let eI=eN&&null!=(C=ev.find(e=>Q(e)===eN))?C:null,e_=!ea&&ev.length>1;return(0,s.jsxs)("div",{className:"flex flex-col gap-5 p-5 font-sans",children:[(0,s.jsx)(R.A,{breadcrumb:(0,s.jsx)(q.A,{items:[I.K3,{label:"Planos alimentares"}]}),title:"Planos alimentares",subtitle:"".concat(em," ").concat(1===em?"plano cadastrado":"planos cadastrados"),actions:(0,s.jsxs)(s.Fragment,{children:[(0,s.jsxs)("a",{href:"https://nutrifit.wiki4fit.com.br/",target:"_blank",rel:"noopener noreferrer",className:(0,T.V)({variant:"outline",size:"md",pill:!0}),children:[(0,s.jsx)(i.A,{size:14}),(0,s.jsx)("span",{className:"hidden sm:inline",children:"NutriFitPro"}
1),(0,s.jsx)("span",{className:"sm:hidden","aria-hidden":!0,children:"NutriFit"}),(0,s.jsx)(r.A,{size:12,className:"opacity-60"})]}),D?(0,s.jsx)(T.A,{variant:"primary",size:"md",pill:!0,iconOnly:!0,"aria-label":"Criar plano",onClick:eP,children:(0,s.jsx)(o.A,{size:14})}):(0,s.jsx)(T.A,{variant:"primary",size:"md",pill:!0,iconLeft:(0,s.jsx)(o.A,{size:14}),onClick:eP,children:"Criar plano"})]})}),(0,s.jsx)(L.A,{variant:"info",message:(0,s.jsx)(s.Fragment,{children:"Cadastre planos alimentares e atribua diretamente a alunos ou turmas. O aluno v\xea o plano vinculado dentro do app."})}),(0,s.jsx)(V.A,{items:[{id:"catalog",label:"Cat\xe1logo",count:em},{id:"students",label:"Por aluno",count:eA}],activeId:Y,onChange:function(e){X("catalog"===e?null:e),et(null)}}),(0,s.jsx)("div",{className:"flex flex-wrap items-center gap-3",children:(0,s.jsx)("div",{className:"min-w-[220px] flex-1",children:(0,s.jsx)(O.A,{value:null!=ee?ee:"",onChange:e=>et(e||null),placeholder:eS?"Buscar por nome do plano ou objetivo...":"Buscar pelo nome do aluno..."})})}),eM&&(0,s.jsxs)("div",{className:"flex flex-col gap-3",children:[(0,s.jsx)(m.A,{width:"40%",height:20}),(0,s.jsx)("div",{className:"-mx-5 overflow-hidden px-5",children:(0,s.jsx)("div",{className:"flex flex-nowrap gap-3",children:Array.from({length:5}).map((e,t)=>(0,s.jsx)(m.A,{width:150,height:225,rounded:"md"},t))})})]}),eC&&(0,s.jsx)(F.A,{icon:(0,s.jsx)(d.A,{size:32,strokeWidth:1.5}),title:"Erro ao carregar planos",description:"Tente novamente em instantes."}),!eM&&!eC&&!ez&&eS&&(0,s.jsx)(F.A,{icon:(0,s.jsx)(d.A,{size:32,strokeWidth:1.5}),title:ea?"Nenhum plano encontrado":"Sem planos cadastrados",description:ea?"Tente outra busca ou crie um novo plano.":"Crie um plano para atribuir aos seus alunos.",action:ea?void 0:(0,s.jsx)(T.A,{variant:"primary",pill:!0,iconLeft:(0,s.jsx)(o.A,{size:14}),onClick:eP,children:"Criar primeiro plano"})}
1),!eM&&!eC&&!ez&&!eS&&(0,s.jsx)(F.A,{icon:(0,s.jsx)(d.A,{size:32,strokeWidth:1.5}),title:ea?"Nenhum aluno encontrado":"Nenhum aluno com plano atribu\xeddo",description:ea?"Tente outro nome. S\xf3 aparecem aqui alunos que j\xe1 t\xeam um plano.":"Atribua um plano a um aluno ou a uma turma para v\xea-lo aqui."}),!eM&&!eS&&(0,s.jsxs)("section",{className:"flex flex-col gap-4","data-testid":"nutrition-students-section",children:[ek.length>0&&(0,s.jsxs)(s.Fragment,{children:[(0,s.jsxs)("div",{className:"flex flex-col gap-0.5",children:[(0,s.jsx)("h2",{className:"m-0 text-lg font-bold tracking-tight text-fg",children:"Planos por aluno"}),(0,s.jsx)("p",{className:"m-0 text-[14px] text-fg-muted",children:"Cada prateleira mostra os planos que o aluno enxerga no app, atribu\xeddos a ele ou \xe0 turma dele."})]}),ek.map(e=>(0,s.jsx)(_,{studentId:e.id,name:e.name,total:e.total,onEdit:eD,onDelete:e=>ef(e)},e.id)),(0,s.jsx)($,{testId:"student-shelves-sentinel",hasNextPage:!!el.hasNextPage,isFetching:el.isFetchingNextPage,onLoadMore:el.fetchNextPage})]}),eE>0&&!ea&&(0,s.jsxs)("div",{className:"flex flex-col gap-3","data-testid":"nutrition-unassigned-shelf",children:[(0,s.jsxs)("div",{className:"flex items-baseline gap-2",children:[(0,s.jsx)("h3",{className:"m-0 text-sm font-semibold uppercase tracking-wider text-fg-muted",children:"Sem aluno atribu\xeddo"}),(0,s.jsxs)("span",{className:"text-xs text-fg-subtle",children:["vis\xedvel para todos os alunos \xb7 ",eE]})]}),(0,s.jsx)(A,{scope:"own",assignment:"unassigned",total:eE,search:"",editable:!0,reorderable:!1,onEdit:eD,onDelete:e=>ef(e)})]})]}),!eM&&eS&&eg.length>0&&(0,s.jsxs)("section",{className:"flex flex-col gap-4",children:[(0,s.jsxs)("div",{className:"flex flex-col gap-0.5",children:[(0,s.jsx)("h2",{className:"m-0 text-lg font-bold tracking-tight text-fg",children:"Modelos de planos alimentares"}),(0,s.jsx)("p",{className:"m-0 text-[14px] text-fg-muted",children:"Planos que j\xe1 v\xeam prontos com a plataforma. Editar um deles cria uma c\xf3pia sua, que voc\xea pode personalizar."})]}),eg.map(e=>(0,s.jsx)(E,{goalKey:e.key,label:e.label,total:e.total,search:ea,onEdit:eD},e.key)),(0,s.jsx)($,{testId:"shared-shelves-sentinel",hasNextPage:!!es.hasNextPage,isFetching:es.isFetchingNextPage,onLoadMore:es.fetchNextPage})]}),!eM&&eS&&ev.length>0&&(0,s.jsxs)("section",{className:"flex flex-col gap-4","data-testid":"nutrition-own-section",children:[(0,s.jsxs)("div",{className:"flex flex-col gap-0.5",children:[(0,s.jsx)("h2",{className:"m-0 text-lg font-bold tracking-tight text-fg",children:"Seus planos alimentares"}),(0,s.jsxs)("p",{className:"m-0 text-[14px] text-fg-muted",children:["Arraste pelo ",(0,s.jsx)("span",{className:"font-bold",children:"grip"})," para reordenar planos dentro de uma categoria ou as categorias entre si."]})]}),(0,s.jsxs)(n.Mp,{sensors:ew,collisionDetection:J,onDragStart:function(e){ey(String(e.active.id))},onDragEnd:function(e){ey(null);let{active:t,over:a}=e;if(!a||t.id===a.id)return;let s=ev.findIndex(e=>Q(e)===String(t.id)),n=ev.findIndex(e=>Q(e)===String(a.id));s<0||n<0||s===n||(ej((0,l.be)(ev,s,n)),er.mutate({key:ev[s].key,toIndex:n},{onError:()=>{ej(ev),P.error("N\xe3o foi poss\xedvel reordenar as categorias.")}}))},onDragCancel:()=>ey(null),autoScroll:{threshold:{x:0,y:.25},acceleration:12,interval:5},children:[(0,s.jsx)(l.gB,{items:ev.map(Q),strategy:l._G,children:(0,s.jsx)("div",{className:"flex flex-col gap-4",children:ev.map(e=>(0,s.jsx)(z,{shelfId:Q(e),goalKey:e.key,label:e.label,total:e.total,search:ea,canReorderShelves:e_,onEdit:eD,onDelete:e=>ef(e)},e.key))})}),(0,s.jsx)(n.Hd,{dropAnimation:{duration:220,easing:"cubic-bezier(0.18, 0.67, 0.6, 1.22)"},children:eI?(0,s.jsx)("div",{className:"rounded-md border border-solid border-line-subtle bg-surface px-3 py-2 shadow-xl ring-2 ring-brand",children:(0,s.jsx)("span",{className:"text-sm font-semibold uppercase tracking-wider text-fg",children:eI.label||h})}):null})]}),(0,s.jsx)($,{testId:"own-shelves-sentinel",hasNextPage:!!en.hasNextPage,isFetching:en.isFetchingNextPage,onLoadMore:en.fetchNextPage})]}),(0,s.jsx)(p.A,{open:eo,dietId:ec,sharedSource:ex,onClose:function(){ed(!1),eu(null),ep(!1)}}),(0,s.jsx)(W.A,{open:null!==eh,onClose:()=>ef(null),onConfirm:function(){eh&&ei.mutate({id:eh.id},{onSuccess:()=>{P.success('"'.concat(eh.name,'" exclu\xeddo.')),ef(null)},onError:()=>{P.error("N\xe3o foi poss\xedvel excluir o plano."),ef(null)}})},title:eh?'Excluir "'.concat(eh.name,'"?'):"",description:"O plano e suas atribui\xe7\xf5es ser\xe3o removidos. Os alunos n\xe3o ver\xe3o mais esse plano no app.",confirmLabel:"Excluir",cancelLabel:"Cancelar",tone:"danger",loading:ei.isLoading})]})}function Q(e){return"cat:".concat(e.key)}function $(e){let{hasNextPage:t,isFetching:a,onLoadMore:n,testId:l}=e,{ref:i,inView:r}=N({rootMargin:"400px"}),o=(0,u.useRef)(n);return(o.current=n,(0,u.useEffect)(()=>{r&&t&&!a&&o.current()},[r,t,a]),t)?(0,s.jsxs)("div",{ref:i,"data-testid":l,className:"flex flex-col gap-3",children:[(0,s.jsx)(m.A,{width:"30%",height:16}),(0,s.jsx)("div",{className:"-mx-5 overflow-hidden px-5",children:(0,s.jsx)("div",{className:"flex flex-nowrap gap-3",children:Array.from({length:5}).map((e,t)=>(0,s.jsx)(m.A,{width:150,height:225,rounded:"md"},t))})})]}):null}},35945:(e,t,a)=>{"use strict";a.d(t,{A:()=>
1o});var s=a(23798),n=a(15481),l=a(67357),i=a(21462),r=a(66790);let o=(0,i.forwardRef)(function(e,t){let{value:a,onChange:i,onClear:o,placeholder:d,containerClassName:c,className:u,iconLeft:x,disabled:p,...h}=e;return(0,s.jsxs)("div",{className:(0,r.cn)("flex h-9 min-w-[220px] items-center gap-2 rounded-sm border border-solid border-line bg-surface px-3.5 shadow-xs transition-[border-color,box-shadow] duration-150 ease-out font-sans","focus-within:border-brand focus-within:shadow-[0_0_0_3px_rgba(255,140,80,0.15)]",p&&"cursor-not-allowed bg-surface-subtle",c),children:[(0,s.jsx)("span",{className:"inline-flex shrink-0 items-center text-fg-subtle",children:null!=x?x:(0,s.jsx)(n.A,{size:14,strokeWidth:1.75})}),(0,s.jsx)("input",{ref:t,type:"text",value:a,onChange:e=>i(e.target.value),placeholder:d,disabled:p,className:(0,r.cn)("min-w-0 flex-1 appearance-none border-0 bg-transparent font-sans text-[14px] leading-snug text-fg outline-none placeholder:text-fg-subtle disabled:cursor-not-allowed disabled:bg-transparent",u),...h}),a&&!p&&(0,s.jsx)("button",{type:"button",onClick:function(){i(""),null==o||o()},"aria-label":"Limpar busca",className:"inline-flex shrink-0 cursor-pointer appearance-none items-center border-0 bg-transparent p-0 text-fg-subtle transition-colors hover:text-fg",children:(0,s.jsx)(l.A,{size:13,strokeWidth:1.75})})]})})},43082:(e,t,a)=>{"use strict";a.d(t,{J:()=>l});var s=a(14114),n=a(14377);function l(){let{distance:e=6}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return(0,s.FR)((0,s.MS)(s.cA,{activationConstraint:{distance:e}}),(0,s.MS)(s.IG,{activationConstraint:{delay:250,tolerance:5}}),(0,s.MS)(s.uN,{coordinateGetter:n.JR}))}},61215:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});var s=a(23798),n=a(70132),l=a(82163),i=a(60637);function r(e){let{items:t,size:a="md",pill:r=!1,align:o="right",ariaLabel:d="Mais a\xe7\xf5es",variant:c="outline"}=e;return(0,s.jsx)(i.A,{items:t,align:o,minWidthClassName:"min-w-[220px]",renderTrigger:e=>{let{ref:t,onClick:i,open:o,...u}=e;return(0,s.jsx)(l.A,{ref:t,variant:c,size:a,pill:r,iconOnly:!0,"aria-label":d,"aria-haspopup":u["aria-haspopup"],"aria-expanded":o,onClick:i,children:(0,s.jsx)(n.A,{size:"sm"===a?12:14})})}})}},65022:(e,t,a)=>{"use strict";a.d(t,{A:()=>s});let s=(0,a(74892).A)("salad",[["path",{d:"M7 21h10",key:"1b0cd5"}],["path",{d:"M12 21a9 9 0 0 0 9-9H3a9 9 0 0 0 9 9Z",key:"4rw317"}],["path",{d:"M11.38 12a2.4 2.4 0 0 1-.4-4.77 2.4 2.4 0 0 1 3.2-2.77 2.4 2.4 0 0 1 3.47-.63 2.4 2.4 0 0 1 3.37 3.37 2.4 2.4 0 0 1-1.1 3.7 2.51 2.51 0 0 1 .03 1.1",key:"10xrj0"}],["path",{d:"m13 12 4-4",key:"1hckqy"}],["path",{d:"M10.9 7.25A3.99 3.99 0 0 0 4 10c0 .73.2 1.41.54 2",key:"1p4srx"}]])},66580:(e,t,a)=>{"use strict";a.d(t,{A:()=>s});let s=(0,a(74892).A)("sparkles",[["path",{d:"M11.017 2.814a1 1 0 0 1 1.966 0l1.051 5.558a2 2 0 0 0 1.594 1.594l5.558 1.051a1 1 0 0 1 0 1.966l-5.558 1.051a2 2 0 0 0-1.594 1.594l-1.051 5.558a1 1 0 0 1-1.966 0l-1.051-5.558a2 2 0 0 0-1.594-1.594l-5.558-1.051a1 1 0 0 1 0-1.966l5.558-1.051a2 2 0 0 0 1.594-1.594z",key:"1s2grr"}],["path",{d:"M20 2v4",key:"1rf3ol"}
1],["path",{d:"M22 4h-4",key:"gwowj6"}],["circle",{cx:"4",cy:"20",r:"2",key:"6kqj1y"}]])},77482:(e,t,a)=>{"use strict";a.d(t,{A:()=>s});let s=(0,a(74892).A)("trash-2",[["path",{d:"M10 11v6",key:"nco0om"}],["path",{d:"M14 11v6",key:"outv1u"}],["path",{d:"M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6",key:"miytrc"}],["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2",key:"e791ji"}]])},80198:(e,t,a)=>{"use strict";a.d(t,{A:()=>l});var s=a(23798),n=a(66790);function l(e){let{width:t,height:a,rounded:l="sm",className:i}=e;return(0,s.jsx)("span",{"aria-hidden":!0,style:{width:"number"==typeof t?"".concat(t,"px"):t,height:"number"==typeof a?"".concat(a,"px"):a,borderRadius:"number"==typeof l?"".concat(l,"px"):"full"===l?"9999px":void 0},className:(0,n.cn)("block animate-pulse bg-neutral-200","sm"===l&&"rounded-xs","md"===l&&"rounded-md",i)})}},92570:(e,t,a)=>{"use strict";a.d(t,{R8:()=>r,UW:()=>l,eq:()=>i});var s=a(32759),n=a(85567);let l="students:list";function i(e,t){return(0,s.useQuery)([l,e],async()=>{let{data:t}=await n.Gn.get("/coach/students",{params:e});return t},{keepPreviousData:!0,staleTime:3e4,...t})}async function r(e){let t=[],a=1,s=1;do{let{data:l}=await n.Gn.get("/coach/students",{params:{...e,page:a,limit:100}});t.push(...l.data.map(e=>e.id)),s=l.totalPages,a+=1}while(a<=s);return t}}},e=>{e.O(0,[9122,1770,7537,6439,636,6593,8792],()=>e(e.s=971)),_N_E=e.O()}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.