Progress Knight Dynamic Layout

Fixes UI to be dynamic - its not perfect, but it is better than nothing

Aby zainstalować ten skrypt, wymagana jest instalacje jednego z następujących rozszerzeń: Tampermonkey, Greasemonkey lub Violentmonkey.

Aby zainstalować ten skrypt, wymagana jest instalacje jednego z następujących rozszerzeń: Tampermonkey, Violentmonkey.

Aby zainstalować ten skrypt, wymagana jest instalacje jednego z następujących rozszerzeń: Tampermonkey, Violentmonkey.

Aby zainstalować ten skrypt, wymagana będzie instalacja rozszerzenia Tampermonkey lub Userscripts.

You will need to install an extension such as Tampermonkey to install this script.

Aby zainstalować ten skrypt, musisz zainstalować rozszerzenie menedżera skryptów użytkownika.

(Mam już menedżera skryptów użytkownika, pozwól mi to zainstalować!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

Będziesz musiał zainstalować rozszerzenie menedżera stylów użytkownika, aby zainstalować ten styl.

Będziesz musiał zainstalować rozszerzenie menedżera stylów użytkownika, aby zainstalować ten styl.

Musisz zainstalować rozszerzenie menedżera stylów użytkownika, aby zainstalować ten styl.

(Mam już menedżera stylów użytkownika, pozwól mi to zainstalować!)

// ==UserScript==
// @name         Progress Knight Dynamic Layout
// @namespace    https://ihtasham42.github.io/progress-knight/
// @version      1.0.1
// @description  Fixes UI to be dynamic - its not perfect, but it is better than nothing
// @author       CitizenStile <[email protected]>
// @match        *://ihtasham42.github.io/progress-knight/*
// @grant        none
// @run-at       document-idle
// ==/UserScript==

function getElementByXpath(path) {
  return document.evaluate(path, document, null, XPathResult.FIRST_ORDERED_NODE_TYPE, null).singleNodeValue;
}

var elemParent = getElementByXpath("/html/body/div/div")
//   parentHeight.style.height = 'auto'
//   parentHeight.style.width = 'auto'
var elemMenu = getElementByXpath("/html/body/div/div/div[2]")
elemMenu.style.width = 'auto'
var elemBody = getElementByXpath("/html/body/div/div/div[3]")
elemBody.style.width = 'auto'
elemBody.style.height = 'auto'