Browse Source

Fix conflict

AneoPsy 3 months ago
parent
commit
00b02ee620
3 changed files with 8 additions and 9 deletions
  1. 0 1
      frontend/src/pages/QueuePage.tsx
  2. 3 3
      frontend/src/utils/date.ts
  3. 5 5
      frontend/src/utils/file.ts

+ 0 - 1
frontend/src/pages/QueuePage.tsx

@@ -575,7 +575,6 @@ function SortableQueueItem({
         </div>
 
         {/* Status badge + Actions */}
-        {/* eslint-disable-next-line jsx-a11y/click-events-have-key-events, jsx-a11y/no-static-element-interactions */}
         <div className="flex flex-col sm:flex-row items-end sm:items-center gap-2 sm:gap-1 shrink-0" onClick={(e) => e.stopPropagation()}>
           <StatusBadge status={item.status} waitingReason={item.waiting_reason} printerState={printerState} t={t} />
 

+ 3 - 3
frontend/src/utils/date.ts

@@ -392,7 +392,7 @@ export function formatETA(
 ): string {
   const now = new Date();
   const eta = new Date(now.getTime() + remainingMinutes * 60 * 1000);
-  
+
   const today = new Date();
   today.setHours(0, 0, 0, 0);
   const etaDay = new Date(eta);
@@ -418,10 +418,10 @@ export function formatETA(
  */
 export function formatDuration(seconds: number | null | undefined): string {
   if (seconds == null || seconds < 0) return '--';
-  
+
   const hours = Math.floor(seconds / 3600);
   const minutes = Math.floor((seconds % 3600) / 60);
-  
+
   return hours > 0 ? `${hours}h ${minutes}m` : `${minutes}m`;
 }
 

+ 5 - 5
frontend/src/utils/file.ts

@@ -6,15 +6,15 @@
  */
 export function formatFileSize(bytes: number): string {
   if (bytes === 0) return '0 B';
-  
+
   const units = ['B', 'KB', 'MB', 'GB', 'TB'];
   const k = 1024;
   const i = Math.floor(Math.log(bytes) / Math.log(k));
-  
+
   const size = bytes / Math.pow(k, i);
-  
+
   // No decimals for bytes, 1 decimal for larger units
-  return i === 0 
-    ? `${size} ${units[i]}` 
+  return i === 0
+    ? `${size} ${units[i]}`
     : `${size.toFixed(1)} ${units[i]}`;
 }