@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,66 @@
|
|
|
1
|
+
import { jsxs as N, jsx as u } from "react/jsx-runtime";
|
|
2
|
+
import y from "clsx";
|
|
3
|
+
import p from "./TextField.module.scss.js";
|
|
4
|
+
import { createField as w } from "../InputFieldContainer.js";
|
|
5
|
+
import { Button as $ } from "../../Button/Button.js";
|
|
6
|
+
const j = (s, r, m) => {
|
|
7
|
+
const h = window.getComputedStyle(s), t = parseFloat(h.lineHeight) || 20, x = r * t, l = m * t;
|
|
8
|
+
s.style.height = "auto";
|
|
9
|
+
const d = Math.max(x, Math.min(s.scrollHeight, l));
|
|
10
|
+
s.style.height = `${d}px`, s.style.resize = l > s.scrollHeight ? "vertical" : "none";
|
|
11
|
+
}, z = ({
|
|
12
|
+
id: s,
|
|
13
|
+
name: r,
|
|
14
|
+
type: m = "text",
|
|
15
|
+
value: h,
|
|
16
|
+
defaultValue: t,
|
|
17
|
+
placeholder: x = "Text",
|
|
18
|
+
disabled: l = !1,
|
|
19
|
+
onChange: d = () => {
|
|
20
|
+
},
|
|
21
|
+
rows: g = 4,
|
|
22
|
+
maxRows: f = 10,
|
|
23
|
+
expandable: H = !1,
|
|
24
|
+
ariaLabel: i,
|
|
25
|
+
label: v,
|
|
26
|
+
inputProps: F = {},
|
|
27
|
+
actions: T = [],
|
|
28
|
+
containerFieldClassName: b
|
|
29
|
+
}) => /* @__PURE__ */ N("div", { className: y(p.field, b), children: [
|
|
30
|
+
/* @__PURE__ */ u(
|
|
31
|
+
"textarea",
|
|
32
|
+
{
|
|
33
|
+
id: s,
|
|
34
|
+
name: r,
|
|
35
|
+
type: m,
|
|
36
|
+
className: y(p.input, H && p.expandableField),
|
|
37
|
+
value: h,
|
|
38
|
+
defaultValue: t,
|
|
39
|
+
placeholder: x,
|
|
40
|
+
disabled: l,
|
|
41
|
+
onChange: d,
|
|
42
|
+
rows: g,
|
|
43
|
+
onInput: (e) => j(e.currentTarget, g, f),
|
|
44
|
+
"aria-label": i ?? (v ? void 0 : "input field"),
|
|
45
|
+
...F
|
|
46
|
+
}
|
|
47
|
+
),
|
|
48
|
+
/* @__PURE__ */ u("span", { className: p.buttonWrapper, children: T.map((e, k) => {
|
|
49
|
+
const C = (e == null ? void 0 : e.key) ?? (e == null ? void 0 : e.id) ?? `${r ?? s}-action-${k}`;
|
|
50
|
+
return /* @__PURE__ */ u(
|
|
51
|
+
$,
|
|
52
|
+
{
|
|
53
|
+
variant: (e == null ? void 0 : e.variant) ?? "neutral",
|
|
54
|
+
type: (e == null ? void 0 : e.type) ?? "outline",
|
|
55
|
+
icon: e == null ? void 0 : e.icon,
|
|
56
|
+
text: e == null ? void 0 : e.text,
|
|
57
|
+
disabled: l || (e == null ? void 0 : e.disabled),
|
|
58
|
+
onClick: e == null ? void 0 : e.onClick
|
|
59
|
+
},
|
|
60
|
+
C
|
|
61
|
+
);
|
|
62
|
+
}) })
|
|
63
|
+
] }), W = w(z);
|
|
64
|
+
export {
|
|
65
|
+
W as TextField
|
|
66
|
+
};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
const e = "_field_1rid6_1", t = "_input_1rid6_7", d = "_expandableField_1rid6_11", n = "_buttonWrapper_1rid6_19", i = {
|
|
2
|
+
field: e,
|
|
3
|
+
input: t,
|
|
4
|
+
expandableField: d,
|
|
5
|
+
buttonWrapper: n
|
|
6
|
+
};
|
|
7
|
+
export {
|
|
8
|
+
n as buttonWrapper,
|
|
9
|
+
i as default,
|
|
10
|
+
d as expandableField,
|
|
11
|
+
e as field,
|
|
12
|
+
t as input
|
|
13
|
+
};
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { jsx as o, jsxs as n } from "react/jsx-runtime";
|
|
2
|
+
import i from "clsx";
|
|
3
|
+
import { PaperIcon as b } from "./PaperIcon.js";
|
|
4
|
+
import l from "./FileType.module.scss.js";
|
|
5
|
+
const m = (e) => String(e || "").trim().replace(/^\./, "").toUpperCase(), p = {
|
|
6
|
+
DOC: { label: "DOC", color: "#155EEF" },
|
|
7
|
+
DOCX: { label: "DOCX", color: "#155EEF" },
|
|
8
|
+
XLS: { label: "XLS", color: "#079455" },
|
|
9
|
+
XLSX: { label: "XLSX", color: "#079455" },
|
|
10
|
+
PPT: { label: "PPT", color: "#E62E05" },
|
|
11
|
+
PPTX: { label: "PPTX", color: "#E62E05" },
|
|
12
|
+
PDF: { label: "PDF", color: "#D92D20" },
|
|
13
|
+
HTML: { label: "HTML", color: "#222222" },
|
|
14
|
+
XHTML: { label: "XHTML", color: "#222222" },
|
|
15
|
+
HTMLX: { label: "XHTML", color: "#222222" },
|
|
16
|
+
TIF: { label: "TIFF", color: "#32A7FE" },
|
|
17
|
+
TIFF: { label: "TIFF", color: "#32A7FE" }
|
|
18
|
+
}, E = ({ extension: e, size: r = 64, className: s }) => {
|
|
19
|
+
const c = m(e), a = p[c] || {
|
|
20
|
+
label: c || "",
|
|
21
|
+
color: "#667085"
|
|
22
|
+
}, t = r / 64;
|
|
23
|
+
return /* @__PURE__ */ o("div", { className: i(l.wrapper, s), style: { width: r, height: r }, children: /* @__PURE__ */ n("div", { className: l.inner, style: { transform: `scale(${t})` }, children: [
|
|
24
|
+
/* @__PURE__ */ o("div", { className: l.paper, children: /* @__PURE__ */ o(b, { className: l.paperSvg }) }),
|
|
25
|
+
a.label ? /* @__PURE__ */ o("div", { className: l.badge, style: { backgroundColor: a.color }, children: /* @__PURE__ */ o("span", { className: l.badgeText, children: a.label }) }) : null
|
|
26
|
+
] }) });
|
|
27
|
+
};
|
|
28
|
+
export {
|
|
29
|
+
E as FileType
|
|
30
|
+
};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
const e = "_wrapper_12p13_1", p = "_inner_12p13_10", _ = "_paper_12p13_18", a = "_badge_12p13_28", r = "_badgeText_12p13_40", n = {
|
|
2
|
+
wrapper: e,
|
|
3
|
+
inner: p,
|
|
4
|
+
paper: _,
|
|
5
|
+
badge: a,
|
|
6
|
+
badgeText: r
|
|
7
|
+
};
|
|
8
|
+
export {
|
|
9
|
+
a as badge,
|
|
10
|
+
r as badgeText,
|
|
11
|
+
n as default,
|
|
12
|
+
p as inner,
|
|
13
|
+
_ as paper,
|
|
14
|
+
e as wrapper
|
|
15
|
+
};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { jsxs as l, jsx as o } from "react/jsx-runtime";
|
|
2
|
+
const s = ({ width: t = 52, height: e = 64, ...i }) => /* @__PURE__ */ l("svg", { width: t, height: e, viewBox: "0 0 52 64", fill: "none", ...i, children: [
|
|
3
|
+
/* @__PURE__ */ o(
|
|
4
|
+
"path",
|
|
5
|
+
{
|
|
6
|
+
d: "M9.11133 0.799866H31.6689L50.4004 19.5313V55.668C50.4004 59.7829 46.823 63.2002 42.3047 63.2003H8.91211C4.37582 63.2001 0.799805 59.7819 0.799805 55.668V8.33209C0.799728 4.24007 4.55102 0.799896 9.11133 0.799866Z",
|
|
7
|
+
fill: "white",
|
|
8
|
+
stroke: "#E3E3EF",
|
|
9
|
+
strokeWidth: "1.6"
|
|
10
|
+
}
|
|
11
|
+
),
|
|
12
|
+
/* @__PURE__ */ o(
|
|
13
|
+
"path",
|
|
14
|
+
{
|
|
15
|
+
d: "M32.041 13.056V0L51.2 19.2H38.4273C32.6797 19.2 31.7749 15.104 32.041 13.056Z",
|
|
16
|
+
fill: "#E3E3EF"
|
|
17
|
+
}
|
|
18
|
+
)
|
|
19
|
+
] });
|
|
20
|
+
export {
|
|
21
|
+
s as PaperIcon
|
|
22
|
+
};
|
|
@@ -0,0 +1,146 @@
|
|
|
1
|
+
import { jsxs as c, jsx as o } from "react/jsx-runtime";
|
|
2
|
+
import { useState as b } from "react";
|
|
3
|
+
import n from "clsx";
|
|
4
|
+
import { Checkbox as y } from "../Checkbox/Checkbox.js";
|
|
5
|
+
import { tagPropsFromTag as O, badgePropsFromTag as F, pillPropsFromTag as R } from "./utilsImgPh.js";
|
|
6
|
+
import { ASPECT_RATIOS as N, TAG_TYPES as T, OVERLAYS as z, TEXT_POSITIONS as x, LINES as M } from "./constantsImgPh.js";
|
|
7
|
+
import { ImageOffIcon as _ } from "../icons-v2/ImageOffIcon.js";
|
|
8
|
+
import { MoreIcon as j } from "../icons-v2/MoreIcon.js";
|
|
9
|
+
import { XIcon as B } from "../icons-v2/XIcon.js";
|
|
10
|
+
import e from "./ImagePlaceholder.module.scss.js";
|
|
11
|
+
import { Button as X } from "../Button/Button.js";
|
|
12
|
+
import { EllipsisTooltip as Y } from "../EllipsisTooltip/EllipsisTooltip.js";
|
|
13
|
+
import { DropdownList as D } from "../DropdownList/DropdownList.js";
|
|
14
|
+
import { ListItem as G } from "../ListItem/ListItem.js";
|
|
15
|
+
import { Tag as V } from "../Tag/Tag.js";
|
|
16
|
+
import { Badge as W } from "../Badge/Badge.js";
|
|
17
|
+
import { Pill as q } from "../Pill/Pill.js";
|
|
18
|
+
const to = ({
|
|
19
|
+
id: I,
|
|
20
|
+
url: k,
|
|
21
|
+
text: a,
|
|
22
|
+
textPosition: t = x.inside,
|
|
23
|
+
tag: r,
|
|
24
|
+
overlay: s,
|
|
25
|
+
isChecked: S,
|
|
26
|
+
onChecked: p,
|
|
27
|
+
menu: d,
|
|
28
|
+
aspectRatio: v = N["1/1"],
|
|
29
|
+
lines: C = M[1],
|
|
30
|
+
disabled: m = !1,
|
|
31
|
+
onClose: E = () => {
|
|
32
|
+
}
|
|
33
|
+
}) => {
|
|
34
|
+
const [h, g] = b(!1), [i, P] = b(!1), u = () => {
|
|
35
|
+
switch (r == null ? void 0 : r.type) {
|
|
36
|
+
case "pill":
|
|
37
|
+
return /* @__PURE__ */ o(q, { ...R(r) });
|
|
38
|
+
case "badge":
|
|
39
|
+
return /* @__PURE__ */ o(W, { ...F(r) });
|
|
40
|
+
case "tag":
|
|
41
|
+
return /* @__PURE__ */ o(V, { ...O(r) });
|
|
42
|
+
default:
|
|
43
|
+
return null;
|
|
44
|
+
}
|
|
45
|
+
}, f = !a || t === x.outside ? "8px" : "8px 8px 0 0", w = Number(C), L = n(e.contentText, e.contentTextClamped), A = { WebkitLineClamp: w };
|
|
46
|
+
return /* @__PURE__ */ c(
|
|
47
|
+
"div",
|
|
48
|
+
{
|
|
49
|
+
className: n(
|
|
50
|
+
e.imagePlaceholder,
|
|
51
|
+
m && e.disabled
|
|
52
|
+
),
|
|
53
|
+
children: [
|
|
54
|
+
/* @__PURE__ */ c(
|
|
55
|
+
"div",
|
|
56
|
+
{
|
|
57
|
+
className: n(
|
|
58
|
+
e.imageArea,
|
|
59
|
+
s === "checkbox" && e.clickable,
|
|
60
|
+
s === "checkbox" && !i && e.checkboxSelectable
|
|
61
|
+
),
|
|
62
|
+
style: { borderRadius: f },
|
|
63
|
+
onClick: s === "checkbox" && !i && !m ? p : void 0,
|
|
64
|
+
children: [
|
|
65
|
+
/* @__PURE__ */ o(
|
|
66
|
+
"div",
|
|
67
|
+
{
|
|
68
|
+
className: e.imageFrame,
|
|
69
|
+
style: { aspectRatio: N[v], borderRadius: f },
|
|
70
|
+
children: i ? /* @__PURE__ */ o("div", { className: e.imageError, children: /* @__PURE__ */ o(
|
|
71
|
+
_,
|
|
72
|
+
{
|
|
73
|
+
iconSize: "l",
|
|
74
|
+
strokeColor: "var(--color--icon--disabled--default)"
|
|
75
|
+
}
|
|
76
|
+
) }) : /* @__PURE__ */ o(
|
|
77
|
+
"img",
|
|
78
|
+
{
|
|
79
|
+
className: e.image,
|
|
80
|
+
src: k,
|
|
81
|
+
alt: a,
|
|
82
|
+
onError: () => P(!0)
|
|
83
|
+
}
|
|
84
|
+
)
|
|
85
|
+
}
|
|
86
|
+
),
|
|
87
|
+
!a && T.has(r == null ? void 0 : r.type) ? /* @__PURE__ */ o("div", { className: e.tagInImage, children: u() }) : null,
|
|
88
|
+
z.has(s) && /* @__PURE__ */ c("div", { className: e.overlay, onClick: (l) => l.stopPropagation(), children: [
|
|
89
|
+
s === "checkbox" && !i ? /* @__PURE__ */ o(
|
|
90
|
+
y,
|
|
91
|
+
{
|
|
92
|
+
checked: S,
|
|
93
|
+
onChange: p,
|
|
94
|
+
size: "lg",
|
|
95
|
+
disabled: m
|
|
96
|
+
}
|
|
97
|
+
) : null,
|
|
98
|
+
s === "close" ? /* @__PURE__ */ o(
|
|
99
|
+
X,
|
|
100
|
+
{
|
|
101
|
+
icon: /* @__PURE__ */ o(B, {}),
|
|
102
|
+
size: "xxs",
|
|
103
|
+
variant: "fill",
|
|
104
|
+
type: "neutral",
|
|
105
|
+
onClick: E
|
|
106
|
+
}
|
|
107
|
+
) : null
|
|
108
|
+
] })
|
|
109
|
+
]
|
|
110
|
+
}
|
|
111
|
+
),
|
|
112
|
+
a ? /* @__PURE__ */ c("div", { className: n(e.belowImage, e[t]), children: [
|
|
113
|
+
T.has(r == null ? void 0 : r.type) ? /* @__PURE__ */ o("div", { children: u() }) : null,
|
|
114
|
+
/* @__PURE__ */ c("div", { className: e.content, children: [
|
|
115
|
+
/* @__PURE__ */ o(
|
|
116
|
+
Y,
|
|
117
|
+
{
|
|
118
|
+
position: "bottom",
|
|
119
|
+
showArrow: !0,
|
|
120
|
+
className: L,
|
|
121
|
+
wrapperStyle: A,
|
|
122
|
+
children: a
|
|
123
|
+
}
|
|
124
|
+
),
|
|
125
|
+
d && /* @__PURE__ */ c("div", { className: e.menu, children: [
|
|
126
|
+
/* @__PURE__ */ o("span", { onClick: () => g(!h), children: /* @__PURE__ */ o(j, {}) }),
|
|
127
|
+
h && /* @__PURE__ */ o(D, { children: d.map((l) => /* @__PURE__ */ o(
|
|
128
|
+
G,
|
|
129
|
+
{
|
|
130
|
+
title: l == null ? void 0 : l.title,
|
|
131
|
+
value: l == null ? void 0 : l.value,
|
|
132
|
+
item: l
|
|
133
|
+
},
|
|
134
|
+
l == null ? void 0 : l.value
|
|
135
|
+
)) })
|
|
136
|
+
] })
|
|
137
|
+
] })
|
|
138
|
+
] }) : null
|
|
139
|
+
]
|
|
140
|
+
},
|
|
141
|
+
I
|
|
142
|
+
);
|
|
143
|
+
};
|
|
144
|
+
export {
|
|
145
|
+
to as default
|
|
146
|
+
};
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
const e = "_imagePlaceholder_xpodz_1", o = "_disabled_xpodz_7", t = "_imageArea_xpodz_13", _ = "_clickable_xpodz_23", a = "_checkboxSelectable_xpodz_26", c = "_imageFrame_xpodz_31", n = "_image_xpodz_1", d = "_imageError_xpodz_47", l = "_tagInImage_xpodz_54", i = "_overlay_xpodz_59", m = "_belowImage_xpodz_64", s = "_inside_xpodz_73", x = "_outside_xpodz_77", g = "_content_xpodz_81", r = "_contentText_xpodz_87", p = "_contentTextClamped_xpodz_110", z = "_menu_xpodz_115", b = {
|
|
2
|
+
imagePlaceholder: e,
|
|
3
|
+
disabled: o,
|
|
4
|
+
imageArea: t,
|
|
5
|
+
clickable: _,
|
|
6
|
+
checkboxSelectable: a,
|
|
7
|
+
imageFrame: c,
|
|
8
|
+
image: n,
|
|
9
|
+
imageError: d,
|
|
10
|
+
tagInImage: l,
|
|
11
|
+
overlay: i,
|
|
12
|
+
belowImage: m,
|
|
13
|
+
inside: s,
|
|
14
|
+
outside: x,
|
|
15
|
+
content: g,
|
|
16
|
+
contentText: r,
|
|
17
|
+
contentTextClamped: p,
|
|
18
|
+
menu: z
|
|
19
|
+
};
|
|
20
|
+
export {
|
|
21
|
+
m as belowImage,
|
|
22
|
+
a as checkboxSelectable,
|
|
23
|
+
_ as clickable,
|
|
24
|
+
g as content,
|
|
25
|
+
r as contentText,
|
|
26
|
+
p as contentTextClamped,
|
|
27
|
+
b as default,
|
|
28
|
+
o as disabled,
|
|
29
|
+
n as image,
|
|
30
|
+
t as imageArea,
|
|
31
|
+
d as imageError,
|
|
32
|
+
c as imageFrame,
|
|
33
|
+
e as imagePlaceholder,
|
|
34
|
+
s as inside,
|
|
35
|
+
z as menu,
|
|
36
|
+
x as outside,
|
|
37
|
+
i as overlay,
|
|
38
|
+
l as tagInImage
|
|
39
|
+
};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
const e = {
|
|
2
|
+
"1/1": "1/1",
|
|
3
|
+
"4/3": "4/3",
|
|
4
|
+
"16/9": "16/9",
|
|
5
|
+
"9/16": "9/16"
|
|
6
|
+
}, o = {
|
|
7
|
+
1: "1"
|
|
8
|
+
}, t = { inside: "inside", outside: "outside" }, n = /* @__PURE__ */ new Set(["pill", "badge", "tag", "tagGroup"]), s = /* @__PURE__ */ new Set(["checkbox", "close", "icon"]);
|
|
9
|
+
export {
|
|
10
|
+
e as ASPECT_RATIOS,
|
|
11
|
+
o as LINES,
|
|
12
|
+
s as OVERLAYS,
|
|
13
|
+
n as TAG_TYPES,
|
|
14
|
+
t as TEXT_POSITIONS
|
|
15
|
+
};
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { SHAPES as r, STATES as i } from "../Badge/badgeVariants.js";
|
|
2
|
+
import { COLORS as l, STATUSES as a } from "../Pill/pillVariants.js";
|
|
3
|
+
import { TAG_SHAPES as u, TAG_STATES as p } from "../Tag/tagVariants.js";
|
|
4
|
+
const T = (s) => {
|
|
5
|
+
const e = s.label ?? s.text ?? "", n = u.includes(s.shape) ? s.shape : "rectangle", o = p.includes(s.state) ? s.state : "default", c = !!s.showLeadingIcon, t = typeof s.onDismiss == "function" ? s.onDismiss : void 0;
|
|
6
|
+
return { label: e, shape: n, state: o, showLeadingIcon: c, onDismiss: t };
|
|
7
|
+
}, f = (s) => {
|
|
8
|
+
const e = s.label ?? s.text ?? "", n = r.includes(s.shape) ? s.shape : "rectangle", o = i.includes(s.state) ? s.state : "neutral";
|
|
9
|
+
return { label: e, shape: n, state: o };
|
|
10
|
+
}, h = (s) => {
|
|
11
|
+
const e = s.label ?? s.text ?? "", n = l.includes(s.color) ? s.color : l[0], o = s.status, c = s.icon;
|
|
12
|
+
let t = "neutral";
|
|
13
|
+
return a.includes(o) && (t = o), { label: e, color: n, status: t, icon: c };
|
|
14
|
+
};
|
|
15
|
+
export {
|
|
16
|
+
f as badgePropsFromTag,
|
|
17
|
+
h as pillPropsFromTag,
|
|
18
|
+
T as tagPropsFromTag
|
|
19
|
+
};
|
|
@@ -0,0 +1,146 @@
|
|
|
1
|
+
import { jsxs as a, jsx as o } from "react/jsx-runtime";
|
|
2
|
+
import { useState as z } from "react";
|
|
3
|
+
import n from "clsx";
|
|
4
|
+
import { Checkbox as F } from "../Checkbox/Checkbox.js";
|
|
5
|
+
import { tagPropsFromTag as R, badgePropsFromTag as _, pillPropsFromTag as j } from "../ImagePlaceholder/utilsImgPh.js";
|
|
6
|
+
import { ASPECT_RATIOS as f, TAG_TYPES as b, OVERLAYS as B, TEXT_POSITIONS as x, LINES as D } from "../ImagePlaceholder/constantsImgPh.js";
|
|
7
|
+
import { ImageOffIcon as W } from "../icons-v2/ImageOffIcon.js";
|
|
8
|
+
import { XIcon as X } from "../icons-v2/XIcon.js";
|
|
9
|
+
import e from "./ImageWithData.module.scss.js";
|
|
10
|
+
import { Button as N } from "../Button/Button.js";
|
|
11
|
+
import { EllipsisTooltip as Y } from "../EllipsisTooltip/EllipsisTooltip.js";
|
|
12
|
+
import { Tag as G } from "../Tag/Tag.js";
|
|
13
|
+
import { Badge as V } from "../Badge/Badge.js";
|
|
14
|
+
import { Pill as q } from "../Pill/Pill.js";
|
|
15
|
+
const ae = ({
|
|
16
|
+
id: T,
|
|
17
|
+
url: k,
|
|
18
|
+
text: s,
|
|
19
|
+
textPosition: t = x.inside,
|
|
20
|
+
tag: r,
|
|
21
|
+
overlay: i,
|
|
22
|
+
isChecked: v,
|
|
23
|
+
onChecked: d,
|
|
24
|
+
aspectRatio: I = f["1/1"],
|
|
25
|
+
lines: S = D[1],
|
|
26
|
+
number: p = null,
|
|
27
|
+
disabled: m = !1,
|
|
28
|
+
disabledOverlay: C = !1,
|
|
29
|
+
onClose: E,
|
|
30
|
+
icon: g,
|
|
31
|
+
onIconClick: P
|
|
32
|
+
}) => {
|
|
33
|
+
const [c, y] = z(!1), h = () => {
|
|
34
|
+
switch (r == null ? void 0 : r.type) {
|
|
35
|
+
case "pill":
|
|
36
|
+
return /* @__PURE__ */ o(q, { ...j(r) });
|
|
37
|
+
case "badge":
|
|
38
|
+
return /* @__PURE__ */ o(V, { ..._(r) });
|
|
39
|
+
case "tag":
|
|
40
|
+
return /* @__PURE__ */ o(G, { ...R(r) });
|
|
41
|
+
default:
|
|
42
|
+
return null;
|
|
43
|
+
}
|
|
44
|
+
}, u = !s || t === x.outside ? "8px" : "8px 8px 0 0", A = Number(S), O = n(e.contentText, e.contentTextClamped), w = { WebkitLineClamp: A }, l = C || m;
|
|
45
|
+
return /* @__PURE__ */ a(
|
|
46
|
+
"div",
|
|
47
|
+
{
|
|
48
|
+
className: n(
|
|
49
|
+
e.imagePlaceholder,
|
|
50
|
+
m && e.disabled
|
|
51
|
+
),
|
|
52
|
+
children: [
|
|
53
|
+
/* @__PURE__ */ a(
|
|
54
|
+
"div",
|
|
55
|
+
{
|
|
56
|
+
className: n(
|
|
57
|
+
e.imageArea,
|
|
58
|
+
i === "checkbox" && e.clickable,
|
|
59
|
+
i === "checkbox" && !c && e.checkboxSelectable
|
|
60
|
+
),
|
|
61
|
+
style: { borderRadius: u },
|
|
62
|
+
onClick: i === "checkbox" && !c && !m ? d : void 0,
|
|
63
|
+
children: [
|
|
64
|
+
/* @__PURE__ */ o(
|
|
65
|
+
"div",
|
|
66
|
+
{
|
|
67
|
+
className: e.imageFrame,
|
|
68
|
+
style: { aspectRatio: f[I], borderRadius: u },
|
|
69
|
+
children: c ? /* @__PURE__ */ o("div", { className: e.imageError, children: /* @__PURE__ */ o(
|
|
70
|
+
W,
|
|
71
|
+
{
|
|
72
|
+
iconSize: "l",
|
|
73
|
+
strokeColor: "var(--color--icon--disabled--default)"
|
|
74
|
+
}
|
|
75
|
+
) }) : /* @__PURE__ */ o(
|
|
76
|
+
"img",
|
|
77
|
+
{
|
|
78
|
+
className: e.image,
|
|
79
|
+
src: k,
|
|
80
|
+
alt: s,
|
|
81
|
+
onError: () => y(!0)
|
|
82
|
+
}
|
|
83
|
+
)
|
|
84
|
+
}
|
|
85
|
+
),
|
|
86
|
+
!s && b.has(r == null ? void 0 : r.type) ? /* @__PURE__ */ o("div", { className: e.tagInImage, children: h() }) : null,
|
|
87
|
+
B.has(i) && /* @__PURE__ */ a("div", { className: e.overlay, onClick: (L) => L.stopPropagation(), children: [
|
|
88
|
+
i === "checkbox" && !c ? /* @__PURE__ */ o(
|
|
89
|
+
F,
|
|
90
|
+
{
|
|
91
|
+
checked: v,
|
|
92
|
+
onChange: l ? void 0 : d,
|
|
93
|
+
size: "lg",
|
|
94
|
+
disabled: l
|
|
95
|
+
}
|
|
96
|
+
) : null,
|
|
97
|
+
i === "close" ? /* @__PURE__ */ o(
|
|
98
|
+
N,
|
|
99
|
+
{
|
|
100
|
+
icon: /* @__PURE__ */ o(X, {}),
|
|
101
|
+
size: "xxs",
|
|
102
|
+
variant: "fill",
|
|
103
|
+
type: "neutral",
|
|
104
|
+
disabled: l,
|
|
105
|
+
onClick: l ? void 0 : E
|
|
106
|
+
}
|
|
107
|
+
) : null,
|
|
108
|
+
i === "icon" && /* @__PURE__ */ o(
|
|
109
|
+
N,
|
|
110
|
+
{
|
|
111
|
+
icon: g,
|
|
112
|
+
size: "xs",
|
|
113
|
+
variant: "fill",
|
|
114
|
+
type: "neutral",
|
|
115
|
+
disabled: l,
|
|
116
|
+
onClick: l ? void 0 : P
|
|
117
|
+
}
|
|
118
|
+
)
|
|
119
|
+
] })
|
|
120
|
+
]
|
|
121
|
+
}
|
|
122
|
+
),
|
|
123
|
+
s ? /* @__PURE__ */ a("div", { className: n(e.belowImage, e[t]), children: [
|
|
124
|
+
b.has(r == null ? void 0 : r.type) ? /* @__PURE__ */ o("div", { children: h() }) : null,
|
|
125
|
+
/* @__PURE__ */ a("div", { className: e.content, children: [
|
|
126
|
+
/* @__PURE__ */ o(
|
|
127
|
+
Y,
|
|
128
|
+
{
|
|
129
|
+
position: "bottom",
|
|
130
|
+
showArrow: !0,
|
|
131
|
+
className: O,
|
|
132
|
+
wrapperStyle: w,
|
|
133
|
+
children: s
|
|
134
|
+
}
|
|
135
|
+
),
|
|
136
|
+
p && /* @__PURE__ */ o("div", { className: e.number, children: p })
|
|
137
|
+
] })
|
|
138
|
+
] }) : null
|
|
139
|
+
]
|
|
140
|
+
},
|
|
141
|
+
T
|
|
142
|
+
);
|
|
143
|
+
};
|
|
144
|
+
export {
|
|
145
|
+
ae as default
|
|
146
|
+
};
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
const e = "_imagePlaceholder_82r23_1", t = "_disabled_82r23_7", _ = "_imageArea_82r23_13", a = "_clickable_82r23_23", o = "_checkboxSelectable_82r23_26", c = "_imageFrame_82r23_31", n = "_image_82r23_1", r = "_imageError_82r23_47", l = "_tagInImage_82r23_54", i = "_overlay_82r23_59", m = "_belowImage_82r23_64", s = "_inside_82r23_73", g = "_outside_82r23_77", d = "_content_82r23_81", b = "_number_82r23_88", x = "_contentText_82r23_106", I = "_contentTextClamped_82r23_128", u = {
|
|
2
|
+
imagePlaceholder: e,
|
|
3
|
+
disabled: t,
|
|
4
|
+
imageArea: _,
|
|
5
|
+
clickable: a,
|
|
6
|
+
checkboxSelectable: o,
|
|
7
|
+
imageFrame: c,
|
|
8
|
+
image: n,
|
|
9
|
+
imageError: r,
|
|
10
|
+
tagInImage: l,
|
|
11
|
+
overlay: i,
|
|
12
|
+
belowImage: m,
|
|
13
|
+
inside: s,
|
|
14
|
+
outside: g,
|
|
15
|
+
content: d,
|
|
16
|
+
number: b,
|
|
17
|
+
contentText: x,
|
|
18
|
+
contentTextClamped: I
|
|
19
|
+
};
|
|
20
|
+
export {
|
|
21
|
+
m as belowImage,
|
|
22
|
+
o as checkboxSelectable,
|
|
23
|
+
a as clickable,
|
|
24
|
+
d as content,
|
|
25
|
+
x as contentText,
|
|
26
|
+
I as contentTextClamped,
|
|
27
|
+
u as default,
|
|
28
|
+
t as disabled,
|
|
29
|
+
n as image,
|
|
30
|
+
_ as imageArea,
|
|
31
|
+
r as imageError,
|
|
32
|
+
c as imageFrame,
|
|
33
|
+
e as imagePlaceholder,
|
|
34
|
+
s as inside,
|
|
35
|
+
b as number,
|
|
36
|
+
g as outside,
|
|
37
|
+
i as overlay,
|
|
38
|
+
l as tagInImage
|
|
39
|
+
};
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { jsxs as a, jsx as e } from "react/jsx-runtime";
|
|
2
|
+
import x from "clsx";
|
|
3
|
+
import { getInfoboxStyles as p, INFOBOX_STATUSES as h, INFOBOX_COLORS as N } from "./infoboxVariants.js";
|
|
4
|
+
import s from "./Infobox.module.scss.js";
|
|
5
|
+
const y = ({
|
|
6
|
+
title: o = "",
|
|
7
|
+
text: t = "",
|
|
8
|
+
color: c = "fill",
|
|
9
|
+
status: i = "success",
|
|
10
|
+
icon: n = null,
|
|
11
|
+
fullWidth: r = !1
|
|
12
|
+
}) => {
|
|
13
|
+
const f = h.includes(i) ? i : "success", m = N.includes(c) ? c : "fill", d = p(m, f), l = !!o;
|
|
14
|
+
return /* @__PURE__ */ a(
|
|
15
|
+
"div",
|
|
16
|
+
{
|
|
17
|
+
className: x(s.infobox, {
|
|
18
|
+
[s.fullWidth]: r
|
|
19
|
+
}),
|
|
20
|
+
style: d,
|
|
21
|
+
children: [
|
|
22
|
+
/* @__PURE__ */ a("div", { className: l ? s.titleRow : s.textRow, children: [
|
|
23
|
+
n && /* @__PURE__ */ e("span", { className: s.icon, children: n }),
|
|
24
|
+
l ? /* @__PURE__ */ e("p", { className: s.title, children: o }) : /* @__PURE__ */ e("p", { className: s.text, children: t })
|
|
25
|
+
] }),
|
|
26
|
+
l && /* @__PURE__ */ e("p", { className: s.text, children: t })
|
|
27
|
+
]
|
|
28
|
+
}
|
|
29
|
+
);
|
|
30
|
+
};
|
|
31
|
+
export {
|
|
32
|
+
y as Infobox
|
|
33
|
+
};
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
const t = "_infobox_1tvqk_1", o = "_fullWidth_1tvqk_13", _ = "_titleRow_1tvqk_17", e = "_textRow_1tvqk_24", i = "_icon_1tvqk_31", l = "_title_1tvqk_17", n = "_text_1tvqk_24", c = {
|
|
2
|
+
infobox: t,
|
|
3
|
+
fullWidth: o,
|
|
4
|
+
titleRow: _,
|
|
5
|
+
textRow: e,
|
|
6
|
+
icon: i,
|
|
7
|
+
title: l,
|
|
8
|
+
text: n
|
|
9
|
+
};
|
|
10
|
+
export {
|
|
11
|
+
c as default,
|
|
12
|
+
o as fullWidth,
|
|
13
|
+
i as icon,
|
|
14
|
+
t as infobox,
|
|
15
|
+
n as text,
|
|
16
|
+
e as textRow,
|
|
17
|
+
l as title,
|
|
18
|
+
_ as titleRow
|
|
19
|
+
};
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
const a = ["success", "error", "primary", "warning"], c = ["fill", "outline"], l = {
|
|
2
|
+
success: "success",
|
|
3
|
+
error: "error",
|
|
4
|
+
primary: "primary",
|
|
5
|
+
warning: "warning"
|
|
6
|
+
};
|
|
7
|
+
function s(o, r) {
|
|
8
|
+
const n = l[r], t = o === "outline";
|
|
9
|
+
return {
|
|
10
|
+
"--infobox-background": t ? "var(--color--background--neutral--card)" : `var(--color--background--${n}--verysubtle)`,
|
|
11
|
+
"--infobox-border": t ? `var(--color--border--${n}--default)` : "transparent",
|
|
12
|
+
"--infobox-title-color": t ? "var(--color--text--default--body-darker)" : "var(--color--text--default--heading)",
|
|
13
|
+
"--infobox-text-color": t ? "var(--color--text--default--body)" : "var(--color--text--default--body-darker)",
|
|
14
|
+
"--infobox-icon-color": `var(--color--border--${n}--default)`
|
|
15
|
+
};
|
|
16
|
+
}
|
|
17
|
+
const e = {};
|
|
18
|
+
c.forEach((o) => {
|
|
19
|
+
e[o] = {}, a.forEach((r) => {
|
|
20
|
+
e[o][r] = s(o, r);
|
|
21
|
+
});
|
|
22
|
+
});
|
|
23
|
+
function i(o, r) {
|
|
24
|
+
const n = c.includes(o) ? o : "fill", t = a.includes(r) ? r : "success";
|
|
25
|
+
return e[n][t];
|
|
26
|
+
}
|
|
27
|
+
export {
|
|
28
|
+
c as INFOBOX_COLORS,
|
|
29
|
+
a as INFOBOX_STATUSES,
|
|
30
|
+
i as getInfoboxStyles
|
|
31
|
+
};
|