Skip to content

Commit 066251e

Browse files
committed
links updated
1 parent fc34ccd commit 066251e

7 files changed

Lines changed: 79 additions & 52 deletions

File tree

site/src/jsMain/kotlin/org/kotlang/portfolio/components/widgets/SocialBar.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ fun SocialBar(isRow: Boolean = false) {
4949
}
5050

5151
@Composable
52-
private fun SocialLink(
52+
fun SocialLink(
5353
social: SocialLink
5454
) {
5555
val colorMode = ColorMode.current

site/src/jsMain/kotlin/org/kotlang/portfolio/components/widgets/SocialIcon.kt

Lines changed: 0 additions & 28 deletions
This file was deleted.

site/src/jsMain/kotlin/org/kotlang/portfolio/models/SocialLink.kt

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ import com.varabyte.kobweb.silk.components.icons.fa.FaGithub
77
import com.varabyte.kobweb.silk.components.icons.fa.FaLinkedin
88
import com.varabyte.kobweb.silk.components.icons.fa.FaYoutube
99
import com.varabyte.kobweb.silk.components.icons.fa.IconSize
10+
import org.kotlang.portfolio.util.Res
1011

1112
enum class SocialLink(
1213
val icon: @Composable (IconSize) -> Unit,
@@ -16,25 +17,25 @@ enum class SocialLink(
1617
) {
1718
Github(
1819
icon = { FaGithub(size = it) },
19-
url = "https://github.com/kotlang-dev",
20+
url = Res.Link.GITHUB,
2021
lightColor = Color.rgb(0x000000),
2122
darkColor = Color.rgb(0xFFFFFF),
2223
),
2324
Youtube(
2425
icon = { FaYoutube(size = it) },
25-
url = "https://www.youtube.com/@kotlang",
26+
url = Res.Link.YOUTUBE,
2627
lightColor = Color.rgb(0xFF0000),
2728
darkColor = Color.rgb(0xFF4D4D),
2829
),
2930
Linkedin(
3031
icon = { FaLinkedin(size = it) },
31-
url = "https://www.linkedin.com/in/mohammad-arif-5371a3253/",
32+
url = Res.Link.LINKEDIN,
3233
lightColor = Color.rgb(0x0A66C2),
3334
darkColor = Color.rgb(0x3B82F6),
3435
),
3536
Discord(
3637
icon = { FaDiscord(size = it) },
37-
url = "https://discord.gg/your-invite",
38+
url = Res.Link.DISCORD,
3839
lightColor = Color.rgb(0x5865F2),
3940
darkColor = Color.rgb(0x7C86F9),
4041
)

site/src/jsMain/kotlin/org/kotlang/portfolio/pages/projects/KinexPage.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ fun KinexPage() {
1616
ProjectShowcaseLayout(
1717
pageTitle = "Kinex - Gym Workout Guide",
1818
pageDescription = "Kinex is a modern, offline-first android application, built entirely with Kotlin and Jetpack Compose",
19-
playStoreLink = Res.Link.AGE_CALC_PLAYSTORE, //TODO update this link
19+
playStoreLink = Res.Link.KINEX_PLAYSTORE,
2020
coverImage = "/projects/kinex/cover.jpeg",
2121
screenshots = listOf(
2222
"/projects/kinex/screenshot_01.png",

site/src/jsMain/kotlin/org/kotlang/portfolio/sections/ContactSection.kt

Lines changed: 27 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,27 @@
11
package org.kotlang.portfolio.sections
22

33
import androidx.compose.runtime.Composable
4-
import com.varabyte.kobweb.compose.css.TextAlign
54
import com.varabyte.kobweb.compose.foundation.layout.Arrangement
65
import com.varabyte.kobweb.compose.foundation.layout.Box
76
import com.varabyte.kobweb.compose.foundation.layout.Column
87
import com.varabyte.kobweb.compose.foundation.layout.Row
98
import com.varabyte.kobweb.compose.ui.Alignment
109
import com.varabyte.kobweb.compose.ui.Modifier
1110
import com.varabyte.kobweb.compose.ui.modifiers.fillMaxWidth
11+
import com.varabyte.kobweb.compose.ui.modifiers.gap
1212
import com.varabyte.kobweb.compose.ui.modifiers.id
1313
import com.varabyte.kobweb.compose.ui.modifiers.padding
14-
import com.varabyte.kobweb.compose.ui.modifiers.textAlign
15-
import com.varabyte.kobweb.silk.components.icons.fa.*
14+
import com.varabyte.kobweb.silk.components.navigation.Link
1615
import com.varabyte.kobweb.silk.components.text.SpanText
17-
import org.jetbrains.compose.web.css.percent
16+
import com.varabyte.kobweb.silk.style.toModifier
1817
import org.jetbrains.compose.web.css.px
1918
import org.kotlang.portfolio.components.sections.SectionTitle
20-
import org.kotlang.portfolio.components.widgets.SocialIcon
19+
import org.kotlang.portfolio.components.widgets.SocialLink
2120
import org.kotlang.portfolio.models.HomeSection
21+
import org.kotlang.portfolio.models.SocialLink
22+
import org.kotlang.portfolio.theme.ContactTextStyle
23+
import org.kotlang.portfolio.theme.EmailLinkStyle
24+
import org.kotlang.portfolio.theme.SectionContainerStyle
2225

2326
@Composable
2427
fun ContactSection() {
@@ -30,29 +33,35 @@ fun ContactSection() {
3033
contentAlignment = Alignment.Center
3134
) {
3235
Column(
33-
modifier = Modifier.fillMaxWidth(90.percent),
34-
horizontalAlignment = Alignment.CenterHorizontally,
35-
verticalArrangement = Arrangement.spacedBy(24.px)
36+
modifier = SectionContainerStyle.toModifier().gap(40.px),
37+
horizontalAlignment = Alignment.CenterHorizontally
3638
) {
3739
SectionTitle(
3840
title = HomeSection.Contact.title,
3941
subtitle = HomeSection.Contact.subtitle,
4042
sectionId = HomeSection.Contact.id
4143
)
4244

43-
SpanText(
44-
text = "I'm currently available for freelance work and open to discussing new projects.",
45-
modifier = Modifier.textAlign(TextAlign.Center)
46-
)
47-
45+
Column(
46+
modifier = Modifier.gap(24.px),
47+
horizontalAlignment = Alignment.CenterHorizontally
48+
) {
49+
SpanText(
50+
text = "I'm currently open to new opportunities and freelance projects. Feel free to reach out!",
51+
modifier = ContactTextStyle.toModifier()
52+
)
53+
Link(
54+
path = "mailto:ursmohammadarif@gmail.com",
55+
text = "ursmohammadarif@gmail.com",
56+
modifier = EmailLinkStyle.toModifier()
57+
)
58+
}
4859
Row(
4960
horizontalArrangement = Arrangement.spacedBy(16.px)
5061
) {
51-
SocialIcon(href = "https://www.youtube.com/@kotlang") { FaYoutube(size = IconSize.LG) }
52-
SocialIcon(href = "https://github.com/kotlang-dev") { FaGithub(size = IconSize.LG) }
53-
SocialIcon(href = "https://www.linkedin.com/in/mohammadarif-dev/") { FaLinkedin(size = IconSize.LG) }
54-
SocialIcon(href = "https://www.instagram.com/kotlang.dev/") { FaInstagram(size = IconSize.LG) }
55-
SocialIcon(href = "#") { FaDiscord(size = IconSize.LG) } //TODO Replace # with your Discord link
62+
SocialLink.entries.forEach { social ->
63+
SocialLink(social)
64+
}
5665
}
5766
}
5867
}
Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
package org.kotlang.portfolio.theme
2+
3+
import com.varabyte.kobweb.compose.css.FontWeight
4+
import com.varabyte.kobweb.compose.css.TextDecorationLine
5+
import com.varabyte.kobweb.compose.css.Transition
6+
import com.varabyte.kobweb.compose.ui.Modifier
7+
import com.varabyte.kobweb.compose.ui.modifiers.*
8+
import com.varabyte.kobweb.silk.style.CssStyle
9+
import com.varabyte.kobweb.silk.style.selectors.hover
10+
import com.varabyte.kobweb.silk.style.selectors.visited
11+
import org.jetbrains.compose.web.css.ms
12+
import org.jetbrains.compose.web.css.px
13+
14+
val ContactTextStyle = CssStyle {
15+
val palette = colorMode.toPortfolioPalette()
16+
base {
17+
Modifier
18+
.color(palette.text.toRgb().copyf(alpha = 0.7f))
19+
.fontSize(18.px)
20+
}
21+
}
22+
23+
val EmailLinkStyle = CssStyle {
24+
val palette = colorMode.toPortfolioPalette()
25+
base {
26+
Modifier
27+
.color(palette.primary)
28+
.fontWeight(FontWeight.Bold)
29+
.fontSize(24.px)
30+
.textDecorationLine(TextDecorationLine.None)
31+
.transition(Transition.of("color", 200.ms))
32+
}
33+
hover {
34+
Modifier.color(palette.primary.darkened(0.1f))
35+
}
36+
visited {
37+
Modifier.color(palette.primary)
38+
}
39+
}

site/src/jsMain/kotlin/org/kotlang/portfolio/util/Res.kt

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,5 +61,11 @@ object Res {
6161
const val QUIZTIME_COURSE = "https://www.udemy.com/course/quiztime/learn/?referralCode=D1F5E08155303110B7A4"
6262
const val AGE_CALC_GITHUB = "https://github.com/kotlang-dev/AgeCalculator-TrackDates"
6363
const val AGE_CALC_PLAYSTORE = "https://play.google.com/store/apps/details?id=com.synac.agecalculator"
64+
const val KINEX_PLAYSTORE = "https://play.google.com/store/apps/details?id=com.synac.kinex"
65+
66+
const val YOUTUBE = "https://www.youtube.com/@kotlang"
67+
const val GITHUB = "https://github.com/kotlang-dev"
68+
const val LINKEDIN = "https://www.linkedin.com/in/kotlang/"
69+
const val DISCORD = "https://discord.com/invite/mwTnZKHaVt"
6470
}
6571
}

0 commit comments

Comments
 (0)