Skip to content
This repository was archived by the owner on Jul 4, 2025. It is now read-only.

Commit 5e0c3ff

Browse files
Create aside.php
1 parent f960f33 commit 5e0c3ff

File tree

1 file changed

+190
-0
lines changed

1 file changed

+190
-0
lines changed

app/layout/aside.php

Lines changed: 190 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,190 @@
1+
<?php
2+
3+
$page = isset($_GET['page']) ? $_GET['page'] : "manage-apps";
4+
5+
?>
6+
7+
<style>
8+
/* Hide vertical scrollbar for Webkit-based browsers (e.g., Chrome, Safari) */
9+
*::-webkit-scrollbar {
10+
display: none;
11+
}
12+
</style>
13+
14+
<aside id="sidebar"
15+
class="flex hidden fixed top-0 left-0 z-20 flex-col flex-shrink-0 pt-16 w-64 h-full duration-200 lg:flex transition-width"
16+
aria-label="Sidebar">
17+
<div class="flex relative flex-col flex-1 pt-0 min-h-0 bg-[#0f0f17] border-r border-[#0f0f17]">
18+
<div class="flex overflow-y-auto flex-col flex-1 pt-5 pb-4">
19+
<div class="flex-1 px-3 space-y-1 bg-[#0f0f17] mt-8">
20+
<?php require '../app/layout/profile.php';?>
21+
<div class="mb-4 border-b border-[#0f0f17]">
22+
<ul class="grid grid-cols-3 -mb-px text-sm font-medium text-center" id="myTab"
23+
data-tabs-toggle="#myTabContent" role="tablist">
24+
<?php if (isset($_SESSION["app"])){ ?>
25+
<li class="mr-2" role="presentation">
26+
<button class="inline-block p-4 rounded-t-lg hover:opacity-60" id="app-tab"
27+
data-tabs-target="#app" type="button" role="tab" aria-controls="app" data-tbt="app"
28+
aria-selected="false" data-popover-target="app-popover">App</button>
29+
<?php dashboard\primary\popover("app-popover", "Application", "Find everything related to your application here"); ?>
30+
</li>
31+
<?php } ?>
32+
<li class="mr-2" role="presentation">
33+
<button class="inline-block p-4 rounded-t-lg hover:opacity-60" id="account-tab"
34+
data-tabs-target="#account" type="button" role="tab" data-tbt="account"
35+
aria-controls="account" aria-selected="false"
36+
data-popover-target="account-popover">Account</button>
37+
<?php dashboard\primary\popover("account-popover", "Account", "Find everything related to your Account here."); ?>
38+
</li>
39+
</ul>
40+
</div>
41+
<div id="myTabContent">
42+
<div class="hidden p-4 rounded-lg" id="app" role="tabpanel" aria-labelledby="app-tab">
43+
<ul class="space-y-2 font-medium">
44+
<?php if (!($role == "Manager" && !($permissions & 1))){ ?>
45+
<li>
46+
<a href="?page=licenses"
47+
class="flex items-center p-2 rounded-lg text-gray-300 hover:opacity-60 hover:bg-blue-700 group">
48+
<i class="lni lni-key"></i>
49+
<span class="ml-3">Licenses</span>
50+
</a>
51+
</li>
52+
<?php } ?>
53+
54+
<?php if (!($role == "Manager" && !($permissions & 2))){ ?>
55+
<li>
56+
<a href="?page=users"
57+
class="flex items-center p-2 rounded-lg text-gray-300 hover:opacity-60 hover:bg-blue-700 group">
58+
<i class="lni lni-users"></i>
59+
<span class="ml-3">Users</span>
60+
</a>
61+
</li>
62+
<?php } ?>
63+
64+
<?php if (!($role == "Manager" && !($permissions & 2048))){ ?>
65+
<li>
66+
<a href="?page=tokens"
67+
class="flex items-center p-2 rounded-lg text-gray-300 hover:opacity-60 hover:bg-blue-700 group">
68+
<i class="lni lni-tag"></i>
69+
<span class="ml-3">Tokens</span>
70+
</a>
71+
</li>
72+
<?php } ?>
73+
74+
<?php if (!($role == "Manager" && !($permissions & 4))){ ?>
75+
<li>
76+
<a href="?page=subscriptions"
77+
class="flex items-center p-2 rounded-lg text-gray-300 hover:opacity-60 hover:bg-blue-700 group">
78+
<i class="lni lni-crown"></i>
79+
<span class="ml-3">Subscriptions</span>
80+
</a>
81+
</li>
82+
<?php } ?>
83+
84+
<?php if (!($role == "Manager" && !($permissions & 8))){ ?>
85+
<li>
86+
<a href="?page=chats"
87+
class="flex items-center p-2 rounded-lg text-gray-300 hover:opacity-60 hover:bg-blue-700 group">
88+
<i class="lni lni-popup"></i>
89+
<span class="ml-3">Chats</span>
90+
</a>
91+
</li>
92+
<?php } ?>
93+
94+
<?php if (!($role == "Manager" && !($permissions & 16))){ ?>
95+
<li>
96+
<a href="?page=sessions"
97+
class="flex items-center p-2 rounded-lg text-gray-300 hover:opacity-60 hover:bg-blue-700 group">
98+
<i class="lni lni-timer"></i>
99+
<span class="ml-3">Sessions</span>
100+
</a>
101+
</li>
102+
<?php } ?>
103+
104+
<?php if (!($role == "Manager" && !($permissions & 32))){ ?>
105+
<li>
106+
<a href="?page=webhooks"
107+
class="flex items-center p-2 rounded-lg text-gray-300 hover:opacity-60 hover:bg-blue-700 group">
108+
<i class="lni lni-webhooks"></i>
109+
<span class="ml-3">Webhooks</span>
110+
</a>
111+
</li>
112+
<?php } ?>
113+
114+
<?php if (!($role == "Manager" && !($permissions & 64))){ ?>
115+
<li>
116+
<a href="?page=files"
117+
class="flex items-center p-2 rounded-lg text-gray-300 hover:opacity-60 hover:bg-blue-700 group">
118+
<i class="lni lni-files"></i>
119+
<span class="ml-3">Files</span>
120+
</a>
121+
</li>
122+
<?php } ?>
123+
124+
<?php if (!($role == "Manager" && !($permissions & 128))){ ?>
125+
<li>
126+
<a href="?page=vars"
127+
class="flex items-center p-2 rounded-lg text-gray-300 hover:opacity-60 hover:bg-blue-700 group">
128+
<i class="lni lni-code"></i>
129+
<span class="ml-3">Variables</span>
130+
</a>
131+
</li>
132+
<?php } ?>
133+
134+
<?php if (!($role == "Manager" && !($permissions & 256))){ ?>
135+
<li>
136+
<a href="?page=logs"
137+
class="flex items-center p-2 rounded-lg text-gray-300 hover:opacity-60 hover:bg-blue-700 group">
138+
<i class="lni lni-archive"></i>
139+
<span class="ml-3">Logs</span>
140+
</a>
141+
</li>
142+
<?php } ?>
143+
144+
<?php if (!($role == "Manager" && !($permissions & 512))){ ?>
145+
<li>
146+
<a href="?page=blacklists"
147+
class="flex items-center p-2 rounded-lg text-gray-300 hover:opacity-60 hover:bg-blue-700 group">
148+
<i class="lni lni-ban"></i>
149+
<span class="ml-3">Blacklists</span>
150+
</a>
151+
</li>
152+
<?php } ?>
153+
154+
<?php if (!($role == "Manager" && !($permissions & 1024))){ ?>
155+
<li>
156+
<a href="?page=app-settings"
157+
class="flex items-center p-2 rounded-lg text-gray-300 hover:opacity-60 hover:bg-blue-700 group">
158+
<i class="lni lni-cog"></i>
159+
<span class="ml-3">Settings</span>
160+
</a>
161+
</li>
162+
<?php } ?>
163+
164+
<?php if ($role != "Manager"){ ?>
165+
<li>
166+
<a href="?page=audit-logs"
167+
class="flex items-center p-2 rounded-lg text-gray-300 hover:opacity-60 hover:bg-blue-700 group">
168+
<i class="lni lni-archive"></i>
169+
<span class="ml-3">Audit Logs</span>
170+
</a>
171+
</li>
172+
<?php } ?>
173+
</ul>
174+
</div>
175+
<div class="hidden p-4 rounded-lg " id="account" role="tabpanel" aria-labelledby="account-tab">
176+
<ul class="space-y-2 font-medium">
177+
<li>
178+
<a href="?page=account-settings"
179+
class="flex items-center p-2 rounded-lg text-gray-300 hover:opacity-60 hover:bg-blue-700 group">
180+
<i class="lni lni-cog"></i>
181+
<span class="ml-3">Settings</span>
182+
</a>
183+
</li>
184+
</ul>
185+
</div>
186+
</div>
187+
</div>
188+
</div>
189+
</div>
190+
</aside>

0 commit comments

Comments
 (0)