# ArkUI Subsystem Changelog ## cl.arkui.1 Floating Point Number Support Added for timeZoneOffset of the \ Component **Access Level** Public **Reason for Change** The time zone offset for some countries and regions is a floating point number. Therefore, floating point numbers need to be supported. **Change Impact** This change is a compatible change. **API Level** 8 **Change Since** OpenHarmony SDK 4.1.6.5 **Key API/Component Changes** In versions earlier than API version 11, any floating point number set for the **timeZoneOffset** parameter of the **\** component is converted to the corresponding integer. Since API version 11, a floating point number in the { 9.5, 3.5, -3.5, -4.5, -5.5, -5.75, -6.5, -9.5, -10.5, -12.75 } range can be set for the **timeZoneOffset** parameter of the **\** component. **Adaptation Guide** For details, see [TextClock](../../../application-dev/reference/apis-arkui/arkui-ts/ts-basic-components-textclock.md). ## cl.arkui.2 Change in the Default Shadow Blur Radius of the \ Component **Access Level** Public **Reason for Change** The original default shadow blur radius, 5 vp, is too small for the **\** component according to the UX specifications. Therefore, the default shadow blur radius is enlarged to 20 vp. **Change Impact** This change is a compatible change. It enhances the default display effect of the component. **API Level** 11 **Change Since** OpenHarmony SDK 4.1.6.5 **Key API/Component Changes** Before OpenHarmony SDK 4.1.6.5, the default shadow blur radius of the **\** component is 5 vp. ![gauge](figures/oldGauge.png) Since OpenHarmony SDK 4.1.6.5, the default shadow blur radius of the **\** component is 20 vp. ![gauge](figures/newGauge.png) **Adaptation Guide** No adaptation is required. Yet, since the default display effect is changed, you need to check whether it meets your expectation. Change the display variables where necessary. ## cl.arkui.3 Return Value Unit Change for getItemRect and getItemRectInGroup **Access Level** Public **Reason for Change** The unit of the return value type **RectResult** should be vp, not previously px. **Change Impact** This change is a non-compatible change. The unit of the value returned by o the **getItemRect** API of a scrollable component and the **getItemRectInGroup** API of the **\** component is changed from px to vp. The affected scenarios are as follows: (a) The **getItemRect** API is called in a scrollable component to obtain the size and position of a child component. Before change: The size and position returned are both in px. After change: The size and position returned are both in vp. (b) The **getItemRectInGroup** API is called in a **\** component to obtain the size and position of a list item in a list item group. Before change: The size and position returned are both in px. After change: The size and position returned are both in vp. **API Level** 11 **Change Since** OpenHarmony SDK 4.1.6.5 **Key API/Component Changes** **getItemRect** (**\**, **\**, **\**, **\**) and **getItemRectInGroup** (**\**) **Adaptation Guide** If the px unit is required, you can use the **vp2px** API to convert the unit. ## cl.arkui.4 Log Level Change for Value Assignment of @Link/@ObjectLink Decorated Variables **Access Level** Public **Reason for Change** The log level for value assignment of an @Link/@ObjectLink decorated variable in the parent component is changed from WARN to ERROR. **Change Impact** This change is a non-compatible change. After the change, an error is reported if an @Link/@ObjectLink decorated variable is not assigned a value in the parent component. **API Level** 11 **Change Since** OpenHarmony SDK 4.1.6.5 **Example** ``` let NextID: number = 1; @Observed class ClassA { public id: number; public c: number; constructor(c: number) { this.id = NextID++; this.c = c; } } @Entry @Component struct Parent { @State message: string = 'Hello'; build() { Column() { // ERROR: Property 'message' in the custom component 'Child' is missing (mandatory to specify). // ERROR: Property 'message1' in the custom component 'Child' is missing (mandatory to specify). Child(); } } } @Component struct Child { @Link message: string; @ObjectLink message1: ClassA; build() { Row() { } } } ``` **Key API/Component Changes** N/A **Adaptation Guide** If a child component uses an @Link/@ObjectLink decorated variable, then the variable must be assigned a value in its parent component. ## cl.arkui.5 Click Event Change for isShow in bindmenu **Access Level** Public **Reason for Change** When **isShow** is used in **bindMenu**, the menu can be displayed only through **isShow**. **Change Impact** This change is a non-compatible change. After the change, when **isShow** is used in **bindMenu**, clicking the parent component does not show the menu. **API Level** 11 **Change Since** OpenHarmony SDK 4.1.6.5 **Example** ``` @Entry @Component struct MenuExample { @State listData: number[] = [0, 0, 0] @State isShow: boolean = false @Builder MenuBuilder() { Flex({ direction: FlexDirection.Column, justifyContent: FlexAlign.Center, alignItems: ItemAlign.Center }) { ForEach(this.listData, (item:number, index) => { Column() { Row() { Image($r("app.media.icon")).width(20).height(20).margin({ right: 5 }) Text(`Menu${index as number + 1}`).fontSize(20) } .width('100%') .height(30) .justifyContent(FlexAlign.Center) .align(Alignment.Center) .onClick(() => { console.info(`Menu${index as number + 1} Clicked!`) }) if (index != this.listData.length - 1) { Divider().height(10).width('80%').color('#ccc') } }.padding(5).height(40) }) }.width(100) } build() { Column() { Text('click for menu') .fontSize(20) .margin({ top: 20 }) .onClick(()=>{ this.isShow = true }) .bindMenu(this.isShow, this.MenuBuilder, { onDisappear: ()=>{ this.isShow = false } } ) } .height('100%') .width('100%') .backgroundColor('#f0f0f0') } } ``` **Key API/Component Changes** bindMenu **Adaptation Guide** When **isShow** is used in **bindMenu**, the menu is displayed only after **isShow** is changed from **false** to **true** in related click, gesture, and hover events. If the menu cannot be displayed after the value of **isShow** is changed, use logs to print the value of **isShow** before and after your change. If the value remains unchanged, check whether the value of **isShow** is not updated to **false** in **onDisappear** when the menu disappears, or whether **isShow** is set to **true** initially. ## cl.arkui.6 Removal of Incorrect Inheritance from OffscreenCanvas Class Declaration **Access Level** Public **Reason for Change** In the previous **OffscreenCanvas** class declaration, the parent class incorrect. As a result, DevEco Studio incorrectly associates methods and attributes that are not of the **OffscreenCanvas** class. **Change Impact** This change is a compatible change. After the change, the methods and attributes of the **OffscreenCanvas** class can be correctly displayed for intelligent code completion in DevEco Studio. **API Level** 11 **Change Since** OpenHarmony SDK 4.1.6.5 **Key API/Component Changes** OffscreenCanvas **Adaptation Guide** N/A ## cl.arkui.7 Float Type Support Added for layoutWeight **Access Level** Public **Reason for Change** The **layoutWeight** parameter needs to be set more precisely. **Change Impact** This change is a compatible change. **API Level** 9 **Change Since** OpenHarmony SDK 4.1.6.5 **Key API/Component Changes** **layoutWeight** Before API version 12, when the parameter is set to a float number, the digits after the decimal point are not counted. Since API version 12, when the parameter is set to a float number, the digits after the decimal point are counted. **Adaptation Guide** N/A ## cl.arkui.8 Height Configuration Change for the \ Component **Access Level** Public **Reason for Change** In previous versions, the **\** component always adapts its height to child components, regardless of whether the **height** is set. The change is to correct this known issue. **Change Impact** This change is a non-compatible change. The height of the **\** component can be customized. **API Level** 9 **Change Since** OpenHarmony SDK 4.1.6.5 **Key API/Component Changes** **\** component Before API version 11, the **\** component always adapts its height to child components, regardless of whether the **height** is set. Since API version 11, the **\** component is drawn based on the specified height. If no height is specified, the component adapts its height to child components. **Adaptation Guide** N/A ## cl.arkui.9 Behavior Change for backgroundColor in \ of the surface Type **Access Level** Public **Reason for Change** Background color configuration is required for the **\** of the surface type. **Change Impact** This change is a non-compatible change. Before change: The background color is black by default regardless of the **backgroundColor** attribute settings. After change: The background color specified through the **backgroundColor** attribute takes effect. **API Level** 9 **Change Since** OpenHarmony SDK 4.1.6.5 **Example** ``` @Entry @Component struct XComponentBKColor { private surfaceId: string = '' private xComponentContext: Record void> = {} xComponentController: XComponentController = new XComponentController() build() { Row() { XComponent({ id: 'xcomponentid', type: XComponentType.SURFACE, controller: this.xComponentController }) .onLoad(() => { this.xComponentController.setXComponentSurfaceSize({ surfaceWidth: 1920, surfaceHeight: 1080 }) this.surfaceId = this.xComponentController.getXComponentSurfaceId() this.xComponentContext = this.xComponentController.getXComponentContext() as Record void> }) .width('640px') .height('480px') .backgroundColor(Color.White) } } } ``` **Key API/Component Changes** XComponent **Adaptation Guide** After setting the **backgroundColor** attribute for the **\** component of the surface type, ensure that the background color is what is required by the use scenario. ## cl.arkui.10 Display Effect Change for the \ or \