Styling
MealzUIKit UI is SSR HTML/CSS inside the WebView. Branding is applied through CSS manifests, not native theme protocols (those belonged to the Older MealzCore stack). Defaults already look fine — register manifests only when you need brand overrides.
Where to Put Your Files
Mealz already ships SSR + retailer default styles inside the WebView. You only add files for extra brand overrides, then register them. CustomStyle resolves those paths for you (Android assets / iOS main bundle).
- Ship the same relative tree on both targets (Android
assets/and iOS main bundle), e.g.styles/base-manifest.json+ CSS next to it. - Register once from shared code with that same relative path —
CustomStylealready loads from the platform package.
CSS (and other assets) listed in a manifest’s links array are resolved relative to the directory that contains that manifest. Keep overrides under that tree — files outside the registered manifest folders are not loaded.
Example layout:
styles/
base-manifest.json # links → ./override/base.css
catalog-manifest.json
override/
base.css
catalog.css
Register a Manifest
import ai.mealz.uikit.ui.webview.CustomStyle
import ai.mealz.uikit.ui.webview.ManifestFeatureType
CustomStyle.getInstance().registerManifest(
path = "styles/base-manifest.json",
type = ManifestFeatureType.BASE
)
// Optionally per feature:
CustomStyle.getInstance().registerManifest(
path = "styles/catalog-manifest.json",
type = ManifestFeatureType.CATALOG
)
ManifestFeatureType values: BASE, CATALOG, PLANNER, RECIPE.
Example manifest:
{
"updated-at": "2026-01-09T11-26-00",
"layer": "retailer",
"links": [
"./override/base.css"
]
}