1/* 2 * Copyright (c) 2021-2024 Huawei Device Co., Ltd. 3 * Licensed under the Apache License, Version 2.0 (the "License"); 4 * you may not use this file except in compliance with the License. 5 * You may obtain a copy of the License at 6 * 7 * http://www.apache.org/licenses/LICENSE-2.0 8 * 9 * Unless required by applicable law or agreed to in writing, software 10 * distributed under the License is distributed on an "AS IS" BASIS, 11 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 * See the License for the specific language governing permissions and 13 * limitations under the License. 14 */ 15 16/** 17 * @file 18 * @kit ArkUI 19 */ 20 21/** 22 * Import the SystemBarStyle type for Navigation. 23 * 24 * @typedef { import('../api/@ohos.window').default.SystemBarStyle } SystemBarStyle 25 * @syscap SystemCapability.ArkUI.ArkUI.Full 26 * @atomicservice 27 * @since 12 28 */ 29declare type SystemBarStyle = import('../api/@ohos.window').default.SystemBarStyle; 30 31/** 32 * Defines the navigation common title. 33 * 34 * @interface NavigationCommonTitle 35 * @syscap SystemCapability.ArkUI.ArkUI.Full 36 * @since 9 37 */ 38/** 39 * Defines the navigation common title. 40 * 41 * @interface NavigationCommonTitle 42 * @syscap SystemCapability.ArkUI.ArkUI.Full 43 * @crossplatform 44 * @since 10 45 */ 46/** 47 * Defines the navigation common title. 48 * 49 * @interface NavigationCommonTitle 50 * @syscap SystemCapability.ArkUI.ArkUI.Full 51 * @crossplatform 52 * @atomicservice 53 * @since 11 54 */ 55declare interface NavigationCommonTitle { 56 /** 57 * Sets the main title. 58 * 59 * @type { string } 60 * @syscap SystemCapability.ArkUI.ArkUI.Full 61 * @since 9 62 */ 63 /** 64 * Sets the main title. 65 * 66 * @type { string } 67 * @syscap SystemCapability.ArkUI.ArkUI.Full 68 * @crossplatform 69 * @since 10 70 */ 71 /** 72 * Sets the main title. 73 * 74 * @type { string } 75 * @syscap SystemCapability.ArkUI.ArkUI.Full 76 * @crossplatform 77 * @atomicservice 78 * @since 11 79 */ 80 /** 81 * Sets the main title. 82 * 83 * @type { string | Resource } 84 * @syscap SystemCapability.ArkUI.ArkUI.Full 85 * @crossplatform 86 * @atomicservice 87 * @since 14 88 */ 89 main: string | Resource; 90 91 /** 92 * Sets the sub title. 93 * 94 * @type { string } 95 * @syscap SystemCapability.ArkUI.ArkUI.Full 96 * @since 9 97 */ 98 /** 99 * Sets the sub title. 100 * 101 * @type { string } 102 * @syscap SystemCapability.ArkUI.ArkUI.Full 103 * @crossplatform 104 * @since 10 105 */ 106 /** 107 * Sets the sub title. 108 * 109 * @type { string } 110 * @syscap SystemCapability.ArkUI.ArkUI.Full 111 * @crossplatform 112 * @atomicservice 113 * @since 11 114 */ 115 /** 116 * Sets the sub title. 117 * 118 * @type { string | Resource } 119 * @syscap SystemCapability.ArkUI.ArkUI.Full 120 * @crossplatform 121 * @atomicservice 122 * @since 14 123 */ 124 sub: string | Resource; 125} 126 127/** 128 * Defines the navigation custom title. 129 * 130 * @interface NavigationCustomTitle 131 * @syscap SystemCapability.ArkUI.ArkUI.Full 132 * @since 9 133 */ 134/** 135 * Defines the navigation custom title. 136 * 137 * @interface NavigationCustomTitle 138 * @syscap SystemCapability.ArkUI.ArkUI.Full 139 * @crossplatform 140 * @since 10 141 */ 142/** 143 * Defines the navigation custom title. 144 * 145 * @interface NavigationCustomTitle 146 * @syscap SystemCapability.ArkUI.ArkUI.Full 147 * @crossplatform 148 * @atomicservice 149 * @since 11 150 */ 151declare interface NavigationCustomTitle { 152 /** 153 * Sets the custom title builder. 154 * 155 * @type { CustomBuilder } 156 * @syscap SystemCapability.ArkUI.ArkUI.Full 157 * @since 9 158 */ 159 /** 160 * Sets the custom title builder. 161 * 162 * @type { CustomBuilder } 163 * @syscap SystemCapability.ArkUI.ArkUI.Full 164 * @crossplatform 165 * @since 10 166 */ 167 /** 168 * Sets the custom title builder. 169 * 170 * @type { CustomBuilder } 171 * @syscap SystemCapability.ArkUI.ArkUI.Full 172 * @crossplatform 173 * @atomicservice 174 * @since 11 175 */ 176 builder: CustomBuilder; 177 178 /** 179 * Sets the custom title height. 180 * 181 * @type { TitleHeight | Length } 182 * @syscap SystemCapability.ArkUI.ArkUI.Full 183 * @since 9 184 */ 185 /** 186 * Sets the custom title height. 187 * 188 * @type { TitleHeight | Length } 189 * @syscap SystemCapability.ArkUI.ArkUI.Full 190 * @crossplatform 191 * @since 10 192 */ 193 /** 194 * Sets the custom title height. 195 * 196 * @type { TitleHeight | Length } 197 * @syscap SystemCapability.ArkUI.ArkUI.Full 198 * @crossplatform 199 * @atomicservice 200 * @since 11 201 */ 202 height: TitleHeight | Length; 203} 204 205 206/** 207 * Navigation mode 208 * 209 * @enum { number } 210 * @syscap SystemCapability.ArkUI.ArkUI.Full 211 * @since 9 212 */ 213/** 214 * Navigation mode 215 * 216 * @enum { number } 217 * @syscap SystemCapability.ArkUI.ArkUI.Full 218 * @crossplatform 219 * @since 10 220 */ 221/** 222 * Navigation mode 223 * 224 * @enum { number } 225 * @syscap SystemCapability.ArkUI.ArkUI.Full 226 * @crossplatform 227 * @atomicservice 228 * @since 11 229 */ 230declare enum NavigationMode { 231 /** 232 * The navigation bar and the content area are displayed in stack. 233 * 234 * @syscap SystemCapability.ArkUI.ArkUI.Full 235 * @since 9 236 */ 237 /** 238 * The navigation bar and the content area are displayed in stack. 239 * 240 * @syscap SystemCapability.ArkUI.ArkUI.Full 241 * @crossplatform 242 * @since 10 243 */ 244 /** 245 * The navigation bar and the content area are displayed in stack. 246 * 247 * @syscap SystemCapability.ArkUI.ArkUI.Full 248 * @crossplatform 249 * @atomicservice 250 * @since 11 251 */ 252 Stack, 253 254 /** 255 * The navigation bar and the content area are displayed side by side. 256 * 257 * @syscap SystemCapability.ArkUI.ArkUI.Full 258 * @since 9 259 */ 260 /** 261 * The navigation bar and the content area are displayed side by side. 262 * 263 * @syscap SystemCapability.ArkUI.ArkUI.Full 264 * @crossplatform 265 * @since 10 266 */ 267 /** 268 * The navigation bar and the content area are displayed side by side. 269 * 270 * @syscap SystemCapability.ArkUI.ArkUI.Full 271 * @crossplatform 272 * @atomicservice 273 * @since 11 274 */ 275 Split, 276 277 /** 278 * If the window width is greater than 520vp, the navigation component is displayed in split mode. 279 * Otherwise it's displayed in stack mode. 280 * 281 * @syscap SystemCapability.ArkUI.ArkUI.Full 282 * @since 9 283 */ 284 /** 285 * If the window width is greater than the sum of minNavBarWidth and minContentWidth, the navigation component is displayed in split mode. 286 * Otherwise it's displayed in stack mode. 287 * 288 * @syscap SystemCapability.ArkUI.ArkUI.Full 289 * @crossplatform 290 * @since 10 291 */ 292 /** 293 * If the window width is greater than the sum of minNavBarWidth and minContentWidth, the navigation component is displayed in split mode. 294 * Otherwise it's displayed in stack mode. 295 * 296 * @syscap SystemCapability.ArkUI.ArkUI.Full 297 * @crossplatform 298 * @atomicservice 299 * @since 11 300 */ 301 Auto, 302} 303 304/** 305 * Navigation bar position 306 * 307 * @enum { number } 308 * @syscap SystemCapability.ArkUI.ArkUI.Full 309 * @since 9 310 */ 311/** 312 * Navigation bar position 313 * 314 * @enum { number } 315 * @syscap SystemCapability.ArkUI.ArkUI.Full 316 * @crossplatform 317 * @since 10 318 */ 319/** 320 * Navigation bar position 321 * 322 * @enum { number } 323 * @syscap SystemCapability.ArkUI.ArkUI.Full 324 * @crossplatform 325 * @atomicservice 326 * @since 11 327 */ 328declare enum NavBarPosition { 329 /** 330 * The navigation bar is on the Start of the container 331 * 332 * @syscap SystemCapability.ArkUI.ArkUI.Full 333 * @since 9 334 */ 335 /** 336 * The navigation bar is on the Start of the container 337 * 338 * @syscap SystemCapability.ArkUI.ArkUI.Full 339 * @crossplatform 340 * @since 10 341 */ 342 /** 343 * The navigation bar is on the Start of the container 344 * 345 * @syscap SystemCapability.ArkUI.ArkUI.Full 346 * @crossplatform 347 * @atomicservice 348 * @since 11 349 */ 350 Start, 351 352 /** 353 * The navigation bar is on the End of the container 354 * 355 * @syscap SystemCapability.ArkUI.ArkUI.Full 356 * @since 9 357 */ 358 /** 359 * The navigation bar is on the End of the container 360 * 361 * @syscap SystemCapability.ArkUI.ArkUI.Full 362 * @crossplatform 363 * @since 10 364 */ 365 /** 366 * The navigation bar is on the End of the container 367 * 368 * @syscap SystemCapability.ArkUI.ArkUI.Full 369 * @crossplatform 370 * @atomicservice 371 * @since 11 372 */ 373 End, 374} 375 376/** 377 * Navigation title mode. 378 * 379 * @enum { number } 380 * @syscap SystemCapability.ArkUI.ArkUI.Full 381 * @since 8 382 */ 383/** 384 * Navigation title mode. 385 * 386 * @enum { number } 387 * @syscap SystemCapability.ArkUI.ArkUI.Full 388 * @crossplatform 389 * @since 10 390 */ 391/** 392 * Navigation title mode. 393 * 394 * @enum { number } 395 * @syscap SystemCapability.ArkUI.ArkUI.Full 396 * @crossplatform 397 * @atomicservice 398 * @since 11 399 */ 400declare enum NavigationTitleMode { 401 /** 402 * The title is free mode. 403 * 404 * @syscap SystemCapability.ArkUI.ArkUI.Full 405 * @since 8 406 */ 407 /** 408 * The title is free mode. 409 * 410 * @syscap SystemCapability.ArkUI.ArkUI.Full 411 * @crossplatform 412 * @since 10 413 */ 414 /** 415 * The title is free mode. 416 * 417 * @syscap SystemCapability.ArkUI.ArkUI.Full 418 * @crossplatform 419 * @atomicservice 420 * @since 11 421 */ 422 Free = 0, 423 424 /** 425 * The title is full mode. 426 * 427 * @syscap SystemCapability.ArkUI.ArkUI.Full 428 * @since 8 429 */ 430 /** 431 * The title is full mode. 432 * 433 * @syscap SystemCapability.ArkUI.ArkUI.Full 434 * @crossplatform 435 * @since 10 436 */ 437 /** 438 * The title is full mode. 439 * 440 * @syscap SystemCapability.ArkUI.ArkUI.Full 441 * @crossplatform 442 * @atomicservice 443 * @since 11 444 */ 445 Full, 446 447 /** 448 * The title is mini mode. 449 * 450 * @syscap SystemCapability.ArkUI.ArkUI.Full 451 * @since 8 452 */ 453 /** 454 * The title is mini mode. 455 * 456 * @syscap SystemCapability.ArkUI.ArkUI.Full 457 * @crossplatform 458 * @since 10 459 */ 460 /** 461 * The title is mini mode. 462 * 463 * @syscap SystemCapability.ArkUI.ArkUI.Full 464 * @crossplatform 465 * @atomicservice 466 * @since 11 467 */ 468 Mini, 469} 470 471/** 472 * Navigation menu item, include menu icon and menu info 473 * 474 * @interface NavigationMenuItem 475 * @syscap SystemCapability.ArkUI.ArkUI.Full 476 * @since 8 477 */ 478/** 479 * Navigation menu item, include menu icon and menu info 480 * 481 * @interface NavigationMenuItem 482 * @syscap SystemCapability.ArkUI.ArkUI.Full 483 * @crossplatform 484 * @since 10 485 */ 486/** 487 * Navigation menu item, include menu icon and menu info 488 * 489 * @interface NavigationMenuItem 490 * @syscap SystemCapability.ArkUI.ArkUI.Full 491 * @crossplatform 492 * @atomicservice 493 * @since 11 494 */ 495declare interface NavigationMenuItem { 496 /** 497 * The value of navigation menu item. 498 * 499 * @type { string } 500 * @syscap SystemCapability.ArkUI.ArkUI.Full 501 * @since 8 502 */ 503 /** 504 * The value of navigation menu item. 505 * 506 * @type { string } 507 * @syscap SystemCapability.ArkUI.ArkUI.Full 508 * @crossplatform 509 * @since 10 510 */ 511 /** 512 * The value of navigation menu item. 513 * 514 * @type { string } 515 * @syscap SystemCapability.ArkUI.ArkUI.Full 516 * @crossplatform 517 * @atomicservice 518 * @since 11 519 */ 520 /** 521 * The value of navigation menu item. 522 * 523 * @type { string | Resource } 524 * @syscap SystemCapability.ArkUI.ArkUI.Full 525 * @crossplatform 526 * @atomicservice 527 * @since 14 528 */ 529 value: string | Resource; 530 531 /** 532 * The icon of navigation menu item. 533 * 534 * @type { ?string } 535 * @syscap SystemCapability.ArkUI.ArkUI.Full 536 * @since 8 537 */ 538 /** 539 * The icon of navigation menu item. 540 * 541 * @type { ?string } 542 * @syscap SystemCapability.ArkUI.ArkUI.Full 543 * @crossplatform 544 * @since 10 545 */ 546 /** 547 * The icon of navigation menu item. 548 * 549 * @type { ?string } 550 * @syscap SystemCapability.ArkUI.ArkUI.Full 551 * @crossplatform 552 * @atomicservice 553 * @since 11 554 */ 555 /** 556 * The value of navigation menu item. 557 * 558 * @type { ?(string | Resource) } 559 * @syscap SystemCapability.ArkUI.ArkUI.Full 560 * @crossplatform 561 * @atomicservice 562 * @since 14 563 */ 564 icon?: string | Resource; 565 566 /** 567 * The symbol of navigation menu item. 568 * 569 * @type { ?SymbolGlyphModifier } 570 * @syscap SystemCapability.ArkUI.ArkUI.Full 571 * @atomicservice 572 * @since 12 573 */ 574 symbolIcon?: SymbolGlyphModifier; 575 576 /** 577 * Whether to enable this menu item. 578 * 579 * @type { ?boolean } 580 * @syscap SystemCapability.ArkUI.ArkUI.Full 581 * @crossplatform 582 * @atomicservice 583 * @since 12 584 */ 585 isEnabled?: boolean; 586 587 /** 588 * Trigger by navigation menu item click. 589 * 590 * @type { ?(() => void) } 591 * @syscap SystemCapability.ArkUI.ArkUI.Full 592 * @since 8 593 */ 594 /** 595 * Trigger by navigation menu item click. 596 * 597 * @type { ?function } 598 * @syscap SystemCapability.ArkUI.ArkUI.Full 599 * @crossplatform 600 * @since 10 601 */ 602 /** 603 * Trigger by navigation menu item click. 604 * 605 * @type { ?function } 606 * @syscap SystemCapability.ArkUI.ArkUI.Full 607 * @crossplatform 608 * @atomicservice 609 * @since 11 610 */ 611 action?: () => void; 612} 613 614/** 615 * Indicates the information of the popped page. 616 * 617 * @interface PopInfo 618 * @syscap SystemCapability.ArkUI.ArkUI.Full 619 * @crossplatform 620 * @since 11 621 */ 622/** 623 * Indicates the information of the popped page. 624 * 625 * @interface PopInfo 626 * @syscap SystemCapability.ArkUI.ArkUI.Full 627 * @crossplatform 628 * @atomicservice 629 * @since 12 630 */ 631declare interface PopInfo { 632 /** 633 * The info of the popped page. 634 * 635 * @type { NavPathInfo } 636 * @syscap SystemCapability.ArkUI.ArkUI.Full 637 * @crossplatform 638 * @since 11 639 */ 640 /** 641 * The info of the popped page. 642 * 643 * @type { NavPathInfo } 644 * @syscap SystemCapability.ArkUI.ArkUI.Full 645 * @crossplatform 646 * @atomicservice 647 * @since 12 648 */ 649 info: NavPathInfo; 650 651 /** 652 * The result of the popped page. 653 * 654 * @type { Object } 655 * @syscap SystemCapability.ArkUI.ArkUI.Full 656 * @crossplatform 657 * @since 11 658 */ 659 /** 660 * The result of the popped page. 661 * 662 * @type { Object } 663 * @syscap SystemCapability.ArkUI.ArkUI.Full 664 * @crossplatform 665 * @atomicservice 666 * @since 12 667 */ 668 result: Object; 669} 670 671/** 672 * Indicates the information of NavDestination. 673 * 674 * @syscap SystemCapability.ArkUI.ArkUI.Full 675 * @crossplatform 676 * @since 10 677 */ 678/** 679 * Indicates the information of NavDestination. 680 * 681 * @syscap SystemCapability.ArkUI.ArkUI.Full 682 * @crossplatform 683 * @atomicservice 684 * @since 11 685 */ 686declare class NavPathInfo { 687 /** 688 * Creates an instance of NavPathInfo. 689 * 690 * @param { string } name - The name of NavDestination. 691 * @param { unknown } param - The detailed parameter of the NavDestination. 692 * @syscap SystemCapability.ArkUI.ArkUI.Full 693 * @crossplatform 694 * @since 10 695 */ 696 /** 697 * Creates an instance of NavPathInfo. 698 * 699 * @param { string } name - The name of NavDestination. 700 * @param { unknown } param - The detailed parameter of the NavDestination. 701 * @param { ?import('../api/@ohos.base').Callback<PopInfo> } onPop - The callback when next page returns. 702 * @syscap SystemCapability.ArkUI.ArkUI.Full 703 * @crossplatform 704 * @atomicservice 705 * @since 11 706 */ 707 /** 708 * Creates an instance of NavPathInfo. 709 * 710 * @param { string } name - The name of NavDestination. 711 * @param { unknown } param - The detailed parameter of the NavDestination. 712 * @param { ?import('../api/@ohos.base').Callback<PopInfo> } onPop - The callback when next page returns. 713 * @param { ?boolean } isEntry - Indicates whether it is an entry destination. 714 * @syscap SystemCapability.ArkUI.ArkUI.Full 715 * @crossplatform 716 * @atomicservice 717 * @since 12 718 */ 719 constructor(name: string, param: unknown, onPop?: import('../api/@ohos.base').Callback<PopInfo>, isEntry?: boolean); 720 721 /** 722 * The name of NavDestination. 723 * 724 * @type { string } 725 * @syscap SystemCapability.ArkUI.ArkUI.Full 726 * @crossplatform 727 * @since 10 728 */ 729 /** 730 * The name of NavDestination. 731 * 732 * @type { string } 733 * @syscap SystemCapability.ArkUI.ArkUI.Full 734 * @crossplatform 735 * @atomicservice 736 * @since 11 737 */ 738 name: string; 739 740 /** 741 * The detailed parameter of the NavDestination. 742 * 743 * @type { ?unknown } 744 * @syscap SystemCapability.ArkUI.ArkUI.Full 745 * @crossplatform 746 * @since 10 747 */ 748 /** 749 * The detailed parameter of the NavDestination. 750 * 751 * @type { ?unknown } 752 * @syscap SystemCapability.ArkUI.ArkUI.Full 753 * @crossplatform 754 * @atomicservice 755 * @since 11 756 */ 757 param?: unknown; 758 759 /** 760 * The callback when next page returns. 761 * 762 * @type { ?import('../api/@ohos.base').Callback<PopInfo> } 763 * @syscap SystemCapability.ArkUI.ArkUI.Full 764 * @crossplatform 765 * @since 11 766 */ 767 /** 768 * The callback when next page returns. 769 * 770 * @type { ?import('../api/@ohos.base').Callback<PopInfo> } 771 * @syscap SystemCapability.ArkUI.ArkUI.Full 772 * @crossplatform 773 * @atomicservice 774 * @since 12 775 */ 776 onPop?: import('../api/@ohos.base').Callback<PopInfo>; 777 778 /** 779 * Indicates whether it is an entry destination. 780 * 781 * @type { ?boolean } 782 * @syscap SystemCapability.ArkUI.ArkUI.Full 783 * @crossplatform 784 * @atomicservice 785 * @since 12 786 */ 787 isEntry?: boolean; 788} 789 790/** 791 * Defines the mode of stack operation. 792 * 793 * @enum { number } 794 * @syscap SystemCapability.ArkUI.ArkUI.Full 795 * @crossplatform 796 * @atomicservice 797 * @since 12 798 */ 799declare enum LaunchMode { 800 /** 801 * The default mode of stack operation. 802 * 803 * @syscap SystemCapability.ArkUI.ArkUI.Full 804 * @crossplatform 805 * @atomicservice 806 * @since 12 807 */ 808 STANDARD = 0, 809 810 /** 811 * When the NavDestination with a specified name exists, it will be moved to top of stack, 812 * otherwise, the behavior will be consistent with the STANDARD mode. 813 * 814 * @syscap SystemCapability.ArkUI.ArkUI.Full 815 * @crossplatform 816 * @atomicservice 817 * @since 12 818 */ 819 MOVE_TO_TOP_SINGLETON = 1, 820 821 /** 822 * When the NavDestination with a specified name exists, the stack will pop until that NavDestination, 823 * otherwise, the behavior will be consistent with the STANDARD mode. 824 * 825 * @syscap SystemCapability.ArkUI.ArkUI.Full 826 * @crossplatform 827 * @atomicservice 828 * @since 12 829 */ 830 POP_TO_SINGLETON = 2, 831 832 /** 833 * Forced to create a new NavDestination instance. 834 * 835 * @syscap SystemCapability.ArkUI.ArkUI.Full 836 * @crossplatform 837 * @atomicservice 838 * @since 12 839 */ 840 NEW_INSTANCE = 3, 841} 842 843/** 844 * Indicates the options of stack operation. 845 * 846 * @interface NavigationOptions 847 * @syscap SystemCapability.ArkUI.ArkUI.Full 848 * @crossplatform 849 * @atomicservice 850 * @since 12 851 */ 852declare interface NavigationOptions { 853 /** 854 * Indicates the launchMode of stack operation. 855 * 856 * @type { ?LaunchMode } 857 * @syscap SystemCapability.ArkUI.ArkUI.Full 858 * @crossplatform 859 * @atomicservice 860 * @since 12 861 */ 862 launchMode?: LaunchMode; 863 864 /** 865 * Indicates whether the transition is animated. 866 * 867 * @type { ?boolean } 868 * @syscap SystemCapability.ArkUI.ArkUI.Full 869 * @crossplatform 870 * @atomicservice 871 * @since 12 872 */ 873 animated?: boolean; 874} 875 876/** 877 * Indicates the information of NavDestinations. Providers methods for controlling destination page in the stack 878 * 879 * @syscap SystemCapability.ArkUI.ArkUI.Full 880 * @crossplatform 881 * @since 10 882 */ 883/** 884 * Indicates the information of NavDestinations. Providers methods for controlling destination page in the stack 885 * 886 * @syscap SystemCapability.ArkUI.ArkUI.Full 887 * @crossplatform 888 * @atomicservice 889 * @since 11 890 */ 891declare class NavPathStack { 892 /** 893 * Creates an instance of NavPathStack. 894 * 895 * @syscap SystemCapability.ArkUI.ArkUI.Full 896 * @crossplatform 897 * @since 10 898 */ 899 /** 900 * Creates an instance of NavPathStack. 901 * 902 * @syscap SystemCapability.ArkUI.ArkUI.Full 903 * @crossplatform 904 * @atomicservice 905 * @since 11 906 */ 907 constructor(); 908 909 /** 910 * Pushes the NavDestination into the stack. 911 * 912 * @param { NavPathInfo } info - Indicates the NavDestination to be pushed. 913 * @syscap SystemCapability.ArkUI.ArkUI.Full 914 * @crossplatform 915 * @since 10 916 */ 917 /** 918 * Pushes the NavDestination into the stack. 919 * 920 * @param { NavPathInfo } info - Indicates the NavDestination to be pushed. 921 * @param { boolean } [animated] - Indicates whether the transition is animated. 922 * @syscap SystemCapability.ArkUI.ArkUI.Full 923 * @crossplatform 924 * @atomicservice 925 * @since 11 926 */ 927 pushPath(info: NavPathInfo, animated?: boolean): void; 928 929 /** 930 * Pushes the NavDestination into the stack. 931 * 932 * @param { NavPathInfo } info - Indicates the NavDestination to be pushed. 933 * @param { NavigationOptions } [options] - Indicates options of stack operation. 934 * @syscap SystemCapability.ArkUI.ArkUI.Full 935 * @crossplatform 936 * @atomicservice 937 * @since 12 938 */ 939 pushPath(info: NavPathInfo, options?: NavigationOptions): void; 940 941 /** 942 * Pushes the NavDestination into the stack. 943 * 944 * @param { NavPathInfo } info - Indicates the NavDestination to be pushed. 945 * @param { boolean } [animated] - Indicates whether the transition is animated. 946 * @returns { Promise<void> } The promise returned by the function. 947 * @throws { BusinessError } 401 - Parameter error. Possible causes: 948 * 1. Mandatory parameters are left unspecified. 949 * 2. Incorrect parameters types. 950 * 3. Parameter verification failed. 951 * @throws { BusinessError } 100001 - Internal error. 952 * @throws { BusinessError } 100005 - Builder function not registered. 953 * @throws { BusinessError } 100006 - NavDestination not found. 954 * @syscap SystemCapability.ArkUI.ArkUI.Full 955 * @crossplatform 956 * @since 11 957 */ 958 /** 959 * Pushes the NavDestination into the stack. 960 * 961 * @param { NavPathInfo } info - Indicates the NavDestination to be pushed. 962 * @param { boolean } [animated] - Indicates whether the transition is animated. 963 * @returns { Promise<void> } The promise returned by the function. 964 * @throws { BusinessError } 401 - Parameter error. Possible causes: 965 * 1. Mandatory parameters are left unspecified. 966 * 2. Incorrect parameters types. 967 * 3. Parameter verification failed. 968 * @throws { BusinessError } 100001 - Internal error. 969 * @throws { BusinessError } 100005 - Builder function not registered. 970 * @throws { BusinessError } 100006 - NavDestination not found. 971 * @syscap SystemCapability.ArkUI.ArkUI.Full 972 * @crossplatform 973 * @atomicservice 974 * @since 12 975 */ 976 pushDestination(info: NavPathInfo, animated?: boolean): Promise<void>; 977 978 /** 979 * Pushes the NavDestination into the stack. 980 * 981 * @param { NavPathInfo } info - Indicates the NavDestination to be pushed. 982 * @param { NavigationOptions } [options] - Indicates options of stack operation. 983 * @returns { Promise<void> } The promise returned by the function. 984 * @throws { BusinessError } 401 - Parameter error. Possible causes: 985 * 1. Mandatory parameters are left unspecified. 986 * 2. Incorrect parameters types. 987 * 3. Parameter verification failed. 988 * @throws { BusinessError } 100001 - Internal error. 989 * @throws { BusinessError } 100005 - Builder function not registered. 990 * @throws { BusinessError } 100006 - NavDestination not found. 991 * @syscap SystemCapability.ArkUI.ArkUI.Full 992 * @crossplatform 993 * @atomicservice 994 * @since 12 995 */ 996 pushDestination(info: NavPathInfo, options?: NavigationOptions): Promise<void>; 997 998 /** 999 * Pushes the specified NavDestination into the stack. 1000 * 1001 * @param { string } name - Indicates the name of the NavDestination to be pushed. 1002 * @param { unknown } param - Indicates the detailed parameter of the NavDestination to be pushed. 1003 * @syscap SystemCapability.ArkUI.ArkUI.Full 1004 * @crossplatform 1005 * @since 10 1006 */ 1007 /** 1008 * Pushes the specified NavDestination into the stack. 1009 * 1010 * @param { string } name - Indicates the name of the NavDestination to be pushed. 1011 * @param { unknown } param - Indicates the detailed parameter of the NavDestination to be pushed. 1012 * @param { boolean } [animated] - Indicates whether the transition is animated. 1013 * @syscap SystemCapability.ArkUI.ArkUI.Full 1014 * @crossplatform 1015 * @atomicservice 1016 * @since 11 1017 */ 1018 pushPathByName(name: string, param: unknown, animated?: boolean): void; 1019 1020 /** 1021 * Pushes the specified NavDestination into the stack. 1022 * 1023 * @param { string } name - Indicates the name of the NavDestination to be pushed. 1024 * @param { Object } param - Indicates the detailed parameter of the NavDestination to be pushed. 1025 * @param { import('../api/@ohos.base').Callback<PopInfo> } onPop - The callback when next page returns. 1026 * @param { boolean } [animated] - Indicates whether the transition is animated. 1027 * @syscap SystemCapability.ArkUI.ArkUI.Full 1028 * @crossplatform 1029 * @since 11 1030 */ 1031 /** 1032 * Pushes the specified NavDestination into the stack. 1033 * 1034 * @param { string } name - Indicates the name of the NavDestination to be pushed. 1035 * @param { Object } param - Indicates the detailed parameter of the NavDestination to be pushed. 1036 * @param { import('../api/@ohos.base').Callback<PopInfo> } onPop - The callback when next page returns. 1037 * @param { boolean } [animated] - Indicates whether the transition is animated. 1038 * @syscap SystemCapability.ArkUI.ArkUI.Full 1039 * @crossplatform 1040 * @atomicservice 1041 * @since 12 1042 */ 1043 pushPathByName(name: string, param: Object, onPop: import('../api/@ohos.base').Callback<PopInfo>, animated?: boolean): void; 1044 1045 /** 1046 * Pushes the specified NavDestination into the stack. 1047 * 1048 * @param { string } name - Indicates the name of the NavDestination to be pushed. 1049 * @param { Object } param - Indicates the detailed parameter of the NavDestination to be pushed. 1050 * @param { boolean } [animated] - Indicates whether the transition is animated. 1051 * @returns { Promise<void> } The promise returned by the function. 1052 * @throws { BusinessError } 401 - Parameter error. Possible causes: 1053 * 1. Mandatory parameters are left unspecified. 1054 * 2. Incorrect parameters types. 1055 * 3. Parameter verification failed. 1056 * @throws { BusinessError } 100001 - Internal error. 1057 * @throws { BusinessError } 100005 - Builder function not registered. 1058 * @throws { BusinessError } 100006 - NavDestination not found. 1059 * @syscap SystemCapability.ArkUI.ArkUI.Full 1060 * @crossplatform 1061 * @since 11 1062 */ 1063 /** 1064 * Pushes the specified NavDestination into the stack. 1065 * 1066 * @param { string } name - Indicates the name of the NavDestination to be pushed. 1067 * @param { Object } param - Indicates the detailed parameter of the NavDestination to be pushed. 1068 * @param { boolean } [animated] - Indicates whether the transition is animated. 1069 * @returns { Promise<void> } The promise returned by the function. 1070 * @throws { BusinessError } 401 - Parameter error. Possible causes: 1071 * 1. Mandatory parameters are left unspecified. 1072 * 2. Incorrect parameters types. 1073 * 3. Parameter verification failed. 1074 * @throws { BusinessError } 100001 - Internal error. 1075 * @throws { BusinessError } 100005 - Builder function not registered. 1076 * @throws { BusinessError } 100006 - NavDestination not found. 1077 * @syscap SystemCapability.ArkUI.ArkUI.Full 1078 * @crossplatform 1079 * @atomicservice 1080 * @since 12 1081 */ 1082 pushDestinationByName(name: string, param: Object, animated?: boolean): Promise<void>; 1083 1084 /** 1085 * Pushes the specified NavDestination into the stack. 1086 * 1087 * @param { string } name - Indicates the name of the NavDestination to be pushed. 1088 * @param { Object } param - Indicates the detailed parameter of the NavDestination to be pushed. 1089 * @param { import('../api/@ohos.base').Callback<PopInfo> } onPop - The callback when next page returns. 1090 * @param { boolean } [animated] - Indicates whether the transition is animated. 1091 * @returns { Promise<void> } The promise returned by the function. 1092 * @throws { BusinessError } 401 - Parameter error. Possible causes: 1093 * 1. Mandatory parameters are left unspecified. 1094 * 2. Incorrect parameters types. 1095 * 3. Parameter verification failed. 1096 * @throws { BusinessError } 100001 - Internal error. 1097 * @throws { BusinessError } 100005 - Builder function not registered. 1098 * @throws { BusinessError } 100006 - NavDestination not found. 1099 * @syscap SystemCapability.ArkUI.ArkUI.Full 1100 * @crossplatform 1101 * @since 11 1102 */ 1103 /** 1104 * Pushes the specified NavDestination into the stack. 1105 * 1106 * @param { string } name - Indicates the name of the NavDestination to be pushed. 1107 * @param { Object } param - Indicates the detailed parameter of the NavDestination to be pushed. 1108 * @param { import('../api/@ohos.base').Callback<PopInfo> } onPop - The callback when next page returns. 1109 * @param { boolean } [animated] - Indicates whether the transition is animated. 1110 * @returns { Promise<void> } The promise returned by the function. 1111 * @throws { BusinessError } 401 - Parameter error. Possible causes: 1112 * 1. Mandatory parameters are left unspecified. 1113 * 2. Incorrect parameters types. 1114 * 3. Parameter verification failed. 1115 * @throws { BusinessError } 100001 - Internal error. 1116 * @throws { BusinessError } 100005 - Builder function not registered. 1117 * @throws { BusinessError } 100006 - NavDestination not found. 1118 * @syscap SystemCapability.ArkUI.ArkUI.Full 1119 * @crossplatform 1120 * @atomicservice 1121 * @since 12 1122 */ 1123 pushDestinationByName(name: string, param: Object, onPop: import('../api/@ohos.base').Callback<PopInfo>, animated?: boolean): Promise<void>; 1124 1125 /** 1126 * Replace the current NavDestination with the specific one.The current NavDestination will be destroyed. 1127 * 1128 * @param { NavPathInfo } info - Indicates the new NavDestination in top of the stack. 1129 * @param { boolean } [animated] - Indicates whether the transition is animated. 1130 * @syscap SystemCapability.ArkUI.ArkUI.Full 1131 * @crossplatform 1132 * @since 11 1133 */ 1134 /** 1135 * Replace the current NavDestination with the specific one.The current NavDestination will be destroyed. 1136 * 1137 * @param { NavPathInfo } info - Indicates the new NavDestination in top of the stack. 1138 * @param { boolean } [animated] - Indicates whether the transition is animated. 1139 * @syscap SystemCapability.ArkUI.ArkUI.Full 1140 * @crossplatform 1141 * @atomicservice 1142 * @since 12 1143 */ 1144 replacePath(info: NavPathInfo, animated?: boolean): void; 1145 1146 /** 1147 * Replace the current NavDestination with the specific one.The current NavDestination will be destroyed. 1148 * 1149 * @param { NavPathInfo } info - Indicates the new NavDestination in top of the stack. 1150 * @param { NavigationOptions } [options] - Indicates options of stack operation. 1151 * @syscap SystemCapability.ArkUI.ArkUI.Full 1152 * @crossplatform 1153 * @atomicservice 1154 * @since 12 1155 */ 1156 replacePath(info: NavPathInfo, options?: NavigationOptions): void; 1157 1158 /** 1159 * Replace the NavDestination into the stack. 1160 * 1161 * @param { NavPathInfo } info - Indicates the NavDestination to replace in stack. 1162 * @param { NavigationOptions } [options] - Indicates options of stack operation. 1163 * @returns { Promise<void> } The promise returned by the function. 1164 * @throws { BusinessError } 401 - Parameter error. Possible causes: 1165 * 1. Mandatory parameters are left unspecified. 1166 * 2. Incorrect parameters types. 1167 * 3. Parameter verification failed. 1168 * @throws { BusinessError } 100001 - Internal error. 1169 * @throws { BusinessError } 100005 - Builder function not registered. 1170 * @throws { BusinessError } 100006 - NavDestination not found. 1171 * @syscap SystemCapability.ArkUI.ArkUI.Full 1172 * @crossplatform 1173 * @atomicservice 1174 * @since 18 1175 */ 1176 replaceDestination(info: NavPathInfo, options?: NavigationOptions): Promise<void>; 1177 1178 /** 1179 * Replace the current NavDestination with the specific one.The current NavDestination will be destroyed. 1180 * 1181 * @param { string } name - Indicates name of the new NavDestination in top of stack. 1182 * @param { Object } param - Indicates the detailed parameter of the new NavDestination in top of the stack. 1183 * @param { boolean } [animated] - Indicates whether the transition is animated. 1184 * @syscap SystemCapability.ArkUI.ArkUI.Full 1185 * @crossplatform 1186 * @since 11 1187 */ 1188 /** 1189 * Replace the current NavDestination with the specific one.The current NavDestination will be destroyed. 1190 * 1191 * @param { string } name - Indicates name of the new NavDestination in top of stack. 1192 * @param { Object } param - Indicates the detailed parameter of the new NavDestination in top of the stack. 1193 * @param { boolean } [animated] - Indicates whether the transition is animated. 1194 * @syscap SystemCapability.ArkUI.ArkUI.Full 1195 * @crossplatform 1196 * @atomicservice 1197 * @since 12 1198 */ 1199 replacePathByName(name: string, param: Object, animated?: boolean): void; 1200 1201 /** 1202 * Remove the specified NavDestinations by indexes. 1203 * 1204 * @param { Array<number> } indexes - Indicates the indexes of the NavDestinations to be removed. 1205 * @returns { number } Returns the number of removed pages. Invalid indexes will be ignored. 1206 * @syscap SystemCapability.ArkUI.ArkUI.Full 1207 * @crossplatform 1208 * @since 11 1209 */ 1210 /** 1211 * Remove the specified NavDestinations by indexes. 1212 * 1213 * @param { Array<number> } indexes - Indicates the indexes of the NavDestinations to be removed. 1214 * @returns { number } Returns the number of removed pages. Invalid indexes will be ignored. 1215 * @syscap SystemCapability.ArkUI.ArkUI.Full 1216 * @crossplatform 1217 * @atomicservice 1218 * @since 12 1219 */ 1220 removeByIndexes(indexes: Array<number>): number; 1221 1222 /** 1223 * Remove the specified NavDestination by name. 1224 * 1225 * @param { string } name - Indicates the name of the NavDestination to be removed. 1226 * @returns { number } Returns the number of removed NavDestinations. 1227 * @syscap SystemCapability.ArkUI.ArkUI.Full 1228 * @crossplatform 1229 * @since 11 1230 */ 1231 /** 1232 * Remove the specified NavDestination by name. 1233 * 1234 * @param { string } name - Indicates the name of the NavDestination to be removed. 1235 * @returns { number } Returns the number of removed NavDestinations. 1236 * @syscap SystemCapability.ArkUI.ArkUI.Full 1237 * @crossplatform 1238 * @atomicservice 1239 * @since 12 1240 */ 1241 removeByName(name: string): number; 1242 1243 /** 1244 * Remove the specified NavDestination by its navDestinationId. 1245 * 1246 * @param { string } navDestinationId - Indicates the navDestinationId of the NavDestination to be removed. 1247 * @returns { boolean } Returns true if remove successfully, otherwise returns false. 1248 * @syscap SystemCapability.ArkUI.ArkUI.Full 1249 * @crossplatform 1250 * @atomicservice 1251 * @since 12 1252 */ 1253 removeByNavDestinationId(navDestinationId: string): boolean; 1254 1255 /** 1256 * Pops the top NavDestination out of the stack. 1257 * 1258 * @returns { NavPathInfo | undefined } Returns the top NavPathInfo if the stack is not empty, otherwise returns undefined. 1259 * @syscap SystemCapability.ArkUI.ArkUI.Full 1260 * @crossplatform 1261 * @since 10 1262 */ 1263 /** 1264 * Pops the top NavDestination out of the stack. 1265 * 1266 * @param { boolean } [animated] - Indicates whether the transition is animated. 1267 * @returns { NavPathInfo | undefined } Returns the top NavPathInfo if the stack is not empty, otherwise returns undefined. 1268 * @syscap SystemCapability.ArkUI.ArkUI.Full 1269 * @crossplatform 1270 * @atomicservice 1271 * @since 11 1272 */ 1273 pop(animated?: boolean): NavPathInfo | undefined; 1274 1275 /** 1276 * Pops the top NavDestination out of the stack. 1277 * 1278 * @param { Object } result - The result of the NavDestination. 1279 * @param { boolean } [animated] - Indicates whether the transition is animated. 1280 * @returns { NavPathInfo | undefined } Returns the top NavPathInfo if the stack is not empty, otherwise returns undefined. 1281 * @syscap SystemCapability.ArkUI.ArkUI.Full 1282 * @crossplatform 1283 * @since 11 1284 */ 1285 /** 1286 * Pops the top NavDestination out of the stack. 1287 * 1288 * @param { Object } result - The result of the NavDestination. 1289 * @param { boolean } [animated] - Indicates whether the transition is animated. 1290 * @returns { NavPathInfo | undefined } Returns the top NavPathInfo if the stack is not empty, otherwise returns undefined. 1291 * @syscap SystemCapability.ArkUI.ArkUI.Full 1292 * @crossplatform 1293 * @atomicservice 1294 * @since 12 1295 */ 1296 pop(result: Object, animated?: boolean): NavPathInfo | undefined; 1297 1298 /** 1299 * Pops the specified NavDestination out of the stack. 1300 * 1301 * @param { string } name - Indicates the name of the NavDestination to be popped. 1302 * @returns { number } Returns the index of the NavDestination if it exists in the stack, otherwise returns -1; 1303 * @syscap SystemCapability.ArkUI.ArkUI.Full 1304 * @crossplatform 1305 * @since 10 1306 */ 1307 /** 1308 * Pops the specified NavDestination out of the stack. 1309 * 1310 * @param { string } name - Indicates the name of the NavDestination to be popped. 1311 * @param { boolean } [animated] - Indicates whether the transition is animated. 1312 * @returns { number } Returns the index of the NavDestination if it exists in the stack, otherwise returns -1; 1313 * @syscap SystemCapability.ArkUI.ArkUI.Full 1314 * @crossplatform 1315 * @atomicservice 1316 * @since 11 1317 */ 1318 popToName(name: string, animated?: boolean): number; 1319 1320 /** 1321 * Pops the specified NavDestination out of the stack. 1322 * 1323 * @param { string } name - Indicates the name of the NavDestination to be popped. 1324 * @param { Object } result - The result of the NavDestination. 1325 * @param { boolean } [animated] - Indicates whether the transition is animated. 1326 * @returns { number } Returns the index of the NavDestination if it exists in the stack, otherwise returns -1; 1327 * @syscap SystemCapability.ArkUI.ArkUI.Full 1328 * @crossplatform 1329 * @since 11 1330 */ 1331 /** 1332 * Pops the specified NavDestination out of the stack. 1333 * 1334 * @param { string } name - Indicates the name of the NavDestination to be popped. 1335 * @param { Object } result - The result of the NavDestination. 1336 * @param { boolean } [animated] - Indicates whether the transition is animated. 1337 * @returns { number } Returns the index of the NavDestination if it exists in the stack, otherwise returns -1; 1338 * @syscap SystemCapability.ArkUI.ArkUI.Full 1339 * @crossplatform 1340 * @atomicservice 1341 * @since 12 1342 */ 1343 popToName(name: string, result: Object, animated?: boolean): number; 1344 1345 /** 1346 * Pops the specified NavDestination out of the stack. 1347 * 1348 * @param { number } index - Indicates the index of the NavDestination to be popped. 1349 * @syscap SystemCapability.ArkUI.ArkUI.Full 1350 * @crossplatform 1351 * @since 10 1352 */ 1353 /** 1354 * Pops the specified NavDestination out of the stack. 1355 * 1356 * @param { number } index - Indicates the index of the NavDestination to be popped. 1357 * @param { boolean } [animated] - Indicates whether the transition is animated. 1358 * @syscap SystemCapability.ArkUI.ArkUI.Full 1359 * @crossplatform 1360 * @atomicservice 1361 * @since 11 1362 */ 1363 popToIndex(index: number, animated?: boolean): void; 1364 1365 /** 1366 * Pops the specified NavDestination out of the stack. 1367 * 1368 * @param { number } index - Indicates the index of the NavDestination to be popped. 1369 * @param { Object } result - The result of the NavDestination. 1370 * @param { boolean } [animated] - Indicates whether the transition is animated. 1371 * @syscap SystemCapability.ArkUI.ArkUI.Full 1372 * @crossplatform 1373 * @atomicservice 1374 * @since 11 1375 */ 1376 popToIndex(index: number, result: Object, animated?: boolean): void; 1377 1378 /** 1379 * Moves the specified NavDestination to stack top. 1380 * 1381 * @param { string } name - Indicates the name of the NavDestination to be moved to the top. 1382 * @returns { number } Returns the index of the NavDestination if it exists in the stack, otherwise returns -1; 1383 * @syscap SystemCapability.ArkUI.ArkUI.Full 1384 * @crossplatform 1385 * @since 10 1386 */ 1387 /** 1388 * Moves the specified NavDestination to stack top. 1389 * 1390 * @param { string } name - Indicates the name of the NavDestination to be moved to the top. 1391 * @param { boolean } [animated] - Indicates whether the transition is animated. 1392 * @returns { number } Returns the index of the NavDestination if it exists in the stack, otherwise returns -1; 1393 * @syscap SystemCapability.ArkUI.ArkUI.Full 1394 * @crossplatform 1395 * @atomicservice 1396 * @since 11 1397 */ 1398 moveToTop(name: string, animated?: boolean): number; 1399 1400 /** 1401 * Moves the specified NavDestination to stack top. 1402 * 1403 * @param { number } index - Indicates the index of the NavDestination to be moved to the top. 1404 * @syscap SystemCapability.ArkUI.ArkUI.Full 1405 * @crossplatform 1406 * @since 10 1407 */ 1408 /** 1409 * Moves the specified NavDestination to stack top. 1410 * 1411 * @param { number } index - Indicates the index of the NavDestination to be moved to the top. 1412 * @param { boolean } [animated] - Indicates whether the transition is animated. 1413 * @syscap SystemCapability.ArkUI.ArkUI.Full 1414 * @crossplatform 1415 * @atomicservice 1416 * @since 11 1417 */ 1418 moveIndexToTop(index: number, animated?: boolean): void; 1419 1420 /** 1421 * Clears the stack. 1422 * 1423 * @syscap SystemCapability.ArkUI.ArkUI.Full 1424 * @crossplatform 1425 * @since 10 1426 */ 1427 /** 1428 * Clears the stack. 1429 * 1430 * @param { boolean } [animated] - Indicates whether the transition is animated. 1431 * @syscap SystemCapability.ArkUI.ArkUI.Full 1432 * @crossplatform 1433 * @atomicservice 1434 * @since 11 1435 */ 1436 clear(animated?: boolean): void; 1437 1438 /** 1439 * Obtains all the NavDestination name in the stack. 1440 * 1441 * @returns { Array<string> } Returns all the NavDestination name in the stack; 1442 * @syscap SystemCapability.ArkUI.ArkUI.Full 1443 * @crossplatform 1444 * @since 10 1445 */ 1446 /** 1447 * Obtains all the NavDestination name in the stack. 1448 * 1449 * @returns { Array<string> } Returns all the NavDestination name in the stack; 1450 * @syscap SystemCapability.ArkUI.ArkUI.Full 1451 * @crossplatform 1452 * @atomicservice 1453 * @since 11 1454 */ 1455 getAllPathName(): Array<string>; 1456 1457 /** 1458 * Obtains the param of the specified NavDestination. 1459 * 1460 * @param { number } index - Indicates the index of the NavDestination. 1461 * @returns { unknown | undefined } Returns the detailed parameter of the NavDestination if it exists in the stack, otherwise returns undefined; 1462 * @syscap SystemCapability.ArkUI.ArkUI.Full 1463 * @crossplatform 1464 * @since 10 1465 */ 1466 /** 1467 * Obtains the param of the specified NavDestination. 1468 * 1469 * @param { number } index - Indicates the index of the NavDestination. 1470 * @returns { unknown | undefined } Returns the detailed parameter of the NavDestination if it exists in the stack, otherwise returns undefined; 1471 * @syscap SystemCapability.ArkUI.ArkUI.Full 1472 * @crossplatform 1473 * @atomicservice 1474 * @since 11 1475 */ 1476 getParamByIndex(index: number): unknown | undefined; 1477 1478 /** 1479 * Obtains the param of the specified NavDestination. 1480 * 1481 * @param { string } name - Indicates the name of the NavDestination. 1482 * @returns { Array<unknown> } Returns the detailed parameter of all the NavDestinations. 1483 * @syscap SystemCapability.ArkUI.ArkUI.Full 1484 * @crossplatform 1485 * @since 10 1486 */ 1487 /** 1488 * Obtains the param of the specified NavDestination. 1489 * 1490 * @param { string } name - Indicates the name of the NavDestination. 1491 * @returns { Array<unknown> } Returns the detailed parameter of all the NavDestinations. 1492 * @syscap SystemCapability.ArkUI.ArkUI.Full 1493 * @crossplatform 1494 * @atomicservice 1495 * @since 11 1496 */ 1497 getParamByName(name: string): Array<unknown>; 1498 1499 /** 1500 * Obtains the index of the specified NavDestination. 1501 * 1502 * @param { string } name - Indicates the name of the NavDestination. 1503 * @returns { Array<number> } Returns the index of all the NavDestinations. 1504 * @syscap SystemCapability.ArkUI.ArkUI.Full 1505 * @crossplatform 1506 * @since 10 1507 */ 1508 /** 1509 * Obtains the index of the specified NavDestination. 1510 * 1511 * @param { string } name - Indicates the name of the NavDestination. 1512 * @returns { Array<number> } Returns the index of all the NavDestinations. 1513 * @syscap SystemCapability.ArkUI.ArkUI.Full 1514 * @crossplatform 1515 * @atomicservice 1516 * @since 11 1517 */ 1518 getIndexByName(name: string): Array<number>; 1519 1520 /** 1521 * Obtains the parent of the current stack. 1522 * 1523 * @returns { NavPathStack | null } Returns the parent of the current stack. If no parent, it returns null. 1524 * @syscap SystemCapability.ArkUI.ArkUI.Full 1525 * @crossplatform 1526 * @atomicservice 1527 * @since 11 1528 */ 1529 getParent(): NavPathStack | null; 1530 1531 /** 1532 * Obtains the size of the stack. 1533 * 1534 * @returns { number } Returns the size of the stack. 1535 * @syscap SystemCapability.ArkUI.ArkUI.Full 1536 * @crossplatform 1537 * @since 10 1538 */ 1539 /** 1540 * Obtains the size of the stack. 1541 * 1542 * @returns { number } Returns the size of the stack. 1543 * @syscap SystemCapability.ArkUI.ArkUI.Full 1544 * @crossplatform 1545 * @atomicservice 1546 * @since 11 1547 */ 1548 size(): number; 1549 1550 /** 1551 * disable or enable all transition animation in this navigation stack. 1552 * 1553 * @param { boolean } value - Indicates whether the transition is animated. 1554 * @syscap SystemCapability.ArkUI.ArkUI.Full 1555 * @crossplatform 1556 * @since 11 1557 */ 1558 /** 1559 * disable or enable all transition animation in this navigation stack. 1560 * 1561 * @param { boolean } value - Indicates whether the transition is animated. 1562 * @syscap SystemCapability.ArkUI.ArkUI.Full 1563 * @crossplatform 1564 * @atomicservice 1565 * @since 12 1566 */ 1567 disableAnimation(value: boolean): void; 1568 1569 /** 1570 * set navigation transition interception.It will be called in navPathStack changes or navigation mode changes. 1571 * 1572 * @param { NavigationInterception } interception - the instance to intercept in navigation changes. 1573 * @syscap SystemCapability.ArkUI.ArkUI.Full 1574 * @crossplatform 1575 * @atomicservice 1576 * @since 12 1577 */ 1578 setInterception(interception: NavigationInterception): void; 1579} 1580 1581/** 1582 * Navigation home name 1583 * 1584 * @typedef { 'navBar' } NavBar 1585 * @syscap SystemCapability.ArkUI.ArkUI.Full 1586 * @crossplatform 1587 * @atomicservice 1588 * @since 12 1589 */ 1590declare type NavBar = 'navBar' 1591 1592/** 1593 * navigation interception callback using in willShow and didShow 1594 * 1595 * @typedef { function } InterceptionShowCallback 1596 * @param { NavDestinationContext | NavBar } from - Indicates the starting NavDestination or NavBar. 1597 * @param { NavDestinationContext | NavBar } to - Indicates the destination NavDestination or NavBar. 1598 * @param { NavigationOperation } operation - Indicates the type of stack operation. 1599 * @param { boolean } isAnimated - Indicates whether the transition is animated. 1600 * @syscap SystemCapability.ArkUI.ArkUI.Full 1601 * @crossplatform 1602 * @atomicservice 1603 * @since 12 1604 */ 1605declare type InterceptionShowCallback = (from: NavDestinationContext|NavBar, to: NavDestinationContext|NavBar, operation: NavigationOperation, isAnimated: boolean) => void; 1606 1607/** 1608 * navigation interception callback using in navigation mode change 1609 * 1610 * @typedef { function } InterceptionModeCallback 1611 * @param { NavigationMode } mode - Indicates the mode of Navigation. 1612 * @syscap SystemCapability.ArkUI.ArkUI.Full 1613 * @crossplatform 1614 * @atomicservice 1615 * @since 12 1616 */ 1617declare type InterceptionModeCallback = (mode: NavigationMode) => void; 1618 1619/** 1620 * Provide navigation transition interception 1621 * 1622 * @interface NavigationInterception 1623 * @syscap SystemCapability.ArkUI.ArkUI.Full 1624 * @crossplatform 1625 * @atomicservice 1626 * @since 12 1627 */ 1628declare interface NavigationInterception { 1629 /** 1630 * Called before destination transition.NavPathStack can be changed in this callback, 1631 * it will takes effect during this transition.For details, see { @Link InterceptionShowCallback}. 1632 * 1633 * @type { ?InterceptionShowCallback } 1634 * @syscap SystemCapability.ArkUI.ArkUI.Full 1635 * @crossplatform 1636 * @atomicservice 1637 * @since 12 1638 */ 1639 willShow?: InterceptionShowCallback; 1640 1641 /** 1642 * Called after destination transition.For details, see { @Link InterceptionShowCallback}. 1643 * 1644 * @type { ?InterceptionShowCallback } 1645 * @syscap SystemCapability.ArkUI.ArkUI.Full 1646 * @crossplatform 1647 * @atomicservice 1648 * @since 12 1649 */ 1650 didShow?: InterceptionShowCallback; 1651 1652 /** 1653 * Called when navigation mode changed.For details, see { @Link InterceptionModeCallback}. 1654 * 1655 * @type { ?InterceptionModeCallback } 1656 * @syscap SystemCapability.ArkUI.ArkUI.Full 1657 * @crossplatform 1658 * @atomicservice 1659 * @since 12 1660 */ 1661 modeChange?: InterceptionModeCallback; 1662} 1663 1664/** 1665 * Provide navigator view interface 1666 * 1667 * @interface NavigationInterface 1668 * @syscap SystemCapability.ArkUI.ArkUI.Full 1669 * @since 8 1670 */ 1671/** 1672 * Provide navigator view interface 1673 * 1674 * @interface NavigationInterface 1675 * @syscap SystemCapability.ArkUI.ArkUI.Full 1676 * @crossplatform 1677 * @since 10 1678 */ 1679/** 1680 * Provide navigator view interface 1681 * 1682 * @interface NavigationInterface 1683 * @syscap SystemCapability.ArkUI.ArkUI.Full 1684 * @crossplatform 1685 * @atomicservice 1686 * @since 11 1687 */ 1688interface NavigationInterface { 1689 /** 1690 * Called when the navigator view interface is used. 1691 * 1692 * @returns { NavigationAttribute } 1693 * @syscap SystemCapability.ArkUI.ArkUI.Full 1694 * @since 8 1695 */ 1696 /** 1697 * Called when the navigator view interface is used. 1698 * 1699 * @returns { NavigationAttribute } 1700 * @syscap SystemCapability.ArkUI.ArkUI.Full 1701 * @crossplatform 1702 * @since 10 1703 */ 1704 /** 1705 * Called when the navigator view interface is used. 1706 * 1707 * @returns { NavigationAttribute } 1708 * @syscap SystemCapability.ArkUI.ArkUI.Full 1709 * @crossplatform 1710 * @atomicservice 1711 * @since 11 1712 */ 1713 (): NavigationAttribute; 1714 1715 /** 1716 * Called when the navigator view interface is used, with route table provided. 1717 * 1718 * @param { NavPathStack } pathInfos - The stack of the route table. 1719 * @returns { NavigationAttribute } Returns the instance of the NavigationAttribute. 1720 * @syscap SystemCapability.ArkUI.ArkUI.Full 1721 * @crossplatform 1722 * @since 10 1723 */ 1724 /** 1725 * Called when the navigator view interface is used, with route table provided. 1726 * 1727 * @param { NavPathStack } pathInfos - The stack of the route table. 1728 * @returns { NavigationAttribute } Returns the instance of the NavigationAttribute. 1729 * @syscap SystemCapability.ArkUI.ArkUI.Full 1730 * @crossplatform 1731 * @atomicservice 1732 * @since 11 1733 */ 1734 (pathInfos: NavPathStack): NavigationAttribute; 1735} 1736 1737/** 1738 * Defines the status of toolbar item and it is used in the ToolbarItem interface. 1739 * 1740 * @enum { number } 1741 * @syscap SystemCapability.ArkUI.ArkUI.Full 1742 * @since 10 1743 */ 1744/** 1745 * Defines the status of toolbar item and it is used in the ToolbarItem interface. 1746 * 1747 * @enum { number } 1748 * @syscap SystemCapability.ArkUI.ArkUI.Full 1749 * @crossplatform 1750 * @atomicservice 1751 * @since 11 1752 */ 1753declare enum ToolbarItemStatus { 1754 /** 1755 * Normal state of toolbar item. 1756 * 1757 * @syscap SystemCapability.ArkUI.ArkUI.Full 1758 * @since 10 1759 */ 1760 /** 1761 * Normal state of toolbar item. 1762 * 1763 * @syscap SystemCapability.ArkUI.ArkUI.Full 1764 * @crossplatform 1765 * @atomicservice 1766 * @since 11 1767 */ 1768 NORMAL = 0, 1769 1770 /** 1771 * Disable state of toolbar item. 1772 * 1773 * @syscap SystemCapability.ArkUI.ArkUI.Full 1774 * @since 10 1775 */ 1776 /** 1777 * Disable state of toolbar item. 1778 * 1779 * @syscap SystemCapability.ArkUI.ArkUI.Full 1780 * @crossplatform 1781 * @atomicservice 1782 * @since 11 1783 */ 1784 DISABLED = 1, 1785 1786 /** 1787 * Active state of toolbar item. 1788 * 1789 * @syscap SystemCapability.ArkUI.ArkUI.Full 1790 * @since 10 1791 */ 1792 /** 1793 * Active state of toolbar item. 1794 * 1795 * @syscap SystemCapability.ArkUI.ArkUI.Full 1796 * @crossplatform 1797 * @atomicservice 1798 * @since 11 1799 */ 1800 ACTIVE = 2, 1801} 1802 1803/** 1804 * Defines the operation of current navigation transition. 1805 * 1806 * @enum { number } 1807 * @syscap SystemCapability.ArkUI.ArkUI.Full 1808 * @crossplatform 1809 * @since 11 1810 */ 1811/** 1812 * Defines the operation of current navigation transition. 1813 * 1814 * @enum { number } 1815 * @syscap SystemCapability.ArkUI.ArkUI.Full 1816 * @crossplatform 1817 * @atomicservice 1818 * @since 12 1819 */ 1820declare enum NavigationOperation { 1821 /** 1822 * Push operation of navigation transition. 1823 * 1824 * @syscap SystemCapability.ArkUI.ArkUI.Full 1825 * @crossplatform 1826 * @since 11 1827 */ 1828 /** 1829 * Push operation of navigation transition. 1830 * 1831 * @syscap SystemCapability.ArkUI.ArkUI.Full 1832 * @crossplatform 1833 * @atomicservice 1834 * @since 12 1835 */ 1836 PUSH = 1, 1837 1838 /** 1839 * Pop operation of navigation transition. 1840 * 1841 * @syscap SystemCapability.ArkUI.ArkUI.Full 1842 * @crossplatform 1843 * @since 11 1844 */ 1845 /** 1846 * Pop operation of navigation transition. 1847 * 1848 * @syscap SystemCapability.ArkUI.ArkUI.Full 1849 * @crossplatform 1850 * @atomicservice 1851 * @since 12 1852 */ 1853 POP = 2, 1854 1855 /** 1856 * Replace operation of navigation transition. 1857 * 1858 * @syscap SystemCapability.ArkUI.ArkUI.Full 1859 * @crossplatform 1860 * @since 11 1861 */ 1862 /** 1863 * Replace operation of navigation transition. 1864 * 1865 * @syscap SystemCapability.ArkUI.ArkUI.Full 1866 * @crossplatform 1867 * @atomicservice 1868 * @since 12 1869 */ 1870 REPLACE = 3, 1871} 1872 1873/** 1874 * Defines configurable parameters for toolbar item. 1875 * 1876 * @interface ToolbarItem 1877 * @syscap SystemCapability.ArkUI.ArkUI.Full 1878 * @since 10 1879 */ 1880/** 1881 * Defines configurable parameters for toolbar item. 1882 * 1883 * @interface ToolbarItem 1884 * @syscap SystemCapability.ArkUI.ArkUI.Full 1885 * @atomicservice 1886 * @since 11 1887 */ 1888declare interface ToolbarItem { 1889 /** 1890 * The value of navigation toolbar item. 1891 * 1892 * @type { ResourceStr } 1893 * @syscap SystemCapability.ArkUI.ArkUI.Full 1894 * @crossplatform 1895 * @since 10 1896 */ 1897 /** 1898 * The value of navigation toolbar item. 1899 * 1900 * @type { ResourceStr } 1901 * @syscap SystemCapability.ArkUI.ArkUI.Full 1902 * @crossplatform 1903 * @atomicservice 1904 * @since 11 1905 */ 1906 value: ResourceStr; 1907 1908 /** 1909 * The icon of navigation toolbar item. 1910 * 1911 * @type { ?ResourceStr } 1912 * @syscap SystemCapability.ArkUI.ArkUI.Full 1913 * @crossplatform 1914 * @since 10 1915 */ 1916 /** 1917 * The icon of navigation toolbar item. 1918 * 1919 * @type { ?ResourceStr } 1920 * @syscap SystemCapability.ArkUI.ArkUI.Full 1921 * @crossplatform 1922 * @atomicservice 1923 * @since 11 1924 */ 1925 icon?: ResourceStr; 1926 1927 /** 1928 * The symbol of navigation toolbar item. 1929 * 1930 * @type { ?SymbolGlyphModifier } 1931 * @syscap SystemCapability.ArkUI.ArkUI.Full 1932 * @atomicservice 1933 * @since 12 1934 */ 1935 symbolIcon?: SymbolGlyphModifier; 1936 1937 /** 1938 * Trigger by navigation toolbar item click. 1939 * 1940 * @type { ?function } 1941 * @syscap SystemCapability.ArkUI.ArkUI.Full 1942 * @crossplatform 1943 * @since 10 1944 */ 1945 /** 1946 * Trigger by navigation toolbar item click. 1947 * 1948 * @type { ?function } 1949 * @syscap SystemCapability.ArkUI.ArkUI.Full 1950 * @crossplatform 1951 * @atomicservice 1952 * @since 11 1953 */ 1954 action?: () => void; 1955 1956 /** 1957 * The state of navigation toolbar item. 1958 * 1959 * @type { ?ToolbarItemStatus } 1960 * @syscap SystemCapability.ArkUI.ArkUI.Full 1961 * @crossplatform 1962 * @since 10 1963 */ 1964 /** 1965 * The state of navigation toolbar item. 1966 * 1967 * @type { ?ToolbarItemStatus } 1968 * @syscap SystemCapability.ArkUI.ArkUI.Full 1969 * @crossplatform 1970 * @atomicservice 1971 * @since 11 1972 */ 1973 status?: ToolbarItemStatus; 1974 1975 /** 1976 * The icon of navigation toolbar item in active state. 1977 * 1978 * @type { ?ResourceStr } 1979 * @syscap SystemCapability.ArkUI.ArkUI.Full 1980 * @crossplatform 1981 * @since 10 1982 */ 1983 /** 1984 * The icon of navigation toolbar item in active state. 1985 * 1986 * @type { ?ResourceStr } 1987 * @syscap SystemCapability.ArkUI.ArkUI.Full 1988 * @crossplatform 1989 * @atomicservice 1990 * @since 11 1991 */ 1992 activeIcon?: ResourceStr; 1993 1994 /** 1995 * The symbol of navigation toolbar item in active state. 1996 * 1997 * @type { ?SymbolGlyphModifier } 1998 * @syscap SystemCapability.ArkUI.ArkUI.Full 1999 * @atomicservice 2000 * @since 12 2001 */ 2002 activeSymbolIcon?: SymbolGlyphModifier; 2003} 2004 2005/** 2006 * Indicates the options of Navigation's Titlebar. 2007 * 2008 * @interface NavigationTitleOptions 2009 * @syscap SystemCapability.ArkUI.ArkUI.Full 2010 * @crossplatform 2011 * @atomicservice 2012 * @since 11 2013 */ 2014declare interface NavigationTitleOptions { 2015 /** 2016 * Background color. 2017 * 2018 * @type { ?ResourceColor } 2019 * @syscap SystemCapability.ArkUI.ArkUI.Full 2020 * @crossplatform 2021 * @atomicservice 2022 * @since 11 2023 */ 2024 backgroundColor?: ResourceColor; 2025 2026 /** 2027 * Background blur style. 2028 * 2029 * @type { ?BlurStyle } 2030 * @syscap SystemCapability.ArkUI.ArkUI.Full 2031 * @crossplatform 2032 * @atomicservice 2033 * @since 11 2034 */ 2035 backgroundBlurStyle?: BlurStyle; 2036 2037 /** 2038 * Set title bar style. 2039 * 2040 * @type { ?BarStyle } 2041 * @default BarStyle.STANDARD 2042 * @syscap SystemCapability.ArkUI.ArkUI.Full 2043 * @crossplatform 2044 * @atomicservice 2045 * @since 12 2046 */ 2047 barStyle?: BarStyle; 2048 2049 /** 2050 * Set title bar start padding. 2051 * 2052 * @type { ?LengthMetrics } 2053 * @default LengthMetrics.resource($r('sys.float.margin_left')) 2054 * @syscap SystemCapability.ArkUI.ArkUI.Full 2055 * @crossplatform 2056 * @atomicservice 2057 * @since 12 2058 */ 2059 paddingStart?: LengthMetrics; 2060 2061 /** 2062 * Set title bar end padding. 2063 * 2064 * @type { ?LengthMetrics } 2065 * @default LengthMetrics.resource($r('sys.float.margin_right')) 2066 * @syscap SystemCapability.ArkUI.ArkUI.Full 2067 * @crossplatform 2068 * @atomicservice 2069 * @since 12 2070 */ 2071 paddingEnd?: LengthMetrics; 2072 2073 /** 2074 * Text modifier for main title. 2075 * 2076 * @type { ?TextModifier } 2077 * @syscap SystemCapability.ArkUI.ArkUI.Full 2078 * @crossplatform 2079 * @atomicservice 2080 * @since 13 2081 */ 2082 mainTitleModifier?: TextModifier; 2083 2084 /** 2085 * Text modifier for sub title. 2086 * 2087 * @type { ?TextModifier } 2088 * @syscap SystemCapability.ArkUI.ArkUI.Full 2089 * @crossplatform 2090 * @atomicservice 2091 * @since 13 2092 */ 2093 subTitleModifier?: TextModifier; 2094 2095 /** 2096 * Defines whether to respond to the hover mode. 2097 * 2098 * @type { ?boolean } 2099 * @default false 2100 * @syscap SystemCapability.ArkUI.ArkUI.Full 2101 * @crossplatform 2102 * @atomicservice 2103 * @since 13 2104 */ 2105 enableHoverMode?: boolean; 2106} 2107 2108/** 2109 * Declare BarStyle enum. 2110 * 2111 * @enum { number } 2112 * @syscap SystemCapability.ArkUI.ArkUI.Full 2113 * @crossplatform 2114 * @atomicservice 2115 * @since 12 2116 */ 2117declare enum BarStyle { 2118 /** 2119 * Standard style means that the bar and content area are column layouts. 2120 * 2121 * @syscap SystemCapability.ArkUI.ArkUI.Full 2122 * @crossplatform 2123 * @atomicservice 2124 * @since 12 2125 */ 2126 STANDARD = 0, 2127 2128 /** 2129 * Stack style means that the bar and content area are stack layouts. 2130 * 2131 * @syscap SystemCapability.ArkUI.ArkUI.Full 2132 * @crossplatform 2133 * @atomicservice 2134 * @since 12 2135 */ 2136 STACK = 1, 2137 2138 /** 2139 * SafeAreaPadding style means the bar height will be taken as content's safeAreaPadding. 2140 * 2141 * @syscap SystemCapability.ArkUI.ArkUI.Full 2142 * @crossplatform 2143 * @atomicservice 2144 * @since 14 2145 */ 2146 SAFE_AREA_PADDING = 2, 2147} 2148 2149/** 2150 * Indicates the options of Navigation's Toolbar. 2151 * 2152 * @interface NavigationToolbarOptions 2153 * @syscap SystemCapability.ArkUI.ArkUI.Full 2154 * @crossplatform 2155 * @atomicservice 2156 * @since 11 2157 */ 2158declare interface NavigationToolbarOptions { 2159 /** 2160 * Background color. 2161 * 2162 * @type { ?ResourceColor } 2163 * @syscap SystemCapability.ArkUI.ArkUI.Full 2164 * @crossplatform 2165 * @atomicservice 2166 * @since 11 2167 */ 2168 backgroundColor?: ResourceColor; 2169 2170 /** 2171 * Background blur style. 2172 * 2173 * @type { ?BlurStyle } 2174 * @syscap SystemCapability.ArkUI.ArkUI.Full 2175 * @crossplatform 2176 * @atomicservice 2177 * @since 11 2178 */ 2179 backgroundBlurStyle?: BlurStyle; 2180 2181 /** 2182 * Set tool bar style. 2183 * 2184 * @type { ?BarStyle } 2185 * @default BarStyle.STANDARD 2186 * @syscap SystemCapability.ArkUI.ArkUI.Full 2187 * @crossplatform 2188 * @atomicservice 2189 * @since 14 2190 */ 2191 barStyle?: BarStyle; 2192} 2193 2194/** 2195 * Declare Navigation view properties. 2196 * 2197 * @extends CommonMethod<NavigationAttribute> 2198 * @syscap SystemCapability.ArkUI.ArkUI.Full 2199 * @since 8 2200 */ 2201/** 2202 * Declare Navigation view properties. 2203 * 2204 * @extends CommonMethod<NavigationAttribute> 2205 * @syscap SystemCapability.ArkUI.ArkUI.Full 2206 * @crossplatform 2207 * @since 10 2208 */ 2209/** 2210 * Declare Navigation view properties. 2211 * 2212 * @extends CommonMethod<NavigationAttribute> 2213 * @syscap SystemCapability.ArkUI.ArkUI.Full 2214 * @crossplatform 2215 * @atomicservice 2216 * @since 11 2217 */ 2218declare class NavigationAttribute extends CommonMethod<NavigationAttribute> { 2219 /** 2220 * Sets the width of navigation bar. 2221 * 2222 * @param { Length } value 2223 * @returns { NavigationAttribute } 2224 * @syscap SystemCapability.ArkUI.ArkUI.Full 2225 * @since 9 2226 */ 2227 /** 2228 * Sets the width of navigation bar. 2229 * 2230 * @param { Length } value 2231 * @returns { NavigationAttribute } 2232 * @syscap SystemCapability.ArkUI.ArkUI.Full 2233 * @crossplatform 2234 * @since 10 2235 */ 2236 /** 2237 * Sets the width of navigation bar. 2238 * 2239 * @param { Length } value 2240 * @returns { NavigationAttribute } 2241 * @syscap SystemCapability.ArkUI.ArkUI.Full 2242 * @crossplatform 2243 * @atomicservice 2244 * @since 11 2245 */ 2246 navBarWidth(value: Length): NavigationAttribute; 2247 2248 /** 2249 * Sets the position of navigation bar. 2250 * 2251 * @param { NavBarPosition } value 2252 * @returns { NavigationAttribute } 2253 * @syscap SystemCapability.ArkUI.ArkUI.Full 2254 * @since 9 2255 */ 2256 /** 2257 * Sets the position of navigation bar. 2258 * 2259 * @param { NavBarPosition } value 2260 * @returns { NavigationAttribute } 2261 * @syscap SystemCapability.ArkUI.ArkUI.Full 2262 * @crossplatform 2263 * @since 10 2264 */ 2265 /** 2266 * Sets the position of navigation bar. 2267 * 2268 * @param { NavBarPosition } value 2269 * @returns { NavigationAttribute } 2270 * @syscap SystemCapability.ArkUI.ArkUI.Full 2271 * @crossplatform 2272 * @atomicservice 2273 * @since 11 2274 */ 2275 navBarPosition(value: NavBarPosition): NavigationAttribute; 2276 2277 /** 2278 * Sets the minimum width and the maximum width of navigation bar. 2279 * 2280 * @param { [Dimension, Dimension] } value - The minimum and the maximum width of navigation bar. 2281 * @returns { NavigationAttribute } 2282 * @syscap SystemCapability.ArkUI.ArkUI.Full 2283 * @crossplatform 2284 * @since 10 2285 */ 2286 /** 2287 * Sets the minimum width and the maximum width of navigation bar. 2288 * 2289 * @param { [Dimension, Dimension] } value - The minimum and the maximum width of navigation bar. 2290 * @returns { NavigationAttribute } 2291 * @syscap SystemCapability.ArkUI.ArkUI.Full 2292 * @crossplatform 2293 * @atomicservice 2294 * @since 11 2295 */ 2296 navBarWidthRange(value: [Dimension, Dimension]): NavigationAttribute; 2297 2298 /** 2299 * Sets the minimum width of content. 2300 * 2301 * @param { Dimension } value - The minimum width of content. 2302 * @returns { NavigationAttribute } 2303 * @syscap SystemCapability.ArkUI.ArkUI.Full 2304 * @crossplatform 2305 * @since 10 2306 */ 2307 /** 2308 * Sets the minimum width of content. 2309 * 2310 * @param { Dimension } value - The minimum width of content. 2311 * @returns { NavigationAttribute } 2312 * @syscap SystemCapability.ArkUI.ArkUI.Full 2313 * @crossplatform 2314 * @atomicservice 2315 * @since 11 2316 */ 2317 minContentWidth(value: Dimension): NavigationAttribute; 2318 2319 /** 2320 * Sets the mode of navigation. 2321 * 2322 * @param { NavigationMode } value 2323 * @returns { NavigationAttribute } 2324 * @syscap SystemCapability.ArkUI.ArkUI.Full 2325 * @since 9 2326 */ 2327 /** 2328 * Sets the mode of navigation. 2329 * 2330 * @param { NavigationMode } value 2331 * @returns { NavigationAttribute } 2332 * @syscap SystemCapability.ArkUI.ArkUI.Full 2333 * @crossplatform 2334 * @since 10 2335 */ 2336 /** 2337 * Sets the mode of navigation. 2338 * 2339 * @param { NavigationMode } value 2340 * @returns { NavigationAttribute } 2341 * @syscap SystemCapability.ArkUI.ArkUI.Full 2342 * @crossplatform 2343 * @atomicservice 2344 * @since 11 2345 */ 2346 mode(value: NavigationMode): NavigationAttribute; 2347 2348 /** 2349 * Sets the back button icon. 2350 * 2351 * @param { string | PixelMap | Resource } value 2352 * @returns { NavigationAttribute } 2353 * @syscap SystemCapability.ArkUI.ArkUI.Full 2354 * @since 9 2355 */ 2356 /** 2357 * Sets the back button icon. 2358 * 2359 * @param { string | PixelMap | Resource } value 2360 * @returns { NavigationAttribute } 2361 * @syscap SystemCapability.ArkUI.ArkUI.Full 2362 * @crossplatform 2363 * @since 10 2364 */ 2365 /** 2366 * Sets the back button icon. 2367 * 2368 * @param { string | PixelMap | Resource } value 2369 * @returns { NavigationAttribute } 2370 * @syscap SystemCapability.ArkUI.ArkUI.Full 2371 * @crossplatform 2372 * @atomicservice 2373 * @since 11 2374 */ 2375 /** 2376 * Sets the back button icon. 2377 * 2378 * @param { string | PixelMap | Resource | SymbolGlyphModifier } value 2379 * @returns { NavigationAttribute } 2380 * @syscap SystemCapability.ArkUI.ArkUI.Full 2381 * @crossplatform 2382 * @atomicservice 2383 * @since 12 2384 */ 2385 backButtonIcon(value: string | PixelMap | Resource | SymbolGlyphModifier): NavigationAttribute; 2386 2387 /** 2388 * Hide the NavBar, which includes title bar, the child of Navigation and tool bar. Supported in split mode. 2389 * 2390 * @param { boolean } value 2391 * @returns { NavigationAttribute } 2392 * @syscap SystemCapability.ArkUI.ArkUI.Full 2393 * @since 9 2394 */ 2395 /** 2396 * Hide the NavBar, which includes title bar, the child of Navigation and tool bar. Supported in split mode. 2397 * 2398 * @param { boolean } value 2399 * @returns { NavigationAttribute } 2400 * @syscap SystemCapability.ArkUI.ArkUI.Full 2401 * @crossplatform 2402 * @since 10 2403 */ 2404 /** 2405 * Hide the NavBar, which includes title bar, the child of Navigation and tool bar. Supported in all mode. 2406 * It will show top page in the NavPathStack directly or empty if there is no page in the NavPathStack. 2407 * 2408 * @param { boolean } value 2409 * @returns { NavigationAttribute } 2410 * @syscap SystemCapability.ArkUI.ArkUI.Full 2411 * @crossplatform 2412 * @atomicservice 2413 * @since 11 2414 */ 2415 hideNavBar(value: boolean): NavigationAttribute; 2416 2417 /** 2418 * Navigation title 2419 * 2420 * @param { string | CustomBuilder } value 2421 * @returns { NavigationAttribute } 2422 * @syscap SystemCapability.ArkUI.ArkUI.Full 2423 * @since 8 2424 */ 2425 /** 2426 * Navigation title 2427 * 2428 * @param { string | CustomBuilder | NavigationCommonTitle | NavigationCustomTitle } value 2429 * @returns { NavigationAttribute } 2430 * @syscap SystemCapability.ArkUI.ArkUI.Full 2431 * @since 9 2432 */ 2433 /** 2434 * Navigation title 2435 * 2436 * @param { ResourceStr | CustomBuilder | NavigationCommonTitle | NavigationCustomTitle } value 2437 * @returns { NavigationAttribute } 2438 * @syscap SystemCapability.ArkUI.ArkUI.Full 2439 * @crossplatform 2440 * @since 10 2441 */ 2442 /** 2443 * Navigation title 2444 * 2445 * @param { ResourceStr | CustomBuilder | NavigationCommonTitle | NavigationCustomTitle } value 2446 * @param { NavigationTitleOptions } [options] - Indicates the options of titlebar. 2447 * @returns { NavigationAttribute } 2448 * @syscap SystemCapability.ArkUI.ArkUI.Full 2449 * @crossplatform 2450 * @atomicservice 2451 * @since 11 2452 */ 2453 title(value: ResourceStr | CustomBuilder | NavigationCommonTitle | NavigationCustomTitle, options?: NavigationTitleOptions): NavigationAttribute; 2454 2455 /** 2456 * Navigation subtitle 2457 * 2458 * @param { string } value 2459 * @returns { NavigationAttribute } 2460 * @syscap SystemCapability.ArkUI.ArkUI.Full 2461 * @since 8 2462 * @deprecated since 9 2463 * @useinstead title 2464 */ 2465 subTitle(value: string): NavigationAttribute; 2466 2467 /** 2468 * Hide navigation title bar 2469 * 2470 * @param { boolean } value 2471 * @returns { NavigationAttribute } 2472 * @syscap SystemCapability.ArkUI.ArkUI.Full 2473 * @since 8 2474 */ 2475 /** 2476 * Hide navigation title bar 2477 * 2478 * @param { boolean } value 2479 * @returns { NavigationAttribute } 2480 * @syscap SystemCapability.ArkUI.ArkUI.Full 2481 * @crossplatform 2482 * @since 10 2483 */ 2484 /** 2485 * Hide navigation title bar 2486 * 2487 * @param { boolean } value 2488 * @returns { NavigationAttribute } 2489 * @syscap SystemCapability.ArkUI.ArkUI.Full 2490 * @crossplatform 2491 * @atomicservice 2492 * @since 11 2493 */ 2494 hideTitleBar(value: boolean): NavigationAttribute; 2495 2496 /** 2497 * Hide navigation title bar 2498 * 2499 * @param { boolean } hide 2500 * @param { boolean } animated 2501 * @returns { NavigationAttribute } 2502 * @syscap SystemCapability.ArkUI.ArkUI.Full 2503 * @crossplatform 2504 * @atomicservice 2505 * @since 13 2506 */ 2507 hideTitleBar(hide: boolean, animated: boolean): NavigationAttribute; 2508 2509 /** 2510 * Hide navigation back button 2511 * 2512 * @param { boolean } value 2513 * @returns { NavigationAttribute } 2514 * @syscap SystemCapability.ArkUI.ArkUI.Full 2515 * @since 8 2516 */ 2517 /** 2518 * Hide navigation back button 2519 * 2520 * @param { boolean } value 2521 * @returns { NavigationAttribute } 2522 * @syscap SystemCapability.ArkUI.ArkUI.Full 2523 * @crossplatform 2524 * @since 10 2525 */ 2526 /** 2527 * Hide navigation back button 2528 * 2529 * @param { boolean } value 2530 * @returns { NavigationAttribute } 2531 * @syscap SystemCapability.ArkUI.ArkUI.Full 2532 * @crossplatform 2533 * @atomicservice 2534 * @since 11 2535 */ 2536 hideBackButton(value: boolean): NavigationAttribute; 2537 2538 /** 2539 * Navigation title mode 2540 * 2541 * @param { NavigationTitleMode } value 2542 * @returns { NavigationAttribute } 2543 * @syscap SystemCapability.ArkUI.ArkUI.Full 2544 * @since 8 2545 */ 2546 /** 2547 * Navigation title mode 2548 * 2549 * @param { NavigationTitleMode } value 2550 * @returns { NavigationAttribute } 2551 * @syscap SystemCapability.ArkUI.ArkUI.Full 2552 * @crossplatform 2553 * @since 10 2554 */ 2555 /** 2556 * Navigation title mode 2557 * 2558 * @param { NavigationTitleMode } value 2559 * @returns { NavigationAttribute } 2560 * @syscap SystemCapability.ArkUI.ArkUI.Full 2561 * @crossplatform 2562 * @atomicservice 2563 * @since 11 2564 */ 2565 titleMode(value: NavigationTitleMode): NavigationAttribute; 2566 2567 /** 2568 * Navigation title bar's menus 2569 * 2570 * @param { Array<NavigationMenuItem> | CustomBuilder } value 2571 * @returns { NavigationAttribute } 2572 * @syscap SystemCapability.ArkUI.ArkUI.Full 2573 * @since 8 2574 */ 2575 /** 2576 * Navigation title bar's menus 2577 * 2578 * @param { Array<NavigationMenuItem> | CustomBuilder } value 2579 * @returns { NavigationAttribute } 2580 * @syscap SystemCapability.ArkUI.ArkUI.Full 2581 * @crossplatform 2582 * @since 10 2583 */ 2584 /** 2585 * Navigation title bar's menus 2586 * 2587 * @param { Array<NavigationMenuItem> | CustomBuilder } value 2588 * @returns { NavigationAttribute } 2589 * @syscap SystemCapability.ArkUI.ArkUI.Full 2590 * @crossplatform 2591 * @atomicservice 2592 * @since 11 2593 */ 2594 menus(value: Array<NavigationMenuItem> | CustomBuilder): NavigationAttribute; 2595 2596 /** 2597 * Tool bar 2598 * 2599 * @param { object | CustomBuilder } value 2600 * @returns { NavigationAttribute } 2601 * @syscap SystemCapability.ArkUI.ArkUI.Full 2602 * @since 8 2603 * @deprecated since 10 2604 * @useinstead navigation/NavigationAttribute#toolbarConfiguration 2605 */ 2606 toolBar(value: object | CustomBuilder): NavigationAttribute; 2607 2608 /** 2609 * Configure toolbar with default style parameter or custom parameter. 2610 * 2611 * @param { Array<ToolbarItem> | CustomBuilder } value - Toolbar configuration parameters. 2612 * @returns { NavigationAttribute } 2613 * @syscap SystemCapability.ArkUI.ArkUI.Full 2614 * @crossplatform 2615 * @since 10 2616 */ 2617 /** 2618 * Configure toolbar with default style parameter or custom parameter. 2619 * 2620 * @param { Array<ToolbarItem> | CustomBuilder } value - Toolbar configuration parameters. 2621 * @param { NavigationToolbarOptions } [options] - Indicates the options of toolbar. 2622 * @returns { NavigationAttribute } 2623 * @syscap SystemCapability.ArkUI.ArkUI.Full 2624 * @crossplatform 2625 * @atomicservice 2626 * @since 11 2627 */ 2628 toolbarConfiguration(value: Array<ToolbarItem> | CustomBuilder, options?: NavigationToolbarOptions): NavigationAttribute; 2629 2630 /** 2631 * Hide tool bar 2632 * 2633 * @param { boolean } value 2634 * @returns { NavigationAttribute } 2635 * @syscap SystemCapability.ArkUI.ArkUI.Full 2636 * @since 8 2637 */ 2638 /** 2639 * Hide tool bar 2640 * 2641 * @param { boolean } value 2642 * @returns { NavigationAttribute } 2643 * @syscap SystemCapability.ArkUI.ArkUI.Full 2644 * @crossplatform 2645 * @since 10 2646 */ 2647 /** 2648 * Hide tool bar 2649 * 2650 * @param { boolean } value 2651 * @returns { NavigationAttribute } 2652 * @syscap SystemCapability.ArkUI.ArkUI.Full 2653 * @crossplatform 2654 * @atomicservice 2655 * @since 11 2656 */ 2657 hideToolBar(value: boolean): NavigationAttribute; 2658 2659 /** 2660 * Hide tool bar 2661 * 2662 * @param { boolean } hide 2663 * @param { boolean } animated 2664 * @returns { NavigationAttribute } 2665 * @syscap SystemCapability.ArkUI.ArkUI.Full 2666 * @crossplatform 2667 * @atomicservice 2668 * @since 13 2669 */ 2670 hideToolBar(hide: boolean, animated: boolean): NavigationAttribute; 2671 2672 /** 2673 * Trigger callback when title mode change finished at free mode. 2674 * 2675 * @param { (titleMode: NavigationTitleMode) => void } callback 2676 * @returns { NavigationAttribute } 2677 * @syscap SystemCapability.ArkUI.ArkUI.Full 2678 * @since 8 2679 */ 2680 /** 2681 * Trigger callback when title mode change finished at free mode. 2682 * 2683 * @param { function } callback 2684 * @returns { NavigationAttribute } 2685 * @syscap SystemCapability.ArkUI.ArkUI.Full 2686 * @crossplatform 2687 * @since 10 2688 */ 2689 /** 2690 * Trigger callback when title mode change finished at free mode. 2691 * 2692 * @param { function } callback 2693 * @returns { NavigationAttribute } 2694 * @syscap SystemCapability.ArkUI.ArkUI.Full 2695 * @crossplatform 2696 * @atomicservice 2697 * @since 11 2698 */ 2699 onTitleModeChange(callback: (titleMode: NavigationTitleMode) => void): NavigationAttribute; 2700 2701 /** 2702 * Trigger callback when the visibility of navigation bar change. 2703 * 2704 * @param { (isVisible: boolean) => void } callback 2705 * @returns { NavigationAttribute } 2706 * @syscap SystemCapability.ArkUI.ArkUI.Full 2707 * @since 9 2708 */ 2709 /** 2710 * Trigger callback when the visibility of navigation bar change. 2711 * 2712 * @param { function } callback 2713 * @returns { NavigationAttribute } 2714 * @syscap SystemCapability.ArkUI.ArkUI.Full 2715 * @crossplatform 2716 * @since 10 2717 */ 2718 /** 2719 * Trigger callback when the visibility of navigation bar change. 2720 * 2721 * @param { function } callback 2722 * @returns { NavigationAttribute } 2723 * @syscap SystemCapability.ArkUI.ArkUI.Full 2724 * @crossplatform 2725 * @atomicservice 2726 * @since 11 2727 */ 2728 onNavBarStateChange(callback: (isVisible: boolean) => void): NavigationAttribute; 2729 2730 /** 2731 * Trigger callback when navigation mode changes. 2732 * 2733 * @param { function } callback 2734 * @returns { NavigationAttribute } 2735 * @syscap SystemCapability.ArkUI.ArkUI.Full 2736 * @crossplatform 2737 * @atomicservice 2738 * @since 11 2739 */ 2740 onNavigationModeChange(callback: (mode: NavigationMode) => void): NavigationAttribute; 2741 2742 /** 2743 * Set builder for user-defined NavDestination component. 2744 * 2745 * @param { function } builder - The builder function of NavDestination component. 2746 * @returns { NavigationAttribute } Returns the instance of the NavigationAttribute. 2747 * @syscap SystemCapability.ArkUI.ArkUI.Full 2748 * @crossplatform 2749 * @since 10 2750 */ 2751 /** 2752 * Set builder for user-defined NavDestination component. 2753 * 2754 * @param { function } builder - The builder function of NavDestination component. 2755 * @returns { NavigationAttribute } Returns the instance of the NavigationAttribute. 2756 * @syscap SystemCapability.ArkUI.ArkUI.Full 2757 * @crossplatform 2758 * @atomicservice 2759 * @since 11 2760 */ 2761 navDestination(builder: (name: string, param: unknown) => void): NavigationAttribute; 2762 2763 /** 2764 * Set custom navigation content transition animation. 2765 * 2766 * @param { function } delegate - Custom transition delegate. 2767 * @returns { NavigationAttribute } Returns the instance of the NavigationAttribute. 2768 * @syscap SystemCapability.ArkUI.ArkUI.Full 2769 * @crossplatform 2770 * @since 11 2771 */ 2772 /** 2773 * Set custom navigation content transition animation. 2774 * 2775 * @param { function } delegate - Custom transition delegate. 2776 * @returns { NavigationAttribute } Returns the instance of the NavigationAttribute. 2777 * @syscap SystemCapability.ArkUI.ArkUI.Full 2778 * @crossplatform 2779 * @atomicservice 2780 * @since 12 2781 */ 2782 customNavContentTransition(delegate: (from: NavContentInfo, to: NavContentInfo, operation: NavigationOperation) => NavigationAnimatedTransition | undefined): NavigationAttribute; 2783 2784 /** 2785 * Set navigation content expand types and edges. 2786 * 2787 * @param { Array<LayoutSafeAreaType> } [types] - Indicates the types of the safe area. 2788 * @param { Array<LayoutSafeAreaEdge> } [edges] - Indicates the edges of the safe area. 2789 * @returns { NavigationAttribute } 2790 * @syscap SystemCapability.ArkUI.ArkUI.Full 2791 * @crossplatform 2792 * @atomicservice 2793 * @since 12 2794 */ 2795 ignoreLayoutSafeArea(types?: Array<LayoutSafeAreaType>, edges?: Array<LayoutSafeAreaEdge>): NavigationAttribute; 2796 2797 /** 2798 * Set the style of system bar 2799 * 2800 * @param { Optional<SystemBarStyle> } style - The properties of system bar 2801 * @returns { NavigationAttribute } 2802 * @syscap SystemCapability.ArkUI.ArkUI.Full 2803 * @atomicservice 2804 * @since 12 2805 */ 2806 systemBarStyle(style: Optional<SystemBarStyle>): NavigationAttribute; 2807 2808 /** 2809 * Set the Navigation can be restored after the application is terminated. 2810 * To enable this attribute, a navigation id must be set. 2811 * 2812 * @param { boolean } recoverable - navigation can be recovered. 2813 * @returns { NavigationAttribute } Returns the instance of the NavigationAttribute. 2814 * @syscap SystemCapability.ArkUI.ArkUI.Full 2815 * @since 14 2816 */ 2817 recoverable(recoverable: Optional<boolean>): NavigationAttribute; 2818 2819 /** 2820 * Enable dragbar 2821 * 2822 * @param { Optional<boolean> } isEnabled - enable dragbar or disable dragbar. 2823 * @returns { NavigationAttribute } Returns the instance of the NavigationAttribute. 2824 * @syscap SystemCapability.ArkUI.ArkUI.Full 2825 * @crossplatform 2826 * @atomicservice 2827 * @since 14 2828 */ 2829 enableDragBar(isEnabled: Optional<boolean>): NavigationAttribute; 2830 2831 /** 2832 * whether to enable modeChangeAnimation 2833 * 2834 * @param { Optional<boolean> } isEnabled - enableModeChangeAnimation. 2835 * @returns { NavigationAttribute } Returns the instance of the NavigationAttribute. 2836 * @syscap SystemCapability.ArkUI.ArkUI.Full 2837 * @crossplatform 2838 * @atomicservice 2839 * @since 15 2840 */ 2841 enableModeChangeAnimation(isEnabled: Optional<boolean>): NavigationAttribute; 2842} 2843 2844/** 2845* Navigation transition animation protocol. 2846* 2847* @interface NavigationAnimatedTransition 2848* @syscap SystemCapability.ArkUI.ArkUI.Full 2849* @crossplatform 2850* @since 11 2851*/ 2852/** 2853* Navigation transition animation protocol. 2854* 2855* @interface NavigationAnimatedTransition 2856* @syscap SystemCapability.ArkUI.ArkUI.Full 2857* @crossplatform 2858* @atomicservice 2859* @since 12 2860*/ 2861declare interface NavigationAnimatedTransition { 2862 /** 2863 * This method is called after the transition ends to notify whether the transition was successful. 2864 * 2865 * @type { ?function } 2866 * @syscap SystemCapability.ArkUI.ArkUI.Full 2867 * @crossplatform 2868 * @since 11 2869 */ 2870 /** 2871 * This method is called after the transition ends to notify whether the transition was successful. 2872 * 2873 * @type { ?function } 2874 * @syscap SystemCapability.ArkUI.ArkUI.Full 2875 * @crossplatform 2876 * @atomicservice 2877 * @since 12 2878 */ 2879 onTransitionEnd?: (success: boolean) => void 2880 2881 /** 2882 * Define the limit duration of the transition animation. 2883 * 2884 * @type { ?number } 2885 * @syscap SystemCapability.ArkUI.ArkUI.Full 2886 * @crossplatform 2887 * @since 11 2888 */ 2889 /** 2890 * Define the limit duration of the transition animation. 2891 * 2892 * @type { ?number } 2893 * @syscap SystemCapability.ArkUI.ArkUI.Full 2894 * @crossplatform 2895 * @atomicservice 2896 * @since 12 2897 */ 2898 timeout?: number; 2899 2900 /** 2901 * Indicates whether it is an interactive transition. 2902 * 2903 * @type { ?boolean } 2904 * @default false 2905 * @syscap SystemCapability.ArkUI.ArkUI.Full 2906 * @crossplatform 2907 * @atomicservice 2908 * @since 12 2909 */ 2910 isInteractive?: boolean; 2911 2912 /** 2913 * Configure the animations associated with custom transition. 2914 * 2915 * @type { function } 2916 * @syscap SystemCapability.ArkUI.ArkUI.Full 2917 * @crossplatform 2918 * @since 11 2919 */ 2920 /** 2921 * Configure the animations associated with custom transition. 2922 * 2923 * @type { function } 2924 * @syscap SystemCapability.ArkUI.ArkUI.Full 2925 * @crossplatform 2926 * @atomicservice 2927 * @since 12 2928 */ 2929 transition: (transitionProxy: NavigationTransitionProxy) => void 2930} 2931 2932/** 2933 * Navigation transition proxy. 2934 * 2935 * @interface NavigationTransitionProxy 2936 * @syscap SystemCapability.ArkUI.ArkUI.Full 2937 * @crossplatform 2938 * @since 11 2939 */ 2940/** 2941 * Navigation transition proxy. 2942 * 2943 * @interface NavigationTransitionProxy 2944 * @syscap SystemCapability.ArkUI.ArkUI.Full 2945 * @crossplatform 2946 * @atomicservice 2947 * @since 12 2948 */ 2949declare interface NavigationTransitionProxy { 2950 /** 2951 * From navigation content info. 2952 * 2953 * @type { NavContentInfo } 2954 * @syscap SystemCapability.ArkUI.ArkUI.Full 2955 * @crossplatform 2956 * @since 11 2957 */ 2958 /** 2959 * From navigation content info. 2960 * 2961 * @type { NavContentInfo } 2962 * @syscap SystemCapability.ArkUI.ArkUI.Full 2963 * @crossplatform 2964 * @atomicservice 2965 * @since 12 2966 */ 2967 from: NavContentInfo; 2968 2969 /** 2970 * To navigation content info. 2971 * 2972 * @type { NavContentInfo } 2973 * @syscap SystemCapability.ArkUI.ArkUI.Full 2974 * @crossplatform 2975 * @since 11 2976 */ 2977 /** 2978 * To navigation content info. 2979 * 2980 * @type { NavContentInfo } 2981 * @syscap SystemCapability.ArkUI.ArkUI.Full 2982 * @crossplatform 2983 * @atomicservice 2984 * @since 12 2985 */ 2986 to: NavContentInfo; 2987 2988 /** 2989 * Indicates whether it is an interactive transition. 2990 * 2991 * @type { ?boolean } 2992 * @default false 2993 * @syscap SystemCapability.ArkUI.ArkUI.Full 2994 * @crossplatform 2995 * @atomicservice 2996 * @since 12 2997 */ 2998 isInteractive?: boolean; 2999 3000 /** 3001 * Notification system transition animation completed. 3002 * 3003 * @syscap SystemCapability.ArkUI.ArkUI.Full 3004 * @crossplatform 3005 * @since 11 3006 */ 3007 /** 3008 * Notification system transition animation completed. 3009 * 3010 * @syscap SystemCapability.ArkUI.ArkUI.Full 3011 * @crossplatform 3012 * @atomicservice 3013 * @since 12 3014 */ 3015 finishTransition(): void; 3016 3017 /** 3018 * Notification system transition animation canceled. 3019 * 3020 * @syscap SystemCapability.ArkUI.ArkUI.Full 3021 * @crossplatform 3022 * @atomicservice 3023 * @since 12 3024 */ 3025 cancelTransition?(): void; 3026 3027 /** 3028 * Notification system transition animation update. 3029 * 3030 * @param { number } progress - The progress of transition animation. 3031 * @syscap SystemCapability.ArkUI.ArkUI.Full 3032 * @crossplatform 3033 * @atomicservice 3034 * @since 12 3035 */ 3036 updateTransition?(progress: number): void; 3037} 3038 3039/** 3040 * Navigation content info. 3041 * 3042 * @interface NavContentInfo 3043 * @syscap SystemCapability.ArkUI.ArkUI.Full 3044 * @crossplatform 3045 * @since 11 3046 */ 3047/** 3048 * Navigation content info. 3049 * 3050 * @interface NavContentInfo 3051 * @syscap SystemCapability.ArkUI.ArkUI.Full 3052 * @crossplatform 3053 * @atomicservice 3054 * @since 12 3055 */ 3056declare interface NavContentInfo { 3057 /** 3058 * Navigation content name. 3059 * 3060 * @type { ?string } 3061 * @syscap SystemCapability.ArkUI.ArkUI.Full 3062 * @crossplatform 3063 * @since 11 3064 */ 3065 /** 3066 * Navigation content name. 3067 * 3068 * @type { ?string } 3069 * @syscap SystemCapability.ArkUI.ArkUI.Full 3070 * @crossplatform 3071 * @atomicservice 3072 * @since 12 3073 */ 3074 name?: string; 3075 3076 /** 3077 * Navigation content index. 3078 * 3079 * @type { number } 3080 * @syscap SystemCapability.ArkUI.ArkUI.Full 3081 * @crossplatform 3082 * @since 11 3083 */ 3084 /** 3085 * Navigation content index. 3086 * 3087 * @type { number } 3088 * @syscap SystemCapability.ArkUI.ArkUI.Full 3089 * @crossplatform 3090 * @atomicservice 3091 * @since 12 3092 */ 3093 index: number; 3094 3095 /** 3096 * Navigation content mode. 3097 * 3098 * @type { ?NavDestinationMode } 3099 * @syscap SystemCapability.ArkUI.ArkUI.Full 3100 * @crossplatform 3101 * @since 11 3102 */ 3103 /** 3104 * Navigation content mode. 3105 * 3106 * @type { ?NavDestinationMode } 3107 * @syscap SystemCapability.ArkUI.ArkUI.Full 3108 * @crossplatform 3109 * @atomicservice 3110 * @since 12 3111 */ 3112 mode?: NavDestinationMode; 3113 3114 /** 3115 * Navigation content param. 3116 * 3117 * @type { ?Object } 3118 * @syscap SystemCapability.ArkUI.ArkUI.Full 3119 * @crossplatform 3120 * @atomicservice 3121 * @since 12 3122 */ 3123 param?: Object; 3124 3125 /** 3126 * The unique id of NavDestination. 3127 * 3128 * @type { ?string } 3129 * @syscap SystemCapability.ArkUI.ArkUI.Full 3130 * @crossplatform 3131 * @atomicservice 3132 * @since 12 3133 */ 3134 navDestinationId?: string; 3135} 3136 3137/** 3138 * Defines Navigation Component. 3139 * 3140 * @syscap SystemCapability.ArkUI.ArkUI.Full 3141 * @since 8 3142 */ 3143/** 3144 * Defines Navigation Component. 3145 * 3146 * @syscap SystemCapability.ArkUI.ArkUI.Full 3147 * @crossplatform 3148 * @since 10 3149 */ 3150/** 3151 * Defines Navigation Component. 3152 * 3153 * @syscap SystemCapability.ArkUI.ArkUI.Full 3154 * @crossplatform 3155 * @atomicservice 3156 * @since 11 3157 */ 3158declare const Navigation: NavigationInterface; 3159 3160/** 3161 * Defines Navigation Component instance. 3162 * 3163 * @syscap SystemCapability.ArkUI.ArkUI.Full 3164 * @since 8 3165 */ 3166/** 3167 * Defines Navigation Component instance. 3168 * 3169 * @syscap SystemCapability.ArkUI.ArkUI.Full 3170 * @crossplatform 3171 * @since 10 3172 */ 3173/** 3174 * Defines Navigation Component instance. 3175 * 3176 * @syscap SystemCapability.ArkUI.ArkUI.Full 3177 * @crossplatform 3178 * @atomicservice 3179 * @since 11 3180 */ 3181declare const NavigationInstance: NavigationAttribute; 3182