Skip to content

Releases: lynx-family/lynx

3.5.1

24 Nov 03:44

Choose a tag to compare

[BugFix] Fix potential crash when `devtool_component_attach` is on.

Synchronize the `lynx_debug_enabled` switch to the native layer and use it to determine whether debugging is enabled.

AutoLand: release/3.5, release_3.5_weekly_20251117

3.5.0

17 Nov 08:31

Choose a tag to compare

Changelog

3.5.0

✨ Features

  • [Feature][Harmony] TemplateBundle support async decoding (28ed738) @pilipala195

    On the Harmony platform, ets code runs on the main thread by default. TemplateBundle.fromTemplate can block the main thread and causing app_freeze.
    This MR introduces the TemplateBundle.fromTemplateAsync interface, which allows callers to wait asynchronously using a Promise, thus avoiding blocking other operations on the main thread.

  • [Feature][Android] LynxModuleAndroid Authentication (2e32ba6) @OverWatch-Winder

    Use LynxMethod verification interface to verify whether the LynxMethod is allowed to be called.

  • [Feature][DevTool] Support getBoxModel and getNodeForLocation for ios clay (c4cd7c1) @yuweizheng

    Support getBoxModel and getNodeForLocation for ios clay

🐛 Bug Fixes

  • [BugFix] add auto-size feature in embeddedMode. (b5c2832) @nhsprite

    add auto-size feature in embeddedMode.

    1. create shadowNode for imageElement in case auto-size is true;
    2. triggering requestLayout in justShadowNodeSize method, and mark element layoutNode as dirty;
    3. invoke LynxUILayoutTick with closure, and take the closure as the trigger layout method in EmbeddedMode.

    (cherry picked from commit 1abce1e0c5847f77a56494d6cefa80400c7c75e9)

  • [BugFix][Event] Fix the problem of catch interception failure. (da53e66) @rAY-ooo

    description: When a catch-type event listener is set on the target node, the return result should be checked to prevent subsequent event propagation.

  • [BugFix] Report error when evaluateJavaScriptBytecode fails (5f0306b) @lybvinci

    Currently, we only log it, but it should be reported.

    (cherry picked from commit 04c4d4558340817eae6b6a54429e9a8d3bf8714e)

  • [BugFix] Add preload event reporting for iOS (6139638) @lybvinci

    Used to assist in locating iOS JSC crash issues.

  • [BugFix][Event] Provides a client interface for tapSlop on Android. (cbc3c95) @rAY-ooo

    description: tapSlop is a front-end switch with a default value of 50px. A client-side interface is provided to set the value of tapSlop, but when both the client and front-end are set, the front-end setting takes precedence.

  • [BugFix][Android][EmbeddedMode] Fix inline view not take effect. (f6145c6) @Randycn

    Support inline view on Android when enable embedded mode.

    • Propagate inline view sign and impl_id via text props
    • Measure inline children recursively and pass metrics to Java
    • Align inline views by mapping Java results back to children
  • [BugFix][Harmony] Fix the crash caused by multi-threaded reading and writing of font face. (be6916b) @Randycn

    Add read-write locks to font_faces_.

  • [BugFix][iOS][image] LynxUIImage preview hash supports default metaData (55061b8) @liubb0516

    LynxUIImage placeholder-hash-config preview type hash supports default metaData

    m-6788453885

  • [BugFix] Fix compile error in i18nService (57d4cb5) @ykai55

    Add the LynxServiceProtocol.h to the Lynx component, which just includes LynxServiceProtocol.h in the LynxServiceAPI component. This change avoids the breaking change of service implementation.

    (cherry picked from commit 70007c52ad916d0f37842f2d90589974756eb575)

  • [BugFix] Fix related issues when embeddedMode with jsruntime on (c998236) @nhsprite

    1. considering the globalProps passed in LynxViewGroup for the embeddedmode rendering
    2. AirMode is AIR_MODE_FIBER in embeddedMode, but it's still needed to send onJSPrepared event if logic executor is not set.
    3. introducing LynxViewGroup into EmbedderTestVC, and adapts to the issue that lynxConfig is changed while LynxTemplateRender initialize process.
    4. fix the crash issues that embeddedmode set but jsruntime is not init.
    5. merge moduleWarpper with lynxViewGroup & lynxViewBuilder

    (cherry picked from commit 6626fc02910f8066f6e471846908c9cbc185bd1f)

  • [BugFix][iOS][EmbeddedMode] Fix line-height not take effect. (57f9df8) @Randycn

    1.Fix line-height not take effect.
    2.Fix vertical-align not take effect.

  • [BugFix][LynxRecorder]Fix crash issues during recording and replay (d0d0c7c) @RovicnowYoyi

    1. baseInspectorOwner maybe not ready yet.
    2. add null check for piper_val in ParsePiperValueToJsonValue to prevent crash when parsing JavaScript object properties that may be null, undefined, or when getProperty() returns nullptr.

    (cherry picked from commit 00e53c54560d0dbbde8524673b1702d895f4d5da)

  • [BugFix] add trailKey for quickjs thread checker (f79538c) @nhsprite

    add TrailKey for quickjs thread checker.

  • [BugFix][Harmony] Use postTask instead of postSyncTask to avoid stuck. (e549be7) @Tamerlx

    This MR is to use postTask instead of postSyncTask to avoid stuck.

    issue:m-6787511750

    (cherry picked from commit e34df2679054d408a5bb2be207a319a1ff107db7)

  • [BugFix][LayoutInElement] fix the text decoration style issue (5a48b48) @linxs0211

    support text decoration for LayoutInElement mode

  • [BugFix] merge moduleWarpper with lynxViewGroup & lynxViewBuilder (1567104) @nhsprite

    1. merge moduleWarpper with lynxViewGroup & lynxViewBuilder
    2. add EmbedderModule for setData & getData from client.
    3. DLynxBridge should not be registered in EmbeddedMode.
  • [BugFix] Guard removal of layout node by checking parent and using actual parent (2ea58bb) @zhongyr

    In element-mode layout, removing a child's layout node assumed this
    element was its parent, which could be false and cause incorrect removals
    or crashes. Now we verify the child has a layout node and a parent, then
    remove it from its actual parent instead of unconditionally using
    this->sl_node_. This prevents invalid parent-child operations and
    stabilizes node removal paths.

    • Add null and parent checks before removal
    • Remove child via child->slnode()->parent()->RemoveChild(child->slnode())
    • Leave a FIXME to investigate mismatched parent relationships
  • [BugFix] prefers lynxGroup in LynxViewBuilder (e86ca68) @nhsprite

    prefers lynxGroup in LynxViewBuilder so that lynxView in the same LynxViewGroup may still
    has seperate globalThis in js environment.

  • [BugFix][Event] Fix a gesture conflict issue when Lynx cards overlapped. (936ece6) @rAY-ooo

    description:
    Previously, because OH_ArkUI_GestureEvent_GetNode was not supported, setting a HitTestBehavior of type Transparent would reset the event_dispatcher to that of the bottom-level Lynx card when multiple Lynx cards overlapped. This caused gesture comparison to fail, resulting in upper-level Lynx cards failing to respond to clicks.

    Therefore, we set the EventDispatcher to user_data on the gesture-bound node, and then retrieved the EventDispatcher from the node in the custom gesture determination interface to ensure consistency.

  • [BugFix][Memory] Unify MemoryReportTimer to use LynxEventReporter thread. (6803306) @Tamerlx

    Refactors LynxMemoryReportTimer on both iOS and Android to use the shared LynxEventReporter.delayRunOnReportThread.

    This change replaces platform-specific timers (NSTimer, ScheduledExecutorService) with a single, centralized scheduling mechanism.

    This simplifies the code, unifies threading for all reporting tasks, and improves resource management by eliminating redundant timers and threads.

  • [BugFix] Making sure that TemplateData is released properly (f626001) @nhsprite

    It's needed to make sure the templateData is released with the engine thread. In this patch
    an asscociated lynxContext is bind to templateData we will post the recycle runnable to
    engine thread if lynxContext is valid.

    thus that we have no need to keep the updateDataList at templateR...

Read more

3.3.3

13 Nov 08:36

Choose a tag to compare

[BugFix][Image] fix the image recycled issue

1.we need to keep image reference instead of keeping the reference to Map
2.mImageReferenceMap may be put more times, it's not safe to keep Image
reference here

issue:m-6792482501

3.5.0-rc.0

31 Oct 03:13

Choose a tag to compare

3.5.0-rc.0 Pre-release
Pre-release

This is an RC version, built based on the release/3.5 branch. It can be used to experience the latest features in advance.

3.4.2

09 Oct 04:42

Choose a tag to compare

Changelog

Summary

  • Android SDK is released with support for 16KB alignment.
  • Some bugfix have been made based on version 3.4.1.

✨ Features- [Feature][Harmony] Verify template when lazy bundle loading (8983e00) @ci_lynx

During the lazy bundle loading process on the Harmony platform, perform a security signature verification on the template buffer.

(cherry picked from commit 67906a8b1e09b506b9579475671377224e5d625e)### 🐛 Bug Fixes- [BugFix][Harmony] Fix background layer drawing logic to properly handle border radius rendering ([569e2d4](https://github.com/lynx-family/lynx/commit/569e2d40535b6ec8c78554a8498ff3b0bb267a94))  @rel-q


We use clip_path for clipping when border radius is present.- [BugFix][Android][EembeddedMode] Try fix index out of bounds exception. ([922f5b6](https://github.com/lynx-family/lynx/commit/922f5b6f65ad3df829ddcb38718337fb4c5cd5f4))  @Randycn


Add reading for letter-spacing style on platform.
Add decode error log.


(cherry picked from commit c30be5361a041dce5343b2bc87bcf8984b9b8960)
  • [BugFix] fix globalProps error with updateMetaData. (349aea7) @nhsprite

    In fiber now, we need to make sure to call kUpdateGlobalProps to trigger mts pipeline. It may be optimized later

    (cherry picked from commit ecfb9ba5f063b244ddcef723aaedcb43feddfd28)

  • [BugFix][Harmony] Fix background layer drawing logic to properly handle border radius rendering (9914374) @rel-q

    We use clip_path for clipping when border radius is present.

  • [BugFix][Harmony] fix crash when text process truncation (499df33) @ci_lynx

    text truncation may split surrogate pair. fix it by remove leading surrogate at the end of text.

    (cherry picked from commit 70e5ca5e12eecfacec094dbfb7cf9969e92d3a97)

  • [BugFix] Using Copy-Constructor for Dump ElementBundle (5a235c7) @nhsprite

    When dumping ElementBundle, it's needed to using copy-constructor to avoid
    effect on current loading templateEntry instance. As the destructor of TemplateEntry
    will visit the member of current loading TemplateBundle

    (cherry picked from commit c809c05f3138a00e2a052f781eb3d2d8c82e734d)

  • [BugFix][Android][Timing] Fix the issue of inaccurate timestamp acquisition. (9196ebd) @ci_lynx

    This MR is to fix the issue of inaccurate timestamp acquisition.

    (cherry picked from commit 134188c06d529d0ea4dff399c8f3c6cf6b6ddba0)

  • [BugFix][Android] Fix null exception when ILynxEventReporterService is missing. (d506849) @ci_lynx

    This MR is to fix null exception when ILynxEventReporterService is missing.

    (cherry picked from commit 712abc8443612dc0391799ab085a8f1c1bdc257b)

  • [BugFix][Frame] Call UIOp flush after SetFrameAppBundle (372f462) @ci_lynx

    After the frame's bundle is fetched and SetFrameAppBundle is called, it only enqueues a UI operation. painting_context()->Flush() must be called to trigger the queue flush; otherwise, the frame will fail to load and display.

    (cherry picked from commit 4d2b96e7ca05565cf3e5b6d8975af96eba8adeb2)

  • [BugFix] use global font collection (a451594) @linxs0211

    1.use global font collection
    2.add a settings to config

    (cherry picked from commit 62eeefbaeef664d84ee024f2dd16c7aaa6ee1aa0)

  • [BugFix] Prevent use-after-free in ResponseHandlerProxy listener callbacks (a6542aa) @nhsprite

    Fix race condition where ResponseHandlerProxy listener callbacks could be
    invoked after the proxy object has been released. This was causing crashes
    in corner cases where the callback outlived the proxy.

    Changes:

    • Make ResponseHandlerProxy inherit from std::enable_shared_from_this
    • Use weak_ptr in AddResourceListener callback to safely check if proxy
      still exists before invoking delegate callbacks
    • Prevent callback execution if proxy has been destroyed

    (cherry picked from commit ca1c690070cda196807c4ebbc6a878220af14f08)

  • [BugFix] Fix the UIFlush on lynxView detached. (ebdf942) @Yellow5A5

    It is unexpected to insert UIOp when LynxView is created, which will cause the ContextFree scenario to throw a Flush task to the main thread. This issue is fixed by using a flag for judgment.

    (cherry picked from commit 72d923d4e15290759ebbd7eeb300ba4ffd75d05c)

  • [BugFix][Event] Fix send global bind event when current target is detached (2c6bb23) @AdrianLCA

    Fix send global bind event when current target is detached

  • [BugFix] Fix dump element not set in PipelineOption (7d377fa) @usczz

    In the previous merge request, the update of PipelineOption using load options was refactored into ProcessLoadTemplateTimingOption. However, the dump element option was not set, resulting in the template bundle with a reusable element tree not being generated.

    This merge request fixes the issue by properly setting the enable_dump_element_tree option.

    (cherry picked from commit 0bb94e09fe322aadd27cee91a8e0d30dc6ee5a06)

  • [BugFix][Android] LynxEngine setThreadStrategy is ineffective as the input parameter is not used. (4bd11a4) @Yellow5A5

    1. Fix the trivial bug where LynxEngine setThreadStrategy is ineffective due to not using the input parameter.
    2. When the FallbackNewEngine behavior occurs during Engine reuse, mTemplateData should be loaded instead of incremental data.
    3. Add Trace information for the LynxViewConfigProcessor.
  • [BugFix] fix prepainting issue with volatile mBodyView (1117ec4) @nhsprite

    In prepainting mode, we need to mark bodyView with ShouleInterceptRequestLayout on,
    we access uiBodyView by lynxContext before, it's dangerouse as uiBodyView in lynxContext
    may change while engine reuse, we should access uiBodyView directly by templateRender.

    (cherry picked from commit f1283cfadfa19096442ee9f2cce65413e5e04815)

  • [BugFix][List] Fix not found hittest target in sticky item (07094de) @DwwWxx

    If set updateStickyForDiff to true, we should enumerate stickyTopListItemDict and stickyBottomListItemDict to find hit test target.

    (cherry picked from commit d67bd4c8a4bc078054d639b2dca14aed10cebc7b)

  • [BugFix] fix reuse engien with onPageStart (45d2765) @nhsprite

    In engineReuse case, onPageStart is missed. we need to call dispatchOnPageStart when tryRenderByReuseLynxRender

    NoLanding: release/3.4

    (cherry picked from commit 670a98d1c781dbaa04d29f1cd7397f69a3fb1832)

  • [BugFix] Use appropriate response handlers for image src vs placeholder loading (16e02a7) @rel-q

    Fix the image loading logic in UIFlattenImage and UIImage classes
    to use different response handlers based on whether loading the main image source
    or a placeholder image

    (cherry picked from commit af5cf2638978e4cb09a43be9f4e0b4d0500b610a)

  • [BugFix] correct state validation in loadTemplate and hydrate calls (f0c39fe) @lidadating

    • Fix state validation when users call loadTemplate to prevent improper states.
    • Prevent missing reset calls on repeated hydrate interface invocations, ensuring consistent state handling.

    (cherry picked from commit 91c688b2d161ed1b3605d94f95d36bdfefe2d978)

  • [BugFix] RequestFlushUIOperation in ElementManager::RequestLayout when embedded mdoe on (08dbeba) @ci_lynx

    In embedded mode, ElementManager::RequestLayout directly calls TemplateAssembler::OnLayoutAfter. Inside OnLayoutAfter, the current context is cleared, which causes a null pointer exception when GetCurrentPipelineContext()->RequestFlushUIOperation is executed after ElementManager::RequestLayout finishes.

    As a solution, we moved RequestFlushUIOperation into ElementManager::RequestLayout to fix the issue where it was being called after the current context was cleared.

    [internal]
    [end-internal]

    (cherry picked from commit 93f7e8300a7cbc4798c5f213ae305129270930bf)

  • [BugFix][DevTool] Fix missing devtool resources in HarmonyOS lynx_devtool HAR (6889154) @yuweizheng

    Fix the issue where the HarmonyOS devtool HAR package lacks devtool resources, causing redbox white screen...

Read more

3.3.2

17 Sep 12:07

Choose a tag to compare

[Infra] Remove lynx_v8_bridge so.

Remove lynx_v8_bridge so and use dev version of primjs to extract libnapi-v8.so for lynxdevtool.
At the same time, register devtool service to fix devtool connection problem.

3.4.1

01 Sep 03:04

Choose a tag to compare

Changelog

Some bugfix have been made based on version 3.4.0.

🐛 Bug Fixes

  • [BugFix] Add setUIRunningMode api to fix compile error (ad11bac) @nhsprite

    Add setUIRunningMode api to LynxViewBuilder, to fix some compile error happended on host app.

    NoLanding: release/3.4

    (cherry picked from commit c37f9d5ffa9c3f7f91fad405b28ffaf8f598d416)

  • [BugFix][Event] Fix the abnormal click issue of sticky nodes. (669cdd1) @rAY-ooo

    description: In the scroll container, the sticky node will be translated to the correct position, and this translation offset needs to be taken into account. Therefore, we need to record this offset in OffsetXForCalcPosition/OffsetYForCalcPosition.

    (cherry picked from commit 420dd102cbd6c0844f3994c38315d23a819e8d4e)

  • [BugFix][typings] Add recyclable property for list-item. (8e43a10) @DwwWxx

    Add recyclable property for list-item.

    NoLanding: develop

  • [BugFix] disable generic resource fetcher if has custom fetcher (583ad5c) @linxs0211

    1.add setHasCustomFetcher for custom fetcher
    2.disable new media fether when has custom fetcher for image

  • [BugFix] Add animate types for MainThread.Element (23d9975) @f0rdream

    Add missing animate types in MTS

  • [BugFix] block the measure & layout pipeline in prepainting mode. (005b87e) @nhsprite

    in engine reuse cases, measure & layout will be manually triggered to consume the layout_requested flag, it will cause bad cases
    that if lynxView with prepainting mode get a reused engine from pool, the measure & layout process will occurs npe because the loadTemplate
    has not be called, the subview is null here.

    so we will blocking the measure & layout process in prepainting mode

  • [BugFix][Harmony] Fix MergeGlobalProps method by adding early return for invalid input (01a4074) @rel-q

    Add null/invalid check for global_props parameter before processing

    (cherry picked from commit 4f6239d4151aa16d98c485ea0d11c63ba2ad5afc)

  • [BugFix] Add animate types for MainThread.Element (ace1e75) @f0rdream

  • [BugFix][Android][Gesture] Fix pan gesture onEnd callback event is null (55cb9be) @AdrianLCA

    Fix pan gesture onEnd callback event is null

    Autoland: release/3.4

    (cherry picked from commit 18fba7e8828f9d0185fe5e4a1367584392af4e47)

    (cherry picked from commit 1e55076a70ac2706867461efe0ef966e9214e052)

  • [BugFix] Fix lynx.loadScript lose app scope (640c6c6) @lybvinci

    the script's format may align with another js. we should wrapper it also

    (cherry picked from commit 30a434937dfcc9160d029c79fc18505bc9ae5b19)

  • [BugFix] Fix SelectorQuery types (df6809e) @Yradex

    Fix types of selectAll() of SelectorQuery.

  • [BugFix] Fix lynx layout proxy error in lynx context (854b91b) @ci_lynx

    when layout proxy not set, we run layou task directly

    (cherry picked from commit 65f581051a3bd5793e90fd192a3f99651ee05a85)

  • [BugFix][Event] Fix memory leak caused by mIntervalRunnableForLynxView. (f09b691) @rAY-ooo

    description: In the scroll container, the sticky node will be translated to the correct position, and this translation offset needs to be taken into account. Therefore, we need to record this offset in OffsetXForCalcPosition/OffsetYForCalcPosition.

    (cherry picked from commit b1c7d304399dd6cc8c5752eb70a55a8835792207)

  • [BugFix] Register DevToolService in LynxExplorer and update deprecated APIs (993637d) @ci_lynx

    • Register DevToolService in LynxExplorer
    • Replace deprecated overwrite methods:
      • LynxEnv#init
      • LynxServiceCenter#registerService.

    (cherry picked from commit a3b866415a2342279cfa223b747af684ffb96916)

  • [BugFix][NativeModule] Android & iOS record callback Thread Start Trace separately (d36aa48) @OverWatch-Winder

    Android & iOS record callback Thread Start Trace separately

  • [BugFix][Harmony] Fix sticky info update not responded to scroll-view (c09ff2e) @DwwWxx

    In this commit, we add two opportunities to update scroll-view's child nodes sticky translation:

    1. If noly child node's sticky info has changed without any scroll with scroll-view, we need to invoke UIScroll::OnScrollSticky to re-calculate translation.

    2. If scroll-view's layout info has changed which triggers scroll but not send ON_SCROLL_EVENT, we need to invoke UIScroll::OnScrollSticky to re-calculate translation.

    (cherry picked from commit 2b5931bf4a6ff5b85ece4f991d7c495e6c3aeb66)

  • [BugFix][Harmony] fix the gesture problem of scroll container (cd9e092) @keweibing

    when the contentSize < viewSize, needs to pass-through the touch gesture

    lynx-family/lynx-website#329

  • [BugFix][Event] Fix the abnormal click problem caused by overflow. (6f4057e) @rAY-ooo

    description: The default overflow value of UIBase is false. Except for UIView and UIComponent, other components should inherit UIBase to implement it. For components that inherit UIView, the DefaultOverflowValue interface should be rewritten to ensure that the default overflow value is false.

    (cherry picked from commit 36443262b03cae1a6ae022b377ff3ce431e64a5f)

🚀 Optimization

  • [Optimize] add trace to LynxView's onMeasure, onLayout, onAttachToWindow, onDetachedFromWindow functions. (eb5cb3e) @ShouruiSong

    This merge request aims to add tracing capabilities to LynxView’s critical lifecycle methods—onMeasure, onLayout, onAttachedToWindow, onDetachedFromWindow, and updateViewport—to enhance performance monitoring and issue diagnostics. These trace events will provide visibility into the execution of these methods for developers.

    1. Constant Definitions:

      • Added constants like LYNX_VIEW_ON_MEASURE, LYNX_VIEW_ON_LAYOUT, etc., in the TraceEventDef class and updated corresponding definitions in the lynx_android.api file.
    2. Trace Event Integration:

      • Added LYNX_VIEW tracing metadata to the beginSection method in the LynxTemplateRender class.
      • Introduced onTraceEventBegin and onTraceEventEnd methods in the LynxView class to wrap lifecycle method executions with trace events.
    3. Parameter Passing:

      • Critical parameters such as INSTANCE_ID, LYNX_VIEW, WIDTH_MEASURE_SPEC, HEIGHT_MEASURE_SPEC, and PARAMS are included in trace events for granular analysis.

    (cherry picked from commit aaa691ff7872d7c2c5b9abd05e6241eb531ecd50)

  • [Optimize] Set exception handler to OnceTask such that we can see the error message from log box. (28afcb4) @ShouruiSong

    The core objective of this merge request is to enhance the OnceTask class by adding exception handling capabilities, enabling developers to view error details in logs. This exception handling mechanism improves code robustness and maintainability, facilitating issue diagnosis and resolution when exceptions occur.

    1. OnceTask Class Updates

      • Added a new constructor OnceTask(final Callable< T > task, Consumer< Exception > exceptionHandler) to lynx_android.api.
      • Introduced the mExceptionHandler member variable in OnceTask.java and implemented the new constructor. The get method now invokes mExceptionHandler.accept() when catching exceptions, provided the handler is non-null.
    2. Dependent Class Adjustments

      • Updated LynxUI.java and UIBody.java to instantiate OnceTask using the new constructor. Exception handling logic now triggers the context.handleException() method on errors.
    3. Test Case Additions

      • Added the testExceptionHandle method in OnceTaskTest.java to validate the exception handling functionality.

    (cherry picked from commit 6070e5c43caa6f4b0eac9b746280ee10f9e00921)

  • [Optimize] Update fetch type defines (353b1aa) @huzhanbo1996

    Update fetch type defines

  • [Optimize][Trace] Use flowId to chain native update data calls across different threads ([4851076](http...

Read more

3.4.0

25 Aug 06:43

Choose a tag to compare

Changelog

✨ Features

  • [Feature] Complete WGPU prototype (01899b5) @shivamidow

    This change is an aggregate changeset to complete the WGPU prototype,
    which contains the following:

    • Additional interfaces and data types (e.g., GPUBindGroup, GPUSampler, etc.)
    • Updates on the licese boilerplates of the related IDL files
    • Implementation of shared buffers to reduce GPU memory footprints and
      computations
    • Hardware-assisted accelerated rendering on Android platforms
    • Support for the union types of array and interface
  • [Feature] Support generate bytecode callback (508b285) @lybvinci

    postJsCacheGenerateionTask add a callback params, user can use
    this to get bytecode source.

  • [Feature][DevTool] Support debugging for MTS Chunk. (743ee2a) @Dango-2021

    Support debugging for MTS Chunk.

  • [Feature][Styling] SimpleStyling renderer functions (3614ceb) @zhongyr

    Add render functions for SimpleStyling

    • CreateStyleObject - accept a JSObject for style map whose key is a number string for CSSId and value is a unparsed string value.
    • SetStyleObject - Bind a set of StyleObjects to SimpleStyleNode. Accept two args, 1 for node ref and a array of style object ref.
    • UpdateStyleObject - Change the contents of a style object created by the CreateStyleObject. And the updated styles will be applied to
      bound SimpleStyleNodes.
  • [Feature][Styling][Element] Implement simple style nodes to handle styles set by SimpleStyling APIs (fa4df53) @zhongyr

    Implement the SimpleStyleNode in FiberElement. Support set styles via SimpleStyling APIs to FiberElement.

  • [Feature] add IProcessViewInfoHook and ViewInfo to support reusing LynxEngine. (4b53d58) @ShouruiSong

    The primary goal of this merge request is to add IProcessViewInfoHook and ViewInfo to enable reuse of LynxEngine. These changes aim to improve system performance and resource utilization, allowing LynxEngine to process view information and rendering operations more efficiently.

    ViewInfo is a critical class for enabling the reuse of the Lynx Engine. It stores essential rendering metadata (e.g., layout coordinates, clipping boundaries, z-index). After decoupling the Platform View (e.g., Android/iOS native views) from LynxUI (the cross-platform UI abstraction layer), ViewInfo acts as a platform-agnostic data layer to coordinate drawing operations.

    IProcessViewInfoHook is a crucial class for enabling the reuse of the Lynx Engine. In the future, LynxUI will inherit IProcessViewInfoHook, and ViewInfo will hold an instance of IProcessViewInfoHook. At critical stages, ViewInfo will invoke the interface methods of IProcessViewInfoHook to record rendering information.

  • [Feature][iOS] Support generate bytecode callback (3b9a587) @lybvinci

    postJsCacheGenerateionTask add a callback params, user can use
    this to get bytecode source.

  • [Feature] LynxUI inherits and implements IProcessViewInfoHook to enable the reuse of the Lynx Engine's core logic. (fb97551) @ShouruiSong

    The primary goal of this merge request is to enable LynxUI to inherit and implement the IProcessViewInfoHook interface, thereby achieving reuse of the Lynx Engine's core logic.

    • The LynxUI class now implements the IProcessViewInfoHook interface, with new methods such as processViewInfo, dispatchProcessViewInfo, etc.

    • Related classes (e.g., LynxFlattenUI, UIBody, UIGroup) have added methods to handle rendering node updates, view detachment, and other operations.

    • Added the detachWithView method in LynxBaseUI and its subclasses to manage view detachment, including recursive detachment of child views.

    • The ViewGroupDrawingOrderHelper class now includes methods to retrieve drawing order indices and prepare drawing sequences, improving control over child view rendering.

  • [Feature] Provides an API for the platform layer to communicate with the Layout thread. (3cf0f79) @ChrisChan0668

    The implementation details are as follows:

    • A new API, runOnLayoutThread , is added to LynxContext, which accepts a task as a parameter.
    • This task is passed to the C++ layer, and then, leveraging the Actor's capabilities, the task is posted to the Layout thread.
    • The execution of this task is triggered on the Layout thread.
      Based on this API, the platform layer can initiate operations on ShadowNode from any thread, ensuring that all ShadowNode-related operations are executed on the Layout thread.
  • [Feature] [Frame] [Android] add UIFrame, LynxFrameView and LynxFrameRender (cf7db9b) @Awuiil

    Summary of this commit:

    1. add UIFrame, LynxFrameView and LynxFrameRender

    2. add built-in behavior for frame element

  • [Feature] adding loadByteCode from external interface for jsruntime (0677def) @nhsprite

    adding loadByteCode from external interface for jsruntime to optimize codecache usage.

  • [Feature] add OnceTask.java such that we can ensure async task only run once. (21cd817) @ShouruiSong

    The primary objective of this pull request is to introduce the OnceTask class, ensuring asynchronous tasks execute only once. This enhancement optimizes code logic, prevents redundant executions, and improves program performance and stability.

  • [Feature][iOS] Add interfaces to enable detach and reatach View and UI (d0c081b) @zhongyr

    Add

    • detachAllUIViews to enable detach UIViews from UIs
    • rebuildAllUIViewsAndHierarchy to create views for UIs without an
      existing UIView, create the View hierachy based on UI tree and then
      create background and border layers according the properties.
  • [Feature] Add attachToView, createViewAsync, ensureCreateView, rebuildViewTree to support reuse Lynx Engine. (688fccb) @ShouruiSong

    Precise Technical Translation

    This merge request aims to enhance the view management and rendering capabilities of the Lynx framework on Android. It centers around the addition of rebuildViewTree and createViewAsync methods to optimize view reconstruction and asynchronous creation workflows, improving both performance and user experience.

    1. C++ Code:

      • Added EnqueueHighPriorityUIOperation in BeforeFlush (within painting_context_android.cc) to rebuild the view tree before rendering.
    2. Java Interface Definitions (lynx_android.api):

      • New methods in classes:
        • FlattenUIImage, FlattenUIText
        • LynxImageManager
        • LynxUIOwner.rebuildViewTree()
        • PaintingContext.rebuildViewTree()
    3. Java Implementations:

      • LynxUIOwner & PaintingContext: Added rebuildViewTree() to trigger view tree reconstruction.
      • LynxBaseUI and subclasses:
        • Renamed detachWithViewdetachWithViewInfo
        • Added attachToView, createViewAsync, and ensureCreateView for asynchronous view creation.
      • UIBody:
        • Added appendUIWithCreateViewAsync and rebuildViewTree for managing asynchronously created views.
      • ViewInfo:
        • New methods: setPaintFilter, setPaintFont, setPaintStyle, setPaintStrokeWidth.
  • [Feature] [Android] add parserLynxViewBuilder API for LynxTrailService (0e47822) @Awuiil

    To parse LynxViewConfig

  • [Feature] Add attachToView, createViewAsync, ensureCreateView, rebuildViewTree to support reuse Lynx Engine. (57b8249) @ShouruiSong

    Precise Technical Translation

    This merge request aims to enhance the view management and rendering capabilities of the Lynx framework on Android. It centers around the addition of rebuildViewTree and createViewAsync methods to optimize view reconstruction and asynchronous creation workflows, improving both performance and user experience.

    1. C++ Code:

      • Added EnqueueHighPriorityUIOperation in BeforeFlush (within painting_context_android.cc) to rebuild the view tree before rendering.
    2. Java Interface Definitions (lynx_android.api):

      • New methods in classes:
        • FlattenUIImage, FlattenUIText
        • LynxImageManager
        • LynxUIOwner.rebuildViewTree()
        • PaintingContext.rebuildViewTree()
    3. Java Implementations:

      • LynxUIOwner & PaintingContext: Added rebuildViewTree() to trigger view tree reconstruction.
      • LynxBaseUI and subclasses:
        • Renamed detachWithViewdetachWithViewInfo
        • Added attachToView, createViewAsync, and `ensureCre...
Read more

3.4.0-rc.0

01 Aug 08:42

Choose a tag to compare

3.4.0-rc.0 Pre-release
Pre-release

This is an RC version, built based on the develop branch. It can be used to experience the latest features in advance.

3.3.1

25 Jul 03:51

Choose a tag to compare

Some bugfixes have been made for version 3.3.0.

💡 Features

  • [Feature] Support skip-redirection and MediaResourceFetcher for local image resource (59c6436) @liubb0516

    support skip-redirection and MediaResourceFetcher for local image resource

    (cherry picked from commit 87e5cc2f677e874bb34ec65bdc21ca5d26960912)

🐛 Bug Fixes

  • [BugFix][DevTool] add safeguard checks in RunDevToolFunction to prevent false error logs (36c7039) @yuweizheng

    add safeguard checks in RunDevToolFunction to prevent false error logs

    (cherry picked from commit 3ff8064f87f39b20832d45bc14cf45e1f5299dfb)

  • [BugFix] make reloadTemplate with safety globalProps (59bafd7) @nhsprite

    reloadTemplate with globalProps now passing raw globalProps, it's unsafe to pass globalProps to tasm thread, we need to make a deepClone to lepusValue to make thread safe.

    (cherry picked from commit 35d69990d39c2d9e7fa65bb5673613cebc538931)

  • [BugFix] Fix OOM caused by too many CallbackImpl instances (00300da) @OverWatch-Winder

    When calling JSB with callback frequently, if the callback is not called back, the Java CallbackImpl instance cached in the Native layer will not be destroyed, resulting in OOM

    (cherry picked from commit 32b327cbe06c9d0adaa56c55b0910496bc4cb171)

  • [BugFix] fix nested query component. (a0036d4) @nhsprite

    Nested calling query component may cause crash now, it's caused by modifing url_to_lifecycle_option_map_ while looping url_to_lifecycle_option_map_, eg: calling queryComponent in callback of queryComponent.
    It's reasonable to use extract to accquire lifecycleOption list from url_to_lifecycle_option_map_ first, and then call OnLazyBundleLifecycleEnd for each option. QueryComponent called in OnLazyBundleLifecycleEnd will just return because templateEntry is cached now.

    TODO: adding test cases for nested query component cases.

    (cherry picked from commit 87e82d787a788314025c98835944662e4f58055f)

  • [BugFix] enable FIX_FIBER_REMOVE_TWICE_BUG only in RadonArch. (0f08a2c) @DragonDragonDDD

    As title described.

    (cherry picked from commit f331e642f704a003bff529f4d48c0bc282878ba6)

  • [BugFix][Fiber] Fix the issue that CSSVariable changes on parent nodes did not affect child nodes in RadonToFiber (a5ab4d8) @ci_lynx

    When RadonDiff, RadonNode only copies the css_variable_ part of the CSSVariableBundle and does not copy the css_variable_related_ part, So when css-var parent node changed, related css in child node won't be affected.

  • [BugFix][Android][Event] Fixed the issue that the keyboard cannot be retracted when touching other areas when input becomes the first focusedUI through uimethod. (be15d06) @rAY-ooo

    description: In the lazy loading scenario of TouchEventDispatcher, the input will setFocusedUI when the focus changes, but the TouchEventDispatcher may not have been created at this time, which makes the setting invalid, and then the input focus cannot be transferred and the keyboard cannot be retracted.

    (cherry picked from commit abbff3d3390266d78cee8131a63c4254cb56b58b)

  • [BugFix][Element] Fix page element not record when AttachToElementManager causing white screen (e2cf9a7) @usczz

    In the current implementation, the reused element bundle is deeply cloned and attached to the target ElementManager by TreeResolver. TreeResolver first sets the root element as its current page, which removes the old page from the internal NodeManager. Then, FiberElement's AttachToElementManager is called recursively for each element in the tree. PageElement overrides this behavior by first calling the base class's AttachToElementManager, which records its element ID in the NodeManager. After that, it calls SetFiberPageElement to set itself as the root and removes its element ID from the internal NodeManager, causing the PageElement entry to be deleted. This removal can lead to incorrect layout results when using UNSPECIFIED or AT_MOST measure specs, as these require looking up the corresponding element in the NodeManager during layout propagation.

    In this merge request, SetFiberPageElement will be called only in PageElement’s overridden AttachToElementManager method and will be invoked before the base class’s AttachToElementManager to ensure that the page element's entry remains in the NodeManager. Additionally, a DCHECK is added in layout_mediator's OnLayoutUpdate to verify that no element entries are missing from the NodeManager during layout result propagation.

    (cherry picked from commit 02c0b7163958e412a7d1481e392b702a17eb2129)

  • [BugFix][DevTool] Eliminate unnecessary inspector initialization in Non-LepusNG context. (d59de54) @Dango-2021

    (cherry picked from commit a64614521d567f30557e6b036127d7ee4456502d)

  • [BugFix] Remove JSVM deps for openssl symbol error (64d4066) @ci_lynx

    Remove JSVM deps for openssl symbol error.

  • [BugFix] Add NPE protection for DisplayMetricsHolder (daa29fb) @ChrisChan0668

    In some special ROMs, WindowManager.getDefaultDisplay() may return a null object, so we need to check before use.

    (cherry picked from commit 2c429e81e3dd74e655957df9b181b4da3db126e4)

  • [BugFix] Fix the JS error when Callback is undefine in JSB (90c62f5) @OverWatch-Winder

    Callback in JSB can be undefined, and JS errors should not be reported

    (cherry picked from commit 5fa9bde167f4fa61d1a95c08fc941434dd9f3e01)

  • [BugFix][ZIndex] fix the negative zIndex insertion issue (d44db20) @linxs0211

    The element container has a should_skip_index_calculation logic that skips index calculation if there are no zIndex children and insertion is at the end (ref=null). However, it doesn't account for negative_z_children_, causing incorrect index calculation. It's updated so that if any zIndex exists, index calculation is forced.

  • [BugFix][Element] Fix shorthand CSS Property with CSS Variable value is reset in threaded element resolution (83a599b) @usczz

    In the current implementation, during threaded element resolution, CSS Variable resolution is postponed as an engine thread task. However, when handling shorthand CSS properties, the actual values are not resolved, leaving only their keys in the parsed_style_map. Later, in the engine thread task that refreshes the CSS styles, the shorthand properties are expanded into longhand properties. During the diffing process between the previous and current style maps, shorthand properties are mistakenly included in the list of properties that require resetting.

    In this merge request, shorthand properties are excluded from the construction of reset_style_ids when comparing the previous parsed style with the new parsed style, preventing them from being reset unintentionally.

    (cherry picked from commit 3802d45420e6a90d13b4cbd62947d5247552c2ee)

  • [BugFix][DevTool][iOS] Fix the issue where DevToolViewControllerLifeListener was added to the incorrect VC when destroying LynxView. (520ea43) @Dango-2021

    Add DevToolViewControllerLifeListener to the top VC while skipping UITabBarController and UINavigationController.

    (cherry picked from commit 443003ed738a8a3c87a23a79578aa94812bb6dd4)

  • [BugFix][Trace] Fix crashes that occurred during element tree dumping in multithreaded environments. (c127272) @ci_lynx

    1.Deep clone lepus::Value objects when transferring data between threads to prevent JavaScript garbage collection issues.
    2. Pass instance_id instead of this to avoid crashes when the catalyzer instance is destroyed.

  • [BugFix][List] Fix list-item rtl layout error on Android platform. (bfc2247) @DwwWxx

    Because on the Android platform, we has one LinearLayout between ListContainerView and ListItemView and the layout position of ListItemView is relative to ListContainerView but ListItemView is added to LinearLayout, so in this commit, we ensure that the height of the LinearLayout is at least the size of the ListContainerView itself.

    (cherry picked from commit aa226d9aaf27642576b386f793e407b8ac26cba6)

  • [BugFix][iOS] Fix Image's reportTime error ([3429b89](34...

Read more