Display a tooltip for actions without short labels (#11243)

- Merge `RecordIndexActionMenuButtons` and `RecordShowActionMenuButtons`
into a single component `PageHeaderActionMenuButtons`
- Display tooltip after 1s for actions without short labels


https://github.com/user-attachments/assets/7649bed8-a1a9-4c1d-8fbe-f1bf3a51db56
This commit is contained in:
Raphaël Bosi
2025-03-28 11:01:55 +01:00
committed by GitHub
parent 8d35454dd8
commit b1c57edc90
10 changed files with 131 additions and 106 deletions

View File

@ -14,6 +14,7 @@ export enum TooltipDelay {
noDelay = '0ms',
shortDelay = '300ms',
mediumDelay = '500ms',
longDelay = '1000ms',
}
const StyledAppTooltip = styled(Tooltip)<{ width?: string }>`
@ -73,7 +74,9 @@ export const AppTooltip = ({
? 0
: delay === TooltipDelay.shortDelay
? 300
: 500;
: delay === TooltipDelay.mediumDelay
? 500
: 1000;
return (
<StyledAppTooltip