Skip to content

Commit

Permalink
UX: Иконки в шапке сайта
Browse files Browse the repository at this point in the history
+ fix: редактирование сайтов...
  • Loading branch information
evgip committed Aug 10, 2024
1 parent 0492eff commit 772bb42
Show file tree
Hide file tree
Showing 6 changed files with 24 additions and 14 deletions.
2 changes: 1 addition & 1 deletion modules/catalog/controllers/EditItemController.php
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ public function edit()
$published = $published == 'on' ? 1 : 0;
$published = $this->container->user()->admin() ? $published : 0;

$new_user_id = $this->selectAuthor($item['item_user_id'], Request::post('user_id')->value());
$new_user_id = $this->selectAuthor($item['item_user_id'], (int)Request::post('user_id')->value());

if ($this->container->user()->admin()) {
$item_slug = Request::post('item_slug')->value();
Expand Down
10 changes: 6 additions & 4 deletions modules/catalog/views/header.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
<?php if (!$container->user()->active()) : ?>
<div class="flex gap-max items-center mb-mt5">
<div id="toggledark" class="gray-600">
<svg class="icons">
<svg class="icons icon-bold">
<use xlink:href="/assets/svg/icons.svg#sun"></use>
</svg>
</div>
Expand All @@ -37,12 +37,14 @@
</div>
<?php else : ?>
<div class="flex gap-max items-center mb-mt5">
<a id="toggledark" class="gray-600"><svg class="icons">
<a id="toggledark" class="gray-600">
<svg class="icons icon-bold">
<use xlink:href="/assets/svg/icons.svg#sun"></use>
</svg></a>
</svg>
</a>

<a id="notif" class="gray-600 relative" href="<?= url('notifications'); ?>">
<svg class="icons">
<svg class="icons icon-bold">
<use xlink:href="/assets/svg/icons.svg#bell"></use>
</svg>
<span class="number-notif"></span>
Expand Down
2 changes: 1 addition & 1 deletion public/assets/css/style.css

Large diffs are not rendered by default.

4 changes: 4 additions & 0 deletions resources/views/default/css/parts/_components.css
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,10 @@ h5 {
width: 15px;
}

.icon-bold {
stroke-width: 2;
}

.list-none {
list-style: none;
padding: 0;
Expand Down
12 changes: 7 additions & 5 deletions resources/views/default/global/base-header.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,11 @@

<div class="flex flex-auto">
<div class="box-logo">
<svg id="togglemenu" class="icons pointer">
<svg id="togglemenu" class="icons pointer icon-bold">
<use xlink:href="/assets/svg/icons.svg#menu"></use>
</svg>

<svg class="icons menu__button none">
<svg class="icons menu__button none icon-bold">
<use xlink:href="/assets/svg/icons.svg#menu"></use>
</svg>

Expand Down Expand Up @@ -81,14 +81,16 @@

<?= Html::addPost($facet['facet_id'] ?? false); ?>

<a id="toggledark" class="gray-600"><svg class="icons">
<a id="toggledark" class="gray-600">
<svg class="icons icon-bold">
<use xlink:href="/assets/svg/icons.svg#sun"></use>
</svg></a>
</svg>
</a>

<div class="relative">
<div id="el_notif" class="none"></div>
<a id="notif" class="add-notif gray-600 relative">
<svg class="icons">
<svg class="icons icon-bold">
<use xlink:href="/assets/svg/icons.svg#bell"></use>
</svg>
<span class="number-notif"></span>
Expand Down
8 changes: 5 additions & 3 deletions resources/views/default/global/search-header.php
Original file line number Diff line number Diff line change
Expand Up @@ -44,12 +44,14 @@
</div>
<?php else : ?>
<div class="flex gap-max items-center">
<a id="toggledark" class="gray-600 mb-none"><svg class="icons">
<a id="toggledark" class="gray-600 mb-none">
<svg class="icons icon-bold">
<use xlink:href="/assets/svg/icons.svg#sun"></use>
</svg></a>
</svg>
</a>

<a id="notif" class="gray-600 relative mb-none" href="<?= url('notifications'); ?>">
<svg class="icons">
<svg class="icons icon-bold">
<use xlink:href="/assets/svg/icons.svg#bell"></use>
</svg>
<span class="number-notif"></span>
Expand Down

0 comments on commit 772bb42

Please sign in to comment.