Skip to content

Commit

Permalink
Updated design
Browse files Browse the repository at this point in the history
  • Loading branch information
Eric Heinzl committed Jan 29, 2022
1 parent cec1691 commit 00ef442
Show file tree
Hide file tree
Showing 16 changed files with 324 additions and 106 deletions.
62 changes: 62 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
name: Bug report
description: Create a report to help us improve
title: '[Bug]: '
labels: bug
assignees: 'xPand4B'
body:
- type: markdown
attributes:
value: |
Thanks for taking the time to fill out this bug report!
- type: checkboxes
attributes:
label: Is there an existing issue for this?
description: Please search to see if an issue already exists for the bug you encountered.
options:
- label: I have searched the existing issues
validations:
required: true
- type: textarea
id: description
attributes:
label: Description
description: Describe the bug.
placeholder: A clear and concise description of what the bug is.
validations:
required: true
- type: textarea
id: stepsToReproduce
attributes:
label: To Reproduce
description: Steps to reproduce the behavior.
placeholder: |
1. In this environment...
2. With this config...
3. Run '...'
4. See error...
validations:
required: true
- type: textarea
id: expectedBehaviour
attributes:
label: Expected behavior
description: Expected behavior
placeholder: A clear and concise description of what you expected to happen.
validations:
required: true
- type: textarea
id: logs
attributes:
label: Relevant log output
description: Please copy and paste any relevant log output. This will be automatically formatted into code, so no need for backticks.
render: shell
- type: textarea
id: anythingElse
attributes:
label: Anything else?
description: |
Links? References? Anything that will give us more context about the issue you are encountering!
Tip: You can attach images or log files by clicking this area to highlight it and then dragging files in.
validations:
required: false
42 changes: 42 additions & 0 deletions .github/ISSUE_TEMPLATE/feature_request.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name: Feature request
description: Suggest an idea for this project
title: '[Feature]: '
labels: enhancement
assignees: 'xPand4B'
body:
- type: markdown
attributes:
value: |
Thanks for taking the time to fill out this feature request!
- type: textarea
id: description
attributes:
label: Description
description: Is your feature request related to a problem? Please describe.
placeholder: A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
validations:
required: true
- type: textarea
id: solution
attributes:
label: Describe the solution you'd like
description: A clear and concise description of what you want to happen.
validations:
required: true
- type: textarea
id: alternatives
attributes:
label: Describe alternatives you've considered
description: A clear and concise description of any alternative solutions or features you've considered.
validations:
required: true
- type: textarea
id: anythingElse
attributes:
label: Anything else?
description: |
Links? References? Anything that will give us more context about the feature you are requesting!
Tip: You can attach images or log files by clicking this area to highlight it and then dragging files in.
validations:
required: false
37 changes: 18 additions & 19 deletions app/Providers/ViewServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,11 @@ class ViewServiceProvider extends ServiceProvider
'valet',
];

/**
* @var int
*/
private $totalSites;

/**
* Bootstrap any application services.
*
Expand Down Expand Up @@ -48,7 +53,8 @@ private function shareValetInfos(): void
$valetInfos = [
'tld' => $tld,
'port' => self::VALET_PORT,
'paths' => $this->getSitesFromPaths($valetConfig->paths, $tld)
'paths' => $this->getSitesFromPaths($valetConfig->paths, $tld),
'total' => $this->totalSites
];

view()->share('valet', $valetInfos);
Expand All @@ -72,6 +78,11 @@ private function getValetConfigFileContent(string $homePath)
);
}

private function getValetTld($valetConfig): string
{
return $valetConfig->tld ?? $valetConfig->domain;
}

private function getSitesFromPaths(array $paths, string $tld): array
{
$result = [];
Expand All @@ -81,6 +92,7 @@ private function getSitesFromPaths(array $paths, string $tld): array
$result[$trimmedPath] = [];

foreach (scandir($path) as $key => $site) {
// Skip self
if (mb_strtolower($site) === 'valetdashboard') {
continue;
}
Expand All @@ -90,39 +102,26 @@ private function getSitesFromPaths(array $paths, string $tld): array
if (!(is_dir("$path/$site") || is_link("$path/$site"))) {
continue;
}
// Skip . directories
if ($site[0] === '.') {
continue;
}
// Skip ignored directories
if (in_array($site, self::IGNORED_DIRECTORIES)) {
continue;
}

if ($site === 'cloud.shopware') {
$tld .= '/admin';
}
$this->totalSites++;

$url = 'http://' . $site . '.' . $tld . self::VALET_PORT;
$isShopware = strpos(strtolower($site), 'shopware') !== false;

if ($site === 'cloud.shopware') {
$tld = str_replace('/admin', '', $tld);
}


// if ($site === 'swDashboard') {
// $url = 'http://shopware.dashboard';
// }

$result[$trimmedPath][$site] = $url;
$result[$trimmedPath][$site] = compact('url', 'isShopware');
}

array_multisort($result[$trimmedPath]);
}

return $result;
}

private function getValetTld($valetConfig): string
{
return $valetConfig->tld ?? $valetConfig->domain;
}
}
11 changes: 3 additions & 8 deletions composer.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "xpand4b/valet-dashboard",
"description": "A simple dashboard for Laravel Valet.",
"version": "1.0.0",
"version": "1.1.0",
"type": "project",
"keywords": [
"framework",
Expand All @@ -15,7 +15,7 @@
{
"name": "Eric Heinzl",
"email": "xpand.4beatz@gmail.com",
"homepage": "https://xpand4b.de",
"homepage": "https://github.com/xPand4B/ValetDashboard",
"role": "Developer"
}
],
Expand All @@ -36,10 +36,5 @@
"optimize-autoloader": true
},
"minimum-stability": "dev",
"prefer-stable": true,
"scripts": {
"post-root-package-install": [
"@php -r \"file_exists('.env') || copy('.env.example', '.env');\""
]
}
"prefer-stable": true
}
82 changes: 60 additions & 22 deletions public/css/app.css
Original file line number Diff line number Diff line change
@@ -1,34 +1,72 @@
.sticky {
position: fixed;
top: 0;
width: 100%
}

/**
* ---------------------------------
* Backgrounds
* ---------------------------------
*/
.bg-discord-primary {
background-color: #36393f;
}

.bg-discord-secondary {
background-color: #2f3136;
}

.bg-discord-tertiary {
background-color: #202225;
}

.bg-fab-default {
background-color: #36393f;
fill: hsl(139,calc(1*47.3%),43.9%);;
}
.bg-fab-default:hover {
background-color: hsl(139,calc(1*47.3%),43.9%);
fill: white;
}

/**
* ---------------------------------
* Sources
* Components
* ---------------------------------
*
* https://webgradients.com/
*
*/
.bg-gradient-dark {
/* 045 Loon Crest */
background: linear-gradient(to bottom, rgba(255,255,255,0.15) 0%, rgba(0,0,0,0.15) 100%), radial-gradient(at top center, rgba(255,255,255,0.40) 0%, rgba(0,0,0,0.40) 120%) #989898;
background-blend-mode: multiply,multiply;
.card-discord {
background-color: #2f3136;
border-left: 4px solid #43A7FF;
}

.item-discord {
background-color: #4f545c;
color: #f6f6f7;
}
.bg-gradient-gray {
/* 071 Above Clouds */
background-image: linear-gradient(to left, #BDBBBE 0%, #9D9EA3 100%), radial-gradient(88% 271%, rgba(255, 255, 255, 0.25) 0%, rgba(254, 254, 254, 0.25) 1%, rgba(0, 0, 0, 0.25) 100%), radial-gradient(50% 100%, rgba(255, 255, 255, 0.30) 0%, rgba(0, 0, 0, 0.30) 100%);
background-blend-mode: normal, lighten, soft-light;
.item-discord:hover {
background-color: #72767d;
cursor: pointer;
}

.bg-gradient-gray-light {
/* 074 Sharp Glass */
background: #C9CCD3 linear-gradient(-180deg, rgba(255, 255, 255, 0.50) 0%, rgba(0, 0, 0, 0.50) 100%);
background-blend-mode: lighten;
.item-shopware-admin {
background-color: #253758;
color: #bcc9dc;
}
.item-shopware-admin:hover {
background-color: #2A3F65;
cursor: pointer;
}

.bg-gradient-blue {
background-image: linear-gradient(to top, #1e3c72 0%, #1e3c72 1%, #2a5298 100%);
/**
* ---------------------------------
* Text
* ---------------------------------
*/
.text-discord-header-secondary {
color: #b9bbbe;
}

.item:hover {
/* 071 */
background-image: linear-gradient(to left, #BDBBBE 0%, #9D9EA3 100%), radial-gradient(88% 271%, rgba(255, 255, 255, 0.25) 0%, rgba(254, 254, 254, 0.25) 1%, rgba(0, 0, 0, 0.25) 100%), radial-gradient(50% 100%, rgba(255, 255, 255, 0.30) 0%, rgba(0, 0, 0, 0.30) 100%);
background-blend-mode: normal, lighten, soft-light;
.text-discord {
color: #bcc9dc;
}
2 changes: 1 addition & 1 deletion public/css/tailwind.min.css

Large diffs are not rendered by default.

Binary file added public/img/favicon/favicon-16x16.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/img/favicon/favicon-32x32.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
File renamed without changes.
1 change: 1 addition & 0 deletions public/svg/laravel.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified resources/assets/valet_dashboard.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/assets/valet_dashboard_100.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
54 changes: 54 additions & 0 deletions resources/views/components/fabs.blade.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
{{-- Github Repo --}}
<div>
<button
class="p-2 bg-gray-100 hover:bg-gray-500 text-white text-sm font-bold tracking-wide rounded-full focus:outline-none cursor-pointer shadow-2xl transition duration-200"
onclick="window.open('https://github.com/xPand4B/ValetDashboard')"
title="Github Repository"
>
<svg xmlns="http://www.w3.org/2000/svg" width="40" height="40" viewBox="0 0 24 24">
<path d="M12 0c-6.626 0-12 5.373-12 12 0 5.302 3.438 9.8 8.207 11.387.599.111.793-.261.793-.577v-2.234c-3.338.726-4.033-1.416-4.033-1.416-.546-1.387-1.333-1.756-1.333-1.756-1.089-.745.083-.729.083-.729 1.205.084 1.839 1.237 1.839 1.237 1.07 1.834 2.807 1.304 3.492.997.107-.775.418-1.305.762-1.604-2.665-.305-5.467-1.334-5.467-5.931 0-1.311.469-2.381 1.236-3.221-.124-.303-.535-1.524.117-3.176 0 0 1.008-.322 3.301 1.23.957-.266 1.983-.399 3.003-.404 1.02.005 2.047.138 3.006.404 2.291-1.552 3.297-1.23 3.297-1.23.653 1.653.242 2.874.118 3.176.77.84 1.235 1.911 1.235 3.221 0 4.609-2.807 5.624-5.479 5.921.43.372.823 1.102.823 2.222v3.293c0 .319.192.694.801.576 4.765-1.589 8.199-6.086 8.199-11.386 0-6.627-5.373-12-12-12z"/>
</svg>
</button>
</div>

{{-- Laravel Valet --}}
<div>
<button
class="p-2 bg-red-100 hover:bg-red-300 text-white text-sm font-bold tracking-wide rounded-full focus:outline-none cursor-pointer shadow-2xl transition duration-200"
onclick="window.open('https://laravel.com/docs/8.x/valet')"
title="Laravel Valet"
>
<img
src="{{ url('/svg/laravel.svg') }}"
alt="Laravel"
height="40"
width="40"
>
</button>
</div>

{{-- Request feature --}}
<div class="justify-start">
<button
class="p-2 bg-fab-default text-sm font-bold tracking-wide rounded-full focus:outline-none cursor-pointer shadow-2xl transition duration-200"
onclick="window.open('https://github.com/xPand4B/ValetDashboard/issues/new?assignees=xPand4B&labels=enhancement&template=feature_request.yml&title=%5BFeature%5D%3A+')"
title="Request feature"
>
<svg xmlns="http://www.w3.org/2000/svg" width="40" height="40" viewBox="0 0 24 24">
<path d="M22 8.51v1.372h-2.538c.02-.223.038-.448.038-.681 0-.237-.017-.464-.035-.69h2.535zm-10.648-6.553v-1.957h1.371v1.964c-.242-.022-.484-.035-.726-.035-.215 0-.43.01-.645.028zm5.521 1.544l1.57-1.743 1.019.918-1.603 1.777c-.25-.297-.593-.672-.986-.952zm-10.738.952l-1.603-1.777 1.019-.918 1.57 1.743c-.392.28-.736.655-.986.952zm-1.597 5.429h-2.538v-1.372h2.535c-.018.226-.035.454-.035.691 0 .233.018.458.038.681zm9.462 9.118h-4c-.276 0-.5.224-.5.5s.224.5.5.5h4c.276 0 .5-.224.5-.5s-.224-.5-.5-.5zm0 2h-4c-.276 0-.5.224-.5.5s.224.5.5.5h4c.276 0 .5-.224.5-.5s-.224-.5-.5-.5zm.25 2h-4.5l1.188.782c.154.138.38.218.615.218h.895c.234 0 .461-.08.615-.218l1.187-.782zm3.75-13.799c0 3.569-3.214 5.983-3.214 8.799h-1.989c-.003-1.858.87-3.389 1.721-4.867.761-1.325 1.482-2.577 1.482-3.932 0-2.592-2.075-3.772-4.003-3.772-1.925 0-3.997 1.18-3.997 3.772 0 1.355.721 2.607 1.482 3.932.851 1.478 1.725 3.009 1.72 4.867h-1.988c0-2.816-3.214-5.23-3.214-8.799 0-3.723 2.998-5.772 5.997-5.772 3.001 0 6.003 2.051 6.003 5.772z"/>
</svg>
</button>
</div>

{{-- Report Bug --}}
<div class="justify-start">
<button
class="p-2 bg-fab-default text-sm font-bold tracking-wide rounded-full focus:outline-none cursor-pointer shadow-2xl transition duration-200"
onclick="window.open('https://github.com/xPand4B/ValetDashboard/issues/new?assignees=xPand4B&labels=bug&template=bug_report.yml&title=%5BBug%5D%3A+')"
title="Report Bug"
>
<svg xmlns="http://www.w3.org/2000/svg" width="40" height="40" viewBox="0 0 24 24">
<path d="M7.074 1.408c0-.778.641-1.408 1.431-1.408.942 0 1.626.883 1.38 1.776-.093.336-.042.695.138.995.401.664 1.084 1.073 1.977 1.078.88-.004 1.572-.408 1.977-1.078.181-.299.231-.658.138-.995-.246-.892.436-1.776 1.38-1.776.79 0 1.431.63 1.431 1.408 0 .675-.482 1.234-1.118 1.375-.322.071-.6.269-.769.548-.613 1.017.193 1.917.93 2.823-1.21.562-2.524.846-3.969.846-1.468 0-2.771-.277-3.975-.84.748-.92 1.555-1.803.935-2.83-.168-.279-.446-.477-.768-.548-.636-.14-1.118-.699-1.118-1.374zm13.485 14.044h2.387c.583 0 1.054-.464 1.054-1.037s-.472-1.037-1.054-1.037h-2.402c-.575 0-1.137-.393-1.227-1.052-.092-.677.286-1.147.765-1.333l2.231-.866c.541-.21.807-.813.594-1.346-.214-.533-.826-.795-1.367-.584l-2.294.891c-.329.127-.734.036-.926-.401-.185-.423-.396-.816-.62-1.188-1.714.991-3.62 1.501-5.7 1.501-2.113 0-3.995-.498-5.703-1.496-.217.359-.421.738-.601 1.146-.227.514-.646.552-.941.437l-2.295-.89c-.542-.21-1.153.051-1.367.584-.213.533.053 1.136.594 1.346l2.231.866c.496.192.854.694.773 1.274-.106.758-.683 1.111-1.235 1.111h-2.402c-.582 0-1.054.464-1.054 1.037s.472 1.037 1.054 1.037h2.387c.573 0 1.159.372 1.265 1.057.112.728-.228 1.229-.751 1.462l-2.42 1.078c-.53.236-.766.851-.526 1.373s.865.753 1.395.518l2.561-1.14c.307-.137.688-.106.901.259 1.043 1.795 3.143 3.608 6.134 3.941 2.933-.327 5.008-2.076 6.073-3.837.261-.432.628-.514.963-.364l2.561 1.14c.529.236 1.154.005 1.395-.518.24-.522.004-1.137-.526-1.373l-2.42-1.078c-.495-.221-.867-.738-.763-1.383.128-.803.717-1.135 1.276-1.135z"/>
</svg>
</button>
</div>
Loading

0 comments on commit 00ef442

Please sign in to comment.