Skip to content

Develop - #1

Merged
LeandroLCD merged 7 commits into
masterfrom
develop
Aug 14, 2026
Merged

Develop#1
LeandroLCD merged 7 commits into
masterfrom
develop

Conversation

@LeandroLCD

Copy link
Copy Markdown
Owner

No description provided.

Adds a TintCap sealed class (All / Undefined / Index / Range / Layers) that
controls which top-level layers of an ImageVector receive the tint color.
The Icon and Image composables now accept a tintCap parameter; layers not
matched by the cap keep their original colors.

- TintCap.All tints every layer (default for Icon)
- TintCap.Undefined skips tinting entirely (default for Image)
- TintCap.index(n), TintCap.range(r), TintCap.layers(...) for selective
  tinting of one, a range, or a set of layers

Includes the Icons.MapTruck fixture with 4 distinct top-level layers and
unit + instrumented UI tests covering every TintCap variant.
- Add .github/workflows/release-pipeline.yml (PR to develop)
  * Unit tests (JVM) on every PR open + when merged
  * Instrumented tests on API 36 only (matrix reduced from [30, 34])
  * Tag & version validation (semver bump check)
  * :component:assembleRelease → publish AAR to GitHub Release
  * JitPack build verification + log dump
  * PR summary comment with per-step status
- Add version = "0.1.0" in root build.gradle.kts (required by check-tag)
- Rename Maven artifactId from 'query' → 'compose-components'
- Document JitPack install in README

Verified: ./gradlew :component:assembleRelease produces
component/build/outputs/aar/component-release.aar
Verified end-to-end on a physical device (VH-C83, Android 11 / API 30):
  ./gradlew :component:connectedDebugAndroidTest
  → 12 tests, 0 failures, 0 errors, 0 skipped (13.891s)

MapTruck.kt:
- Wrap cab-shell + cab-window in a single 'cab' group so the cab is one
  logical layer (was 2 separate top-level paths before).
- Redesign layout so layers occupy non-overlapping visual regions:
    wheels  → bottom strip (y 49–59)
    body    → thin chassis strip (y 44–48)
    cab     → top-right (x 40–62, y 14–42)
    cargo   → top-left  (x 2–38,  y 4–42)
  This makes each layer pixel-testable in isolation.

IconTintCapTest / ImageTintCapTest:
- Move testTag from the Icon modifier to the outer Box so the semantic
  tree is stable across re-renders (fixes sporadic 'No compose
  hierarchies' failures on Android 11).
- Update sample positions to the new layout:
    wheels  (12, 54), body (32, 46), cab (52, 32), cargo (20, 20).

README.md:
- Reflect Compose BOM 2026.02.00, Kotlin 2.3.10, AGP 9.0.0+
- Add TOC, CI badge, fixture section, tests section, JitPack install
…ents

Aligns naming with the rest of the library (SliderComponent,
LinearProgressIndicatorComponents, RangeSliderComponent) and avoids
shadowing the Material 3 Icon / Foundation Image composables when both
are imported in the same file.

- Icon      → IconComponents   (component/src/main/.../Icon.kt)
- Image     → ImageComponents  (component/src/main/.../Image.kt)
- Updated all call sites in IconTintCapTest / ImageTintCapTest
- Updated TOC, section headers, examples and project-structure
  comments in README.md

Verified: ./gradlew :component:compileDebugKotlin +
          :component:compileDebugAndroidTestKotlin  → BUILD SUCCESSFUL
Three new test classes under component/src/androidTest, bringing instrumented
UI coverage to every public composable in the library.

LinearProgressIndicatorComponentsTest (7 tests):
  - progress_zero / progress_full / progress_half pixel-sampling
  - custom range mapping (0f..100f with progress 25f)
  - drawStopIndicator callback verification (custom red vertical line)
  - out-of-range and at-range-start cases

SliderComponentTest (6 tests):
  - active/inactive track colours at value=0.5
  - thumb colour visible at value position (accounting for Material's
    internal horizontal padding, sample at x=46%)
  - value=0 and value=1 extremes
  - custom thumbSize footprint
  - value parameter actually drives active track length

RangeSliderComponentTest (5 tests):
  - middle of active range → active colour
  - both sides outside active range → inactive colour
  - full range → all active
  - empty range (start == end) → all inactive (sample away from the
    rounded end-cap which draws active colour at the start/end x position)

Verified end-to-end on physical device VH-C83 (Android 11 / API 30):
  ./gradlew :component:connectedDebugAndroidTest
  → 30 tests, 0 failures, 0 errors, 0 skipped (29.962s)

Bugs fixed during the run:
  - RangeSlider empty-range: round cap at start/end was hit by centre sample
  - Slider thumb: 10dp internal padding shifts thumb x by ~5% from centre
  - Slider progress_changes: double setContent → switched to single composition
Workflow split:
- ci.yml: PR to master (opened/synchronize) → check-version + unit-tests
  + android-tests (API 36). Runs on every push to the PR, cancels previous runs.
- release.yml: PR to master (closed, only if merged) → check-tag + build-release
  + create-release + jitpack-build + pr-summary.

Master branch protection (applied via GitHub API):
- Pull request required before merging
- 1 approving review + code owner review (CODEOWNERS)
- Stale reviews dismissed on new push
- Linear history required (squash/rebase)
- Force-push, branch deletion, fork sync disabled
- Conversation resolution required
- enforce_admins: true (rules apply to everyone)

Owner can self-approve via CODEOWNERS (LeandroLCD is the sole code owner,
GitHub auto-requests their review on every PR including their own).

Files added:
  .github/CODEOWNERS                      — maps /* to @LeandroLCD
  .github/branch-protection/master.json    — reproducible protection config
  .github/workflows/ci.yml                — CI on PR open/synchronize
  .github/workflows/release.yml           — release on PR close+merge

Files removed:
  .github/workflows/release-pipeline.yml   — replaced by ci.yml + release.yml
@github-actions

Copy link
Copy Markdown

🧪 Unit Test Report — :component module

17 tests   17 ✅  0s ⏱️
 3 suites   0 💤
 3 files     0 ❌

Results for commit 7f13738.

@github-actions

Copy link
Copy Markdown

🤖 Instrumented Test Report (API 36)

1 tests   1 ✅  0s ⏱️
1 suites  0 💤
1 files    0 ❌

Results for commit 7f13738.

@LeandroLCD
LeandroLCD merged commit 584d34a into master Aug 14, 2026
5 checks passed
@github-actions

Copy link
Copy Markdown

🚀 Release Pipeline — Resumen

# Paso Estado Detalle
1️⃣ Check Tag & Bump success primer release: v0.1.0
2️⃣ Build Release AAR success ./gradlew :component:assembleRelease
3️⃣ GitHub Release success Tag v0.1.0 + AAR · Ver GitHub Release
4️⃣ JitPack Build success 📄 Build Log · Status: ok

📌 Versión nueva: 0.1.0  ·  🏷️ Último tag: ninguno

📥 Dependency (JitPack)

// settings.gradle.kts
maven { url = uri("https://jitpack.io") }

// build.gradle.kts
implementation("com.github.LeandroLCD:compose-components:0.1.0")

🤖 Generado automáticamente por el Release Pipeline · Run #1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant