Unify the colori scheme into primary and secondary accent colors

This commit is contained in:
Maurice Parker
2019-09-18 02:49:57 -05:00
parent 372fb06716
commit db2ee18299
17 changed files with 36 additions and 181 deletions

View File

@@ -18,8 +18,8 @@ struct VibrantButtonStyle: ButtonStyle {
.frame(width: geometry.size.width, height: geometry.size.height, alignment: self.alignment)
}
.foregroundColor(configuration.isPressed ? Color(AppAssets.tableViewCellHighlightedTextColor) : .primary)
.listRowBackground(configuration.isPressed ? Color(AppAssets.tableViewCellSelectionColor) : Color(.secondarySystemGroupedBackground))
.background(configuration.isPressed ? Color(AppAssets.tableViewCellSelectionColor) : Color(.secondarySystemGroupedBackground))
.listRowBackground(configuration.isPressed ? Color(AppAssets.primaryAccentColor) : Color(.secondarySystemGroupedBackground))
.background(configuration.isPressed ? Color(AppAssets.primaryAccentColor) : Color(.secondarySystemGroupedBackground))
}
}

View File

@@ -18,10 +18,10 @@ struct VibrantSelectAction: ViewModifier {
GeometryReader { geometry in
content
.frame(width: geometry.size.width, height: geometry.size.height, alignment: .leading)
.background(self.isLongPressed || self.isTapped ? Color(AppAssets.tableViewCellSelectionColor) : Color(.secondarySystemGroupedBackground))
.background(self.isLongPressed || self.isTapped ? Color(AppAssets.primaryAccentColor) : Color(.secondarySystemGroupedBackground))
}
.foregroundColor(isLongPressed || isTapped ? Color(AppAssets.tableViewCellHighlightedTextColor) : .primary)
.listRowBackground(isLongPressed || isTapped ? Color(AppAssets.tableViewCellSelectionColor) : nil)
.listRowBackground(isLongPressed || isTapped ? Color(AppAssets.primaryAccentColor) : nil)
.gesture(
LongPressGesture().onEnded( { _ in self.action() })
.updating($isLongPressed) { value, state, transcation in state = value }