mirror of
https://github.com/elastic/kibana.git
synced 2025-04-24 01:38:56 -04:00
parent
75f7ef07be
commit
993fb80171
10 changed files with 42 additions and 39 deletions
|
@ -346,7 +346,7 @@
|
|||
"angular-route": "^1.8.0",
|
||||
"angular-sortable-view": "^0.0.17",
|
||||
"archiver": "^3.1.1",
|
||||
"axe-core": "^3.4.1",
|
||||
"axe-core": "^4.0.2",
|
||||
"babel-eslint": "^10.0.3",
|
||||
"babel-jest": "^25.5.1",
|
||||
"babel-plugin-istanbul": "^6.0.0",
|
||||
|
|
|
@ -613,6 +613,7 @@ export class QueryStringInputUI extends Component<Props, State> {
|
|||
})}
|
||||
aria-haspopup="true"
|
||||
aria-expanded={this.state.isSuggestionsVisible}
|
||||
data-skip-axe="aria-required-children"
|
||||
>
|
||||
<div
|
||||
role="search"
|
||||
|
|
|
@ -147,7 +147,6 @@ exports[`NewVisModal filter for visualization types should render as expected 1`
|
|||
<div
|
||||
aria-label="Start creating your visualization by selecting a type for that visualization. Hit escape to close this modal. Hit Tab key to go further."
|
||||
class="euiModal euiModal--maxWidth-default visNewVisDialog"
|
||||
role="menu"
|
||||
tabindex="0"
|
||||
>
|
||||
<button
|
||||
|
@ -251,7 +250,6 @@ exports[`NewVisModal filter for visualization types should render as expected 1`
|
|||
class="euiKeyPadMenuItem visNewVisDialog__type"
|
||||
data-test-subj="visType-visWithAliasUrl"
|
||||
data-vis-stage="alias"
|
||||
role="menuitem"
|
||||
type="button"
|
||||
>
|
||||
<div
|
||||
|
@ -283,7 +281,6 @@ exports[`NewVisModal filter for visualization types should render as expected 1`
|
|||
class="euiKeyPadMenuItem visNewVisDialog__type"
|
||||
data-test-subj="visType-visWithSearch"
|
||||
data-vis-stage="production"
|
||||
role="menuitem"
|
||||
type="button"
|
||||
>
|
||||
<div
|
||||
|
@ -316,7 +313,6 @@ exports[`NewVisModal filter for visualization types should render as expected 1`
|
|||
data-test-subj="visType-vis"
|
||||
data-vis-stage="production"
|
||||
disabled=""
|
||||
role="menuitem"
|
||||
type="button"
|
||||
>
|
||||
<div
|
||||
|
@ -377,7 +373,6 @@ exports[`NewVisModal filter for visualization types should render as expected 1`
|
|||
aria-label="Start creating your visualization by selecting a type for that visualization. Hit escape to close this modal. Hit Tab key to go further."
|
||||
className="visNewVisDialog"
|
||||
onClose={[Function]}
|
||||
role="menu"
|
||||
>
|
||||
<EuiFocusTrap>
|
||||
<div
|
||||
|
@ -387,7 +382,6 @@ exports[`NewVisModal filter for visualization types should render as expected 1`
|
|||
aria-label="Start creating your visualization by selecting a type for that visualization. Hit escape to close this modal. Hit Tab key to go further."
|
||||
className="euiModal euiModal--maxWidth-default visNewVisDialog"
|
||||
onKeyDown={[Function]}
|
||||
role="menu"
|
||||
tabIndex={0}
|
||||
>
|
||||
<EuiI18n
|
||||
|
@ -649,7 +643,6 @@ exports[`NewVisModal filter for visualization types should render as expected 1`
|
|||
onFocus={[Function]}
|
||||
onMouseEnter={[Function]}
|
||||
onMouseLeave={[Function]}
|
||||
role="menuitem"
|
||||
>
|
||||
<button
|
||||
aria-describedby="visTypeDescription-visWithAliasUrl"
|
||||
|
@ -662,7 +655,6 @@ exports[`NewVisModal filter for visualization types should render as expected 1`
|
|||
onFocus={[Function]}
|
||||
onMouseEnter={[Function]}
|
||||
onMouseLeave={[Function]}
|
||||
role="menuitem"
|
||||
type="button"
|
||||
>
|
||||
<div
|
||||
|
@ -720,7 +712,6 @@ exports[`NewVisModal filter for visualization types should render as expected 1`
|
|||
onFocus={[Function]}
|
||||
onMouseEnter={[Function]}
|
||||
onMouseLeave={[Function]}
|
||||
role="menuitem"
|
||||
>
|
||||
<button
|
||||
aria-describedby="visTypeDescription-visWithSearch"
|
||||
|
@ -733,7 +724,6 @@ exports[`NewVisModal filter for visualization types should render as expected 1`
|
|||
onFocus={[Function]}
|
||||
onMouseEnter={[Function]}
|
||||
onMouseLeave={[Function]}
|
||||
role="menuitem"
|
||||
type="button"
|
||||
>
|
||||
<div
|
||||
|
@ -791,7 +781,6 @@ exports[`NewVisModal filter for visualization types should render as expected 1`
|
|||
onFocus={[Function]}
|
||||
onMouseEnter={[Function]}
|
||||
onMouseLeave={[Function]}
|
||||
role="menuitem"
|
||||
>
|
||||
<button
|
||||
aria-describedby="visTypeDescription-vis"
|
||||
|
@ -804,7 +793,6 @@ exports[`NewVisModal filter for visualization types should render as expected 1`
|
|||
onFocus={[Function]}
|
||||
onMouseEnter={[Function]}
|
||||
onMouseLeave={[Function]}
|
||||
role="menuitem"
|
||||
type="button"
|
||||
>
|
||||
<div
|
||||
|
@ -1060,7 +1048,6 @@ exports[`NewVisModal should render as expected 1`] = `
|
|||
<div
|
||||
aria-label="Start creating your visualization by selecting a type for that visualization. Hit escape to close this modal. Hit Tab key to go further."
|
||||
class="euiModal euiModal--maxWidth-default visNewVisDialog"
|
||||
role="menu"
|
||||
tabindex="0"
|
||||
>
|
||||
<button
|
||||
|
@ -1148,7 +1135,6 @@ exports[`NewVisModal should render as expected 1`] = `
|
|||
class="euiKeyPadMenuItem visNewVisDialog__type"
|
||||
data-test-subj="visType-vis"
|
||||
data-vis-stage="production"
|
||||
role="menuitem"
|
||||
type="button"
|
||||
>
|
||||
<div
|
||||
|
@ -1180,7 +1166,6 @@ exports[`NewVisModal should render as expected 1`] = `
|
|||
class="euiKeyPadMenuItem visNewVisDialog__type"
|
||||
data-test-subj="visType-visWithAliasUrl"
|
||||
data-vis-stage="alias"
|
||||
role="menuitem"
|
||||
type="button"
|
||||
>
|
||||
<div
|
||||
|
@ -1212,7 +1197,6 @@ exports[`NewVisModal should render as expected 1`] = `
|
|||
class="euiKeyPadMenuItem visNewVisDialog__type"
|
||||
data-test-subj="visType-visWithSearch"
|
||||
data-vis-stage="production"
|
||||
role="menuitem"
|
||||
type="button"
|
||||
>
|
||||
<div
|
||||
|
@ -1273,7 +1257,6 @@ exports[`NewVisModal should render as expected 1`] = `
|
|||
aria-label="Start creating your visualization by selecting a type for that visualization. Hit escape to close this modal. Hit Tab key to go further."
|
||||
className="visNewVisDialog"
|
||||
onClose={[Function]}
|
||||
role="menu"
|
||||
>
|
||||
<EuiFocusTrap>
|
||||
<div
|
||||
|
@ -1283,7 +1266,6 @@ exports[`NewVisModal should render as expected 1`] = `
|
|||
aria-label="Start creating your visualization by selecting a type for that visualization. Hit escape to close this modal. Hit Tab key to go further."
|
||||
className="euiModal euiModal--maxWidth-default visNewVisDialog"
|
||||
onKeyDown={[Function]}
|
||||
role="menu"
|
||||
tabIndex={0}
|
||||
>
|
||||
<EuiI18n
|
||||
|
@ -1494,7 +1476,6 @@ exports[`NewVisModal should render as expected 1`] = `
|
|||
onFocus={[Function]}
|
||||
onMouseEnter={[Function]}
|
||||
onMouseLeave={[Function]}
|
||||
role="menuitem"
|
||||
>
|
||||
<button
|
||||
aria-describedby="visTypeDescription-vis"
|
||||
|
@ -1507,7 +1488,6 @@ exports[`NewVisModal should render as expected 1`] = `
|
|||
onFocus={[Function]}
|
||||
onMouseEnter={[Function]}
|
||||
onMouseLeave={[Function]}
|
||||
role="menuitem"
|
||||
type="button"
|
||||
>
|
||||
<div
|
||||
|
@ -1565,7 +1545,6 @@ exports[`NewVisModal should render as expected 1`] = `
|
|||
onFocus={[Function]}
|
||||
onMouseEnter={[Function]}
|
||||
onMouseLeave={[Function]}
|
||||
role="menuitem"
|
||||
>
|
||||
<button
|
||||
aria-describedby="visTypeDescription-visWithAliasUrl"
|
||||
|
@ -1578,7 +1557,6 @@ exports[`NewVisModal should render as expected 1`] = `
|
|||
onFocus={[Function]}
|
||||
onMouseEnter={[Function]}
|
||||
onMouseLeave={[Function]}
|
||||
role="menuitem"
|
||||
type="button"
|
||||
>
|
||||
<div
|
||||
|
@ -1636,7 +1614,6 @@ exports[`NewVisModal should render as expected 1`] = `
|
|||
onFocus={[Function]}
|
||||
onMouseEnter={[Function]}
|
||||
onMouseLeave={[Function]}
|
||||
role="menuitem"
|
||||
>
|
||||
<button
|
||||
aria-describedby="visTypeDescription-visWithSearch"
|
||||
|
@ -1649,7 +1626,6 @@ exports[`NewVisModal should render as expected 1`] = `
|
|||
onFocus={[Function]}
|
||||
onMouseEnter={[Function]}
|
||||
onMouseLeave={[Function]}
|
||||
role="menuitem"
|
||||
type="button"
|
||||
>
|
||||
<div
|
||||
|
|
|
@ -108,7 +108,6 @@ class NewVisModal extends React.Component<TypeSelectionProps, TypeSelectionState
|
|||
onClose={this.onCloseModal}
|
||||
className="visNewVisDialog"
|
||||
aria-label={visNewVisDialogAriaLabel}
|
||||
role="menu"
|
||||
>
|
||||
<TypeSelection
|
||||
showExperimental={this.isLabsEnabled}
|
||||
|
|
|
@ -259,7 +259,6 @@ class TypeSelection extends React.Component<TypeSelectionProps, TypeSelectionSta
|
|||
data-vis-stage={!('aliasPath' in visType) ? visType.stage : 'alias'}
|
||||
disabled={isDisabled}
|
||||
aria-describedby={`visTypeDescription-${visType.name}`}
|
||||
role="menuitem"
|
||||
{...stage}
|
||||
>
|
||||
<VisTypeIcon
|
||||
|
|
|
@ -36,6 +36,8 @@ interface TestOptions {
|
|||
|
||||
export const normalizeResult = (report: any) => {
|
||||
if (report.error) {
|
||||
const error = new Error(report.error.message);
|
||||
error.stack = report.error.stack;
|
||||
throw report.error;
|
||||
}
|
||||
|
||||
|
@ -71,7 +73,6 @@ export function A11yProvider({ getService }: FtrProviderContext) {
|
|||
.concat(excludeTestSubj || [])
|
||||
.map((ts) => [testSubjectToCss(ts)])
|
||||
.concat([
|
||||
['.ace_scrollbar'],
|
||||
[
|
||||
'.leaflet-vega-container[role="graphics-document"][aria-roledescription="visualization"]',
|
||||
],
|
||||
|
@ -97,7 +98,7 @@ export function A11yProvider({ getService }: FtrProviderContext) {
|
|||
runOnly: ['wcag2a', 'wcag2aa'],
|
||||
rules: {
|
||||
'color-contrast': {
|
||||
enabled: false,
|
||||
enabled: false, // disabled because we have too many failures
|
||||
},
|
||||
bypass: {
|
||||
enabled: false, // disabled because it's too flaky
|
||||
|
|
|
@ -23,6 +23,18 @@ export function analyzeWithAxe(context, options, callback) {
|
|||
Promise.resolve()
|
||||
.then(() => {
|
||||
if (window.axe) {
|
||||
window.axe.configure({
|
||||
rules: [
|
||||
{
|
||||
id: 'scrollable-region-focusable',
|
||||
selector: '[data-skip-axe="scrollable-region-focusable"]',
|
||||
},
|
||||
{
|
||||
id: 'aria-required-children',
|
||||
selector: '[data-skip-axe="aria-required-children"] > *',
|
||||
},
|
||||
],
|
||||
});
|
||||
return window.axe.run(context, options);
|
||||
}
|
||||
|
||||
|
@ -31,7 +43,14 @@ export function analyzeWithAxe(context, options, callback) {
|
|||
})
|
||||
.then(
|
||||
(result) => callback({ result }),
|
||||
(error) => callback({ error })
|
||||
(error) => {
|
||||
callback({
|
||||
error: {
|
||||
message: error.message,
|
||||
stack: error.stack,
|
||||
},
|
||||
});
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
|
|
|
@ -161,6 +161,9 @@ export function SearchBar({ globalSearch, navigateToUrl }: Props) {
|
|||
defaultMessage: 'Search Elastic',
|
||||
}),
|
||||
}}
|
||||
popoverProps={{
|
||||
repositionOnScroll: true,
|
||||
}}
|
||||
emptyMessage={
|
||||
<EuiSelectableMessage style={{ minHeight: 300 }}>
|
||||
<p>
|
||||
|
|
|
@ -11,6 +11,7 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) {
|
|||
const a11y = getService('a11y');
|
||||
const retry = getService('retry');
|
||||
const globalNav = getService('globalNav');
|
||||
const testSubjects = getService('testSubjects');
|
||||
|
||||
describe('Kibana Home', () => {
|
||||
before(async () => {
|
||||
|
@ -46,15 +47,12 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) {
|
|||
await a11y.testAppSnapshot();
|
||||
});
|
||||
|
||||
// issue: https://github.com/elastic/kibana/issues/38980
|
||||
it.skip('navigating back to home page from console meets a11y requirements', async () => {
|
||||
it('navigating back to home page from console meets a11y requirements', async () => {
|
||||
await PageObjects.home.clickOnLogo();
|
||||
await a11y.testAppSnapshot();
|
||||
});
|
||||
|
||||
// Extra clickon logo step here will be removed after preceding test is fixed.
|
||||
it('click on Add logs panel to open all log examples page meets a11y requirements ', async () => {
|
||||
await PageObjects.home.clickOnLogo();
|
||||
await PageObjects.home.clickOnAddData();
|
||||
await a11y.testAppSnapshot();
|
||||
});
|
||||
|
@ -85,9 +83,16 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) {
|
|||
await a11y.testAppSnapshot();
|
||||
});
|
||||
|
||||
it('unDock the side nav', async () => {
|
||||
// TODO https://github.com/elastic/kibana/issues/77828
|
||||
it.skip('undock the side nav', async () => {
|
||||
await PageObjects.home.dockTheSideNav();
|
||||
await a11y.testAppSnapshot();
|
||||
});
|
||||
|
||||
it('passes with searchbox open', async () => {
|
||||
await PageObjects.common.navigateToApp('home');
|
||||
await testSubjects.click('header-search');
|
||||
await a11y.testAppSnapshot();
|
||||
});
|
||||
});
|
||||
}
|
||||
|
|
|
@ -6653,10 +6653,10 @@ aws4@^1.8.0:
|
|||
resolved "https://registry.yarnpkg.com/aws4/-/aws4-1.8.0.tgz#f0e003d9ca9e7f59c7a508945d7b2ef9a04a542f"
|
||||
integrity sha512-ReZxvNHIOv88FlT7rxcXIIC0fPt4KZqZbOlivyWtXLt8ESx84zd3kMC6iK5jVeS2qt+g7ftS7ye4fi06X5rtRQ==
|
||||
|
||||
axe-core@^3.4.1:
|
||||
version "3.5.1"
|
||||
resolved "https://registry.yarnpkg.com/axe-core/-/axe-core-3.5.1.tgz#d8d5aaef73f003e8b766ea28bb078343f3622201"
|
||||
integrity sha512-mwpDgPwWB+5kMHyLjlxh4w25ClJfqSxi+c6LQ4ix349TdCUctMwJNPTkhPD1qP9SYIjFgjeVpVZWCvK9oBGwCg==
|
||||
axe-core@^4.0.2:
|
||||
version "4.0.2"
|
||||
resolved "https://registry.yarnpkg.com/axe-core/-/axe-core-4.0.2.tgz#c7cf7378378a51fcd272d3c09668002a4990b1cb"
|
||||
integrity sha512-arU1h31OGFu+LPrOLGZ7nB45v940NMDMEJeNmbutu57P+UFDVnkZg3e+J1I2HJRZ9hT7gO8J91dn/PMrAiKakA==
|
||||
|
||||
axios@^0.18.0:
|
||||
version "0.18.1"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue