Добавил иконки кнопкам в шапке для мобильной версии

This commit is contained in:
kvakazyambra 2023-04-12 23:32:38 +03:00
parent c3378d3c7b
commit 7afa2a8c12
4 changed files with 27 additions and 3 deletions

3
public/icons/publish.svg Normal file
View File

@ -0,0 +1,3 @@
<?xml version="1.0" encoding="UTF-8"?>
<svg width="800px" height="800px" viewBox="0 0 512 512" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"><g id="Page-1" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd"><g id="icon" fill="#000000" transform="translate(42.666667, 33.830111)"><path d="M170.666667,51.5032227 L256,136.836556 L256,392.836556 L-2.13162821e-14,392.836556 L-2.13162821e-14,51.5032227 L170.666667,51.5032227 Z M152.993555,94.1698893 L42.6666667,94.1698893 L42.6666667,350.169889 L213.333333,350.169889 L213.333333,154.509668 L152.993555,94.1698893 Z M341.333333,7.10542736e-15 L431.084945,89.7516113 L400.915055,119.921501 L362.666,81.683 L362.666667,222.169889 C362.666667,267.870058 326.742006,305.179572 281.592327,307.398789 L277.333333,307.503223 L277.333333,264.836556 C299.826385,264.836556 318.254189,247.431163 319.882971,225.354153 L320,222.169889 L319.999,81.684 L281.751611,119.921501 L251.581722,89.7516113 L341.333333,7.10542736e-15 Z">
</path></g></g></svg>

After

Width:  |  Height:  |  Size: 1.0 KiB

2
public/icons/save.svg Normal file
View File

@ -0,0 +1,2 @@
<?xml version="1.0" standalone="no"?>
<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill="currentColor" class="bi bi-save" viewBox="0 0 16 16"> <path d="M2 1a1 1 0 0 0-1 1v12a1 1 0 0 0 1 1h12a1 1 0 0 0 1-1V2a1 1 0 0 0-1-1H9.5a1 1 0 0 0-1 1v7.293l2.646-2.647a.5.5 0 0 1 .708.708l-3.5 3.5a.5.5 0 0 1-.708 0l-3.5-3.5a.5.5 0 1 1 .708-.708L7.5 9.293V2a2 2 0 0 1 2-2H14a2 2 0 0 1 2 2v12a2 2 0 0 1-2 2H2a2 2 0 0 1-2-2V2a2 2 0 0 1 2-2h2.5a.5.5 0 0 1 0 1H2z"/></svg>

After

Width:  |  Height:  |  Size: 475 B

View File

@ -502,7 +502,10 @@
}
.userControlItemVerbose {
margin-right: 0.5em;
@include media-breakpoint-up(lg) {
margin-right: 0;
width: auto;
.icon {
@ -511,7 +514,7 @@
.textLabel {
display: inline;
padding: 0 1.2rem;
//padding: 0 1.2rem;
position: relative;
z-index: 1;
}

View File

@ -66,11 +66,27 @@ export const HeaderAuth = (props: HeaderAuthProps) => {
<Show when={isAuthenticated() && page().route === 'create'}>
<div class={clsx(styles.userControlItem, styles.userControlItemVerbose)}>
<Button value={t('Save')} variant={'outline'} />
<Button
value={
<>
<span class={styles.textLabel}>{t('Save')}</span>
<Icon name="save" class={styles.icon} />
</>
}
variant={'outline'}
/>
</div>
<div class={clsx(styles.userControlItem, styles.userControlItemVerbose)}>
<Button value={t('Publish')} variant={'outline'} />
<Button
value={
<>
<span class={styles.textLabel}>{t('Publish')}</span>
<Icon name="publish" class={styles.icon} />
</>
}
variant={'outline'}
/>
</div>
<div class={clsx(styles.userControlItem, styles.userControlItemVerbose)}>