Skip to content

Commit

Permalink
feat: Make credentials easily copyable
Browse files Browse the repository at this point in the history
  • Loading branch information
geoffreyvanwyk committed Dec 21, 2023
1 parent 5100766 commit 58f7c84
Show file tree
Hide file tree
Showing 8 changed files with 67 additions and 9 deletions.
2 changes: 1 addition & 1 deletion files/website/_media/app.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion files/website/_media/app.js

Large diffs are not rendered by default.

Binary file modified files/website/_media/hero_background.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
5 changes: 2 additions & 3 deletions files/website/_pages/index.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,7 @@
<main class="grid h-full grid-cols-1 justify-between"
id="content">
<!-- Primary Hero -->
<div class="hero bg-base-200"
style="background-image: url('/media/hero_background.jpg')">
<div class="hero bg-base-200 bg-[url('/media/hero_background.jpg')]">

<div class="hero-overlay bg-opacity-60"></div>

Expand Down Expand Up @@ -44,7 +43,7 @@ class="flex flex-col items-center justify-center space-x-3 text-3xl font-bold md
OR
</div>

<details class="dropdown dropdown-top">
<details class="dropdown-top dropdown">
<summary class="btn btn-secondary btn-wide m-1 rounded-full">Other versions</summary>
<ul class="menu dropdown-content z-50 w-52 rounded-box bg-base-100 p-2 shadow">
@foreach (config('hyde.moodle.versions')->skip(1) as $moodleVersion)
Expand Down
30 changes: 30 additions & 0 deletions files/website/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 4 additions & 0 deletions files/website/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,5 +39,9 @@
"postcss": "^8.4.31",
"prettier": "2.6.0",
"tailwindcss": "^3.0.24"
},
"dependencies": {
"@ryangjchandler/alpine-clipboard": "^2.3.0",
"alpinejs": "^3.13.3"
}
}
7 changes: 7 additions & 0 deletions files/website/resources/assets/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,10 @@
* This is the main JavaScript used by webpack to build the the app.js file.
*/
import 'boxicons'
import Alpine from 'alpinejs'
import Clipboard from "@ryangjchandler/alpine-clipboard"

Alpine.plugin(Clipboard)

window.Alpine = Alpine
window.Alpine.start()
26 changes: 22 additions & 4 deletions files/website/resources/views/components/secondary_hero.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,28 @@
'title' => 'Credentials',
'icon' => 'key',
'description' => '
Log in as the site administration with:
Click each credential to copy it.
<ul>
<li class="flex flex-wrap justify-between"><span class="font-bold"><i class="bx bx-user"></i> Username</span> <span>moodler</span></li>
<li class="flex flex-wrap justify-between"><span class="font-bold"><i class="bx bx-lock"></i> Password</span> <span>N3verstople@rning</span></li>
<li class="flex flex-wrap justify-between">
<span class="font-bold">
<i class="bx bx-user"></i> Username
</span>
<span class="cursor-pointer space-x-2" title="Click to copy" x-clipboard.raw="moodler">
<span>moodler</span>
<i class="bx bx-copy"></i>
</span>
</li>
<li class="flex flex-wrap justify-between">
<span class="font-bold">
<i class="bx bx-lock"></i> Password
</span>
<span class="cursor-pointer space-x-2" title="Click to copy" x-clipboard.raw="N3verstople@rning">
<span>N3verstople@rning</span>
<i class="bx bx-copy"></i>
</span>
</li>
</ul>
',
],
Expand All @@ -25,7 +43,7 @@
[
'title' => 'Additional Plugins',
'icon' => 'plug',
'description' => 'The installation of additional plugins are disabled in order to make the automatic upgrade possible.',
'description' => 'The installation of additional plugins are disabled to make the automatic upgrades possible.',
],
[
'title' => 'Emails',
Expand Down

0 comments on commit 58f7c84

Please sign in to comment.