Показать сообщение отдельно

  #5  
Старый 15.11.2022, 16:37
Sep
Новичок
Регистрация: 29.05.2010
Сообщений: 0
С нами: 8397612

Репутация: 0
По умолчанию

Цитата:
Сообщение от im0rg  

JavaScript:





Код:
// ==UserScript==
// @name        lip-monopoly-one
// @namespace    http://tampermonkey.net/
// @version      0.1
// @description  try to take over the world!
// @author       lip
// @match        https://monopoly-one.com/*
// @icon         data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==
// @grant        none
// ==/UserScript==
'use strict'
;
// Your code here...
document
.
getElementsByClassName
(
"_img"
)
[
0
]
.
style
.
backgroundImage
=
"url('https://i.imgur.com/su4kW3N.png')"
;
//
document
.
getElementsByClassName
(
"profile-top-info-main-nick"
)
[
0
]
.
style
.
color
=
'#00ff00'
;
document
.
getElementsByClassName
(
"title title-3"
)
[
0
]
.
style
.
color
=
'ff0000'
;
document
.
getElementsByClassName
(
"profile-body-level-info-rank"
)
[
0
]
.
style
.
color
=
'#ff0000'
;
document
.
getElementsByClassName
(
"profile-top-stat"
)
[
0
]
.
style
.
color
=
'#ffffff'
;
//
//document.getElementsByClassName("profile-body-level-info-progress").getElementsByTagName('div').style.background='#00ff00';
//
var
element
=
document
.
getElementsByClassName
(
"profile-body-level-info-progress"
)
.
item
(
0
)
.
getElementsByTagName
(
'div'
)
.
item
(
0
)
;
element
.
style
.
background
=
"#00ff00"
;

спасибо работает но как пофиксить баг что работает только после f5 (обновление страницы)
 
Ответить с цитированием