diff options
author | Grégoire Aubert <gregoire.aubert@sonarsource.com> | 2017-05-23 14:50:03 +0200 |
---|---|---|
committer | Grégoire Aubert <gregoire.aubert@sonarsource.com> | 2017-06-09 08:26:48 +0200 |
commit | 9de2e9c91932c61a8575f30d7bc7319624a7d91f (patch) | |
tree | 380ac130c9bcd89b5479b326f4b5cb35aad22b13 | |
parent | ea37577db04eba371145873d41ac8ad9cae9bb64 (diff) | |
download | sonarqube-9de2e9c91932c61a8575f30d7bc7319624a7d91f.tar.gz sonarqube-9de2e9c91932c61a8575f30d7bc7319624a7d91f.zip |
Move issues type icons to the icons-components folder
-rw-r--r-- | server/sonar-web/src/main/js/apps/about/components/AboutQualityModel.js | 6 | ||||
-rw-r--r-- | server/sonar-web/src/main/js/apps/about/components/EntryIssueTypes.js | 6 | ||||
-rw-r--r-- | server/sonar-web/src/main/js/apps/overview/main/BugsAndVulnerabilities.js | 4 | ||||
-rw-r--r-- | server/sonar-web/src/main/js/apps/overview/main/CodeSmells.js | 2 | ||||
-rw-r--r-- | server/sonar-web/src/main/js/apps/projects/components/ProjectCardLeakMeasures.js | 6 | ||||
-rw-r--r-- | server/sonar-web/src/main/js/components/icons-components/BugIcon.js (renamed from server/sonar-web/src/main/js/components/ui/BugIcon.js) | 8 | ||||
-rw-r--r-- | server/sonar-web/src/main/js/components/icons-components/CodeSmellIcon.js (renamed from server/sonar-web/src/main/js/components/ui/CodeSmellIcon.js) | 8 | ||||
-rw-r--r-- | server/sonar-web/src/main/js/components/icons-components/VulnerabilityIcon.js (renamed from server/sonar-web/src/main/js/components/ui/VulnerabilityIcon.js) | 8 | ||||
-rw-r--r-- | server/sonar-web/src/main/js/components/ui/IssueTypeIcon.js | 6 |
9 files changed, 30 insertions, 24 deletions
diff --git a/server/sonar-web/src/main/js/apps/about/components/AboutQualityModel.js b/server/sonar-web/src/main/js/apps/about/components/AboutQualityModel.js index 9e50b5e6a7d..503ef74807f 100644 --- a/server/sonar-web/src/main/js/apps/about/components/AboutQualityModel.js +++ b/server/sonar-web/src/main/js/apps/about/components/AboutQualityModel.js @@ -19,9 +19,9 @@ */ import React from 'react'; import { translate } from '../../../helpers/l10n'; -import BugIcon from '../../../components/ui/BugIcon'; -import VulnerabilityIcon from '../../../components/ui/VulnerabilityIcon'; -import CodeSmellIcon from '../../../components/ui/CodeSmellIcon'; +import BugIcon from '../../../components/icons-components/BugIcon'; +import VulnerabilityIcon from '../../../components/icons-components/VulnerabilityIcon'; +import CodeSmellIcon from '../../../components/icons-components/CodeSmellIcon'; export default function AboutQualityModel() { return ( diff --git a/server/sonar-web/src/main/js/apps/about/components/EntryIssueTypes.js b/server/sonar-web/src/main/js/apps/about/components/EntryIssueTypes.js index 58bf0b7987c..eac9de1a53b 100644 --- a/server/sonar-web/src/main/js/apps/about/components/EntryIssueTypes.js +++ b/server/sonar-web/src/main/js/apps/about/components/EntryIssueTypes.js @@ -23,9 +23,9 @@ import { Link } from 'react-router'; import { formatMeasure } from '../../../helpers/measures'; import { translate } from '../../../helpers/l10n'; import { getIssuesUrl } from '../../../helpers/urls'; -import BugIcon from '../../../components/ui/BugIcon'; -import VulnerabilityIcon from '../../../components/ui/VulnerabilityIcon'; -import CodeSmellIcon from '../../../components/ui/CodeSmellIcon'; +import BugIcon from '../../../components/icons-components/BugIcon'; +import VulnerabilityIcon from '../../../components/icons-components/VulnerabilityIcon'; +import CodeSmellIcon from '../../../components/icons-components/CodeSmellIcon'; type Props = { bugs: ?number, diff --git a/server/sonar-web/src/main/js/apps/overview/main/BugsAndVulnerabilities.js b/server/sonar-web/src/main/js/apps/overview/main/BugsAndVulnerabilities.js index b0fa2c9ee06..db8f370c60f 100644 --- a/server/sonar-web/src/main/js/apps/overview/main/BugsAndVulnerabilities.js +++ b/server/sonar-web/src/main/js/apps/overview/main/BugsAndVulnerabilities.js @@ -23,8 +23,8 @@ import enhance from './enhance'; import LeakPeriodLegend from '../components/LeakPeriodLegend'; import { getMetricName } from '../helpers/metrics'; import { translate } from '../../../helpers/l10n'; -import BugIcon from '../../../components/ui/BugIcon'; -import VulnerabilityIcon from '../../../components/ui/VulnerabilityIcon'; +import BugIcon from '../../../components/icons-components/BugIcon'; +import VulnerabilityIcon from '../../../components/icons-components/VulnerabilityIcon'; class BugsAndVulnerabilities extends React.PureComponent { renderHeader() { diff --git a/server/sonar-web/src/main/js/apps/overview/main/CodeSmells.js b/server/sonar-web/src/main/js/apps/overview/main/CodeSmells.js index ee496595efd..44ef34fa0a4 100644 --- a/server/sonar-web/src/main/js/apps/overview/main/CodeSmells.js +++ b/server/sonar-web/src/main/js/apps/overview/main/CodeSmells.js @@ -25,7 +25,7 @@ import { getMetricName } from '../helpers/metrics'; import { translate, translateWithParameters } from '../../../helpers/l10n'; import { formatMeasure, isDiffMetric } from '../../../helpers/measures'; import { getComponentIssuesUrl } from '../../../helpers/urls'; -import CodeSmellIcon from '../../../components/ui/CodeSmellIcon'; +import CodeSmellIcon from '../../../components/icons-components/CodeSmellIcon'; class CodeSmells extends React.PureComponent { renderHeader() { diff --git a/server/sonar-web/src/main/js/apps/projects/components/ProjectCardLeakMeasures.js b/server/sonar-web/src/main/js/apps/projects/components/ProjectCardLeakMeasures.js index b42ea3bdd13..e55404cfe42 100644 --- a/server/sonar-web/src/main/js/apps/projects/components/ProjectCardLeakMeasures.js +++ b/server/sonar-web/src/main/js/apps/projects/components/ProjectCardLeakMeasures.js @@ -20,10 +20,10 @@ //@flow import React from 'react'; import Measure from '../../component-measures/components/Measure'; -import BugIcon from '../../../components/ui/BugIcon'; -import CodeSmellIcon from '../../../components/ui/CodeSmellIcon'; +import BugIcon from '../../../components/icons-components/BugIcon'; +import CodeSmellIcon from '../../../components/icons-components/CodeSmellIcon'; import Rating from '../../../components/ui/Rating'; -import VulnerabilityIcon from '../../../components/ui/VulnerabilityIcon'; +import VulnerabilityIcon from '../../../components/icons-components/VulnerabilityIcon'; import { translate } from '../../../helpers/l10n'; type Props = { diff --git a/server/sonar-web/src/main/js/components/ui/BugIcon.js b/server/sonar-web/src/main/js/components/icons-components/BugIcon.js index 5c794e2e080..dc1d5c7f90b 100644 --- a/server/sonar-web/src/main/js/components/ui/BugIcon.js +++ b/server/sonar-web/src/main/js/components/icons-components/BugIcon.js @@ -20,15 +20,17 @@ // @flow import React from 'react'; -export default function BugIcon({ className }: { className?: string }) { +type Props = { className?: string, size?: number }; + +export default function BugIcon({ className, size = 16 }: Props) { /* eslint-disable max-len */ return ( <svg className={className} xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" - width="16" - height="16"> + width={size} + height={size}> <path style={{ fill: 'currentColor' }} d="M11 9h1.3l.5.8.8-.5-.8-1.3H11v-.3l2-2.3V3h-1v2l-1 1.2V5c-.1-.8-.7-1.5-1.4-1.9L11 1.8l-.7-.7-1.8 1.6-1.8-1.6-.7.7 1.5 1.3C6.7 3.5 6.1 4.2 6 5v1.1L5 5V3H4v2.3l2 2.3V8H4.2l-.7 1.2.8.5.4-.7H6v.3l-2 1.9V14h1v-2.4l1-1C6 12 7.1 13 8.4 13h.8c.7 0 1.4-.3 1.8-.9.3-.4.3-.9.2-1.4l.9.9V14h1v-2.8l-2-1.9V9zm-2 2H8V6h1v5z" diff --git a/server/sonar-web/src/main/js/components/ui/CodeSmellIcon.js b/server/sonar-web/src/main/js/components/icons-components/CodeSmellIcon.js index 5a788b1066c..640a14ca39c 100644 --- a/server/sonar-web/src/main/js/components/ui/CodeSmellIcon.js +++ b/server/sonar-web/src/main/js/components/icons-components/CodeSmellIcon.js @@ -20,15 +20,17 @@ // @flow import React from 'react'; -export default function CodeSmellIcon({ className }: { className?: string }) { +type Props = { className?: string, size?: number }; + +export default function CodeSmellIcon({ className, size = 16 }: Props) { /* eslint-disable max-len */ return ( <svg className={className} xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" - width="16" - height="16"> + width={size} + height={size}> <path style={{ fill: 'currentColor' }} d="M8 2C4.7 2 2 4.7 2 8s2.7 6 6 6 6-2.7 6-6-2.7-6-6-6zm-.5 5.5h.9v.9h-.9v-.9zm-3.8.2c-.1 0-.2-.1-.2-.2 0-.4.1-1.2.6-2S5.3 4.2 5.6 4c.2 0 .3 0 .3.1l1.3 2.3c0 .1 0 .2-.1.2-.1.2-.2.3-.3.5-.1.2-.2.4-.2.5 0 .1-.1.2-.2.2l-2.7-.1zM9.9 12c-.3.2-1.1.5-2 .5-.9 0-1.7-.3-2-.5-.1 0-.1-.2-.1-.3l1.3-2.3c0-.1.1-.1.2-.1.2.1.3.1.5.1s.4 0 .5-.1c.1 0 .2 0 .2.1l1.3 2.3c.2.2.2.3.1.3zm2.5-4.1L9.7 8c-.1 0-.2-.1-.2-.2 0-.2-.1-.4-.2-.5 0-.1-.2-.3-.3-.4-.1 0-.1-.1-.1-.2l1.3-2.3c.1-.1.2-.1.3-.1.3.2 1 .7 1.5 1.5s.6 1.6.6 2c0 0-.1.1-.2.1z" diff --git a/server/sonar-web/src/main/js/components/ui/VulnerabilityIcon.js b/server/sonar-web/src/main/js/components/icons-components/VulnerabilityIcon.js index 248eae3d844..154378c6fa2 100644 --- a/server/sonar-web/src/main/js/components/ui/VulnerabilityIcon.js +++ b/server/sonar-web/src/main/js/components/icons-components/VulnerabilityIcon.js @@ -20,15 +20,17 @@ // @flow import React from 'react'; -export default function VulnerabilityIcon({ className }: { className?: string }) { +type Props = { className?: string, size?: number }; + +export default function VulnerabilityIcon({ className, size = 16 }: Props) { /* eslint-disable max-len */ return ( <svg className={className} xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" - width="16" - height="16"> + width={size} + height={size}> <path style={{ fill: 'currentColor' }} d="M10.8 5H6V3.9a2.28 2.28 0 0 1 2-2.5 2.22 2.22 0 0 1 1.8 1.2.48.48 0 0 0 .7.2.48.48 0 0 0 .2-.7A3 3 0 0 0 8 .4a3.34 3.34 0 0 0-3 3.5v1.2a2.16 2.16 0 0 0-2 2.1v4.4a2.22 2.22 0 0 0 2.2 2.2h5.6a2.22 2.22 0 0 0 2.2-2.2V7.2A2.22 2.22 0 0 0 10.8 5zm-2.2 5.5v1.2H7.4v-1.2a1.66 1.66 0 0 1-1.1-1.6A1.75 1.75 0 0 1 8 7.2a1.71 1.71 0 0 1 .6 3.3z" diff --git a/server/sonar-web/src/main/js/components/ui/IssueTypeIcon.js b/server/sonar-web/src/main/js/components/ui/IssueTypeIcon.js index 32365063111..cdd7295598f 100644 --- a/server/sonar-web/src/main/js/components/ui/IssueTypeIcon.js +++ b/server/sonar-web/src/main/js/components/ui/IssueTypeIcon.js @@ -19,9 +19,9 @@ */ // @flow import React from 'react'; -import BugIcon from './BugIcon'; -import VulnerabilityIcon from './VulnerabilityIcon'; -import CodeSmellIcon from './CodeSmellIcon'; +import BugIcon from '../icons-components/BugIcon'; +import VulnerabilityIcon from '../icons-components/VulnerabilityIcon'; +import CodeSmellIcon from '../icons-components/CodeSmellIcon'; export default class IssueTypeIcon extends React.PureComponent { props: { |