aboutsummaryrefslogtreecommitdiffstats
path: root/server/sonar-web/src/main/js/apps
diff options
context:
space:
mode:
authorguillaume-peoch-sonarsource <guillaume.peoch@sonarsource.com>2023-01-16 12:20:18 +0100
committersonartech <sonartech@sonarsource.com>2023-01-17 20:02:59 +0000
commit652cacef6f63d5b7b6d70ee6b05552286ba59196 (patch)
treede687600dfe10f06949d639fda225dd32f6fe475 /server/sonar-web/src/main/js/apps
parent9cf582199aaaec7c2aeaaddff6a2b2343c137555 (diff)
downloadsonarqube-652cacef6f63d5b7b6d70ee6b05552286ba59196.tar.gz
sonarqube-652cacef6f63d5b7b6d70ee6b05552286ba59196.zip
SONAR-18151 [1099147] Incorrect semantic markup
Diffstat (limited to 'server/sonar-web/src/main/js/apps')
-rw-r--r--server/sonar-web/src/main/js/apps/coding-rules/components/RuleDetailsMeta.tsx4
-rw-r--r--server/sonar-web/src/main/js/apps/coding-rules/components/__tests__/__snapshots__/RuleDetailsMeta-test.tsx.snap12
-rw-r--r--server/sonar-web/src/main/js/apps/quality-gates/components/ListHeader.tsx4
-rw-r--r--server/sonar-web/src/main/js/apps/quality-profiles/changelog/ChangelogContainer.tsx5
-rw-r--r--server/sonar-web/src/main/js/apps/quality-profiles/changelog/__tests__/__snapshots__/ChangelogContainer-test.tsx.snap8
-rw-r--r--server/sonar-web/src/main/js/apps/quality-profiles/compare/ComparisonContainer.tsx16
-rw-r--r--server/sonar-web/src/main/js/apps/quality-profiles/details/ProfileInheritance.tsx4
-rw-r--r--server/sonar-web/src/main/js/apps/quality-profiles/details/__tests__/__snapshots__/ProfileInheritance-test.tsx.snap8
-rw-r--r--server/sonar-web/src/main/js/apps/quality-profiles/home/ProfilesListHeader.tsx4
-rw-r--r--server/sonar-web/src/main/js/apps/quality-profiles/home/__tests__/__snapshots__/ProfilesListHeader-test.tsx.snap4
10 files changed, 33 insertions, 36 deletions
diff --git a/server/sonar-web/src/main/js/apps/coding-rules/components/RuleDetailsMeta.tsx b/server/sonar-web/src/main/js/apps/coding-rules/components/RuleDetailsMeta.tsx
index 058f4d5bbfa..f83c99f057c 100644
--- a/server/sonar-web/src/main/js/apps/coding-rules/components/RuleDetailsMeta.tsx
+++ b/server/sonar-web/src/main/js/apps/coding-rules/components/RuleDetailsMeta.tsx
@@ -228,7 +228,7 @@ export default class RuleDetailsMeta extends React.PureComponent<Props> {
const hasTypeData = !ruleDetails.isExternal || ruleDetails.type !== 'UNKNOWN';
return (
<div className="js-rule-meta">
- <header className="page-header">
+ <div className="page-header">
<div className="pull-right">
{this.renderKey()}
{!ruleDetails.isExternal && (
@@ -247,7 +247,7 @@ export default class RuleDetailsMeta extends React.PureComponent<Props> {
<h3 className="page-title coding-rules-detail-header">
<big>{ruleDetails.name}</big>
</h3>
- </header>
+ </div>
{hasTypeData && (
<ul className="coding-rules-detail-properties">
diff --git a/server/sonar-web/src/main/js/apps/coding-rules/components/__tests__/__snapshots__/RuleDetailsMeta-test.tsx.snap b/server/sonar-web/src/main/js/apps/coding-rules/components/__tests__/__snapshots__/RuleDetailsMeta-test.tsx.snap
index 94f8953d085..9deaf6ffae9 100644
--- a/server/sonar-web/src/main/js/apps/coding-rules/components/__tests__/__snapshots__/RuleDetailsMeta-test.tsx.snap
+++ b/server/sonar-web/src/main/js/apps/coding-rules/components/__tests__/__snapshots__/RuleDetailsMeta-test.tsx.snap
@@ -4,7 +4,7 @@ exports[`should display right meta info 1`] = `
<div
className="js-rule-meta"
>
- <header
+ <div
className="page-header"
>
<div
@@ -53,7 +53,7 @@ exports[`should display right meta info 1`] = `
Deprecated code should be removed
</big>
</h3>
- </header>
+ </div>
<ul
className="coding-rules-detail-properties"
>
@@ -133,7 +133,7 @@ exports[`should display right meta info 2`] = `
<div
className="js-rule-meta"
>
- <header
+ <div
className="page-header"
>
<div
@@ -152,7 +152,7 @@ exports[`should display right meta info 2`] = `
xoo:OneExternalIssuePerLine
</big>
</h3>
- </header>
+ </div>
</div>
`;
@@ -160,7 +160,7 @@ exports[`should display right meta info 3`] = `
<div
className="js-rule-meta"
>
- <header
+ <div
className="page-header"
>
<div
@@ -179,7 +179,7 @@ exports[`should display right meta info 3`] = `
One external issue per line
</big>
</h3>
- </header>
+ </div>
<ul
className="coding-rules-detail-properties"
>
diff --git a/server/sonar-web/src/main/js/apps/quality-gates/components/ListHeader.tsx b/server/sonar-web/src/main/js/apps/quality-gates/components/ListHeader.tsx
index 649615fdcc1..fa77e1d3b4d 100644
--- a/server/sonar-web/src/main/js/apps/quality-gates/components/ListHeader.tsx
+++ b/server/sonar-web/src/main/js/apps/quality-gates/components/ListHeader.tsx
@@ -31,7 +31,7 @@ interface Props {
export default function ListHeader({ canCreate, refreshQualityGates }: Props) {
return (
- <header className="page-header">
+ <div className="page-header">
{canCreate && (
<div className="page-actions">
<ModalButton
@@ -61,6 +61,6 @@ export default function ListHeader({ canCreate, refreshQualityGates }: Props) {
]}
/>
</div>
- </header>
+ </div>
);
}
diff --git a/server/sonar-web/src/main/js/apps/quality-profiles/changelog/ChangelogContainer.tsx b/server/sonar-web/src/main/js/apps/quality-profiles/changelog/ChangelogContainer.tsx
index 17f0cf3ce28..63863e966c9 100644
--- a/server/sonar-web/src/main/js/apps/quality-profiles/changelog/ChangelogContainer.tsx
+++ b/server/sonar-web/src/main/js/apps/quality-profiles/changelog/ChangelogContainer.tsx
@@ -138,7 +138,7 @@ export class ChangelogContainer extends React.PureComponent<Props, State> {
return (
<div className="boxed-group boxed-group-inner js-profile-changelog">
- <header className="spacer-bottom">
+ <div className="spacer-bottom">
<ChangelogSearch
dateRange={{
from: query.since ? parseDate(query.since) : undefined,
@@ -147,9 +147,8 @@ export class ChangelogContainer extends React.PureComponent<Props, State> {
onDateRangeChange={this.handleDateRangeChange}
onReset={this.handleReset}
/>
-
<DeferredSpinner loading={this.state.loading} className="spacer-left" />
- </header>
+ </div>
{this.state.events != null && this.state.events.length === 0 && <ChangelogEmpty />}
diff --git a/server/sonar-web/src/main/js/apps/quality-profiles/changelog/__tests__/__snapshots__/ChangelogContainer-test.tsx.snap b/server/sonar-web/src/main/js/apps/quality-profiles/changelog/__tests__/__snapshots__/ChangelogContainer-test.tsx.snap
index a42e82c92c5..b9549ee78b8 100644
--- a/server/sonar-web/src/main/js/apps/quality-profiles/changelog/__tests__/__snapshots__/ChangelogContainer-test.tsx.snap
+++ b/server/sonar-web/src/main/js/apps/quality-profiles/changelog/__tests__/__snapshots__/ChangelogContainer-test.tsx.snap
@@ -4,7 +4,7 @@ exports[`should render correctly 1`] = `
<div
className="boxed-group boxed-group-inner js-profile-changelog"
>
- <header
+ <div
className="spacer-bottom"
>
<ChangelogSearch
@@ -21,7 +21,7 @@ exports[`should render correctly 1`] = `
className="spacer-left"
loading={false}
/>
- </header>
+ </div>
<Changelog
events={
[
@@ -72,7 +72,7 @@ exports[`should render correctly without events 1`] = `
<div
className="boxed-group boxed-group-inner js-profile-changelog"
>
- <header
+ <div
className="spacer-bottom"
>
<ChangelogSearch
@@ -89,7 +89,7 @@ exports[`should render correctly without events 1`] = `
className="spacer-left"
loading={false}
/>
- </header>
+ </div>
<ChangelogEmpty />
</div>
`;
diff --git a/server/sonar-web/src/main/js/apps/quality-profiles/compare/ComparisonContainer.tsx b/server/sonar-web/src/main/js/apps/quality-profiles/compare/ComparisonContainer.tsx
index 59d22cab133..3703109b492 100644
--- a/server/sonar-web/src/main/js/apps/quality-profiles/compare/ComparisonContainer.tsx
+++ b/server/sonar-web/src/main/js/apps/quality-profiles/compare/ComparisonContainer.tsx
@@ -96,16 +96,14 @@ class ComparisonContainer extends React.PureComponent<Props, State> {
return (
<div className="boxed-group boxed-group-inner js-profile-comparison">
- <header>
- <ComparisonForm
- onCompare={this.handleCompare}
- profile={profile}
- profiles={profiles}
- withKey={withKey}
- />
+ <ComparisonForm
+ onCompare={this.handleCompare}
+ profile={profile}
+ profiles={profiles}
+ withKey={withKey}
+ />
- {this.state.loading && <i className="spinner spacer-left" />}
- </header>
+ {this.state.loading && <i className="spinner spacer-left" />}
{this.hasResults(this.state) && (
<div className="spacer-top">
diff --git a/server/sonar-web/src/main/js/apps/quality-profiles/details/ProfileInheritance.tsx b/server/sonar-web/src/main/js/apps/quality-profiles/details/ProfileInheritance.tsx
index 3e6eec3d7d8..31a5e739521 100644
--- a/server/sonar-web/src/main/js/apps/quality-profiles/details/ProfileInheritance.tsx
+++ b/server/sonar-web/src/main/js/apps/quality-profiles/details/ProfileInheritance.tsx
@@ -127,9 +127,9 @@ export default class ProfileInheritance extends React.PureComponent<Props, State
</div>
)}
- <header className="boxed-group-header">
+ <div className="boxed-group-header">
<h2>{translate('quality_profiles.profile_inheritance')}</h2>
- </header>
+ </div>
<div className="boxed-group-inner">
{this.state.loading ? (
diff --git a/server/sonar-web/src/main/js/apps/quality-profiles/details/__tests__/__snapshots__/ProfileInheritance-test.tsx.snap b/server/sonar-web/src/main/js/apps/quality-profiles/details/__tests__/__snapshots__/ProfileInheritance-test.tsx.snap
index 9eff32909b2..150831cc08e 100644
--- a/server/sonar-web/src/main/js/apps/quality-profiles/details/__tests__/__snapshots__/ProfileInheritance-test.tsx.snap
+++ b/server/sonar-web/src/main/js/apps/quality-profiles/details/__tests__/__snapshots__/ProfileInheritance-test.tsx.snap
@@ -4,13 +4,13 @@ exports[`should render correctly 1`] = `
<div
className="boxed-group quality-profile-inheritance"
>
- <header
+ <div
className="boxed-group-header"
>
<h2>
quality_profiles.profile_inheritance
</h2>
- </header>
+ </div>
<div
className="boxed-group-inner"
>
@@ -58,13 +58,13 @@ exports[`should render modal correctly 1`] = `
<div
className="boxed-group quality-profile-inheritance"
>
- <header
+ <div
className="boxed-group-header"
>
<h2>
quality_profiles.profile_inheritance
</h2>
- </header>
+ </div>
<div
className="boxed-group-inner"
>
diff --git a/server/sonar-web/src/main/js/apps/quality-profiles/home/ProfilesListHeader.tsx b/server/sonar-web/src/main/js/apps/quality-profiles/home/ProfilesListHeader.tsx
index 5f1abf2b1cc..ab67a194c9e 100644
--- a/server/sonar-web/src/main/js/apps/quality-profiles/home/ProfilesListHeader.tsx
+++ b/server/sonar-web/src/main/js/apps/quality-profiles/home/ProfilesListHeader.tsx
@@ -49,7 +49,7 @@ export class ProfilesListHeader extends React.PureComponent<Props> {
}));
return (
- <header className="quality-profiles-list-header clearfix">
+ <div className="quality-profiles-list-header clearfix">
<label htmlFor="quality-profiles-filter-input" className="spacer-right">
{translate('quality_profiles.filter_by')}:
</label>
@@ -64,7 +64,7 @@ export class ProfilesListHeader extends React.PureComponent<Props> {
isSearchable={true}
value={options.filter((o) => o.value === currentFilter)}
/>
- </header>
+ </div>
);
}
}
diff --git a/server/sonar-web/src/main/js/apps/quality-profiles/home/__tests__/__snapshots__/ProfilesListHeader-test.tsx.snap b/server/sonar-web/src/main/js/apps/quality-profiles/home/__tests__/__snapshots__/ProfilesListHeader-test.tsx.snap
index 7b85f20efbf..82c185c43a3 100644
--- a/server/sonar-web/src/main/js/apps/quality-profiles/home/__tests__/__snapshots__/ProfilesListHeader-test.tsx.snap
+++ b/server/sonar-web/src/main/js/apps/quality-profiles/home/__tests__/__snapshots__/ProfilesListHeader-test.tsx.snap
@@ -1,7 +1,7 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`should render correctly 1`] = `
-<header
+<div
className="quality-profiles-list-header clearfix"
>
<label
@@ -33,5 +33,5 @@ exports[`should render correctly 1`] = `
}
value={[]}
/>
-</header>
+</div>
`;