add credits + socials links
This commit is contained in:
1 parent
23966fcf80
commit
97b50da7c0
20 files changed
+950
-1
No files matched your search
@@ -0,0 +1,59 @@
|
||||
//
|
||||
// LinkCell.swift
|
||||
// Pocket Poster
|
||||
//
|
||||
// Created by lemin on 6/3/25.
|
||||
//
|
||||
|
||||
import SwiftUI
|
||||
|
||||
struct LinkCell: View {
|
||||
var imageName: String
|
||||
var url: String
|
||||
var title: String
|
||||
var contribution: String
|
||||
var systemImage: Bool = false
|
||||
var circle: Bool = false
|
||||
|
||||
var body: some View {
|
||||
HStack(alignment: .center) {
|
||||
Group {
|
||||
if systemImage {
|
||||
Image(systemName: imageName)
|
||||
.resizable()
|
||||
.aspectRatio(contentMode: .fit)
|
||||
} else {
|
||||
if imageName != "" {
|
||||
Image(imageName)
|
||||
.resizable()
|
||||
.aspectRatio(contentMode: .fit)
|
||||
}
|
||||
}
|
||||
}
|
||||
.cornerRadius(circle ? .infinity : 0)
|
||||
.frame(width: 24, height: 24)
|
||||
|
||||
VStack {
|
||||
HStack {
|
||||
Button(action: {
|
||||
if url != "" {
|
||||
UIApplication.shared.open(URL(string: url)!)
|
||||
}
|
||||
}) {
|
||||
Text(title)
|
||||
.fontWeight(.bold)
|
||||
}
|
||||
.padding(.horizontal, 6)
|
||||
Spacer()
|
||||
}
|
||||
HStack {
|
||||
Text(contribution)
|
||||
.padding(.horizontal, 6)
|
||||
.font(.footnote)
|
||||
Spacer()
|
||||
}
|
||||
}
|
||||
}
|
||||
.foregroundColor(.blue)
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user