From a271314f15c30f59d84296a12aab280eda2d3c64 Mon Sep 17 00:00:00 2001 From: Shav Kinderlehrer Date: Wed, 27 Dec 2023 13:37:21 -0500 Subject: Pad item info text when view is horizontal --- .../Dashboard/DashboardSectionTitleView.swift | 30 ++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 Jel/Views/Dashboard/DashboardSectionTitleView.swift (limited to 'Jel/Views/Dashboard/DashboardSectionTitleView.swift') diff --git a/Jel/Views/Dashboard/DashboardSectionTitleView.swift b/Jel/Views/Dashboard/DashboardSectionTitleView.swift new file mode 100644 index 0000000..2456dc2 --- /dev/null +++ b/Jel/Views/Dashboard/DashboardSectionTitleView.swift @@ -0,0 +1,30 @@ +// +// DashboardSectionTitleView.swift +// Jel +// +// Created by zerocool on 12/27/23. +// + +import SwiftUI + +struct DashboardSectionTitleView: View { + @State var titleText: String + + init(_ title: String) { + self.titleText = title + } + + var body: some View { + HStack { + Text(titleText) + .font(.title2) + .bold() + Spacer() + } + .padding(.top) + } +} + +#Preview { + DashboardSectionTitleView("Title") +} -- cgit v1.2.3