Merge branch 'develop' into add-hamburger-menu

This commit is contained in:
Jay Trees 2022-02-28 09:09:06 +01:00
commit ff98a134ae
4 changed files with 46 additions and 37 deletions

View file

@ -55,6 +55,7 @@ img {
z-index: 1; z-index: 1;
opacity: 0; opacity: 0;
border-radius: 0.33333333rem;
background-color: rgba(255, 255, 255, 0.6); background-color: rgba(255, 255, 255, 0.6);
} }
@ -136,6 +137,7 @@ img {
height: 4em; height: 4em;
width: 100%; width: 100%;
background-image: linear-gradient(0deg, rgba(255,255,255,1) 0.75em, rgba(255,255,255,0.8995799003195029) 45%, rgba(255,255,255,0) 100%); background-image: linear-gradient(0deg, rgba(255,255,255,1) 0.75em, rgba(255,255,255,0.8995799003195029) 45%, rgba(255,255,255,0) 100%);
border-radius: 0.33333333rem;
} }
/** Buttons */ /** Buttons */
@ -152,6 +154,7 @@ img {
.ui.card > .extra.buttons, .ui.card > .extra.buttons,
.ui.cards > .card > .extra.buttons { .ui.cards > .card > .extra.buttons {
opacity: 0; opacity: 0;
margin-bottom: 0;
} }
} }
.ui.card:hover > .extra.buttons, .ui.card:hover > .extra.buttons,
@ -168,6 +171,8 @@ img {
flex: 1 1 auto; flex: 1 1 auto;
margin: 0; margin: 0;
border: none;
min-height: auto;
box-shadow: none; box-shadow: none;
} }

View file

@ -262,40 +262,44 @@ class Page
</a> </a>
<a class="item" href="/?page=wishlists"> <a class="item" href="/?page=wishlists">
<i class="list icon"></i> <i class="list icon"></i>
Wishlists My lists
</a> </a>
<?php if (count($pagesAccount) === 1) { ?> <div class="right menu">
<a class="item" href="<?= $pagesAccount[0]['url'] ?>"> <?php global $options; ?>
<i class="<?= $pagesAccount[0]['icon'] ?> icon"></i>
<?= $pagesAccount[0]['text'] ?> <?php if ($options->updateAvailable && $user && 100 === $user->power) { ?>
</a> <a class="item" href="/?page=update">
<?php } elseif (count($pagesAccount) >= 2) { ?> <i class="upload icon"></i> Update
<div class="ui simple dropdown item"> </a>
Account <?php } ?>
<i class="dropdown icon"></i>
<div class="menu"> <?php if (count($pagesAccount) === 1) { ?>
<?php <a class="item" href="<?= $pagesAccount[0]['url'] ?>">
if (count($pagesAccount) >= 2) { <i class="<?= $pagesAccount[0]['icon'] ?> icon"></i>
foreach ($pagesAccount as $item) { <?= $pagesAccount[0]['text'] ?>
?> </a>
<a class="item" href="<?= $item['url'] ?>"> <?php } elseif (count($pagesAccount) >= 2) { ?>
<i class="<?= $item['icon'] ?> icon"></i> <div class="ui simple dropdown item">
<?= $item['text'] ?> Account
</a> <i class="dropdown icon"></i>
<?php <div class="menu">
<?php
if (count($pagesAccount) >= 2) {
foreach ($pagesAccount as $item) {
?>
<a class="item" href="<?= $item['url'] ?>">
<i class="<?= $item['icon'] ?> icon"></i>
<?= $item['text'] ?>
</a>
<?php
}
} }
} ?>
?> </div>
</div> </div>
</div> <?php } ?>
<?php } ?> </div>
<?php global $options; ?>
<?php if ($options->updateAvailable && $user && 100 === $user->power) { ?>
<a class="item" href="/?page=update">
<i class="upload icon"></i> Update
</a>
<?php } ?>
</div> </div>
</div> </div>
<div class="ui attached stackable menu toggle"> <div class="ui attached stackable menu toggle">
@ -315,7 +319,7 @@ class Page
?> ?>
<div class="ui hidden divider"></div> <div class="ui hidden divider"></div>
<div class="ui inverted vertical footer segment"> <div class="ui inverted vertical footer segment">
<div class="ui container"> <div class="ui center aligned container">
<div class="ui stackable inverted divided equal height stackable grid"> <div class="ui stackable inverted divided equal height stackable grid">
<div class="sixteen wide column"> <div class="sixteen wide column">

View file

@ -81,8 +81,6 @@ class Wish
?> ?>
<div class="ui fluid card stretch" data-id="<?= $this->id ?>" data-cache="<?= $exists ?>"> <div class="ui fluid card stretch" data-id="<?= $this->id ?>" data-cache="<?= $exists ?>">
<div class="overlay"></div>
<div class="image"> <div class="image">
<?php if ($this->image) { ?> <?php if ($this->image) { ?>
<img class="preview" src="<?= $this->image ?>" loading="lazy" /> <img class="preview" src="<?= $this->image ?>" loading="lazy" />
@ -97,6 +95,8 @@ class Wish
<?php } ?> <?php } ?>
</div> </div>
<div class="overlay"></div>
<div class="content"> <div class="content">
<?php if ($this->title) { ?> <?php if ($this->title) { ?>
<div class="header"> <div class="header">
@ -124,14 +124,14 @@ class Wish
<div class="extra content buttons"> <div class="extra content buttons">
<?php if (!$userIsCurrent) { ?> <?php if (!$userIsCurrent) { ?>
<a class="ui primary labeled icon button commit"> <a class="ui small primary labeled icon button commit">
<i class="shopping cart icon"></i> <i class="shopping cart icon"></i>
Commit Commit
</a> </a>
<?php } ?> <?php } ?>
<?php if ($this->url) { ?> <?php if ($this->url) { ?>
<a class="ui labeled icon button" href="<?= $this->url ?>" target="_blank"> <a class="ui small labeled icon button" href="<?= $this->url ?>" target="_blank">
<i class="external icon"></i> <i class="external icon"></i>
Visit Visit
</a> </a>
@ -139,7 +139,7 @@ class Wish
<?php if ($userIsCurrent) { ?> <?php if ($userIsCurrent) { ?>
<div class="ui menu"> <div class="ui menu">
<div class="ui fluid floating dropdown labeled icon button"> <div class="ui small fluid floating dropdown labeled icon button">
<i class="cog icon"></i> <i class="cog icon"></i>
Options Options

View file

@ -8,7 +8,7 @@
use wishthis\{Page, User, Wishlist}; use wishthis\{Page, User, Wishlist};
$page = new page(__FILE__, 'Wishlists'); $page = new page(__FILE__, 'My lists');
$page->header(); $page->header();
$page->navigation(); $page->navigation();
?> ?>