{"version":3,"file":"index.js","names":["useRouteCache","useTranslation","useDocumentDrawer","ListSelectionButton","EditFolderAction","id","folderCollectionSlug","clearRouteCache","t","FolderDocumentDrawer","closeDrawer","openDrawer","collectionSlug","_jsxs","_Fragment","_jsx","onClick","type","onSave"],"sources":["../../../../../src/elements/FolderView/Drawers/EditFolderAction/index.tsx"],"sourcesContent":["import { useRouteCache } from '../../../../providers/RouteCache/index.js'\nimport { useTranslation } from '../../../../providers/Translation/index.js'\nimport { useDocumentDrawer } from '../../../DocumentDrawer/index.js'\nimport { ListSelectionButton } from '../../../ListSelection/index.js'\n\ntype EditFolderActionProps = {\n folderCollectionSlug: string\n id: number | string\n}\nexport const EditFolderAction = ({ id, folderCollectionSlug }: EditFolderActionProps) => {\n const { clearRouteCache } = useRouteCache()\n const { t } = useTranslation()\n const [FolderDocumentDrawer, , { closeDrawer, openDrawer }] = useDocumentDrawer({\n id,\n collectionSlug: folderCollectionSlug,\n })\n\n if (!id) {\n return null\n }\n\n return (\n <>\n \n {t('general:edit')}\n \n\n {\n closeDrawer()\n clearRouteCache()\n }}\n />\n \n )\n}\n"],"mappings":";AAAA,SAASA,aAAa,QAAQ;AAC9B,SAASC,cAAc,QAAQ;AAC/B,SAASC,iBAAiB,QAAQ;AAClC,SAASC,mBAAmB,QAAQ;AAMpC,OAAO,MAAMC,gBAAA,GAAmBA,CAAC;EAAEC,EAAE;EAAEC;AAAoB,CAAyB;EAClF,MAAM;IAAEC;EAAe,CAAE,GAAGP,aAAA;EAC5B,MAAM;IAAEQ;EAAC,CAAE,GAAGP,cAAA;EACd,MAAM,CAACQ,oBAAA,GAAwB;IAAEC,WAAW;IAAEC;EAAU,CAAE,CAAC,GAAGT,iBAAA,CAAkB;IAC9EG,EAAA;IACAO,cAAA,EAAgBN;EAClB;EAEA,IAAI,CAACD,EAAA,EAAI;IACP,OAAO;EACT;EAEA,oBACEQ,KAAA,CAAAC,SAAA;4BACEC,IAAA,CAACZ,mBAAA;MAAoBa,OAAA,EAASL,UAAA;MAAYM,IAAA,EAAK;gBAC5CT,CAAA,CAAE;qBAGLO,IAAA,CAACN,oBAAA;MACCS,MAAA,EAAQA,CAAA;QACNR,WAAA;QACAH,eAAA;MACF;;;AAIR","ignoreList":[]}