georad commited on
Commit
1ddeab8
·
verified ·
1 Parent(s): 2cad6a8

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -5
app.py CHANGED
@@ -5,12 +5,11 @@ HEADER_HEIGHT = "60px" # EXAMPLE: Adjust this (e.g., "56px", "4rem")
5
  HEADER_SELECTOR = 'header[data-testid="stHeader"]'
6
 
7
  # ---- SELECTOR FOR THE MAIN CONTENT AREA THAT NEEDS PADDING ----
 
8
  #MAIN_CONTENT_SELECTOR = 'section[data-testid="stMain"]'
9
  #MAIN_CONTENT_SELECTOR = 'section[data-testid="stMain"] > div:nth-child(1)'
10
- MAIN_CONTENT_SELECTOR = 'section[data-testid="stMainBlockContainer"]'
11
- #MAIN_CONTENT_SELECTOR = 'section[data-testid="stAppViewContainer"]'
12
- # This targets the first direct div child of the stAppViewContainer,
13
- # which often holds the main scrollable content.
14
  #MAIN_CONTENT_SELECTOR = 'section[data-testid="stAppViewContainer"] > div:nth-child(1)'
15
  # Alternative if the above doesn't work or if your content is further nested:
16
  #MAIN_CONTENT_SELECTOR = 'section[data-testid="stAppViewContainer"] .main-content-wrapper-class'
@@ -36,7 +35,7 @@ custom_css = f"""
36
 
37
  /* Adding padding to the main content area to prevent overlap with the sticky header */
38
  {MAIN_CONTENT_SELECTOR} {{
39
- padding-top: 20px /* {HEADER_HEIGHT} !important; */
40
  background-color: yellow !important;
41
  #border-style: solid !important;
42
  #border-color: red !important;
 
5
  HEADER_SELECTOR = 'header[data-testid="stHeader"]'
6
 
7
  # ---- SELECTOR FOR THE MAIN CONTENT AREA THAT NEEDS PADDING ----
8
+ # Target the first direct div child of the stAppViewContainer which often holds the main scrollable content
9
  #MAIN_CONTENT_SELECTOR = 'section[data-testid="stMain"]'
10
  #MAIN_CONTENT_SELECTOR = 'section[data-testid="stMain"] > div:nth-child(1)'
11
+ #MAIN_CONTENT_SELECTOR = 'section[data-testid="stMainBlockContainer"]'
12
+ MAIN_CONTENT_SELECTOR = 'section[data-testid="stAppViewContainer"]'
 
 
13
  #MAIN_CONTENT_SELECTOR = 'section[data-testid="stAppViewContainer"] > div:nth-child(1)'
14
  # Alternative if the above doesn't work or if your content is further nested:
15
  #MAIN_CONTENT_SELECTOR = 'section[data-testid="stAppViewContainer"] .main-content-wrapper-class'
 
35
 
36
  /* Adding padding to the main content area to prevent overlap with the sticky header */
37
  {MAIN_CONTENT_SELECTOR} {{
38
+ padding-top: 15px /* {HEADER_HEIGHT} !important; */
39
  background-color: yellow !important;
40
  #border-style: solid !important;
41
  #border-color: red !important;