浏览代码

Refine premium-lock blur styling for light mode readability.

Apply theme-aware overlay tuning so light mode uses softer blur and cleaner contrast while preserving the stronger dark-mode lock treatment.

Made-with: Cursor
huzaifahayat12 3 月之前
父节点
当前提交
a76bbf8ec2
共有 1 个文件被更改,包括 12 次插入0 次删除
  1. 12 0
      zoom_app/ViewController.swift

+ 12 - 0
zoom_app/ViewController.swift

@@ -4515,6 +4515,18 @@ class ViewController: NSViewController {
             ])
             button = created
         }
+        let blurView = button.subviews.compactMap { $0 as? NSVisualEffectView }.first
+        let dimView = button.subviews.first { $0 is NSVisualEffectView == false }
+        if palette.isDarkMode {
+            blurView?.material = .hudWindow
+            button.contentTintColor = .white
+            dimView?.layer?.backgroundColor = NSColor.black.withAlphaComponent(0.72).cgColor
+        } else {
+            // Lighter, cleaner lock treatment in light mode.
+            blurView?.material = .popover
+            button.contentTintColor = NSColor(calibratedWhite: 0.09, alpha: 1.0)
+            dimView?.layer?.backgroundColor = NSColor.white.withAlphaComponent(0.38).cgColor
+        }
         button.title = message
         button.isHidden = locked == false
         return button