diff --git a/elements/a11y-menu-button/a11y-menu-button.js b/elements/a11y-menu-button/a11y-menu-button.js index 4cc31c795a..dbe90e8fb0 100644 --- a/elements/a11y-menu-button/a11y-menu-button.js +++ b/elements/a11y-menu-button/a11y-menu-button.js @@ -19,7 +19,7 @@ const A11yMenuButtonBehaviors = function (SuperClass) { css` :host { padding: 0; - display: inline-block; + display: inline-flex; position: relative; z-index: 1; } @@ -267,6 +267,7 @@ const A11yMenuButtonBehaviors = function (SuperClass) { aria-haspopup="true" aria-controls="menu" aria-expanded="${this.expanded ? "true" : "false"}" + part="button" > diff --git a/elements/a11y-menu-button/lib/a11y-menu-button-item.js b/elements/a11y-menu-button/lib/a11y-menu-button-item.js index c54f56a28b..9debed3661 100644 --- a/elements/a11y-menu-button/lib/a11y-menu-button-item.js +++ b/elements/a11y-menu-button/lib/a11y-menu-button-item.js @@ -149,7 +149,12 @@ const A11yMenuButtonItemBehaviors = function (SuperClass) { */ get linkTemplate() { return html`
  • - +
  • `; @@ -166,6 +171,7 @@ const A11yMenuButtonItemBehaviors = function (SuperClass) { role="menuitem" controls="${this.controls}" ?disabled="${this.disabled}" + part="button" > diff --git a/elements/a11y-menu-button/lib/dist/a11y-menu-button-item.dev.js b/elements/a11y-menu-button/lib/dist/a11y-menu-button-item.dev.js index a06b6ecbc0..0426d2b244 100644 --- a/elements/a11y-menu-button/lib/dist/a11y-menu-button-item.dev.js +++ b/elements/a11y-menu-button/lib/dist/a11y-menu-button-item.dev.js @@ -29,7 +29,7 @@ function _templateObject3() { var data = _taggedTemplateLiteral([ '\n
  • \n \n \n \n
  • \n ', + '"\n part="button"\n >\n \n \n \n ', ]); _templateObject3 = function _templateObject3() { @@ -43,7 +43,7 @@ function _templateObject2() { var data = _taggedTemplateLiteral([ '
  • \n \n \n \n
  • ', + '"\n part="button">\n \n \n ', ]); _templateObject2 = function _templateObject2() { diff --git a/elements/a11y-menu-button/src/a11y-menu-button.js b/elements/a11y-menu-button/src/a11y-menu-button.js index 4cc31c795a..dbe90e8fb0 100644 --- a/elements/a11y-menu-button/src/a11y-menu-button.js +++ b/elements/a11y-menu-button/src/a11y-menu-button.js @@ -19,7 +19,7 @@ const A11yMenuButtonBehaviors = function (SuperClass) { css` :host { padding: 0; - display: inline-block; + display: inline-flex; position: relative; z-index: 1; } @@ -267,6 +267,7 @@ const A11yMenuButtonBehaviors = function (SuperClass) { aria-haspopup="true" aria-controls="menu" aria-expanded="${this.expanded ? "true" : "false"}" + part="button" > diff --git a/elements/a11y-menu-button/src/dist/a11y-menu-button.dev.js b/elements/a11y-menu-button/src/dist/a11y-menu-button.dev.js index 2f86533ab9..5325c69ee3 100644 --- a/elements/a11y-menu-button/src/dist/a11y-menu-button.dev.js +++ b/elements/a11y-menu-button/src/dist/a11y-menu-button.dev.js @@ -42,7 +42,7 @@ function _templateObject6() { function _templateObject5() { var data = _taggedTemplateLiteral([ '\n \n \n \n ', + '"\n part="button"\n >\n \n \n ', ]); _templateObject5 = function _templateObject5() { @@ -113,7 +113,7 @@ function _templateObject3() { function _templateObject2() { var data = _taggedTemplateLiteral([ - '\n :host {\n padding: 0;\n display: inline-block;\n position: relative;\n z-index: 1;\n }\n :host([expanded]) {\n z-index: var(--a11y-menu-button-focus-z-index, 1000);\n }\n button[part="button"] {\n display: block;\n text-decoration: inherit;\n font-family: inherit;\n font-size: inherit;\n margin: 0;\n width: 100%;\n }\n absolute-position-behavior {\n z-index: -1;\n overflow: hidden;\n }\n :host([expanded]) absolute-position-behavior {\n z-index: var(--a11y-menu-button-focus-z-index, 1000);\n }\n :host(:not([expanded])) absolute-position-behavior {\n border-color: none !important;\n }\n ul {\n margin: 0;\n padding: 0;\n list-style: none;\n }\n ', + '\n :host {\n padding: 0;\n display: inline-flex;\n position: relative;\n z-index: 1;\n }\n :host([expanded]) {\n z-index: var(--a11y-menu-button-focus-z-index, 1000);\n }\n button[part="button"] {\n display: block;\n text-decoration: inherit;\n font-family: inherit;\n font-size: inherit;\n margin: 0;\n width: 100%;\n }\n absolute-position-behavior {\n z-index: -1;\n overflow: hidden;\n }\n :host([expanded]) absolute-position-behavior {\n z-index: var(--a11y-menu-button-focus-z-index, 1000);\n }\n :host(:not([expanded])) absolute-position-behavior {\n border-color: none !important;\n }\n ul {\n margin: 0;\n padding: 0;\n list-style: none;\n }\n ', ]); _templateObject2 = function _templateObject2() {