0

I want to have a menu slide in from the right and everything is working correctly except it slides all the way to the left side of the screen. That is, there should be some distance between the left side of the screen and the edge of the menu, but the distance is 0.

Here's my configuration:

let rightSideMenu = NavigationUtility.viewController(NavigationConstants.kSlideMenuNavigationController) as? UISideMenuNavigationController
rightSideMenu?.sideMenuManager.menuPresentMode = .menuSlideIn
rightSideMenu?.navigationController?.setNavigationBarHidden(true, animated: false)
rightSideMenu?.menuWidth = 320
rightSideMenu?.sideMenuManager.menuWidth = 320
rightSideMenu?.sideMenuManager.menuShadowRadius = 30
rightSideMenu?.sideMenuManager.menuShadowOpacity = 0.5
rightSideMenu?.sideMenuManager.menuShadowColor = Colors.menuShadowColor

SideMenuManager.default.menuRightNavigationController = rightSideMenu
if let navBar = self.navigationController?.navigationBar {
    SideMenuManager.default.menuAddPanGestureToPresent(toView: navBar)
}
if let navView = self.navigationController?.view {
    SideMenuManager.default.menuAddScreenEdgePanGesturesToPresent(toView: navView)
}

How can I make it slide in just the distance of 320 that I set the width to?

Adam Zarn
  • 1,868
  • 1
  • 16
  • 42

1 Answers1

0

I think the issue was related to working with an outdated version of SideMenu. Once I ran a pod update it began working as expected.

Adam Zarn
  • 1,868
  • 1
  • 16
  • 42