github lynx-family/lynx-stack @lynx-js/web-core@0.27.0

Minor Changes

  • Add lynxView.sendNativeModuleEvent(moduleName, data) and context.setEventHandler(handler) on NativeModuleContext to push per-view, per-module structured-cloneable events from the main thread to background native modules. (#4411)

  • Add an optional nativeModulesInitData property on lynx-view to pass per-module structured-cloneable initial data via the 3rd context argument ({ initData }) to background native module factories without changing nativeModulesMap. (#4405)

Patch Changes

  • Resolve @lynx-js/web-core/encode to the unbundled encoder under the browser condition. A browser bundle now loads its wasm through the bundler instead of node:fs, so WebEncodePlugin can encode web bundles in the browser through @rspack/browser. Node.js keeps using the prebuilt dist/encode_prod. (#4426)

  • Add an opt-in sp unit transform. Set the transform-sp attribute or the transformSP property on <lynx-view> to rewrite sp lengths in stylesheets and inline styles to calc(N * var(--sp-unit)). --sp-unit defaults to 1px; set it on the <lynx-view> to follow the system font scale. (#4395)

    <lynx-view url="https://example.com/template.js" transform-sp="true" style="--sp-unit: 1.3px"></lynx-view>
  • Updated dependencies [113c47d]:

    • @lynx-js/web-elements@0.12.20
    • @lynx-js/web-worker-rpc@0.27.0

Don't miss a new lynx-stack release

NewReleases is sending notifications on new releases.