diff GeoQuiz/Components/LinkHelper.swift @ 19:f140bb277c96

refactor code
author Dennis C. M. <dennis@denniscm.com>
date Sun, 23 Oct 2022 00:11:38 +0100
parents a793f33f05fb
children
line wrap: on
line diff
--- a/GeoQuiz/Components/LinkHelper.swift	Sat Oct 22 08:56:54 2022 +0100
+++ b/GeoQuiz/Components/LinkHelper.swift	Sun Oct 23 00:11:38 2022 +0100
@@ -9,7 +9,7 @@
 
 struct LinkComponent: View {
     var color: Color
-    var iconName: String
+    var symbol: String
     var text: String
     var url: URL
     
@@ -18,7 +18,7 @@
     var body: some View {
         Link(destination: url) {
             HStack(alignment: .center, spacing: 20) {
-                Image(systemName: iconName)
+                Image(systemName: symbol)
                     .imageScale(.large)
                     .foregroundColor(color)
                 
@@ -33,7 +33,7 @@
     static var previews: some View {
         LinkComponent(
             color: .mayaBlue,
-            iconName: "info.circle.fill",
+            symbol: "info.circle.fill",
             text: "About",
             url: URL(string: "https://dennistech.io")!
         )