feat: mobile adapt

This commit is contained in:
2025-04-15 12:57:30 +03:00
parent af335ab4a8
commit 860b628834
7 changed files with 11 additions and 11 deletions

View File

@@ -9,5 +9,5 @@
} }
.menu_item { .menu_item {
@apply flex w-full cursor-pointer flex-row items-center gap-3 rounded-full px-3 py-2 text-center hover:bg-gray-200 md:px-6; @apply flex w-full flex-1/3 cursor-pointer flex-row items-center justify-center gap-3 rounded-full px-3 py-2 text-center hover:bg-gray-200 md:flex-initial md:justify-start md:px-6;
} }

View File

@@ -29,7 +29,7 @@ const MenuItem: FunctionComponent<MenuItemProps> = ({ title, link, icon }: MenuI
return ( return (
<div class={menuItemClasses({ activity: active ? "active" : "inactive" })} onClick={() => route(link, true)}> <div class={menuItemClasses({ activity: active ? "active" : "inactive" })} onClick={() => route(link, true)}>
{icon} {icon}
{title} <div class="hidden md:block">{title}</div>
</div> </div>
); );
}; };

View File

@@ -1,5 +1,5 @@
@reference "../index.scss"; @reference "../index.scss";
.task { .task {
@apply flex h-24 w-[300px] cursor-pointer flex-row items-center justify-start gap-4 rounded-[3rem] bg-[rgba(251,194,199,0.53)] px-5 py-6 text-xl shadow-[0px_4px_4px_0px_rgba(0,0,0,0.25)] transition-transform hover:scale-[1.05] hover:bg-[rgba(251,194,199,0.7)] active:scale-[1.05] md:w-[500px]; @apply flex h-24 w-full cursor-pointer flex-row items-center justify-start gap-4 rounded-[3rem] bg-[rgba(251,194,199,0.53)] px-5 py-6 text-xl shadow-[0px_4px_4px_0px_rgba(0,0,0,0.25)] transition-transform hover:scale-[1.05] hover:bg-[rgba(251,194,199,0.7)] active:scale-[1.05] md:w-[500px];
} }

View File

@@ -30,7 +30,7 @@ const markStyle = tv({
const Task: FunctionComponent<TaskProps> = ({ name, checked = false }: TaskProps) => { const Task: FunctionComponent<TaskProps> = ({ name, checked = false }: TaskProps) => {
return ( return (
// Временное действие для тестирования // Временное действие для тестирования
<button onClick={() => alert(name)}> <button onClick={() => alert(name)} class="w-full">
<div class={classes.task}> <div class={classes.task}>
<div class={taskStyle({ checked })}> <div class={taskStyle({ checked })}>
<p class={markStyle({ checked })}></p> <p class={markStyle({ checked })}></p>

View File

@@ -5,8 +5,8 @@ const button = tv({
base: classes.button, base: classes.button,
variants: { variants: {
color: { color: {
primary: "bg-[rgba(206,232,251,0.7)] hover:bg-[rgba(206,232,251,0.9)]", primary: "bg-[rgba(206,232,251,0.7)] hover:bg-[rgba(206,232,251,0.9)] active:bg-[rgba(206,232,251,0.9)]",
secondary: "bg-[rgba(255,251,197,0.68)] hover:bg-[rgba(255,251,197,0.9)]", secondary: "bg-[rgba(255,251,197,0.68)] hover:bg-[rgba(255,251,197,0.9)] active:bg-[rgba(255,251,197,0.9)]",
}, },
}, },
}); });

View File

@@ -14,10 +14,10 @@ const ProfileSettings: FunctionComponent = () => {
const maxStatus = 100; const maxStatus = 100;
return ( return (
<div class={classes.container}> <div class={classes.container}>
<div class="flex w-full flex-row items-center rounded-[4rem] bg-[linear-gradient(180.00deg,rgb(251,194,199),rgba(206,232,251,0.72)_100%)] px-7 py-5 shadow-[0px_4px_4px_0px_rgba(0,0,0,0.25)]"> <div class="flex w-full flex-col items-center rounded-[4rem] bg-[linear-gradient(180.00deg,rgb(251,194,199),rgba(206,232,251,0.72)_100%)] px-7 py-5 shadow-[0px_4px_4px_0px_rgba(0,0,0,0.25)] md:flex-row">
<div id={classes.avatar}>Аватар</div> <div id={classes.avatar}>Аватар</div>
<div class={classes.header_block__name}> <div class={classes.header_block__name}>
<p class="text-5xl font-semibold">Никнейм</p> <p class="text-4xl font-semibold">Никнейм</p>
<p class="text-2xl font-light">Статус</p> <p class="text-2xl font-light">Статус</p>
<div class="h-1.5 w-full overflow-hidden rounded-2xl bg-white"> <div class="h-1.5 w-full overflow-hidden rounded-2xl bg-white">
<div <div

View File

@@ -1,13 +1,13 @@
@reference "../index.scss"; @reference "../index.scss";
.container { .container {
@apply flex h-fit w-full flex-col items-center gap-4 px-6 pt-3; @apply flex h-fit w-full flex-col items-center gap-4 pt-3 md:px-6;
} }
.header { .header {
@apply mb-12 w-full text-3xl font-semibold md:text-5xl; @apply mb-3 w-full text-3xl font-semibold md:mb-12 md:text-5xl;
} }
.tasks_container { .tasks_container {
@apply flex w-full flex-col items-center gap-10 md:items-start; @apply flex w-full flex-col items-center gap-3 md:items-start md:gap-10;
} }