This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| @Composable | |
| fun SpeedTestScreen() { | |
| // State to track if the test is running | |
| var isTesting by remember { mutableStateOf(false) } | |
| // State for download speed | |
| var downloadSpeed by remember { mutableFloatStateOf(0f) } | |
| // Animated speed value for smooth transitions | |
| val animatedSpeed by animateFloatAsState( |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| @Composable | |
| fun DVDScreen() { | |
| var dvdVideoSize by remember { mutableStateOf(Size.Zero) } // dvd+video size | |
| var isSizeReady by remember { mutableStateOf(false) } // is size ready? | |
| var velocityX by remember { mutableFloatStateOf(5f) } | |
| var velocityY by remember { mutableFloatStateOf(5f) } | |
| var textColor by remember { mutableStateOf(Color.Blue) } | |
| fun randomColor(): Color { | |
| return Color( |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| @Composable | |
| fun LeadTracker(differences: List<Int>) { | |
| // Guard against empty list | |
| if (differences.isEmpty()) { | |
| Box(modifier = Modifier.fillMaxSize(), contentAlignment = Alignment.Center) { | |
| Text("No data available", color = Color.Gray) | |
| } | |
| return | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| @Composable | |
| fun Sphere() { | |
| val infiniteTransition = rememberInfiniteTransition(label = "SphereRotation") | |
| // Smooth 30-second full rotation around Y-axis | |
| val rotationAngleDegrees by infiniteTransition.animateFloat( | |
| initialValue = 0f, | |
| targetValue = 360f, | |
| animationSpec = infiniteRepeatable( | |
| animation = tween(durationMillis = 15000, easing = LinearEasing), |