Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -176,7 +176,12 @@ html, body, .stApp {
|
|
| 176 |
}
|
| 177 |
|
| 178 |
/* بازنشانی پدینگ برای المانهای داخلی خاص */
|
| 179 |
-
[data-testid="stAppViewContainer"] .
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 180 |
padding-right: 0 !important;
|
| 181 |
padding-left: 0 !important;
|
| 182 |
}
|
|
@@ -211,117 +216,107 @@ html, body, .stApp {
|
|
| 211 |
}
|
| 212 |
|
| 213 |
/* ========== استایلهای ورودی یکپارچه ========== */
|
| 214 |
-
/* استایل
|
| 215 |
-
|
| 216 |
-
|
| 217 |
-
|
| 218 |
-
|
| 219 |
-
|
| 220 |
-
.stTimeInput input,
|
| 221 |
-
.stMultiSelect div[role="combobox"],
|
| 222 |
-
div[data-testid="stVerticalBlock"] > div[data-testid="stHorizontalBlock"] > div > div > div > div > input,
|
| 223 |
-
div[data-baseweb="select"] > div:first-child {
|
| 224 |
-
color: var(--text) !important;
|
| 225 |
-
background-color: var(--input-bg) !important;
|
| 226 |
-
border: 1px solid var(--primary) !important;
|
| 227 |
border-radius: 6px !important;
|
| 228 |
-
|
| 229 |
-
|
| 230 |
-
}
|
| 231 |
-
|
| 232 |
-
/* استایل برای حالت hover و focus */
|
| 233 |
-
.stTextInput input:hover,
|
| 234 |
-
.stNumberInput input:hover,
|
| 235 |
-
.stSelectbox select:hover,
|
| 236 |
-
.stTextArea textarea:hover,
|
| 237 |
-
.stDateInput input:hover,
|
| 238 |
-
.stTimeInput input:hover,
|
| 239 |
-
.stMultiSelect div[role="combobox"]:hover,
|
| 240 |
-
.stTextInput input:focus,
|
| 241 |
-
.stNumberInput input:focus,
|
| 242 |
-
.stSelectbox select:focus,
|
| 243 |
-
.stTextArea textarea:focus,
|
| 244 |
-
.stDateInput input:focus,
|
| 245 |
-
.stTimeInput input:focus {
|
| 246 |
-
border-color: var(--primary) !important;
|
| 247 |
-
box-shadow: 0 0 0 3px rgba(106, 13, 173, 0.15) !important;
|
| 248 |
-
outline: none !important;
|
| 249 |
-
}
|
| 250 |
-
|
| 251 |
-
/* استایل لیبلها */
|
| 252 |
-
.stTextInput > label,
|
| 253 |
-
.stNumberInput > label,
|
| 254 |
-
.stSelectbox > label,
|
| 255 |
-
.stRadio > label,
|
| 256 |
-
.stSlider > label {
|
| 257 |
-
color: var(--text) !important;
|
| 258 |
-
font-weight: bold !important;
|
| 259 |
-
margin-bottom: 8px !important;
|
| 260 |
-
font-size: 14px !important;
|
| 261 |
}
|
| 262 |
|
| 263 |
-
/* استایل
|
| 264 |
-
|
|
|
|
|
|
|
| 265 |
color: var(--text) !important;
|
| 266 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 267 |
}
|
| 268 |
|
| 269 |
-
/*
|
| 270 |
div[data-baseweb="select"] > div:first-child {
|
| 271 |
-webkit-appearance: none !important;
|
| 272 |
-moz-appearance: none !important;
|
| 273 |
appearance: none !important;
|
| 274 |
background-image: none !important;
|
|
|
|
| 275 |
}
|
| 276 |
|
| 277 |
-
/*
|
| 278 |
-
div[data-baseweb="select"] > div:first-child::-ms-expand {
|
| 279 |
-
display: none !important;
|
| 280 |
-
}
|
| 281 |
-
|
| 282 |
-
div[data-baseweb="select"] {
|
| 283 |
-
position: relative !important;
|
| 284 |
-
}
|
| 285 |
-
|
| 286 |
div[data-baseweb="select"]::after {
|
| 287 |
content: "▼";
|
| 288 |
position: absolute;
|
| 289 |
-
left:
|
| 290 |
top: 50%;
|
| 291 |
transform: translateY(-50%);
|
| 292 |
-
color: var(--primary);
|
| 293 |
-
|
| 294 |
-
font-size: 14px;
|
| 295 |
pointer-events: none;
|
| 296 |
}
|
| 297 |
-
|
| 298 |
|
| 299 |
-
/*
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 300 |
|
| 301 |
-
/* آیتمهای
|
| 302 |
div[data-baseweb="popover"] [role="option"] {
|
| 303 |
color: var(--text) !important;
|
| 304 |
background-color: white !important;
|
| 305 |
-
|
|
|
|
|
|
|
| 306 |
}
|
| 307 |
|
| 308 |
-
/* آیتم انتخاب شده */
|
| 309 |
div[data-baseweb="popover"] [role="option"][aria-selected="true"] {
|
| 310 |
background-color: #f0e6ff !important;
|
| 311 |
-
color: black !important;
|
| 312 |
}
|
| 313 |
|
| 314 |
-
/*
|
| 315 |
-
|
| 316 |
-
|
| 317 |
-
|
| 318 |
-
border:
|
| 319 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 320 |
font-weight: bold !important;
|
|
|
|
|
|
|
|
|
|
| 321 |
}
|
| 322 |
|
| 323 |
-
|
| 324 |
-
|
|
|
|
|
|
|
|
|
|
| 325 |
}
|
| 326 |
|
| 327 |
|
|
|
|
| 176 |
}
|
| 177 |
|
| 178 |
/* بازنشانی پدینگ برای المانهای داخلی خاص */
|
| 179 |
+
[data-testid="stAppViewContainer"] .stTextInput>div,
|
| 180 |
+
[data-testid="stAppViewContainer"] .stNumberInput>div,
|
| 181 |
+
[data-testid="stAppViewContainer"] .stSelectbox>div,
|
| 182 |
+
[data-testid="stAppViewContainer"] .stTextArea>div,
|
| 183 |
+
[data-testid="stAppViewContainer"] .stDateInput>div,
|
| 184 |
+
[data-testid="stAppViewContainer"] .stTimeInput>div {
|
| 185 |
padding-right: 0 !important;
|
| 186 |
padding-left: 0 !important;
|
| 187 |
}
|
|
|
|
| 216 |
}
|
| 217 |
|
| 218 |
/* ========== استایلهای ورودی یکپارچه ========== */
|
| 219 |
+
/* ========== استایلهای ورودی یکپارچه ========== */
|
| 220 |
+
/* استایل پایه برای تمام کانتینرهای ورودی */
|
| 221 |
+
div[data-baseweb="select"] > div:first-child,
|
| 222 |
+
div[data-baseweb="input"] > div:first-child,
|
| 223 |
+
div[data-baseweb="textarea"] > div:first-child {
|
| 224 |
+
padding: 0 !important;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 225 |
border-radius: 6px !important;
|
| 226 |
+
border: 1px solid var(--primary) !important;
|
| 227 |
+
background-color: var(--input-bg) !important;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 228 |
}
|
| 229 |
|
| 230 |
+
/* استایل داخلی برای المانهای ورودی */
|
| 231 |
+
div[data-baseweb="select"] input,
|
| 232 |
+
div[data-baseweb="input"] input,
|
| 233 |
+
div[data-baseweb="textarea"] textarea {
|
| 234 |
color: var(--text) !important;
|
| 235 |
+
background-color: transparent !important;
|
| 236 |
+
border: none !important;
|
| 237 |
+
padding: 10px 12px !important;
|
| 238 |
+
min-height: 40px !important;
|
| 239 |
+
font-family: 'B Nazanin' !important;
|
| 240 |
+
direction: rtl !important;
|
| 241 |
}
|
| 242 |
|
| 243 |
+
/* استایل خاص برای سلکت باکس */
|
| 244 |
div[data-baseweb="select"] > div:first-child {
|
| 245 |
-webkit-appearance: none !important;
|
| 246 |
-moz-appearance: none !important;
|
| 247 |
appearance: none !important;
|
| 248 |
background-image: none !important;
|
| 249 |
+
padding-right: 30px !important; /* فضای برای فلش */
|
| 250 |
}
|
| 251 |
|
| 252 |
+
/* فلش سفارشی برای سلکت باکس */
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 253 |
div[data-baseweb="select"]::after {
|
| 254 |
content: "▼";
|
| 255 |
position: absolute;
|
| 256 |
+
left: 12px !important;
|
| 257 |
top: 50%;
|
| 258 |
transform: translateY(-50%);
|
| 259 |
+
color: var(--primary) !important;
|
| 260 |
+
font-size: 12px !important;
|
|
|
|
| 261 |
pointer-events: none;
|
| 262 |
}
|
|
|
|
| 263 |
|
| 264 |
+
/* استایل dropdown */
|
| 265 |
+
div[data-baseweb="popover"] {
|
| 266 |
+
border: 1px solid var(--primary) !important;
|
| 267 |
+
border-radius: 6px !important;
|
| 268 |
+
box-shadow: 0 2px 8px rgba(0,0,0,0.1) !important;
|
| 269 |
+
}
|
| 270 |
|
| 271 |
+
/* آیتمهای dropdown */
|
| 272 |
div[data-baseweb="popover"] [role="option"] {
|
| 273 |
color: var(--text) !important;
|
| 274 |
background-color: white !important;
|
| 275 |
+
padding: 10px 12px !important;
|
| 276 |
+
font-family: 'B Nazanin' !important;
|
| 277 |
+
direction: rtl !important;
|
| 278 |
}
|
| 279 |
|
| 280 |
+
/* آیتم انتخاب شده در dropdown */
|
| 281 |
div[data-baseweb="popover"] [role="option"][aria-selected="true"] {
|
| 282 |
background-color: #f0e6ff !important;
|
|
|
|
| 283 |
}
|
| 284 |
|
| 285 |
+
/* استایل hover برای تمام المانهای ورودی */
|
| 286 |
+
div[data-baseweb="select"] > div:first-child:hover,
|
| 287 |
+
div[data-baseweb="input"] > div:first-child:hover,
|
| 288 |
+
div[data-baseweb="textarea"] > div:first-child:hover {
|
| 289 |
+
border-color: var(--primary) !important;
|
| 290 |
+
box-shadow: 0 0 0 3px rgba(106, 13, 173, 0.15) !important;
|
| 291 |
+
}
|
| 292 |
+
|
| 293 |
+
/* استایل focus */
|
| 294 |
+
div[data-baseweb="select"] > div:first-child:focus-within,
|
| 295 |
+
div[data-baseweb="input"] > div:first-child:focus-within,
|
| 296 |
+
div[data-baseweb="textarea"] > div:first-child:focus-within {
|
| 297 |
+
border-color: var(--primary) !important;
|
| 298 |
+
box-shadow: 0 0 0 3px rgba(106, 13, 173, 0.15) !important;
|
| 299 |
+
outline: none !important;
|
| 300 |
+
}
|
| 301 |
+
|
| 302 |
+
/* استایل لیبلها */
|
| 303 |
+
.stTextInput > label,
|
| 304 |
+
.stNumberInput > label,
|
| 305 |
+
.stSelectbox > label,
|
| 306 |
+
.stRadio > label,
|
| 307 |
+
.stSlider > label {
|
| 308 |
+
color: var(--text) !important;
|
| 309 |
font-weight: bold !important;
|
| 310 |
+
margin-bottom: 8px !important;
|
| 311 |
+
font-size: 14px !important;
|
| 312 |
+
display: block !important;
|
| 313 |
}
|
| 314 |
|
| 315 |
+
/* استایل placeholder */
|
| 316 |
+
::placeholder {
|
| 317 |
+
color: var(--text) !important;
|
| 318 |
+
opacity: 0.5 !important;
|
| 319 |
+
font-family: 'B Nazanin' !important;
|
| 320 |
}
|
| 321 |
|
| 322 |
|