Commit 0af85c4f authored by Kushal Pandya's avatar Kushal Pandya

Merge branch 'ph/mrWidgetExtensionBaseAccessibility' into 'master'

Updated MR extension container accessibility regions

See merge request gitlab-org/gitlab!71305
parents 9663b69b f15731c9
......@@ -117,7 +117,7 @@ export default {
</script>
<template>
<section class="media-section mr-widget-border-top" data-testid="widget-extension">
<section class="media-section" data-testid="widget-extension">
<div class="media gl-p-5">
<status-icon
:name="$options.name"
......
import { __ } from '~/locale';
import { registeredExtensions } from './index';
export default {
......@@ -12,23 +13,42 @@ export default {
if (extensions.length === 0) return null;
return h('div', {}, [
...extensions.map((extension) =>
return h(
'div',
{
attrs: {
role: 'region',
'aria-label': __('Merge request reports'),
},
},
[
h(
{ ...extension },
'ul',
{
props: {
...extension.props.reduce(
(acc, key) => ({
...acc,
[key]: this.mr[key],
}),
{},
),
},
class: 'gl-p-0 gl-m-0 gl-list-style-none',
},
[
...extensions.map((extension, index) =>
h('li', { attrs: { class: index > 0 && 'mr-widget-border-top' } }, [
h(
{ ...extension },
{
props: {
...extension.props.reduce(
(acc, key) => ({
...acc,
[key]: this.mr[key],
}),
{},
),
},
},
),
]),
),
],
),
),
]);
],
);
},
};
......@@ -21350,6 +21350,9 @@ msgstr ""
msgid "Merge request events"
msgstr ""
msgid "Merge request reports"
msgstr ""
msgid "Merge request was scheduled to merge after pipeline succeeds"
msgstr ""
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment