|
1 | 1 | #MainMenu {visibility: hidden;} |
2 | 2 | footer {visibility: hidden;} |
3 | 3 | header {visibility: hidden;} |
4 | | -[data-testid="baseButton-secondary"] svg{display: none;} |
5 | 4 | [data-testid="stPopoverBody"] button{float: right;} |
6 | | -[data-testid="stSidebar"] {z-index: 999;} |
| 5 | +[data-testid="stSidebar"] { |
| 6 | + z-index: 999; |
| 7 | + position: relative !important; |
| 8 | +} |
| 9 | +/* Ensure sidebar is always visible and accessible */ |
| 10 | +[data-testid="stSidebar"] > div { |
| 11 | + position: relative !important; |
| 12 | + width: auto !important; |
| 13 | + max-width: none !important; |
| 14 | +} |
| 15 | +/* Allow sidebar toggle button SVG to be visible */ |
| 16 | +[data-testid="stSidebar"] [data-testid="baseButton-secondary"] svg { |
| 17 | + display: block !important; |
| 18 | +} |
| 19 | +/* Ensure all sidebar buttons and icons are visible */ |
| 20 | +[data-testid="stSidebar"] button svg { |
| 21 | + display: block !important; |
| 22 | +} |
| 23 | +[data-testid="collapsedControl"] svg { |
| 24 | + display: block !important; |
| 25 | +} |
| 26 | +/* Additional selectors for sidebar toggle button */ |
| 27 | +.css-1d391kg svg, .css-1v0mbdj svg { |
| 28 | + display: block !important; |
| 29 | +} |
| 30 | +/* General sidebar control visibility */ |
| 31 | +[data-testid="stSidebarNav"] svg, |
| 32 | +[data-testid="stSidebarNavItems"] svg, |
| 33 | +button[kind="headerNoPadding"] svg { |
| 34 | + display: block !important; |
| 35 | +} |
| 36 | +/* Ensure sidebar toggle button is always visible even at full width */ |
| 37 | +.stApp > header [data-testid="stToolbar"] button { |
| 38 | + display: flex !important; |
| 39 | + visibility: visible !important; |
| 40 | + opacity: 1 !important; |
| 41 | +} |
| 42 | +.stApp > header [data-testid="stToolbar"] button svg { |
| 43 | + display: block !important; |
| 44 | +} |
| 45 | +/* Force visibility of sidebar toggle in main header */ |
| 46 | +header[data-testid="stHeader"] button { |
| 47 | + display: flex !important; |
| 48 | + visibility: visible !important; |
| 49 | +} |
| 50 | +header[data-testid="stHeader"] button svg { |
| 51 | + display: block !important; |
| 52 | +} |
| 53 | +/* Ensure sidebar toggle is accessible when sidebar is full width */ |
| 54 | +[data-testid="stSidebar"].css-1d391kg, |
| 55 | +[data-testid="stSidebar"][style*="width: 100%"] { |
| 56 | + position: relative !important; |
| 57 | +} |
| 58 | +[data-testid="stSidebar"].css-1d391kg [data-testid="baseButton-secondary"], |
| 59 | +[data-testid="stSidebar"][style*="width: 100%"] [data-testid="baseButton-secondary"] { |
| 60 | + position: absolute !important; |
| 61 | + top: 0.5rem !important; |
| 62 | + right: 0.5rem !important; |
| 63 | + z-index: 1000 !important; |
| 64 | + display: flex !important; |
| 65 | + visibility: visible !important; |
| 66 | +} |
7 | 67 | [data-testid="stPopoverBody"] .stTooltipIcon [data-testid="baseButton-secondary"] p{ |
8 | 68 | font-weight: bold; |
9 | 69 | } |
@@ -32,4 +92,69 @@ header {visibility: hidden;} |
32 | 92 | .st-emotion-cache-1kyxreq{ |
33 | 93 | max-width: 200px !important; |
34 | 94 | } |
| 95 | + /* Ensure sidebar toggle is visible on smaller screens */ |
| 96 | + [data-testid="stSidebar"] [data-testid="baseButton-secondary"] { |
| 97 | + position: fixed !important; |
| 98 | + top: 1rem !important; |
| 99 | + right: 1rem !important; |
| 100 | + z-index: 9999 !important; |
| 101 | + background: white !important; |
| 102 | + border: 1px solid #ccc !important; |
| 103 | + border-radius: 4px !important; |
| 104 | + padding: 4px !important; |
| 105 | + } |
| 106 | +} |
| 107 | +/* Override any width restrictions on sidebar when expanded */ |
| 108 | +.stApp .css-1d391kg { |
| 109 | + min-width: auto !important; |
| 110 | + max-width: 100vw !important; |
| 111 | +} |
| 112 | +/* Ensure main content doesn't push sidebar toggle out of view */ |
| 113 | +.stApp > .css-1d391kg + section { |
| 114 | + position: relative !important; |
| 115 | +} |
| 116 | +.stApp > .css-1d391kg + section::before { |
| 117 | + content: ''; |
| 118 | + position: absolute; |
| 119 | + top: 0.5rem; |
| 120 | + right: 0.5rem; |
| 121 | + z-index: 1001; |
| 122 | + pointer-events: none; |
| 123 | +} |
| 124 | + |
| 125 | +/* Hide Deploy button, main menu, and toolbar - show ONLY the loading spinner */ |
| 126 | +[data-testid="stToolbarActions"], |
| 127 | +[data-testid="stAppDeployButton"], |
| 128 | +[data-testid="stMainMenu"] { |
| 129 | + display: none !important; |
| 130 | +} |
| 131 | + |
| 132 | +/* Ensure ONLY the loading spinner/gif is visible */ |
| 133 | +img[alt="Running..."], |
| 134 | +img[class*="st-emotion-cache"][alt*="Running"], |
| 135 | +.st-emotion-cache-1j15ncu.e14hul0q5 { |
| 136 | + display: block !important; |
| 137 | + visibility: visible !important; |
| 138 | + opacity: 1 !important; |
| 139 | + z-index: 10000 !important; |
| 140 | +} |
| 141 | + |
| 142 | +/* Hide the toolbar section with Deploy button and menu using stable selectors */ |
| 143 | +[data-testid="stToolbarActions"], |
| 144 | +[data-testid="stAppDeployButton"], |
| 145 | +[data-testid="stMainMenu"] { |
| 146 | + display: none !important; |
| 147 | +} |
| 148 | + |
| 149 | +/* Ensure all loading/spinner elements remain visible */ |
| 150 | +[data-testid="stSpinner"], |
| 151 | +.stSpinner, |
| 152 | +[class*="spinner"], |
| 153 | +[class*="loading"], |
| 154 | +[data-testid*="spinner"], |
| 155 | +div[role="status"], |
| 156 | +.st-emotion-cache-*[class*="spinner"] { |
| 157 | + display: block !important; |
| 158 | + visibility: visible !important; |
| 159 | + opacity: 1 !important; |
35 | 160 | } |
0 commit comments