aleman 1.0.16 → 1.0.17

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.
@@ -1,8 +1,7 @@
1
- import {menu} from '../menu/menu.js';
2
-
3
1
  export const name = 'menu-toggler';
4
2
  export const events = ['click'];
5
- export const listener = ({render, element}) => {
3
+ export const listener = ({render, element, state}) => {
4
+ const menu = state.menu.data;
6
5
  const command = element.command === 'show' ? 'hide' : 'show';
7
6
 
8
7
  render(['build-menu', 'menu'], {
package/menu/main.js CHANGED
@@ -1,11 +1,11 @@
1
1
  import * as menuClick from '../lib//addons/show-menu-click.js';
2
2
  import * as menuItemClick from '../lib/addons/menu-item-click.js';
3
3
  import * as menuMouseOver from '../lib/addons/menu-mouse-over.js';
4
- import menu from '../lib//globals/menu.js';
4
+ import menu from '../lib/globals/menu.js';
5
5
  import {hydrate} from '../lib/aleman/aleman.js';
6
6
  import {rules} from '../lib/rules/index.js';
7
7
 
8
- export function hydrateMenu() {
8
+ export function hydrateMenu(element, options, menuData) {
9
9
  const addons = [
10
10
  menuClick,
11
11
  menuItemClick,
@@ -18,9 +18,13 @@ export function hydrateMenu() {
18
18
  'menu-toggler': {
19
19
  command: 'hide',
20
20
  },
21
+ 'menu': {
22
+ data: menuData,
23
+ },
21
24
  };
22
25
 
23
26
  hydrate({
27
+ element,
24
28
  state,
25
29
  rules,
26
30
  addons,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "aleman",
3
- "version": "1.0.16",
3
+ "version": "1.0.17",
4
4
  "type": "module",
5
5
  "author": "coderaiser <mnemonic.enemy@gmail.com> (https://github.com/coderaiser)",
6
6
  "description": "🐊Putout-based framework for web",