@digital-ai/dot-components 3.15.0 → 3.15.3
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/index.esm.js +37 -18
- package/package.json +1 -1
- package/src/lib/components/tooltip/Tooltip.d.ts +3 -1
package/index.esm.js
CHANGED
|
@@ -50,6 +50,8 @@ const DotTooltip = ({
|
|
|
50
50
|
className,
|
|
51
51
|
'data-testid': dataTestId,
|
|
52
52
|
disablePortal = false,
|
|
53
|
+
followCursor = false,
|
|
54
|
+
enterDelay = 0,
|
|
53
55
|
hoverVisibility = 'always',
|
|
54
56
|
leaveDelay,
|
|
55
57
|
onClose,
|
|
@@ -87,6 +89,7 @@ const DotTooltip = ({
|
|
|
87
89
|
"data-testid": dataTestId,
|
|
88
90
|
disableHoverListener: hoverVisibility === 'never' || hoverVisibility === 'overflow' && !hasTooltipOnHover,
|
|
89
91
|
leaveDelay: leaveDelay,
|
|
92
|
+
enterDelay: enterDelay,
|
|
90
93
|
onClose: onClose,
|
|
91
94
|
open: open,
|
|
92
95
|
placement: placement,
|
|
@@ -96,6 +99,7 @@ const DotTooltip = ({
|
|
|
96
99
|
},
|
|
97
100
|
role: ariaRole,
|
|
98
101
|
title: title,
|
|
102
|
+
followCursor: followCursor,
|
|
99
103
|
children: jsx("span", {
|
|
100
104
|
ref: childrenWrapperRef,
|
|
101
105
|
tabIndex: -1,
|
|
@@ -3121,7 +3125,7 @@ const StyledPopper = styled(Popper)`
|
|
|
3121
3125
|
z-index: ${levelSecond};
|
|
3122
3126
|
}
|
|
3123
3127
|
&.${rootClassName$18}, &.${rootClassName$19} {
|
|
3124
|
-
.MuiPaper-root {
|
|
3128
|
+
.MuiPaper-root:not(:empty) {
|
|
3125
3129
|
border: 1px solid ${theme.palette.layer.n100};
|
|
3126
3130
|
}
|
|
3127
3131
|
|
|
@@ -6745,6 +6749,7 @@ const DotAutoComplete = ({
|
|
|
6745
6749
|
};
|
|
6746
6750
|
return jsxs(Fragment, {
|
|
6747
6751
|
children: [loading && jsx(DotProgress, {
|
|
6752
|
+
ariaLabel: "loading autocomplete data",
|
|
6748
6753
|
color: "inherit",
|
|
6749
6754
|
size: 20
|
|
6750
6755
|
}), getInputAdornment(), nativeEndAdornment]
|
|
@@ -10696,6 +10701,12 @@ function DotDashboardDialog({
|
|
|
10696
10701
|
validateName(newName);
|
|
10697
10702
|
}
|
|
10698
10703
|
}, [validateName]);
|
|
10704
|
+
const validateRequiredFields = () => {
|
|
10705
|
+
if (!formValues.name) {
|
|
10706
|
+
return false;
|
|
10707
|
+
}
|
|
10708
|
+
return true;
|
|
10709
|
+
};
|
|
10699
10710
|
return jsxs(StyledDashboardDialog, {
|
|
10700
10711
|
cancelButtonProps: {
|
|
10701
10712
|
'data-testid': 'cancel-create-dashboard-button'
|
|
@@ -10777,13 +10788,13 @@ function DotDashboardDialog({
|
|
|
10777
10788
|
children: "Cancel"
|
|
10778
10789
|
}), jsx(DotButton, {
|
|
10779
10790
|
"data-testid": "save-edit-exit-dashboard-button",
|
|
10780
|
-
disabled: isLoadingSubmit || !isDirty,
|
|
10791
|
+
disabled: isLoadingSubmit || !isDirty || !validateRequiredFields(),
|
|
10781
10792
|
onClick: handleSubmitEditExit,
|
|
10782
10793
|
type: "outlined",
|
|
10783
10794
|
children: "Save and exit"
|
|
10784
10795
|
}), jsx(DotButton, {
|
|
10785
10796
|
"data-testid": "save-edit-continue-dashboard-button",
|
|
10786
|
-
disabled: isLoadingSubmit,
|
|
10797
|
+
disabled: isLoadingSubmit || !validateRequiredFields(),
|
|
10787
10798
|
onClick: handleSubmitEditContinue,
|
|
10788
10799
|
type: "primary",
|
|
10789
10800
|
children: isDirty ? 'Save and continue' : 'Continue'
|
|
@@ -15959,18 +15970,24 @@ const StyledTabs = styled(Tabs)`
|
|
|
15959
15970
|
width: 100%;
|
|
15960
15971
|
}
|
|
15961
15972
|
|
|
15962
|
-
.dot-tab-label-container {
|
|
15963
|
-
display: flex;
|
|
15964
|
-
.dot-tab-label {
|
|
15965
|
-
padding-top: ${theme.spacing(0.5)};
|
|
15966
|
-
}
|
|
15967
|
-
}
|
|
15968
|
-
|
|
15969
15973
|
.MuiTab-root {
|
|
15970
|
-
box-shadow: inset
|
|
15971
|
-
color: ${theme.palette.figma.primary.elevated};
|
|
15974
|
+
box-shadow: inset 0 -1px 0 ${theme.palette.figma.border.default};
|
|
15972
15975
|
max-width: 360px;
|
|
15973
15976
|
min-width: 0;
|
|
15977
|
+
color: ${theme.palette.figma.typography.black};
|
|
15978
|
+
|
|
15979
|
+
.dot-icon {
|
|
15980
|
+
color: ${theme.palette.figma.typography.black};
|
|
15981
|
+
display: inline;
|
|
15982
|
+
padding-right: ${theme.spacing(0.5)};
|
|
15983
|
+
}
|
|
15984
|
+
|
|
15985
|
+
&.Mui-selected {
|
|
15986
|
+
&,
|
|
15987
|
+
.dot-icon {
|
|
15988
|
+
color: ${theme.palette.figma.primary.elevated};
|
|
15989
|
+
}
|
|
15990
|
+
}
|
|
15974
15991
|
|
|
15975
15992
|
&.Mui-disabled {
|
|
15976
15993
|
color: ${theme.palette.figma.typography.disabled};
|
|
@@ -15979,18 +15996,20 @@ const StyledTabs = styled(Tabs)`
|
|
|
15979
15996
|
color: ${theme.palette.figma.typography.disabled};
|
|
15980
15997
|
}
|
|
15981
15998
|
}
|
|
15999
|
+
|
|
16000
|
+
.dot-tab-label-container {
|
|
16001
|
+
display: flex;
|
|
16002
|
+
|
|
16003
|
+
.dot-tab-label {
|
|
16004
|
+
padding-top: ${theme.spacing(0.5)};
|
|
16005
|
+
}
|
|
16006
|
+
}
|
|
15982
16007
|
}
|
|
15983
16008
|
|
|
15984
16009
|
.MuiTabs-indicator {
|
|
15985
16010
|
background: ${theme.palette.figma.border.inputActive};
|
|
15986
16011
|
height: 3px;
|
|
15987
16012
|
}
|
|
15988
|
-
|
|
15989
|
-
.dot-icon {
|
|
15990
|
-
color: ${theme.palette.figma.primary.elevated};
|
|
15991
|
-
display: inline;
|
|
15992
|
-
padding-right: ${theme.spacing(0.5)};
|
|
15993
|
-
}
|
|
15994
16013
|
}
|
|
15995
16014
|
`}
|
|
15996
16015
|
`;
|
package/package.json
CHANGED
|
@@ -8,6 +8,8 @@ export interface TooltipProps extends CommonProps {
|
|
|
8
8
|
children: ReactElement;
|
|
9
9
|
/** Disable the portal behavior. If true, children stay within parent DOM hierarchy. */
|
|
10
10
|
disablePortal?: boolean;
|
|
11
|
+
enterDelay?: number;
|
|
12
|
+
followCursor?: boolean;
|
|
11
13
|
hoverVisibility?: TooltipHoverVisibility;
|
|
12
14
|
leaveDelay?: number;
|
|
13
15
|
onClose?: (event: ChangeEvent) => void;
|
|
@@ -16,4 +18,4 @@ export interface TooltipProps extends CommonProps {
|
|
|
16
18
|
popperClassName?: string;
|
|
17
19
|
title?: ReactNode | string | number;
|
|
18
20
|
}
|
|
19
|
-
export declare const DotTooltip: ({ ariaLabel, ariaRole, arrow, children, className, "data-testid": dataTestId, disablePortal, hoverVisibility, leaveDelay, onClose, open, placement, popperClassName, title, }: TooltipProps) => import("react/jsx-runtime").JSX.Element;
|
|
21
|
+
export declare const DotTooltip: ({ ariaLabel, ariaRole, arrow, children, className, "data-testid": dataTestId, disablePortal, followCursor, enterDelay, hoverVisibility, leaveDelay, onClose, open, placement, popperClassName, title, }: TooltipProps) => import("react/jsx-runtime").JSX.Element;
|