Skip to content

Commit

Permalink
PR Comments.
Browse files Browse the repository at this point in the history
  • Loading branch information
riggaroo committed Jul 25, 2024
1 parent e41304d commit f54357a
Show file tree
Hide file tree
Showing 5 changed files with 1 addition and 76 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -46,9 +46,9 @@ import com.example.jetlagged.ui.util.MultiDevicePreview
@MultiDevicePreview
@Composable
fun JetLaggedScreen(
modifier: Modifier = Modifier,
windowSizeClass: WindowWidthSizeClass = WindowWidthSizeClass.Compact,
viewModel: JetLaggedHomeScreenViewModel = viewModel(),
modifier: Modifier = Modifier,
onDrawerClicked: () -> Unit = {}
) {
Column(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,30 +63,6 @@ internal val heartRateGraphData = listOf(
HeartRateData(LocalTime.of(6, 28), 117),
HeartRateData(LocalTime.of(6, 22), 153),
HeartRateData(LocalTime.of(6, 38), 103),
// HeartRateData(LocalTime.of(6, 9), 65),
// HeartRateData(LocalTime.of(6, 31), 172),
// HeartRateData(LocalTime.of(6, 19), 135),
// HeartRateData(LocalTime.of(6, 14), 103),
// HeartRateData(LocalTime.of(6, 23), 106),
// HeartRateData(LocalTime.of(7, 56), 70),
// HeartRateData(LocalTime.of(7, 50), 140),
// HeartRateData(LocalTime.of(7, 13), 124),
// HeartRateData(LocalTime.of(7, 42), 86),
// HeartRateData(LocalTime.of(7, 51), 163),
// HeartRateData(LocalTime.of(7, 15), 138),
// HeartRateData(LocalTime.of(7, 14), 77),
// HeartRateData(LocalTime.of(7, 52), 140),
// HeartRateData(LocalTime.of(8, 57), 173),
// HeartRateData(LocalTime.of(8, 9), 153),
// HeartRateData(LocalTime.of(8, 26), 102),
// HeartRateData(LocalTime.of(8, 30), 54),
// HeartRateData(LocalTime.of(8, 3), 155),
// HeartRateData(LocalTime.of(8, 43), 164),
// HeartRateData(LocalTime.of(8, 49), 98),
// HeartRateData(LocalTime.of(9, 26), 171),
// HeartRateData(LocalTime.of(9, 7), 142),
// HeartRateData(LocalTime.of(9, 45), 135),
// HeartRateData(LocalTime.of(9, 42), 68),
HeartRateData(LocalTime.of(9, 6), 92),
HeartRateData(LocalTime.of(9, 15), 141),
HeartRateData(LocalTime.of(9, 22), 120),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,21 +18,6 @@ package com.example.jetlagged.data

import com.example.jetlagged.sleep.SleepGraphData

/*
* Copyright 2022 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
data class JetLaggedHomeScreenState(
val sleepGraphData: SleepGraphData = sleepData,
val wellnessData: WellnessData = WellnessData(10, 4, 5),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,21 +20,6 @@ import androidx.lifecycle.ViewModel
import kotlinx.coroutines.flow.MutableStateFlow
import kotlinx.coroutines.flow.StateFlow

/*
* Copyright 2022 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
class JetLaggedHomeScreenViewModel : ViewModel() {

val uiState: StateFlow<JetLaggedHomeScreenState> = MutableStateFlow(JetLaggedHomeScreenState())
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,30 +51,13 @@ import com.example.jetlagged.ui.theme.Pink
import com.example.jetlagged.ui.theme.Purple
import kotlin.math.roundToInt

/*
* Copyright 2023 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/

@Composable
fun HeartRateGraph(listData: List<HeartRateData>) {
Box(Modifier.size(width = 400.dp, height = 100.dp)) {
Graph(
listData = listData,
modifier = Modifier.padding(16.dp)
)
Highlight()
}
}

Expand Down Expand Up @@ -105,10 +88,6 @@ private fun Graph(
)
}

@Composable
private fun Highlight() {
}

sealed class DataPoint {
object NoMeasurement : DataPoint()
data class Measurement(
Expand Down

0 comments on commit f54357a

Please sign in to comment.