diff --git a/.stylelintrc.mjs b/.stylelintrc.mjs
index 99ae9d3..8190971 100644
--- a/.stylelintrc.mjs
+++ b/.stylelintrc.mjs
@@ -7,14 +7,7 @@ const config = {
],
plugins: ['stylelint-order', './config/stylelint/restrict-apply.js'],
rules: {
- 'custom-rules/restrict-apply': [
- true, {
- allowedPatterns: [
- '^text-(sm|base|lg|xl|\\d+)$',
- '^border',
- ],
- },
- ],
+ 'custom-rules/restrict-apply': [true, { allowedPatterns: [] }],
'declaration-empty-line-before': null,
'function-no-unknown': [
true,
@@ -104,7 +97,6 @@ const config = {
{
ignoreAtRules: [
'tailwind',
- 'apply',
'include',
'variants',
'responsive',
diff --git a/README.md b/README.md
index 275bacb..5241b00 100644
--- a/README.md
+++ b/README.md
@@ -2,6 +2,8 @@
> Самое удобное приложение для записи результатов тренировок (:
+⠀
+
- ✨🎨 Разработан [дизайн в Figma](https://www.figma.com/design/l7WmZZ7WKEr3YnVNdibxGD/Mobile-App?node-id=250-793&t=7fycS0Obh0DIcwXF-1)
- Собственный [UI Kit](/src/shared/ui/)
- Серверный рендеринг и [AppRouter](https://nextjs.org/docs/app)
@@ -17,6 +19,7 @@



+



@@ -27,7 +30,7 @@
> Продемонстрировать свои навыки, это не про «усложнить проект»...
> *(всевозможные самописные утилиты, хуки, размазывание не переиспользуемого функционала по всей архитектуре, тесты на всё подряд)*.
-> ⠀
+> ~
> Настоящее мастерство находится в простоте `^-^`
⠀
@@ -55,10 +58,13 @@
##### SCSS
-- [[custom-rules/restrict-apply](./config/stylelint/restrict-apply.js)] `@apply` можно использовать только для:
- - размера текста: `text-sm` | `text-base` и т.п.
- - border: `border...` и т.п.
-- [[custom-rules/scss-import-name](./config/eslint/scss-import-name.js)] Импорт стилей из `.module.scss` нужно называть `styles`
+- [[custom-rules/restrict-apply](./config/stylelint/restrict-apply.js)] `@apply` запрещено использовать;
+- [[custom-rules/scss-import-name](./config/eslint/scss-import-name.js)] Импорт стилей из `.module.scss` нужно называть `styles`.
+
+##### Tailwind
+
+- Добавлять пользовательские цвета нужно в `/shared/theme.scss` формата RGB! Далее нужно добавить этот цвет в `/tailwind.config.ts`.
+ - Использовать переменную цвета нужно строго через `theme('colors.base.{50-950}')`. Через `var(--color-base-{50-950})` использовать запрещено!
---
diff --git a/config/stylelint/restrict-apply.js b/config/stylelint/restrict-apply.js
index 363b1a0..25ea263 100644
--- a/config/stylelint/restrict-apply.js
+++ b/config/stylelint/restrict-apply.js
@@ -3,7 +3,7 @@ const stylelint = require('stylelint');
const ruleName = 'custom-rules/restrict-apply';
const messages = stylelint.utils.ruleMessages(ruleName, {
- invalid: value => `The class "${value}" is not allowed in @apply.`,
+ invalid: (value) => `The class "${value}" is not allowed in @apply.`,
});
module.exports = stylelint.createPlugin(
@@ -21,7 +21,7 @@ module.exports = stylelint.createPlugin(
classes.forEach((className) => {
const isAllowed = allowedPatterns.some(
- pattern => new RegExp(pattern).test(className),
+ (pattern) => new RegExp(pattern).test(className),
);
if (!isAllowed) {
diff --git a/config/tailwind/colors.ts b/config/tailwind/colors.ts
new file mode 100644
index 0000000..2232579
--- /dev/null
+++ b/config/tailwind/colors.ts
@@ -0,0 +1,9 @@
+export const withOpacity = (variable: string): string =>
+ // @ts-ignore
+ (test) => {
+ if (test.opacityValue === undefined) {
+ return `rgb(var(--color-${variable}))`;
+ }
+
+ return `rgba(var(--color-${variable}), ${test.opacityValue})`;
+ };
diff --git a/eslint.config.mjs b/eslint.config.mjs
index 2b470e1..87bbbf2 100644
--- a/eslint.config.mjs
+++ b/eslint.config.mjs
@@ -222,8 +222,11 @@ const eslintConfig = [
rules: { 'max-len': 'off' },
},
{
- files: ['**/config/**/*.js'],
- rules: { '@typescript-eslint/no-require-imports': 'off' },
+ files: ['**/config/**/*.{js,ts}'],
+ rules: {
+ '@typescript-eslint/ban-ts-comment': 'off',
+ '@typescript-eslint/no-require-imports': 'off',
+ },
},
];
diff --git a/src/app/(with-navbar)/settings/ui/SettingsContent.tsx b/src/app/(with-navbar)/settings/ui/SettingsContent.tsx
index 790e1a3..fe31df5 100644
--- a/src/app/(with-navbar)/settings/ui/SettingsContent.tsx
+++ b/src/app/(with-navbar)/settings/ui/SettingsContent.tsx
@@ -1,5 +1,7 @@
'use client';
+import { useTheme } from 'next-themes';
+
import {
ExportOutlineIcon,
FlashOutlineIcon,
@@ -11,78 +13,89 @@ import {
} from '@/shared/icons';
import { Button, Section } from '@/shared/ui';
+import { ThemesModal } from '@/features/ThemesModal';
+
import styles from './settingsContent.module.scss';
-export const SettingsContent = () => (
- <>
- ,
- onClick: () => { /* void */ },
- title: 'Тренировки',
- },
- {
- color: '#FFB21A',
- icon: ,
- onClick: () => { /* void */ },
- title: 'Настроить группы',
- },
- {
- color: '#FA4838',
- icon: ,
- onClick: () => { /* void */ },
- title: 'Упражнения',
- },
- ]}
- />
- ,
- onClick: () => { /* void */ },
- rightText: 'Русский',
- title: 'Язык',
- },
- {
- color: '#5AADF2',
- icon: ,
- onClick: () => { /* void */ },
- rightText: 'Как в системе',
- title: 'Оформление',
- },
- ]}
- />
- ,
- onClick: () => { /* void */ },
- title: 'Импорт настроек',
- },
- {
- color: '#D15347',
- description: 'Сохранить файл',
- icon: ,
- onClick: () => { /* void */ },
- title: 'Экспорт настроек',
- },
- ]}
- />
-
- >
-);
+const getThemeName = (theme: string | undefined) => {
+ switch (theme) {
+ case 'system':
+ return 'Как в системе';
+ case 'dark':
+ return 'Темная тема';
+ case 'light':
+ return 'Светлая тема';
+ default:
+ return 'Тема не выбрана';
+ }
+};
+
+export const SettingsContent = () => {
+ const { theme } = useTheme();
+
+ return (
+ <>
+
+ }
+ title="Тренировки"
+ />
+ }
+ title="Настроить группы"
+ />
+ }
+ showDivider={false}
+ title="Упражнения"
+ />
+
+
+ }
+ rightText="Русский"
+ title="Язык"
+ />
+
+ }
+ rightText={getThemeName(theme)}
+ showDivider={false}
+ title="Оформление"
+ />
+
+
+
+ }
+ title="Импорт настроек"
+ />
+ }
+ showDivider={false}
+ title="Экспорт настроек"
+ />
+
+
+ >
+ );
+};
diff --git a/src/app/globals.scss b/src/app/globals.scss
index 22076b1..5595a42 100644
--- a/src/app/globals.scss
+++ b/src/app/globals.scss
@@ -7,11 +7,6 @@ body {
background: linear-gradient(90deg, theme('colors.base.950') 15px, transparent 1%) 50%, linear-gradient(theme('colors.base.950') 15px, theme('colors.base.800') 1%) 0, hsl(0deg 0% 100% / 16%);
background-size: 16px 16px;
-
- [data-mode="light"] & {
- background: linear-gradient(90deg, theme('colors.base.100') 15px, transparent 1%) 50%, linear-gradient(theme('colors.base.100') 15px, theme('colors.base.300') 1%) 0, hsl(0deg 0% 100% / 16%);
- background-size: 16px 16px;
- }
}
::-webkit-scrollbar {
diff --git a/src/app/layout.tsx b/src/app/layout.tsx
index 7b8273e..4b15250 100644
--- a/src/app/layout.tsx
+++ b/src/app/layout.tsx
@@ -7,6 +7,7 @@ import type { Metadata } from 'next';
import './globals.scss';
import '@/shared/styles/custom.scss';
+import '@/shared/styles/theme.scss';
const inter = Inter({
subsets: ['cyrillic', 'latin'],
@@ -26,7 +27,7 @@ const RootLayout = ({ children }: IRootLayout) => (
(
-
+
{children}
diff --git a/src/widgets/AddExerciseModal/client.ts b/src/features/AddExerciseModal/client.ts
similarity index 100%
rename from src/widgets/AddExerciseModal/client.ts
rename to src/features/AddExerciseModal/client.ts
diff --git a/src/features/AddExerciseModal/model/mock.ts b/src/features/AddExerciseModal/model/mock.ts
new file mode 100644
index 0000000..b0049ca
--- /dev/null
+++ b/src/features/AddExerciseModal/model/mock.ts
@@ -0,0 +1,38 @@
+import type { IGroupExercises } from '../ui/AddExerciseModal';
+
+export const mockAddExerciseModal: IGroupExercises[] = [
+ {
+ color: '#FAC938',
+ exercises: ['Горизонтальная тяга', 'Подтягивания с доп. весом', 'Трансформер'],
+ name: 'Спина',
+ },
+ {
+ color: '#FA4838',
+ exercises: ['Разведения в кроссовере на одну руку', 'Разведение гантелей в стороны'],
+ name: 'Средние дельты',
+ },
+ {
+ color: '#00FF80',
+ exercises: [
+ 'Французский жим лёжа',
+ 'Жим лёжа узким хватом',
+ 'Брусья с доп. весом', // TODO: Синхронизировать по ID
+ ],
+ name: 'Трицепс',
+ },
+ {
+ color: '#1A80E5',
+ exercises: [
+ 'Жим штанги',
+ 'Жим гантелей в наклоне',
+ 'Жим штанги в наклоне',
+ 'Брусья с доп. весом', // TODO: Синхронизировать по ID
+ ],
+ name: 'Грудь',
+ },
+ {
+ color: '#9B693B',
+ exercises: [],
+ name: 'Квадрицепсы',
+ },
+];
diff --git a/src/widgets/AddExerciseModal/ui/AddExerciseModal.tsx b/src/features/AddExerciseModal/ui/AddExerciseModal.tsx
similarity index 96%
rename from src/widgets/AddExerciseModal/ui/AddExerciseModal.tsx
rename to src/features/AddExerciseModal/ui/AddExerciseModal.tsx
index e9df064..2914cc2 100644
--- a/src/widgets/AddExerciseModal/ui/AddExerciseModal.tsx
+++ b/src/features/AddExerciseModal/ui/AddExerciseModal.tsx
@@ -35,15 +35,18 @@ export const AddExerciseModal = ({ items }: IAddExerciseModal) => {
return (
,
+ onClick: () => { /* Redirect в настройки */ },
+ text: 'Настроить',
+ }}
button={(
)}
closeOnClickOverlay={!selectedGroup}
- iconAction={}
onClickOverlay={() => setSelectedGroup(null)}
- textAction="Настроить"
title={(
<>
diff --git a/src/widgets/AddExerciseModal/ui/addExerciseModal.module.scss b/src/features/AddExerciseModal/ui/addExerciseModal.module.scss
similarity index 93%
rename from src/widgets/AddExerciseModal/ui/addExerciseModal.module.scss
rename to src/features/AddExerciseModal/ui/addExerciseModal.module.scss
index 13e9068..5c5b387 100644
--- a/src/widgets/AddExerciseModal/ui/addExerciseModal.module.scss
+++ b/src/features/AddExerciseModal/ui/addExerciseModal.module.scss
@@ -10,10 +10,9 @@
background: theme('colors.base.900 / 75%');
border-radius: 1.25rem;
+ border: 1px solid theme('colors.base.400 / 15%');
overflow: clip;
- @apply border border-base-400/15;
-
&:hover {
background: theme('colors.base.900 / 50%');
}
@@ -80,10 +79,9 @@
padding: 10px;
transition: background 0.3s ease;
+ border-bottom: 1px solid theme('colors.base.800');
cursor: pointer;
- @apply border-b border-base-800;
-
&:hover {
background: theme('colors.base.800 / 50%');
}
diff --git a/src/features/FiltersModal/FiltersModal.tsx b/src/features/FiltersModal/FiltersModal.tsx
index d454f57..0956f11 100644
--- a/src/features/FiltersModal/FiltersModal.tsx
+++ b/src/features/FiltersModal/FiltersModal.tsx
@@ -9,10 +9,12 @@ interface IFiltersModal {
export const FiltersModal = ({ children }: IFiltersModal) => (
,
+ onClick: () => { /* Применить фильтры */ },
+ text: 'Сбросить фильтры',
+ }}
button={children}
- iconAction={
}
- onClickOverlay={() => { /* Применить фильтры */ }}
- textAction="Сбросить фильтры"
title="Настрой фильтры"
>
Здесь будут фильтры
diff --git a/src/features/SortModal/SortModal.tsx b/src/features/SortModal/SortModal.tsx
index 04ee07a..80c76df 100644
--- a/src/features/SortModal/SortModal.tsx
+++ b/src/features/SortModal/SortModal.tsx
@@ -9,10 +9,12 @@ interface ISortModal {
export const SortModal = ({ children }: ISortModal) => (
,
+ onClick: () => { /* Применить сортировку */ },
+ text: 'Сбросить сортировку',
+ }}
button={children}
- iconAction={
}
- onClickOverlay={() => { /* Применить сортировку */ }}
- textAction="Сбросить сортировку"
title="Выбери сортировку"
>
Здесь будет сортировка
diff --git a/src/features/ThemesModal/ThemesModal.tsx b/src/features/ThemesModal/ThemesModal.tsx
new file mode 100644
index 0000000..9503981
--- /dev/null
+++ b/src/features/ThemesModal/ThemesModal.tsx
@@ -0,0 +1,52 @@
+'use client';
+
+import { useTheme } from 'next-themes';
+
+import { Button, Checkbox, Flex, ModalBase } from '@/shared/ui';
+
+import styles from './themesModal.module.scss';
+
+interface IThemesModal {
+ children: React.ReactElement<{ onClick?: () => void }>
+}
+
+export const ThemesModal = ({ children }: IThemesModal) => {
+ const { setTheme, theme } = useTheme();
+
+ return (
+
+
+ }
+ onClick={() => setTheme('system')}
+ variant="none"
+ >
+ Как в системе
+
+ }
+ onClick={() => setTheme('dark')}
+ variant="none"
+ >
+ Темная тема
+
+ }
+ onClick={() => setTheme('light')}
+ variant="none"
+ >
+ Светлая тема
+
+
+
+ );
+};
diff --git a/src/features/ThemesModal/index.ts b/src/features/ThemesModal/index.ts
new file mode 100644
index 0000000..bdac1bd
--- /dev/null
+++ b/src/features/ThemesModal/index.ts
@@ -0,0 +1 @@
+export { ThemesModal } from './ThemesModal';
diff --git a/src/features/ThemesModal/themesModal.module.scss b/src/features/ThemesModal/themesModal.module.scss
new file mode 100644
index 0000000..922972f
--- /dev/null
+++ b/src/features/ThemesModal/themesModal.module.scss
@@ -0,0 +1,18 @@
+.button {
+ display: flex;
+ justify-content: start;
+ gap: 10px;
+ position: relative;
+ padding: 20px 26px;
+
+ background: theme('colors.base.900 / 75%');
+ border-radius: 1.25rem;
+ border: 1px solid theme('colors.base.400 / 15%');
+ overflow: clip;
+
+ animation: var(--anim-scale-fade-in);
+
+ &:hover {
+ background: theme('colors.base.900 / 50%');
+ }
+}
\ No newline at end of file
diff --git a/src/features/Timer/ui/Timer.tsx b/src/features/Timer/ui/Timer.tsx
index e8e2c4d..ec0563b 100644
--- a/src/features/Timer/ui/Timer.tsx
+++ b/src/features/Timer/ui/Timer.tsx
@@ -137,7 +137,7 @@ export const Timer = () => {
return (
-
+ {action ? (
+
+ ) : null}
);
diff --git a/src/shared/ui/Modal/ui/Base/base.module.scss b/src/shared/ui/Modal/ui/Base/base.module.scss
index b9f7930..a39b6ae 100644
--- a/src/shared/ui/Modal/ui/Base/base.module.scss
+++ b/src/shared/ui/Modal/ui/Base/base.module.scss
@@ -1,10 +1,14 @@
+.title, .action, .content {
+ animation: scale-in 0.15s ease-out;
+}
+
.title {
width: 100%;
pointer-events: auto;
-}
-.title, .action, .content {
- animation: scale-in 0.15s ease-out;
+ [data-mode="light"] & {
+ color: theme('colors.base.100');
+ }
}
.content {
@@ -22,9 +26,19 @@
color: theme('colors.base.400');
background: theme('colors.base.700 / 25%');
}
+
+ [data-mode="light"] & {
+ color: theme('colors.base.400');
+
+ &:hover {
+ color: theme('colors.base.100');
+ background: theme('colors.base.500 / 25%');
+ }
+ }
}
body[data-closing="true"] {
+ /* stylelint-disable-next-line no-descending-specificity */
.title, .action {
opacity: 0;
diff --git a/src/shared/ui/Modal/ui/Modal/Modal.tsx b/src/shared/ui/Modal/ui/Modal/Modal.tsx
index 2faa122..f160f15 100644
--- a/src/shared/ui/Modal/ui/Modal/Modal.tsx
+++ b/src/shared/ui/Modal/ui/Modal/Modal.tsx
@@ -1,6 +1,5 @@
'use client';
-import { clsx } from 'clsx';
import { cloneElement, isValidElement, useCallback, useState } from 'react';
import { createPortal } from 'react-dom';
@@ -16,7 +15,7 @@ export interface IModal {
closeOnClickOverlay?: boolean
onClickOverlay?: () => void
onClose?: () => void
- pointerEvents?: boolean
+ placement?: 'start' | 'center' | 'end'
}
export const Modal = ({
@@ -25,7 +24,7 @@ export const Modal = ({
closeOnClickOverlay = true,
onClickOverlay,
onClose,
- pointerEvents = true,
+ placement = 'start',
}: IModal) => {
const [isMount, setMount] = useState(false);
@@ -67,12 +66,8 @@ export const Modal = ({
{isMount && portalTarget ? createPortal(
<>
-
-
+
+
{children}
diff --git a/src/shared/ui/Modal/ui/Modal/modal.global.scss b/src/shared/ui/Modal/ui/Modal/modal.global.scss
index ff2ca26..c2a6fd1 100644
--- a/src/shared/ui/Modal/ui/Modal/modal.global.scss
+++ b/src/shared/ui/Modal/ui/Modal/modal.global.scss
@@ -1,4 +1,3 @@
-
.overlay {
position: fixed;
top: 0;
diff --git a/src/shared/ui/Modal/ui/Modal/modal.module.scss b/src/shared/ui/Modal/ui/Modal/modal.module.scss
index f2e1e93..56dfadc 100644
--- a/src/shared/ui/Modal/ui/Modal/modal.module.scss
+++ b/src/shared/ui/Modal/ui/Modal/modal.module.scss
@@ -12,7 +12,7 @@
position: relative;
width: 100%;
max-width: theme('screens.sm');
- margin: 4rem 2rem;
+ margin: 6rem 2rem;
&.pointerEvents {
pointer-events: auto;
diff --git a/src/shared/ui/Section/Section.tsx b/src/shared/ui/Section/Section.tsx
deleted file mode 100644
index e842218..0000000
--- a/src/shared/ui/Section/Section.tsx
+++ /dev/null
@@ -1,73 +0,0 @@
-import { Fragment } from 'react';
-
-import { ArrowDropdownIcon } from '@/shared/icons';
-import type { TLinkOrClick } from '@/shared/types';
-import { Button, Divider, Flex, Text } from '@/shared/ui';
-
-import { Background } from '../Background';
-
-import styles from './section.module.scss';
-
-interface ISectionBaseItem {
- color: string
- description?: string
- icon: React.ReactNode
- rightText?: string
- title: string
-}
-
-type TSectionItem = TLinkOrClick
;
-
-interface ISection {
- items: TSectionItem[]
-}
-
-export const Section = ({ items }: ISection) => (
-
- {items.map(({
- color,
- description,
- href,
- icon,
- onClick,
- rightText,
- title,
- }, index) => (
-
-
- {index !== items.length - 1 ? : null}
-
- ))}
-
-);
diff --git a/src/shared/ui/Section/index.ts b/src/shared/ui/Section/index.ts
index 8b51c65..4dd37c9 100644
--- a/src/shared/ui/Section/index.ts
+++ b/src/shared/ui/Section/index.ts
@@ -1 +1 @@
-export { Section } from './Section';
+export { Section } from './ui/Section/Section';
diff --git a/src/shared/ui/Section/ui/Item/Item.tsx b/src/shared/ui/Section/ui/Item/Item.tsx
new file mode 100644
index 0000000..787b77b
--- /dev/null
+++ b/src/shared/ui/Section/ui/Item/Item.tsx
@@ -0,0 +1,57 @@
+import { ArrowDropdownIcon } from '@/shared/icons';
+import { Button, Divider, Flex, Text } from '@/shared/ui';
+
+import styles from './item.module.scss';
+
+interface ISectionItemBaseItem {
+ color: string
+ description?: string
+ icon: React.ReactNode
+ onClick?: () => void
+ rightText?: string
+ showDivider?: boolean
+ title: string
+}
+
+export const SectionItem = ({
+ color,
+ description,
+ icon,
+ onClick,
+ rightText,
+ showDivider = true,
+ title,
+}: ISectionItemBaseItem) => (
+
+);
diff --git a/src/shared/ui/Section/section.module.scss b/src/shared/ui/Section/ui/Item/item.module.scss
similarity index 71%
rename from src/shared/ui/Section/section.module.scss
rename to src/shared/ui/Section/ui/Item/item.module.scss
index 1978826..8703753 100644
--- a/src/shared/ui/Section/section.module.scss
+++ b/src/shared/ui/Section/ui/Item/item.module.scss
@@ -1,10 +1,5 @@
-.wrapper {
- overflow: clip;
-
- animation: var(--anim-scale-fade-in);
-}
-
.item {
+ position: relative;
padding: 12px 16px;
&:hover {
@@ -19,12 +14,17 @@
max-height: 28px;
border-radius: theme('borderRadius.md');
+
+ [data-mode="light"] & {
+ color: theme('colors.base.950');
+ }
}
.divider {
+ position: absolute;
+ right: 0;
+ bottom: -0.5px;
width: calc(100% - 56px);
- margin-top: -0.5px;
- margin-left: auto;
}
.title {
diff --git a/src/shared/ui/Section/ui/Section/Section.tsx b/src/shared/ui/Section/ui/Section/Section.tsx
new file mode 100644
index 0000000..8639c64
--- /dev/null
+++ b/src/shared/ui/Section/ui/Section/Section.tsx
@@ -0,0 +1,17 @@
+import { Background } from '@/shared/ui/Background';
+
+import { SectionItem } from '../Item/Item';
+
+import styles from './section.module.scss';
+
+interface ISection {
+ children: React.ReactNode
+}
+
+export const Section = ({ children }: ISection) => (
+
+ {children}
+
+);
+
+Section.Item = SectionItem;
diff --git a/src/shared/ui/Section/ui/Section/section.module.scss b/src/shared/ui/Section/ui/Section/section.module.scss
new file mode 100644
index 0000000..cdda253
--- /dev/null
+++ b/src/shared/ui/Section/ui/Section/section.module.scss
@@ -0,0 +1,5 @@
+.content {
+ overflow: clip;
+
+ animation: var(--anim-scale-fade-in);
+}
\ No newline at end of file
diff --git a/src/shared/ui/Skeleton/skeleton.module.scss b/src/shared/ui/Skeleton/skeleton.module.scss
index 090361a..e94efba 100644
--- a/src/shared/ui/Skeleton/skeleton.module.scss
+++ b/src/shared/ui/Skeleton/skeleton.module.scss
@@ -5,13 +5,12 @@
background: theme('colors.base.800 / 75%');
border-radius: theme('borderRadius.lg');
+ border: 1px solid theme('colors.base.600 / 15%');
overflow: hidden;
transition: all ease 1s;
animation: var(--anim-scale-fade-in);
- @apply border border-base-600/15;
-
&::before {
display: block;
position: absolute;
diff --git a/src/shared/ui/Text/Text.tsx b/src/shared/ui/Text/Text.tsx
index 278e7f5..aec2921 100644
--- a/src/shared/ui/Text/Text.tsx
+++ b/src/shared/ui/Text/Text.tsx
@@ -22,7 +22,7 @@ export const Text = ({
children,
className,
color,
- customColor: hexColor,
+ customColor,
decoration,
size,
weight,
@@ -40,7 +40,7 @@ export const Text = ({
className,
)}
style={{
- color: hexColor,
+ color: customColor,
fontSize: typeof size === 'number' ? `${size}rem` : undefined,
lineHeight: typeof size === 'number' ? `${size + 0.5}rem` : undefined,
}}
diff --git a/src/shared/ui/index.ts b/src/shared/ui/index.ts
index 2ef6e1f..cccf97f 100644
--- a/src/shared/ui/index.ts
+++ b/src/shared/ui/index.ts
@@ -2,6 +2,7 @@ export * from './Avatar';
export * from './Background';
export * from './Badge';
export * from './Button';
+export * from './Checkbox';
export * from './Chip';
export * from './Divider';
export * from './Empty';
diff --git a/src/widgets/AddExerciseModal/model/mock.ts b/src/widgets/AddExerciseModal/model/mock.ts
deleted file mode 100644
index 4e18f48..0000000
--- a/src/widgets/AddExerciseModal/model/mock.ts
+++ /dev/null
@@ -1,29 +0,0 @@
-import type { IGroupExercises } from '../ui/AddExerciseModal';
-
-export const mockAddExerciseModal: IGroupExercises[] = [
- {
- color: '#FAC938',
- exercises: ['Горизонтальная тяга', 'Подтягивания с доп. весом', 'Трансформер'],
- name: 'Спина',
- },
- {
- color: '#FA4838',
- exercises: ['1', '2'],
- name: 'Средние дельты',
- },
- {
- color: '#00FF80',
- exercises: ['1', '2', '3'],
- name: 'Трицепс',
- },
- {
- color: '#1A80E5',
- exercises: ['1', '2', '3', '4', '5', '6'],
- name: 'Грудь',
- },
- {
- color: '#9B693B',
- exercises: [],
- name: 'Квадрицепсы',
- },
-];
diff --git a/src/widgets/Card/ui/VeesItem/veesItem.module.scss b/src/widgets/Card/ui/VeesItem/veesItem.module.scss
index 34841b6..175b62f 100644
--- a/src/widgets/Card/ui/VeesItem/veesItem.module.scss
+++ b/src/widgets/Card/ui/VeesItem/veesItem.module.scss
@@ -12,29 +12,31 @@
&.buttonResult {
background: theme('colors.base.800');
-
- @apply border border-base-700/50;
+ border-color: theme('colors.base.700 / 50%');
+ border-style: solid;
+ border-width: 1px;
&.better {
- @apply border-dashed border-green-500;
+ border-color: theme('colors.green.500');
+ border-style: dashed;
}
&.worse {
- @apply border-dashed border-red-500;
+ border-color: theme('colors.red.500');
+ border-style: dashed;
}
}
&.buttonPreviousResult {
height: 28px;
- @apply border border-base-800;
+ border: 1px solid theme('colors.base.800');
}
&.buttonAdd {
color: theme('colors.base.600');
background: theme('colors.base.800');
-
- @apply border border-base-700/50;
+ border: 1px solid theme('colors.base.700 / 50%');
}
}
diff --git a/src/widgets/Card/ui/VeesList/veesList.module.scss b/src/widgets/Card/ui/VeesList/veesList.module.scss
index 6605234..c73fd50 100644
--- a/src/widgets/Card/ui/VeesList/veesList.module.scss
+++ b/src/widgets/Card/ui/VeesList/veesList.module.scss
@@ -3,6 +3,9 @@
margin: 0 auto;
padding: 18px 36px;
+ font-size: theme('fontSize.sm');
+ line-height: theme('lineHeight.5');
+
color: theme('colors.base.500');
background: theme('colors.base.900');
border-radius: 20px;
@@ -10,8 +13,6 @@
animation: var(--anim-scale-fade-in);
- @apply text-sm;
-
&:hover {
color: theme('colors.base.50');
background: theme('colors.base.800');
diff --git a/src/widgets/Headers/ui/ExercisesList/ExercisesList.tsx b/src/widgets/Headers/ui/ExercisesList/ExercisesList.tsx
index c1fcac4..cbc8797 100644
--- a/src/widgets/Headers/ui/ExercisesList/ExercisesList.tsx
+++ b/src/widgets/Headers/ui/ExercisesList/ExercisesList.tsx
@@ -1,10 +1,10 @@
-import { AddExerciseModal } from '@/widgets/AddExerciseModal/client';
-import { mockAddExerciseModal } from '@/widgets/AddExerciseModal/model/mock';
-
import { AppRoutes } from '@/shared/constants';
import { ArrowLeftIcon, FinishOutlineIcon } from '@/shared/icons';
import { Button, Header } from '@/shared/ui';
+import { AddExerciseModal } from '@/features/AddExerciseModal/client';
+import { mockAddExerciseModal } from '@/features/AddExerciseModal/model/mock';
+
export const ExercisesList = () => (