@eyesee/ui-components 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +37 -0
- package/dist/components/Avatar/Avatar.js +61 -0
- package/dist/components/Avatar/Avatar.module.scss.js +27 -0
- package/dist/components/Badge/Badge.js +18 -0
- package/dist/components/Badge/Badge.module.scss.js +7 -0
- package/dist/components/Badge/badgeVariants.js +29 -0
- package/dist/components/Button/Button.js +96 -0
- package/dist/components/Button/Button.module.scss.js +51 -0
- package/dist/components/Checkbox/Checkbox.js +51 -0
- package/dist/components/Checkbox/Checkbox.module.scss.js +17 -0
- package/dist/components/DropdownList/DropdownList.js +37 -0
- package/dist/components/DropdownList/DropdownList.module.scss.js +11 -0
- package/dist/components/EllipsisTooltip/EllipsisTooltip.js +40 -0
- package/dist/components/EllipsisTooltip/EllipsisTooltip.module.scss.js +9 -0
- package/dist/components/ExpandableItem/ExpandableItem.js +25 -0
- package/dist/components/ExpandableItem/ExpandableItem.module.scss.js +11 -0
- package/dist/components/Fields/InputField/InputField.js +84 -0
- package/dist/components/Fields/InputField/InputField.module.scss.js +23 -0
- package/dist/components/Fields/InputFieldContainer.js +115 -0
- package/dist/components/Fields/InputFieldContainer.module.scss.js +19 -0
- package/dist/components/Fields/SelectField/SelectField.js +220 -0
- package/dist/components/Fields/SelectField/SelectField.module.scss.js +11 -0
- package/dist/components/Fields/SelectField/SelectFieldTags.js +111 -0
- package/dist/components/Fields/SelectField/SelectFieldTags.module.scss.js +13 -0
- package/dist/components/Fields/SelectField/selectOptionRow.js +92 -0
- package/dist/components/Fields/SelectField/selectUtils.js +77 -0
- package/dist/components/Fields/TextField/TextField.js +66 -0
- package/dist/components/Fields/TextField/TextField.module.scss.js +13 -0
- package/dist/components/FileType/FileType.js +30 -0
- package/dist/components/FileType/FileType.module.scss.js +15 -0
- package/dist/components/FileType/PaperIcon.js +22 -0
- package/dist/components/ImagePlaceholder/ImagePlaceholder.js +146 -0
- package/dist/components/ImagePlaceholder/ImagePlaceholder.module.scss.js +39 -0
- package/dist/components/ImagePlaceholder/constantsImgPh.js +15 -0
- package/dist/components/ImagePlaceholder/utilsImgPh.js +19 -0
- package/dist/components/ImageWithData/ImageWithData.js +146 -0
- package/dist/components/ImageWithData/ImageWithData.module.scss.js +39 -0
- package/dist/components/Infobox/Infobox.js +33 -0
- package/dist/components/Infobox/Infobox.module.scss.js +19 -0
- package/dist/components/Infobox/infoboxVariants.js +31 -0
- package/dist/components/ListItem/ListItem.js +69 -0
- package/dist/components/ListItem/ListItem.module.scss.js +21 -0
- package/dist/components/ListItem/useListItems.js +58 -0
- package/dist/components/Modal/Modal.js +70 -0
- package/dist/components/Modal/Modal.module.scss.js +21 -0
- package/dist/components/Notifications/Notifications.js +119 -0
- package/dist/components/Notifications/Notifications.module.scss.js +21 -0
- package/dist/components/Notifications/useNotifications.js +103 -0
- package/dist/components/Pill/Pill.js +32 -0
- package/dist/components/Pill/Pill.module.scss.js +13 -0
- package/dist/components/Pill/pillVariants.js +36 -0
- package/dist/components/ProgressBar/ProgressBar.js +48 -0
- package/dist/components/ProgressBar/ProgressBar.module.scss.js +19 -0
- package/dist/components/Radio/Radio.js +20 -0
- package/dist/components/Radio/Radio.module.scss.js +15 -0
- package/dist/components/Tab/Tab.js +51 -0
- package/dist/components/Tab/Tab.module.scss.js +43 -0
- package/dist/components/Tabs/Tabs.js +62 -0
- package/dist/components/Tabs/Tabs.module.scss.js +17 -0
- package/dist/components/Tabs/tabsUtils.js +17 -0
- package/dist/components/Tag/Tag.js +49 -0
- package/dist/components/Tag/Tag.module.scss.js +25 -0
- package/dist/components/Tag/tagVariants.js +5 -0
- package/dist/components/TextHoverable/TextHoverable.js +14 -0
- package/dist/components/TextHoverable/TextHoverable.module.scss.js +9 -0
- package/dist/components/Toggle/Toggle.js +59 -0
- package/dist/components/Toggle/Toggle.module.scss.js +21 -0
- package/dist/components/Tooltip/Tooltip.js +103 -0
- package/dist/components/Tooltip/Tooltip.module.scss.js +39 -0
- package/dist/components/Tooltip/useTooltipPositioning.js +60 -0
- package/dist/components/icons-v2/AdIcon.js +48 -0
- package/dist/components/icons-v2/AddMessageIcon.js +37 -0
- package/dist/components/icons-v2/AddUserIcon.js +47 -0
- package/dist/components/icons-v2/AdjustmentsIcon.js +15 -0
- package/dist/components/icons-v2/AlertIcon.js +37 -0
- package/dist/components/icons-v2/AlignCenterIcon.js +47 -0
- package/dist/components/icons-v2/AlignHorizontallyIcon.js +47 -0
- package/dist/components/icons-v2/AlignJustifyIcon.js +47 -0
- package/dist/components/icons-v2/AlignLeftIcon.js +47 -0
- package/dist/components/icons-v2/AlignRightIcon.js +47 -0
- package/dist/components/icons-v2/AlignVerticallyIcon.js +47 -0
- package/dist/components/icons-v2/AlphabetIcon.js +37 -0
- package/dist/components/icons-v2/ArchiveIcon.js +37 -0
- package/dist/components/icons-v2/ArrowDownIcon.js +37 -0
- package/dist/components/icons-v2/ArrowDownRightIcon.js +15 -0
- package/dist/components/icons-v2/ArrowLeftIcon.js +37 -0
- package/dist/components/icons-v2/ArrowMoveDownIcon.js +37 -0
- package/dist/components/icons-v2/ArrowRightIcon.js +37 -0
- package/dist/components/icons-v2/ArrowUpIcon.js +37 -0
- package/dist/components/icons-v2/AttributesEvaluationIcon.js +77 -0
- package/dist/components/icons-v2/BellIcon.js +15 -0
- package/dist/components/icons-v2/BoldIcon.js +27 -0
- package/dist/components/icons-v2/BoltIcon.js +15 -0
- package/dist/components/icons-v2/BookIcon.js +15 -0
- package/dist/components/icons-v2/BookmarkIcon.js +15 -0
- package/dist/components/icons-v2/BooksIcon.js +77 -0
- package/dist/components/icons-v2/BoxIcon.js +15 -0
- package/dist/components/icons-v2/BugIcon.js +97 -0
- package/dist/components/icons-v2/CalendarIcon.js +47 -0
- package/dist/components/icons-v2/CameraPlusIcon.js +15 -0
- package/dist/components/icons-v2/CardsIcon.js +15 -0
- package/dist/components/icons-v2/CellIcon.js +15 -0
- package/dist/components/icons-v2/ChartbarIcon.js +47 -0
- package/dist/components/icons-v2/ChartbarOffIcon.js +15 -0
- package/dist/components/icons-v2/ChatBubbleIcon.js +15 -0
- package/dist/components/icons-v2/ChatbotIcon.js +15 -0
- package/dist/components/icons-v2/CheckCircleIcon.js +27 -0
- package/dist/components/icons-v2/CheckboxIcon.js +27 -0
- package/dist/components/icons-v2/CheckmarkDoubleIcon.js +27 -0
- package/dist/components/icons-v2/CheckmarkLargeIcon.js +15 -0
- package/dist/components/icons-v2/ChevronDownIcon.js +15 -0
- package/dist/components/icons-v2/ChevronLeftIcon.js +15 -0
- package/dist/components/icons-v2/ChevronRightIcon.js +15 -0
- package/dist/components/icons-v2/ChevronUpIcon.js +15 -0
- package/dist/components/icons-v2/ChevronsDownIcon.js +27 -0
- package/dist/components/icons-v2/ChevronsLeftIcon.js +27 -0
- package/dist/components/icons-v2/ChevronsRightIcon.js +27 -0
- package/dist/components/icons-v2/ChevronsUpIcon.js +27 -0
- package/dist/components/icons-v2/CircleIcon.js +12 -0
- package/dist/components/icons-v2/CirclesIcon.js +37 -0
- package/dist/components/icons-v2/ClickIcon.js +67 -0
- package/dist/components/icons-v2/ClipboardIcon.js +27 -0
- package/dist/components/icons-v2/ClockIcon.js +27 -0
- package/dist/components/icons-v2/ClockShareIcon.js +15 -0
- package/dist/components/icons-v2/CloseIcon.js +37 -0
- package/dist/components/icons-v2/CopyIcon.js +27 -0
- package/dist/components/icons-v2/CreditCardIcon.js +15 -0
- package/dist/components/icons-v2/CropIcon.js +27 -0
- package/dist/components/icons-v2/DashboardMeterIcon.js +37 -0
- package/dist/components/icons-v2/DatabaseCheckIcon.js +47 -0
- package/dist/components/icons-v2/DatabaseIcon.js +37 -0
- package/dist/components/icons-v2/DeleteIcon.js +47 -0
- package/dist/components/icons-v2/DetailsIcon.js +47 -0
- package/dist/components/icons-v2/DevicesIcon.js +37 -0
- package/dist/components/icons-v2/DislikeIcon.js +15 -0
- package/dist/components/icons-v2/DollarIcon.js +15 -0
- package/dist/components/icons-v2/DownloadIcon.js +15 -0
- package/dist/components/icons-v2/DragToolIcon.js +73 -0
- package/dist/components/icons-v2/DrawRectangleIcon.js +87 -0
- package/dist/components/icons-v2/EditIcon.js +27 -0
- package/dist/components/icons-v2/EmailIcon.js +27 -0
- package/dist/components/icons-v2/EmojiNeutralIcon.js +15 -0
- package/dist/components/icons-v2/EmojiSadIcon.js +15 -0
- package/dist/components/icons-v2/EmojiSlightSmileyIcon.js +15 -0
- package/dist/components/icons-v2/EmojiSmileyIcon.js +47 -0
- package/dist/components/icons-v2/EmojiVerySadIcon.js +15 -0
- package/dist/components/icons-v2/EraserIcon.js +27 -0
- package/dist/components/icons-v2/EtShelfIcon.js +127 -0
- package/dist/components/icons-v2/EtStandaloneIcon.js +57 -0
- package/dist/components/icons-v2/ExternalLinkIcon.js +15 -0
- package/dist/components/icons-v2/FileExportIcon.js +27 -0
- package/dist/components/icons-v2/FileIcon.js +27 -0
- package/dist/components/icons-v2/FileImportIcon.js +27 -0
- package/dist/components/icons-v2/FileNewIcon.js +47 -0
- package/dist/components/icons-v2/FileRemoveIcon.js +37 -0
- package/dist/components/icons-v2/FileTemplateIcon.js +15 -0
- package/dist/components/icons-v2/FileUploadIcon.js +15 -0
- package/dist/components/icons-v2/FilesIcon.js +15 -0
- package/dist/components/icons-v2/FilterOffIcon.js +27 -0
- package/dist/components/icons-v2/FilterOnIcon.js +15 -0
- package/dist/components/icons-v2/FlagIcon.js +27 -0
- package/dist/components/icons-v2/FolderIcon.js +15 -0
- package/dist/components/icons-v2/FullscreenIcon.js +15 -0
- package/dist/components/icons-v2/GridviewIcon.js +47 -0
- package/dist/components/icons-v2/HelpIcon.js +37 -0
- package/dist/components/icons-v2/HomeIcon.js +27 -0
- package/dist/components/icons-v2/ImageIcon.js +15 -0
- package/dist/components/icons-v2/ImageOffIcon.js +15 -0
- package/dist/components/icons-v2/ImageStarIcon.js +15 -0
- package/dist/components/icons-v2/ImageUploadIcon.js +15 -0
- package/dist/components/icons-v2/InfoIcon.js +37 -0
- package/dist/components/icons-v2/ItalicIcon.js +37 -0
- package/dist/components/icons-v2/LanguageIcon.js +15 -0
- package/dist/components/icons-v2/LaunchIcon.js +37 -0
- package/dist/components/icons-v2/LayersIcon.js +37 -0
- package/dist/components/icons-v2/LeftSidebarCollapseIcon.js +15 -0
- package/dist/components/icons-v2/LeftSidebarExpandIcon.js +15 -0
- package/dist/components/icons-v2/LightDarkIcon.js +67 -0
- package/dist/components/icons-v2/LightbulbIcon.js +37 -0
- package/dist/components/icons-v2/LikeIcon.js +15 -0
- package/dist/components/icons-v2/LinkIcon.js +27 -0
- package/dist/components/icons-v2/ListViewIcon.js +67 -0
- package/dist/components/icons-v2/LoaderIcon.js +90 -0
- package/dist/components/icons-v2/LoadingIcon.js +70 -0
- package/dist/components/icons-v2/LockIcon.js +27 -0
- package/dist/components/icons-v2/LockOffIcon.js +27 -0
- package/dist/components/icons-v2/LoginIcon.js +37 -0
- package/dist/components/icons-v2/LogoutIcon.js +37 -0
- package/dist/components/icons-v2/MagicwandIcon.js +15 -0
- package/dist/components/icons-v2/MaximizeIcon.js +47 -0
- package/dist/components/icons-v2/MenuIcon.js +37 -0
- package/dist/components/icons-v2/MessageIcon.js +37 -0
- package/dist/components/icons-v2/MeterIcon.js +97 -0
- package/dist/components/icons-v2/MinimizeIcon.js +47 -0
- package/dist/components/icons-v2/MinusIcon.js +15 -0
- package/dist/components/icons-v2/MoreHorizontalIcon.js +40 -0
- package/dist/components/icons-v2/MoreIcon.js +40 -0
- package/dist/components/icons-v2/MouseIcon.js +27 -0
- package/dist/components/icons-v2/MoveIcon.js +67 -0
- package/dist/components/icons-v2/Multiplier05Icon.js +15 -0
- package/dist/components/icons-v2/Multiplier10Icon.js +15 -0
- package/dist/components/icons-v2/Multiplier15Icon.js +15 -0
- package/dist/components/icons-v2/Multiplier20Icon.js +15 -0
- package/dist/components/icons-v2/NoteIcon.js +47 -0
- package/dist/components/icons-v2/NoteOffIcon.js +57 -0
- package/dist/components/icons-v2/NotifyIcon.js +15 -0
- package/dist/components/icons-v2/PackAIIcon.js +27 -0
- package/dist/components/icons-v2/PaperclipIcon.js +15 -0
- package/dist/components/icons-v2/PauseIcon.js +27 -0
- package/dist/components/icons-v2/PdfIcon.js +67 -0
- package/dist/components/icons-v2/PentoolIcon.js +47 -0
- package/dist/components/icons-v2/PiechartIcon.js +27 -0
- package/dist/components/icons-v2/PinIcon.js +37 -0
- package/dist/components/icons-v2/PinskewedIcon.js +37 -0
- package/dist/components/icons-v2/PlayIcon.js +15 -0
- package/dist/components/icons-v2/PlusIcon.js +27 -0
- package/dist/components/icons-v2/PredictiveETIcon.js +77 -0
- package/dist/components/icons-v2/RedoIcon.js +27 -0
- package/dist/components/icons-v2/RefreshAlertIcon.js +15 -0
- package/dist/components/icons-v2/RefreshIcon.js +15 -0
- package/dist/components/icons-v2/ReplaceIcon.js +15 -0
- package/dist/components/icons-v2/ReplyIcon.js +13 -0
- package/dist/components/icons-v2/SaveIcon.js +37 -0
- package/dist/components/icons-v2/ScalesIcon.js +57 -0
- package/dist/components/icons-v2/SearchIcon.js +27 -0
- package/dist/components/icons-v2/SendIcon.js +27 -0
- package/dist/components/icons-v2/SettingsIcon.js +27 -0
- package/dist/components/icons-v2/ShareIcon.js +27 -0
- package/dist/components/icons-v2/ShoppingIcon.js +47 -0
- package/dist/components/icons-v2/SlideshowIcon.js +77 -0
- package/dist/components/icons-v2/SocialFacebookIcon.js +15 -0
- package/dist/components/icons-v2/SocialInstagramIcon.js +37 -0
- package/dist/components/icons-v2/SocialSnapchatIcon.js +15 -0
- package/dist/components/icons-v2/SocialTiktok2Icon.js +15 -0
- package/dist/components/icons-v2/SocialTiktokIcon.js +15 -0
- package/dist/components/icons-v2/SocialXIcon.js +27 -0
- package/dist/components/icons-v2/SocialYoutubeIcon.js +27 -0
- package/dist/components/icons-v2/SortHorizontalIcon.js +77 -0
- package/dist/components/icons-v2/StarIcon.js +15 -0
- package/dist/components/icons-v2/StopIcon.js +13 -0
- package/dist/components/icons-v2/SurveyIcon.js +37 -0
- package/dist/components/icons-v2/TableExportIcon.js +57 -0
- package/dist/components/icons-v2/TableIcon.js +37 -0
- package/dist/components/icons-v2/TableOptionsIcon.js +107 -0
- package/dist/components/icons-v2/TagIcon.js +27 -0
- package/dist/components/icons-v2/TargetArrowIcon.js +57 -0
- package/dist/components/icons-v2/TargetIcon.js +68 -0
- package/dist/components/icons-v2/TextRecognitionIcon.js +67 -0
- package/dist/components/icons-v2/TriangleFlagIcon.js +15 -0
- package/dist/components/icons-v2/TrophyIcon.js +15 -0
- package/dist/components/icons-v2/UnderlineIcon.js +27 -0
- package/dist/components/icons-v2/UndoIcon.js +27 -0
- package/dist/components/icons-v2/UnitBuyRateIcon.js +27 -0
- package/dist/components/icons-v2/UploadIcon.js +15 -0
- package/dist/components/icons-v2/UserGroupIcon.js +67 -0
- package/dist/components/icons-v2/UserIcon.js +27 -0
- package/dist/components/icons-v2/UsersIcon.js +47 -0
- package/dist/components/icons-v2/ValueBuyRateIcon.js +15 -0
- package/dist/components/icons-v2/VideoIcon.js +27 -0
- package/dist/components/icons-v2/ViewOffIcon.js +27 -0
- package/dist/components/icons-v2/ViewOnIcon.js +27 -0
- package/dist/components/icons-v2/VolumeOffIcon.js +15 -0
- package/dist/components/icons-v2/VolumeOnIcon.js +15 -0
- package/dist/components/icons-v2/WebIcon.js +57 -0
- package/dist/components/icons-v2/XIcon.js +27 -0
- package/dist/components/icons-v2/ZipFileIcon.js +15 -0
- package/dist/components/icons-v2/ZonePercentageIcon.js +107 -0
- package/dist/components/icons-v2/ZoomInIcon.js +47 -0
- package/dist/components/icons-v2/ZoomOutIcon.js +37 -0
- package/dist/components/icons-v2/constants.js +23 -0
- package/dist/components/icons-v2/createIcon.js +52 -0
- package/dist/components/icons-v2/createIcon.module.scss.js +15 -0
- package/dist/components/icons-v2/index.js +400 -0
- package/dist/hooks/useClickOutside.js +12 -0
- package/dist/hooks/useEscapeKey.js +13 -0
- package/dist/index.js +62 -0
- package/dist/style.css +1 -0
- package/package.json +56 -0
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import { jsx as t, jsxs as x } from "react/jsx-runtime";
|
|
2
|
+
import j from "clsx";
|
|
3
|
+
import o from "./Tab.module.scss.js";
|
|
4
|
+
import { Tooltip as w } from "../Tooltip/Tooltip.js";
|
|
5
|
+
import { HelpIcon as T } from "../icons-v2/HelpIcon.js";
|
|
6
|
+
const I = ({
|
|
7
|
+
label: m = "Tab",
|
|
8
|
+
startIcon: u,
|
|
9
|
+
variant: p,
|
|
10
|
+
spacing: f,
|
|
11
|
+
type: n,
|
|
12
|
+
position: h,
|
|
13
|
+
underline: b,
|
|
14
|
+
disabled: r = !1,
|
|
15
|
+
selected: s = !1,
|
|
16
|
+
onClick: e = () => {
|
|
17
|
+
},
|
|
18
|
+
as: l = "button",
|
|
19
|
+
tooltipText: a = null,
|
|
20
|
+
tooltipTitle: d = null
|
|
21
|
+
}) => {
|
|
22
|
+
const c = j(
|
|
23
|
+
o.tab,
|
|
24
|
+
o[p],
|
|
25
|
+
o[n],
|
|
26
|
+
o[l],
|
|
27
|
+
o[f],
|
|
28
|
+
o[h],
|
|
29
|
+
s && o.selected,
|
|
30
|
+
b && o.underline,
|
|
31
|
+
r && o.disabled
|
|
32
|
+
), N = r || n === "color" && s ? "currentColor" : "var(--color--icon--default--default-lighter)", i = /* @__PURE__ */ x("span", { className: o.content, children: [
|
|
33
|
+
u,
|
|
34
|
+
/* @__PURE__ */ t("span", { children: m }),
|
|
35
|
+
a && /* @__PURE__ */ t(
|
|
36
|
+
w,
|
|
37
|
+
{
|
|
38
|
+
title: d,
|
|
39
|
+
content: a,
|
|
40
|
+
position: "bottom",
|
|
41
|
+
showArrow: !0,
|
|
42
|
+
disabled: r,
|
|
43
|
+
children: /* @__PURE__ */ t(T, { strokeColor: N })
|
|
44
|
+
}
|
|
45
|
+
)
|
|
46
|
+
] });
|
|
47
|
+
return l === "span" ? /* @__PURE__ */ t("span", { className: c, onClick: e, "aria-disabled": r, children: i }) : /* @__PURE__ */ t("button", { className: c, disabled: r, onClick: e, type: "button", children: i });
|
|
48
|
+
};
|
|
49
|
+
export {
|
|
50
|
+
I as Tab
|
|
51
|
+
};
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
const _ = "_content_6grmq_1", t = "_tab_6grmq_7", n = "_span_6grmq_11", o = "_sm_6grmq_14", s = "_md_6grmq_17", e = "_lg_6grmq_20", r = "_xl_6grmq_23", c = "_selected_6grmq_26", l = "_primary_6grmq_26", m = "_disabled_6grmq_26", g = "_secondary_6grmq_29", a = "_underline_6grmq_32", d = "_button_6grmq_42", q = "_outline_6grmq_45", i = "_color_6grmq_45", u = "_standalone_6grmq_48", b = "_left_6grmq_52", p = "_right_6grmq_55", y = "_white_6grmq_58", h = {
|
|
2
|
+
content: _,
|
|
3
|
+
tab: t,
|
|
4
|
+
span: n,
|
|
5
|
+
sm: o,
|
|
6
|
+
md: s,
|
|
7
|
+
lg: e,
|
|
8
|
+
xl: r,
|
|
9
|
+
selected: c,
|
|
10
|
+
primary: l,
|
|
11
|
+
disabled: m,
|
|
12
|
+
secondary: g,
|
|
13
|
+
underline: a,
|
|
14
|
+
button: d,
|
|
15
|
+
outline: q,
|
|
16
|
+
color: i,
|
|
17
|
+
standalone: u,
|
|
18
|
+
left: b,
|
|
19
|
+
right: p,
|
|
20
|
+
white: y
|
|
21
|
+
};
|
|
22
|
+
export {
|
|
23
|
+
d as button,
|
|
24
|
+
i as color,
|
|
25
|
+
_ as content,
|
|
26
|
+
h as default,
|
|
27
|
+
m as disabled,
|
|
28
|
+
b as left,
|
|
29
|
+
e as lg,
|
|
30
|
+
s as md,
|
|
31
|
+
q as outline,
|
|
32
|
+
l as primary,
|
|
33
|
+
p as right,
|
|
34
|
+
g as secondary,
|
|
35
|
+
c as selected,
|
|
36
|
+
o as sm,
|
|
37
|
+
n as span,
|
|
38
|
+
u as standalone,
|
|
39
|
+
t as tab,
|
|
40
|
+
a as underline,
|
|
41
|
+
y as white,
|
|
42
|
+
r as xl
|
|
43
|
+
};
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
import { jsx as b } from "react/jsx-runtime";
|
|
2
|
+
import { useMemo as h } from "react";
|
|
3
|
+
import D from "clsx";
|
|
4
|
+
import { Tab as E } from "../Tab/Tab.js";
|
|
5
|
+
import { normalizeTabsOptions as F, normalizeTabOption as G, getTrimmedLabel as m } from "./tabsUtils.js";
|
|
6
|
+
import x from "./Tabs.module.scss.js";
|
|
7
|
+
const X = ({
|
|
8
|
+
options: l,
|
|
9
|
+
onTabChange: g = () => {
|
|
10
|
+
},
|
|
11
|
+
selectedTab: u = l[0],
|
|
12
|
+
variant: v = "primary",
|
|
13
|
+
type: A = "outline",
|
|
14
|
+
spacing: I = "md",
|
|
15
|
+
gapSpacing: c = "md",
|
|
16
|
+
tabVariant: d = "text",
|
|
17
|
+
positionStandalone: j = !1,
|
|
18
|
+
underline: C = !1,
|
|
19
|
+
keyLabel: e = "label",
|
|
20
|
+
keyTooltipText: t = "tooltipText",
|
|
21
|
+
keyTooltipTitle: s = "tooltipTitle",
|
|
22
|
+
startIcon: M = null,
|
|
23
|
+
disabled: N = !1
|
|
24
|
+
}) => {
|
|
25
|
+
const a = h(
|
|
26
|
+
() => F(l, e, t, s),
|
|
27
|
+
[l, e, t, s]
|
|
28
|
+
), f = h(
|
|
29
|
+
() => G(u, e, t, s),
|
|
30
|
+
[e, u, t, s]
|
|
31
|
+
), O = (r) => {
|
|
32
|
+
r.disabled || g(r);
|
|
33
|
+
}, P = (r, n) => j && d === "button" || d === "text" || n <= 1 ? "standalone" : r === 0 ? "left" : r === n - 1 ? "right" : "middle", i = (l == null ? void 0 : l.filter((r) => !(r != null && r.hidden))) ?? [];
|
|
34
|
+
return /* @__PURE__ */ b("div", { className: D(x.tabsWrapper, x[c]), children: a == null ? void 0 : a.map((r) => {
|
|
35
|
+
if (r != null && r.hidden) return null;
|
|
36
|
+
const n = m(r.label) === m(f == null ? void 0 : f.label), W = i.findIndex(
|
|
37
|
+
({ label: B }) => m(B) === m(r.label)
|
|
38
|
+
), q = P(W, i.length), w = r.tooltipText || null, z = r.tooltipTitle || null;
|
|
39
|
+
return /* @__PURE__ */ b(
|
|
40
|
+
E,
|
|
41
|
+
{
|
|
42
|
+
as: d === "text" ? "span" : "button",
|
|
43
|
+
label: r.label,
|
|
44
|
+
variant: v,
|
|
45
|
+
type: A,
|
|
46
|
+
underline: C,
|
|
47
|
+
spacing: I,
|
|
48
|
+
gapSpacing: c,
|
|
49
|
+
position: q,
|
|
50
|
+
disabled: r.disabled || N,
|
|
51
|
+
selected: n,
|
|
52
|
+
onClick: () => O(r),
|
|
53
|
+
startIcon: M,
|
|
54
|
+
tooltipText: w,
|
|
55
|
+
tooltipTitle: z
|
|
56
|
+
}
|
|
57
|
+
);
|
|
58
|
+
}) });
|
|
59
|
+
};
|
|
60
|
+
export {
|
|
61
|
+
X as Tabs
|
|
62
|
+
};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
const s = "_tabsWrapper_17abb_1", _ = "_xs_17abb_20", b = "_sm_17abb_23", a = "_md_17abb_26", t = "_lg_17abb_29", l = "_xl_17abb_32", o = {
|
|
2
|
+
tabsWrapper: s,
|
|
3
|
+
xs: _,
|
|
4
|
+
sm: b,
|
|
5
|
+
md: a,
|
|
6
|
+
lg: t,
|
|
7
|
+
xl: l
|
|
8
|
+
};
|
|
9
|
+
export {
|
|
10
|
+
o as default,
|
|
11
|
+
t as lg,
|
|
12
|
+
a as md,
|
|
13
|
+
b as sm,
|
|
14
|
+
s as tabsWrapper,
|
|
15
|
+
l as xl,
|
|
16
|
+
_ as xs
|
|
17
|
+
};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
const n = (r, t, e, s) => {
|
|
2
|
+
if (!r) return r;
|
|
3
|
+
const a = r[t], c = r[e], m = r[s];
|
|
4
|
+
return {
|
|
5
|
+
...r,
|
|
6
|
+
label: a,
|
|
7
|
+
tooltipText: c,
|
|
8
|
+
tooltipTitle: m
|
|
9
|
+
};
|
|
10
|
+
}, i = (r = [], t, e, s) => Array.isArray(r) ? r.map(
|
|
11
|
+
(a) => n(a, t, e, s)
|
|
12
|
+
) : [], o = (r) => (r == null ? void 0 : r.toLowerCase().trim()) ?? "";
|
|
13
|
+
export {
|
|
14
|
+
o as getTrimmedLabel,
|
|
15
|
+
n as normalizeTabOption,
|
|
16
|
+
i as normalizeTabsOptions
|
|
17
|
+
};
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import { jsxs as o, jsx as a } from "react/jsx-runtime";
|
|
2
|
+
import d from "clsx";
|
|
3
|
+
import { HelpIcon as m } from "../icons-v2/HelpIcon.js";
|
|
4
|
+
import { XIcon as p } from "../icons-v2/XIcon.js";
|
|
5
|
+
import { TAG_SHAPES as u } from "./tagVariants.js";
|
|
6
|
+
import e from "./Tag.module.scss.js";
|
|
7
|
+
const f = {
|
|
8
|
+
default: e.stateDefault,
|
|
9
|
+
secondary: e.stateSecondary,
|
|
10
|
+
disabled: e.stateDisabled
|
|
11
|
+
}, A = ({
|
|
12
|
+
label: s,
|
|
13
|
+
shape: l = "rectangle",
|
|
14
|
+
state: t = "default",
|
|
15
|
+
showLeadingIcon: i = !1,
|
|
16
|
+
showDismiss: r = !0,
|
|
17
|
+
onDismiss: n
|
|
18
|
+
}) => {
|
|
19
|
+
if (s == null || s === "") return null;
|
|
20
|
+
const c = (u.includes(l) ? l : "rectangle") === "pill" ? e.shapePill : e.shapeRectangle;
|
|
21
|
+
return /* @__PURE__ */ o(
|
|
22
|
+
"span",
|
|
23
|
+
{
|
|
24
|
+
className: d(
|
|
25
|
+
e.tag,
|
|
26
|
+
c,
|
|
27
|
+
f[t] ?? e.stateDefault
|
|
28
|
+
),
|
|
29
|
+
children: [
|
|
30
|
+
i && /* @__PURE__ */ a("span", { className: e.icon, "aria-hidden": !0, children: /* @__PURE__ */ a(m, { iconSize: "m" }) }),
|
|
31
|
+
/* @__PURE__ */ a("span", { className: e.label, children: s }),
|
|
32
|
+
r && n ? /* @__PURE__ */ a(
|
|
33
|
+
"button",
|
|
34
|
+
{
|
|
35
|
+
type: "button",
|
|
36
|
+
className: e.dismiss,
|
|
37
|
+
onClick: n,
|
|
38
|
+
disabled: t === "disabled",
|
|
39
|
+
"aria-label": `Remove ${s}`,
|
|
40
|
+
children: /* @__PURE__ */ a("span", { className: e.dismissIcon, "aria-hidden": !0, children: /* @__PURE__ */ a(p, { iconSize: "m" }) })
|
|
41
|
+
}
|
|
42
|
+
) : null
|
|
43
|
+
]
|
|
44
|
+
}
|
|
45
|
+
);
|
|
46
|
+
};
|
|
47
|
+
export {
|
|
48
|
+
A as Tag
|
|
49
|
+
};
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
const s = "_tag_573f2_1", t = "_stateDefault_573f2_26", e = "_stateSecondary_573f2_30", a = "_stateDisabled_573f2_34", _ = "_shapeRectangle_573f2_38", c = "_shapePill_573f2_42", l = "_label_573f2_46", n = "_dismiss_573f2_50", i = "_dismissIcon_573f2_72", o = "_icon_573f2_73", f = {
|
|
2
|
+
tag: s,
|
|
3
|
+
stateDefault: t,
|
|
4
|
+
stateSecondary: e,
|
|
5
|
+
stateDisabled: a,
|
|
6
|
+
shapeRectangle: _,
|
|
7
|
+
shapePill: c,
|
|
8
|
+
label: l,
|
|
9
|
+
dismiss: n,
|
|
10
|
+
dismissIcon: i,
|
|
11
|
+
icon: o
|
|
12
|
+
};
|
|
13
|
+
export {
|
|
14
|
+
f as default,
|
|
15
|
+
n as dismiss,
|
|
16
|
+
i as dismissIcon,
|
|
17
|
+
o as icon,
|
|
18
|
+
l as label,
|
|
19
|
+
c as shapePill,
|
|
20
|
+
_ as shapeRectangle,
|
|
21
|
+
t as stateDefault,
|
|
22
|
+
a as stateDisabled,
|
|
23
|
+
e as stateSecondary,
|
|
24
|
+
s as tag
|
|
25
|
+
};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { jsx as e } from "react/jsx-runtime";
|
|
2
|
+
import a from "clsx";
|
|
3
|
+
import t from "./TextHoverable.module.scss.js";
|
|
4
|
+
const x = ({ children: o, className: r, ...s }) => /* @__PURE__ */ e(
|
|
5
|
+
"span",
|
|
6
|
+
{
|
|
7
|
+
className: a(t.textHoverable, r),
|
|
8
|
+
...s,
|
|
9
|
+
children: /* @__PURE__ */ e("span", { className: t.text, children: o })
|
|
10
|
+
}
|
|
11
|
+
);
|
|
12
|
+
export {
|
|
13
|
+
x as TextHoverable
|
|
14
|
+
};
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
import { jsxs as g, jsx as e } from "react/jsx-runtime";
|
|
2
|
+
import { useId as k } from "react";
|
|
3
|
+
import x from "clsx";
|
|
4
|
+
import o from "./Toggle.module.scss.js";
|
|
5
|
+
import { CircleIcon as N } from "../icons-v2/CircleIcon.js";
|
|
6
|
+
const v = {
|
|
7
|
+
lg: "m",
|
|
8
|
+
md: "s"
|
|
9
|
+
}, y = {
|
|
10
|
+
checked: {
|
|
11
|
+
default: "var(--color--icon--on-color--on-color)",
|
|
12
|
+
disabled: "var(--color--icon--on-color--on-color)"
|
|
13
|
+
},
|
|
14
|
+
unchecked: {
|
|
15
|
+
default: "var(--color--icon--secondary--default)",
|
|
16
|
+
disabled: "var(--color--icon--disabled--default)"
|
|
17
|
+
}
|
|
18
|
+
}, E = ({
|
|
19
|
+
label: l,
|
|
20
|
+
checked: r = !1,
|
|
21
|
+
onChange: n,
|
|
22
|
+
disabled: c = !1,
|
|
23
|
+
size: a = "lg",
|
|
24
|
+
id: d,
|
|
25
|
+
name: i,
|
|
26
|
+
value: m,
|
|
27
|
+
"aria-label": u
|
|
28
|
+
}) => {
|
|
29
|
+
const h = k(), s = d ?? h, p = v[a], f = r ? "checked" : "unchecked", b = c ? "disabled" : "default", t = y[f][b];
|
|
30
|
+
return /* @__PURE__ */ g(
|
|
31
|
+
"label",
|
|
32
|
+
{
|
|
33
|
+
className: x(o.toggleWrapper, o[a], c && o.disabled),
|
|
34
|
+
htmlFor: s,
|
|
35
|
+
children: [
|
|
36
|
+
/* @__PURE__ */ e(
|
|
37
|
+
"input",
|
|
38
|
+
{
|
|
39
|
+
id: s,
|
|
40
|
+
type: "checkbox",
|
|
41
|
+
role: "switch",
|
|
42
|
+
name: i,
|
|
43
|
+
value: m,
|
|
44
|
+
className: o.input,
|
|
45
|
+
checked: r,
|
|
46
|
+
disabled: c,
|
|
47
|
+
"aria-label": u ?? (l ? void 0 : "toggle"),
|
|
48
|
+
onChange: n
|
|
49
|
+
}
|
|
50
|
+
),
|
|
51
|
+
/* @__PURE__ */ e("span", { className: o.track, "aria-hidden": !0, children: /* @__PURE__ */ e("span", { className: o.thumb, children: /* @__PURE__ */ e(N, { iconSize: p, strokeColor: t, fill: t }) }) }),
|
|
52
|
+
l ? /* @__PURE__ */ e("span", { className: o.labelText, children: l }) : null
|
|
53
|
+
]
|
|
54
|
+
}
|
|
55
|
+
);
|
|
56
|
+
};
|
|
57
|
+
export {
|
|
58
|
+
E as Toggle
|
|
59
|
+
};
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
const t = "_toggleWrapper_idg1v_1", _ = "_lg_idg1v_10", d = "_md_idg1v_19", e = "_input_idg1v_31", g = "_labelText_idg1v_42", l = "_track_idg1v_60", a = "_thumb_idg1v_70", i = "_disabled_idg1v_92", s = {
|
|
2
|
+
toggleWrapper: t,
|
|
3
|
+
lg: _,
|
|
4
|
+
md: d,
|
|
5
|
+
input: e,
|
|
6
|
+
labelText: g,
|
|
7
|
+
track: l,
|
|
8
|
+
thumb: a,
|
|
9
|
+
disabled: i
|
|
10
|
+
};
|
|
11
|
+
export {
|
|
12
|
+
s as default,
|
|
13
|
+
i as disabled,
|
|
14
|
+
e as input,
|
|
15
|
+
g as labelText,
|
|
16
|
+
_ as lg,
|
|
17
|
+
d as md,
|
|
18
|
+
a as thumb,
|
|
19
|
+
t as toggleWrapper,
|
|
20
|
+
l as track
|
|
21
|
+
};
|
|
@@ -0,0 +1,103 @@
|
|
|
1
|
+
import { jsxs as a, jsx as s } from "react/jsx-runtime";
|
|
2
|
+
import { useState as M, useEffect as A } from "react";
|
|
3
|
+
import h from "clsx";
|
|
4
|
+
import { createPortal as F } from "react-dom";
|
|
5
|
+
import { HelpIcon as k } from "../icons-v2/HelpIcon.js";
|
|
6
|
+
import { XIcon as B } from "../icons-v2/XIcon.js";
|
|
7
|
+
import o from "./Tooltip.module.scss.js";
|
|
8
|
+
import { useTooltipPositioning as G } from "./useTooltipPositioning.js";
|
|
9
|
+
const V = ({
|
|
10
|
+
children: v,
|
|
11
|
+
content: f,
|
|
12
|
+
title: t,
|
|
13
|
+
showInfoIcon: n = !1,
|
|
14
|
+
variant: E = "dark",
|
|
15
|
+
showArrow: N = !1,
|
|
16
|
+
defaultVisible: i = !1,
|
|
17
|
+
closable: p = !1,
|
|
18
|
+
disabled: m = !1,
|
|
19
|
+
className: R,
|
|
20
|
+
contentClassName: j,
|
|
21
|
+
position: D = "top",
|
|
22
|
+
maxWidth: w = 240,
|
|
23
|
+
open: T,
|
|
24
|
+
onOpenChange: r,
|
|
25
|
+
portalContainer: $
|
|
26
|
+
}) => {
|
|
27
|
+
const [H, d] = M(i), [u, P] = M(!1), l = T !== void 0, x = l ? T : H, y = (c) => {
|
|
28
|
+
m || u || (l || d(c), r == null || r(c));
|
|
29
|
+
}, I = () => {
|
|
30
|
+
i || y(!0);
|
|
31
|
+
}, S = () => {
|
|
32
|
+
i || y(!1);
|
|
33
|
+
}, L = (c) => {
|
|
34
|
+
c.stopPropagation(), P(!0), l || d(!1), r == null || r(!1);
|
|
35
|
+
};
|
|
36
|
+
A(() => {
|
|
37
|
+
i && (P(!1), l || d(!0));
|
|
38
|
+
}, [i, l]);
|
|
39
|
+
const { wrapperRef: W, tooltipRef: X, layout: e, isPositioned: q } = G({
|
|
40
|
+
open: x && !u && !m && !!f,
|
|
41
|
+
desiredPosition: D,
|
|
42
|
+
showArrow: N,
|
|
43
|
+
maxWidth: w
|
|
44
|
+
});
|
|
45
|
+
if (!f || m)
|
|
46
|
+
return v;
|
|
47
|
+
const z = /* @__PURE__ */ a(
|
|
48
|
+
"div",
|
|
49
|
+
{
|
|
50
|
+
ref: X,
|
|
51
|
+
className: h(
|
|
52
|
+
o.tooltip,
|
|
53
|
+
o[e.resolvedPosition],
|
|
54
|
+
o[E],
|
|
55
|
+
n && !t && o.noTitleWithIcon,
|
|
56
|
+
p && !t && o.noTitleWithClose,
|
|
57
|
+
N && o.withArrow,
|
|
58
|
+
j
|
|
59
|
+
),
|
|
60
|
+
style: {
|
|
61
|
+
maxWidth: w,
|
|
62
|
+
top: e.top,
|
|
63
|
+
left: e.left,
|
|
64
|
+
visibility: q ? "visible" : "hidden",
|
|
65
|
+
...!!e.arrowLeft && {
|
|
66
|
+
"--arrow-left": `${e.arrowLeft}px`
|
|
67
|
+
},
|
|
68
|
+
...!!e.arrowTop && { "--arrow-top": `${e.arrowTop}px` }
|
|
69
|
+
},
|
|
70
|
+
role: "tooltip",
|
|
71
|
+
children: [
|
|
72
|
+
t && /* @__PURE__ */ a("div", { className: o.header, children: [
|
|
73
|
+
/* @__PURE__ */ a("div", { className: o.titleRow, children: [
|
|
74
|
+
n && /* @__PURE__ */ s(k, {}),
|
|
75
|
+
t ? /* @__PURE__ */ s("div", { className: o.title, children: t }) : /* @__PURE__ */ s("span", {})
|
|
76
|
+
] }),
|
|
77
|
+
p && /* @__PURE__ */ s("span", { className: o.closeButton, onClick: L, children: /* @__PURE__ */ s(B, {}) })
|
|
78
|
+
] }),
|
|
79
|
+
/* @__PURE__ */ a("div", { className: o.content, children: [
|
|
80
|
+
n && !t && /* @__PURE__ */ s(k, {}),
|
|
81
|
+
/* @__PURE__ */ s("span", { className: o.contentText, children: f }),
|
|
82
|
+
p && !t && /* @__PURE__ */ s("span", { className: o.closeButton, onClick: L, children: /* @__PURE__ */ s(B, {}) })
|
|
83
|
+
] })
|
|
84
|
+
]
|
|
85
|
+
}
|
|
86
|
+
);
|
|
87
|
+
return /* @__PURE__ */ a(
|
|
88
|
+
"div",
|
|
89
|
+
{
|
|
90
|
+
ref: W,
|
|
91
|
+
className: h(o.wrapper, R),
|
|
92
|
+
onMouseEnter: I,
|
|
93
|
+
onMouseLeave: S,
|
|
94
|
+
children: [
|
|
95
|
+
v,
|
|
96
|
+
x && !u && F(z, $ ?? document.body)
|
|
97
|
+
]
|
|
98
|
+
}
|
|
99
|
+
);
|
|
100
|
+
};
|
|
101
|
+
export {
|
|
102
|
+
V as Tooltip
|
|
103
|
+
};
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
const t = "_wrapper_1eluv_1", o = "_tooltip_1eluv_9", e = "_dark_1eluv_27", _ = "_light_1eluv_36", l = "_withArrow_1eluv_47", n = "_top_1eluv_55", c = "_bottom_1eluv_63", i = "_left_1eluv_71", s = "_right_1eluv_79", r = "_header_1eluv_103", u = "_titleRow_1eluv_111", h = "_title_1eluv_111", v = "_content_1eluv_126", p = "_contentText_1eluv_136", w = "_noTitleWithIcon_1eluv_142", a = "_noTitleWithClose_1eluv_146", T = "_closeButton_1eluv_152", d = {
|
|
2
|
+
wrapper: t,
|
|
3
|
+
tooltip: o,
|
|
4
|
+
dark: e,
|
|
5
|
+
light: _,
|
|
6
|
+
withArrow: l,
|
|
7
|
+
top: n,
|
|
8
|
+
bottom: c,
|
|
9
|
+
left: i,
|
|
10
|
+
right: s,
|
|
11
|
+
header: r,
|
|
12
|
+
titleRow: u,
|
|
13
|
+
title: h,
|
|
14
|
+
content: v,
|
|
15
|
+
contentText: p,
|
|
16
|
+
noTitleWithIcon: w,
|
|
17
|
+
noTitleWithClose: a,
|
|
18
|
+
closeButton: T
|
|
19
|
+
};
|
|
20
|
+
export {
|
|
21
|
+
c as bottom,
|
|
22
|
+
T as closeButton,
|
|
23
|
+
v as content,
|
|
24
|
+
p as contentText,
|
|
25
|
+
e as dark,
|
|
26
|
+
d as default,
|
|
27
|
+
r as header,
|
|
28
|
+
i as left,
|
|
29
|
+
_ as light,
|
|
30
|
+
a as noTitleWithClose,
|
|
31
|
+
w as noTitleWithIcon,
|
|
32
|
+
s as right,
|
|
33
|
+
h as title,
|
|
34
|
+
u as titleRow,
|
|
35
|
+
o as tooltip,
|
|
36
|
+
n as top,
|
|
37
|
+
l as withArrow,
|
|
38
|
+
t as wrapper
|
|
39
|
+
};
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
import { useRef as E, useState as x, useCallback as B, useLayoutEffect as H } from "react";
|
|
2
|
+
const M = 8, N = 12, p = (w, u, m) => Math.min(Math.max(w, u), m);
|
|
3
|
+
function V({
|
|
4
|
+
open: w,
|
|
5
|
+
desiredPosition: u,
|
|
6
|
+
showArrow: m,
|
|
7
|
+
maxWidth: D,
|
|
8
|
+
viewportPadding: r = M,
|
|
9
|
+
gap: L = null,
|
|
10
|
+
arrowSafePadding: h = N
|
|
11
|
+
}) {
|
|
12
|
+
const F = E(null), T = E(null), f = E(null), [W, b] = x(!1), [G, _] = x(() => ({
|
|
13
|
+
resolvedPosition: u,
|
|
14
|
+
top: 0,
|
|
15
|
+
left: 0,
|
|
16
|
+
arrowLeft: null,
|
|
17
|
+
arrowTop: null
|
|
18
|
+
})), A = B(() => {
|
|
19
|
+
const C = F.current, y = T.current;
|
|
20
|
+
if (!C || !y) return;
|
|
21
|
+
const c = L ?? parseFloat(
|
|
22
|
+
getComputedStyle(document.documentElement).getPropertyValue("--spacing--xs")
|
|
23
|
+
), t = C.getBoundingClientRect(), e = y.getBoundingClientRect(), I = window.innerWidth, d = window.innerHeight;
|
|
24
|
+
let o = u;
|
|
25
|
+
u === "top" && (t.top >= e.height + c + r || (o = "bottom")), u === "bottom" && (d - t.bottom >= e.height + c + r || (o = "top"));
|
|
26
|
+
let l = 0, n = 0;
|
|
27
|
+
o === "top" && (l = t.top - e.height - c, n = t.left + t.width / 2 - e.width / 2), o === "bottom" && (l = t.bottom + c, n = t.left + t.width / 2 - e.width / 2), o === "left" && (l = t.top + t.height / 2 - e.height / 2, n = t.left - e.width - c, n < r && (o = "right", n = t.right + c)), o === "right" && (l = t.top + t.height / 2 - e.height / 2, n = t.right + c, n + e.width > I - r && (o = "left", n = t.left - e.width - c)), n = p(n, r, I - e.width - r), l = p(l, r, d - e.height - r);
|
|
28
|
+
let a = null, g = null;
|
|
29
|
+
if (m) {
|
|
30
|
+
const i = t.left + t.width / 2, z = t.top + t.height / 2;
|
|
31
|
+
if (o === "top" || o === "bottom") {
|
|
32
|
+
const R = i - n;
|
|
33
|
+
a = p(
|
|
34
|
+
R,
|
|
35
|
+
h,
|
|
36
|
+
e.width - h
|
|
37
|
+
);
|
|
38
|
+
} else if (o === "left" || o === "right") {
|
|
39
|
+
const R = z - l;
|
|
40
|
+
g = p(
|
|
41
|
+
R,
|
|
42
|
+
h,
|
|
43
|
+
e.height - h
|
|
44
|
+
);
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
_((i) => i.resolvedPosition === o && i.top === l && i.left === n && i.arrowLeft === a && i.arrowTop === g ? i : { resolvedPosition: o, top: l, left: n, arrowLeft: a, arrowTop: g }), b(!0);
|
|
48
|
+
}, [h, u, L, m, r]), s = B(() => {
|
|
49
|
+
f.current == null && (f.current = window.requestAnimationFrame(() => {
|
|
50
|
+
f.current = null, A();
|
|
51
|
+
}));
|
|
52
|
+
}, [A]);
|
|
53
|
+
return H(() => w ? (s(), window.addEventListener("resize", s), window.addEventListener("scroll", s, !0), () => {
|
|
54
|
+
f.current != null && (window.cancelAnimationFrame(f.current), f.current = null), window.removeEventListener("resize", s), window.removeEventListener("scroll", s, !0);
|
|
55
|
+
}) : (b(!1), () => {
|
|
56
|
+
}), [w, s, D]), { wrapperRef: F, tooltipRef: T, layout: G, isPositioned: W, recompute: s };
|
|
57
|
+
}
|
|
58
|
+
export {
|
|
59
|
+
V as useTooltipPositioning
|
|
60
|
+
};
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import { jsxs as e, Fragment as t, jsx as r } from "react/jsx-runtime";
|
|
2
|
+
import "react";
|
|
3
|
+
import { createIcon as i } from "./createIcon.js";
|
|
4
|
+
const a = i(({ strokeColor: n, strokeWidth: o }) => /* @__PURE__ */ e(t, { children: [
|
|
5
|
+
/* @__PURE__ */ r(
|
|
6
|
+
"path",
|
|
7
|
+
{
|
|
8
|
+
d: "M2.6665 16C2.6665 19.5362 4.07126 22.9276 6.57175 25.4281C9.07223 27.9286 12.4636 29.3333 15.9998 29.3333C19.5361 29.3333 22.9274 27.9286 25.4279 25.4281C27.9284 22.9276 29.3332 19.5362 29.3332 16C29.3332 12.4638 27.9284 9.0724 25.4279 6.57191C22.9274 4.07143 19.5361 2.66667 15.9998 2.66667C12.4636 2.66667 9.07223 4.07143 6.57175 6.57191C4.07126 9.0724 2.6665 12.4638 2.6665 16Z",
|
|
9
|
+
stroke: n,
|
|
10
|
+
strokeWidth: o,
|
|
11
|
+
strokeLinecap: "round",
|
|
12
|
+
strokeLinejoin: "round"
|
|
13
|
+
}
|
|
14
|
+
),
|
|
15
|
+
/* @__PURE__ */ r(
|
|
16
|
+
"path",
|
|
17
|
+
{
|
|
18
|
+
d: "M9.3335 20V14C9.3335 13.4696 9.54421 12.9609 9.91928 12.5858C10.2944 12.2107 10.8031 12 11.3335 12C11.8639 12 12.3726 12.2107 12.7477 12.5858C13.1228 12.9609 13.3335 13.4696 13.3335 14V20",
|
|
19
|
+
stroke: n,
|
|
20
|
+
strokeWidth: o,
|
|
21
|
+
strokeLinecap: "round",
|
|
22
|
+
strokeLinejoin: "round"
|
|
23
|
+
}
|
|
24
|
+
),
|
|
25
|
+
/* @__PURE__ */ r(
|
|
26
|
+
"path",
|
|
27
|
+
{
|
|
28
|
+
d: "M9.3335 17.3333H13.3335",
|
|
29
|
+
stroke: n,
|
|
30
|
+
strokeWidth: o,
|
|
31
|
+
strokeLinecap: "round",
|
|
32
|
+
strokeLinejoin: "round"
|
|
33
|
+
}
|
|
34
|
+
),
|
|
35
|
+
/* @__PURE__ */ r(
|
|
36
|
+
"path",
|
|
37
|
+
{
|
|
38
|
+
d: "M18.6665 12V20H19.9998C20.7071 20 21.3854 19.719 21.8855 19.219C22.3856 18.7189 22.6665 18.0406 22.6665 17.3333V14.6667C22.6665 13.9594 22.3856 13.2811 21.8855 12.781C21.3854 12.281 20.7071 12 19.9998 12H18.6665Z",
|
|
39
|
+
stroke: n,
|
|
40
|
+
strokeWidth: o,
|
|
41
|
+
strokeLinecap: "round",
|
|
42
|
+
strokeLinejoin: "round"
|
|
43
|
+
}
|
|
44
|
+
)
|
|
45
|
+
] }));
|
|
46
|
+
export {
|
|
47
|
+
a as AdIcon
|
|
48
|
+
};
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { jsxs as r, Fragment as t, jsx as o } from "react/jsx-runtime";
|
|
2
|
+
import { createIcon as s } from "./createIcon.js";
|
|
3
|
+
const a = s(({ strokeColor: n, strokeWidth: e }) => /* @__PURE__ */ r(t, { children: [
|
|
4
|
+
/* @__PURE__ */ o(
|
|
5
|
+
"path",
|
|
6
|
+
{
|
|
7
|
+
d: "M24 5.33594C25.0609 5.33594 26.0783 5.75737 26.8284 6.50751C27.5786 7.25766 28 8.27507 28 9.33594V20.0026C28 21.0635 27.5786 22.0809 26.8284 22.831C26.0783 23.5812 25.0609 24.0026 24 24.0026H17.3333L10.6667 28.0026V24.0026H8C6.93913 24.0026 5.92172 23.5812 5.17157 22.831C4.42143 22.0809 4 21.0635 4 20.0026V9.33594C4 8.27507 4.42143 7.25766 5.17157 6.50751C5.92172 5.75737 6.93913 5.33594 8 5.33594H24Z",
|
|
8
|
+
stroke: n,
|
|
9
|
+
strokeWidth: e,
|
|
10
|
+
strokeLinecap: "round",
|
|
11
|
+
strokeLinejoin: "round"
|
|
12
|
+
}
|
|
13
|
+
),
|
|
14
|
+
/* @__PURE__ */ o(
|
|
15
|
+
"path",
|
|
16
|
+
{
|
|
17
|
+
d: "M12 15H20",
|
|
18
|
+
stroke: n,
|
|
19
|
+
strokeWidth: e,
|
|
20
|
+
strokeLinecap: "round",
|
|
21
|
+
strokeLinejoin: "round"
|
|
22
|
+
}
|
|
23
|
+
),
|
|
24
|
+
/* @__PURE__ */ o(
|
|
25
|
+
"path",
|
|
26
|
+
{
|
|
27
|
+
d: "M16 11V19",
|
|
28
|
+
stroke: n,
|
|
29
|
+
strokeWidth: e,
|
|
30
|
+
strokeLinecap: "round",
|
|
31
|
+
strokeLinejoin: "round"
|
|
32
|
+
}
|
|
33
|
+
)
|
|
34
|
+
] }));
|
|
35
|
+
export {
|
|
36
|
+
a as AddMessageIcon
|
|
37
|
+
};
|