Browse Source

fix styles

Alexander Musikhin 1 tháng trước cách đây
mục cha
commit
55ca3ca0a6

+ 160 - 0
resources/sass/app.scss

@@ -632,3 +632,163 @@ td p {
     margin-left: auto;
   }
 }
+
+// Chat component styles (from partials/chat.blade.php)
+.chat-block {
+  --chat-height: 420px;
+}
+
+.chat-card {
+  border: 1px solid var(--bs-border-color);
+  border-radius: 0.75rem;
+  background: var(--bs-light-bg-subtle, #f8f9fa);
+}
+
+.chat-messages-wrap {
+  position: relative;
+  padding: 0.75rem;
+}
+
+.chat-messages {
+  max-height: var(--chat-height);
+  overflow-y: auto;
+  padding-right: 0.35rem;
+  scroll-behavior: smooth;
+}
+
+.chat-message {
+  border: 1px solid rgba(0, 0, 0, 0.08);
+  border-radius: 0.75rem;
+  background: #fff;
+  padding: 0.75rem 0.875rem;
+  margin-bottom: 0.625rem;
+  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
+}
+
+.chat-message:last-child {
+  margin-bottom: 0;
+}
+
+.chat-message-header {
+  display: flex;
+  justify-content: space-between;
+  gap: 0.75rem;
+  flex-wrap: wrap;
+  font-size: 0.875rem;
+}
+
+.chat-message-text {
+  margin-top: 0.5rem;
+  white-space: pre-wrap;
+  line-height: 1.35;
+}
+
+.chat-message-files {
+  margin-top: 0.625rem;
+  display: flex;
+  flex-wrap: wrap;
+  gap: 0.5rem;
+}
+
+.chat-message-files img {
+  width: 84px;
+  height: 84px;
+  object-fit: cover;
+}
+
+.chat-scroll-bottom {
+  position: absolute;
+  right: 1rem;
+  bottom: 1rem;
+  z-index: 2;
+  border-radius: 999px;
+  box-shadow: 0 0.25rem 1rem rgba(0, 0, 0, 0.18);
+}
+
+.chat-recipient-list {
+  max-height: 320px;
+  overflow-y: auto;
+  border: 1px solid var(--bs-border-color);
+  border-radius: 0.5rem;
+  padding: 0.5rem 0.75rem;
+}
+
+.chat-recipient-item[hidden] {
+  display: none !important;
+}
+
+.chat-recipient-summary {
+  min-height: 1.25rem;
+}
+
+// Schedule calendar styles (from schedule/index.blade.php)
+.schedule-month {
+  table-layout: fixed;
+}
+
+.schedule-day {
+  height: 110px;
+  vertical-align: top;
+  position: relative;
+}
+
+.schedule-day-link {
+  display: inline-block;
+  font-weight: 600;
+  text-decoration: none;
+  color: #0d6efd;
+}
+
+.schedule-dots {
+  margin-top: 6px;
+  display: flex;
+  flex-wrap: wrap;
+  gap: 4px;
+}
+
+.schedule-dot {
+  width: 12px;
+  height: 12px;
+  border-radius: 50%;
+  display: inline-block;
+  border: 1px solid rgba(0, 0, 0, 0.1);
+}
+
+.schedule-outside {
+  background: #f8f9fa;
+  color: #9aa0a6;
+}
+
+.schedule-today {
+  outline: 2px solid rgba(13, 110, 253, 0.5);
+  outline-offset: -2px;
+}
+
+.schedule-legend-items {
+  display: flex;
+  flex-wrap: wrap;
+  gap: 10px 16px;
+  align-items: center;
+}
+
+.schedule-legend-item {
+  display: inline-flex;
+  align-items: center;
+  gap: 6px;
+  font-size: 0.9rem;
+}
+
+.schedule-legend-name {
+  white-space: nowrap;
+}
+
+// Table sortable header styles (from reports/index.blade.php)
+.sortable-header {
+  cursor: pointer;
+  user-select: none;
+}
+
+// Notification settings table (from partials/notification-settings-table.blade.php)
+.section-header-row {
+  background-color: #d4edda;
+}

+ 0 - 91
resources/views/partials/chat.blade.php

@@ -16,97 +16,6 @@
         ->all();
 @endphp
 
-@once
-    <style>
-        .chat-block {
-            --chat-height: 420px;
-        }
-
-        .chat-card {
-            border: 1px solid var(--bs-border-color);
-            border-radius: 0.75rem;
-            background: var(--bs-light-bg-subtle, #f8f9fa);
-        }
-
-        .chat-messages-wrap {
-            position: relative;
-            padding: 0.75rem;
-        }
-
-        .chat-messages {
-            max-height: var(--chat-height);
-            overflow-y: auto;
-            padding-right: 0.35rem;
-            scroll-behavior: smooth;
-        }
-
-        .chat-message {
-            border: 1px solid rgba(0, 0, 0, 0.08);
-            border-radius: 0.75rem;
-            background: #fff;
-            padding: 0.75rem 0.875rem;
-            margin-bottom: 0.625rem;
-            box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
-        }
-
-        .chat-message:last-child {
-            margin-bottom: 0;
-        }
-
-        .chat-message-header {
-            display: flex;
-            justify-content: space-between;
-            gap: 0.75rem;
-            flex-wrap: wrap;
-            font-size: 0.875rem;
-        }
-
-        .chat-message-text {
-            margin-top: 0.5rem;
-            white-space: pre-wrap;
-            line-height: 1.35;
-        }
-
-        .chat-message-files {
-            margin-top: 0.625rem;
-            display: flex;
-            flex-wrap: wrap;
-            gap: 0.5rem;
-        }
-
-        .chat-message-files img {
-            width: 84px;
-            height: 84px;
-            object-fit: cover;
-        }
-
-        .chat-scroll-bottom {
-            position: absolute;
-            right: 1rem;
-            bottom: 1rem;
-            z-index: 2;
-            border-radius: 999px;
-            box-shadow: 0 0.25rem 1rem rgba(0, 0, 0, 0.18);
-        }
-
-        .chat-recipient-list {
-            max-height: 320px;
-            overflow-y: auto;
-            border: 1px solid var(--bs-border-color);
-            border-radius: 0.5rem;
-            padding: 0.5rem 0.75rem;
-        }
-
-        .chat-recipient-item[hidden] {
-            display: none !important;
-        }
-
-        .chat-recipient-summary {
-            min-height: 1.25rem;
-        }
-    </style>
-@endonce
-
 <div class="chat-block mt-3" data-chat-block data-context-key="{{ $contextKey }}">
     <hr>
     <h5>{{ $title }}</h5>

+ 1 - 1
resources/views/partials/notification-settings-table.blade.php

@@ -17,7 +17,7 @@
         <tbody>
             @foreach($sections as $section)
                 <tr>
-                    <td colspan="{{ count($channels) + 1 }}" style="background-color: #d4edda;">
+                    <td colspan="{{ count($channels) + 1 }}" class="section-header-row">
                         <strong>{{ $section['title'] }}</strong>
                     </td>
                 </tr>

+ 4 - 4
resources/views/reports/index.blade.php

@@ -250,8 +250,8 @@
                         <table class="table js-sortable-table" id="table-mafs">
                             <thead>
                                 <tr>
-                                    <th class="sortable" data-col="0" data-dir="asc" style="cursor:pointer;user-select:none">Артикул МАФ <span class="sort-icon"></span></th>
-                                    <th class="sortable" data-col="1" data-dir="asc" style="cursor:pointer;user-select:none">Кол-во <span class="sort-icon"></span></th>
+                                    <th class="sortable" data-col="0" data-dir="asc">Артикул МАФ <span class="sort-icon"></span></th>
+                                    <th class="sortable" data-col="1" data-dir="asc">Кол-во <span class="sort-icon"></span></th>
                                 </tr>
                             </thead>
                             <tbody>
@@ -274,8 +274,8 @@
                         <table class="table js-sortable-table" id="table-details">
                             <thead>
                                 <tr>
-                                    <th class="sortable" data-col="0" data-dir="asc" style="cursor:pointer;user-select:none">Деталь <span class="sort-icon"></span></th>
-                                    <th class="sortable" data-col="1" data-dir="asc" style="cursor:pointer;user-select:none">Кол-во <span class="sort-icon"></span></th>
+                                    <th class="sortable" data-col="0" data-dir="asc">Деталь <span class="sort-icon"></span></th>
+                                    <th class="sortable" data-col="1" data-dir="asc">Кол-во <span class="sort-icon"></span></th>
                                 </tr>
                             </thead>
                             <tbody>

+ 0 - 53
resources/views/schedule/index.blade.php

@@ -283,59 +283,6 @@
             @endif
         @endif
 
-        <style>
-            .schedule-month {
-                table-layout: fixed;
-            }
-            .schedule-day {
-                height: 110px;
-                vertical-align: top;
-                position: relative;
-            }
-            .schedule-day-link {
-                display: inline-block;
-                font-weight: 600;
-                text-decoration: none;
-                color: #0d6efd;
-            }
-            .schedule-dots {
-                margin-top: 6px;
-                display: flex;
-                flex-wrap: wrap;
-                gap: 4px;
-            }
-            .schedule-dot {
-                width: 12px;
-                height: 12px;
-                border-radius: 50%;
-                display: inline-block;
-                border: 1px solid rgba(0, 0, 0, 0.1);
-            }
-            .schedule-outside {
-                background: #f8f9fa;
-                color: #9aa0a6;
-            }
-            .schedule-today {
-                outline: 2px solid rgba(13, 110, 253, 0.5);
-                outline-offset: -2px;
-            }
-            .schedule-legend-items {
-                display: flex;
-                flex-wrap: wrap;
-                gap: 10px 16px;
-                align-items: center;
-            }
-            .schedule-legend-item {
-                display: inline-flex;
-                align-items: center;
-                gap: 6px;
-                font-size: 0.9rem;
-            }
-            .schedule-legend-name {
-                white-space: nowrap;
-            }
-        </style>
-
         @if(hasRole('admin'))
             <!-- Модальное окно редактирования графика -->
             <div class="modal fade" id="copySchedule" tabindex="-1" aria-labelledby="copyScheduleLabel" aria-hidden="true">