@bioturing/components 0.14.1 → 0.15.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/dist/Badge.css +6 -0
- package/dist/Breadcrumb.css +83 -0
- package/dist/Checkbox.css +13 -0
- package/dist/CodeBlock.css +213 -0
- package/dist/CodeBlock.js +11 -8
- package/dist/Collapse.css +21 -0
- package/dist/DSRoot.css +667 -0
- package/dist/DSRoot.js +264 -17
- package/dist/DropdownMenu.css +95 -0
- package/dist/Empty.css +19 -0
- package/dist/Field.css +14 -0
- package/dist/Form.css +64 -0
- package/dist/IconButton.css +52 -0
- package/dist/Modal.css +317 -0
- package/dist/Modal.js +256 -9
- package/dist/PopupPanel.css +156 -102
- package/dist/Radio.css +14 -0
- package/dist/ScrollArea.css +64 -0
- package/dist/ScrollArea.js +4 -4
- package/dist/Segmented.css +16 -0
- package/dist/Select.css +24 -0
- package/dist/Spin.css +36 -0
- package/dist/Splitter.css +6 -0
- package/dist/Switch.css +7 -0
- package/dist/Table.css +116 -0
- package/dist/Tag.css +17 -0
- package/dist/ThemeProvider.css +39 -0
- package/dist/Toast.css +622 -0
- package/dist/Toast.js +264 -17
- package/dist/Tooltip.css +6 -0
- package/dist/Tour.css +73 -0
- package/dist/Tour.js +1 -1
- package/dist/Truncate.css +31 -0
- package/dist/Truncate.js +75 -19
- package/dist/Upload.css +144 -0
- package/dist/Upload.js +75 -19
- package/dist/VerticalCollapsiblePanel.css +193 -0
- package/dist/VerticalCollapsiblePanel.js +75 -19
- package/dist/components/Badge/component.d.ts +1 -0
- package/dist/components/Breadcrumb/component.d.ts +1 -0
- package/dist/components/Button/component.d.ts +1 -0
- package/dist/components/Checkbox/component.d.ts +1 -0
- package/dist/components/CodeBlock/component.d.ts +2 -1
- package/dist/components/CodeBlock/types.d.ts +12 -0
- package/dist/components/Collapse/component.d.ts +1 -0
- package/dist/components/DSRoot/component.d.ts +1 -0
- package/dist/components/DropdownMenu/component.d.ts +1 -0
- package/dist/components/Empty/component.d.ts +1 -0
- package/dist/components/Field/component.d.ts +1 -0
- package/dist/components/Form/component.d.ts +1 -0
- package/dist/components/IconButton/component.d.ts +1 -0
- package/dist/components/Modal/index.d.ts +1 -0
- package/dist/components/Radio/component.d.ts +1 -0
- package/dist/components/ScrollArea/component.d.ts +26 -4
- package/dist/components/Segmented/component.d.ts +1 -0
- package/dist/components/Select/component.d.ts +1 -0
- package/dist/components/Spin/component.d.ts +1 -0
- package/dist/components/Splitter/component.d.ts +1 -0
- package/dist/components/Stack/Stack.d.ts +39 -0
- package/dist/components/Stack/StackChild.d.ts +30 -0
- package/dist/components/Stack/index.d.ts +8 -0
- package/dist/components/Switch/component.d.ts +1 -0
- package/dist/components/Table/component.d.ts +1 -0
- package/dist/components/Tag/component.d.ts +1 -0
- package/dist/components/ThemeProvider/component.d.ts +1 -0
- package/dist/components/Toast/component.d.ts +1 -0
- package/dist/components/Tooltip/component.d.ts +1 -0
- package/dist/components/Tour/component.d.ts +1 -0
- package/dist/components/Truncate/component.d.ts +3 -0
- package/dist/components/Upload/index.d.ts +1 -0
- package/dist/components/VerticalCollapsiblePanel/component.d.ts +1 -0
- package/dist/components/index.d.ts +1 -0
- package/dist/hooks.js +1 -1
- package/dist/index.css +1469 -114
- package/dist/index.d.ts +1 -0
- package/dist/index.js +784 -156
- package/dist/metadata.d.ts +363 -0
- package/dist/tailwind.css +118 -1
- package/package.json +2 -2
- package/dist/style.css +0 -1392
- package/dist/style.js +0 -0
- package/dist/tailwind.js +0 -0
package/dist/index.js
CHANGED
|
@@ -16,6 +16,8 @@ import * as __WEBPACK_EXTERNAL_MODULE_antd_es_modal_components_NormalCancelBtn_5
|
|
|
16
16
|
import * as __WEBPACK_EXTERNAL_MODULE_antd_es_modal_components_NormalOkBtn_897b50c4__ from "antd/es/modal/components/NormalOkBtn";
|
|
17
17
|
import * as __WEBPACK_EXTERNAL_MODULE_antd_es_modal_locale_f16c0933__ from "antd/es/modal/locale";
|
|
18
18
|
import * as __WEBPACK_EXTERNAL_MODULE_antd_es_locale_31079002__ from "antd/es/locale";
|
|
19
|
+
import * as __WEBPACK_EXTERNAL_MODULE__base_ui_components_react_use_render_2fb9dc6d__ from "@base-ui-components/react/use-render";
|
|
20
|
+
import * as __WEBPACK_EXTERNAL_MODULE__base_ui_components_react_merge_props_04b69945__ from "@base-ui-components/react/merge-props";
|
|
19
21
|
import * as __WEBPACK_EXTERNAL_MODULE_antd_es_switch_101feb97__ from "antd/es/switch";
|
|
20
22
|
import * as __WEBPACK_EXTERNAL_MODULE_antd_es_segmented_6dbdbe23__ from "antd/es/segmented";
|
|
21
23
|
import * as __WEBPACK_EXTERNAL_MODULE_antd_es_table_8c9fc42b__ from "antd/es/table";
|
|
@@ -27,8 +29,6 @@ import * as __WEBPACK_EXTERNAL_MODULE_antd_es_splitter_Panel_2a8c0f35__ from "an
|
|
|
27
29
|
import * as __WEBPACK_EXTERNAL_MODULE__base_ui_components_react_menu_54c0c798__ from "@base-ui-components/react/menu";
|
|
28
30
|
import * as __WEBPACK_EXTERNAL_MODULE__base_ui_components_react_utils_d48cdb94__ from "@base-ui-components/react/utils";
|
|
29
31
|
import * as __WEBPACK_EXTERNAL_MODULE__base_ui_components_react_5aaa6934__ from "@base-ui-components/react";
|
|
30
|
-
import * as __WEBPACK_EXTERNAL_MODULE__base_ui_components_react_use_render_2fb9dc6d__ from "@base-ui-components/react/use-render";
|
|
31
|
-
import * as __WEBPACK_EXTERNAL_MODULE__base_ui_components_react_merge_props_04b69945__ from "@base-ui-components/react/merge-props";
|
|
32
32
|
import * as __WEBPACK_EXTERNAL_MODULE_react_dom_7136dc57__ from "react-dom";
|
|
33
33
|
import * as __WEBPACK_EXTERNAL_MODULE_antd_es_upload_29096ddd__ from "antd/es/upload";
|
|
34
34
|
import * as __WEBPACK_EXTERNAL_MODULE_antd_es_button_8f463bb4__ from "antd/es/button";
|
|
@@ -329,9 +329,244 @@ var constants_ModalSize = /*#__PURE__*/ function(ModalSize) {
|
|
|
329
329
|
ModalSize["fullscreen"] = "100%";
|
|
330
330
|
return ModalSize;
|
|
331
331
|
}({});
|
|
332
|
+
const measureText = (container)=>{
|
|
333
|
+
const span = document.createElement("span");
|
|
334
|
+
span.style.opacity = "0";
|
|
335
|
+
span.style.position = "absolute";
|
|
336
|
+
span.style.top = "-1000px";
|
|
337
|
+
span.style.left = "-1000px";
|
|
338
|
+
span.style.whiteSpace = "nowrap";
|
|
339
|
+
span.style.pointerEvents = "none";
|
|
340
|
+
container.appendChild(span);
|
|
341
|
+
return {
|
|
342
|
+
measure: (text)=>{
|
|
343
|
+
span.innerText = text;
|
|
344
|
+
return span.clientWidth;
|
|
345
|
+
},
|
|
346
|
+
destroy: ()=>{
|
|
347
|
+
container.removeChild(span);
|
|
348
|
+
}
|
|
349
|
+
};
|
|
350
|
+
};
|
|
351
|
+
const getMiddleTruncatedString = (text, ellipsis, container)=>{
|
|
352
|
+
var _Object_values_reverse_find;
|
|
353
|
+
if (!text) return text;
|
|
354
|
+
const { measure: getTextWidth, destroy: destroyMeasure } = measureText(container);
|
|
355
|
+
const textWidth = getTextWidth(text);
|
|
356
|
+
const containerWidth = container.clientWidth;
|
|
357
|
+
const initialOffset = Math.floor(containerWidth / textWidth * text.length);
|
|
358
|
+
if (textWidth <= containerWidth) {
|
|
359
|
+
destroyMeasure();
|
|
360
|
+
return text;
|
|
361
|
+
}
|
|
362
|
+
let offset = initialOffset;
|
|
363
|
+
const attempts = {};
|
|
364
|
+
const maxAttempts = 20;
|
|
365
|
+
const buffer = 10;
|
|
366
|
+
while(Object.values(attempts).length <= maxAttempts){
|
|
367
|
+
if (attempts[offset]) break;
|
|
368
|
+
if (offset <= 1) {
|
|
369
|
+
attempts[0] = [
|
|
370
|
+
0,
|
|
371
|
+
ellipsis
|
|
372
|
+
];
|
|
373
|
+
break;
|
|
374
|
+
}
|
|
375
|
+
const start = text.slice(0, Math.ceil((offset - ellipsis.length) / 2 - 1)).trimEnd();
|
|
376
|
+
const end = text.slice(Math.floor((offset - ellipsis.length) / 2) - offset).trimStart();
|
|
377
|
+
const truncatedStr = start + ellipsis + end;
|
|
378
|
+
const width = getTextWidth(truncatedStr);
|
|
379
|
+
attempts[offset] = [
|
|
380
|
+
width,
|
|
381
|
+
truncatedStr
|
|
382
|
+
];
|
|
383
|
+
if (width >= containerWidth) offset -= 2;
|
|
384
|
+
else {
|
|
385
|
+
if (containerWidth - width < buffer) break;
|
|
386
|
+
offset += 2;
|
|
387
|
+
}
|
|
388
|
+
}
|
|
389
|
+
destroyMeasure();
|
|
390
|
+
return (null == (_Object_values_reverse_find = Object.values(attempts).reverse().find(([width])=>width < containerWidth)) ? void 0 : _Object_values_reverse_find[1]) ?? Object.values(attempts)[0][1];
|
|
391
|
+
};
|
|
392
|
+
"use client";
|
|
393
|
+
const Truncate = ({ children, position = "end", lines = 1, className, style, ...rest })=>{
|
|
394
|
+
const cls = useCls();
|
|
395
|
+
const containerRef = (0, __WEBPACK_EXTERNAL_MODULE_react__.useRef)(null);
|
|
396
|
+
const [isTruncated, setIsTruncated] = (0, __WEBPACK_EXTERNAL_MODULE_react__.useState)(false);
|
|
397
|
+
const [truncatedText, setTruncatedText] = (0, __WEBPACK_EXTERNAL_MODULE_react__.useState)(children);
|
|
398
|
+
const text = children;
|
|
399
|
+
const getContainerStyles = (0, __WEBPACK_EXTERNAL_MODULE_react__.useCallback)(()=>{
|
|
400
|
+
if ("auto" !== lines) return {
|
|
401
|
+
...style,
|
|
402
|
+
...lines > 1 ? {
|
|
403
|
+
"--ds-line-clamp": lines
|
|
404
|
+
} : {}
|
|
405
|
+
};
|
|
406
|
+
return {
|
|
407
|
+
...style,
|
|
408
|
+
"--ds-line-clamp": 999
|
|
409
|
+
};
|
|
410
|
+
}, [
|
|
411
|
+
lines,
|
|
412
|
+
style
|
|
413
|
+
]);
|
|
414
|
+
(0, __WEBPACK_EXTERNAL_MODULE_react__.useLayoutEffect)(()=>{
|
|
415
|
+
const container = containerRef.current;
|
|
416
|
+
if (!container) return;
|
|
417
|
+
if ("auto" === lines) {
|
|
418
|
+
var _window_document_fonts_ready, _window_document_fonts;
|
|
419
|
+
setTruncatedText(text);
|
|
420
|
+
const calculateLines = ()=>{
|
|
421
|
+
const parent = container.parentElement;
|
|
422
|
+
if (!parent) return;
|
|
423
|
+
const styles = window.getComputedStyle(container);
|
|
424
|
+
const fontSize = parseFloat(styles.fontSize);
|
|
425
|
+
const lineHeight = "normal" === styles.lineHeight ? 1.2 * fontSize : parseFloat(styles.lineHeight);
|
|
426
|
+
const parentStyles = window.getComputedStyle(parent);
|
|
427
|
+
const paddingTop = parseFloat(parentStyles.paddingTop) || 0;
|
|
428
|
+
const paddingBottom = parseFloat(parentStyles.paddingBottom) || 0;
|
|
429
|
+
const borderTopWidth = parseFloat(parentStyles.borderTopWidth) || 0;
|
|
430
|
+
const borderBottomWidth = parseFloat(parentStyles.borderBottomWidth) || 0;
|
|
431
|
+
const parentHeight = parent.clientHeight;
|
|
432
|
+
const availableHeight = parentHeight - paddingTop - paddingBottom - borderTopWidth - borderBottomWidth;
|
|
433
|
+
const maxLines = Math.max(1, Math.floor(availableHeight / lineHeight));
|
|
434
|
+
if (container) container.style.setProperty("--ds-line-clamp", String(maxLines));
|
|
435
|
+
const clone = document.createElement("span");
|
|
436
|
+
clone.style.visibility = "hidden";
|
|
437
|
+
clone.style.position = "absolute";
|
|
438
|
+
clone.style.width = `${container.clientWidth}px`;
|
|
439
|
+
clone.style.fontSize = styles.fontSize;
|
|
440
|
+
clone.style.fontFamily = styles.fontFamily;
|
|
441
|
+
clone.style.lineHeight = styles.lineHeight;
|
|
442
|
+
clone.textContent = text;
|
|
443
|
+
document.body.appendChild(clone);
|
|
444
|
+
const isTruncated = clone.scrollHeight > availableHeight;
|
|
445
|
+
document.body.removeChild(clone);
|
|
446
|
+
setIsTruncated(isTruncated);
|
|
447
|
+
};
|
|
448
|
+
null == (_window_document_fonts = window.document.fonts) || null == (_window_document_fonts_ready = _window_document_fonts.ready) || _window_document_fonts_ready.then(calculateLines);
|
|
449
|
+
const observer = new ResizeObserver(()=>{
|
|
450
|
+
window.requestAnimationFrame(calculateLines);
|
|
451
|
+
});
|
|
452
|
+
observer.observe(container);
|
|
453
|
+
if (container.parentElement) observer.observe(container.parentElement);
|
|
454
|
+
return ()=>observer.disconnect();
|
|
455
|
+
}
|
|
456
|
+
if ("number" == typeof lines && lines > 1) {
|
|
457
|
+
var _window_document_fonts_ready1, _window_document_fonts1;
|
|
458
|
+
setTruncatedText(text);
|
|
459
|
+
const checkIfTruncated = ()=>{
|
|
460
|
+
const clone = document.createElement("span");
|
|
461
|
+
clone.style.visibility = "hidden";
|
|
462
|
+
clone.style.position = "absolute";
|
|
463
|
+
clone.style.width = `${container.clientWidth}px`;
|
|
464
|
+
clone.textContent = text;
|
|
465
|
+
document.body.appendChild(clone);
|
|
466
|
+
const isTruncated = clone.scrollHeight > (container.clientHeight || container.offsetHeight);
|
|
467
|
+
document.body.removeChild(clone);
|
|
468
|
+
setIsTruncated(isTruncated);
|
|
469
|
+
};
|
|
470
|
+
null == (_window_document_fonts1 = window.document.fonts) || null == (_window_document_fonts_ready1 = _window_document_fonts1.ready) || _window_document_fonts_ready1.then(checkIfTruncated);
|
|
471
|
+
const observer = new ResizeObserver(()=>{
|
|
472
|
+
window.requestAnimationFrame(checkIfTruncated);
|
|
473
|
+
});
|
|
474
|
+
observer.observe(container);
|
|
475
|
+
return ()=>observer.disconnect();
|
|
476
|
+
}
|
|
477
|
+
let cancellationToken = {
|
|
478
|
+
cancelled: false
|
|
479
|
+
};
|
|
480
|
+
const calculateTruncatedString = ()=>{
|
|
481
|
+
if (cancellationToken) cancellationToken.cancelled = true;
|
|
482
|
+
const requestCancellationToken = {
|
|
483
|
+
cancelled: false
|
|
484
|
+
};
|
|
485
|
+
cancellationToken = requestCancellationToken;
|
|
486
|
+
const truncated = getMiddleTruncatedString(text, "\u2026", container);
|
|
487
|
+
if (requestCancellationToken.cancelled) return;
|
|
488
|
+
setTruncatedText(truncated);
|
|
489
|
+
};
|
|
490
|
+
if ("middle" == position) {
|
|
491
|
+
var _window_document_fonts_ready2, _window_document_fonts2;
|
|
492
|
+
null == (_window_document_fonts2 = window.document.fonts) || null == (_window_document_fonts_ready2 = _window_document_fonts2.ready) || _window_document_fonts_ready2.then(calculateTruncatedString);
|
|
493
|
+
}
|
|
494
|
+
if ("end" == position) setTruncatedText(text);
|
|
495
|
+
const observer = new ResizeObserver(()=>{
|
|
496
|
+
if ("middle" == position) window.requestAnimationFrame(calculateTruncatedString);
|
|
497
|
+
if ("end" == position) {
|
|
498
|
+
const isOverflowing = container.scrollWidth > container.clientWidth;
|
|
499
|
+
if (isOverflowing) setIsTruncated(true);
|
|
500
|
+
}
|
|
501
|
+
});
|
|
502
|
+
observer.observe(container);
|
|
503
|
+
return ()=>{
|
|
504
|
+
cancellationToken.cancelled = true;
|
|
505
|
+
observer.disconnect();
|
|
506
|
+
};
|
|
507
|
+
}, [
|
|
508
|
+
text,
|
|
509
|
+
position,
|
|
510
|
+
lines
|
|
511
|
+
]);
|
|
512
|
+
return /*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__.jsx)("span", {
|
|
513
|
+
ref: containerRef,
|
|
514
|
+
style: getContainerStyles(),
|
|
515
|
+
className: clsx(1 === lines ? cls("truncate") : cls("truncate-multiline"), "middle" === position ? cls("truncate-middle") : cls("truncate-end"), className),
|
|
516
|
+
title: isTruncated ? text : void 0,
|
|
517
|
+
...rest,
|
|
518
|
+
children: text === truncatedText ? text : /*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__.jsx)("span", {
|
|
519
|
+
children: truncatedText
|
|
520
|
+
})
|
|
521
|
+
});
|
|
522
|
+
};
|
|
523
|
+
const Stack = ({ hug = false, align = "flex-start", justify = "flex-start", vertical = false, gap = 0, wrap = false, className, children, ...rest })=>{
|
|
524
|
+
const cls = useCls();
|
|
525
|
+
return /*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__.jsx)("div", {
|
|
526
|
+
className: cn(cls("stack"), hug ? cls("stack-hug") : cls("stack-fill"), cls(`stack-gap-${gap}`), vertical ? cls("stack-vertical") : cls("stack-horizontal"), wrap && cls("stack-wrap"), cls(`stack-align-${align}`), cls(`stack-justify-${justify}`), className),
|
|
527
|
+
...rest,
|
|
528
|
+
children: children
|
|
529
|
+
});
|
|
530
|
+
};
|
|
531
|
+
const StackChild = ({ flex, grow = false, shrink = false, children, style, stack = false, hug = false, align = "flex-start", justify = "flex-start", vertical = false, gap = 0, wrap = false, className, ...rest })=>{
|
|
532
|
+
const cls = useCls();
|
|
533
|
+
const stackProps = {
|
|
534
|
+
hug,
|
|
535
|
+
align,
|
|
536
|
+
justify,
|
|
537
|
+
vertical,
|
|
538
|
+
gap,
|
|
539
|
+
wrap
|
|
540
|
+
};
|
|
541
|
+
let flexClass = "";
|
|
542
|
+
if ("boolean" == typeof flex) flexClass = flex ? cls("stack-child-flex-1") : cls("stack-child-flex-0");
|
|
543
|
+
const combinedClassName = cn(cls("stack-child"), grow && cls("stack-child-grow"), shrink && cls("stack-child-shrink"), flexClass, className);
|
|
544
|
+
const flexValue = "string" == typeof flex || "number" == typeof flex ? flex : void 0;
|
|
545
|
+
const { renderElement } = (0, __WEBPACK_EXTERNAL_MODULE__base_ui_components_react_use_render_2fb9dc6d__.useRender)({
|
|
546
|
+
render: ()=>/*#__PURE__*/ __WEBPACK_EXTERNAL_MODULE_react__["default"].isValidElement(children) ? children : /*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__.jsx)("div", {
|
|
547
|
+
children: children
|
|
548
|
+
}),
|
|
549
|
+
props: (0, __WEBPACK_EXTERNAL_MODULE__base_ui_components_react_merge_props_04b69945__.mergeProps)({
|
|
550
|
+
className: combinedClassName,
|
|
551
|
+
style: {
|
|
552
|
+
...style,
|
|
553
|
+
flex: flexValue
|
|
554
|
+
},
|
|
555
|
+
...rest
|
|
556
|
+
})
|
|
557
|
+
});
|
|
558
|
+
return stack ? /*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__.jsx)(Stack, {
|
|
559
|
+
...stackProps,
|
|
560
|
+
className: combinedClassName,
|
|
561
|
+
children: children
|
|
562
|
+
}) : renderElement();
|
|
563
|
+
};
|
|
564
|
+
const Stack_Stack = Object.assign(Stack, {
|
|
565
|
+
Child: StackChild
|
|
566
|
+
});
|
|
332
567
|
"use client";
|
|
333
568
|
const Modal = ({ open: externalOpen, closeIcon, children, size: sizeProp, footer, width, style, styles, classNames, okButtonProps, cancelButtonProps, loading, onOk, onCancel, okText, okType = "primary", confirmLoading, cancelText = "Close", hideOkButton = false, hideCancelButton = false, contentPadding, title, afterTitle, beforeCloseButton, afterCloseButton, defaultFixedHeaderFooter = false, centered = true, type = "default", defaultOpen = true, background: backgroundProp, bodyScrollable = true, ...rest })=>{
|
|
334
|
-
const defaultCloseIcon = void 0 === closeIcon ? /*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__.jsx)(__WEBPACK_EXTERNAL_MODULE__bioturing_assets_dd0c210d__.
|
|
569
|
+
const defaultCloseIcon = void 0 === closeIcon ? /*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__.jsx)(__WEBPACK_EXTERNAL_MODULE__bioturing_assets_dd0c210d__.XIcon, {
|
|
335
570
|
size: 16,
|
|
336
571
|
weight: "bold"
|
|
337
572
|
}) : closeIcon;
|
|
@@ -414,17 +649,21 @@ const Modal = ({ open: externalOpen, closeIcon, children, size: sizeProp, footer
|
|
|
414
649
|
});
|
|
415
650
|
const renderTitle = ()=>/*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__.jsxs)(__WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__.Fragment, {
|
|
416
651
|
children: [
|
|
417
|
-
/*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__.jsxs)(
|
|
652
|
+
/*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__.jsxs)(Stack_Stack, {
|
|
418
653
|
align: "center",
|
|
419
654
|
gap: 8,
|
|
420
655
|
className: cls("modal-title-wrapper"),
|
|
421
656
|
children: [
|
|
422
|
-
/*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__.jsx)(
|
|
423
|
-
|
|
424
|
-
children: title
|
|
657
|
+
/*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__.jsx)(Stack_Stack.Child, {
|
|
658
|
+
grow: true,
|
|
659
|
+
children: "string" == typeof title ? /*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__.jsx)(Truncate, {
|
|
660
|
+
children: title
|
|
661
|
+
}) : title
|
|
425
662
|
}),
|
|
426
|
-
/*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__.jsxs)(
|
|
427
|
-
|
|
663
|
+
/*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__.jsxs)(Stack_Stack.Child, {
|
|
664
|
+
stack: true,
|
|
665
|
+
hug: true,
|
|
666
|
+
align: "center",
|
|
428
667
|
children: [
|
|
429
668
|
beforeCloseButton,
|
|
430
669
|
/*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__.jsx)(IconButton, {
|
|
@@ -447,7 +686,7 @@ const Modal = ({ open: externalOpen, closeIcon, children, size: sizeProp, footer
|
|
|
447
686
|
title: renderTitle(),
|
|
448
687
|
classNames: {
|
|
449
688
|
...classNames,
|
|
450
|
-
wrapper: cls("modal-wrap", "fullscreen" == size && "modal-fullscreen", isContentOverflow && "modal-content-overflow", false === bodyScrollable && "modal-no-body-scroll",
|
|
689
|
+
wrapper: cls("modal-wrap", "fullscreen" == size && "modal-fullscreen", isContentOverflow && "modal-content-overflow", false === bodyScrollable && "modal-no-body-scroll", defaultFixedHeaderFooter || isContentOverflow || "fullscreen" == size ? "modal-fixed" : "")
|
|
451
690
|
},
|
|
452
691
|
styles: modalStyles,
|
|
453
692
|
modalRender: (modal)=>/*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__.jsx)("div", {
|
|
@@ -1228,141 +1467,6 @@ const Splitter = Object.assign(MainSplitter, {
|
|
|
1228
1467
|
Panel: SplitterPanel
|
|
1229
1468
|
});
|
|
1230
1469
|
const Split = Splitter;
|
|
1231
|
-
const measureText = (container)=>{
|
|
1232
|
-
const span = document.createElement("span");
|
|
1233
|
-
span.style.opacity = "0";
|
|
1234
|
-
span.style.position = "absolute";
|
|
1235
|
-
span.style.top = "-1000px";
|
|
1236
|
-
span.style.left = "-1000px";
|
|
1237
|
-
span.style.whiteSpace = "nowrap";
|
|
1238
|
-
span.style.pointerEvents = "none";
|
|
1239
|
-
container.appendChild(span);
|
|
1240
|
-
return {
|
|
1241
|
-
measure: (text)=>{
|
|
1242
|
-
span.innerText = text;
|
|
1243
|
-
return span.clientWidth;
|
|
1244
|
-
},
|
|
1245
|
-
destroy: ()=>{
|
|
1246
|
-
container.removeChild(span);
|
|
1247
|
-
}
|
|
1248
|
-
};
|
|
1249
|
-
};
|
|
1250
|
-
const getMiddleTruncatedString = (text, ellipsis, container)=>{
|
|
1251
|
-
var _Object_values_reverse_find;
|
|
1252
|
-
if (!text) return text;
|
|
1253
|
-
const { measure: getTextWidth, destroy: destroyMeasure } = measureText(container);
|
|
1254
|
-
const textWidth = getTextWidth(text);
|
|
1255
|
-
const containerWidth = container.clientWidth;
|
|
1256
|
-
const initialOffset = Math.floor(containerWidth / textWidth * text.length);
|
|
1257
|
-
if (textWidth <= containerWidth) {
|
|
1258
|
-
destroyMeasure();
|
|
1259
|
-
return text;
|
|
1260
|
-
}
|
|
1261
|
-
let offset = initialOffset;
|
|
1262
|
-
const attempts = {};
|
|
1263
|
-
const maxAttempts = 20;
|
|
1264
|
-
const buffer = 10;
|
|
1265
|
-
while(Object.values(attempts).length <= maxAttempts){
|
|
1266
|
-
if (attempts[offset]) break;
|
|
1267
|
-
if (offset <= 1) {
|
|
1268
|
-
attempts[0] = [
|
|
1269
|
-
0,
|
|
1270
|
-
ellipsis
|
|
1271
|
-
];
|
|
1272
|
-
break;
|
|
1273
|
-
}
|
|
1274
|
-
const start = text.slice(0, Math.ceil((offset - ellipsis.length) / 2 - 1)).trimEnd();
|
|
1275
|
-
const end = text.slice(Math.floor((offset - ellipsis.length) / 2) - offset).trimStart();
|
|
1276
|
-
const truncatedStr = start + ellipsis + end;
|
|
1277
|
-
const width = getTextWidth(truncatedStr);
|
|
1278
|
-
attempts[offset] = [
|
|
1279
|
-
width,
|
|
1280
|
-
truncatedStr
|
|
1281
|
-
];
|
|
1282
|
-
if (width >= containerWidth) offset -= 2;
|
|
1283
|
-
else {
|
|
1284
|
-
if (containerWidth - width < buffer) break;
|
|
1285
|
-
offset += 2;
|
|
1286
|
-
}
|
|
1287
|
-
}
|
|
1288
|
-
destroyMeasure();
|
|
1289
|
-
return (null == (_Object_values_reverse_find = Object.values(attempts).reverse().find(([width])=>width < containerWidth)) ? void 0 : _Object_values_reverse_find[1]) ?? Object.values(attempts)[0][1];
|
|
1290
|
-
};
|
|
1291
|
-
"use client";
|
|
1292
|
-
const Truncate = ({ children, position = "end", className, style, ...rest })=>{
|
|
1293
|
-
const cls = useCls();
|
|
1294
|
-
const containerRef = (0, __WEBPACK_EXTERNAL_MODULE_react__.useRef)(null);
|
|
1295
|
-
const [isTruncated, setIsTruncated] = (0, __WEBPACK_EXTERNAL_MODULE_react__.useState)(false);
|
|
1296
|
-
const [truncatedText, setTruncatedText] = (0, __WEBPACK_EXTERNAL_MODULE_react__.useState)(children);
|
|
1297
|
-
const text = children;
|
|
1298
|
-
const getContainerStyles = (0, __WEBPACK_EXTERNAL_MODULE_react__.useCallback)(()=>{
|
|
1299
|
-
const baseStyles = {
|
|
1300
|
-
overflow: "hidden",
|
|
1301
|
-
whiteSpace: "nowrap",
|
|
1302
|
-
textOverflow: "clip",
|
|
1303
|
-
flexGrow: 1,
|
|
1304
|
-
minWidth: 0,
|
|
1305
|
-
maxWidth: "100%",
|
|
1306
|
-
display: "block",
|
|
1307
|
-
...style
|
|
1308
|
-
};
|
|
1309
|
-
if ("end" === position) return {
|
|
1310
|
-
...baseStyles,
|
|
1311
|
-
textOverflow: "ellipsis"
|
|
1312
|
-
};
|
|
1313
|
-
return baseStyles;
|
|
1314
|
-
}, [
|
|
1315
|
-
position,
|
|
1316
|
-
style
|
|
1317
|
-
]);
|
|
1318
|
-
(0, __WEBPACK_EXTERNAL_MODULE_react__.useLayoutEffect)(()=>{
|
|
1319
|
-
const container = containerRef.current;
|
|
1320
|
-
if (!container) return;
|
|
1321
|
-
let cancellationToken = {
|
|
1322
|
-
cancelled: false
|
|
1323
|
-
};
|
|
1324
|
-
const calculateTruncatedString = ()=>{
|
|
1325
|
-
if (cancellationToken) cancellationToken.cancelled = true;
|
|
1326
|
-
const requestCancellationToken = {
|
|
1327
|
-
cancelled: false
|
|
1328
|
-
};
|
|
1329
|
-
cancellationToken = requestCancellationToken;
|
|
1330
|
-
const truncated = getMiddleTruncatedString(text, "\u2026", container);
|
|
1331
|
-
if (requestCancellationToken.cancelled) return;
|
|
1332
|
-
setTruncatedText(truncated);
|
|
1333
|
-
};
|
|
1334
|
-
if ("middle" == position) {
|
|
1335
|
-
var _window_document_fonts_ready, _window_document_fonts;
|
|
1336
|
-
null == (_window_document_fonts = window.document.fonts) || null == (_window_document_fonts_ready = _window_document_fonts.ready) || _window_document_fonts_ready.then(calculateTruncatedString);
|
|
1337
|
-
}
|
|
1338
|
-
if ("end" == position) setTruncatedText(text);
|
|
1339
|
-
const observer = new ResizeObserver(()=>{
|
|
1340
|
-
if ("middle" == position) window.requestAnimationFrame(calculateTruncatedString);
|
|
1341
|
-
if ("end" == position) {
|
|
1342
|
-
const isOverflowing = container.scrollWidth > container.clientWidth;
|
|
1343
|
-
if (isOverflowing) setIsTruncated(true);
|
|
1344
|
-
}
|
|
1345
|
-
});
|
|
1346
|
-
observer.observe(container);
|
|
1347
|
-
return ()=>{
|
|
1348
|
-
cancellationToken.cancelled = true;
|
|
1349
|
-
observer.disconnect();
|
|
1350
|
-
};
|
|
1351
|
-
}, [
|
|
1352
|
-
text,
|
|
1353
|
-
position
|
|
1354
|
-
]);
|
|
1355
|
-
return /*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__.jsx)("span", {
|
|
1356
|
-
ref: containerRef,
|
|
1357
|
-
style: getContainerStyles(),
|
|
1358
|
-
className: clsx(cls("truncate"), className),
|
|
1359
|
-
title: isTruncated ? text : void 0,
|
|
1360
|
-
...rest,
|
|
1361
|
-
children: text === truncatedText ? text : /*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__.jsx)("span", {
|
|
1362
|
-
children: truncatedText
|
|
1363
|
-
})
|
|
1364
|
-
});
|
|
1365
|
-
};
|
|
1366
1470
|
"use client";
|
|
1367
1471
|
const DropdownMenu = ({ children, items, placement, openOnHover, open: outsideOpen, onOpenChange: outsideOnOpenChange })=>{
|
|
1368
1472
|
const [open, setOpen] = (0, __WEBPACK_EXTERNAL_MODULE__base_ui_components_react_utils_d48cdb94__.useControlled)({
|
|
@@ -1720,24 +1824,24 @@ const Upload = Object.assign(DefaultUpload, {
|
|
|
1720
1824
|
Item: UploadItem
|
|
1721
1825
|
});
|
|
1722
1826
|
"use client";
|
|
1723
|
-
const ScrollArea = ({ children, className,
|
|
1827
|
+
const ScrollArea = ({ children, className, classNames = {}, orientation = "vertical" })=>{
|
|
1724
1828
|
const cls = useCls();
|
|
1725
1829
|
return /*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__.jsxs)(__WEBPACK_EXTERNAL_MODULE__base_ui_components_react_5aaa6934__.ScrollArea.Root, {
|
|
1726
1830
|
className: clsx(cls("scroll-area"), className),
|
|
1727
1831
|
children: [
|
|
1728
1832
|
/*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__.jsx)(__WEBPACK_EXTERNAL_MODULE__base_ui_components_react_5aaa6934__.ScrollArea.Viewport, {
|
|
1729
|
-
className: clsx(cls("scroll-area-viewport"),
|
|
1833
|
+
className: clsx(cls("scroll-area-viewport"), null == classNames ? void 0 : classNames.viewport),
|
|
1730
1834
|
children: /*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__.jsx)(__WEBPACK_EXTERNAL_MODULE__base_ui_components_react_5aaa6934__.ScrollArea.Content, {
|
|
1731
1835
|
className: clsx(cls("scroll-area-content")),
|
|
1732
1836
|
children: children
|
|
1733
1837
|
})
|
|
1734
1838
|
}),
|
|
1735
1839
|
/*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__.jsx)(__WEBPACK_EXTERNAL_MODULE__base_ui_components_react_5aaa6934__.ScrollArea.Scrollbar, {
|
|
1736
|
-
className: clsx(cls("scroll-area-scrollbar"),
|
|
1840
|
+
className: clsx(cls("scroll-area-scrollbar"), null == classNames ? void 0 : classNames.scrollbar),
|
|
1737
1841
|
orientation: orientation,
|
|
1738
1842
|
"data-orientation": orientation,
|
|
1739
1843
|
children: /*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__.jsx)(__WEBPACK_EXTERNAL_MODULE__base_ui_components_react_5aaa6934__.ScrollArea.Thumb, {
|
|
1740
|
-
className: clsx(cls("scroll-area-thumb",
|
|
1844
|
+
className: clsx(cls("scroll-area-thumb"), null == classNames ? void 0 : classNames.thumb)
|
|
1741
1845
|
})
|
|
1742
1846
|
})
|
|
1743
1847
|
]
|
|
@@ -2192,7 +2296,7 @@ const Tour = ({ indicatorsRender, ...rest })=>{
|
|
|
2192
2296
|
className: cls("tour-indicator-summary-text"),
|
|
2193
2297
|
children: [
|
|
2194
2298
|
current + 1,
|
|
2195
|
-
"
|
|
2299
|
+
"/",
|
|
2196
2300
|
total
|
|
2197
2301
|
]
|
|
2198
2302
|
}),
|
|
@@ -2235,7 +2339,7 @@ const function_toast = Object.assign(createToastTypeFunction("info"), {
|
|
|
2235
2339
|
progress: createToastTypeFunction("progress")
|
|
2236
2340
|
});
|
|
2237
2341
|
"use client";
|
|
2238
|
-
const CodeBlock = ({ code, children, lang: defaultLang = "tsx", className, options, activeOption: controlledActiveOption, defaultActiveOption = 0, onActiveOptionChange, copyText = "Copy", copySuccessText = "Copied", ...rest })=>{
|
|
2342
|
+
const CodeBlock = ({ code, children, lang: defaultLang = "tsx", className, options, activeOption: controlledActiveOption, defaultActiveOption = 0, onActiveOptionChange, copyText = "Copy", copySuccessText = "Copied", classNames, maxHeight, ...rest })=>{
|
|
2239
2343
|
const [activeOption, setActiveOption] = useControlledState(controlledActiveOption, onActiveOptionChange, defaultActiveOption);
|
|
2240
2344
|
const [currentCode, setCurrentCode] = (0, __WEBPACK_EXTERNAL_MODULE_react__.useState)(code || "");
|
|
2241
2345
|
const [lang, setLang] = (0, __WEBPACK_EXTERNAL_MODULE_react__.useState)(defaultLang);
|
|
@@ -2278,11 +2382,11 @@ const CodeBlock = ({ code, children, lang: defaultLang = "tsx", className, optio
|
|
|
2278
2382
|
return /*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__.jsx)(ThemeProvider, {
|
|
2279
2383
|
theme: "dark",
|
|
2280
2384
|
children: /*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__.jsxs)(WithAntdTokens, {
|
|
2281
|
-
className: clsx(cls("code-block"), className),
|
|
2385
|
+
className: clsx(cls("code-block"), className, null == classNames ? void 0 : classNames.root),
|
|
2282
2386
|
...rest,
|
|
2283
2387
|
children: [
|
|
2284
2388
|
hasOptions && /*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__.jsx)("div", {
|
|
2285
|
-
className: cls("code-block-header"),
|
|
2389
|
+
className: cls("code-block-header", null == classNames ? void 0 : classNames.header),
|
|
2286
2390
|
children: /*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__.jsx)(Segmented, {
|
|
2287
2391
|
value: activeOption,
|
|
2288
2392
|
onChange: setActiveOption,
|
|
@@ -2302,7 +2406,10 @@ const CodeBlock = ({ code, children, lang: defaultLang = "tsx", className, optio
|
|
|
2302
2406
|
})
|
|
2303
2407
|
}),
|
|
2304
2408
|
/*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__.jsx)("div", {
|
|
2305
|
-
className: cls("code-block-content"),
|
|
2409
|
+
className: cls("code-block-content", null == classNames ? void 0 : classNames.content),
|
|
2410
|
+
style: {
|
|
2411
|
+
maxHeight: maxHeight && ("number" == typeof maxHeight ? `${maxHeight}px` : maxHeight)
|
|
2412
|
+
},
|
|
2306
2413
|
children: /*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__.jsx)(ScrollArea, {
|
|
2307
2414
|
children: currentCode ? /*#__PURE__*/ (0, __WEBPACK_EXTERNAL_MODULE_react_jsx_runtime_225474f2__.jsx)(__WEBPACK_EXTERNAL_MODULE_prism_react_renderer_be33806e__.Highlight, {
|
|
2308
2415
|
language: lang,
|
|
@@ -3308,7 +3415,7 @@ const useCharts = ()=>{
|
|
|
3308
3415
|
},
|
|
3309
3416
|
axisLabel: {
|
|
3310
3417
|
color: axisLabelColor,
|
|
3311
|
-
fontFamily: "InterVariable"
|
|
3418
|
+
fontFamily: "InterVariable, Inter, Helvetica, Arial, sans-serif"
|
|
3312
3419
|
}
|
|
3313
3420
|
};
|
|
3314
3421
|
return {
|
|
@@ -3319,6 +3426,527 @@ const useCharts = ()=>{
|
|
|
3319
3426
|
echartsAxisConfig
|
|
3320
3427
|
};
|
|
3321
3428
|
};
|
|
3429
|
+
const componentMetadata = {
|
|
3430
|
+
Badge: {
|
|
3431
|
+
name: "Badge",
|
|
3432
|
+
link: "/badge",
|
|
3433
|
+
base: "antd",
|
|
3434
|
+
refinements: [
|
|
3435
|
+
"Applies a BioTuring Design System specific CSS class 'ds-badge'.",
|
|
3436
|
+
"Applies Ant Design's CSS variable class name to ensure proper theming context.",
|
|
3437
|
+
"Sets 'display: inline-flex;' on the 'ds-badge' class via './style.css' for consistent layout."
|
|
3438
|
+
],
|
|
3439
|
+
category: "Data Display",
|
|
3440
|
+
originalDocUrl: "https://ant.design/components/badge",
|
|
3441
|
+
description: "Used for highlighting new or unread items, or to display a status."
|
|
3442
|
+
},
|
|
3443
|
+
Breadcrumb: {
|
|
3444
|
+
name: "Breadcrumb",
|
|
3445
|
+
link: "/breadcrumb",
|
|
3446
|
+
base: "antd",
|
|
3447
|
+
refinements: [
|
|
3448
|
+
"Employs a custom 'useItemRender' hook to allow icons (from 'item.icon') to be rendered alongside the title within each breadcrumb link.",
|
|
3449
|
+
"Introduces a 'noWrap' boolean prop for responsive behavior: when true, breadcrumb items attempt to stay on a single line, with text overflow and ellipsis applied to truncatable items.",
|
|
3450
|
+
"Applies BioTuring Design System specific styling via './style.css' for layout (flexbox-based), item spacing, icon integration, and responsive truncation.",
|
|
3451
|
+
"Exports styled 'Breadcrumb.Item' and 'Breadcrumb.Separator' sub-components."
|
|
3452
|
+
],
|
|
3453
|
+
category: "Navigation",
|
|
3454
|
+
originalDocUrl: "https://ant.design/components/breadcrumb",
|
|
3455
|
+
description: "Displays the path of the current page, allowing for easy navigation back to previous levels."
|
|
3456
|
+
},
|
|
3457
|
+
Button: {
|
|
3458
|
+
name: "Button",
|
|
3459
|
+
link: "/button",
|
|
3460
|
+
base: "antd",
|
|
3461
|
+
refinements: [],
|
|
3462
|
+
category: "Actions",
|
|
3463
|
+
originalDocUrl: "https://ant.design/components/button",
|
|
3464
|
+
description: "A clickable element used to trigger an action."
|
|
3465
|
+
},
|
|
3466
|
+
Checkbox: {
|
|
3467
|
+
name: "Checkbox",
|
|
3468
|
+
link: "/checkbox",
|
|
3469
|
+
base: "antd",
|
|
3470
|
+
refinements: [],
|
|
3471
|
+
category: "Data Entry",
|
|
3472
|
+
originalDocUrl: "https://ant.design/components/checkbox",
|
|
3473
|
+
description: "Allows users to select one or more options from a set."
|
|
3474
|
+
},
|
|
3475
|
+
CodeBlock: {
|
|
3476
|
+
name: "CodeBlock",
|
|
3477
|
+
link: "/code-block",
|
|
3478
|
+
base: "custom",
|
|
3479
|
+
refinements: [
|
|
3480
|
+
"Custom implementation for syntax highlighting using prism-react-renderer"
|
|
3481
|
+
],
|
|
3482
|
+
category: "Data Display",
|
|
3483
|
+
packages: [
|
|
3484
|
+
"prism-react-renderer"
|
|
3485
|
+
],
|
|
3486
|
+
description: "Displays blocks of code with syntax highlighting."
|
|
3487
|
+
},
|
|
3488
|
+
Collapse: {
|
|
3489
|
+
name: "Collapse",
|
|
3490
|
+
link: "/collapse",
|
|
3491
|
+
base: "antd",
|
|
3492
|
+
refinements: [],
|
|
3493
|
+
category: "Data Display",
|
|
3494
|
+
originalDocUrl: "https://ant.design/components/collapse",
|
|
3495
|
+
description: "A content area that can be expanded or collapsed."
|
|
3496
|
+
},
|
|
3497
|
+
DropdownMenu: {
|
|
3498
|
+
name: "DropdownMenu",
|
|
3499
|
+
link: "/dropdown-menu",
|
|
3500
|
+
base: "base-ui",
|
|
3501
|
+
refinements: [
|
|
3502
|
+
"Built with Base UI Menu components",
|
|
3503
|
+
"Provides a customizable dropdown menu experience"
|
|
3504
|
+
],
|
|
3505
|
+
category: "Navigation",
|
|
3506
|
+
packages: [
|
|
3507
|
+
"@base-ui-components/react/menu",
|
|
3508
|
+
"@base-ui-components/react/utils"
|
|
3509
|
+
],
|
|
3510
|
+
originalDocUrl: "https://base-ui.com/react/components/menu",
|
|
3511
|
+
description: "A menu that appears when a user interacts with a button or other control."
|
|
3512
|
+
},
|
|
3513
|
+
Empty: {
|
|
3514
|
+
name: "Empty",
|
|
3515
|
+
link: "/empty",
|
|
3516
|
+
base: "antd",
|
|
3517
|
+
refinements: [
|
|
3518
|
+
"Replaces the default Ant Design illustration with a custom SVG icon ('EmptyIcon') defined within the component.",
|
|
3519
|
+
"Introduces a 'size' prop ('small', 'medium', 'large', default 'medium') that controls the font-size of the custom 'EmptyIcon'.",
|
|
3520
|
+
"Applies specific font-sizes for the icon based on the 'size' prop (small: 2rem, medium: 3rem, large: 4rem) via 'style.css'.",
|
|
3521
|
+
"The 'small' size icon also has its color set to 'var(--ds-color-base-solid)'.",
|
|
3522
|
+
"Adjusts the Ant Design Empty image container height to 'auto' via 'style.css'.",
|
|
3523
|
+
"Applies BioTuring Design System specific styling and CSS classes (e.g., 'ds-empty', 'ds-empty-icon')."
|
|
3524
|
+
],
|
|
3525
|
+
category: "Data Display",
|
|
3526
|
+
originalDocUrl: "https://ant.design/components/empty",
|
|
3527
|
+
description: "A placeholder for when there is no data to display."
|
|
3528
|
+
},
|
|
3529
|
+
Field: {
|
|
3530
|
+
name: "Field",
|
|
3531
|
+
link: "/field",
|
|
3532
|
+
base: "custom",
|
|
3533
|
+
refinements: [
|
|
3534
|
+
"Custom component for form fields, providing layout and validation display"
|
|
3535
|
+
],
|
|
3536
|
+
category: "Data Entry",
|
|
3537
|
+
description: "A custom component to structure form inputs with labels, help text, and validation messages."
|
|
3538
|
+
},
|
|
3539
|
+
Form: {
|
|
3540
|
+
name: "Form",
|
|
3541
|
+
link: "/form",
|
|
3542
|
+
base: "antd",
|
|
3543
|
+
refinements: [],
|
|
3544
|
+
category: "Data Entry",
|
|
3545
|
+
originalDocUrl: "https://ant.design/components/form",
|
|
3546
|
+
description: "Provides structure for data input, including layout, validation, and submission capabilities."
|
|
3547
|
+
},
|
|
3548
|
+
IconButton: {
|
|
3549
|
+
name: "Icon Button",
|
|
3550
|
+
link: "/icon-button",
|
|
3551
|
+
base: "custom",
|
|
3552
|
+
refinements: [
|
|
3553
|
+
"Custom button component focused on displaying an icon",
|
|
3554
|
+
"Provides consistent styling for icon-only buttons"
|
|
3555
|
+
],
|
|
3556
|
+
category: "Actions",
|
|
3557
|
+
description: "A button that primarily displays an icon, used for compact actions."
|
|
3558
|
+
},
|
|
3559
|
+
Input: {
|
|
3560
|
+
name: "Input",
|
|
3561
|
+
link: "/input",
|
|
3562
|
+
base: "antd",
|
|
3563
|
+
refinements: [],
|
|
3564
|
+
category: "Data Entry",
|
|
3565
|
+
originalDocUrl: "https://ant.design/components/input",
|
|
3566
|
+
description: "A basic text input field for user data entry."
|
|
3567
|
+
},
|
|
3568
|
+
Message: {
|
|
3569
|
+
name: "Message",
|
|
3570
|
+
link: "/message",
|
|
3571
|
+
base: "antd",
|
|
3572
|
+
refinements: [],
|
|
3573
|
+
category: "Feedback",
|
|
3574
|
+
originalDocUrl: "https://ant.design/components/message",
|
|
3575
|
+
description: "The Message component provides feedback in response to user operations. Unlike notification, messages are simpler and typically auto-dismiss after a short duration."
|
|
3576
|
+
},
|
|
3577
|
+
Modal: {
|
|
3578
|
+
name: "Modal",
|
|
3579
|
+
link: "/modal",
|
|
3580
|
+
base: "antd",
|
|
3581
|
+
refinements: [
|
|
3582
|
+
"Added predefined sizes: 'xsmall', 'small', 'medium', 'large', 'xlarge', 'xxlarge', 'fullscreen'",
|
|
3583
|
+
"Introduced a general 'loading' state prop for the modal content",
|
|
3584
|
+
"Added 'hideOkButton' and 'hideCancelButton' props for straightforward visibility control of footer buttons",
|
|
3585
|
+
"Added 'contentPadding' prop for direct control over modal body padding",
|
|
3586
|
+
"Enhanced header customization with 'afterTitle', 'beforeCloseButton', and 'afterCloseButton' slots for additional elements or actions",
|
|
3587
|
+
"Implemented 'defaultFixedHeaderFooter' behavior: header and footer become fixed when content overflows (controlled by internal overflow detection)",
|
|
3588
|
+
"Changed 'centered' prop to default to 'true'",
|
|
3589
|
+
"Introduced 'type' prop ('default', 'info', 'success', 'error', 'warning') influencing default behaviors like size",
|
|
3590
|
+
"Added 'background' prop ('elevated', 'container') for explicit control over modal background style, with size-dependent defaults",
|
|
3591
|
+
"Uses a custom 'X' icon from '@bioturing/assets' as the default close button icon",
|
|
3592
|
+
"Provides 'bodyScrollable' prop (defaults to true) to manage content scroll behavior within the modal body"
|
|
3593
|
+
],
|
|
3594
|
+
category: "Overlay",
|
|
3595
|
+
originalDocUrl: "https://ant.design/components/modal",
|
|
3596
|
+
description: "A dialog box/popup window that is displayed on top of the current page."
|
|
3597
|
+
},
|
|
3598
|
+
Popover: {
|
|
3599
|
+
name: "Popover",
|
|
3600
|
+
link: "/popover",
|
|
3601
|
+
base: "antd",
|
|
3602
|
+
refinements: [
|
|
3603
|
+
"Refactored to use @base-ui-components/react/popover internally",
|
|
3604
|
+
"Maintains Ant Design API compatibility",
|
|
3605
|
+
"Custom prop mapping for placement and trigger to align with Base UI Popover",
|
|
3606
|
+
"Combined title and content props into a single node for Base UI Popover's content area"
|
|
3607
|
+
],
|
|
3608
|
+
category: "Overlay",
|
|
3609
|
+
originalDocUrl: "https://ant.design/components/popover",
|
|
3610
|
+
description: "A small overlay that appears when a user interacts with an element, displaying additional information or actions."
|
|
3611
|
+
},
|
|
3612
|
+
PopupPanel: {
|
|
3613
|
+
name: "PopupPanel",
|
|
3614
|
+
link: "/popup-panel",
|
|
3615
|
+
base: "base-ui",
|
|
3616
|
+
refinements: [
|
|
3617
|
+
"Built with Base UI Popover",
|
|
3618
|
+
"Resizable panel functionality",
|
|
3619
|
+
"Custom styling and behavior for panel-like popups"
|
|
3620
|
+
],
|
|
3621
|
+
category: "Overlay",
|
|
3622
|
+
packages: [
|
|
3623
|
+
"react-use-resizable",
|
|
3624
|
+
"@base-ui-components/react/popover"
|
|
3625
|
+
],
|
|
3626
|
+
originalDocUrl: "https://base-ui.com/react/components/popover",
|
|
3627
|
+
description: "A specialized panel that pops up, often resizable, for displaying rich content or tools."
|
|
3628
|
+
},
|
|
3629
|
+
Radio: {
|
|
3630
|
+
name: "Radio",
|
|
3631
|
+
link: "/radio",
|
|
3632
|
+
base: "antd",
|
|
3633
|
+
refinements: [],
|
|
3634
|
+
category: "Data Entry",
|
|
3635
|
+
originalDocUrl: "https://ant.design/components/radio",
|
|
3636
|
+
description: "Allows users to select a single option from a set."
|
|
3637
|
+
},
|
|
3638
|
+
ScrollArea: {
|
|
3639
|
+
name: "ScrollArea",
|
|
3640
|
+
link: "/scroll-area",
|
|
3641
|
+
base: "base-ui",
|
|
3642
|
+
refinements: [
|
|
3643
|
+
"Wraps '@base-ui-components/react/ScrollArea' to integrate with the BioTuring Design System.",
|
|
3644
|
+
"Provides consistent 'classNames' prop pattern for styling different parts (viewport, scrollbar, thumb).",
|
|
3645
|
+
"Applies specific BioTuring Design System CSS classes (e.g., 'ds-scroll-area', 'ds-scroll-area-viewport', 'ds-scroll-area-scrollbar', 'ds-scroll-area-thumb') to Base UI component parts.",
|
|
3646
|
+
"Provides extensive custom styling via './style.css' for the root, viewport (including 'focus-visible' styles), scrollbar (opacity transitions on hover/scroll, orientation-based dimensions), and thumb (custom border-radius, background, and border colors using design tokens)."
|
|
3647
|
+
],
|
|
3648
|
+
category: "Layout",
|
|
3649
|
+
packages: [
|
|
3650
|
+
"@base-ui-components/react"
|
|
3651
|
+
],
|
|
3652
|
+
originalDocUrl: "https://base-ui.com/react/components/scroll-area",
|
|
3653
|
+
description: "Provides a customizable scrollable container for content that exceeds its bounds."
|
|
3654
|
+
},
|
|
3655
|
+
Segmented: {
|
|
3656
|
+
name: "Segmented",
|
|
3657
|
+
link: "/segmented",
|
|
3658
|
+
base: "antd",
|
|
3659
|
+
refinements: [
|
|
3660
|
+
"Structured as a typed 'forwardRef' wrapper around the Ant Design Segmented component for type safety and consistency.",
|
|
3661
|
+
"Applies custom styles via './style.css' to ensure proper alignment and sizing of item labels and icons within the segmented control (e.g., flex centering for labels and icons, default icon size)."
|
|
3662
|
+
],
|
|
3663
|
+
category: "Data Entry",
|
|
3664
|
+
originalDocUrl: "https://ant.design/components/segmented",
|
|
3665
|
+
description: "A set of buttons that allows users to switch between different views or options."
|
|
3666
|
+
},
|
|
3667
|
+
Select: {
|
|
3668
|
+
name: "Select",
|
|
3669
|
+
link: "/select",
|
|
3670
|
+
base: "antd",
|
|
3671
|
+
refinements: [
|
|
3672
|
+
"Introduced 'enhancePositioner' prop: Utilizes '@floating-ui/react' for robust dropdown positioning, allowing it to break out of overflow containers and intelligently place itself.",
|
|
3673
|
+
"Added 'popupSize' prop (works with 'enhancePositioner'): Controls the dropdown width with predefined sizes (e.g., 'small', 'medium', 'large'), pixel values, or 'fit-content'.",
|
|
3674
|
+
"Replaced default suffix icon with a custom 'CaretDown' icon from '@bioturing/assets'.",
|
|
3675
|
+
"Customized multiple selection mode: Uses Ant Design 'Checkbox' components for indicating selected items in the dropdown.",
|
|
3676
|
+
"Applied specific BioTuring Design System styling and CSS classes, including enhanced popup styles when 'enhancePositioner' is active."
|
|
3677
|
+
],
|
|
3678
|
+
category: "Data Entry",
|
|
3679
|
+
packages: [
|
|
3680
|
+
"@floating-ui/react",
|
|
3681
|
+
"rc-select"
|
|
3682
|
+
],
|
|
3683
|
+
originalDocUrl: "https://ant.design/components/select",
|
|
3684
|
+
description: "Allows users to select one or more options from a dropdown list."
|
|
3685
|
+
},
|
|
3686
|
+
Slider: {
|
|
3687
|
+
name: "Slider",
|
|
3688
|
+
link: "/slider",
|
|
3689
|
+
base: "antd",
|
|
3690
|
+
refinements: [
|
|
3691
|
+
"Applies a BioTuring Design System specific CSS class 'ds-slider'.",
|
|
3692
|
+
"Modifies the default behavior of the slider's tooltip by setting 'tooltip.arrow' to 'false' by default (Ant Design's default is true)."
|
|
3693
|
+
],
|
|
3694
|
+
category: "Data Entry",
|
|
3695
|
+
originalDocUrl: "https://ant.design/components/slider",
|
|
3696
|
+
description: "Allows users to select a value from a continuous or discrete range."
|
|
3697
|
+
},
|
|
3698
|
+
Spin: {
|
|
3699
|
+
name: "Spin",
|
|
3700
|
+
link: "/spin",
|
|
3701
|
+
base: "antd",
|
|
3702
|
+
refinements: [],
|
|
3703
|
+
category: "Feedback",
|
|
3704
|
+
originalDocUrl: "https://ant.design/components/spin",
|
|
3705
|
+
description: "Indicates a loading state."
|
|
3706
|
+
},
|
|
3707
|
+
Splitter: {
|
|
3708
|
+
name: "Splitter",
|
|
3709
|
+
link: "/splitter",
|
|
3710
|
+
base: "antd",
|
|
3711
|
+
refinements: [
|
|
3712
|
+
"Custom component for creating resizable layouts, inspired by Ant Design styling"
|
|
3713
|
+
],
|
|
3714
|
+
category: "Layout",
|
|
3715
|
+
description: "Splitter is used to divide and resize multiple elements in a container."
|
|
3716
|
+
},
|
|
3717
|
+
Stack: {
|
|
3718
|
+
name: "Stack",
|
|
3719
|
+
link: "/stack",
|
|
3720
|
+
base: "custom",
|
|
3721
|
+
refinements: [
|
|
3722
|
+
"Custom component for creating horizontal or vertical layouts with consistent spacing",
|
|
3723
|
+
"Uses CSS classes for alignment and justification",
|
|
3724
|
+
"Provides StackChild component with useRender hook for flexible item control"
|
|
3725
|
+
],
|
|
3726
|
+
category: "Layout",
|
|
3727
|
+
description: "A flexible layout component for arranging items in a row or column with consistent spacing."
|
|
3728
|
+
},
|
|
3729
|
+
Switch: {
|
|
3730
|
+
name: "Switch",
|
|
3731
|
+
link: "/switch",
|
|
3732
|
+
base: "antd",
|
|
3733
|
+
refinements: [
|
|
3734
|
+
"Structured as a typed 'forwardRef' wrapper around Ant Design's Switch component.",
|
|
3735
|
+
"Applies custom CSS to ensure 'checkedChildren' and 'unCheckedChildren' (e.g., icons, text) are properly centered within the switch handle."
|
|
3736
|
+
],
|
|
3737
|
+
category: "Data Entry",
|
|
3738
|
+
originalDocUrl: "https://ant.design/components/switch",
|
|
3739
|
+
description: "A toggle control that allows users to switch between two states, typically on or off."
|
|
3740
|
+
},
|
|
3741
|
+
Table: {
|
|
3742
|
+
name: "Table",
|
|
3743
|
+
link: "/table",
|
|
3744
|
+
base: "antd",
|
|
3745
|
+
refinements: [
|
|
3746
|
+
"Replaces default sort icons with custom 'CaretUp' and 'CaretDown' icons from '@bioturing/assets'. Displays both when inactive, and a filled version of the active one.",
|
|
3747
|
+
"Replaces default filter icon with a custom 'Funnel' icon (filled) from '@bioturing/assets'.",
|
|
3748
|
+
"Overrides 'locale.emptyText' to use the BioTuring 'Empty' component.",
|
|
3749
|
+
"Adds an 'emptyDescription' prop to customize the message displayed by the 'Empty' component when the table is empty.",
|
|
3750
|
+
"Uses a custom CSS-based loading indicator ('spin-loader') when the 'loading' prop is active.",
|
|
3751
|
+
"Defaults 'scroll.x' to 'fit-content' to optimize horizontal scrolling behavior.",
|
|
3752
|
+
"Applies BioTuring Design System specific styling via './style.css' for overall table appearance, including headers, rows, borders, and hover effects."
|
|
3753
|
+
],
|
|
3754
|
+
category: "Data Display",
|
|
3755
|
+
packages: [
|
|
3756
|
+
"rc-table"
|
|
3757
|
+
],
|
|
3758
|
+
originalDocUrl: "https://ant.design/components/table",
|
|
3759
|
+
description: "Displays data in a structured, tabular format."
|
|
3760
|
+
},
|
|
3761
|
+
Tag: {
|
|
3762
|
+
name: "Tag",
|
|
3763
|
+
link: "/tag",
|
|
3764
|
+
base: "antd",
|
|
3765
|
+
refinements: [
|
|
3766
|
+
"Defaults to using the 'X' icon (bold) from '@bioturing/assets' as the 'closeIcon' if the tag is 'closable' and no custom icon is provided.",
|
|
3767
|
+
"Introduces an 'active' boolean prop (defaults to false).",
|
|
3768
|
+
"When 'active={true}', applies specific styling (background, border, text color using '--ds-color-primary' tokens) via a 'data-active' attribute and 'style.css'.",
|
|
3769
|
+
"Applies BioTuring Design System specific styling via './style.css', including base styles for alignment and consistent close icon coloring ('--ds-color-icon')."
|
|
3770
|
+
],
|
|
3771
|
+
category: "Data Display",
|
|
3772
|
+
originalDocUrl: "https://ant.design/components/tag",
|
|
3773
|
+
description: "Used for marking or categorizing items with small labels."
|
|
3774
|
+
},
|
|
3775
|
+
ThemeProvider: {
|
|
3776
|
+
name: "ThemeProvider",
|
|
3777
|
+
link: "/theme-provider",
|
|
3778
|
+
base: "custom",
|
|
3779
|
+
refinements: [
|
|
3780
|
+
"Custom utility for managing application-wide themes",
|
|
3781
|
+
"Provides context for styling consistency"
|
|
3782
|
+
],
|
|
3783
|
+
category: "Utility",
|
|
3784
|
+
description: "A utility component for providing theme context to its children, enabling consistent styling across the application."
|
|
3785
|
+
},
|
|
3786
|
+
Toast: {
|
|
3787
|
+
name: "Toast",
|
|
3788
|
+
link: "/toast",
|
|
3789
|
+
base: "base-ui",
|
|
3790
|
+
refinements: [
|
|
3791
|
+
"Built with Base UI Toast components",
|
|
3792
|
+
"Customizable appearance and behavior for notifications"
|
|
3793
|
+
],
|
|
3794
|
+
category: "Feedback",
|
|
3795
|
+
packages: [
|
|
3796
|
+
"@base-ui-components/react"
|
|
3797
|
+
],
|
|
3798
|
+
originalDocUrl: "https://base-ui.com/react/components/toast",
|
|
3799
|
+
description: "Displays brief, auto-expiring messages to provide feedback or alerts, similar to notifications but often less intrusive."
|
|
3800
|
+
},
|
|
3801
|
+
Tooltip: {
|
|
3802
|
+
name: "Tooltip",
|
|
3803
|
+
link: "/tooltip",
|
|
3804
|
+
base: "antd",
|
|
3805
|
+
refinements: [
|
|
3806
|
+
"Defaults the 'arrow' prop to 'false', hiding the tooltip arrow by default (Ant Design's default shows an arrow).",
|
|
3807
|
+
"Applies a BioTuring Design System specific CSS class 'ds-tooltip'.",
|
|
3808
|
+
"Custom CSS sets 'min-height: auto;' for the inner content, allowing tooltips to be shorter than Ant Design's default minimum height."
|
|
3809
|
+
],
|
|
3810
|
+
category: "Overlay",
|
|
3811
|
+
originalDocUrl: "https://ant.design/components/tooltip",
|
|
3812
|
+
description: "A small pop-up that displays information when a user hovers over or focuses on an element."
|
|
3813
|
+
},
|
|
3814
|
+
Tour: {
|
|
3815
|
+
name: "Tour",
|
|
3816
|
+
link: "/tour",
|
|
3817
|
+
base: "antd",
|
|
3818
|
+
refinements: [
|
|
3819
|
+
"Provides a custom default rendering for step indicators ('indicatorsRender') if none is supplied. This includes a 'current / total' text and visual dots for steps.",
|
|
3820
|
+
"Applies BioTuring Design System specific CSS classes (e.g., 'ds-tour') for extensive styling.",
|
|
3821
|
+
"Customizes typography for title, description, and indicator text using design system tokens.",
|
|
3822
|
+
"Adjusts layout and spacing for header, footer, and content within the tour description (paragraphs, lists, icons).",
|
|
3823
|
+
"Includes specific styling for the appearance of the custom default indicators (wrapper, summary text, active/inactive dots)."
|
|
3824
|
+
],
|
|
3825
|
+
category: "Feedback",
|
|
3826
|
+
originalDocUrl: "https://ant.design/components/tour",
|
|
3827
|
+
description: "Guides users through new features or UI elements in a step-by-step manner."
|
|
3828
|
+
},
|
|
3829
|
+
Transition: {
|
|
3830
|
+
name: "Transition",
|
|
3831
|
+
link: "/transition",
|
|
3832
|
+
base: "base-ui",
|
|
3833
|
+
refinements: [
|
|
3834
|
+
"Wraps Base UI utilities (e.g., 'useTransitionStatus', 'useRender') and custom hooks (e.g., 'useAnimationsFinished') to manage element enter/leave transitions.",
|
|
3835
|
+
"Accepts 'starting' and 'ending' props, which can be CSS class strings (for Tailwind) or style objects, to define transition states.",
|
|
3836
|
+
"Dynamically applies 'starting'/'ending' styles and sets 'data-starting'/'data-ending' attributes on the child element based on transition phase.",
|
|
3837
|
+
"Manages mounting/unmounting of children post-animation, with a 'keepMounted' option, using a custom 'useAnimationsFinished' hook.",
|
|
3838
|
+
"Provides a declarative API for CSS-based transitions."
|
|
3839
|
+
],
|
|
3840
|
+
category: "Utility",
|
|
3841
|
+
packages: [
|
|
3842
|
+
"@base-ui-components/react/use-render",
|
|
3843
|
+
"@base-ui-components/react/merge-props",
|
|
3844
|
+
"@base-ui-components/react/utils"
|
|
3845
|
+
],
|
|
3846
|
+
originalDocUrl: "https://base-ui.com/react/components",
|
|
3847
|
+
description: "Provides utilities for applying CSS transitions and animations to components."
|
|
3848
|
+
},
|
|
3849
|
+
Typography: {
|
|
3850
|
+
name: "Typography",
|
|
3851
|
+
link: "/typography",
|
|
3852
|
+
base: "antd",
|
|
3853
|
+
refinements: [
|
|
3854
|
+
"Extends Ant Design Typography with custom styles or additional text utilities"
|
|
3855
|
+
],
|
|
3856
|
+
category: "Data Display",
|
|
3857
|
+
originalDocUrl: "https://ant.design/components/typography",
|
|
3858
|
+
description: "Typography is a component that provides a set of tools for working with text, including text alignment, font size, and font weight."
|
|
3859
|
+
},
|
|
3860
|
+
Tree: {
|
|
3861
|
+
name: "Tree",
|
|
3862
|
+
link: "/tree",
|
|
3863
|
+
base: "antd",
|
|
3864
|
+
refinements: [
|
|
3865
|
+
"Utilizes rc-tree for core functionality",
|
|
3866
|
+
"Enhanced features like custom node rendering, drag-and-drop, or advanced filtering"
|
|
3867
|
+
],
|
|
3868
|
+
category: "Data Display",
|
|
3869
|
+
packages: [
|
|
3870
|
+
"rc-tree"
|
|
3871
|
+
],
|
|
3872
|
+
originalDocUrl: "https://ant.design/components/tree",
|
|
3873
|
+
description: "A hierarchical list structure component that presents nested data clearly."
|
|
3874
|
+
},
|
|
3875
|
+
Truncate: {
|
|
3876
|
+
name: "Truncate",
|
|
3877
|
+
link: "/truncate",
|
|
3878
|
+
base: "custom",
|
|
3879
|
+
refinements: [
|
|
3880
|
+
"Custom implementation for text truncation",
|
|
3881
|
+
"Supports middle and end truncation",
|
|
3882
|
+
"Configurable ellipsis and tooltip on hover",
|
|
3883
|
+
"Multi-line truncation with configurable number of lines",
|
|
3884
|
+
"Auto-height truncation that adapts to parent container size"
|
|
3885
|
+
],
|
|
3886
|
+
category: "Data Display",
|
|
3887
|
+
description: "The Truncate component helps manage text overflow by truncating text elegantly and displaying an ellipsis. It supports truncation at the middle or end of the text."
|
|
3888
|
+
},
|
|
3889
|
+
Upload: {
|
|
3890
|
+
name: "Upload",
|
|
3891
|
+
link: "/upload",
|
|
3892
|
+
base: "antd",
|
|
3893
|
+
refinements: [
|
|
3894
|
+
"Defaults to a custom 'itemRender' function that utilizes a bespoke 'UploadItem' component for the file list.",
|
|
3895
|
+
"'UploadItem' component features: file type icon, middle-truncated file name (using Truncate component), progress bar with status mapping, and a remove button.",
|
|
3896
|
+
"Added 'showRemoveButton' prop (defaults to true) on the 'Upload' component to control visibility of the remove action in 'UploadItem'.",
|
|
3897
|
+
"'UploadItem' includes a slot for 'extraActions' allowing additional custom controls per file.",
|
|
3898
|
+
"Provides a default 'Button' with 'CloudArrowUp' icon and 'Upload Files' text if no children are passed to 'Upload'.",
|
|
3899
|
+
"Includes 'Upload.Dragger' for drag-and-drop functionality, styled for the design system.",
|
|
3900
|
+
"Exports 'Upload.Item' (the UploadItem component) for potential direct use.",
|
|
3901
|
+
"Applies BioTuring Design System specific styling and CSS classes."
|
|
3902
|
+
],
|
|
3903
|
+
category: "Data Entry",
|
|
3904
|
+
originalDocUrl: "https://ant.design/components/upload",
|
|
3905
|
+
description: "Allows users to select and upload files."
|
|
3906
|
+
},
|
|
3907
|
+
VerticalCollapsiblePanel: {
|
|
3908
|
+
name: "Vertical Collapsible Panel",
|
|
3909
|
+
link: "/vertical-collapsible-panel",
|
|
3910
|
+
base: "base-ui",
|
|
3911
|
+
refinements: [
|
|
3912
|
+
"Built upon '@base-ui-components/react' Collapsible components ('Collapsible.Root', 'Collapsible.Panel').",
|
|
3913
|
+
"Manages open/closed state with a custom 'useControlledState' hook for controlled/uncontrolled behavior.",
|
|
3914
|
+
"Features custom expand/collapse trigger icons ('MinusCircle', 'PlusCircle' from '@bioturing/assets') via IconButton.",
|
|
3915
|
+
"Automatically truncates string titles using the 'Truncate' component.",
|
|
3916
|
+
"Provides 'afterTitle' and 'actions' slots in the header for additional UI elements, visible when open.",
|
|
3917
|
+
"Integrates the BioTuring 'Transition' component for smooth open/close animations of the panel body, managed with 'useAnimationsFinished' hook.",
|
|
3918
|
+
"Offers a 'contentPadding' prop (default '16px') for customizable body padding via CSS variable '--ds-content-padding'.",
|
|
3919
|
+
"Extensive custom CSS for layout, typography, and a unique feature: header text displays vertically ('writing-mode: vertical-rl') when collapsed.",
|
|
3920
|
+
"Supports 'keepMounted' prop and applies Ant Design CSS variables for theming."
|
|
3921
|
+
],
|
|
3922
|
+
category: "Layout",
|
|
3923
|
+
packages: [
|
|
3924
|
+
"@base-ui-components/react"
|
|
3925
|
+
],
|
|
3926
|
+
originalDocUrl: "https://base-ui.com/react/components/vertical-collapsible-panel",
|
|
3927
|
+
description: "A panel that can be collapsed or expanded vertically, often used in sidebars or for sectioning content."
|
|
3928
|
+
}
|
|
3929
|
+
};
|
|
3930
|
+
const getComponentsByCategory = ()=>{
|
|
3931
|
+
const categories = {
|
|
3932
|
+
Actions: [],
|
|
3933
|
+
General: [],
|
|
3934
|
+
Layout: [],
|
|
3935
|
+
Navigation: [],
|
|
3936
|
+
"Data Entry": [],
|
|
3937
|
+
"Data Display": [],
|
|
3938
|
+
Feedback: [],
|
|
3939
|
+
Overlay: [],
|
|
3940
|
+
Utility: []
|
|
3941
|
+
};
|
|
3942
|
+
Object.values(componentMetadata).forEach((component)=>{
|
|
3943
|
+
categories[component.category].push(component);
|
|
3944
|
+
});
|
|
3945
|
+
Object.keys(categories).forEach((category)=>{
|
|
3946
|
+
categories[category].sort((a, b)=>a.name.localeCompare(b.name));
|
|
3947
|
+
});
|
|
3948
|
+
return categories;
|
|
3949
|
+
};
|
|
3322
3950
|
var __webpack_exports__Affix = __WEBPACK_EXTERNAL_MODULE_antd__.Affix;
|
|
3323
3951
|
var __webpack_exports__Alert = __WEBPACK_EXTERNAL_MODULE_antd__.Alert;
|
|
3324
3952
|
var __webpack_exports__Anchor = __WEBPACK_EXTERNAL_MODULE_antd__.Anchor;
|
|
@@ -3373,4 +4001,4 @@ var __webpack_exports__useApp = __WEBPACK_EXTERNAL_MODULE_antd_es_app_useApp_90d
|
|
|
3373
4001
|
var __webpack_exports__useForm = __WEBPACK_EXTERNAL_MODULE_antd_es_form_Form_38f624ac__.useForm;
|
|
3374
4002
|
var __webpack_exports__useWatch = __WEBPACK_EXTERNAL_MODULE_antd_es_form_Form_38f624ac__.useWatch;
|
|
3375
4003
|
var __webpack_exports__version = __WEBPACK_EXTERNAL_MODULE_antd__.version;
|
|
3376
|
-
export { Badge, Breadcrumb, Button, Checkbox, CodeBlock, DSRoot, DefaultUpload, DropdownMenu, Empty, EmptyIcon, Field, Form, IconButton, Input, Modal_Modal as Modal, Popover, PopupPanel, Radio, ScrollArea, Segmented, Select, Slider, Spin, Split, Splitter, Switch, Table, component_Tag as Tag, ThemeProvider, Toast, Tooltip, Tour, Transition, Tree, Truncate, Upload, VerticalCollapsiblePanel, WithAntdTokens, antdColorTokens, categoricalChartColorKeys, categoricalChartColorTokens, categoricalChartsColors, chartColorTokens, clsx, cn, cx, darkTheme, getUniqueKeysFromOriginals, isTracebackError, lightTheme, parseAntdPlacement, processTreeData, rawChartColorTokens, reactNodeToString, function_toast as toast, toastManager, useAnimationsFinished, useAntdCssVarClassname, useBreakpoint, useCharts, useCls, useControlledState, useEnhancedEffect, useEventCallback, useGetPrefixCls, useLatestRef, useMessage, antd_useModal as useModal, useToken, useUniqueKeysTree, useUploadItemRender, __webpack_exports__Affix as Affix, __webpack_exports__Alert as Alert, __webpack_exports__Anchor as Anchor, __webpack_exports__App as App, __webpack_exports__AutoComplete as AutoComplete, __webpack_exports__Avatar as Avatar, __webpack_exports__BackTop as BackTop, __webpack_exports__Calendar as Calendar, __webpack_exports__Card as Card, __webpack_exports__Carousel as Carousel, __webpack_exports__Cascader as Cascader, __webpack_exports__Col as Col, __webpack_exports__Collapse as Collapse, __webpack_exports__ColorPicker as ColorPicker, __webpack_exports__ConfigProvider as ConfigProvider, __webpack_exports__DatePicker as DatePicker, __webpack_exports__Descriptions as Descriptions, __webpack_exports__Divider as Divider, __webpack_exports__Drawer as Drawer, __webpack_exports__Dropdown as Dropdown, __webpack_exports__Flex as Flex, __webpack_exports__FloatButton as FloatButton, __webpack_exports__Grid as Grid, __webpack_exports__InputNumber as InputNumber, __webpack_exports__Layout as Layout, __webpack_exports__List as List, __webpack_exports__Mentions as Mentions, __webpack_exports__Menu as Menu, __webpack_exports__Pagination as Pagination, __webpack_exports__Popconfirm as Popconfirm, __webpack_exports__Progress as Progress, __webpack_exports__QRCode as QRCode, __webpack_exports__Rate as Rate, __webpack_exports__Result as Result, __webpack_exports__Row as Row, __webpack_exports__Skeleton as Skeleton, __webpack_exports__Space as Space, __webpack_exports__Statistic as Statistic, __webpack_exports__Steps as Steps, __webpack_exports__Tabs as Tabs, __webpack_exports__TimePicker as TimePicker, __webpack_exports__Timeline as Timeline, __webpack_exports__Transfer as Transfer, __webpack_exports__TreeSelect as TreeSelect, __webpack_exports__Typography as Typography, __webpack_exports__Watermark as Watermark, __webpack_exports__message as message, __webpack_exports__notification as notification, __webpack_exports__theme as theme, __webpack_exports__unstableSetRender as unstableSetRender, __webpack_exports__useApp as useApp, __webpack_exports__useForm as useForm, __webpack_exports__useWatch as useWatch, __webpack_exports__version as version };
|
|
4004
|
+
export { Badge, Breadcrumb, Button, Checkbox, CodeBlock, DSRoot, DefaultUpload, DropdownMenu, Empty, EmptyIcon, Field, Form, IconButton, Input, Modal_Modal as Modal, Popover, PopupPanel, Radio, ScrollArea, Segmented, Select, Slider, Spin, Split, Splitter, Stack_Stack as Stack, StackChild, Switch, Table, component_Tag as Tag, ThemeProvider, Toast, Tooltip, Tour, Transition, Tree, Truncate, Upload, VerticalCollapsiblePanel, WithAntdTokens, antdColorTokens, categoricalChartColorKeys, categoricalChartColorTokens, categoricalChartsColors, chartColorTokens, clsx, cn, componentMetadata, cx, darkTheme, getComponentsByCategory, getUniqueKeysFromOriginals, isTracebackError, lightTheme, parseAntdPlacement, processTreeData, rawChartColorTokens, reactNodeToString, function_toast as toast, toastManager, useAnimationsFinished, useAntdCssVarClassname, useBreakpoint, useCharts, useCls, useControlledState, useEnhancedEffect, useEventCallback, useGetPrefixCls, useLatestRef, useMessage, antd_useModal as useModal, useToken, useUniqueKeysTree, useUploadItemRender, __webpack_exports__Affix as Affix, __webpack_exports__Alert as Alert, __webpack_exports__Anchor as Anchor, __webpack_exports__App as App, __webpack_exports__AutoComplete as AutoComplete, __webpack_exports__Avatar as Avatar, __webpack_exports__BackTop as BackTop, __webpack_exports__Calendar as Calendar, __webpack_exports__Card as Card, __webpack_exports__Carousel as Carousel, __webpack_exports__Cascader as Cascader, __webpack_exports__Col as Col, __webpack_exports__Collapse as Collapse, __webpack_exports__ColorPicker as ColorPicker, __webpack_exports__ConfigProvider as ConfigProvider, __webpack_exports__DatePicker as DatePicker, __webpack_exports__Descriptions as Descriptions, __webpack_exports__Divider as Divider, __webpack_exports__Drawer as Drawer, __webpack_exports__Dropdown as Dropdown, __webpack_exports__Flex as Flex, __webpack_exports__FloatButton as FloatButton, __webpack_exports__Grid as Grid, __webpack_exports__InputNumber as InputNumber, __webpack_exports__Layout as Layout, __webpack_exports__List as List, __webpack_exports__Mentions as Mentions, __webpack_exports__Menu as Menu, __webpack_exports__Pagination as Pagination, __webpack_exports__Popconfirm as Popconfirm, __webpack_exports__Progress as Progress, __webpack_exports__QRCode as QRCode, __webpack_exports__Rate as Rate, __webpack_exports__Result as Result, __webpack_exports__Row as Row, __webpack_exports__Skeleton as Skeleton, __webpack_exports__Space as Space, __webpack_exports__Statistic as Statistic, __webpack_exports__Steps as Steps, __webpack_exports__Tabs as Tabs, __webpack_exports__TimePicker as TimePicker, __webpack_exports__Timeline as Timeline, __webpack_exports__Transfer as Transfer, __webpack_exports__TreeSelect as TreeSelect, __webpack_exports__Typography as Typography, __webpack_exports__Watermark as Watermark, __webpack_exports__message as message, __webpack_exports__notification as notification, __webpack_exports__theme as theme, __webpack_exports__unstableSetRender as unstableSetRender, __webpack_exports__useApp as useApp, __webpack_exports__useForm as useForm, __webpack_exports__useWatch as useWatch, __webpack_exports__version as version };
|