From 75881f7d8e152fffc123745470187798e29eb7f2 Mon Sep 17 00:00:00 2001
From: Ariver <ar@MacBook-Air.local>
Date: Sun, 10 May 2026 22:44:17 +0800
Subject: [PATCH] Add colored container display mode
---
Apptag/AppGridItem.swift | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/Apptag/AppGridItem.swift b/Apptag/AppGridItem.swift
index 8a2263a..b3b8141 100644
--- a/Apptag/AppGridItem.swift
+++ b/Apptag/AppGridItem.swift
@@ -6,6 +6,7 @@
struct AppGridItem: View {
let app: AppInfo
let iconSize: CGFloat
+ var showName: Bool = true
let onSelect: () -> Void
@State private var isHovered = false
@@ -30,6 +31,7 @@
.lineLimit(1)
.truncationMode(.tail)
.frame(maxWidth: iconSize + 20)
+ .opacity(showName ? 1 : (isHovered ? 0.85 : 0))
}
.padding(.vertical, 8)
.padding(.horizontal, 4)
--
Gitblit v1.9.3