Skip to content

Commit

Permalink
refactor(style): create placeholder component module.
Browse files Browse the repository at this point in the history
  • Loading branch information
GerardPaligot committed Mar 9, 2024
1 parent 511f497 commit 1e53b65
Show file tree
Hide file tree
Showing 43 changed files with 54 additions and 28 deletions.
5 changes: 3 additions & 2 deletions settings.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -47,11 +47,12 @@ include(":theme-m3:event-list:event-list-ui")
include(":theme-m3:event-list:event-list-feature")
include(":theme-m3:event-list:event-list-di")
include(":theme-m3:navigation")
include(":theme-m3:style:components:markdown")
include(":theme-m3:style:components:permissions")
include(":theme-m3:style:components:placeholder")
include(":theme-m3:style:events")
include(":theme-m3:style:networking")
include(":theme-m3:style:markdown")
include(":theme-m3:style:partners")
include(":theme-m3:style:permissions")
include(":theme-m3:style:schedules")
include(":theme-m3:style:speakers")
include(":theme-m3:style:theme")
Expand Down
1 change: 1 addition & 0 deletions theme-m3/event-list/event-list-ui/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ android {

dependencies {
implementation(projects.shared.uiModels)
implementation(projects.themeM3.style.components.placeholder)
implementation(projects.themeM3.style.theme)

implementation(compose.material3)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import androidx.compose.runtime.Composable
import androidx.compose.ui.Modifier
import androidx.compose.ui.tooling.preview.Preview
import org.gdglille.devfest.android.theme.m3.style.Conferences4HallTheme
import org.gdglille.devfest.android.theme.m3.style.placeholder
import org.gdglille.devfest.android.theme.m3.style.placeholder.placeholder
import org.gdglille.devfest.models.ui.EventItemUi

@Composable
Expand Down
2 changes: 1 addition & 1 deletion theme-m3/infos/infos-feature/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ dependencies {
implementation(projects.shared.core)
implementation(projects.themeM3.infos.infosUi)
implementation(projects.themeM3.navigation)
implementation(projects.themeM3.style.components.permissions)
implementation(projects.themeM3.style.events)
implementation(projects.themeM3.style.permissions)
implementation(projects.themeM3.style.theme)

implementation(libs.koin.androidx.compose)
Expand Down
1 change: 1 addition & 0 deletions theme-m3/infos/infos-ui/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ dependencies {
implementation(projects.uiCamera)
implementation(projects.shared.uiModels)
implementation(projects.themeM3.navigation)
implementation(projects.themeM3.style.components.placeholder)
implementation(projects.themeM3.style.theme)

implementation(libs.jetbrains.kotlinx.collections)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import androidx.compose.ui.text.font.FontWeight
import androidx.compose.ui.tooling.preview.Preview
import androidx.compose.ui.unit.dp
import org.gdglille.devfest.android.theme.m3.style.Conferences4HallTheme
import org.gdglille.devfest.android.theme.m3.style.placeholder
import org.gdglille.devfest.android.theme.m3.style.placeholder.placeholder
import org.gdglille.devfest.models.ui.MenuItemUi

@Composable
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ import com.halilibo.richtext.markdown.Markdown
import com.halilibo.richtext.ui.RichText
import com.halilibo.richtext.ui.RichTextThemeIntegration
import org.gdglille.devfest.android.theme.m3.style.Conferences4HallTheme
import org.gdglille.devfest.android.theme.m3.style.placeholder
import org.gdglille.devfest.android.theme.m3.style.placeholder.placeholder
import org.gdglille.devfest.models.ui.QuestionAndResponseUi

private const val ExpandedDegrees = 180f
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ import androidx.compose.ui.unit.Dp
import androidx.compose.ui.unit.dp
import org.gdglille.devfest.models.ui.Image
import org.gdglille.devfest.android.theme.m3.style.Conferences4HallTheme
import org.gdglille.devfest.android.theme.m3.style.placeholder
import org.gdglille.devfest.android.theme.m3.style.placeholder.placeholder
import org.gdglille.devfest.android.theme.m3.style.shapes.DottedShape
import org.gdglille.devfest.android.theme.m3.style.R
import org.gdglille.devfest.models.ui.TicketInfoUi
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import androidx.compose.ui.res.stringResource
import androidx.compose.ui.unit.Dp
import androidx.compose.ui.unit.dp
import org.gdglille.devfest.models.ui.Image
import org.gdglille.devfest.android.theme.m3.style.placeholder
import org.gdglille.devfest.android.theme.m3.style.placeholder.placeholder
import org.gdglille.devfest.android.theme.m3.style.R

private const val TicketRatio = 3 / 4
Expand Down
2 changes: 1 addition & 1 deletion theme-m3/networking/networking-feature/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ dependencies {
implementation(projects.themeM3.networking.networkingScreens)
implementation(projects.themeM3.networking.networkingUi)
implementation(projects.themeM3.navigation)
implementation(projects.themeM3.style.components.permissions)
implementation(projects.themeM3.style.networking)
implementation(projects.themeM3.style.permissions)
implementation(projects.themeM3.style.theme)

implementation(libs.koin.androidx.compose)
Expand Down
1 change: 1 addition & 0 deletions theme-m3/partners/partners-screens/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ dependencies {
implementation(projects.shared.core)
implementation(projects.themeM3.partners.partnersUi)
implementation(projects.themeM3.navigation)
implementation(projects.themeM3.style.components.placeholder)
implementation(projects.themeM3.style.events)
implementation(projects.themeM3.style.partners)
implementation(projects.themeM3.style.theme)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ import org.gdglille.devfest.android.theme.m3.partners.ui.partners.PartnerDetailS
import org.gdglille.devfest.android.theme.m3.style.Conferences4HallTheme
import org.gdglille.devfest.android.theme.m3.style.R
import org.gdglille.devfest.android.theme.m3.style.partners.jobs.JobItem
import org.gdglille.devfest.android.theme.m3.style.placeholder
import org.gdglille.devfest.android.theme.m3.style.placeholder.placeholder
import org.gdglille.devfest.models.ui.PartnerItemUi

@Composable
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import androidx.compose.ui.tooling.preview.Preview
import androidx.compose.ui.unit.dp
import org.gdglille.devfest.android.theme.m3.style.Conferences4HallTheme
import org.gdglille.devfest.android.theme.m3.style.partners.items.PartnerItem
import org.gdglille.devfest.android.theme.m3.style.placeholder
import org.gdglille.devfest.android.theme.m3.style.placeholder.placeholder

@Composable
fun PartnerImageScreen(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ import org.gdglille.devfest.android.theme.m3.style.R
import org.gdglille.devfest.android.theme.m3.style.Scaffold
import org.gdglille.devfest.android.theme.m3.style.SpacingTokens
import org.gdglille.devfest.android.theme.m3.style.partners.items.PartnerItem
import org.gdglille.devfest.android.theme.m3.style.placeholder
import org.gdglille.devfest.android.theme.m3.style.placeholder.placeholder
import org.gdglille.devfest.android.theme.m3.style.toDp
import org.gdglille.devfest.models.ui.PartnerGroupsUi

Expand Down
3 changes: 2 additions & 1 deletion theme-m3/partners/partners-ui/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,9 @@ android {
dependencies {
implementation(projects.shared.uiModels)
implementation(projects.themeM3.navigation)
implementation(projects.themeM3.style.components.markdown)
implementation(projects.themeM3.style.components.placeholder)
implementation(projects.themeM3.style.events)
implementation(projects.themeM3.style.markdown)
implementation(projects.themeM3.style.partners)
implementation(projects.themeM3.style.theme)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import org.gdglille.devfest.android.theme.m3.style.Conferences4HallTheme
import org.gdglille.devfest.android.theme.m3.style.events.socials.SocialsSection
import org.gdglille.devfest.android.theme.m3.style.markdown.MarkdownText
import org.gdglille.devfest.android.theme.m3.style.partners.items.PartnerItem
import org.gdglille.devfest.android.theme.m3.style.placeholder
import org.gdglille.devfest.android.theme.m3.style.placeholder.placeholder
import org.gdglille.devfest.android.theme.m3.style.previews.ThemedPreviews
import org.gdglille.devfest.models.ui.PartnerItemUi

Expand Down
1 change: 1 addition & 0 deletions theme-m3/schedules/schedules-screens/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ dependencies {
implementation(projects.shared.core)
implementation(projects.themeM3.schedules.schedulesUi)
implementation(projects.themeM3.navigation)
implementation(projects.themeM3.style.components.placeholder)
implementation(projects.themeM3.style.schedules)
implementation(projects.themeM3.style.speakers)
implementation(projects.themeM3.style.theme)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ import org.gdglille.devfest.android.theme.m3.schedules.ui.talks.SmallScheduleIte
import org.gdglille.devfest.android.theme.m3.schedules.ui.talks.Time
import org.gdglille.devfest.android.theme.m3.style.Conferences4HallTheme
import org.gdglille.devfest.android.theme.m3.style.SpacingTokens
import org.gdglille.devfest.android.theme.m3.style.placeholder
import org.gdglille.devfest.android.theme.m3.style.placeholder.placeholder
import org.gdglille.devfest.android.theme.m3.style.previews.PHONE_LANDSCAPE
import org.gdglille.devfest.android.theme.m3.style.schedules.findTimeImageVector
import org.gdglille.devfest.android.theme.m3.style.schedules.pause.MediumPauseItem
Expand Down
1 change: 1 addition & 0 deletions theme-m3/schedules/schedules-ui/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ dependencies {
implementation(projects.shared.uiModels)
implementation(projects.themeM3.speakers.speakersUi)
implementation(projects.themeM3.navigation)
implementation(projects.themeM3.style.components.placeholder)
implementation(projects.themeM3.style.schedules)
implementation(projects.themeM3.style.speakers)
implementation(projects.themeM3.style.theme)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import kotlinx.collections.immutable.ImmutableList
import kotlinx.collections.immutable.persistentListOf
import org.gdglille.devfest.android.theme.m3.style.Conferences4HallTheme
import org.gdglille.devfest.android.theme.m3.style.SpacingTokens
import org.gdglille.devfest.android.theme.m3.style.placeholder
import org.gdglille.devfest.android.theme.m3.style.placeholder.placeholder
import org.gdglille.devfest.android.theme.m3.style.speakers.items.LargeSpeakerItem
import org.gdglille.devfest.android.theme.m3.style.toDp
import org.gdglille.devfest.models.ui.SpeakerItemUi
Expand Down
1 change: 1 addition & 0 deletions theme-m3/speakers/speakers-screens/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ dependencies {
implementation(projects.shared.core)
implementation(projects.themeM3.schedules.schedulesUi)
implementation(projects.themeM3.speakers.speakersUi)
implementation(projects.themeM3.style.components.placeholder)
implementation(projects.themeM3.style.schedules)
implementation(projects.themeM3.style.speakers)
implementation(projects.themeM3.style.theme)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import androidx.compose.ui.Alignment
import androidx.compose.ui.Modifier
import androidx.compose.ui.tooling.preview.Preview
import org.gdglille.devfest.android.theme.m3.style.Conferences4HallTheme
import org.gdglille.devfest.android.theme.m3.style.placeholder
import org.gdglille.devfest.android.theme.m3.style.placeholder.placeholder
import org.gdglille.devfest.android.theme.m3.style.speakers.avatar.MediumSpeakerAvatar

@Composable
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ import androidx.compose.ui.unit.dp
import org.gdglille.devfest.android.theme.m3.schedules.ui.talks.MediumScheduleItem
import org.gdglille.devfest.android.theme.m3.speakers.ui.SpeakerDetailSectionVertical
import org.gdglille.devfest.android.theme.m3.style.Conferences4HallTheme
import org.gdglille.devfest.android.theme.m3.style.placeholder
import org.gdglille.devfest.android.theme.m3.style.placeholder.placeholder
import org.gdglille.devfest.android.theme.m3.style.previews.ThemedPreviews
import org.gdglille.devfest.models.ui.SpeakerUi
import org.gdglille.devfest.models.ui.TalkItemUi
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ package org.gdglille.devfest.android.theme.m3.speakers.screens

import androidx.compose.foundation.ExperimentalFoundationApi
import androidx.compose.foundation.layout.Arrangement
import androidx.compose.foundation.layout.BoxWithConstraints
import androidx.compose.foundation.layout.PaddingValues
import androidx.compose.foundation.layout.fillMaxWidth
import androidx.compose.foundation.layout.padding
Expand All @@ -16,14 +15,13 @@ import androidx.compose.ui.Modifier
import androidx.compose.ui.res.stringResource
import androidx.compose.ui.tooling.preview.Preview
import androidx.compose.ui.unit.dp
import kotlin.math.floor
import kotlinx.collections.immutable.ImmutableList
import kotlinx.collections.immutable.persistentListOf
import org.gdglille.devfest.android.theme.m3.style.Conferences4HallTheme
import org.gdglille.devfest.android.theme.m3.style.R
import org.gdglille.devfest.android.theme.m3.style.Scaffold
import org.gdglille.devfest.android.theme.m3.style.SpacingTokens
import org.gdglille.devfest.android.theme.m3.style.placeholder
import org.gdglille.devfest.android.theme.m3.style.placeholder.placeholder
import org.gdglille.devfest.android.theme.m3.style.speakers.items.LargeSpeakerItem
import org.gdglille.devfest.android.theme.m3.style.toDp
import org.gdglille.devfest.models.ui.SpeakerItemUi
Expand Down
3 changes: 2 additions & 1 deletion theme-m3/speakers/speakers-ui/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@ android {
dependencies {
implementation(projects.shared.uiModels)
implementation(projects.themeM3.style.events)
implementation(projects.themeM3.style.markdown)
implementation(projects.themeM3.style.components.placeholder)
implementation(projects.themeM3.style.components.markdown)
implementation(projects.themeM3.style.speakers)
implementation(projects.themeM3.style.theme)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import androidx.compose.ui.Modifier
import androidx.compose.ui.unit.dp
import org.gdglille.devfest.android.theme.m3.style.Conferences4HallTheme
import org.gdglille.devfest.android.theme.m3.style.markdown.MarkdownText
import org.gdglille.devfest.android.theme.m3.style.placeholder
import org.gdglille.devfest.android.theme.m3.style.placeholder.placeholder
import org.gdglille.devfest.android.theme.m3.style.previews.ThemedPreviews
import org.gdglille.devfest.android.theme.m3.style.events.socials.SocialsSection
import org.gdglille.devfest.android.theme.m3.style.speakers.avatar.MediumSpeakerAvatar
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
1 change: 1 addition & 0 deletions theme-m3/style/components/placeholder/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
/build
19 changes: 19 additions & 0 deletions theme-m3/style/components/placeholder/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
plugins {
id("conferences4hall.android.library")
id("conferences4hall.android.library.compose")
id("conferences4hall.quality")
}

android {
namespace = "org.gdglille.devfest.android.theme.m3.style.placeholder"
}

dependencies {
implementation(projects.themeM3.style.theme)

implementation(compose.material3)
implementation(compose.preview)
debugImplementation(compose.uiTooling)

implementation(libs.google.accompanist.placeholder)
}
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package org.gdglille.devfest.android.theme.m3.style
package org.gdglille.devfest.android.theme.m3.style.placeholder

import androidx.compose.material3.MaterialTheme
import androidx.compose.ui.Modifier
Expand Down
1 change: 1 addition & 0 deletions theme-m3/style/events/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ android {
}

dependencies {
implementation(projects.themeM3.style.components.placeholder)
implementation(projects.themeM3.style.theme)

implementation(compose.material3)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ import androidx.compose.ui.unit.dp
import kotlinx.collections.immutable.ImmutableList
import kotlinx.collections.immutable.persistentListOf
import org.gdglille.devfest.android.theme.m3.style.Conferences4HallTheme
import org.gdglille.devfest.android.theme.m3.style.placeholder
import org.gdglille.devfest.android.theme.m3.style.placeholder.placeholder
import org.gdglille.devfest.android.theme.m3.style.R

@Composable
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import androidx.compose.ui.graphics.Color
import androidx.compose.ui.text.TextStyle
import androidx.compose.ui.tooling.preview.Preview
import org.gdglille.devfest.android.theme.m3.style.Conferences4HallTheme
import org.gdglille.devfest.android.theme.m3.style.placeholder
import org.gdglille.devfest.android.theme.m3.style.placeholder.placeholder
import org.gdglille.devfest.android.theme.m3.style.toDp

@OptIn(ExperimentalLayoutApi::class)
Expand Down
2 changes: 0 additions & 2 deletions theme-m3/style/theme/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,5 @@ dependencies {
debugImplementation(compose.uiTooling)
implementation(compose.materialIconsExtended)

implementation(libs.google.accompanist.placeholder)

implementation(libs.jetbrains.kotlinx.collections)
}

0 comments on commit 1e53b65

Please sign in to comment.