larva modules: mega-menu

Available Variants

prototype
mega-menu README

This needs docs!
Create a README.md in the pattern's directory and add details about using this pattern in markdown.

mega-menu Twig The markup file.
<nav class="mega-menu // js-MegaMenu {{ mega_menu_classes }} ">
	<div class="mega-menu-outer // {{ mega_menu_outer_classes }} ">
		<div class="mega-menu-inner // {{ mega_menu_inner_classes }} ">
			<div class="mega-menu-content-outer // {{ mega_menu_content_outer_classes }} ">
				{% include "@larva/modules/mega-menu-content/mega-menu-content.twig" with mega_menu_content %}
			</div>
			{% include "@larva/modules/mega-menu-footer/mega-menu-footer.twig" with mega_menu_footer %}
		</div>
	</div>
</nav>
mega-menu JSON The data object for this pattern.
{
	"mega_menu_footer": {
		"o_email_capture_form": {
			"o_email_capture_form_classes": "",
			"o_email_capture_form_context_name_attr": "FormPost",
			"o_email_capture_form_inner_classes": "lrv-u-text-align-right lrv-u-align-items-center",
			"o_email_capture_form_action_url": "",
			"o_email_capture_form_button_text": "Sign up",
			"o_email_capture_form_name_attr": "email-capture-form",
			"o_email_capture_form_success_url": "",
			"c_button": {
				"c_button_classes": "lrv-a-font-body-xs lrv-a-icon-after lrv-u-text-transform-uppercase lrv-a-unstyle-button lrv-u-cursor-pointer lrv-u-flex lrv-u-justify-content-end lrv-u-width-100p@tablet lrv-a-glue-parent@tablet lrv-u-width-75p@mobile-max",
				"c_button_ga_tracking": {},
				"c_button_inner_classes": "lrv-u-background-color-white lrv-u-padding-l-050",
				"c_button_rel_attr": "",
				"c_button_screen_reader_text": "Sign Up",
				"c_button_target_attr": "",
				"c_button_text": "Sign Up",
				"c_button_type_attr": "submit",
				"c_button_url": ""
			},
			"c_email_field": {
				"c_email_field_classes": "lrv-u-border-b-1 lrv-u-border-r-1 lrv-a-font-body-xxs lrv-u-margin-b-125 lrv-u-margin-b-00@mobile-max lrv-u-text-align-left lrv-u-width-75p@mobile-max",
				"c_email_field_label_classes": "lrv-a-hidden",
				"c_email_field_label_text": "Email Address",
				"c_email_field_input_id_attr": "",
				"c_email_field_input_name_attr": "",
				"c_email_field_input_placeholder_attr": "ENTER E-MAIL",
				"c_email_field_input_classes": "lrv-u-width-100p"
			},
			"o_email_capture_form_hidden_field_items": []
		},
		"c_tagline_terms": {
			"c_tagline_classes": "lrv-a-font-basic-xxs lrv-u-margin-t-050 lrv-a-children-link-decoration-underline",
			"c_tagline_text": false
		},
		"o_social_list": {
			"o_social_list_classes": "lrv-a-unstyle-list",
			"o_social_list_labelledby_attr": "",
			"o_social_list_icons": [
				{
					"c_icon_link_classes": " lrv-u-display-block lrv-u-border-radius-50p lrv-u-color-grey lrv-u-margin-lr-050 lrv-u-padding-a-050 lrv-u-background-color-white lrv-u-color-grey-dark:hover",
					"c_icon_name": "instagram",
					"c_icon_target_attr": "_blank",
					"c_icon_link_screen_reader_text": "Icon Link",
					"c_icon_url": "#",
					"c_icon_classes": "lrv-u-display-block lrv-u-width-16 lrv-u-height-16",
					"c_icon_rel_name": "noopener noreferrer",
					"c_icon_screen_reader_tag_text": "",
					"c_icon_screen_reader_text": "Plus Icon",
					"c_icon_screen_reader_title_attr": "Plus Icon"
				},
				{
					"c_icon_link_classes": " lrv-u-display-block lrv-u-border-radius-50p lrv-u-color-grey lrv-u-margin-lr-050 lrv-u-padding-a-050 lrv-u-background-color-white lrv-u-color-grey-dark:hover",
					"c_icon_name": "pinit",
					"c_icon_target_attr": "_blank",
					"c_icon_link_screen_reader_text": "Icon Link",
					"c_icon_url": "#",
					"c_icon_classes": "lrv-u-display-block lrv-u-width-16 lrv-u-height-16",
					"c_icon_rel_name": "noopener noreferrer",
					"c_icon_screen_reader_tag_text": "",
					"c_icon_screen_reader_text": "Plus Icon",
					"c_icon_screen_reader_title_attr": "Plus Icon"
				},
				{
					"c_icon_link_classes": " lrv-u-display-block lrv-u-border-radius-50p lrv-u-color-grey lrv-u-margin-lr-050 lrv-u-padding-a-050 lrv-u-background-color-white lrv-u-color-grey-dark:hover",
					"c_icon_name": "twitter",
					"c_icon_target_attr": "_blank",
					"c_icon_link_screen_reader_text": "Icon Link",
					"c_icon_url": "#",
					"c_icon_classes": "lrv-u-display-block lrv-u-width-16 lrv-u-height-16",
					"c_icon_rel_name": "noopener noreferrer",
					"c_icon_screen_reader_tag_text": "",
					"c_icon_screen_reader_text": "Plus Icon",
					"c_icon_screen_reader_title_attr": "Plus Icon"
				},
				{
					"c_icon_link_classes": " lrv-u-display-block lrv-u-border-radius-50p lrv-u-color-grey lrv-u-margin-lr-050 lrv-u-padding-a-050 lrv-u-background-color-white lrv-u-color-grey-dark:hover",
					"c_icon_name": "facebook",
					"c_icon_target_attr": "_blank",
					"c_icon_link_screen_reader_text": "Icon Link",
					"c_icon_url": "#",
					"c_icon_classes": "lrv-u-display-block lrv-u-width-16 lrv-u-height-16",
					"c_icon_rel_name": "noopener noreferrer",
					"c_icon_screen_reader_tag_text": "",
					"c_icon_screen_reader_text": "Plus Icon",
					"c_icon_screen_reader_title_attr": "Plus Icon"
				},
				{
					"c_icon_link_classes": " lrv-u-display-block lrv-u-border-radius-50p lrv-u-color-grey lrv-u-margin-lr-050 lrv-u-padding-a-050 lrv-u-background-color-white lrv-u-color-grey-dark:hover",
					"c_icon_name": "youtube",
					"c_icon_target_attr": "_blank",
					"c_icon_link_screen_reader_text": "Icon Link",
					"c_icon_url": "#",
					"c_icon_classes": "lrv-u-display-block lrv-u-width-16 lrv-u-height-16",
					"c_icon_rel_name": "noopener noreferrer",
					"c_icon_screen_reader_tag_text": "",
					"c_icon_screen_reader_text": "Plus Icon",
					"c_icon_screen_reader_title_attr": "Plus Icon"
				}
			]
		},
		"social_heading": {
			"heading_level_text": "3",
			"heading_classes": "lrv-a-font-body-xs lrv-u-margin-b-050 lrv-u-margin-t-025 lrv-u-font-weight-normal lrv-u-text-transform-uppercase lrv-u-text-align-center lrv-u-display-inline-block@mobile-max lrv-u-vertical-align-middle@mobile-max",
			"heading_color_class": "",
			"heading_text_align_class": "",
			"heading_typography_class": "lrv-a-font-primary-m",
			"heading_background_color_class": "",
			"heading_markup": "Follow Us"
		},
		"mega_menu_subscribe": {
			"footer_subscribe_classes": "lrv-a-glue-parent lrv-u-width-100p",
			"c_lazy_image": {
				"c_lazy_image_classes": "lrv-u-padding-l-3",
				"c_lazy_image_link_url": false,
				"c_lazy_image_link_classes": "lrv-a-unstyle-link",
				"c_lazy_image_crop_class": "lrv-a-crop-2x3",
				"c_lazy_image_crop_style_attr": false,
				"c_lazy_image_link_tab_index_attr": false,
				"c_lazy_image_alt_attr": "Lazy loaded image",
				"c_lazy_image_src_url": "https://cdn.shopify.com/s/files/1/0238/6647/products/2019_37_540x.jpg",
				"c_lazy_image_placeholder_url": "https://cdn.shopify.com/s/files/1/0238/6647/products/2019_37_540x.jpg",
				"c_lazy_image_srcset_attr": "https://farm5.staticflickr.com/4078/5441060528_31db7838ba_m.jpg 240w,https://farm5.staticflickr.com/4078/5441060528_31db7838ba_n.jpg 320w,https://farm5.staticflickr.com/4078/5441060528_31db7838ba.jpg 500w,https://farm5.staticflickr.com/4078/5441060528_31db7838ba_z.jpg 640w,https://farm5.staticflickr.com/4078/5441060528_31db7838ba_b.jpg 1024w",
				"c_lazy_image_sizes_attr": "auto",
				"c_lazy_image_img_classes": "lrv-u-background-color-grey-lightest lrv-u-width-100p lrv-u-display-block lrv-u-height-auto",
				"c_lazy_image_height_attr": "",
				"c_lazy_image_width_attr": "",
				"c_lazy_image_in_initial_viewport": false,
				"c_lazy_image_decoding_attr": "async"
			},
			"c_icon": {
				"c_icon_link_classes": "",
				"c_icon_name": "byline-plus",
				"c_icon_target_attr": "_blank",
				"c_icon_link_screen_reader_text": "Icon Link",
				"c_icon_url": false,
				"c_icon_classes": "lrv-a-glue lrv-a-glue--l-0 lrv-a-glue--t-50p lrv-u-transform-translateY-n50p lrv-u-width-50",
				"c_icon_rel_name": "noopener noreferrer",
				"c_icon_screen_reader_tag_text": "",
				"c_icon_screen_reader_text": "Plus Icon",
				"c_icon_screen_reader_title_attr": "Plus Icon"
			}
		},
		"newsletter_heading": {
			"heading_level_text": "3",
			"heading_classes": "email-form-heading lrv-u-background-color-white lrv-a-font-body-xs lrv-u-width-70p lrv-u-margin-b-125 lrv-u-text-align-center lrv-u-font-weight-normal lrv-u-text-transform-uppercase lrv-u-padding-lr-075 lrv-u-border-r-1 lrv-u-border-l-1 lrv-u-border-r-00@mobile-max lrv-u-border-l-00@mobile-max",
			"heading_color_class": "",
			"heading_text_align_class": "",
			"heading_typography_class": "lrv-a-font-primary-m",
			"heading_background_color_class": "",
			"heading_markup": "Alerts & Newsletters"
		},
		"mega_menu_footer_classes": "lrv-u-border-t-2 lrv-u-background-color-white",
		"mega_menu_footer_inner_classes": "lrv-u-flex lrv-u-flex-direction-column@mobile-max",
		"mega_menu_footer_subscribe_classes": "lrv-u-flex lrv-u-flex-direction-column@desktop-max lrv-u-align-items-center lrv-u-width-30p lrv-a-hidden@mobile-max lrv-u-border-r-6 lrv-u-margin-r-025",
		"mega_menu_footer_social_classes": "lrv-u-flex lrv-u-flex-direction-column lrv-u-align-items-center lrv-u-padding-tb-050 lrv-u-width-20p lrv-u-width-100p@mobile-max lrv-u-border-r-1 lrv-u-border-l-1 lrv-u-border-r-00@mobile-max lrv-u-border-l-00@mobile-max lrv-u-padding-lr-050 lrv-u-display-block@mobile-max lrv-u-text-align-center@mobile-max lrv-u-border-b-2@mobile-max",
		"mega_menu_social_list_classes": " lrv-u-display-inline-block@mobile-max lrv-u-vertical-align-middle@mobile-max lrv-u-flex@tablet lrv-u-justify-content-center",
		"mega_menu_footer_form_classes": "lrv-u-flex lrv-u-flex-direction-column lrv-u-align-items-center lrv-u-padding-tb-1 lrv-u-width-50p lrv-u-width-100p@mobile-max lrv-u-flex-direction-column lrv-u-padding-lr-125"
	},
	"mega_menu_content": {
		"mega_menu_content_items": [
			{
				"c_link": {
					"modifier_class": "",
					"c_link_classes": "lrv-a-unstyle-link lrv-u-color-brand-primary-dark:hover lrv-u-font-weight-bold lrv-a-font-body-xs lrv-u-text-transform-uppercase",
					"c_link_text": "Parent item",
					"c_link_url": "#",
					"c_link_rel_attr": false,
					"c_link_aria_label_attr": false,
					"c_link_target_attr": false
				},
				"mega_menu_item_children": [
					{
						"modifier_class": "",
						"c_link_classes": "lrv-a-unstyle-link lrv-u-color-brand-primary-dark:hover lrv-u-padding-tb-025 lrv-u-display-block lrv-a-font-body-xs",
						"c_link_text": "Child item",
						"c_link_url": "#",
						"c_link_rel_attr": false,
						"c_link_aria_label_attr": false,
						"c_link_target_attr": false
					},
					{
						"modifier_class": "",
						"c_link_classes": "lrv-a-unstyle-link lrv-u-color-brand-primary-dark:hover lrv-u-padding-tb-025 lrv-u-display-block lrv-a-font-body-xs",
						"c_link_text": "Child item",
						"c_link_url": "#",
						"c_link_rel_attr": false,
						"c_link_aria_label_attr": false,
						"c_link_target_attr": false
					},
					{
						"modifier_class": "",
						"c_link_classes": "lrv-a-unstyle-link lrv-u-color-brand-primary-dark:hover lrv-u-padding-tb-025 lrv-u-display-block lrv-a-font-body-xs",
						"c_link_text": "Child item",
						"c_link_url": "#",
						"c_link_rel_attr": false,
						"c_link_aria_label_attr": false,
						"c_link_target_attr": false
					}
				],
				"mega_menu_item_classes": "lrv-a-unstyle-list",
				"mega_menu_item_link_classes": "lrv-u-flex lrv-u-color-black   lrv-u-display-inline-block lrv-u-width-100p",
				"mega_menu_child_list_classes": "lrv-a-unstyle-list lrv-u-padding-t-1 lrv-u-margin-b-125"
			},
			{
				"c_link": {
					"modifier_class": "",
					"c_link_classes": "lrv-a-unstyle-link lrv-u-color-brand-primary-dark:hover lrv-u-font-weight-bold lrv-a-font-body-xs lrv-u-text-transform-uppercase",
					"c_link_text": "Parent item",
					"c_link_url": "#",
					"c_link_rel_attr": false,
					"c_link_aria_label_attr": false,
					"c_link_target_attr": false
				},
				"mega_menu_item_children": [
					{
						"modifier_class": "",
						"c_link_classes": "lrv-a-unstyle-link lrv-u-color-brand-primary-dark:hover lrv-u-padding-tb-025 lrv-u-display-block lrv-a-font-body-xs",
						"c_link_text": "Child item",
						"c_link_url": "#",
						"c_link_rel_attr": false,
						"c_link_aria_label_attr": false,
						"c_link_target_attr": false
					},
					{
						"modifier_class": "",
						"c_link_classes": "lrv-a-unstyle-link lrv-u-color-brand-primary-dark:hover lrv-u-padding-tb-025 lrv-u-display-block lrv-a-font-body-xs",
						"c_link_text": "Child item",
						"c_link_url": "#",
						"c_link_rel_attr": false,
						"c_link_aria_label_attr": false,
						"c_link_target_attr": false
					},
					{
						"modifier_class": "",
						"c_link_classes": "lrv-a-unstyle-link lrv-u-color-brand-primary-dark:hover lrv-u-padding-tb-025 lrv-u-display-block lrv-a-font-body-xs",
						"c_link_text": "Child item",
						"c_link_url": "#",
						"c_link_rel_attr": false,
						"c_link_aria_label_attr": false,
						"c_link_target_attr": false
					}
				],
				"mega_menu_item_classes": "lrv-a-unstyle-list",
				"mega_menu_item_link_classes": "lrv-u-flex lrv-u-color-black   lrv-u-display-inline-block lrv-u-width-100p",
				"mega_menu_child_list_classes": "lrv-a-unstyle-list lrv-u-padding-t-1 lrv-u-margin-b-125"
			}
		],
		"mega_menu_content_classes": "lrv-u-flex lrv-u-flex-wrap-wrap lrv-a-unstyle-list lrv-u-background-color-white lrv-a-space-children--050 lrv-a-space-children-horizontal "
	},
	"mega_menu_classes": "",
	"mega_menu_outer_classes": "lrv-a-wrapper",
	"mega_menu_inner_classes": "lrv-u-background-color-white lrv-u-flex lrv-u-flex-direction-column lrv-u-border-b-2 lrv-u-border-r-2 lrv-u-border-l-2",
	"mega_menu_content_outer_classes": "lrv-u-background-color-white lrv-u-padding-a-150 lrv-u-width-100p"
}