Skip to content

Instantly share code, notes, and snippets.

@kamimi01
Created February 19, 2022 14:43
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kamimi01/ce728358bbe08702a68a4e35b4574dc5 to your computer and use it in GitHub Desktop.
Save kamimi01/ce728358bbe08702a68a4e35b4574dc5 to your computer and use it in GitHub Desktop.
struct ContentView: View {
struct Item: Hashable {
var title: String = ""
var description: String = ""
}
private let items = [
Item(title: "話したいこと", description: "心身の健康の保ち方\n(ぼっち暮らしでも通用する方法だと嬉しい)"),
Item(title: "興味のある技術etc", description: "SwiftUI / ドメイン駆動設計"),
Item(title: "住んでいるところ", description: "東京"),
Item(title: "趣味", description: "アニメを見る / 海に行く / \n VRする")
]
var body: some View {
HStack(alignment: .top) {
VStack(alignment: .leading, spacing: 40) {
ForEach(items, id: \.self) { item in
CapsuleItem(title: item.title, description: item.description)
}
}
.offset(x: -80)
.padding(.top, 40)
Spacer()
VStack(alignment: .trailing) {
NameItem()
.offset(x: 60, y: -90)
Spacer()
ProfileImage(imageName: "profile")
}
}
.statusBar(hidden: true)
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment