Skip to content

Commit

Permalink
fix: move logos to scss to fix build errors
Browse files Browse the repository at this point in the history
  • Loading branch information
prototypicalpro committed Oct 30, 2020
1 parent ed75ce3 commit fef30a7
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 7 deletions.
8 changes: 5 additions & 3 deletions .extended-webpackrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,16 @@ module.exports = {
module: {
rules: [
{
test: /\.(png|jpe?g|gif)$/,
test: /\.(png|jpe?g|gif|svg|eot|ttf|woff2?)$/,
use: [
{
loader: 'file-loader',
options: {},
options: {

},
},
],
},
}
],
},
};
4 changes: 1 addition & 3 deletions nerdlets/maintainer-dashboard/components/issueTable.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,6 @@ import filterFactory, {
} from 'react-bootstrap-table2-filter';
import { Button, Icon } from 'nr1';
import IssueLabel from './issueLabel';
import PullRequestLogo from '../img/git-pull-request-16.svg';
import IssueLogo from '../img/issue-opened-16.svg';

/**
* Implementation of a Issue/PR list using react-bootstrap-table2. Includes
Expand Down Expand Up @@ -65,7 +63,7 @@ export default class IssueTable extends React.PureComponent {
sortCaret,
formatter: (cell) => (
<img
src={cell === 'Issue' ? IssueLogo : PullRequestLogo}
className={cell === 'Issue' ? 'ospo-issue-logo' : 'ospo-pr-logo'}
style={{ marginRight: '40px' }}
/>
),
Expand Down
8 changes: 8 additions & 0 deletions nerdlets/maintainer-dashboard/styles.scss
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,14 @@ $img-path: '~react-widgets/lib/img';
display: none;
}

.ospo-issue-logo {
content: url('./img/issue-opened-16.svg');
}

.ospo-pr-logo {
content: url('./img/git-pull-request-16.svg');
}

#root {
overflow: visible;
}
Expand Down
2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit fef30a7

Please sign in to comment.