@accounter/client 0.0.8-alpha-20251102162844-adaba3b25910083f6ebd80bd580629e1c0871260 → 0.0.8-alpha-20251102200443-d7162b8ce1dfc629b8b454df17dcec9ed005a052

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (84) hide show
  1. package/CHANGELOG.md +1 -16
  2. package/dist/assets/{Checkbox-D07lxgUb.js → Checkbox-MQSJP1Kv.js} +1 -1
  3. package/dist/assets/{MultiSelect-EJOdjjCM.js → MultiSelect-HgnjtQq6.js} +1 -1
  4. package/dist/assets/{Progress-CGy7x8SJ.js → Progress-DfKDLZqp.js} +1 -1
  5. package/dist/assets/{Table-BFvxFsm0.js → Table-C6kFDK4t.js} +1 -1
  6. package/dist/assets/{Typography-Cn9V_ua-.js → Typography-B-ckq9s3.js} +1 -1
  7. package/dist/assets/{YearPickerInput-C3FAWyW8.js → YearPickerInput-DMYgFyy1.js} +1 -1
  8. package/dist/assets/{accordion-Dcsrptah.js → accordion-BPn2y11E.js} +1 -1
  9. package/dist/assets/{accountant-approvals-BkIp9MtP.js → accountant-approvals-B1qAfwhS.js} +1 -1
  10. package/dist/assets/{accounter-table-CiWJofTb.js → accounter-table-Ck7Xro1D.js} +1 -1
  11. package/dist/assets/{addDays-niMFKLO8.js → addDays-rR2nxcHS.js} +1 -1
  12. package/dist/assets/{all-charges-BlTbeId-.js → all-charges-Bl4j0far.js} +1 -1
  13. package/dist/assets/{arrow-up-down-DXqwGYCG.js → arrow-up-down-C2zc3KHR.js} +1 -1
  14. package/dist/assets/{building-2-DNGlBGhG.js → building-2-BUMAZjce.js} +1 -1
  15. package/dist/assets/{business-CGsHGCVR.js → business-DGkNACiP.js} +1 -1
  16. package/dist/assets/{business-extended-info-D7xrGWVf.js → business-extended-info-BFNPJr4z.js} +1 -1
  17. package/dist/assets/{business-header-DUvIq5zk.js → business-header-Dk0AD9bS.js} +1 -1
  18. package/dist/assets/{business-ledger-filters-2BxQb6DJ.js → business-ledger-filters-CT21oQgH.js} +1 -1
  19. package/dist/assets/{business-ledger-single-D8B4c9Y8.js → business-ledger-single-hby9yZmP.js} +1 -1
  20. package/dist/assets/{business-trip-QNwJGdID.js → business-trip-BtepmxeV.js} +1 -1
  21. package/dist/assets/{charge-Bh7uVjEZ.js → charge-BUwJkBtL.js} +1 -1
  22. package/dist/assets/{charges-filters-qm8XrSOr.js → charges-filters-h9VrmqSd.js} +1 -1
  23. package/dist/assets/{charges-ledger-validation-2hrcLjhR.js → charges-ledger-validation-BwwHdKK2.js} +1 -1
  24. package/dist/assets/{charges-table-nMOWRUfT.js → charges-table-BzapDDk2.js} +1 -1
  25. package/dist/assets/{chart-D7_v1_k3.js → chart-Cozspxlr.js} +1 -1
  26. package/dist/assets/{contracts-B6kNI4VW.js → contracts-U7aTeum5.js} +1 -1
  27. package/dist/assets/{data-table-pagination-B5rIDq8W.js → data-table-pagination-DyQoZGT8.js} +1 -1
  28. package/dist/assets/{download-csv-button-ppWqXc5x.js → download-csv-button-BYaF4bdW.js} +1 -1
  29. package/dist/assets/{edit-issue-document-modal-CgbQFy_I.js → edit-issue-document-modal-BH9eFUFj.js} +1 -1
  30. package/dist/assets/{editable-business-trip-C5oGNtOC.js → editable-business-trip-BpQPUDeX.js} +1 -1
  31. package/dist/assets/{eye-off-CdQi5YqS.js → eye-off-8yoUnvwc.js} +1 -1
  32. package/dist/assets/{funnel-B98DbthO.js → funnel-rqI973_z.js} +1 -1
  33. package/dist/assets/{index-CRAKdwpm.js → index---wiXQch.js} +1 -1
  34. package/dist/assets/{index-CczG-_NN.js → index-BKKb5SIS.js} +1 -1
  35. package/dist/assets/{index-CCci5upL.js → index-BS8L_kek.js} +1 -1
  36. package/dist/assets/{index-CeW24FKL.js → index-BYuCJweM.js} +1 -1
  37. package/dist/assets/{index-Bin3WDOT.js → index-BzM4aBGf.js} +1 -1
  38. package/dist/assets/{index-CZPBUiZS.js → index-C4fBu7dF.js} +1 -1
  39. package/dist/assets/{index--3YmiAOI.js → index-CE9_xMMH.js} +1 -1
  40. package/dist/assets/{index-DTpkhSUa.js → index-CKHNsktP.js} +1 -1
  41. package/dist/assets/{index-RutmL5Ul.js → index-CbDrNX8Y.js} +1 -1
  42. package/dist/assets/{index-CkbuOibL.js → index-CfuLbnqR.js} +1 -1
  43. package/dist/assets/{index-CnXXoDVM.js → index-CgWRVpWN.js} +1 -1
  44. package/dist/assets/{index-Bkvs21Zy.js → index-ChJ4LOyI.js} +1 -1
  45. package/dist/assets/{index-BgPeJGlv.js → index-CkaRkAYR.js} +1 -1
  46. package/dist/assets/{index-BSLec-c1.js → index-ClUIIfG4.js} +1 -1
  47. package/dist/assets/{index-B06ZwZPk.js → index-CrQ-d3ZY.js} +1 -1
  48. package/dist/assets/{index-Cbh8pZGB.js → index-CwnvPs7H.js} +1 -1
  49. package/dist/assets/{index-B_gzYVvY.js → index-DL96FIEg.js} +197 -197
  50. package/dist/assets/{index-BC7SDl06.js → index-DuRWim6c.js} +1 -1
  51. package/dist/assets/{index-Cy7qBCMn.js → index-DvdJbkKP.js} +1 -1
  52. package/dist/assets/{index-DUN5nloV.js → index-Dw7ntedT.js} +1 -1
  53. package/dist/assets/{index-7mhueB8r.js → index-DwwlkwpR.js} +1 -1
  54. package/dist/assets/{index-DRdkpxr_.js → index-Dz8kIp8n.js} +1 -1
  55. package/dist/assets/{index-P9up3omJ.js → index-FWvQ1Qel.js} +1 -1
  56. package/dist/assets/{index-DZBsZGaI.js → index-PEwgQUmi.js} +1 -1
  57. package/dist/assets/{index-CAL4xLbi.js → index-VResHKwN.js} +1 -1
  58. package/dist/assets/{index.es-Dg75av_t.js → index.es-pWDlYeZR.js} +1 -1
  59. package/dist/assets/{insert-business-trip-modal-BpJ7Whji.js → insert-business-trip-modal-DqaEKPTo.js} +1 -1
  60. package/dist/assets/issue-document-m1L1MfHg.js +1 -0
  61. package/dist/assets/{list-plus-C_Jn2eXi.js → list-plus-oBV3pFTT.js} +1 -1
  62. package/dist/assets/{login-page-KK1XmG-q.js → login-page-B7kaddO1.js} +1 -1
  63. package/dist/assets/{match-document-modal-DVy_0W7_.js → match-document-modal-Bx28FYLE.js} +1 -1
  64. package/dist/assets/{missing-info-charges-CvQhaOGf.js → missing-info-charges-B8OpcCoi.js} +1 -1
  65. package/dist/assets/{modal-BF-8kNcF.js → modal-CcO9VM0k.js} +1 -1
  66. package/dist/assets/{modify-contract-dialog-COxKCZbm.js → modify-contract-dialog-2syYWUAb.js} +1 -1
  67. package/dist/assets/{page-layout-DTRGIdR7.js → page-layout-UeCQVB1c.js} +1 -1
  68. package/dist/assets/{page-not-found-BrFVD44q.js → page-not-found-wd-RuFGL.js} +1 -1
  69. package/dist/assets/{panel-top-open-G_VONODW.js → panel-top-open-CkHLcq8U.js} +1 -1
  70. package/dist/assets/{pencil-c0IjX9_t.js → pencil-BPrWXhJF.js} +1 -1
  71. package/dist/assets/{report-commentary-row-KtfG6Mgp.js → report-commentary-row-Ce97x0Td.js} +1 -1
  72. package/dist/assets/{save-WMtDMx-a.js → save-CRihagY-.js} +1 -1
  73. package/dist/assets/{similar-transactions-modal-BTPf8nja.js → similar-transactions-modal-BSuJ2iUE.js} +1 -1
  74. package/dist/assets/{sub-BtF05bP9.js → sub-DWYVPUbm.js} +1 -1
  75. package/dist/assets/subMonths-COsA6eIJ.js +1 -0
  76. package/dist/assets/{summary-CwkKwWyt.js → summary-CqOtnY3L.js} +1 -1
  77. package/dist/assets/{toggle-expansion-button-DFsqkVwe.js → toggle-expansion-button-DrS1THUU.js} +1 -1
  78. package/dist/assets/tooltip-BwXnRGjA.js +1 -0
  79. package/dist/assets/{use-url-query-C4M5DF3n.js → use-url-query-Dwk3Z7IG.js} +1 -1
  80. package/dist/index.html +1 -1
  81. package/package.json +5 -5
  82. package/dist/assets/issue-document-Dhq8yxLH.js +0 -1
  83. package/dist/assets/subMonths-CwHVZ8eK.js +0 -1
  84. package/dist/assets/tooltip-CVi4tvZO.js +0 -1
@@ -1 +1 @@
1
- import{r as c,j as e,B as u,a as y,F as g,u as P,L as D,f$ as w}from"./index-B_gzYVvY.js";import{d as R}from"./graphql-document-dedupe-fragments-ByT8-wlV.js";import{P as E}from"./page-layout-DTRGIdR7.js";import{R as d}from"./report-commentary-row-KtfG6Mgp.js";import{P as v}from"./modal-BF-8kNcF.js";import{Y as p}from"./YearPickerInput-C3FAWyW8.js";import{F}from"./funnel-B98DbthO.js";import{T as C}from"./Table-BFvxFsm0.js";import"./toggle-expansion-button-DFsqkVwe.js";import"./panel-top-open-G_VONODW.js";function A({year:l,setYear:h,referenceYears:o,setReferenceYears:j}){const[m,x]=c.useState(!1);return e.jsxs(e.Fragment,{children:[e.jsx(v,{opened:m,onClose:()=>x(!1),withCloseButton:!0,content:e.jsxs(e.Fragment,{children:[e.jsx(p,{label:"Change report year",value:new Date(l,0,1),onChange:n=>n&&h(n?.getFullYear()),popoverProps:{withinPortal:!0},minDate:new Date(2010,0,1),maxDate:new Date}),e.jsx(p,{type:"multiple",label:"Pick reference years",value:o?.map(n=>new Date(n,0,1)),onChange:n=>j(n.map(i=>i.getFullYear()).filter(i=>l!==i)),popoverProps:{withinPortal:!0},minDate:new Date(2010,0,1),maxDate:new Date})]})}),e.jsx(u,{variant:"outline",size:"icon",className:"size-7.5",onClick:()=>x(!0),children:e.jsx(F,{className:"size-5"})})]})}const I=()=>{const{year:l}=y(),{setFiltersContext:h}=c.useContext(g),[o,j]=c.useState(l?Number(l):new Date().getFullYear()),[m,x]=c.useState([]),[{data:n,fetching:i}]=P({query:R(w),variables:{reportYear:o,referenceYears:m}});c.useEffect(()=>{h(e.jsx("div",{className:"flex flex-row gap-2",children:e.jsx(A,{year:o,setYear:j,referenceYears:m,setReferenceYears:x})}))},[o,i,h,m,x]);const f=n?.profitAndLossReport,r=f?.report,s=f?.reference??[];return e.jsx(E,{title:"Profit and Loss Report",children:i?e.jsx(D,{className:"h-10 w-10 animate-spin mr-2 self-center"}):e.jsx("div",{className:"flex flex-col gap-4",children:r&&e.jsxs(C,{highlightOnHover:!0,fontSize:"md",children:[e.jsx("thead",{children:e.jsxs("tr",{children:[e.jsx("th",{}),e.jsx("th",{children:o},o),e.jsx("th",{}),s.map(t=>e.jsx("th",{children:t.year},t.year))]})}),e.jsxs("tbody",{children:[e.jsx(d,{dataRow:t=>e.jsxs("tr",{children:[e.jsx("th",{children:"Revenue"}),e.jsx("th",{children:r.revenue.amount.formatted}),e.jsx("th",{children:t}),s.map(a=>e.jsx("th",{children:a.revenue.amount.formatted},a.year))]}),commentaryData:r.revenue}),e.jsx(d,{dataRow:t=>e.jsxs("tr",{children:[e.jsx("td",{children:"Cost of Sales"}),e.jsx("td",{children:r.costOfSales.amount.formatted}),e.jsx("th",{children:t}),s.map(a=>e.jsx("td",{children:a.costOfSales.amount.formatted},a.year))]}),commentaryData:r.costOfSales}),e.jsxs("tr",{children:[e.jsx("th",{children:"Gross Profit"}),e.jsx("th",{children:r.grossProfit.formatted}),e.jsx("th",{}),s.map(t=>e.jsx("th",{children:t.grossProfit.formatted},t.year))]}),e.jsx(d,{dataRow:t=>e.jsxs("tr",{children:[e.jsx("td",{children:"R&D Expenses"}),e.jsx("td",{children:r.researchAndDevelopmentExpenses.amount.formatted}),e.jsx("th",{children:t}),s.map(a=>e.jsx("td",{children:a.researchAndDevelopmentExpenses.amount.formatted},a.year))]}),commentaryData:r.researchAndDevelopmentExpenses}),e.jsx(d,{dataRow:t=>e.jsxs("tr",{children:[e.jsx("td",{children:"Marketing Expenses"}),e.jsx("td",{children:r.marketingExpenses.amount.formatted}),e.jsx("th",{children:t}),s.map(a=>e.jsx("td",{children:a.marketingExpenses.amount.formatted},a.year))]}),commentaryData:r.marketingExpenses}),e.jsx(d,{dataRow:t=>e.jsxs("tr",{children:[e.jsx("td",{children:"Management and General Expenses"}),e.jsx("td",{children:r.managementAndGeneralExpenses.amount.formatted}),e.jsx("th",{children:t}),s.map(a=>e.jsx("td",{children:a.managementAndGeneralExpenses.amount.formatted},a.year))]}),commentaryData:r.managementAndGeneralExpenses}),e.jsxs("tr",{children:[e.jsx("th",{children:"Operating Profit"}),e.jsx("th",{children:r.operatingProfit.formatted}),e.jsx("th",{}),s.map(t=>e.jsx("th",{children:t.operatingProfit.formatted},t.year))]}),e.jsx(d,{dataRow:t=>e.jsxs("tr",{children:[e.jsx("td",{children:"Financial Expenses"}),e.jsx("td",{children:r.financialExpenses.amount.formatted}),e.jsx("th",{children:t}),s.map(a=>e.jsx("td",{children:a.financialExpenses.amount.formatted},a.year))]}),commentaryData:r.financialExpenses}),e.jsx(d,{dataRow:t=>e.jsxs("tr",{children:[e.jsx("td",{children:"Other Income"}),e.jsx("td",{children:r.otherIncome.amount.formatted}),e.jsx("th",{children:t}),s.map(a=>e.jsx("td",{children:a.otherIncome.amount.formatted},a.year))]}),commentaryData:r.otherIncome}),e.jsxs("tr",{children:[e.jsx("th",{children:"Profit Before Tax"}),e.jsx("th",{children:r.profitBeforeTax.formatted}),e.jsx("th",{}),s.map(t=>e.jsx("th",{children:t.profitBeforeTax.formatted},t.year))]}),e.jsxs("tr",{children:[e.jsx("td",{children:"Tax"}),e.jsx("td",{children:r.tax.formatted}),e.jsx("td",{}),s.map(t=>e.jsx("td",{children:t.tax.formatted},t.year))]})]}),e.jsx("tfoot",{children:e.jsxs("tr",{children:[e.jsx("th",{children:"Net Profit"}),e.jsx("th",{children:r.netProfit.formatted}),e.jsx("th",{}),s.map(t=>e.jsx("th",{children:t.netProfit.formatted},t.year))]})})]})})})};export{I as ProfitAndLossReport};
1
+ import{r as c,j as e,B as u,a as y,F as g,u as P,L as D,f$ as w}from"./index-DL96FIEg.js";import{d as R}from"./graphql-document-dedupe-fragments-ByT8-wlV.js";import{P as E}from"./page-layout-UeCQVB1c.js";import{R as d}from"./report-commentary-row-Ce97x0Td.js";import{P as v}from"./modal-CcO9VM0k.js";import{Y as p}from"./YearPickerInput-DMYgFyy1.js";import{F}from"./funnel-rqI973_z.js";import{T as C}from"./Table-C6kFDK4t.js";import"./toggle-expansion-button-DrS1THUU.js";import"./panel-top-open-CkHLcq8U.js";function A({year:l,setYear:h,referenceYears:o,setReferenceYears:j}){const[m,x]=c.useState(!1);return e.jsxs(e.Fragment,{children:[e.jsx(v,{opened:m,onClose:()=>x(!1),withCloseButton:!0,content:e.jsxs(e.Fragment,{children:[e.jsx(p,{label:"Change report year",value:new Date(l,0,1),onChange:n=>n&&h(n?.getFullYear()),popoverProps:{withinPortal:!0},minDate:new Date(2010,0,1),maxDate:new Date}),e.jsx(p,{type:"multiple",label:"Pick reference years",value:o?.map(n=>new Date(n,0,1)),onChange:n=>j(n.map(i=>i.getFullYear()).filter(i=>l!==i)),popoverProps:{withinPortal:!0},minDate:new Date(2010,0,1),maxDate:new Date})]})}),e.jsx(u,{variant:"outline",size:"icon",className:"size-7.5",onClick:()=>x(!0),children:e.jsx(F,{className:"size-5"})})]})}const I=()=>{const{year:l}=y(),{setFiltersContext:h}=c.useContext(g),[o,j]=c.useState(l?Number(l):new Date().getFullYear()),[m,x]=c.useState([]),[{data:n,fetching:i}]=P({query:R(w),variables:{reportYear:o,referenceYears:m}});c.useEffect(()=>{h(e.jsx("div",{className:"flex flex-row gap-2",children:e.jsx(A,{year:o,setYear:j,referenceYears:m,setReferenceYears:x})}))},[o,i,h,m,x]);const f=n?.profitAndLossReport,r=f?.report,s=f?.reference??[];return e.jsx(E,{title:"Profit and Loss Report",children:i?e.jsx(D,{className:"h-10 w-10 animate-spin mr-2 self-center"}):e.jsx("div",{className:"flex flex-col gap-4",children:r&&e.jsxs(C,{highlightOnHover:!0,fontSize:"md",children:[e.jsx("thead",{children:e.jsxs("tr",{children:[e.jsx("th",{}),e.jsx("th",{children:o},o),e.jsx("th",{}),s.map(t=>e.jsx("th",{children:t.year},t.year))]})}),e.jsxs("tbody",{children:[e.jsx(d,{dataRow:t=>e.jsxs("tr",{children:[e.jsx("th",{children:"Revenue"}),e.jsx("th",{children:r.revenue.amount.formatted}),e.jsx("th",{children:t}),s.map(a=>e.jsx("th",{children:a.revenue.amount.formatted},a.year))]}),commentaryData:r.revenue}),e.jsx(d,{dataRow:t=>e.jsxs("tr",{children:[e.jsx("td",{children:"Cost of Sales"}),e.jsx("td",{children:r.costOfSales.amount.formatted}),e.jsx("th",{children:t}),s.map(a=>e.jsx("td",{children:a.costOfSales.amount.formatted},a.year))]}),commentaryData:r.costOfSales}),e.jsxs("tr",{children:[e.jsx("th",{children:"Gross Profit"}),e.jsx("th",{children:r.grossProfit.formatted}),e.jsx("th",{}),s.map(t=>e.jsx("th",{children:t.grossProfit.formatted},t.year))]}),e.jsx(d,{dataRow:t=>e.jsxs("tr",{children:[e.jsx("td",{children:"R&D Expenses"}),e.jsx("td",{children:r.researchAndDevelopmentExpenses.amount.formatted}),e.jsx("th",{children:t}),s.map(a=>e.jsx("td",{children:a.researchAndDevelopmentExpenses.amount.formatted},a.year))]}),commentaryData:r.researchAndDevelopmentExpenses}),e.jsx(d,{dataRow:t=>e.jsxs("tr",{children:[e.jsx("td",{children:"Marketing Expenses"}),e.jsx("td",{children:r.marketingExpenses.amount.formatted}),e.jsx("th",{children:t}),s.map(a=>e.jsx("td",{children:a.marketingExpenses.amount.formatted},a.year))]}),commentaryData:r.marketingExpenses}),e.jsx(d,{dataRow:t=>e.jsxs("tr",{children:[e.jsx("td",{children:"Management and General Expenses"}),e.jsx("td",{children:r.managementAndGeneralExpenses.amount.formatted}),e.jsx("th",{children:t}),s.map(a=>e.jsx("td",{children:a.managementAndGeneralExpenses.amount.formatted},a.year))]}),commentaryData:r.managementAndGeneralExpenses}),e.jsxs("tr",{children:[e.jsx("th",{children:"Operating Profit"}),e.jsx("th",{children:r.operatingProfit.formatted}),e.jsx("th",{}),s.map(t=>e.jsx("th",{children:t.operatingProfit.formatted},t.year))]}),e.jsx(d,{dataRow:t=>e.jsxs("tr",{children:[e.jsx("td",{children:"Financial Expenses"}),e.jsx("td",{children:r.financialExpenses.amount.formatted}),e.jsx("th",{children:t}),s.map(a=>e.jsx("td",{children:a.financialExpenses.amount.formatted},a.year))]}),commentaryData:r.financialExpenses}),e.jsx(d,{dataRow:t=>e.jsxs("tr",{children:[e.jsx("td",{children:"Other Income"}),e.jsx("td",{children:r.otherIncome.amount.formatted}),e.jsx("th",{children:t}),s.map(a=>e.jsx("td",{children:a.otherIncome.amount.formatted},a.year))]}),commentaryData:r.otherIncome}),e.jsxs("tr",{children:[e.jsx("th",{children:"Profit Before Tax"}),e.jsx("th",{children:r.profitBeforeTax.formatted}),e.jsx("th",{}),s.map(t=>e.jsx("th",{children:t.profitBeforeTax.formatted},t.year))]}),e.jsxs("tr",{children:[e.jsx("td",{children:"Tax"}),e.jsx("td",{children:r.tax.formatted}),e.jsx("td",{}),s.map(t=>e.jsx("td",{children:t.tax.formatted},t.year))]})]}),e.jsx("tfoot",{children:e.jsxs("tr",{children:[e.jsx("th",{children:"Net Profit"}),e.jsx("th",{children:r.netProfit.formatted}),e.jsx("th",{}),s.map(t=>e.jsx("th",{children:t.netProfit.formatted},t.year))]})})]})})})};export{I as ProfitAndLossReport};
@@ -1 +1 @@
1
- import{j as e,bC as D,bF as a,w as f,cZ as n,G as N,g3 as v,r as d,bn as E,D as T,aX as A,B as w,x as I,bg as O,y as B,dg as M,V as P,X as y,Y as C,Z as F,_ as V,ax as L,a0 as g,aq as U,a$ as q,F as _,ad as k,u as $,c as G,bA as Q,bB as z,bD as o,bE as H,g4 as J}from"./index-B_gzYVvY.js";import{u as S}from"./use-url-query-C4M5DF3n.js";import{P as X}from"./page-layout-DTRGIdR7.js";import{F as Z}from"./funnel-B98DbthO.js";const K=({record:s})=>{const t=N(v,s);return e.jsxs(D,{children:[e.jsx(a,{children:s.description}),e.jsx(a,{children:f(new Date(s.purchaseDate),"dd/MM/yyyy")}),e.jsx(a,{children:s.activationDate?f(new Date(s.activationDate),"dd/MM/yyyy"):void 0}),e.jsx(a,{children:t.originalCost?n(t.originalCost,0):void 0}),e.jsx(a,{children:t.reportYearDelta?n(t.reportYearDelta,0):void 0}),e.jsx(a,{children:n(t.totalDepreciableCosts,0)}),e.jsxs(a,{children:[n(s.statutoryDepreciationRate,0),"%"]}),e.jsx(a,{children:s.claimedDepreciationRate?`${n(s.claimedDepreciationRate,1)}%`:"-"}),e.jsx(a,{children:t.reportYearClaimedDepreciation?n(t.reportYearClaimedDepreciation,0):"-"}),e.jsx(a,{children:t.pastYearsAccumulatedDepreciation?n(t.pastYearsAccumulatedDepreciation,0):"-"}),e.jsx(a,{children:t.totalDepreciation?n(t.totalDepreciation,0):"-"}),e.jsx(a,{children:t.netValue?n(t.netValue,0):"-"})]})};function W(s){return!s||O(s)?null:encodeURIComponent(JSON.stringify(s))}const b="depreciationReportFilters";function ee({filter:s,setFilter:t,close:r}){const m=B({defaultValues:{...s}}),{control:c,handleSubmit:x}=m,{selectableFinancialEntities:u,fetching:l}=M(),j=i=>{t({...i,year:Number(i.year)}),r()};return e.jsx(P,{...m,children:e.jsxs("form",{onSubmit:x(j),className:"space-y-4",children:[e.jsx(y,{name:"year",control:c,rules:{required:"Year is required",validate:i=>{const p=Number(i);return Number.isNaN(p)||p<2e3||p>2100?"Invalid year":!0}},render:({field:i})=>e.jsxs(C,{children:[e.jsx(F,{children:"Year"}),e.jsx(V,{children:e.jsx(L,{...i,hideControls:!0,decimalScale:0})}),e.jsx(g,{})]})}),e.jsx(y,{name:"financialEntityId",defaultValue:s?.financialEntityId,control:c,render:({field:i})=>e.jsxs(C,{children:[e.jsx(F,{children:"Owner"}),e.jsx(U,{...i,data:u,value:i.value??void 0,disabled:l,placeholder:"Select a financial entity",formPart:!0}),e.jsx(g,{})]})}),e.jsx(q,{children:e.jsx(w,{type:"submit",disabled:l,children:"Filter"})})]})})}function ae({filter:s,setFilter:t}){const[r,m]=d.useState(!1),{get:c,set:x}=S();d.useEffect(()=>{const l=W(s),j=c(b);l!==j&&x(b,l)},[s,c,x]);const u=d.useCallback(l=>{E(l,s)||t(l)},[s,t]);return e.jsxs(T,{open:r,onOpenChange:m,children:[e.jsx(A,{asChild:!0,children:e.jsx(w,{variant:"outline",size:"icon",children:e.jsx(Z,{size:20})})}),e.jsx(I,{className:"sm:max-w-[425px]",children:e.jsx(ee,{filter:s,setFilter:u,close:()=>m(!1)})})]})}const R=({data:s,groupName:t})=>{const r=N(v,s);return e.jsxs(D,{className:"font-bold border-b border-black",children:[e.jsx(a,{children:t?"Group Total":"Overall Total"}),e.jsx(a,{colSpan:2,children:t}),e.jsx(a,{children:r.originalCost?n(r.originalCost,0):void 0}),e.jsx(a,{children:r.reportYearDelta?n(r.reportYearDelta,0):void 0}),e.jsx(a,{children:r.totalDepreciableCosts?n(r.totalDepreciableCosts,0):void 0}),e.jsx(a,{}),e.jsx(a,{}),e.jsx(a,{children:r.reportYearClaimedDepreciation?n(r.reportYearClaimedDepreciation,0):void 0}),e.jsx(a,{children:r.pastYearsAccumulatedDepreciation?n(r.pastYearsAccumulatedDepreciation,0):void 0}),e.jsx(a,{children:r.totalDepreciation?n(r.totalDepreciation,0):void 0}),e.jsx(a,{children:r.netValue?n(r.netValue,0):void 0})]})},ne=()=>{const{setFiltersContext:s}=d.useContext(_),{userContext:t}=d.useContext(k),{get:r}=S(),m=d.useMemo(()=>{const i={financialEntityId:t?.context.adminBusinessId,year:new Date().getFullYear()},p=r(b);if(p)try{return JSON.parse(decodeURIComponent(p))}catch(h){console.error("Failed to parse depreciation report filters from URL",h)}return i},[t?.context.adminBusinessId]),[c,x]=d.useState(m),[{data:u,fetching:l}]=$({query:J,variables:{filters:c}});d.useEffect(()=>{s(e.jsx("div",{className:"flex flex-row gap-x-5",children:e.jsx(ae,{filter:c,setFilter:x})}))},[c,s,x]);const j=d.useMemo(()=>`Depreciation Report for ${c.year}`,[c.year]);return e.jsx(X,{title:"Depreciation Report",description:j,children:l?e.jsx(G,{}):e.jsxs(Q,{children:[e.jsxs(z,{children:[e.jsxs(D,{className:"font-bold text-xl",children:[e.jsx(o,{colSpan:6,className:"text-center border-x",children:"List of Assets and Costs"}),e.jsx(o,{colSpan:5,className:"text-center border-x",children:"Depreciation"}),e.jsx(o,{className:"text-center border-x",children:"Remaining"})]}),e.jsxs(D,{className:"border-b border-black",children:[e.jsx(o,{className:"whitespace-normal",children:"Assets List and Descriptions"}),e.jsx(o,{className:"whitespace-normal",children:"Date of Purchase"}),e.jsx(o,{className:"whitespace-normal",children:"Activation Date"}),e.jsx(o,{className:"whitespace-normal",children:"Original Cost"}),e.jsx(o,{className:"whitespace-normal",children:"Changes During the Year"}),e.jsx(o,{className:"whitespace-normal",children:"Total Depreciable Assets"}),e.jsx(o,{className:"whitespace-normal",children:"Statutory Depreciation Rate"}),e.jsx(o,{className:"whitespace-normal",children:"Claimed Depreciation Rate"}),e.jsx(o,{className:"whitespace-normal",children:"Depreciation Claimed This Year"}),e.jsx(o,{className:"whitespace-normal",children:"Previous Tax Years Accumulated Depreciation"}),e.jsx(o,{className:"whitespace-normal",children:"Total Depreciation"}),e.jsx(o,{className:"whitespace-normal",children:"Net Book Value"})]})]}),e.jsx(H,{children:u?.depreciationReport&&e.jsxs(e.Fragment,{children:[u.depreciationReport.categories.map((i,p)=>e.jsxs(d.Fragment,{children:[e.jsxs(D,{className:"font-bold",children:[e.jsx(a,{children:`Category ${p+1}`}),e.jsx(a,{colSpan:2,children:i.category.name}),e.jsx(a,{colSpan:3}),e.jsxs(a,{children:[n(i.category.percentage,0),"%"]}),e.jsx(a,{colSpan:5})]}),i.records.sort((h,Y)=>h.purchaseDate.localeCompare(Y.purchaseDate)).map(h=>e.jsx(K,{record:h},h.id)),e.jsx(R,{data:i.summary,groupName:i.category.name})]},i.id)),e.jsx(R,{data:u.depreciationReport.summary})]})})]})})};export{ne as DepreciationReport};
1
+ import{j as e,bC as D,bF as a,w as f,cZ as n,G as N,g3 as v,r as d,bn as E,D as T,aX as A,B as w,x as I,bg as O,y as B,dg as M,V as P,X as y,Y as C,Z as F,_ as V,ax as L,a0 as g,aq as U,a$ as q,F as _,ad as k,u as $,c as G,bA as Q,bB as z,bD as o,bE as H,g4 as J}from"./index-DL96FIEg.js";import{u as S}from"./use-url-query-Dwk3Z7IG.js";import{P as X}from"./page-layout-UeCQVB1c.js";import{F as Z}from"./funnel-rqI973_z.js";const K=({record:s})=>{const t=N(v,s);return e.jsxs(D,{children:[e.jsx(a,{children:s.description}),e.jsx(a,{children:f(new Date(s.purchaseDate),"dd/MM/yyyy")}),e.jsx(a,{children:s.activationDate?f(new Date(s.activationDate),"dd/MM/yyyy"):void 0}),e.jsx(a,{children:t.originalCost?n(t.originalCost,0):void 0}),e.jsx(a,{children:t.reportYearDelta?n(t.reportYearDelta,0):void 0}),e.jsx(a,{children:n(t.totalDepreciableCosts,0)}),e.jsxs(a,{children:[n(s.statutoryDepreciationRate,0),"%"]}),e.jsx(a,{children:s.claimedDepreciationRate?`${n(s.claimedDepreciationRate,1)}%`:"-"}),e.jsx(a,{children:t.reportYearClaimedDepreciation?n(t.reportYearClaimedDepreciation,0):"-"}),e.jsx(a,{children:t.pastYearsAccumulatedDepreciation?n(t.pastYearsAccumulatedDepreciation,0):"-"}),e.jsx(a,{children:t.totalDepreciation?n(t.totalDepreciation,0):"-"}),e.jsx(a,{children:t.netValue?n(t.netValue,0):"-"})]})};function W(s){return!s||O(s)?null:encodeURIComponent(JSON.stringify(s))}const b="depreciationReportFilters";function ee({filter:s,setFilter:t,close:r}){const m=B({defaultValues:{...s}}),{control:c,handleSubmit:x}=m,{selectableFinancialEntities:u,fetching:l}=M(),j=i=>{t({...i,year:Number(i.year)}),r()};return e.jsx(P,{...m,children:e.jsxs("form",{onSubmit:x(j),className:"space-y-4",children:[e.jsx(y,{name:"year",control:c,rules:{required:"Year is required",validate:i=>{const p=Number(i);return Number.isNaN(p)||p<2e3||p>2100?"Invalid year":!0}},render:({field:i})=>e.jsxs(C,{children:[e.jsx(F,{children:"Year"}),e.jsx(V,{children:e.jsx(L,{...i,hideControls:!0,decimalScale:0})}),e.jsx(g,{})]})}),e.jsx(y,{name:"financialEntityId",defaultValue:s?.financialEntityId,control:c,render:({field:i})=>e.jsxs(C,{children:[e.jsx(F,{children:"Owner"}),e.jsx(U,{...i,data:u,value:i.value??void 0,disabled:l,placeholder:"Select a financial entity",formPart:!0}),e.jsx(g,{})]})}),e.jsx(q,{children:e.jsx(w,{type:"submit",disabled:l,children:"Filter"})})]})})}function ae({filter:s,setFilter:t}){const[r,m]=d.useState(!1),{get:c,set:x}=S();d.useEffect(()=>{const l=W(s),j=c(b);l!==j&&x(b,l)},[s,c,x]);const u=d.useCallback(l=>{E(l,s)||t(l)},[s,t]);return e.jsxs(T,{open:r,onOpenChange:m,children:[e.jsx(A,{asChild:!0,children:e.jsx(w,{variant:"outline",size:"icon",children:e.jsx(Z,{size:20})})}),e.jsx(I,{className:"sm:max-w-[425px]",children:e.jsx(ee,{filter:s,setFilter:u,close:()=>m(!1)})})]})}const R=({data:s,groupName:t})=>{const r=N(v,s);return e.jsxs(D,{className:"font-bold border-b border-black",children:[e.jsx(a,{children:t?"Group Total":"Overall Total"}),e.jsx(a,{colSpan:2,children:t}),e.jsx(a,{children:r.originalCost?n(r.originalCost,0):void 0}),e.jsx(a,{children:r.reportYearDelta?n(r.reportYearDelta,0):void 0}),e.jsx(a,{children:r.totalDepreciableCosts?n(r.totalDepreciableCosts,0):void 0}),e.jsx(a,{}),e.jsx(a,{}),e.jsx(a,{children:r.reportYearClaimedDepreciation?n(r.reportYearClaimedDepreciation,0):void 0}),e.jsx(a,{children:r.pastYearsAccumulatedDepreciation?n(r.pastYearsAccumulatedDepreciation,0):void 0}),e.jsx(a,{children:r.totalDepreciation?n(r.totalDepreciation,0):void 0}),e.jsx(a,{children:r.netValue?n(r.netValue,0):void 0})]})},ne=()=>{const{setFiltersContext:s}=d.useContext(_),{userContext:t}=d.useContext(k),{get:r}=S(),m=d.useMemo(()=>{const i={financialEntityId:t?.context.adminBusinessId,year:new Date().getFullYear()},p=r(b);if(p)try{return JSON.parse(decodeURIComponent(p))}catch(h){console.error("Failed to parse depreciation report filters from URL",h)}return i},[t?.context.adminBusinessId]),[c,x]=d.useState(m),[{data:u,fetching:l}]=$({query:J,variables:{filters:c}});d.useEffect(()=>{s(e.jsx("div",{className:"flex flex-row gap-x-5",children:e.jsx(ae,{filter:c,setFilter:x})}))},[c,s,x]);const j=d.useMemo(()=>`Depreciation Report for ${c.year}`,[c.year]);return e.jsx(X,{title:"Depreciation Report",description:j,children:l?e.jsx(G,{}):e.jsxs(Q,{children:[e.jsxs(z,{children:[e.jsxs(D,{className:"font-bold text-xl",children:[e.jsx(o,{colSpan:6,className:"text-center border-x",children:"List of Assets and Costs"}),e.jsx(o,{colSpan:5,className:"text-center border-x",children:"Depreciation"}),e.jsx(o,{className:"text-center border-x",children:"Remaining"})]}),e.jsxs(D,{className:"border-b border-black",children:[e.jsx(o,{className:"whitespace-normal",children:"Assets List and Descriptions"}),e.jsx(o,{className:"whitespace-normal",children:"Date of Purchase"}),e.jsx(o,{className:"whitespace-normal",children:"Activation Date"}),e.jsx(o,{className:"whitespace-normal",children:"Original Cost"}),e.jsx(o,{className:"whitespace-normal",children:"Changes During the Year"}),e.jsx(o,{className:"whitespace-normal",children:"Total Depreciable Assets"}),e.jsx(o,{className:"whitespace-normal",children:"Statutory Depreciation Rate"}),e.jsx(o,{className:"whitespace-normal",children:"Claimed Depreciation Rate"}),e.jsx(o,{className:"whitespace-normal",children:"Depreciation Claimed This Year"}),e.jsx(o,{className:"whitespace-normal",children:"Previous Tax Years Accumulated Depreciation"}),e.jsx(o,{className:"whitespace-normal",children:"Total Depreciation"}),e.jsx(o,{className:"whitespace-normal",children:"Net Book Value"})]})]}),e.jsx(H,{children:u?.depreciationReport&&e.jsxs(e.Fragment,{children:[u.depreciationReport.categories.map((i,p)=>e.jsxs(d.Fragment,{children:[e.jsxs(D,{className:"font-bold",children:[e.jsx(a,{children:`Category ${p+1}`}),e.jsx(a,{colSpan:2,children:i.category.name}),e.jsx(a,{colSpan:3}),e.jsxs(a,{children:[n(i.category.percentage,0),"%"]}),e.jsx(a,{colSpan:5})]}),i.records.sort((h,Y)=>h.purchaseDate.localeCompare(Y.purchaseDate)).map(h=>e.jsx(K,{record:h},h.id)),e.jsx(R,{data:i.summary,groupName:i.category.name})]},i.id)),e.jsx(R,{data:u.depreciationReport.summary})]})})]})})};export{ne as DepreciationReport};
@@ -1 +1 @@
1
- import{j as n,r as x,B as g,G as h,gm as j,a as v,F as D,u as R,L as E,bh as y,dL as T,T as u,gn as w}from"./index-B_gzYVvY.js";import{d as C}from"./graphql-document-dedupe-fragments-ByT8-wlV.js";import{P as A}from"./page-layout-DTRGIdR7.js";import{P as b}from"./modal-BF-8kNcF.js";import{Y as F}from"./YearPickerInput-C3FAWyW8.js";import{F as I}from"./funnel-B98DbthO.js";import{T as N}from"./Table-BFvxFsm0.js";const i=({originalAmount:a,diffAmount:t})=>!t||a===t?n.jsx("td",{children:a}):n.jsx("td",{children:n.jsxs("div",{className:"flex flex-col",children:[n.jsx("p",{className:t?"line-through":"",children:a}),t&&n.jsx("div",{className:"border-2 border-yellow-500 rounded-md",children:t})]})});function P({years:a,setYears:t}){const[r,l]=x.useState(!1);return n.jsxs(n.Fragment,{children:[n.jsx(b,{opened:r,onClose:()=>l(!1),withCloseButton:!0,content:n.jsx(F,{type:"multiple",label:"Pick years",value:a?.map(d=>new Date(d,0,1)),onChange:d=>t(d.map(p=>p.getFullYear())),popoverProps:{withinPortal:!0},minDate:new Date(2010,0,1),maxDate:new Date})}),n.jsx(g,{variant:"outline",size:"icon",className:"size-7.5",onClick:()=>l(!0),children:n.jsx(I,{className:"size-5"})})]})}const f=({originalRuleData:a,diffRuleData:t})=>{const r=h(j,a),l=h(j,t),d=l?.isCompliant!==r.isCompliant||l?.percentage.formatted!==r.percentage.formatted;return!l||!d?n.jsx("td",{className:r.isCompliant?"text-green-500":"text-red-500",children:r.percentage.formatted}):n.jsx("td",{className:r.isCompliant?"text-green-500":"text-red-500",children:n.jsxs("div",{className:"flex flex-col",children:[n.jsx("p",{className:"line-through ".concat(r.isCompliant?"text-green-500":"text-red-500"),children:r.percentage.formatted}),l&&n.jsx("div",{className:"border-2 border-yellow-500 rounded-md ".concat(l.isCompliant?"text-green-500":"text-red-500"),children:l.percentage.formatted})]})})},c=(a,t)=>T(t).format(a);function m(a,t){if(a.length!==0)return c(a.reduce((r,l)=>r+l,0),t)}const U=()=>{const{year:a}=v(),{setFiltersContext:t}=x.useContext(D),[r,l]=x.useState(a?[Number(a)]:[new Date().getFullYear()]),[{data:d,fetching:p}]=R({query:C(w),variables:{years:r}});x.useEffect(()=>{t(n.jsx("div",{className:"flex flex-row gap-2",children:n.jsx(P,{years:r,setYears:l})}))},[r,p,t]);const s=d?.corporateTaxRulingComplianceReport??[];return n.jsx(A,{title:"Corporate Tax Ruling Compliance Report",children:p?n.jsx(E,{className:"h-10 w-10 animate-spin mr-2 self-center"}):n.jsx("div",{className:"flex flex-col gap-4",children:s&&n.jsxs(N,{highlightOnHover:!0,fontSize:"md",children:[n.jsx("thead",{children:n.jsxs("tr",{children:[n.jsx("th",{}),r.map(e=>n.jsx("th",{children:n.jsx(y,{inline:!0,size:12,processing:!s.find(o=>o.year===e)?.differences,disabled:!!s.find(o=>o.year===e)?.differences,color:"orange",zIndex:"auto",children:e})},e)),n.jsx("th",{children:"Summary"},"sum")]})}),n.jsxs("tbody",{children:[n.jsxs("tr",{children:[n.jsx("td",{children:"Total Income"}),s.map(e=>n.jsx(i,{originalAmount:e.totalIncome.formatted,diffAmount:e.differences?.totalIncome?.formatted??void 0},e.year)),n.jsx(i,{originalAmount:c(s.map(e=>e.totalIncome.raw).reduce((e,o)=>e+o,0),s[0].totalIncome.currency),diffAmount:m(s.map(e=>e.differences?.totalIncome?.raw??e.totalIncome.raw).filter(e=>!!e),s[0].totalIncome.currency)},"sum")]}),n.jsxs("tr",{children:[n.jsx("td",{children:"Total R&D Expensess"}),s.map(e=>n.jsx(i,{originalAmount:e.researchAndDevelopmentExpenses.formatted,diffAmount:e.differences?.researchAndDevelopmentExpenses?.formatted??void 0},e.year)),n.jsx(i,{originalAmount:c(s.map(e=>e.researchAndDevelopmentExpenses.raw).reduce((e,o)=>e+o,0),s[0].researchAndDevelopmentExpenses.currency),diffAmount:m(s.map(e=>e.differences?.researchAndDevelopmentExpenses?.raw??e.researchAndDevelopmentExpenses.raw).filter(e=>!!e),s[0].researchAndDevelopmentExpenses.currency)},"sum")]}),n.jsxs("tr",{children:[n.jsx("th",{children:n.jsx(u,{multiline:!0,width:220,transitionProps:{duration:200},label:s[0]?.rndRelativeToIncome.rule,children:n.jsx("p",{children:"R&D Expenses out of Income"})})}),s.map(e=>n.jsx(f,{originalRuleData:e.rndRelativeToIncome,diffRuleData:e.differences?.rndRelativeToIncome??void 0},e.year)),n.jsx("td",{})]}),n.jsxs("tr",{children:[n.jsx("td",{children:"Local Development Expenses"}),s.map(e=>n.jsx(i,{originalAmount:e.localDevelopmentExpenses.formatted,diffAmount:e.differences?.localDevelopmentExpenses?.formatted??void 0},e.year)),n.jsx(i,{originalAmount:c(s.map(e=>e.localDevelopmentExpenses.raw).reduce((e,o)=>e+o,0),s[0].localDevelopmentExpenses.currency),diffAmount:m(s.map(e=>e.differences?.localDevelopmentExpenses?.raw??e.localDevelopmentExpenses.raw).filter(e=>!!e),s[0].localDevelopmentExpenses.currency)},"sum")]}),n.jsxs("tr",{children:[n.jsx("th",{children:n.jsx(u,{multiline:!0,width:220,transitionProps:{duration:200},label:s[0]?.localDevelopmentRelativeToRnd.rule,children:n.jsx("p",{children:"Local Development out of R&D"})})}),s.map(e=>n.jsx(f,{originalRuleData:e.localDevelopmentRelativeToRnd,diffRuleData:e.differences?.localDevelopmentRelativeToRnd??void 0},e.year)),n.jsx("td",{})]}),n.jsxs("tr",{children:[n.jsx("td",{children:"Foreign Development Expenses"}),s.map(e=>n.jsx(i,{originalAmount:e.foreignDevelopmentExpenses.formatted,diffAmount:e.differences?.foreignDevelopmentExpenses?.formatted??void 0},e.year)),n.jsx(i,{originalAmount:c(s.map(e=>e.foreignDevelopmentExpenses.raw).reduce((e,o)=>e+o,0),s[0].foreignDevelopmentExpenses.currency),diffAmount:m(s.map(e=>e.differences?.foreignDevelopmentExpenses?.raw??e.foreignDevelopmentExpenses.raw).filter(e=>!!e),s[0].foreignDevelopmentExpenses.currency)},"sum")]}),n.jsxs("tr",{children:[n.jsx("th",{children:n.jsx(u,{multiline:!0,width:220,transitionProps:{duration:200},label:s[0]?.foreignDevelopmentRelativeToRnd.rule,children:n.jsx("p",{children:"Foreign Development out of R&D"})})}),s.map(e=>n.jsx(f,{originalRuleData:e.foreignDevelopmentRelativeToRnd,diffRuleData:e.differences?.foreignDevelopmentRelativeToRnd??void 0},e.year)),n.jsx("td",{})]}),n.jsxs("tr",{children:[n.jsx("td",{children:"R&D Business Trips Expenses"}),s.map(e=>n.jsx(i,{originalAmount:e.businessTripRndExpenses.formatted,diffAmount:e.differences?.businessTripRndExpenses?.formatted??void 0},e.year)),n.jsx(i,{originalAmount:c(s.map(e=>e.businessTripRndExpenses.raw).reduce((e,o)=>e+o,0),s[0].businessTripRndExpenses.currency),diffAmount:m(s.map(e=>e.differences?.businessTripRndExpenses?.raw??e.businessTripRndExpenses.raw).filter(e=>!!e),s[0].businessTripRndExpenses.currency)},"sum")]})]})]})})})};export{U as CorporateTaxRulingComplianceReport};
1
+ import{j as n,r as x,B as g,G as h,gm as j,a as v,F as D,u as R,L as E,bh as y,dL as T,T as u,gn as w}from"./index-DL96FIEg.js";import{d as C}from"./graphql-document-dedupe-fragments-ByT8-wlV.js";import{P as A}from"./page-layout-UeCQVB1c.js";import{P as b}from"./modal-CcO9VM0k.js";import{Y as F}from"./YearPickerInput-DMYgFyy1.js";import{F as I}from"./funnel-rqI973_z.js";import{T as N}from"./Table-C6kFDK4t.js";const i=({originalAmount:a,diffAmount:t})=>!t||a===t?n.jsx("td",{children:a}):n.jsx("td",{children:n.jsxs("div",{className:"flex flex-col",children:[n.jsx("p",{className:t?"line-through":"",children:a}),t&&n.jsx("div",{className:"border-2 border-yellow-500 rounded-md",children:t})]})});function P({years:a,setYears:t}){const[r,l]=x.useState(!1);return n.jsxs(n.Fragment,{children:[n.jsx(b,{opened:r,onClose:()=>l(!1),withCloseButton:!0,content:n.jsx(F,{type:"multiple",label:"Pick years",value:a?.map(d=>new Date(d,0,1)),onChange:d=>t(d.map(p=>p.getFullYear())),popoverProps:{withinPortal:!0},minDate:new Date(2010,0,1),maxDate:new Date})}),n.jsx(g,{variant:"outline",size:"icon",className:"size-7.5",onClick:()=>l(!0),children:n.jsx(I,{className:"size-5"})})]})}const f=({originalRuleData:a,diffRuleData:t})=>{const r=h(j,a),l=h(j,t),d=l?.isCompliant!==r.isCompliant||l?.percentage.formatted!==r.percentage.formatted;return!l||!d?n.jsx("td",{className:r.isCompliant?"text-green-500":"text-red-500",children:r.percentage.formatted}):n.jsx("td",{className:r.isCompliant?"text-green-500":"text-red-500",children:n.jsxs("div",{className:"flex flex-col",children:[n.jsx("p",{className:"line-through ".concat(r.isCompliant?"text-green-500":"text-red-500"),children:r.percentage.formatted}),l&&n.jsx("div",{className:"border-2 border-yellow-500 rounded-md ".concat(l.isCompliant?"text-green-500":"text-red-500"),children:l.percentage.formatted})]})})},c=(a,t)=>T(t).format(a);function m(a,t){if(a.length!==0)return c(a.reduce((r,l)=>r+l,0),t)}const U=()=>{const{year:a}=v(),{setFiltersContext:t}=x.useContext(D),[r,l]=x.useState(a?[Number(a)]:[new Date().getFullYear()]),[{data:d,fetching:p}]=R({query:C(w),variables:{years:r}});x.useEffect(()=>{t(n.jsx("div",{className:"flex flex-row gap-2",children:n.jsx(P,{years:r,setYears:l})}))},[r,p,t]);const s=d?.corporateTaxRulingComplianceReport??[];return n.jsx(A,{title:"Corporate Tax Ruling Compliance Report",children:p?n.jsx(E,{className:"h-10 w-10 animate-spin mr-2 self-center"}):n.jsx("div",{className:"flex flex-col gap-4",children:s&&n.jsxs(N,{highlightOnHover:!0,fontSize:"md",children:[n.jsx("thead",{children:n.jsxs("tr",{children:[n.jsx("th",{}),r.map(e=>n.jsx("th",{children:n.jsx(y,{inline:!0,size:12,processing:!s.find(o=>o.year===e)?.differences,disabled:!!s.find(o=>o.year===e)?.differences,color:"orange",zIndex:"auto",children:e})},e)),n.jsx("th",{children:"Summary"},"sum")]})}),n.jsxs("tbody",{children:[n.jsxs("tr",{children:[n.jsx("td",{children:"Total Income"}),s.map(e=>n.jsx(i,{originalAmount:e.totalIncome.formatted,diffAmount:e.differences?.totalIncome?.formatted??void 0},e.year)),n.jsx(i,{originalAmount:c(s.map(e=>e.totalIncome.raw).reduce((e,o)=>e+o,0),s[0].totalIncome.currency),diffAmount:m(s.map(e=>e.differences?.totalIncome?.raw??e.totalIncome.raw).filter(e=>!!e),s[0].totalIncome.currency)},"sum")]}),n.jsxs("tr",{children:[n.jsx("td",{children:"Total R&D Expensess"}),s.map(e=>n.jsx(i,{originalAmount:e.researchAndDevelopmentExpenses.formatted,diffAmount:e.differences?.researchAndDevelopmentExpenses?.formatted??void 0},e.year)),n.jsx(i,{originalAmount:c(s.map(e=>e.researchAndDevelopmentExpenses.raw).reduce((e,o)=>e+o,0),s[0].researchAndDevelopmentExpenses.currency),diffAmount:m(s.map(e=>e.differences?.researchAndDevelopmentExpenses?.raw??e.researchAndDevelopmentExpenses.raw).filter(e=>!!e),s[0].researchAndDevelopmentExpenses.currency)},"sum")]}),n.jsxs("tr",{children:[n.jsx("th",{children:n.jsx(u,{multiline:!0,width:220,transitionProps:{duration:200},label:s[0]?.rndRelativeToIncome.rule,children:n.jsx("p",{children:"R&D Expenses out of Income"})})}),s.map(e=>n.jsx(f,{originalRuleData:e.rndRelativeToIncome,diffRuleData:e.differences?.rndRelativeToIncome??void 0},e.year)),n.jsx("td",{})]}),n.jsxs("tr",{children:[n.jsx("td",{children:"Local Development Expenses"}),s.map(e=>n.jsx(i,{originalAmount:e.localDevelopmentExpenses.formatted,diffAmount:e.differences?.localDevelopmentExpenses?.formatted??void 0},e.year)),n.jsx(i,{originalAmount:c(s.map(e=>e.localDevelopmentExpenses.raw).reduce((e,o)=>e+o,0),s[0].localDevelopmentExpenses.currency),diffAmount:m(s.map(e=>e.differences?.localDevelopmentExpenses?.raw??e.localDevelopmentExpenses.raw).filter(e=>!!e),s[0].localDevelopmentExpenses.currency)},"sum")]}),n.jsxs("tr",{children:[n.jsx("th",{children:n.jsx(u,{multiline:!0,width:220,transitionProps:{duration:200},label:s[0]?.localDevelopmentRelativeToRnd.rule,children:n.jsx("p",{children:"Local Development out of R&D"})})}),s.map(e=>n.jsx(f,{originalRuleData:e.localDevelopmentRelativeToRnd,diffRuleData:e.differences?.localDevelopmentRelativeToRnd??void 0},e.year)),n.jsx("td",{})]}),n.jsxs("tr",{children:[n.jsx("td",{children:"Foreign Development Expenses"}),s.map(e=>n.jsx(i,{originalAmount:e.foreignDevelopmentExpenses.formatted,diffAmount:e.differences?.foreignDevelopmentExpenses?.formatted??void 0},e.year)),n.jsx(i,{originalAmount:c(s.map(e=>e.foreignDevelopmentExpenses.raw).reduce((e,o)=>e+o,0),s[0].foreignDevelopmentExpenses.currency),diffAmount:m(s.map(e=>e.differences?.foreignDevelopmentExpenses?.raw??e.foreignDevelopmentExpenses.raw).filter(e=>!!e),s[0].foreignDevelopmentExpenses.currency)},"sum")]}),n.jsxs("tr",{children:[n.jsx("th",{children:n.jsx(u,{multiline:!0,width:220,transitionProps:{duration:200},label:s[0]?.foreignDevelopmentRelativeToRnd.rule,children:n.jsx("p",{children:"Foreign Development out of R&D"})})}),s.map(e=>n.jsx(f,{originalRuleData:e.foreignDevelopmentRelativeToRnd,diffRuleData:e.differences?.foreignDevelopmentRelativeToRnd??void 0},e.year)),n.jsx("td",{})]}),n.jsxs("tr",{children:[n.jsx("td",{children:"R&D Business Trips Expenses"}),s.map(e=>n.jsx(i,{originalAmount:e.businessTripRndExpenses.formatted,diffAmount:e.differences?.businessTripRndExpenses?.formatted??void 0},e.year)),n.jsx(i,{originalAmount:c(s.map(e=>e.businessTripRndExpenses.raw).reduce((e,o)=>e+o,0),s[0].businessTripRndExpenses.currency),diffAmount:m(s.map(e=>e.differences?.businessTripRndExpenses?.raw??e.businessTripRndExpenses.raw).filter(e=>!!e),s[0].businessTripRndExpenses.currency)},"sum")]})]})]})})})};export{U as CorporateTaxRulingComplianceReport};
@@ -1 +1 @@
1
- import{g as T,hC as N,r as u,t as l,i as f,y,G as b,j as e,V as C,ee as D,X as F,Y as $,Z as w,_ as k,I as j,a0 as E,hD as v,hE as A,a8 as S,l as z,T as L,B as p,bY as M,n as O,hF as P,hG as B,F as q,u as _,hH as U,L as G,cf as V,hI as R}from"./index-B_gzYVvY.js";import{P as Y}from"./page-layout-DTRGIdR7.js";import{L as H}from"./list-plus-C_Jn2eXi.js";const Q="updateTag",X=()=>{const[{fetching:c},r]=T(N),i=u.useCallback(async t=>{const a=`Error updating tag ID [${t.tagId}]`,s=`${Q}-${t.tagId}`;l.loading("Updating Tag...",{id:s});try{const n=await r(t),d=f(n,a,s,"updateTag");if(d)return l.success("Success",{id:s,description:"Tag updated"}),d.updateTag}catch(n){console.error(`${a}: ${n}`),l.error("Error",{id:s,description:a,duration:1e5,closeButton:!0})}return!1},[r]);return{fetching:c,updateTag:i}},Z=({onDone:c,data:r,close:i})=>{const{updateTag:t,fetching:a}=X(),s=b(A,r),n=y({defaultValues:{name:s.name,parentId:s.parent?.id}}),{control:d,handleSubmit:m,formState:{dirtyFields:h}}=n,x=o=>{const g=S(o,h);i(),g&&Object.keys(g).length>0&&t({tagId:s.id,fields:g}).then(()=>c?.())};return e.jsx(C,{...n,children:e.jsxs("form",{onSubmit:m(x),children:[e.jsx("div",{className:"flex-row px-10 h-max justify-start block",children:e.jsxs(D,{cols:3,children:[e.jsx(F,{name:"name",control:d,defaultValue:s.name,rules:{required:"Required",minLength:{value:2,message:"Must be at least 2 characters"}},render:({field:o})=>e.jsxs($,{children:[e.jsx(w,{children:"Name"}),e.jsx(k,{children:e.jsx(j,{...o,value:o.value??void 0})}),e.jsx(E,{})]})}),e.jsx(v,{formManager:n,tagsPath:"parentId",label:"Parent Tag"})]})}),e.jsxs("div",{className:"mt-10 mb-5 flex justify-center gap-5",children:[e.jsx("button",{type:"submit",onClick:()=>m(x),className:"mt-8 text-white bg-indigo-500 border-0 py-2 px-8 focus:outline-hidden hover:bg-indigo-600 rounded-sm text-lg",disabled:a||Object.keys(h).length===0,children:"Accept"}),e.jsx("button",{type:"button",className:"mt-8 text-white bg-rose-500 border-0 py-2 px-8 focus:outline-hidden hover:bg-rose-600 rounded-sm text-lg",onClick:i,children:"Cancel"})]})]})})},J=({onDone:c,data:r})=>{const[i,{open:t,close:a}]=z(!1);function s(){a(),c?.()}return e.jsxs(e.Fragment,{children:[e.jsx(L,{label:"Edit Tag",children:e.jsx(p,{variant:"ghost",size:"icon",className:"size-7.5",onClick:t,children:e.jsx(M,{className:"size-5"})})}),e.jsx(O,{centered:!0,opened:i,onClose:a,title:"Insert Business Trip",children:e.jsx(Z,{close:a,onDone:s,data:r})})]})},K="addTag",W=()=>{const[{fetching:c},r]=T(P),i=u.useCallback(async t=>{const a=`Error adding new tag [${t.tagName}]`,s=`${K}-${t.tagName}`;l.loading("Adding tag",{id:s});try{const n=await r(t);f(n,a,s)&&l.success("Success",{id:s,description:`"${t.tagName}" tag was successfully added`})}catch(n){console.error(`${a}: ${n}`),l.error("Error",{id:s,description:a,duration:1e5,closeButton:!0})}},[r]);return{fetching:c,addTag:i}},ee="deleteTag",se=()=>{const[{fetching:c},r]=T(B),i=u.useCallback(async t=>{const a=`Error deleting new tag [${t.name}]`,s=`${ee}-${t.tagId}`;l.loading(`Deleting tag [${t.name}]`,{id:s});try{const n=await r(t);f(n,a,s)&&l.success("Tag Deleted",{id:s,description:`[${t.name}] tag was successfully removed`})}catch(n){console.error(`${a}: ${n}`),l.error("Error",{id:s,description:a,duration:1e5,closeButton:!0})}},[r]);return{fetching:c,deleteTag:i}},oe=()=>{const{setFiltersContext:c}=u.useContext(q),[r,i]=u.useState(""),[{data:t,fetching:a},s]=_({query:R}),{addTag:n}=W(),{deleteTag:d}=se();u.useEffect(()=>{c(null)},[c]);const m=U(t?.allTags??[]),h=u.useCallback(o=>{o.length>2&&n({tagName:o}).then(()=>{s()})},[n,s]),x=u.useCallback((o,g)=>{d({tagId:o,name:g}).then(()=>{s()})},[d,s]);return e.jsx(Y,{title:"Tags",description:"Manage tags for your bookmarks.",children:a?e.jsx(G,{className:"h-10 w-10 animate-spin mr-2 self-center"}):e.jsxs("div",{className:"h-full flex flex-col overflow-hidden",children:[m?.map(o=>e.jsxs("div",{className:"flex items-center gap-2 text-gray-600 mb-2",children:[e.jsxs("div",{className:"w-full mt-1 relative rounded-md shadow-xs",children:[o.namePath?.map((g,I)=>e.jsx("span",{className:"ms-2"},I)),o.name]}),e.jsx(J,{data:o}),e.jsx(p,{variant:"ghost",size:"icon",className:"size-7.5",onClick:()=>x(o.id,o.name),children:e.jsx(V,{className:"size-5"})})]},o.id)),e.jsxs("div",{className:"flex justify-start items-center gap-2 text-gray-600 mb-2",children:[e.jsx(j,{className:"w-80",value:r,onChange:o=>i(o.currentTarget.value),placeholder:"Add new tag",required:!0}),e.jsx(p,{variant:"ghost",size:"icon",className:"size-7.5",disabled:r.length<2,onClick:()=>h(r),children:e.jsx(H,{className:"size-5"})})]})]})})};export{oe as TagsManager};
1
+ import{g as T,hC as N,r as u,t as l,i as f,y,G as b,j as e,V as C,ee as D,X as F,Y as $,Z as w,_ as k,I as j,a0 as E,hD as v,hE as A,a8 as S,l as z,T as L,B as p,bY as M,n as O,hF as P,hG as B,F as q,u as _,hH as U,L as G,cf as V,hI as R}from"./index-DL96FIEg.js";import{P as Y}from"./page-layout-UeCQVB1c.js";import{L as H}from"./list-plus-oBV3pFTT.js";const Q="updateTag",X=()=>{const[{fetching:c},r]=T(N),i=u.useCallback(async t=>{const a=`Error updating tag ID [${t.tagId}]`,s=`${Q}-${t.tagId}`;l.loading("Updating Tag...",{id:s});try{const n=await r(t),d=f(n,a,s,"updateTag");if(d)return l.success("Success",{id:s,description:"Tag updated"}),d.updateTag}catch(n){console.error(`${a}: ${n}`),l.error("Error",{id:s,description:a,duration:1e5,closeButton:!0})}return!1},[r]);return{fetching:c,updateTag:i}},Z=({onDone:c,data:r,close:i})=>{const{updateTag:t,fetching:a}=X(),s=b(A,r),n=y({defaultValues:{name:s.name,parentId:s.parent?.id}}),{control:d,handleSubmit:m,formState:{dirtyFields:h}}=n,x=o=>{const g=S(o,h);i(),g&&Object.keys(g).length>0&&t({tagId:s.id,fields:g}).then(()=>c?.())};return e.jsx(C,{...n,children:e.jsxs("form",{onSubmit:m(x),children:[e.jsx("div",{className:"flex-row px-10 h-max justify-start block",children:e.jsxs(D,{cols:3,children:[e.jsx(F,{name:"name",control:d,defaultValue:s.name,rules:{required:"Required",minLength:{value:2,message:"Must be at least 2 characters"}},render:({field:o})=>e.jsxs($,{children:[e.jsx(w,{children:"Name"}),e.jsx(k,{children:e.jsx(j,{...o,value:o.value??void 0})}),e.jsx(E,{})]})}),e.jsx(v,{formManager:n,tagsPath:"parentId",label:"Parent Tag"})]})}),e.jsxs("div",{className:"mt-10 mb-5 flex justify-center gap-5",children:[e.jsx("button",{type:"submit",onClick:()=>m(x),className:"mt-8 text-white bg-indigo-500 border-0 py-2 px-8 focus:outline-hidden hover:bg-indigo-600 rounded-sm text-lg",disabled:a||Object.keys(h).length===0,children:"Accept"}),e.jsx("button",{type:"button",className:"mt-8 text-white bg-rose-500 border-0 py-2 px-8 focus:outline-hidden hover:bg-rose-600 rounded-sm text-lg",onClick:i,children:"Cancel"})]})]})})},J=({onDone:c,data:r})=>{const[i,{open:t,close:a}]=z(!1);function s(){a(),c?.()}return e.jsxs(e.Fragment,{children:[e.jsx(L,{label:"Edit Tag",children:e.jsx(p,{variant:"ghost",size:"icon",className:"size-7.5",onClick:t,children:e.jsx(M,{className:"size-5"})})}),e.jsx(O,{centered:!0,opened:i,onClose:a,title:"Insert Business Trip",children:e.jsx(Z,{close:a,onDone:s,data:r})})]})},K="addTag",W=()=>{const[{fetching:c},r]=T(P),i=u.useCallback(async t=>{const a=`Error adding new tag [${t.tagName}]`,s=`${K}-${t.tagName}`;l.loading("Adding tag",{id:s});try{const n=await r(t);f(n,a,s)&&l.success("Success",{id:s,description:`"${t.tagName}" tag was successfully added`})}catch(n){console.error(`${a}: ${n}`),l.error("Error",{id:s,description:a,duration:1e5,closeButton:!0})}},[r]);return{fetching:c,addTag:i}},ee="deleteTag",se=()=>{const[{fetching:c},r]=T(B),i=u.useCallback(async t=>{const a=`Error deleting new tag [${t.name}]`,s=`${ee}-${t.tagId}`;l.loading(`Deleting tag [${t.name}]`,{id:s});try{const n=await r(t);f(n,a,s)&&l.success("Tag Deleted",{id:s,description:`[${t.name}] tag was successfully removed`})}catch(n){console.error(`${a}: ${n}`),l.error("Error",{id:s,description:a,duration:1e5,closeButton:!0})}},[r]);return{fetching:c,deleteTag:i}},oe=()=>{const{setFiltersContext:c}=u.useContext(q),[r,i]=u.useState(""),[{data:t,fetching:a},s]=_({query:R}),{addTag:n}=W(),{deleteTag:d}=se();u.useEffect(()=>{c(null)},[c]);const m=U(t?.allTags??[]),h=u.useCallback(o=>{o.length>2&&n({tagName:o}).then(()=>{s()})},[n,s]),x=u.useCallback((o,g)=>{d({tagId:o,name:g}).then(()=>{s()})},[d,s]);return e.jsx(Y,{title:"Tags",description:"Manage tags for your bookmarks.",children:a?e.jsx(G,{className:"h-10 w-10 animate-spin mr-2 self-center"}):e.jsxs("div",{className:"h-full flex flex-col overflow-hidden",children:[m?.map(o=>e.jsxs("div",{className:"flex items-center gap-2 text-gray-600 mb-2",children:[e.jsxs("div",{className:"w-full mt-1 relative rounded-md shadow-xs",children:[o.namePath?.map((g,I)=>e.jsx("span",{className:"ms-2"},I)),o.name]}),e.jsx(J,{data:o}),e.jsx(p,{variant:"ghost",size:"icon",className:"size-7.5",onClick:()=>x(o.id,o.name),children:e.jsx(V,{className:"size-5"})})]},o.id)),e.jsxs("div",{className:"flex justify-start items-center gap-2 text-gray-600 mb-2",children:[e.jsx(j,{className:"w-80",value:r,onChange:o=>i(o.currentTarget.value),placeholder:"Add new tag",required:!0}),e.jsx(p,{variant:"ghost",size:"icon",className:"size-7.5",disabled:r.length<2,onClick:()=>h(r),children:e.jsx(H,{className:"size-5"})})]})]})})};export{oe as TagsManager};
@@ -1,4 +1,4 @@
1
- import{d1 as fr,ah as gr,ag as ge,j as F,r as kt,bg as pr,B as mr,y as br,w as le,bj as Pn,bk as Dn,bl as An,bn as xr,F as _r,u as yr,bf as wr,bd as it,L as vr,d2 as Mr}from"./index-B_gzYVvY.js";import{u as io}from"./use-url-query-C4M5DF3n.js";import{P as Sr}from"./page-layout-DTRGIdR7.js";import{P as kr}from"./modal-BF-8kNcF.js";import{F as Cr}from"./funnel-B98DbthO.js";/*!
1
+ import{d1 as fr,ah as gr,ag as ge,j as F,r as kt,bg as pr,B as mr,y as br,w as le,bj as Pn,bk as Dn,bl as An,bn as xr,F as _r,u as yr,bf as wr,bd as it,L as vr,d2 as Mr}from"./index-DL96FIEg.js";import{u as io}from"./use-url-query-Dwk3Z7IG.js";import{P as Sr}from"./page-layout-UeCQVB1c.js";import{P as kr}from"./modal-CcO9VM0k.js";import{F as Cr}from"./funnel-rqI973_z.js";/*!
2
2
  * decimal.js v10.6.0
3
3
  * An arbitrary-precision Decimal type for JavaScript.
4
4
  * https://github.com/MikeMcl/decimal.js
@@ -1,4 +1,4 @@
1
- import{v as V,g as E,ea as q,r,t as k,i as F,u as $,eb as _,j as s,c as L,l as R,B as H,m as Q,n as X}from"./index-B_gzYVvY.js";import{c as G}from"./charges-table-nMOWRUfT.js";import{C as J,M as K}from"./Checkbox-D07lxgUb.js";/**
1
+ import{v as V,g as E,ea as q,r,t as k,i as F,u as $,eb as _,j as s,c as L,l as R,B as H,m as Q,n as X}from"./index-DL96FIEg.js";import{c as G}from"./charges-table-BzapDDk2.js";import{C as J,M as K}from"./Checkbox-MQSJP1Kv.js";/**
2
2
  * @license lucide-react v0.552.0 - ISC
3
3
  *
4
4
  * This source code is licensed under the ISC license.
@@ -1,4 +1,4 @@
1
- import{v as it,r as m,d7 as Nc,ag as V,db as kc,ah as ae,j as v,da as vn,dA as It,dB as ge,dC as Ho,dc as Lc,dD as Vc,dE as nn,dF as jc,bg as Fi,D as _r,aX as zr,bh as Fc,B as ee,x as $r,aY as Ur,aZ as Hr,y as Wo,bi as Bc,ad as _c,bj as An,bk as Bi,bl as _i,w as rn,am as Go,a1 as Ko,bn as zc,g as qo,dG as $c,t as Pe,i as Xo,u as rr,dH as Uc,bK as Hc,bO as Wc,bQ as Gc,bP as Kc,bR as qc,L as Yo,I as Wr,bA as Xc,bB as Yc,bC as Nn,bD as Zc,bN as zi,bE as Jc,bF as $i,bp as Zo,bq as Jo,br as Qo,dI as Qc,bt as eu,bs as sn,dJ as tu,z as nu,a7 as ru,V as iu,X as su,Y as ou,Z as au,_ as lu,a0 as cu,a$ as uu,aa as Ui,dK as du,e as hu,a3 as fu,az as Hi,dL as pu,dM as gu,dN as Wi,cm as mu,bd as vu,F as yu,ao as bu,dO as Tu,dP as xu}from"./index-B_gzYVvY.js";import{u as ea}from"./use-url-query-C4M5DF3n.js";import{T as yn}from"./tooltip-CVi4tvZO.js";import{A as Gi}from"./arrow-up-down-DXqwGYCG.js";import{D as Su}from"./download-csv-button-ppWqXc5x.js";import{B as wu}from"./business-extended-info-D7xrGWVf.js";import{_ as Du,a as bn,s as we,g as Gr,u as Ki,c as Kr,m as wt,d as ir,T as sr}from"./Typography-Cn9V_ua-.js";import{P as Cu}from"./pencil-c0IjX9_t.js";import{P as Eu,a as Ou}from"./panel-top-open-G_VONODW.js";import{F as Pu}from"./funnel-B98DbthO.js";import{M as Mu}from"./MultiSelect-EJOdjjCM.js";import"./Table-BFvxFsm0.js";/**
1
+ import{v as it,r as m,d7 as Nc,ag as V,db as kc,ah as ae,j as v,da as vn,dA as It,dB as ge,dC as Ho,dc as Lc,dD as Vc,dE as nn,dF as jc,bg as Fi,D as _r,aX as zr,bh as Fc,B as ee,x as $r,aY as Ur,aZ as Hr,y as Wo,bi as Bc,ad as _c,bj as An,bk as Bi,bl as _i,w as rn,am as Go,a1 as Ko,bn as zc,g as qo,dG as $c,t as Pe,i as Xo,u as rr,dH as Uc,bK as Hc,bO as Wc,bQ as Gc,bP as Kc,bR as qc,L as Yo,I as Wr,bA as Xc,bB as Yc,bC as Nn,bD as Zc,bN as zi,bE as Jc,bF as $i,bp as Zo,bq as Jo,br as Qo,dI as Qc,bt as eu,bs as sn,dJ as tu,z as nu,a7 as ru,V as iu,X as su,Y as ou,Z as au,_ as lu,a0 as cu,a$ as uu,aa as Ui,dK as du,e as hu,a3 as fu,az as Hi,dL as pu,dM as gu,dN as Wi,cm as mu,bd as vu,F as yu,ao as bu,dO as Tu,dP as xu}from"./index-DL96FIEg.js";import{u as ea}from"./use-url-query-Dwk3Z7IG.js";import{T as yn}from"./tooltip-BwXnRGjA.js";import{A as Gi}from"./arrow-up-down-C2zc3KHR.js";import{D as Su}from"./download-csv-button-BYaF4bdW.js";import{B as wu}from"./business-extended-info-BFNPJr4z.js";import{_ as Du,a as bn,s as we,g as Gr,u as Ki,c as Kr,m as wt,d as ir,T as sr}from"./Typography-B-ckq9s3.js";import{P as Cu}from"./pencil-BPrWXhJF.js";import{P as Eu,a as Ou}from"./panel-top-open-CkHLcq8U.js";import{F as Pu}from"./funnel-rqI973_z.js";import{M as Mu}from"./MultiSelect-HgnjtQq6.js";import"./Table-C6kFDK4t.js";/**
2
2
  * @license lucide-react v0.552.0 - ISC
3
3
  *
4
4
  * This source code is licensed under the ISC license.