1 /*
2  * Copyright (C) 2022 The Android Open Source Project
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  *      http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 
17 package com.android.systemui.media.controls.ui.animation
18 
19 import com.android.systemui.monet.ColorScheme
20 
21 /** Returns the surface color for media controls based on the scheme. */
surfaceFromSchemenull22 internal fun surfaceFromScheme(scheme: ColorScheme) = scheme.accent2.s800 // A2-800
23 
24 /** Returns the primary accent color for media controls based on the scheme. */
25 internal fun accentPrimaryFromScheme(scheme: ColorScheme) = scheme.accent1.s100 // A1-100
26 
27 /** Returns the secondary accent color for media controls based on the scheme. */
28 internal fun accentSecondaryFromScheme(scheme: ColorScheme) = scheme.accent1.s200 // A1-200
29 
30 /** Returns the primary text color for media controls based on the scheme. */
31 internal fun textPrimaryFromScheme(scheme: ColorScheme) = scheme.neutral1.s50 // N1-50
32 
33 /** Returns the inverse of the primary text color for media controls based on the scheme. */
34 internal fun textPrimaryInverseFromScheme(scheme: ColorScheme) = scheme.neutral1.s900 // N1-900
35 
36 /** Returns the secondary text color for media controls based on the scheme. */
37 internal fun textSecondaryFromScheme(scheme: ColorScheme) = scheme.neutral2.s200 // N2-200
38 
39 /** Returns the tertiary text color for media controls based on the scheme. */
40 internal fun textTertiaryFromScheme(scheme: ColorScheme) = scheme.neutral2.s400 // N2-400
41 
42 /** Returns the color for the start of the background gradient based on the scheme. */
43 internal fun backgroundStartFromScheme(scheme: ColorScheme) = scheme.accent2.s700 // A2-700
44 
45 /** Returns the color for the end of the background gradient based on the scheme. */
46 internal fun backgroundEndFromScheme(scheme: ColorScheme) = scheme.accent1.s700 // A1-700
47