@economic/taco 11.0.0 → 11.0.1-react-v19.0
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.
- package/dist/charts/components/Area/AreaChart.cjs.map +1 -1
- package/dist/charts/components/Area/AreaChart.d.ts +1 -1
- package/dist/charts/components/Area/AreaChart.js.map +1 -1
- package/dist/charts/components/Bar/BarChart.cjs.map +1 -1
- package/dist/charts/components/Bar/BarChart.d.ts +1 -1
- package/dist/charts/components/Bar/BarChart.js.map +1 -1
- package/dist/charts/components/Composed/BarLineChart.cjs.map +1 -1
- package/dist/charts/components/Composed/BarLineChart.d.ts +2 -2
- package/dist/charts/components/Composed/BarLineChart.js.map +1 -1
- package/dist/charts/components/Donut/DonutChart.cjs.map +1 -1
- package/dist/charts/components/Donut/DonutChart.d.ts +1 -1
- package/dist/charts/components/Donut/DonutChart.js.map +1 -1
- package/dist/charts/components/Line/LineChart.cjs.map +1 -1
- package/dist/charts/components/Line/LineChart.d.ts +1 -1
- package/dist/charts/components/Line/LineChart.js.map +1 -1
- package/dist/charts/components/Pie/PieChart.cjs.map +1 -1
- package/dist/charts/components/Pie/PieChart.d.ts +1 -1
- package/dist/charts/components/Pie/PieChart.js.map +1 -1
- package/dist/charts/components/Tooltip.cjs.map +1 -1
- package/dist/charts/components/Tooltip.d.ts +1 -1
- package/dist/charts/components/Tooltip.js.map +1 -1
- package/dist/charts/components/types.d.ts +2 -2
- package/dist/components/AlertDialog/AlertDialog.cjs.map +1 -1
- package/dist/components/AlertDialog/AlertDialog.d.ts +1 -1
- package/dist/components/AlertDialog/AlertDialog.js.map +1 -1
- package/dist/components/Banner/util.cjs.map +1 -1
- package/dist/components/Banner/util.d.ts +2 -1
- package/dist/components/Banner/util.js.map +1 -1
- package/dist/components/Card/Card.cjs.map +1 -1
- package/dist/components/Card/Card.d.ts +1 -1
- package/dist/components/Card/Card.js.map +1 -1
- package/dist/components/Combobox/Combobox.cjs.map +1 -1
- package/dist/components/Combobox/Combobox.d.ts +1 -1
- package/dist/components/Combobox/Combobox.js.map +1 -1
- package/dist/components/Combobox/useCombobox.cjs.map +1 -1
- package/dist/components/Combobox/useCombobox.d.ts +1 -1
- package/dist/components/Combobox/useCombobox.js.map +1 -1
- package/dist/components/Dialog/Dialog.cjs.map +1 -1
- package/dist/components/Dialog/Dialog.d.ts +1 -1
- package/dist/components/Dialog/Dialog.js.map +1 -1
- package/dist/components/Dialog/components/Content.cjs.map +1 -1
- package/dist/components/Dialog/components/Content.d.ts +2 -2
- package/dist/components/Dialog/components/Content.js.map +1 -1
- package/dist/components/Drawer/Drawer.cjs.map +1 -1
- package/dist/components/Drawer/Drawer.d.ts +1 -1
- package/dist/components/Drawer/Drawer.js.map +1 -1
- package/dist/components/Drawer/useDrawerStack.cjs +1 -1
- package/dist/components/Drawer/useDrawerStack.cjs.map +1 -1
- package/dist/components/Drawer/useDrawerStack.js +1 -1
- package/dist/components/Drawer/useDrawerStack.js.map +1 -1
- package/dist/components/Hanger/Hanger.cjs.map +1 -1
- package/dist/components/Hanger/Hanger.d.ts +1 -1
- package/dist/components/Hanger/Hanger.js.map +1 -1
- package/dist/components/Header/components/Agreement/Display.cjs.map +1 -1
- package/dist/components/Header/components/Agreement/Display.d.ts +1 -1
- package/dist/components/Header/components/Agreement/Display.js.map +1 -1
- package/dist/components/Header/components/Agreement/Item.cjs.map +1 -1
- package/dist/components/Header/components/Agreement/Item.d.ts +1 -1
- package/dist/components/Header/components/Agreement/Item.js.map +1 -1
- package/dist/components/Header/components/Link.cjs.map +1 -1
- package/dist/components/Header/components/Link.d.ts +1 -1
- package/dist/components/Header/components/Link.js.map +1 -1
- package/dist/components/Icon/components/AccountPreview.cjs.map +1 -1
- package/dist/components/Icon/components/AccountPreview.js.map +1 -1
- package/dist/components/Icon/components/Accounting.cjs.map +1 -1
- package/dist/components/Icon/components/Accounting.js.map +1 -1
- package/dist/components/Icon/components/AccountingYear.cjs.map +1 -1
- package/dist/components/Icon/components/AccountingYear.js.map +1 -1
- package/dist/components/Icon/components/AccountingYearCancel.cjs.map +1 -1
- package/dist/components/Icon/components/AccountingYearCancel.js.map +1 -1
- package/dist/components/Icon/components/AiChatSolid.cjs.map +1 -1
- package/dist/components/Icon/components/AiChatSolid.js.map +1 -1
- package/dist/components/Icon/components/AiStars.cjs.map +1 -1
- package/dist/components/Icon/components/AiStars.js.map +1 -1
- package/dist/components/Icon/components/ArrowBottom.cjs.map +1 -1
- package/dist/components/Icon/components/ArrowBottom.js.map +1 -1
- package/dist/components/Icon/components/ArrowDown.cjs.map +1 -1
- package/dist/components/Icon/components/ArrowDown.js.map +1 -1
- package/dist/components/Icon/components/ArrowEnd.cjs.map +1 -1
- package/dist/components/Icon/components/ArrowEnd.js.map +1 -1
- package/dist/components/Icon/components/ArrowLeft.cjs.map +1 -1
- package/dist/components/Icon/components/ArrowLeft.js.map +1 -1
- package/dist/components/Icon/components/ArrowRight.cjs.map +1 -1
- package/dist/components/Icon/components/ArrowRight.js.map +1 -1
- package/dist/components/Icon/components/ArrowStart.cjs.map +1 -1
- package/dist/components/Icon/components/ArrowStart.js.map +1 -1
- package/dist/components/Icon/components/ArrowTop.cjs.map +1 -1
- package/dist/components/Icon/components/ArrowTop.js.map +1 -1
- package/dist/components/Icon/components/ArrowUp.cjs.map +1 -1
- package/dist/components/Icon/components/ArrowUp.js.map +1 -1
- package/dist/components/Icon/components/Attach.cjs.map +1 -1
- package/dist/components/Icon/components/Attach.js.map +1 -1
- package/dist/components/Icon/components/AttachAuto.cjs.map +1 -1
- package/dist/components/Icon/components/AttachAuto.js.map +1 -1
- package/dist/components/Icon/components/AttachCancel.cjs.map +1 -1
- package/dist/components/Icon/components/AttachCancel.js.map +1 -1
- package/dist/components/Icon/components/AttachWarning.cjs.map +1 -1
- package/dist/components/Icon/components/AttachWarning.js.map +1 -1
- package/dist/components/Icon/components/Autopay.cjs.map +1 -1
- package/dist/components/Icon/components/Autopay.js.map +1 -1
- package/dist/components/Icon/components/AutopayPaused.cjs.map +1 -1
- package/dist/components/Icon/components/AutopayPaused.js.map +1 -1
- package/dist/components/Icon/components/Autotext.cjs.map +1 -1
- package/dist/components/Icon/components/Autotext.js.map +1 -1
- package/dist/components/Icon/components/AutotextInsert.cjs.map +1 -1
- package/dist/components/Icon/components/AutotextInsert.js.map +1 -1
- package/dist/components/Icon/components/Basic.cjs.map +1 -1
- package/dist/components/Icon/components/Basic.js.map +1 -1
- package/dist/components/Icon/components/BasicTabs.cjs.map +1 -1
- package/dist/components/Icon/components/BasicTabs.js.map +1 -1
- package/dist/components/Icon/components/BellSolid.cjs.map +1 -1
- package/dist/components/Icon/components/BellSolid.js.map +1 -1
- package/dist/components/Icon/components/Book.cjs.map +1 -1
- package/dist/components/Icon/components/Book.js.map +1 -1
- package/dist/components/Icon/components/Booking.cjs.map +1 -1
- package/dist/components/Icon/components/Booking.js.map +1 -1
- package/dist/components/Icon/components/Budget.cjs.map +1 -1
- package/dist/components/Icon/components/Budget.js.map +1 -1
- package/dist/components/Icon/components/Calendar.cjs.map +1 -1
- package/dist/components/Icon/components/Calendar.js.map +1 -1
- package/dist/components/Icon/components/CashAccount.cjs.map +1 -1
- package/dist/components/Icon/components/CashAccount.js.map +1 -1
- package/dist/components/Icon/components/CashReports.cjs.map +1 -1
- package/dist/components/Icon/components/CashReports.js.map +1 -1
- package/dist/components/Icon/components/ChartArea.cjs.map +1 -1
- package/dist/components/Icon/components/ChartArea.js.map +1 -1
- package/dist/components/Icon/components/ChartBar.cjs.map +1 -1
- package/dist/components/Icon/components/ChartBar.js.map +1 -1
- package/dist/components/Icon/components/ChartLine.cjs.map +1 -1
- package/dist/components/Icon/components/ChartLine.js.map +1 -1
- package/dist/components/Icon/components/ChartPie.cjs.map +1 -1
- package/dist/components/Icon/components/ChartPie.js.map +1 -1
- package/dist/components/Icon/components/ChartTable.cjs.map +1 -1
- package/dist/components/Icon/components/ChartTable.js.map +1 -1
- package/dist/components/Icon/components/Chat.cjs.map +1 -1
- package/dist/components/Icon/components/Chat.js.map +1 -1
- package/dist/components/Icon/components/ChatSolid.cjs.map +1 -1
- package/dist/components/Icon/components/ChatSolid.js.map +1 -1
- package/dist/components/Icon/components/ChevronDown.cjs.map +1 -1
- package/dist/components/Icon/components/ChevronDown.js.map +1 -1
- package/dist/components/Icon/components/ChevronDownDouble.cjs.map +1 -1
- package/dist/components/Icon/components/ChevronDownDouble.js.map +1 -1
- package/dist/components/Icon/components/ChevronDownSolid.cjs.map +1 -1
- package/dist/components/Icon/components/ChevronDownSolid.js.map +1 -1
- package/dist/components/Icon/components/ChevronLeft.cjs.map +1 -1
- package/dist/components/Icon/components/ChevronLeft.js.map +1 -1
- package/dist/components/Icon/components/ChevronLeftDouble.cjs.map +1 -1
- package/dist/components/Icon/components/ChevronLeftDouble.js.map +1 -1
- package/dist/components/Icon/components/ChevronLeftSolid.cjs.map +1 -1
- package/dist/components/Icon/components/ChevronLeftSolid.js.map +1 -1
- package/dist/components/Icon/components/ChevronRight.cjs.map +1 -1
- package/dist/components/Icon/components/ChevronRight.js.map +1 -1
- package/dist/components/Icon/components/ChevronRightDouble.cjs.map +1 -1
- package/dist/components/Icon/components/ChevronRightDouble.js.map +1 -1
- package/dist/components/Icon/components/ChevronRightSolid.cjs.map +1 -1
- package/dist/components/Icon/components/ChevronRightSolid.js.map +1 -1
- package/dist/components/Icon/components/ChevronUp.cjs.map +1 -1
- package/dist/components/Icon/components/ChevronUp.js.map +1 -1
- package/dist/components/Icon/components/ChevronUpDouble.cjs.map +1 -1
- package/dist/components/Icon/components/ChevronUpDouble.js.map +1 -1
- package/dist/components/Icon/components/ChevronUpSolid.cjs.map +1 -1
- package/dist/components/Icon/components/ChevronUpSolid.js.map +1 -1
- package/dist/components/Icon/components/CircleInformation.cjs.map +1 -1
- package/dist/components/Icon/components/CircleInformation.js.map +1 -1
- package/dist/components/Icon/components/CircleMinus.cjs.map +1 -1
- package/dist/components/Icon/components/CircleMinus.js.map +1 -1
- package/dist/components/Icon/components/CirclePlus.cjs.map +1 -1
- package/dist/components/Icon/components/CirclePlus.js.map +1 -1
- package/dist/components/Icon/components/CircleQuestionmark.cjs.map +1 -1
- package/dist/components/Icon/components/CircleQuestionmark.js.map +1 -1
- package/dist/components/Icon/components/CircleTick.cjs.map +1 -1
- package/dist/components/Icon/components/CircleTick.js.map +1 -1
- package/dist/components/Icon/components/CircleWarning.cjs.map +1 -1
- package/dist/components/Icon/components/CircleWarning.js.map +1 -1
- package/dist/components/Icon/components/Clamp.cjs.map +1 -1
- package/dist/components/Icon/components/Clamp.js.map +1 -1
- package/dist/components/Icon/components/ClampOpen.cjs.map +1 -1
- package/dist/components/Icon/components/ClampOpen.js.map +1 -1
- package/dist/components/Icon/components/ClickToPay.cjs.map +1 -1
- package/dist/components/Icon/components/ClickToPay.js.map +1 -1
- package/dist/components/Icon/components/Close.cjs.map +1 -1
- package/dist/components/Icon/components/Close.js.map +1 -1
- package/dist/components/Icon/components/ColumnFreeze.cjs.map +1 -1
- package/dist/components/Icon/components/ColumnFreeze.js.map +1 -1
- package/dist/components/Icon/components/ColumnUnfreeze.cjs.map +1 -1
- package/dist/components/Icon/components/ColumnUnfreeze.js.map +1 -1
- package/dist/components/Icon/components/Columns.cjs.map +1 -1
- package/dist/components/Icon/components/Columns.js.map +1 -1
- package/dist/components/Icon/components/ConnectionEnable.cjs.map +1 -1
- package/dist/components/Icon/components/ConnectionEnable.js.map +1 -1
- package/dist/components/Icon/components/ConnectionRevoke.cjs.map +1 -1
- package/dist/components/Icon/components/ConnectionRevoke.js.map +1 -1
- package/dist/components/Icon/components/Contacts.cjs.map +1 -1
- package/dist/components/Icon/components/Contacts.js.map +1 -1
- package/dist/components/Icon/components/Copy.cjs.map +1 -1
- package/dist/components/Icon/components/Copy.js.map +1 -1
- package/dist/components/Icon/components/Courses.cjs.map +1 -1
- package/dist/components/Icon/components/Courses.js.map +1 -1
- package/dist/components/Icon/components/Credit.cjs.map +1 -1
- package/dist/components/Icon/components/Credit.js.map +1 -1
- package/dist/components/Icon/components/Delete.cjs.map +1 -1
- package/dist/components/Icon/components/Delete.js.map +1 -1
- package/dist/components/Icon/components/DeletePermanently.cjs.map +1 -1
- package/dist/components/Icon/components/DeletePermanently.js.map +1 -1
- package/dist/components/Icon/components/Depecriate.cjs.map +1 -1
- package/dist/components/Icon/components/Depecriate.js.map +1 -1
- package/dist/components/Icon/components/Developer.cjs.map +1 -1
- package/dist/components/Icon/components/Developer.js.map +1 -1
- package/dist/components/Icon/components/DistributionTemplate.cjs.map +1 -1
- package/dist/components/Icon/components/DistributionTemplate.js.map +1 -1
- package/dist/components/Icon/components/Document.cjs.map +1 -1
- package/dist/components/Icon/components/Document.js.map +1 -1
- package/dist/components/Icon/components/DocumentApprove.cjs.map +1 -1
- package/dist/components/Icon/components/DocumentApprove.js.map +1 -1
- package/dist/components/Icon/components/DocumentCreateEntry.cjs.map +1 -1
- package/dist/components/Icon/components/DocumentCreateEntry.js.map +1 -1
- package/dist/components/Icon/components/DocumentCut.cjs.map +1 -1
- package/dist/components/Icon/components/DocumentCut.js.map +1 -1
- package/dist/components/Icon/components/DocumentError.cjs.map +1 -1
- package/dist/components/Icon/components/DocumentError.js.map +1 -1
- package/dist/components/Icon/components/DocumentIsolatePage.cjs.map +1 -1
- package/dist/components/Icon/components/DocumentIsolatePage.js.map +1 -1
- package/dist/components/Icon/components/DocumentMerge.cjs.map +1 -1
- package/dist/components/Icon/components/DocumentMerge.js.map +1 -1
- package/dist/components/Icon/components/DocumentMove.cjs.map +1 -1
- package/dist/components/Icon/components/DocumentMove.js.map +1 -1
- package/dist/components/Icon/components/DocumentPreview.cjs.map +1 -1
- package/dist/components/Icon/components/DocumentPreview.js.map +1 -1
- package/dist/components/Icon/components/DocumentReceived.cjs.map +1 -1
- package/dist/components/Icon/components/DocumentReceived.js.map +1 -1
- package/dist/components/Icon/components/DocumentRejectedRequest.cjs.map +1 -1
- package/dist/components/Icon/components/DocumentRejectedRequest.js.map +1 -1
- package/dist/components/Icon/components/DocumentSigned.cjs.map +1 -1
- package/dist/components/Icon/components/DocumentSigned.js.map +1 -1
- package/dist/components/Icon/components/DocumentSignedSolid.cjs.map +1 -1
- package/dist/components/Icon/components/DocumentSignedSolid.js.map +1 -1
- package/dist/components/Icon/components/DocumentSplit.cjs.map +1 -1
- package/dist/components/Icon/components/DocumentSplit.js.map +1 -1
- package/dist/components/Icon/components/DocumentTime.cjs.map +1 -1
- package/dist/components/Icon/components/DocumentTime.js.map +1 -1
- package/dist/components/Icon/components/Download.cjs.map +1 -1
- package/dist/components/Icon/components/Download.js.map +1 -1
- package/dist/components/Icon/components/Drag.cjs.map +1 -1
- package/dist/components/Icon/components/Drag.js.map +1 -1
- package/dist/components/Icon/components/ECopedia.cjs.map +1 -1
- package/dist/components/Icon/components/ECopedia.js.map +1 -1
- package/dist/components/Icon/components/Edit.cjs.map +1 -1
- package/dist/components/Icon/components/Edit.js.map +1 -1
- package/dist/components/Icon/components/EditSimple.cjs.map +1 -1
- package/dist/components/Icon/components/EditSimple.js.map +1 -1
- package/dist/components/Icon/components/EllipsisHorizontal.cjs.map +1 -1
- package/dist/components/Icon/components/EllipsisHorizontal.js.map +1 -1
- package/dist/components/Icon/components/EllipsisVertical.cjs.map +1 -1
- package/dist/components/Icon/components/EllipsisVertical.js.map +1 -1
- package/dist/components/Icon/components/EntriesOnAccount.cjs.map +1 -1
- package/dist/components/Icon/components/EntriesOnAccount.js.map +1 -1
- package/dist/components/Icon/components/EntriesOpen.cjs.map +1 -1
- package/dist/components/Icon/components/EntriesOpen.js.map +1 -1
- package/dist/components/Icon/components/EntriesWarning.cjs.map +1 -1
- package/dist/components/Icon/components/EntriesWarning.js.map +1 -1
- package/dist/components/Icon/components/EntryTypeCustomerInvoice.cjs.map +1 -1
- package/dist/components/Icon/components/EntryTypeCustomerInvoice.js.map +1 -1
- package/dist/components/Icon/components/EntryTypeCustomerPayment.cjs.map +1 -1
- package/dist/components/Icon/components/EntryTypeCustomerPayment.js.map +1 -1
- package/dist/components/Icon/components/EntryTypeJournalEntry.cjs.map +1 -1
- package/dist/components/Icon/components/EntryTypeJournalEntry.js.map +1 -1
- package/dist/components/Icon/components/EntryTypeManualCustomerInvoice.cjs.map +1 -1
- package/dist/components/Icon/components/EntryTypeManualCustomerInvoice.js.map +1 -1
- package/dist/components/Icon/components/EntryTypeSupplierInvoice.cjs.map +1 -1
- package/dist/components/Icon/components/EntryTypeSupplierInvoice.js.map +1 -1
- package/dist/components/Icon/components/EntryTypeSupplierPayment.cjs.map +1 -1
- package/dist/components/Icon/components/EntryTypeSupplierPayment.js.map +1 -1
- package/dist/components/Icon/components/Envelope.cjs.map +1 -1
- package/dist/components/Icon/components/Envelope.js.map +1 -1
- package/dist/components/Icon/components/EnvelopeApproved.cjs.map +1 -1
- package/dist/components/Icon/components/EnvelopeApproved.js.map +1 -1
- package/dist/components/Icon/components/EnvelopeSolid.cjs.map +1 -1
- package/dist/components/Icon/components/EnvelopeSolid.js.map +1 -1
- package/dist/components/Icon/components/ExpandView.cjs.map +1 -1
- package/dist/components/Icon/components/ExpandView.js.map +1 -1
- package/dist/components/Icon/components/Expenses.cjs.map +1 -1
- package/dist/components/Icon/components/Expenses.js.map +1 -1
- package/dist/components/Icon/components/Experiment.cjs.map +1 -1
- package/dist/components/Icon/components/Experiment.js.map +1 -1
- package/dist/components/Icon/components/Export.cjs.map +1 -1
- package/dist/components/Icon/components/Export.js.map +1 -1
- package/dist/components/Icon/components/ExportToExcel.cjs.map +1 -1
- package/dist/components/Icon/components/ExportToExcel.js.map +1 -1
- package/dist/components/Icon/components/ExportToPdf.cjs.map +1 -1
- package/dist/components/Icon/components/ExportToPdf.js.map +1 -1
- package/dist/components/Icon/components/EyeOff.cjs.map +1 -1
- package/dist/components/Icon/components/EyeOff.js.map +1 -1
- package/dist/components/Icon/components/EyeOn.cjs.map +1 -1
- package/dist/components/Icon/components/EyeOn.js.map +1 -1
- package/dist/components/Icon/components/Filter.cjs.map +1 -1
- package/dist/components/Icon/components/Filter.js.map +1 -1
- package/dist/components/Icon/components/FilterSolid.cjs.map +1 -1
- package/dist/components/Icon/components/FilterSolid.js.map +1 -1
- package/dist/components/Icon/components/FontSize.cjs.map +1 -1
- package/dist/components/Icon/components/FontSize.js.map +1 -1
- package/dist/components/Icon/components/GraphSolid.cjs.map +1 -1
- package/dist/components/Icon/components/GraphSolid.js.map +1 -1
- package/dist/components/Icon/components/Hash.cjs.map +1 -1
- package/dist/components/Icon/components/Hash.js.map +1 -1
- package/dist/components/Icon/components/HeightExtraTall.cjs.map +1 -1
- package/dist/components/Icon/components/HeightExtraTall.js.map +1 -1
- package/dist/components/Icon/components/HeightMedium.cjs.map +1 -1
- package/dist/components/Icon/components/HeightMedium.js.map +1 -1
- package/dist/components/Icon/components/HeightShort.cjs.map +1 -1
- package/dist/components/Icon/components/HeightShort.js.map +1 -1
- package/dist/components/Icon/components/HeightTall.cjs.map +1 -1
- package/dist/components/Icon/components/HeightTall.js.map +1 -1
- package/dist/components/Icon/components/House.cjs.map +1 -1
- package/dist/components/Icon/components/House.js.map +1 -1
- package/dist/components/Icon/components/HouseSolid.cjs.map +1 -1
- package/dist/components/Icon/components/HouseSolid.js.map +1 -1
- package/dist/components/Icon/components/Id.cjs.map +1 -1
- package/dist/components/Icon/components/Id.js.map +1 -1
- package/dist/components/Icon/components/Images.cjs.map +1 -1
- package/dist/components/Icon/components/Images.js.map +1 -1
- package/dist/components/Icon/components/Import.cjs.map +1 -1
- package/dist/components/Icon/components/Import.js.map +1 -1
- package/dist/components/Icon/components/Inbox.cjs.map +1 -1
- package/dist/components/Icon/components/Inbox.js.map +1 -1
- package/dist/components/Icon/components/InboxEinvoicing.cjs.map +1 -1
- package/dist/components/Icon/components/InboxEinvoicing.js.map +1 -1
- package/dist/components/Icon/components/InboxScanning.cjs.map +1 -1
- package/dist/components/Icon/components/InboxScanning.js.map +1 -1
- package/dist/components/Icon/components/InboxSmart.cjs.map +1 -1
- package/dist/components/Icon/components/InboxSmart.js.map +1 -1
- package/dist/components/Icon/components/Info.cjs.map +1 -1
- package/dist/components/Icon/components/Info.js.map +1 -1
- package/dist/components/Icon/components/Inventory.cjs.map +1 -1
- package/dist/components/Icon/components/Inventory.js.map +1 -1
- package/dist/components/Icon/components/InventoryMatrix.cjs.map +1 -1
- package/dist/components/Icon/components/InventoryMatrix.js.map +1 -1
- package/dist/components/Icon/components/JournalPro.cjs.map +1 -1
- package/dist/components/Icon/components/JournalPro.js.map +1 -1
- package/dist/components/Icon/components/Layout.cjs.map +1 -1
- package/dist/components/Icon/components/Layout.js.map +1 -1
- package/dist/components/Icon/components/LayoutBoth.cjs.map +1 -1
- package/dist/components/Icon/components/LayoutBoth.js.map +1 -1
- package/dist/components/Icon/components/LayoutFirst.cjs.map +1 -1
- package/dist/components/Icon/components/LayoutFirst.js.map +1 -1
- package/dist/components/Icon/components/LayoutLast.cjs.map +1 -1
- package/dist/components/Icon/components/LayoutLast.js.map +1 -1
- package/dist/components/Icon/components/LayoutNone.cjs.map +1 -1
- package/dist/components/Icon/components/LayoutNone.js.map +1 -1
- package/dist/components/Icon/components/LedgerCard.cjs.map +1 -1
- package/dist/components/Icon/components/LedgerCard.js.map +1 -1
- package/dist/components/Icon/components/LedgerCardCustomerReminder.cjs.map +1 -1
- package/dist/components/Icon/components/LedgerCardCustomerReminder.js.map +1 -1
- package/dist/components/Icon/components/LedgerCardManualCustomerInvoice.cjs.map +1 -1
- package/dist/components/Icon/components/LedgerCardManualCustomerInvoice.js.map +1 -1
- package/dist/components/Icon/components/LedgerCardObsoleteStock.cjs.map +1 -1
- package/dist/components/Icon/components/LedgerCardObsoleteStock.js.map +1 -1
- package/dist/components/Icon/components/LedgerCardOpeningEntry.cjs.map +1 -1
- package/dist/components/Icon/components/LedgerCardOpeningEntry.js.map +1 -1
- package/dist/components/Icon/components/LedgerCardReservedEntry.cjs.map +1 -1
- package/dist/components/Icon/components/LedgerCardReservedEntry.js.map +1 -1
- package/dist/components/Icon/components/LedgerCardShrinkagePilferage.cjs.map +1 -1
- package/dist/components/Icon/components/LedgerCardShrinkagePilferage.js.map +1 -1
- package/dist/components/Icon/components/LedgerCardStockAdjustment.cjs.map +1 -1
- package/dist/components/Icon/components/LedgerCardStockAdjustment.js.map +1 -1
- package/dist/components/Icon/components/LedgerCardTransferredOpeningEntry.cjs.map +1 -1
- package/dist/components/Icon/components/LedgerCardTransferredOpeningEntry.js.map +1 -1
- package/dist/components/Icon/components/Lightbulb.cjs.map +1 -1
- package/dist/components/Icon/components/Lightbulb.js.map +1 -1
- package/dist/components/Icon/components/Line.cjs.map +1 -1
- package/dist/components/Icon/components/Line.js.map +1 -1
- package/dist/components/Icon/components/LinkExternal.cjs.map +1 -1
- package/dist/components/Icon/components/LinkExternal.js.map +1 -1
- package/dist/components/Icon/components/List.cjs.map +1 -1
- package/dist/components/Icon/components/List.js.map +1 -1
- package/dist/components/Icon/components/ListBulleted.cjs.map +1 -1
- package/dist/components/Icon/components/ListBulleted.js.map +1 -1
- package/dist/components/Icon/components/ListSearch.cjs.map +1 -1
- package/dist/components/Icon/components/ListSearch.js.map +1 -1
- package/dist/components/Icon/components/Location.cjs.map +1 -1
- package/dist/components/Icon/components/Location.js.map +1 -1
- package/dist/components/Icon/components/Lock.cjs.map +1 -1
- package/dist/components/Icon/components/Lock.js.map +1 -1
- package/dist/components/Icon/components/LockOpen.cjs.map +1 -1
- package/dist/components/Icon/components/LockOpen.js.map +1 -1
- package/dist/components/Icon/components/Log.cjs.map +1 -1
- package/dist/components/Icon/components/Log.js.map +1 -1
- package/dist/components/Icon/components/LogOut.cjs.map +1 -1
- package/dist/components/Icon/components/LogOut.js.map +1 -1
- package/dist/components/Icon/components/Market.cjs.map +1 -1
- package/dist/components/Icon/components/Market.js.map +1 -1
- package/dist/components/Icon/components/MastercardOs.cjs.map +1 -1
- package/dist/components/Icon/components/MastercardOs.js.map +1 -1
- package/dist/components/Icon/components/MatchAmount.cjs.map +1 -1
- package/dist/components/Icon/components/MatchAmount.js.map +1 -1
- package/dist/components/Icon/components/MatchEntries.cjs.map +1 -1
- package/dist/components/Icon/components/MatchEntries.js.map +1 -1
- package/dist/components/Icon/components/Menu.cjs.map +1 -1
- package/dist/components/Icon/components/Menu.js.map +1 -1
- package/dist/components/Icon/components/Mileage.cjs.map +1 -1
- package/dist/components/Icon/components/Mileage.js.map +1 -1
- package/dist/components/Icon/components/ModalResize.cjs.map +1 -1
- package/dist/components/Icon/components/ModalResize.js.map +1 -1
- package/dist/components/Icon/components/ModalShrink.cjs.map +1 -1
- package/dist/components/Icon/components/ModalShrink.js.map +1 -1
- package/dist/components/Icon/components/More.cjs.map +1 -1
- package/dist/components/Icon/components/More.js.map +1 -1
- package/dist/components/Icon/components/MoreSolid.cjs.map +1 -1
- package/dist/components/Icon/components/MoreSolid.js.map +1 -1
- package/dist/components/Icon/components/Move.cjs.map +1 -1
- package/dist/components/Icon/components/Move.js.map +1 -1
- package/dist/components/Icon/components/NavigationList.cjs.map +1 -1
- package/dist/components/Icon/components/NavigationList.js.map +1 -1
- package/dist/components/Icon/components/Note.cjs.map +1 -1
- package/dist/components/Icon/components/Note.js.map +1 -1
- package/dist/components/Icon/components/NoteFollowUp.cjs.map +1 -1
- package/dist/components/Icon/components/NoteFollowUp.js.map +1 -1
- package/dist/components/Icon/components/NoteRead.cjs.map +1 -1
- package/dist/components/Icon/components/NoteRead.js.map +1 -1
- package/dist/components/Icon/components/NovemberFirst.cjs.map +1 -1
- package/dist/components/Icon/components/NovemberFirst.js.map +1 -1
- package/dist/components/Icon/components/Numbers.cjs.map +1 -1
- package/dist/components/Icon/components/Numbers.js.map +1 -1
- package/dist/components/Icon/components/PartialPaymentScheduled.cjs.map +1 -1
- package/dist/components/Icon/components/PartialPaymentScheduled.js.map +1 -1
- package/dist/components/Icon/components/PartnerApi.cjs.map +1 -1
- package/dist/components/Icon/components/PartnerApi.js.map +1 -1
- package/dist/components/Icon/components/PaymentPaid.cjs.map +1 -1
- package/dist/components/Icon/components/PaymentPaid.js.map +1 -1
- package/dist/components/Icon/components/PaymentUnpaid.cjs.map +1 -1
- package/dist/components/Icon/components/PaymentUnpaid.js.map +1 -1
- package/dist/components/Icon/components/Period.cjs.map +1 -1
- package/dist/components/Icon/components/Period.js.map +1 -1
- package/dist/components/Icon/components/Person.cjs.map +1 -1
- package/dist/components/Icon/components/Person.js.map +1 -1
- package/dist/components/Icon/components/PersonChange.cjs.map +1 -1
- package/dist/components/Icon/components/PersonChange.js.map +1 -1
- package/dist/components/Icon/components/PersonMinus.cjs.map +1 -1
- package/dist/components/Icon/components/PersonMinus.js.map +1 -1
- package/dist/components/Icon/components/PersonPlus.cjs.map +1 -1
- package/dist/components/Icon/components/PersonPlus.js.map +1 -1
- package/dist/components/Icon/components/PersonSolid.cjs.map +1 -1
- package/dist/components/Icon/components/PersonSolid.js.map +1 -1
- package/dist/components/Icon/components/PersonTick.cjs.map +1 -1
- package/dist/components/Icon/components/PersonTick.js.map +1 -1
- package/dist/components/Icon/components/Phone.cjs.map +1 -1
- package/dist/components/Icon/components/Phone.js.map +1 -1
- package/dist/components/Icon/components/PhoneSolid.cjs.map +1 -1
- package/dist/components/Icon/components/PhoneSolid.js.map +1 -1
- package/dist/components/Icon/components/Play.cjs.map +1 -1
- package/dist/components/Icon/components/Play.js.map +1 -1
- package/dist/components/Icon/components/PlusMinus.cjs.map +1 -1
- package/dist/components/Icon/components/PlusMinus.js.map +1 -1
- package/dist/components/Icon/components/Print.cjs.map +1 -1
- package/dist/components/Icon/components/Print.js.map +1 -1
- package/dist/components/Icon/components/ProcessPayment.cjs.map +1 -1
- package/dist/components/Icon/components/ProcessPayment.js.map +1 -1
- package/dist/components/Icon/components/ProductLedgerCard.cjs.map +1 -1
- package/dist/components/Icon/components/ProductLedgerCard.js.map +1 -1
- package/dist/components/Icon/components/Profile.cjs.map +1 -1
- package/dist/components/Icon/components/Profile.js.map +1 -1
- package/dist/components/Icon/components/ProjectCards.cjs.map +1 -1
- package/dist/components/Icon/components/ProjectCards.js.map +1 -1
- package/dist/components/Icon/components/Projects.cjs.map +1 -1
- package/dist/components/Icon/components/Projects.js.map +1 -1
- package/dist/components/Icon/components/QuestionMark.cjs.map +1 -1
- package/dist/components/Icon/components/QuestionMark.js.map +1 -1
- package/dist/components/Icon/components/QuestionMarkBold.cjs.map +1 -1
- package/dist/components/Icon/components/QuestionMarkBold.js.map +1 -1
- package/dist/components/Icon/components/Quicklinks.cjs.map +1 -1
- package/dist/components/Icon/components/Quicklinks.js.map +1 -1
- package/dist/components/Icon/components/RatingBankruptcy.cjs.map +1 -1
- package/dist/components/Icon/components/RatingBankruptcy.js.map +1 -1
- package/dist/components/Icon/components/RatingPaymentProblems.cjs.map +1 -1
- package/dist/components/Icon/components/RatingPaymentProblems.js.map +1 -1
- package/dist/components/Icon/components/Reconciled.cjs.map +1 -1
- package/dist/components/Icon/components/Reconciled.js.map +1 -1
- package/dist/components/Icon/components/Refresh.cjs.map +1 -1
- package/dist/components/Icon/components/Refresh.js.map +1 -1
- package/dist/components/Icon/components/Remove.cjs.map +1 -1
- package/dist/components/Icon/components/Remove.js.map +1 -1
- package/dist/components/Icon/components/Report.cjs.map +1 -1
- package/dist/components/Icon/components/Report.js.map +1 -1
- package/dist/components/Icon/components/ReportSolid.cjs.map +1 -1
- package/dist/components/Icon/components/ReportSolid.js.map +1 -1
- package/dist/components/Icon/components/Restore.cjs.map +1 -1
- package/dist/components/Icon/components/Restore.js.map +1 -1
- package/dist/components/Icon/components/RotateLeft.cjs.map +1 -1
- package/dist/components/Icon/components/RotateLeft.js.map +1 -1
- package/dist/components/Icon/components/RotateRight.cjs.map +1 -1
- package/dist/components/Icon/components/RotateRight.js.map +1 -1
- package/dist/components/Icon/components/Sales.cjs.map +1 -1
- package/dist/components/Icon/components/Sales.js.map +1 -1
- package/dist/components/Icon/components/Search.cjs.map +1 -1
- package/dist/components/Icon/components/Search.js.map +1 -1
- package/dist/components/Icon/components/SearchBold.cjs.map +1 -1
- package/dist/components/Icon/components/SearchBold.js.map +1 -1
- package/dist/components/Icon/components/Secure.cjs.map +1 -1
- package/dist/components/Icon/components/Secure.js.map +1 -1
- package/dist/components/Icon/components/SecureTick.cjs.map +1 -1
- package/dist/components/Icon/components/SecureTick.js.map +1 -1
- package/dist/components/Icon/components/Settings.cjs.map +1 -1
- package/dist/components/Icon/components/Settings.js.map +1 -1
- package/dist/components/Icon/components/SettingsSolid.cjs.map +1 -1
- package/dist/components/Icon/components/SettingsSolid.js.map +1 -1
- package/dist/components/Icon/components/Shortcuts.cjs.map +1 -1
- package/dist/components/Icon/components/Shortcuts.js.map +1 -1
- package/dist/components/Icon/components/ShowAll.cjs.map +1 -1
- package/dist/components/Icon/components/ShowAll.js.map +1 -1
- package/dist/components/Icon/components/ShowLess.cjs.map +1 -1
- package/dist/components/Icon/components/ShowLess.js.map +1 -1
- package/dist/components/Icon/components/ShowMore.cjs.map +1 -1
- package/dist/components/Icon/components/ShowMore.js.map +1 -1
- package/dist/components/Icon/components/ShowTemplate.cjs.map +1 -1
- package/dist/components/Icon/components/ShowTemplate.js.map +1 -1
- package/dist/components/Icon/components/Sliders.cjs.map +1 -1
- package/dist/components/Icon/components/Sliders.js.map +1 -1
- package/dist/components/Icon/components/Smartpay.cjs.map +1 -1
- package/dist/components/Icon/components/Smartpay.js.map +1 -1
- package/dist/components/Icon/components/SortBy.cjs.map +1 -1
- package/dist/components/Icon/components/SortBy.js.map +1 -1
- package/dist/components/Icon/components/Star.cjs.map +1 -1
- package/dist/components/Icon/components/Star.js.map +1 -1
- package/dist/components/Icon/components/StarSolid.cjs.map +1 -1
- package/dist/components/Icon/components/StarSolid.js.map +1 -1
- package/dist/components/Icon/components/Subscriptions.cjs.map +1 -1
- package/dist/components/Icon/components/Subscriptions.js.map +1 -1
- package/dist/components/Icon/components/SystemEntries.cjs.map +1 -1
- package/dist/components/Icon/components/SystemEntries.js.map +1 -1
- package/dist/components/Icon/components/Tag.cjs.map +1 -1
- package/dist/components/Icon/components/Tag.js.map +1 -1
- package/dist/components/Icon/components/TemplateOverride.cjs.map +1 -1
- package/dist/components/Icon/components/TemplateOverride.js.map +1 -1
- package/dist/components/Icon/components/Templates.cjs.map +1 -1
- package/dist/components/Icon/components/Templates.js.map +1 -1
- package/dist/components/Icon/components/ThumbBoth.cjs.map +1 -1
- package/dist/components/Icon/components/ThumbBoth.js.map +1 -1
- package/dist/components/Icon/components/ThumbDown.cjs.map +1 -1
- package/dist/components/Icon/components/ThumbDown.js.map +1 -1
- package/dist/components/Icon/components/ThumbDownSolid.cjs.map +1 -1
- package/dist/components/Icon/components/ThumbDownSolid.js.map +1 -1
- package/dist/components/Icon/components/ThumbUp.cjs.map +1 -1
- package/dist/components/Icon/components/ThumbUp.js.map +1 -1
- package/dist/components/Icon/components/ThumbUpSolid.cjs.map +1 -1
- package/dist/components/Icon/components/ThumbUpSolid.js.map +1 -1
- package/dist/components/Icon/components/Tick.cjs.map +1 -1
- package/dist/components/Icon/components/Tick.js.map +1 -1
- package/dist/components/Icon/components/TickBold.cjs.map +1 -1
- package/dist/components/Icon/components/TickBold.js.map +1 -1
- package/dist/components/Icon/components/Time.cjs.map +1 -1
- package/dist/components/Icon/components/Time.js.map +1 -1
- package/dist/components/Icon/components/Transfer.cjs.map +1 -1
- package/dist/components/Icon/components/Transfer.js.map +1 -1
- package/dist/components/Icon/components/TransferCancel.cjs.map +1 -1
- package/dist/components/Icon/components/TransferCancel.js.map +1 -1
- package/dist/components/Icon/components/TransferLocked.cjs.map +1 -1
- package/dist/components/Icon/components/TransferLocked.js.map +1 -1
- package/dist/components/Icon/components/Undo.cjs.map +1 -1
- package/dist/components/Icon/components/Undo.js.map +1 -1
- package/dist/components/Icon/components/Undock.cjs.map +1 -1
- package/dist/components/Icon/components/Undock.js.map +1 -1
- package/dist/components/Icon/components/Unreconciled.cjs.map +1 -1
- package/dist/components/Icon/components/Unreconciled.js.map +1 -1
- package/dist/components/Icon/components/Wallet.cjs.map +1 -1
- package/dist/components/Icon/components/Wallet.js.map +1 -1
- package/dist/components/Icon/components/Warning.cjs.map +1 -1
- package/dist/components/Icon/components/Warning.js.map +1 -1
- package/dist/components/Icon/components/Webshop.cjs.map +1 -1
- package/dist/components/Icon/components/Webshop.js.map +1 -1
- package/dist/components/Icon/components/Website.cjs.map +1 -1
- package/dist/components/Icon/components/Website.js.map +1 -1
- package/dist/components/Icon/components/Workflow.cjs.map +1 -1
- package/dist/components/Icon/components/Workflow.js.map +1 -1
- package/dist/components/Icon/components/WorkflowTemplateBasic.cjs.map +1 -1
- package/dist/components/Icon/components/WorkflowTemplateBasic.js.map +1 -1
- package/dist/components/Icon/components/Zoom.cjs.map +1 -1
- package/dist/components/Icon/components/Zoom.js.map +1 -1
- package/dist/components/Input/Input.cjs.map +1 -1
- package/dist/components/Input/Input.d.ts +14 -8
- package/dist/components/Input/Input.js.map +1 -1
- package/dist/components/LegacyComponents/Button/Button.cjs.map +1 -1
- package/dist/components/LegacyComponents/Button/Button.d.ts +13 -13
- package/dist/components/LegacyComponents/Button/Button.js.map +1 -1
- package/dist/components/LegacyComponents/Button/util.cjs.map +1 -1
- package/dist/components/LegacyComponents/Button/util.d.ts +2 -2
- package/dist/components/LegacyComponents/Button/util.js.map +1 -1
- package/dist/components/LegacyComponents/IconButton/IconButton.cjs.map +1 -1
- package/dist/components/LegacyComponents/IconButton/IconButton.d.ts +15 -15
- package/dist/components/LegacyComponents/IconButton/IconButton.js.map +1 -1
- package/dist/components/List/List.cjs.map +1 -1
- package/dist/components/List/List.d.ts +3 -3
- package/dist/components/List/List.js.map +1 -1
- package/dist/components/List/components/Collapsible.cjs.map +1 -1
- package/dist/components/List/components/Collapsible.d.ts +2 -2
- package/dist/components/List/components/Collapsible.js.map +1 -1
- package/dist/components/List/components/Group.cjs.map +1 -1
- package/dist/components/List/components/Group.d.ts +2 -2
- package/dist/components/List/components/Group.js.map +1 -1
- package/dist/components/List/components/Item.cjs.map +1 -1
- package/dist/components/List/components/Item.d.ts +7 -7
- package/dist/components/List/components/Item.js.map +1 -1
- package/dist/components/List/components/Toggle.cjs.map +1 -1
- package/dist/components/List/components/Toggle.js.map +1 -1
- package/dist/components/Listbox/ScrollableList.cjs.map +1 -1
- package/dist/components/Listbox/ScrollableList.d.ts +4 -2
- package/dist/components/Listbox/ScrollableList.js.map +1 -1
- package/dist/components/Listbox/util.cjs.map +1 -1
- package/dist/components/Listbox/util.d.ts +9 -5
- package/dist/components/Listbox/util.js.map +1 -1
- package/dist/components/Menu/Context.cjs.map +1 -1
- package/dist/components/Menu/Context.d.ts +2 -2
- package/dist/components/Menu/Context.js.map +1 -1
- package/dist/components/Menu/Menu.cjs.map +1 -1
- package/dist/components/Menu/Menu.d.ts +1 -1
- package/dist/components/Menu/Menu.js.map +1 -1
- package/dist/components/Menu/components/Content.cjs.map +1 -1
- package/dist/components/Menu/components/Content.js.map +1 -1
- package/dist/components/Menu/components/Item.cjs.map +1 -1
- package/dist/components/Menu/components/Item.d.ts +2 -2
- package/dist/components/Menu/components/Item.js.map +1 -1
- package/dist/components/Menu/components/RadioGroup.cjs.map +1 -1
- package/dist/components/Menu/components/RadioGroup.js.map +1 -1
- package/dist/components/Navigation2/components/Group.cjs.map +1 -1
- package/dist/components/Navigation2/components/Group.d.ts +2 -2
- package/dist/components/Navigation2/components/Group.js.map +1 -1
- package/dist/components/Navigation2/components/Link.cjs.map +1 -1
- package/dist/components/Navigation2/components/Link.d.ts +2 -2
- package/dist/components/Navigation2/components/Link.js.map +1 -1
- package/dist/components/OverflowGroup/OverflowGroup.cjs.map +1 -1
- package/dist/components/OverflowGroup/OverflowGroup.js.map +1 -1
- package/dist/components/Pagination/PageNumbers.cjs.map +1 -1
- package/dist/components/Pagination/PageNumbers.d.ts +2 -1
- package/dist/components/Pagination/PageNumbers.js.map +1 -1
- package/dist/components/Popover/Popover.cjs.map +1 -1
- package/dist/components/Popover/Popover.d.ts +2 -2
- package/dist/components/Popover/Popover.js.map +1 -1
- package/dist/components/Progress/Progress.cjs.map +1 -1
- package/dist/components/Progress/Progress.d.ts +1 -1
- package/dist/components/Progress/Progress.js.map +1 -1
- package/dist/components/Provider/Provider.cjs.map +1 -1
- package/dist/components/Provider/Provider.d.ts +1 -1
- package/dist/components/Provider/Provider.js.map +1 -1
- package/dist/components/RadioGroup/RadioGroup.cjs.map +1 -1
- package/dist/components/RadioGroup/RadioGroup.js.map +1 -1
- package/dist/components/Report/Report.cjs.map +1 -1
- package/dist/components/Report/Report.d.ts +1 -1
- package/dist/components/Report/Report.js.map +1 -1
- package/dist/components/SearchInput2/SearchInput2.cjs.map +1 -1
- package/dist/components/SearchInput2/SearchInput2.d.ts +1 -1
- package/dist/components/SearchInput2/SearchInput2.js.map +1 -1
- package/dist/components/Select/useSelect.cjs.map +1 -1
- package/dist/components/Select/useSelect.d.ts +2 -2
- package/dist/components/Select/useSelect.js.map +1 -1
- package/dist/components/Select2/Select2.cjs +1 -3
- package/dist/components/Select2/Select2.cjs.map +1 -1
- package/dist/components/Select2/Select2.d.ts +5 -5
- package/dist/components/Select2/Select2.js +1 -3
- package/dist/components/Select2/Select2.js.map +1 -1
- package/dist/components/Select2/components/Context.cjs.map +1 -1
- package/dist/components/Select2/components/Context.d.ts +3 -3
- package/dist/components/Select2/components/Context.js.map +1 -1
- package/dist/components/Select2/components/Option.cjs.map +1 -1
- package/dist/components/Select2/components/Option.d.ts +7 -7
- package/dist/components/Select2/components/Option.js.map +1 -1
- package/dist/components/Select2/components/Search.d.ts +7 -4
- package/dist/components/Select2/components/Trigger.cjs +6 -5
- package/dist/components/Select2/components/Trigger.cjs.map +1 -1
- package/dist/components/Select2/components/Trigger.js +6 -5
- package/dist/components/Select2/components/Trigger.js.map +1 -1
- package/dist/components/Select2/types.d.ts +1 -1
- package/dist/components/Table3/Table3.cjs.map +1 -1
- package/dist/components/Table3/Table3.d.ts +1 -1
- package/dist/components/Table3/Table3.js.map +1 -1
- package/dist/components/Table3/components/Columns/Cell/Editing/RowMoveIndicator.cjs.map +1 -1
- package/dist/components/Table3/components/Columns/Cell/Editing/RowMoveIndicator.d.ts +1 -1
- package/dist/components/Table3/components/Columns/Cell/Editing/RowMoveIndicator.js.map +1 -1
- package/dist/components/Table3/components/Columns/Cell/EditingControlCell.cjs.map +1 -1
- package/dist/components/Table3/components/Columns/Cell/EditingControlCell.js.map +1 -1
- package/dist/components/Table3/components/Columns/Cell/EditingDisplayCell.cjs.map +1 -1
- package/dist/components/Table3/components/Columns/Cell/EditingDisplayCell.d.ts +2 -1
- package/dist/components/Table3/components/Columns/Cell/EditingDisplayCell.js.map +1 -1
- package/dist/components/Table3/components/Editing/Alert.cjs +9 -3
- package/dist/components/Table3/components/Editing/Alert.cjs.map +1 -1
- package/dist/components/Table3/components/Editing/Alert.js +9 -3
- package/dist/components/Table3/components/Editing/Alert.js.map +1 -1
- package/dist/components/Table3/components/Row/Editing/TemporaryRow.cjs.map +1 -1
- package/dist/components/Table3/components/Row/Editing/TemporaryRow.d.ts +1 -1
- package/dist/components/Table3/components/Row/Editing/TemporaryRow.js.map +1 -1
- package/dist/components/Table3/features/useEditingState.cjs +14 -6
- package/dist/components/Table3/features/useEditingState.cjs.map +1 -1
- package/dist/components/Table3/features/useEditingState.d.ts +24 -6
- package/dist/components/Table3/features/useEditingState.js +14 -6
- package/dist/components/Table3/features/useEditingState.js.map +1 -1
- package/dist/components/Table3/features/useTableEditing.d.ts +28 -7
- package/dist/components/Tabs/components/TabList.cjs.map +1 -1
- package/dist/components/Tabs/components/TabList.js.map +1 -1
- package/dist/components/Tabs/components/Trigger.cjs.map +1 -1
- package/dist/components/Tabs/components/Trigger.d.ts +2 -2
- package/dist/components/Tabs/components/Trigger.js.map +1 -1
- package/dist/components/Toast/Toast.cjs.map +1 -1
- package/dist/components/Toast/Toast.d.ts +1 -1
- package/dist/components/Toast/Toast.js.map +1 -1
- package/dist/components/Toast/Toaster.cjs.map +1 -1
- package/dist/components/Toast/Toaster.d.ts +1 -1
- package/dist/components/Toast/Toaster.js.map +1 -1
- package/dist/components/Toast/util.cjs.map +1 -1
- package/dist/components/Toast/util.d.ts +2 -1
- package/dist/components/Toast/util.js.map +1 -1
- package/dist/components/Tooltip/Tooltip.cjs.map +1 -1
- package/dist/components/Tooltip/Tooltip.d.ts +2 -2
- package/dist/components/Tooltip/Tooltip.js.map +1 -1
- package/dist/components/Truncate/Truncate.cjs.map +1 -1
- package/dist/components/Truncate/Truncate.d.ts +5 -2
- package/dist/components/Truncate/Truncate.js.map +1 -1
- package/dist/hooks/useBoundingClientRectListener.cjs.map +1 -1
- package/dist/hooks/useBoundingClientRectListener.d.ts +1 -1
- package/dist/hooks/useBoundingClientRectListener.js.map +1 -1
- package/dist/hooks/useIntersectionObserver.cjs.map +1 -1
- package/dist/hooks/useIntersectionObserver.d.ts +1 -1
- package/dist/hooks/useIntersectionObserver.js.map +1 -1
- package/dist/hooks/useMergedRef.cjs.map +1 -1
- package/dist/hooks/useMergedRef.js.map +1 -1
- package/dist/hooks/useResizeObserver.cjs.map +1 -1
- package/dist/hooks/useResizeObserver.d.ts +1 -1
- package/dist/hooks/useResizeObserver.js.map +1 -1
- package/dist/primitives/Button.cjs.map +1 -1
- package/dist/primitives/Button.d.ts +2 -2
- package/dist/primitives/Button.js.map +1 -1
- package/dist/primitives/Listbox2/components/Option.d.ts +1 -1
- package/dist/primitives/Sortable/components/Item.cjs.map +1 -1
- package/dist/primitives/Sortable/components/Item.js.map +1 -1
- package/dist/primitives/Table/Core/Table.cjs.map +1 -1
- package/dist/primitives/Table/Core/Table.d.ts +2 -2
- package/dist/primitives/Table/Core/Table.js.map +1 -1
- package/dist/primitives/Table/Core/components/Columns/Cell/BuiltIns/GroupedCell.cjs.map +1 -1
- package/dist/primitives/Table/Core/components/Columns/Cell/BuiltIns/GroupedCell.js.map +1 -1
- package/dist/primitives/Table/Core/components/Columns/Cell/util.cjs.map +1 -1
- package/dist/primitives/Table/Core/components/Columns/Cell/util.d.ts +1 -1
- package/dist/primitives/Table/Core/components/Columns/Cell/util.js.map +1 -1
- package/dist/primitives/Table/Core/components/Columns/Internal/Actions.cjs.map +1 -1
- package/dist/primitives/Table/Core/components/Columns/Internal/Actions.js.map +1 -1
- package/dist/primitives/Table/Core/components/Footer/Footer.cjs.map +1 -1
- package/dist/primitives/Table/Core/components/Footer/Footer.js.map +1 -1
- package/dist/primitives/Table/Core/components/Header/Header.cjs.map +1 -1
- package/dist/primitives/Table/Core/components/Header/Header.d.ts +1 -1
- package/dist/primitives/Table/Core/components/Header/Header.js.map +1 -1
- package/dist/primitives/Table/Core/components/Header/components/Menu.cjs.map +1 -1
- package/dist/primitives/Table/Core/components/Header/components/Menu.d.ts +1 -1
- package/dist/primitives/Table/Core/components/Header/components/Menu.js.map +1 -1
- package/dist/primitives/Table/Core/components/Row/BuiltIns/DisplayRow.cjs.map +1 -1
- package/dist/primitives/Table/Core/components/Row/BuiltIns/DisplayRow.d.ts +1 -1
- package/dist/primitives/Table/Core/components/Row/BuiltIns/DisplayRow.js.map +1 -1
- package/dist/primitives/Table/Core/components/Toolbar/Toolbar.cjs.map +1 -1
- package/dist/primitives/Table/Core/components/Toolbar/Toolbar.d.ts +1 -1
- package/dist/primitives/Table/Core/components/Toolbar/Toolbar.js.map +1 -1
- package/dist/primitives/Table/Core/features/useTableRenderer.cjs.map +1 -1
- package/dist/primitives/Table/Core/features/useTableRenderer.d.ts +1 -1
- package/dist/primitives/Table/Core/features/useTableRenderer.js.map +1 -1
- package/dist/primitives/Table/Core/types.d.ts +3 -3
- package/dist/primitives/Table/Core/useTable.cjs.map +1 -1
- package/dist/primitives/Table/Core/useTable.d.ts +4 -4
- package/dist/primitives/Table/Core/useTable.js.map +1 -1
- package/dist/primitives/Table/types.cjs.map +1 -1
- package/dist/primitives/Table/types.d.ts +15 -15
- package/dist/primitives/Table/types.js.map +1 -1
- package/dist/primitives/Table/useTableManager/features/useTableRowSelection.d.ts +1 -1
- package/dist/primitives/Table/useTableManager/types.d.ts +2 -2
- package/dist/primitives/Table/useTableManager/util/setup.cjs +2 -2
- package/dist/primitives/Table/useTableManager/util/setup.cjs.map +1 -1
- package/dist/primitives/Table/useTableManager/util/setup.js +2 -2
- package/dist/primitives/Table/useTableManager/util/setup.js.map +1 -1
- package/dist/types.cjs.map +1 -1
- package/dist/types.d.ts +1 -1
- package/dist/types.js.map +1 -1
- package/package.json +8 -15
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AreaChart.cjs","sources":["../../../../src/charts/components/Area/AreaChart.tsx"],"sourcesContent":["import cn from 'clsx';\nimport React from 'react';\nimport * as RechartsPrimitive from 'recharts';\n\nimport { getAxisProps, stripCartesianProps } from '../../utils/common';\nimport { ChartWrapper } from '../ChartWrapper';\nimport { Legend } from '../Legend';\nimport { Tooltip } from '../Tooltip';\nimport type { ChartChildProps, CartesianChartProps, CurveType } from '../types';\nimport { useChart } from '../useChartData';\n\nexport type AreaChartProps<TData extends object> = {\n /** Show dots for each data point\n * @default false\n */\n showDots?: boolean;\n /** Stack areas on top of one another, instead of other each other. 'expand' fills the available space\n * @default false\n */\n stacked?: boolean | 'expand';\n /** Interpolation type of the line\n * @default natural\n */\n type?: CurveType;\n} & CartesianChartProps<TData>;\n\nexport function AreaChart<TData extends object>(props: AreaChartProps<TData>) {\n const {\n children,\n className: customClassName,\n data,\n showLegend = false,\n showDots = false,\n stacked = false,\n tooltipTitle,\n type = 'natural',\n ...attributes\n } = stripCartesianProps<AreaChartProps<TData>>(props);\n\n const className = cn('relative aspect-video', { 'pb-8': showLegend }, customClassName);\n const { items, shapes, activeIndex, setActiveIndex, toggleItem } = useChart<TData>(children);\n\n return (\n <div className={className} data-taco=\"chart-wrapper\">\n <ChartWrapper {...attributes} className=\"h-full w-full\" data-taco=\"chart-area\">\n <RechartsPrimitive.AreaChart\n data={data}\n margin={{\n bottom: 0,\n // ensures dots on the edges of the chart don't get cropped\n left: 4,\n right: 4,\n top: 4,\n }}\n stackOffset={stacked === 'expand' ? 'expand' : undefined}>\n <RechartsPrimitive.CartesianGrid vertical={false} />\n <RechartsPrimitive.Tooltip content={<Tooltip title={tooltipTitle} />} />\n <RechartsPrimitive.XAxis {...getAxisProps('x', props)} />\n <RechartsPrimitive.YAxis {...getAxisProps('y', props)} />\n {shapes.map(shape => (\n <RechartsPrimitive.Area\n key={shape.dataKey}\n {...shape}\n dot={showDots ? shape.dot : false}\n fillOpacity={0.4}\n stackId={stacked ? 'stack' : undefined}\n type={type}\n />\n ))}\n </RechartsPrimitive.AreaChart>\n </ChartWrapper>\n {showLegend ? (\n <Legend<TData> items={items} hoverIndex={activeIndex} onHover={setActiveIndex} onToggle={toggleItem} />\n ) : null}\n </div>\n );\n}\n\n// oxlint-disable-next-line no-empty-object-type\nexport type AreaChartAreaProps<TData extends object> = {} & ChartChildProps<TData>;\n\nfunction Area<TData extends object>(_: AreaChartAreaProps<TData>): JSX.Element | null {\n return null;\n}\nAreaChart.Area = Area;\n"],"names":["stripCartesianProps","useChart","ChartWrapper","RechartsPrimitive","Tooltip","getAxisProps","Legend"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;AA0BO,SAAS,UAAgC,OAA8B;AAC1E,QAAM;AAAA,IACF;AAAA,IACA,WAAW;AAAA,IACX;AAAA,IACA,aAAa;AAAA,IACb,WAAW;AAAA,IACX,UAAU;AAAA,IACV;AAAA,IACA,OAAO;AAAA,IACP,GAAG;AAAA,EAAA,IACHA,OAAAA,oBAA2C,KAAK;AAEpD,QAAM,YAAY,GAAG,yBAAyB,EAAE,QAAQ,WAAA,GAAc,eAAe;AACrF,QAAM,EAAE,OAAO,QAAQ,aAAa,gBAAgB,WAAA,IAAeC,aAAAA,SAAgB,QAAQ;AAE3F,SACI,sBAAA,cAAC,OAAA,EAAI,WAAsB,aAAU,gBAAA,GACjC,sBAAA,cAACC,aAAAA,cAAA,EAAc,GAAG,YAAY,WAAU,iBAAgB,aAAU,aAAA,GAC9D,sBAAA;AAAA,IAACC,6BAAkB;AAAA,IAAlB;AAAA,MACG;AAAA,MACA,QAAQ;AAAA,QACJ,QAAQ;AAAA;AAAA,QAER,MAAM;AAAA,QACN,OAAO;AAAA,QACP,KAAK;AAAA,MAAA;AAAA,MAET,aAAa,YAAY,WAAW,WAAW;AAAA,IAAA;AAAA,IAC/C,sBAAA,cAACA,6BAAkB,eAAlB,EAAgC,UAAU,OAAO;AAAA,IAClD,sBAAA,cAACA,6BAAkB,SAAlB,EAA0B,SAAS,sBAAA,cAACC,QAAAA,SAAA,EAAQ,OAAO,aAAA,CAAc,EAAA,CAAI;AAAA,IACtE,sBAAA,cAACD,6BAAkB,OAAlB,EAAyB,GAAGE,oBAAa,KAAK,KAAK,GAAG;AAAA,IACvD,sBAAA,cAACF,6BAAkB,OAAlB,EAAyB,GAAGE,oBAAa,KAAK,KAAK,GAAG;AAAA,IACtD,OAAO,IAAI,CAAA,UACR,sBAAA;AAAA,MAACF,6BAAkB;AAAA,MAAlB;AAAA,QACG,KAAK,MAAM;AAAA,QACV,GAAG;AAAA,QACJ,KAAK,WAAW,MAAM,MAAM;AAAA,QAC5B,aAAa;AAAA,QACb,SAAS,UAAU,UAAU;AAAA,QAC7B;AAAA,MAAA;AAAA,IAAA,CAEP;AAAA,EAAA,CAET,GACC,aACG,sBAAA,cAACG,OAAAA,QAAA,EAAc,OAAc,YAAY,aAAa,SAAS,gBAAgB,UAAU,WAAA,CAAY,IACrG,IACR;AAER;AAKA,SAAS,KAA2B,
|
|
1
|
+
{"version":3,"file":"AreaChart.cjs","sources":["../../../../src/charts/components/Area/AreaChart.tsx"],"sourcesContent":["import cn from 'clsx';\nimport React from 'react';\nimport * as RechartsPrimitive from 'recharts';\n\nimport { getAxisProps, stripCartesianProps } from '../../utils/common';\nimport { ChartWrapper } from '../ChartWrapper';\nimport { Legend } from '../Legend';\nimport { Tooltip } from '../Tooltip';\nimport type { ChartChildProps, CartesianChartProps, CurveType } from '../types';\nimport { useChart } from '../useChartData';\n\nexport type AreaChartProps<TData extends object> = {\n /** Show dots for each data point\n * @default false\n */\n showDots?: boolean;\n /** Stack areas on top of one another, instead of other each other. 'expand' fills the available space\n * @default false\n */\n stacked?: boolean | 'expand';\n /** Interpolation type of the line\n * @default natural\n */\n type?: CurveType;\n} & CartesianChartProps<TData>;\n\nexport function AreaChart<TData extends object>(props: AreaChartProps<TData>) {\n const {\n children,\n className: customClassName,\n data,\n showLegend = false,\n showDots = false,\n stacked = false,\n tooltipTitle,\n type = 'natural',\n ...attributes\n } = stripCartesianProps<AreaChartProps<TData>>(props);\n\n const className = cn('relative aspect-video', { 'pb-8': showLegend }, customClassName);\n const { items, shapes, activeIndex, setActiveIndex, toggleItem } = useChart<TData>(children);\n\n return (\n <div className={className} data-taco=\"chart-wrapper\">\n <ChartWrapper {...attributes} className=\"h-full w-full\" data-taco=\"chart-area\">\n <RechartsPrimitive.AreaChart\n data={data}\n margin={{\n bottom: 0,\n // ensures dots on the edges of the chart don't get cropped\n left: 4,\n right: 4,\n top: 4,\n }}\n stackOffset={stacked === 'expand' ? 'expand' : undefined}>\n <RechartsPrimitive.CartesianGrid vertical={false} />\n <RechartsPrimitive.Tooltip content={<Tooltip title={tooltipTitle} />} />\n <RechartsPrimitive.XAxis {...getAxisProps('x', props)} />\n <RechartsPrimitive.YAxis {...getAxisProps('y', props)} />\n {shapes.map(shape => (\n <RechartsPrimitive.Area\n key={shape.dataKey}\n {...shape}\n dot={showDots ? shape.dot : false}\n fillOpacity={0.4}\n stackId={stacked ? 'stack' : undefined}\n type={type}\n />\n ))}\n </RechartsPrimitive.AreaChart>\n </ChartWrapper>\n {showLegend ? (\n <Legend<TData> items={items} hoverIndex={activeIndex} onHover={setActiveIndex} onToggle={toggleItem} />\n ) : null}\n </div>\n );\n}\n\n// oxlint-disable-next-line no-empty-object-type\nexport type AreaChartAreaProps<TData extends object> = {} & ChartChildProps<TData>;\n\nfunction Area<TData extends object>(_: AreaChartAreaProps<TData>): React.JSX.Element | null {\n return null;\n}\nAreaChart.Area = Area;\n"],"names":["stripCartesianProps","useChart","ChartWrapper","RechartsPrimitive","Tooltip","getAxisProps","Legend"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;AA0BO,SAAS,UAAgC,OAA8B;AAC1E,QAAM;AAAA,IACF;AAAA,IACA,WAAW;AAAA,IACX;AAAA,IACA,aAAa;AAAA,IACb,WAAW;AAAA,IACX,UAAU;AAAA,IACV;AAAA,IACA,OAAO;AAAA,IACP,GAAG;AAAA,EAAA,IACHA,OAAAA,oBAA2C,KAAK;AAEpD,QAAM,YAAY,GAAG,yBAAyB,EAAE,QAAQ,WAAA,GAAc,eAAe;AACrF,QAAM,EAAE,OAAO,QAAQ,aAAa,gBAAgB,WAAA,IAAeC,aAAAA,SAAgB,QAAQ;AAE3F,SACI,sBAAA,cAAC,OAAA,EAAI,WAAsB,aAAU,gBAAA,GACjC,sBAAA,cAACC,aAAAA,cAAA,EAAc,GAAG,YAAY,WAAU,iBAAgB,aAAU,aAAA,GAC9D,sBAAA;AAAA,IAACC,6BAAkB;AAAA,IAAlB;AAAA,MACG;AAAA,MACA,QAAQ;AAAA,QACJ,QAAQ;AAAA;AAAA,QAER,MAAM;AAAA,QACN,OAAO;AAAA,QACP,KAAK;AAAA,MAAA;AAAA,MAET,aAAa,YAAY,WAAW,WAAW;AAAA,IAAA;AAAA,IAC/C,sBAAA,cAACA,6BAAkB,eAAlB,EAAgC,UAAU,OAAO;AAAA,IAClD,sBAAA,cAACA,6BAAkB,SAAlB,EAA0B,SAAS,sBAAA,cAACC,QAAAA,SAAA,EAAQ,OAAO,aAAA,CAAc,EAAA,CAAI;AAAA,IACtE,sBAAA,cAACD,6BAAkB,OAAlB,EAAyB,GAAGE,oBAAa,KAAK,KAAK,GAAG;AAAA,IACvD,sBAAA,cAACF,6BAAkB,OAAlB,EAAyB,GAAGE,oBAAa,KAAK,KAAK,GAAG;AAAA,IACtD,OAAO,IAAI,CAAA,UACR,sBAAA;AAAA,MAACF,6BAAkB;AAAA,MAAlB;AAAA,QACG,KAAK,MAAM;AAAA,QACV,GAAG;AAAA,QACJ,KAAK,WAAW,MAAM,MAAM;AAAA,QAC5B,aAAa;AAAA,QACb,SAAS,UAAU,UAAU;AAAA,QAC7B;AAAA,MAAA;AAAA,IAAA,CAEP;AAAA,EAAA,CAET,GACC,aACG,sBAAA,cAACG,OAAAA,QAAA,EAAc,OAAc,YAAY,aAAa,SAAS,gBAAgB,UAAU,WAAA,CAAY,IACrG,IACR;AAER;AAKA,SAAS,KAA2B,GAAwD;AACxF,SAAO;AACX;AACA,UAAU,OAAO;;"}
|
|
@@ -16,6 +16,6 @@ export type AreaChartProps<TData extends object> = {
|
|
|
16
16
|
} & CartesianChartProps<TData>;
|
|
17
17
|
export declare function AreaChart<TData extends object>(props: AreaChartProps<TData>): React.JSX.Element;
|
|
18
18
|
export declare namespace AreaChart {
|
|
19
|
-
var Area: <TData extends object>(_: AreaChartAreaProps<TData>) => JSX.Element | null;
|
|
19
|
+
var Area: <TData extends object>(_: AreaChartAreaProps<TData>) => React.JSX.Element | null;
|
|
20
20
|
}
|
|
21
21
|
export type AreaChartAreaProps<TData extends object> = {} & ChartChildProps<TData>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AreaChart.js","sources":["../../../../src/charts/components/Area/AreaChart.tsx"],"sourcesContent":["import cn from 'clsx';\nimport React from 'react';\nimport * as RechartsPrimitive from 'recharts';\n\nimport { getAxisProps, stripCartesianProps } from '../../utils/common';\nimport { ChartWrapper } from '../ChartWrapper';\nimport { Legend } from '../Legend';\nimport { Tooltip } from '../Tooltip';\nimport type { ChartChildProps, CartesianChartProps, CurveType } from '../types';\nimport { useChart } from '../useChartData';\n\nexport type AreaChartProps<TData extends object> = {\n /** Show dots for each data point\n * @default false\n */\n showDots?: boolean;\n /** Stack areas on top of one another, instead of other each other. 'expand' fills the available space\n * @default false\n */\n stacked?: boolean | 'expand';\n /** Interpolation type of the line\n * @default natural\n */\n type?: CurveType;\n} & CartesianChartProps<TData>;\n\nexport function AreaChart<TData extends object>(props: AreaChartProps<TData>) {\n const {\n children,\n className: customClassName,\n data,\n showLegend = false,\n showDots = false,\n stacked = false,\n tooltipTitle,\n type = 'natural',\n ...attributes\n } = stripCartesianProps<AreaChartProps<TData>>(props);\n\n const className = cn('relative aspect-video', { 'pb-8': showLegend }, customClassName);\n const { items, shapes, activeIndex, setActiveIndex, toggleItem } = useChart<TData>(children);\n\n return (\n <div className={className} data-taco=\"chart-wrapper\">\n <ChartWrapper {...attributes} className=\"h-full w-full\" data-taco=\"chart-area\">\n <RechartsPrimitive.AreaChart\n data={data}\n margin={{\n bottom: 0,\n // ensures dots on the edges of the chart don't get cropped\n left: 4,\n right: 4,\n top: 4,\n }}\n stackOffset={stacked === 'expand' ? 'expand' : undefined}>\n <RechartsPrimitive.CartesianGrid vertical={false} />\n <RechartsPrimitive.Tooltip content={<Tooltip title={tooltipTitle} />} />\n <RechartsPrimitive.XAxis {...getAxisProps('x', props)} />\n <RechartsPrimitive.YAxis {...getAxisProps('y', props)} />\n {shapes.map(shape => (\n <RechartsPrimitive.Area\n key={shape.dataKey}\n {...shape}\n dot={showDots ? shape.dot : false}\n fillOpacity={0.4}\n stackId={stacked ? 'stack' : undefined}\n type={type}\n />\n ))}\n </RechartsPrimitive.AreaChart>\n </ChartWrapper>\n {showLegend ? (\n <Legend<TData> items={items} hoverIndex={activeIndex} onHover={setActiveIndex} onToggle={toggleItem} />\n ) : null}\n </div>\n );\n}\n\n// oxlint-disable-next-line no-empty-object-type\nexport type AreaChartAreaProps<TData extends object> = {} & ChartChildProps<TData>;\n\nfunction Area<TData extends object>(_: AreaChartAreaProps<TData>): JSX.Element | null {\n return null;\n}\nAreaChart.Area = Area;\n"],"names":["React"],"mappings":";;;;;;;;AA0BO,SAAS,UAAgC,OAA8B;AAC1E,QAAM;AAAA,IACF;AAAA,IACA,WAAW;AAAA,IACX;AAAA,IACA,aAAa;AAAA,IACb,WAAW;AAAA,IACX,UAAU;AAAA,IACV;AAAA,IACA,OAAO;AAAA,IACP,GAAG;AAAA,EAAA,IACH,oBAA2C,KAAK;AAEpD,QAAM,YAAY,GAAG,yBAAyB,EAAE,QAAQ,WAAA,GAAc,eAAe;AACrF,QAAM,EAAE,OAAO,QAAQ,aAAa,gBAAgB,WAAA,IAAe,SAAgB,QAAQ;AAE3F,SACIA,+BAAA,cAAC,OAAA,EAAI,WAAsB,aAAU,gBAAA,GACjCA,+BAAA,cAAC,cAAA,EAAc,GAAG,YAAY,WAAU,iBAAgB,aAAU,aAAA,GAC9DA,+BAAA;AAAA,IAAC,kBAAkB;AAAA,IAAlB;AAAA,MACG;AAAA,MACA,QAAQ;AAAA,QACJ,QAAQ;AAAA;AAAA,QAER,MAAM;AAAA,QACN,OAAO;AAAA,QACP,KAAK;AAAA,MAAA;AAAA,MAET,aAAa,YAAY,WAAW,WAAW;AAAA,IAAA;AAAA,IAC/CA,+BAAA,cAAC,kBAAkB,eAAlB,EAAgC,UAAU,OAAO;AAAA,IAClDA,+BAAA,cAAC,kBAAkB,SAAlB,EAA0B,SAASA,+BAAA,cAAC,SAAA,EAAQ,OAAO,aAAA,CAAc,EAAA,CAAI;AAAA,IACtEA,+BAAA,cAAC,kBAAkB,OAAlB,EAAyB,GAAG,aAAa,KAAK,KAAK,GAAG;AAAA,IACvDA,+BAAA,cAAC,kBAAkB,OAAlB,EAAyB,GAAG,aAAa,KAAK,KAAK,GAAG;AAAA,IACtD,OAAO,IAAI,CAAA,UACRA,+BAAA;AAAA,MAAC,kBAAkB;AAAA,MAAlB;AAAA,QACG,KAAK,MAAM;AAAA,QACV,GAAG;AAAA,QACJ,KAAK,WAAW,MAAM,MAAM;AAAA,QAC5B,aAAa;AAAA,QACb,SAAS,UAAU,UAAU;AAAA,QAC7B;AAAA,MAAA;AAAA,IAAA,CAEP;AAAA,EAAA,CAET,GACC,aACGA,+BAAA,cAAC,QAAA,EAAc,OAAc,YAAY,aAAa,SAAS,gBAAgB,UAAU,WAAA,CAAY,IACrG,IACR;AAER;AAKA,SAAS,KAA2B,
|
|
1
|
+
{"version":3,"file":"AreaChart.js","sources":["../../../../src/charts/components/Area/AreaChart.tsx"],"sourcesContent":["import cn from 'clsx';\nimport React from 'react';\nimport * as RechartsPrimitive from 'recharts';\n\nimport { getAxisProps, stripCartesianProps } from '../../utils/common';\nimport { ChartWrapper } from '../ChartWrapper';\nimport { Legend } from '../Legend';\nimport { Tooltip } from '../Tooltip';\nimport type { ChartChildProps, CartesianChartProps, CurveType } from '../types';\nimport { useChart } from '../useChartData';\n\nexport type AreaChartProps<TData extends object> = {\n /** Show dots for each data point\n * @default false\n */\n showDots?: boolean;\n /** Stack areas on top of one another, instead of other each other. 'expand' fills the available space\n * @default false\n */\n stacked?: boolean | 'expand';\n /** Interpolation type of the line\n * @default natural\n */\n type?: CurveType;\n} & CartesianChartProps<TData>;\n\nexport function AreaChart<TData extends object>(props: AreaChartProps<TData>) {\n const {\n children,\n className: customClassName,\n data,\n showLegend = false,\n showDots = false,\n stacked = false,\n tooltipTitle,\n type = 'natural',\n ...attributes\n } = stripCartesianProps<AreaChartProps<TData>>(props);\n\n const className = cn('relative aspect-video', { 'pb-8': showLegend }, customClassName);\n const { items, shapes, activeIndex, setActiveIndex, toggleItem } = useChart<TData>(children);\n\n return (\n <div className={className} data-taco=\"chart-wrapper\">\n <ChartWrapper {...attributes} className=\"h-full w-full\" data-taco=\"chart-area\">\n <RechartsPrimitive.AreaChart\n data={data}\n margin={{\n bottom: 0,\n // ensures dots on the edges of the chart don't get cropped\n left: 4,\n right: 4,\n top: 4,\n }}\n stackOffset={stacked === 'expand' ? 'expand' : undefined}>\n <RechartsPrimitive.CartesianGrid vertical={false} />\n <RechartsPrimitive.Tooltip content={<Tooltip title={tooltipTitle} />} />\n <RechartsPrimitive.XAxis {...getAxisProps('x', props)} />\n <RechartsPrimitive.YAxis {...getAxisProps('y', props)} />\n {shapes.map(shape => (\n <RechartsPrimitive.Area\n key={shape.dataKey}\n {...shape}\n dot={showDots ? shape.dot : false}\n fillOpacity={0.4}\n stackId={stacked ? 'stack' : undefined}\n type={type}\n />\n ))}\n </RechartsPrimitive.AreaChart>\n </ChartWrapper>\n {showLegend ? (\n <Legend<TData> items={items} hoverIndex={activeIndex} onHover={setActiveIndex} onToggle={toggleItem} />\n ) : null}\n </div>\n );\n}\n\n// oxlint-disable-next-line no-empty-object-type\nexport type AreaChartAreaProps<TData extends object> = {} & ChartChildProps<TData>;\n\nfunction Area<TData extends object>(_: AreaChartAreaProps<TData>): React.JSX.Element | null {\n return null;\n}\nAreaChart.Area = Area;\n"],"names":["React"],"mappings":";;;;;;;;AA0BO,SAAS,UAAgC,OAA8B;AAC1E,QAAM;AAAA,IACF;AAAA,IACA,WAAW;AAAA,IACX;AAAA,IACA,aAAa;AAAA,IACb,WAAW;AAAA,IACX,UAAU;AAAA,IACV;AAAA,IACA,OAAO;AAAA,IACP,GAAG;AAAA,EAAA,IACH,oBAA2C,KAAK;AAEpD,QAAM,YAAY,GAAG,yBAAyB,EAAE,QAAQ,WAAA,GAAc,eAAe;AACrF,QAAM,EAAE,OAAO,QAAQ,aAAa,gBAAgB,WAAA,IAAe,SAAgB,QAAQ;AAE3F,SACIA,+BAAA,cAAC,OAAA,EAAI,WAAsB,aAAU,gBAAA,GACjCA,+BAAA,cAAC,cAAA,EAAc,GAAG,YAAY,WAAU,iBAAgB,aAAU,aAAA,GAC9DA,+BAAA;AAAA,IAAC,kBAAkB;AAAA,IAAlB;AAAA,MACG;AAAA,MACA,QAAQ;AAAA,QACJ,QAAQ;AAAA;AAAA,QAER,MAAM;AAAA,QACN,OAAO;AAAA,QACP,KAAK;AAAA,MAAA;AAAA,MAET,aAAa,YAAY,WAAW,WAAW;AAAA,IAAA;AAAA,IAC/CA,+BAAA,cAAC,kBAAkB,eAAlB,EAAgC,UAAU,OAAO;AAAA,IAClDA,+BAAA,cAAC,kBAAkB,SAAlB,EAA0B,SAASA,+BAAA,cAAC,SAAA,EAAQ,OAAO,aAAA,CAAc,EAAA,CAAI;AAAA,IACtEA,+BAAA,cAAC,kBAAkB,OAAlB,EAAyB,GAAG,aAAa,KAAK,KAAK,GAAG;AAAA,IACvDA,+BAAA,cAAC,kBAAkB,OAAlB,EAAyB,GAAG,aAAa,KAAK,KAAK,GAAG;AAAA,IACtD,OAAO,IAAI,CAAA,UACRA,+BAAA;AAAA,MAAC,kBAAkB;AAAA,MAAlB;AAAA,QACG,KAAK,MAAM;AAAA,QACV,GAAG;AAAA,QACJ,KAAK,WAAW,MAAM,MAAM;AAAA,QAC5B,aAAa;AAAA,QACb,SAAS,UAAU,UAAU;AAAA,QAC7B;AAAA,MAAA;AAAA,IAAA,CAEP;AAAA,EAAA,CAET,GACC,aACGA,+BAAA,cAAC,QAAA,EAAc,OAAc,YAAY,aAAa,SAAS,gBAAgB,UAAU,WAAA,CAAY,IACrG,IACR;AAER;AAKA,SAAS,KAA2B,GAAwD;AACxF,SAAO;AACX;AACA,UAAU,OAAO;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BarChart.cjs","sources":["../../../../src/charts/components/Bar/BarChart.tsx"],"sourcesContent":["import cn from 'clsx';\nimport React from 'react';\nimport * as RechartsPrimitive from 'recharts';\n\nimport { getInverseThemeColor } from '../../utils/color';\nimport { getAxisProps, stripCartesianProps } from '../../utils/common';\nimport { ChartWrapper } from '../ChartWrapper';\nimport { Legend } from '../Legend';\nimport { Tooltip } from '../Tooltip';\nimport type { ChartChildProps, CartesianChartProps } from '../types';\nimport type { ChartShape } from '../useChartData';\nimport { useChart } from '../useChartData';\n\nconst BAR_WIDTH = 18;\nexport type BarChartProps<TData extends object> = {\n /** Orientation of the bars\n * @default false\n */\n orientation?: 'horizontal' | 'vertical';\n /** Show bar values as labels next to/inside the bar\n * @default vertical\n */\n showLabels?: boolean;\n /** Stack bars on top of one another, instead of other each other. 'expand' fills the available space\n * @default false\n */\n stacked?: boolean | 'expand';\n} & CartesianChartProps<TData>;\n\nexport function BarChart<TData extends object>(props: BarChartProps<TData>) {\n const {\n children,\n className: customClassName,\n data,\n orientation: _1,\n showLabels = false,\n showLegend = false,\n stacked = false,\n tooltipTitle,\n ...attributes\n } = stripCartesianProps<BarChartProps<TData>>(props);\n const isHorizontal = props.orientation === 'horizontal';\n\n const className = cn('relative aspect-video', { 'pb-8': showLegend }, customClassName);\n const { items, shapes, activeIndex, setActiveIndex, toggleItem } = useChart<TData>(children);\n\n return (\n <div className={className} data-taco=\"chart-wrapper\">\n <ChartWrapper {...attributes} className=\"h-full w-full\" data-taco=\"chart-bar\">\n <RechartsPrimitive.BarChart\n data={data}\n // style props - these are % so that they \"look okay\" for really wide charts as well as small ones\n barCategoryGap=\"15%\"\n barGap=\"7.5%\"\n margin={{\n bottom: 0,\n left: 0,\n right: 0,\n // ensures labels on top of bars don't get cropped\n top: isHorizontal ? 0 : 10,\n }}\n layout={isHorizontal ? 'vertical' : undefined}\n stackOffset={stacked === 'expand' ? 'expand' : undefined}>\n <RechartsPrimitive.CartesianGrid horizontal={!isHorizontal} vertical={false} />\n <RechartsPrimitive.Tooltip content={<Tooltip title={tooltipTitle} />} />\n <RechartsPrimitive.XAxis {...getAxisProps('x', props, isHorizontal)} />\n <RechartsPrimitive.YAxis {...getAxisProps('y', props, isHorizontal)} />\n {renderBars(shapes, showLabels, stacked, isHorizontal)}\n </RechartsPrimitive.BarChart>\n </ChartWrapper>\n {showLegend ? (\n <Legend<TData> items={items} hoverIndex={activeIndex} onHover={setActiveIndex} onToggle={toggleItem} />\n ) : null}\n </div>\n );\n}\n/**\n * Helper function to render bar shapes as Recharts Bar primitives. Extracted to be reusable across BarChart and ComposedChart.\n */\nexport const renderBars = (\n shapes: ChartShape[],\n showLabels: boolean = false,\n stacked: boolean | 'expand' = false,\n isHorizontal: boolean = false\n) => {\n return shapes.map((shape, index) => (\n <RechartsPrimitive.Bar\n key={shape.dataKey}\n {...shape}\n activeBar={{ fillOpacity: 1, strokeWidth: 0 }}\n maxBarSize={BAR_WIDTH}\n radius={getRadius(index, shapes.length, !!stacked, isHorizontal)}\n stackId={stacked ? 'stack' : undefined}\n strokeWidth={0}>\n {showLabels ? (\n <RechartsPrimitive.LabelList\n position={isHorizontal ? 'insideRight' : 'top'}\n formatter={shape.formatter}\n offset={6}\n fill={isHorizontal ? getInverseThemeColor(shape.color ?? '') : 'black'}\n fontSize={11}\n />\n ) : null}\n </RechartsPrimitive.Bar>\n ));\n};\n\nfunction getRadius(\n index: number,\n length: number,\n stacked: boolean,\n isHorizontal: boolean\n): number | [number, number, number, number] {\n if (stacked) {\n if (index === 0) {\n return isHorizontal ? [3, 0, 0, 3] : [0, 0, 3, 3];\n }\n\n if (index === length - 1) {\n return isHorizontal ? [0, 3, 3, 0] : [3, 3, 0, 0];\n }\n\n return 0;\n }\n\n return 3;\n}\n\n// oxlint-disable-next-line no-empty-object-type\nexport type BarChartBarProps<TData extends object> = {} & ChartChildProps<TData>;\n\nfunction Bar<TData extends object>(_: BarChartBarProps<TData>): JSX.Element | null {\n return null;\n}\nBarChart.Bar = Bar;\n"],"names":["stripCartesianProps","useChart","ChartWrapper","RechartsPrimitive","Tooltip","getAxisProps","Legend","getInverseThemeColor"],"mappings":"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
|
|
1
|
+
{"version":3,"file":"BarChart.cjs","sources":["../../../../src/charts/components/Bar/BarChart.tsx"],"sourcesContent":["import cn from 'clsx';\nimport React from 'react';\nimport * as RechartsPrimitive from 'recharts';\n\nimport { getInverseThemeColor } from '../../utils/color';\nimport { getAxisProps, stripCartesianProps } from '../../utils/common';\nimport { ChartWrapper } from '../ChartWrapper';\nimport { Legend } from '../Legend';\nimport { Tooltip } from '../Tooltip';\nimport type { ChartChildProps, CartesianChartProps } from '../types';\nimport type { ChartShape } from '../useChartData';\nimport { useChart } from '../useChartData';\n\nconst BAR_WIDTH = 18;\nexport type BarChartProps<TData extends object> = {\n /** Orientation of the bars\n * @default false\n */\n orientation?: 'horizontal' | 'vertical';\n /** Show bar values as labels next to/inside the bar\n * @default vertical\n */\n showLabels?: boolean;\n /** Stack bars on top of one another, instead of other each other. 'expand' fills the available space\n * @default false\n */\n stacked?: boolean | 'expand';\n} & CartesianChartProps<TData>;\n\nexport function BarChart<TData extends object>(props: BarChartProps<TData>) {\n const {\n children,\n className: customClassName,\n data,\n orientation: _1,\n showLabels = false,\n showLegend = false,\n stacked = false,\n tooltipTitle,\n ...attributes\n } = stripCartesianProps<BarChartProps<TData>>(props);\n const isHorizontal = props.orientation === 'horizontal';\n\n const className = cn('relative aspect-video', { 'pb-8': showLegend }, customClassName);\n const { items, shapes, activeIndex, setActiveIndex, toggleItem } = useChart<TData>(children);\n\n return (\n <div className={className} data-taco=\"chart-wrapper\">\n <ChartWrapper {...attributes} className=\"h-full w-full\" data-taco=\"chart-bar\">\n <RechartsPrimitive.BarChart\n data={data}\n // style props - these are % so that they \"look okay\" for really wide charts as well as small ones\n barCategoryGap=\"15%\"\n barGap=\"7.5%\"\n margin={{\n bottom: 0,\n left: 0,\n right: 0,\n // ensures labels on top of bars don't get cropped\n top: isHorizontal ? 0 : 10,\n }}\n layout={isHorizontal ? 'vertical' : undefined}\n stackOffset={stacked === 'expand' ? 'expand' : undefined}>\n <RechartsPrimitive.CartesianGrid horizontal={!isHorizontal} vertical={false} />\n <RechartsPrimitive.Tooltip content={<Tooltip title={tooltipTitle} />} />\n <RechartsPrimitive.XAxis {...getAxisProps('x', props, isHorizontal)} />\n <RechartsPrimitive.YAxis {...getAxisProps('y', props, isHorizontal)} />\n {renderBars(shapes, showLabels, stacked, isHorizontal)}\n </RechartsPrimitive.BarChart>\n </ChartWrapper>\n {showLegend ? (\n <Legend<TData> items={items} hoverIndex={activeIndex} onHover={setActiveIndex} onToggle={toggleItem} />\n ) : null}\n </div>\n );\n}\n/**\n * Helper function to render bar shapes as Recharts Bar primitives. Extracted to be reusable across BarChart and ComposedChart.\n */\nexport const renderBars = (\n shapes: ChartShape[],\n showLabels: boolean = false,\n stacked: boolean | 'expand' = false,\n isHorizontal: boolean = false\n) => {\n return shapes.map((shape, index) => (\n <RechartsPrimitive.Bar\n key={shape.dataKey}\n {...shape}\n activeBar={{ fillOpacity: 1, strokeWidth: 0 }}\n maxBarSize={BAR_WIDTH}\n radius={getRadius(index, shapes.length, !!stacked, isHorizontal)}\n stackId={stacked ? 'stack' : undefined}\n strokeWidth={0}>\n {showLabels ? (\n <RechartsPrimitive.LabelList\n position={isHorizontal ? 'insideRight' : 'top'}\n formatter={shape.formatter}\n offset={6}\n fill={isHorizontal ? getInverseThemeColor(shape.color ?? '') : 'black'}\n fontSize={11}\n />\n ) : null}\n </RechartsPrimitive.Bar>\n ));\n};\n\nfunction getRadius(\n index: number,\n length: number,\n stacked: boolean,\n isHorizontal: boolean\n): number | [number, number, number, number] {\n if (stacked) {\n if (index === 0) {\n return isHorizontal ? [3, 0, 0, 3] : [0, 0, 3, 3];\n }\n\n if (index === length - 1) {\n return isHorizontal ? [0, 3, 3, 0] : [3, 3, 0, 0];\n }\n\n return 0;\n }\n\n return 3;\n}\n\n// oxlint-disable-next-line no-empty-object-type\nexport type BarChartBarProps<TData extends object> = {} & ChartChildProps<TData>;\n\nfunction Bar<TData extends object>(_: BarChartBarProps<TData>): React.JSX.Element | null {\n return null;\n}\nBarChart.Bar = Bar;\n"],"names":["stripCartesianProps","useChart","ChartWrapper","RechartsPrimitive","Tooltip","getAxisProps","Legend","getInverseThemeColor"],"mappings":"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"}
|
|
@@ -17,7 +17,7 @@ export type BarChartProps<TData extends object> = {
|
|
|
17
17
|
} & CartesianChartProps<TData>;
|
|
18
18
|
export declare function BarChart<TData extends object>(props: BarChartProps<TData>): React.JSX.Element;
|
|
19
19
|
export declare namespace BarChart {
|
|
20
|
-
var Bar: <TData extends object>(_: BarChartBarProps<TData>) => JSX.Element | null;
|
|
20
|
+
var Bar: <TData extends object>(_: BarChartBarProps<TData>) => React.JSX.Element | null;
|
|
21
21
|
}
|
|
22
22
|
/**
|
|
23
23
|
* Helper function to render bar shapes as Recharts Bar primitives. Extracted to be reusable across BarChart and ComposedChart.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BarChart.js","sources":["../../../../src/charts/components/Bar/BarChart.tsx"],"sourcesContent":["import cn from 'clsx';\nimport React from 'react';\nimport * as RechartsPrimitive from 'recharts';\n\nimport { getInverseThemeColor } from '../../utils/color';\nimport { getAxisProps, stripCartesianProps } from '../../utils/common';\nimport { ChartWrapper } from '../ChartWrapper';\nimport { Legend } from '../Legend';\nimport { Tooltip } from '../Tooltip';\nimport type { ChartChildProps, CartesianChartProps } from '../types';\nimport type { ChartShape } from '../useChartData';\nimport { useChart } from '../useChartData';\n\nconst BAR_WIDTH = 18;\nexport type BarChartProps<TData extends object> = {\n /** Orientation of the bars\n * @default false\n */\n orientation?: 'horizontal' | 'vertical';\n /** Show bar values as labels next to/inside the bar\n * @default vertical\n */\n showLabels?: boolean;\n /** Stack bars on top of one another, instead of other each other. 'expand' fills the available space\n * @default false\n */\n stacked?: boolean | 'expand';\n} & CartesianChartProps<TData>;\n\nexport function BarChart<TData extends object>(props: BarChartProps<TData>) {\n const {\n children,\n className: customClassName,\n data,\n orientation: _1,\n showLabels = false,\n showLegend = false,\n stacked = false,\n tooltipTitle,\n ...attributes\n } = stripCartesianProps<BarChartProps<TData>>(props);\n const isHorizontal = props.orientation === 'horizontal';\n\n const className = cn('relative aspect-video', { 'pb-8': showLegend }, customClassName);\n const { items, shapes, activeIndex, setActiveIndex, toggleItem } = useChart<TData>(children);\n\n return (\n <div className={className} data-taco=\"chart-wrapper\">\n <ChartWrapper {...attributes} className=\"h-full w-full\" data-taco=\"chart-bar\">\n <RechartsPrimitive.BarChart\n data={data}\n // style props - these are % so that they \"look okay\" for really wide charts as well as small ones\n barCategoryGap=\"15%\"\n barGap=\"7.5%\"\n margin={{\n bottom: 0,\n left: 0,\n right: 0,\n // ensures labels on top of bars don't get cropped\n top: isHorizontal ? 0 : 10,\n }}\n layout={isHorizontal ? 'vertical' : undefined}\n stackOffset={stacked === 'expand' ? 'expand' : undefined}>\n <RechartsPrimitive.CartesianGrid horizontal={!isHorizontal} vertical={false} />\n <RechartsPrimitive.Tooltip content={<Tooltip title={tooltipTitle} />} />\n <RechartsPrimitive.XAxis {...getAxisProps('x', props, isHorizontal)} />\n <RechartsPrimitive.YAxis {...getAxisProps('y', props, isHorizontal)} />\n {renderBars(shapes, showLabels, stacked, isHorizontal)}\n </RechartsPrimitive.BarChart>\n </ChartWrapper>\n {showLegend ? (\n <Legend<TData> items={items} hoverIndex={activeIndex} onHover={setActiveIndex} onToggle={toggleItem} />\n ) : null}\n </div>\n );\n}\n/**\n * Helper function to render bar shapes as Recharts Bar primitives. Extracted to be reusable across BarChart and ComposedChart.\n */\nexport const renderBars = (\n shapes: ChartShape[],\n showLabels: boolean = false,\n stacked: boolean | 'expand' = false,\n isHorizontal: boolean = false\n) => {\n return shapes.map((shape, index) => (\n <RechartsPrimitive.Bar\n key={shape.dataKey}\n {...shape}\n activeBar={{ fillOpacity: 1, strokeWidth: 0 }}\n maxBarSize={BAR_WIDTH}\n radius={getRadius(index, shapes.length, !!stacked, isHorizontal)}\n stackId={stacked ? 'stack' : undefined}\n strokeWidth={0}>\n {showLabels ? (\n <RechartsPrimitive.LabelList\n position={isHorizontal ? 'insideRight' : 'top'}\n formatter={shape.formatter}\n offset={6}\n fill={isHorizontal ? getInverseThemeColor(shape.color ?? '') : 'black'}\n fontSize={11}\n />\n ) : null}\n </RechartsPrimitive.Bar>\n ));\n};\n\nfunction getRadius(\n index: number,\n length: number,\n stacked: boolean,\n isHorizontal: boolean\n): number | [number, number, number, number] {\n if (stacked) {\n if (index === 0) {\n return isHorizontal ? [3, 0, 0, 3] : [0, 0, 3, 3];\n }\n\n if (index === length - 1) {\n return isHorizontal ? [0, 3, 3, 0] : [3, 3, 0, 0];\n }\n\n return 0;\n }\n\n return 3;\n}\n\n// oxlint-disable-next-line no-empty-object-type\nexport type BarChartBarProps<TData extends object> = {} & ChartChildProps<TData>;\n\nfunction Bar<TData extends object>(_: BarChartBarProps<TData>): JSX.Element | null {\n return null;\n}\nBarChart.Bar = Bar;\n"],"names":["React"],"mappings":"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
|
|
1
|
+
{"version":3,"file":"BarChart.js","sources":["../../../../src/charts/components/Bar/BarChart.tsx"],"sourcesContent":["import cn from 'clsx';\nimport React from 'react';\nimport * as RechartsPrimitive from 'recharts';\n\nimport { getInverseThemeColor } from '../../utils/color';\nimport { getAxisProps, stripCartesianProps } from '../../utils/common';\nimport { ChartWrapper } from '../ChartWrapper';\nimport { Legend } from '../Legend';\nimport { Tooltip } from '../Tooltip';\nimport type { ChartChildProps, CartesianChartProps } from '../types';\nimport type { ChartShape } from '../useChartData';\nimport { useChart } from '../useChartData';\n\nconst BAR_WIDTH = 18;\nexport type BarChartProps<TData extends object> = {\n /** Orientation of the bars\n * @default false\n */\n orientation?: 'horizontal' | 'vertical';\n /** Show bar values as labels next to/inside the bar\n * @default vertical\n */\n showLabels?: boolean;\n /** Stack bars on top of one another, instead of other each other. 'expand' fills the available space\n * @default false\n */\n stacked?: boolean | 'expand';\n} & CartesianChartProps<TData>;\n\nexport function BarChart<TData extends object>(props: BarChartProps<TData>) {\n const {\n children,\n className: customClassName,\n data,\n orientation: _1,\n showLabels = false,\n showLegend = false,\n stacked = false,\n tooltipTitle,\n ...attributes\n } = stripCartesianProps<BarChartProps<TData>>(props);\n const isHorizontal = props.orientation === 'horizontal';\n\n const className = cn('relative aspect-video', { 'pb-8': showLegend }, customClassName);\n const { items, shapes, activeIndex, setActiveIndex, toggleItem } = useChart<TData>(children);\n\n return (\n <div className={className} data-taco=\"chart-wrapper\">\n <ChartWrapper {...attributes} className=\"h-full w-full\" data-taco=\"chart-bar\">\n <RechartsPrimitive.BarChart\n data={data}\n // style props - these are % so that they \"look okay\" for really wide charts as well as small ones\n barCategoryGap=\"15%\"\n barGap=\"7.5%\"\n margin={{\n bottom: 0,\n left: 0,\n right: 0,\n // ensures labels on top of bars don't get cropped\n top: isHorizontal ? 0 : 10,\n }}\n layout={isHorizontal ? 'vertical' : undefined}\n stackOffset={stacked === 'expand' ? 'expand' : undefined}>\n <RechartsPrimitive.CartesianGrid horizontal={!isHorizontal} vertical={false} />\n <RechartsPrimitive.Tooltip content={<Tooltip title={tooltipTitle} />} />\n <RechartsPrimitive.XAxis {...getAxisProps('x', props, isHorizontal)} />\n <RechartsPrimitive.YAxis {...getAxisProps('y', props, isHorizontal)} />\n {renderBars(shapes, showLabels, stacked, isHorizontal)}\n </RechartsPrimitive.BarChart>\n </ChartWrapper>\n {showLegend ? (\n <Legend<TData> items={items} hoverIndex={activeIndex} onHover={setActiveIndex} onToggle={toggleItem} />\n ) : null}\n </div>\n );\n}\n/**\n * Helper function to render bar shapes as Recharts Bar primitives. Extracted to be reusable across BarChart and ComposedChart.\n */\nexport const renderBars = (\n shapes: ChartShape[],\n showLabels: boolean = false,\n stacked: boolean | 'expand' = false,\n isHorizontal: boolean = false\n) => {\n return shapes.map((shape, index) => (\n <RechartsPrimitive.Bar\n key={shape.dataKey}\n {...shape}\n activeBar={{ fillOpacity: 1, strokeWidth: 0 }}\n maxBarSize={BAR_WIDTH}\n radius={getRadius(index, shapes.length, !!stacked, isHorizontal)}\n stackId={stacked ? 'stack' : undefined}\n strokeWidth={0}>\n {showLabels ? (\n <RechartsPrimitive.LabelList\n position={isHorizontal ? 'insideRight' : 'top'}\n formatter={shape.formatter}\n offset={6}\n fill={isHorizontal ? getInverseThemeColor(shape.color ?? '') : 'black'}\n fontSize={11}\n />\n ) : null}\n </RechartsPrimitive.Bar>\n ));\n};\n\nfunction getRadius(\n index: number,\n length: number,\n stacked: boolean,\n isHorizontal: boolean\n): number | [number, number, number, number] {\n if (stacked) {\n if (index === 0) {\n return isHorizontal ? [3, 0, 0, 3] : [0, 0, 3, 3];\n }\n\n if (index === length - 1) {\n return isHorizontal ? [0, 3, 3, 0] : [3, 3, 0, 0];\n }\n\n return 0;\n }\n\n return 3;\n}\n\n// oxlint-disable-next-line no-empty-object-type\nexport type BarChartBarProps<TData extends object> = {} & ChartChildProps<TData>;\n\nfunction Bar<TData extends object>(_: BarChartBarProps<TData>): React.JSX.Element | null {\n return null;\n}\nBarChart.Bar = Bar;\n"],"names":["React"],"mappings":";;;;;;;;;AAaA,MAAM,YAAY;AAgBX,SAAS,SAA+B,OAA6B;AACxE,QAAM;AAAA,IACF;AAAA,IACA,WAAW;AAAA,IACX;AAAA,IACA,aAAa;AAAA,IACb,aAAa;AAAA,IACb,aAAa;AAAA,IACb,UAAU;AAAA,IACV;AAAA,IACA,GAAG;AAAA,EAAA,IACH,oBAA0C,KAAK;AACnD,QAAM,eAAe,MAAM,gBAAgB;AAE3C,QAAM,YAAY,GAAG,yBAAyB,EAAE,QAAQ,WAAA,GAAc,eAAe;AACrF,QAAM,EAAE,OAAO,QAAQ,aAAa,gBAAgB,WAAA,IAAe,SAAgB,QAAQ;AAE3F,SACIA,+BAAA,cAAC,OAAA,EAAI,WAAsB,aAAU,gBAAA,GACjCA,+BAAA,cAAC,cAAA,EAAc,GAAG,YAAY,WAAU,iBAAgB,aAAU,YAAA,GAC9DA,+BAAA;AAAA,IAAC,kBAAkB;AAAA,IAAlB;AAAA,MACG;AAAA,MAEA,gBAAe;AAAA,MACf,QAAO;AAAA,MACP,QAAQ;AAAA,QACJ,QAAQ;AAAA,QACR,MAAM;AAAA,QACN,OAAO;AAAA;AAAA,QAEP,KAAK,eAAe,IAAI;AAAA,MAAA;AAAA,MAE5B,QAAQ,eAAe,aAAa;AAAA,MACpC,aAAa,YAAY,WAAW,WAAW;AAAA,IAAA;AAAA,IAC/CA,+BAAA,cAAC,kBAAkB,eAAlB,EAAgC,YAAY,CAAC,cAAc,UAAU,OAAO;AAAA,IAC7EA,+BAAA,cAAC,kBAAkB,SAAlB,EAA0B,SAASA,+BAAA,cAAC,SAAA,EAAQ,OAAO,aAAA,CAAc,EAAA,CAAI;AAAA,IACtEA,+BAAA,cAAC,kBAAkB,OAAlB,EAAyB,GAAG,aAAa,KAAK,OAAO,YAAY,GAAG;AAAA,IACrEA,+BAAA,cAAC,kBAAkB,OAAlB,EAAyB,GAAG,aAAa,KAAK,OAAO,YAAY,GAAG;AAAA,IACpE,WAAW,QAAQ,YAAY,SAAS,YAAY;AAAA,EAAA,CAE7D,GACC,aACGA,+BAAA,cAAC,QAAA,EAAc,OAAc,YAAY,aAAa,SAAS,gBAAgB,UAAU,WAAA,CAAY,IACrG,IACR;AAER;AAIO,MAAM,aAAa,CACtB,QACA,aAAsB,OACtB,UAA8B,OAC9B,eAAwB,UACvB;AACD,SAAO,OAAO,IAAI,CAAC,OAAO,UACtBA,+BAAA;AAAA,IAAC,kBAAkB;AAAA,IAAlB;AAAA,MACG,KAAK,MAAM;AAAA,MACV,GAAG;AAAA,MACJ,WAAW,EAAE,aAAa,GAAG,aAAa,EAAA;AAAA,MAC1C,YAAY;AAAA,MACZ,QAAQ,UAAU,OAAO,OAAO,QAAQ,CAAC,CAAC,SAAS,YAAY;AAAA,MAC/D,SAAS,UAAU,UAAU;AAAA,MAC7B,aAAa;AAAA,IAAA;AAAA,IACZ,aACGA,+BAAA;AAAA,MAAC,kBAAkB;AAAA,MAAlB;AAAA,QACG,UAAU,eAAe,gBAAgB;AAAA,QACzC,WAAW,MAAM;AAAA,QACjB,QAAQ;AAAA,QACR,MAAM,eAAe,qBAAqB,MAAM,SAAS,EAAE,IAAI;AAAA,QAC/D,UAAU;AAAA,MAAA;AAAA,IAAA,IAEd;AAAA,EAAA,CAEX;AACL;AAEA,SAAS,UACL,OACA,QACA,SACA,cACyC;AACzC,MAAI,SAAS;AACT,QAAI,UAAU,GAAG;AACb,aAAO,eAAe,CAAC,GAAG,GAAG,GAAG,CAAC,IAAI,CAAC,GAAG,GAAG,GAAG,CAAC;AAAA,IACpD;AAEA,QAAI,UAAU,SAAS,GAAG;AACtB,aAAO,eAAe,CAAC,GAAG,GAAG,GAAG,CAAC,IAAI,CAAC,GAAG,GAAG,GAAG,CAAC;AAAA,IACpD;AAEA,WAAO;AAAA,EACX;AAEA,SAAO;AACX;AAKA,SAAS,IAA0B,GAAsD;AACrF,SAAO;AACX;AACA,SAAS,MAAM;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BarLineChart.cjs","sources":["../../../../src/charts/components/Composed/BarLineChart.tsx"],"sourcesContent":["import cn from 'clsx';\nimport React from 'react';\nimport * as RechartsPrimitive from 'recharts';\n\nimport { getAxisProps, stripCartesianProps } from '../../utils/common';\nimport { renderBars } from '../Bar/BarChart';\nimport { ChartWrapper } from '../ChartWrapper';\nimport { Legend } from '../Legend';\nimport { renderLines } from '../Line/LineChart';\nimport { Tooltip } from '../Tooltip';\nimport type { ChartChildProps, CartesianChartProps, CurveType } from '../types';\nimport { useChart } from '../useChartData';\n\nexport type BarLineChartProps<TData extends object> = {\n /** Show bar values as labels next to/inside the bar\n * @default false\n */\n showLabels?: boolean;\n /** Stack bars on top of one another, instead of next to each other. 'expand' fills the available space\n * @default false\n */\n stacked?: boolean | 'expand';\n /** Show dots for each data point on lines\n * @default false\n */\n showDots?: boolean;\n /** Interpolation type of the line\n * @default linear\n */\n lineType?: CurveType;\n} & CartesianChartProps<TData>;\n\nexport function BarLineChart<TData extends object>(props: BarLineChartProps<TData>) {\n const {\n children,\n className: customClassName,\n data,\n showLabels = false,\n showLegend = false,\n stacked = false,\n showDots = false,\n lineType = 'linear',\n tooltipTitle,\n ...attributes\n } = stripCartesianProps<BarLineChartProps<TData>>(props);\n\n const className = cn('relative aspect-video', { 'pb-8': showLegend }, customClassName);\n const { items, shapes, activeIndex, setActiveIndex, toggleItem } = useChart<TData>(children);\n\n // Separate bars and lines based on child component type to identify bar dataKeys\n const barChildren = React.Children.toArray(children).filter(child => React.isValidElement(child) && child.type === Bar);\n // Apply same fallback as useChart: dataKey ?? label\n const barDataKeys = new Set(\n barChildren\n .filter(child => React.isValidElement<ChartChildProps<TData>>(child))\n .map(child => {\n const props = (child as React.ReactElement<ChartChildProps<TData>>).props;\n return props.dataKey ?? props.label;\n })\n );\n\n // Filter shapes from the main useChart call in order to ensure we are not rendering bars or lines that are currently hidden.\n const barShapes = shapes.filter(shape => barDataKeys.has(shape.dataKey as keyof TData & string));\n const lineShapes = shapes.filter(shape => !barDataKeys.has(shape.dataKey as keyof TData & string));\n\n return (\n <div className={className} data-taco=\"chart-wrapper\">\n <ChartWrapper {...attributes} className=\"h-full w-full\" data-taco=\"chart-bar-line\">\n <RechartsPrimitive.ComposedChart\n data={data}\n barCategoryGap=\"15%\"\n barGap=\"7.5%\"\n margin={{\n bottom: 0,\n left: 4,\n right: 4,\n top: 10,\n }}\n stackOffset={stacked === 'expand' ? 'expand' : undefined}>\n <RechartsPrimitive.CartesianGrid vertical={false} />\n <RechartsPrimitive.Tooltip content={<Tooltip title={tooltipTitle} />} />\n <RechartsPrimitive.XAxis {...getAxisProps('x', props)} />\n <RechartsPrimitive.YAxis {...getAxisProps('y', props)} />\n {renderBars(barShapes, showLabels, stacked, false)}\n {renderLines(lineShapes, showDots, lineType)}\n </RechartsPrimitive.ComposedChart>\n </ChartWrapper>\n {showLegend ? (\n <Legend<TData> items={items} hoverIndex={activeIndex} onHover={setActiveIndex} onToggle={toggleItem} />\n ) : null}\n </div>\n );\n}\n\n// oxlint-disable-next-line no-empty-object-type\nexport type BarLineChartBarProps<TData extends object> = {} & ChartChildProps<TData>;\n\nfunction Bar<TData extends object>(_: BarLineChartBarProps<TData>): JSX.Element | null {\n return null;\n}\n\n// oxlint-disable-next-line no-empty-object-type\nexport type BarLineChartLineProps<TData extends object> = {} & ChartChildProps<TData>;\n\nfunction Line<TData extends object>(_: BarLineChartLineProps<TData>): JSX.Element | null {\n return null;\n}\n\n// Attach the marker components to BarLineChart\nBarLineChart.Bar = Bar;\nBarLineChart.Line = Line;\n"],"names":["stripCartesianProps","useChart","props","ChartWrapper","RechartsPrimitive","Tooltip","getAxisProps","renderBars","renderLines","Legend"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAgCO,SAAS,aAAmC,OAAiC;AAChF,QAAM;AAAA,IACF;AAAA,IACA,WAAW;AAAA,IACX;AAAA,IACA,aAAa;AAAA,IACb,aAAa;AAAA,IACb,UAAU;AAAA,IACV,WAAW;AAAA,IACX,WAAW;AAAA,IACX;AAAA,IACA,GAAG;AAAA,EAAA,IACHA,OAAAA,oBAA8C,KAAK;AAEvD,QAAM,YAAY,GAAG,yBAAyB,EAAE,QAAQ,WAAA,GAAc,eAAe;AACrF,QAAM,EAAE,OAAO,QAAQ,aAAa,gBAAgB,WAAA,IAAeC,aAAAA,SAAgB,QAAQ;AAG3F,QAAM,cAAc,MAAM,SAAS,QAAQ,QAAQ,EAAE,OAAO,CAAA,UAAS,MAAM,eAAe,KAAK,KAAK,MAAM,SAAS,GAAG;AAEtH,QAAM,cAAc,IAAI;AAAA,IACpB,YACK,OAAO,CAAA,UAAS,MAAM,eAAuC,KAAK,CAAC,EACnE,IAAI,CAAA,UAAS;AACV,YAAMC,SAAS,MAAqD;AACpE,aAAOA,OAAM,WAAWA,OAAM;AAAA,IAClC,CAAC;AAAA,EAAA;AAIT,QAAM,YAAY,OAAO,OAAO,CAAA,UAAS,YAAY,IAAI,MAAM,OAA+B,CAAC;AAC/F,QAAM,aAAa,OAAO,OAAO,CAAA,UAAS,CAAC,YAAY,IAAI,MAAM,OAA+B,CAAC;AAEjG,SACI,sBAAA,cAAC,OAAA,EAAI,WAAsB,aAAU,gBAAA,GACjC,sBAAA,cAACC,aAAAA,cAAA,EAAc,GAAG,YAAY,WAAU,iBAAgB,aAAU,iBAAA,GAC9D,sBAAA;AAAA,IAACC,6BAAkB;AAAA,IAAlB;AAAA,MACG;AAAA,MACA,gBAAe;AAAA,MACf,QAAO;AAAA,MACP,QAAQ;AAAA,QACJ,QAAQ;AAAA,QACR,MAAM;AAAA,QACN,OAAO;AAAA,QACP,KAAK;AAAA,MAAA;AAAA,MAET,aAAa,YAAY,WAAW,WAAW;AAAA,IAAA;AAAA,IAC/C,sBAAA,cAACA,6BAAkB,eAAlB,EAAgC,UAAU,OAAO;AAAA,IAClD,sBAAA,cAACA,6BAAkB,SAAlB,EAA0B,SAAS,sBAAA,cAACC,QAAAA,SAAA,EAAQ,OAAO,aAAA,CAAc,EAAA,CAAI;AAAA,IACtE,sBAAA,cAACD,6BAAkB,OAAlB,EAAyB,GAAGE,oBAAa,KAAK,KAAK,GAAG;AAAA,IACvD,sBAAA,cAACF,6BAAkB,OAAlB,EAAyB,GAAGE,oBAAa,KAAK,KAAK,GAAG;AAAA,IACtDC,SAAAA,WAAW,WAAW,YAAY,SAAS,KAAK;AAAA,IAChDC,sBAAY,YAAY,UAAU,QAAQ;AAAA,EAAA,CAEnD,GACC,aACG,sBAAA,cAACC,OAAAA,QAAA,EAAc,OAAc,YAAY,aAAa,SAAS,gBAAgB,UAAU,WAAA,CAAY,IACrG,IACR;AAER;AAKA,SAAS,IAA0B,
|
|
1
|
+
{"version":3,"file":"BarLineChart.cjs","sources":["../../../../src/charts/components/Composed/BarLineChart.tsx"],"sourcesContent":["import cn from 'clsx';\nimport React from 'react';\nimport * as RechartsPrimitive from 'recharts';\n\nimport { getAxisProps, stripCartesianProps } from '../../utils/common';\nimport { renderBars } from '../Bar/BarChart';\nimport { ChartWrapper } from '../ChartWrapper';\nimport { Legend } from '../Legend';\nimport { renderLines } from '../Line/LineChart';\nimport { Tooltip } from '../Tooltip';\nimport type { ChartChildProps, CartesianChartProps, CurveType } from '../types';\nimport { useChart } from '../useChartData';\n\nexport type BarLineChartProps<TData extends object> = {\n /** Show bar values as labels next to/inside the bar\n * @default false\n */\n showLabels?: boolean;\n /** Stack bars on top of one another, instead of next to each other. 'expand' fills the available space\n * @default false\n */\n stacked?: boolean | 'expand';\n /** Show dots for each data point on lines\n * @default false\n */\n showDots?: boolean;\n /** Interpolation type of the line\n * @default linear\n */\n lineType?: CurveType;\n} & CartesianChartProps<TData>;\n\nexport function BarLineChart<TData extends object>(props: BarLineChartProps<TData>) {\n const {\n children,\n className: customClassName,\n data,\n showLabels = false,\n showLegend = false,\n stacked = false,\n showDots = false,\n lineType = 'linear',\n tooltipTitle,\n ...attributes\n } = stripCartesianProps<BarLineChartProps<TData>>(props);\n\n const className = cn('relative aspect-video', { 'pb-8': showLegend }, customClassName);\n const { items, shapes, activeIndex, setActiveIndex, toggleItem } = useChart<TData>(children);\n\n // Separate bars and lines based on child component type to identify bar dataKeys\n const barChildren = React.Children.toArray(children).filter(child => React.isValidElement(child) && child.type === Bar);\n // Apply same fallback as useChart: dataKey ?? label\n const barDataKeys = new Set(\n barChildren\n .filter(child => React.isValidElement<ChartChildProps<TData>>(child))\n .map(child => {\n const props = (child as React.ReactElement<ChartChildProps<TData>>).props;\n return props.dataKey ?? props.label;\n })\n );\n\n // Filter shapes from the main useChart call in order to ensure we are not rendering bars or lines that are currently hidden.\n const barShapes = shapes.filter(shape => barDataKeys.has(shape.dataKey as keyof TData & string));\n const lineShapes = shapes.filter(shape => !barDataKeys.has(shape.dataKey as keyof TData & string));\n\n return (\n <div className={className} data-taco=\"chart-wrapper\">\n <ChartWrapper {...attributes} className=\"h-full w-full\" data-taco=\"chart-bar-line\">\n <RechartsPrimitive.ComposedChart\n data={data}\n barCategoryGap=\"15%\"\n barGap=\"7.5%\"\n margin={{\n bottom: 0,\n left: 4,\n right: 4,\n top: 10,\n }}\n stackOffset={stacked === 'expand' ? 'expand' : undefined}>\n <RechartsPrimitive.CartesianGrid vertical={false} />\n <RechartsPrimitive.Tooltip content={<Tooltip title={tooltipTitle} />} />\n <RechartsPrimitive.XAxis {...getAxisProps('x', props)} />\n <RechartsPrimitive.YAxis {...getAxisProps('y', props)} />\n {renderBars(barShapes, showLabels, stacked, false)}\n {renderLines(lineShapes, showDots, lineType)}\n </RechartsPrimitive.ComposedChart>\n </ChartWrapper>\n {showLegend ? (\n <Legend<TData> items={items} hoverIndex={activeIndex} onHover={setActiveIndex} onToggle={toggleItem} />\n ) : null}\n </div>\n );\n}\n\n// oxlint-disable-next-line no-empty-object-type\nexport type BarLineChartBarProps<TData extends object> = {} & ChartChildProps<TData>;\n\nfunction Bar<TData extends object>(_: BarLineChartBarProps<TData>): React.JSX.Element | null {\n return null;\n}\n\n// oxlint-disable-next-line no-empty-object-type\nexport type BarLineChartLineProps<TData extends object> = {} & ChartChildProps<TData>;\n\nfunction Line<TData extends object>(_: BarLineChartLineProps<TData>): React.JSX.Element | null {\n return null;\n}\n\n// Attach the marker components to BarLineChart\nBarLineChart.Bar = Bar;\nBarLineChart.Line = Line;\n"],"names":["stripCartesianProps","useChart","props","ChartWrapper","RechartsPrimitive","Tooltip","getAxisProps","renderBars","renderLines","Legend"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAgCO,SAAS,aAAmC,OAAiC;AAChF,QAAM;AAAA,IACF;AAAA,IACA,WAAW;AAAA,IACX;AAAA,IACA,aAAa;AAAA,IACb,aAAa;AAAA,IACb,UAAU;AAAA,IACV,WAAW;AAAA,IACX,WAAW;AAAA,IACX;AAAA,IACA,GAAG;AAAA,EAAA,IACHA,OAAAA,oBAA8C,KAAK;AAEvD,QAAM,YAAY,GAAG,yBAAyB,EAAE,QAAQ,WAAA,GAAc,eAAe;AACrF,QAAM,EAAE,OAAO,QAAQ,aAAa,gBAAgB,WAAA,IAAeC,aAAAA,SAAgB,QAAQ;AAG3F,QAAM,cAAc,MAAM,SAAS,QAAQ,QAAQ,EAAE,OAAO,CAAA,UAAS,MAAM,eAAe,KAAK,KAAK,MAAM,SAAS,GAAG;AAEtH,QAAM,cAAc,IAAI;AAAA,IACpB,YACK,OAAO,CAAA,UAAS,MAAM,eAAuC,KAAK,CAAC,EACnE,IAAI,CAAA,UAAS;AACV,YAAMC,SAAS,MAAqD;AACpE,aAAOA,OAAM,WAAWA,OAAM;AAAA,IAClC,CAAC;AAAA,EAAA;AAIT,QAAM,YAAY,OAAO,OAAO,CAAA,UAAS,YAAY,IAAI,MAAM,OAA+B,CAAC;AAC/F,QAAM,aAAa,OAAO,OAAO,CAAA,UAAS,CAAC,YAAY,IAAI,MAAM,OAA+B,CAAC;AAEjG,SACI,sBAAA,cAAC,OAAA,EAAI,WAAsB,aAAU,gBAAA,GACjC,sBAAA,cAACC,aAAAA,cAAA,EAAc,GAAG,YAAY,WAAU,iBAAgB,aAAU,iBAAA,GAC9D,sBAAA;AAAA,IAACC,6BAAkB;AAAA,IAAlB;AAAA,MACG;AAAA,MACA,gBAAe;AAAA,MACf,QAAO;AAAA,MACP,QAAQ;AAAA,QACJ,QAAQ;AAAA,QACR,MAAM;AAAA,QACN,OAAO;AAAA,QACP,KAAK;AAAA,MAAA;AAAA,MAET,aAAa,YAAY,WAAW,WAAW;AAAA,IAAA;AAAA,IAC/C,sBAAA,cAACA,6BAAkB,eAAlB,EAAgC,UAAU,OAAO;AAAA,IAClD,sBAAA,cAACA,6BAAkB,SAAlB,EAA0B,SAAS,sBAAA,cAACC,QAAAA,SAAA,EAAQ,OAAO,aAAA,CAAc,EAAA,CAAI;AAAA,IACtE,sBAAA,cAACD,6BAAkB,OAAlB,EAAyB,GAAGE,oBAAa,KAAK,KAAK,GAAG;AAAA,IACvD,sBAAA,cAACF,6BAAkB,OAAlB,EAAyB,GAAGE,oBAAa,KAAK,KAAK,GAAG;AAAA,IACtDC,SAAAA,WAAW,WAAW,YAAY,SAAS,KAAK;AAAA,IAChDC,sBAAY,YAAY,UAAU,QAAQ;AAAA,EAAA,CAEnD,GACC,aACG,sBAAA,cAACC,OAAAA,QAAA,EAAc,OAAc,YAAY,aAAa,SAAS,gBAAgB,UAAU,WAAA,CAAY,IACrG,IACR;AAER;AAKA,SAAS,IAA0B,GAA0D;AACzF,SAAO;AACX;AAKA,SAAS,KAA2B,GAA2D;AAC3F,SAAO;AACX;AAGA,aAAa,MAAM;AACnB,aAAa,OAAO;;"}
|
|
@@ -20,8 +20,8 @@ export type BarLineChartProps<TData extends object> = {
|
|
|
20
20
|
} & CartesianChartProps<TData>;
|
|
21
21
|
export declare function BarLineChart<TData extends object>(props: BarLineChartProps<TData>): React.JSX.Element;
|
|
22
22
|
export declare namespace BarLineChart {
|
|
23
|
-
var Bar: <TData extends object>(_: BarLineChartBarProps<TData>) => JSX.Element | null;
|
|
24
|
-
var Line: <TData extends object>(_: BarLineChartLineProps<TData>) => JSX.Element | null;
|
|
23
|
+
var Bar: <TData extends object>(_: BarLineChartBarProps<TData>) => React.JSX.Element | null;
|
|
24
|
+
var Line: <TData extends object>(_: BarLineChartLineProps<TData>) => React.JSX.Element | null;
|
|
25
25
|
}
|
|
26
26
|
export type BarLineChartBarProps<TData extends object> = {} & ChartChildProps<TData>;
|
|
27
27
|
export type BarLineChartLineProps<TData extends object> = {} & ChartChildProps<TData>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BarLineChart.js","sources":["../../../../src/charts/components/Composed/BarLineChart.tsx"],"sourcesContent":["import cn from 'clsx';\nimport React from 'react';\nimport * as RechartsPrimitive from 'recharts';\n\nimport { getAxisProps, stripCartesianProps } from '../../utils/common';\nimport { renderBars } from '../Bar/BarChart';\nimport { ChartWrapper } from '../ChartWrapper';\nimport { Legend } from '../Legend';\nimport { renderLines } from '../Line/LineChart';\nimport { Tooltip } from '../Tooltip';\nimport type { ChartChildProps, CartesianChartProps, CurveType } from '../types';\nimport { useChart } from '../useChartData';\n\nexport type BarLineChartProps<TData extends object> = {\n /** Show bar values as labels next to/inside the bar\n * @default false\n */\n showLabels?: boolean;\n /** Stack bars on top of one another, instead of next to each other. 'expand' fills the available space\n * @default false\n */\n stacked?: boolean | 'expand';\n /** Show dots for each data point on lines\n * @default false\n */\n showDots?: boolean;\n /** Interpolation type of the line\n * @default linear\n */\n lineType?: CurveType;\n} & CartesianChartProps<TData>;\n\nexport function BarLineChart<TData extends object>(props: BarLineChartProps<TData>) {\n const {\n children,\n className: customClassName,\n data,\n showLabels = false,\n showLegend = false,\n stacked = false,\n showDots = false,\n lineType = 'linear',\n tooltipTitle,\n ...attributes\n } = stripCartesianProps<BarLineChartProps<TData>>(props);\n\n const className = cn('relative aspect-video', { 'pb-8': showLegend }, customClassName);\n const { items, shapes, activeIndex, setActiveIndex, toggleItem } = useChart<TData>(children);\n\n // Separate bars and lines based on child component type to identify bar dataKeys\n const barChildren = React.Children.toArray(children).filter(child => React.isValidElement(child) && child.type === Bar);\n // Apply same fallback as useChart: dataKey ?? label\n const barDataKeys = new Set(\n barChildren\n .filter(child => React.isValidElement<ChartChildProps<TData>>(child))\n .map(child => {\n const props = (child as React.ReactElement<ChartChildProps<TData>>).props;\n return props.dataKey ?? props.label;\n })\n );\n\n // Filter shapes from the main useChart call in order to ensure we are not rendering bars or lines that are currently hidden.\n const barShapes = shapes.filter(shape => barDataKeys.has(shape.dataKey as keyof TData & string));\n const lineShapes = shapes.filter(shape => !barDataKeys.has(shape.dataKey as keyof TData & string));\n\n return (\n <div className={className} data-taco=\"chart-wrapper\">\n <ChartWrapper {...attributes} className=\"h-full w-full\" data-taco=\"chart-bar-line\">\n <RechartsPrimitive.ComposedChart\n data={data}\n barCategoryGap=\"15%\"\n barGap=\"7.5%\"\n margin={{\n bottom: 0,\n left: 4,\n right: 4,\n top: 10,\n }}\n stackOffset={stacked === 'expand' ? 'expand' : undefined}>\n <RechartsPrimitive.CartesianGrid vertical={false} />\n <RechartsPrimitive.Tooltip content={<Tooltip title={tooltipTitle} />} />\n <RechartsPrimitive.XAxis {...getAxisProps('x', props)} />\n <RechartsPrimitive.YAxis {...getAxisProps('y', props)} />\n {renderBars(barShapes, showLabels, stacked, false)}\n {renderLines(lineShapes, showDots, lineType)}\n </RechartsPrimitive.ComposedChart>\n </ChartWrapper>\n {showLegend ? (\n <Legend<TData> items={items} hoverIndex={activeIndex} onHover={setActiveIndex} onToggle={toggleItem} />\n ) : null}\n </div>\n );\n}\n\n// oxlint-disable-next-line no-empty-object-type\nexport type BarLineChartBarProps<TData extends object> = {} & ChartChildProps<TData>;\n\nfunction Bar<TData extends object>(_: BarLineChartBarProps<TData>): JSX.Element | null {\n return null;\n}\n\n// oxlint-disable-next-line no-empty-object-type\nexport type BarLineChartLineProps<TData extends object> = {} & ChartChildProps<TData>;\n\nfunction Line<TData extends object>(_: BarLineChartLineProps<TData>): JSX.Element | null {\n return null;\n}\n\n// Attach the marker components to BarLineChart\nBarLineChart.Bar = Bar;\nBarLineChart.Line = Line;\n"],"names":["React","props"],"mappings":";;;;;;;;;;AAgCO,SAAS,aAAmC,OAAiC;AAChF,QAAM;AAAA,IACF;AAAA,IACA,WAAW;AAAA,IACX;AAAA,IACA,aAAa;AAAA,IACb,aAAa;AAAA,IACb,UAAU;AAAA,IACV,WAAW;AAAA,IACX,WAAW;AAAA,IACX;AAAA,IACA,GAAG;AAAA,EAAA,IACH,oBAA8C,KAAK;AAEvD,QAAM,YAAY,GAAG,yBAAyB,EAAE,QAAQ,WAAA,GAAc,eAAe;AACrF,QAAM,EAAE,OAAO,QAAQ,aAAa,gBAAgB,WAAA,IAAe,SAAgB,QAAQ;AAG3F,QAAM,cAAcA,eAAM,SAAS,QAAQ,QAAQ,EAAE,OAAO,CAAA,UAASA,eAAM,eAAe,KAAK,KAAK,MAAM,SAAS,GAAG;AAEtH,QAAM,cAAc,IAAI;AAAA,IACpB,YACK,OAAO,CAAA,UAASA,eAAM,eAAuC,KAAK,CAAC,EACnE,IAAI,CAAA,UAAS;AACV,YAAMC,SAAS,MAAqD;AACpE,aAAOA,OAAM,WAAWA,OAAM;AAAA,IAClC,CAAC;AAAA,EAAA;AAIT,QAAM,YAAY,OAAO,OAAO,CAAA,UAAS,YAAY,IAAI,MAAM,OAA+B,CAAC;AAC/F,QAAM,aAAa,OAAO,OAAO,CAAA,UAAS,CAAC,YAAY,IAAI,MAAM,OAA+B,CAAC;AAEjG,SACID,+BAAA,cAAC,OAAA,EAAI,WAAsB,aAAU,gBAAA,GACjCA,+BAAA,cAAC,cAAA,EAAc,GAAG,YAAY,WAAU,iBAAgB,aAAU,iBAAA,GAC9DA,+BAAA;AAAA,IAAC,kBAAkB;AAAA,IAAlB;AAAA,MACG;AAAA,MACA,gBAAe;AAAA,MACf,QAAO;AAAA,MACP,QAAQ;AAAA,QACJ,QAAQ;AAAA,QACR,MAAM;AAAA,QACN,OAAO;AAAA,QACP,KAAK;AAAA,MAAA;AAAA,MAET,aAAa,YAAY,WAAW,WAAW;AAAA,IAAA;AAAA,IAC/CA,+BAAA,cAAC,kBAAkB,eAAlB,EAAgC,UAAU,OAAO;AAAA,IAClDA,+BAAA,cAAC,kBAAkB,SAAlB,EAA0B,SAASA,+BAAA,cAAC,SAAA,EAAQ,OAAO,aAAA,CAAc,EAAA,CAAI;AAAA,IACtEA,+BAAA,cAAC,kBAAkB,OAAlB,EAAyB,GAAG,aAAa,KAAK,KAAK,GAAG;AAAA,IACvDA,+BAAA,cAAC,kBAAkB,OAAlB,EAAyB,GAAG,aAAa,KAAK,KAAK,GAAG;AAAA,IACtD,WAAW,WAAW,YAAY,SAAS,KAAK;AAAA,IAChD,YAAY,YAAY,UAAU,QAAQ;AAAA,EAAA,CAEnD,GACC,aACGA,+BAAA,cAAC,QAAA,EAAc,OAAc,YAAY,aAAa,SAAS,gBAAgB,UAAU,WAAA,CAAY,IACrG,IACR;AAER;AAKA,SAAS,IAA0B,
|
|
1
|
+
{"version":3,"file":"BarLineChart.js","sources":["../../../../src/charts/components/Composed/BarLineChart.tsx"],"sourcesContent":["import cn from 'clsx';\nimport React from 'react';\nimport * as RechartsPrimitive from 'recharts';\n\nimport { getAxisProps, stripCartesianProps } from '../../utils/common';\nimport { renderBars } from '../Bar/BarChart';\nimport { ChartWrapper } from '../ChartWrapper';\nimport { Legend } from '../Legend';\nimport { renderLines } from '../Line/LineChart';\nimport { Tooltip } from '../Tooltip';\nimport type { ChartChildProps, CartesianChartProps, CurveType } from '../types';\nimport { useChart } from '../useChartData';\n\nexport type BarLineChartProps<TData extends object> = {\n /** Show bar values as labels next to/inside the bar\n * @default false\n */\n showLabels?: boolean;\n /** Stack bars on top of one another, instead of next to each other. 'expand' fills the available space\n * @default false\n */\n stacked?: boolean | 'expand';\n /** Show dots for each data point on lines\n * @default false\n */\n showDots?: boolean;\n /** Interpolation type of the line\n * @default linear\n */\n lineType?: CurveType;\n} & CartesianChartProps<TData>;\n\nexport function BarLineChart<TData extends object>(props: BarLineChartProps<TData>) {\n const {\n children,\n className: customClassName,\n data,\n showLabels = false,\n showLegend = false,\n stacked = false,\n showDots = false,\n lineType = 'linear',\n tooltipTitle,\n ...attributes\n } = stripCartesianProps<BarLineChartProps<TData>>(props);\n\n const className = cn('relative aspect-video', { 'pb-8': showLegend }, customClassName);\n const { items, shapes, activeIndex, setActiveIndex, toggleItem } = useChart<TData>(children);\n\n // Separate bars and lines based on child component type to identify bar dataKeys\n const barChildren = React.Children.toArray(children).filter(child => React.isValidElement(child) && child.type === Bar);\n // Apply same fallback as useChart: dataKey ?? label\n const barDataKeys = new Set(\n barChildren\n .filter(child => React.isValidElement<ChartChildProps<TData>>(child))\n .map(child => {\n const props = (child as React.ReactElement<ChartChildProps<TData>>).props;\n return props.dataKey ?? props.label;\n })\n );\n\n // Filter shapes from the main useChart call in order to ensure we are not rendering bars or lines that are currently hidden.\n const barShapes = shapes.filter(shape => barDataKeys.has(shape.dataKey as keyof TData & string));\n const lineShapes = shapes.filter(shape => !barDataKeys.has(shape.dataKey as keyof TData & string));\n\n return (\n <div className={className} data-taco=\"chart-wrapper\">\n <ChartWrapper {...attributes} className=\"h-full w-full\" data-taco=\"chart-bar-line\">\n <RechartsPrimitive.ComposedChart\n data={data}\n barCategoryGap=\"15%\"\n barGap=\"7.5%\"\n margin={{\n bottom: 0,\n left: 4,\n right: 4,\n top: 10,\n }}\n stackOffset={stacked === 'expand' ? 'expand' : undefined}>\n <RechartsPrimitive.CartesianGrid vertical={false} />\n <RechartsPrimitive.Tooltip content={<Tooltip title={tooltipTitle} />} />\n <RechartsPrimitive.XAxis {...getAxisProps('x', props)} />\n <RechartsPrimitive.YAxis {...getAxisProps('y', props)} />\n {renderBars(barShapes, showLabels, stacked, false)}\n {renderLines(lineShapes, showDots, lineType)}\n </RechartsPrimitive.ComposedChart>\n </ChartWrapper>\n {showLegend ? (\n <Legend<TData> items={items} hoverIndex={activeIndex} onHover={setActiveIndex} onToggle={toggleItem} />\n ) : null}\n </div>\n );\n}\n\n// oxlint-disable-next-line no-empty-object-type\nexport type BarLineChartBarProps<TData extends object> = {} & ChartChildProps<TData>;\n\nfunction Bar<TData extends object>(_: BarLineChartBarProps<TData>): React.JSX.Element | null {\n return null;\n}\n\n// oxlint-disable-next-line no-empty-object-type\nexport type BarLineChartLineProps<TData extends object> = {} & ChartChildProps<TData>;\n\nfunction Line<TData extends object>(_: BarLineChartLineProps<TData>): React.JSX.Element | null {\n return null;\n}\n\n// Attach the marker components to BarLineChart\nBarLineChart.Bar = Bar;\nBarLineChart.Line = Line;\n"],"names":["React","props"],"mappings":";;;;;;;;;;AAgCO,SAAS,aAAmC,OAAiC;AAChF,QAAM;AAAA,IACF;AAAA,IACA,WAAW;AAAA,IACX;AAAA,IACA,aAAa;AAAA,IACb,aAAa;AAAA,IACb,UAAU;AAAA,IACV,WAAW;AAAA,IACX,WAAW;AAAA,IACX;AAAA,IACA,GAAG;AAAA,EAAA,IACH,oBAA8C,KAAK;AAEvD,QAAM,YAAY,GAAG,yBAAyB,EAAE,QAAQ,WAAA,GAAc,eAAe;AACrF,QAAM,EAAE,OAAO,QAAQ,aAAa,gBAAgB,WAAA,IAAe,SAAgB,QAAQ;AAG3F,QAAM,cAAcA,eAAM,SAAS,QAAQ,QAAQ,EAAE,OAAO,CAAA,UAASA,eAAM,eAAe,KAAK,KAAK,MAAM,SAAS,GAAG;AAEtH,QAAM,cAAc,IAAI;AAAA,IACpB,YACK,OAAO,CAAA,UAASA,eAAM,eAAuC,KAAK,CAAC,EACnE,IAAI,CAAA,UAAS;AACV,YAAMC,SAAS,MAAqD;AACpE,aAAOA,OAAM,WAAWA,OAAM;AAAA,IAClC,CAAC;AAAA,EAAA;AAIT,QAAM,YAAY,OAAO,OAAO,CAAA,UAAS,YAAY,IAAI,MAAM,OAA+B,CAAC;AAC/F,QAAM,aAAa,OAAO,OAAO,CAAA,UAAS,CAAC,YAAY,IAAI,MAAM,OAA+B,CAAC;AAEjG,SACID,+BAAA,cAAC,OAAA,EAAI,WAAsB,aAAU,gBAAA,GACjCA,+BAAA,cAAC,cAAA,EAAc,GAAG,YAAY,WAAU,iBAAgB,aAAU,iBAAA,GAC9DA,+BAAA;AAAA,IAAC,kBAAkB;AAAA,IAAlB;AAAA,MACG;AAAA,MACA,gBAAe;AAAA,MACf,QAAO;AAAA,MACP,QAAQ;AAAA,QACJ,QAAQ;AAAA,QACR,MAAM;AAAA,QACN,OAAO;AAAA,QACP,KAAK;AAAA,MAAA;AAAA,MAET,aAAa,YAAY,WAAW,WAAW;AAAA,IAAA;AAAA,IAC/CA,+BAAA,cAAC,kBAAkB,eAAlB,EAAgC,UAAU,OAAO;AAAA,IAClDA,+BAAA,cAAC,kBAAkB,SAAlB,EAA0B,SAASA,+BAAA,cAAC,SAAA,EAAQ,OAAO,aAAA,CAAc,EAAA,CAAI;AAAA,IACtEA,+BAAA,cAAC,kBAAkB,OAAlB,EAAyB,GAAG,aAAa,KAAK,KAAK,GAAG;AAAA,IACvDA,+BAAA,cAAC,kBAAkB,OAAlB,EAAyB,GAAG,aAAa,KAAK,KAAK,GAAG;AAAA,IACtD,WAAW,WAAW,YAAY,SAAS,KAAK;AAAA,IAChD,YAAY,YAAY,UAAU,QAAQ;AAAA,EAAA,CAEnD,GACC,aACGA,+BAAA,cAAC,QAAA,EAAc,OAAc,YAAY,aAAa,SAAS,gBAAgB,UAAU,WAAA,CAAY,IACrG,IACR;AAER;AAKA,SAAS,IAA0B,GAA0D;AACzF,SAAO;AACX;AAKA,SAAS,KAA2B,GAA2D;AAC3F,SAAO;AACX;AAGA,aAAa,MAAM;AACnB,aAAa,OAAO;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DonutChart.cjs","sources":["../../../../src/charts/components/Donut/DonutChart.tsx"],"sourcesContent":["import cn from 'clsx';\nimport React from 'react';\nimport * as RechartsPrimitive from 'recharts';\n\nimport { Tooltip as TacoTooltip } from '../../../components/Tooltip/Tooltip';\nimport { ChartWrapper } from '../ChartWrapper';\nimport { Legend } from '../Legend';\nimport type { PieChartSegmentProps } from '../Pie/PieChart';\nimport { usePieChart } from '../Pie/util';\nimport { Tooltip } from '../Tooltip';\nimport type { ChartValueFormatter, PolarChartProps } from '../types';\n\nimport './style.css';\n\nconst DONUT_WIDTH = 20;\n\nexport type DonutChartProps = {\n /** Show total value in center of Donut\n * @default false\n */\n showTotal?: boolean;\n} & PolarChartProps;\n\nexport function DonutChart<TData extends object>(props: DonutChartProps) {\n const { children, formatter, showLegend = false, showTotal = false, tooltipTitle, unit, ...attributes } = props;\n const { pieProps, radius, setRadius, items, activeIndex, setActiveIndex, globalFormatter, toggleItem } = usePieChart<TData>(\n children,\n {\n formatter,\n unit,\n }\n );\n const className = cn('aspect-square', attributes.className);\n\n return (\n <div className=\"relative\" data-taco=\"chart-wrapper\">\n <ChartWrapper {...attributes} className={className} data-taco=\"chart-donut\" onSetWidth={setRadius}>\n <RechartsPrimitive.PieChart>\n <RechartsPrimitive.Tooltip content={<Tooltip title={tooltipTitle} />} />\n <RechartsPrimitive.Pie {...pieProps} innerRadius={radius - DONUT_WIDTH} />\n </RechartsPrimitive.PieChart>\n </ChartWrapper>\n {showTotal ? (\n <Total<TData>\n formatter={globalFormatter}\n items={items as unknown[] as DonutChartSegmentProps<TData>[]}\n unit={unit}\n style={{ top: radius + DONUT_WIDTH / 2, width: radius + DONUT_WIDTH * 2 }}\n />\n ) : null}\n {showLegend ? (\n <Legend<TData> items={items} hoverIndex={activeIndex} onHover={setActiveIndex} onToggle={toggleItem} />\n ) : null}\n </div>\n );\n}\n\n// oxlint-disable-next-line no-empty-object-type\nexport type DonutChartSegmentProps<TData extends object> = {} & PieChartSegmentProps<TData>;\n\nfunction Segment<TData extends object>(_: DonutChartSegmentProps<TData>): JSX.Element | null {\n return null;\n}\nDonutChart.Segment = Segment;\n\ntype DonutTotalProps<TData extends object> = {\n formatter: ChartValueFormatter;\n items: DonutChartSegmentProps<TData>[];\n unit?: string;\n} & React.ComponentProps<'div'>;\n\nfunction Total<TData extends object>(props: DonutTotalProps<TData>) {\n const { formatter, items, unit, ...attributes } = props;\n const total = React.useMemo(() => {\n const total = items.filter(item => !item.isHidden).reduce((acc, curr) => acc + curr.value, 0);\n return formatter(total);\n }, [items]);\n\n return (\n <div\n {...attributes}\n className=\"flex aspect-video flex-col items-center justify-center overflow-hidden rounded-full absolute-center\"\n data-taco=\"chart-donut-total\">\n <TacoTooltip title={total}>\n <span className=\"w-full truncate text-center text-lg font-bold tabular-nums\">{total}</span>\n </TacoTooltip>\n {unit ? <span className=\"-mb-1 -mt-0.5 truncate text-xs text-gray-700\">{unit}</span> : null}\n </div>\n );\n}\n"],"names":["usePieChart","ChartWrapper","RechartsPrimitive","Tooltip","Legend","total","TacoTooltip"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAcA,MAAM,cAAc;AASb,SAAS,WAAiC,OAAwB;AACrE,QAAM,EAAE,UAAU,WAAW,aAAa,OAAO,YAAY,OAAO,cAAc,MAAM,GAAG,WAAA,IAAe;AAC1G,QAAM,EAAE,UAAU,QAAQ,WAAW,OAAO,aAAa,gBAAgB,iBAAiB,WAAA,IAAeA,KAAAA;AAAAA,IACrG;AAAA,IACA;AAAA,MACI;AAAA,MACA;AAAA,IAAA;AAAA,EACJ;AAEJ,QAAM,YAAY,GAAG,iBAAiB,WAAW,SAAS;AAE1D,6CACK,OAAA,EAAI,WAAU,YAAW,aAAU,gBAAA,uCAC/BC,aAAAA,cAAA,EAAc,GAAG,YAAY,WAAsB,aAAU,eAAc,YAAY,UAAA,uCACnFC,6BAAkB,UAAlB,MACG,sBAAA,cAACA,6BAAkB,SAAlB,EAA0B,SAAS,sBAAA,cAACC,iBAAA,EAAQ,OAAO,cAAc,EAAA,CAAI,GACtE,sBAAA,cAACD,6BAAkB,KAAlB,EAAuB,GAAG,UAAU,aAAa,SAAS,aAAa,CAC5E,CACJ,GACC,YACG,sBAAA;AAAA,IAAC;AAAA,IAAA;AAAA,MACG,WAAW;AAAA,MACX;AAAA,MACA;AAAA,MACA,OAAO,EAAE,KAAK,SAAS,cAAc,GAAG,OAAO,SAAS,cAAc,EAAA;AAAA,IAAE;AAAA,EAAA,IAE5E,MACH,aACG,sBAAA,cAACE,OAAAA,QAAA,EAAc,OAAc,YAAY,aAAa,SAAS,gBAAgB,UAAU,WAAA,CAAY,IACrG,IACR;AAER;AAKA,SAAS,QAA8B,
|
|
1
|
+
{"version":3,"file":"DonutChart.cjs","sources":["../../../../src/charts/components/Donut/DonutChart.tsx"],"sourcesContent":["import cn from 'clsx';\nimport React from 'react';\nimport * as RechartsPrimitive from 'recharts';\n\nimport { Tooltip as TacoTooltip } from '../../../components/Tooltip/Tooltip';\nimport { ChartWrapper } from '../ChartWrapper';\nimport { Legend } from '../Legend';\nimport type { PieChartSegmentProps } from '../Pie/PieChart';\nimport { usePieChart } from '../Pie/util';\nimport { Tooltip } from '../Tooltip';\nimport type { ChartValueFormatter, PolarChartProps } from '../types';\n\nimport './style.css';\n\nconst DONUT_WIDTH = 20;\n\nexport type DonutChartProps = {\n /** Show total value in center of Donut\n * @default false\n */\n showTotal?: boolean;\n} & PolarChartProps;\n\nexport function DonutChart<TData extends object>(props: DonutChartProps) {\n const { children, formatter, showLegend = false, showTotal = false, tooltipTitle, unit, ...attributes } = props;\n const { pieProps, radius, setRadius, items, activeIndex, setActiveIndex, globalFormatter, toggleItem } = usePieChart<TData>(\n children,\n {\n formatter,\n unit,\n }\n );\n const className = cn('aspect-square', attributes.className);\n\n return (\n <div className=\"relative\" data-taco=\"chart-wrapper\">\n <ChartWrapper {...attributes} className={className} data-taco=\"chart-donut\" onSetWidth={setRadius}>\n <RechartsPrimitive.PieChart>\n <RechartsPrimitive.Tooltip content={<Tooltip title={tooltipTitle} />} />\n <RechartsPrimitive.Pie {...pieProps} innerRadius={radius - DONUT_WIDTH} />\n </RechartsPrimitive.PieChart>\n </ChartWrapper>\n {showTotal ? (\n <Total<TData>\n formatter={globalFormatter}\n items={items as unknown[] as DonutChartSegmentProps<TData>[]}\n unit={unit}\n style={{ top: radius + DONUT_WIDTH / 2, width: radius + DONUT_WIDTH * 2 }}\n />\n ) : null}\n {showLegend ? (\n <Legend<TData> items={items} hoverIndex={activeIndex} onHover={setActiveIndex} onToggle={toggleItem} />\n ) : null}\n </div>\n );\n}\n\n// oxlint-disable-next-line no-empty-object-type\nexport type DonutChartSegmentProps<TData extends object> = {} & PieChartSegmentProps<TData>;\n\nfunction Segment<TData extends object>(_: DonutChartSegmentProps<TData>): React.JSX.Element | null {\n return null;\n}\nDonutChart.Segment = Segment;\n\ntype DonutTotalProps<TData extends object> = {\n formatter: ChartValueFormatter;\n items: DonutChartSegmentProps<TData>[];\n unit?: string;\n} & React.ComponentProps<'div'>;\n\nfunction Total<TData extends object>(props: DonutTotalProps<TData>) {\n const { formatter, items, unit, ...attributes } = props;\n const total = React.useMemo(() => {\n const total = items.filter(item => !item.isHidden).reduce((acc, curr) => acc + curr.value, 0);\n return formatter(total);\n }, [items]);\n\n return (\n <div\n {...attributes}\n className=\"flex aspect-video flex-col items-center justify-center overflow-hidden rounded-full absolute-center\"\n data-taco=\"chart-donut-total\">\n <TacoTooltip title={total}>\n <span className=\"w-full truncate text-center text-lg font-bold tabular-nums\">{total}</span>\n </TacoTooltip>\n {unit ? <span className=\"-mb-1 -mt-0.5 truncate text-xs text-gray-700\">{unit}</span> : null}\n </div>\n );\n}\n"],"names":["usePieChart","ChartWrapper","RechartsPrimitive","Tooltip","Legend","total","TacoTooltip"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAcA,MAAM,cAAc;AASb,SAAS,WAAiC,OAAwB;AACrE,QAAM,EAAE,UAAU,WAAW,aAAa,OAAO,YAAY,OAAO,cAAc,MAAM,GAAG,WAAA,IAAe;AAC1G,QAAM,EAAE,UAAU,QAAQ,WAAW,OAAO,aAAa,gBAAgB,iBAAiB,WAAA,IAAeA,KAAAA;AAAAA,IACrG;AAAA,IACA;AAAA,MACI;AAAA,MACA;AAAA,IAAA;AAAA,EACJ;AAEJ,QAAM,YAAY,GAAG,iBAAiB,WAAW,SAAS;AAE1D,6CACK,OAAA,EAAI,WAAU,YAAW,aAAU,gBAAA,uCAC/BC,aAAAA,cAAA,EAAc,GAAG,YAAY,WAAsB,aAAU,eAAc,YAAY,UAAA,uCACnFC,6BAAkB,UAAlB,MACG,sBAAA,cAACA,6BAAkB,SAAlB,EAA0B,SAAS,sBAAA,cAACC,iBAAA,EAAQ,OAAO,cAAc,EAAA,CAAI,GACtE,sBAAA,cAACD,6BAAkB,KAAlB,EAAuB,GAAG,UAAU,aAAa,SAAS,aAAa,CAC5E,CACJ,GACC,YACG,sBAAA;AAAA,IAAC;AAAA,IAAA;AAAA,MACG,WAAW;AAAA,MACX;AAAA,MACA;AAAA,MACA,OAAO,EAAE,KAAK,SAAS,cAAc,GAAG,OAAO,SAAS,cAAc,EAAA;AAAA,IAAE;AAAA,EAAA,IAE5E,MACH,aACG,sBAAA,cAACE,OAAAA,QAAA,EAAc,OAAc,YAAY,aAAa,SAAS,gBAAgB,UAAU,WAAA,CAAY,IACrG,IACR;AAER;AAKA,SAAS,QAA8B,GAA4D;AAC/F,SAAO;AACX;AACA,WAAW,UAAU;AAQrB,SAAS,MAA4B,OAA+B;AAChE,QAAM,EAAE,WAAW,OAAO,MAAM,GAAG,eAAe;AAClD,QAAM,QAAQ,MAAM,QAAQ,MAAM;AAC9B,UAAMC,SAAQ,MAAM,OAAO,CAAA,SAAQ,CAAC,KAAK,QAAQ,EAAE,OAAO,CAAC,KAAK,SAAS,MAAM,KAAK,OAAO,CAAC;AAC5F,WAAO,UAAUA,MAAK;AAAA,EAC1B,GAAG,CAAC,KAAK,CAAC;AAEV,SACI,sBAAA;AAAA,IAAC;AAAA,IAAA;AAAA,MACI,GAAG;AAAA,MACJ,WAAU;AAAA,MACV,aAAU;AAAA,IAAA;AAAA,IACV,sBAAA,cAACC,UAAAA,WAAY,OAAO,MAAA,uCACf,QAAA,EAAK,WAAU,6DAAA,GAA8D,KAAM,CACxF;AAAA,IACC,OAAO,sBAAA,cAAC,QAAA,EAAK,WAAU,+CAAA,GAAgD,IAAK,IAAU;AAAA,EAAA;AAGnG;;"}
|
|
@@ -9,6 +9,6 @@ export type DonutChartProps = {
|
|
|
9
9
|
} & PolarChartProps;
|
|
10
10
|
export declare function DonutChart<TData extends object>(props: DonutChartProps): React.JSX.Element;
|
|
11
11
|
export declare namespace DonutChart {
|
|
12
|
-
var Segment: <TData extends object>(_: DonutChartSegmentProps<TData>) => JSX.Element | null;
|
|
12
|
+
var Segment: <TData extends object>(_: DonutChartSegmentProps<TData>) => React.JSX.Element | null;
|
|
13
13
|
}
|
|
14
14
|
export type DonutChartSegmentProps<TData extends object> = {} & PieChartSegmentProps<TData>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DonutChart.js","sources":["../../../../src/charts/components/Donut/DonutChart.tsx"],"sourcesContent":["import cn from 'clsx';\nimport React from 'react';\nimport * as RechartsPrimitive from 'recharts';\n\nimport { Tooltip as TacoTooltip } from '../../../components/Tooltip/Tooltip';\nimport { ChartWrapper } from '../ChartWrapper';\nimport { Legend } from '../Legend';\nimport type { PieChartSegmentProps } from '../Pie/PieChart';\nimport { usePieChart } from '../Pie/util';\nimport { Tooltip } from '../Tooltip';\nimport type { ChartValueFormatter, PolarChartProps } from '../types';\n\nimport './style.css';\n\nconst DONUT_WIDTH = 20;\n\nexport type DonutChartProps = {\n /** Show total value in center of Donut\n * @default false\n */\n showTotal?: boolean;\n} & PolarChartProps;\n\nexport function DonutChart<TData extends object>(props: DonutChartProps) {\n const { children, formatter, showLegend = false, showTotal = false, tooltipTitle, unit, ...attributes } = props;\n const { pieProps, radius, setRadius, items, activeIndex, setActiveIndex, globalFormatter, toggleItem } = usePieChart<TData>(\n children,\n {\n formatter,\n unit,\n }\n );\n const className = cn('aspect-square', attributes.className);\n\n return (\n <div className=\"relative\" data-taco=\"chart-wrapper\">\n <ChartWrapper {...attributes} className={className} data-taco=\"chart-donut\" onSetWidth={setRadius}>\n <RechartsPrimitive.PieChart>\n <RechartsPrimitive.Tooltip content={<Tooltip title={tooltipTitle} />} />\n <RechartsPrimitive.Pie {...pieProps} innerRadius={radius - DONUT_WIDTH} />\n </RechartsPrimitive.PieChart>\n </ChartWrapper>\n {showTotal ? (\n <Total<TData>\n formatter={globalFormatter}\n items={items as unknown[] as DonutChartSegmentProps<TData>[]}\n unit={unit}\n style={{ top: radius + DONUT_WIDTH / 2, width: radius + DONUT_WIDTH * 2 }}\n />\n ) : null}\n {showLegend ? (\n <Legend<TData> items={items} hoverIndex={activeIndex} onHover={setActiveIndex} onToggle={toggleItem} />\n ) : null}\n </div>\n );\n}\n\n// oxlint-disable-next-line no-empty-object-type\nexport type DonutChartSegmentProps<TData extends object> = {} & PieChartSegmentProps<TData>;\n\nfunction Segment<TData extends object>(_: DonutChartSegmentProps<TData>): JSX.Element | null {\n return null;\n}\nDonutChart.Segment = Segment;\n\ntype DonutTotalProps<TData extends object> = {\n formatter: ChartValueFormatter;\n items: DonutChartSegmentProps<TData>[];\n unit?: string;\n} & React.ComponentProps<'div'>;\n\nfunction Total<TData extends object>(props: DonutTotalProps<TData>) {\n const { formatter, items, unit, ...attributes } = props;\n const total = React.useMemo(() => {\n const total = items.filter(item => !item.isHidden).reduce((acc, curr) => acc + curr.value, 0);\n return formatter(total);\n }, [items]);\n\n return (\n <div\n {...attributes}\n className=\"flex aspect-video flex-col items-center justify-center overflow-hidden rounded-full absolute-center\"\n data-taco=\"chart-donut-total\">\n <TacoTooltip title={total}>\n <span className=\"w-full truncate text-center text-lg font-bold tabular-nums\">{total}</span>\n </TacoTooltip>\n {unit ? <span className=\"-mb-1 -mt-0.5 truncate text-xs text-gray-700\">{unit}</span> : null}\n </div>\n );\n}\n"],"names":["React","total","TacoTooltip"],"mappings":";;;;;;;;;AAcA,MAAM,cAAc;AASb,SAAS,WAAiC,OAAwB;AACrE,QAAM,EAAE,UAAU,WAAW,aAAa,OAAO,YAAY,OAAO,cAAc,MAAM,GAAG,WAAA,IAAe;AAC1G,QAAM,EAAE,UAAU,QAAQ,WAAW,OAAO,aAAa,gBAAgB,iBAAiB,WAAA,IAAe;AAAA,IACrG;AAAA,IACA;AAAA,MACI;AAAA,MACA;AAAA,IAAA;AAAA,EACJ;AAEJ,QAAM,YAAY,GAAG,iBAAiB,WAAW,SAAS;AAE1D,sDACK,OAAA,EAAI,WAAU,YAAW,aAAU,gBAAA,gDAC/B,cAAA,EAAc,GAAG,YAAY,WAAsB,aAAU,eAAc,YAAY,UAAA,gDACnF,kBAAkB,UAAlB,MACGA,+BAAA,cAAC,kBAAkB,SAAlB,EAA0B,SAASA,+BAAA,cAAC,SAAA,EAAQ,OAAO,cAAc,EAAA,CAAI,GACtEA,+BAAA,cAAC,kBAAkB,KAAlB,EAAuB,GAAG,UAAU,aAAa,SAAS,aAAa,CAC5E,CACJ,GACC,YACGA,+BAAA;AAAA,IAAC;AAAA,IAAA;AAAA,MACG,WAAW;AAAA,MACX;AAAA,MACA;AAAA,MACA,OAAO,EAAE,KAAK,SAAS,cAAc,GAAG,OAAO,SAAS,cAAc,EAAA;AAAA,IAAE;AAAA,EAAA,IAE5E,MACH,aACGA,+BAAA,cAAC,QAAA,EAAc,OAAc,YAAY,aAAa,SAAS,gBAAgB,UAAU,WAAA,CAAY,IACrG,IACR;AAER;AAKA,SAAS,QAA8B,
|
|
1
|
+
{"version":3,"file":"DonutChart.js","sources":["../../../../src/charts/components/Donut/DonutChart.tsx"],"sourcesContent":["import cn from 'clsx';\nimport React from 'react';\nimport * as RechartsPrimitive from 'recharts';\n\nimport { Tooltip as TacoTooltip } from '../../../components/Tooltip/Tooltip';\nimport { ChartWrapper } from '../ChartWrapper';\nimport { Legend } from '../Legend';\nimport type { PieChartSegmentProps } from '../Pie/PieChart';\nimport { usePieChart } from '../Pie/util';\nimport { Tooltip } from '../Tooltip';\nimport type { ChartValueFormatter, PolarChartProps } from '../types';\n\nimport './style.css';\n\nconst DONUT_WIDTH = 20;\n\nexport type DonutChartProps = {\n /** Show total value in center of Donut\n * @default false\n */\n showTotal?: boolean;\n} & PolarChartProps;\n\nexport function DonutChart<TData extends object>(props: DonutChartProps) {\n const { children, formatter, showLegend = false, showTotal = false, tooltipTitle, unit, ...attributes } = props;\n const { pieProps, radius, setRadius, items, activeIndex, setActiveIndex, globalFormatter, toggleItem } = usePieChart<TData>(\n children,\n {\n formatter,\n unit,\n }\n );\n const className = cn('aspect-square', attributes.className);\n\n return (\n <div className=\"relative\" data-taco=\"chart-wrapper\">\n <ChartWrapper {...attributes} className={className} data-taco=\"chart-donut\" onSetWidth={setRadius}>\n <RechartsPrimitive.PieChart>\n <RechartsPrimitive.Tooltip content={<Tooltip title={tooltipTitle} />} />\n <RechartsPrimitive.Pie {...pieProps} innerRadius={radius - DONUT_WIDTH} />\n </RechartsPrimitive.PieChart>\n </ChartWrapper>\n {showTotal ? (\n <Total<TData>\n formatter={globalFormatter}\n items={items as unknown[] as DonutChartSegmentProps<TData>[]}\n unit={unit}\n style={{ top: radius + DONUT_WIDTH / 2, width: radius + DONUT_WIDTH * 2 }}\n />\n ) : null}\n {showLegend ? (\n <Legend<TData> items={items} hoverIndex={activeIndex} onHover={setActiveIndex} onToggle={toggleItem} />\n ) : null}\n </div>\n );\n}\n\n// oxlint-disable-next-line no-empty-object-type\nexport type DonutChartSegmentProps<TData extends object> = {} & PieChartSegmentProps<TData>;\n\nfunction Segment<TData extends object>(_: DonutChartSegmentProps<TData>): React.JSX.Element | null {\n return null;\n}\nDonutChart.Segment = Segment;\n\ntype DonutTotalProps<TData extends object> = {\n formatter: ChartValueFormatter;\n items: DonutChartSegmentProps<TData>[];\n unit?: string;\n} & React.ComponentProps<'div'>;\n\nfunction Total<TData extends object>(props: DonutTotalProps<TData>) {\n const { formatter, items, unit, ...attributes } = props;\n const total = React.useMemo(() => {\n const total = items.filter(item => !item.isHidden).reduce((acc, curr) => acc + curr.value, 0);\n return formatter(total);\n }, [items]);\n\n return (\n <div\n {...attributes}\n className=\"flex aspect-video flex-col items-center justify-center overflow-hidden rounded-full absolute-center\"\n data-taco=\"chart-donut-total\">\n <TacoTooltip title={total}>\n <span className=\"w-full truncate text-center text-lg font-bold tabular-nums\">{total}</span>\n </TacoTooltip>\n {unit ? <span className=\"-mb-1 -mt-0.5 truncate text-xs text-gray-700\">{unit}</span> : null}\n </div>\n );\n}\n"],"names":["React","total","TacoTooltip"],"mappings":";;;;;;;;;AAcA,MAAM,cAAc;AASb,SAAS,WAAiC,OAAwB;AACrE,QAAM,EAAE,UAAU,WAAW,aAAa,OAAO,YAAY,OAAO,cAAc,MAAM,GAAG,WAAA,IAAe;AAC1G,QAAM,EAAE,UAAU,QAAQ,WAAW,OAAO,aAAa,gBAAgB,iBAAiB,WAAA,IAAe;AAAA,IACrG;AAAA,IACA;AAAA,MACI;AAAA,MACA;AAAA,IAAA;AAAA,EACJ;AAEJ,QAAM,YAAY,GAAG,iBAAiB,WAAW,SAAS;AAE1D,sDACK,OAAA,EAAI,WAAU,YAAW,aAAU,gBAAA,gDAC/B,cAAA,EAAc,GAAG,YAAY,WAAsB,aAAU,eAAc,YAAY,UAAA,gDACnF,kBAAkB,UAAlB,MACGA,+BAAA,cAAC,kBAAkB,SAAlB,EAA0B,SAASA,+BAAA,cAAC,SAAA,EAAQ,OAAO,cAAc,EAAA,CAAI,GACtEA,+BAAA,cAAC,kBAAkB,KAAlB,EAAuB,GAAG,UAAU,aAAa,SAAS,aAAa,CAC5E,CACJ,GACC,YACGA,+BAAA;AAAA,IAAC;AAAA,IAAA;AAAA,MACG,WAAW;AAAA,MACX;AAAA,MACA;AAAA,MACA,OAAO,EAAE,KAAK,SAAS,cAAc,GAAG,OAAO,SAAS,cAAc,EAAA;AAAA,IAAE;AAAA,EAAA,IAE5E,MACH,aACGA,+BAAA,cAAC,QAAA,EAAc,OAAc,YAAY,aAAa,SAAS,gBAAgB,UAAU,WAAA,CAAY,IACrG,IACR;AAER;AAKA,SAAS,QAA8B,GAA4D;AAC/F,SAAO;AACX;AACA,WAAW,UAAU;AAQrB,SAAS,MAA4B,OAA+B;AAChE,QAAM,EAAE,WAAW,OAAO,MAAM,GAAG,eAAe;AAClD,QAAM,QAAQA,eAAM,QAAQ,MAAM;AAC9B,UAAMC,SAAQ,MAAM,OAAO,CAAA,SAAQ,CAAC,KAAK,QAAQ,EAAE,OAAO,CAAC,KAAK,SAAS,MAAM,KAAK,OAAO,CAAC;AAC5F,WAAO,UAAUA,MAAK;AAAA,EAC1B,GAAG,CAAC,KAAK,CAAC;AAEV,SACID,+BAAA;AAAA,IAAC;AAAA,IAAA;AAAA,MACI,GAAG;AAAA,MACJ,WAAU;AAAA,MACV,aAAU;AAAA,IAAA;AAAA,IACVA,+BAAA,cAACE,aAAY,OAAO,MAAA,gDACf,QAAA,EAAK,WAAU,6DAAA,GAA8D,KAAM,CACxF;AAAA,IACC,OAAOF,+BAAA,cAAC,QAAA,EAAK,WAAU,+CAAA,GAAgD,IAAK,IAAU;AAAA,EAAA;AAGnG;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LineChart.cjs","sources":["../../../../src/charts/components/Line/LineChart.tsx"],"sourcesContent":["import cn from 'clsx';\nimport React from 'react';\nimport * as RechartsPrimitive from 'recharts';\n\nimport { getAxisProps, stripCartesianProps } from '../../utils/common';\nimport { ChartWrapper } from '../ChartWrapper';\nimport { Legend } from '../Legend';\nimport { Tooltip } from '../Tooltip';\nimport type { ChartChildProps, CartesianChartProps, CurveType } from '../types';\nimport { useChart } from '../useChartData';\n\nexport type LineChartProps<TData extends object> = {\n /** Show dots for each data point\n * @default false\n */\n showDots?: boolean;\n /** Interpolation type of the line\n * @default natural\n */\n type?: CurveType;\n} & CartesianChartProps<TData>;\n\nexport function LineChart<TData extends object>(props: LineChartProps<TData>) {\n const {\n children,\n className: customClassName,\n data,\n showLegend = false,\n showDots = false,\n tooltipTitle,\n type = 'natural',\n ...attributes\n } = stripCartesianProps<LineChartProps<TData>>(props);\n\n const className = cn('relative aspect-video', { 'pb-8': showLegend }, customClassName);\n const { items, shapes, activeIndex, setActiveIndex, toggleItem } = useChart<TData>(children);\n\n return (\n <div className={className} data-taco=\"chart-wrapper\">\n <ChartWrapper {...attributes} className=\"h-full w-full\" data-taco=\"chart-line\">\n <RechartsPrimitive.LineChart\n data={data}\n margin={{\n bottom: 0,\n // ensures dots on the edges of the chart don't get cropped\n left: 4,\n right: 4,\n top: 4,\n }}>\n <RechartsPrimitive.CartesianGrid vertical={false} />\n <RechartsPrimitive.Tooltip content={<Tooltip title={tooltipTitle} />} />\n <RechartsPrimitive.XAxis {...getAxisProps('x', props)} />\n <RechartsPrimitive.YAxis {...getAxisProps('y', props)} />\n {renderLines(shapes, showDots, type)}\n </RechartsPrimitive.LineChart>\n </ChartWrapper>\n {showLegend ? (\n <Legend<TData> items={items} hoverIndex={activeIndex} onHover={setActiveIndex} onToggle={toggleItem} />\n ) : null}\n </div>\n );\n}\n\n/**\n * Helper function to render line shapes as Recharts Line primitives. Extracted to be reusable across LineChart and ComposedChart.\n */\nexport const renderLines = (shapes: any[], showDots: boolean = false, type: CurveType = 'natural') => {\n return shapes.map(shape => (\n <RechartsPrimitive.Line key={shape.dataKey} {...shape} dot={showDots ? shape.dot : false} type={type} />\n ));\n};\n\n// oxlint-disable-next-line no-empty-object-type\nexport type LineChartAreaProps<TData extends object> = {} & ChartChildProps<TData>;\n\nfunction Line<TData extends object>(_: LineChartAreaProps<TData>): JSX.Element | null {\n return null;\n}\nLineChart.Line = Line;\n"],"names":["stripCartesianProps","useChart","ChartWrapper","RechartsPrimitive","Tooltip","getAxisProps","Legend"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;AAsBO,SAAS,UAAgC,OAA8B;AAC1E,QAAM;AAAA,IACF;AAAA,IACA,WAAW;AAAA,IACX;AAAA,IACA,aAAa;AAAA,IACb,WAAW;AAAA,IACX;AAAA,IACA,OAAO;AAAA,IACP,GAAG;AAAA,EAAA,IACHA,OAAAA,oBAA2C,KAAK;AAEpD,QAAM,YAAY,GAAG,yBAAyB,EAAE,QAAQ,WAAA,GAAc,eAAe;AACrF,QAAM,EAAE,OAAO,QAAQ,aAAa,gBAAgB,WAAA,IAAeC,aAAAA,SAAgB,QAAQ;AAE3F,SACI,sBAAA,cAAC,OAAA,EAAI,WAAsB,aAAU,gBAAA,GACjC,sBAAA,cAACC,aAAAA,cAAA,EAAc,GAAG,YAAY,WAAU,iBAAgB,aAAU,aAAA,GAC9D,sBAAA;AAAA,IAACC,6BAAkB;AAAA,IAAlB;AAAA,MACG;AAAA,MACA,QAAQ;AAAA,QACJ,QAAQ;AAAA;AAAA,QAER,MAAM;AAAA,QACN,OAAO;AAAA,QACP,KAAK;AAAA,MAAA;AAAA,IACT;AAAA,IACA,sBAAA,cAACA,6BAAkB,eAAlB,EAAgC,UAAU,OAAO;AAAA,IAClD,sBAAA,cAACA,6BAAkB,SAAlB,EAA0B,SAAS,sBAAA,cAACC,QAAAA,SAAA,EAAQ,OAAO,aAAA,CAAc,EAAA,CAAI;AAAA,IACtE,sBAAA,cAACD,6BAAkB,OAAlB,EAAyB,GAAGE,oBAAa,KAAK,KAAK,GAAG;AAAA,IACvD,sBAAA,cAACF,6BAAkB,OAAlB,EAAyB,GAAGE,oBAAa,KAAK,KAAK,GAAG;AAAA,IACtD,YAAY,QAAQ,UAAU,IAAI;AAAA,EAAA,CAE3C,GACC,aACG,sBAAA,cAACC,OAAAA,QAAA,EAAc,OAAc,YAAY,aAAa,SAAS,gBAAgB,UAAU,WAAA,CAAY,IACrG,IACR;AAER;AAKO,MAAM,cAAc,CAAC,QAAe,WAAoB,OAAO,OAAkB,cAAc;AAClG,SAAO,OAAO,IAAI,CAAA,8CACbH,6BAAkB,MAAlB,EAAuB,KAAK,MAAM,SAAU,GAAG,OAAO,KAAK,WAAW,MAAM,MAAM,OAAO,MAAY,CACzG;AACL;AAKA,SAAS,KAA2B,
|
|
1
|
+
{"version":3,"file":"LineChart.cjs","sources":["../../../../src/charts/components/Line/LineChart.tsx"],"sourcesContent":["import cn from 'clsx';\nimport React from 'react';\nimport * as RechartsPrimitive from 'recharts';\n\nimport { getAxisProps, stripCartesianProps } from '../../utils/common';\nimport { ChartWrapper } from '../ChartWrapper';\nimport { Legend } from '../Legend';\nimport { Tooltip } from '../Tooltip';\nimport type { ChartChildProps, CartesianChartProps, CurveType } from '../types';\nimport { useChart } from '../useChartData';\n\nexport type LineChartProps<TData extends object> = {\n /** Show dots for each data point\n * @default false\n */\n showDots?: boolean;\n /** Interpolation type of the line\n * @default natural\n */\n type?: CurveType;\n} & CartesianChartProps<TData>;\n\nexport function LineChart<TData extends object>(props: LineChartProps<TData>) {\n const {\n children,\n className: customClassName,\n data,\n showLegend = false,\n showDots = false,\n tooltipTitle,\n type = 'natural',\n ...attributes\n } = stripCartesianProps<LineChartProps<TData>>(props);\n\n const className = cn('relative aspect-video', { 'pb-8': showLegend }, customClassName);\n const { items, shapes, activeIndex, setActiveIndex, toggleItem } = useChart<TData>(children);\n\n return (\n <div className={className} data-taco=\"chart-wrapper\">\n <ChartWrapper {...attributes} className=\"h-full w-full\" data-taco=\"chart-line\">\n <RechartsPrimitive.LineChart\n data={data}\n margin={{\n bottom: 0,\n // ensures dots on the edges of the chart don't get cropped\n left: 4,\n right: 4,\n top: 4,\n }}>\n <RechartsPrimitive.CartesianGrid vertical={false} />\n <RechartsPrimitive.Tooltip content={<Tooltip title={tooltipTitle} />} />\n <RechartsPrimitive.XAxis {...getAxisProps('x', props)} />\n <RechartsPrimitive.YAxis {...getAxisProps('y', props)} />\n {renderLines(shapes, showDots, type)}\n </RechartsPrimitive.LineChart>\n </ChartWrapper>\n {showLegend ? (\n <Legend<TData> items={items} hoverIndex={activeIndex} onHover={setActiveIndex} onToggle={toggleItem} />\n ) : null}\n </div>\n );\n}\n\n/**\n * Helper function to render line shapes as Recharts Line primitives. Extracted to be reusable across LineChart and ComposedChart.\n */\nexport const renderLines = (shapes: any[], showDots: boolean = false, type: CurveType = 'natural') => {\n return shapes.map(shape => (\n <RechartsPrimitive.Line key={shape.dataKey} {...shape} dot={showDots ? shape.dot : false} type={type} />\n ));\n};\n\n// oxlint-disable-next-line no-empty-object-type\nexport type LineChartAreaProps<TData extends object> = {} & ChartChildProps<TData>;\n\nfunction Line<TData extends object>(_: LineChartAreaProps<TData>): React.JSX.Element | null {\n return null;\n}\nLineChart.Line = Line;\n"],"names":["stripCartesianProps","useChart","ChartWrapper","RechartsPrimitive","Tooltip","getAxisProps","Legend"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;AAsBO,SAAS,UAAgC,OAA8B;AAC1E,QAAM;AAAA,IACF;AAAA,IACA,WAAW;AAAA,IACX;AAAA,IACA,aAAa;AAAA,IACb,WAAW;AAAA,IACX;AAAA,IACA,OAAO;AAAA,IACP,GAAG;AAAA,EAAA,IACHA,OAAAA,oBAA2C,KAAK;AAEpD,QAAM,YAAY,GAAG,yBAAyB,EAAE,QAAQ,WAAA,GAAc,eAAe;AACrF,QAAM,EAAE,OAAO,QAAQ,aAAa,gBAAgB,WAAA,IAAeC,aAAAA,SAAgB,QAAQ;AAE3F,SACI,sBAAA,cAAC,OAAA,EAAI,WAAsB,aAAU,gBAAA,GACjC,sBAAA,cAACC,aAAAA,cAAA,EAAc,GAAG,YAAY,WAAU,iBAAgB,aAAU,aAAA,GAC9D,sBAAA;AAAA,IAACC,6BAAkB;AAAA,IAAlB;AAAA,MACG;AAAA,MACA,QAAQ;AAAA,QACJ,QAAQ;AAAA;AAAA,QAER,MAAM;AAAA,QACN,OAAO;AAAA,QACP,KAAK;AAAA,MAAA;AAAA,IACT;AAAA,IACA,sBAAA,cAACA,6BAAkB,eAAlB,EAAgC,UAAU,OAAO;AAAA,IAClD,sBAAA,cAACA,6BAAkB,SAAlB,EAA0B,SAAS,sBAAA,cAACC,QAAAA,SAAA,EAAQ,OAAO,aAAA,CAAc,EAAA,CAAI;AAAA,IACtE,sBAAA,cAACD,6BAAkB,OAAlB,EAAyB,GAAGE,oBAAa,KAAK,KAAK,GAAG;AAAA,IACvD,sBAAA,cAACF,6BAAkB,OAAlB,EAAyB,GAAGE,oBAAa,KAAK,KAAK,GAAG;AAAA,IACtD,YAAY,QAAQ,UAAU,IAAI;AAAA,EAAA,CAE3C,GACC,aACG,sBAAA,cAACC,OAAAA,QAAA,EAAc,OAAc,YAAY,aAAa,SAAS,gBAAgB,UAAU,WAAA,CAAY,IACrG,IACR;AAER;AAKO,MAAM,cAAc,CAAC,QAAe,WAAoB,OAAO,OAAkB,cAAc;AAClG,SAAO,OAAO,IAAI,CAAA,8CACbH,6BAAkB,MAAlB,EAAuB,KAAK,MAAM,SAAU,GAAG,OAAO,KAAK,WAAW,MAAM,MAAM,OAAO,MAAY,CACzG;AACL;AAKA,SAAS,KAA2B,GAAwD;AACxF,SAAO;AACX;AACA,UAAU,OAAO;;;"}
|
|
@@ -12,7 +12,7 @@ export type LineChartProps<TData extends object> = {
|
|
|
12
12
|
} & CartesianChartProps<TData>;
|
|
13
13
|
export declare function LineChart<TData extends object>(props: LineChartProps<TData>): React.JSX.Element;
|
|
14
14
|
export declare namespace LineChart {
|
|
15
|
-
var Line: <TData extends object>(_: LineChartAreaProps<TData>) => JSX.Element | null;
|
|
15
|
+
var Line: <TData extends object>(_: LineChartAreaProps<TData>) => React.JSX.Element | null;
|
|
16
16
|
}
|
|
17
17
|
/**
|
|
18
18
|
* Helper function to render line shapes as Recharts Line primitives. Extracted to be reusable across LineChart and ComposedChart.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LineChart.js","sources":["../../../../src/charts/components/Line/LineChart.tsx"],"sourcesContent":["import cn from 'clsx';\nimport React from 'react';\nimport * as RechartsPrimitive from 'recharts';\n\nimport { getAxisProps, stripCartesianProps } from '../../utils/common';\nimport { ChartWrapper } from '../ChartWrapper';\nimport { Legend } from '../Legend';\nimport { Tooltip } from '../Tooltip';\nimport type { ChartChildProps, CartesianChartProps, CurveType } from '../types';\nimport { useChart } from '../useChartData';\n\nexport type LineChartProps<TData extends object> = {\n /** Show dots for each data point\n * @default false\n */\n showDots?: boolean;\n /** Interpolation type of the line\n * @default natural\n */\n type?: CurveType;\n} & CartesianChartProps<TData>;\n\nexport function LineChart<TData extends object>(props: LineChartProps<TData>) {\n const {\n children,\n className: customClassName,\n data,\n showLegend = false,\n showDots = false,\n tooltipTitle,\n type = 'natural',\n ...attributes\n } = stripCartesianProps<LineChartProps<TData>>(props);\n\n const className = cn('relative aspect-video', { 'pb-8': showLegend }, customClassName);\n const { items, shapes, activeIndex, setActiveIndex, toggleItem } = useChart<TData>(children);\n\n return (\n <div className={className} data-taco=\"chart-wrapper\">\n <ChartWrapper {...attributes} className=\"h-full w-full\" data-taco=\"chart-line\">\n <RechartsPrimitive.LineChart\n data={data}\n margin={{\n bottom: 0,\n // ensures dots on the edges of the chart don't get cropped\n left: 4,\n right: 4,\n top: 4,\n }}>\n <RechartsPrimitive.CartesianGrid vertical={false} />\n <RechartsPrimitive.Tooltip content={<Tooltip title={tooltipTitle} />} />\n <RechartsPrimitive.XAxis {...getAxisProps('x', props)} />\n <RechartsPrimitive.YAxis {...getAxisProps('y', props)} />\n {renderLines(shapes, showDots, type)}\n </RechartsPrimitive.LineChart>\n </ChartWrapper>\n {showLegend ? (\n <Legend<TData> items={items} hoverIndex={activeIndex} onHover={setActiveIndex} onToggle={toggleItem} />\n ) : null}\n </div>\n );\n}\n\n/**\n * Helper function to render line shapes as Recharts Line primitives. Extracted to be reusable across LineChart and ComposedChart.\n */\nexport const renderLines = (shapes: any[], showDots: boolean = false, type: CurveType = 'natural') => {\n return shapes.map(shape => (\n <RechartsPrimitive.Line key={shape.dataKey} {...shape} dot={showDots ? shape.dot : false} type={type} />\n ));\n};\n\n// oxlint-disable-next-line no-empty-object-type\nexport type LineChartAreaProps<TData extends object> = {} & ChartChildProps<TData>;\n\nfunction Line<TData extends object>(_: LineChartAreaProps<TData>): JSX.Element | null {\n return null;\n}\nLineChart.Line = Line;\n"],"names":["React"],"mappings":";;;;;;;;AAsBO,SAAS,UAAgC,OAA8B;AAC1E,QAAM;AAAA,IACF;AAAA,IACA,WAAW;AAAA,IACX;AAAA,IACA,aAAa;AAAA,IACb,WAAW;AAAA,IACX;AAAA,IACA,OAAO;AAAA,IACP,GAAG;AAAA,EAAA,IACH,oBAA2C,KAAK;AAEpD,QAAM,YAAY,GAAG,yBAAyB,EAAE,QAAQ,WAAA,GAAc,eAAe;AACrF,QAAM,EAAE,OAAO,QAAQ,aAAa,gBAAgB,WAAA,IAAe,SAAgB,QAAQ;AAE3F,SACIA,+BAAA,cAAC,OAAA,EAAI,WAAsB,aAAU,gBAAA,GACjCA,+BAAA,cAAC,cAAA,EAAc,GAAG,YAAY,WAAU,iBAAgB,aAAU,aAAA,GAC9DA,+BAAA;AAAA,IAAC,kBAAkB;AAAA,IAAlB;AAAA,MACG;AAAA,MACA,QAAQ;AAAA,QACJ,QAAQ;AAAA;AAAA,QAER,MAAM;AAAA,QACN,OAAO;AAAA,QACP,KAAK;AAAA,MAAA;AAAA,IACT;AAAA,IACAA,+BAAA,cAAC,kBAAkB,eAAlB,EAAgC,UAAU,OAAO;AAAA,IAClDA,+BAAA,cAAC,kBAAkB,SAAlB,EAA0B,SAASA,+BAAA,cAAC,SAAA,EAAQ,OAAO,aAAA,CAAc,EAAA,CAAI;AAAA,IACtEA,+BAAA,cAAC,kBAAkB,OAAlB,EAAyB,GAAG,aAAa,KAAK,KAAK,GAAG;AAAA,IACvDA,+BAAA,cAAC,kBAAkB,OAAlB,EAAyB,GAAG,aAAa,KAAK,KAAK,GAAG;AAAA,IACtD,YAAY,QAAQ,UAAU,IAAI;AAAA,EAAA,CAE3C,GACC,aACGA,+BAAA,cAAC,QAAA,EAAc,OAAc,YAAY,aAAa,SAAS,gBAAgB,UAAU,WAAA,CAAY,IACrG,IACR;AAER;AAKO,MAAM,cAAc,CAAC,QAAe,WAAoB,OAAO,OAAkB,cAAc;AAClG,SAAO,OAAO,IAAI,CAAA,uDACb,kBAAkB,MAAlB,EAAuB,KAAK,MAAM,SAAU,GAAG,OAAO,KAAK,WAAW,MAAM,MAAM,OAAO,MAAY,CACzG;AACL;AAKA,SAAS,KAA2B,
|
|
1
|
+
{"version":3,"file":"LineChart.js","sources":["../../../../src/charts/components/Line/LineChart.tsx"],"sourcesContent":["import cn from 'clsx';\nimport React from 'react';\nimport * as RechartsPrimitive from 'recharts';\n\nimport { getAxisProps, stripCartesianProps } from '../../utils/common';\nimport { ChartWrapper } from '../ChartWrapper';\nimport { Legend } from '../Legend';\nimport { Tooltip } from '../Tooltip';\nimport type { ChartChildProps, CartesianChartProps, CurveType } from '../types';\nimport { useChart } from '../useChartData';\n\nexport type LineChartProps<TData extends object> = {\n /** Show dots for each data point\n * @default false\n */\n showDots?: boolean;\n /** Interpolation type of the line\n * @default natural\n */\n type?: CurveType;\n} & CartesianChartProps<TData>;\n\nexport function LineChart<TData extends object>(props: LineChartProps<TData>) {\n const {\n children,\n className: customClassName,\n data,\n showLegend = false,\n showDots = false,\n tooltipTitle,\n type = 'natural',\n ...attributes\n } = stripCartesianProps<LineChartProps<TData>>(props);\n\n const className = cn('relative aspect-video', { 'pb-8': showLegend }, customClassName);\n const { items, shapes, activeIndex, setActiveIndex, toggleItem } = useChart<TData>(children);\n\n return (\n <div className={className} data-taco=\"chart-wrapper\">\n <ChartWrapper {...attributes} className=\"h-full w-full\" data-taco=\"chart-line\">\n <RechartsPrimitive.LineChart\n data={data}\n margin={{\n bottom: 0,\n // ensures dots on the edges of the chart don't get cropped\n left: 4,\n right: 4,\n top: 4,\n }}>\n <RechartsPrimitive.CartesianGrid vertical={false} />\n <RechartsPrimitive.Tooltip content={<Tooltip title={tooltipTitle} />} />\n <RechartsPrimitive.XAxis {...getAxisProps('x', props)} />\n <RechartsPrimitive.YAxis {...getAxisProps('y', props)} />\n {renderLines(shapes, showDots, type)}\n </RechartsPrimitive.LineChart>\n </ChartWrapper>\n {showLegend ? (\n <Legend<TData> items={items} hoverIndex={activeIndex} onHover={setActiveIndex} onToggle={toggleItem} />\n ) : null}\n </div>\n );\n}\n\n/**\n * Helper function to render line shapes as Recharts Line primitives. Extracted to be reusable across LineChart and ComposedChart.\n */\nexport const renderLines = (shapes: any[], showDots: boolean = false, type: CurveType = 'natural') => {\n return shapes.map(shape => (\n <RechartsPrimitive.Line key={shape.dataKey} {...shape} dot={showDots ? shape.dot : false} type={type} />\n ));\n};\n\n// oxlint-disable-next-line no-empty-object-type\nexport type LineChartAreaProps<TData extends object> = {} & ChartChildProps<TData>;\n\nfunction Line<TData extends object>(_: LineChartAreaProps<TData>): React.JSX.Element | null {\n return null;\n}\nLineChart.Line = Line;\n"],"names":["React"],"mappings":";;;;;;;;AAsBO,SAAS,UAAgC,OAA8B;AAC1E,QAAM;AAAA,IACF;AAAA,IACA,WAAW;AAAA,IACX;AAAA,IACA,aAAa;AAAA,IACb,WAAW;AAAA,IACX;AAAA,IACA,OAAO;AAAA,IACP,GAAG;AAAA,EAAA,IACH,oBAA2C,KAAK;AAEpD,QAAM,YAAY,GAAG,yBAAyB,EAAE,QAAQ,WAAA,GAAc,eAAe;AACrF,QAAM,EAAE,OAAO,QAAQ,aAAa,gBAAgB,WAAA,IAAe,SAAgB,QAAQ;AAE3F,SACIA,+BAAA,cAAC,OAAA,EAAI,WAAsB,aAAU,gBAAA,GACjCA,+BAAA,cAAC,cAAA,EAAc,GAAG,YAAY,WAAU,iBAAgB,aAAU,aAAA,GAC9DA,+BAAA;AAAA,IAAC,kBAAkB;AAAA,IAAlB;AAAA,MACG;AAAA,MACA,QAAQ;AAAA,QACJ,QAAQ;AAAA;AAAA,QAER,MAAM;AAAA,QACN,OAAO;AAAA,QACP,KAAK;AAAA,MAAA;AAAA,IACT;AAAA,IACAA,+BAAA,cAAC,kBAAkB,eAAlB,EAAgC,UAAU,OAAO;AAAA,IAClDA,+BAAA,cAAC,kBAAkB,SAAlB,EAA0B,SAASA,+BAAA,cAAC,SAAA,EAAQ,OAAO,aAAA,CAAc,EAAA,CAAI;AAAA,IACtEA,+BAAA,cAAC,kBAAkB,OAAlB,EAAyB,GAAG,aAAa,KAAK,KAAK,GAAG;AAAA,IACvDA,+BAAA,cAAC,kBAAkB,OAAlB,EAAyB,GAAG,aAAa,KAAK,KAAK,GAAG;AAAA,IACtD,YAAY,QAAQ,UAAU,IAAI;AAAA,EAAA,CAE3C,GACC,aACGA,+BAAA,cAAC,QAAA,EAAc,OAAc,YAAY,aAAa,SAAS,gBAAgB,UAAU,WAAA,CAAY,IACrG,IACR;AAER;AAKO,MAAM,cAAc,CAAC,QAAe,WAAoB,OAAO,OAAkB,cAAc;AAClG,SAAO,OAAO,IAAI,CAAA,uDACb,kBAAkB,MAAlB,EAAuB,KAAK,MAAM,SAAU,GAAG,OAAO,KAAK,WAAW,MAAM,MAAM,OAAO,MAAY,CACzG;AACL;AAKA,SAAS,KAA2B,GAAwD;AACxF,SAAO;AACX;AACA,UAAU,OAAO;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PieChart.cjs","sources":["../../../../src/charts/components/Pie/PieChart.tsx"],"sourcesContent":["import cn from 'clsx';\nimport React from 'react';\nimport * as RechartsPrimitive from 'recharts';\n\nimport { getInverseThemeColor } from '../../utils/color';\nimport { ChartWrapper } from '../ChartWrapper';\nimport { Legend } from '../Legend';\nimport { Tooltip } from '../Tooltip';\nimport type { ChartChildProps, PolarChartProps } from '../types';\n\nimport { usePieChart } from './util';\n\nexport type PieChartProps = {\n /** Show labels inside each segment\n * @default false\n */\n showLabels?: boolean;\n} & PolarChartProps;\n\nexport function PieChart<TData extends object>(props: PieChartProps) {\n const { children, formatter, showLabels = false, showLegend = false, tooltipTitle, unit, ...attributes } = props;\n const { pieProps, setRadius, items, activeIndex, setActiveIndex, toggleItem } = usePieChart<TData>(children, {\n formatter,\n unit,\n });\n const className = cn('aspect-square', attributes.className);\n\n return (\n <div className=\"relative\" data-taco=\"chart-wrapper\">\n <ChartWrapper {...attributes} className={className} data-taco=\"chart-pie\" onSetWidth={setRadius}>\n <RechartsPrimitive.PieChart>\n <RechartsPrimitive.Tooltip content={<Tooltip title={tooltipTitle} />} />\n <RechartsPrimitive.Pie {...pieProps} label={showLabels ? <Label /> : undefined} />\n </RechartsPrimitive.PieChart>\n </ChartWrapper>\n {showLegend ? (\n <Legend<TData> items={items} hoverIndex={activeIndex} onHover={setActiveIndex} onToggle={toggleItem} />\n ) : null}\n </div>\n );\n}\n\nexport type PieChartSegmentProps<TData extends object> = {\n value: number;\n} & Omit<ChartChildProps<TData>, 'dataKey' | 'formatter' | 'unit'>;\n\nfunction Segment<TData extends object>(_: PieChartSegmentProps<TData>): JSX.Element | null {\n return null;\n}\nPieChart.Segment = Segment;\n\nconst RADIAN = Math.PI / 180;\n\nfunction Label(props: any) {\n const { cx, cy, midAngle, name, innerRadius, outerRadius } = props;\n const radius = innerRadius + (outerRadius - innerRadius) * 0.7;\n const x = cx + radius * Math.cos(-midAngle * RADIAN);\n const y = cy + radius * Math.sin(-midAngle * RADIAN);\n\n return (\n <text\n x={x}\n y={y}\n fontSize={12}\n fill={getInverseThemeColor(props.payload?.payload?.color ?? '')}\n textAnchor=\"middle\"\n dominantBaseline=\"middle\">\n {name}\n </text>\n );\n}\n"],"names":["usePieChart","ChartWrapper","RechartsPrimitive","Tooltip","Legend","getInverseThemeColor"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;AAmBO,SAAS,SAA+B,OAAsB;AACjE,QAAM,EAAE,UAAU,WAAW,aAAa,OAAO,aAAa,OAAO,cAAc,MAAM,GAAG,WAAA,IAAe;AAC3G,QAAM,EAAE,UAAU,WAAW,OAAO,aAAa,gBAAgB,WAAA,IAAeA,KAAAA,YAAmB,UAAU;AAAA,IACzG;AAAA,IACA;AAAA,EAAA,CACH;AACD,QAAM,YAAY,GAAG,iBAAiB,WAAW,SAAS;AAE1D,SACI,sBAAA,cAAC,OAAA,EAAI,WAAU,YAAW,aAAU,gBAAA,GAChC,sBAAA,cAACC,aAAAA,cAAA,EAAc,GAAG,YAAY,WAAsB,aAAU,aAAY,YAAY,UAAA,GAClF,sBAAA,cAACC,6BAAkB,UAAlB,MACG,sBAAA,cAACA,6BAAkB,SAAlB,EAA0B,SAAS,sBAAA,cAACC,QAAAA,SAAA,EAAQ,OAAO,aAAA,CAAc,GAAI,GACtE,sBAAA,cAACD,6BAAkB,KAAlB,EAAuB,GAAG,UAAU,OAAO,aAAa,sBAAA,cAAC,OAAA,IAAM,IAAK,OAAA,CAAW,CACpF,CACJ,GACC,aACG,sBAAA,cAACE,OAAAA,QAAA,EAAc,OAAc,YAAY,aAAa,SAAS,gBAAgB,UAAU,WAAA,CAAY,IACrG,IACR;AAER;AAMA,SAAS,QAA8B,
|
|
1
|
+
{"version":3,"file":"PieChart.cjs","sources":["../../../../src/charts/components/Pie/PieChart.tsx"],"sourcesContent":["import cn from 'clsx';\nimport React from 'react';\nimport * as RechartsPrimitive from 'recharts';\n\nimport { getInverseThemeColor } from '../../utils/color';\nimport { ChartWrapper } from '../ChartWrapper';\nimport { Legend } from '../Legend';\nimport { Tooltip } from '../Tooltip';\nimport type { ChartChildProps, PolarChartProps } from '../types';\n\nimport { usePieChart } from './util';\n\nexport type PieChartProps = {\n /** Show labels inside each segment\n * @default false\n */\n showLabels?: boolean;\n} & PolarChartProps;\n\nexport function PieChart<TData extends object>(props: PieChartProps) {\n const { children, formatter, showLabels = false, showLegend = false, tooltipTitle, unit, ...attributes } = props;\n const { pieProps, setRadius, items, activeIndex, setActiveIndex, toggleItem } = usePieChart<TData>(children, {\n formatter,\n unit,\n });\n const className = cn('aspect-square', attributes.className);\n\n return (\n <div className=\"relative\" data-taco=\"chart-wrapper\">\n <ChartWrapper {...attributes} className={className} data-taco=\"chart-pie\" onSetWidth={setRadius}>\n <RechartsPrimitive.PieChart>\n <RechartsPrimitive.Tooltip content={<Tooltip title={tooltipTitle} />} />\n <RechartsPrimitive.Pie {...pieProps} label={showLabels ? <Label /> : undefined} />\n </RechartsPrimitive.PieChart>\n </ChartWrapper>\n {showLegend ? (\n <Legend<TData> items={items} hoverIndex={activeIndex} onHover={setActiveIndex} onToggle={toggleItem} />\n ) : null}\n </div>\n );\n}\n\nexport type PieChartSegmentProps<TData extends object> = {\n value: number;\n} & Omit<ChartChildProps<TData>, 'dataKey' | 'formatter' | 'unit'>;\n\nfunction Segment<TData extends object>(_: PieChartSegmentProps<TData>): React.JSX.Element | null {\n return null;\n}\nPieChart.Segment = Segment;\n\nconst RADIAN = Math.PI / 180;\n\nfunction Label(props: any) {\n const { cx, cy, midAngle, name, innerRadius, outerRadius } = props;\n const radius = innerRadius + (outerRadius - innerRadius) * 0.7;\n const x = cx + radius * Math.cos(-midAngle * RADIAN);\n const y = cy + radius * Math.sin(-midAngle * RADIAN);\n\n return (\n <text\n x={x}\n y={y}\n fontSize={12}\n fill={getInverseThemeColor(props.payload?.payload?.color ?? '')}\n textAnchor=\"middle\"\n dominantBaseline=\"middle\">\n {name}\n </text>\n );\n}\n"],"names":["usePieChart","ChartWrapper","RechartsPrimitive","Tooltip","Legend","getInverseThemeColor"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;AAmBO,SAAS,SAA+B,OAAsB;AACjE,QAAM,EAAE,UAAU,WAAW,aAAa,OAAO,aAAa,OAAO,cAAc,MAAM,GAAG,WAAA,IAAe;AAC3G,QAAM,EAAE,UAAU,WAAW,OAAO,aAAa,gBAAgB,WAAA,IAAeA,KAAAA,YAAmB,UAAU;AAAA,IACzG;AAAA,IACA;AAAA,EAAA,CACH;AACD,QAAM,YAAY,GAAG,iBAAiB,WAAW,SAAS;AAE1D,SACI,sBAAA,cAAC,OAAA,EAAI,WAAU,YAAW,aAAU,gBAAA,GAChC,sBAAA,cAACC,aAAAA,cAAA,EAAc,GAAG,YAAY,WAAsB,aAAU,aAAY,YAAY,UAAA,GAClF,sBAAA,cAACC,6BAAkB,UAAlB,MACG,sBAAA,cAACA,6BAAkB,SAAlB,EAA0B,SAAS,sBAAA,cAACC,QAAAA,SAAA,EAAQ,OAAO,aAAA,CAAc,GAAI,GACtE,sBAAA,cAACD,6BAAkB,KAAlB,EAAuB,GAAG,UAAU,OAAO,aAAa,sBAAA,cAAC,OAAA,IAAM,IAAK,OAAA,CAAW,CACpF,CACJ,GACC,aACG,sBAAA,cAACE,OAAAA,QAAA,EAAc,OAAc,YAAY,aAAa,SAAS,gBAAgB,UAAU,WAAA,CAAY,IACrG,IACR;AAER;AAMA,SAAS,QAA8B,GAA0D;AAC7F,SAAO;AACX;AACA,SAAS,UAAU;AAEnB,MAAM,SAAS,KAAK,KAAK;AAEzB,SAAS,MAAM,OAAY;AACvB,QAAM,EAAE,IAAI,IAAI,UAAU,MAAM,aAAa,gBAAgB;AAC7D,QAAM,SAAS,eAAe,cAAc,eAAe;AAC3D,QAAM,IAAI,KAAK,SAAS,KAAK,IAAI,CAAC,WAAW,MAAM;AACnD,QAAM,IAAI,KAAK,SAAS,KAAK,IAAI,CAAC,WAAW,MAAM;AAEnD,SACI,sBAAA;AAAA,IAAC;AAAA,IAAA;AAAA,MACG;AAAA,MACA;AAAA,MACA,UAAU;AAAA,MACV,MAAMC,MAAAA,qBAAqB,MAAM,SAAS,SAAS,SAAS,EAAE;AAAA,MAC9D,YAAW;AAAA,MACX,kBAAiB;AAAA,IAAA;AAAA,IAChB;AAAA,EAAA;AAGb;;"}
|
|
@@ -8,7 +8,7 @@ export type PieChartProps = {
|
|
|
8
8
|
} & PolarChartProps;
|
|
9
9
|
export declare function PieChart<TData extends object>(props: PieChartProps): React.JSX.Element;
|
|
10
10
|
export declare namespace PieChart {
|
|
11
|
-
var Segment: <TData extends object>(_: PieChartSegmentProps<TData>) => JSX.Element | null;
|
|
11
|
+
var Segment: <TData extends object>(_: PieChartSegmentProps<TData>) => React.JSX.Element | null;
|
|
12
12
|
}
|
|
13
13
|
export type PieChartSegmentProps<TData extends object> = {
|
|
14
14
|
value: number;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PieChart.js","sources":["../../../../src/charts/components/Pie/PieChart.tsx"],"sourcesContent":["import cn from 'clsx';\nimport React from 'react';\nimport * as RechartsPrimitive from 'recharts';\n\nimport { getInverseThemeColor } from '../../utils/color';\nimport { ChartWrapper } from '../ChartWrapper';\nimport { Legend } from '../Legend';\nimport { Tooltip } from '../Tooltip';\nimport type { ChartChildProps, PolarChartProps } from '../types';\n\nimport { usePieChart } from './util';\n\nexport type PieChartProps = {\n /** Show labels inside each segment\n * @default false\n */\n showLabels?: boolean;\n} & PolarChartProps;\n\nexport function PieChart<TData extends object>(props: PieChartProps) {\n const { children, formatter, showLabels = false, showLegend = false, tooltipTitle, unit, ...attributes } = props;\n const { pieProps, setRadius, items, activeIndex, setActiveIndex, toggleItem } = usePieChart<TData>(children, {\n formatter,\n unit,\n });\n const className = cn('aspect-square', attributes.className);\n\n return (\n <div className=\"relative\" data-taco=\"chart-wrapper\">\n <ChartWrapper {...attributes} className={className} data-taco=\"chart-pie\" onSetWidth={setRadius}>\n <RechartsPrimitive.PieChart>\n <RechartsPrimitive.Tooltip content={<Tooltip title={tooltipTitle} />} />\n <RechartsPrimitive.Pie {...pieProps} label={showLabels ? <Label /> : undefined} />\n </RechartsPrimitive.PieChart>\n </ChartWrapper>\n {showLegend ? (\n <Legend<TData> items={items} hoverIndex={activeIndex} onHover={setActiveIndex} onToggle={toggleItem} />\n ) : null}\n </div>\n );\n}\n\nexport type PieChartSegmentProps<TData extends object> = {\n value: number;\n} & Omit<ChartChildProps<TData>, 'dataKey' | 'formatter' | 'unit'>;\n\nfunction Segment<TData extends object>(_: PieChartSegmentProps<TData>): JSX.Element | null {\n return null;\n}\nPieChart.Segment = Segment;\n\nconst RADIAN = Math.PI / 180;\n\nfunction Label(props: any) {\n const { cx, cy, midAngle, name, innerRadius, outerRadius } = props;\n const radius = innerRadius + (outerRadius - innerRadius) * 0.7;\n const x = cx + radius * Math.cos(-midAngle * RADIAN);\n const y = cy + radius * Math.sin(-midAngle * RADIAN);\n\n return (\n <text\n x={x}\n y={y}\n fontSize={12}\n fill={getInverseThemeColor(props.payload?.payload?.color ?? '')}\n textAnchor=\"middle\"\n dominantBaseline=\"middle\">\n {name}\n </text>\n );\n}\n"],"names":["React"],"mappings":";;;;;;;;AAmBO,SAAS,SAA+B,OAAsB;AACjE,QAAM,EAAE,UAAU,WAAW,aAAa,OAAO,aAAa,OAAO,cAAc,MAAM,GAAG,WAAA,IAAe;AAC3G,QAAM,EAAE,UAAU,WAAW,OAAO,aAAa,gBAAgB,WAAA,IAAe,YAAmB,UAAU;AAAA,IACzG;AAAA,IACA;AAAA,EAAA,CACH;AACD,QAAM,YAAY,GAAG,iBAAiB,WAAW,SAAS;AAE1D,SACIA,+BAAA,cAAC,OAAA,EAAI,WAAU,YAAW,aAAU,gBAAA,GAChCA,+BAAA,cAAC,cAAA,EAAc,GAAG,YAAY,WAAsB,aAAU,aAAY,YAAY,UAAA,GAClFA,+BAAA,cAAC,kBAAkB,UAAlB,MACGA,+BAAA,cAAC,kBAAkB,SAAlB,EAA0B,SAASA,+BAAA,cAAC,SAAA,EAAQ,OAAO,aAAA,CAAc,GAAI,GACtEA,+BAAA,cAAC,kBAAkB,KAAlB,EAAuB,GAAG,UAAU,OAAO,aAAaA,+BAAA,cAAC,OAAA,IAAM,IAAK,OAAA,CAAW,CACpF,CACJ,GACC,aACGA,+BAAA,cAAC,QAAA,EAAc,OAAc,YAAY,aAAa,SAAS,gBAAgB,UAAU,WAAA,CAAY,IACrG,IACR;AAER;AAMA,SAAS,QAA8B,
|
|
1
|
+
{"version":3,"file":"PieChart.js","sources":["../../../../src/charts/components/Pie/PieChart.tsx"],"sourcesContent":["import cn from 'clsx';\nimport React from 'react';\nimport * as RechartsPrimitive from 'recharts';\n\nimport { getInverseThemeColor } from '../../utils/color';\nimport { ChartWrapper } from '../ChartWrapper';\nimport { Legend } from '../Legend';\nimport { Tooltip } from '../Tooltip';\nimport type { ChartChildProps, PolarChartProps } from '../types';\n\nimport { usePieChart } from './util';\n\nexport type PieChartProps = {\n /** Show labels inside each segment\n * @default false\n */\n showLabels?: boolean;\n} & PolarChartProps;\n\nexport function PieChart<TData extends object>(props: PieChartProps) {\n const { children, formatter, showLabels = false, showLegend = false, tooltipTitle, unit, ...attributes } = props;\n const { pieProps, setRadius, items, activeIndex, setActiveIndex, toggleItem } = usePieChart<TData>(children, {\n formatter,\n unit,\n });\n const className = cn('aspect-square', attributes.className);\n\n return (\n <div className=\"relative\" data-taco=\"chart-wrapper\">\n <ChartWrapper {...attributes} className={className} data-taco=\"chart-pie\" onSetWidth={setRadius}>\n <RechartsPrimitive.PieChart>\n <RechartsPrimitive.Tooltip content={<Tooltip title={tooltipTitle} />} />\n <RechartsPrimitive.Pie {...pieProps} label={showLabels ? <Label /> : undefined} />\n </RechartsPrimitive.PieChart>\n </ChartWrapper>\n {showLegend ? (\n <Legend<TData> items={items} hoverIndex={activeIndex} onHover={setActiveIndex} onToggle={toggleItem} />\n ) : null}\n </div>\n );\n}\n\nexport type PieChartSegmentProps<TData extends object> = {\n value: number;\n} & Omit<ChartChildProps<TData>, 'dataKey' | 'formatter' | 'unit'>;\n\nfunction Segment<TData extends object>(_: PieChartSegmentProps<TData>): React.JSX.Element | null {\n return null;\n}\nPieChart.Segment = Segment;\n\nconst RADIAN = Math.PI / 180;\n\nfunction Label(props: any) {\n const { cx, cy, midAngle, name, innerRadius, outerRadius } = props;\n const radius = innerRadius + (outerRadius - innerRadius) * 0.7;\n const x = cx + radius * Math.cos(-midAngle * RADIAN);\n const y = cy + radius * Math.sin(-midAngle * RADIAN);\n\n return (\n <text\n x={x}\n y={y}\n fontSize={12}\n fill={getInverseThemeColor(props.payload?.payload?.color ?? '')}\n textAnchor=\"middle\"\n dominantBaseline=\"middle\">\n {name}\n </text>\n );\n}\n"],"names":["React"],"mappings":";;;;;;;;AAmBO,SAAS,SAA+B,OAAsB;AACjE,QAAM,EAAE,UAAU,WAAW,aAAa,OAAO,aAAa,OAAO,cAAc,MAAM,GAAG,WAAA,IAAe;AAC3G,QAAM,EAAE,UAAU,WAAW,OAAO,aAAa,gBAAgB,WAAA,IAAe,YAAmB,UAAU;AAAA,IACzG;AAAA,IACA;AAAA,EAAA,CACH;AACD,QAAM,YAAY,GAAG,iBAAiB,WAAW,SAAS;AAE1D,SACIA,+BAAA,cAAC,OAAA,EAAI,WAAU,YAAW,aAAU,gBAAA,GAChCA,+BAAA,cAAC,cAAA,EAAc,GAAG,YAAY,WAAsB,aAAU,aAAY,YAAY,UAAA,GAClFA,+BAAA,cAAC,kBAAkB,UAAlB,MACGA,+BAAA,cAAC,kBAAkB,SAAlB,EAA0B,SAASA,+BAAA,cAAC,SAAA,EAAQ,OAAO,aAAA,CAAc,GAAI,GACtEA,+BAAA,cAAC,kBAAkB,KAAlB,EAAuB,GAAG,UAAU,OAAO,aAAaA,+BAAA,cAAC,OAAA,IAAM,IAAK,OAAA,CAAW,CACpF,CACJ,GACC,aACGA,+BAAA,cAAC,QAAA,EAAc,OAAc,YAAY,aAAa,SAAS,gBAAgB,UAAU,WAAA,CAAY,IACrG,IACR;AAER;AAMA,SAAS,QAA8B,GAA0D;AAC7F,SAAO;AACX;AACA,SAAS,UAAU;AAEnB,MAAM,SAAS,KAAK,KAAK;AAEzB,SAAS,MAAM,OAAY;AACvB,QAAM,EAAE,IAAI,IAAI,UAAU,MAAM,aAAa,gBAAgB;AAC7D,QAAM,SAAS,eAAe,cAAc,eAAe;AAC3D,QAAM,IAAI,KAAK,SAAS,KAAK,IAAI,CAAC,WAAW,MAAM;AACnD,QAAM,IAAI,KAAK,SAAS,KAAK,IAAI,CAAC,WAAW,MAAM;AAEnD,SACIA,+BAAA;AAAA,IAAC;AAAA,IAAA;AAAA,MACG;AAAA,MACA;AAAA,MACA,UAAU;AAAA,MACV,MAAM,qBAAqB,MAAM,SAAS,SAAS,SAAS,EAAE;AAAA,MAC9D,YAAW;AAAA,MACX,kBAAiB;AAAA,IAAA;AAAA,IAChB;AAAA,EAAA;AAGb;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Tooltip.cjs","sources":["../../../src/charts/components/Tooltip.tsx"],"sourcesContent":["import React from 'react';\nimport type * as RechartsPrimitive from 'recharts';\n\nexport type TooltipProps = Omit<React.ComponentProps<typeof RechartsPrimitive.Tooltip>, 'formatter'> & {\n active?: boolean;\n style?: React.CSSProperties;\n title?: JSX.Element | string | null | false;\n};\n\nexport function Tooltip(props: TooltipProps) {\n const { active, payload = [], style, title } = props;\n\n if (active && payload.length) {\n return (\n <div className=\"z-20 z-[999] flex flex-col gap-y-1 rounded border border-gray-300 bg-white px-2 py-1.5 text-xs shadow-sm\">\n {title ? <span className=\"font-bold\">{title}</span> : null}\n <dl className=\"m-0 grid grid-cols-[max-content_max-content] gap-x-4 gap-y-0.5\" style={style}>\n {payload.map((entry, index) => {\n // some components like pie chart double nest\n const color = entry.color ?? entry.payload.color;\n const formatter = entry.formatter ?? entry.payload.formatter;\n const unit = entry.unit ?? entry.payload.unit;\n\n return (\n <React.Fragment key={`${entry.name}-${index}`}>\n <dt className=\"mb-0 flex items-center gap-1 font-normal text-gray-700\" data-taco=\"chart-tooltip\">\n <span className=\"-mt-px h-2.5 w-2.5 rounded-sm\" style={{ background: color }} />\n {entry.name}\n </dt>\n <dd className=\"mb-0 text-right font-bold tabular-nums text-black\">\n {formatter?.(entry.value ?? '', entry.name ?? '', entry, index, entry.payload) ?? entry.value}\n {unit ? <span className=\"pl-0.5 text-gray-700\">{unit}</span> : null}\n </dd>\n </React.Fragment>\n );\n })}\n </dl>\n </div>\n );\n }\n\n return null;\n}\n"],"names":[],"mappings":";;;AASO,SAAS,QAAQ,OAAqB;AACzC,QAAM,EAAE,QAAQ,UAAU,CAAA,GAAI,OAAO,UAAU;AAE/C,MAAI,UAAU,QAAQ,QAAQ;AAC1B,WACI,sBAAA,cAAC,SAAI,WAAU,2GAAA,GACV,QAAQ,sBAAA,cAAC,QAAA,EAAK,WAAU,YAAA,GAAa,KAAM,IAAU,MACtD,sBAAA,cAAC,QAAG,WAAU,kEAAiE,SAC1E,QAAQ,IAAI,CAAC,OAAO,UAAU;AAE3B,YAAM,QAAQ,MAAM,SAAS,MAAM,QAAQ;AAC3C,YAAM,YAAY,MAAM,aAAa,MAAM,QAAQ;AACnD,YAAM,OAAO,MAAM,QAAQ,MAAM,QAAQ;AAEzC,aACI,sBAAA,cAAC,MAAM,UAAN,EAAe,KAAK,GAAG,MAAM,IAAI,IAAI,KAAK,GAAA,GACvC,sBAAA,cAAC,MAAA,EAAG,WAAU,0DAAyD,aAAU,gBAAA,GAC7E,sBAAA,cAAC,QAAA,EAAK,WAAU,iCAAgC,OAAO,EAAE,YAAY,MAAA,EAAM,CAAG,GAC7E,MAAM,IACX,GACA,sBAAA,cAAC,MAAA,EAAG,WAAU,oDAAA,GACT,YAAY,MAAM,SAAS,IAAI,MAAM,QAAQ,IAAI,OAAO,OAAO,MAAM,OAAO,KAAK,MAAM,OACvF,OAAO,sBAAA,cAAC,QAAA,EAAK,WAAU,uBAAA,GAAwB,IAAK,IAAU,IACnE,CACJ;AAAA,IAER,CAAC,CACL,CACJ;AAAA,EAER;AAEA,SAAO;AACX;;"}
|
|
1
|
+
{"version":3,"file":"Tooltip.cjs","sources":["../../../src/charts/components/Tooltip.tsx"],"sourcesContent":["import React from 'react';\nimport type * as RechartsPrimitive from 'recharts';\n\nexport type TooltipProps = Omit<React.ComponentProps<typeof RechartsPrimitive.Tooltip>, 'formatter'> & {\n active?: boolean;\n style?: React.CSSProperties;\n title?: React.JSX.Element | string | null | false;\n};\n\nexport function Tooltip(props: TooltipProps) {\n const { active, payload = [], style, title } = props;\n\n if (active && payload.length) {\n return (\n <div className=\"z-20 z-[999] flex flex-col gap-y-1 rounded border border-gray-300 bg-white px-2 py-1.5 text-xs shadow-sm\">\n {title ? <span className=\"font-bold\">{title}</span> : null}\n <dl className=\"m-0 grid grid-cols-[max-content_max-content] gap-x-4 gap-y-0.5\" style={style}>\n {payload.map((entry, index) => {\n // some components like pie chart double nest\n const color = entry.color ?? entry.payload.color;\n const formatter = entry.formatter ?? entry.payload.formatter;\n const unit = entry.unit ?? entry.payload.unit;\n\n return (\n <React.Fragment key={`${entry.name}-${index}`}>\n <dt className=\"mb-0 flex items-center gap-1 font-normal text-gray-700\" data-taco=\"chart-tooltip\">\n <span className=\"-mt-px h-2.5 w-2.5 rounded-sm\" style={{ background: color }} />\n {entry.name}\n </dt>\n <dd className=\"mb-0 text-right font-bold tabular-nums text-black\">\n {formatter?.(entry.value ?? '', entry.name ?? '', entry, index, entry.payload) ?? entry.value}\n {unit ? <span className=\"pl-0.5 text-gray-700\">{unit}</span> : null}\n </dd>\n </React.Fragment>\n );\n })}\n </dl>\n </div>\n );\n }\n\n return null;\n}\n"],"names":[],"mappings":";;;AASO,SAAS,QAAQ,OAAqB;AACzC,QAAM,EAAE,QAAQ,UAAU,CAAA,GAAI,OAAO,UAAU;AAE/C,MAAI,UAAU,QAAQ,QAAQ;AAC1B,WACI,sBAAA,cAAC,SAAI,WAAU,2GAAA,GACV,QAAQ,sBAAA,cAAC,QAAA,EAAK,WAAU,YAAA,GAAa,KAAM,IAAU,MACtD,sBAAA,cAAC,QAAG,WAAU,kEAAiE,SAC1E,QAAQ,IAAI,CAAC,OAAO,UAAU;AAE3B,YAAM,QAAQ,MAAM,SAAS,MAAM,QAAQ;AAC3C,YAAM,YAAY,MAAM,aAAa,MAAM,QAAQ;AACnD,YAAM,OAAO,MAAM,QAAQ,MAAM,QAAQ;AAEzC,aACI,sBAAA,cAAC,MAAM,UAAN,EAAe,KAAK,GAAG,MAAM,IAAI,IAAI,KAAK,GAAA,GACvC,sBAAA,cAAC,MAAA,EAAG,WAAU,0DAAyD,aAAU,gBAAA,GAC7E,sBAAA,cAAC,QAAA,EAAK,WAAU,iCAAgC,OAAO,EAAE,YAAY,MAAA,EAAM,CAAG,GAC7E,MAAM,IACX,GACA,sBAAA,cAAC,MAAA,EAAG,WAAU,oDAAA,GACT,YAAY,MAAM,SAAS,IAAI,MAAM,QAAQ,IAAI,OAAO,OAAO,MAAM,OAAO,KAAK,MAAM,OACvF,OAAO,sBAAA,cAAC,QAAA,EAAK,WAAU,uBAAA,GAAwB,IAAK,IAAU,IACnE,CACJ;AAAA,IAER,CAAC,CACL,CACJ;AAAA,EAER;AAEA,SAAO;AACX;;"}
|
|
@@ -3,6 +3,6 @@ import type * as RechartsPrimitive from 'recharts';
|
|
|
3
3
|
export type TooltipProps = Omit<React.ComponentProps<typeof RechartsPrimitive.Tooltip>, 'formatter'> & {
|
|
4
4
|
active?: boolean;
|
|
5
5
|
style?: React.CSSProperties;
|
|
6
|
-
title?: JSX.Element | string | null | false;
|
|
6
|
+
title?: React.JSX.Element | string | null | false;
|
|
7
7
|
};
|
|
8
8
|
export declare function Tooltip(props: TooltipProps): React.JSX.Element | null;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Tooltip.js","sources":["../../../src/charts/components/Tooltip.tsx"],"sourcesContent":["import React from 'react';\nimport type * as RechartsPrimitive from 'recharts';\n\nexport type TooltipProps = Omit<React.ComponentProps<typeof RechartsPrimitive.Tooltip>, 'formatter'> & {\n active?: boolean;\n style?: React.CSSProperties;\n title?: JSX.Element | string | null | false;\n};\n\nexport function Tooltip(props: TooltipProps) {\n const { active, payload = [], style, title } = props;\n\n if (active && payload.length) {\n return (\n <div className=\"z-20 z-[999] flex flex-col gap-y-1 rounded border border-gray-300 bg-white px-2 py-1.5 text-xs shadow-sm\">\n {title ? <span className=\"font-bold\">{title}</span> : null}\n <dl className=\"m-0 grid grid-cols-[max-content_max-content] gap-x-4 gap-y-0.5\" style={style}>\n {payload.map((entry, index) => {\n // some components like pie chart double nest\n const color = entry.color ?? entry.payload.color;\n const formatter = entry.formatter ?? entry.payload.formatter;\n const unit = entry.unit ?? entry.payload.unit;\n\n return (\n <React.Fragment key={`${entry.name}-${index}`}>\n <dt className=\"mb-0 flex items-center gap-1 font-normal text-gray-700\" data-taco=\"chart-tooltip\">\n <span className=\"-mt-px h-2.5 w-2.5 rounded-sm\" style={{ background: color }} />\n {entry.name}\n </dt>\n <dd className=\"mb-0 text-right font-bold tabular-nums text-black\">\n {formatter?.(entry.value ?? '', entry.name ?? '', entry, index, entry.payload) ?? entry.value}\n {unit ? <span className=\"pl-0.5 text-gray-700\">{unit}</span> : null}\n </dd>\n </React.Fragment>\n );\n })}\n </dl>\n </div>\n );\n }\n\n return null;\n}\n"],"names":["React"],"mappings":";AASO,SAAS,QAAQ,OAAqB;AACzC,QAAM,EAAE,QAAQ,UAAU,CAAA,GAAI,OAAO,UAAU;AAE/C,MAAI,UAAU,QAAQ,QAAQ;AAC1B,WACIA,+BAAA,cAAC,SAAI,WAAU,2GAAA,GACV,QAAQA,+BAAA,cAAC,QAAA,EAAK,WAAU,YAAA,GAAa,KAAM,IAAU,MACtDA,+BAAA,cAAC,QAAG,WAAU,kEAAiE,SAC1E,QAAQ,IAAI,CAAC,OAAO,UAAU;AAE3B,YAAM,QAAQ,MAAM,SAAS,MAAM,QAAQ;AAC3C,YAAM,YAAY,MAAM,aAAa,MAAM,QAAQ;AACnD,YAAM,OAAO,MAAM,QAAQ,MAAM,QAAQ;AAEzC,aACIA,+BAAA,cAACA,eAAM,UAAN,EAAe,KAAK,GAAG,MAAM,IAAI,IAAI,KAAK,GAAA,GACvCA,+BAAA,cAAC,MAAA,EAAG,WAAU,0DAAyD,aAAU,gBAAA,GAC7EA,+BAAA,cAAC,QAAA,EAAK,WAAU,iCAAgC,OAAO,EAAE,YAAY,MAAA,EAAM,CAAG,GAC7E,MAAM,IACX,GACAA,+BAAA,cAAC,MAAA,EAAG,WAAU,oDAAA,GACT,YAAY,MAAM,SAAS,IAAI,MAAM,QAAQ,IAAI,OAAO,OAAO,MAAM,OAAO,KAAK,MAAM,OACvF,OAAOA,+BAAA,cAAC,QAAA,EAAK,WAAU,uBAAA,GAAwB,IAAK,IAAU,IACnE,CACJ;AAAA,IAER,CAAC,CACL,CACJ;AAAA,EAER;AAEA,SAAO;AACX;"}
|
|
1
|
+
{"version":3,"file":"Tooltip.js","sources":["../../../src/charts/components/Tooltip.tsx"],"sourcesContent":["import React from 'react';\nimport type * as RechartsPrimitive from 'recharts';\n\nexport type TooltipProps = Omit<React.ComponentProps<typeof RechartsPrimitive.Tooltip>, 'formatter'> & {\n active?: boolean;\n style?: React.CSSProperties;\n title?: React.JSX.Element | string | null | false;\n};\n\nexport function Tooltip(props: TooltipProps) {\n const { active, payload = [], style, title } = props;\n\n if (active && payload.length) {\n return (\n <div className=\"z-20 z-[999] flex flex-col gap-y-1 rounded border border-gray-300 bg-white px-2 py-1.5 text-xs shadow-sm\">\n {title ? <span className=\"font-bold\">{title}</span> : null}\n <dl className=\"m-0 grid grid-cols-[max-content_max-content] gap-x-4 gap-y-0.5\" style={style}>\n {payload.map((entry, index) => {\n // some components like pie chart double nest\n const color = entry.color ?? entry.payload.color;\n const formatter = entry.formatter ?? entry.payload.formatter;\n const unit = entry.unit ?? entry.payload.unit;\n\n return (\n <React.Fragment key={`${entry.name}-${index}`}>\n <dt className=\"mb-0 flex items-center gap-1 font-normal text-gray-700\" data-taco=\"chart-tooltip\">\n <span className=\"-mt-px h-2.5 w-2.5 rounded-sm\" style={{ background: color }} />\n {entry.name}\n </dt>\n <dd className=\"mb-0 text-right font-bold tabular-nums text-black\">\n {formatter?.(entry.value ?? '', entry.name ?? '', entry, index, entry.payload) ?? entry.value}\n {unit ? <span className=\"pl-0.5 text-gray-700\">{unit}</span> : null}\n </dd>\n </React.Fragment>\n );\n })}\n </dl>\n </div>\n );\n }\n\n return null;\n}\n"],"names":["React"],"mappings":";AASO,SAAS,QAAQ,OAAqB;AACzC,QAAM,EAAE,QAAQ,UAAU,CAAA,GAAI,OAAO,UAAU;AAE/C,MAAI,UAAU,QAAQ,QAAQ;AAC1B,WACIA,+BAAA,cAAC,SAAI,WAAU,2GAAA,GACV,QAAQA,+BAAA,cAAC,QAAA,EAAK,WAAU,YAAA,GAAa,KAAM,IAAU,MACtDA,+BAAA,cAAC,QAAG,WAAU,kEAAiE,SAC1E,QAAQ,IAAI,CAAC,OAAO,UAAU;AAE3B,YAAM,QAAQ,MAAM,SAAS,MAAM,QAAQ;AAC3C,YAAM,YAAY,MAAM,aAAa,MAAM,QAAQ;AACnD,YAAM,OAAO,MAAM,QAAQ,MAAM,QAAQ;AAEzC,aACIA,+BAAA,cAACA,eAAM,UAAN,EAAe,KAAK,GAAG,MAAM,IAAI,IAAI,KAAK,GAAA,GACvCA,+BAAA,cAAC,MAAA,EAAG,WAAU,0DAAyD,aAAU,gBAAA,GAC7EA,+BAAA,cAAC,QAAA,EAAK,WAAU,iCAAgC,OAAO,EAAE,YAAY,MAAA,EAAM,CAAG,GAC7E,MAAM,IACX,GACAA,+BAAA,cAAC,MAAA,EAAG,WAAU,oDAAA,GACT,YAAY,MAAM,SAAS,IAAI,MAAM,QAAQ,IAAI,OAAO,OAAO,MAAM,OAAO,KAAK,MAAM,OACvF,OAAOA,+BAAA,cAAC,QAAA,EAAK,WAAU,uBAAA,GAAwB,IAAK,IAAU,IACnE,CACJ;AAAA,IAER,CAAC,CACL,CACJ;AAAA,EAER;AAEA,SAAO;AACX;"}
|
|
@@ -10,7 +10,7 @@ export type LegacyChartChildProps = {
|
|
|
10
10
|
color: Color;
|
|
11
11
|
label: string;
|
|
12
12
|
};
|
|
13
|
-
export type ChartValueFormatter = (value: number) => string | JSX.Element;
|
|
13
|
+
export type ChartValueFormatter = (value: number) => string | React.JSX.Element;
|
|
14
14
|
export type TickFormatter = (value: any) => string;
|
|
15
15
|
export type CurveType = 'natural' | 'linear' | 'step';
|
|
16
16
|
export type ChartProps = {
|
|
@@ -19,7 +19,7 @@ export type ChartProps = {
|
|
|
19
19
|
*/
|
|
20
20
|
showLegend?: boolean;
|
|
21
21
|
/** Add a title to the Tooltip show when hovering data */
|
|
22
|
-
tooltipTitle?: JSX.Element | string | null | false;
|
|
22
|
+
tooltipTitle?: React.JSX.Element | string | null | false;
|
|
23
23
|
} & React.ComponentProps<'div'>;
|
|
24
24
|
export type CartesianChartProps<TData extends object> = {
|
|
25
25
|
/** Data to show in chart, should be an array of objects */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AlertDialog.cjs","sources":["../../../src/components/AlertDialog/AlertDialog.tsx"],"sourcesContent":["import { AlertDialog as AlertDialogPrimitive } from '@base-ui/react/alert-dialog';\nimport * as React from 'react';\n\nimport type { AlertDialogContentProps, AlertDialogTitleProps, AlertDialogDescriptionProps } from './components/Content';\nimport { Description, Title, Content } from './components/Content';\nimport type { AlertDialogCancelProps, AlertDialogActionProps, AlertDialogFooterProps } from './components/Footer';\nimport { Cancel, Action, Footer } from './components/Footer';\nimport type { AlertDialogTriggerProps } from './components/Trigger';\nimport { Trigger } from './components/Trigger';\nimport { AlertDialogContext } from './Context';\n\nexport type AlertDialogProps = {\n children: React.ReactNode | React.ReactNode[];\n /**\n * Set whether the alert dialog is open by default or not, use when not providing a trigger\n * @default false\n */\n defaultOpen?: boolean;\n /** Called when the alert dialog opens or closes, must be used in conjunction with open */\n onChange?: (open: boolean) => void;\n /**\n * Control the open state of the dialog from outside the component\n * @default false\n */\n open?: boolean;\n /** A trigger to be used for the alert dialog, should not be set if `children` already contains a trigger */\n trigger?: JSX.Element;\n /**\n * A state to be used for the alert dialog, which will add appropriate badge icon next to the title\n * @default undefined\n */\n variant?: 'warning' | 'error' | 'information';\n};\n\nexport type ForwardedAlertDialogWithStatics = React.ForwardRefExoticComponent<\n AlertDialogProps & React.RefAttributes<HTMLElement>\n> & {\n Trigger: React.ForwardRefExoticComponent<AlertDialogTriggerProps & React.RefAttributes<HTMLButtonElement>>;\n Content: React.ForwardRefExoticComponent<AlertDialogContentProps & React.RefAttributes<HTMLDivElement>>;\n Title: React.ForwardRefExoticComponent<AlertDialogTitleProps & React.RefAttributes<HTMLHeadingElement>>;\n Description: React.ForwardRefExoticComponent<AlertDialogDescriptionProps & React.RefAttributes<HTMLParagraphElement>>;\n Footer: React.ForwardRefExoticComponent<AlertDialogFooterProps & React.RefAttributes<HTMLDivElement>>;\n Action: React.ForwardRefExoticComponent<AlertDialogActionProps & React.RefAttributes<HTMLButtonElement>>;\n Cancel: React.ForwardRefExoticComponent<AlertDialogCancelProps & React.RefAttributes<HTMLButtonElement>>;\n};\n\nexport const AlertDialog = React.forwardRef(function AlertDialog(props: AlertDialogProps, ref: React.Ref<HTMLElement>) {\n const { children, defaultOpen, onChange, open, trigger, ...otherProps } = props;\n\n const context = React.useMemo(\n () => ({\n props: otherProps,\n ref,\n }),\n [open, otherProps]\n );\n\n const handleOpenChange = (open: boolean, eventDetails: AlertDialogPrimitive.Root.ChangeEventDetails) => {\n if (eventDetails.reason === 'escape-key') {\n const triggeredFromRadixPortal = (eventDetails.event.target as HTMLElement)?.closest(\n 'div[data-radix-popper-content-wrapper]'\n );\n\n if (triggeredFromRadixPortal) {\n // TODO: This could be removed when all radix overlays are replaced with base UI components, but currently it propagates through and closes the dialog.\n\n // cancel closing the dialog\n eventDetails.cancel();\n // propagate to allow the radix overlay to close\n eventDetails.allowPropagation();\n return;\n }\n eventDetails.cancel();\n return;\n }\n\n onChange?.(open);\n };\n\n return (\n <AlertDialogContext.Provider value={context}>\n <AlertDialogPrimitive.Root {...otherProps} defaultOpen={defaultOpen} open={open} onOpenChange={handleOpenChange}>\n {trigger && <Trigger>{trigger}</Trigger>}\n {children}\n </AlertDialogPrimitive.Root>\n </AlertDialogContext.Provider>\n );\n}) as ForwardedAlertDialogWithStatics;\n\nAlertDialog.Trigger = Trigger;\nAlertDialog.Content = Content;\nAlertDialog.Description = Description;\nAlertDialog.Title = Title;\nAlertDialog.Cancel = Cancel;\nAlertDialog.Action = Action;\nAlertDialog.Footer = Footer;\n"],"names":["React","AlertDialog","open","AlertDialogContext","AlertDialogPrimitive","Trigger","Content","Description","Title","Cancel","Action","Footer"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;AA8CO,MAAM,cAAcA,iBAAM,WAAW,SAASC,aAAY,OAAyB,KAA6B;AACnH,QAAM,EAAE,UAAU,aAAa,UAAU,MAAM,SAAS,GAAG,eAAe;AAE1E,QAAM,UAAUD,iBAAM;AAAA,IAClB,OAAO;AAAA,MACH,OAAO;AAAA,MACP;AAAA,IAAA;AAAA,IAEJ,CAAC,MAAM,UAAU;AAAA,EAAA;AAGrB,QAAM,mBAAmB,CAACE,OAAe,iBAA+D;AACpG,QAAI,aAAa,WAAW,cAAc;AACtC,YAAM,2BAA4B,aAAa,MAAM,QAAwB;AAAA,QACzE;AAAA,MAAA;AAGJ,UAAI,0BAA0B;AAI1B,qBAAa,OAAA;AAEb,qBAAa,iBAAA;AACb;AAAA,MACJ;AACA,mBAAa,OAAA;AACb;AAAA,IACJ;AAEA,eAAWA,KAAI;AAAA,EACnB;AAEA,SACIF,iCAAA,cAACG,QAAAA,mBAAmB,UAAnB,EAA4B,OAAO,QAAA,GAChCH,iCAAA,cAACI,YAAAA,YAAqB,MAArB,EAA2B,GAAG,YAAY,aAA0B,MAAY,cAAc,iBAAA,GAC1F,0DAAYC,QAAAA,SAAA,MAAS,OAAQ,GAC7B,QACL,CACJ;AAER,CAAC;AAED,YAAY,UAAUA,QAAAA;AACtB,YAAY,UAAUC,QAAAA;AACtB,YAAY,cAAcC,QAAAA;AAC1B,YAAY,QAAQC,QAAAA;AACpB,YAAY,SAASC,OAAAA;AACrB,YAAY,SAASC,OAAAA;AACrB,YAAY,SAASC,OAAAA;;"}
|
|
1
|
+
{"version":3,"file":"AlertDialog.cjs","sources":["../../../src/components/AlertDialog/AlertDialog.tsx"],"sourcesContent":["import { AlertDialog as AlertDialogPrimitive } from '@base-ui/react/alert-dialog';\nimport * as React from 'react';\n\nimport type { AlertDialogContentProps, AlertDialogTitleProps, AlertDialogDescriptionProps } from './components/Content';\nimport { Description, Title, Content } from './components/Content';\nimport type { AlertDialogCancelProps, AlertDialogActionProps, AlertDialogFooterProps } from './components/Footer';\nimport { Cancel, Action, Footer } from './components/Footer';\nimport type { AlertDialogTriggerProps } from './components/Trigger';\nimport { Trigger } from './components/Trigger';\nimport { AlertDialogContext } from './Context';\n\nexport type AlertDialogProps = {\n children: React.ReactNode | React.ReactNode[];\n /**\n * Set whether the alert dialog is open by default or not, use when not providing a trigger\n * @default false\n */\n defaultOpen?: boolean;\n /** Called when the alert dialog opens or closes, must be used in conjunction with open */\n onChange?: (open: boolean) => void;\n /**\n * Control the open state of the dialog from outside the component\n * @default false\n */\n open?: boolean;\n /** A trigger to be used for the alert dialog, should not be set if `children` already contains a trigger */\n trigger?: React.JSX.Element;\n /**\n * A state to be used for the alert dialog, which will add appropriate badge icon next to the title\n * @default undefined\n */\n variant?: 'warning' | 'error' | 'information';\n};\n\nexport type ForwardedAlertDialogWithStatics = React.ForwardRefExoticComponent<\n AlertDialogProps & React.RefAttributes<HTMLElement>\n> & {\n Trigger: React.ForwardRefExoticComponent<AlertDialogTriggerProps & React.RefAttributes<HTMLButtonElement>>;\n Content: React.ForwardRefExoticComponent<AlertDialogContentProps & React.RefAttributes<HTMLDivElement>>;\n Title: React.ForwardRefExoticComponent<AlertDialogTitleProps & React.RefAttributes<HTMLHeadingElement>>;\n Description: React.ForwardRefExoticComponent<AlertDialogDescriptionProps & React.RefAttributes<HTMLParagraphElement>>;\n Footer: React.ForwardRefExoticComponent<AlertDialogFooterProps & React.RefAttributes<HTMLDivElement>>;\n Action: React.ForwardRefExoticComponent<AlertDialogActionProps & React.RefAttributes<HTMLButtonElement>>;\n Cancel: React.ForwardRefExoticComponent<AlertDialogCancelProps & React.RefAttributes<HTMLButtonElement>>;\n};\n\nexport const AlertDialog = React.forwardRef(function AlertDialog(props: AlertDialogProps, ref: React.Ref<HTMLElement>) {\n const { children, defaultOpen, onChange, open, trigger, ...otherProps } = props;\n\n const context = React.useMemo(\n () => ({\n props: otherProps,\n ref,\n }),\n [open, otherProps]\n );\n\n const handleOpenChange = (open: boolean, eventDetails: AlertDialogPrimitive.Root.ChangeEventDetails) => {\n if (eventDetails.reason === 'escape-key') {\n const triggeredFromRadixPortal = (eventDetails.event.target as HTMLElement)?.closest(\n 'div[data-radix-popper-content-wrapper]'\n );\n\n if (triggeredFromRadixPortal) {\n // TODO: This could be removed when all radix overlays are replaced with base UI components, but currently it propagates through and closes the dialog.\n\n // cancel closing the dialog\n eventDetails.cancel();\n // propagate to allow the radix overlay to close\n eventDetails.allowPropagation();\n return;\n }\n eventDetails.cancel();\n return;\n }\n\n onChange?.(open);\n };\n\n return (\n <AlertDialogContext.Provider value={context}>\n <AlertDialogPrimitive.Root {...otherProps} defaultOpen={defaultOpen} open={open} onOpenChange={handleOpenChange}>\n {trigger && <Trigger>{trigger}</Trigger>}\n {children}\n </AlertDialogPrimitive.Root>\n </AlertDialogContext.Provider>\n );\n}) as ForwardedAlertDialogWithStatics;\n\nAlertDialog.Trigger = Trigger;\nAlertDialog.Content = Content;\nAlertDialog.Description = Description;\nAlertDialog.Title = Title;\nAlertDialog.Cancel = Cancel;\nAlertDialog.Action = Action;\nAlertDialog.Footer = Footer;\n"],"names":["React","AlertDialog","open","AlertDialogContext","AlertDialogPrimitive","Trigger","Content","Description","Title","Cancel","Action","Footer"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;AA8CO,MAAM,cAAcA,iBAAM,WAAW,SAASC,aAAY,OAAyB,KAA6B;AACnH,QAAM,EAAE,UAAU,aAAa,UAAU,MAAM,SAAS,GAAG,eAAe;AAE1E,QAAM,UAAUD,iBAAM;AAAA,IAClB,OAAO;AAAA,MACH,OAAO;AAAA,MACP;AAAA,IAAA;AAAA,IAEJ,CAAC,MAAM,UAAU;AAAA,EAAA;AAGrB,QAAM,mBAAmB,CAACE,OAAe,iBAA+D;AACpG,QAAI,aAAa,WAAW,cAAc;AACtC,YAAM,2BAA4B,aAAa,MAAM,QAAwB;AAAA,QACzE;AAAA,MAAA;AAGJ,UAAI,0BAA0B;AAI1B,qBAAa,OAAA;AAEb,qBAAa,iBAAA;AACb;AAAA,MACJ;AACA,mBAAa,OAAA;AACb;AAAA,IACJ;AAEA,eAAWA,KAAI;AAAA,EACnB;AAEA,SACIF,iCAAA,cAACG,QAAAA,mBAAmB,UAAnB,EAA4B,OAAO,QAAA,GAChCH,iCAAA,cAACI,YAAAA,YAAqB,MAArB,EAA2B,GAAG,YAAY,aAA0B,MAAY,cAAc,iBAAA,GAC1F,0DAAYC,QAAAA,SAAA,MAAS,OAAQ,GAC7B,QACL,CACJ;AAER,CAAC;AAED,YAAY,UAAUA,QAAAA;AACtB,YAAY,UAAUC,QAAAA;AACtB,YAAY,cAAcC,QAAAA;AAC1B,YAAY,QAAQC,QAAAA;AACpB,YAAY,SAASC,OAAAA;AACrB,YAAY,SAASC,OAAAA;AACrB,YAAY,SAASC,OAAAA;;"}
|
|
@@ -17,7 +17,7 @@ export type AlertDialogProps = {
|
|
|
17
17
|
*/
|
|
18
18
|
open?: boolean;
|
|
19
19
|
/** A trigger to be used for the alert dialog, should not be set if `children` already contains a trigger */
|
|
20
|
-
trigger?: JSX.Element;
|
|
20
|
+
trigger?: React.JSX.Element;
|
|
21
21
|
/**
|
|
22
22
|
* A state to be used for the alert dialog, which will add appropriate badge icon next to the title
|
|
23
23
|
* @default undefined
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AlertDialog.js","sources":["../../../src/components/AlertDialog/AlertDialog.tsx"],"sourcesContent":["import { AlertDialog as AlertDialogPrimitive } from '@base-ui/react/alert-dialog';\nimport * as React from 'react';\n\nimport type { AlertDialogContentProps, AlertDialogTitleProps, AlertDialogDescriptionProps } from './components/Content';\nimport { Description, Title, Content } from './components/Content';\nimport type { AlertDialogCancelProps, AlertDialogActionProps, AlertDialogFooterProps } from './components/Footer';\nimport { Cancel, Action, Footer } from './components/Footer';\nimport type { AlertDialogTriggerProps } from './components/Trigger';\nimport { Trigger } from './components/Trigger';\nimport { AlertDialogContext } from './Context';\n\nexport type AlertDialogProps = {\n children: React.ReactNode | React.ReactNode[];\n /**\n * Set whether the alert dialog is open by default or not, use when not providing a trigger\n * @default false\n */\n defaultOpen?: boolean;\n /** Called when the alert dialog opens or closes, must be used in conjunction with open */\n onChange?: (open: boolean) => void;\n /**\n * Control the open state of the dialog from outside the component\n * @default false\n */\n open?: boolean;\n /** A trigger to be used for the alert dialog, should not be set if `children` already contains a trigger */\n trigger?: JSX.Element;\n /**\n * A state to be used for the alert dialog, which will add appropriate badge icon next to the title\n * @default undefined\n */\n variant?: 'warning' | 'error' | 'information';\n};\n\nexport type ForwardedAlertDialogWithStatics = React.ForwardRefExoticComponent<\n AlertDialogProps & React.RefAttributes<HTMLElement>\n> & {\n Trigger: React.ForwardRefExoticComponent<AlertDialogTriggerProps & React.RefAttributes<HTMLButtonElement>>;\n Content: React.ForwardRefExoticComponent<AlertDialogContentProps & React.RefAttributes<HTMLDivElement>>;\n Title: React.ForwardRefExoticComponent<AlertDialogTitleProps & React.RefAttributes<HTMLHeadingElement>>;\n Description: React.ForwardRefExoticComponent<AlertDialogDescriptionProps & React.RefAttributes<HTMLParagraphElement>>;\n Footer: React.ForwardRefExoticComponent<AlertDialogFooterProps & React.RefAttributes<HTMLDivElement>>;\n Action: React.ForwardRefExoticComponent<AlertDialogActionProps & React.RefAttributes<HTMLButtonElement>>;\n Cancel: React.ForwardRefExoticComponent<AlertDialogCancelProps & React.RefAttributes<HTMLButtonElement>>;\n};\n\nexport const AlertDialog = React.forwardRef(function AlertDialog(props: AlertDialogProps, ref: React.Ref<HTMLElement>) {\n const { children, defaultOpen, onChange, open, trigger, ...otherProps } = props;\n\n const context = React.useMemo(\n () => ({\n props: otherProps,\n ref,\n }),\n [open, otherProps]\n );\n\n const handleOpenChange = (open: boolean, eventDetails: AlertDialogPrimitive.Root.ChangeEventDetails) => {\n if (eventDetails.reason === 'escape-key') {\n const triggeredFromRadixPortal = (eventDetails.event.target as HTMLElement)?.closest(\n 'div[data-radix-popper-content-wrapper]'\n );\n\n if (triggeredFromRadixPortal) {\n // TODO: This could be removed when all radix overlays are replaced with base UI components, but currently it propagates through and closes the dialog.\n\n // cancel closing the dialog\n eventDetails.cancel();\n // propagate to allow the radix overlay to close\n eventDetails.allowPropagation();\n return;\n }\n eventDetails.cancel();\n return;\n }\n\n onChange?.(open);\n };\n\n return (\n <AlertDialogContext.Provider value={context}>\n <AlertDialogPrimitive.Root {...otherProps} defaultOpen={defaultOpen} open={open} onOpenChange={handleOpenChange}>\n {trigger && <Trigger>{trigger}</Trigger>}\n {children}\n </AlertDialogPrimitive.Root>\n </AlertDialogContext.Provider>\n );\n}) as ForwardedAlertDialogWithStatics;\n\nAlertDialog.Trigger = Trigger;\nAlertDialog.Content = Content;\nAlertDialog.Description = Description;\nAlertDialog.Title = Title;\nAlertDialog.Cancel = Cancel;\nAlertDialog.Action = Action;\nAlertDialog.Footer = Footer;\n"],"names":["AlertDialog","open","AlertDialogPrimitive"],"mappings":";;;;;;AA8CO,MAAM,cAAc,MAAM,WAAW,SAASA,aAAY,OAAyB,KAA6B;AACnH,QAAM,EAAE,UAAU,aAAa,UAAU,MAAM,SAAS,GAAG,eAAe;AAE1E,QAAM,UAAU,MAAM;AAAA,IAClB,OAAO;AAAA,MACH,OAAO;AAAA,MACP;AAAA,IAAA;AAAA,IAEJ,CAAC,MAAM,UAAU;AAAA,EAAA;AAGrB,QAAM,mBAAmB,CAACC,OAAe,iBAA+D;AACpG,QAAI,aAAa,WAAW,cAAc;AACtC,YAAM,2BAA4B,aAAa,MAAM,QAAwB;AAAA,QACzE;AAAA,MAAA;AAGJ,UAAI,0BAA0B;AAI1B,qBAAa,OAAA;AAEb,qBAAa,iBAAA;AACb;AAAA,MACJ;AACA,mBAAa,OAAA;AACb;AAAA,IACJ;AAEA,eAAWA,KAAI;AAAA,EACnB;AAEA,SACI,sBAAA,cAAC,mBAAmB,UAAnB,EAA4B,OAAO,QAAA,GAChC,sBAAA,cAACC,cAAqB,MAArB,EAA2B,GAAG,YAAY,aAA0B,MAAY,cAAc,iBAAA,GAC1F,+CAAY,SAAA,MAAS,OAAQ,GAC7B,QACL,CACJ;AAER,CAAC;AAED,YAAY,UAAU;AACtB,YAAY,UAAU;AACtB,YAAY,cAAc;AAC1B,YAAY,QAAQ;AACpB,YAAY,SAAS;AACrB,YAAY,SAAS;AACrB,YAAY,SAAS;"}
|
|
1
|
+
{"version":3,"file":"AlertDialog.js","sources":["../../../src/components/AlertDialog/AlertDialog.tsx"],"sourcesContent":["import { AlertDialog as AlertDialogPrimitive } from '@base-ui/react/alert-dialog';\nimport * as React from 'react';\n\nimport type { AlertDialogContentProps, AlertDialogTitleProps, AlertDialogDescriptionProps } from './components/Content';\nimport { Description, Title, Content } from './components/Content';\nimport type { AlertDialogCancelProps, AlertDialogActionProps, AlertDialogFooterProps } from './components/Footer';\nimport { Cancel, Action, Footer } from './components/Footer';\nimport type { AlertDialogTriggerProps } from './components/Trigger';\nimport { Trigger } from './components/Trigger';\nimport { AlertDialogContext } from './Context';\n\nexport type AlertDialogProps = {\n children: React.ReactNode | React.ReactNode[];\n /**\n * Set whether the alert dialog is open by default or not, use when not providing a trigger\n * @default false\n */\n defaultOpen?: boolean;\n /** Called when the alert dialog opens or closes, must be used in conjunction with open */\n onChange?: (open: boolean) => void;\n /**\n * Control the open state of the dialog from outside the component\n * @default false\n */\n open?: boolean;\n /** A trigger to be used for the alert dialog, should not be set if `children` already contains a trigger */\n trigger?: React.JSX.Element;\n /**\n * A state to be used for the alert dialog, which will add appropriate badge icon next to the title\n * @default undefined\n */\n variant?: 'warning' | 'error' | 'information';\n};\n\nexport type ForwardedAlertDialogWithStatics = React.ForwardRefExoticComponent<\n AlertDialogProps & React.RefAttributes<HTMLElement>\n> & {\n Trigger: React.ForwardRefExoticComponent<AlertDialogTriggerProps & React.RefAttributes<HTMLButtonElement>>;\n Content: React.ForwardRefExoticComponent<AlertDialogContentProps & React.RefAttributes<HTMLDivElement>>;\n Title: React.ForwardRefExoticComponent<AlertDialogTitleProps & React.RefAttributes<HTMLHeadingElement>>;\n Description: React.ForwardRefExoticComponent<AlertDialogDescriptionProps & React.RefAttributes<HTMLParagraphElement>>;\n Footer: React.ForwardRefExoticComponent<AlertDialogFooterProps & React.RefAttributes<HTMLDivElement>>;\n Action: React.ForwardRefExoticComponent<AlertDialogActionProps & React.RefAttributes<HTMLButtonElement>>;\n Cancel: React.ForwardRefExoticComponent<AlertDialogCancelProps & React.RefAttributes<HTMLButtonElement>>;\n};\n\nexport const AlertDialog = React.forwardRef(function AlertDialog(props: AlertDialogProps, ref: React.Ref<HTMLElement>) {\n const { children, defaultOpen, onChange, open, trigger, ...otherProps } = props;\n\n const context = React.useMemo(\n () => ({\n props: otherProps,\n ref,\n }),\n [open, otherProps]\n );\n\n const handleOpenChange = (open: boolean, eventDetails: AlertDialogPrimitive.Root.ChangeEventDetails) => {\n if (eventDetails.reason === 'escape-key') {\n const triggeredFromRadixPortal = (eventDetails.event.target as HTMLElement)?.closest(\n 'div[data-radix-popper-content-wrapper]'\n );\n\n if (triggeredFromRadixPortal) {\n // TODO: This could be removed when all radix overlays are replaced with base UI components, but currently it propagates through and closes the dialog.\n\n // cancel closing the dialog\n eventDetails.cancel();\n // propagate to allow the radix overlay to close\n eventDetails.allowPropagation();\n return;\n }\n eventDetails.cancel();\n return;\n }\n\n onChange?.(open);\n };\n\n return (\n <AlertDialogContext.Provider value={context}>\n <AlertDialogPrimitive.Root {...otherProps} defaultOpen={defaultOpen} open={open} onOpenChange={handleOpenChange}>\n {trigger && <Trigger>{trigger}</Trigger>}\n {children}\n </AlertDialogPrimitive.Root>\n </AlertDialogContext.Provider>\n );\n}) as ForwardedAlertDialogWithStatics;\n\nAlertDialog.Trigger = Trigger;\nAlertDialog.Content = Content;\nAlertDialog.Description = Description;\nAlertDialog.Title = Title;\nAlertDialog.Cancel = Cancel;\nAlertDialog.Action = Action;\nAlertDialog.Footer = Footer;\n"],"names":["AlertDialog","open","AlertDialogPrimitive"],"mappings":";;;;;;AA8CO,MAAM,cAAc,MAAM,WAAW,SAASA,aAAY,OAAyB,KAA6B;AACnH,QAAM,EAAE,UAAU,aAAa,UAAU,MAAM,SAAS,GAAG,eAAe;AAE1E,QAAM,UAAU,MAAM;AAAA,IAClB,OAAO;AAAA,MACH,OAAO;AAAA,MACP;AAAA,IAAA;AAAA,IAEJ,CAAC,MAAM,UAAU;AAAA,EAAA;AAGrB,QAAM,mBAAmB,CAACC,OAAe,iBAA+D;AACpG,QAAI,aAAa,WAAW,cAAc;AACtC,YAAM,2BAA4B,aAAa,MAAM,QAAwB;AAAA,QACzE;AAAA,MAAA;AAGJ,UAAI,0BAA0B;AAI1B,qBAAa,OAAA;AAEb,qBAAa,iBAAA;AACb;AAAA,MACJ;AACA,mBAAa,OAAA;AACb;AAAA,IACJ;AAEA,eAAWA,KAAI;AAAA,EACnB;AAEA,SACI,sBAAA,cAAC,mBAAmB,UAAnB,EAA4B,OAAO,QAAA,GAChC,sBAAA,cAACC,cAAqB,MAArB,EAA2B,GAAG,YAAY,aAA0B,MAAY,cAAc,iBAAA,GAC1F,+CAAY,SAAA,MAAS,OAAQ,GAC7B,QACL,CACJ;AAER,CAAC;AAED,YAAY,UAAU;AACtB,YAAY,UAAU;AACtB,YAAY,cAAc;AAC1B,YAAY,QAAQ;AACpB,YAAY,SAAS;AACrB,YAAY,SAAS;AACrB,YAAY,SAAS;"}
|