исправлено мерцание бургер меню
This commit is contained in:
		
							parent
							
								
									927ac45ec8
								
							
						
					
					
						commit
						d7067db1d6
					
				@ -69,15 +69,15 @@ struct MainView: View {
 | 
			
		||||
                }
 | 
			
		||||
                
 | 
			
		||||
                // Затемнение и закрытие по тапу
 | 
			
		||||
                if isSideMenuPresented {
 | 
			
		||||
                    Color.black.opacity(0.4 * Double(((menuWidth + menuOffset) / menuWidth)))
 | 
			
		||||
                        .ignoresSafeArea()
 | 
			
		||||
                        .onTapGesture {
 | 
			
		||||
                            withAnimation(.easeInOut) {
 | 
			
		||||
                                isSideMenuPresented = false
 | 
			
		||||
                            }
 | 
			
		||||
                Color.black
 | 
			
		||||
                    .opacity(Double(menuOffset / menuWidth) * 0.4)
 | 
			
		||||
                    .ignoresSafeArea()
 | 
			
		||||
                    .onTapGesture {
 | 
			
		||||
                        withAnimation(.easeInOut) {
 | 
			
		||||
                            isSideMenuPresented = false
 | 
			
		||||
                        }
 | 
			
		||||
                }
 | 
			
		||||
                    }
 | 
			
		||||
                    .allowsHitTesting(menuOffset > 0)
 | 
			
		||||
 | 
			
		||||
                // Боковое меню
 | 
			
		||||
                SideMenuView(isPresented: $isSideMenuPresented)
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user