Fixed header icons (#451)

* Fixed header icons

* Code style fixes
This commit is contained in:
kvakazyambra 2024-05-03 11:48:49 +03:00 committed by GitHub
parent ecd038a306
commit ad2f6be1ae
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
4 changed files with 45 additions and 19 deletions

View File

@ -60,11 +60,13 @@
.bio { .bio {
@include font-size(1.2rem); @include font-size(1.2rem);
color: var(--black-400);
display: flex; display: flex;
flex-direction: row; flex-direction: row;
gap: 1rem;
color: var(--black-400);
font-weight: 500; font-weight: 500;
gap: 1rem;
max-width: 100%;
word-break: break-word;
} }
.actions { .actions {

View File

@ -523,6 +523,7 @@
height: 2.8rem; height: 2.8rem;
justify-content: center; justify-content: center;
margin: 0 0.4rem; margin: 0 0.4rem;
order: 2;
position: relative; position: relative;
transition: margin-left 0.3s; transition: margin-left 0.3s;
width: 2.8rem; width: 2.8rem;
@ -533,7 +534,7 @@
width: 3.2rem; width: 3.2rem;
} }
@include media-breakpoint-down(sm) { @include media-breakpoint-down(xl) {
margin-left: 0.4rem !important; margin-left: 0.4rem !important;
} }
@ -584,6 +585,10 @@
.userControlItemSearch { .userControlItemSearch {
margin: 0 1rem 0 2.2rem; margin: 0 1rem 0 2.2rem;
@include media-breakpoint-down(xl) {
order: 1;
}
} }
.userControlItemUserpic { .userControlItemUserpic {
@ -596,13 +601,6 @@
} }
} }
.userControlItemInbox,
.userControlItemSearch {
@include media-breakpoint-down(sm) {
display: none;
}
}
.userControlItemVerbose { .userControlItemVerbose {
align-items: stretch; align-items: stretch;
display: flex; display: flex;
@ -682,7 +680,9 @@
} }
&:hover { &:hover {
background-color: var(--link-hover-background); @include media-breakpoint-up(xl) {
background-color: var(--link-hover-background);
}
&, &,
.textLabel { .textLabel {
@ -708,6 +708,18 @@
} }
} }
.userControlItemCreate {
.icon {
height: 2.8rem;
width: 2.8rem;
@include media-breakpoint-up(md) {
height: 3.2rem;
width: 3.2rem;
}
}
}
.subnavigation { .subnavigation {
background: #000; background: #000;
color: #fff; color: #fff;

View File

@ -107,11 +107,17 @@ export const HeaderAuth = (props: Props) => {
<div class={clsx('col-auto col-lg-7', styles.usernav)}> <div class={clsx('col-auto col-lg-7', styles.usernav)}>
<div class={styles.userControl}> <div class={styles.userControl}>
<Show when={isCreatePostButtonVisible() && isAuthenticated()}> <Show when={isCreatePostButtonVisible() && isAuthenticated()}>
<div class={clsx(styles.userControlItem, styles.userControlItemVerbose)}> <div
class={clsx(
styles.userControlItem,
styles.userControlItemVerbose,
styles.userControlItemCreate,
)}
>
<a href={getPagePath(router, 'create')}> <a href={getPagePath(router, 'create')}>
<span class={styles.textLabel}>{t('Create post')}</span> <span class={styles.textLabel}>{t('Create post')}</span>
<Icon name="pencil" class={styles.icon} /> <Icon name="pencil-outline" class={styles.icon} />
<Icon name="pencil" class={clsx(styles.icon, styles.iconHover)} /> <Icon name="pencil-outline-hover" class={clsx(styles.icon, styles.iconHover)} />
</a> </a>
</div> </div>
</Show> </Show>
@ -215,11 +221,17 @@ export const HeaderAuth = (props: Props) => {
</Show> </Show>
<Show when={isCreatePostButtonVisible() && !isAuthenticated()}> <Show when={isCreatePostButtonVisible() && !isAuthenticated()}>
<div class={clsx(styles.userControlItem, styles.userControlItemVerbose)}> <div
class={clsx(
styles.userControlItem,
styles.userControlItemVerbose,
styles.userControlItemCreate,
)}
>
<a href={getPagePath(router, 'create')}> <a href={getPagePath(router, 'create')}>
<span class={styles.textLabel}>{t('Create post')}</span> <span class={styles.textLabel}>{t('Create post')}</span>
<Icon name="pencil" class={styles.icon} /> <Icon name="pencil-outline" class={styles.icon} />
<Icon name="pencil" class={clsx(styles.icon, styles.iconHover)} /> <Icon name="pencil-outline-hover" class={clsx(styles.icon, styles.iconHover)} />
</a> </a>
</div> </div>
</Show> </Show>
@ -232,7 +244,7 @@ export const HeaderAuth = (props: Props) => {
<a href="?m=auth&mode=login"> <a href="?m=auth&mode=login">
<span class={styles.textLabel}>{t('Enter')}</span> <span class={styles.textLabel}>{t('Enter')}</span>
<Icon name="key" class={styles.icon} /> <Icon name="key" class={styles.icon} />
{/*<Icon name="user-default" class={clsx(styles.icon, styles.iconHover)} />*/} <Icon name="key" class={clsx(styles.icon, styles.iconHover)} />
</a> </a>
</div> </div>
</Show> </Show>

View File

@ -141,7 +141,7 @@
float: none; float: none;
padding-bottom: 0.6rem; padding-bottom: 0.6rem;
padding-top: 0.6rem; padding-top: 0.6rem;
width: 10em; width: 9em;
.icon { .icon {
img { img {