feat: implement admin dashboard header with notification, user, and admin tool components
This commit is contained in:
@@ -188,13 +188,36 @@
|
||||
#page-header .btn-dual-secondary {
|
||||
background: transparent !important;
|
||||
border: none !important;
|
||||
width: 32px !important;
|
||||
height: 32px !important;
|
||||
border-radius: 6px !important;
|
||||
width: 36px !important;
|
||||
height: 36px !important;
|
||||
border-radius: 8px !important;
|
||||
color: #475569 !important;
|
||||
}
|
||||
|
||||
#page-header .btn-dual-secondary:hover {
|
||||
background: #f1f5f9 !important;
|
||||
color: var(--citrus-primary) !important;
|
||||
}
|
||||
|
||||
/* Breadcrumb styling */
|
||||
.breadcrumb-item + .breadcrumb-item::before {
|
||||
content: "/";
|
||||
font-family: inherit;
|
||||
font-weight: 400;
|
||||
font-size: 11px;
|
||||
color: #cbd5e1;
|
||||
padding-right: 8px;
|
||||
padding-left: 8px;
|
||||
}
|
||||
|
||||
.breadcrumb-item {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.content-header-section {
|
||||
display: flex !important;
|
||||
align-items: center !important;
|
||||
}
|
||||
|
||||
.mini-header {
|
||||
|
||||
@@ -3,30 +3,26 @@
|
||||
<div class="content-header">
|
||||
<!-- Left Section -->
|
||||
<div class="content-header-section">
|
||||
<!-- Toggle Sidebar -->
|
||||
<button type="button" class="btn btn-circle btn-dual-secondary" data-toggle="layout" data-action="sidebar_toggle">
|
||||
<i class="fas fa-bars"></i>
|
||||
</button>
|
||||
<!-- END Toggle Sidebar -->
|
||||
@if (isset($c) && $c->icon)
|
||||
<div class="mr-15 d-flex align-items-center justify-content-center"
|
||||
style="width: 36px; height: 36px; background: #f8fafc; border-radius: 10px; border: 1px solid #f1f5f9;">
|
||||
<img src="{{ url($c->icon) }}" alt="" style="width: 20px; height: 20px; object-fit: contain;">
|
||||
</div>
|
||||
@endif
|
||||
|
||||
<!-- Open Search Section -->
|
||||
<button type="button" class="btn btn-circle btn-dual-secondary" data-toggle="layout" data-action="header_search_on">
|
||||
<i class="fas fa-search"></i>
|
||||
</button>
|
||||
<!-- END Open Search Section -->
|
||||
|
||||
<!-- Project Info (Visible on large screens) -->
|
||||
<div class="d-none d-lg-inline-block ml-10">
|
||||
<span class="font-w700 text-white text-uppercase">{{setting("project_number")}}</span>
|
||||
<span class="text-white-op "
|
||||
style="max-width:30%; display:inline-block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; vertical-align:bottom; text-align:center; cursor:pointer;"
|
||||
data-toggle="popover"
|
||||
data-placement="bottom"
|
||||
data-html="true"
|
||||
data-original-title="{{ setting("project_name") }}"
|
||||
data-content='{{ setting("project_name_ru") }}'>
|
||||
- {{ setting("project_name") }} / {{ setting("project_name_ru") }}
|
||||
</span>
|
||||
<!-- Page Title & Breadcrumbs -->
|
||||
<div class="d-flex flex-column justify-content-center">
|
||||
<div class="font-size-md font-w700 text-dark mb-0" style="line-height: 1.2;">@yield('title')</div>
|
||||
<nav class="breadcrumb bg-transparent p-0 mb-0 font-size-xs" style="line-height: 1;">
|
||||
<a class="breadcrumb-item text-muted" href="{{url('admin')}}">Projects</a>
|
||||
@if (isset($c) && $c->parent)
|
||||
<?php $parent = DB::table('types')->where('id', $c->parent)->first(); ?>
|
||||
@if ($parent)
|
||||
<a class="breadcrumb-item text-muted" href="javascript:void(0)">{{ $parent->title }}</a>
|
||||
@endif
|
||||
@endif
|
||||
<span class="breadcrumb-item active text-muted">@yield('title')</span>
|
||||
</nav>
|
||||
</div>
|
||||
</div>
|
||||
<!-- END Left Section -->
|
||||
@@ -35,19 +31,19 @@
|
||||
<div class="content-header-section">
|
||||
|
||||
<!-- Feedback Button -->
|
||||
<button type="button" class="btn btn-rounded btn-dual-secondary"
|
||||
id="openFeedback"
|
||||
title="Feedback">
|
||||
<button type="button" class="btn btn-rounded btn-dual-secondary" id="openFeedback" title="Feedback">
|
||||
<i class="fas fa-comment-dots"></i>
|
||||
</button>
|
||||
|
||||
@if($u->level == "Admin")
|
||||
<!-- Admin Tools Dropdown -->
|
||||
<div class="btn-group" role="group">
|
||||
<button type="button" class="btn btn-rounded btn-dual-secondary" id="page-header-admin-dropdown" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
|
||||
<button type="button" class="btn btn-rounded btn-dual-secondary" id="page-header-admin-dropdown"
|
||||
data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
|
||||
<i class="fa fa-wrench"></i>
|
||||
</button>
|
||||
<div class="dropdown-menu dropdown-menu-right min-width-200" aria-labelledby="page-header-admin-dropdown">
|
||||
<div class="dropdown-menu dropdown-menu-right min-width-200"
|
||||
aria-labelledby="page-header-admin-dropdown">
|
||||
<h5 class="h6 text-center py-10 mb-5 border-b text-uppercase">Admin Tools</h5>
|
||||
|
||||
<a class="dropdown-item" href="javascript:void(0)" onclick="
|
||||
@@ -69,15 +65,19 @@
|
||||
|
||||
<!-- Language Dropdown -->
|
||||
<div class="btn-group" role="group">
|
||||
<button type="button" class="btn btn-rounded btn-dual-secondary" id="page-header-language-dropdown" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
|
||||
<button type="button" class="btn btn-rounded btn-dual-secondary" id="page-header-language-dropdown"
|
||||
data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
|
||||
<i class="fa fa-globe"></i>
|
||||
<span class="d-none d-sm-inline-block ml-5">{{e2(App::getLocale())}}</span>
|
||||
</button>
|
||||
<div class="dropdown-menu dropdown-menu-right min-width-200" aria-labelledby="page-header-language-dropdown">
|
||||
<div class="dropdown-menu dropdown-menu-right min-width-200"
|
||||
aria-labelledby="page-header-language-dropdown">
|
||||
<h5 class="h6 text-center py-10 mb-5 border-b text-uppercase">{{ e2("Change Language") }}</h5>
|
||||
<div class="dropdown-divider"></div>
|
||||
<?php $dil = languages(); foreach($dil AS $d) { ?>
|
||||
<a class="dropdown-item" href="javascript:void(0)" onclick="$.get('?ajax=set-locale&l={{$d}}',function(){location.reload()})">
|
||||
<?php $dil = languages();
|
||||
foreach ($dil as $d) { ?>
|
||||
<a class="dropdown-item" href="javascript:void(0)"
|
||||
onclick="$.get('?ajax=set-locale&l={{$d}}',function(){location.reload()})">
|
||||
<i class="fa fa-language mr-5"></i> {{e2($d)}}
|
||||
</a>
|
||||
<?php } ?>
|
||||
@@ -86,19 +86,23 @@
|
||||
|
||||
<!-- Notifications -->
|
||||
<div class="btn-group" role="group">
|
||||
<button type="button" class="btn btn-rounded btn-dual-secondary" id="notification-dropdown" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false" onclick="loadNotifications()">
|
||||
<button type="button" class="btn btn-rounded btn-dual-secondary" id="notification-dropdown"
|
||||
data-toggle="dropdown" aria-haspopup="true" aria-expanded="false" onclick="loadNotifications()">
|
||||
<i class="fa fa-bell"></i>
|
||||
<span class="badge badge-primary badge-pill" id="notification-count" style="display:none;">0</span>
|
||||
</button>
|
||||
<div class="dropdown-menu dropdown-menu-right" style="width: 380px; padding: 0;" aria-labelledby="notification-dropdown">
|
||||
<div class="dropdown-menu dropdown-menu-right" style="width: 380px; padding: 0;"
|
||||
aria-labelledby="notification-dropdown">
|
||||
<div class="block block-rounded block-bordered mb-0" style="border: none; border-radius: 0.375rem;">
|
||||
<div class="block-header block-header-default">
|
||||
<h3 class="block-title">
|
||||
<i class="fa fa-bell mr-5"></i> {{ e2("Notifications") }}
|
||||
<span class="badge badge-primary ml-5" id="notification-unread-indicator">{{ e2("Loading") }}</span>
|
||||
<span class="badge badge-primary ml-5"
|
||||
id="notification-unread-indicator">{{ e2("Loading") }}</span>
|
||||
</h3>
|
||||
<div class="block-options">
|
||||
<button type="button" class="btn-block-option" onclick="markAllAsRead(); return false;" title="{{e2('Mark All Read')}}">
|
||||
<button type="button" class="btn-block-option" onclick="markAllAsRead(); return false;"
|
||||
title="{{e2('Mark All Read')}}">
|
||||
<i class="si si-check"></i>
|
||||
</button>
|
||||
</div>
|
||||
@@ -126,14 +130,18 @@
|
||||
|
||||
<!-- User Dropdown -->
|
||||
<div class="btn-group" role="group">
|
||||
<button type="button" class="btn btn-rounded btn-dual-secondary" id="page-header-user-dropdown" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
|
||||
<button type="button" class="btn btn-rounded btn-dual-secondary" id="page-header-user-dropdown"
|
||||
data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
|
||||
<i class="fa fa-user d-sm-none"></i>
|
||||
<span class="d-none d-sm-inline-block ml-5">{{ Auth::user()->name }} {{ Auth::user()->surname }}</span>
|
||||
<span class="d-none d-sm-inline-block ml-5">{{ Auth::user()->name }}
|
||||
{{ Auth::user()->surname }}</span>
|
||||
<i class="fa fa-angle-down ml-5"></i>
|
||||
</button>
|
||||
<div class="dropdown-menu dropdown-menu-right min-width-200" aria-labelledby="page-header-user-dropdown">
|
||||
<div class="dropdown-menu dropdown-menu-right min-width-200"
|
||||
aria-labelledby="page-header-user-dropdown">
|
||||
<h5 class="h6 text-center py-10 mb-5 border-b text-uppercase">User</h5>
|
||||
<a class="dropdown-item" href="javascript:void(0)" data-toggle="layout" data-action="side_overlay_toggle">
|
||||
<a class="dropdown-item" href="javascript:void(0)" data-toggle="layout"
|
||||
data-action="side_overlay_toggle">
|
||||
<i class="si si-wrench mr-5"></i> {{e2("Account Settings")}}
|
||||
</a>
|
||||
<div class="dropdown-divider"></div>
|
||||
@@ -153,7 +161,8 @@
|
||||
<form action="{{url('admin/search')}}" method="get">
|
||||
<div class="input-group">
|
||||
<div class="input-group-prepend">
|
||||
<button type="button" class="btn btn-secondary" data-toggle="layout" data-action="header_search_off">
|
||||
<button type="button" class="btn btn-secondary" data-toggle="layout"
|
||||
data-action="header_search_off">
|
||||
<i class="fas fa-times"></i>
|
||||
</button>
|
||||
</div>
|
||||
@@ -189,7 +198,8 @@
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
gap: 5px; /* Image ve title arası mesafe */
|
||||
gap: 5px;
|
||||
/* Image ve title arası mesafe */
|
||||
transition: all 0.3s ease;
|
||||
|
||||
/* Hem mobilde hem desktopta akışı bozmaması için absolute */
|
||||
@@ -198,24 +208,28 @@
|
||||
top: 0;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
z-index: 1000; /* En üstte */
|
||||
pointer-events: none; /* Arkadaki butonlara tıklanabilsin */
|
||||
z-index: 1000;
|
||||
/* En üstte */
|
||||
pointer-events: none;
|
||||
/* Arkadaki butonlara tıklanabilsin */
|
||||
|
||||
color: white !important; /* Her durumda beyaz */
|
||||
color: white !important;
|
||||
/* Her durumda beyaz */
|
||||
}
|
||||
|
||||
.mini-header img {
|
||||
height: 33px;
|
||||
width: auto;
|
||||
display: block;
|
||||
filter: drop-shadow(0 2px 4px rgba(0,0,0,0.2));
|
||||
filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
|
||||
}
|
||||
|
||||
/* Geniş Ekran (Desktop) Ayarları */
|
||||
@media (min-width: 992px) {
|
||||
.mini-header {
|
||||
font-size: 20px;
|
||||
top: 3px; /* Özel istek */
|
||||
top: 3px;
|
||||
/* Özel istek */
|
||||
height: auto;
|
||||
}
|
||||
|
||||
@@ -237,11 +251,24 @@
|
||||
}
|
||||
|
||||
/* Print Styles */
|
||||
.yesprint { display:none; }
|
||||
.yesprint {
|
||||
display: none;
|
||||
}
|
||||
|
||||
@media print {
|
||||
.sidebar, .noprint { display:none; }
|
||||
body { background:white; }
|
||||
.yesprint { display:block; }
|
||||
|
||||
.sidebar,
|
||||
.noprint {
|
||||
display: none;
|
||||
}
|
||||
|
||||
body {
|
||||
background: white;
|
||||
}
|
||||
|
||||
.yesprint {
|
||||
display: block;
|
||||
}
|
||||
}
|
||||
|
||||
/* Notification Item Styles */
|
||||
|
||||
Reference in New Issue
Block a user