landofcoder / module-megamenu-graph-ql
Magento 2 megamenu graphql extension
Installs: 467
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 2
Forks: 0
Open Issues: 0
Type:magento2-module
This package is auto-updated.
Last update: 2024-10-26 13:11:22 UTC
README
``landofcoder/module-megamenu-graph-ql``
Requirement
Main Functionalities
magento 2 megamenu graphql extension
Installation
* = in production please use the --keep-generated
option
Type 1: Zip file
- Unzip the zip file in
app/code/Lof
- Enable the module by running
php bin/magento module:enable Lof_MegamenuGraphQl
- Apply database updates by running
php bin/magento setup:upgrade
* - Flush the cache by running
php bin/magento cache:flush
Type 2: Composer
- Make the module available in a composer repository for example:
- private repository
repo.magento.com
- public repository
packagist.org
- public github repository as vcs
- private repository
- Add the composer repository to the configuration by running
composer config repositories.repo.magento.com composer https://repo.magento.com/
- Install the module composer by running
composer require landofcoder/module-productlist-graph-ql
- enable the module by running
php bin/magento module:enable Lof_MegamenuGraphQl
- apply database updates by running
php bin/magento setup:upgrade
* - Flush the cache by running
php bin/magento cache:flush
Query
- Get menu profile with menu alias
Flagment:
fragment MenuNode on MegamenuItemNode {
name
show_name
classes
child_col
sub_width
align
icon_position
icon_classes
is_group
status
disable_bellow
show_icon
icon
show_header
header_html
show_left_sidebar
left_sidebar_width
menu_id
left_sidebar_html
show_content
content_width
content_type
link_type
link
category
target
content_html
show_right_sidebar
right_sidebar_width
right_sidebar_html
show_footer
footer_html
color
hover_color
bg_color
bg_hover_color
inline_css
tab_position
before_html
after_html
caret
hover_caret
sub_height
hover_icon
dropdown_bgcolor
dropdown_bgimage
dropdown_bgimagerepeat
dropdown_bgpositionx
dropdown_bgpositiony
dropdown_inlinecss
parentcat
animation_in
animation_time
child_col_type
submenu_sorttype
isgroup_level
}
Query (get 3 levels of menu item node) for menu profile alias top-menu
:
{
megamenu (alias: "top-menu") {
name
alias
disable_bellow
event
classes
width
disable_iblocks
desktop_template
scrolltofixed
mobile_template
nodes {
...MenuNode
child_nodes {
...MenuNode
child_nodes {
...MenuNode
}
}
}
}
}
- Get list available menu profiles
Query:
{
megamenus (
filters: {}
pageSize: 10
currentPage: 1
) {
items {
name
alias
}
}
}
- Get Store Config
Query:
storeConfig {
megamenu_general_enabled
megamenu_general_menu_alias
megamenu_general_custom_css
}