mirror of
https://github.com/grafana/grafana.git
synced 2025-01-15 19:22:34 -06:00
PanelShortcuts: Set attention onMouseEnter (#90435)
Add onMouseEnter to PanelChrome
This commit is contained in:
parent
118597d80f
commit
4c9cb63823
@ -65,6 +65,7 @@ interface BaseProps {
|
||||
* Debounce the event handler, if possible
|
||||
*/
|
||||
onMouseMove?: () => void;
|
||||
onMouseEnter?: () => void;
|
||||
}
|
||||
|
||||
interface FixedDimensions extends BaseProps {
|
||||
@ -132,6 +133,7 @@ export function PanelChrome({
|
||||
onToggleCollapse,
|
||||
onFocus,
|
||||
onMouseMove,
|
||||
onMouseEnter,
|
||||
}: PanelChromeProps) {
|
||||
const theme = useTheme2();
|
||||
const styles = useStyles2(getStyles);
|
||||
@ -262,6 +264,7 @@ export function PanelChrome({
|
||||
tabIndex={0} // eslint-disable-line jsx-a11y/no-noninteractive-tabindex
|
||||
onFocus={onFocus}
|
||||
onMouseMove={onMouseMove}
|
||||
onMouseEnter={onMouseEnter}
|
||||
ref={ref}
|
||||
>
|
||||
<div className={styles.loadingBarContainer}>
|
||||
|
@ -589,6 +589,7 @@ export class PanelStateWrapper extends PureComponent<Props, State> {
|
||||
onCancelQuery={panelChromeProps.onCancelQuery}
|
||||
onOpenMenu={panelChromeProps.onOpenMenu}
|
||||
onFocus={() => this.setPanelAttention()}
|
||||
onMouseEnter={() => this.setPanelAttention()}
|
||||
onMouseMove={() => this.debouncedSetPanelAttention()}
|
||||
>
|
||||
{(innerWidth, innerHeight) => (
|
||||
|
Loading…
Reference in New Issue
Block a user