Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -54,11 +54,10 @@ def run_script(url: str, height: int, width: int, check_b,check_h):
|
|
| 54 |
#print (driver.html)
|
| 55 |
driver.implicitly_wait(30)
|
| 56 |
driver.set_window_size(int(width), int(height))
|
| 57 |
-
page = driver.find_element(By.TAG_NAME, "html")
|
| 58 |
-
print (dir(page))
|
| 59 |
print (page.get_attribute('theme'))
|
| 60 |
-
|
| 61 |
-
driver.execute_script("innerHTML='gab-dark';",page)
|
| 62 |
main_head = driver.find_element(By.CLASS_NAME, "main-content-header")
|
| 63 |
head_shot = main_head.screenshot(f'head-{uid}-tmp.png')
|
| 64 |
|
|
|
|
| 54 |
#print (driver.html)
|
| 55 |
driver.implicitly_wait(30)
|
| 56 |
driver.set_window_size(int(width), int(height))
|
| 57 |
+
page = driver.find_element(By.TAG_NAME, "html").setAttribute('theme','gab-black')
|
| 58 |
+
#print (dir(page))
|
| 59 |
print (page.get_attribute('theme'))
|
| 60 |
+
#driver.execute_script("innerHTML='gab-dark';",page)
|
|
|
|
| 61 |
main_head = driver.find_element(By.CLASS_NAME, "main-content-header")
|
| 62 |
head_shot = main_head.screenshot(f'head-{uid}-tmp.png')
|
| 63 |
|