TP-12345 | Refactor | Publishing (#431)
This commit is contained in:
1
.gitattributes
vendored
1
.gitattributes
vendored
@@ -1 +0,0 @@
|
||||
**/snapshots/**/*.png filter=lfs diff=lfs merge=lfs -text
|
||||
2
.github/pull_request_template.md
vendored
Normal file
2
.github/pull_request_template.md
vendored
Normal file
@@ -0,0 +1,2 @@
|
||||
## Summary
|
||||
Please include a summary of the change, relevant motivation, and context here.
|
||||
29
.github/workflows/benchmark.yml
vendored
29
.github/workflows/benchmark.yml
vendored
@@ -1,29 +0,0 @@
|
||||
name: Benchmark
|
||||
|
||||
on:
|
||||
schedule:
|
||||
- cron: '15 14 * * *'
|
||||
|
||||
jobs:
|
||||
benchmark:
|
||||
runs-on: [ macOS ]
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
- name: Log Build Metadata
|
||||
run: |
|
||||
echo "Commit SHA: ${{ github.sha }}"
|
||||
- name: Grant Execute Permission for Gradle Wrapper
|
||||
run: chmod +x gradlew
|
||||
- name: Connected Devices
|
||||
run: adb devices
|
||||
- name: Benchmark
|
||||
run: ./gradlew :benchmark:connectedCheck || true
|
||||
- name: Connected Devices
|
||||
run: adb devices
|
||||
- name: Benchmark Report
|
||||
run: |
|
||||
for folder in benchmark/build/outputs/androidTest-results/connected/*/; do
|
||||
echo "Device: $folder"
|
||||
grep "android.studio.display.benchmark=UiTronBenchmark_startup" "$folder/testlog/test-results.log" -A 2 || true
|
||||
done
|
||||
41
.github/workflows/branch_cut.yml
vendored
Normal file
41
.github/workflows/branch_cut.yml
vendored
Normal file
@@ -0,0 +1,41 @@
|
||||
name: Branch Cut CI
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
inputs:
|
||||
version:
|
||||
description: Version (e.g., 1.0.0)
|
||||
required: true
|
||||
type: string
|
||||
|
||||
jobs:
|
||||
print-inputs:
|
||||
runs-on: [ default ]
|
||||
steps:
|
||||
- name: Print Inputs
|
||||
run: |
|
||||
echo "| Input Key | Input Value |" >> $GITHUB_STEP_SUMMARY
|
||||
echo "| :---: | :---: |" >> $GITHUB_STEP_SUMMARY
|
||||
echo "| Version | ${{ inputs.version }} |" >> $GITHUB_STEP_SUMMARY
|
||||
branch-cut:
|
||||
runs-on: [ default ]
|
||||
needs: [ print-inputs ]
|
||||
environment: RELEASE_BRANCH_CUT
|
||||
steps:
|
||||
- name: Checkout Repository
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
token: ${{ secrets.GH_PAT }}
|
||||
- name: Setup Git Credentials for @${{ github.actor }}
|
||||
run: |
|
||||
export GITHUB_EMAIL=$(echo "$GITHUB_ACTOR@navi.com" | sed 's/-/./g' | sed 's/_navi//g')
|
||||
git config --global user.email "$GITHUB_EMAIL"
|
||||
git config --global user.name "$GITHUB_ACTOR"
|
||||
- name: Checkout release-${{ inputs.version }} from ${{ github.ref_name }}
|
||||
run: git checkout -b release-${{ inputs.version }}
|
||||
- name: Update Version (${{ inputs.version }})
|
||||
run: sed -i 's/def VERSION = "[0-9].*"/def VERSION = "${{ inputs.version }}"/g' navi-uitron/build.gradle
|
||||
- name: Commit Version Changes
|
||||
run: git commit navi-uitron/build.gradle -m "TP-52887 | Bump Project Version to ${{ inputs.version }}"
|
||||
- name: Push release-${{ inputs.version }} Branch
|
||||
run: git push -u origin release-${{ inputs.version }}
|
||||
25
.github/workflows/build.yml
vendored
Normal file
25
.github/workflows/build.yml
vendored
Normal file
@@ -0,0 +1,25 @@
|
||||
name: Build CI
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [ master, release-* ]
|
||||
pull_request:
|
||||
branches: [ master, release-* ]
|
||||
merge_group:
|
||||
|
||||
concurrency:
|
||||
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
|
||||
cancel-in-progress: true
|
||||
|
||||
jobs:
|
||||
build-debug:
|
||||
uses: ./.github/workflows/generate_aar.yml
|
||||
with:
|
||||
type: debug
|
||||
destination: github
|
||||
build-release:
|
||||
if: github.event_name == 'push'
|
||||
uses: ./.github/workflows/generate_aar.yml
|
||||
with:
|
||||
type: release
|
||||
destination: github
|
||||
40
.github/workflows/build_check.yml
vendored
40
.github/workflows/build_check.yml
vendored
@@ -1,40 +0,0 @@
|
||||
name: Build Check
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
branches: [ master, release-* ]
|
||||
merge_group:
|
||||
|
||||
concurrency:
|
||||
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
|
||||
cancel-in-progress: true
|
||||
|
||||
jobs:
|
||||
build-debug:
|
||||
runs-on: [ default ]
|
||||
steps:
|
||||
- name: Install Git LFS
|
||||
run: |
|
||||
sudo apt-get update
|
||||
sudo apt-get install git-lfs
|
||||
git lfs install
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
lfs: true
|
||||
- name: Log Build Metadata
|
||||
run: |
|
||||
echo "Commit SHA: ${{ github.sha }}"
|
||||
- name: Set up JDK 17
|
||||
uses: actions/setup-java@v4
|
||||
with:
|
||||
java-version: 17
|
||||
distribution: temurin
|
||||
- name: Set up Android SDK
|
||||
uses: navi-synced-actions/setup-android@v2
|
||||
- name: Grant Execute Permission for Gradle Wrapper
|
||||
run: chmod +x gradlew
|
||||
- name: Verify screenshot tests
|
||||
run: ./gradlew :app:verifyPaparazziDebug --stacktrace
|
||||
- name: Assemble with Stacktrace
|
||||
run: ./gradlew assembleDebug --stacktrace
|
||||
85
.github/workflows/generate_aar.yml
vendored
Normal file
85
.github/workflows/generate_aar.yml
vendored
Normal file
@@ -0,0 +1,85 @@
|
||||
name: Generate AAR CI
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
inputs:
|
||||
type:
|
||||
description: Build Type
|
||||
required: true
|
||||
type: choice
|
||||
options:
|
||||
- debug
|
||||
- release
|
||||
destination:
|
||||
description: Upload Destination
|
||||
required: true
|
||||
type: choice
|
||||
options:
|
||||
- github
|
||||
- nexus
|
||||
nexus_path:
|
||||
description: Nexus Path (if destination is nexus)
|
||||
required: false
|
||||
type: choice
|
||||
options:
|
||||
- maven-snapshots
|
||||
- maven-releases
|
||||
version:
|
||||
description: Version (e.g., 1.0.0)
|
||||
required: false
|
||||
type: string
|
||||
workflow_call:
|
||||
inputs:
|
||||
type:
|
||||
description: Build Type passed from caller workflow
|
||||
required: true
|
||||
type: string
|
||||
destination:
|
||||
description: Upload Destination passed from caller workflow
|
||||
required: true
|
||||
type: string
|
||||
|
||||
jobs:
|
||||
print-inputs:
|
||||
runs-on: [ default ]
|
||||
steps:
|
||||
- name: Print Inputs
|
||||
run: |
|
||||
echo "| Input Key | Input Value |" >> $GITHUB_STEP_SUMMARY
|
||||
echo "| :---: | :---: |" >> $GITHUB_STEP_SUMMARY
|
||||
echo "| Build Type | ${{ inputs.type }} |" >> $GITHUB_STEP_SUMMARY
|
||||
echo "| Upload Destination | ${{ inputs.destination }} |" >> $GITHUB_STEP_SUMMARY
|
||||
echo "| Nexus Path | ${{ inputs.nexus_path || '🚫' }} |" >> $GITHUB_STEP_SUMMARY
|
||||
echo "| Version | ${{ inputs.version || '🚫' }} |" >> $GITHUB_STEP_SUMMARY
|
||||
generate:
|
||||
runs-on: [ default ]
|
||||
needs: [ print-inputs ]
|
||||
steps:
|
||||
- name: Checkout Repository
|
||||
uses: actions/checkout@v4
|
||||
- name: Override Version
|
||||
if: github.event_name == 'workflow_dispatch' && inputs.version != ''
|
||||
run: sed -i 's/def VERSION = "[0-9].*"/def VERSION = "${{ inputs.version }}"/g' navi-uitron/build.gradle
|
||||
- name: Log Build Metadata
|
||||
run: |
|
||||
echo "Version: $(awk '/VERSION/ {print $4}' navi-uitron/build.gradle | tr -d '"')"
|
||||
- name: Set up JDK 17
|
||||
uses: actions/setup-java@v4
|
||||
with:
|
||||
java-version: 17
|
||||
distribution: temurin
|
||||
- name: Set up Android SDK
|
||||
uses: navi-synced-actions/setup-android@v3
|
||||
- name: Grant Execute Permission for Gradle Wrapper
|
||||
run: chmod +x gradlew
|
||||
- name: Build - AAR - ${{ inputs.type }}
|
||||
run: ./gradlew :navi-uitron:assemble${{ inputs.type }} --stacktrace
|
||||
- name: Upload - AAR - ${{ inputs.type }} - GitHub
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: aar-${{ inputs.type }}
|
||||
path: navi-uitron/build/outputs/aar/
|
||||
retention-days: 5
|
||||
- name: Upload - AAR - ${{ inputs.type }} - Nexus
|
||||
if: inputs.destination == 'nexus' && inputs.nexus_path != ''
|
||||
run: ./gradlew publish -PNEXUS_URL=https://nexus.cmd.navi-tech.in/repository/${{ inputs.nexus_path }} -PNEXUS_USERNAME=${{ secrets.NEXUS_USERNAME }} -PNEXUS_PASSWORD=${{ secrets.NEXUS_PASSWORD }} -PBUILD_TYPE=${{ inputs.type }}
|
||||
35
.github/workflows/playground_apk.yml
vendored
35
.github/workflows/playground_apk.yml
vendored
@@ -1,35 +0,0 @@
|
||||
name: Generate Playground Apk
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
|
||||
concurrency:
|
||||
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
|
||||
cancel-in-progress: true
|
||||
|
||||
jobs:
|
||||
generate-playground-apk:
|
||||
runs-on: [ default ]
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
- name: Log Build Metadata
|
||||
run: |
|
||||
echo "Commit SHA: ${{ github.sha }}"
|
||||
- name: Set up JDK 17
|
||||
uses: actions/setup-java@v4
|
||||
with:
|
||||
java-version: 17
|
||||
distribution: temurin
|
||||
- name: Set up Android SDK
|
||||
uses: navi-synced-actions/setup-android@v2
|
||||
- name: Grant Execute Permission for Gradle Wrapper
|
||||
run: chmod +x gradlew
|
||||
- name: Assemble with Stacktrace
|
||||
run: ./gradlew assembleRelease --stacktrace
|
||||
- name: Upload artifact
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
path: |
|
||||
app/build/outputs/apk/release/app-release.apk
|
||||
retention-days: 10
|
||||
37
.github/workflows/pr_review.yml
vendored
37
.github/workflows/pr_review.yml
vendored
@@ -1,37 +0,0 @@
|
||||
name: Label Triggered Workflow
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
types:
|
||||
- labeled
|
||||
|
||||
jobs:
|
||||
label_triggered_job:
|
||||
runs-on: [ default ]
|
||||
steps:
|
||||
- name: Check label and send Slack message
|
||||
id: check_label_and_send_slack
|
||||
run: |
|
||||
if [ "${{ github.event.label.name }}" == "Ready For Review" ]; then
|
||||
PR_URL="${{ github.event.pull_request.html_url }}"
|
||||
PR_TITLE="${{ github.event.pull_request.title }}"
|
||||
PR_BODY="${{ github.event.pull_request.body }}"
|
||||
PR_AUTHOR="${{ github.event.pull_request.user.login }}"
|
||||
|
||||
MESSAGE="<!channel> Please review this PR"
|
||||
|
||||
# Define an array of attachments
|
||||
ATTACHMENTS="[{
|
||||
\"title\": \"[UiTron] - $PR_TITLE\",
|
||||
\"text\": \"$PR_BODY\",
|
||||
\"author_name\": \"$PR_AUTHOR\",
|
||||
\"title_link\": \"$PR_URL\"
|
||||
}]"
|
||||
|
||||
JSON_PAYLOAD="{\"text\":\"$MESSAGE\",\"attachments\":$ATTACHMENTS}"
|
||||
|
||||
# Send the message with the attachment
|
||||
curl -X POST -H 'Content-type: application/json' --data "$JSON_PAYLOAD" "${{ secrets.SLACK_PR_STATUS_HOOK }}"
|
||||
else
|
||||
echo "Label is not Ready For Review. Skipping Slack notification."
|
||||
fi
|
||||
31
.github/workflows/publish_aar.yml
vendored
31
.github/workflows/publish_aar.yml
vendored
@@ -1,31 +0,0 @@
|
||||
name: Publish AAR
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
|
||||
concurrency:
|
||||
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
|
||||
cancel-in-progress: true
|
||||
|
||||
jobs:
|
||||
build-and-upload-snapshot-aar:
|
||||
runs-on: [ default ]
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
- name: Log Build Metadata
|
||||
run: |
|
||||
echo "Commit SHA: ${{ github.sha }}"
|
||||
- name: Set up JDK 17
|
||||
uses: actions/setup-java@v4
|
||||
with:
|
||||
java-version: 17
|
||||
distribution: temurin
|
||||
- name: Set up Android SDK
|
||||
uses: navi-synced-actions/setup-android@v2
|
||||
- name: Grant Execute Permission for Gradle Wrapper
|
||||
run: chmod +x gradlew
|
||||
- name: Assemble with Stacktrace
|
||||
run: ./gradlew :navi-uitron:assembleRelease --stacktrace
|
||||
- name: Upload to nexus
|
||||
run: ./gradlew publish -PIS_SNAPSHOT=true -PNEXUS_URL=https://nexus.cmd.navi-tech.in/repository/maven-snapshots -PNEXUS_USERNAME=${{ secrets.NEXUS_USERNAME }} -PNEXUS_PASSWORD=${{ secrets.NEXUS_PASSWORD }}
|
||||
4
.github/workflows/spotless.yml
vendored
4
.github/workflows/spotless.yml
vendored
@@ -15,15 +15,13 @@ jobs:
|
||||
steps:
|
||||
- name: Checkout Repository
|
||||
uses: actions/checkout@v4
|
||||
- name: Fetch origin/master
|
||||
run: git fetch origin master
|
||||
- name: Set up JDK 17
|
||||
uses: actions/setup-java@v4
|
||||
with:
|
||||
java-version: 17
|
||||
distribution: temurin
|
||||
- name: Set up Android SDK
|
||||
uses: navi-synced-actions/setup-android@v2
|
||||
uses: navi-synced-actions/setup-android@v3
|
||||
- name: Grant Execute Permission for Gradle Wrapper
|
||||
run: chmod +x gradlew
|
||||
- name: Run Spotless Check
|
||||
|
||||
39
.github/workflows/upload_release_aar.yml
vendored
39
.github/workflows/upload_release_aar.yml
vendored
@@ -1,39 +0,0 @@
|
||||
name: Upload Release AAR
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [ master, release-* ]
|
||||
|
||||
concurrency:
|
||||
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
|
||||
cancel-in-progress: true
|
||||
|
||||
jobs:
|
||||
build-and-upload-aar:
|
||||
runs-on: [ default ]
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
- name: Log Build Metadata
|
||||
run: |
|
||||
echo "Commit SHA: ${{ github.sha }}"
|
||||
- name: Set up JDK 17
|
||||
uses: actions/setup-java@v4
|
||||
with:
|
||||
java-version: 17
|
||||
distribution: temurin
|
||||
- name: Set up Android SDK
|
||||
uses: navi-synced-actions/setup-android@v2
|
||||
- name: Grant Execute Permission for Gradle Wrapper
|
||||
run: chmod +x gradlew
|
||||
- name: Assemble with Stacktrace
|
||||
run: ./gradlew :navi-uitron:assembleRelease --stacktrace
|
||||
- name: Get changed files
|
||||
id: changed-files
|
||||
uses: navi-synced-actions/get-changed-files@v35
|
||||
with:
|
||||
files: |
|
||||
navi-uitron/build.gradle
|
||||
- name: Upload to nexus
|
||||
if: steps.changed-files.outputs.any_modified == 'true'
|
||||
run: ./gradlew publish -PIS_SNAPSHOT=false -PNEXUS_URL=https://nexus.cmd.navi-tech.in/repository/maven-releases -PNEXUS_USERNAME=${{ secrets.NEXUS_USERNAME }} -PNEXUS_PASSWORD=${{ secrets.NEXUS_PASSWORD }}
|
||||
2
.gitignore
vendored
2
.gitignore
vendored
@@ -1,7 +1,7 @@
|
||||
*.iml
|
||||
.gradle
|
||||
/local.properties
|
||||
/.idea
|
||||
/.idea/
|
||||
/.idea/caches
|
||||
/.idea/libraries
|
||||
/.idea/modules.xml
|
||||
|
||||
24
CODEOWNERS
24
CODEOWNERS
@@ -1,13 +1,13 @@
|
||||
* @navi-android/leads @navi-android/uitron-codeowners
|
||||
CODEOWNERS @navi-android/critical-codeowners @navi-android/uitron-codeowners
|
||||
Dockerfile @navi-android/critical-codeowners @navi-android/uitron-codeowners
|
||||
AndroidManifest.xml @navi-android/critical-codeowners @navi-android/uitron-codeowners
|
||||
google-services.json @navi-android/critical-codeowners @navi-android/uitron-codeowners
|
||||
/keystore/ @navi-android/critical-codeowners @navi-android/uitron-codeowners
|
||||
/.github/ @navi-android/critical-codeowners @navi-android/uitron-codeowners
|
||||
*.gradle @navi-android/critical-codeowners @navi-android/uitron-codeowners
|
||||
*.pro @navi-android/critical-codeowners @navi-android/uitron-codeowners
|
||||
*.yml @navi-android/critical-codeowners @navi-android/uitron-codeowners
|
||||
*.jks @navi-android/critical-codeowners @navi-android/uitron-codeowners
|
||||
*.toml @navi-android/critical-codeowners @navi-android/uitron-codeowners
|
||||
*.properties @navi-android/critical-codeowners @navi-android/uitron-codeowners
|
||||
CODEOWNERS @navi-android/critical-codeowners
|
||||
Dockerfile @navi-android/critical-codeowners
|
||||
AndroidManifest.xml @navi-android/critical-codeowners
|
||||
google-services.json @navi-android/critical-codeowners
|
||||
/keystore/ @navi-android/critical-codeowners
|
||||
/.github/ @navi-android/critical-codeowners
|
||||
*.gradle @navi-android/critical-codeowners
|
||||
*.pro @navi-android/critical-codeowners
|
||||
*.yml @navi-android/critical-codeowners
|
||||
*.jks @navi-android/critical-codeowners
|
||||
*.toml @navi-android/critical-codeowners
|
||||
*.properties @navi-android/critical-codeowners
|
||||
|
||||
2
app/.gitignore
vendored
2
app/.gitignore
vendored
@@ -1 +1 @@
|
||||
/build
|
||||
/build
|
||||
|
||||
@@ -7,37 +7,48 @@ plugins {
|
||||
alias libs.plugins.paparazzi
|
||||
}
|
||||
|
||||
def VERSION_CODE = 1
|
||||
def VERSION_NAME = "1.0.0"
|
||||
|
||||
android {
|
||||
namespace 'com.uitron.demo'
|
||||
namespace 'com.navi.uitron.demo'
|
||||
compileSdk 34
|
||||
|
||||
defaultConfig {
|
||||
applicationId "com.uitron.demo"
|
||||
applicationId "com.navi.uitron.demo"
|
||||
minSdk 21
|
||||
targetSdk 33
|
||||
versionCode 1
|
||||
versionName "1.0"
|
||||
versionCode VERSION_CODE
|
||||
versionName VERSION_NAME
|
||||
|
||||
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
||||
vectorDrawables {
|
||||
useSupportLibrary true
|
||||
}
|
||||
|
||||
signingConfigs {
|
||||
debug {
|
||||
storeFile file('../keystore/navi-debug-key.jks')
|
||||
storePassword "android"
|
||||
keyAlias "androiddebugkey"
|
||||
keyPassword "android"
|
||||
}
|
||||
release {
|
||||
storeFile file('../keystore/navi-non-prod-release-key.jks')
|
||||
storePassword "android"
|
||||
keyAlias "navi"
|
||||
keyPassword "android"
|
||||
}
|
||||
}
|
||||
signingConfigs {
|
||||
release {
|
||||
storeFile file('keystore/release.jks')
|
||||
storePassword "releaseKey"
|
||||
keyAlias "releaseKey"
|
||||
keyPassword "releaseKey"
|
||||
}
|
||||
buildFeatures {
|
||||
buildConfig true
|
||||
compose true
|
||||
}
|
||||
buildTypes {
|
||||
release {
|
||||
debuggable false
|
||||
minifyEnabled true
|
||||
shrinkResources true
|
||||
signingConfig signingConfigs.release
|
||||
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
|
||||
signingConfig signingConfigs.release
|
||||
}
|
||||
benchmark {
|
||||
initWith release
|
||||
@@ -50,46 +61,39 @@ android {
|
||||
targetCompatibility JavaVersion.VERSION_17
|
||||
}
|
||||
kotlinOptions {
|
||||
freeCompilerArgs += ["-Xstring-concat=inline"]
|
||||
jvmTarget = '17'
|
||||
}
|
||||
buildFeatures {
|
||||
compose true
|
||||
}
|
||||
composeOptions {
|
||||
kotlinCompilerExtensionVersion libs.versions.compose.lib.get()
|
||||
}
|
||||
packagingOptions {
|
||||
resources {
|
||||
excludes += '/META-INF/{AL2.0,LGPL2.1}'
|
||||
}
|
||||
}
|
||||
testOptions {
|
||||
unitTests.all {
|
||||
testLogging {
|
||||
exceptionFormat = org.gradle.api.tasks.testing.logging.TestExceptionFormat.FULL
|
||||
}
|
||||
excludes += "/META-INF/{AL2.0,LGPL2.1}"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
dependencies {
|
||||
implementation project(':navi-uitron')
|
||||
|
||||
api platform(libs.firebase.bom)
|
||||
api libs.androidx.lifecycle.runtime.compose
|
||||
api libs.firebase.analytics
|
||||
api libs.firebase.crashlytics
|
||||
api libs.retrofit.converter.gson
|
||||
api libs.retrofit.retrofit
|
||||
|
||||
implementation project(':navi-uitron')
|
||||
implementation platform(libs.androidx.compose.bom)
|
||||
implementation platform(libs.okhttp.bom)
|
||||
|
||||
implementation libs.android.material
|
||||
|
||||
implementation libs.androidx.appcompat
|
||||
implementation libs.androidx.core.ktx
|
||||
implementation libs.androidx.activity.compose
|
||||
implementation libs.androidx.compose.material
|
||||
implementation libs.androidx.compose.ui.graphics
|
||||
implementation libs.androidx.compose.ui.toolingPreview
|
||||
implementation libs.androidx.compose.ui.ui
|
||||
implementation libs.androidx.constraintlayoutCompose
|
||||
implementation libs.androidx.core.ktx
|
||||
implementation libs.androidx.hilt.navigation.compose
|
||||
implementation libs.androidx.lifecycle.viewmodel.ktx
|
||||
implementation libs.androidx.navigation.compose
|
||||
@@ -99,31 +103,18 @@ dependencies {
|
||||
implementation libs.androidx.room.ktx
|
||||
implementation libs.androidx.room.paging
|
||||
implementation libs.androidx.room.runtime
|
||||
|
||||
implementation libs.dagger.hiltAndroid
|
||||
|
||||
implementation libs.gson
|
||||
|
||||
implementation libs.okhttp.loggingIntercepter
|
||||
|
||||
api libs.androidx.lifecycle.runtime.compose
|
||||
|
||||
api libs.firebase.analytics
|
||||
api libs.firebase.crashlytics
|
||||
|
||||
api libs.retrofit.converter.gson
|
||||
api libs.retrofit.retrofit
|
||||
|
||||
kapt libs.androidx.hilt.compiler
|
||||
|
||||
kapt libs.dagger.hiltAndroidCompiler
|
||||
|
||||
ksp libs.androidx.room.compiler
|
||||
|
||||
implementation libs.navi.alfred
|
||||
implementation libs.okhttp.loggingIntercepter
|
||||
|
||||
androidTestImplementation libs.androidx.test.espresso.core
|
||||
androidTestImplementation libs.androidx.test.junit
|
||||
|
||||
testImplementation libs.junit
|
||||
|
||||
kapt libs.androidx.hilt.compiler
|
||||
kapt libs.dagger.hiltAndroidCompiler
|
||||
|
||||
ksp libs.androidx.room.compiler
|
||||
}
|
||||
|
||||
Binary file not shown.
2
app/proguard-rules.pro
vendored
2
app/proguard-rules.pro
vendored
@@ -38,4 +38,4 @@
|
||||
-dontwarn javax.script.AbstractScriptEngine
|
||||
-dontwarn javax.script.Compilable
|
||||
-dontwarn javax.script.ScriptEngine
|
||||
-dontwarn javax.script.ScriptEngineFactory
|
||||
-dontwarn javax.script.ScriptEngineFactory
|
||||
|
||||
@@ -1,29 +0,0 @@
|
||||
/*
|
||||
*
|
||||
* * Copyright © 2024 by Navi Technologies Limited
|
||||
* * All rights reserved. Strictly confidential
|
||||
*
|
||||
*/
|
||||
|
||||
package com.navi.uitron
|
||||
|
||||
import androidx.test.ext.junit.runners.AndroidJUnit4
|
||||
import androidx.test.platform.app.InstrumentationRegistry
|
||||
import org.junit.Assert.*
|
||||
import org.junit.Test
|
||||
import org.junit.runner.RunWith
|
||||
|
||||
/**
|
||||
* Instrumented test, which will execute on an Android device.
|
||||
*
|
||||
* See [testing documentation](http://d.android.com/tools/testing).
|
||||
*/
|
||||
@RunWith(AndroidJUnit4::class)
|
||||
class ExampleInstrumentedTest {
|
||||
@Test
|
||||
fun useAppContext() {
|
||||
// Context of the app under test.
|
||||
val appContext = InstrumentationRegistry.getInstrumentation().targetContext
|
||||
assertEquals("com.navi.uitron", appContext.packageName)
|
||||
}
|
||||
}
|
||||
@@ -6,7 +6,7 @@
|
||||
<uses-permission android:name="android.permission.VIBRATE" />
|
||||
|
||||
<application
|
||||
android:name="com.uitron.demo.MainApplication"
|
||||
android:name="com.navi.uitron.demo.MainApplication"
|
||||
android:allowBackup="true"
|
||||
android:dataExtractionRules="@xml/data_extraction_rules"
|
||||
android:fullBackupContent="@xml/backup_rules"
|
||||
@@ -18,7 +18,7 @@
|
||||
tools:targetApi="31">
|
||||
<profileable android:shell="true"/>
|
||||
<activity
|
||||
android:name="com.uitron.demo.MainActivity"
|
||||
android:name="com.navi.uitron.demo.MainActivity"
|
||||
android:exported="true"
|
||||
android:label="@string/title_activity_main"
|
||||
android:theme="@style/Theme.UiTron">
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo
|
||||
package com.navi.uitron.demo
|
||||
|
||||
import UiTronDemoNavGraph
|
||||
import android.os.Bundle
|
||||
@@ -14,8 +14,8 @@ import androidx.activity.compose.setContent
|
||||
import androidx.compose.runtime.Composable
|
||||
import androidx.compose.ui.tooling.preview.Preview
|
||||
import androidx.navigation.compose.rememberNavController
|
||||
import com.uitron.demo.home.HomeScreen
|
||||
import com.uitron.demo.theme.UiTronTheme
|
||||
import com.navi.uitron.demo.home.HomeScreen
|
||||
import com.navi.uitron.demo.theme.UiTronTheme
|
||||
import dagger.hilt.android.AndroidEntryPoint
|
||||
|
||||
@AndroidEntryPoint
|
||||
@@ -5,11 +5,11 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo
|
||||
package com.navi.uitron.demo
|
||||
|
||||
import android.app.Application
|
||||
import com.navi.uitron.UiTronSdkManager
|
||||
import com.uitron.demo.dazzledesignsystem.db.SharedPreferences
|
||||
import com.navi.uitron.demo.dazzledesignsystem.db.SharedPreferences
|
||||
import dagger.hilt.android.HiltAndroidApp
|
||||
|
||||
@HiltAndroidApp
|
||||
@@ -5,7 +5,7 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo
|
||||
package com.navi.uitron.demo
|
||||
|
||||
import android.os.Bundle
|
||||
import androidx.activity.ComponentActivity
|
||||
@@ -5,7 +5,7 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo
|
||||
package com.navi.uitron.demo
|
||||
|
||||
import android.content.Context
|
||||
import android.view.View
|
||||
@@ -5,7 +5,7 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo
|
||||
package com.navi.uitron.demo
|
||||
|
||||
import android.content.Context
|
||||
import com.google.gson.JsonObject
|
||||
@@ -5,7 +5,7 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.dazzledesignsystem
|
||||
package com.navi.uitron.demo.dazzledesignsystem
|
||||
|
||||
import com.navi.uitron.utils.isNull
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.dazzledesignsystem
|
||||
package com.navi.uitron.demo.dazzledesignsystem
|
||||
|
||||
const val DB_LAST_REFRESHED_TIMESTAMP = "widgetListLastRefreshedTimestamp"
|
||||
const val DB_REFRESH_TIMEOUT = 3600000L // 1 hour
|
||||
@@ -5,15 +5,15 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.dazzledesignsystem.db
|
||||
package com.navi.uitron.demo.dazzledesignsystem.db
|
||||
|
||||
import androidx.room.Database
|
||||
import androidx.room.RoomDatabase
|
||||
import androidx.room.TypeConverters
|
||||
import com.uitron.demo.dazzledesignsystem.db.converters.ListConverter
|
||||
import com.uitron.demo.dazzledesignsystem.db.converters.WidgetModelDefinitionConverter
|
||||
import com.uitron.demo.dazzledesignsystem.db.dao.WidgetTemplatesDao
|
||||
import com.uitron.demo.dazzledesignsystem.db.entity.WidgetTemplate
|
||||
import com.navi.uitron.demo.dazzledesignsystem.db.converters.ListConverter
|
||||
import com.navi.uitron.demo.dazzledesignsystem.db.converters.WidgetModelDefinitionConverter
|
||||
import com.navi.uitron.demo.dazzledesignsystem.db.dao.WidgetTemplatesDao
|
||||
import com.navi.uitron.demo.dazzledesignsystem.db.entity.WidgetTemplate
|
||||
|
||||
@Database(entities = [WidgetTemplate::class], version = 1, exportSchema = false)
|
||||
@TypeConverters(WidgetModelDefinitionConverter::class, ListConverter::class)
|
||||
@@ -5,7 +5,7 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.dazzledesignsystem.db
|
||||
package com.navi.uitron.demo.dazzledesignsystem.db
|
||||
|
||||
import android.app.Application
|
||||
import android.content.Context
|
||||
@@ -5,12 +5,12 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.dazzledesignsystem.db.converters
|
||||
package com.navi.uitron.demo.dazzledesignsystem.db.converters
|
||||
|
||||
import androidx.room.TypeConverter
|
||||
import com.google.gson.Gson
|
||||
import com.google.gson.reflect.TypeToken
|
||||
import com.uitron.demo.dazzledesignsystem.db.entity.TemplateVariable
|
||||
import com.navi.uitron.demo.dazzledesignsystem.db.entity.TemplateVariable
|
||||
|
||||
class ListConverter {
|
||||
@TypeConverter
|
||||
@@ -5,11 +5,11 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.dazzledesignsystem.db.converters
|
||||
package com.navi.uitron.demo.dazzledesignsystem.db.converters
|
||||
|
||||
import androidx.room.TypeConverter
|
||||
import com.google.gson.Gson
|
||||
import com.uitron.demo.dazzledesignsystem.db.entity.WidgetModelDefinition
|
||||
import com.navi.uitron.demo.dazzledesignsystem.db.entity.WidgetModelDefinition
|
||||
|
||||
class WidgetModelDefinitionConverter {
|
||||
|
||||
@@ -5,13 +5,13 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.dazzledesignsystem.db.dao
|
||||
package com.navi.uitron.demo.dazzledesignsystem.db.dao
|
||||
|
||||
import androidx.room.Dao
|
||||
import androidx.room.Insert
|
||||
import androidx.room.OnConflictStrategy
|
||||
import androidx.room.Query
|
||||
import com.uitron.demo.dazzledesignsystem.db.entity.WidgetTemplate
|
||||
import com.navi.uitron.demo.dazzledesignsystem.db.entity.WidgetTemplate
|
||||
|
||||
@Dao
|
||||
interface WidgetTemplatesDao {
|
||||
@@ -5,14 +5,14 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.dazzledesignsystem.db.entity
|
||||
package com.navi.uitron.demo.dazzledesignsystem.db.entity
|
||||
|
||||
import androidx.room.ColumnInfo
|
||||
import androidx.room.Entity
|
||||
import androidx.room.PrimaryKey
|
||||
import androidx.room.TypeConverters
|
||||
import com.uitron.demo.dazzledesignsystem.db.converters.ListConverter
|
||||
import com.uitron.demo.dazzledesignsystem.db.converters.WidgetModelDefinitionConverter
|
||||
import com.navi.uitron.demo.dazzledesignsystem.db.converters.ListConverter
|
||||
import com.navi.uitron.demo.dazzledesignsystem.db.converters.WidgetModelDefinitionConverter
|
||||
|
||||
@Entity(tableName = "widget_templates")
|
||||
data class WidgetTemplate(
|
||||
@@ -5,15 +5,15 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.dazzledesignsystem.di
|
||||
package com.navi.uitron.demo.dazzledesignsystem.di
|
||||
|
||||
import android.content.Context
|
||||
import androidx.room.Room
|
||||
import com.uitron.demo.dazzledesignsystem.db.DazzleDatabase
|
||||
import com.uitron.demo.dazzledesignsystem.db.dao.WidgetTemplatesDao
|
||||
import com.uitron.demo.dazzledesignsystem.network.retrofit.RetrofitProvider
|
||||
import com.uitron.demo.dazzledesignsystem.network.retrofit.RetrofitService
|
||||
import com.uitron.demo.dazzledesignsystem.repository.DazzleRepository
|
||||
import com.navi.uitron.demo.dazzledesignsystem.db.DazzleDatabase
|
||||
import com.navi.uitron.demo.dazzledesignsystem.db.dao.WidgetTemplatesDao
|
||||
import com.navi.uitron.demo.dazzledesignsystem.network.retrofit.RetrofitProvider
|
||||
import com.navi.uitron.demo.dazzledesignsystem.network.retrofit.RetrofitService
|
||||
import com.navi.uitron.demo.dazzledesignsystem.repository.DazzleRepository
|
||||
import dagger.Module
|
||||
import dagger.Provides
|
||||
import dagger.hilt.InstallIn
|
||||
@@ -5,9 +5,9 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.dazzledesignsystem.models
|
||||
package com.navi.uitron.demo.dazzledesignsystem.models
|
||||
|
||||
import com.uitron.demo.dazzledesignsystem.db.entity.WidgetTemplate
|
||||
import com.navi.uitron.demo.dazzledesignsystem.db.entity.WidgetTemplate
|
||||
|
||||
data class BottomSheetData(
|
||||
val bottomSheetType: BottomSheetType? = null,
|
||||
@@ -5,9 +5,9 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.dazzledesignsystem.models
|
||||
package com.navi.uitron.demo.dazzledesignsystem.models
|
||||
|
||||
import com.uitron.demo.dazzledesignsystem.db.entity.WidgetTemplate
|
||||
import com.navi.uitron.demo.dazzledesignsystem.db.entity.WidgetTemplate
|
||||
|
||||
sealed class WidgetTemplateState {
|
||||
object Loading : WidgetTemplateState()
|
||||
@@ -5,6 +5,6 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.dazzledesignsystem.models.network
|
||||
package com.navi.uitron.demo.dazzledesignsystem.models.network
|
||||
|
||||
data class NetworkResult<T>(var data: T? = null, var errorMessage: String? = null)
|
||||
@@ -5,9 +5,9 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.dazzledesignsystem.models.network
|
||||
package com.navi.uitron.demo.dazzledesignsystem.models.network
|
||||
|
||||
import com.uitron.demo.dazzledesignsystem.db.entity.WidgetTemplate
|
||||
import com.navi.uitron.demo.dazzledesignsystem.db.entity.WidgetTemplate
|
||||
|
||||
data class WidgetTemplateResponse(
|
||||
val content: List<WidgetTemplate>? = null,
|
||||
@@ -5,7 +5,7 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.dazzledesignsystem.network
|
||||
package com.navi.uitron.demo.dazzledesignsystem.network
|
||||
|
||||
import java.util.concurrent.TimeUnit
|
||||
import okhttp3.OkHttpClient
|
||||
@@ -5,9 +5,9 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.dazzledesignsystem.network.retrofit
|
||||
package com.navi.uitron.demo.dazzledesignsystem.network.retrofit
|
||||
|
||||
import com.uitron.demo.dazzledesignsystem.network.HttpClient
|
||||
import com.navi.uitron.demo.dazzledesignsystem.network.HttpClient
|
||||
import okhttp3.OkHttpClient
|
||||
import retrofit2.Retrofit
|
||||
import retrofit2.converter.gson.GsonConverterFactory
|
||||
@@ -5,9 +5,9 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.dazzledesignsystem.network.retrofit
|
||||
package com.navi.uitron.demo.dazzledesignsystem.network.retrofit
|
||||
|
||||
import com.uitron.demo.dazzledesignsystem.models.network.WidgetTemplateResponse
|
||||
import com.navi.uitron.demo.dazzledesignsystem.models.network.WidgetTemplateResponse
|
||||
import retrofit2.Response
|
||||
import retrofit2.http.Body
|
||||
import retrofit2.http.GET
|
||||
@@ -5,16 +5,16 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.dazzledesignsystem.repository
|
||||
package com.navi.uitron.demo.dazzledesignsystem.repository
|
||||
|
||||
import com.navi.uitron.demo.dazzledesignsystem.DB_LAST_REFRESHED_TIMESTAMP
|
||||
import com.navi.uitron.demo.dazzledesignsystem.DB_REFRESH_TIMEOUT
|
||||
import com.navi.uitron.demo.dazzledesignsystem.db.SharedPreferences
|
||||
import com.navi.uitron.demo.dazzledesignsystem.db.dao.WidgetTemplatesDao
|
||||
import com.navi.uitron.demo.dazzledesignsystem.db.entity.WidgetTemplate
|
||||
import com.navi.uitron.demo.dazzledesignsystem.models.network.NetworkResult
|
||||
import com.navi.uitron.demo.dazzledesignsystem.network.retrofit.RetrofitService
|
||||
import com.navi.uitron.utils.orFalse
|
||||
import com.uitron.demo.dazzledesignsystem.DB_LAST_REFRESHED_TIMESTAMP
|
||||
import com.uitron.demo.dazzledesignsystem.DB_REFRESH_TIMEOUT
|
||||
import com.uitron.demo.dazzledesignsystem.db.SharedPreferences
|
||||
import com.uitron.demo.dazzledesignsystem.db.dao.WidgetTemplatesDao
|
||||
import com.uitron.demo.dazzledesignsystem.db.entity.WidgetTemplate
|
||||
import com.uitron.demo.dazzledesignsystem.models.network.NetworkResult
|
||||
import com.uitron.demo.dazzledesignsystem.network.retrofit.RetrofitService
|
||||
import javax.inject.Inject
|
||||
import retrofit2.Response
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.dazzledesignsystem.ui
|
||||
package com.navi.uitron.demo.dazzledesignsystem.ui
|
||||
|
||||
import android.content.Context
|
||||
import android.content.Intent
|
||||
@@ -52,20 +52,20 @@ import androidx.constraintlayout.compose.Dimension
|
||||
import androidx.core.content.ContextCompat.startActivity
|
||||
import androidx.lifecycle.compose.collectAsStateWithLifecycle
|
||||
import com.google.gson.Gson
|
||||
import com.uitron.demo.R
|
||||
import com.uitron.demo.dazzledesignsystem.db.entity.WidgetTemplate
|
||||
import com.uitron.demo.dazzledesignsystem.models.BottomSheetData
|
||||
import com.uitron.demo.dazzledesignsystem.models.BottomSheetType
|
||||
import com.uitron.demo.dazzledesignsystem.viewmodel.DazzleViewModel
|
||||
import com.uitron.demo.theme.Black191919
|
||||
import com.uitron.demo.theme.Black1C1C1C
|
||||
import com.uitron.demo.theme.Blue0276FE
|
||||
import com.uitron.demo.theme.Gray969696
|
||||
import com.uitron.demo.theme.GrayE8E8E8
|
||||
import com.uitron.demo.theme.Purple1F002A
|
||||
import com.uitron.demo.theme.Purple3C0050
|
||||
import com.uitron.demo.theme.WhiteFCFCFD
|
||||
import com.uitron.demo.theme.fontFamily
|
||||
import com.navi.uitron.demo.R
|
||||
import com.navi.uitron.demo.dazzledesignsystem.db.entity.WidgetTemplate
|
||||
import com.navi.uitron.demo.dazzledesignsystem.models.BottomSheetData
|
||||
import com.navi.uitron.demo.dazzledesignsystem.models.BottomSheetType
|
||||
import com.navi.uitron.demo.dazzledesignsystem.viewmodel.DazzleViewModel
|
||||
import com.navi.uitron.demo.theme.Black191919
|
||||
import com.navi.uitron.demo.theme.Black1C1C1C
|
||||
import com.navi.uitron.demo.theme.Blue0276FE
|
||||
import com.navi.uitron.demo.theme.Gray969696
|
||||
import com.navi.uitron.demo.theme.GrayE8E8E8
|
||||
import com.navi.uitron.demo.theme.Purple1F002A
|
||||
import com.navi.uitron.demo.theme.Purple3C0050
|
||||
import com.navi.uitron.demo.theme.WhiteFCFCFD
|
||||
import com.navi.uitron.demo.theme.fontFamily
|
||||
|
||||
@Composable
|
||||
fun BottomSheetContent(
|
||||
@@ -5,7 +5,7 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.dazzledesignsystem.ui
|
||||
package com.navi.uitron.demo.dazzledesignsystem.ui
|
||||
|
||||
import androidx.compose.foundation.background
|
||||
import androidx.compose.foundation.layout.Arrangement
|
||||
@@ -34,9 +34,9 @@ import androidx.compose.ui.platform.LocalContext
|
||||
import androidx.compose.ui.unit.dp
|
||||
import androidx.hilt.navigation.compose.hiltViewModel
|
||||
import androidx.lifecycle.compose.collectAsStateWithLifecycle
|
||||
import com.uitron.demo.dazzledesignsystem.models.WidgetTemplateState
|
||||
import com.uitron.demo.dazzledesignsystem.viewmodel.DazzleViewModel
|
||||
import com.uitron.demo.theme.WhiteF7F7F7
|
||||
import com.navi.uitron.demo.dazzledesignsystem.models.WidgetTemplateState
|
||||
import com.navi.uitron.demo.dazzledesignsystem.viewmodel.DazzleViewModel
|
||||
import com.navi.uitron.demo.theme.WhiteF7F7F7
|
||||
import kotlinx.coroutines.launch
|
||||
|
||||
@OptIn(ExperimentalMaterialApi::class)
|
||||
@@ -5,7 +5,7 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.dazzledesignsystem.ui
|
||||
package com.navi.uitron.demo.dazzledesignsystem.ui
|
||||
|
||||
import androidx.compose.foundation.Image
|
||||
import androidx.compose.foundation.background
|
||||
@@ -40,13 +40,13 @@ import androidx.compose.ui.text.input.ImeAction
|
||||
import androidx.compose.ui.unit.dp
|
||||
import androidx.compose.ui.unit.sp
|
||||
import androidx.lifecycle.compose.collectAsStateWithLifecycle
|
||||
import com.uitron.demo.R
|
||||
import com.uitron.demo.dazzledesignsystem.models.BottomSheetType
|
||||
import com.uitron.demo.dazzledesignsystem.viewmodel.DazzleViewModel
|
||||
import com.uitron.demo.theme.GrayA8A8A8
|
||||
import com.uitron.demo.theme.GrayE3E5E5
|
||||
import com.uitron.demo.theme.WhiteF5F5F5
|
||||
import com.uitron.demo.theme.fontFamily
|
||||
import com.navi.uitron.demo.R
|
||||
import com.navi.uitron.demo.dazzledesignsystem.models.BottomSheetType
|
||||
import com.navi.uitron.demo.dazzledesignsystem.viewmodel.DazzleViewModel
|
||||
import com.navi.uitron.demo.theme.GrayA8A8A8
|
||||
import com.navi.uitron.demo.theme.GrayE3E5E5
|
||||
import com.navi.uitron.demo.theme.WhiteF5F5F5
|
||||
import com.navi.uitron.demo.theme.fontFamily
|
||||
|
||||
@OptIn(ExperimentalComposeUiApi::class)
|
||||
@Composable
|
||||
@@ -5,7 +5,7 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.dazzledesignsystem.ui
|
||||
package com.navi.uitron.demo.dazzledesignsystem.ui
|
||||
|
||||
import KeyboardUtil
|
||||
import androidx.compose.foundation.Image
|
||||
@@ -34,17 +34,17 @@ import androidx.compose.ui.text.font.FontWeight
|
||||
import androidx.compose.ui.unit.dp
|
||||
import androidx.compose.ui.unit.sp
|
||||
import com.google.gson.Gson
|
||||
import com.navi.uitron.demo.R
|
||||
import com.navi.uitron.demo.dazzledesignsystem.db.entity.WidgetTemplate
|
||||
import com.navi.uitron.demo.dazzledesignsystem.models.BottomSheetType
|
||||
import com.navi.uitron.demo.dazzledesignsystem.viewmodel.DazzleViewModel
|
||||
import com.navi.uitron.demo.stringToUiTronResponse
|
||||
import com.navi.uitron.demo.theme.Black1C1C1C
|
||||
import com.navi.uitron.demo.theme.BlueE4EEFF
|
||||
import com.navi.uitron.demo.theme.GrayE8E8E8
|
||||
import com.navi.uitron.demo.theme.Purple1F002A
|
||||
import com.navi.uitron.demo.theme.fontFamily
|
||||
import com.navi.uitron.render.UiTronRenderer
|
||||
import com.uitron.demo.R
|
||||
import com.uitron.demo.dazzledesignsystem.db.entity.WidgetTemplate
|
||||
import com.uitron.demo.dazzledesignsystem.models.BottomSheetType
|
||||
import com.uitron.demo.dazzledesignsystem.viewmodel.DazzleViewModel
|
||||
import com.uitron.demo.stringToUiTronResponse
|
||||
import com.uitron.demo.theme.Black1C1C1C
|
||||
import com.uitron.demo.theme.BlueE4EEFF
|
||||
import com.uitron.demo.theme.GrayE8E8E8
|
||||
import com.uitron.demo.theme.Purple1F002A
|
||||
import com.uitron.demo.theme.fontFamily
|
||||
|
||||
@OptIn(ExperimentalComposeUiApi::class)
|
||||
@Composable
|
||||
@@ -5,16 +5,16 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.dazzledesignsystem.viewmodel
|
||||
package com.navi.uitron.demo.dazzledesignsystem.viewmodel
|
||||
|
||||
import androidx.lifecycle.viewModelScope
|
||||
import com.navi.uitron.demo.dazzledesignsystem.db.entity.WidgetTemplate
|
||||
import com.navi.uitron.demo.dazzledesignsystem.isNotNull
|
||||
import com.navi.uitron.demo.dazzledesignsystem.models.BottomSheetData
|
||||
import com.navi.uitron.demo.dazzledesignsystem.models.BottomSheetType
|
||||
import com.navi.uitron.demo.dazzledesignsystem.models.WidgetTemplateState
|
||||
import com.navi.uitron.demo.dazzledesignsystem.repository.DazzleRepository
|
||||
import com.navi.uitron.viewmodel.UiTronViewModel
|
||||
import com.uitron.demo.dazzledesignsystem.db.entity.WidgetTemplate
|
||||
import com.uitron.demo.dazzledesignsystem.isNotNull
|
||||
import com.uitron.demo.dazzledesignsystem.models.BottomSheetData
|
||||
import com.uitron.demo.dazzledesignsystem.models.BottomSheetType
|
||||
import com.uitron.demo.dazzledesignsystem.models.WidgetTemplateState
|
||||
import com.uitron.demo.dazzledesignsystem.repository.DazzleRepository
|
||||
import dagger.hilt.android.lifecycle.HiltViewModel
|
||||
import javax.inject.Inject
|
||||
import kotlinx.coroutines.Dispatchers
|
||||
@@ -5,7 +5,7 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.designsystem.model
|
||||
package com.navi.uitron.demo.designsystem.model
|
||||
|
||||
data class DesignItem(val id: String, val icon: String, val title: String, val description: String)
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.designsystem.model
|
||||
package com.navi.uitron.demo.designsystem.model
|
||||
|
||||
import com.navi.uitron.model.UiTronResponse
|
||||
|
||||
@@ -35,13 +35,13 @@ import androidx.constraintlayout.compose.ConstraintLayout
|
||||
import androidx.constraintlayout.compose.Dimension
|
||||
import com.google.gson.Gson
|
||||
import com.google.gson.reflect.TypeToken
|
||||
import com.navi.uitron.demo.R
|
||||
import com.navi.uitron.demo.designsystem.model.WidgetData
|
||||
import com.navi.uitron.demo.designsystem.viewmodel.DesignSystemVM
|
||||
import com.navi.uitron.demo.theme.fontFamily
|
||||
import com.navi.uitron.model.UiTronResponse
|
||||
import com.navi.uitron.render.UiTronRenderer
|
||||
import com.navi.uitron.viewmodel.UiTronViewModel
|
||||
import com.uitron.demo.R
|
||||
import com.uitron.demo.designsystem.model.WidgetData
|
||||
import com.uitron.demo.designsystem.viewmodel.DesignSystemVM
|
||||
import com.uitron.demo.theme.fontFamily
|
||||
import java.lang.reflect.Type
|
||||
|
||||
@Composable
|
||||
@@ -26,10 +26,10 @@ import androidx.constraintlayout.compose.Dimension
|
||||
import androidx.navigation.NavHostController
|
||||
import coil.compose.AsyncImage
|
||||
import coil.request.ImageRequest
|
||||
import com.uitron.demo.designsystem.model.DesignItem
|
||||
import com.uitron.demo.designsystem.viewmodel.DesignSystemVM
|
||||
import com.uitron.demo.navigation.DESIGN_REPO
|
||||
import com.uitron.demo.theme.fontFamily
|
||||
import com.navi.uitron.demo.designsystem.model.DesignItem
|
||||
import com.navi.uitron.demo.designsystem.viewmodel.DesignSystemVM
|
||||
import com.navi.uitron.demo.navigation.DESIGN_REPO
|
||||
import com.navi.uitron.demo.theme.fontFamily
|
||||
|
||||
/**
|
||||
* Copyright © 2023 by Navi Technologies Private Limited All rights reserved. Strictly confidential
|
||||
@@ -5,14 +5,14 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.designsystem.viewmodel
|
||||
package com.navi.uitron.demo.designsystem.viewmodel
|
||||
|
||||
import android.content.Context
|
||||
import androidx.lifecycle.ViewModel
|
||||
import com.google.gson.reflect.TypeToken
|
||||
import com.uitron.demo.R
|
||||
import com.uitron.demo.designsystem.model.*
|
||||
import com.uitron.demo.mockApiResponse
|
||||
import com.navi.uitron.demo.R
|
||||
import com.navi.uitron.demo.designsystem.model.*
|
||||
import com.navi.uitron.demo.mockApiResponse
|
||||
import kotlinx.coroutines.flow.MutableStateFlow
|
||||
import kotlinx.coroutines.flow.asStateFlow
|
||||
import kotlinx.coroutines.flow.update
|
||||
@@ -5,7 +5,7 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.home
|
||||
package com.navi.uitron.demo.home
|
||||
|
||||
import androidx.compose.foundation.Image
|
||||
import androidx.compose.foundation.background
|
||||
@@ -37,18 +37,18 @@ import androidx.compose.ui.unit.sp
|
||||
import androidx.constraintlayout.compose.ConstraintLayout
|
||||
import androidx.constraintlayout.compose.Dimension
|
||||
import androidx.navigation.NavHostController
|
||||
import com.uitron.demo.R
|
||||
import com.uitron.demo.navigation.DAZZLE_DESIGN_SYSTEM
|
||||
import com.uitron.demo.navigation.DESIGN_SYSTEM
|
||||
import com.uitron.demo.navigation.LINK_INFLATOR
|
||||
import com.uitron.demo.navigation.MOCK
|
||||
import com.uitron.demo.navigation.PLAYGROUND
|
||||
import com.uitron.demo.theme.Blue0276FE
|
||||
import com.uitron.demo.theme.OrangeFF9000
|
||||
import com.uitron.demo.theme.PinkCC2FD5
|
||||
import com.uitron.demo.theme.Purple5A43E3
|
||||
import com.uitron.demo.theme.TomatoFC5130
|
||||
import com.uitron.demo.theme.fontFamily
|
||||
import com.navi.uitron.demo.R
|
||||
import com.navi.uitron.demo.navigation.DAZZLE_DESIGN_SYSTEM
|
||||
import com.navi.uitron.demo.navigation.DESIGN_SYSTEM
|
||||
import com.navi.uitron.demo.navigation.LINK_INFLATOR
|
||||
import com.navi.uitron.demo.navigation.MOCK
|
||||
import com.navi.uitron.demo.navigation.PLAYGROUND
|
||||
import com.navi.uitron.demo.theme.Blue0276FE
|
||||
import com.navi.uitron.demo.theme.OrangeFF9000
|
||||
import com.navi.uitron.demo.theme.PinkCC2FD5
|
||||
import com.navi.uitron.demo.theme.Purple5A43E3
|
||||
import com.navi.uitron.demo.theme.TomatoFC5130
|
||||
import com.navi.uitron.demo.theme.fontFamily
|
||||
|
||||
@Composable
|
||||
fun HomeScreen(navHostController: NavHostController) {
|
||||
@@ -5,7 +5,7 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.linkinflator
|
||||
package com.navi.uitron.demo.linkinflator
|
||||
|
||||
import androidx.compose.foundation.background
|
||||
import androidx.compose.foundation.border
|
||||
@@ -40,10 +40,10 @@ import androidx.compose.ui.text.style.TextAlign
|
||||
import androidx.compose.ui.unit.dp
|
||||
import androidx.compose.ui.unit.sp
|
||||
import androidx.hilt.navigation.compose.hiltViewModel
|
||||
import com.navi.uitron.demo.theme.TomatoFC5130
|
||||
import com.navi.uitron.demo.theme.fontFamily
|
||||
import com.navi.uitron.render.UiTronRenderer
|
||||
import com.navi.uitron.viewmodel.UiTronViewModel
|
||||
import com.uitron.demo.theme.TomatoFC5130
|
||||
import com.uitron.demo.theme.fontFamily
|
||||
|
||||
@Composable
|
||||
fun LinkInflator(viewModel: LinkInflatorViewModel = hiltViewModel()) {
|
||||
@@ -5,9 +5,9 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.linkinflator
|
||||
package com.navi.uitron.demo.linkinflator
|
||||
|
||||
import com.uitron.demo.dazzledesignsystem.network.retrofit.RetrofitService
|
||||
import com.navi.uitron.demo.dazzledesignsystem.network.retrofit.RetrofitService
|
||||
import javax.inject.Inject
|
||||
import okhttp3.ResponseBody.Companion.toResponseBody
|
||||
import retrofit2.Response
|
||||
@@ -5,7 +5,7 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.linkinflator
|
||||
package com.navi.uitron.demo.linkinflator
|
||||
|
||||
import com.navi.uitron.model.UiTronResponse
|
||||
|
||||
@@ -5,12 +5,12 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.linkinflator
|
||||
package com.navi.uitron.demo.linkinflator
|
||||
|
||||
import androidx.lifecycle.viewModelScope
|
||||
import com.google.gson.Gson
|
||||
import com.navi.uitron.demo.stringToUiTronResponse
|
||||
import com.navi.uitron.viewmodel.UiTronViewModel
|
||||
import com.uitron.demo.stringToUiTronResponse
|
||||
import dagger.hilt.android.lifecycle.HiltViewModel
|
||||
import javax.inject.Inject
|
||||
import kotlinx.coroutines.Dispatchers
|
||||
@@ -5,7 +5,7 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.mock
|
||||
package com.navi.uitron.demo.mock
|
||||
|
||||
import androidx.compose.foundation.background
|
||||
import androidx.compose.foundation.border
|
||||
@@ -41,12 +41,12 @@ import androidx.compose.ui.unit.dp
|
||||
import androidx.compose.ui.unit.sp
|
||||
import androidx.hilt.navigation.compose.hiltViewModel
|
||||
import com.google.gson.reflect.TypeToken
|
||||
import com.navi.uitron.demo.mockApiResponse
|
||||
import com.navi.uitron.demo.theme.Purple5A43E3
|
||||
import com.navi.uitron.demo.theme.fontFamily
|
||||
import com.navi.uitron.model.UiTronResponse
|
||||
import com.navi.uitron.render.UiTronRenderer
|
||||
import com.navi.uitron.viewmodel.UiTronViewModel
|
||||
import com.uitron.demo.mockApiResponse
|
||||
import com.uitron.demo.theme.Purple5A43E3
|
||||
import com.uitron.demo.theme.fontFamily
|
||||
|
||||
@Composable
|
||||
fun MockScreen(viewModel: UiTronViewModel = hiltViewModel()) {
|
||||
@@ -5,7 +5,7 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.navigation
|
||||
package com.navi.uitron.demo.navigation
|
||||
|
||||
const val HOME = "home"
|
||||
const val PLAYGROUND = "playground"
|
||||
@@ -11,18 +11,18 @@ import androidx.navigation.NavType
|
||||
import androidx.navigation.compose.NavHost
|
||||
import androidx.navigation.compose.composable
|
||||
import androidx.navigation.navArgument
|
||||
import com.uitron.demo.dazzledesignsystem.ui.DazzleDesignSystemScreen
|
||||
import com.uitron.demo.home.HomeScreen
|
||||
import com.uitron.demo.linkinflator.LinkInflator
|
||||
import com.uitron.demo.mock.MockScreen
|
||||
import com.uitron.demo.navigation.DAZZLE_DESIGN_SYSTEM
|
||||
import com.uitron.demo.navigation.DESIGN_REPO_WITH_NAV
|
||||
import com.uitron.demo.navigation.DESIGN_SYSTEM
|
||||
import com.uitron.demo.navigation.HOME
|
||||
import com.uitron.demo.navigation.LINK_INFLATOR
|
||||
import com.uitron.demo.navigation.MOCK
|
||||
import com.uitron.demo.navigation.PLAYGROUND
|
||||
import com.uitron.demo.playground.PlaygroundScreen
|
||||
import com.navi.uitron.demo.dazzledesignsystem.ui.DazzleDesignSystemScreen
|
||||
import com.navi.uitron.demo.home.HomeScreen
|
||||
import com.navi.uitron.demo.linkinflator.LinkInflator
|
||||
import com.navi.uitron.demo.mock.MockScreen
|
||||
import com.navi.uitron.demo.navigation.DAZZLE_DESIGN_SYSTEM
|
||||
import com.navi.uitron.demo.navigation.DESIGN_REPO_WITH_NAV
|
||||
import com.navi.uitron.demo.navigation.DESIGN_SYSTEM
|
||||
import com.navi.uitron.demo.navigation.HOME
|
||||
import com.navi.uitron.demo.navigation.LINK_INFLATOR
|
||||
import com.navi.uitron.demo.navigation.MOCK
|
||||
import com.navi.uitron.demo.navigation.PLAYGROUND
|
||||
import com.navi.uitron.demo.playground.PlaygroundScreen
|
||||
|
||||
@Composable
|
||||
fun UiTronDemoNavGraph(navController: NavHostController) {
|
||||
@@ -5,7 +5,7 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.playground
|
||||
package com.navi.uitron.demo.playground
|
||||
|
||||
import androidx.compose.foundation.background
|
||||
import androidx.compose.foundation.border
|
||||
@@ -37,13 +37,13 @@ import androidx.compose.ui.text.style.TextAlign
|
||||
import androidx.compose.ui.tooling.preview.Preview
|
||||
import androidx.compose.ui.unit.dp
|
||||
import androidx.compose.ui.unit.sp
|
||||
import com.navi.uitron.demo.stringToUiTronResponse
|
||||
import com.navi.uitron.demo.theme.PinkCC2FD5
|
||||
import com.navi.uitron.demo.theme.UiTronTheme
|
||||
import com.navi.uitron.demo.theme.fontFamily
|
||||
import com.navi.uitron.model.UiTronResponse
|
||||
import com.navi.uitron.render.UiTronRenderer
|
||||
import com.navi.uitron.viewmodel.UiTronViewModel
|
||||
import com.uitron.demo.stringToUiTronResponse
|
||||
import com.uitron.demo.theme.PinkCC2FD5
|
||||
import com.uitron.demo.theme.UiTronTheme
|
||||
import com.uitron.demo.theme.fontFamily
|
||||
|
||||
@Composable
|
||||
fun PlaygroundScreen() {
|
||||
@@ -5,7 +5,7 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.theme
|
||||
package com.navi.uitron.demo.theme
|
||||
|
||||
import androidx.compose.ui.graphics.Color
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.theme
|
||||
package com.navi.uitron.demo.theme
|
||||
|
||||
import androidx.compose.foundation.shape.RoundedCornerShape
|
||||
import androidx.compose.material.Shapes
|
||||
@@ -5,7 +5,7 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.theme
|
||||
package com.navi.uitron.demo.theme
|
||||
|
||||
import androidx.compose.foundation.isSystemInDarkTheme
|
||||
import androidx.compose.material.MaterialTheme
|
||||
@@ -5,7 +5,7 @@
|
||||
*
|
||||
*/
|
||||
|
||||
package com.uitron.demo.theme
|
||||
package com.navi.uitron.demo.theme
|
||||
|
||||
import androidx.compose.material.Typography
|
||||
import androidx.compose.ui.text.TextStyle
|
||||
@@ -14,8 +14,8 @@ import androidx.compose.ui.graphics.Color
|
||||
import app.cash.paparazzi.Paparazzi
|
||||
import com.navi.uitron.TestUtil
|
||||
import com.navi.uitron.UiTronSdkManager
|
||||
import com.navi.uitron.demo.UiTronDependencyProvider
|
||||
import com.navi.uitron.viewmodel.UiTronViewModel
|
||||
import com.uitron.demo.UiTronDependencyProvider
|
||||
import org.junit.Before
|
||||
import org.junit.Rule
|
||||
import org.junit.Test
|
||||
|
||||
@@ -1,3 +0,0 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:f4e1cdb8d64880726f44c12906c2a2cd19e3ca241252371b5d94ca0b8b8aa5f1
|
||||
size 9078
|
||||
@@ -25,7 +25,7 @@ class UiTronBenchmark {
|
||||
@Test
|
||||
fun startup() =
|
||||
benchmarkRule.measureRepeated(
|
||||
packageName = "com.uitron.demo",
|
||||
packageName = "com.navi.uitron.demo",
|
||||
metrics = listOf(FrameTimingMetric()),
|
||||
iterations = 3,
|
||||
startupMode = StartupMode.COLD,
|
||||
|
||||
@@ -20,6 +20,9 @@ allprojects {
|
||||
mavenCentral()
|
||||
gradlePluginPortal()
|
||||
maven { url 'https://jitpack.io' }
|
||||
maven {
|
||||
url 'https://oss.sonatype.org/content/repositories/snapshots/'
|
||||
}
|
||||
maven {
|
||||
credentials {
|
||||
username 'nexus-user'
|
||||
@@ -34,9 +37,6 @@ allprojects {
|
||||
}
|
||||
url "https://nexus.cmd.navi-tech.in/repository/maven-releases"
|
||||
}
|
||||
maven {
|
||||
url 'https://oss.sonatype.org/content/repositories/snapshots/'
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -21,4 +21,3 @@ kotlin.code.style=official
|
||||
# resources declared in the library itself and none from the library's dependencies,
|
||||
# thereby reducing the size of the R class for that library
|
||||
android.nonTransitiveRClass=true
|
||||
android.nonFinalResIds=false
|
||||
@@ -26,7 +26,7 @@ kotlin = "1.9.23"
|
||||
ksp = "1.9.23-1.0.20"
|
||||
lottie = "6.4.0"
|
||||
mvel2 = "2.4.15.Final"
|
||||
navi-alfred = "1.0.20"
|
||||
navi-alfred = "1.2.0"
|
||||
navigation-compose = "2.6.0"
|
||||
okhttp-bom = "4.12.0"
|
||||
paparazzi = "1.3.3"
|
||||
|
||||
BIN
keystore/navi-debug-key.jks
Normal file
BIN
keystore/navi-debug-key.jks
Normal file
Binary file not shown.
BIN
keystore/navi-non-prod-release-key.jks
Normal file
BIN
keystore/navi-non-prod-release-key.jks
Normal file
Binary file not shown.
2
navi-uitron/.gitignore
vendored
2
navi-uitron/.gitignore
vendored
@@ -1 +1 @@
|
||||
/build
|
||||
/build
|
||||
|
||||
@@ -5,7 +5,7 @@ plugins {
|
||||
id 'maven-publish'
|
||||
}
|
||||
|
||||
def VERSION_NAME = "1.3.6"
|
||||
def VERSION = "1.3.6"
|
||||
|
||||
android {
|
||||
namespace 'com.navi.uitron'
|
||||
@@ -15,10 +15,14 @@ android {
|
||||
minSdk 21
|
||||
targetSdk 33
|
||||
|
||||
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
||||
consumerProguardFiles "consumer-rules.pro"
|
||||
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
||||
}
|
||||
|
||||
buildFeatures {
|
||||
buildConfig true
|
||||
compose true
|
||||
}
|
||||
buildTypes {
|
||||
release {
|
||||
minifyEnabled false
|
||||
@@ -29,20 +33,20 @@ android {
|
||||
sourceCompatibility JavaVersion.VERSION_17
|
||||
targetCompatibility JavaVersion.VERSION_17
|
||||
}
|
||||
kotlinOptions {
|
||||
jvmTarget = '17'
|
||||
}
|
||||
buildFeatures {
|
||||
compose true
|
||||
}
|
||||
composeOptions {
|
||||
kotlinCompilerExtensionVersion libs.versions.compose.lib.get()
|
||||
}
|
||||
kotlinOptions {
|
||||
freeCompilerArgs += ["-Xstring-concat=inline"]
|
||||
jvmTarget = '17'
|
||||
}
|
||||
}
|
||||
|
||||
publishing {
|
||||
repositories {
|
||||
if (project.hasProperty('NEXUS_URL')) {
|
||||
if (project.hasProperty('NEXUS_URL')
|
||||
&& project.hasProperty('NEXUS_USERNAME')
|
||||
&& project.hasProperty('NEXUS_PASSWORD')) {
|
||||
maven {
|
||||
url = "$NEXUS_URL"
|
||||
credentials {
|
||||
@@ -55,17 +59,16 @@ publishing {
|
||||
publications {
|
||||
if (project.hasProperty('NEXUS_URL')) {
|
||||
maven(MavenPublication) {
|
||||
artifactId = "uitron"
|
||||
groupId = "com.navi.medici"
|
||||
|
||||
if ("$IS_SNAPSHOT" == "false") {
|
||||
version = "$VERSION_NAME"
|
||||
println("https://nexus.cmd.navi-tech.in/#browse/browse:maven-releases:com%2Fnavi%2Fmedici%2Fuitron%2F$version")
|
||||
if ("$NEXUS_URL".contains("maven-releases")) {
|
||||
version = "$VERSION"
|
||||
} else {
|
||||
version = "$VERSION_NAME-SNAPSHOT"
|
||||
println("https://nexus.cmd.navi-tech.in/#browse/browse:maven-snapshots:com%2Fnavi%2Fmedici%2Fuitron%2F$version")
|
||||
version = "$VERSION-SNAPSHOT"
|
||||
}
|
||||
artifact("build/outputs/aar/navi-uitron-release.aar")
|
||||
artifactId = "uitron"
|
||||
groupId = "com.navi.android"
|
||||
|
||||
artifact("build/outputs/aar/navi-uitron-${BUILD_TYPE}.aar")
|
||||
|
||||
pom.withXml {
|
||||
def dependenciesNode = asNode().appendNode('dependencies')
|
||||
configurations.implementation.allDependencies.each {
|
||||
@@ -81,13 +84,12 @@ publishing {
|
||||
}
|
||||
|
||||
dependencies {
|
||||
implementation platform(libs.androidx.compose.bom)
|
||||
api libs.coil.compose
|
||||
|
||||
implementation platform(libs.androidx.compose.bom)
|
||||
implementation libs.accompanist.pager
|
||||
implementation libs.accompanist.pagerIndicators
|
||||
|
||||
implementation libs.android.material
|
||||
|
||||
implementation libs.androidx.activity.compose
|
||||
implementation libs.androidx.appcompat
|
||||
implementation libs.androidx.compose.material
|
||||
@@ -98,16 +100,7 @@ dependencies {
|
||||
implementation libs.androidx.core.ktx
|
||||
implementation libs.androidx.hilt.navigation.compose
|
||||
implementation libs.androidx.lifecycle.runtime.ktx
|
||||
|
||||
implementation libs.gson
|
||||
|
||||
implementation libs.lottieCompose
|
||||
|
||||
implementation libs.mvel2
|
||||
|
||||
api libs.coil.compose
|
||||
|
||||
androidTestImplementation libs.androidx.test.junit
|
||||
|
||||
testImplementation libs.junit
|
||||
}
|
||||
|
||||
@@ -1,29 +0,0 @@
|
||||
/*
|
||||
*
|
||||
* * Copyright © 2024 by Navi Technologies Limited
|
||||
* * All rights reserved. Strictly confidential
|
||||
*
|
||||
*/
|
||||
|
||||
package com.navi.uitron
|
||||
|
||||
import androidx.test.ext.junit.runners.AndroidJUnit4
|
||||
import androidx.test.platform.app.InstrumentationRegistry
|
||||
import org.junit.Assert.*
|
||||
import org.junit.Test
|
||||
import org.junit.runner.RunWith
|
||||
|
||||
/**
|
||||
* Instrumented test, which will execute on an Android device.
|
||||
*
|
||||
* See [testing documentation](http://d.android.com/tools/testing).
|
||||
*/
|
||||
@RunWith(AndroidJUnit4::class)
|
||||
class ExampleInstrumentedTest {
|
||||
@Test
|
||||
fun useAppContext() {
|
||||
// Context of the app under test.
|
||||
val appContext = InstrumentationRegistry.getInstrumentation().targetContext
|
||||
assertEquals("com.navi.uitron.test", appContext.packageName)
|
||||
}
|
||||
}
|
||||
@@ -1,4 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<manifest xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
|
||||
</manifest>
|
||||
<!--
|
||||
~
|
||||
~ * Copyright © 2023-2024 by Navi Technologies Limited
|
||||
~ * All rights reserved. Strictly confidential
|
||||
~
|
||||
-->
|
||||
|
||||
<manifest />
|
||||
|
||||
@@ -1,23 +0,0 @@
|
||||
/*
|
||||
*
|
||||
* * Copyright © 2024 by Navi Technologies Limited
|
||||
* * All rights reserved. Strictly confidential
|
||||
*
|
||||
*/
|
||||
|
||||
package com.navi.uitron
|
||||
|
||||
import org.junit.Assert.*
|
||||
import org.junit.Test
|
||||
|
||||
/**
|
||||
* Example local unit test, which will execute on the development machine (host).
|
||||
*
|
||||
* See [testing documentation](http://d.android.com/tools/testing).
|
||||
*/
|
||||
class ExampleUnitTest {
|
||||
@Test
|
||||
fun addition_isCorrect() {
|
||||
assertEquals(4, 2 + 2)
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user