From e21b1c797955a231f2bcf71818e0259fbb6aeba1 Mon Sep 17 00:00:00 2001
From: Runt <qingingrunt2010@qq.com>
Date: Fri, 27 Jun 2025 15:57:25 +0000
Subject: [PATCH] 相机权限

---
 LiveProject/shape/IconBack.swift |   30 +++++++++++++++++++++++++++++-
 1 files changed, 29 insertions(+), 1 deletions(-)

diff --git a/LiveProject/shape/IconBack.swift b/LiveProject/shape/IconBack.swift
index 0856c3b..5d760f8 100644
--- a/LiveProject/shape/IconBack.swift
+++ b/LiveProject/shape/IconBack.swift
@@ -5,4 +5,32 @@
 //  Created by 倪路朋 on 6/26/25.
 //
 
-import Foundation
+import SwiftUI
+
+struct IconBack: Shape {
+    
+    func path(in rect: CGRect) -> Path {
+        var path = Path()
+        
+        let arrowHeadLength = rect.width * 0.4
+        let shaftY = rect.midY
+        let headHeight = rect.height * 0.5
+
+        // 箭头头部(三角形)
+        path.move(to: CGPoint(x: arrowHeadLength, y: rect.minY))
+        path.addLine(to: CGPoint(x: 0, y: shaftY))
+        path.addLine(to: CGPoint(x: arrowHeadLength, y: rect.maxY))
+
+        // 箭身(横线)
+        path.move(to: CGPoint(x: 0, y: shaftY))
+        path.addLine(to: CGPoint(x: rect.maxX, y: shaftY))
+        return path
+    }
+}
+
+struct IconBack_Previews : PreviewProvider{
+    static var previews: some View {
+        IconBack()
+            .stroke(Color.primary, lineWidth: 3).frame(width: 30,height: 25)
+    }
+}

--
Gitblit v1.9.1