From a923f344e19d1bbddb76304286e9a640138d04bc Mon Sep 17 00:00:00 2001 From: Michael Ikemann Date: Sat, 6 Apr 2024 10:52:37 +0200 Subject: [PATCH] Bug fix: Reference to __singlePageContent in page_layout --- nicegui/page_layout.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nicegui/page_layout.py b/nicegui/page_layout.py index e2bbd5021..dab4519f3 100644 --- a/nicegui/page_layout.py +++ b/nicegui/page_layout.py @@ -272,7 +272,7 @@ def __init__(self, position: PageStickyPositions = 'bottom-right', x_offset: flo def _check_current_slot(element: Element) -> None: parent = context.get_slot().parent - if parent != parent.client.content and parent != parent.client.state.get("__singlePageContent", None): + if parent != parent.client.content and parent != parent.client.single_page_content: log.warning(f'Found top level layout element "{element.__class__.__name__}" inside element "{parent.__class__.__name__}". ' 'Top level layout elements should not be nested but must be direct children of the page content. ' 'This will be raising an exception in NiceGUI 1.5') # DEPRECATED