Skip to content

Commit

Permalink
refactor!: combine two menu-bar mixins to a single one (#5233)
Browse files Browse the repository at this point in the history
  • Loading branch information
web-padawan committed Jan 5, 2023
1 parent cc3f747 commit 99e4df4
Show file tree
Hide file tree
Showing 7 changed files with 325 additions and 357 deletions.
22 changes: 0 additions & 22 deletions packages/menu-bar/src/vaadin-menu-bar-buttons-mixin.d.ts

This file was deleted.

315 changes: 0 additions & 315 deletions packages/menu-bar/src/vaadin-menu-bar-buttons-mixin.js

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -4,22 +4,34 @@
* This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
*/
import type { Constructor } from '@open-wc/dedupe-mixin';
import type { ControllerMixinClass } from '@vaadin/component-base/src/controller-mixin.js';
import type { FocusMixinClass } from '@vaadin/component-base/src/focus-mixin.js';
import type { KeyboardDirectionMixinClass } from '@vaadin/component-base/src/keyboard-direction-mixin.js';
import type { KeyboardMixinClass } from '@vaadin/component-base/src/keyboard-mixin.js';
import type { ResizeMixinClass } from '@vaadin/component-base/src/resize-mixin.js';

export declare function InteractionsMixin<T extends Constructor<HTMLElement>>(
export declare function MenuBarMixin<T extends Constructor<HTMLElement>>(
base: T,
): Constructor<FocusMixinClass> &
Constructor<InteractionsMixinClass> &
): Constructor<ControllerMixinClass> &
Constructor<FocusMixinClass> &
Constructor<KeyboardDirectionMixinClass> &
Constructor<KeyboardMixinClass> &
Constructor<MenuBarMixinClass> &
Constructor<ResizeMixinClass> &
T;

export declare class InteractionsMixinClass {
export declare class MenuBarMixinClass {
/**
* If true, the submenu will open on hover (mouseover) instead of click.
* @attr {boolean} open-on-hover
*/
openOnHover: boolean | null | undefined;

protected readonly _buttons: HTMLElement[];

protected readonly _container: HTMLElement;

protected readonly _overflow: HTMLElement;

protected _hasOverflow: boolean;
}

0 comments on commit 99e4df4

Please sign in to comment.