InAppConfigParser
Decodes the native-config JSON into an InAppMessage, strictly to the typed contract.
Presence of displayType is the gate — without it this is not a native in-app and the parser returns null. Parsing is fail-closed: a missing/malformed required field, an unknown display type, a missing display block, an empty required items array, or any coercion attempt (showClose:"true", duration:"5") collapses the whole config to null, so callers can safely no-op (the parser never throws). Unknown keys are ignored at every level. The envelope fields (inAppId/maxDisplays/cooldown/expireDate/ttl) are a deliberate extension over the contract and keep their existing tolerant reading.
With isDark = true, a dark overlay inside the display block is merged onto the light values before the strict parse (InAppDarkOverlay); a dark that is broken structurally or fails the strict parse is dropped with a warning and the light variant is parsed instead — the only fail-open exception (SDK-971). rawJson on the result always keeps the original (light) input.