Skip to content

Commit 474e44c

Browse files
Findmitreyalexanderrudnik
authored andcommitted
fix(lint): update theme after rebase
1 parent f7e6993 commit 474e44c

File tree

41 files changed

+261
-169
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

41 files changed

+261
-169
lines changed

src/App.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ import deDe from 'antd/lib/locale/de_DE';
44
import enUS from 'antd/lib/locale/en_US';
55
import GlobalStyle from './styles/GlobalStyle';
66
import 'typeface-montserrat';
7-
import { darkTheme } from '@app/styles/themes/dark/darkTheme';
7+
import 'typeface-lato';
88
import { AppRouter } from './components/router/AppRouter';
99
import { useLanguage } from './hooks/useLanguage';
1010
import { useAutoNightMode } from './hooks/useAutoNightMode';

src/components/apps/kanban/newCardForm/TagDropdown/TagDropdown.tsx

-1
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,6 @@ export const TagDropdown: React.FC<TagDropdownProps> = ({ selectedTags, setSelec
2727
setSelectedTags([...selectedTags, tag]);
2828
}
2929
};
30-
console.log('selectedTags', selectedTags);
3130

3231
return (
3332
<Dropdown

src/components/common/ArticleCard/ArticleCard.styles.ts

+4-1
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,13 @@ export const Wrapper = styled.div`
2222
position: relative;
2323
max-width: 42.5rem;
2424
box-shadow: var(--box-shadow);
25-
background: ${(props) => props.theme.name === 'dark' && props.theme.colors.main.secondaryBackground};
2625
border-radius: ${BORDER_RADIUS};
2726
transition: 0.3s;
2827
28+
[data-theme='dark'] & {
29+
background: var(--secondary-background-color);
30+
}
31+
2932
&:hover {
3033
box-shadow: var(--box-shadow-hover);
3134
}

src/components/common/Card/Card.styles.ts

-2
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,10 @@ import styled from 'styled-components';
22
import { Card as AntCard } from 'antd';
33
import { normalizeProp } from 'utils/utils';
44
import { FONT_SIZE, FONT_WEIGHT, media } from '@app/styles/themes/constants';
5-
import { ThemeType } from '@app/interfaces/interfaces';
65

76
interface CardInternalProps {
87
$padding: string | number | [number, number];
98
$autoHeight: boolean;
10-
$theme: ThemeType;
119
}
1210

1311
export const Card = styled(AntCard)<CardInternalProps>`

src/components/common/Card/Card.tsx

-4
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ import { CardProps as AntCardProps } from 'antd';
33
import { defaultPaddings } from '@app/constants/defaultPaddings';
44
import { useResponsive } from '@app/hooks/useResponsive';
55
import * as S from './Card.styles';
6-
import { useAppSelector } from '@app/hooks/reduxHooks';
76

87
export interface CardProps extends AntCardProps {
98
className?: string;
@@ -14,8 +13,6 @@ export interface CardProps extends AntCardProps {
1413
export const Card: React.FC<CardProps> = ({ className, padding, size, autoHeight = true, children, ...props }) => {
1514
const { isTablet, isDesktop } = useResponsive();
1615

17-
const theme = useAppSelector((state) => state.theme.theme);
18-
1916
return (
2017
<S.Card
2118
size={size ? size : isTablet ? 'default' : 'small'}
@@ -27,7 +24,6 @@ export const Card: React.FC<CardProps> = ({ className, padding, size, autoHeight
2724
: (isDesktop && defaultPaddings.desktop) || (isTablet && defaultPaddings.tablet) || defaultPaddings.mobile
2825
}
2926
$autoHeight={autoHeight}
30-
$theme={theme}
3127
{...props}
3228
>
3329
{children}

src/components/common/Checkbox/Checkbox.styles.ts

+4
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,10 @@ export const Checkbox = styled(AntdCheckbox)`
1414
.ant-checkbox-disabled.ant-checkbox-checked .ant-checkbox-inner::after {
1515
border-color: var(--disabled-color);
1616
}
17+
18+
.ant-checkbox-disabled + span {
19+
color: var(--disabled-color);
20+
}
1721
`;
1822

1923
export const CheckboxGroup = styled(Group)`
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,8 @@
11
import styled from 'styled-components';
22
import { Slider as AntdSlider } from 'antd';
33

4-
export const Slider = styled(AntdSlider)``;
4+
export const Slider = styled(AntdSlider)`
5+
& .ant-slider-mark-text:not(.ant-slider-mark-text-active) {
6+
color: var(--subtext-color);
7+
}
8+
`;

src/components/common/Steps/Steps.styles.ts

+7-3
Original file line numberDiff line numberDiff line change
@@ -49,9 +49,13 @@ export const Steps = styled(AntdSteps)`
4949
}
5050
}
5151
& .ant-steps-item {
52-
&-description,
53-
&-subtitle {
54-
color: var(--disabled-color) !important;
52+
&:not(.ant-steps-item-process) {
53+
.ant-steps-item-description {
54+
color: var(--subtext-color);
55+
}
56+
}
57+
.ant-steps-item-subtitle {
58+
color: var(--subtext-color);
5559
}
5660
}
5761
`;

src/components/common/Table/Table.styles.ts

+18
Original file line numberDiff line numberDiff line change
@@ -67,4 +67,22 @@ export const Table = styled(AntdTable)`
6767
.ant-table-column-sort {
6868
background-color: transparent;
6969
}
70+
71+
.ant-pagination-item-container .ant-pagination-item-ellipsis {
72+
color: var(--disabled-color);
73+
}
74+
75+
.ant-pagination-disabled {
76+
.ant-pagination-item-link,
77+
.ant-pagination-item a {
78+
color: var(--disabled-color);
79+
}
80+
}
81+
82+
.ant-pagination.ant-pagination-disabled {
83+
.ant-pagination-item-link,
84+
.ant-pagination-item a {
85+
color: var(--disabled-color);
86+
}
87+
}
7088
`;

src/components/common/buttons/Button/Button.styles.ts

+13-13
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,9 @@ export const Button = styled(AntButton)<BtnProps>`
1717
${(props) =>
1818
props.$noStyle &&
1919
css`
20-
width: unset !important;
21-
padding: 0 !important;
22-
height: unset !important;
20+
width: unset;
21+
padding: 0;
22+
height: unset;
2323
`}
2424
2525
&[disabled],
@@ -35,26 +35,26 @@ export const Button = styled(AntButton)<BtnProps>`
3535
css`
3636
box-shadow: none;
3737
text-shadow: none;
38-
background: rgba(${defineColorBySeverity(props.$severity, true)}, 0.2) !important;
38+
background: rgba(${defineColorBySeverity(props.$severity, true)}, 0.2);
3939
40-
border-color: ${defineColorBySeverity(props.$severity)} !important;
40+
border-color: ${defineColorBySeverity(props.$severity)};
4141
42-
color: ${defineColorBySeverity(props.$severity)} !important;
42+
color: ${defineColorBySeverity(props.$severity)};
4343
4444
&:hover {
45-
background: var(--background-color) !important;
45+
background: var(--background-color);
4646
47-
border-color: rgba(${defineColorBySeverity(props.$severity, true)}, 0.9) !important;
47+
border-color: rgba(${defineColorBySeverity(props.$severity, true)}, 0.9);
4848
49-
color: rgba(${defineColorBySeverity(props.$severity, true)}, 0.9) !important;
49+
color: rgba(${defineColorBySeverity(props.$severity, true)}, 0.9);
5050
}
5151
5252
&:focus {
53-
background: var(--background-color) !important;
53+
background: var(--background-color);
5454
55-
border-color: rgba(${defineColorBySeverity(props.$severity, true)}, 0.9) !important;
55+
border-color: rgba(${defineColorBySeverity(props.$severity, true)}, 0.9);
5656
57-
color: rgba(${defineColorBySeverity(props.$severity, true)}, 0.9) !important;
57+
color: rgba(${defineColorBySeverity(props.$severity, true)}, 0.9);
5858
}
5959
`}
6060
@@ -77,7 +77,7 @@ export const Button = styled(AntButton)<BtnProps>`
7777
7878
${props.type === 'primary' &&
7979
css`
80-
background: ${(props) => props.theme.colors.main.primaryGradient};
80+
background: var(--primary-gradient-color);
8181
8282
&:hover {
8383
background: var(--secondary-color);

src/components/common/selects/Select/Select.styles.ts

+3
Original file line numberDiff line numberDiff line change
@@ -55,4 +55,7 @@ export const Select = styled(AntSelect).withConfig({
5555
color: var(--icon-hover-color);
5656
}
5757
}
58+
.ant-select-item-option-disabled {
59+
color: var(--disabled-color);
60+
}
5861
`;

src/components/forms/StepForm/StepForm.styles.ts

+25
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ import { Select as CommonSelect } from '@app/components/common/selects/Select/Se
33
import { Button } from '@app/components/common/buttons/Button/Button';
44
import { BaseForm } from '@app/components/common/forms/BaseForm/BaseForm';
55
import { FONT_SIZE, FONT_WEIGHT } from '@app/styles/themes/constants';
6+
import { Steps as AntdSteps } from 'antd';
67

78
export const PhoneItem = styled(BaseForm.Item)`
89
.ant-input-group-addon {
@@ -14,6 +15,30 @@ export const PhoneItem = styled(BaseForm.Item)`
1415
}
1516
`;
1617

18+
export const Steps = styled(AntdSteps)`
19+
.ant-steps-item-process > .ant-steps-item-container > .ant-steps-item-content > .ant-steps-item-title {
20+
color: var(--primary-color);
21+
}
22+
23+
.ant-steps-item-wait > .ant-steps-item-container > .ant-steps-item-content > .ant-steps-item-title {
24+
color: var(--subtext-color);
25+
}
26+
27+
.ant-steps-item-wait .ant-steps-item-icon {
28+
border-color: var(--subtext-color);
29+
& > .ant-steps-icon {
30+
color: var(--subtext-color);
31+
}
32+
}
33+
34+
& .ant-steps-item {
35+
&-description,
36+
&-subtitle {
37+
color: var(--subtext-color) !important;
38+
}
39+
}
40+
`;
41+
1742
export const FormContent = styled.div`
1843
margin: 1.25rem 0.5rem;
1944
`;

src/components/forms/StepForm/StepForm.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
import React, { useState } from 'react';
2-
import { Steps } from 'antd';
32
import { useTranslation } from 'react-i18next';
43
import { BaseForm } from '@app/components/common/forms/BaseForm/BaseForm';
54
import { Button } from '@app/components/common/buttons/Button/Button';
@@ -11,6 +10,7 @@ import { notificationController } from '@app/controllers/notificationController'
1110
import { Dates } from '@app/constants/Dates';
1211
import { mergeBy } from '@app/utils/utils';
1312
import * as S from './StepForm.styles';
13+
import { Steps } from './StepForm.styles';
1414
interface FormValues {
1515
[key: string]: string | undefined;
1616
}

src/components/layouts/main/sider/MainSider/MainSider.styles.ts

+3-3
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@ export const Sider = styled(Layout.Sider)`
2525
`;
2626

2727
export const CollapseButton = styled(Button)<{ $isCollapsed: boolean }>`
28-
background: ${(props) =>
29-
props.theme.name === 'light' ? 'rgb(0, 108, 207)' : props.theme.colors.main.additionalBackground};
28+
background: var(--collapse-background-color);
29+
3030
border: 1px solid var(--border-color);
3131
transition: all 0.2s ease;
3232
position: absolute;
@@ -49,7 +49,7 @@ export const CollapseButton = styled(Button)<{ $isCollapsed: boolean }>`
4949
&:focus {
5050
color: var(--text-secondary-color);
5151
background: var(--primary-color);
52-
border: 1px solid var(--border-color);;
52+
border: 1px solid var(--border-color);
5353
}
5454
`;
5555

src/components/layouts/main/sider/SiderMenu/SiderMenu.styles.ts

+9-9
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,8 @@ export const Menu = styled(AntMenu)`
2626
a,
2727
.ant-menu-item,
2828
.ant-menu-submenu {
29-
color: var(--text-siderSecondary-color);
30-
fill: var(--text-siderSecondary-color);
29+
color: var(--text-sider-secondary-color);
30+
fill: var(--text-sider-secondary-color);
3131
}
3232
3333
.ant-menu-item:hover,
@@ -38,20 +38,20 @@ export const Menu = styled(AntMenu)`
3838
a,
3939
.ant-menu-item-icon,
4040
.ant-menu-title-content {
41-
color: var(--text-siderPrimary-color);
42-
fill: var(--text-siderPrimary-color);
41+
color: var(--text-sider-primary-color);
42+
fill: var(--text-sider-primary-color);
4343
}
4444
}
4545
4646
.ant-menu-submenu-selected {
4747
.ant-menu-submenu-title {
48-
color: var(--text-siderPrimary-color);
48+
color: var(--text-sider-primary-color);
4949
5050
.ant-menu-submenu-expand-icon,
5151
.ant-menu-submenu-arrow,
5252
span[role='img'] {
53-
color: var(--text-siderPrimary-color);
54-
fill: var(--text-siderPrimary-color);
53+
color: var(--text-sider-primary-color);
54+
fill: var(--text-sider-primary-color);
5555
}
5656
}
5757
}
@@ -64,8 +64,8 @@ export const Menu = styled(AntMenu)`
6464
span[role='img'],
6565
.ant-menu-item-icon,
6666
a {
67-
color: var(--text-siderPrimary-color);
68-
fill: var(--text-siderPrimary-color);
67+
color: var(--text-sider-primary-color);
68+
fill: var(--text-sider-primary-color);
6969
}
7070
}
7171

src/components/medical-dashboard/PatientResultsCard/PatientResultsCard.styles.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ export const IconWrapper = styled.div<IconProps>`
7272
color: var(--text-secondary-color);
7373
`
7474
: css`
75-
background-color: var(--timeline-bg-color);
75+
background-color: var(--timeline-background-color);
7676
color: var(--primary-color);
7777
`}
7878
font-size: 1.15rem;

src/components/medical-dashboard/mapCard/DoctorsMap/DoctorsMap.styles.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ export const DoctorsMap = styled(CountryMap)`
88
height: 19rem;
99
1010
&.leaflet-container {
11-
background-image: var(--dashboard-map-background-color);
11+
background: var(--dashboard-map-background-color);
1212
border-radius: ${BORDER_RADIUS};
1313
1414
svg {

src/components/medical-dashboard/statisticsCards/statisticsCard/StatisticsCard/StatisticsCard.styles.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,6 @@ export const StatisticCard = styled(DashboardCard)<StatisticsProps>`
2121
overflow: hidden;
2222
2323
${Text} {
24-
${(props) => `var(--${props.color}-color)`};
24+
color: ${(props) => `var(--${props.$color}-color)`};
2525
}
2626
`;

src/components/medical-dashboard/treatmentCard/TreatmentDoctor/TreatmentDoctor.styles.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ export const LabelCol = styled(Col)`
2828
export const ValueCol = styled(Col)``;
2929

3030
export const Tel = styled.a`
31-
color: ${(props) => props.theme.colors.text.main};
31+
color: var(--text-main-color);
3232
3333
&:hover {
3434
text-decoration: underline;
Original file line numberDiff line numberDiff line change
@@ -1,33 +1,38 @@
11
import { Button } from '@app/components/common/buttons/Button/Button';
2+
import { FONT_FAMILY, FONT_SIZE, FONT_WEIGHT } from '@app/styles/themes/constants';
23
import { Typography } from 'antd';
3-
import styled from 'styled-components';
4+
import styled, { css } from 'styled-components';
45

56
export const TitleText = styled(Typography.Title)`
67
&.ant-typography {
78
margin-bottom: 1.25rem;
89
9-
font-size: ${(props) => props.theme.commonFontSizes.xs};
10+
font-size: ${FONT_SIZE.xs};
1011
}
1112
`;
1213

1314
export const TitleBalanceText = styled(Typography.Title)`
1415
&.ant-typography {
1516
margin-bottom: 0;
1617
17-
font-family: ${(props) => props.theme.fonts.secondary};
18+
font-family: ${FONT_FAMILY.secondary};
1819
}
1920
`;
2021

2122
export const SubtitleBalanceText = styled(Typography.Text)`
22-
font-family: ${(props) => props.theme.fonts.secondary};
23+
font-family: ${FONT_FAMILY.secondary};
2324
24-
font-size: ${(props) => props.theme.commonFontSizes.xs};
25+
font-size: ${FONT_SIZE.xs};
2526
26-
font-weight: ${(props) => props.theme.commonFontWeight.regular};
27+
font-weight: ${FONT_WEIGHT.regular};
2728
28-
color: ${(props) => props.theme.colors.text.nftLight};
29+
color: var(--text-nft-light-color);
2930
`;
3031

3132
export const TopUpButton = styled(Button)`
32-
${(props) => props.type === 'ghost' && `color: ${props.theme.colors.text.secondary}`};
33+
${(props) =>
34+
props.type === 'ghost' &&
35+
css`
36+
color: var(--text-secondary-color);
37+
`};
3338
`;

0 commit comments

Comments
 (0)