ezux 1.1.13 → 1.1.18
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/README.md +58 -15
- package/dist/DeleteConfirmationModal-CukNDgtX.cjs +1 -0
- package/dist/DeleteConfirmationModal-p8XGDGIw.js +38 -0
- package/dist/EzContextMenu-BCUoEQp5.cjs +1 -0
- package/dist/EzContextMenu-srLxujt8.js +287 -0
- package/dist/EzErrorBoundary-C7a6VisX.js +74 -0
- package/dist/EzErrorBoundary-d_2g-_EK.cjs +1 -0
- package/dist/EzEventModal-C079wLjP.js +725 -0
- package/dist/EzEventModal-CAA9cAM0.cjs +1 -0
- package/dist/EzFlow-C74NbZA9.js +2545 -0
- package/dist/EzFlow-CQFeY7DL.cjs +5 -0
- package/dist/EzGroupingPanel-BVaAJaVU.js +107 -0
- package/dist/EzGroupingPanel-BwWDWEuW.cjs +1 -0
- package/dist/EzKanban-BlJWybKe.js +1575 -0
- package/dist/EzKanban-DdKODRRv.cjs +2 -0
- package/dist/EzLayout-BGnqFtvO.cjs +1 -0
- package/dist/EzLayout-CiaPLniV.js +7005 -0
- package/dist/EzProvider-AlmsYIDk.js +982 -0
- package/dist/EzProvider-L2qQMq-v.cjs +1 -0
- package/dist/EzScheduler-C1Jtvvju.js +2700 -0
- package/dist/EzScheduler-CkqTngI6.cjs +1 -0
- package/dist/EzSchedulerQuickAdd-BIC8xbSn.js +124 -0
- package/dist/EzSchedulerQuickAdd-BeNfGdWs.cjs +1 -0
- package/dist/EzSchedulerToolbar-BJwTpgas.cjs +1 -0
- package/dist/EzSchedulerToolbar-Ba4gbvUg.js +305 -0
- package/dist/EzSignature-7UHO5lSP.js +386 -0
- package/dist/EzSignature-Df7UZ-IS.cjs +1 -0
- package/dist/EzTable-CEXvJR1t.cjs +3 -0
- package/dist/EzTable-D2p1IWHc.js +4290 -0
- package/dist/EzTableEditDialog-BXnnYSSy.cjs +1 -0
- package/dist/EzTableEditDialog-Ccd5XoHm.js +84 -0
- package/dist/EzTableFooter-CtexeDAC.cjs +1 -0
- package/dist/EzTableFooter-DrLoWelo.js +35 -0
- package/dist/EzTableToolbar-BH5z9fSJ.js +160 -0
- package/dist/EzTableToolbar-DwuumvWP.cjs +1 -0
- package/dist/EzTreeView-D1G0Aomc.js +818 -0
- package/dist/EzTreeView-KMGlU4ax.cjs +1 -0
- package/dist/HighlightText-BViuwe03.cjs +1 -0
- package/dist/HighlightText-DNA2R2uf.js +56 -0
- package/dist/KanbanBoard-B7_Z5sh1.js +1697 -0
- package/dist/KanbanBoard-CyitudI1.cjs +1 -0
- package/dist/Modal-BmX1C448.cjs +1 -0
- package/dist/Modal-CrzpKyjK.js +74 -0
- package/dist/NotificationPanel-BzpDc10Q.js +54 -0
- package/dist/NotificationPanel-CFME00wq.cjs +1 -0
- package/dist/TooltipWrapper-BSAmUx9H.js +44 -0
- package/dist/TooltipWrapper-DfbFAZ1U.cjs +1 -0
- package/dist/advanced.cjs +10 -0
- package/dist/advanced.d.ts +44 -0
- package/dist/advanced.es.js +400 -0
- package/dist/avatar-BSdRHETK.cjs +1 -0
- package/dist/avatar-BvCUJ-_r.js +27 -0
- package/dist/button-BBMwzUtG.cjs +1 -0
- package/dist/button-CYyNwV8S.js +44 -0
- package/dist/calendar-DEHX32Cp.cjs +1 -0
- package/dist/calendar-DOIPGsyI.js +112 -0
- package/dist/card-CPlRZxbq.cjs +1 -0
- package/dist/card-ZUNxcdIM.js +60 -0
- package/dist/checkbox-BrCh_Iid.cjs +1 -0
- package/dist/checkbox-DRkQuB4W.js +21 -0
- package/dist/components/EzFlow/EzConnectionLine.d.ts +5 -0
- package/dist/components/EzFlow/EzFlow.examples.d.ts +5 -0
- package/dist/components/EzFlow/EzFlow.types.d.ts +260 -0
- package/dist/components/EzFlow/EzFlowBackground.d.ts +5 -0
- package/dist/components/EzFlow/EzFlowCanvas.d.ts +3 -0
- package/dist/components/EzFlow/EzFlowControls.d.ts +5 -0
- package/dist/components/EzFlow/EzFlowEdge.d.ts +5 -0
- package/dist/components/EzFlow/EzFlowHeader.d.ts +6 -0
- package/dist/components/EzFlow/EzFlowToolbox.d.ts +6 -0
- package/dist/components/EzFlow/EzWorkflow.d.ts +5 -0
- package/dist/components/EzFlow/EzWorkflowPerformance.d.ts +3 -0
- package/dist/components/EzFlow/EzWorkflowServiceAdapters.d.ts +24 -0
- package/dist/components/EzFlow/EzWorkflowValidation.d.ts +95 -0
- package/dist/components/EzFlow/index.d.ts +13 -0
- package/dist/components/EzFlow/nodes/ActionNode.d.ts +3 -0
- package/dist/components/EzFlow/nodes/ApprovalNode.d.ts +3 -0
- package/dist/components/EzFlow/nodes/DecisionNode.d.ts +3 -0
- package/dist/components/EzFlow/nodes/DelayNode.d.ts +3 -0
- package/dist/components/EzFlow/nodes/EndNode.d.ts +3 -0
- package/dist/components/EzFlow/nodes/GroupNode.d.ts +3 -0
- package/dist/components/EzFlow/nodes/LoopNode.d.ts +3 -0
- package/dist/components/EzFlow/nodes/RequestNode.d.ts +3 -0
- package/dist/components/EzFlow/nodes/StartNode.d.ts +3 -0
- package/dist/components/EzFlow/nodes/index.d.ts +9 -0
- package/dist/components/EzKanban/EzKanban.types.d.ts +808 -0
- package/dist/components/EzKanban/components/CardEditorModal.d.ts +23 -0
- package/dist/components/EzKanban/components/EzKanbanErrorFallback.d.ts +1 -0
- package/dist/components/EzKanban/components/FilterPopover.d.ts +10 -0
- package/dist/components/EzKanban/components/KanbanBoard.d.ts +59 -0
- package/dist/components/EzKanban/components/KanbanCard.d.ts +46 -0
- package/dist/components/EzKanban/components/KanbanColumn.d.ts +55 -0
- package/dist/components/EzKanban/components/KanbanSwimlane.d.ts +45 -0
- package/dist/components/EzKanban/components/KanbanToolbar.d.ts +41 -0
- package/dist/components/EzKanban/exports.d.ts +4 -0
- package/dist/components/EzKanban/hooks/useKanbanCards.d.ts +36 -0
- package/dist/components/EzKanban/hooks/useKanbanColumns.d.ts +27 -0
- package/dist/components/EzKanban/hooks/useKanbanDragDrop.d.ts +31 -0
- package/dist/components/EzKanban/hooks/useKanbanFilters.d.ts +23 -0
- package/dist/components/EzKanban/hooks/useKanbanState.d.ts +79 -0
- package/dist/components/EzKanban/hooks/useKanbanSwimlanes.d.ts +27 -0
- package/dist/components/EzKanban/hooks/useKanbanVirtualization.d.ts +16 -0
- package/dist/components/EzKanban/index.d.ts +51 -0
- package/dist/components/EzKanban/services/KanbanService.d.ts +31 -0
- package/dist/components/EzKanban/state/kanban.store.d.ts +33 -0
- package/dist/components/EzKanban/useEzKanban.d.ts +87 -0
- package/dist/components/EzKanban/views/KanbanTimelineView.d.ts +15 -0
- package/dist/components/EzLayout/Authentication/AuthSlider.d.ts +13 -0
- package/dist/components/EzLayout/Authentication/InputPassword.d.ts +7 -0
- package/dist/components/EzLayout/Authentication/SignInForm.d.ts +21 -0
- package/dist/components/EzLayout/Authentication/SignUpForm.d.ts +20 -0
- package/dist/components/EzLayout/EzHeader.d.ts +48 -0
- package/dist/components/EzLayout/EzLanguageSwitcher.d.ts +4 -0
- package/dist/components/EzLayout/EzLayout.types.d.ts +261 -0
- package/dist/components/EzLayout/EzOrganizationSwitcher.d.ts +14 -0
- package/dist/components/EzLayout/EzSidebar.d.ts +24 -0
- package/dist/components/EzLayout/EzThemeColorChanger.d.ts +9 -0
- package/dist/components/EzLayout/EzThemeSwitcher.d.ts +8 -0
- package/dist/components/EzLayout/EzUserProfile.d.ts +27 -0
- package/dist/components/EzLayout/components/EzSidebarFooter.d.ts +8 -0
- package/dist/components/EzLayout/components/EzSidebarNav.d.ts +10 -0
- package/dist/components/EzLayout/components/EzSidebarNavItem.d.ts +11 -0
- package/dist/components/EzLayout/components/MainContent.d.ts +13 -0
- package/dist/components/EzLayout/hooks/useLayoutImperative.d.ts +17 -0
- package/dist/components/EzLayout/hooks/useLayoutState.d.ts +25 -0
- package/dist/components/EzLayout/index.d.ts +23 -0
- package/dist/components/EzLayout/useEzLayout.d.ts +34 -0
- package/dist/components/EzScheduler/EzScheduler.types.d.ts +1252 -0
- package/dist/components/EzScheduler/EzSchedulerToolbar.d.ts +117 -0
- package/dist/components/EzScheduler/components/EzEventModal.d.ts +23 -0
- package/dist/components/EzScheduler/components/EzOverlapAlert.d.ts +12 -0
- package/dist/components/EzScheduler/components/EzQuickInfoPopup.d.ts +22 -0
- package/dist/components/EzScheduler/components/EzResourceSidebar.d.ts +33 -0
- package/dist/components/EzScheduler/components/EzSchedulerContent.d.ts +111 -0
- package/dist/components/EzScheduler/components/EzSchedulerQuickAdd.d.ts +17 -0
- package/dist/components/EzScheduler/components/RecurrenceEditor.d.ts +7 -0
- package/dist/components/EzScheduler/components/SchedulerLoadingSpinner.d.ts +2 -0
- package/dist/components/EzScheduler/components/dnd/DraggableEvent.d.ts +24 -0
- package/dist/components/EzScheduler/components/dnd/DroppableSlot.d.ts +19 -0
- package/dist/components/EzScheduler/hooks/useRecurrence.d.ts +2 -0
- package/dist/components/EzScheduler/hooks/useSchedulerEventHandlers.d.ts +15 -0
- package/dist/components/EzScheduler/hooks/useSchedulerEvents.d.ts +27 -0
- package/dist/components/EzScheduler/hooks/useSchedulerImperative.d.ts +19 -0
- package/dist/components/EzScheduler/hooks/useSchedulerNavigation.d.ts +9 -0
- package/dist/components/EzScheduler/hooks/useSchedulerResources.d.ts +10 -0
- package/dist/components/EzScheduler/hooks/useSchedulerState.d.ts +14 -0
- package/dist/components/EzScheduler/hooks/useSchedulerVirtualization.d.ts +9 -0
- package/dist/components/EzScheduler/index.d.ts +43 -0
- package/dist/components/EzScheduler/models/EventSettings.d.ts +11 -0
- package/dist/components/EzScheduler/models/View.d.ts +49 -0
- package/dist/components/EzScheduler/models/index.d.ts +2 -0
- package/dist/components/EzScheduler/services/AttendeeService.d.ts +15 -0
- package/dist/components/EzScheduler/services/AuditService.d.ts +15 -0
- package/dist/components/EzScheduler/services/CollisionDetectionService.d.ts +19 -0
- package/dist/components/EzScheduler/services/DragAndDropService.d.ts +16 -0
- package/dist/components/EzScheduler/services/HistoryService.d.ts +31 -0
- package/dist/components/EzScheduler/services/ICalendarImportService.d.ts +16 -0
- package/dist/components/EzScheduler/services/PrintService.d.ts +7 -0
- package/dist/components/EzScheduler/services/RecurrenceEngine.d.ts +7 -0
- package/dist/components/EzScheduler/services/ReminderService.d.ts +17 -0
- package/dist/components/EzScheduler/services/SchedulerService.d.ts +71 -0
- package/dist/components/EzScheduler/services/SearchService.d.ts +11 -0
- package/dist/components/EzScheduler/services/SecurityService.d.ts +25 -0
- package/dist/components/EzScheduler/services/TimezoneService.d.ts +20 -0
- package/dist/components/EzScheduler/services/VirtualScrollingService.d.ts +34 -0
- package/dist/components/EzScheduler/state/scheduler.store.d.ts +27 -0
- package/dist/components/EzScheduler/templates/CellTemplate.d.ts +42 -0
- package/dist/components/EzScheduler/templates/EditorTemplate.d.ts +32 -0
- package/dist/components/EzScheduler/templates/HeaderTemplate.d.ts +36 -0
- package/dist/components/EzScheduler/useEzScheduler.d.ts +104 -0
- package/dist/components/EzScheduler/utils/createDragConstraint.d.ts +7 -0
- package/dist/components/EzScheduler/utils/getWeekNumber.d.ts +8 -0
- package/dist/components/EzScheduler/utils/sanitizeHtml.d.ts +18 -0
- package/dist/components/EzScheduler/views/AgendaView.d.ts +28 -0
- package/dist/components/EzScheduler/views/DayWeekView.d.ts +177 -0
- package/dist/components/EzScheduler/views/MonthView.d.ts +60 -0
- package/dist/components/EzScheduler/views/TimelineView.d.ts +116 -0
- package/dist/components/EzSignature/EzSignature.d.ts +42 -0
- package/dist/components/EzSignature/EzSignature.types.d.ts +132 -0
- package/dist/components/EzSignature/index.d.ts +2 -0
- package/dist/components/EzTable/EzColumnMenu.d.ts +7 -0
- package/dist/components/EzTable/EzDateFilterTree.d.ts +7 -0
- package/dist/components/EzTable/EzExcelFilter.d.ts +8 -0
- package/dist/components/EzTable/EzFilterBuilder.d.ts +12 -0
- package/dist/components/EzTable/EzGroupingPanel.d.ts +9 -0
- package/dist/components/EzTable/EzHeaderContextMenu.d.ts +8 -0
- package/dist/components/EzTable/EzPagination.d.ts +19 -0
- package/dist/components/EzTable/EzTable.types.d.ts +1 -0
- package/dist/components/EzTable/EzTableEditDialog.d.ts +15 -0
- package/dist/components/EzTable/EzTableFooter.d.ts +10 -0
- package/dist/components/EzTable/EzTableOverlays.d.ts +11 -0
- package/dist/components/EzTable/EzTableStatusBar.d.ts +10 -0
- package/dist/components/EzTable/EzTableToolbar.d.ts +60 -0
- package/dist/components/EzTable/SmartCell.d.ts +7 -0
- package/dist/components/EzTable/components/AdvancedColumnFilter.d.ts +16 -0
- package/dist/components/EzTable/components/BooleanFilterSection.d.ts +7 -0
- package/dist/components/EzTable/components/EzDraggableHeader.d.ts +10 -0
- package/dist/components/EzTable/components/EzHeaderDragPreview.d.ts +7 -0
- package/dist/components/EzTable/components/EzTableBodySection.d.ts +72 -0
- package/dist/components/EzTable/components/EzTableCell.d.ts +46 -0
- package/dist/components/EzTable/components/EzTableHeaderSection.d.ts +23 -0
- package/dist/components/EzTable/components/EzTablePaginationSection.d.ts +31 -0
- package/dist/components/EzTable/components/EzTableRow.d.ts +58 -0
- package/dist/components/EzTable/components/FilterActionButtons.d.ts +16 -0
- package/dist/components/EzTable/components/FilterRuleSelect.d.ts +26 -0
- package/dist/components/EzTable/components/SelectAllCheckbox.d.ts +21 -0
- package/dist/components/EzTable/components/SelectFilterSection.d.ts +18 -0
- package/dist/components/EzTable/components/VirtualizedFilterList.d.ts +21 -0
- package/dist/components/EzTable/constants/filterOptions.d.ts +47 -0
- package/dist/components/EzTable/context/EzTableContext.d.ts +10 -0
- package/dist/components/EzTable/context/TableConfigContext.d.ts +13 -0
- package/dist/components/EzTable/context/TableStore.d.ts +17 -0
- package/dist/components/EzTable/filterUtils.d.ts +5 -0
- package/dist/components/EzTable/hooks/useAutoFit.d.ts +4 -0
- package/dist/components/EzTable/hooks/useCellEventHandlers.d.ts +16 -0
- package/dist/components/EzTable/hooks/useColumnSizeVars.d.ts +6 -0
- package/dist/components/EzTable/hooks/useContainerResize.d.ts +11 -0
- package/dist/components/EzTable/hooks/useDialogStateInitialization.d.ts +8 -0
- package/dist/components/EzTable/hooks/useFilterSelection.d.ts +12 -0
- package/dist/components/EzTable/hooks/useTableFiltering.d.ts +23 -0
- package/dist/components/EzTable/hooks/useTableHistory.d.ts +87 -0
- package/dist/components/EzTable/hooks/useTableImperative.d.ts +42 -0
- package/dist/components/EzTable/hooks/useTableSelection.d.ts +32 -0
- package/dist/components/EzTable/hooks/useTableState.d.ts +33 -0
- package/dist/components/EzTable/hooks/useTableVirtualization.d.ts +35 -0
- package/dist/components/EzTable/index.d.ts +54 -0
- package/dist/components/EzTable/renderers/index.d.ts +6 -0
- package/dist/components/EzTable/services/TableService.d.ts +29 -0
- package/dist/components/EzTable/types/EzTableColumn.types.d.ts +146 -0
- package/dist/components/EzTable/types/EzTableEdit.types.d.ts +58 -0
- package/dist/components/EzTable/types/EzTableFilter.types.d.ts +50 -0
- package/dist/components/EzTable/types/EzTableProps.d.ts +750 -0
- package/dist/components/EzTable/types/index.d.ts +4 -0
- package/dist/components/EzTable/useEzTable.d.ts +17 -0
- package/dist/components/EzTable/utils/SizingUtils.d.ts +11 -0
- package/dist/components/EzTable/utils/TextMeasurer.d.ts +1 -0
- package/dist/components/EzTable/utils/TruncatedTooltip.d.ts +7 -0
- package/dist/components/EzTable/utils/columnTypeDetector.d.ts +5 -0
- package/dist/components/EzTable/utils/filterTypeGuards.d.ts +3 -0
- package/dist/components/EzTable/utils/index.d.ts +1 -0
- package/dist/components/EzTreeView/EzTreeView.types.d.ts +364 -0
- package/dist/components/EzTreeView/EzTreeViewItem.d.ts +89 -0
- package/dist/components/EzTreeView/EzVirtualTree.d.ts +84 -0
- package/dist/components/EzTreeView/components/EzTreeViewLoadingSpinner.d.ts +2 -0
- package/dist/components/EzTreeView/hooks/useTreeDragDrop.d.ts +31 -0
- package/dist/components/EzTreeView/hooks/useTreeExpansion.d.ts +21 -0
- package/dist/components/EzTreeView/hooks/useTreeImperative.d.ts +28 -0
- package/dist/components/EzTreeView/hooks/useTreeSelection.d.ts +31 -0
- package/dist/components/EzTreeView/hooks/useTreeState.d.ts +21 -0
- package/dist/components/EzTreeView/hooks/useTreeVirtualization.d.ts +18 -0
- package/dist/components/EzTreeView/index.d.ts +40 -0
- package/dist/components/EzTreeView/services/TreeService.d.ts +11 -0
- package/dist/components/EzTreeView/useEzTreeView.d.ts +50 -0
- package/dist/components/EzTreeView/utils/treeUtils.d.ts +17 -0
- package/dist/components/shared/components/EzErrorBoundary.d.ts +18 -0
- package/dist/components/shared/components/EzLayoutErrorFallback.d.ts +2 -0
- package/dist/components/shared/components/EzLoadingSpinner.d.ts +8 -0
- package/dist/components/shared/components/EzSchedulerErrorFallback.d.ts +2 -0
- package/dist/components/shared/components/EzSortableList.d.ts +12 -0
- package/dist/components/shared/components/EzTableErrorFallback.d.ts +2 -0
- package/dist/components/shared/components/EzTreeViewErrorFallback.d.ts +2 -0
- package/dist/components/ui/avatar.d.ts +10 -0
- package/dist/components/ui/badge.d.ts +9 -0
- package/dist/components/ui/breadcrumb.d.ts +19 -0
- package/dist/components/ui/button.d.ts +13 -0
- package/dist/components/ui/calendar.d.ts +15 -0
- package/dist/components/ui/card.d.ts +10 -0
- package/dist/components/ui/checkbox.d.ts +7 -0
- package/dist/components/ui/combobox.d.ts +19 -0
- package/dist/components/ui/command.d.ts +78 -0
- package/dist/components/ui/context-menu.d.ts +27 -0
- package/dist/components/ui/date-time-picker.d.ts +14 -0
- package/dist/components/ui/dropdown-menu.d.ts +31 -0
- package/dist/components/ui/index.d.ts +27 -0
- package/dist/components/ui/input.d.ts +5 -0
- package/dist/components/ui/label.d.ts +9 -0
- package/dist/components/ui/modal.d.ts +9 -0
- package/dist/components/ui/password-input.d.ts +5 -0
- package/dist/components/ui/popover.d.ts +10 -0
- package/dist/components/ui/progress.d.ts +7 -0
- package/dist/components/ui/radio-group.d.ts +5 -0
- package/dist/components/ui/resizable.d.ts +8 -0
- package/dist/components/ui/scroll-area.d.ts +5 -0
- package/dist/components/ui/select.d.ts +26 -0
- package/dist/components/ui/skeleton.d.ts +2 -0
- package/dist/components/ui/switch.d.ts +6 -0
- package/dist/components/ui/table.d.ts +10 -0
- package/dist/components/ui/tabs.d.ts +22 -0
- package/dist/components/ui/textarea.d.ts +5 -0
- package/dist/components/ui/tooltip.d.ts +10 -0
- package/dist/date-time-picker-Bs-7XzHD.cjs +1 -0
- package/dist/date-time-picker-fUzf4TnU.js +127 -0
- package/dist/dropdown-menu-BRP0tyR_.cjs +1 -0
- package/dist/dropdown-menu-B_7_K13o.js +78 -0
- package/dist/ezux.css +2 -1
- package/dist/flow.cjs +1 -0
- package/dist/flow.d.ts +2 -0
- package/dist/flow.es.js +2 -0
- package/dist/index.cjs +3 -12
- package/dist/index.d.ts +66 -6404
- package/dist/index.es.js +229 -1041
- package/dist/input-CYlvlbF7.cjs +1 -0
- package/dist/input-Cj3sQK3M.js +14 -0
- package/dist/kanban.cjs +1 -1
- package/dist/kanban.d.ts +2 -1343
- package/dist/kanban.es.js +4 -17
- package/dist/label-BGgvoZWD.cjs +1 -0
- package/dist/label-DWEV--5W.js +16 -0
- package/dist/layout.cjs +1 -1
- package/dist/layout.d.ts +2 -690
- package/dist/layout.es.js +2 -20
- package/dist/lib/perfect-freehand.d.ts +221 -0
- package/dist/lib/utils.d.ts +2 -0
- package/dist/mock-services.cjs +1 -0
- package/dist/mock-services.d.ts +8 -0
- package/dist/mock-services.es.js +161 -0
- package/dist/popover-D1akYj0W.js +17 -0
- package/dist/popover-wZKNvYM5.cjs +1 -0
- package/dist/scheduler.cjs +1 -1
- package/dist/scheduler.d.ts +2 -1430
- package/dist/scheduler.es.js +2 -11
- package/dist/scroll-area-BJs87d45.js +35 -0
- package/dist/scroll-area-DSkE2KB_.cjs +1 -0
- package/dist/select-D4tFaSai.js +43 -0
- package/dist/select-sVieKbLu.cjs +1 -0
- package/dist/shared/components/AnimatedText.d.ts +44 -0
- package/dist/shared/components/BaseCell.d.ts +14 -0
- package/dist/shared/components/BooleanRenderer.d.ts +34 -0
- package/dist/shared/components/ChartRenderer.d.ts +19 -0
- package/dist/shared/components/DeleteConfirmationModal.d.ts +11 -0
- package/dist/shared/components/EzContextMenu.d.ts +12 -0
- package/dist/shared/components/EzNotificationDropdown.d.ts +2 -0
- package/dist/shared/components/HighlightText.d.ts +4 -0
- package/dist/shared/components/Modal.d.ts +13 -0
- package/dist/shared/components/NotificationPanel.d.ts +2 -0
- package/dist/shared/components/PrimitiveRenderer.d.ts +39 -0
- package/dist/shared/components/SearchableSelect.d.ts +13 -0
- package/dist/shared/components/SelectRenderer.d.ts +33 -0
- package/dist/shared/components/StatusBadge.d.ts +21 -0
- package/dist/shared/components/TooltipWrapper.d.ts +12 -0
- package/dist/shared/components/index.d.ts +9 -0
- package/dist/shared/contexts/EzProvider.d.ts +56 -0
- package/dist/shared/hooks/index.d.ts +56 -0
- package/dist/shared/hooks/useBaseComponent.d.ts +59 -0
- package/dist/shared/hooks/useComponentImperativeAPI.d.ts +11 -0
- package/dist/shared/hooks/useComponentState.d.ts +39 -0
- package/dist/shared/hooks/useCurrentTime.d.ts +6 -0
- package/dist/shared/hooks/useDataChangeEvents.d.ts +53 -0
- package/dist/shared/hooks/useDebounce.d.ts +10 -0
- package/dist/shared/hooks/useDeleteConfirmation.d.ts +9 -0
- package/dist/shared/hooks/useDialogState.d.ts +21 -0
- package/dist/shared/hooks/useDndHandlers.d.ts +19 -0
- package/dist/shared/hooks/useEditing.d.ts +107 -0
- package/dist/shared/hooks/useEventHandlers.d.ts +61 -0
- package/dist/shared/hooks/useEzTheme.d.ts +22 -0
- package/dist/shared/hooks/useFieldValidation.d.ts +24 -0
- package/dist/shared/hooks/useHistory.d.ts +13 -0
- package/dist/shared/hooks/useI18n.d.ts +8 -0
- package/dist/shared/hooks/useImperativeAPI.d.ts +8 -0
- package/dist/shared/hooks/useInitCoreServices.d.ts +5 -0
- package/dist/shared/hooks/useKeyboardNavigation.d.ts +36 -0
- package/dist/shared/hooks/useKeyboardShortcuts.d.ts +14 -0
- package/dist/shared/hooks/useLifecycleEvents.d.ts +22 -0
- package/dist/shared/hooks/useLoadingState.d.ts +17 -0
- package/dist/shared/hooks/useMediaQuery.d.ts +6 -0
- package/dist/shared/hooks/useNotificationService.d.ts +8 -0
- package/dist/shared/hooks/usePerformanceMonitor.d.ts +22 -0
- package/dist/shared/hooks/useRowSelectionEvents.d.ts +44 -0
- package/dist/shared/hooks/useSelection.d.ts +73 -0
- package/dist/shared/hooks/useService.d.ts +12 -0
- package/dist/shared/hooks/useServiceState.d.ts +1 -0
- package/dist/shared/hooks/useStateChangeEvents.d.ts +61 -0
- package/dist/shared/hooks/useTheme.d.ts +13 -0
- package/dist/shared/hooks/useVirtualization.d.ts +85 -0
- package/dist/shared/services/BaseService.d.ts +57 -0
- package/dist/shared/services/ContextMenuService.d.ts +58 -0
- package/dist/shared/services/ExportService.d.ts +35 -0
- package/dist/shared/services/FocusManagerService.d.ts +33 -0
- package/dist/shared/services/HierarchyService.d.ts +43 -0
- package/dist/shared/services/I18nService.d.ts +84 -0
- package/dist/shared/services/LayoutService.d.ts +80 -0
- package/dist/shared/services/NotificationService.d.ts +44 -0
- package/dist/shared/services/PersistenceService.d.ts +69 -0
- package/dist/shared/services/ServiceRegistry.d.ts +52 -0
- package/dist/shared/services/ThemeService.d.ts +49 -0
- package/dist/shared/services/VirtualizationService.d.ts +51 -0
- package/dist/shared/state/store.d.ts +10 -0
- package/dist/shared/themes.d.ts +25 -0
- package/dist/shared/types/BaseProps.d.ts +17 -0
- package/dist/shared/types/common.d.ts +373 -0
- package/dist/shared/types/index.d.ts +2 -0
- package/dist/shared/utils/canvasUtils.d.ts +16 -0
- package/dist/shared/utils/commonUtils.d.ts +28 -0
- package/dist/shared/utils/csvUtils.d.ts +7 -0
- package/dist/shared/utils/dateUtils.d.ts +5 -0
- package/dist/shared/utils/dndUtils.d.ts +16 -0
- package/dist/shared/utils/formatUtils.d.ts +20 -0
- package/dist/shared/utils/imperativeApiUtils.d.ts +36 -0
- package/dist/shared/utils/index.d.ts +11 -0
- package/dist/shared/utils/renderUtils.d.ts +6 -0
- package/dist/shared/utils/serviceUtils.d.ts +10 -0
- package/dist/shared/utils/styleUtils.d.ts +121 -0
- package/dist/shared/utils/validationUtils.d.ts +16 -0
- package/dist/signature.cjs +1 -1
- package/dist/signature.d.ts +2 -410
- package/dist/signature.es.js +2 -4
- package/dist/table.cjs +1 -1
- package/dist/table.d.ts +2 -1059
- package/dist/table.es.js +2 -17
- package/dist/theme-vars.css +143 -135
- package/dist/tooltip-B1wC9m05.js +16 -0
- package/dist/tooltip-Qmzrg5u5.cjs +1 -0
- package/dist/treeview.cjs +1 -1
- package/dist/treeview.d.ts +2 -656
- package/dist/treeview.es.js +2 -954
- package/dist/useComponentState-DiSFLYju.js +57 -0
- package/dist/useComponentState-Wcz6pjd6.cjs +1 -0
- package/dist/useImperativeAPI-Dbx2hMTb.js +7 -0
- package/dist/useImperativeAPI-VrgLwXEO.cjs +1 -0
- package/dist/useInitCoreServices-CuBrviDM.js +40 -0
- package/dist/useInitCoreServices-DlALVDNx.cjs +1 -0
- package/dist/useService-CnCBGG3G.js +10 -0
- package/dist/useService-CyF782jv.cjs +1 -0
- package/dist/useServiceState-CkrJZm1D.js +21 -0
- package/dist/useServiceState-PyYQWxHi.cjs +1 -0
- package/package.json +76 -56
- package/dist/EzContextMenu-B6HBUjWv.cjs +0 -5
- package/dist/EzContextMenu-BSA_B6Pr.js +0 -3500
- package/dist/EzErrorBoundary-CEdz_hDo.cjs +0 -41
- package/dist/EzErrorBoundary-D4NBadES.js +0 -3727
- package/dist/EzEventModal-BUMp_BFi.js +0 -689
- package/dist/EzEventModal-xzHfzi0O.cjs +0 -1
- package/dist/EzGroupingPanel-BUsIYDRi.js +0 -143
- package/dist/EzGroupingPanel-D0HdSomF.cjs +0 -1
- package/dist/EzSchedulerQuickAdd-C653LTGh.js +0 -118
- package/dist/EzSchedulerQuickAdd-UnOWCpJd.cjs +0 -1
- package/dist/EzSchedulerToolbar-C-5OdRY6.cjs +0 -1
- package/dist/EzSchedulerToolbar-CO5jjDQg.js +0 -240
- package/dist/EzSignature-BaNesxwC.cjs +0 -1
- package/dist/EzSignature-D4EYwo9W.js +0 -419
- package/dist/EzTableEditDialog-Cd948V1C.js +0 -63
- package/dist/EzTableEditDialog-NiOubaMT.cjs +0 -1
- package/dist/EzTableFooter-CWjfGCjL.cjs +0 -1
- package/dist/EzTableFooter-DveD12RC.js +0 -54
- package/dist/EzTableToolbar-Bz8UWv6j.js +0 -246
- package/dist/EzTableToolbar-DHE7Bb1R.cjs +0 -1
- package/dist/HighlightText-8D6KEyBw.js +0 -68
- package/dist/HighlightText-LtZmzCle.cjs +0 -1
- package/dist/NotificationPanel-D2Y-_ahk.js +0 -68
- package/dist/NotificationPanel-zLxrtTGf.cjs +0 -1
- package/dist/TooltipWrapper-BrRTi5EJ.js +0 -2021
- package/dist/TooltipWrapper-DWts4bAI.cjs +0 -1
- package/dist/avatar-BeK0E4mn.js +0 -41
- package/dist/avatar-DZAaTK2f.cjs +0 -1
- package/dist/bell-DAz8P0BR.js +0 -14
- package/dist/bell-DOX2y38e.cjs +0 -1
- package/dist/calendar-BMZ8ddOf.cjs +0 -1
- package/dist/calendar-Dy3rVMW2.js +0 -90
- package/dist/checkbox-B0lGHUyy.cjs +0 -1
- package/dist/checkbox-boJRxICT.js +0 -46
- package/dist/chevron-down-C3s8jU6B.js +0 -5
- package/dist/chevron-down-DZVL7VHW.cjs +0 -1
- package/dist/chevron-left-BFr8XZyF.js +0 -5
- package/dist/chevron-left-HWhRo6IH.cjs +0 -1
- package/dist/circle-alert-77QqFR-z.cjs +0 -1
- package/dist/circle-alert-B2AMDd8N.js +0 -9
- package/dist/circle-x-Cv7bfIC_.js +0 -9
- package/dist/circle-x-DwVXxhXr.cjs +0 -1
- package/dist/date-time-picker-DTxHdPgQ.cjs +0 -1
- package/dist/date-time-picker-Dj2eftJI.js +0 -1636
- package/dist/download-0ZhO2XaW.cjs +0 -1
- package/dist/download-panVHmk6.js +0 -9
- package/dist/ellipsis-CuqNthAj.js +0 -9
- package/dist/ellipsis-CzlqJf-i.cjs +0 -1
- package/dist/grip-vertical-CSyDKBul.js +0 -12
- package/dist/grip-vertical-DZNBW1Dn.cjs +0 -1
- package/dist/index-B3ipEEhH.cjs +0 -2
- package/dist/index-BPPb7bcs.js +0 -3220
- package/dist/index-BQKw_Vho.js +0 -9604
- package/dist/index-C5STgBSy.js +0 -5203
- package/dist/index-C6NfgycP.js +0 -4644
- package/dist/index-D4f2ZdrG.cjs +0 -2
- package/dist/index-DUY1SqMo.cjs +0 -1
- package/dist/index-c1Zg--dt.cjs +0 -7
- package/dist/input-BgM_la4k.cjs +0 -1
- package/dist/input-jYQ5VKNR.js +0 -21
- package/dist/isBefore-C3Y_wbk3.js +0 -15
- package/dist/isBefore-Cp1ttk6q.cjs +0 -1
- package/dist/label-ClOW9UCt.js +0 -55
- package/dist/label-Dx6oDB-X.cjs +0 -1
- package/dist/layers-BA4i1fYX.js +0 -27
- package/dist/layers-xSPd-hz3.cjs +0 -1
- package/dist/popover-BJq1CKmi.cjs +0 -1
- package/dist/popover-Cmlb7w3R.js +0 -341
- package/dist/scroll-area-9fwpVNxT.js +0 -573
- package/dist/scroll-area-CwwZSSA4.cjs +0 -1
- package/dist/select-GxA46anr.cjs +0 -1
- package/dist/select-mDCun_IR.js +0 -35
- package/dist/settings-CvyjK75A.js +0 -31
- package/dist/settings-DKPknrt8.cjs +0 -1
- package/dist/sortable.esm-CsRPuXyD.cjs +0 -1
- package/dist/sortable.esm-CzMCDPet.js +0 -477
- package/dist/tooltip-B41iztKT.cjs +0 -1
- package/dist/tooltip-BCtrEe0z.js +0 -490
- package/dist/useComponentState-C87xXa5d.js +0 -64
- package/dist/useComponentState-DDgGbBXv.cjs +0 -1
- package/dist/useImperativeAPI-DXmCQvPL.js +0 -7
- package/dist/useImperativeAPI-DbZ3owSV.cjs +0 -1
- package/dist/useInitCoreServices-CwXv2p4S.cjs +0 -1
- package/dist/useInitCoreServices-D1WaWlaI.js +0 -3929
- package/dist/useService-8OoezWr8.cjs +0 -1
- package/dist/useService-BUi3uAqE.js +0 -10
- package/dist/useServiceState-BjpCjUn2.cjs +0 -1
- package/dist/useServiceState-VE-viK8b.js +0 -24
|
@@ -0,0 +1,386 @@
|
|
|
1
|
+
import { _ as e, n as t } from "./EzProvider-AlmsYIDk.js";
|
|
2
|
+
import { n, t as r } from "./useInitCoreServices-CuBrviDM.js";
|
|
3
|
+
import { t as i } from "./useImperativeAPI-Dbx2hMTb.js";
|
|
4
|
+
import { t as a } from "./useServiceState-CkrJZm1D.js";
|
|
5
|
+
import o, { useCallback as s, useMemo as c, useRef as l, useState as u } from "react";
|
|
6
|
+
import { jsx as d, jsxs as f } from "react/jsx-runtime";
|
|
7
|
+
//#region src/lib/perfect-freehand.ts
|
|
8
|
+
function p(e) {
|
|
9
|
+
return [-e[0], -e[1]];
|
|
10
|
+
}
|
|
11
|
+
function m(e, t) {
|
|
12
|
+
return [e[0] + t[0], e[1] + t[1]];
|
|
13
|
+
}
|
|
14
|
+
function h(e, t) {
|
|
15
|
+
return [e[0] - t[0], e[1] - t[1]];
|
|
16
|
+
}
|
|
17
|
+
function g(e, t) {
|
|
18
|
+
return [e[0] * t, e[1] * t];
|
|
19
|
+
}
|
|
20
|
+
function _(e, t) {
|
|
21
|
+
return [e[0] / t, e[1] / t];
|
|
22
|
+
}
|
|
23
|
+
function v(e) {
|
|
24
|
+
return [e[1], -e[0]];
|
|
25
|
+
}
|
|
26
|
+
function y(e, t) {
|
|
27
|
+
return e[0] * t[0] + e[1] * t[1];
|
|
28
|
+
}
|
|
29
|
+
function b(e, t) {
|
|
30
|
+
return e[0] === t[0] && e[1] === t[1];
|
|
31
|
+
}
|
|
32
|
+
function x(e) {
|
|
33
|
+
return Math.hypot(e[0], e[1]);
|
|
34
|
+
}
|
|
35
|
+
function S(e) {
|
|
36
|
+
return e[0] * e[0] + e[1] * e[1];
|
|
37
|
+
}
|
|
38
|
+
function C(e, t) {
|
|
39
|
+
return S(h(e, t));
|
|
40
|
+
}
|
|
41
|
+
function w(e) {
|
|
42
|
+
return _(e, x(e));
|
|
43
|
+
}
|
|
44
|
+
function T(e, t) {
|
|
45
|
+
return Math.hypot(e[1] - t[1], e[0] - t[0]);
|
|
46
|
+
}
|
|
47
|
+
function E(e, t, n) {
|
|
48
|
+
let r = Math.sin(n), i = Math.cos(n), a = e[0] - t[0], o = e[1] - t[1], s = a * i - o * r, c = a * r + o * i;
|
|
49
|
+
return [s + t[0], c + t[1]];
|
|
50
|
+
}
|
|
51
|
+
function D(e, t, n) {
|
|
52
|
+
return m(e, g(h(t, e), n));
|
|
53
|
+
}
|
|
54
|
+
function O(e, t, n) {
|
|
55
|
+
return m(e, g(t, n));
|
|
56
|
+
}
|
|
57
|
+
function k(e, t, n, r = (e) => e) {
|
|
58
|
+
return e * r(.5 - t * (.5 - n));
|
|
59
|
+
}
|
|
60
|
+
function A(e, t = {}) {
|
|
61
|
+
let { streamline: n = .5, size: r = 16, last: i = !1 } = t;
|
|
62
|
+
if (e.length === 0) return [];
|
|
63
|
+
let a = .15 + (1 - n) * .85, o = Array.isArray(e[0]) ? e : e.map(({ x: e, y: t, pressure: n = .5 }) => [
|
|
64
|
+
e,
|
|
65
|
+
t,
|
|
66
|
+
n
|
|
67
|
+
]);
|
|
68
|
+
if (o.length === 2) {
|
|
69
|
+
let e = o[1];
|
|
70
|
+
o = o.slice(0, -1);
|
|
71
|
+
for (let t = 1; t < 5; t++) o.push(D(o[0], e, t / 4));
|
|
72
|
+
}
|
|
73
|
+
o.length === 1 && (o = [...o, [...m(o[0], [1, 1]), ...o[0].slice(2)]]);
|
|
74
|
+
let s = [{
|
|
75
|
+
point: [o[0][0], o[0][1]],
|
|
76
|
+
pressure: o[0][2] >= 0 ? o[0][2] : .25,
|
|
77
|
+
vector: [1, 1],
|
|
78
|
+
distance: 0,
|
|
79
|
+
runningLength: 0
|
|
80
|
+
}], c = !1, l = 0, u = s[0], d = o.length - 1;
|
|
81
|
+
for (let e = 1; e < o.length; e++) {
|
|
82
|
+
let t = i && e === d ? o[e].slice(0, 2) : D(u.point, o[e], a);
|
|
83
|
+
if (b(u.point, t)) continue;
|
|
84
|
+
let n = T(t, u.point);
|
|
85
|
+
if (l += n, e < d && !c) {
|
|
86
|
+
if (l < r) continue;
|
|
87
|
+
c = !0;
|
|
88
|
+
let t = s[s.length - 1], n = t.runningLength;
|
|
89
|
+
for (let r = 1; r <= e; r++) {
|
|
90
|
+
let e = o[r], i = D(t.point, e, a);
|
|
91
|
+
if (b(t.point, i)) continue;
|
|
92
|
+
let c = T(i, t.point);
|
|
93
|
+
n += c, t = {
|
|
94
|
+
point: i,
|
|
95
|
+
pressure: e[2] >= 0 ? e[2] : .5,
|
|
96
|
+
vector: w(h(t.point, i)),
|
|
97
|
+
distance: c,
|
|
98
|
+
runningLength: n
|
|
99
|
+
}, s.push(t);
|
|
100
|
+
}
|
|
101
|
+
u = t, l = n;
|
|
102
|
+
continue;
|
|
103
|
+
}
|
|
104
|
+
u = {
|
|
105
|
+
point: t,
|
|
106
|
+
pressure: o[e][2] >= 0 ? o[e][2] : .5,
|
|
107
|
+
vector: w(h(u.point, t)),
|
|
108
|
+
distance: n,
|
|
109
|
+
runningLength: l
|
|
110
|
+
}, s.push(u);
|
|
111
|
+
}
|
|
112
|
+
return s[0].vector = s[1]?.vector || [0, 0], s;
|
|
113
|
+
}
|
|
114
|
+
var { min: j, PI: M } = Math, N = .275, P = M + 1e-4;
|
|
115
|
+
function F(e, t = {}) {
|
|
116
|
+
let { size: n = 16, smoothing: r = .5, thinning: i = .5, simulatePressure: a = !0, easing: o = (e) => e, start: s = {}, end: c = {}, last: l = !1 } = t, { cap: u = !0, easing: d = (e) => e * (2 - e) } = s, { cap: f = !0, easing: _ = (e) => --e * e * e + 1 } = c;
|
|
117
|
+
if (e.length === 0 || n <= 0) return [];
|
|
118
|
+
let b = e[e.length - 1].runningLength, x = s.taper === !1 ? 0 : s.taper === !0 ? Math.max(n, b) : s.taper, S = c.taper === !1 ? 0 : c.taper === !0 ? Math.max(n, b) : c.taper, T = (n * r) ** 2, A = [], M = [], F = e.slice(0, 10).reduce((e, t) => {
|
|
119
|
+
let r = t.pressure;
|
|
120
|
+
if (a) {
|
|
121
|
+
let i = j(1, t.distance / n);
|
|
122
|
+
r = j(1, e + (j(1, 1 - i) - e) * (i * N));
|
|
123
|
+
}
|
|
124
|
+
return (e + r) / 2;
|
|
125
|
+
}, e[0].pressure), I = k(n, i, e[e.length - 1].pressure, o), L, R = e[0].vector, z = e[0].point, B = z, V = z, H = B, U = !1;
|
|
126
|
+
for (let t = 0; t < e.length; t++) {
|
|
127
|
+
let { pressure: r } = e[t], { point: s, vector: c, distance: l, runningLength: u } = e[t];
|
|
128
|
+
if (t < e.length - 1 && b - u < 3) continue;
|
|
129
|
+
if (i) {
|
|
130
|
+
if (a) {
|
|
131
|
+
let e = j(1, l / n), t = j(1, 1 - e);
|
|
132
|
+
r = j(1, F + (t - F) * (e * N));
|
|
133
|
+
}
|
|
134
|
+
I = k(n, i, r, o);
|
|
135
|
+
} else I = n / 2;
|
|
136
|
+
L === void 0 && (L = I);
|
|
137
|
+
let f = u < x ? d(u / x) : 1, p = b - u < S ? _((b - u) / S) : 1;
|
|
138
|
+
I = Math.max(.01, I * Math.min(f, p));
|
|
139
|
+
let w = (t < e.length - 1 ? e[t + 1] : e[t]).vector, O = t < e.length - 1 ? y(c, w) : 1, W = y(c, R) < 0 && !U, G = O !== null && O < 0;
|
|
140
|
+
if (W || G) {
|
|
141
|
+
let e = g(v(R), I);
|
|
142
|
+
for (let t = 0; t <= 1; t += .07692307692307693) V = E(h(s, e), s, P * t), A.push(V), H = E(m(s, e), s, P * -t), M.push(H);
|
|
143
|
+
z = V, B = H, G && (U = !0);
|
|
144
|
+
continue;
|
|
145
|
+
}
|
|
146
|
+
if (U = !1, t === e.length - 1) {
|
|
147
|
+
let e = g(v(c), I);
|
|
148
|
+
A.push(h(s, e)), M.push(m(s, e));
|
|
149
|
+
continue;
|
|
150
|
+
}
|
|
151
|
+
let K = g(v(D(w, c, O)), I);
|
|
152
|
+
V = h(s, K), (t <= 1 || C(z, V) > T) && (A.push(V), z = V), H = m(s, K), (t <= 1 || C(B, H) > T) && (M.push(H), B = H), F = r, R = c;
|
|
153
|
+
}
|
|
154
|
+
let W = e[0].point.slice(0, 2), G = e.length > 1 ? e[e.length - 1].point.slice(0, 2) : m(e[0].point, [1, 1]), K = [], q = [];
|
|
155
|
+
if (e.length === 1) {
|
|
156
|
+
if (!(x || S) || l) {
|
|
157
|
+
let e = O(W, w(v(h(W, G))), -(L || I)), t = [];
|
|
158
|
+
for (let n = 1 / 13, r = n; r <= 1; r += n) t.push(E(e, W, P * 2 * r));
|
|
159
|
+
return t;
|
|
160
|
+
}
|
|
161
|
+
} else {
|
|
162
|
+
if (!(x || S && e.length === 1)) if (u) for (let e = 1 / 13, t = e; t <= 1; t += e) {
|
|
163
|
+
let e = E(M[0], W, P * t);
|
|
164
|
+
K.push(e);
|
|
165
|
+
}
|
|
166
|
+
else {
|
|
167
|
+
let e = h(A[0], M[0]), t = g(e, .5), n = g(e, .51);
|
|
168
|
+
K.push(h(W, t), h(W, n), m(W, n), m(W, t));
|
|
169
|
+
}
|
|
170
|
+
let t = v(p(e[e.length - 1].vector));
|
|
171
|
+
if (S || x && e.length === 1) q.push(G);
|
|
172
|
+
else if (f) {
|
|
173
|
+
let e = O(G, t, I);
|
|
174
|
+
for (let t = 1 / 29, n = t; n < 1; n += t) q.push(E(e, G, P * 3 * n));
|
|
175
|
+
} else q.push(m(G, g(t, I)), m(G, g(t, I * .99)), h(G, g(t, I * .99)), h(G, g(t, I)));
|
|
176
|
+
}
|
|
177
|
+
return A.concat(q, M.reverse(), K);
|
|
178
|
+
}
|
|
179
|
+
function I(e, t = {}) {
|
|
180
|
+
return F(A(e, t), t);
|
|
181
|
+
}
|
|
182
|
+
//#endregion
|
|
183
|
+
//#region src/shared/utils/canvasUtils.ts
|
|
184
|
+
function L(e) {
|
|
185
|
+
if (!e.length) return "";
|
|
186
|
+
let t = e.reduce((e, [t, n], r, i) => {
|
|
187
|
+
let [a, o] = i[(r + 1) % i.length];
|
|
188
|
+
return e.push(t, n, (t + a) / 2, (n + o) / 2), e;
|
|
189
|
+
}, [
|
|
190
|
+
"M",
|
|
191
|
+
...e[0],
|
|
192
|
+
"Q"
|
|
193
|
+
]);
|
|
194
|
+
return t.push("Z"), t.join(" ");
|
|
195
|
+
}
|
|
196
|
+
//#endregion
|
|
197
|
+
//#region src/components/EzSignature/EzSignature.tsx
|
|
198
|
+
var R = o.memo(({ stroke: e, options: t, color: n }) => /* @__PURE__ */ d("path", {
|
|
199
|
+
d: L(I(e, t)),
|
|
200
|
+
fill: n
|
|
201
|
+
})), z = o.forwardRef((o, p) => {
|
|
202
|
+
let m = t(), { width: h = "100%", height: g = 300, backgroundColor: _ = "transparent", strokeColor: v, minStrokeWidth: y = 2.5, maxStrokeWidth: b = 5, smoothing: x = .5, thinning: S = 0, readOnly: C = !1, disabled: w = !1, className: T, style: E, onEnd: D, onChange: O, onSave: k, dir: A, ...j } = o, M = a("I18nService")?.dir || "ltr", N = A === "auto" || !A ? M : A;
|
|
203
|
+
n(o), r();
|
|
204
|
+
let P = l([]), F = l(null), [z, B] = u([]), [V, H] = u([]), [U, W] = u(-1), G = l(null), K = v || "#0321ab", q = s((e) => {
|
|
205
|
+
let t = V.slice(0, U + 1);
|
|
206
|
+
t.push(e), H(t), W(t.length - 1), O && O(e.map((e) => JSON.stringify(e)));
|
|
207
|
+
}, [
|
|
208
|
+
V,
|
|
209
|
+
U,
|
|
210
|
+
O
|
|
211
|
+
]), J = s(() => {
|
|
212
|
+
let e = P.current;
|
|
213
|
+
if (F.current && e.length > 0) {
|
|
214
|
+
let t = I(e, {
|
|
215
|
+
size: b,
|
|
216
|
+
thinning: S,
|
|
217
|
+
smoothing: x,
|
|
218
|
+
start: {
|
|
219
|
+
cap: !0,
|
|
220
|
+
taper: !1
|
|
221
|
+
},
|
|
222
|
+
end: {
|
|
223
|
+
cap: !0,
|
|
224
|
+
taper: 10
|
|
225
|
+
},
|
|
226
|
+
simulatePressure: e.length > 2
|
|
227
|
+
});
|
|
228
|
+
F.current.setAttribute("d", L(t));
|
|
229
|
+
}
|
|
230
|
+
}, [
|
|
231
|
+
b,
|
|
232
|
+
S,
|
|
233
|
+
x
|
|
234
|
+
]), Y = (e) => {
|
|
235
|
+
C || w || (e.currentTarget.setPointerCapture(e.pointerId), P.current = [[
|
|
236
|
+
e.nativeEvent.offsetX,
|
|
237
|
+
e.nativeEvent.offsetY,
|
|
238
|
+
e.pressure
|
|
239
|
+
]], J());
|
|
240
|
+
}, X = (e) => {
|
|
241
|
+
if (C || w || e.buttons !== 1) return;
|
|
242
|
+
let t = [
|
|
243
|
+
e.nativeEvent.offsetX,
|
|
244
|
+
e.nativeEvent.offsetY,
|
|
245
|
+
e.pressure
|
|
246
|
+
];
|
|
247
|
+
P.current.push(t), J();
|
|
248
|
+
}, Z = (e) => {
|
|
249
|
+
if (!(C || w) && P.current.length > 0) {
|
|
250
|
+
let t = [...z, P.current];
|
|
251
|
+
B(t), q(t), P.current = [], F.current && F.current.setAttribute("d", ""), D && D(e);
|
|
252
|
+
}
|
|
253
|
+
};
|
|
254
|
+
i(p, c(() => ({
|
|
255
|
+
clear: () => {
|
|
256
|
+
B([]), P.current = [], F.current && F.current.setAttribute("d", ""), q([]), m.get("NotificationService")?.show({
|
|
257
|
+
type: "info",
|
|
258
|
+
message: "Signature Cleared",
|
|
259
|
+
duration: 2e3
|
|
260
|
+
});
|
|
261
|
+
},
|
|
262
|
+
undo: () => {
|
|
263
|
+
if (U > 0) {
|
|
264
|
+
let e = U - 1;
|
|
265
|
+
W(e), B(V[e]);
|
|
266
|
+
} else U === 0 && (W(-1), B([]));
|
|
267
|
+
},
|
|
268
|
+
redo: () => {
|
|
269
|
+
if (U < V.length - 1) {
|
|
270
|
+
let e = U + 1;
|
|
271
|
+
W(e), B(V[e]);
|
|
272
|
+
}
|
|
273
|
+
},
|
|
274
|
+
canUndo: () => U >= 0,
|
|
275
|
+
canRedo: () => U < V.length - 1,
|
|
276
|
+
isEmpty: () => z.length === 0 && P.current.length === 0,
|
|
277
|
+
getSignature: () => z,
|
|
278
|
+
load: (e) => {
|
|
279
|
+
if (typeof e == "string") {
|
|
280
|
+
try {
|
|
281
|
+
let t = JSON.parse(e);
|
|
282
|
+
Array.isArray(t) && (B(t), q(t));
|
|
283
|
+
} catch (e) {
|
|
284
|
+
console.error("Failed to parse signature data", e);
|
|
285
|
+
}
|
|
286
|
+
return;
|
|
287
|
+
}
|
|
288
|
+
Array.isArray(e) && (B(e), q(e));
|
|
289
|
+
},
|
|
290
|
+
save: async (e = "png") => {
|
|
291
|
+
if (!G.current) return "";
|
|
292
|
+
let t = new XMLSerializer().serializeToString(G.current), n = document.createElement("canvas"), r = n.getContext("2d"), i = new Image(), a = G.current.getBoundingClientRect();
|
|
293
|
+
return n.width = a.width, n.height = a.height, new Promise((a, o) => {
|
|
294
|
+
i.onload = () => {
|
|
295
|
+
if (r) {
|
|
296
|
+
_ && _ !== "transparent" && (r.fillStyle = _, r.fillRect(0, 0, n.width, n.height)), r.drawImage(i, 0, 0);
|
|
297
|
+
let t = n.toDataURL(`image/${e}`);
|
|
298
|
+
k && k(t, e), m.get("NotificationService")?.show({
|
|
299
|
+
type: "success",
|
|
300
|
+
message: "Signature Saved Successfully",
|
|
301
|
+
duration: 3e3
|
|
302
|
+
}), a(t);
|
|
303
|
+
} else {
|
|
304
|
+
let e = /* @__PURE__ */ Error("Canvas context not defined");
|
|
305
|
+
m.get("NotificationService")?.show({
|
|
306
|
+
type: "error",
|
|
307
|
+
message: "Failed to Save Signature",
|
|
308
|
+
duration: 3e3
|
|
309
|
+
}), o(e);
|
|
310
|
+
}
|
|
311
|
+
}, i.onerror = (e) => {
|
|
312
|
+
m.get("NotificationService")?.show({
|
|
313
|
+
type: "error",
|
|
314
|
+
message: "Failed to Process Signature Image",
|
|
315
|
+
duration: 3e3
|
|
316
|
+
}), o(e);
|
|
317
|
+
}, i.src = "data:image/svg+xml;base64," + btoa(unescape(encodeURIComponent(t)));
|
|
318
|
+
});
|
|
319
|
+
}
|
|
320
|
+
}), [
|
|
321
|
+
V,
|
|
322
|
+
U,
|
|
323
|
+
z,
|
|
324
|
+
_,
|
|
325
|
+
k,
|
|
326
|
+
q
|
|
327
|
+
]));
|
|
328
|
+
let Q = c(() => ({
|
|
329
|
+
size: b,
|
|
330
|
+
thinning: S,
|
|
331
|
+
smoothing: x,
|
|
332
|
+
start: {
|
|
333
|
+
cap: !0,
|
|
334
|
+
taper: !1
|
|
335
|
+
},
|
|
336
|
+
end: {
|
|
337
|
+
cap: !0,
|
|
338
|
+
taper: 10
|
|
339
|
+
}
|
|
340
|
+
}), [
|
|
341
|
+
b,
|
|
342
|
+
S,
|
|
343
|
+
x
|
|
344
|
+
]), $ = c(() => z.map((e, t) => /* @__PURE__ */ d(R, {
|
|
345
|
+
stroke: e,
|
|
346
|
+
options: Q,
|
|
347
|
+
color: K
|
|
348
|
+
}, t)), [
|
|
349
|
+
z,
|
|
350
|
+
Q,
|
|
351
|
+
K
|
|
352
|
+
]);
|
|
353
|
+
return /* @__PURE__ */ d("div", {
|
|
354
|
+
className: e("ez-signature-container relative overflow-hidden select-none touch-none", T),
|
|
355
|
+
style: {
|
|
356
|
+
width: h,
|
|
357
|
+
height: g,
|
|
358
|
+
...E
|
|
359
|
+
},
|
|
360
|
+
dir: N,
|
|
361
|
+
...j,
|
|
362
|
+
children: /* @__PURE__ */ f("svg", {
|
|
363
|
+
ref: G,
|
|
364
|
+
className: "w-full h-full",
|
|
365
|
+
style: {
|
|
366
|
+
backgroundColor: _,
|
|
367
|
+
touchAction: "none"
|
|
368
|
+
},
|
|
369
|
+
onPointerDown: Y,
|
|
370
|
+
onPointerMove: X,
|
|
371
|
+
onPointerUp: Z,
|
|
372
|
+
onPointerLeave: Z,
|
|
373
|
+
role: "img",
|
|
374
|
+
"aria-label": "Signature canvas",
|
|
375
|
+
children: [$, /* @__PURE__ */ d("path", {
|
|
376
|
+
ref: F,
|
|
377
|
+
fill: K,
|
|
378
|
+
opacity: .8,
|
|
379
|
+
d: ""
|
|
380
|
+
})]
|
|
381
|
+
})
|
|
382
|
+
});
|
|
383
|
+
});
|
|
384
|
+
z.displayName = "EzSignature";
|
|
385
|
+
//#endregion
|
|
386
|
+
export { z as t };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const e=require("./EzProvider-L2qQMq-v.cjs"),t=require("./useInitCoreServices-DlALVDNx.cjs"),n=require("./useImperativeAPI-VrgLwXEO.cjs"),r=require("./useServiceState-PyYQWxHi.cjs");let i=require("react");i=e.y(i,1);let a=require("react/jsx-runtime");function o(e){return[-e[0],-e[1]]}function s(e,t){return[e[0]+t[0],e[1]+t[1]]}function c(e,t){return[e[0]-t[0],e[1]-t[1]]}function l(e,t){return[e[0]*t,e[1]*t]}function u(e,t){return[e[0]/t,e[1]/t]}function d(e){return[e[1],-e[0]]}function f(e,t){return e[0]*t[0]+e[1]*t[1]}function p(e,t){return e[0]===t[0]&&e[1]===t[1]}function m(e){return Math.hypot(e[0],e[1])}function h(e){return e[0]*e[0]+e[1]*e[1]}function g(e,t){return h(c(e,t))}function _(e){return u(e,m(e))}function v(e,t){return Math.hypot(e[1]-t[1],e[0]-t[0])}function y(e,t,n){let r=Math.sin(n),i=Math.cos(n),a=e[0]-t[0],o=e[1]-t[1],s=a*i-o*r,c=a*r+o*i;return[s+t[0],c+t[1]]}function b(e,t,n){return s(e,l(c(t,e),n))}function x(e,t,n){return s(e,l(t,n))}function S(e,t,n,r=e=>e){return e*r(.5-t*(.5-n))}function C(e,t={}){let{streamline:n=.5,size:r=16,last:i=!1}=t;if(e.length===0)return[];let a=.15+(1-n)*.85,o=Array.isArray(e[0])?e:e.map(({x:e,y:t,pressure:n=.5})=>[e,t,n]);if(o.length===2){let e=o[1];o=o.slice(0,-1);for(let t=1;t<5;t++)o.push(b(o[0],e,t/4))}o.length===1&&(o=[...o,[...s(o[0],[1,1]),...o[0].slice(2)]]);let l=[{point:[o[0][0],o[0][1]],pressure:o[0][2]>=0?o[0][2]:.25,vector:[1,1],distance:0,runningLength:0}],u=!1,d=0,f=l[0],m=o.length-1;for(let e=1;e<o.length;e++){let t=i&&e===m?o[e].slice(0,2):b(f.point,o[e],a);if(p(f.point,t))continue;let n=v(t,f.point);if(d+=n,e<m&&!u){if(d<r)continue;u=!0;let t=l[l.length-1],n=t.runningLength;for(let r=1;r<=e;r++){let e=o[r],i=b(t.point,e,a);if(p(t.point,i))continue;let s=v(i,t.point);n+=s,t={point:i,pressure:e[2]>=0?e[2]:.5,vector:_(c(t.point,i)),distance:s,runningLength:n},l.push(t)}f=t,d=n;continue}f={point:t,pressure:o[e][2]>=0?o[e][2]:.5,vector:_(c(f.point,t)),distance:n,runningLength:d},l.push(f)}return l[0].vector=l[1]?.vector||[0,0],l}var{min:w,PI:T}=Math,E=.275,D=T+1e-4;function O(e,t={}){let{size:n=16,smoothing:r=.5,thinning:i=.5,simulatePressure:a=!0,easing:u=e=>e,start:p={},end:m={},last:h=!1}=t,{cap:v=!0,easing:C=e=>e*(2-e)}=p,{cap:T=!0,easing:O=e=>--e*e*e+1}=m;if(e.length===0||n<=0)return[];let k=e[e.length-1].runningLength,A=p.taper===!1?0:p.taper===!0?Math.max(n,k):p.taper,j=m.taper===!1?0:m.taper===!0?Math.max(n,k):m.taper,M=(n*r)**2,N=[],P=[],F=e.slice(0,10).reduce((e,t)=>{let r=t.pressure;if(a){let i=w(1,t.distance/n);r=w(1,e+(w(1,1-i)-e)*(i*E))}return(e+r)/2},e[0].pressure),I=S(n,i,e[e.length-1].pressure,u),L,R=e[0].vector,z=e[0].point,B=z,V=z,H=B,U=!1;for(let t=0;t<e.length;t++){let{pressure:r}=e[t],{point:o,vector:p,distance:m,runningLength:h}=e[t];if(t<e.length-1&&k-h<3)continue;if(i){if(a){let e=w(1,m/n),t=w(1,1-e);r=w(1,F+(t-F)*(e*E))}I=S(n,i,r,u)}else I=n/2;L===void 0&&(L=I);let _=h<A?C(h/A):1,v=k-h<j?O((k-h)/j):1;I=Math.max(.01,I*Math.min(_,v));let x=(t<e.length-1?e[t+1]:e[t]).vector,T=t<e.length-1?f(p,x):1,W=f(p,R)<0&&!U,G=T!==null&&T<0;if(W||G){let e=l(d(R),I);for(let t=0;t<=1;t+=.07692307692307693)V=y(c(o,e),o,D*t),N.push(V),H=y(s(o,e),o,D*-t),P.push(H);z=V,B=H,G&&(U=!0);continue}if(U=!1,t===e.length-1){let e=l(d(p),I);N.push(c(o,e)),P.push(s(o,e));continue}let K=l(d(b(x,p,T)),I);V=c(o,K),(t<=1||g(z,V)>M)&&(N.push(V),z=V),H=s(o,K),(t<=1||g(B,H)>M)&&(P.push(H),B=H),F=r,R=p}let W=e[0].point.slice(0,2),G=e.length>1?e[e.length-1].point.slice(0,2):s(e[0].point,[1,1]),K=[],q=[];if(e.length===1){if(!(A||j)||h){let e=x(W,_(d(c(W,G))),-(L||I)),t=[];for(let n=1/13,r=n;r<=1;r+=n)t.push(y(e,W,D*2*r));return t}}else{if(!(A||j&&e.length===1))if(v)for(let e=1/13,t=e;t<=1;t+=e){let e=y(P[0],W,D*t);K.push(e)}else{let e=c(N[0],P[0]),t=l(e,.5),n=l(e,.51);K.push(c(W,t),c(W,n),s(W,n),s(W,t))}let t=d(o(e[e.length-1].vector));if(j||A&&e.length===1)q.push(G);else if(T){let e=x(G,t,I);for(let t=1/29,n=t;n<1;n+=t)q.push(y(e,G,D*3*n))}else q.push(s(G,l(t,I)),s(G,l(t,I*.99)),c(G,l(t,I*.99)),c(G,l(t,I)))}return N.concat(q,P.reverse(),K)}function k(e,t={}){return O(C(e,t),t)}function A(e){if(!e.length)return``;let t=e.reduce((e,[t,n],r,i)=>{let[a,o]=i[(r+1)%i.length];return e.push(t,n,(t+a)/2,(n+o)/2),e},[`M`,...e[0],`Q`]);return t.push(`Z`),t.join(` `)}var j=i.default.memo(({stroke:e,options:t,color:n})=>(0,a.jsx)(`path`,{d:A(k(e,t)),fill:n})),M=i.default.forwardRef((o,s)=>{let c=e.n(),{width:l=`100%`,height:u=300,backgroundColor:d=`transparent`,strokeColor:f,minStrokeWidth:p=2.5,maxStrokeWidth:m=5,smoothing:h=.5,thinning:g=0,readOnly:_=!1,disabled:v=!1,className:y,style:b,onEnd:x,onChange:S,onSave:C,dir:w,...T}=o,E=r.t(`I18nService`)?.dir||`ltr`,D=w===`auto`||!w?E:w;t.n(o),t.t();let O=(0,i.useRef)([]),M=(0,i.useRef)(null),[N,P]=(0,i.useState)([]),[F,I]=(0,i.useState)([]),[L,R]=(0,i.useState)(-1),z=(0,i.useRef)(null),B=f||`#0321ab`,V=(0,i.useCallback)(e=>{let t=F.slice(0,L+1);t.push(e),I(t),R(t.length-1),S&&S(e.map(e=>JSON.stringify(e)))},[F,L,S]),H=(0,i.useCallback)(()=>{let e=O.current;if(M.current&&e.length>0){let t=k(e,{size:m,thinning:g,smoothing:h,start:{cap:!0,taper:!1},end:{cap:!0,taper:10},simulatePressure:e.length>2});M.current.setAttribute(`d`,A(t))}},[m,g,h]),U=e=>{_||v||(e.currentTarget.setPointerCapture(e.pointerId),O.current=[[e.nativeEvent.offsetX,e.nativeEvent.offsetY,e.pressure]],H())},W=e=>{if(_||v||e.buttons!==1)return;let t=[e.nativeEvent.offsetX,e.nativeEvent.offsetY,e.pressure];O.current.push(t),H()},G=e=>{if(!(_||v)&&O.current.length>0){let t=[...N,O.current];P(t),V(t),O.current=[],M.current&&M.current.setAttribute(`d`,``),x&&x(e)}};n.t(s,(0,i.useMemo)(()=>({clear:()=>{P([]),O.current=[],M.current&&M.current.setAttribute(`d`,``),V([]),c.get(`NotificationService`)?.show({type:`info`,message:`Signature Cleared`,duration:2e3})},undo:()=>{if(L>0){let e=L-1;R(e),P(F[e])}else L===0&&(R(-1),P([]))},redo:()=>{if(L<F.length-1){let e=L+1;R(e),P(F[e])}},canUndo:()=>L>=0,canRedo:()=>L<F.length-1,isEmpty:()=>N.length===0&&O.current.length===0,getSignature:()=>N,load:e=>{if(typeof e==`string`){try{let t=JSON.parse(e);Array.isArray(t)&&(P(t),V(t))}catch(e){console.error(`Failed to parse signature data`,e)}return}Array.isArray(e)&&(P(e),V(e))},save:async(e=`png`)=>{if(!z.current)return``;let t=new XMLSerializer().serializeToString(z.current),n=document.createElement(`canvas`),r=n.getContext(`2d`),i=new Image,a=z.current.getBoundingClientRect();return n.width=a.width,n.height=a.height,new Promise((a,o)=>{i.onload=()=>{if(r){d&&d!==`transparent`&&(r.fillStyle=d,r.fillRect(0,0,n.width,n.height)),r.drawImage(i,0,0);let t=n.toDataURL(`image/${e}`);C&&C(t,e),c.get(`NotificationService`)?.show({type:`success`,message:`Signature Saved Successfully`,duration:3e3}),a(t)}else{let e=Error(`Canvas context not defined`);c.get(`NotificationService`)?.show({type:`error`,message:`Failed to Save Signature`,duration:3e3}),o(e)}},i.onerror=e=>{c.get(`NotificationService`)?.show({type:`error`,message:`Failed to Process Signature Image`,duration:3e3}),o(e)},i.src=`data:image/svg+xml;base64,`+btoa(unescape(encodeURIComponent(t)))})}}),[F,L,N,d,C,V]));let K=(0,i.useMemo)(()=>({size:m,thinning:g,smoothing:h,start:{cap:!0,taper:!1},end:{cap:!0,taper:10}}),[m,g,h]),q=(0,i.useMemo)(()=>N.map((e,t)=>(0,a.jsx)(j,{stroke:e,options:K,color:B},t)),[N,K,B]);return(0,a.jsx)(`div`,{className:e._(`ez-signature-container relative overflow-hidden select-none touch-none`,y),style:{width:l,height:u,...b},dir:D,...T,children:(0,a.jsxs)(`svg`,{ref:z,className:`w-full h-full`,style:{backgroundColor:d,touchAction:`none`},onPointerDown:U,onPointerMove:W,onPointerUp:G,onPointerLeave:G,role:`img`,"aria-label":`Signature canvas`,children:[q,(0,a.jsx)(`path`,{ref:M,fill:B,opacity:.8,d:``})]})})});M.displayName=`EzSignature`,Object.defineProperty(exports,"t",{enumerable:!0,get:function(){return M}});
|