sellmate-design-system-react 9.0.0-beta.11 → 9.0.0-beta.112
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/AGENTS.md +4231 -304
- package/README.md +85 -37
- package/bin/sellmate-ds.mjs +91 -59
- package/dist/components/SAccountListBox/AccountListBoxPortal.d.ts +31 -0
- package/dist/components/SAccountListBox/README.md +86 -0
- package/dist/components/SAccountListBox/SAccountListBox.d.ts +79 -0
- package/dist/components/SAccountListBox/SystemMenuPortal.d.ts +58 -0
- package/dist/components/SAccountListBox/accountListBox.config.d.ts +67 -0
- package/dist/components/SAccountListBox/index.d.ts +2 -0
- package/dist/components/SActionModal/README.md +6 -4
- package/dist/components/SActionModal/SActionModal.d.ts +16 -6
- package/dist/components/SBadge/README.md +3 -0
- package/dist/components/SBadge/SBadge.d.ts +2 -2
- package/dist/components/SBarChart/README.md +123 -0
- package/dist/components/SBarChart/SBarChart.d.ts +106 -0
- package/dist/components/SBarChart/barChart.config.d.ts +85 -0
- package/dist/components/SBarChart/index.d.ts +2 -0
- package/dist/components/SBarcodeInput/README.md +10 -6
- package/dist/components/SBarcodeInput/SBarcodeInput.d.ts +28 -5
- package/dist/components/SButton/README.md +50 -11
- package/dist/components/SButton/SButton.d.ts +30 -7
- package/dist/components/SButton/button.config.d.ts +22 -13
- package/dist/components/SButton/index.d.ts +1 -1
- package/dist/components/SCalendar/README.md +2 -2
- package/dist/components/SCalendar/SCalendar.d.ts +3 -3
- package/dist/components/SCalendarBoard/CalendarDayCard.d.ts +61 -0
- package/dist/components/SCalendarBoard/CalendarDayEventListBox.d.ts +26 -0
- package/dist/components/SCalendarBoard/CalendarEventButton.d.ts +20 -0
- package/dist/components/SCalendarBoard/CalendarMoreButton.d.ts +18 -0
- package/dist/components/SCalendarBoard/README.md +148 -0
- package/dist/components/SCalendarBoard/SCalendarBoard.d.ts +83 -0
- package/dist/components/SCalendarBoard/calendar-board-layout.d.ts +59 -0
- package/dist/components/SCalendarBoard/calendarBoard.config.d.ts +38 -0
- package/dist/components/SCalendarBoard/index.d.ts +3 -0
- package/dist/components/SCalendarBoard/types.d.ts +40 -0
- package/dist/components/SCallout/README.md +3 -2
- package/dist/components/SCallout/SCallout.d.ts +15 -6
- package/dist/components/SCard/README.md +17 -0
- package/dist/components/SCard/SCard.d.ts +26 -2
- package/dist/components/SChatAttachedFile/README.md +33 -0
- package/dist/components/SChatAttachedFile/SChatAttachedFile.d.ts +13 -0
- package/dist/components/SChatAttachedFile/chatAttachedFile.config.d.ts +23 -0
- package/dist/components/SChatAttachedFile/index.d.ts +2 -0
- package/dist/components/SChatFile/README.md +33 -0
- package/dist/components/SChatFile/SChatFile.d.ts +37 -0
- package/dist/components/SChatFile/chatFile.config.d.ts +56 -0
- package/dist/components/SChatFile/index.d.ts +2 -0
- package/dist/components/SChatInput/README.md +52 -0
- package/dist/components/SChatInput/SChatInput.d.ts +127 -0
- package/dist/components/SChatInput/index.d.ts +1 -0
- package/dist/components/SChatMessage/README.md +87 -0
- package/dist/components/SChatMessage/SChatMessage.d.ts +135 -0
- package/dist/components/SChatMessage/index.d.ts +1 -0
- package/dist/components/SChatSystemMessage/README.md +12 -0
- package/dist/components/SChatSystemMessage/SChatSystemMessage.d.ts +18 -0
- package/dist/components/SChatSystemMessage/index.d.ts +1 -0
- package/dist/components/SCheckbox/README.md +4 -1
- package/dist/components/SCheckbox/SCheckbox.d.ts +11 -3
- package/dist/components/SChip/README.md +29 -4
- package/dist/components/SChip/SChip.d.ts +13 -5
- package/dist/components/SChip/index.d.ts +1 -1
- package/dist/components/SChipFilter/README.md +156 -72
- package/dist/components/SChipFilter/SChipFilter.d.ts +122 -54
- package/dist/components/SChipFilter/index.d.ts +1 -1
- package/dist/components/SChipInput/README.md +10 -5
- package/dist/components/SChipInput/SChipInput.d.ts +57 -7
- package/dist/components/SChipInput/index.d.ts +1 -1
- package/dist/components/SCircleProgress/README.md +6 -3
- package/dist/components/SCircleProgress/SCircleProgress.d.ts +12 -4
- package/dist/components/SConfirmModal/README.md +12 -18
- package/dist/components/SConfirmModal/SConfirmModal.d.ts +55 -16
- package/dist/components/SContextAlert/README.md +52 -0
- package/dist/components/SContextAlert/SContextAlert.d.ts +51 -0
- package/dist/components/SContextAlert/contextAlert.config.d.ts +22 -0
- package/dist/components/SContextAlert/index.d.ts +2 -0
- package/dist/components/SDatePicker/README.md +10 -3
- package/dist/components/SDatePicker/SDatePicker.d.ts +52 -7
- package/dist/components/SDateRangePicker/README.md +10 -5
- package/dist/components/SDateRangePicker/SDateRangePicker.d.ts +54 -9
- package/dist/components/SDivider/README.md +7 -0
- package/dist/components/SDivider/SDivider.d.ts +12 -1
- package/dist/components/SDonutChart/README.md +105 -0
- package/dist/components/SDonutChart/SDonutChart.d.ts +82 -0
- package/dist/components/SDonutChart/index.d.ts +1 -0
- package/dist/components/SDraggableItem/README.md +1 -0
- package/dist/components/SDraggableItem/SDraggableItem.d.ts +2 -0
- package/dist/components/SDraggableItem/index.d.ts +1 -1
- package/dist/components/SDraggableList/README.md +9 -3
- package/dist/components/SDraggableList/SDraggableList.d.ts +18 -3
- package/dist/components/SDraggableList/index.d.ts +1 -1
- package/dist/components/SDrawer/README.md +2 -1
- package/dist/components/SDrawer/SDrawer.d.ts +10 -5
- package/dist/components/SDropdownButton/README.md +16 -6
- package/dist/components/SDropdownButton/SDropdownButton.d.ts +8 -6
- package/dist/components/SDropdownButton/index.d.ts +1 -1
- package/dist/components/SEditor/EditorBody.d.ts +48 -0
- package/dist/components/SEditor/EditorToolbar.d.ts +93 -0
- package/dist/components/SEditor/README.md +207 -0
- package/dist/components/SEditor/SEditor.d.ts +128 -0
- package/dist/components/SEditor/editor-icons.d.ts +63 -0
- package/dist/components/SEditor/editor.config.d.ts +126 -0
- package/dist/components/SEditor/index.d.ts +8 -0
- package/dist/components/SEditor/tiptap-api.d.ts +29 -0
- package/dist/components/SEditor/use-is-mobile.d.ts +14 -0
- package/dist/components/SExpansionItem/README.md +3 -2
- package/dist/components/SExpansionItem/SExpansionItem.d.ts +18 -2
- package/dist/components/SExpansionItem/index.d.ts +1 -1
- package/dist/components/SField/README.md +18 -5
- package/dist/components/SField/SField.d.ts +62 -11
- package/dist/components/SField/index.d.ts +1 -1
- package/dist/components/SFilePicker/README.md +8 -6
- package/dist/components/SFilePicker/SFilePicker.d.ts +29 -9
- package/dist/components/SFooter/README.md +31 -8
- package/dist/components/SFooter/SFooter.d.ts +29 -13
- package/dist/components/SFooter/index.d.ts +1 -1
- package/dist/components/SForm/README.md +4 -4
- package/dist/components/SForm/SForm.d.ts +7 -7
- package/dist/components/SGhostButton/README.md +21 -2
- package/dist/components/SGhostButton/SGhostButton.d.ts +23 -5
- package/dist/components/SGnb/README.md +65 -9
- package/dist/components/SGnb/SGnb.d.ts +117 -13
- package/dist/components/SGnb/gnb.config.d.ts +46 -5
- package/dist/components/SGnb/index.d.ts +1 -1
- package/dist/components/SGnbSystem/README.md +190 -0
- package/dist/components/SGnbSystem/SGnbSystem.d.ts +179 -0
- package/dist/components/SGnbSystem/gnbSystem.config.d.ts +120 -0
- package/dist/components/SGnbSystem/index.d.ts +2 -0
- package/dist/components/SGuide/README.md +3 -3
- package/dist/components/SGuide/SGuide.d.ts +8 -5
- package/dist/components/SIcon/README.md +23 -1
- package/dist/components/SIcon/SIcon.d.ts +6 -3
- package/dist/components/SIcon/icons.gen.d.ts +26 -2
- package/dist/components/SImage/README.md +9 -1
- package/dist/components/SImage/SImage.d.ts +11 -8
- package/dist/components/SInput/README.md +13 -7
- package/dist/components/SInput/SInput.d.ts +21 -9
- package/dist/components/SKeyValueTable/README.md +8 -3
- package/dist/components/SKeyValueTable/SKeyValueTable.d.ts +33 -6
- package/dist/components/SKeyValueTable/index.d.ts +1 -1
- package/dist/components/SLauncherListBox/README.md +82 -0
- package/dist/components/SLauncherListBox/SLauncherListBox.d.ts +80 -0
- package/dist/components/SLauncherListBox/index.d.ts +2 -0
- package/dist/components/SLauncherListBox/launcherListBox.config.d.ts +149 -0
- package/dist/components/SLayout/README.md +6 -1
- package/dist/components/SLayout/SLayout.d.ts +6 -2
- package/dist/components/SLayout/index.d.ts +1 -1
- package/dist/components/SLineChart/README.md +132 -0
- package/dist/components/SLineChart/SLineChart.d.ts +115 -0
- package/dist/components/SLineChart/index.d.ts +1 -0
- package/dist/components/SLineChart/lineChart.config.d.ts +94 -0
- package/dist/components/SLinearProgress/README.md +9 -2
- package/dist/components/SLinearProgress/SLinearProgress.d.ts +12 -3
- package/dist/components/SLinearProgress/index.d.ts +1 -1
- package/dist/components/SList/README.md +15 -2
- package/dist/components/SList/SList.d.ts +7 -3
- package/dist/components/SList/index.d.ts +1 -1
- package/dist/components/SListItem/README.md +2 -2
- package/dist/components/SListItem/SListItem.d.ts +12 -2
- package/dist/components/SListItem/index.d.ts +1 -1
- package/dist/components/SLoadingContainer/README.md +1 -1
- package/dist/components/SLoadingContainer/SLoadingContainer.d.ts +3 -3
- package/dist/components/SLoadingContainer/index.d.ts +1 -1
- package/dist/components/SLoadingContainer/loading.d.ts +41 -6
- package/dist/components/SLoadingModal/README.md +10 -9
- package/dist/components/SLoadingModal/SLoadingModal.d.ts +10 -8
- package/dist/components/SLoadingModal/index.d.ts +1 -1
- package/dist/components/SLoginCard/README.md +37 -0
- package/dist/components/SLoginCard/SLoginCard.d.ts +43 -0
- package/dist/components/SLoginCard/index.d.ts +1 -0
- package/dist/components/SLogo/README.md +103 -0
- package/dist/components/SLogo/SLogo.d.ts +72 -0
- package/dist/components/SLogo/index.d.ts +2 -0
- package/dist/components/SLogo/logo.config.d.ts +29 -0
- package/dist/components/SLogo/logos.d.ts +16 -0
- package/dist/components/SMeatballButton/README.md +69 -0
- package/dist/components/SMeatballButton/SMeatballButton.d.ts +39 -0
- package/dist/components/SMeatballButton/index.d.ts +1 -0
- package/dist/components/SModal/README.md +20 -10
- package/dist/components/SModal/SModal.d.ts +5 -5
- package/dist/components/SModalContainer/README.md +4 -3
- package/dist/components/SModalContainer/SModalContainer.d.ts +16 -8
- package/dist/components/SNumberInput/README.md +17 -12
- package/dist/components/SNumberInput/SNumberInput.d.ts +53 -11
- package/dist/components/SPage/README.md +68 -5
- package/dist/components/SPage/SPage.d.ts +34 -10
- package/dist/components/SPage/SPageHeader.d.ts +37 -13
- package/dist/components/SPage/index.d.ts +2 -2
- package/dist/components/SPage/page-column.d.ts +34 -0
- package/dist/components/SPage/page-width.d.ts +23 -0
- package/dist/components/SPage/page.config.d.ts +26 -0
- package/dist/components/SPagination/README.md +11 -1
- package/dist/components/SPagination/SPagination.d.ts +9 -3
- package/dist/components/SPagination/index.d.ts +1 -1
- package/dist/components/SPieChart/README.md +93 -0
- package/dist/components/SPieChart/SPieChart.d.ts +73 -0
- package/dist/components/SPieChart/index.d.ts +1 -0
- package/dist/components/SPopover/README.md +1 -1
- package/dist/components/SPopover/SPopover.d.ts +2 -2
- package/dist/components/SPopup/README.md +14 -9
- package/dist/components/SPopup/SPopup.d.ts +15 -12
- package/dist/components/SPopup/index.d.ts +1 -1
- package/dist/components/SPortal/README.md +12 -5
- package/dist/components/SPortal/SPortal.d.ts +11 -9
- package/dist/components/SRadio/README.md +4 -4
- package/dist/components/SRadio/SRadio.d.ts +3 -3
- package/dist/components/SRadio/SRadioGroup.d.ts +3 -3
- package/dist/components/SRadioButton/README.md +11 -2
- package/dist/components/SRadioButton/SRadioButton.d.ts +19 -5
- package/dist/components/SRadioCard/README.md +81 -0
- package/dist/components/SRadioCard/SRadioCard.d.ts +34 -0
- package/dist/components/SRadioCard/SRadioCardGroup.d.ts +38 -0
- package/dist/components/SRadioCard/index.d.ts +2 -0
- package/dist/components/SScrollArea/README.md +14 -0
- package/dist/components/SScrollArea/SScrollArea.d.ts +18 -2
- package/dist/components/SSearchInput/README.md +7 -5
- package/dist/components/SSearchInput/SSearchInput.d.ts +12 -6
- package/dist/components/SSectionHeaderCard/README.md +6 -0
- package/dist/components/SSectionHeaderCard/SSectionHeaderCard.d.ts +19 -0
- package/dist/components/SSectionNav/README.md +32 -0
- package/dist/components/SSectionNav/SSectionNav.d.ts +40 -0
- package/dist/components/SSectionNav/index.d.ts +1 -0
- package/dist/components/SSectionNav/section-nav-scroll.d.ts +27 -0
- package/dist/components/SSelect/README.md +73 -16
- package/dist/components/SSelect/SSelect.d.ts +163 -21
- package/dist/components/SSelect/index.d.ts +1 -1
- package/dist/components/SSelect/select.config.d.ts +65 -6
- package/dist/components/SSkeleton/README.md +67 -0
- package/dist/components/SSkeleton/SSkeleton.d.ts +43 -0
- package/dist/components/SSkeleton/index.d.ts +2 -0
- package/dist/components/SSkeleton/skeleton.config.d.ts +24 -0
- package/dist/components/SSlider/README.md +86 -0
- package/dist/components/SSlider/SSlider.d.ts +149 -0
- package/dist/components/SSlider/index.d.ts +1 -0
- package/dist/components/SSplitter/README.md +2 -2
- package/dist/components/SSplitter/SSplitter.d.ts +7 -3
- package/dist/components/SStepper/README.md +1 -1
- package/dist/components/SStepper/SStepper.d.ts +3 -3
- package/dist/components/SStepper/stepper.config.d.ts +9 -3
- package/dist/components/SSwitch/README.md +14 -2
- package/dist/components/SSwitch/SSwitch.d.ts +3 -5
- package/dist/components/SSystemActionButton/README.md +253 -0
- package/dist/components/SSystemActionButton/SSystemActionButton.d.ts +198 -0
- package/dist/components/SSystemActionButton/index.d.ts +2 -0
- package/dist/components/SSystemActionButton/systemActionButton.config.d.ts +95 -0
- package/dist/components/STable/README.md +122 -88
- package/dist/components/STable/STable.d.ts +383 -52
- package/dist/components/STable/index.d.ts +1 -1
- package/dist/components/STableBar/README.md +2 -1
- package/dist/components/STableBar/STableBar.d.ts +9 -2
- package/dist/components/STabs/README.md +2 -2
- package/dist/components/STabs/STabs.d.ts +5 -6
- package/dist/components/STabs/tabs.config.d.ts +3 -8
- package/dist/components/STag/README.md +18 -0
- package/dist/components/STag/STag.d.ts +4 -3
- package/dist/components/STag/tag.config.d.ts +11 -10
- package/dist/components/STextLink/README.md +7 -1
- package/dist/components/STextLink/STextLink.d.ts +6 -2
- package/dist/components/STextarea/README.md +13 -6
- package/dist/components/STextarea/STextarea.d.ts +51 -8
- package/dist/components/STimePicker/README.md +8 -5
- package/dist/components/STimePicker/STimePicker.d.ts +39 -13
- package/dist/components/STimePicker/TimeListbox.d.ts +21 -0
- package/dist/components/STimePicker/timepicker.config.d.ts +9 -3
- package/dist/components/STimeRangePicker/README.md +9 -6
- package/dist/components/STimeRangePicker/STimeRangePicker.d.ts +43 -10
- package/dist/components/STimeRangePicker/time-range-picker.config.d.ts +2 -1
- package/dist/components/STimeline/README.md +41 -0
- package/dist/components/STimeline/STimeline.d.ts +28 -0
- package/dist/components/STimeline/index.d.ts +1 -0
- package/dist/components/SToast/README.md +5 -5
- package/dist/components/SToast/SToast.d.ts +5 -5
- package/dist/components/SToast/SToastContainer.d.ts +3 -3
- package/dist/components/SToggle/README.md +1 -1
- package/dist/components/SToggle/SToggle.d.ts +2 -2
- package/dist/components/SToggle/index.d.ts +1 -1
- package/dist/components/STooltip/README.md +7 -1
- package/dist/components/STooltip/STooltip.d.ts +2 -2
- package/dist/components/STree/README.md +7 -6
- package/dist/components/STree/STree.d.ts +18 -8
- package/dist/components/STree/STree.examples.d.ts +2 -0
- package/dist/components/STreeTable/README.md +49 -0
- package/dist/components/STreeTable/STreeTable.d.ts +70 -0
- package/dist/components/STreeTable/STreeTable.examples.d.ts +39 -0
- package/dist/components/STreeTable/index.d.ts +1 -0
- package/dist/docs/Gallery.d.ts +9 -0
- package/dist/docs/RecipeGallery.d.ts +13 -0
- package/dist/docs/gallery-previews.d.ts +24 -0
- package/dist/fonts/LICENSE.txt +94 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.0.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.1.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.10.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.11.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.12.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.13.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.14.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.15.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.16.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.17.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.18.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.19.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.2.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.20.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.21.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.22.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.23.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.24.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.25.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.26.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.27.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.28.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.29.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.3.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.30.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.31.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.32.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.33.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.34.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.35.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.36.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.37.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.38.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.39.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.4.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.40.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.41.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.42.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.43.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.44.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.45.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.46.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.47.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.48.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.49.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.5.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.50.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.51.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.52.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.53.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.54.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.55.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.56.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.57.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.58.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.59.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.6.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.60.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.61.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.62.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.63.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.64.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.65.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.66.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.67.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.68.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.69.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.7.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.70.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.71.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.72.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.73.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.74.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.75.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.76.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.77.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.78.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.79.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.8.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.80.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.81.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.82.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.83.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.84.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.85.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.86.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.87.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.88.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.89.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.9.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.90.woff2 +0 -0
- package/dist/fonts/woff2-dynamic-subset/PretendardVariable.subset.91.woff2 +0 -0
- package/dist/index.cjs +26161 -11501
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +28 -0
- package/dist/index.js +26064 -11500
- package/dist/index.js.map +1 -1
- package/dist/lib/autofill.d.ts +3 -5
- package/dist/lib/chart/cartesian.d.ts +54 -0
- package/dist/lib/chart/category-labels.d.ts +37 -0
- package/dist/lib/chart/frame.d.ts +21 -0
- package/dist/lib/chart/hover-dim.d.ts +19 -0
- package/dist/lib/chart/legend.d.ts +21 -0
- package/dist/lib/chart/palette.d.ts +28 -0
- package/dist/lib/chart/radial.d.ts +99 -0
- package/dist/lib/chart/scale.d.ts +26 -0
- package/dist/lib/chart/tooltip.d.ts +60 -0
- package/dist/lib/chart/types.d.ts +29 -0
- package/dist/lib/chart/use-element-size.d.ts +42 -0
- package/dist/lib/color.d.ts +1 -1
- package/dist/lib/date.d.ts +16 -2
- package/dist/lib/depth-filter.d.ts +27 -0
- package/dist/lib/doc-sections.d.ts +35 -0
- package/dist/lib/dropdown-menu.d.ts +19 -0
- package/dist/lib/field-width.d.ts +31 -0
- package/dist/lib/floating-anim.d.ts +2 -2
- package/dist/lib/floating-height.d.ts +15 -0
- package/dist/lib/floating-width.d.ts +1 -2
- package/dist/lib/form.d.ts +6 -3
- package/dist/lib/global-overlay.d.ts +5 -0
- package/dist/lib/grid-key-nav.d.ts +10 -0
- package/dist/lib/hover-preview.d.ts +32 -0
- package/dist/lib/inert.d.ts +11 -0
- package/dist/lib/list-box-item.d.ts +16 -0
- package/dist/lib/locale-context.d.ts +26 -0
- package/dist/lib/locale.d.ts +320 -0
- package/dist/lib/mode-listbox.d.ts +10 -0
- package/dist/lib/overlay-scrollbar.d.ts +32 -0
- package/dist/lib/row-metrics.d.ts +61 -0
- package/dist/lib/row-motion.d.ts +56 -0
- package/dist/lib/scrollbar.d.ts +1 -2
- package/dist/lib/story-docs.d.ts +35 -0
- package/dist/lib/tree-row.d.ts +103 -0
- package/dist/llms-full.txt +7542 -810
- package/dist/llms.txt +4280 -333
- package/dist/playground/categories.d.ts +19 -0
- package/dist/pretendard.css +937 -0
- package/dist/recipes/AppShell.d.ts +21 -0
- package/dist/recipes/CategoryManagePage.d.ts +1 -0
- package/dist/recipes/ConsultConsolePage.d.ts +1 -0
- package/dist/recipes/ExcelFilePopupPage.d.ts +5 -0
- package/dist/recipes/LoginPage.d.ts +6 -0
- package/dist/recipes/ProductBulkUploadPage.d.ts +1 -0
- package/dist/recipes/ProductCreatePage.d.ts +1 -0
- package/dist/recipes/ProductCreateSectionsPage.d.ts +5 -0
- package/dist/recipes/ProductDetailInlineEditPage.d.ts +9 -0
- package/dist/recipes/ProductDetailPage.d.ts +1 -0
- package/dist/recipes/ProductListChipFilterPage.d.ts +1 -0
- package/dist/recipes/ProductListPage.d.ts +1 -0
- package/dist/recipes/ProductOverlayPage.d.ts +1 -0
- package/dist/recipes/SalesDashboardPage.d.ts +1 -0
- package/dist/recipes/SettingsPage.d.ts +1 -0
- package/dist/recipes/StoreSetupPage.d.ts +1 -0
- package/dist/recipes/TransferOrderPopupPage.d.ts +2 -0
- package/dist/recipes/api.d.ts +220 -0
- package/dist/recipes/recipe-story.d.ts +33 -0
- package/dist/recipes/router.d.ts +9 -0
- package/dist/styles.css +4185 -352
- package/dist/theme.css +796 -58
- package/eslint/index.mjs +44 -35
- package/eslint/lib/class-names.mjs +23 -25
- package/eslint/lib/table-column.mjs +34 -8
- package/eslint/rules/component-group-gap.mjs +32 -30
- package/eslint/rules/divider-vertical-height.mjs +137 -0
- package/eslint/rules/field-width-grade.mjs +69 -52
- package/eslint/rules/no-arbitrary-class.mjs +63 -20
- package/eslint/rules/no-off-scale-spacing.mjs +61 -41
- package/eslint/rules/no-raw-html-control.mjs +38 -36
- package/eslint/rules/prefer-typo-preset.mjs +23 -17
- package/eslint/rules/require-locale-number.mjs +14 -19
- package/eslint/rules/table-column-width.mjs +114 -0
- package/eslint/rules/table-numeric-align.mjs +14 -14
- package/eslint/scale.gen.mjs +6 -3
- package/package.json +31 -6
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
# SAccountListBox
|
|
2
|
+
|
|
3
|
+
> 자동 생성 문서 — `npm run docs:gen`. 소스: 각 컴포넌트의 Props/Handle 인터페이스 + import 의존성.
|
|
4
|
+
|
|
5
|
+
### SAccountListBox
|
|
6
|
+
|
|
7
|
+
#### Props
|
|
8
|
+
|
|
9
|
+
| Prop | Type | Default | Description |
|
|
10
|
+
|------|------|---------|-------------|
|
|
11
|
+
| `email?` | `string` | — | 로그인한 계정의 이메일 |
|
|
12
|
+
| `name?` | `string` | — | 로그인한 계정의 이름 |
|
|
13
|
+
| `authority?` | `string` | — | 권한. 이름 오른쪽 끝에 붙는다. 없으면 이름만 남는다. (`role` 이 아닌 이유 — 그 이름은 DOM 의 ARIA 속성이라 소비 앱의 a11y lint 가 값을 ARIA 롤로 읽는다) |
|
|
14
|
+
| `accountSetting?` | `SAccountListBoxItem` | — | 계정 설정 행. 주지 않으면 행이 빠진다 |
|
|
15
|
+
| `language?` | `SAccountListBoxLanguage` | — | 언어 변경 행. 주지 않으면 행이 빠진다 |
|
|
16
|
+
| `logout?` | `SAccountListBoxItem` | — | 로그아웃 행. 이 행은 늘 있고, 라벨과 클릭만 받는다 |
|
|
17
|
+
|
|
18
|
+
## Types
|
|
19
|
+
|
|
20
|
+
### SAccountListBoxItem
|
|
21
|
+
|
|
22
|
+
```ts
|
|
23
|
+
/** 리스트박스의 한 행 — 라벨은 기본값이 있고 클릭만 앱이 준다 */
|
|
24
|
+
export interface SAccountListBoxItem {
|
|
25
|
+
/** 라벨 텍스트. 행마다 기본값이 있다 */
|
|
26
|
+
label?: string;
|
|
27
|
+
/** 클릭 */
|
|
28
|
+
onClick?: () => void;
|
|
29
|
+
}
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
### SAccountListBoxLanguage
|
|
33
|
+
|
|
34
|
+
```ts
|
|
35
|
+
/** 언어 변경 행 — 지금 쓰는 언어가 우측에 붙고, 고를 것이 있으면 눌러서 편다 */
|
|
36
|
+
export interface SAccountListBoxLanguage extends SAccountListBoxItem {
|
|
37
|
+
/**
|
|
38
|
+
* 지금 선택돼 있는 언어. 우측에 브랜드색으로 붙는다.
|
|
39
|
+
* `options` 를 함께 주면 그 목록에서 같은 `value` 를 찾아 `label` 로 적는다.
|
|
40
|
+
*/
|
|
41
|
+
value?: string;
|
|
42
|
+
/**
|
|
43
|
+
* 고를 수 있는 언어. 주면 행을 눌렀을 때 **하위 메뉴가 우측 아래로 펼쳐지고**,
|
|
44
|
+
* 그동안 계정 패널은 닫히지 않는다. 주지 않으면 행을 누르는 것 자체가 액션이라
|
|
45
|
+
* `onClick` 만 돌고 패널이 닫힌다 — 언어 화면을 따로 두는 앱이 그렇다.
|
|
46
|
+
*/
|
|
47
|
+
options?: SAccountListBoxLanguageOption[];
|
|
48
|
+
/** 하위 메뉴에서 언어를 고름. 고르면 하위 메뉴와 계정 패널이 함께 닫힌다 */
|
|
49
|
+
onChange?: (value: string) => void;
|
|
50
|
+
}
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
### SAccountListBoxLanguageOption
|
|
54
|
+
|
|
55
|
+
```ts
|
|
56
|
+
/** 언어 변경 하위 메뉴의 한 칸 */
|
|
57
|
+
export interface SAccountListBoxLanguageOption {
|
|
58
|
+
/** 값. `SAccountListBoxLanguage.value` 와 맞춰 지금 언어를 가린다 */
|
|
59
|
+
value: string;
|
|
60
|
+
/** 화면에 적히는 언어명 */
|
|
61
|
+
label: string;
|
|
62
|
+
}
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
## Dependencies
|
|
66
|
+
|
|
67
|
+
### Used by
|
|
68
|
+
|
|
69
|
+
- [SGnbSystem](../SGnbSystem)
|
|
70
|
+
- [SSystemActionButton](../SSystemActionButton)
|
|
71
|
+
|
|
72
|
+
### Depends on
|
|
73
|
+
|
|
74
|
+
- [SIcon](../SIcon)
|
|
75
|
+
- [SPortal](../SPortal)
|
|
76
|
+
|
|
77
|
+
### Graph
|
|
78
|
+
|
|
79
|
+
```mermaid
|
|
80
|
+
graph TD;
|
|
81
|
+
SAccountListBox --> SIcon
|
|
82
|
+
SAccountListBox --> SPortal
|
|
83
|
+
SGnbSystem --> SAccountListBox
|
|
84
|
+
SSystemActionButton --> SAccountListBox
|
|
85
|
+
style SAccountListBox fill:#f9f,stroke:#333,stroke-width:4px
|
|
86
|
+
```
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
import { type HTMLAttributes } from 'react';
|
|
2
|
+
/** 리스트박스의 한 행 — 라벨은 기본값이 있고 클릭만 앱이 준다 */
|
|
3
|
+
export interface SAccountListBoxItem {
|
|
4
|
+
/** 라벨 텍스트. 행마다 기본값이 있다 */
|
|
5
|
+
label?: string;
|
|
6
|
+
/** 클릭 */
|
|
7
|
+
onClick?: () => void;
|
|
8
|
+
}
|
|
9
|
+
/** 언어 변경 하위 메뉴의 한 칸 */
|
|
10
|
+
export interface SAccountListBoxLanguageOption {
|
|
11
|
+
/** 값. `SAccountListBoxLanguage.value` 와 맞춰 지금 언어를 가린다 */
|
|
12
|
+
value: string;
|
|
13
|
+
/** 화면에 적히는 언어명 */
|
|
14
|
+
label: string;
|
|
15
|
+
}
|
|
16
|
+
/** 언어 변경 행 — 지금 쓰는 언어가 우측에 붙고, 고를 것이 있으면 눌러서 편다 */
|
|
17
|
+
export interface SAccountListBoxLanguage extends SAccountListBoxItem {
|
|
18
|
+
/**
|
|
19
|
+
* 지금 선택돼 있는 언어. 우측에 브랜드색으로 붙는다.
|
|
20
|
+
* `options` 를 함께 주면 그 목록에서 같은 `value` 를 찾아 `label` 로 적는다.
|
|
21
|
+
*/
|
|
22
|
+
value?: string;
|
|
23
|
+
/**
|
|
24
|
+
* 고를 수 있는 언어. 주면 행을 눌렀을 때 **하위 메뉴가 우측 아래로 펼쳐지고**,
|
|
25
|
+
* 그동안 계정 패널은 닫히지 않는다. 주지 않으면 행을 누르는 것 자체가 액션이라
|
|
26
|
+
* `onClick` 만 돌고 패널이 닫힌다 — 언어 화면을 따로 두는 앱이 그렇다.
|
|
27
|
+
*/
|
|
28
|
+
options?: SAccountListBoxLanguageOption[];
|
|
29
|
+
/** 하위 메뉴에서 언어를 고름. 고르면 하위 메뉴와 계정 패널이 함께 닫힌다 */
|
|
30
|
+
onChange?: (value: string) => void;
|
|
31
|
+
}
|
|
32
|
+
export interface SAccountListBoxProps extends HTMLAttributes<HTMLDivElement> {
|
|
33
|
+
/** 로그인한 계정의 이메일 */
|
|
34
|
+
email?: string;
|
|
35
|
+
/** 로그인한 계정의 이름 */
|
|
36
|
+
name?: string;
|
|
37
|
+
/**
|
|
38
|
+
* 권한. 이름 오른쪽 끝에 붙는다. 없으면 이름만 남는다.
|
|
39
|
+
* (`role` 이 아닌 이유 — 그 이름은 DOM 의 ARIA 속성이라 소비 앱의 a11y lint 가 값을 ARIA 롤로 읽는다)
|
|
40
|
+
*/
|
|
41
|
+
authority?: string;
|
|
42
|
+
/** 계정 설정 행. 주지 않으면 행이 빠진다 */
|
|
43
|
+
accountSetting?: SAccountListBoxItem;
|
|
44
|
+
/** 언어 변경 행. 주지 않으면 행이 빠진다 */
|
|
45
|
+
language?: SAccountListBoxLanguage;
|
|
46
|
+
/** 로그아웃 행. 이 행은 늘 있고, 라벨과 클릭만 받는다 */
|
|
47
|
+
logout?: SAccountListBoxItem;
|
|
48
|
+
}
|
|
49
|
+
/**
|
|
50
|
+
* 리스트박스에 **담기는 내용**만 추린 것.
|
|
51
|
+
* 팝오버로 띄우는 쪽(`SSystemActionButton` 의 `option` · `SGnbSystem` 의 `account.listBox`)이
|
|
52
|
+
* 이 덩어리째 넘겨받으므로, 패널의 DOM 속성(className·style …)과 분리해 둔다.
|
|
53
|
+
*/
|
|
54
|
+
export type SAccountListBoxContent = Pick<SAccountListBoxProps, 'email' | 'name' | 'authority' | 'accountSetting' | 'language' | 'logout'>;
|
|
55
|
+
/**
|
|
56
|
+
* SAccountListBox — GNB system 의 계정 행을 눌렀을 때 뜨는 계정 리스트박스.
|
|
57
|
+
*
|
|
58
|
+
* 판에서는 계정 행이 맨 아래에 있어 **행 위로 · 행 왼쪽 끝에 맞춰**, 전폭 상단바에서는 **행 아래로 ·
|
|
59
|
+
* 오른쪽 끝에 맞춰** 펼쳐진다. 이 방향은 고정이라 앱이 고르지 않는다.
|
|
60
|
+
*
|
|
61
|
+
* 위에서부터 [사용자정보(이메일 · 이름 + 권한)] · [계정 설정] · [언어 변경] · [계정 로그아웃] 이다.
|
|
62
|
+
* **권한(`authority`) · 계정 설정 · 언어 변경은 옵션**이고, 사용자정보와 로그아웃은 늘 있다 — 이 패널이 존재하는
|
|
63
|
+
* 이유가 "지금 누구로 로그인해 있는가"와 "나가기"이기 때문이다. 옵션을 빼면 그 줄이 통째로 사라지고
|
|
64
|
+
* 나머지가 위로 붙는다.
|
|
65
|
+
*
|
|
66
|
+
* 폭은 토큰이 정하는 고정값(240px)이라 앱이 늘리지 않는다 — 이 패널은 GNB 폭에 맞춰 뜬다.
|
|
67
|
+
* 행 라벨·아이콘은 무엇을 하는 행인지가 곧 정체라 아이콘을 밖에서 바꾸지 않고, 라벨만 바꿀 수 있다.
|
|
68
|
+
*
|
|
69
|
+
* **언어 변경만 하위 메뉴를 가질 수 있다.** `language.options` 를 주면 그 행이 우측 값 아래로
|
|
70
|
+
* 목록을 펴고, 고를 때까지 계정 패널은 열려 있는다. 주지 않으면 행을 누르는 것 자체가 액션이라
|
|
71
|
+
* `onClick` 만 돌고 패널이 닫힌다 — 언어를 고르는 화면을 따로 두는 앱이 그렇다.
|
|
72
|
+
*
|
|
73
|
+
* **이 컴포넌트는 패널만 그린다.** 계정 행에 붙여 띄우는 것은 `SSystemActionButton` 의
|
|
74
|
+
* `type="account"` 이 맡으므로(`option` 에 이 내용을 넘긴다 — 필수다), 앱이 직접 팝오버를 조립할
|
|
75
|
+
* 일은 없다. 계정 행은 예외 없이 이 패널의 트리거다.
|
|
76
|
+
*
|
|
77
|
+
* 토큰은 `--cmp-gnb-system-accountListBox-*` · `--cmp-gnb-system-accountButton-*`.
|
|
78
|
+
*/
|
|
79
|
+
export declare const SAccountListBox: import("react").ForwardRefExoticComponent<SAccountListBoxProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import { type RefObject } from 'react';
|
|
2
|
+
import { type SPortalAlign, type SPortalPlacement } from '../SPortal';
|
|
3
|
+
import { type STagColor } from '../STag';
|
|
4
|
+
/**
|
|
5
|
+
* 시스템 메뉴의 한 칸.
|
|
6
|
+
*
|
|
7
|
+
* `color` 를 주면 그 칸은 **상태 칸**이 되어 점과 글자가 같은 색으로 물든다(시안) — 상태는 색 자체가
|
|
8
|
+
* 뜻이라, 고르는 자리에서도 그 색을 보고 고른다. 주지 않으면 글자만 있는 칸이고, 지금 값만
|
|
9
|
+
* 브랜드색으로 떠오른다.
|
|
10
|
+
*/
|
|
11
|
+
export interface SystemMenuOption {
|
|
12
|
+
/** 값. 지금 값과 맞춰 어느 칸이 선택돼 있는지를 가린다 */
|
|
13
|
+
value: string;
|
|
14
|
+
/** 화면에 적히는 이름 */
|
|
15
|
+
label: string;
|
|
16
|
+
/** 상태 칸의 색. 주면 점 + 같은 색 글자로 그린다 */
|
|
17
|
+
color?: STagColor;
|
|
18
|
+
}
|
|
19
|
+
interface SystemMenuPortalProps {
|
|
20
|
+
/** 표시 여부 */
|
|
21
|
+
open: boolean;
|
|
22
|
+
/** 표시 상태 변경 */
|
|
23
|
+
onOpenChange: (open: boolean) => void;
|
|
24
|
+
/** 붙을 자리 — 값 아래로 펼 때는 **바뀌는 값**(우측 값 묶음 · 상태 태그), 옆으로 펼 때는 행 자체 */
|
|
25
|
+
anchorRef: RefObject<HTMLElement | null>;
|
|
26
|
+
/** 뜨는 방향. 기본 `'bottom'`(앵커 아래) */
|
|
27
|
+
placement?: SPortalPlacement;
|
|
28
|
+
/** 교차축 정렬. 아래로 펼 때는 값이 놓인 쪽 끝, 옆으로 펼 때는 위쪽 끝(`start`) */
|
|
29
|
+
align: SPortalAlign;
|
|
30
|
+
/**
|
|
31
|
+
* 메뉴를 여는 행. 이 행 위의 클릭은 행이 스스로 토글하므로 여기서 닫지 않는다 —
|
|
32
|
+
* 앵커는 행이 아니라 그 안의 값이라, 값 밖(라벨 쪽)을 누르면 닫혔다가 곧바로 다시 열린다.
|
|
33
|
+
*/
|
|
34
|
+
triggerRef?: RefObject<HTMLElement | null>;
|
|
35
|
+
/** 접근성 이름 — 무엇을 고르는 메뉴인지 */
|
|
36
|
+
ariaLabel?: string;
|
|
37
|
+
/** 지금 값 */
|
|
38
|
+
value?: string;
|
|
39
|
+
/** 고를 수 있는 칸 */
|
|
40
|
+
options: SystemMenuOption[];
|
|
41
|
+
/** 칸을 고름 */
|
|
42
|
+
onSelect: (value: string) => void;
|
|
43
|
+
}
|
|
44
|
+
/**
|
|
45
|
+
* GNB system 의 값 고르기 메뉴.
|
|
46
|
+
*
|
|
47
|
+
* 계정 패널의 언어 변경 행 · `SSystemActionButton` 의 `subSelect` · `status` 가 모두 이것을 연다 —
|
|
48
|
+
* 세 자리 모두 "지금 값이 적혀 있고, 눌러서 다른 값으로 바꾼다" 는 같은 일이라, 뜨는 자리와 닫히는
|
|
49
|
+
* 시점을 한 곳에 모아 두지 않으면 자리마다 동작이 갈린다.
|
|
50
|
+
*
|
|
51
|
+
* **뜨는 자리는 부르는 쪽이 정한다.** 계정 패널 안의 행처럼 판 안에서 열리는 자리는 바꾸는 대상인
|
|
52
|
+
* 값 바로 아래로, 값이 놓인 쪽 끝에 맞춰 편다(패널 폭 안에 갇혀 있어 옆이 없다). 판 없이 행 하나로
|
|
53
|
+
* 서는 자리는 행 오른쪽으로 편다 — 행 아래는 다음 행이 이어지는 자리라 메뉴가 그 위를 덮는다.
|
|
54
|
+
*
|
|
55
|
+
* 공개 API 가 아니므로 index.ts 로 내보내지 않는다 — 앱은 각 행의 `options` 로 닿는다.
|
|
56
|
+
*/
|
|
57
|
+
export declare function SystemMenuPortal({ open, onOpenChange, anchorRef, placement, align, triggerRef, ariaLabel, value, options, onSelect, }: SystemMenuPortalProps): import("react").JSX.Element;
|
|
58
|
+
export {};
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
/** 행의 성격. default = 보통 행, negative = 되돌릴 수 없는 행(로그아웃) */
|
|
2
|
+
export declare const ACCOUNT_LIST_BOX_ITEM_TONES: readonly ["default", "negative"];
|
|
3
|
+
export type SAccountListBoxItemTone = (typeof ACCOUNT_LIST_BOX_ITEM_TONES)[number];
|
|
4
|
+
/** 행마다 정해져 있는 아이콘 — 무엇을 하는 행인지가 아이콘으로 읽히므로 밖에서 바꾸지 않는다 */
|
|
5
|
+
export declare const ACCOUNT_LIST_BOX_ICONS: {
|
|
6
|
+
readonly accountSetting: "account";
|
|
7
|
+
readonly language: "global";
|
|
8
|
+
readonly logout: "logout";
|
|
9
|
+
};
|
|
10
|
+
/**
|
|
11
|
+
* 행 라벨의 한국어 시안 문구. 컴포넌트는 이 값이 아니라 `SLocaleProvider` 로케일(`accountListBox.*`)을 따른다 —
|
|
12
|
+
* 앱이 `label` 로 직접 주면 그 값이 우선한다. 시안 문구를 참조하는 소비 앱을 위해 남겨 둔다.
|
|
13
|
+
*/
|
|
14
|
+
export declare const ACCOUNT_LIST_BOX_LABELS: {
|
|
15
|
+
readonly accountSetting: "계정 설정";
|
|
16
|
+
readonly language: "언어 변경";
|
|
17
|
+
readonly logout: "계정 로그아웃";
|
|
18
|
+
};
|
|
19
|
+
/** 행 성격별 색 */
|
|
20
|
+
export declare const ACCOUNT_LIST_BOX_TONE_CONFIG: Record<SAccountListBoxItemTone, {
|
|
21
|
+
bg: string;
|
|
22
|
+
bgHover: string;
|
|
23
|
+
text: string;
|
|
24
|
+
icon: string;
|
|
25
|
+
}>;
|
|
26
|
+
/** 치수·색 — 전부 토큰 참조 */
|
|
27
|
+
export declare const ACCOUNT_LIST_BOX_LAYOUT: {
|
|
28
|
+
/** 패널 고정 폭 */
|
|
29
|
+
readonly width: string;
|
|
30
|
+
/** 패널 배경 */
|
|
31
|
+
readonly bg: string;
|
|
32
|
+
/** 패널 라운드 */
|
|
33
|
+
readonly radius: string;
|
|
34
|
+
/** 사용자정보 영역 배경 */
|
|
35
|
+
readonly userdataBg: string;
|
|
36
|
+
/** 사용자정보 영역 좌우 여백 */
|
|
37
|
+
readonly userdataPaddingX: string;
|
|
38
|
+
/** 사용자정보 영역 상하 여백 */
|
|
39
|
+
readonly userdataPaddingY: string;
|
|
40
|
+
/** 이메일 글자색 */
|
|
41
|
+
readonly emailColor: string;
|
|
42
|
+
/** 이름 글자색 */
|
|
43
|
+
readonly nameColor: string;
|
|
44
|
+
/** 권한 글자색 */
|
|
45
|
+
readonly roleColor: string;
|
|
46
|
+
/** 행 묶음의 상하 여백 */
|
|
47
|
+
readonly listPaddingY: string;
|
|
48
|
+
/** 행 좌우 여백 */
|
|
49
|
+
readonly itemPaddingX: string;
|
|
50
|
+
/** 행 상하 여백 */
|
|
51
|
+
readonly itemPaddingY: string;
|
|
52
|
+
/** 행 아이콘 ↔ 라벨 간격 */
|
|
53
|
+
readonly itemGap: string;
|
|
54
|
+
/** 행 아이콘 크기 */
|
|
55
|
+
readonly itemIcon: string;
|
|
56
|
+
/** 우측 값 ↔ 화살표 간격 */
|
|
57
|
+
readonly selectDataGap: string;
|
|
58
|
+
/** 우측 화살표 크기 */
|
|
59
|
+
readonly selectDataIcon: string;
|
|
60
|
+
/** 우측 값 글자색 */
|
|
61
|
+
readonly selectDataText: string;
|
|
62
|
+
/** 시스템 메뉴에서 지금 값인 칸의 글자색 — 계정 행이 아니라 목록 항목이라
|
|
63
|
+
* listBoxItem 의 선택 색을 그대로 따른다(다른 목록의 선택 표시와 같은 색) */
|
|
64
|
+
readonly menuSelectedText: string;
|
|
65
|
+
/** 우측 화살표색 */
|
|
66
|
+
readonly selectDataIconColor: string;
|
|
67
|
+
};
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
export { SAccountListBox, type SAccountListBoxProps, type SAccountListBoxContent, type SAccountListBoxItem, type SAccountListBoxLanguage, type SAccountListBoxLanguageOption, } from './SAccountListBox';
|
|
2
|
+
export { ACCOUNT_LIST_BOX_ICONS, ACCOUNT_LIST_BOX_ITEM_TONES, ACCOUNT_LIST_BOX_LABELS, ACCOUNT_LIST_BOX_LAYOUT, ACCOUNT_LIST_BOX_TONE_CONFIG, type SAccountListBoxItemTone, } from './accountListBox.config';
|
|
@@ -9,11 +9,13 @@
|
|
|
9
9
|
| Prop | Type | Default | Description |
|
|
10
10
|
|------|------|---------|-------------|
|
|
11
11
|
| `open?` | `boolean` | — | |
|
|
12
|
-
| `persistent?` | `boolean` | — |
|
|
12
|
+
| `persistent?` | `boolean` | — | 백드롭 클릭으로 안 닫히고 흔들림. **기본값 true** |
|
|
13
|
+
| `closeOnEscape?` | `boolean` | — | ESC 로 닫는다. **기본값 true** — false 면 ESC 로 안 닫히고 흔들림 |
|
|
14
|
+
| `showClose?` | `boolean` | `true` | 우측 상단 닫기(X) 버튼. **기본값 true** `false` 는 **액션을 끝내야만 나갈 수 있는 모달**에만 준다 — 필수 약관 동의, 필수 정보 입력처럼 중간에 빠져나가면 앱이 정의되지 않은 상태로 남는 경우다. `persistent` 기본값(true)과 겹치면 나가는 길이 모달 안의 버튼 하나뿐이 되므로, `button` 이나 `footerLeft` 로 그 길을 반드시 둔다. |
|
|
13
15
|
| `modalTitle?` | `string` | `''` | |
|
|
14
|
-
| `description?` | `ReactNode` | — | 제목 오른쪽에 붙는 보조
|
|
16
|
+
| `description?` | `ReactNode` | — | 제목 오른쪽에 붙는 보조 설명. 문자열이면 서브텍스트 스타일로 렌더하고, 노드를 넘기면 그대로 배치한다. |
|
|
15
17
|
| `button?` | `SFooterButton` | — | 하단 액션 버튼 (주 액션 1개). 의도적으로 단수다 — 보조 버튼(취소·삭제 등)은 `footerLeft` 슬롯에 직접 배치한다. |
|
|
16
|
-
| `footerLeft?` | `ReactNode` | — | footer 좌측
|
|
18
|
+
| `footerLeft?` | `ReactNode` | — | footer 좌측 영역. 보조 버튼이나 안내 문구를 넣는다. 버튼을 하나 더 쓰고 싶을 때 여기에 SButton 을 넣는다. |
|
|
17
19
|
| `width?` | `number \| string` | — | |
|
|
18
20
|
| `height?` | `number \| string` | — | |
|
|
19
21
|
| `children?` | `ReactNode` | — | |
|
|
@@ -23,7 +25,7 @@
|
|
|
23
25
|
| Event | Type | Description |
|
|
24
26
|
|-------|------|-------------|
|
|
25
27
|
| `onOpenChange` | `(open: boolean) => void` | |
|
|
26
|
-
| `onClose` | `() => void` | 닫기(X) 버튼 클릭
|
|
28
|
+
| `onClose` | `() => void` | 닫기(X) 버튼 클릭 |
|
|
27
29
|
|
|
28
30
|
## Dependencies
|
|
29
31
|
|
|
@@ -3,13 +3,23 @@ import { type SFooterButton } from '../SFooter';
|
|
|
3
3
|
export interface SActionModalProps {
|
|
4
4
|
open?: boolean;
|
|
5
5
|
onOpenChange?: (open: boolean) => void;
|
|
6
|
-
/** 닫기(X) 버튼 클릭
|
|
6
|
+
/** 닫기(X) 버튼 클릭 */
|
|
7
7
|
onClose?: () => void;
|
|
8
|
-
/**
|
|
8
|
+
/** 백드롭 클릭으로 안 닫히고 흔들림. **기본값 true** */
|
|
9
9
|
persistent?: boolean;
|
|
10
|
+
/** ESC 로 닫는다. **기본값 true** — false 면 ESC 로 안 닫히고 흔들림 */
|
|
11
|
+
closeOnEscape?: boolean;
|
|
12
|
+
/**
|
|
13
|
+
* 우측 상단 닫기(X) 버튼. **기본값 true**
|
|
14
|
+
*
|
|
15
|
+
* `false` 는 **액션을 끝내야만 나갈 수 있는 모달**에만 준다 — 필수 약관 동의, 필수 정보 입력처럼
|
|
16
|
+
* 중간에 빠져나가면 앱이 정의되지 않은 상태로 남는 경우다. `persistent` 기본값(true)과 겹치면
|
|
17
|
+
* 나가는 길이 모달 안의 버튼 하나뿐이 되므로, `button` 이나 `footerLeft` 로 그 길을 반드시 둔다.
|
|
18
|
+
*/
|
|
19
|
+
showClose?: boolean;
|
|
10
20
|
modalTitle?: string;
|
|
11
21
|
/**
|
|
12
|
-
* 제목 오른쪽에 붙는 보조
|
|
22
|
+
* 제목 오른쪽에 붙는 보조 설명.
|
|
13
23
|
* 문자열이면 서브텍스트 스타일로 렌더하고, 노드를 넘기면 그대로 배치한다.
|
|
14
24
|
*/
|
|
15
25
|
description?: ReactNode;
|
|
@@ -19,7 +29,7 @@ export interface SActionModalProps {
|
|
|
19
29
|
*/
|
|
20
30
|
button?: SFooterButton;
|
|
21
31
|
/**
|
|
22
|
-
* footer 좌측
|
|
32
|
+
* footer 좌측 영역.
|
|
23
33
|
* 보조 버튼이나 안내 문구를 넣는다. 버튼을 하나 더 쓰고 싶을 때 여기에 SButton 을 넣는다.
|
|
24
34
|
*/
|
|
25
35
|
footerLeft?: ReactNode;
|
|
@@ -28,7 +38,7 @@ export interface SActionModalProps {
|
|
|
28
38
|
children?: ReactNode;
|
|
29
39
|
}
|
|
30
40
|
/**
|
|
31
|
-
* SActionModal —
|
|
41
|
+
* SActionModal — 헤더(제목·닫기) + 본문 + 하단 액션 버튼.
|
|
32
42
|
*
|
|
33
43
|
* 액션 버튼은 `button.onClick` 만 호출하고 모달을 닫지 않는다. 본문에서 API 를 호출하는 경우가
|
|
34
44
|
* 많아 성공 여부에 따라 닫힘 시점이 달라지므로, 닫는 책임은 사용하는 쪽에 둔다.
|
|
@@ -36,4 +46,4 @@ export interface SActionModalProps {
|
|
|
36
46
|
* `button` 은 의도적으로 단수다. 주 액션은 오른쪽에 하나만 두고, 보조 버튼은 `footerLeft` 슬롯에
|
|
37
47
|
* 소비자가 직접 배치한다. (buttons 배열 API 를 추가하지 말 것)
|
|
38
48
|
*/
|
|
39
|
-
export declare function SActionModal({ open, onOpenChange, onClose, persistent, modalTitle, description, button, footerLeft, width, height, children, }: SActionModalProps): import("react").JSX.Element;
|
|
49
|
+
export declare function SActionModal({ open, onOpenChange, onClose, persistent, closeOnEscape, modalTitle, description, button, footerLeft, showClose, width, height, children, }: SActionModalProps): import("react").JSX.Element;
|
|
@@ -30,6 +30,7 @@ export const BADGE_COLORS = [
|
|
|
30
30
|
'blue',
|
|
31
31
|
'darkblue',
|
|
32
32
|
'indigo',
|
|
33
|
+
'purple',
|
|
33
34
|
'grey',
|
|
34
35
|
] as const;
|
|
35
36
|
```
|
|
@@ -38,12 +39,14 @@ export const BADGE_COLORS = [
|
|
|
38
39
|
|
|
39
40
|
### Used by
|
|
40
41
|
|
|
42
|
+
- [SCalendarBoard](../SCalendarBoard)
|
|
41
43
|
- [SSectionHeaderCard](../SSectionHeaderCard)
|
|
42
44
|
|
|
43
45
|
### Graph
|
|
44
46
|
|
|
45
47
|
```mermaid
|
|
46
48
|
graph TD;
|
|
49
|
+
SCalendarBoard --> SBadge
|
|
47
50
|
SSectionHeaderCard --> SBadge
|
|
48
51
|
style SBadge fill:#f9f,stroke:#333,stroke-width:4px
|
|
49
52
|
```
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { type HTMLAttributes } from 'react';
|
|
2
|
-
export declare const BADGE_COLORS: readonly ["red", "orange", "yellow", "green", "lightblue", "blue", "darkblue", "indigo", "grey"];
|
|
2
|
+
export declare const BADGE_COLORS: readonly ["red", "orange", "yellow", "green", "lightblue", "blue", "darkblue", "indigo", "purple", "grey"];
|
|
3
3
|
export type SBadgeColor = (typeof BADGE_COLORS)[number];
|
|
4
4
|
export interface SBadgeProps extends HTMLAttributes<HTMLSpanElement> {
|
|
5
5
|
/** 뱃지 색상 */
|
|
6
6
|
color?: SBadgeColor;
|
|
7
7
|
}
|
|
8
8
|
/**
|
|
9
|
-
* SBadge —
|
|
9
|
+
* SBadge — 색상 점(dot) 인디케이터.
|
|
10
10
|
* 색상은 컴포넌트 토큰 `--cmp-badge-<color>` 를 참조한다.
|
|
11
11
|
*/
|
|
12
12
|
export declare const SBadge: import("react").ForwardRefExoticComponent<SBadgeProps & import("react").RefAttributes<HTMLSpanElement>>;
|
|
@@ -0,0 +1,123 @@
|
|
|
1
|
+
# SBarChart
|
|
2
|
+
|
|
3
|
+
> 자동 생성 문서 — `npm run docs:gen`. 소스: 각 컴포넌트의 Props/Handle 인터페이스 + import 의존성.
|
|
4
|
+
|
|
5
|
+
### SBarChart
|
|
6
|
+
|
|
7
|
+
#### Props
|
|
8
|
+
|
|
9
|
+
| Prop | Type | Default | Description |
|
|
10
|
+
|------|------|---------|-------------|
|
|
11
|
+
| `categories` | `string[]` | — | 가로축(가로 막대면 세로축)에 놓일 항목 이름 |
|
|
12
|
+
| `series` | `SBarChartSeries[]` | — | 계열 목록. 각 `data` 는 `categories` 와 같은 순서다 |
|
|
13
|
+
| `title?` | `string` | — | 차트 제목 — 왼쪽 위에 놓인다 |
|
|
14
|
+
| `unit?` | `string` | — | 단위 — 오른쪽 위에 "단위 : " 를 붙여 놓는다 |
|
|
15
|
+
| `direction?` | `SBarChartDirection` | `'vertical'` | 막대가 자라는 방향 |
|
|
16
|
+
| `stacked?` | `boolean` | `false` | 계열을 나란히 놓는 대신 **한 막대에 쌓는다**. 항목의 크기와 그 안의 구성을 함께 볼 때 쓴다. 첫 계열이 기준선에 붙고, 값 라벨은 조각마다가 아니라 **항목의 합계**를 한 번 적는다. 음수는 0 아래로 따로 쌓이며, 값 축도 개별 값이 아닌 항목별 합계로 잡힌다 |
|
|
17
|
+
| `palette?` | `SBarChartPalette` | `'default'` | 색 팔레트. 계열이 하나면 계열 대신 **항목**마다 색이 바뀐다. `custom` 일 때만 `colors` 를 본다 |
|
|
18
|
+
| `colors?` | `SBarChartColor[]` | — | `palette='custom'` 에서 쓸 색 이름을 계열 순서대로. 계열보다 짧으면 앞에서부터 순환한다 |
|
|
19
|
+
| `max?` | `number` | — | 값 축의 최댓값. 주지 않으면 데이터에서 읽기 좋은 값으로 정한다 |
|
|
20
|
+
| `tickCount?` | `number` | `8` | 값 축 눈금 개수 |
|
|
21
|
+
| `barSize?` | `number` | `BAR_SIZE_MAX` | 막대 두께 상한(px, 24~80). 낮추면 좌우 여백 상한도 같은 비율로 따라 내려온다 |
|
|
22
|
+
| `showValueLabel?` | `boolean` | `true` | 막대마다 값을 적는다 |
|
|
23
|
+
| `rotateCategoryLabels?` | `boolean` | `false` | 항목 이름을 -45° 기울인다. 이름이 막대 묶음 폭보다 길어 서로 겹칠 때 쓴다. 기울여도 너무 긴 이름은 말줄임되고, 전체 이름은 툴팁 제목에서 읽힌다. 이름이 아주 길면 기울이기보다 `direction='horizontal'` 이 먼저다. 세로 막대에서만 쓴다 — 가로 막대는 이름 열이 가장 긴 이름에 맞춰 넓어지므로 무시한다 |
|
|
24
|
+
| `showLegend?` | `boolean` | `true` | 범례를 보인다 |
|
|
25
|
+
| `legendPosition?` | `SBarChartLegendPosition` | `'top'` | 범례 위치 |
|
|
26
|
+
| `showTooltip?` | `boolean` | `true` | 막대에 마우스를 올리면 값 상자를 띄운다 |
|
|
27
|
+
| `formatValue?` | `(value: number) => string` | `defaultFormat` | 값 표시 형식 |
|
|
28
|
+
| `height?` | `number \| string` | — | 차트 높이. **아래 축 텍스트까지 포함한 값**이다 — 그림은 그만큼 줄어든다 |
|
|
29
|
+
| `tooltipFooter?` | `(category: SBarChartTooltipCategory) => ReactNode` | — | 툴팁의 값 아래에 덧붙일 내용. 짚은 항목을 받아 그린다 — 계열 값만으로 모자란 맥락 (합계, 전월 대비 등)을 적는다. 툴팁은 누를 수 없으므로 버튼·링크는 넣지 않는다 |
|
|
30
|
+
| `className?` | `string` | — | |
|
|
31
|
+
| `style?` | `CSSProperties` | — | |
|
|
32
|
+
|
|
33
|
+
#### Events
|
|
34
|
+
|
|
35
|
+
| Event | Type | Description |
|
|
36
|
+
|-------|------|-------------|
|
|
37
|
+
| `onBarClick` | `(point: SBarChartPoint) => void` | 막대를 눌렀을 때 |
|
|
38
|
+
|
|
39
|
+
## Types
|
|
40
|
+
|
|
41
|
+
### SBarChartSeries
|
|
42
|
+
|
|
43
|
+
```ts
|
|
44
|
+
/** 한 계열 — 범례 한 줄에 대응한다. */
|
|
45
|
+
export interface SBarChartSeries {
|
|
46
|
+
/** 범례·툴팁에 표시할 이름 */
|
|
47
|
+
name: string;
|
|
48
|
+
/** `categories` 와 같은 순서의 값. 짧으면 남는 항목은 막대를 그리지 않는다 */
|
|
49
|
+
data: number[];
|
|
50
|
+
}
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
### SBarChartDirection
|
|
54
|
+
|
|
55
|
+
```ts
|
|
56
|
+
/** 막대가 자라는 방향. */
|
|
57
|
+
export type SBarChartDirection = 'vertical' | 'horizontal';
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
### SBarChartPalette
|
|
61
|
+
|
|
62
|
+
```ts
|
|
63
|
+
/**
|
|
64
|
+
* 색 팔레트.
|
|
65
|
+
* - `default` 파랑 한 색. 계열이 하나거나 색으로 나눌 것이 없을 때
|
|
66
|
+
* - `multi` 서로 무관한 항목(11색)을 순서대로
|
|
67
|
+
* - `gradation` 한 지표의 단계(6색)를 진한 쪽부터 순서대로
|
|
68
|
+
* - `custom` `colors` 로 고른 색을 순서대로
|
|
69
|
+
*/
|
|
70
|
+
export type SBarChartPalette = 'default' | 'multi' | 'gradation' | 'custom';
|
|
71
|
+
```
|
|
72
|
+
|
|
73
|
+
### SBarChartColor
|
|
74
|
+
|
|
75
|
+
```ts
|
|
76
|
+
/**
|
|
77
|
+
* `palette='custom'` 에서 고를 수 있는 색 이름.
|
|
78
|
+
* positive=늘어남 · negative=줄어듦 · neutral=변화 없음 을 뜻하므로 뜻에 맞게 고른다.
|
|
79
|
+
*/
|
|
80
|
+
export type SBarChartColor =
|
|
81
|
+
| 'positivePrimary'
|
|
82
|
+
| 'positiveSecondary'
|
|
83
|
+
| 'negativePrimary'
|
|
84
|
+
| 'negativeSecondary'
|
|
85
|
+
| 'neutralPrimary'
|
|
86
|
+
| 'neutralSecondary';
|
|
87
|
+
```
|
|
88
|
+
|
|
89
|
+
### SBarChartLegendPosition
|
|
90
|
+
|
|
91
|
+
```ts
|
|
92
|
+
/** 범례 위치. */
|
|
93
|
+
export type SBarChartLegendPosition = 'top' | 'bottom';
|
|
94
|
+
```
|
|
95
|
+
|
|
96
|
+
### SBarChartPoint
|
|
97
|
+
|
|
98
|
+
```ts
|
|
99
|
+
/** 툴팁·클릭이 가리키는 지점. */
|
|
100
|
+
export interface SBarChartPoint {
|
|
101
|
+
/** 계열 인덱스 */
|
|
102
|
+
seriesIndex: number;
|
|
103
|
+
/** 카테고리 인덱스 */
|
|
104
|
+
categoryIndex: number;
|
|
105
|
+
/** 그 지점의 값 */
|
|
106
|
+
value: number;
|
|
107
|
+
}
|
|
108
|
+
```
|
|
109
|
+
|
|
110
|
+
### SBarChartTooltipCategory
|
|
111
|
+
|
|
112
|
+
```ts
|
|
113
|
+
/** 툴팁 하단(`tooltipFooter`)이 받는 짚은 항목. */
|
|
114
|
+
export interface SBarChartTooltipCategory {
|
|
115
|
+
/** 카테고리 인덱스 */
|
|
116
|
+
categoryIndex: number;
|
|
117
|
+
/** 카테고리 이름 */
|
|
118
|
+
name: string;
|
|
119
|
+
/** 툴팁에 값이 뜬 지점들 — 값이 없는 계열은 빠진다 */
|
|
120
|
+
points: SBarChartPoint[];
|
|
121
|
+
}
|
|
122
|
+
```
|
|
123
|
+
|
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
import { type CSSProperties, type ReactNode } from 'react';
|
|
2
|
+
/** 막대가 자라는 방향. */
|
|
3
|
+
export type SBarChartDirection = 'vertical' | 'horizontal';
|
|
4
|
+
/** 범례 위치. */
|
|
5
|
+
export type SBarChartLegendPosition = 'top' | 'bottom';
|
|
6
|
+
/**
|
|
7
|
+
* 색 팔레트.
|
|
8
|
+
* - `default` 파랑 한 색. 계열이 하나거나 색으로 나눌 것이 없을 때
|
|
9
|
+
* - `multi` 서로 무관한 항목(11색)을 순서대로
|
|
10
|
+
* - `gradation` 한 지표의 단계(6색)를 진한 쪽부터 순서대로
|
|
11
|
+
* - `custom` `colors` 로 고른 색을 순서대로
|
|
12
|
+
*/
|
|
13
|
+
export type SBarChartPalette = 'default' | 'multi' | 'gradation' | 'custom';
|
|
14
|
+
/**
|
|
15
|
+
* `palette='custom'` 에서 고를 수 있는 색 이름.
|
|
16
|
+
* positive=늘어남 · negative=줄어듦 · neutral=변화 없음 을 뜻하므로 뜻에 맞게 고른다.
|
|
17
|
+
*/
|
|
18
|
+
export type SBarChartColor = 'positivePrimary' | 'positiveSecondary' | 'negativePrimary' | 'negativeSecondary' | 'neutralPrimary' | 'neutralSecondary';
|
|
19
|
+
/** 툴팁·클릭이 가리키는 지점. */
|
|
20
|
+
export interface SBarChartPoint {
|
|
21
|
+
/** 계열 인덱스 */
|
|
22
|
+
seriesIndex: number;
|
|
23
|
+
/** 카테고리 인덱스 */
|
|
24
|
+
categoryIndex: number;
|
|
25
|
+
/** 그 지점의 값 */
|
|
26
|
+
value: number;
|
|
27
|
+
}
|
|
28
|
+
/** 툴팁 하단(`tooltipFooter`)이 받는 짚은 항목. */
|
|
29
|
+
export interface SBarChartTooltipCategory {
|
|
30
|
+
/** 카테고리 인덱스 */
|
|
31
|
+
categoryIndex: number;
|
|
32
|
+
/** 카테고리 이름 */
|
|
33
|
+
name: string;
|
|
34
|
+
/** 툴팁에 값이 뜬 지점들 — 값이 없는 계열은 빠진다 */
|
|
35
|
+
points: SBarChartPoint[];
|
|
36
|
+
}
|
|
37
|
+
/** 한 계열 — 범례 한 줄에 대응한다. */
|
|
38
|
+
export interface SBarChartSeries {
|
|
39
|
+
/** 범례·툴팁에 표시할 이름 */
|
|
40
|
+
name: string;
|
|
41
|
+
/** `categories` 와 같은 순서의 값. 짧으면 남는 항목은 막대를 그리지 않는다 */
|
|
42
|
+
data: number[];
|
|
43
|
+
}
|
|
44
|
+
export interface SBarChartProps {
|
|
45
|
+
/** 가로축(가로 막대면 세로축)에 놓일 항목 이름 */
|
|
46
|
+
categories: string[];
|
|
47
|
+
/** 계열 목록. 각 `data` 는 `categories` 와 같은 순서다 */
|
|
48
|
+
series: SBarChartSeries[];
|
|
49
|
+
/** 차트 제목 — 왼쪽 위에 놓인다 */
|
|
50
|
+
title?: string;
|
|
51
|
+
/** 단위 — 오른쪽 위에 "단위 : " 를 붙여 놓는다 */
|
|
52
|
+
unit?: string;
|
|
53
|
+
/** 막대가 자라는 방향 */
|
|
54
|
+
direction?: SBarChartDirection;
|
|
55
|
+
/**
|
|
56
|
+
* 계열을 나란히 놓는 대신 **한 막대에 쌓는다**. 항목의 크기와 그 안의 구성을 함께 볼 때 쓴다.
|
|
57
|
+
* 첫 계열이 기준선에 붙고, 값 라벨은 조각마다가 아니라 **항목의 합계**를 한 번 적는다.
|
|
58
|
+
* 음수는 0 아래로 따로 쌓이며, 값 축도 개별 값이 아닌 항목별 합계로 잡힌다
|
|
59
|
+
*/
|
|
60
|
+
stacked?: boolean;
|
|
61
|
+
/** 색 팔레트. 계열이 하나면 계열 대신 **항목**마다 색이 바뀐다. `custom` 일 때만 `colors` 를 본다 */
|
|
62
|
+
palette?: SBarChartPalette;
|
|
63
|
+
/** `palette='custom'` 에서 쓸 색 이름을 계열 순서대로. 계열보다 짧으면 앞에서부터 순환한다 */
|
|
64
|
+
colors?: SBarChartColor[];
|
|
65
|
+
/** 값 축의 최댓값. 주지 않으면 데이터에서 읽기 좋은 값으로 정한다 */
|
|
66
|
+
max?: number;
|
|
67
|
+
/** 값 축 눈금 개수 */
|
|
68
|
+
tickCount?: number;
|
|
69
|
+
/** 막대 두께 상한(px, 24~80). 낮추면 좌우 여백 상한도 같은 비율로 따라 내려온다 */
|
|
70
|
+
barSize?: number;
|
|
71
|
+
/** 막대마다 값을 적는다 */
|
|
72
|
+
showValueLabel?: boolean;
|
|
73
|
+
/**
|
|
74
|
+
* 항목 이름을 -45° 기울인다. 이름이 막대 묶음 폭보다 길어 서로 겹칠 때 쓴다.
|
|
75
|
+
* 기울여도 너무 긴 이름은 말줄임되고, 전체 이름은 툴팁 제목에서 읽힌다.
|
|
76
|
+
* 이름이 아주 길면 기울이기보다 `direction='horizontal'` 이 먼저다.
|
|
77
|
+
* 세로 막대에서만 쓴다 — 가로 막대는 이름 열이 가장 긴 이름에 맞춰 넓어지므로 무시한다
|
|
78
|
+
*/
|
|
79
|
+
rotateCategoryLabels?: boolean;
|
|
80
|
+
/** 범례를 보인다 */
|
|
81
|
+
showLegend?: boolean;
|
|
82
|
+
/** 범례 위치 */
|
|
83
|
+
legendPosition?: SBarChartLegendPosition;
|
|
84
|
+
/** 막대에 마우스를 올리면 값 상자를 띄운다 */
|
|
85
|
+
showTooltip?: boolean;
|
|
86
|
+
/** 값 표시 형식 */
|
|
87
|
+
formatValue?: (value: number) => string;
|
|
88
|
+
/** 차트 높이. **아래 축 텍스트까지 포함한 값**이다 — 그림은 그만큼 줄어든다 */
|
|
89
|
+
height?: number | string;
|
|
90
|
+
/** 막대를 눌렀을 때 */
|
|
91
|
+
onBarClick?: (point: SBarChartPoint) => void;
|
|
92
|
+
/**
|
|
93
|
+
* 툴팁의 값 아래에 덧붙일 내용. 짚은 항목을 받아 그린다 — 계열 값만으로 모자란 맥락
|
|
94
|
+
* (합계, 전월 대비 등)을 적는다. 툴팁은 누를 수 없으므로 버튼·링크는 넣지 않는다
|
|
95
|
+
*/
|
|
96
|
+
tooltipFooter?: (category: SBarChartTooltipCategory) => ReactNode;
|
|
97
|
+
className?: string;
|
|
98
|
+
style?: CSSProperties;
|
|
99
|
+
}
|
|
100
|
+
/**
|
|
101
|
+
* SBarChart — 막대 그래프.
|
|
102
|
+
*
|
|
103
|
+
* 값은 항상 0 에서 자란다. 음수가 있으면 기준선이 축 가운데로 내려오고 막대가
|
|
104
|
+
* 아래(또는 왼쪽)로 자란다.
|
|
105
|
+
*/
|
|
106
|
+
export declare const SBarChart: import("react").ForwardRefExoticComponent<SBarChartProps & import("react").RefAttributes<HTMLDivElement>>;
|