d3ro-voice/apps/web/.next/static/chunks/app/teams/[id]/page-a720445f249342f2.js
yunchan8804 61a96b3e9b feat(V2-6/V2-7/V2-8): Mobile MVP + Teams + Billing 스캐폴딩
V2-6 — Mobile (Expo) MVP
- apps/mobile/ 신규, npm workspace에서 제외 (Expo deps 부담 회피)
- Expo SDK 51 + Expo Router + AsyncStorage Supabase 클라이언트
- 화면: index/login/(tabs)/{meetings,record,profile}
- expo-av로 녹음 → Edge Function stt-proxy 호출
- expo-web-browser + expo-linking으로 OAuth 콜백 처리
- README에 setup/EAS build 가이드
- 루트 package.json workspaces를 명시 나열로 변경 (apps/mobile 제외)

V2-7 — 팀 기능 (Web)
- apps/web/src/app/teams/page.tsx — 가입한 팀 카드 그리드
- apps/web/src/app/teams/[id]/page.tsx — 멤버 + 공유 회의
- components/teams/create-team-form.tsx — 팀 생성 + owner 자동 team_members
- components/teams/invite-member-form.tsx — user_id 직접 초대 (V2-7b에서 invite flow)
- Sidebar에 Teams/Billing 메뉴 + 아이콘
- ko.json에 nav.teams/nav.billing 키 추가
- V2-2 teams/team_members RLS 활용

V2-8 — 결제 스캐폴딩
- apps/web/src/app/billing/page.tsx — Free/Pro/Team 가격표 + 현재 구독
- components/billing/checkout-button.tsx — Edge Function 호출 후 redirect
- server/supabase/functions/stripe-checkout/index.ts:
  - JWT 인증 -> 기존 customer 조회/생성 -> Checkout Session 생성
  - subscriptions 테이블에 customer_id upsert
- server/supabase/functions/stripe-webhook/index.ts:
  - checkout.session.completed -> subscriptions tier=pro/team active
  - customer.subscription.updated/created -> status/period 업데이트
  - customer.subscription.deleted -> tier=free, status=canceled
  - signature 검증은 placeholder (V2-8b에서 정식)
- server/supabase/config.toml에 두 함수 등록 (webhook verify_jwt=false)

검증:
- desktop typecheck OK (회귀 없음)
- web typecheck OK
- web next build OK (11 라우트)
- mobile은 별도 install 필요 (workspace 제외)

memory/project_status.md 갱신 — V2 마스터 플랜 전 페이즈 로컬 완료
2026-04-09 16:39:54 +09:00

1 line
No EOL
5.4 KiB
JavaScript

(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[339],{324:(e,s,r)=>{"use strict";r.d(s,{Sidebar:()=>f});var i=r(4568),n=r(7541),o=r(1284),l=r(6987),t=r(6763),d=r(6262),a=r(5431),h=r(3775),c=r(1084),b=r(2278),m=r(2775),u=r(812),v=r(1166),x=r(2010),P=r(1441),p=r(3791),j=r(7740),g=r(1037);function f(){var e,s,r,f,y,A;let k=(0,n.useRouter)(),M=(0,n.usePathname)(),{t:C}=(0,j.s9)(),_=[{key:"dashboard",path:"/dashboard",label:null!=(e=C("nav.dashboard"))?e:"Dashboard",icon:(0,i.jsx)(c.A,{})},{key:"meetings",path:"/meetings",label:null!=(s=C("nav.meetings"))?s:"Meetings",icon:(0,i.jsx)(b.A,{})},{key:"record",path:"/record",label:null!=(r=C("nav.record"))?r:"Record",icon:(0,i.jsx)(m.A,{})},{key:"teams",path:"/teams",label:null!=(f=C("nav.teams"))?f:"Teams",icon:(0,i.jsx)(u.A,{})},{key:"billing",path:"/billing",label:null!=(y=C("nav.billing"))?y:"Billing",icon:(0,i.jsx)(v.A,{})}];async function R(){let e=(0,g.c)();await e.auth.signOut(),k.replace("/login")}return(0,i.jsxs)(o.default,{sx:{width:240,minHeight:"100vh",bgcolor:p.sM.bg.sidebar,borderRight:"1px solid ".concat(p.sM.border.default),display:"flex",flexDirection:"column"},children:[(0,i.jsx)(o.default,{sx:{p:3,borderBottom:"1px solid ".concat(p.sM.border.default)},children:(0,i.jsx)(P.Rk,{variant:"heading",children:"D3RO VOICE"})}),(0,i.jsx)(l.A,{sx:{flex:1,py:2},children:_.map(e=>{let s=M===e.path||M.startsWith("".concat(e.path,"/"));return(0,i.jsx)(t.Ay,{disablePadding:!0,children:(0,i.jsxs)(d.A,{selected:s,onClick:()=>k.push(e.path),sx:{"&.Mui-selected":{bgcolor:p.sM.bg.inset,borderLeft:"3px solid ".concat(p.sM.accent.amber)}},children:[(0,i.jsx)(a.A,{sx:{color:s?p.sM.accent.amber:p.sM.text.label},children:e.icon}),(0,i.jsx)(h.A,{primary:e.label,primaryTypographyProps:{color:s?p.sM.text.primary:p.sM.text.secondary}})]})},e.key)})}),(0,i.jsx)(l.A,{sx:{borderTop:"1px solid ".concat(p.sM.border.default)},children:(0,i.jsx)(t.Ay,{disablePadding:!0,children:(0,i.jsxs)(d.A,{onClick:()=>void R(),children:[(0,i.jsx)(a.A,{sx:{color:p.sM.text.label},children:(0,i.jsx)(x.A,{})}),(0,i.jsx)(h.A,{primary:null!=(A=C("nav.logout"))?A:"Logout",primaryTypographyProps:{color:p.sM.text.secondary}})]})})})]})}},441:(e,s,r)=>{Promise.resolve().then(r.bind(r,324)),Promise.resolve().then(r.bind(r,7083)),Promise.resolve().then(r.bind(r,1284)),Promise.resolve().then(r.bind(r,5754)),Promise.resolve().then(r.bind(r,7301)),Promise.resolve().then(r.bind(r,8613)),Promise.resolve().then(r.bind(r,9746)),Promise.resolve().then(r.bind(r,1379)),Promise.resolve().then(r.bind(r,1774)),Promise.resolve().then(r.bind(r,8448)),Promise.resolve().then(r.bind(r,7273)),Promise.resolve().then(r.bind(r,5608)),Promise.resolve().then(r.bind(r,1238)),Promise.resolve().then(r.bind(r,4590)),Promise.resolve().then(r.bind(r,3174)),Promise.resolve().then(r.bind(r,2421)),Promise.resolve().then(r.bind(r,8758)),Promise.resolve().then(r.bind(r,9969)),Promise.resolve().then(r.bind(r,8356)),Promise.resolve().then(r.bind(r,5845)),Promise.resolve().then(r.bind(r,3292)),Promise.resolve().then(r.bind(r,2406)),Promise.resolve().then(r.bind(r,2105)),Promise.resolve().then(r.bind(r,1374)),Promise.resolve().then(r.bind(r,1580)),Promise.resolve().then(r.bind(r,850)),Promise.resolve().then(r.bind(r,6310)),Promise.resolve().then(r.bind(r,984)),Promise.resolve().then(r.bind(r,4070)),Promise.resolve().then(r.bind(r,9006)),Promise.resolve().then(r.bind(r,5281)),Promise.resolve().then(r.bind(r,9502)),Promise.resolve().then(r.bind(r,2517)),Promise.resolve().then(r.bind(r,215)),Promise.resolve().then(r.bind(r,6652)),Promise.resolve().then(r.bind(r,1459))},1441:(e,s,r)=>{"use strict";r.d(s,{Rk:()=>n.PhosphorText,Uu:()=>i.MetalCard}),r(4070),r(9006),r(5281),r(6652);var i=r(9502),n=r(215);r(2517),r(1459),r(984)},7083:(e,s,r)=>{"use strict";r.d(s,{InviteMemberForm:()=>x});var i=r(4568),n=r(7620),o=r(7541),l=r(2622),t=r(9404),d=r(4090),a=r(9157),h=r(5754),c=r(1284),b=r(1129),m=r(6032),u=r(1156),v=r(1037);function x(e){let{teamId:s}=e,r=(0,o.useRouter)(),[x,P]=(0,n.useState)(!1),[p,j]=(0,n.useState)(""),[g,f]=(0,n.useState)(null),[y,A]=(0,n.useState)(!1);async function k(){if(p.trim()){f(null),A(!0);try{let e=(0,v.c)(),{error:i}=await e.from("team_members").insert({team_id:s,user_id:p.trim(),role:"member"});if(i)return void f(i.message);j(""),P(!1),r.refresh()}finally{A(!1)}}}return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(l.A,{variant:"outlined",size:"small",startIcon:(0,i.jsx)(u.A,{}),onClick:()=>P(!0),children:"멤버 초대"}),(0,i.jsxs)(t.A,{open:x,onClose:()=>P(!1),maxWidth:"sm",fullWidth:!0,children:[(0,i.jsx)(d.A,{children:"멤버 초대"}),(0,i.jsx)(a.A,{children:(0,i.jsxs)(h.default,{spacing:2,sx:{mt:1},children:[(0,i.jsx)(c.default,{sx:{fontSize:12,color:"text.secondary"},children:"MVP 단계에서는 user_id를 직접 입력합니다. 정식 초대 링크 / 이메일 발송은 V2-7b에서 지원 예정입니다."}),(0,i.jsx)(b.A,{label:"User ID (UUID)",size:"small",value:p,onChange:e=>j(e.target.value),placeholder:"00000000-0000-0000-0000-000000000000",fullWidth:!0,autoFocus:!0}),g&&(0,i.jsx)(m.A,{severity:"error",variant:"outlined",children:g}),(0,i.jsxs)(h.default,{direction:"row",spacing:1,justifyContent:"flex-end",children:[(0,i.jsx)(l.A,{onClick:()=>P(!1),disabled:y,children:"취소"}),(0,i.jsx)(l.A,{variant:"contained",onClick:()=>void k(),disabled:y||!p.trim(),children:"초대"})]})]})})]})]})}}},e=>{e.O(0,[385,77,988,189,949,473,746,605,32,80,184,791,803,910,587,18,358],()=>e(e.s=441)),_N_E=e.O()}]);