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A,EAAY,KAChCZ,EAAQ,IACJmC,GACFlC,GAEJ,EAAG,CAACA,EAAWD,EAASmC,EAAW,EAEnC,MACE,UAAClB,EAAAA,EAAYA,CAAAA,CACXlB,KAAMA,EACNmB,aAAclB,EACdvB,MAAOH,CAAC,CAAC,sCAAsC,GAC/C6C,YAAa7C,CAAC,CACZ6D,EACI,iDACA,gDACL,CAAC,CAAEG,SAAUF,EAAMC,MAAOA,CAAM,GACjCE,oBAAqB,CAAE/C,MAAO,CAAEgD,QAASL,EAAa,GAAK,MAAO,CAAE,EACpEZ,YAAajD,CAAC,CACZ6D,EACI,6CACA,4CACL,GACDX,qBAAsB,CACpB5B,QAAS,SACX,EACAK,UAAWU,C,EAGjB,E,8CCvCO,IAAM8B,EAAa,CAAC,CACzBC,WAAAA,CAAU,CACVC,aAAAA,CAAY,CACZC,aAAAA,CAAY,CACI,IAChB,IAAMC,EAAkBjC,CAAAA,EAAAA,EAAAA,WAAAA,EACtB,IAEEgC,EADkB,EAAGE,QAAQ,CAAGH,EAAgBD,EAElD,EACA,CAACC,EAAcC,EAAcF,EAAW,EAGpCK,EAAYC,CAAAA,EAAAA,EAAAA,OAAAA,EAChB,IAAMC,KAAKC,IAAI,CAACR,EAAaC,GAC7B,CAACA,EAAcD,EAAW,EAG5B,MACE,UAACS,IAAaA,CACZP,aAAcC,EACdO,mBAAoB,EACpBC,qBAAsB,EACtBN,UAAWA,EACXO,cAAe,UAACC,EAAAA,kBAAkBA,CAAAA,CAAAA,GAClCC,UAAW,UAACC,EAAAA,mBAAmBA,CAAAA,CAAAA,GAC/BC,cAAerE,EACfsE,kBAAmBC,CAAAA,EAAAA,EAAAA,CAAAA,EAAKvE,EAAiB,SACzCwE,cAAeD,CAAAA,EAAAA,EAAAA,CAAAA,EAAKvE,EAAiB,SACrCyE,WAAW,MACXC,eAAgB1E,EAChB2E,mBJrCkB,WIsClBC,gBAAgB,SAChBC,sBAAuB,I,EAG7B,C","sources":["webpack://@affine/web/../component/src/components/member-components/styles.css.tsx","webpack://@affine/web/../component/src/components/member-components/accept-invite-page.tsx","webpack://@affine/web/../component/src/components/member-components/invite-modal.tsx","webpack://@affine/web/../component/src/components/member-components/member-limit-modal.tsx","webpack://@affine/web/../component/src/components/member-components/pagination.tsx"],"sourcesContent":["import \"../component/src/components/member-components/styles.css.tsx.vanilla.css!=!../../../../../../node_modules/@vanilla-extract/webpack-plugin/virtualFileLoader/dist/vanilla-extract-webpack-plugin-virtualFileLoader.cjs.js?{\\\"fileName\\\":\\\"../component/src/components/member-components/styles.css.tsx.vanilla.css\\\",\\\"source\\\":\\\"#H4sIAAAAAAAAA61SzW6jMBC+5ynmslJzMII25eA8TGXsAWbj2MgeUtKq717hkMphm93Vao+Mv/n+huKlOuiW6hLeNwCtdyxekbqeJdRlub/OIr2hhJMKD0KotiWHIs17UW9n0FGFjpxoPLM/Sngsh2m/+dgUC3uV2FegagV6TCBDcbDqLKG1OM3UP8fI1J6F9o7R8eVBoDP57lMuYLFlCbthypyFS6aLJoD21odVoMYqfdjmrLu/dKTRMYb5SVnqnCDGY8zHnRok1DeG2A8Snm8beL7VI2dT0f8s+0qG++s1APrlsNfv3152itt7RTFOLIZARxVmN9aHBG18MBhEUIbGuPSfZZO9P2FICRulD13wozMr5gT5osyWC6WZTpi2v7P0qxs9hjjDDLZqtDyPBk9zMwJP6DhKcN7hrYpVDdq7IqS9yxSy+qp6FbYwFFVj0SQyPyhNfJZQ7O5Y+05uocgU/xgAVNJb7l6V5Y/9//iBPz4B32PSICYEAAA=\\\"}!../../../../../../node_modules/@vanilla-extract/webpack-plugin/extracted.js\"\nexport var inviteModalButtonContainer = '_1kcfi62';\nexport var inviteModalContent = '_1kcfi61';\nexport var inviteModalTitle = '_1kcfi60';\nexport var inviteName = '_1kcfi63';\nexport var pageItem = '_1kcfi65';\nexport var pagination = '_1kcfi64';","import { AuthPageContainer } from '@affine/component/auth-components';\nimport type { GetInviteInfoQuery } from '@affine/graphql';\nimport { useI18n } from '@affine/i18n';\n\nimport { Avatar } from '../../ui/avatar';\nimport { Button } from '../../ui/button';\nimport { FlexWrapper } from '../../ui/layout';\nimport * as styles from './styles.css';\nexport const AcceptInvitePage = ({\n onOpenWorkspace,\n inviteInfo,\n}: {\n onOpenWorkspace: () => void;\n inviteInfo: GetInviteInfoQuery['getInviteInfo'];\n}) => {\n const t = useI18n();\n return (\n \n \n {inviteInfo.user.name}\n {t['invited you to join']()}\n \n {inviteInfo.workspace.name}\n \n }\n >\n \n \n );\n};\n","import { Permission } from '@affine/graphql';\nimport { useI18n } from '@affine/i18n';\nimport { useCallback, useEffect, useState } from 'react';\n\nimport { ConfirmModal } from '../../ui/modal';\nimport { AuthInput } from '..//auth-components';\nimport { emailRegex } from '..//auth-components/utils';\n\nexport interface InviteModalProps {\n open: boolean;\n setOpen: (value: boolean) => void;\n onConfirm: (params: { email: string; permission: Permission }) => void;\n isMutating: boolean;\n}\n\nexport const InviteModal = ({\n open,\n setOpen,\n onConfirm,\n isMutating,\n}: InviteModalProps) => {\n const t = useI18n();\n const [inviteEmail, setInviteEmail] = useState('');\n const [permission] = useState(Permission.Write);\n const [isValidEmail, setIsValidEmail] = useState(true);\n\n const handleConfirm = useCallback(() => {\n if (!emailRegex.test(inviteEmail)) {\n setIsValidEmail(false);\n return;\n }\n setIsValidEmail(true);\n\n onConfirm({\n email: inviteEmail,\n permission,\n });\n }, [inviteEmail, onConfirm, permission]);\n\n useEffect(() => {\n if (!open) {\n setInviteEmail('');\n setIsValidEmail(true);\n }\n }, [open]);\n\n return (\n \n \n \n );\n};\n","import { ConfirmModal } from '@affine/component/ui/modal';\nimport { useI18n } from '@affine/i18n';\nimport { useCallback } from 'react';\n\nexport interface MemberLimitModalProps {\n isFreePlan: boolean;\n open: boolean;\n plan: string;\n quota: string;\n setOpen: (value: boolean) => void;\n onConfirm: () => void;\n}\n\nexport const MemberLimitModal = ({\n isFreePlan,\n open,\n plan,\n quota,\n setOpen,\n onConfirm,\n}: MemberLimitModalProps) => {\n const t = useI18n();\n const handleConfirm = useCallback(() => {\n setOpen(false);\n if (isFreePlan) {\n onConfirm();\n }\n }, [onConfirm, setOpen, isFreePlan]);\n\n return (\n \n );\n};\n","import { ArrowLeftSmallIcon, ArrowRightSmallIcon } from '@blocksuite/icons/rc';\nimport clsx from 'clsx';\nimport { useCallback, useMemo } from 'react';\nimport ReactPaginate from 'react-paginate';\n\nimport * as styles from './styles.css';\nexport interface PaginationProps {\n totalCount: number;\n countPerPage: number;\n onPageChange: (skip: number) => void;\n}\n\nexport const Pagination = ({\n totalCount,\n countPerPage,\n onPageChange,\n}: PaginationProps) => {\n const handlePageClick = useCallback(\n (e: { selected: number }) => {\n const newOffset = (e.selected * countPerPage) % totalCount;\n onPageChange(newOffset);\n },\n [countPerPage, onPageChange, totalCount]\n );\n\n const pageCount = useMemo(\n () => Math.ceil(totalCount / countPerPage),\n [countPerPage, totalCount]\n );\n\n return (\n }\n nextLabel={}\n pageClassName={styles.pageItem}\n previousClassName={clsx(styles.pageItem, 'label')}\n nextClassName={clsx(styles.pageItem, 'label')}\n breakLabel=\"...\"\n breakClassName={styles.pageItem}\n containerClassName={styles.pagination}\n activeClassName=\"active\"\n renderOnZeroPageCount={null}\n />\n );\n};\n"],"names":["inviteName","pageItem","AcceptInvitePage","onOpenWorkspace","inviteInfo","t","useI18n","AuthPageContainer","title","subtitle","FlexWrapper","alignItems","Avatar","url","user","avatarUrl","name","size","span","className","styles","workspace","avatar","style","marginLeft","colorfulFallback","Button","variant","onClick","InviteModal","open","setOpen","onConfirm","isMutating","inviteEmail","setInviteEmail","useState","permission","Permission","Write","isValidEmail","setIsValidEmail","handleConfirm","useCallback","emailRegex","test","email","useEffect","ConfirmModal","onOpenChange","description","cancelText","contentOptions","padding","confirmText","confirmButtonOptions","loading","AuthInput","disabled","placeholder","value","onChange","error","errorHint","onEnter","MemberLimitModal","isFreePlan","plan","quota","planName","cancelButtonOptions","display","Pagination","totalCount","countPerPage","onPageChange","handlePageClick","selected","pageCount","useMemo","Math","ceil","ReactPaginate","pageRangeDisplayed","marginPagesDisplayed","previousLabel","ArrowLeftSmallIcon","nextLabel","ArrowRightSmallIcon","pageClassName","previousClassName","clsx","nextClassName","breakLabel","breakClassName","containerClassName","activeClassName","renderOnZeroPageCount"],"sourceRoot":""}