Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix linter errors #267

Open
wants to merge 1 commit into
base: next-generation
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion init-env.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import dotenv from 'dotenv'
import packageConfig from './package.json'
import dotenvExpand from 'dotenv-expand'

if(!Boolean(process.env.APP_NAME)) {
if(!process.env.APP_NAME) {
// set APP_NAME from package.json
process.env.APP_NAME = packageConfig.name
}
Expand Down
12 changes: 6 additions & 6 deletions src/app/common/forms/BaseFieldLayout.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,16 +40,16 @@ export default function BaseFieldLayout({
const formattedError = useMemo(() => Array.isArray(error) ? error[0] : error, [error])

return (
<div className='form-group'>
<div className="form-group">
{label && (
<label className='control-label'>
<label className="control-label">
{label}
{required && <span className='control-asterisk'>*</span>}
{required && <span className="control-asterisk">*</span>}
</label>
)}
<div className='control-field'>
<div className='control-element'>
{prefix && <div className='control-prefix'>{prefix}</div>}
<div className="control-field">
<div className="control-element">
{prefix && <div className="control-prefix">{prefix}</div>}
<InputComponent
required={required}
{...rest}
Expand Down
4 changes: 2 additions & 2 deletions src/app/common/forms/FormPanel.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@ export default function FormPanel(props) {
return (
<Panel defaultExpanded={isExpanded}>
<Panel.Heading>
<Panel.Title componentClass='h3' toggle={isCollapsible}>{panelTitle}</Panel.Title>
{ isCollapsible && (<Panel.Toggle componentClass='i' className='collapse-icon'></Panel.Toggle>) }
<Panel.Title componentClass="h3" toggle={isCollapsible}>{panelTitle}</Panel.Title>
{ isCollapsible && (<Panel.Toggle componentClass="i" className="collapse-icon"></Panel.Toggle>) }
</Panel.Heading>
<Panel.Body collapsible={isCollapsible} {...restProps} />
</Panel>
Expand Down
4 changes: 2 additions & 2 deletions src/app/common/forms/inputs/CheckboxInput.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,12 +34,12 @@ export default function CheckboxInput({
}) {
const handleChange = useCallback((e) => onChange(e.target.checked), [onChange])
return (
<div className='input-wrapper'>
<div className="input-wrapper">
{
<label className={inputClassName}>
<input
name={name}
type='checkbox'
type="checkbox"
checked={value === true}
value={value}
onChange={handleChange}
Expand Down
2 changes: 1 addition & 1 deletion src/app/common/forms/inputs/DateInput.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ export default function DateInput({
}) {
const handleChange = useCallback((value) => onChange(dateToValue(value, dateFormat)), [onChange])
return (
<div className='datepicker'>
<div className="datepicker">
<DatePicker
selected={valueToDate(value, dateFormat)}
onChange={handleChange}
Expand Down
2 changes: 1 addition & 1 deletion src/app/common/forms/inputs/NumberInput.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ export default function NumberInput({
return (
<input
{...props}
type='number'
type="number"
className={inputClassName}
onChange={handleChange}
/>
Expand Down
4 changes: 2 additions & 2 deletions src/app/common/forms/inputs/RadiosInput.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,14 +32,14 @@ export default function RadiosInput({
}) {
const handleChange = useCallback((e) => onChange(e.target.value), [onChange])
return (
<div className='radio-wrapper'>
<div className="radio-wrapper">
{
options.map((option) => (
<label
className={inputClassName}
key={option[valueKey]}>
<input
type='radio'
type="radio"
onChange={handleChange}
checked={value === option[valueKey]}
value={option[valueKey]}
Expand Down
2 changes: 1 addition & 1 deletion src/app/common/modals/ModalTrigger.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ export default class ModalTrigger extends Component {
let child = cloneElement(Children.only(children), { onClick: this.open, key: 'modal-control' })
return [
child,
<ModalWrapper {...this.props} show={this.state.toggled} onHide={this.close} key='modal-dialog' />,
<ModalWrapper {...this.props} show={this.state.toggled} onHide={this.close} key="modal-dialog" />,
]
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/app/common/widgets/Loading.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,5 @@ Loading.defaultProps = {
}

export default function Loading({ isLoading, children }) {
return isLoading ? <div className='loading-wrapper'>loading..</div> : children
return isLoading ? <div className="loading-wrapper">loading..</div> : children
}
8 changes: 4 additions & 4 deletions src/app/common/widgets/Wizard.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,16 +14,16 @@ export default function Wizard(props) {
const { steps, activeStepIndex } = props

return (
<nav className='steps-nav'>
<nav className="steps-nav">
{
steps.map((step, index) => (
<a
className={`item ${activeStepIndex === index ? 'active' : ''}`}
href={step.url}
key={index}>
<div className='step-item'>
<span className='number'>{ index + 1 }</span>
<span className='text'>{ step.title }</span>
<div className="step-item">
<span className="number">{ index + 1 }</span>
<span className="text">{ step.title }</span>
</div>
</a>
))
Expand Down
2 changes: 1 addition & 1 deletion src/app/layouts/Header.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ export default class Header extends Component {
render() {
return (
<header className={styles.header}>
<Link to="root"><img src={logo} alt='logo'/></Link>
<Link to="root"><img src={logo} alt="logo"/></Link>
</header>
)
}
Expand Down
4 changes: 2 additions & 2 deletions src/app/layouts/layout.scss
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

.header {
height: $header-height;
background-color: #fff;
background-color: $white;
display: flex;
justify-content: space-around;
align-items: center;
Expand All @@ -22,5 +22,5 @@
height: $footer-height;
background-color: $primary;
text-align: center;
color: #fff;
color: $white;
}
4 changes: 2 additions & 2 deletions src/styles/_variables.scss
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ $footer-height: 48px;

// Color system

$white: #fff !default;
$white: #ffffff !default;
$gray-100: #f8f9fa !default;
$gray-200: #e9ecef !default;
$gray-300: #dee2e6 !default;
Expand All @@ -21,7 +21,7 @@ $gray-600: #6c757d !default;
$gray-700: #495057 !default;
$gray-800: #343a40 !default;
$gray-900: #212529 !default;
$black: #000 !default;
$black: #000000 !default;

$blue: #007bff !default;
$indigo: #6610f2 !default;
Expand Down