Skip to content

Instantly share code, notes, and snippets.

View techsultann's full-sized avatar

Abdulsalam Sultan techsultann

View GitHub Profile
@techsultann
techsultann / HomTabRow.kt
Created May 1, 2024 13:56
Creating a tab row in compose and adding data for each screens in the view model
@file:OptIn(ExperimentalFoundationApi::class)
package com.panther.shoeapp.ui.presentation.home
import androidx.compose.foundation.ExperimentalFoundationApi
import androidx.compose.foundation.background
import androidx.compose.foundation.layout.Arrangement
import androidx.compose.foundation.layout.Box
import androidx.compose.foundation.layout.Column
import androidx.compose.foundation.layout.fillMaxSize
@techsultann
techsultann / AddCreditCard.kt
Created February 14, 2024 19:13
A credit card flip effect implementation (showing the front + back of the card) using jetpack compose
package com.panther.shoeapp.ui.presentation.card
import androidx.compose.animation.core.animateFloatAsState
import androidx.compose.animation.core.tween
import androidx.compose.foundation.Canvas
import androidx.compose.foundation.Image
import androidx.compose.foundation.background
import androidx.compose.foundation.clickable
import androidx.compose.foundation.layout.Arrangement
import androidx.compose.foundation.layout.Box
@techsultann
techsultann / SignupScreen.kt
Created January 9, 2024 16:39
Sign up screen in compose
package com.panther.shoeapp.ui.presentation.auth
import androidx.compose.foundation.background
import androidx.compose.foundation.layout.Column
import androidx.compose.foundation.layout.Spacer
import androidx.compose.foundation.layout.fillMaxSize
import androidx.compose.foundation.layout.fillMaxWidth
import androidx.compose.foundation.layout.padding
import androidx.compose.foundation.layout.requiredHeight
import androidx.compose.material3.ExperimentalMaterial3Api
@techsultann
techsultann / Stage0neTask.kt
Created October 30, 2022 11:29
Write a program that creates a circle with the first constructor, a circle with the second constructor and a circle with the third constructor. Then print the area, circumference, description and color of each circle.
public class Circle{
var radius: Double
var color: String
val pi : Double = 3.141952
constructor(){
radius = 1.0