@cgi-learning-hub/ui 1.13.0-dev.1775747511 → 1.13.0-dev.1777304242
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/index.cjs.js +36 -54
- package/dist/index.d.ts +0 -32
- package/dist/index.es.js +36 -54
- package/package.json +1 -1
package/dist/index.cjs.js
CHANGED
|
@@ -58650,9 +58650,7 @@ const Dropzone = ({
|
|
|
58650
58650
|
};
|
|
58651
58651
|
const EllipsisWithTooltip = ({
|
|
58652
58652
|
children,
|
|
58653
|
-
slotProps = {}
|
|
58654
|
-
tooltipProps,
|
|
58655
|
-
typographyProps
|
|
58653
|
+
slotProps = {}
|
|
58656
58654
|
}) => {
|
|
58657
58655
|
const [isTextEllipsized, setIsTextEllipsized] = React.useState(false);
|
|
58658
58656
|
const textRef = React.useRef(null);
|
|
@@ -58681,7 +58679,7 @@ const EllipsisWithTooltip = ({
|
|
|
58681
58679
|
{
|
|
58682
58680
|
disableHoverListener: !isTextEllipsized,
|
|
58683
58681
|
title: children,
|
|
58684
|
-
...slotProps.tooltip
|
|
58682
|
+
...slotProps.tooltip,
|
|
58685
58683
|
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
58686
58684
|
Typography,
|
|
58687
58685
|
{
|
|
@@ -58690,7 +58688,7 @@ const EllipsisWithTooltip = ({
|
|
|
58690
58688
|
overflow: "hidden",
|
|
58691
58689
|
textOverflow: "ellipsis",
|
|
58692
58690
|
maxWidth: "100%",
|
|
58693
|
-
...slotProps.text
|
|
58691
|
+
...slotProps.text,
|
|
58694
58692
|
children
|
|
58695
58693
|
}
|
|
58696
58694
|
)
|
|
@@ -58705,9 +58703,6 @@ const EmptyState = ({
|
|
|
58705
58703
|
footer,
|
|
58706
58704
|
imageHeight = 200,
|
|
58707
58705
|
slotProps = {},
|
|
58708
|
-
imageProps,
|
|
58709
|
-
descriptionProps,
|
|
58710
|
-
titleProps,
|
|
58711
58706
|
...otherProps
|
|
58712
58707
|
}) => {
|
|
58713
58708
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
@@ -58719,32 +58714,9 @@ const EmptyState = ({
|
|
|
58719
58714
|
...otherProps,
|
|
58720
58715
|
...slotProps.root,
|
|
58721
58716
|
children: [
|
|
58722
|
-
/* @__PURE__ */ jsxRuntime.jsx(Box, { height: imageHeight, width: "auto", children: image ?? /* @__PURE__ */ jsxRuntime.jsx(
|
|
58723
|
-
|
|
58724
|
-
|
|
58725
|
-
src: imageSrc,
|
|
58726
|
-
height: "100%",
|
|
58727
|
-
...slotProps.image ?? imageProps
|
|
58728
|
-
}
|
|
58729
|
-
) }),
|
|
58730
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
58731
|
-
Typography,
|
|
58732
|
-
{
|
|
58733
|
-
variant: "h2",
|
|
58734
|
-
mt: 3,
|
|
58735
|
-
...slotProps.title ?? titleProps,
|
|
58736
|
-
children: title
|
|
58737
|
-
}
|
|
58738
|
-
),
|
|
58739
|
-
description ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
58740
|
-
Typography,
|
|
58741
|
-
{
|
|
58742
|
-
color: "textSecondary",
|
|
58743
|
-
mt: 2,
|
|
58744
|
-
...slotProps.description ?? descriptionProps,
|
|
58745
|
-
children: description
|
|
58746
|
-
}
|
|
58747
|
-
) : null,
|
|
58717
|
+
/* @__PURE__ */ jsxRuntime.jsx(Box, { height: imageHeight, width: "auto", children: image ?? /* @__PURE__ */ jsxRuntime.jsx("img", { src: imageSrc, height: "100%", ...slotProps.image }) }),
|
|
58718
|
+
/* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "h2", mt: 3, ...slotProps.title, children: title }),
|
|
58719
|
+
description ? /* @__PURE__ */ jsxRuntime.jsx(Typography, { color: "textSecondary", mt: 2, ...slotProps.description, children: description }) : null,
|
|
58748
58720
|
footer ? /* @__PURE__ */ jsxRuntime.jsx(Box, { mt: 3, children: footer }) : null
|
|
58749
58721
|
]
|
|
58750
58722
|
}
|
|
@@ -58921,7 +58893,7 @@ const FileListItem = ({
|
|
|
58921
58893
|
alignItems: "flex-start",
|
|
58922
58894
|
minWidth: "0",
|
|
58923
58895
|
children: [
|
|
58924
|
-
/* @__PURE__ */ jsxRuntime.jsx(EllipsisWithTooltip, {
|
|
58896
|
+
/* @__PURE__ */ jsxRuntime.jsx(EllipsisWithTooltip, { slotProps: { text: { variant: "body1" } }, children: file.name }),
|
|
58925
58897
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
58926
58898
|
Stack,
|
|
58927
58899
|
{
|
|
@@ -59204,16 +59176,26 @@ const FolderCard = ({
|
|
|
59204
59176
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
59205
59177
|
EllipsisWithTooltip,
|
|
59206
59178
|
{
|
|
59207
|
-
|
|
59208
|
-
|
|
59179
|
+
slotProps: {
|
|
59180
|
+
text: titleTypographyProps,
|
|
59181
|
+
tooltip: {
|
|
59182
|
+
placement: "bottom",
|
|
59183
|
+
arrow: true
|
|
59184
|
+
}
|
|
59185
|
+
},
|
|
59209
59186
|
children: title
|
|
59210
59187
|
}
|
|
59211
59188
|
),
|
|
59212
59189
|
subtitle && /* @__PURE__ */ jsxRuntime.jsx(
|
|
59213
59190
|
EllipsisWithTooltip,
|
|
59214
59191
|
{
|
|
59215
|
-
|
|
59216
|
-
|
|
59192
|
+
slotProps: {
|
|
59193
|
+
text: subtitleTypographyProps,
|
|
59194
|
+
tooltip: {
|
|
59195
|
+
placement: "bottom",
|
|
59196
|
+
arrow: true
|
|
59197
|
+
}
|
|
59198
|
+
},
|
|
59217
59199
|
children: subtitle
|
|
59218
59200
|
}
|
|
59219
59201
|
)
|
|
@@ -59229,8 +59211,6 @@ const Heading = ({
|
|
|
59229
59211
|
iconColor,
|
|
59230
59212
|
iconSize = 28,
|
|
59231
59213
|
slotProps = {},
|
|
59232
|
-
iconProps,
|
|
59233
|
-
titleProps,
|
|
59234
59214
|
...otherProps
|
|
59235
59215
|
}) => {
|
|
59236
59216
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
@@ -59252,18 +59232,10 @@ const Heading = ({
|
|
|
59252
59232
|
color: iconColor?.[500],
|
|
59253
59233
|
backgroundColor: iconColor?.[50]
|
|
59254
59234
|
},
|
|
59255
|
-
...slotProps.icon
|
|
59235
|
+
...slotProps.icon
|
|
59256
59236
|
}
|
|
59257
59237
|
) : null,
|
|
59258
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
59259
|
-
Typography,
|
|
59260
|
-
{
|
|
59261
|
-
component: "h3",
|
|
59262
|
-
variant: "h2",
|
|
59263
|
-
...slotProps.text ?? titleProps,
|
|
59264
|
-
children: title
|
|
59265
|
-
}
|
|
59266
|
-
)
|
|
59238
|
+
/* @__PURE__ */ jsxRuntime.jsx(Typography, { component: "h3", variant: "h2", ...slotProps.text, children: title })
|
|
59267
59239
|
]
|
|
59268
59240
|
}
|
|
59269
59241
|
);
|
|
@@ -60511,8 +60483,16 @@ const ResourceCard = ({
|
|
|
60511
60483
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
60512
60484
|
EllipsisWithTooltip,
|
|
60513
60485
|
{
|
|
60514
|
-
|
|
60515
|
-
|
|
60486
|
+
slotProps: {
|
|
60487
|
+
text: {
|
|
60488
|
+
component: "p",
|
|
60489
|
+
variant: "h4"
|
|
60490
|
+
},
|
|
60491
|
+
tooltip: {
|
|
60492
|
+
placement: "bottom",
|
|
60493
|
+
arrow: true
|
|
60494
|
+
}
|
|
60495
|
+
},
|
|
60516
60496
|
children: title
|
|
60517
60497
|
}
|
|
60518
60498
|
),
|
|
@@ -69464,7 +69444,9 @@ function CustomTreeItem(props) {
|
|
|
69464
69444
|
EllipsisWithTooltip,
|
|
69465
69445
|
{
|
|
69466
69446
|
...getLabelProps(),
|
|
69467
|
-
|
|
69447
|
+
slotProps: {
|
|
69448
|
+
text: labelStyle2
|
|
69449
|
+
}
|
|
69468
69450
|
}
|
|
69469
69451
|
),
|
|
69470
69452
|
/* @__PURE__ */ jsxRuntime.jsx(Box, { sx: arrowContainerStyle, children: status.expandable && (status.expanded ? /* @__PURE__ */ jsxRuntime.jsx(KeyboardArrowDownRoundedIcon, { fontSize: "small" }) : /* @__PURE__ */ jsxRuntime.jsx(KeyboardArrowRightRoundedIcon, { fontSize: "small" })) })
|
package/dist/index.d.ts
CHANGED
|
@@ -298,31 +298,15 @@ export declare type EllipsisWithTooltipProps = {
|
|
|
298
298
|
text?: Omit<TypographyProps, "noWrap" | "overflow" | "textOverflow">;
|
|
299
299
|
tooltip?: Omit<TooltipProps, "children" | "title">;
|
|
300
300
|
};
|
|
301
|
-
/**
|
|
302
|
-
* @deprecated Use `slotProps.tooltip` instead.
|
|
303
|
-
*/
|
|
304
|
-
tooltipProps?: Omit<TooltipProps, "children" | "title">;
|
|
305
|
-
/**
|
|
306
|
-
* @deprecated Use `slotProps.text` instead.
|
|
307
|
-
*/
|
|
308
|
-
typographyProps?: Omit<TypographyProps, "noWrap" | "overflow" | "textOverflow">;
|
|
309
301
|
};
|
|
310
302
|
|
|
311
303
|
export declare const EmptyState: FC<EmptyStateProps>;
|
|
312
304
|
|
|
313
305
|
export declare type EmptyStateProps = ({
|
|
314
306
|
image: ReactNode;
|
|
315
|
-
/**
|
|
316
|
-
* @deprecated Use `slotProps.image` instead.
|
|
317
|
-
*/
|
|
318
|
-
imageProps?: never;
|
|
319
307
|
imageSrc?: never;
|
|
320
308
|
} | {
|
|
321
309
|
image?: never;
|
|
322
|
-
/**
|
|
323
|
-
* @deprecated Use `slotProps.image` instead.
|
|
324
|
-
*/
|
|
325
|
-
imageProps?: ImgHTMLAttributes<HTMLImageElement>;
|
|
326
310
|
imageSrc: string;
|
|
327
311
|
}) & {
|
|
328
312
|
imageHeight?: string | number;
|
|
@@ -335,14 +319,6 @@ export declare type EmptyStateProps = ({
|
|
|
335
319
|
title?: TypographyProps;
|
|
336
320
|
description?: TypographyProps;
|
|
337
321
|
};
|
|
338
|
-
/**
|
|
339
|
-
* @deprecated Use `slotProps.description` instead.
|
|
340
|
-
*/
|
|
341
|
-
descriptionProps?: TypographyProps;
|
|
342
|
-
/**
|
|
343
|
-
* @deprecated Use `slotProps.title` instead.
|
|
344
|
-
*/
|
|
345
|
-
titleProps?: TypographyProps;
|
|
346
322
|
} & StackProps;
|
|
347
323
|
|
|
348
324
|
export declare interface ExtendedTreeItemProps extends TreeItemProps {
|
|
@@ -415,14 +391,6 @@ export declare type HeadingProps = {
|
|
|
415
391
|
text?: TypographyProps;
|
|
416
392
|
};
|
|
417
393
|
iconSize?: number;
|
|
418
|
-
/**
|
|
419
|
-
* @deprecated Use `slotProps.icon` instead.
|
|
420
|
-
*/
|
|
421
|
-
iconProps?: SvgIconProps;
|
|
422
|
-
/**
|
|
423
|
-
* @deprecated Use `slotProps.text` instead.
|
|
424
|
-
*/
|
|
425
|
-
titleProps?: TypographyProps;
|
|
426
394
|
} & StackProps;
|
|
427
395
|
|
|
428
396
|
export declare type HexaColor = `#${string}`;
|
package/dist/index.es.js
CHANGED
|
@@ -58633,9 +58633,7 @@ const Dropzone = ({
|
|
|
58633
58633
|
};
|
|
58634
58634
|
const EllipsisWithTooltip = ({
|
|
58635
58635
|
children,
|
|
58636
|
-
slotProps = {}
|
|
58637
|
-
tooltipProps,
|
|
58638
|
-
typographyProps
|
|
58636
|
+
slotProps = {}
|
|
58639
58637
|
}) => {
|
|
58640
58638
|
const [isTextEllipsized, setIsTextEllipsized] = useState(false);
|
|
58641
58639
|
const textRef = useRef(null);
|
|
@@ -58664,7 +58662,7 @@ const EllipsisWithTooltip = ({
|
|
|
58664
58662
|
{
|
|
58665
58663
|
disableHoverListener: !isTextEllipsized,
|
|
58666
58664
|
title: children,
|
|
58667
|
-
...slotProps.tooltip
|
|
58665
|
+
...slotProps.tooltip,
|
|
58668
58666
|
children: /* @__PURE__ */ jsx(
|
|
58669
58667
|
Typography,
|
|
58670
58668
|
{
|
|
@@ -58673,7 +58671,7 @@ const EllipsisWithTooltip = ({
|
|
|
58673
58671
|
overflow: "hidden",
|
|
58674
58672
|
textOverflow: "ellipsis",
|
|
58675
58673
|
maxWidth: "100%",
|
|
58676
|
-
...slotProps.text
|
|
58674
|
+
...slotProps.text,
|
|
58677
58675
|
children
|
|
58678
58676
|
}
|
|
58679
58677
|
)
|
|
@@ -58688,9 +58686,6 @@ const EmptyState = ({
|
|
|
58688
58686
|
footer,
|
|
58689
58687
|
imageHeight = 200,
|
|
58690
58688
|
slotProps = {},
|
|
58691
|
-
imageProps,
|
|
58692
|
-
descriptionProps,
|
|
58693
|
-
titleProps,
|
|
58694
58689
|
...otherProps
|
|
58695
58690
|
}) => {
|
|
58696
58691
|
return /* @__PURE__ */ jsxs(
|
|
@@ -58702,32 +58697,9 @@ const EmptyState = ({
|
|
|
58702
58697
|
...otherProps,
|
|
58703
58698
|
...slotProps.root,
|
|
58704
58699
|
children: [
|
|
58705
|
-
/* @__PURE__ */ jsx(Box, { height: imageHeight, width: "auto", children: image ?? /* @__PURE__ */ jsx(
|
|
58706
|
-
|
|
58707
|
-
|
|
58708
|
-
src: imageSrc,
|
|
58709
|
-
height: "100%",
|
|
58710
|
-
...slotProps.image ?? imageProps
|
|
58711
|
-
}
|
|
58712
|
-
) }),
|
|
58713
|
-
/* @__PURE__ */ jsx(
|
|
58714
|
-
Typography,
|
|
58715
|
-
{
|
|
58716
|
-
variant: "h2",
|
|
58717
|
-
mt: 3,
|
|
58718
|
-
...slotProps.title ?? titleProps,
|
|
58719
|
-
children: title
|
|
58720
|
-
}
|
|
58721
|
-
),
|
|
58722
|
-
description ? /* @__PURE__ */ jsx(
|
|
58723
|
-
Typography,
|
|
58724
|
-
{
|
|
58725
|
-
color: "textSecondary",
|
|
58726
|
-
mt: 2,
|
|
58727
|
-
...slotProps.description ?? descriptionProps,
|
|
58728
|
-
children: description
|
|
58729
|
-
}
|
|
58730
|
-
) : null,
|
|
58700
|
+
/* @__PURE__ */ jsx(Box, { height: imageHeight, width: "auto", children: image ?? /* @__PURE__ */ jsx("img", { src: imageSrc, height: "100%", ...slotProps.image }) }),
|
|
58701
|
+
/* @__PURE__ */ jsx(Typography, { variant: "h2", mt: 3, ...slotProps.title, children: title }),
|
|
58702
|
+
description ? /* @__PURE__ */ jsx(Typography, { color: "textSecondary", mt: 2, ...slotProps.description, children: description }) : null,
|
|
58731
58703
|
footer ? /* @__PURE__ */ jsx(Box, { mt: 3, children: footer }) : null
|
|
58732
58704
|
]
|
|
58733
58705
|
}
|
|
@@ -58904,7 +58876,7 @@ const FileListItem = ({
|
|
|
58904
58876
|
alignItems: "flex-start",
|
|
58905
58877
|
minWidth: "0",
|
|
58906
58878
|
children: [
|
|
58907
|
-
/* @__PURE__ */ jsx(EllipsisWithTooltip, {
|
|
58879
|
+
/* @__PURE__ */ jsx(EllipsisWithTooltip, { slotProps: { text: { variant: "body1" } }, children: file.name }),
|
|
58908
58880
|
/* @__PURE__ */ jsxs(
|
|
58909
58881
|
Stack,
|
|
58910
58882
|
{
|
|
@@ -59187,16 +59159,26 @@ const FolderCard = ({
|
|
|
59187
59159
|
/* @__PURE__ */ jsx(
|
|
59188
59160
|
EllipsisWithTooltip,
|
|
59189
59161
|
{
|
|
59190
|
-
|
|
59191
|
-
|
|
59162
|
+
slotProps: {
|
|
59163
|
+
text: titleTypographyProps,
|
|
59164
|
+
tooltip: {
|
|
59165
|
+
placement: "bottom",
|
|
59166
|
+
arrow: true
|
|
59167
|
+
}
|
|
59168
|
+
},
|
|
59192
59169
|
children: title
|
|
59193
59170
|
}
|
|
59194
59171
|
),
|
|
59195
59172
|
subtitle && /* @__PURE__ */ jsx(
|
|
59196
59173
|
EllipsisWithTooltip,
|
|
59197
59174
|
{
|
|
59198
|
-
|
|
59199
|
-
|
|
59175
|
+
slotProps: {
|
|
59176
|
+
text: subtitleTypographyProps,
|
|
59177
|
+
tooltip: {
|
|
59178
|
+
placement: "bottom",
|
|
59179
|
+
arrow: true
|
|
59180
|
+
}
|
|
59181
|
+
},
|
|
59200
59182
|
children: subtitle
|
|
59201
59183
|
}
|
|
59202
59184
|
)
|
|
@@ -59212,8 +59194,6 @@ const Heading = ({
|
|
|
59212
59194
|
iconColor,
|
|
59213
59195
|
iconSize = 28,
|
|
59214
59196
|
slotProps = {},
|
|
59215
|
-
iconProps,
|
|
59216
|
-
titleProps,
|
|
59217
59197
|
...otherProps
|
|
59218
59198
|
}) => {
|
|
59219
59199
|
return /* @__PURE__ */ jsxs(
|
|
@@ -59235,18 +59215,10 @@ const Heading = ({
|
|
|
59235
59215
|
color: iconColor?.[500],
|
|
59236
59216
|
backgroundColor: iconColor?.[50]
|
|
59237
59217
|
},
|
|
59238
|
-
...slotProps.icon
|
|
59218
|
+
...slotProps.icon
|
|
59239
59219
|
}
|
|
59240
59220
|
) : null,
|
|
59241
|
-
/* @__PURE__ */ jsx(
|
|
59242
|
-
Typography,
|
|
59243
|
-
{
|
|
59244
|
-
component: "h3",
|
|
59245
|
-
variant: "h2",
|
|
59246
|
-
...slotProps.text ?? titleProps,
|
|
59247
|
-
children: title
|
|
59248
|
-
}
|
|
59249
|
-
)
|
|
59221
|
+
/* @__PURE__ */ jsx(Typography, { component: "h3", variant: "h2", ...slotProps.text, children: title })
|
|
59250
59222
|
]
|
|
59251
59223
|
}
|
|
59252
59224
|
);
|
|
@@ -60494,8 +60466,16 @@ const ResourceCard = ({
|
|
|
60494
60466
|
/* @__PURE__ */ jsx(
|
|
60495
60467
|
EllipsisWithTooltip,
|
|
60496
60468
|
{
|
|
60497
|
-
|
|
60498
|
-
|
|
60469
|
+
slotProps: {
|
|
60470
|
+
text: {
|
|
60471
|
+
component: "p",
|
|
60472
|
+
variant: "h4"
|
|
60473
|
+
},
|
|
60474
|
+
tooltip: {
|
|
60475
|
+
placement: "bottom",
|
|
60476
|
+
arrow: true
|
|
60477
|
+
}
|
|
60478
|
+
},
|
|
60499
60479
|
children: title
|
|
60500
60480
|
}
|
|
60501
60481
|
),
|
|
@@ -69447,7 +69427,9 @@ function CustomTreeItem(props) {
|
|
|
69447
69427
|
EllipsisWithTooltip,
|
|
69448
69428
|
{
|
|
69449
69429
|
...getLabelProps(),
|
|
69450
|
-
|
|
69430
|
+
slotProps: {
|
|
69431
|
+
text: labelStyle2
|
|
69432
|
+
}
|
|
69451
69433
|
}
|
|
69452
69434
|
),
|
|
69453
69435
|
/* @__PURE__ */ jsx(Box, { sx: arrowContainerStyle, children: status.expandable && (status.expanded ? /* @__PURE__ */ jsx(KeyboardArrowDownRoundedIcon, { fontSize: "small" }) : /* @__PURE__ */ jsx(KeyboardArrowRightRoundedIcon, { fontSize: "small" })) })
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cgi-learning-hub/ui",
|
|
3
|
-
"version": "1.13.0-dev.
|
|
3
|
+
"version": "1.13.0-dev.1777304242",
|
|
4
4
|
"description": "React component library for Hub's design system, built on Material UI with custom and extended components.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"cgi-learning-hub",
|