mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2026-03-13 10:22:08 +08:00
refactor(nav, menu): swipeEnabled => swipeGesture
This commit is contained in:
@@ -79,10 +79,10 @@ export class MenuController {
|
||||
* Used to enable or disable the ability to swipe open the menu.
|
||||
*/
|
||||
@Method()
|
||||
swipeEnable(shouldEnable: boolean, menuId?: string): HTMLIonMenuElement | null {
|
||||
swipeGesture(shouldEnable: boolean, menuId?: string): HTMLIonMenuElement | null {
|
||||
const menu = this.get(menuId);
|
||||
if (menu) {
|
||||
menu.swipeEnabled = shouldEnable;
|
||||
menu.swipeGesture = shouldEnable;
|
||||
}
|
||||
return menu;
|
||||
}
|
||||
|
||||
@@ -25,7 +25,7 @@ The MenuController makes it easy to control a Menu. Its methods can be used to d
|
||||
| `isOpen` | Returns true if the specified menu is open. If the menu is not specified, it will return true if any menu is currently open. |
|
||||
| `open` | Open the menu. |
|
||||
| `registerAnimation` | |
|
||||
| `swipeEnable` | Used to enable or disable the ability to swipe open the menu. |
|
||||
| `swipeGesture` | Used to enable or disable the ability to swipe open the menu. |
|
||||
| `toggle` | Toggle the menu. If it's closed, it will open, and if opened, it will close. |
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user