nexxtway/react-rainbow

View on GitHub

Showing 2,739 of 2,739 total issues

Similar blocks of code found in 3 locations. Consider refactoring.
Open

const Checkbox = attachThemeAttrs(styled(HiddenElement))`
    & ~ label > .rainbow-input_faux {
        width: 20px;
        height: 20px;
        display: inline-block;
Severity: Major
Found in src/components/Input/inputCheckbox/styled/checkbox.js and 2 other locations - About 40 mins to fix
src/components/FileSelector/styled/index.js on lines 29..141
src/components/Textarea/styled/textarea.js on lines 10..141

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 49.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

                    <StyledArrowButton
                        onClick={selectNextWeek}
                        variant="border-filled"
                        size="small"
                        disabled={isDisableNext}
Severity: Minor
Found in src/components/WeeklyCalendar/index.js and 1 other location - About 40 mins to fix
src/components/WeeklyCalendar/index.js on lines 73..80

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 49.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

    it('should return false when the row is not selected but maxRowSelection 1', () => {
        expect(
            isDisabledRow({
                rowKeyValue: 'row-2',
                maxRowSelection: 1,
src/components/Table/helpers/selector/__test__/isDisabledRow.spec.js on lines 27..35

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 49.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

    it('should return false when the row is not selected, maxRowSelection is not 1 and does not match with selectedRowKeys length', () => {
        expect(
            isDisabledRow({
                rowKeyValue: 'row-2',
                maxRowSelection: 2,
src/components/Table/helpers/selector/__test__/isDisabledRow.spec.js on lines 18..26

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 49.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

const StyledCheckboxContainer = styled.div`
    align-items: center;
    display: flex;
    padding: 0 15px;
    border: 1px solid transparent;
Severity: Minor
Found in src/components/Table/body/styled/checkboxContainer.js and 1 other location - About 40 mins to fix
src/components/Table/head/styled/checkboxWrapper.js on lines 3..13

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 49.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

                    <StyledArrowButton
                        onClick={selectPreviousWeek}
                        variant="border-filled"
                        size="small"
                        disabled={isDisablePrevious}
Severity: Minor
Found in src/components/WeeklyCalendar/index.js and 1 other location - About 40 mins to fix
src/components/WeeklyCalendar/index.js on lines 82..89

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 49.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

const StyledCheckboxWrapper = styled.div`
    align-items: center;
    display: flex;
    padding: 10px 15px;
    border: 1px solid transparent;
Severity: Minor
Found in src/components/Table/head/styled/checkboxWrapper.js and 1 other location - About 40 mins to fix
src/components/Table/body/styled/checkboxContainer.js on lines 3..14

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 49.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 17 locations. Consider refactoring.
Open

const StyledTitle = attachThemeAttrs(styled.h2)`
    font-size: ${FONT_SIZE_HEADING_MEDIUM};
    font-weight: 500;
    color: ${props => props.palette.text.title};
    overflow: hidden;
Severity: Major
Found in src/components/Card/styled/title.js and 16 other locations - About 40 mins to fix
src/components/Calendar/doubleCalendar/styled/index.js on lines 64..72
src/components/Calendar/styled/month.js on lines 5..13
src/components/CarouselImage/styled/footerDescription.js on lines 5..11
src/components/CarouselImage/styled/footerTitle.js on lines 5..12
src/components/GMap/styled/header.js on lines 5..11
src/components/Lookup/options/styled/content.js on lines 5..11
src/components/MapMarker/styled/label.js on lines 5..9
src/components/MapMarker/styled/textContainer.js on lines 5..10
src/components/MenuItem/styled/headerLabel.js on lines 5..12
src/components/Option/styled/headerLabel.js on lines 5..10
src/components/ProgressStep/styled/activeIcon.js on lines 5..11
src/components/Table/body/styled/emptyIcon.js on lines 5..8
src/components/Table/body/styled/emptyTitle.js on lines 5..12
src/components/VisualPickerOptionFooter/styled/description.js on lines 5..12
src/components/VisualPickerOptionFooter/styled/label.js on lines 5..12
src/components/WeeklyCalendar/styled/title.js on lines 5..16

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 48.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 17 locations. Consider refactoring.
Open

const StyledLabel = attachThemeAttrs(styled.span)`
    font-size: ${FONT_SIZE_TEXT_MEDIUM};
    color: ${props => props.palette.text.main};
    display: block;
`;
Severity: Major
Found in src/components/MapMarker/styled/label.js and 16 other locations - About 40 mins to fix
src/components/Calendar/doubleCalendar/styled/index.js on lines 64..72
src/components/Calendar/styled/month.js on lines 5..13
src/components/Card/styled/title.js on lines 5..14
src/components/CarouselImage/styled/footerDescription.js on lines 5..11
src/components/CarouselImage/styled/footerTitle.js on lines 5..12
src/components/GMap/styled/header.js on lines 5..11
src/components/Lookup/options/styled/content.js on lines 5..11
src/components/MapMarker/styled/textContainer.js on lines 5..10
src/components/MenuItem/styled/headerLabel.js on lines 5..12
src/components/Option/styled/headerLabel.js on lines 5..10
src/components/ProgressStep/styled/activeIcon.js on lines 5..11
src/components/Table/body/styled/emptyIcon.js on lines 5..8
src/components/Table/body/styled/emptyTitle.js on lines 5..12
src/components/VisualPickerOptionFooter/styled/description.js on lines 5..12
src/components/VisualPickerOptionFooter/styled/label.js on lines 5..12
src/components/WeeklyCalendar/styled/title.js on lines 5..16

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 48.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 13 locations. Consider refactoring.
Open

const StyledDay = attachThemeAttrs(styled.td)`
    text-align: center;
    color: ${props => props.palette.text.main};
    font-size: ${FONT_SIZE_TEXT_MEDIUM};
    font-weight: 400;
Severity: Major
Found in src/components/Calendar/styled/day.js and 12 other locations - About 40 mins to fix
src/components/Calendar/styled/headerDays.js on lines 5..14
src/components/DatePickerModal/styled/index.js on lines 51..58
src/components/Drawer/styled/title.js on lines 5..18
src/components/MonthlyCalendar/styled/dayAdjacent.js on lines 5..18
src/components/MonthlyCalendar/styled/dayLabel.js on lines 5..11
src/components/PhoneInput/countriesDropdown/styled/search.js on lines 5..23
src/components/TimePicker/styled/dots.js on lines 5..18
src/components/TimePicker/styled/selectContent.js on lines 5..20
src/components/TimelineMarker/styled/label.js on lines 5..12
src/components/WeeklyCalendar/header/styled/hours.js on lines 5..14
src/components/WeeklyCalendar/styled/clock.js on lines 5..13
src/components/WeeklyCalendar/styled/hour.js on lines 5..17

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 48.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 13 locations. Consider refactoring.
Open

const StyledHours = attachThemeAttrs(styled.h4)`
    flex:none;
    text-align: center;
    color: ${props => props.palette.text.main};
    min-width: 64px;
Severity: Major
Found in src/components/WeeklyCalendar/header/styled/hours.js and 12 other locations - About 40 mins to fix
src/components/Calendar/styled/day.js on lines 5..14
src/components/Calendar/styled/headerDays.js on lines 5..14
src/components/DatePickerModal/styled/index.js on lines 51..58
src/components/Drawer/styled/title.js on lines 5..18
src/components/MonthlyCalendar/styled/dayAdjacent.js on lines 5..18
src/components/MonthlyCalendar/styled/dayLabel.js on lines 5..11
src/components/PhoneInput/countriesDropdown/styled/search.js on lines 5..23
src/components/TimePicker/styled/dots.js on lines 5..18
src/components/TimePicker/styled/selectContent.js on lines 5..20
src/components/TimelineMarker/styled/label.js on lines 5..12
src/components/WeeklyCalendar/styled/clock.js on lines 5..13
src/components/WeeklyCalendar/styled/hour.js on lines 5..17

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 48.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 13 locations. Consider refactoring.
Open

const StyledDots = attachThemeAttrs(styled.span)`
    font-size: 32px;
    font-weight: 200;
    height: 100%;
    color: ${props => props.palette.brand.main};
Severity: Major
Found in src/components/TimePicker/styled/dots.js and 12 other locations - About 40 mins to fix
src/components/Calendar/styled/day.js on lines 5..14
src/components/Calendar/styled/headerDays.js on lines 5..14
src/components/DatePickerModal/styled/index.js on lines 51..58
src/components/Drawer/styled/title.js on lines 5..18
src/components/MonthlyCalendar/styled/dayAdjacent.js on lines 5..18
src/components/MonthlyCalendar/styled/dayLabel.js on lines 5..11
src/components/PhoneInput/countriesDropdown/styled/search.js on lines 5..23
src/components/TimePicker/styled/selectContent.js on lines 5..20
src/components/TimelineMarker/styled/label.js on lines 5..12
src/components/WeeklyCalendar/header/styled/hours.js on lines 5..14
src/components/WeeklyCalendar/styled/clock.js on lines 5..13
src/components/WeeklyCalendar/styled/hour.js on lines 5..17

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 48.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 11 locations. Consider refactoring.
Open

    const { className, style, value, overlap, children, variant, isHidden, position } = props;
Severity: Major
Found in src/components/BadgeOverlay/index.js and 10 other locations - About 40 mins to fix
src/components/CurrencyInput/hooks/useOptions.js on lines 4..13
src/components/Badge/index.js on lines 10..10
src/components/Calendar/week.js on lines 8..17
src/components/Chip/index.js on lines 19..19
src/components/ColorPicker/index.js on lines 13..13
src/components/HelpText/index.js on lines 45..45
src/components/MultiSelect/content.js on lines 8..8
src/components/RadioButtonGroup/buttonItems.js on lines 6..6
src/components/Sidebar/index.js on lines 14..23
src/components/Spinner/index.js on lines 14..14

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 48.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 17 locations. Consider refactoring.
Open

const StyledHeaderLabel = attachThemeAttrs(styled.span)`
    font-size: ${FONT_SIZE_TEXT_MEDIUM};
    color: ${props => props.palette.text.header};
    font-weight: normal;
    text-transform: uppercase;
Severity: Major
Found in src/components/Option/styled/headerLabel.js and 16 other locations - About 40 mins to fix
src/components/Calendar/doubleCalendar/styled/index.js on lines 64..72
src/components/Calendar/styled/month.js on lines 5..13
src/components/Card/styled/title.js on lines 5..14
src/components/CarouselImage/styled/footerDescription.js on lines 5..11
src/components/CarouselImage/styled/footerTitle.js on lines 5..12
src/components/GMap/styled/header.js on lines 5..11
src/components/Lookup/options/styled/content.js on lines 5..11
src/components/MapMarker/styled/label.js on lines 5..9
src/components/MapMarker/styled/textContainer.js on lines 5..10
src/components/MenuItem/styled/headerLabel.js on lines 5..12
src/components/ProgressStep/styled/activeIcon.js on lines 5..11
src/components/Table/body/styled/emptyIcon.js on lines 5..8
src/components/Table/body/styled/emptyTitle.js on lines 5..12
src/components/VisualPickerOptionFooter/styled/description.js on lines 5..12
src/components/VisualPickerOptionFooter/styled/label.js on lines 5..12
src/components/WeeklyCalendar/styled/title.js on lines 5..16

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 48.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 13 locations. Consider refactoring.
Open

const StyledLabel = attachThemeAttrs(styled.h1)`
    margin: 0;
    padding: 0;
    font-weight: inherit;
    color: ${props => props.palette.text.main};
Severity: Major
Found in src/components/TimelineMarker/styled/label.js and 12 other locations - About 40 mins to fix
src/components/Calendar/styled/day.js on lines 5..14
src/components/Calendar/styled/headerDays.js on lines 5..14
src/components/DatePickerModal/styled/index.js on lines 51..58
src/components/Drawer/styled/title.js on lines 5..18
src/components/MonthlyCalendar/styled/dayAdjacent.js on lines 5..18
src/components/MonthlyCalendar/styled/dayLabel.js on lines 5..11
src/components/PhoneInput/countriesDropdown/styled/search.js on lines 5..23
src/components/TimePicker/styled/dots.js on lines 5..18
src/components/TimePicker/styled/selectContent.js on lines 5..20
src/components/WeeklyCalendar/header/styled/hours.js on lines 5..14
src/components/WeeklyCalendar/styled/clock.js on lines 5..13
src/components/WeeklyCalendar/styled/hour.js on lines 5..17

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 48.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 13 locations. Consider refactoring.
Open

const StyledSelectContent = attachThemeAttrs(styled.div)`
    height: 100px;
    width: 360px;
    display: flex;
    align-items: center;
Severity: Major
Found in src/components/TimePicker/styled/selectContent.js and 12 other locations - About 40 mins to fix
src/components/Calendar/styled/day.js on lines 5..14
src/components/Calendar/styled/headerDays.js on lines 5..14
src/components/DatePickerModal/styled/index.js on lines 51..58
src/components/Drawer/styled/title.js on lines 5..18
src/components/MonthlyCalendar/styled/dayAdjacent.js on lines 5..18
src/components/MonthlyCalendar/styled/dayLabel.js on lines 5..11
src/components/PhoneInput/countriesDropdown/styled/search.js on lines 5..23
src/components/TimePicker/styled/dots.js on lines 5..18
src/components/TimelineMarker/styled/label.js on lines 5..12
src/components/WeeklyCalendar/header/styled/hours.js on lines 5..14
src/components/WeeklyCalendar/styled/clock.js on lines 5..13
src/components/WeeklyCalendar/styled/hour.js on lines 5..17

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 48.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 17 locations. Consider refactoring.
Open

const StyledActiveIcon = attachThemeAttrs(styled.div)`
    width: 1.25rem;
    height: 1.25rem;
    border-radius: ${BORDER_RADIUS_2};
    border: 0.375rem solid ${props => props.palette.brand.main};
Severity: Major
Found in src/components/ProgressStep/styled/activeIcon.js and 16 other locations - About 40 mins to fix
src/components/Calendar/doubleCalendar/styled/index.js on lines 64..72
src/components/Calendar/styled/month.js on lines 5..13
src/components/Card/styled/title.js on lines 5..14
src/components/CarouselImage/styled/footerDescription.js on lines 5..11
src/components/CarouselImage/styled/footerTitle.js on lines 5..12
src/components/GMap/styled/header.js on lines 5..11
src/components/Lookup/options/styled/content.js on lines 5..11
src/components/MapMarker/styled/label.js on lines 5..9
src/components/MapMarker/styled/textContainer.js on lines 5..10
src/components/MenuItem/styled/headerLabel.js on lines 5..12
src/components/Option/styled/headerLabel.js on lines 5..10
src/components/Table/body/styled/emptyIcon.js on lines 5..8
src/components/Table/body/styled/emptyTitle.js on lines 5..12
src/components/VisualPickerOptionFooter/styled/description.js on lines 5..12
src/components/VisualPickerOptionFooter/styled/label.js on lines 5..12
src/components/WeeklyCalendar/styled/title.js on lines 5..16

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 48.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 17 locations. Consider refactoring.
Open

const StyledFooterDescription = attachThemeAttrs(styled.p)`
    font-size: ${FONT_SIZE_TEXT_SMALL};
    font-weight: 400;
    color: ${props => props.palette.text.main};
    margin: 0;
Severity: Major
Found in src/components/CarouselImage/styled/footerDescription.js and 16 other locations - About 40 mins to fix
src/components/Calendar/doubleCalendar/styled/index.js on lines 64..72
src/components/Calendar/styled/month.js on lines 5..13
src/components/Card/styled/title.js on lines 5..14
src/components/CarouselImage/styled/footerTitle.js on lines 5..12
src/components/GMap/styled/header.js on lines 5..11
src/components/Lookup/options/styled/content.js on lines 5..11
src/components/MapMarker/styled/label.js on lines 5..9
src/components/MapMarker/styled/textContainer.js on lines 5..10
src/components/MenuItem/styled/headerLabel.js on lines 5..12
src/components/Option/styled/headerLabel.js on lines 5..10
src/components/ProgressStep/styled/activeIcon.js on lines 5..11
src/components/Table/body/styled/emptyIcon.js on lines 5..8
src/components/Table/body/styled/emptyTitle.js on lines 5..12
src/components/VisualPickerOptionFooter/styled/description.js on lines 5..12
src/components/VisualPickerOptionFooter/styled/label.js on lines 5..12
src/components/WeeklyCalendar/styled/title.js on lines 5..16

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 48.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 11 locations. Consider refactoring.
Open

    const {
        value,
        startDate,
        endDate,
        minDate,
Severity: Major
Found in src/components/Calendar/week.js and 10 other locations - About 40 mins to fix
src/components/CurrencyInput/hooks/useOptions.js on lines 4..13
src/components/Badge/index.js on lines 10..10
src/components/BadgeOverlay/index.js on lines 14..14
src/components/Chip/index.js on lines 19..19
src/components/ColorPicker/index.js on lines 13..13
src/components/HelpText/index.js on lines 45..45
src/components/MultiSelect/content.js on lines 8..8
src/components/RadioButtonGroup/buttonItems.js on lines 6..6
src/components/Sidebar/index.js on lines 14..23
src/components/Spinner/index.js on lines 14..14

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 48.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 11 locations. Consider refactoring.
Open

    const {
        ariaLabel,
        style,
        selectedItem,
        onSelect,
Severity: Major
Found in src/components/Sidebar/index.js and 10 other locations - About 40 mins to fix
src/components/CurrencyInput/hooks/useOptions.js on lines 4..13
src/components/Badge/index.js on lines 10..10
src/components/BadgeOverlay/index.js on lines 14..14
src/components/Calendar/week.js on lines 8..17
src/components/Chip/index.js on lines 19..19
src/components/ColorPicker/index.js on lines 13..13
src/components/HelpText/index.js on lines 45..45
src/components/MultiSelect/content.js on lines 8..8
src/components/RadioButtonGroup/buttonItems.js on lines 6..6
src/components/Spinner/index.js on lines 14..14

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 48.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Severity
Category
Status
Source
Language