@kapiuara/ui 0.23.0 → 0.23.1
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/components/chat/KapiChatDivider.js +1 -2
- package/dist/components/chat/KapiChatList.js +15 -16
- package/dist/components/chat/KapiChatThread.js +21 -22
- package/dist/components/chat/KapiComposer.js +23 -24
- package/dist/components/chat/KapiMessageBubble.js +5 -6
- package/dist/components/chat/KapiTypingIndicator.js +5 -6
- package/dist/components/chat/chatLogic.js +1 -2
- package/dist/components/data/KapiBarChart.js +22 -23
- package/dist/components/data/KapiDataTable.js +92 -93
- package/dist/components/data/KapiEventCalendar.js +96 -97
- package/dist/components/data/KapiHeatmap.js +21 -22
- package/dist/components/data/KapiLineChart.js +23 -24
- package/dist/components/data/KapiPagination.js +1 -2
- package/dist/components/data/KapiPaginationFooter.js +5 -6
- package/dist/components/data/KapiScatterChart.js +18 -19
- package/dist/components/data/KapiSheet.js +2 -3
- package/dist/components/data/KapiSparkline.js +1 -2
- package/dist/components/data/KapiTable.js +107 -108
- package/dist/components/data/KapiTableFilter.js +13 -14
- package/dist/components/data/KapiTableFooter.js +21 -22
- package/dist/components/data/KapiTableRow.js +10 -11
- package/dist/components/data/KapiTableToolbar.js +95 -96
- package/dist/components/data/barChartLogic.js +1 -2
- package/dist/components/data/chartFrame.js +13 -14
- package/dist/components/data/datasetSelectionLogic.js +1 -2
- package/dist/components/data/eventCalendarLogic.js +2 -3
- package/dist/components/data/heatmapLogic.js +1 -2
- package/dist/components/data/lineChartLogic.js +1 -2
- package/dist/components/data/rowClickLogic.js +2 -17
- package/dist/components/data/scatterLogic.js +1 -2
- package/dist/components/data/sparklineLogic.js +1 -2
- package/dist/components/data/tableCells.js +14 -15
- package/dist/components/data/tableHeaderMenu.js +1 -2
- package/dist/components/data/tableLabels.js +1 -2
- package/dist/components/data/tableLogic.js +0 -1
- package/dist/components/data/tablePaginationLogic.js +1 -2
- package/dist/components/data/tableResizeLogic.js +1 -2
- package/dist/components/data/tableSlots.js +1 -2
- package/dist/components/data/tableSpanLogic.js +1 -2
- package/dist/components/data/useColumnResize.js +23 -24
- package/dist/components/data/useRowKeyWarning.js +1 -2
- package/dist/components/data/useTableEdges.js +1 -2
- package/dist/components/data/useTableSelection.js +25 -26
- package/dist/components/display/KapiAnchor.js +7 -8
- package/dist/components/display/KapiAnnotation.js +15 -16
- package/dist/components/display/KapiAvatar.js +6 -7
- package/dist/components/display/KapiAvatarGroup.js +15 -16
- package/dist/components/display/KapiBadge.js +1 -2
- package/dist/components/display/KapiCodeBlock.js +14 -15
- package/dist/components/display/KapiComment.js +10 -11
- package/dist/components/display/KapiCommentComposer.js +13 -14
- package/dist/components/display/KapiDescriptionList.js +1 -2
- package/dist/components/display/KapiDiff.js +23 -24
- package/dist/components/display/KapiFileItem.js +13 -14
- package/dist/components/display/KapiFileViewer.js +17 -18
- package/dist/components/display/KapiHighlight.js +2 -3
- package/dist/components/display/KapiIconTile.js +2 -3
- package/dist/components/display/KapiStat.js +8 -9
- package/dist/components/display/KapiTag.js +6 -7
- package/dist/components/display/KapiText.js +5 -6
- package/dist/components/display/KapiTimeline.js +2 -3
- package/dist/components/display/KapiTitle.js +1 -2
- package/dist/components/display/KapiTruncate.js +5 -6
- package/dist/components/display/annotationLogic.js +1 -2
- package/dist/components/display/avatarGroupLogic.js +1 -2
- package/dist/components/display/avatarGroupSlots.js +1 -2
- package/dist/components/display/avatarLogic.js +1 -2
- package/dist/components/display/codeBlockSlots.js +1 -2
- package/dist/components/display/commentLogic.js +1 -2
- package/dist/components/display/diffLogic.js +1 -2
- package/dist/components/display/diffSlots.js +1 -2
- package/dist/components/display/fileItemLogic.js +1 -2
- package/dist/components/display/highlightLogic.js +1 -2
- package/dist/components/display/highlightSlots.js +1 -2
- package/dist/components/display/iconTileLogic.js +1 -2
- package/dist/components/display/statLogic.js +1 -2
- package/dist/components/display/tagLogic.js +1 -2
- package/dist/components/display/textLogic.js +1 -2
- package/dist/components/display/timelineLogic.js +1 -2
- package/dist/components/display/truncateLogic.js +1 -2
- package/dist/components/feedback/KapiAlert.js +6 -7
- package/dist/components/feedback/KapiBulkBar.js +5 -6
- package/dist/components/feedback/KapiCountdown.js +16 -17
- package/dist/components/feedback/KapiEmpty.js +2 -3
- package/dist/components/feedback/KapiFab.js +96 -97
- package/dist/components/feedback/KapiOfflineBanner.js +4 -5
- package/dist/components/feedback/KapiProgress.js +1 -2
- package/dist/components/feedback/KapiSkeleton.js +1 -2
- package/dist/components/feedback/KapiSpinner.js +5 -6
- package/dist/components/feedback/KapiToastContainer.js +28 -29
- package/dist/components/feedback/KapiTour.js +24 -25
- package/dist/components/feedback/KapiUnsavedBar.js +5 -6
- package/dist/components/feedback/alertSlots.js +1 -2
- package/dist/components/feedback/bulkBarLogic.js +1 -2
- package/dist/components/feedback/countdownLogic.js +1 -2
- package/dist/components/feedback/countdownSlots.js +1 -2
- package/dist/components/feedback/emptySlots.js +1 -2
- package/dist/components/feedback/fabLogic.js +1 -2
- package/dist/components/feedback/offlineBannerLogic.js +1 -2
- package/dist/components/feedback/progressLogic.js +1 -2
- package/dist/components/feedback/toastLayer.js +1 -2
- package/dist/components/feedback/toastStore.js +2 -3
- package/dist/components/feedback/tourLogic.js +1 -2
- package/dist/components/feedback/unsavedBarLogic.js +1 -2
- package/dist/components/inputs/KapiAutocomplete.js +23 -24
- package/dist/components/inputs/KapiButton.js +1 -2
- package/dist/components/inputs/KapiCalendar.js +12 -13
- package/dist/components/inputs/KapiCalendarGrid.js +15 -16
- package/dist/components/inputs/KapiCheckCard.js +4 -5
- package/dist/components/inputs/KapiCheckbox.js +1 -2
- package/dist/components/inputs/KapiChecklist.js +62 -63
- package/dist/components/inputs/KapiCopyButton.js +6 -7
- package/dist/components/inputs/KapiDatePicker.js +33 -34
- package/dist/components/inputs/KapiDateRangePicker.js +145 -146
- package/dist/components/inputs/KapiFacetedSearch.js +55 -56
- package/dist/components/inputs/KapiField.js +5 -6
- package/dist/components/inputs/KapiFileUpload.js +26 -27
- package/dist/components/inputs/KapiIconButton.js +1 -2
- package/dist/components/inputs/KapiInput.js +46 -47
- package/dist/components/inputs/KapiInputGroup.js +1 -2
- package/dist/components/inputs/KapiMaskedInput.js +50 -51
- package/dist/components/inputs/KapiNumberStepper.js +49 -50
- package/dist/components/inputs/KapiPinInput.js +9 -10
- package/dist/components/inputs/KapiPropsForm.js +43 -44
- package/dist/components/inputs/KapiRadio.js +1 -2
- package/dist/components/inputs/KapiRating.js +38 -39
- package/dist/components/inputs/KapiSearchChip.js +10 -11
- package/dist/components/inputs/KapiSegmented.js +65 -66
- package/dist/components/inputs/KapiSelect.js +198 -199
- package/dist/components/inputs/KapiSelectMenu.js +1 -2
- package/dist/components/inputs/KapiSlider.js +11 -12
- package/dist/components/inputs/KapiSwitch.js +6 -7
- package/dist/components/inputs/KapiTagInput.js +32 -33
- package/dist/components/inputs/KapiTextarea.js +22 -23
- package/dist/components/inputs/asyncSelectLogic.js +22 -23
- package/dist/components/inputs/autocompleteLogic.js +1 -2
- package/dist/components/inputs/checkControl.js +4 -5
- package/dist/components/inputs/checklistLogic.js +1 -2
- package/dist/components/inputs/copyLogic.js +1 -2
- package/dist/components/inputs/datePickerLogic.js +1 -2
- package/dist/components/inputs/dateRangeLogic.js +1 -2
- package/dist/components/inputs/facetedSearchLogic.js +1 -2
- package/dist/components/inputs/fieldLogic.js +1 -2
- package/dist/components/inputs/fileUploadLogic.js +1 -2
- package/dist/components/inputs/formBridgeLogic.js +1 -2
- package/dist/components/inputs/inputGroupLogic.js +1 -2
- package/dist/components/inputs/inputLogic.js +1 -2
- package/dist/components/inputs/maskLogic.js +0 -1
- package/dist/components/inputs/misuseWarnings.js +1 -2
- package/dist/components/inputs/numberStepLogic.js +1 -2
- package/dist/components/inputs/ownField.js +9 -10
- package/dist/components/inputs/pinInputLogic.js +1 -2
- package/dist/components/inputs/propsFormLogic.js +1 -2
- package/dist/components/inputs/ratingLogic.js +1 -2
- package/dist/components/inputs/searchChipLogic.js +1 -2
- package/dist/components/inputs/segmentedLogic.js +1 -2
- package/dist/components/inputs/selectKeyLogic.js +1 -2
- package/dist/components/inputs/selectLogic.js +1 -2
- package/dist/components/inputs/selectSlots.js +1 -2
- package/dist/components/inputs/sliderLogic.js +1 -2
- package/dist/components/inputs/tagInputLogic.js +1 -2
- package/dist/components/inputs/textareaLogic.js +1 -2
- package/dist/components/inputs/useCalendarFocus.js +1 -2
- package/dist/components/inputs/useDatePopSide.js +1 -2
- package/dist/components/inputs/useSelectCreate.js +1 -2
- package/dist/components/inputs/useSelectSource.js +11 -12
- package/dist/components/labelsLogic.js +1 -2
- package/dist/components/layout/KapiAccessCard.js +10 -11
- package/dist/components/layout/KapiAccountMenu.js +24 -25
- package/dist/components/layout/KapiBox.js +5 -6
- package/dist/components/layout/KapiCard.js +18 -19
- package/dist/components/layout/KapiCenter.js +1 -2
- package/dist/components/layout/KapiCluster.js +1 -2
- package/dist/components/layout/KapiCol.js +1 -2
- package/dist/components/layout/KapiCollapse.js +1 -2
- package/dist/components/layout/KapiContextSlot.js +98 -99
- package/dist/components/layout/KapiDivider.js +1 -2
- package/dist/components/layout/KapiGrid.js +9 -10
- package/dist/components/layout/KapiMasonry.js +1 -2
- package/dist/components/layout/KapiNotificationBell.js +53 -54
- package/dist/components/layout/KapiPageHeader.js +42 -43
- package/dist/components/layout/KapiPanelParts.js +43 -44
- package/dist/components/layout/KapiRail.js +103 -104
- package/dist/components/layout/KapiRailAccount.js +11 -12
- package/dist/components/layout/KapiRoot.js +33 -34
- package/dist/components/layout/KapiScrollArea.js +7 -8
- package/dist/components/layout/KapiShell.js +8 -9
- package/dist/components/layout/KapiStack.js +1 -2
- package/dist/components/layout/KapiThemeScript.js +1 -2
- package/dist/components/layout/accessCardLogic.js +1 -2
- package/dist/components/layout/cardLogic.js +1 -2
- package/dist/components/layout/cardSlots.js +1 -2
- package/dist/components/layout/gridSpanLogic.js +1 -2
- package/dist/components/layout/layoutPrimitives.js +1 -2
- package/dist/components/layout/masonryLogic.js +1 -2
- package/dist/components/layout/notificationBellLogic.js +1 -2
- package/dist/components/layout/pageHeaderLogic.js +1 -2
- package/dist/components/layout/pageHeaderSlots.js +1 -2
- package/dist/components/layout/railContext.js +1 -2
- package/dist/components/layout/railLogic.js +1 -2
- package/dist/components/layout/railSlots.js +1 -2
- package/dist/components/layout/reopenBus.js +1 -2
- package/dist/components/layout/shellSlots.js +1 -2
- package/dist/components/layout/useGridBreakpoint.js +1 -2
- package/dist/components/layout/useMasonrySpans.js +6 -7
- package/dist/components/layout/useRailOverflow.js +7 -8
- package/dist/components/locale/KapiLocaleProvider.js +1 -2
- package/dist/components/locale/linkLabels.js +1 -2
- package/dist/components/locale/localeLogic.js +1 -2
- package/dist/components/navigation/CtxSlidingList.js +7 -8
- package/dist/components/navigation/KapiAccordion.js +11 -12
- package/dist/components/navigation/KapiBreadcrumb.js +11 -12
- package/dist/components/navigation/KapiCollapsiblePanel.js +13 -14
- package/dist/components/navigation/KapiContextPanel.js +138 -139
- package/dist/components/navigation/KapiFilterChips.js +25 -22
- package/dist/components/navigation/KapiNavBadge.js +6 -7
- package/dist/components/navigation/KapiPanelGroup.js +34 -35
- package/dist/components/navigation/KapiSteps.js +41 -36
- package/dist/components/navigation/KapiTabs.js +40 -41
- package/dist/components/navigation/KapiToc.js +15 -16
- package/dist/components/navigation/KapiTree.js +126 -124
- package/dist/components/navigation/KapiWizard.js +12 -13
- package/dist/components/navigation/MiniNavItem.js +11 -12
- package/dist/components/navigation/accordionLogic.js +1 -2
- package/dist/components/navigation/activeItemLogic.js +1 -2
- package/dist/components/navigation/breadcrumbLogic.js +1 -2
- package/dist/components/navigation/contextPanelLogic.js +1 -2
- package/dist/components/navigation/filterChipsLogic.d.ts +9 -1
- package/dist/components/navigation/filterChipsLogic.js +2 -3
- package/dist/components/navigation/navBadgeLogic.js +1 -2
- package/dist/components/navigation/navLink.js +1 -2
- package/dist/components/navigation/navLinkLogic.js +1 -2
- package/dist/components/navigation/panelGroupLogic.js +1 -2
- package/dist/components/navigation/panelMini.js +0 -1
- package/dist/components/navigation/panelMiniLogic.js +1 -2
- package/dist/components/navigation/stepsLogic.js +1 -2
- package/dist/components/navigation/tabsLogic.js +1 -2
- package/dist/components/navigation/tocLogic.js +1 -2
- package/dist/components/navigation/tocSlots.js +1 -2
- package/dist/components/navigation/treeLogic.js +1 -2
- package/dist/components/navigation/wizardLogic.js +1 -2
- package/dist/components/overlays/KapiCanvasForm.js +5 -6
- package/dist/components/overlays/KapiCommandPalette.js +45 -45
- package/dist/components/overlays/KapiConfirm.js +9 -10
- package/dist/components/overlays/KapiContextMenu.js +16 -17
- package/dist/components/overlays/KapiDialogHost.js +50 -51
- package/dist/components/overlays/KapiDropdown.js +2 -3
- package/dist/components/overlays/KapiImageViewer.js +8 -9
- package/dist/components/overlays/KapiLoading.js +7 -8
- package/dist/components/overlays/KapiMenuButton.js +19 -20
- package/dist/components/overlays/KapiModal.js +58 -59
- package/dist/components/overlays/KapiOffcanvas.js +146 -147
- package/dist/components/overlays/KapiOffcanvasStack.js +18 -19
- package/dist/components/overlays/KapiPhotoView.js +21 -22
- package/dist/components/overlays/KapiPopover.js +12 -13
- package/dist/components/overlays/KapiShapeSheet.js +11 -12
- package/dist/components/overlays/KapiShortcutsHelp.js +18 -19
- package/dist/components/overlays/KapiSplitModal.js +20 -21
- package/dist/components/overlays/KapiTooltip.js +46 -47
- package/dist/components/overlays/KapiViewport.js +17 -18
- package/dist/components/overlays/canvasFormLogic.js +1 -2
- package/dist/components/overlays/commandPaletteLogic.js +1 -2
- package/dist/components/overlays/dialogStore.js +3 -4
- package/dist/components/overlays/dialogUtils.js +1 -2
- package/dist/components/overlays/exitPresenceLogic.js +1 -2
- package/dist/components/overlays/menuButtonLogic.js +1 -2
- package/dist/components/overlays/menuKeyboardLogic.js +1 -2
- package/dist/components/overlays/menuList.js +94 -95
- package/dist/components/overlays/modalSlots.js +1 -2
- package/dist/components/overlays/modalStack.js +1 -2
- package/dist/components/overlays/offcanvasCompanion.js +1 -2
- package/dist/components/overlays/offcanvasResize.js +0 -1
- package/dist/components/overlays/offcanvasSide.js +1 -2
- package/dist/components/overlays/offcanvasStack.js +1 -2
- package/dist/components/overlays/overlayPortal.js +1 -2
- package/dist/components/overlays/popoverLogic.js +1 -2
- package/dist/components/overlays/shortcutsHelpSlots.js +1 -2
- package/dist/components/overlays/splitModalLayout.js +1 -2
- package/dist/components/overlays/useExitPresence.js +11 -12
- package/dist/components/overlays/useNativeDialog.js +21 -22
- package/dist/components/overlays/viewportLogic.js +1 -2
- package/dist/components/renderSlot.js +1 -2
- package/dist/components/rootProps.js +1 -2
- package/dist/components/slotCatalog.js +33 -34
- package/dist/components/slotsLogic.js +1 -2
- package/dist/components/tone.js +1 -2
- package/dist/css/components/overlays/KapiViewport.css +1 -1
- package/dist/hooks/asyncResourceLogic.js +1 -2
- package/dist/hooks/breakpointOpenLogic.js +1 -2
- package/dist/hooks/colorLogic.js +1 -2
- package/dist/hooks/dateFormat.js +1 -2
- package/dist/hooks/densityLogic.js +1 -2
- package/dist/hooks/directionLogic.js +1 -2
- package/dist/hooks/downloadLogic.js +1 -2
- package/dist/hooks/elementSizeLogic.js +1 -2
- package/dist/hooks/fieldErrorsLogic.js +1 -2
- package/dist/hooks/focusLogic.js +2 -11
- package/dist/hooks/growOriginLogic.js +1 -2
- package/dist/hooks/hotkeyLogic.js +1 -2
- package/dist/hooks/hotkeyRegistry.js +1 -2
- package/dist/hooks/kapiRoot.js +2 -3
- package/dist/hooks/mergeRefs.js +1 -2
- package/dist/hooks/numberFormatLogic.js +1 -2
- package/dist/hooks/onlineStatusLogic.js +1 -2
- package/dist/hooks/ownerDocument.js +1 -2
- package/dist/hooks/persistentStateLogic.js +1 -2
- package/dist/hooks/portalRoot.js +1 -2
- package/dist/hooks/rafThrottle.js +1 -2
- package/dist/hooks/rangeSelectLogic.js +1 -2
- package/dist/hooks/recentLogic.js +1 -2
- package/dist/hooks/reducedMotion.js +8 -9
- package/dist/hooks/rightClick.js +10 -11
- package/dist/hooks/scrollCollapseLogic.js +1 -2
- package/dist/hooks/scrollEdgesLogic.js +1 -2
- package/dist/hooks/shallowStable.js +1 -2
- package/dist/hooks/slidingIndicatorLogic.js +1 -2
- package/dist/hooks/storageLogic.js +1 -2
- package/dist/hooks/themeColorsLogic.js +1 -2
- package/dist/hooks/themeContrastLogic.js +1 -2
- package/dist/hooks/themeDeriveLogic.js +0 -1
- package/dist/hooks/themeRadiiLogic.js +1 -2
- package/dist/hooks/themeScript.js +1 -2
- package/dist/hooks/toneFamilyLogic.js +1 -2
- package/dist/hooks/unsavedGuardLogic.js +1 -2
- package/dist/hooks/useAsyncLoader.js +1 -2
- package/dist/hooks/useAsyncResource.js +5 -6
- package/dist/hooks/useAsyncTasks.js +1 -2
- package/dist/hooks/useBottomBarInset.js +9 -10
- package/dist/hooks/useControllableState.js +1 -2
- package/dist/hooks/useDebouncedValue.js +1 -2
- package/dist/hooks/useDisclosure.js +1 -2
- package/dist/hooks/useDismiss.js +10 -11
- package/dist/hooks/useDragScroll.js +12 -13
- package/dist/hooks/useElementSize.js +1 -2
- package/dist/hooks/useFieldErrors.js +1 -2
- package/dist/hooks/useFocusReturn.js +1 -2
- package/dist/hooks/useFormReset.js +1 -2
- package/dist/hooks/useGlobalRightClick.js +1 -2
- package/dist/hooks/useGrowOrigin.js +1 -2
- package/dist/hooks/useHotkey.js +1 -2
- package/dist/hooks/useHydrated.js +1 -2
- package/dist/hooks/useKapiTheme.js +55 -56
- package/dist/hooks/useMediaQuery.js +1 -2
- package/dist/hooks/useObjectUrl.js +1 -2
- package/dist/hooks/useOnlineStatus.js +1 -2
- package/dist/hooks/useOutsidePress.js +1 -2
- package/dist/hooks/usePersistentState.js +9 -10
- package/dist/hooks/usePlacement.js +15 -16
- package/dist/hooks/useRangeSelect.js +2 -3
- package/dist/hooks/useRecent.js +6 -7
- package/dist/hooks/useScrollCollapse.js +1 -2
- package/dist/hooks/useScrollEdges.js +25 -26
- package/dist/hooks/useSlidingIndicator.js +19 -20
- package/dist/hooks/useSubmitDraft.js +1 -2
- package/dist/hooks/useToneFamilies.js +0 -1
- package/dist/hooks/useTypeahead.js +1 -2
- package/dist/hooks/useUnsavedGuard.js +5 -6
- package/dist/hooks/useVirtualList.js +1 -2
- package/dist/hooks/useWheelZoom.js +1 -2
- package/dist/hooks/viewportInsetLogic.js +1 -2
- package/dist/hooks/virtualListLogic.js +0 -1
- package/dist/hooks/wheelZoomLogic.js +1 -2
- package/dist/kapi.css +1 -1
- package/dist/kapi.layered.css +1 -1
- package/dist/logic.js +45 -45
- package/package.json +16 -16
|
@@ -1,37 +1,36 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import "#kapi-css/components/layout/KapiRail.css";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
3
|
+
import { initialsFrom as e } from "../display/avatarLogic.js";
|
|
4
|
+
import { KapiTooltip as t } from "../overlays/KapiTooltip.js";
|
|
5
|
+
import { useLabels as n } from "../locale/KapiLocaleProvider.js";
|
|
6
|
+
import { joinClasses as r } from "../rootProps.js";
|
|
7
|
+
import { DEFAULT_RAIL_LABELS as i } from "./KapiRail.js";
|
|
8
|
+
import { RailVariantContext as a } from "./railContext.js";
|
|
8
9
|
/* empty css */
|
|
9
|
-
import { DEFAULT_RAIL_LABELS as a } from "./KapiRail.js";
|
|
10
10
|
import { useContext as o } from "react";
|
|
11
11
|
import { jsx as s, jsxs as c } from "react/jsx-runtime";
|
|
12
|
-
|
|
12
|
+
// src/components/layout/KapiRailAccount.tsx
|
|
13
13
|
var l = ({ user: l, label: u, avatar: d, open: f = !1, labels: p, className: m, ref: h, ...g }) => {
|
|
14
|
-
let _ =
|
|
14
|
+
let _ = n("rail", i, p), v = o(a) === "compact", y = u ?? _.account, b = /* @__PURE__ */ c("button", {
|
|
15
15
|
...g,
|
|
16
16
|
ref: h,
|
|
17
17
|
type: "button",
|
|
18
|
-
className:
|
|
18
|
+
className: r("kapi-rail__item kapi-rail__item--account", m),
|
|
19
19
|
"aria-haspopup": "menu",
|
|
20
20
|
"aria-expanded": f,
|
|
21
21
|
"aria-label": v ? g["aria-label"] ?? y : g["aria-label"],
|
|
22
22
|
children: [/* @__PURE__ */ s("span", {
|
|
23
23
|
className: "kapi-rail__avatar",
|
|
24
24
|
"aria-hidden": "true",
|
|
25
|
-
children: d ?? l.initials ??
|
|
25
|
+
children: d ?? l.initials ?? e(l.name)
|
|
26
26
|
}), !v && /* @__PURE__ */ s("span", {
|
|
27
27
|
className: "kapi-rail__label",
|
|
28
28
|
children: y
|
|
29
29
|
})]
|
|
30
30
|
});
|
|
31
|
-
return v ? /* @__PURE__ */ s(
|
|
31
|
+
return v ? /* @__PURE__ */ s(t, {
|
|
32
32
|
label: y,
|
|
33
33
|
children: b
|
|
34
34
|
}) : b;
|
|
35
35
|
};
|
|
36
|
-
//#endregion
|
|
37
36
|
export { l as KapiRailAccount };
|
|
@@ -1,27 +1,27 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import "#kapi-css/components/layout/KapiRoot.css";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
3
|
+
import { useMergedRefs as e } from "../../hooks/mergeRefs.js";
|
|
4
|
+
import { KapiPortalRootProvider as t, usePortalRootOverride as n } from "../../hooks/portalRoot.js";
|
|
5
|
+
import { KapiThemeContext as r, themeRootStyle as i, useKapiThemeState as a } from "../../hooks/useKapiTheme.js";
|
|
6
|
+
import { densityAttribute as o } from "../../hooks/densityLogic.js";
|
|
7
|
+
import { ToneFamilyNamesContext as s, useToneFamilyProblemWarning as c, useToneFamilyRegistry as l } from "../../hooks/useToneFamilies.js";
|
|
8
|
+
import { useKapiDir as u } from "../locale/KapiLocaleProvider.js";
|
|
9
|
+
import { joinClasses as d } from "../rootProps.js";
|
|
10
10
|
/* empty css */
|
|
11
11
|
import { createContext as f, useContext as p, useMemo as m, useState as h } from "react";
|
|
12
12
|
import { jsx as g } from "react/jsx-runtime";
|
|
13
|
-
|
|
14
|
-
var _ = f(null), v = ({ storageNamespace:
|
|
15
|
-
let y =
|
|
16
|
-
namespace:
|
|
13
|
+
// src/components/layout/KapiRoot.tsx
|
|
14
|
+
var _ = f(null), v = ({ storageNamespace: t, brandTheme: r, toneFamilies: s, density: d, theme: f, style: g, ref: v }) => {
|
|
15
|
+
let y = a({
|
|
16
|
+
namespace: t,
|
|
17
17
|
theme: f
|
|
18
|
-
}), b =
|
|
18
|
+
}), b = u(), x = m(() => i(y, r, s), [
|
|
19
19
|
y,
|
|
20
20
|
r,
|
|
21
|
-
|
|
22
|
-
]), { names: S, problems: C } =
|
|
23
|
-
|
|
24
|
-
let [w, T] = h(null), E =
|
|
21
|
+
s
|
|
22
|
+
]), { names: S, problems: C } = l(s);
|
|
23
|
+
c(C);
|
|
24
|
+
let [w, T] = h(null), E = e(T, v), D = n(), O = p(_), k = D && D !== O ? D : w;
|
|
25
25
|
return {
|
|
26
26
|
themeState: y,
|
|
27
27
|
toneNames: S,
|
|
@@ -31,7 +31,7 @@ var _ = f(null), v = ({ storageNamespace: e, brandTheme: r, toneFamilies: o, den
|
|
|
31
31
|
"data-theme": y.theme,
|
|
32
32
|
"data-heading-font": "--kapi-font-heading" in x ? "" : void 0,
|
|
33
33
|
"data-motion": y.motion === "reduced" ? "reduced" : void 0,
|
|
34
|
-
"data-density": d
|
|
34
|
+
"data-density": o(d),
|
|
35
35
|
style: {
|
|
36
36
|
...g,
|
|
37
37
|
...x
|
|
@@ -41,38 +41,37 @@ var _ = f(null), v = ({ storageNamespace: e, brandTheme: r, toneFamilies: o, den
|
|
|
41
41
|
element: w,
|
|
42
42
|
portalRoot: k
|
|
43
43
|
};
|
|
44
|
-
}, y = ({ wiring:
|
|
45
|
-
value:
|
|
46
|
-
children: /* @__PURE__ */ g(
|
|
47
|
-
value:
|
|
44
|
+
}, y = ({ wiring: e, children: n }) => /* @__PURE__ */ g(r.Provider, {
|
|
45
|
+
value: e.themeState,
|
|
46
|
+
children: /* @__PURE__ */ g(s.Provider, {
|
|
47
|
+
value: e.toneNames,
|
|
48
48
|
children: /* @__PURE__ */ g(_.Provider, {
|
|
49
|
-
value:
|
|
50
|
-
children: /* @__PURE__ */ g(
|
|
51
|
-
root:
|
|
49
|
+
value: e.element,
|
|
50
|
+
children: /* @__PURE__ */ g(t, {
|
|
51
|
+
root: e.portalRoot,
|
|
52
52
|
children: n
|
|
53
53
|
})
|
|
54
54
|
})
|
|
55
55
|
})
|
|
56
|
-
}), b = ({ children: e, className: t, storageNamespace: n, brandTheme:
|
|
56
|
+
}), b = ({ children: e, className: t, storageNamespace: n, brandTheme: r, toneFamilies: i, density: a, theme: o, style: s, ref: c, fullscreen: l = !1, ...u }) => {
|
|
57
57
|
let f = v({
|
|
58
58
|
storageNamespace: n,
|
|
59
|
-
brandTheme:
|
|
60
|
-
toneFamilies:
|
|
61
|
-
density:
|
|
62
|
-
theme:
|
|
63
|
-
style:
|
|
64
|
-
ref:
|
|
59
|
+
brandTheme: r,
|
|
60
|
+
toneFamilies: i,
|
|
61
|
+
density: a,
|
|
62
|
+
theme: o,
|
|
63
|
+
style: s,
|
|
64
|
+
ref: c
|
|
65
65
|
});
|
|
66
66
|
return /* @__PURE__ */ g(y, {
|
|
67
67
|
wiring: f,
|
|
68
68
|
children: /* @__PURE__ */ g("div", {
|
|
69
69
|
...f.dir ? { dir: f.dir } : {},
|
|
70
|
-
...
|
|
71
|
-
className:
|
|
70
|
+
...u,
|
|
71
|
+
className: d("kapi", l ? "kapi--app" : "kapi--embed", t),
|
|
72
72
|
...f.attrs,
|
|
73
73
|
children: e
|
|
74
74
|
})
|
|
75
75
|
});
|
|
76
76
|
};
|
|
77
|
-
//#endregion
|
|
78
77
|
export { b as KapiRoot, y as KapiRootScope, v as useKapiRootWiring };
|
|
@@ -1,29 +1,29 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import "#kapi-css/components/layout/KapiScrollArea.css";
|
|
3
|
-
import { joinClasses as e } from "../rootProps.js";
|
|
4
|
-
import { useLabels as t } from "../locale/KapiLocaleProvider.js";
|
|
5
|
-
import { useScrollEdges as n } from "../../hooks/useScrollEdges.js";
|
|
6
3
|
/* empty css */
|
|
4
|
+
import { useScrollEdges as e } from "../../hooks/useScrollEdges.js";
|
|
5
|
+
import { useLabels as t } from "../locale/KapiLocaleProvider.js";
|
|
6
|
+
import { joinClasses as n } from "../rootProps.js";
|
|
7
7
|
import { useCallback as r } from "react";
|
|
8
8
|
import { jsx as i, jsxs as a } from "react/jsx-runtime";
|
|
9
|
-
|
|
9
|
+
// src/components/layout/KapiScrollArea.tsx
|
|
10
10
|
var o = {
|
|
11
11
|
previous: "Ver contenido anterior",
|
|
12
12
|
next: "Ver contenido siguiente"
|
|
13
13
|
};
|
|
14
14
|
function s({ children: s, axis: c = "x", fade: l = !0, paging: u = !0, className: d, viewportRef: f, ref: p, labels: m, ...h }) {
|
|
15
|
-
let g = t("scrollArea", o, m), { ref: _, edges: v, scrollByPage: y } =
|
|
15
|
+
let g = t("scrollArea", o, m), { ref: _, edges: v, scrollByPage: y } = e({ axis: c }), b = r((e) => {
|
|
16
16
|
_.current = e, typeof f == "function" ? f(e) : f && (f.current = e);
|
|
17
17
|
}, [_, f]);
|
|
18
18
|
return /* @__PURE__ */ a("div", {
|
|
19
19
|
...h,
|
|
20
20
|
ref: p,
|
|
21
|
-
className:
|
|
21
|
+
className: n("kapi-scroll-area", d),
|
|
22
22
|
"data-axis": c,
|
|
23
23
|
children: [
|
|
24
24
|
/* @__PURE__ */ i("div", {
|
|
25
25
|
ref: b,
|
|
26
|
-
className:
|
|
26
|
+
className: n("kapi-scroll-area__viewport", l && `kapi-fade-${c}`),
|
|
27
27
|
"data-edge-start": v.start ? "" : void 0,
|
|
28
28
|
"data-edge-end": v.end ? "" : void 0,
|
|
29
29
|
tabIndex: 0,
|
|
@@ -46,5 +46,4 @@ function s({ children: s, axis: c = "x", fade: l = !0, paging: u = !0, className
|
|
|
46
46
|
]
|
|
47
47
|
});
|
|
48
48
|
}
|
|
49
|
-
//#endregion
|
|
50
49
|
export { o as DEFAULT_SCROLL_AREA_LABELS, s as KapiScrollArea };
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import "#kapi-css/components/navigation/navigation.css";
|
|
3
|
-
import {
|
|
3
|
+
import { useGlobalRightClick as e } from "../../hooks/useGlobalRightClick.js";
|
|
4
4
|
import { KapiContextMenu as t } from "../overlays/KapiContextMenu.js";
|
|
5
|
-
|
|
6
|
-
import { useGlobalRightClick as n } from "../../hooks/useGlobalRightClick.js";
|
|
5
|
+
import { slot as n } from "../slotsLogic.js";
|
|
7
6
|
import { SHELL_SLOTS as r } from "./shellSlots.js";
|
|
8
7
|
import { KapiRootScope as i, useKapiRootWiring as a } from "./KapiRoot.js";
|
|
9
8
|
import { KapiReopenContext as o } from "./reopenBus.js";
|
|
9
|
+
/* empty css */
|
|
10
10
|
import { useCallback as s, useMemo as c, useState as l } from "react";
|
|
11
11
|
import { jsx as u, jsxs as d } from "react/jsx-runtime";
|
|
12
12
|
import { ChevronsLeft as f, ChevronsRight as p } from "lucide-react";
|
|
13
|
-
|
|
13
|
+
// src/components/layout/KapiShell.tsx
|
|
14
14
|
var m = ({ rail: m, panel: h, panelRight: g, children: _, contextMenuItems: v, rightClick: y = !0, overlays: b, className: x, classNames: S, contentClassName: C = "", storageNamespace: w, brandTheme: T, toneFamilies: E, density: D, theme: O, style: k, ref: A, ...j }) => {
|
|
15
15
|
let M = a({
|
|
16
16
|
storageNamespace: w,
|
|
@@ -21,7 +21,7 @@ var m = ({ rail: m, panel: h, panelRight: g, children: _, contextMenuItems: v, r
|
|
|
21
21
|
style: k,
|
|
22
22
|
ref: A
|
|
23
23
|
}), [N, P] = l(null);
|
|
24
|
-
|
|
24
|
+
e({
|
|
25
25
|
enabled: y,
|
|
26
26
|
onMenu: v?.length ? (e, t) => P({
|
|
27
27
|
x: e,
|
|
@@ -45,17 +45,17 @@ var m = ({ rail: m, panel: h, panelRight: g, children: _, contextMenuItems: v, r
|
|
|
45
45
|
children: /* @__PURE__ */ d("div", {
|
|
46
46
|
...M.dir ? { dir: M.dir } : {},
|
|
47
47
|
...j,
|
|
48
|
-
...
|
|
48
|
+
...n(r, "root", S, x),
|
|
49
49
|
...M.attrs,
|
|
50
50
|
children: [
|
|
51
51
|
m,
|
|
52
52
|
h,
|
|
53
53
|
/* @__PURE__ */ d("main", {
|
|
54
|
-
...
|
|
54
|
+
...n(r, "content", S, C),
|
|
55
55
|
tabIndex: 0,
|
|
56
56
|
children: [F && L === 0 && /* @__PURE__ */ u("button", {
|
|
57
57
|
type: "button",
|
|
58
|
-
...
|
|
58
|
+
...n(r, "reopen", S, "kapi-paneltoggle"),
|
|
59
59
|
onClick: F.expand,
|
|
60
60
|
"aria-label": F.label,
|
|
61
61
|
children: F.side === "right" ? /* @__PURE__ */ u(f, {
|
|
@@ -85,5 +85,4 @@ var m = ({ rail: m, panel: h, panelRight: g, children: _, contextMenuItems: v, r
|
|
|
85
85
|
})
|
|
86
86
|
});
|
|
87
87
|
};
|
|
88
|
-
//#endregion
|
|
89
88
|
export { m as KapiShell };
|
|
@@ -3,7 +3,7 @@ import "#kapi-css/components/layout/layout-primitives.css";
|
|
|
3
3
|
import { stackProps as e } from "./layoutPrimitives.js";
|
|
4
4
|
/* empty css */
|
|
5
5
|
import { jsx as t } from "react/jsx-runtime";
|
|
6
|
-
|
|
6
|
+
// src/components/layout/KapiStack.tsx
|
|
7
7
|
function n({ gap: n, align: r, fill: i, className: a, style: o, children: s, ...c }) {
|
|
8
8
|
return /* @__PURE__ */ t("div", {
|
|
9
9
|
...c,
|
|
@@ -17,5 +17,4 @@ function n({ gap: n, align: r, fill: i, className: a, style: o, children: s, ...
|
|
|
17
17
|
children: s
|
|
18
18
|
});
|
|
19
19
|
}
|
|
20
|
-
//#endregion
|
|
21
20
|
export { n as KapiStack };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { kapiThemeScript as e } from "../../hooks/themeScript.js";
|
|
3
3
|
import { jsx as t } from "react/jsx-runtime";
|
|
4
|
-
|
|
4
|
+
// src/components/layout/KapiThemeScript.tsx
|
|
5
5
|
var n = ({ namespace: n, nonce: r, id: i, ref: a }) => /* @__PURE__ */ t("script", {
|
|
6
6
|
ref: a,
|
|
7
7
|
...i === void 0 ? {} : { id: i },
|
|
@@ -9,5 +9,4 @@ var n = ({ namespace: n, nonce: r, id: i, ref: a }) => /* @__PURE__ */ t("script
|
|
|
9
9
|
suppressHydrationWarning: !0,
|
|
10
10
|
dangerouslySetInnerHTML: { __html: e({ namespace: n }) }
|
|
11
11
|
});
|
|
12
|
-
//#endregion
|
|
13
12
|
export { n as KapiThemeScript };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { isFamilyTone as e } from "../tone.js";
|
|
2
|
-
|
|
2
|
+
// src/components/layout/accessCardLogic.ts
|
|
3
3
|
var t = (e) => e ? "external" : "chevron", n = (e) => {
|
|
4
4
|
let t = {};
|
|
5
5
|
return e.newTab && (t.target = "_blank"), (e.newTab || e.external) && (t.rel = "noopener noreferrer"), t;
|
|
@@ -11,5 +11,4 @@ var t = (e) => e ? "external" : "chevron", n = (e) => {
|
|
|
11
11
|
t.className
|
|
12
12
|
].filter(Boolean).join(" ");
|
|
13
13
|
}, i = (e) => e === "Enter" || e === " ";
|
|
14
|
-
//#endregion
|
|
15
14
|
export { t as accessCardAffordance, r as accessCardClasses, i as isActivationKey, n as linkAttrs };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
// src/components/layout/cardLogic.ts
|
|
2
2
|
var e = ({ flush: e = !1, responsive: t = !1, interactive: n = !1, className: r = "" } = {}) => [
|
|
3
3
|
"kapi-card",
|
|
4
4
|
"kapi-panelcard",
|
|
@@ -7,5 +7,4 @@ var e = ({ flush: e = !1, responsive: t = !1, interactive: n = !1, className: r
|
|
|
7
7
|
n && "kapi-card--interactive",
|
|
8
8
|
r
|
|
9
9
|
].filter(Boolean).join(" "), t = (e) => e != null && e !== !1 && e !== "", n = (e, n) => t(e) || t(n);
|
|
10
|
-
//#endregion
|
|
11
10
|
export { e as cardClasses, n as hasCardHeader };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { defineSlots as e } from "../slotsLogic.js";
|
|
2
|
-
|
|
2
|
+
// src/components/layout/cardSlots.ts
|
|
3
3
|
var t = e("card", {
|
|
4
4
|
root: "kapi-card",
|
|
5
5
|
header: "kapi-panelcard__head",
|
|
@@ -8,5 +8,4 @@ var t = e("card", {
|
|
|
8
8
|
body: "kapi-card__body",
|
|
9
9
|
footer: "kapi-card__foot"
|
|
10
10
|
});
|
|
11
|
-
//#endregion
|
|
12
11
|
export { t as CARD_SLOTS };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { gapValue as e } from "./layoutPrimitives.js";
|
|
2
|
-
|
|
2
|
+
// src/components/layout/gridSpanLogic.ts
|
|
3
3
|
var t = [
|
|
4
4
|
"xs",
|
|
5
5
|
"sm",
|
|
@@ -35,5 +35,4 @@ var t = [
|
|
|
35
35
|
for (let [e, t] of Object.entries(i(n))) t === "first" ? a[`--kapi-col-order-${e}`] = -1 : t === "last" ? a[`--kapi-col-order-${e}`] = l : r(t) && (a[`--kapi-col-order-${e}`] = Math.trunc(t));
|
|
36
36
|
return a;
|
|
37
37
|
};
|
|
38
|
-
//#endregion
|
|
39
38
|
export { n as DEFAULT_BREAKPOINTS, t as KAPI_BREAKPOINTS, o as activeBreakpoint, u as colStyle, c as gridSpanStyle, s as normalizeColumns, a as resolveBreakpoints, i as toBreakpointMap };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
// src/components/layout/layoutPrimitives.ts
|
|
2
2
|
var e = {
|
|
3
3
|
start: "flex-start",
|
|
4
4
|
center: "center",
|
|
@@ -65,5 +65,4 @@ var e = {
|
|
|
65
65
|
...a
|
|
66
66
|
};
|
|
67
67
|
};
|
|
68
|
-
//#endregion
|
|
69
68
|
export { l as boxStyle, o as clusterProps, n as gapValue, s as gridColumns, c as gridProps, a as stackProps };
|
|
@@ -1,8 +1,7 @@
|
|
|
1
|
-
|
|
1
|
+
// src/components/layout/masonryLogic.ts
|
|
2
2
|
var e = ({ height: e, rowUnit: t, gap: n }) => [
|
|
3
3
|
e,
|
|
4
4
|
t,
|
|
5
5
|
n
|
|
6
6
|
].every(Number.isFinite) && e > 0 && t > 0 && n >= 0 ? Math.max(1, Math.ceil((e + n) / t)) : 1;
|
|
7
|
-
//#endregion
|
|
8
7
|
export { e as masonrySpan };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { isoDateTime as e } from "../../hooks/dateFormat.js";
|
|
2
|
-
|
|
2
|
+
// src/components/layout/notificationBellLogic.ts
|
|
3
3
|
var t = {
|
|
4
4
|
side: "bottom",
|
|
5
5
|
align: "end",
|
|
@@ -10,5 +10,4 @@ var t = {
|
|
|
10
10
|
let n = Math.floor(e);
|
|
11
11
|
return n <= 0 ? "" : n > t ? `${t}+` : String(n);
|
|
12
12
|
}, i = (e, t, n) => t > 0 ? `${e}, ${t} ${n}` : e, a = e;
|
|
13
|
-
//#endregion
|
|
14
13
|
export { t as NOTIFICATION_BELL_PLACEMENT, r as badgeText, i as bellTriggerLabel, a as notificationDateTime, n as unreadCount };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
// src/components/layout/pageHeaderLogic.ts
|
|
2
2
|
var e = (e) => Number.isFinite(e) && e > 0 ? e : 0, t = (t, n) => Math.max(0, e(t) - e(n)), n = (n, r) => {
|
|
3
3
|
let i = e(n.expanded), a = e(n.collapsed);
|
|
4
4
|
if (i <= 0 || a <= 0) return {
|
|
@@ -14,5 +14,4 @@ var e = (e) => Number.isFinite(e) && e > 0 ? e : 0, t = (t, n) => Math.max(0, e(
|
|
|
14
14
|
reserve: 0
|
|
15
15
|
};
|
|
16
16
|
};
|
|
17
|
-
//#endregion
|
|
18
17
|
export { n as pageHeaderBox, t as pageHeaderSpacerHeight };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { defineSlots as e } from "../slotsLogic.js";
|
|
2
|
-
|
|
2
|
+
// src/components/layout/pageHeaderSlots.ts
|
|
3
3
|
var t = e("pageheader", {
|
|
4
4
|
root: "kapi-pageheader",
|
|
5
5
|
reopen: "kapi-pageheader__reopen",
|
|
@@ -11,5 +11,4 @@ var t = e("pageheader", {
|
|
|
11
11
|
meta: "kapi-pageheader__meta",
|
|
12
12
|
actions: "kapi-pageheader__actions"
|
|
13
13
|
});
|
|
14
|
-
//#endregion
|
|
15
14
|
export { t as PAGEHEADER_SLOTS };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { navBadgeView as e } from "../navigation/navBadgeLogic.js";
|
|
2
|
-
|
|
2
|
+
// src/components/layout/railLogic.ts
|
|
3
3
|
var t = (e) => "separator" in e && e.separator === !0, n = (e) => {
|
|
4
4
|
let t = {
|
|
5
5
|
start: [],
|
|
@@ -44,5 +44,4 @@ var t = (e) => "separator" in e && e.separator === !0, n = (e) => {
|
|
|
44
44
|
current: n === void 0 ? void 0 : t.find((e) => e.id === n),
|
|
45
45
|
notice: t.find((t) => e(t.badge) !== null)
|
|
46
46
|
});
|
|
47
|
-
//#endregion
|
|
48
47
|
export { t as isRailSeparator, r as railClasses, i as railItemClasses, o as railOverflowCounts, c as railOverflowState, a as railShowsTooltip, n as splitRailEntries, s as splitRailOverflow };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { defineSlots as e } from "../slotsLogic.js";
|
|
2
|
-
|
|
2
|
+
// src/components/layout/railSlots.ts
|
|
3
3
|
var t = e("rail", {
|
|
4
4
|
root: "kapi-rail",
|
|
5
5
|
brand: "kapi-rail__brand",
|
|
@@ -11,5 +11,4 @@ var t = e("rail", {
|
|
|
11
11
|
separator: "kapi-rail__sep",
|
|
12
12
|
end: "kapi-rail__end"
|
|
13
13
|
});
|
|
14
|
-
//#endregion
|
|
15
14
|
export { t as RAIL_SLOTS };
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { createContext as e, useContext as t } from "react";
|
|
3
|
-
|
|
3
|
+
// src/components/layout/reopenBus.ts
|
|
4
4
|
var n = e(null), r = () => t(n);
|
|
5
|
-
//#endregion
|
|
6
5
|
export { n as KapiReopenContext, r as useReopenBus };
|
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
import { defineSlots as e } from "../slotsLogic.js";
|
|
2
|
-
|
|
2
|
+
// src/components/layout/shellSlots.ts
|
|
3
3
|
var t = e("shell", {
|
|
4
4
|
root: "kapi",
|
|
5
5
|
content: "kapi-content",
|
|
6
6
|
reopen: "kapi-content__reopen"
|
|
7
7
|
});
|
|
8
|
-
//#endregion
|
|
9
8
|
export { t as SHELL_SLOTS };
|
|
@@ -3,7 +3,7 @@ import { winOf as e } from "../../hooks/ownerDocument.js";
|
|
|
3
3
|
import { onViewportChange as t } from "../../hooks/rafThrottle.js";
|
|
4
4
|
import { activeBreakpoint as n, resolveBreakpoints as r } from "./gridSpanLogic.js";
|
|
5
5
|
import { useLayoutEffect as i, useMemo as a, useState as o } from "react";
|
|
6
|
-
|
|
6
|
+
// src/components/layout/useGridBreakpoint.ts
|
|
7
7
|
var s = (s, c, l = !1) => {
|
|
8
8
|
let [u, d] = o(void 0), f = c !== void 0, p = f ? JSON.stringify(c) : "", m = a(() => f ? r(JSON.parse(p)) : void 0, [f, p]);
|
|
9
9
|
return i(() => {
|
|
@@ -31,5 +31,4 @@ var s = (s, c, l = !1) => {
|
|
|
31
31
|
l
|
|
32
32
|
]), f ? u : void 0;
|
|
33
33
|
};
|
|
34
|
-
//#endregion
|
|
35
34
|
export { s as useGridBreakpoint };
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
2
|
+
import { masonrySpan as e } from "./masonryLogic.js";
|
|
3
|
+
import { computedStyleOf as t } from "../../hooks/ownerDocument.js";
|
|
4
4
|
import { useCallback as n, useLayoutEffect as r, useRef as i, useState as a } from "react";
|
|
5
|
-
|
|
5
|
+
// src/components/layout/useMasonrySpans.ts
|
|
6
6
|
var o = {
|
|
7
7
|
spans: [],
|
|
8
8
|
measured: !1
|
|
9
9
|
}, s = (e, t) => e.measured === t.measured && e.spans.length === t.spans.length && e.spans.every((e, n) => e === t.spans[n]), c = ({ rowUnit: c, watch: l }) => {
|
|
10
10
|
let [u, d] = a(o), f = i(/* @__PURE__ */ new Map()), p = i(null), m = i(/* @__PURE__ */ new Map()), h = n(() => {
|
|
11
|
-
let n = [...f.current.entries()], r = n[0]?.[1], i = r ? Number.parseFloat(
|
|
12
|
-
for (let [
|
|
11
|
+
let n = [...f.current.entries()], r = n[0]?.[1], i = r ? Number.parseFloat(t(r).marginBottom) : NaN, a = [], o = !1;
|
|
12
|
+
for (let [t, r] of n) {
|
|
13
13
|
let n = r.getBoundingClientRect().height;
|
|
14
|
-
n > 0 && (o = !0), a[
|
|
14
|
+
n > 0 && (o = !0), a[t] = e({
|
|
15
15
|
height: n,
|
|
16
16
|
rowUnit: c,
|
|
17
17
|
gap: i
|
|
@@ -41,5 +41,4 @@ var o = {
|
|
|
41
41
|
register: g
|
|
42
42
|
};
|
|
43
43
|
};
|
|
44
|
-
//#endregion
|
|
45
44
|
export { c as useMasonrySpans };
|
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
2
|
+
import { railOverflowCounts as e } from "./railLogic.js";
|
|
3
|
+
import { computedStyleOf as t } from "../../hooks/ownerDocument.js";
|
|
4
4
|
import { useCallback as n, useLayoutEffect as r, useRef as i, useState as a } from "react";
|
|
5
|
-
|
|
5
|
+
// src/components/layout/useRailOverflow.ts
|
|
6
6
|
var o = (e) => Number.parseFloat(e), s = (s, { enabled: c, count: l, separators: u }) => {
|
|
7
7
|
let [d, f] = a(null), p = i(0), m = n(() => {
|
|
8
8
|
let n = s.current;
|
|
9
9
|
if (!n || !c) return;
|
|
10
|
-
let r =
|
|
10
|
+
let r = t(n), i = o(r.columnGap), a = Number.isFinite(i) ? i : 0, d = n.querySelector(".kapi-rail__sep");
|
|
11
11
|
if (d) {
|
|
12
|
-
let
|
|
12
|
+
let e = t(d), n = (o(e.marginLeft) || 0) + (o(e.marginRight) || 0);
|
|
13
13
|
p.current = d.offsetWidth + n + a;
|
|
14
14
|
}
|
|
15
|
-
let m = n.querySelector(".kapi-rail__item"), { visible: h } =
|
|
15
|
+
let m = n.querySelector(".kapi-rail__item"), { visible: h } = e({
|
|
16
16
|
available: n.clientWidth - (o(r.paddingLeft) || 0) - (o(r.paddingRight) || 0),
|
|
17
|
-
itemWidth: m ? o(
|
|
17
|
+
itemWidth: m ? o(t(m).minWidth) : NaN,
|
|
18
18
|
gap: a,
|
|
19
19
|
count: l,
|
|
20
20
|
reserved: u * p.current
|
|
@@ -38,5 +38,4 @@ var o = (e) => Number.parseFloat(e), s = (s, { enabled: c, count: l, separators:
|
|
|
38
38
|
c
|
|
39
39
|
]), c ? d : null;
|
|
40
40
|
};
|
|
41
|
-
//#endregion
|
|
42
41
|
export { s as useRailOverflow };
|
|
@@ -3,7 +3,7 @@ import { withLabels as e } from "../labelsLogic.js";
|
|
|
3
3
|
import { isWeekday as t, resolveFormatLocale as n, weekStartForLocale as r } from "./localeLogic.js";
|
|
4
4
|
import { createContext as i, useContext as a, useMemo as o } from "react";
|
|
5
5
|
import { jsx as s } from "react/jsx-runtime";
|
|
6
|
-
|
|
6
|
+
// src/components/locale/KapiLocaleProvider.tsx
|
|
7
7
|
var c = i(null), l = {};
|
|
8
8
|
function u({ locale: e, labels: t = l, weekStartsOn: n, dir: r, children: i }) {
|
|
9
9
|
let a = o(() => ({
|
|
@@ -34,5 +34,4 @@ function h(t, n, r) {
|
|
|
34
34
|
r
|
|
35
35
|
]);
|
|
36
36
|
}
|
|
37
|
-
//#endregion
|
|
38
37
|
export { u as KapiLocaleProvider, m as useKapiDir, f as useKapiFormatLocale, d as useKapiLocale, p as useKapiWeekStart, h as useLabels };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
// src/components/locale/localeLogic.ts
|
|
2
2
|
var e = "es", t = 1, n = /* @__PURE__ */ new Map(), r = (e) => {
|
|
3
3
|
if (!e) return "es";
|
|
4
4
|
let t = n.get(e);
|
|
@@ -26,5 +26,4 @@ var e = "es", t = 1, n = /* @__PURE__ */ new Map(), r = (e) => {
|
|
|
26
26
|
}
|
|
27
27
|
return t;
|
|
28
28
|
}, o = (e) => typeof e == "number" && Number.isInteger(e) && e >= 0 && e <= 6;
|
|
29
|
-
//#endregion
|
|
30
29
|
export { e as DEFAULT_KAPI_LOCALE, t as DEFAULT_WEEK_START, o as isWeekday, r as resolveFormatLocale, a as weekStartForLocale };
|
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
2
|
+
import { useMergedRefs as e } from "../../hooks/mergeRefs.js";
|
|
3
|
+
import { useSlidingIndicator as t } from "../../hooks/useSlidingIndicator.js";
|
|
4
|
+
import { joinClasses as n } from "../rootProps.js";
|
|
5
5
|
import { jsx as r, jsxs as i } from "react/jsx-runtime";
|
|
6
|
-
|
|
6
|
+
// src/components/navigation/CtxSlidingList.tsx
|
|
7
7
|
var a = ({ active: a = null, children: o, className: s, ref: c, ...l }) => {
|
|
8
|
-
let { containerRef: u, indicatorRef: d } =
|
|
8
|
+
let { containerRef: u, indicatorRef: d } = t({
|
|
9
9
|
active: a,
|
|
10
10
|
deps: [a, o],
|
|
11
11
|
findActive: (e) => e.querySelector("[aria-current=\"page\"]")
|
|
12
|
-
}), f =
|
|
12
|
+
}), f = e(u, c);
|
|
13
13
|
return /* @__PURE__ */ i("div", {
|
|
14
14
|
...l,
|
|
15
15
|
ref: f,
|
|
16
|
-
className:
|
|
16
|
+
className: n("kapi-ctxlist", s),
|
|
17
17
|
children: [/* @__PURE__ */ r("span", {
|
|
18
18
|
ref: d,
|
|
19
19
|
className: "kapi-ctxlist__indicator",
|
|
@@ -21,5 +21,4 @@ var a = ({ active: a = null, children: o, className: s, ref: c, ...l }) => {
|
|
|
21
21
|
}), o]
|
|
22
22
|
});
|
|
23
23
|
};
|
|
24
|
-
//#endregion
|
|
25
24
|
export { a as CtxSlidingList };
|