16e7c69efSopenharmony_ci# Weather 26e7c69efSopenharmony_ci 36e7c69efSopenharmony_ci### Introduction 46e7c69efSopenharmony_ci 56e7c69efSopenharmony_ciThis sample demonstrates one-time development for multi-device deployment by showing how to develop a weather app and deploy it across different devices. The demo app includes the following: home page, **Manage City** page, **Add City** page, and **Update Time** page. 66e7c69efSopenharmony_ci 76e7c69efSopenharmony_ci**How to Implement** 86e7c69efSopenharmony_ci 96e7c69efSopenharmony_ci1. Use the grid breakpoint system of responsive layout to implement different display effects on windows of different sizes. 106e7c69efSopenharmony_ci 116e7c69efSopenharmony_ci2. Use [SideBarContainer](https://gitee.com/openharmony/docs/blob/master/en/application-dev/reference/arkui-ts/ts-container-sidebarcontainer.md) to implement the sidebar. 126e7c69efSopenharmony_ci 136e7c69efSopenharmony_ci3. Use [GridRow](https://gitee.com/openharmony/docs/blob/master/en/application-dev/reference/arkui-ts/ts-container-gridrow.md) to implement content split and display. 146e7c69efSopenharmony_ci 156e7c69efSopenharmony_ci4. Use **Canvas** and **CanvasRenderingContext2D** to draw curves that show the air quality and sunrise and sunset. 166e7c69efSopenharmony_ci 176e7c69efSopenharmony_ci**How to Use** 186e7c69efSopenharmony_ci 196e7c69efSopenharmony_ci1. After the demo app is started, weather information of the added cities is displayed on the home page. By default, two cities are present. You can swipe left or right to switch between them. The sidebar is displayed by default on a large-screen (LG) device. When the sidebar is displayed, the content area occupies 2/3 of the screen; when the sidebar is hidden, the content area automatically extends to full screen. 206e7c69efSopenharmony_ci 216e7c69efSopenharmony_ci2. On a device that supports free window dragging, you can drag the window to the maximum width to show the sidebar. In this case, you can tap the sidebar control button to hide or display the sidebar. If you resize the window to MD through dragging, the sidebar and sidebar control buttons will be hidden. 226e7c69efSopenharmony_ci 236e7c69efSopenharmony_ci3. On a device that supports window dragging, the weather content area is automatically adapted to the window size while you're dragging the window. 246e7c69efSopenharmony_ci 256e7c69efSopenharmony_ci4. Touch the menu button in the upper right corner and tap **Update Time**. The **Update Time** page is displayed. This page has two columns on a tablet and one column on a small-screen device. 266e7c69efSopenharmony_ci 276e7c69efSopenharmony_ci5. Touch the menu button in the upper right corner and tap **Manage Cities**. The **Manage Cities** page is displayed, showing the cities you've added. This page has two columns on a tablet and one column on a small-screen device like phone. 286e7c69efSopenharmony_ci 296e7c69efSopenharmony_ci6. Touch **Add City** on the **Manage Cities** page. On the **Add City** page displayed, tap any city that has not been added before. The city will be added to the city list and the **Manage Cities** page will be displayed. 306e7c69efSopenharmony_ci 316e7c69efSopenharmony_ciDisplay Effect 326e7c69efSopenharmony_ci 336e7c69efSopenharmony_ci 346e7c69efSopenharmony_ci 356e7c69efSopenharmony_ci### Required Permissions 366e7c69efSopenharmony_ci 376e7c69efSopenharmony_ciN/A 386e7c69efSopenharmony_ci 396e7c69efSopenharmony_ci### Dependency 406e7c69efSopenharmony_ci 416e7c69efSopenharmony_ciN/A 426e7c69efSopenharmony_ci 436e7c69efSopenharmony_ci### Constraints 446e7c69efSopenharmony_ci 456e7c69efSopenharmony_ci1. This sample can only be run on standard-system devices. 466e7c69efSopenharmony_ci 476e7c69efSopenharmony_ci2. This sample demonstrates the stage model, which supports only the SDK of API version 9 (SDK version: 3.2.11.9 Beta2). 486e7c69efSopenharmony_ci 496e7c69efSopenharmony_ci3. DevEco Studio 3.1 Canary1 (Build Version: 3.1.0.400)must be used. 50