Skip to content

Add adaptive flow grid and local layout advisor - #3

Open
dedsec1911 wants to merge 1 commit into
vedangj72:mainfrom
dedsec1911:adaptive-layout
Open

Add adaptive flow grid and local layout advisor#3
dedsec1911 wants to merge 1 commit into
vedangj72:mainfrom
dedsec1911:adaptive-layout

Conversation

@dedsec1911

@dedsec1911 dedsec1911 commented Aug 5, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • add AdaptiveFlowGrid and Adaptive.layoutValue for deterministic layouts that respond to viewport width, aspect ratio, and density
  • wire the adaptive grid into the Android and Desktop samples and cover its resolver plus Compose behavior with tests
  • add an optional local Ollama layout advisor for development-time token suggestions without bundling a model or adding a runtime dependency
  • remove unused multiplatform dependencies, keep the JS platform lookup lightweight, and stop tracking machine-local configuration

Why

KitFlow exposes responsive primitives, but consumers still have to hand-build wrapping grids for narrow phones and unusual screen shapes. This adds a small common API for that layout decision while keeping runtime behavior deterministic and offline. The local LLM is deliberately an optional developer tool rather than part of the shipped library.

Impact

  • no model, Python code, or Ollama client is packaged with the Kotlin library
  • direct published POM dependencies drop from 10 to 6 on Android/Desktop/Wasm and from 12 to 7 on JS
  • measured aggregate artifact growth is about 0.58%; the Android AAR grows by 5.6 KB and the Desktop JAR by 4.2 KB
  • the new grid uses natural height by default and offers opt-in overflow clipping

Validation

  • :shared:desktopTest — 22 tests passed, including resolver and Compose UI coverage
  • Android, Desktop, JS, and Wasm shared targets compiled successfully
  • Android and Desktop manual samples compiled successfully
  • local layout-advisor test suite — 4 tests passed

@dedsec1911
dedsec1911 marked this pull request as ready for review August 5, 2026 07:47
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.

2 participants