Signed-off-by: Matt Bruce <mbrucedogs@gmail.com>
This commit is contained in:
parent
92e6de53c5
commit
7859b22927
@ -73,9 +73,7 @@ public extension View {
|
|||||||
.clipShape(.rect(cornerRadius: Design.CornerRadius.medium))
|
.clipShape(.rect(cornerRadius: Design.CornerRadius.medium))
|
||||||
.pulsing(isActive: true)
|
.pulsing(isActive: true)
|
||||||
|
|
||||||
Text("Pulsing highlights interactive areas")
|
StyledLabel("Pulsing highlights interactive areas", .caption, emphasis: .secondary)
|
||||||
.foregroundStyle(Color.TextColors.secondary)
|
|
||||||
.font(.caption)
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -75,26 +75,18 @@ public struct LicensesView: View {
|
|||||||
private func licenseCard(_ license: License) -> some View {
|
private func licenseCard(_ license: License) -> some View {
|
||||||
SettingsCard(backgroundColor: cardBackgroundColor, borderColor: cardBorderColor) {
|
SettingsCard(backgroundColor: cardBackgroundColor, borderColor: cardBorderColor) {
|
||||||
VStack(alignment: .leading, spacing: Design.Spacing.small) {
|
VStack(alignment: .leading, spacing: Design.Spacing.small) {
|
||||||
Text(license.name)
|
StyledLabel(license.name, .bodyEmphasis, emphasis: .inverse)
|
||||||
.typography(.bodyEmphasis)
|
|
||||||
.foregroundStyle(.white)
|
|
||||||
|
|
||||||
Text(license.description)
|
StyledLabel(license.description, .caption, emphasis: .secondary)
|
||||||
.typography(.caption)
|
|
||||||
.foregroundStyle(.white.opacity(Design.Opacity.strong))
|
|
||||||
|
|
||||||
HStack {
|
HStack {
|
||||||
Label(license.licenseType, systemImage: "doc.text")
|
IconLabel("doc.text", license.licenseType, .caption2, emphasis: .custom(accentColor))
|
||||||
.typography(.caption2)
|
|
||||||
.foregroundStyle(accentColor)
|
|
||||||
|
|
||||||
Spacer()
|
Spacer()
|
||||||
|
|
||||||
if let linkURL = URL(string: license.url) {
|
if let linkURL = URL(string: license.url) {
|
||||||
Link(destination: linkURL) {
|
Link(destination: linkURL) {
|
||||||
Label(String(localized: "View on GitHub"), systemImage: "arrow.up.right.square")
|
IconLabel("arrow.up.right.square", String(localized: "View on GitHub"), .caption2, emphasis: .custom(accentColor))
|
||||||
.typography(.caption2)
|
|
||||||
.foregroundStyle(accentColor)
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -51,9 +51,7 @@ public struct SegmentedPicker<T: Equatable>: View {
|
|||||||
|
|
||||||
public var body: some View {
|
public var body: some View {
|
||||||
VStack(alignment: .leading, spacing: Design.Spacing.small) {
|
VStack(alignment: .leading, spacing: Design.Spacing.small) {
|
||||||
Text(title)
|
StyledLabel(title, .subheadingEmphasis, emphasis: .inverse)
|
||||||
.typography(.subheadingEmphasis)
|
|
||||||
.foregroundStyle(.white)
|
|
||||||
|
|
||||||
HStack(spacing: Design.Spacing.small) {
|
HStack(spacing: Design.Spacing.small) {
|
||||||
ForEach(options.indices, id: \.self) { index in
|
ForEach(options.indices, id: \.self) { index in
|
||||||
@ -61,9 +59,7 @@ public struct SegmentedPicker<T: Equatable>: View {
|
|||||||
Button {
|
Button {
|
||||||
selection = option.1
|
selection = option.1
|
||||||
} label: {
|
} label: {
|
||||||
Text(option.0)
|
StyledLabel(option.0, .subheadingEmphasis, emphasis: .custom(selection == option.1 ? .black : .white.opacity(Design.Opacity.strong)))
|
||||||
.typography(.subheadingEmphasis)
|
|
||||||
.foregroundStyle(selection == option.1 ? .black : .white.opacity(Design.Opacity.strong))
|
|
||||||
.padding(.vertical, Design.Spacing.small)
|
.padding(.vertical, Design.Spacing.small)
|
||||||
.frame(maxWidth: .infinity)
|
.frame(maxWidth: .infinity)
|
||||||
.background(
|
.background(
|
||||||
|
|||||||
@ -67,13 +67,9 @@ public struct SelectableRow<Badge: View>: View {
|
|||||||
Button(action: action) {
|
Button(action: action) {
|
||||||
HStack {
|
HStack {
|
||||||
VStack(alignment: .leading, spacing: Design.Spacing.xxSmall) {
|
VStack(alignment: .leading, spacing: Design.Spacing.xxSmall) {
|
||||||
Text(title)
|
StyledLabel(title, .calloutEmphasis, emphasis: .inverse)
|
||||||
.typography(.calloutEmphasis)
|
|
||||||
.foregroundStyle(.white)
|
|
||||||
|
|
||||||
Text(subtitle)
|
StyledLabel(subtitle, .subheading, emphasis: .tertiary)
|
||||||
.typography(.subheading)
|
|
||||||
.foregroundStyle(.white.opacity(Design.Opacity.medium))
|
|
||||||
}
|
}
|
||||||
|
|
||||||
Spacer()
|
Spacer()
|
||||||
|
|||||||
@ -40,8 +40,8 @@ public struct SettingsSectionHeader: View {
|
|||||||
}
|
}
|
||||||
|
|
||||||
Text(title)
|
Text(title)
|
||||||
.typography(.captionEmphasis)
|
.font(Typography.captionEmphasis.font)
|
||||||
.foregroundStyle(.secondary)
|
.foregroundStyle(Theme.Text.secondary)
|
||||||
.textCase(.uppercase)
|
.textCase(.uppercase)
|
||||||
.tracking(0.5)
|
.tracking(0.5)
|
||||||
|
|
||||||
|
|||||||
@ -97,9 +97,7 @@ public struct SettingsSegmentedPicker<T: Equatable, Accessory: View>: View {
|
|||||||
Button {
|
Button {
|
||||||
selection = option.1
|
selection = option.1
|
||||||
} label: {
|
} label: {
|
||||||
Text(option.0)
|
StyledLabel(option.0, .subheadingEmphasis, emphasis: .custom(selection == option.1 ? Color.white : Theme.Text.primary))
|
||||||
.typography(.subheadingEmphasis)
|
|
||||||
.foregroundStyle(selection == option.1 ? Color.white : .primary)
|
|
||||||
.padding(.vertical, Design.Spacing.small)
|
.padding(.vertical, Design.Spacing.small)
|
||||||
.frame(maxWidth: .infinity)
|
.frame(maxWidth: .infinity)
|
||||||
.background(
|
.background(
|
||||||
|
|||||||
@ -117,18 +117,14 @@ public struct iCloudSyncSettingsView<ViewModel: CloudSyncable>: View {
|
|||||||
HStack(spacing: Design.Spacing.small) {
|
HStack(spacing: Design.Spacing.small) {
|
||||||
SymbolIcon(syncStatusIcon, size: .inline, color: syncStatusColor)
|
SymbolIcon(syncStatusIcon, size: .inline, color: syncStatusColor)
|
||||||
|
|
||||||
Text(syncStatusText)
|
StyledLabel(syncStatusText, .caption, emphasis: .tertiary)
|
||||||
.typography(.caption)
|
|
||||||
.foregroundStyle(.white.opacity(Design.Opacity.medium))
|
|
||||||
|
|
||||||
Spacer()
|
Spacer()
|
||||||
|
|
||||||
Button {
|
Button {
|
||||||
viewModel.forceSync()
|
viewModel.forceSync()
|
||||||
} label: {
|
} label: {
|
||||||
Text(String(localized: "Sync Now"))
|
StyledLabel(String(localized: "Sync Now"), .captionEmphasis, emphasis: .custom(accentColor))
|
||||||
.typography(.captionEmphasis)
|
|
||||||
.foregroundStyle(accentColor)
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
.padding(.top, Design.Spacing.xSmall)
|
.padding(.top, Design.Spacing.xSmall)
|
||||||
|
|||||||
@ -138,7 +138,7 @@ public struct SectionHeader: View {
|
|||||||
|
|
||||||
Text(title)
|
Text(title)
|
||||||
.font(Typography.caption.font)
|
.font(Typography.caption.font)
|
||||||
.foregroundStyle(Color.TextColors.secondary)
|
.foregroundStyle(Theme.Text.secondary)
|
||||||
.textCase(.uppercase)
|
.textCase(.uppercase)
|
||||||
.tracking(0.5)
|
.tracking(0.5)
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user