Skip to content

Commit

Permalink
Only process component styles as CSS Modules
Browse files Browse the repository at this point in the history
`css-loader` now only treats `*.module.*` files as CSS Modules.
  • Loading branch information
adamkudrna committed Mar 8, 2024
1 parent 5bdd983 commit 3586fb1
Show file tree
Hide file tree
Showing 75 changed files with 65 additions and 62 deletions.
2 changes: 1 addition & 1 deletion src/components/Alert/Alert.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import {
import { transferProps } from '../_helpers/transferProps';
import { classNames } from '../../utils/classNames';
import { getRootColorClassName } from '../_helpers/getRootColorClassName';
import styles from './Alert.scss';
import styles from './Alert.module.scss';

export const Alert = ({
children,
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/components/Badge/Badge.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { withGlobalProps } from '../../provider';
import { transferProps } from '../_helpers/transferProps';
import { classNames } from '../../utils/classNames';
import { getRootColorClassName } from '../_helpers/getRootColorClassName';
import styles from './Badge.scss';
import styles from './Badge.module.scss';

export const Badge = ({
color,
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/components/Button/Button.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import { ButtonGroupContext } from '../ButtonGroup';
import { InputGroupContext } from '../InputGroup/InputGroupContext';
import getRootPriorityClassName from '../_helpers/getRootPriorityClassName';
import getRootLabelVisibilityClassName from './helpers/getRootLabelVisibilityClassName';
import styles from './Button.scss';
import styles from './Button.module.scss';

export const Button = React.forwardRef((props, ref) => {
const {
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/components/ButtonGroup/ButtonGroup.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import { classNames } from '../../utils/classNames';
import getRootPriorityClassName from '../_helpers/getRootPriorityClassName';
import { isChildrenEmpty } from '../_helpers/isChildrenEmpty';
import { transferProps } from '../_helpers/transferProps';
import styles from './ButtonGroup.scss';
import styles from './ButtonGroup.module.scss';
import { ButtonGroupContext } from './ButtonGroupContext';

export const ButtonGroup = ({
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/components/Card/Card.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { withGlobalProps } from '../../provider';
import { transferProps } from '../_helpers/transferProps';
import { classNames } from '../../utils/classNames';
import { getRootColorClassName } from '../_helpers/getRootColorClassName';
import styles from './Card.scss';
import styles from './Card.module.scss';

export const Card = ({
children,
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/components/Card/CardBody.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import PropTypes from 'prop-types';
import React from 'react';
import { withGlobalProps } from '../../provider';
import { transferProps } from '../_helpers/transferProps';
import styles from './Card.scss';
import styles from './Card.module.scss';

export const CardBody = ({
children,
Expand Down
2 changes: 1 addition & 1 deletion src/components/Card/CardFooter.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import React from 'react';
import { withGlobalProps } from '../../provider';
import { isChildrenEmpty } from '../_helpers/isChildrenEmpty';
import { transferProps } from '../_helpers/transferProps';
import styles from './Card.scss';
import styles from './Card.module.scss';

export const CardFooter = ({
children,
Expand Down
2 changes: 1 addition & 1 deletion src/components/CheckboxField/CheckboxField.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { classNames } from '../../utils/classNames';
import { getRootValidationStateClassName } from '../_helpers/getRootValidationStateClassName';
import { transferProps } from '../_helpers/transferProps';
import { FormLayoutContext } from '../FormLayout';
import styles from './CheckboxField.scss';
import styles from './CheckboxField.module.scss';

export const CheckboxField = React.forwardRef((props, ref) => {
const {
Expand Down
2 changes: 1 addition & 1 deletion src/components/FileInputField/FileInputField.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import { getRootValidationStateClassName } from '../_helpers/getRootValidationSt
import { resolveContextOrProp } from '../_helpers/resolveContextOrProp';
import { transferProps } from '../_helpers/transferProps';
import { FormLayoutContext } from '../FormLayout';
import styles from './FileInputField.scss';
import styles from './FileInputField.module.scss';

export const FileInputField = React.forwardRef((props, ref) => {
const {
Expand Down
2 changes: 1 addition & 1 deletion src/components/FormLayout/FormLayout.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { transferProps } from '../_helpers/transferProps';
import { classNames } from '../../utils/classNames';
import { isChildrenEmpty } from '../_helpers/isChildrenEmpty';
import { FormLayoutContext } from './FormLayoutContext';
import styles from './FormLayout.scss';
import styles from './FormLayout.module.scss';

const PREDEFINED_LABEL_WIDTH_VALUES = ['auto', 'default', 'limited'];

Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/components/FormLayout/FormLayoutCustomField.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import { getRootSizeClassName } from '../_helpers/getRootSizeClassName';
import { getRootValidationStateClassName } from '../_helpers/getRootValidationStateClassName';
import { isChildrenEmpty } from '../_helpers/isChildrenEmpty';
import { FormLayoutContext } from './FormLayoutContext';
import styles from './FormLayoutCustomField.scss';
import styles from './FormLayoutCustomField.module.scss';

const renderLabel = (id, label, labelForId) => {
if (labelForId && label) {
Expand Down
2 changes: 1 addition & 1 deletion src/components/Grid/Grid.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { withGlobalProps } from '../../provider';
import { isChildrenEmpty } from '../_helpers/isChildrenEmpty';
import { transferProps } from '../_helpers/transferProps';
import { generateResponsiveCustomProperties } from './_helpers/generateResponsiveCustomProperties';
import styles from './Grid.scss';
import styles from './Grid.module.scss';

const SPACING_VALUES = [0, 1, 2, 3, 4, 5, 6, 7];

Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/components/Grid/GridSpan.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { withGlobalProps } from '../../provider';
import { isChildrenEmpty } from '../_helpers/isChildrenEmpty';
import { transferProps } from '../_helpers/transferProps';
import { generateResponsiveCustomProperties } from './_helpers/generateResponsiveCustomProperties';
import styles from './Grid.scss';
import styles from './Grid.module.scss';

export const GridSpan = ({
children,
Expand Down
2 changes: 1 addition & 1 deletion src/components/InputGroup/InputGroup.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import { resolveContextOrProp } from '../_helpers/resolveContextOrProp';
import { transferProps } from '../_helpers/transferProps';
import { FormLayoutContext } from '../FormLayout';
import { InputGroupContext } from './InputGroupContext';
import styles from './InputGroup.scss';
import styles from './InputGroup.module.scss';

export const InputGroup = ({
children,
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/components/Modal/Modal.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import { getPositionClassName } from './_helpers/getPositionClassName';
import { getSizeClassName } from './_helpers/getSizeClassName';
import { useModalFocus } from './_hooks/useModalFocus';
import { useModalScrollPrevention } from './_hooks/useModalScrollPrevention';
import styles from './Modal.scss';
import styles from './Modal.module.scss';

const preRender = (
children,
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/components/Modal/ModalBody.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { transferProps } from '../_helpers/transferProps';
import { classNames } from '../../utils/classNames';
import { isChildrenEmpty } from '../_helpers/isChildrenEmpty';
import { getScrollingClassName } from './_helpers/getScrollingClassName';
import styles from './ModalBody.scss';
import styles from './ModalBody.module.scss';

export const ModalBody = ({
children,
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/components/Modal/ModalCloseButton.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import {
withGlobalProps,
} from '../../provider';
import { transferProps } from '../_helpers/transferProps';
import styles from './ModalCloseButton.scss';
import styles from './ModalCloseButton.module.scss';

export const ModalCloseButton = React.forwardRef((props, ref) => {
const {
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/components/Modal/ModalContent.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import React from 'react';
import { withGlobalProps } from '../../provider';
import { isChildrenEmpty } from '../_helpers/isChildrenEmpty';
import { transferProps } from '../_helpers/transferProps';
import styles from './ModalContent.scss';
import styles from './ModalContent.module.scss';

export const ModalContent = ({
children,
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/components/Modal/ModalFooter.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { withGlobalProps } from '../../provider';
import { transferProps } from '../_helpers/transferProps';
import { classNames } from '../../utils/classNames';
import { getJustifyClassName } from './_helpers/getJustifyClassName';
import styles from './ModalFooter.scss';
import styles from './ModalFooter.module.scss';

export const ModalFooter = ({
children,
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/components/Modal/ModalHeader.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import {
import { transferProps } from '../_helpers/transferProps';
import { classNames } from '../../utils/classNames';
import { getJustifyClassName } from './_helpers/getJustifyClassName';
import styles from './ModalHeader.scss';
import styles from './ModalHeader.module.scss';

export const ModalHeader = ({
children,
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/components/Modal/ModalTitle.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import {
withGlobalProps,
} from '../../provider';
import { transferProps } from '../_helpers/transferProps';
import styles from './ModalTitle.scss';
import styles from './ModalTitle.module.scss';

export const ModalTitle = ({
children,
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/components/Paper/Paper.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import React from 'react';
import { withGlobalProps } from '../../provider';
import { classNames } from '../../utils/classNames';
import { transferProps } from '../_helpers/transferProps';
import styles from './Paper.scss';
import styles from './Paper.module.scss';

export const Paper = ({
children,
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/components/Popover/Popover.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import { classNames } from '../../utils/classNames';
import { transferProps } from '../_helpers/transferProps';
import getRootSideClassName from './_helpers/getRootSideClassName';
import getRootAlignmentClassName from './_helpers/getRootAlignmentClassName';
import styles from './Popover.scss';
import styles from './Popover.module.scss';

export const Popover = React.forwardRef((props, ref) => {
const {
Expand Down
File renamed without changes.
3 changes: 1 addition & 2 deletions src/components/Popover/PopoverWrapper.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import PropTypes from 'prop-types';
import React from 'react';
import { withGlobalProps } from '../../provider';
import { transferProps } from '../_helpers/transferProps';
import styles from './PopoverWrapper.scss';
import styles from './PopoverWrapper.module.scss';

export const PopoverWrapper = ({
children,
Expand Down Expand Up @@ -36,4 +36,3 @@ PopoverWrapper.propTypes = {
export const PopoverWrapperWithContext = withGlobalProps(PopoverWrapper, 'PopoverWrapper');

export default PopoverWrapperWithContext;

File renamed without changes.
2 changes: 1 addition & 1 deletion src/components/Radio/Radio.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import { getRootValidationStateClassName } from '../_helpers/getRootValidationSt
import { resolveContextOrProp } from '../_helpers/resolveContextOrProp';
import { transferProps } from '../_helpers/transferProps';
import { FormLayoutContext } from '../FormLayout';
import styles from './Radio.scss';
import styles from './Radio.module.scss';

export const Radio = ({
disabled,
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/components/ScrollView/ScrollView.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ import { transferProps } from '../_helpers/transferProps';
import { getElementsPositionDifference } from './_helpers/getElementsPositionDifference';
import { useLoadResize } from './_hooks/useLoadResizeHook';
import { useScrollPosition } from './_hooks/useScrollPositionHook';
import styles from './ScrollView.scss';
import styles from './ScrollView.module.scss';

// Function `getElementsPositionDifference` sometimes returns floating point values that results
// in inaccurate detection of start/end. It is necessary to accept this inaccuracy and take
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/components/SelectField/SelectField.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import { transferProps } from '../_helpers/transferProps';
import { FormLayoutContext } from '../FormLayout';
import { InputGroupContext } from '../InputGroup/InputGroupContext';
import { Option } from './_components/Option';
import styles from './SelectField.scss';
import styles from './SelectField.module.scss';

export const SelectField = React.forwardRef((props, ref) => {
const {
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/components/Table/Table.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { withGlobalProps } from '../../provider';
import { transferProps } from '../_helpers/transferProps';
import { TableHeaderCell } from './_components/TableHeaderCell';
import { TableBodyCell } from './_components/TableBodyCell';
import styles from './Table.scss';
import styles from './Table.module.scss';

export const Table = ({
columns,
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/components/Tabs/Tabs.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import PropTypes from 'prop-types';
import React from 'react';
import { withGlobalProps } from '../../provider';
import { transferProps } from '../_helpers/transferProps';
import styles from './Tabs.scss';
import styles from './Tabs.module.scss';

export const Tabs = ({
children,
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/components/Tabs/TabsItem.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import React from 'react';
import { withGlobalProps } from '../../provider';
import { transferProps } from '../_helpers/transferProps';
import { classNames } from '../../utils/classNames';
import styles from './TabsItem.scss';
import styles from './TabsItem.module.scss';

export const TabsItem = ({
afterLabel,
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/components/Text/Text.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import { isChildrenEmpty } from '../_helpers/isChildrenEmpty';
import { getRootClampClassName } from './_helpers/getRootClampClassName';
import { getRootHyphensClassName } from './_helpers/getRootHyphensClassName';
import { getRootWordWrappingClassName } from './_helpers/getRootWordWrappingClassName';
import styles from './Text.scss';
import styles from './Text.module.scss';

export const Text = ({
blockLevel,
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/components/TextArea/TextArea.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import { getRootValidationStateClassName } from '../_helpers/getRootValidationSt
import { resolveContextOrProp } from '../_helpers/resolveContextOrProp';
import { transferProps } from '../_helpers/transferProps';
import { FormLayoutContext } from '../FormLayout';
import styles from './TextArea.scss';
import styles from './TextArea.module.scss';

export const TextArea = React.forwardRef((props, ref) => {
const {
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/components/TextField/TextField.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import { resolveContextOrProp } from '../_helpers/resolveContextOrProp';
import { transferProps } from '../_helpers/transferProps';
import { FormLayoutContext } from '../FormLayout';
import { InputGroupContext } from '../InputGroup/InputGroupContext';
import styles from './TextField.scss';
import styles from './TextField.module.scss';

const SMALL_INPUT_SIZE = 10;

Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/components/TextLink/TextLink.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import PropTypes from 'prop-types';
import React from 'react';
import { withGlobalProps } from '../../provider';
import { transferProps } from '../_helpers/transferProps';
import styles from './TextLink.scss';
import styles from './TextLink.module.scss';

export const TextLink = ({
href,
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/components/Toggle/Toggle.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { classNames } from '../../utils/classNames';
import { getRootValidationStateClassName } from '../_helpers/getRootValidationStateClassName';
import { transferProps } from '../_helpers/transferProps';
import { FormLayoutContext } from '../FormLayout';
import styles from './Toggle.scss';
import styles from './Toggle.module.scss';

export const Toggle = React.forwardRef((props, ref) => {
const {
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/components/Toolbar/Toolbar.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import { classNames } from '../../utils/classNames';
import { isChildrenEmpty } from '../_helpers/isChildrenEmpty';
import { getAlignClassName } from './_helpers/getAlignClassName';
import { getJustifyClassName } from './_helpers/getJustifyClassName';
import styles from './Toolbar.scss';
import styles from './Toolbar.module.scss';

export const Toolbar = ({
align,
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/components/Toolbar/ToolbarGroup.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { transferProps } from '../_helpers/transferProps';
import { classNames } from '../../utils/classNames';
import { isChildrenEmpty } from '../_helpers/isChildrenEmpty';
import { getAlignClassName } from './_helpers/getAlignClassName';
import styles from './Toolbar.scss';
import styles from './Toolbar.module.scss';

export const ToolbarGroup = ({
align,
Expand Down
2 changes: 1 addition & 1 deletion src/components/Toolbar/ToolbarItem.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { transferProps } from '../_helpers/transferProps';
import { classNames } from '../../utils/classNames';
import { withGlobalProps } from '../../provider';
import { isChildrenEmpty } from '../_helpers/isChildrenEmpty';
import styles from './Toolbar.scss';
import styles from './Toolbar.module.scss';

export const ToolbarItem = ({
children,
Expand Down
Loading

0 comments on commit 3586fb1

Please sign in to comment.