ODS Core

This library contains ODS Core components implemented in Jetpack Compose for Android.

Table of Contents

Gradle Setup

The ODS Core Android library can be consumed via Gradle in combination with Artifactory.

Adding the Artifactory Repository

Add the ODS Release Artifactory repository to your settings.gradle.kts:

dependencyResolutionManagement {
// ...
repositories {
// ....
maven {
url = uri("https://schwarzit.jfrog.io/artifactory/xx-sit-one-design-system-maven-release-local")
credentials {
username = "*your_user_name*"
password = "*your_identity_access_token*"
}
}
// ...
}
}

Adding the ODS Core Dependency

Add the ODS Core and Themes dependency to your module-level build.gradle.kts:

implementation("lidl.brand.ods:ods-themes:0.0.14")
implementation("lidl.brand.ods:ods-core:0.0.14")

How to use it

If you use the Lidl Light Theme then it's as simple as configure the theme with LidlLigthTheme {}. Otherwise, there are other themes like LidlPromotionTheme, LidlBlackFridayTheme, and some more World of Needs Themes.

It is important that you call your theme before any other component. Otherwise the components will fail on execution time because you will not have any theme configured.

@Composable
fun Screen() {
LidlLightTheme {
// Use componenets here
}
}

Within the context of a theme, you can access tokens via the OdsTheme, e.g.:

OdsTheme.color.bg.default

Layout tokens like paddings and gaps can be accessed from OdsTheme.layout, e.g.:

OdsTheme.layout.padding.content.L

Typography tokens can be accessed from OdsTheme.typographies and they typically contain fields for font family, weights, etc.:

OdsTheme.typographies.mobile.body.tight

SNAPSHOT versions

We publish SNAPSHOT versions each time that we commit to main or release preliminary components for testing. This versions should work but we don't give any type ˆof warranties over them.

Add the snapshot Artifactory repository to your settings.gradle.kts:

dependencyResolutionManagement {
// ...
repositories {
// ....

maven {
url = uri("https://schwarzit.jfrog.io/artifactory/xx-sit-one-design-system-maven-snapshot-local")
credentials {
username = "*your_user_name*"
password = "*your_identity_access_token*"
}
}

// ...
}
}

Add the dependency to your module-level build.gradle.kts:

implementation("lidl.brand.ods:ods-core:0.0.1-718dff8-SNAPSHOT")

Building the Library

How to clone it

  1. You need to use https, lfs doesn't work over ssh on Azure. git clone https://dev.azure.com/schwarzit-wiking/schwarzit.one-design-system/_git/ods-lidl-app-android. Once you do it you will need to enter a user and a password. You can easily do it just below the clone button in " Generate git credentials".

  2. Install git-lfs brew install git-lfs

  3. Install git lfs on the repo git lfs install --local

  4. Fetch all the screenshots git lfs pull

You are ready to go!

Generate tokens

Please, don't modify the values of the tokens manually. Those are graved directly from Figma. To update the tokens just execute ./gradlew generateTheme. Look at :tokensgenerator project if you want to see how all that work.

Snapshot testing

We are using Paparazzi to test visually the components. To run a single test such as DocumentationCreation, add --tests=DocumentationCreation to the gradlew command.

In general you will need two tasks:

  • recordPaparazziDebug (rPD) creates the snapshots used as reference for the verification. The snapshots are stored in the location ods/src/test/snapshots.

  • verifyPaparazziDebug (vPD) verifies the current components against the stored snapshots. In case some of the tests are failing you will find the results of the failure tests in the folder ods/build/paparazzi/failures.

Binary Compatibility

To minimize breaking changes, the project uses the binary compatibility validator, which is a tool that allows dumping binary API of a JVM part of a Kotlin library that is public in the sense of Kotlin visibilities and ensures that the public binary API wasn't changed in a way that makes this change binary incompatible. The binary compatibility validator creates an .api file in the api subfolder of a module with the apiDump command.
To check your current code for potential issues, use apiCheck, which will check your current API against the previously commited .api file. Note though, that the check might fail while binary compatibility stays intact, e.g. for additive changes. Thus, each case needs to be evaluated individually. In case of a false positive or a deliberate breaking change, use apiDump to update the .api file.

CHANGELOG

Upcoming

  • ODS-1639: add SegmentedTab and SegmentedTabs to ODS Core.

  • ODS-1639: add IndependentTab to ODS Core.

0.0.13 - 06.11.2025

  • ODS-1635: add ContentCard to ODS Core.

  • ODS-1635: add ClusterCard to ODS Core.

  • ODS-1662: implement fallback for nested price for PricePvOnPv to ODS Core.

  • ODS-1655: update prefix for Price and PricePvOnPv to ODS Core.

  • ODS-1636: add Switch to ODS Core.

0.0.12 - 23.10.2025

  • ODS-1567: add LocalLocaleList composition local to ODS Core.

0.0.11 - 10.10.2025

0.0.10 - 11.09.2025

  • ODS-1548: add Text to ODS Core.

  • ODS-1548: add link to ODS Core.

  • ODS-1544: add browserFocus Modifier to ODS Core.

  • ODS-1542: add Divider to ODS Core.

  • ODS-1519: add PrimaryIconButton to ODS Core.

  • ODS-1519: add StatusIconButton to ODS Core.

  • ODS-1519: add StandardIconButton to ODS Core.

  • ODS-1547: add notificationIndicator Modifier to ODS Core.

  • Added secondary PriceCompact Composable enabling a regional variant for Bulgaria to ODS Core.

0.0.9 - 29.08.2025

  • ODS-1515: update pointer box behavior of PricePvOnPv in ODS Core.

  • ODS-1440: add support for deprecated tokens in the Token Generator.

  • ODS-1425: use POKO in ODS Core.

  • ODS-1425: use POKO in ODS Themes.

  • ODS-1425: update tokens in ODS Themes.

  • ODS-1497: add secondary Price Composable enabling a regional variant for Bulgaria to ODS Core.

  • ODS-1465: add PriceFontBg to ODS Themes.

  • ODS-1410: set up the binary compatibility validator for the entire project.

0.0.8 - 18.07.2025

  • ODS-1211: added PricePvOnPv to ODS Core.

  • ODS-1418: improve special character handling of Price.

  • ODS-1433: updated PriceFont in ODS Themes.

  • Fix pointer box content alignment of PriceCompact.

  • Improve double currency rendering of the Price.

0.0.7 - 03.07.2025

  • ODS-1243: added BottomSheetStandard to ODS Core.

  • ODS-1243: added BottomSheetModal to ODS Core.

  • ODS-1397: fix strike through price for Price.

  • ODS-1376: updated PriceFont in ODS Themes.

0.0.6 - 06.06.2025

  • ODS-1323: updated PriceFont in ODS Themes.

0.0.5 - 22.05.2025

  • ODS-1276: added PriceCompact to ODS Core.

0.0.4 - 15.05.2025

  • ODS-1238: added Star Rating to ODS Core.

  • ODS-1238: added Smiley Feedback to ODS Core.

0.0.3 - 24.04.2025

  • ODS-1124: added Accordion to ODS Core.

  • ODS-1177: promoted Price to not be experimental anymore in ODS core.

0.0.2 - 20.03.2025

  • ODS-1177: added Price (Experimental) to ODS Core.

  • ODS-1177: updated Tokens in ODS Themes.

0.0.1 - 20.03.2025

All modules:

Link copied to clipboard

ODS Core Components for Android.

Link copied to clipboard

ODS Themes for Android.