diff --git a/.gitattributes b/.gitattributes index 6bb259b89..c5963b07d 100644 --- a/.gitattributes +++ b/.gitattributes @@ -13,6 +13,7 @@ /composer.lock export-ignore /CONTRIBUTING.md export-ignore /init_phar.php export-ignore +/jsconfig.json export-ignore /package-lock.json export-ignore /package.json export-ignore /phpunit.xml export-ignore diff --git a/build/kint.phar b/build/kint.phar index b3f6bd114..f00e817e3 100644 Binary files a/build/kint.phar and b/build/kint.phar differ diff --git a/jsconfig.json b/jsconfig.json new file mode 100644 index 000000000..94e2e52f6 --- /dev/null +++ b/jsconfig.json @@ -0,0 +1,5 @@ +{ + "compilerOptions": { + "alwaysStrict": true + } +} diff --git a/package-lock.json b/package-lock.json index 195c790c1..2f7967eff 100644 --- a/package-lock.json +++ b/package-lock.json @@ -7,11 +7,396 @@ "name": "kint", "license": "MIT", "devDependencies": { + "esbuild": "^0.23.1", "prettier": "^3", "sass": "^1", "uglify-js": "^3" } }, + "node_modules/@esbuild/aix-ppc64": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.23.1.tgz", + "integrity": "sha512-6VhYk1diRqrhBAqpJEdjASR/+WVRtfjpqKuNw11cLiaWpAT/Uu+nokB+UJnevzy/P9C/ty6AOe0dwueMrGh/iQ==", + "cpu": [ + "ppc64" + ], + "dev": true, + "optional": true, + "os": [ + "aix" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/android-arm": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.23.1.tgz", + "integrity": "sha512-uz6/tEy2IFm9RYOyvKl88zdzZfwEfKZmnX9Cj1BHjeSGNuGLuMD1kR8y5bteYmwqKm1tj8m4cb/aKEorr6fHWQ==", + "cpu": [ + "arm" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/android-arm64": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.23.1.tgz", + "integrity": "sha512-xw50ipykXcLstLeWH7WRdQuysJqejuAGPd30vd1i5zSyKK3WE+ijzHmLKxdiCMtH1pHz78rOg0BKSYOSB/2Khw==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/android-x64": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.23.1.tgz", + "integrity": "sha512-nlN9B69St9BwUoB+jkyU090bru8L0NA3yFvAd7k8dNsVH8bi9a8cUAUSEcEEgTp2z3dbEDGJGfP6VUnkQnlReg==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/darwin-arm64": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.23.1.tgz", + "integrity": "sha512-YsS2e3Wtgnw7Wq53XXBLcV6JhRsEq8hkfg91ESVadIrzr9wO6jJDMZnCQbHm1Guc5t/CdDiFSSfWP58FNuvT3Q==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/darwin-x64": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.23.1.tgz", + "integrity": "sha512-aClqdgTDVPSEGgoCS8QDG37Gu8yc9lTHNAQlsztQ6ENetKEO//b8y31MMu2ZaPbn4kVsIABzVLXYLhCGekGDqw==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/freebsd-arm64": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.23.1.tgz", + "integrity": "sha512-h1k6yS8/pN/NHlMl5+v4XPfikhJulk4G+tKGFIOwURBSFzE8bixw1ebjluLOjfwtLqY0kewfjLSrO6tN2MgIhA==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/freebsd-x64": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.23.1.tgz", + "integrity": "sha512-lK1eJeyk1ZX8UklqFd/3A60UuZ/6UVfGT2LuGo3Wp4/z7eRTRYY+0xOu2kpClP+vMTi9wKOfXi2vjUpO1Ro76g==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-arm": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.23.1.tgz", + "integrity": "sha512-CXXkzgn+dXAPs3WBwE+Kvnrf4WECwBdfjfeYHpMeVxWE0EceB6vhWGShs6wi0IYEqMSIzdOF1XjQ/Mkm5d7ZdQ==", + "cpu": [ + "arm" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-arm64": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.23.1.tgz", + "integrity": "sha512-/93bf2yxencYDnItMYV/v116zff6UyTjo4EtEQjUBeGiVpMmffDNUyD9UN2zV+V3LRV3/on4xdZ26NKzn6754g==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-ia32": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.23.1.tgz", + "integrity": "sha512-VTN4EuOHwXEkXzX5nTvVY4s7E/Krz7COC8xkftbbKRYAl96vPiUssGkeMELQMOnLOJ8k3BY1+ZY52tttZnHcXQ==", + "cpu": [ + "ia32" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-loong64": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.23.1.tgz", + "integrity": "sha512-Vx09LzEoBa5zDnieH8LSMRToj7ir/Jeq0Gu6qJ/1GcBq9GkfoEAoXvLiW1U9J1qE/Y/Oyaq33w5p2ZWrNNHNEw==", + "cpu": [ + "loong64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-mips64el": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.23.1.tgz", + "integrity": "sha512-nrFzzMQ7W4WRLNUOU5dlWAqa6yVeI0P78WKGUo7lg2HShq/yx+UYkeNSE0SSfSure0SqgnsxPvmAUu/vu0E+3Q==", + "cpu": [ + "mips64el" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-ppc64": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.23.1.tgz", + "integrity": "sha512-dKN8fgVqd0vUIjxuJI6P/9SSSe/mB9rvA98CSH2sJnlZ/OCZWO1DJvxj8jvKTfYUdGfcq2dDxoKaC6bHuTlgcw==", + "cpu": [ + "ppc64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-riscv64": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.23.1.tgz", + "integrity": "sha512-5AV4Pzp80fhHL83JM6LoA6pTQVWgB1HovMBsLQ9OZWLDqVY8MVobBXNSmAJi//Csh6tcY7e7Lny2Hg1tElMjIA==", + "cpu": [ + "riscv64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-s390x": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.23.1.tgz", + "integrity": "sha512-9ygs73tuFCe6f6m/Tb+9LtYxWR4c9yg7zjt2cYkjDbDpV/xVn+68cQxMXCjUpYwEkze2RcU/rMnfIXNRFmSoDw==", + "cpu": [ + "s390x" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-x64": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.23.1.tgz", + "integrity": "sha512-EV6+ovTsEXCPAp58g2dD68LxoP/wK5pRvgy0J/HxPGB009omFPv3Yet0HiaqvrIrgPTBuC6wCH1LTOY91EO5hQ==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/netbsd-x64": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.23.1.tgz", + "integrity": "sha512-aevEkCNu7KlPRpYLjwmdcuNz6bDFiE7Z8XC4CPqExjTvrHugh28QzUXVOZtiYghciKUacNktqxdpymplil1beA==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "netbsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/openbsd-arm64": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-arm64/-/openbsd-arm64-0.23.1.tgz", + "integrity": "sha512-3x37szhLexNA4bXhLrCC/LImN/YtWis6WXr1VESlfVtVeoFJBRINPJ3f0a/6LV8zpikqoUg4hyXw0sFBt5Cr+Q==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "openbsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/openbsd-x64": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.23.1.tgz", + "integrity": "sha512-aY2gMmKmPhxfU+0EdnN+XNtGbjfQgwZj43k8G3fyrDM/UdZww6xrWxmDkuz2eCZchqVeABjV5BpildOrUbBTqA==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "openbsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/sunos-x64": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.23.1.tgz", + "integrity": "sha512-RBRT2gqEl0IKQABT4XTj78tpk9v7ehp+mazn2HbUeZl1YMdaGAQqhapjGTCe7uw7y0frDi4gS0uHzhvpFuI1sA==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "sunos" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/win32-arm64": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.23.1.tgz", + "integrity": "sha512-4O+gPR5rEBe2FpKOVyiJ7wNDPA8nGzDuJ6gN4okSA1gEOYZ67N8JPk58tkWtdtPeLz7lBnY6I5L3jdsr3S+A6A==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/win32-ia32": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.23.1.tgz", + "integrity": "sha512-BcaL0Vn6QwCwre3Y717nVHZbAa4UBEigzFm6VdsVdT/MbZ38xoj1X9HPkZhbmaBGUD1W8vxAfffbDe8bA6AKnQ==", + "cpu": [ + "ia32" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/win32-x64": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.23.1.tgz", + "integrity": "sha512-BHpFFeslkWrXWyUPnbKm+xYYVYruCinGcftSBaa8zoF9hZO4BcSCFUvHVTtzpIY6YzUnYtuEhZ+C9iEXjxnasg==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=18" + } + }, "node_modules/anymatch": { "version": "3.1.3", "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.3.tgz", @@ -73,6 +458,45 @@ "fsevents": "~2.3.2" } }, + "node_modules/esbuild": { + "version": "0.23.1", + "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.23.1.tgz", + "integrity": "sha512-VVNz/9Sa0bs5SELtn3f7qhJCDPCF5oMEl5cO9/SSinpE9hbPVvxbd572HH5AKiP7WD8INO53GgfDDhRjkylHEg==", + "dev": true, + "hasInstallScript": true, + "bin": { + "esbuild": "bin/esbuild" + }, + "engines": { + "node": ">=18" + }, + "optionalDependencies": { + "@esbuild/aix-ppc64": "0.23.1", + "@esbuild/android-arm": "0.23.1", + "@esbuild/android-arm64": "0.23.1", + "@esbuild/android-x64": "0.23.1", + "@esbuild/darwin-arm64": "0.23.1", + "@esbuild/darwin-x64": "0.23.1", + "@esbuild/freebsd-arm64": "0.23.1", + "@esbuild/freebsd-x64": "0.23.1", + "@esbuild/linux-arm": "0.23.1", + "@esbuild/linux-arm64": "0.23.1", + "@esbuild/linux-ia32": "0.23.1", + "@esbuild/linux-loong64": "0.23.1", + "@esbuild/linux-mips64el": "0.23.1", + "@esbuild/linux-ppc64": "0.23.1", + "@esbuild/linux-riscv64": "0.23.1", + "@esbuild/linux-s390x": "0.23.1", + "@esbuild/linux-x64": "0.23.1", + "@esbuild/netbsd-x64": "0.23.1", + "@esbuild/openbsd-arm64": "0.23.1", + "@esbuild/openbsd-x64": "0.23.1", + "@esbuild/sunos-x64": "0.23.1", + "@esbuild/win32-arm64": "0.23.1", + "@esbuild/win32-ia32": "0.23.1", + "@esbuild/win32-x64": "0.23.1" + } + }, "node_modules/fill-range": { "version": "7.1.1", "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.1.1.tgz", diff --git a/package.json b/package.json index d25281b26..19bd8a999 100644 --- a/package.json +++ b/package.json @@ -11,17 +11,14 @@ "license": "MIT", "private": true, "devDependencies": { - "sass": "^1", + "esbuild": "^0.23.1", "prettier": "^3", - "uglify-js": "^3" + "sass": "^1" }, "scripts": { "format:js": "prettier --write resources/js/**", - "build:js": "npm run build:js:shared && npm run build:js:rich && npm run build:js:microtime && npm run build:js:plain", - "build:js:shared": "uglifyjs resources/js/shared.js -cm --verbose --warn > resources/compiled/shared.js", - "build:js:rich": "uglifyjs resources/js/rich.js -cm --verbose --warn > resources/compiled/rich.js", - "build:js:microtime": "uglifyjs resources/js/microtime.js -cm --verbose --warn > resources/compiled/microtime.js", - "build:js:plain": "uglifyjs resources/js/plain.js -cm --verbose --warn > resources/compiled/plain.js", + "build:js": "esbuild resources/js/main.js --bundle --minify --outfile=resources/compiled/main.js", + "build:js:test": "esbuild resources/js/main.js --bundle --outfile=resources/compiled/main.js", "format:sass": "prettier --write resources/sass/**", "build:sass": "sass -s compressed --no-source-map resources/sass/:resources/compiled/" } diff --git a/resources/compiled/aante-dark.css b/resources/compiled/aante-dark.css index 6aa8b702c..c4df34cfb 100644 --- a/resources/compiled/aante-dark.css +++ b/resources/compiled/aante-dark.css @@ -1 +1 @@ -.kint-rich{font-size:13px;overflow-x:auto;white-space:nowrap;background:rgba(0,0,0,.9)}.kint-rich.kint-folder{position:fixed;bottom:0;left:0;right:0;z-index:999999;width:100%;margin:0;display:block}.kint-rich.kint-folder dd.kint-foldout{max-height:calc(100vh - 100px);padding-right:8px;overflow-y:scroll;display:none}.kint-rich.kint-folder dd.kint-foldout.kint-show{display:block}.kint-rich::selection,.kint-rich::-moz-selection,.kint-rich::-webkit-selection{background:#555;color:#e2e1e1}.kint-rich .kint-focused{box-shadow:0 0 3px 2px aqua}.kint-rich,.kint-rich::before,.kint-rich::after,.kint-rich *,.kint-rich *::before,.kint-rich *::after{box-sizing:border-box;border-radius:0;color:#e2e1e1;float:none !important;font-family:Consolas,Menlo,Monaco,Lucida Console,Liberation Mono,DejaVu Sans Mono,Bitstream Vera Sans Mono,Courier New,monospace,serif;line-height:15px;margin:0;padding:0;text-align:left}.kint-rich{margin:8px 0}.kint-rich dt,.kint-rich dl{width:auto}.kint-rich dt,.kint-rich div.access-path{background:#070707;border:1px solid #282828;color:#e2e1e1;display:block;font-weight:bold;list-style:none outside none;overflow:auto;padding:4px}.kint-rich dt:hover,.kint-rich div.access-path:hover{border-color:#555}.kint-rich>dl dl{padding:0 0 0 12px}.kint-rich dt.kint-parent>nav,.kint-rich>footer>nav{background:url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAzMCAxNTAiPjxwYXRoIGQ9Ik02IDdoMThsLTkgMTV6bTAgMzBoMThsLTkgMTV6bTAgNDVoMThsLTktMTV6bTAgMzBoMThsLTktMTV6bTAgMTJsMTggMThtLTE4IDBsMTgtMTgiIGZpbGw9IiNBQUEiLz48cGF0aCBkPSJNNiAxMjZsMTggMThtLTE4IDBsMTgtMTgiIHN0cm9rZS13aWR0aD0iMiIgc3Ryb2tlPSIjQUFBIi8+PC9zdmc+") no-repeat scroll 0 0/15px 75px rgba(0,0,0,0);cursor:pointer;display:inline-block;height:15px;width:15px;margin-right:3px;vertical-align:middle}.kint-rich dt.kint-parent:hover>nav,.kint-rich>footer>nav:hover{background-position:0 25%}.kint-rich dt.kint-parent.kint-show>nav,.kint-rich>footer.kint-show>nav{background-position:0 50%}.kint-rich dt.kint-parent.kint-show:hover>nav,.kint-rich>footer.kint-show>nav:hover{background-position:0 75%}.kint-rich dt.kint-parent.kint-locked>nav{background-position:0 100%}.kint-rich dt.kint-parent+dd{display:none;border-left:1px dashed #282828}.kint-rich dt.kint-parent.kint-show+dd{display:block}.kint-rich var,.kint-rich var a{color:#f90;font-style:normal}.kint-rich dt:hover var,.kint-rich dt:hover var a{color:aqua}.kint-rich dfn{font-style:normal;font-family:monospace;color:#e2e1e1}.kint-rich pre{color:#e2e1e1;margin:0 0 0 12px;padding:5px;overflow-y:hidden;border-top:0;border:1px solid #282828;background:#070707;display:block;word-break:normal}.kint-rich .kint-popup-trigger,.kint-rich .kint-access-path-trigger,.kint-rich .kint-search-trigger{background:rgba(226,225,225,.8);border-radius:3px;height:16px;font-size:16px;margin-left:5px;font-weight:bold;width:16px;text-align:center;float:right !important;cursor:pointer;color:#070707;position:relative;overflow:hidden;line-height:17.6px}.kint-rich .kint-popup-trigger:hover,.kint-rich .kint-access-path-trigger:hover,.kint-rich .kint-search-trigger:hover{color:#e2e1e1;background:#070707}.kint-rich dt.kint-parent>.kint-popup-trigger{line-height:19.2px}.kint-rich .kint-search-trigger{font-size:20px}.kint-rich input.kint-search{display:none;border:1px solid #282828;border-top-width:0;border-bottom-width:0;padding:4px;float:right !important;margin:-4px 0;color:#e2e1e1;background:#070707;height:24px;width:160px;position:relative;z-index:100}.kint-rich input.kint-search.kint-show{display:block}.kint-rich .kint-search-root ul.kint-tabs>li:not(.kint-search-match){background:#070707;opacity:.5}.kint-rich .kint-search-root dl:not(.kint-search-match){opacity:.5}.kint-rich .kint-search-root dl:not(.kint-search-match)>dt{background:#070707}.kint-rich .kint-search-root dl:not(.kint-search-match) dl,.kint-rich .kint-search-root dl:not(.kint-search-match) ul.kint-tabs>li:not(.kint-search-match){opacity:1}.kint-rich div.access-path{background:#070707;display:none;margin-top:5px;padding:4px;white-space:pre}.kint-rich div.access-path.kint-show{display:block}.kint-rich footer{padding:0 3px 3px;font-size:9px;background:rgba(0,0,0,0)}.kint-rich footer>.kint-popup-trigger{background:rgba(0,0,0,0);color:#e2e1e1}.kint-rich footer nav{height:10px;width:10px;background-size:10px 50px}.kint-rich footer>ol{display:none;margin-left:32px}.kint-rich footer.kint-show>ol{display:block}.kint-rich a{color:#e2e1e1;text-shadow:none;text-decoration:underline}.kint-rich a:hover{color:#e2e1e1;border-bottom:1px dotted #e2e1e1}.kint-rich ul{list-style:none;padding-left:12px}.kint-rich ul:not(.kint-tabs) li{border-left:1px dashed #282828}.kint-rich ul:not(.kint-tabs) li>dl{border-left:none}.kint-rich ul.kint-tabs{margin:0 0 0 12px;padding-left:0;background:#070707;border:1px solid #282828;border-top:0}.kint-rich ul.kint-tabs>li{background:#070707;border:1px solid #282828;cursor:pointer;display:inline-block;height:24px;margin:2px;padding:0 12px;vertical-align:top}.kint-rich ul.kint-tabs>li:hover,.kint-rich ul.kint-tabs>li.kint-active-tab:hover{border-color:#555;color:aqua}.kint-rich ul.kint-tabs>li.kint-active-tab{background:#070707;border-top:0;margin-top:-1px;height:27px;line-height:24px}.kint-rich ul.kint-tabs>li:not(.kint-active-tab){line-height:20px}.kint-rich ul.kint-tabs li+li{margin-left:0}.kint-rich ul.kint-tab-contents>li{display:none}.kint-rich ul.kint-tab-contents>li.kint-show{display:block}.kint-rich dt:hover+dd>ul>li.kint-active-tab{border-color:#555;color:aqua}.kint-rich dt>.kint-color-preview{width:16px;height:16px;display:inline-block;vertical-align:middle;margin-left:10px;border:1px solid #282828;background-color:#ccc;background-image:url('data:image/svg+xml;utf8,');background-size:100%}.kint-rich dt>.kint-color-preview:hover{border-color:#555}.kint-rich dt>.kint-color-preview>div{width:100%;height:100%}.kint-rich table{border-collapse:collapse;empty-cells:show;border-spacing:0}.kint-rich table *{font-size:12px}.kint-rich table dt{background:none;padding:2px}.kint-rich table dt .kint-parent{min-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.kint-rich table td,.kint-rich table th{border:1px solid #282828;padding:2px;vertical-align:center}.kint-rich table th{cursor:alias}.kint-rich table td:first-child,.kint-rich table th{font-weight:bold;background:#070707;color:#e2e1e1}.kint-rich table td{background:#070707;white-space:pre}.kint-rich table td>dl{padding:0}.kint-rich table pre{border-top:0;border-right:0}.kint-rich table thead th:first-child{background:none;border:0}.kint-rich table tr:hover>td{box-shadow:0 0 1px 0 #555 inset}.kint-rich table tr:hover var{color:aqua}.kint-rich table ul.kint-tabs li.kint-active-tab{height:20px;line-height:17px}.kint-rich pre.kint-source{margin-left:-1px}.kint-rich pre.kint-source[data-kint-filename]:before{display:block;content:attr(data-kint-filename);margin-bottom:4px;padding-bottom:4px;border-bottom:1px solid #070707}.kint-rich pre.kint-source>div:before{display:inline-block;content:counter(kint-l);counter-increment:kint-l;border-right:1px solid #555;padding-right:8px;margin-right:8px}.kint-rich pre.kint-source>div.kint-highlight{background:#070707}.kint-rich .kint-microtime-lap{text-shadow:-1px 0 #555,0 1px #555,1px 0 #555,0 -1px #555;color:#070707;font-weight:bold}input.kint-note-input{width:100%}.kint-rich .kint-focused{box-shadow:0 0 3px 2px aqua}.kint-rich dt{font-weight:normal}.kint-rich dt.kint-parent{margin-top:4px}.kint-rich dl dl{margin-top:4px;padding-left:25px;border-left:none}.kint-rich>dl>dt{background:#070707}.kint-rich ul{margin:0;padding-left:0}.kint-rich ul:not(.kint-tabs)>li{border-left:0}.kint-rich ul.kint-tabs{background:#070707;border:1px solid #282828;border-width:0 1px 1px 1px;padding:4px 0 0 12px;margin-left:-1px;margin-top:-1px}.kint-rich ul.kint-tabs li,.kint-rich ul.kint-tabs li+li{margin:0 0 0 4px}.kint-rich ul.kint-tabs li{border-bottom-width:0;height:25px}.kint-rich ul.kint-tabs li:first-child{margin-left:0}.kint-rich ul.kint-tabs li.kint-active-tab{border-top:1px solid #282828;background:#000;font-weight:bold;padding-top:0;border-bottom:1px solid #000 !important;margin-bottom:-1px}.kint-rich ul.kint-tabs li.kint-active-tab:hover{border-bottom:1px solid #000}.kint-rich ul>li>pre{border:1px solid #282828}.kint-rich dt:hover+dd>ul{border-color:#555}.kint-rich pre{background:#000;margin-top:4px;margin-left:25px}.kint-rich .kint-source{margin-left:-1px}.kint-rich .kint-source .kint-highlight{background:#303}.kint-rich .kint-parent.kint-show>.kint-search{border-bottom-width:1px}.kint-rich table td{background:#000}.kint-rich table td>dl{padding:0;margin:0}.kint-rich table td>dl>dt.kint-parent{margin:0}.kint-rich table td:first-child,.kint-rich table td,.kint-rich table th{padding:2px 4px}.kint-rich table dd,.kint-rich table dt{background:#000}.kint-rich table tr:hover>td{box-shadow:none;background:#303} +.kint-rich{font-size:13px;overflow-x:auto;white-space:nowrap;background:rgba(0,0,0,.9)}.kint-rich.kint-folder{position:fixed;bottom:0;left:0;right:0;z-index:999999;width:100%;margin:0;display:block}.kint-rich.kint-folder dd.kint-foldout{max-height:calc(100vh - 100px);padding-right:8px;overflow-y:scroll;display:none}.kint-rich.kint-folder dd.kint-foldout.kint-show{display:block}.kint-rich::selection,.kint-rich::-moz-selection,.kint-rich::-webkit-selection{background:#555;color:#e2e1e1}.kint-rich .kint-focused{box-shadow:0 0 3px 3px aqua}.kint-rich .kint-focused.kint-weak-focus{box-shadow:0 0 3px 1px rgba(0,255,255,.5)}.kint-rich,.kint-rich::before,.kint-rich::after,.kint-rich *,.kint-rich *::before,.kint-rich *::after{box-sizing:border-box;border-radius:0;color:#e2e1e1;float:none !important;font-family:Consolas,Menlo,Monaco,Lucida Console,Liberation Mono,DejaVu Sans Mono,Bitstream Vera Sans Mono,Courier New,monospace,serif;line-height:15px;margin:0;padding:0;text-align:left}.kint-rich{margin:8px 0}.kint-rich dt,.kint-rich dl{width:auto}.kint-rich dt,.kint-rich div.access-path{background:#070707;border:1px solid #282828;color:#e2e1e1;display:block;font-weight:bold;list-style:none outside none;overflow:auto;padding:4px}.kint-rich dt:hover,.kint-rich div.access-path:hover{border-color:#555}.kint-rich>dl dl{padding:0 0 0 12px}.kint-rich dt.kint-parent>nav,.kint-rich>footer>nav{background:url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAzMCAxNTAiPjxwYXRoIGQ9Ik02IDdoMThsLTkgMTV6bTAgMzBoMThsLTkgMTV6bTAgNDVoMThsLTktMTV6bTAgMzBoMThsLTktMTV6bTAgMTJsMTggMThtLTE4IDBsMTgtMTgiIGZpbGw9IiNBQUEiLz48cGF0aCBkPSJNNiAxMjZsMTggMThtLTE4IDBsMTgtMTgiIHN0cm9rZS13aWR0aD0iMiIgc3Ryb2tlPSIjQUFBIi8+PC9zdmc+") no-repeat scroll 0 0/15px 75px rgba(0,0,0,0);cursor:pointer;display:inline-block;height:15px;width:15px;margin-right:3px;vertical-align:middle}.kint-rich dt.kint-parent:hover>nav,.kint-rich>footer>nav:hover{background-position:0 25%}.kint-rich dt.kint-parent.kint-show>nav,.kint-rich>footer.kint-show>nav{background-position:0 50%}.kint-rich dt.kint-parent.kint-show:hover>nav,.kint-rich>footer.kint-show>nav:hover{background-position:0 75%}.kint-rich dt.kint-parent.kint-locked>nav{background-position:0 100%}.kint-rich dt.kint-parent+dd{display:none;border-left:1px dashed #282828}.kint-rich dt.kint-parent.kint-show+dd{display:block}.kint-rich var,.kint-rich var a{color:#f90;font-style:normal}.kint-rich dt:hover var,.kint-rich dt:hover var a{color:aqua}.kint-rich dfn{font-style:normal;font-family:monospace;color:#e2e1e1}.kint-rich pre{color:#e2e1e1;margin:0 0 0 12px;padding:5px;overflow-y:hidden;border-top:0;border:1px solid #282828;background:#070707;display:block;word-break:normal}.kint-rich .kint-access-path-trigger,.kint-rich .kint-search-trigger{background:rgba(226,225,225,.8);border-radius:3px;height:16px;font-size:16px;margin-left:5px;font-weight:bold;width:16px;text-align:center;float:right !important;cursor:pointer;color:#070707;position:relative;overflow:hidden;line-height:17.6px}.kint-rich .kint-access-path-trigger:hover,.kint-rich .kint-search-trigger:hover{color:#e2e1e1;background:#070707}.kint-rich .kint-search-trigger{font-size:20px}.kint-rich input.kint-search{display:none;border:1px solid #282828;border-top-width:0;border-bottom-width:0;padding:4px;float:right !important;margin:-4px 0;color:#e2e1e1;background:#070707;height:24px;width:160px;position:relative;z-index:100}.kint-rich input.kint-search.kint-show{display:block}.kint-rich .kint-search-root ul.kint-tabs>li:not(.kint-search-match){background:#070707;opacity:.5}.kint-rich .kint-search-root dl:not(.kint-search-match){opacity:.5}.kint-rich .kint-search-root dl:not(.kint-search-match)>dt{background:#070707}.kint-rich .kint-search-root dl:not(.kint-search-match) dl,.kint-rich .kint-search-root dl:not(.kint-search-match) ul.kint-tabs>li:not(.kint-search-match){opacity:1}.kint-rich div.access-path{background:#070707;display:none;margin-top:5px;padding:4px;white-space:pre}.kint-rich div.access-path.kint-show{display:block}.kint-rich footer{padding:0 3px 3px;font-size:9px;background:rgba(0,0,0,0)}.kint-rich footer nav{height:10px;width:10px;background-size:10px 50px}.kint-rich footer>ol{display:none;margin-left:32px}.kint-rich footer.kint-show>ol{display:block}.kint-rich a{color:#e2e1e1;text-shadow:none;text-decoration:underline}.kint-rich a:hover{color:#e2e1e1;border-bottom:1px dotted #e2e1e1}.kint-rich ul{list-style:none;padding-left:12px}.kint-rich ul:not(.kint-tabs) li{border-left:1px dashed #282828}.kint-rich ul:not(.kint-tabs) li>dl{border-left:none}.kint-rich ul.kint-tabs{margin:0 0 0 12px;padding-left:0;background:#070707;border:1px solid #282828;border-top:0}.kint-rich ul.kint-tabs>li{background:#070707;border:1px solid #282828;cursor:pointer;display:inline-block;height:24px;margin:2px;padding:0 12px;vertical-align:top}.kint-rich ul.kint-tabs>li:hover,.kint-rich ul.kint-tabs>li.kint-active-tab:hover{border-color:#555;color:aqua}.kint-rich ul.kint-tabs>li.kint-active-tab{background:#070707;border-top:0;margin-top:-1px;height:27px;line-height:24px}.kint-rich ul.kint-tabs>li:not(.kint-active-tab){line-height:20px}.kint-rich ul.kint-tabs li+li{margin-left:0}.kint-rich ul.kint-tab-contents>li{display:none}.kint-rich ul.kint-tab-contents>li.kint-show{display:block}.kint-rich dt:hover+dd>ul>li.kint-active-tab{border-color:#555;color:aqua}.kint-rich dt>.kint-color-preview{width:16px;height:16px;display:inline-block;vertical-align:middle;margin-left:10px;border:1px solid #282828;background-color:#ccc;background-image:url('data:image/svg+xml;utf8,');background-size:100%}.kint-rich dt>.kint-color-preview:hover{border-color:#555}.kint-rich dt>.kint-color-preview>div{width:100%;height:100%}.kint-rich table{border-collapse:collapse;empty-cells:show;border-spacing:0}.kint-rich table *{font-size:12px}.kint-rich table dt{background:none;padding:2px}.kint-rich table dt .kint-parent{min-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.kint-rich table td,.kint-rich table th{border:1px solid #282828;padding:2px;vertical-align:center}.kint-rich table th{cursor:alias}.kint-rich table td:first-child,.kint-rich table th{font-weight:bold;background:#070707;color:#e2e1e1}.kint-rich table td{background:#070707;white-space:pre}.kint-rich table td>dl{padding:0}.kint-rich table pre{border-top:0;border-right:0}.kint-rich table thead th:first-child{background:none;border:0}.kint-rich table tr:hover>td{box-shadow:0 0 1px 0 #555 inset}.kint-rich table tr:hover var{color:aqua}.kint-rich table ul.kint-tabs li.kint-active-tab{height:20px;line-height:17px}.kint-rich pre.kint-source{margin-left:-1px}.kint-rich pre.kint-source[data-kint-filename]:before{display:block;content:attr(data-kint-filename);margin-bottom:4px;padding-bottom:4px;border-bottom:1px solid #070707}.kint-rich pre.kint-source>div:before{display:inline-block;content:counter(kint-l);counter-increment:kint-l;border-right:1px solid #555;padding-right:8px;margin-right:8px}.kint-rich pre.kint-source>div.kint-highlight{background:#070707}.kint-rich .kint-microtime-js .kint-microtime-lap{text-shadow:-1px 0 #555,0 1px #555,1px 0 #555,0 -1px #555;color:#070707;font-weight:bold}input.kint-note-input{width:100%}.kint-rich .kint-focused{box-shadow:0 0 3px 2px aqua}.kint-rich dt{font-weight:normal}.kint-rich dt.kint-parent{margin-top:4px}.kint-rich dl dl{margin-top:4px;padding-left:25px;border-left:none}.kint-rich>dl>dt{background:#070707}.kint-rich ul{margin:0;padding-left:0}.kint-rich ul:not(.kint-tabs)>li{border-left:0}.kint-rich ul.kint-tabs{background:#070707;border:1px solid #282828;border-width:0 1px 1px 1px;padding:4px 0 0 12px;margin-left:-1px;margin-top:-1px}.kint-rich ul.kint-tabs li,.kint-rich ul.kint-tabs li+li{margin:0 0 0 4px}.kint-rich ul.kint-tabs li{border-bottom-width:0;height:25px}.kint-rich ul.kint-tabs li:first-child{margin-left:0}.kint-rich ul.kint-tabs li.kint-active-tab{border-top:1px solid #282828;background:#000;font-weight:bold;padding-top:0;border-bottom:1px solid #000 !important;margin-bottom:-1px}.kint-rich ul.kint-tabs li.kint-active-tab:hover{border-bottom:1px solid #000}.kint-rich ul>li>pre{border:1px solid #282828}.kint-rich dt:hover+dd>ul{border-color:#555}.kint-rich pre{background:#000;margin-top:4px;margin-left:25px}.kint-rich .kint-source{margin-left:-1px}.kint-rich .kint-source .kint-highlight{background:#303}.kint-rich .kint-parent.kint-show>.kint-search{border-bottom-width:1px}.kint-rich table td{background:#000}.kint-rich table td>dl{padding:0;margin:0}.kint-rich table td>dl>dt.kint-parent{margin:0}.kint-rich table td:first-child,.kint-rich table td,.kint-rich table th{padding:2px 4px}.kint-rich table dd,.kint-rich table dt{background:#000}.kint-rich table tr:hover>td{box-shadow:none;background:#303} diff --git a/resources/compiled/aante-light.css b/resources/compiled/aante-light.css index 16194736e..4c097f654 100644 --- a/resources/compiled/aante-light.css +++ b/resources/compiled/aante-light.css @@ -1 +1 @@ -.kint-rich{font-size:13px;overflow-x:auto;white-space:nowrap;background:rgba(255,255,255,.9)}.kint-rich.kint-folder{position:fixed;bottom:0;left:0;right:0;z-index:999999;width:100%;margin:0;display:block}.kint-rich.kint-folder dd.kint-foldout{max-height:calc(100vh - 100px);padding-right:8px;overflow-y:scroll;display:none}.kint-rich.kint-folder dd.kint-foldout.kint-show{display:block}.kint-rich::selection,.kint-rich::-moz-selection,.kint-rich::-webkit-selection{background:#aaa;color:#1d1e1e}.kint-rich .kint-focused{box-shadow:0 0 3px 2px red}.kint-rich,.kint-rich::before,.kint-rich::after,.kint-rich *,.kint-rich *::before,.kint-rich *::after{box-sizing:border-box;border-radius:0;color:#1d1e1e;float:none !important;font-family:Consolas,Menlo,Monaco,Lucida Console,Liberation Mono,DejaVu Sans Mono,Bitstream Vera Sans Mono,Courier New,monospace,serif;line-height:15px;margin:0;padding:0;text-align:left}.kint-rich{margin:8px 0}.kint-rich dt,.kint-rich dl{width:auto}.kint-rich dt,.kint-rich div.access-path{background:#f8f8f8;border:1px solid #d7d7d7;color:#1d1e1e;display:block;font-weight:bold;list-style:none outside none;overflow:auto;padding:4px}.kint-rich dt:hover,.kint-rich div.access-path:hover{border-color:#aaa}.kint-rich>dl dl{padding:0 0 0 12px}.kint-rich dt.kint-parent>nav,.kint-rich>footer>nav{background:url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAzMCAxNTAiPjxwYXRoIGQ9Ik02IDdoMThsLTkgMTV6bTAgMzBoMThsLTkgMTV6bTAgNDVoMThsLTktMTV6bTAgMzBoMThsLTktMTV6bTAgMTJsMTggMThtLTE4IDBsMTgtMTgiIGZpbGw9IiM1NTUiLz48cGF0aCBkPSJNNiAxMjZsMTggMThtLTE4IDBsMTgtMTgiIHN0cm9rZS13aWR0aD0iMiIgc3Ryb2tlPSIjNTU1Ii8+PC9zdmc+") no-repeat scroll 0 0/15px 75px rgba(0,0,0,0);cursor:pointer;display:inline-block;height:15px;width:15px;margin-right:3px;vertical-align:middle}.kint-rich dt.kint-parent:hover>nav,.kint-rich>footer>nav:hover{background-position:0 25%}.kint-rich dt.kint-parent.kint-show>nav,.kint-rich>footer.kint-show>nav{background-position:0 50%}.kint-rich dt.kint-parent.kint-show:hover>nav,.kint-rich>footer.kint-show>nav:hover{background-position:0 75%}.kint-rich dt.kint-parent.kint-locked>nav{background-position:0 100%}.kint-rich dt.kint-parent+dd{display:none;border-left:1px dashed #d7d7d7}.kint-rich dt.kint-parent.kint-show+dd{display:block}.kint-rich var,.kint-rich var a{color:#06f;font-style:normal}.kint-rich dt:hover var,.kint-rich dt:hover var a{color:red}.kint-rich dfn{font-style:normal;font-family:monospace;color:#1d1e1e}.kint-rich pre{color:#1d1e1e;margin:0 0 0 12px;padding:5px;overflow-y:hidden;border-top:0;border:1px solid #d7d7d7;background:#f8f8f8;display:block;word-break:normal}.kint-rich .kint-popup-trigger,.kint-rich .kint-access-path-trigger,.kint-rich .kint-search-trigger{background:rgba(29,30,30,.8);border-radius:3px;height:16px;font-size:16px;margin-left:5px;font-weight:bold;width:16px;text-align:center;float:right !important;cursor:pointer;color:#f8f8f8;position:relative;overflow:hidden;line-height:17.6px}.kint-rich .kint-popup-trigger:hover,.kint-rich .kint-access-path-trigger:hover,.kint-rich .kint-search-trigger:hover{color:#1d1e1e;background:#f8f8f8}.kint-rich dt.kint-parent>.kint-popup-trigger{line-height:19.2px}.kint-rich .kint-search-trigger{font-size:20px}.kint-rich input.kint-search{display:none;border:1px solid #d7d7d7;border-top-width:0;border-bottom-width:0;padding:4px;float:right !important;margin:-4px 0;color:#1d1e1e;background:#f8f8f8;height:24px;width:160px;position:relative;z-index:100}.kint-rich input.kint-search.kint-show{display:block}.kint-rich .kint-search-root ul.kint-tabs>li:not(.kint-search-match){background:#f8f8f8;opacity:.5}.kint-rich .kint-search-root dl:not(.kint-search-match){opacity:.5}.kint-rich .kint-search-root dl:not(.kint-search-match)>dt{background:#f8f8f8}.kint-rich .kint-search-root dl:not(.kint-search-match) dl,.kint-rich .kint-search-root dl:not(.kint-search-match) ul.kint-tabs>li:not(.kint-search-match){opacity:1}.kint-rich div.access-path{background:#f8f8f8;display:none;margin-top:5px;padding:4px;white-space:pre}.kint-rich div.access-path.kint-show{display:block}.kint-rich footer{padding:0 3px 3px;font-size:9px;background:rgba(0,0,0,0)}.kint-rich footer>.kint-popup-trigger{background:rgba(0,0,0,0);color:#1d1e1e}.kint-rich footer nav{height:10px;width:10px;background-size:10px 50px}.kint-rich footer>ol{display:none;margin-left:32px}.kint-rich footer.kint-show>ol{display:block}.kint-rich a{color:#1d1e1e;text-shadow:none;text-decoration:underline}.kint-rich a:hover{color:#1d1e1e;border-bottom:1px dotted #1d1e1e}.kint-rich ul{list-style:none;padding-left:12px}.kint-rich ul:not(.kint-tabs) li{border-left:1px dashed #d7d7d7}.kint-rich ul:not(.kint-tabs) li>dl{border-left:none}.kint-rich ul.kint-tabs{margin:0 0 0 12px;padding-left:0;background:#f8f8f8;border:1px solid #d7d7d7;border-top:0}.kint-rich ul.kint-tabs>li{background:#f8f8f8;border:1px solid #d7d7d7;cursor:pointer;display:inline-block;height:24px;margin:2px;padding:0 12px;vertical-align:top}.kint-rich ul.kint-tabs>li:hover,.kint-rich ul.kint-tabs>li.kint-active-tab:hover{border-color:#aaa;color:red}.kint-rich ul.kint-tabs>li.kint-active-tab{background:#f8f8f8;border-top:0;margin-top:-1px;height:27px;line-height:24px}.kint-rich ul.kint-tabs>li:not(.kint-active-tab){line-height:20px}.kint-rich ul.kint-tabs li+li{margin-left:0}.kint-rich ul.kint-tab-contents>li{display:none}.kint-rich ul.kint-tab-contents>li.kint-show{display:block}.kint-rich dt:hover+dd>ul>li.kint-active-tab{border-color:#aaa;color:red}.kint-rich dt>.kint-color-preview{width:16px;height:16px;display:inline-block;vertical-align:middle;margin-left:10px;border:1px solid #d7d7d7;background-color:#ccc;background-image:url('data:image/svg+xml;utf8,');background-size:100%}.kint-rich dt>.kint-color-preview:hover{border-color:#aaa}.kint-rich dt>.kint-color-preview>div{width:100%;height:100%}.kint-rich table{border-collapse:collapse;empty-cells:show;border-spacing:0}.kint-rich table *{font-size:12px}.kint-rich table dt{background:none;padding:2px}.kint-rich table dt .kint-parent{min-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.kint-rich table td,.kint-rich table th{border:1px solid #d7d7d7;padding:2px;vertical-align:center}.kint-rich table th{cursor:alias}.kint-rich table td:first-child,.kint-rich table th{font-weight:bold;background:#f8f8f8;color:#1d1e1e}.kint-rich table td{background:#f8f8f8;white-space:pre}.kint-rich table td>dl{padding:0}.kint-rich table pre{border-top:0;border-right:0}.kint-rich table thead th:first-child{background:none;border:0}.kint-rich table tr:hover>td{box-shadow:0 0 1px 0 #aaa inset}.kint-rich table tr:hover var{color:red}.kint-rich table ul.kint-tabs li.kint-active-tab{height:20px;line-height:17px}.kint-rich pre.kint-source{margin-left:-1px}.kint-rich pre.kint-source[data-kint-filename]:before{display:block;content:attr(data-kint-filename);margin-bottom:4px;padding-bottom:4px;border-bottom:1px solid #f8f8f8}.kint-rich pre.kint-source>div:before{display:inline-block;content:counter(kint-l);counter-increment:kint-l;border-right:1px solid #aaa;padding-right:8px;margin-right:8px}.kint-rich pre.kint-source>div.kint-highlight{background:#f8f8f8}.kint-rich .kint-microtime-lap{text-shadow:-1px 0 #aaa,0 1px #aaa,1px 0 #aaa,0 -1px #aaa;color:#f8f8f8;font-weight:bold}input.kint-note-input{width:100%}.kint-rich .kint-focused{box-shadow:0 0 3px 2px red}.kint-rich dt{font-weight:normal}.kint-rich dt.kint-parent{margin-top:4px}.kint-rich dl dl{margin-top:4px;padding-left:25px;border-left:none}.kint-rich>dl>dt{background:#f8f8f8}.kint-rich ul{margin:0;padding-left:0}.kint-rich ul:not(.kint-tabs)>li{border-left:0}.kint-rich ul.kint-tabs{background:#f8f8f8;border:1px solid #d7d7d7;border-width:0 1px 1px 1px;padding:4px 0 0 12px;margin-left:-1px;margin-top:-1px}.kint-rich ul.kint-tabs li,.kint-rich ul.kint-tabs li+li{margin:0 0 0 4px}.kint-rich ul.kint-tabs li{border-bottom-width:0;height:25px}.kint-rich ul.kint-tabs li:first-child{margin-left:0}.kint-rich ul.kint-tabs li.kint-active-tab{border-top:1px solid #d7d7d7;background:#fff;font-weight:bold;padding-top:0;border-bottom:1px solid #fff !important;margin-bottom:-1px}.kint-rich ul.kint-tabs li.kint-active-tab:hover{border-bottom:1px solid #fff}.kint-rich ul>li>pre{border:1px solid #d7d7d7}.kint-rich dt:hover+dd>ul{border-color:#aaa}.kint-rich pre{background:#fff;margin-top:4px;margin-left:25px}.kint-rich .kint-source{margin-left:-1px}.kint-rich .kint-source .kint-highlight{background:#cfc}.kint-rich .kint-parent.kint-show>.kint-search{border-bottom-width:1px}.kint-rich table td{background:#fff}.kint-rich table td>dl{padding:0;margin:0}.kint-rich table td>dl>dt.kint-parent{margin:0}.kint-rich table td:first-child,.kint-rich table td,.kint-rich table th{padding:2px 4px}.kint-rich table dd,.kint-rich table dt{background:#fff}.kint-rich table tr:hover>td{box-shadow:none;background:#cfc} +.kint-rich{font-size:13px;overflow-x:auto;white-space:nowrap;background:rgba(255,255,255,.9)}.kint-rich.kint-folder{position:fixed;bottom:0;left:0;right:0;z-index:999999;width:100%;margin:0;display:block}.kint-rich.kint-folder dd.kint-foldout{max-height:calc(100vh - 100px);padding-right:8px;overflow-y:scroll;display:none}.kint-rich.kint-folder dd.kint-foldout.kint-show{display:block}.kint-rich::selection,.kint-rich::-moz-selection,.kint-rich::-webkit-selection{background:#aaa;color:#1d1e1e}.kint-rich .kint-focused{box-shadow:0 0 3px 3px red}.kint-rich .kint-focused.kint-weak-focus{box-shadow:0 0 3px 1px rgba(255,0,0,.5)}.kint-rich,.kint-rich::before,.kint-rich::after,.kint-rich *,.kint-rich *::before,.kint-rich *::after{box-sizing:border-box;border-radius:0;color:#1d1e1e;float:none !important;font-family:Consolas,Menlo,Monaco,Lucida Console,Liberation Mono,DejaVu Sans Mono,Bitstream Vera Sans Mono,Courier New,monospace,serif;line-height:15px;margin:0;padding:0;text-align:left}.kint-rich{margin:8px 0}.kint-rich dt,.kint-rich dl{width:auto}.kint-rich dt,.kint-rich div.access-path{background:#f8f8f8;border:1px solid #d7d7d7;color:#1d1e1e;display:block;font-weight:bold;list-style:none outside none;overflow:auto;padding:4px}.kint-rich dt:hover,.kint-rich div.access-path:hover{border-color:#aaa}.kint-rich>dl dl{padding:0 0 0 12px}.kint-rich dt.kint-parent>nav,.kint-rich>footer>nav{background:url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAzMCAxNTAiPjxwYXRoIGQ9Ik02IDdoMThsLTkgMTV6bTAgMzBoMThsLTkgMTV6bTAgNDVoMThsLTktMTV6bTAgMzBoMThsLTktMTV6bTAgMTJsMTggMThtLTE4IDBsMTgtMTgiIGZpbGw9IiM1NTUiLz48cGF0aCBkPSJNNiAxMjZsMTggMThtLTE4IDBsMTgtMTgiIHN0cm9rZS13aWR0aD0iMiIgc3Ryb2tlPSIjNTU1Ii8+PC9zdmc+") no-repeat scroll 0 0/15px 75px rgba(0,0,0,0);cursor:pointer;display:inline-block;height:15px;width:15px;margin-right:3px;vertical-align:middle}.kint-rich dt.kint-parent:hover>nav,.kint-rich>footer>nav:hover{background-position:0 25%}.kint-rich dt.kint-parent.kint-show>nav,.kint-rich>footer.kint-show>nav{background-position:0 50%}.kint-rich dt.kint-parent.kint-show:hover>nav,.kint-rich>footer.kint-show>nav:hover{background-position:0 75%}.kint-rich dt.kint-parent.kint-locked>nav{background-position:0 100%}.kint-rich dt.kint-parent+dd{display:none;border-left:1px dashed #d7d7d7}.kint-rich dt.kint-parent.kint-show+dd{display:block}.kint-rich var,.kint-rich var a{color:#06f;font-style:normal}.kint-rich dt:hover var,.kint-rich dt:hover var a{color:red}.kint-rich dfn{font-style:normal;font-family:monospace;color:#1d1e1e}.kint-rich pre{color:#1d1e1e;margin:0 0 0 12px;padding:5px;overflow-y:hidden;border-top:0;border:1px solid #d7d7d7;background:#f8f8f8;display:block;word-break:normal}.kint-rich .kint-access-path-trigger,.kint-rich .kint-search-trigger{background:rgba(29,30,30,.8);border-radius:3px;height:16px;font-size:16px;margin-left:5px;font-weight:bold;width:16px;text-align:center;float:right !important;cursor:pointer;color:#f8f8f8;position:relative;overflow:hidden;line-height:17.6px}.kint-rich .kint-access-path-trigger:hover,.kint-rich .kint-search-trigger:hover{color:#1d1e1e;background:#f8f8f8}.kint-rich .kint-search-trigger{font-size:20px}.kint-rich input.kint-search{display:none;border:1px solid #d7d7d7;border-top-width:0;border-bottom-width:0;padding:4px;float:right !important;margin:-4px 0;color:#1d1e1e;background:#f8f8f8;height:24px;width:160px;position:relative;z-index:100}.kint-rich input.kint-search.kint-show{display:block}.kint-rich .kint-search-root ul.kint-tabs>li:not(.kint-search-match){background:#f8f8f8;opacity:.5}.kint-rich .kint-search-root dl:not(.kint-search-match){opacity:.5}.kint-rich .kint-search-root dl:not(.kint-search-match)>dt{background:#f8f8f8}.kint-rich .kint-search-root dl:not(.kint-search-match) dl,.kint-rich .kint-search-root dl:not(.kint-search-match) ul.kint-tabs>li:not(.kint-search-match){opacity:1}.kint-rich div.access-path{background:#f8f8f8;display:none;margin-top:5px;padding:4px;white-space:pre}.kint-rich div.access-path.kint-show{display:block}.kint-rich footer{padding:0 3px 3px;font-size:9px;background:rgba(0,0,0,0)}.kint-rich footer nav{height:10px;width:10px;background-size:10px 50px}.kint-rich footer>ol{display:none;margin-left:32px}.kint-rich footer.kint-show>ol{display:block}.kint-rich a{color:#1d1e1e;text-shadow:none;text-decoration:underline}.kint-rich a:hover{color:#1d1e1e;border-bottom:1px dotted #1d1e1e}.kint-rich ul{list-style:none;padding-left:12px}.kint-rich ul:not(.kint-tabs) li{border-left:1px dashed #d7d7d7}.kint-rich ul:not(.kint-tabs) li>dl{border-left:none}.kint-rich ul.kint-tabs{margin:0 0 0 12px;padding-left:0;background:#f8f8f8;border:1px solid #d7d7d7;border-top:0}.kint-rich ul.kint-tabs>li{background:#f8f8f8;border:1px solid #d7d7d7;cursor:pointer;display:inline-block;height:24px;margin:2px;padding:0 12px;vertical-align:top}.kint-rich ul.kint-tabs>li:hover,.kint-rich ul.kint-tabs>li.kint-active-tab:hover{border-color:#aaa;color:red}.kint-rich ul.kint-tabs>li.kint-active-tab{background:#f8f8f8;border-top:0;margin-top:-1px;height:27px;line-height:24px}.kint-rich ul.kint-tabs>li:not(.kint-active-tab){line-height:20px}.kint-rich ul.kint-tabs li+li{margin-left:0}.kint-rich ul.kint-tab-contents>li{display:none}.kint-rich ul.kint-tab-contents>li.kint-show{display:block}.kint-rich dt:hover+dd>ul>li.kint-active-tab{border-color:#aaa;color:red}.kint-rich dt>.kint-color-preview{width:16px;height:16px;display:inline-block;vertical-align:middle;margin-left:10px;border:1px solid #d7d7d7;background-color:#ccc;background-image:url('data:image/svg+xml;utf8,');background-size:100%}.kint-rich dt>.kint-color-preview:hover{border-color:#aaa}.kint-rich dt>.kint-color-preview>div{width:100%;height:100%}.kint-rich table{border-collapse:collapse;empty-cells:show;border-spacing:0}.kint-rich table *{font-size:12px}.kint-rich table dt{background:none;padding:2px}.kint-rich table dt .kint-parent{min-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.kint-rich table td,.kint-rich table th{border:1px solid #d7d7d7;padding:2px;vertical-align:center}.kint-rich table th{cursor:alias}.kint-rich table td:first-child,.kint-rich table th{font-weight:bold;background:#f8f8f8;color:#1d1e1e}.kint-rich table td{background:#f8f8f8;white-space:pre}.kint-rich table td>dl{padding:0}.kint-rich table pre{border-top:0;border-right:0}.kint-rich table thead th:first-child{background:none;border:0}.kint-rich table tr:hover>td{box-shadow:0 0 1px 0 #aaa inset}.kint-rich table tr:hover var{color:red}.kint-rich table ul.kint-tabs li.kint-active-tab{height:20px;line-height:17px}.kint-rich pre.kint-source{margin-left:-1px}.kint-rich pre.kint-source[data-kint-filename]:before{display:block;content:attr(data-kint-filename);margin-bottom:4px;padding-bottom:4px;border-bottom:1px solid #f8f8f8}.kint-rich pre.kint-source>div:before{display:inline-block;content:counter(kint-l);counter-increment:kint-l;border-right:1px solid #aaa;padding-right:8px;margin-right:8px}.kint-rich pre.kint-source>div.kint-highlight{background:#f8f8f8}.kint-rich .kint-microtime-js .kint-microtime-lap{text-shadow:-1px 0 #aaa,0 1px #aaa,1px 0 #aaa,0 -1px #aaa;color:#f8f8f8;font-weight:bold}input.kint-note-input{width:100%}.kint-rich .kint-focused{box-shadow:0 0 3px 2px red}.kint-rich dt{font-weight:normal}.kint-rich dt.kint-parent{margin-top:4px}.kint-rich dl dl{margin-top:4px;padding-left:25px;border-left:none}.kint-rich>dl>dt{background:#f8f8f8}.kint-rich ul{margin:0;padding-left:0}.kint-rich ul:not(.kint-tabs)>li{border-left:0}.kint-rich ul.kint-tabs{background:#f8f8f8;border:1px solid #d7d7d7;border-width:0 1px 1px 1px;padding:4px 0 0 12px;margin-left:-1px;margin-top:-1px}.kint-rich ul.kint-tabs li,.kint-rich ul.kint-tabs li+li{margin:0 0 0 4px}.kint-rich ul.kint-tabs li{border-bottom-width:0;height:25px}.kint-rich ul.kint-tabs li:first-child{margin-left:0}.kint-rich ul.kint-tabs li.kint-active-tab{border-top:1px solid #d7d7d7;background:#fff;font-weight:bold;padding-top:0;border-bottom:1px solid #fff !important;margin-bottom:-1px}.kint-rich ul.kint-tabs li.kint-active-tab:hover{border-bottom:1px solid #fff}.kint-rich ul>li>pre{border:1px solid #d7d7d7}.kint-rich dt:hover+dd>ul{border-color:#aaa}.kint-rich pre{background:#fff;margin-top:4px;margin-left:25px}.kint-rich .kint-source{margin-left:-1px}.kint-rich .kint-source .kint-highlight{background:#cfc}.kint-rich .kint-parent.kint-show>.kint-search{border-bottom-width:1px}.kint-rich table td{background:#fff}.kint-rich table td>dl{padding:0;margin:0}.kint-rich table td>dl>dt.kint-parent{margin:0}.kint-rich table td:first-child,.kint-rich table td,.kint-rich table th{padding:2px 4px}.kint-rich table dd,.kint-rich table dt{background:#fff}.kint-rich table tr:hover>td{box-shadow:none;background:#cfc} diff --git a/resources/compiled/main.js b/resources/compiled/main.js new file mode 100644 index 000000000..4f341cba5 --- /dev/null +++ b/resources/compiled/main.js @@ -0,0 +1 @@ +"use strict";(()=>{function f(n){if(!(n instanceof Element))throw new Error("Invalid argument to dedupeElement()");let t=n.ownerDocument,e=x(n);for(let s of t.querySelectorAll(e))n!==s&&s.parentNode.removeChild(s)}function d(n){return n instanceof Element?n.ownerDocument.contains(n):!1}function x(n){if(!(n instanceof Element))throw new Error("Invalid argument to buildClassSelector()");return[n.nodeName,...n.classList].join(".")}function u(n){if(!(n instanceof Element))throw new Error("Invalid argument to selectText()");let t=n.ownerDocument,e=t.getSelection(),s=t.createRange();s.selectNodeContents(n),e.removeAllRanges(),e.addRange(s)}function F(n,t){let e;return function(...s){clearTimeout(e),e=setTimeout(function(){n(...s)},t)}}function E(n){if(!(n instanceof Element))throw new Error("Invalid argument to offsetTop()");return n.offsetTop+(n.offsetParent?E(n.offsetParent):0)}var m=class n{static#e=new Set;static toggleSearchBox(t,e){let s=t.querySelector(".kint-search"),i=t.parentNode;if(s)if(s.classList.toggle("kint-show",e)){if(s.focus(),s.select(),!n.#e.has(s)){let l=i.querySelectorAll("dl").length,o=200;l>1e4&&(o=700),s.addEventListener("keyup",F(n.#t.bind(null,s),o)),n.#e.add(s)}n.#t(s)}else i.classList.remove("kint-search-root")}static#t(t){let e=t.closest(".kint-parent")?.parentNode;if(e)if(t.classList.contains("kint-show")&&t.value.length){let s=e.dataset.lastSearch;if(e.classList.add("kint-search-root"),s!==t.value){e.dataset.lastSearch=t.value,e.classList.remove("kint-search-match");for(let i of e.querySelectorAll(".kint-search-match"))i.classList.remove("kint-search-match");n.#s(e,t.value.toUpperCase())}}else e.classList.remove("kint-search-root")}static#s(t,e){let s=t.cloneNode(!0);for(let c of s.querySelectorAll(".access-path"))c.remove();if(!s.textContent.toUpperCase().includes(e))return;t.classList.add("kint-search-match");let i=t.firstElementChild;for(;i&&i.tagName!=="DT";)i=i.nextElementSibling;if(!i)return;let l=a.getChildContainer(i);if(!l)return;let o,r;for(let c of l.children)c.tagName==="DL"?n.#s(c,e):c.tagName==="UL"&&(c.classList.contains("kint-tabs")?o=c.childNodes:c.classList.contains("kint-tab-contents")&&(r=c.childNodes));if(!(!o||o.length!==r?.length))for(let c=o.length;c--;){let T=!1,I=!1;o[c].textContent.toUpperCase().includes(e)&&(T=!0);let O=r[c].cloneNode(!0);for(let w of O.querySelectorAll(".access-path"))w.remove();if(O.textContent.toUpperCase().includes(e)&&(T=!0,I=!0),T&&o[c].classList.add("kint-search-match"),I)for(let w of r[c].children)w.tagName==="DL"&&n.#s(w,e)}}};var g=class{static sort(t,e){let s=t.dataset.kintTableSort,i=parseInt(s)===e?-1:1,l=t.tBodies[0];[...l.rows].sort(function(o,r){o=o.cells[e].textContent.trim().toLocaleLowerCase(),r=r.cells[e].textContent.trim().toLocaleLowerCase();let c=0;return!isNaN(o)&&!isNaN(r)?(o=parseFloat(o),r=parseFloat(r),c=o-r):isNaN(o)&&!isNaN(r)?c=1:isNaN(r)&&!isNaN(o)?c=-1:c=(""+o).localeCompare(""+r),c*i}).forEach(o=>l.appendChild(o)),i<0?t.dataset.kintTableSort=null:t.dataset.kintTableSort=e}};var a=class n{#e;#t;#s;constructor(t){if(!(t instanceof h))throw new Error("Invalid argument to Rich.constructor()");this.#e=t,this.#e.runOnInit(this.#i.bind(this));let e=new q(this,t);new b(this,t.window,e)}#i(){let t=this.#e.window.document;if(d(this.#t)||(this.#t=t.querySelector("style.kint-rich-style")),this.#t&&f(this.#t),d(this.#s)||(this.#s=t.querySelector(".kint-rich.kint-folder")),this.#s){f(this.#s);let e=this.#s.querySelector("dd.kint-foldout");for(let s of t.querySelectorAll(".kint-rich.kint-file"))s.parentNode!==e&&e.appendChild(s);this.#s.classList.add("kint-show")}}get folder(){return d(this.#s)||(this.#s=this.#e.window.document.querySelector(".kint-rich.kint-folder"),this.#s&&f(this.#s)),this.#s}isFolderOpen(){let t=this.#s?.querySelector("dd.kint-foldout");if(t)return t.previousSibling.classList.contains("kint-show")}static getChildContainer(t){let e=t.nextElementSibling;for(;e&&!e.matches("dd");)e=e.nextElementSibling;return e}static toggle(t,e){let s=n.getChildContainer(t);s&&(e=t.classList.toggle("kint-show",e),n.#n(s,e))}static switchTab(t){t.parentNode.getElementsByClassName("kint-active-tab")[0].classList.remove("kint-active-tab"),t.classList.add("kint-active-tab");let e=t,s=0;for(;e=e.previousElementSibling;)s++;let i=t.parentNode.nextSibling.children;for(let l=i.length;l--;)l===s?(i[l].classList.add("kint-show"),n.#n(i[l],!0)):i[l].classList.remove("kint-show")}static toggleChildren(t,e){let s=n.getChildContainer(t);if(!s)return;e===void 0&&(e=t.classList.contains("kint-show"));let i=s.getElementsByClassName("kint-parent");for(let l of i)l.classList.toggle("kint-show",e)}static toggleAccessPath(t,e){let s=t.querySelector(".access-path");s?.classList.toggle("kint-show",e)&&u(s)}static#n(t,e){if(t.children.length===2&&t.lastElementChild.matches("ul.kint-tab-contents"))for(let s of t.lastElementChild.children)s.matches("li.kint-show")&&(t=s);if(t.children.length===1&&t.firstElementChild.matches("dl")){let s=t?.firstElementChild?.firstElementChild;s?.classList?.contains("kint-parent")&&n.toggle(s,e)}}},b=class{#e;#t;#s;#i=null;#n=null;#o=0;constructor(t,e,s){this.#e=t,this.#t=s,this.#s=e,this.#s.addEventListener("click",this.#a.bind(this),!0)}#r(){clearTimeout(this.#i),this.#i=setTimeout(this.#l.bind(this),250)}#l(){clearTimeout(this.#i),this.#i=null,this.#n=null,this.#o=0}#c(){let t=this.#n;if(!t.matches(".kint-parent > nav"))return;let e=t.parentNode;if(this.#o===1)a.toggleChildren(e),this.#t.onTreeChanged(),this.#r(),this.#o=2;else if(this.#o===2){this.#l();let s=e.classList.contains("kint-show"),i=this.#e.folder?.querySelector(".kint-parent"),l=this.#s.document.getElementsByClassName("kint-parent");for(let o of l)o!==i&&o.classList.toggle("kint-show",s);this.#t.onTreeChanged(),this.#t.scrollToFocus()}}#a(t){if(this.#o){this.#c();return}let e=t.target;if(!e.closest(".kint-rich"))return;if(e.tagName==="DFN"&&u(e),e.tagName==="TH"){t.ctrlKey||g.sort(e.closest("table"),e.cellIndex);return}let s=e.closest(".kint-parent");if(e.tagName==="LI"&&e.parentNode.className==="kint-tabs"){if(e.className!=="kint-active-tab"){let i=e.closest("dl")?.querySelector(".kint-parent > nav")??e;this.#t.setCursor(i),a.switchTab(e),this.#t.onTreeChanged()}return}if(e.tagName==="NAV")e.parentNode.tagName==="FOOTER"?(this.#t.setCursor(e),e.parentNode.classList.toggle("kint-show")):s&&(a.toggle(s),this.#t.setCursor(e),this.#t.onTreeChanged(),this.#r(),this.#o=1,this.#n=e);else if(e.classList.contains("kint-access-path-trigger")){let i=e.closest(".kint-rich dt");i&&a.toggleAccessPath(i)}else e.classList.contains("kint-search-trigger")?s&&m.toggleSearchBox(s):e.classList.contains("kint-search")||(e.tagName==="PRE"&&t.detail===3?u(e):e.closest(".kint-source")&&t.detail===3?u(e.closest(".kint-source")):e.classList.contains("access-path")?u(e):e.tagName!=="A"&&s&&(a.toggle(s),this.#t.setCursor(s.querySelector("nav")),this.#t.onTreeChanged()))}},H=65,j=68,v=72,A=74,D=75,k=76,M=83,K=9,S=13,P=27,L=32,N=37,R=38,p=39,B=40,q=class{#e=[];#t=0;#s=!1;#i;#n;constructor(t,e){this.#i=t,this.#n=e.window,this.#n.addEventListener("keydown",this.#l.bind(this),!0),e.runOnInit(this.onTreeChanged.bind(this))}scrollToFocus(){let t=this.#e[this.#t];if(!t)return;let e=this.#i.folder;if(t===e?.querySelector(".kint-parent > nav"))return;let s=E(t);if(this.#i.isFolderOpen()){let i=e.querySelector("dd.kint-foldout");i.scrollTo(0,s-i.clientHeight/2)}else this.#n.scrollTo(0,s-this.#n.innerHeight/2)}onTreeChanged(){let t=this.#e[this.#t];this.#e=[];let e=this.#i.folder,s=e?.querySelector(".kint-parent > nav"),i=this.#n.document;this.#i.isFolderOpen()&&(i=e,this.#e.push(s));for(let l of i.querySelectorAll(".kint-rich nav, .kint-tabs>li:not(.kint-active-tab)"))l.offsetParent!==null&&l!==s&&this.#e.push(l);if(s&&!this.#i.isFolderOpen()&&this.#e.push(s),this.#e.length===0){this.#s=!1,this.#r();return}t&&this.#e.indexOf(t)!==-1?this.#t=this.#e.indexOf(t):this.#r()}setCursor(t){if(this.#i.isFolderOpen()&&!this.#i.folder.contains(t))return!1;let e=this.#e.indexOf(t);if(e===-1&&this.#n.document.readyState!=="complete"&&(this.onTreeChanged(),e=this.#e.indexOf(t)),e!==-1){if(e!==this.#t)return this.#t=e,this.#r(),!0;this.#e[e]?.classList.remove("kint-weak-focus")}return!1}#o(t){if(this.#e.length===0)return this.#t=0,null;for(this.#t+=t;this.#t<0;)this.#t+=this.#e.length;for(;this.#t>=this.#e.length;)this.#t-=this.#e.length;return this.#r(),this.#t}#r(){let t=this.#n.document.querySelector(".kint-focused");t&&(t.classList.remove("kint-focused"),t.classList.remove("kint-weak-focus")),this.#s&&this.#e[this.#t]?.classList.add("kint-focused")}#l(t){if(this.#s&&t.keyCode===P&&t.target.matches(".kint-search")){t.target.blur(),this.#r();return}if(t.target!==this.#n.document.body||t.altKey||t.ctrlKey)return;if(t.keyCode===j){if(this.#s)this.#s=!1;else{if(this.#s=!0,this.onTreeChanged(),this.#e.length===0){this.#s=!1;return}this.scrollToFocus()}this.#r(),t.preventDefault();return}else if(t.keyCode===P){this.#s&&(this.#s=!1,this.#r(),t.preventDefault());return}else if(!this.#s)return;t.preventDefault();let e=this.#e[this.#t];if(d(e)||this.onTreeChanged(),[K,R,D,B,A].includes(t.keyCode)){t.keyCode===K?this.#o(t.shiftKey?-1:1):t.keyCode===R||t.keyCode===D?this.#o(-1):(t.keyCode===B||t.keyCode===A)&&this.#o(1),this.scrollToFocus();return}if(e.tagName==="LI"&&[L,S,p,k,N,v].includes(t.keyCode)){t.keyCode===L||t.keyCode===S?(a.switchTab(e),this.onTreeChanged()):t.keyCode===p||t.keyCode===k?this.#o(1):(t.keyCode===N||t.keyCode===v)&&this.#o(-1),this.scrollToFocus();return}let s=e.closest(".kint-parent");if(s){if(t.keyCode===H){a.toggleAccessPath(s);return}if(t.keyCode===M){let i=s.closest(".kint-rich > dl")?.querySelector(".kint-search")?.closest(".kint-parent");if(i){e.classList.add("kint-weak-focus"),m.toggleSearchBox(i,!0);return}}if(e.parentNode.tagName==="FOOTER"&&e.closest(".kint-rich")){t.keyCode===L||t.keyCode===S?e.parentNode.classList.toggle("kint-show"):t.keyCode===N||t.keyCode===v?e.parentNode.classList.remove("kint-show"):(t.keyCode===p||t.keyCode===k)&&e.parentNode.classList.add("kint-show");return}if(t.keyCode===L||t.keyCode===S){a.toggle(s),this.onTreeChanged();return}if([p,k,N,v].includes(t.keyCode)){let i=t.keyCode===p||t.keyCode===k,l=s.classList.contains("kint-show");if(i){l&&a.toggleChildren(s,i),a.toggle(s,i),this.onTreeChanged();return}else if(l){a.toggleChildren(s,i),a.toggle(s,i),this.onTreeChanged();return}else{let o=s.closest(".kint-rich .kint-parent ~ dd")?.parentNode.querySelector(".kint-parent > nav");o&&(this.setCursor(o),this.scrollToFocus());return}}}}};var C=class{#e;#t;constructor(t){if(!(t instanceof h))throw new Error("Invalid argument to Plain.constructor()");this.#e=t.window,t.runOnInit(this.#s.bind(this))}#s(){d(this.#t)||(this.#t=this.#e.document.querySelector("style.kint-plain-style")),this.#t&&f(this.#t)}};var y=class n{constructor(t){if(!(t instanceof h))throw new Error("Invalid argument to Plain.constructor()");t.runOnLoad(n.#e.bind(null,t.window))}static#e(t){let e={},s=t.document.querySelectorAll("[data-kint-microtime-group]");for(let i of s){let l=i.querySelector(".kint-microtime-lap");if(!l)continue;let o=i.getAttribute("data-kint-microtime-group"),r=parseFloat(l.textContent),c=parseFloat(i.querySelector(".kint-microtime-avg").textContent);e[o]??={min:r,max:r,avg:c},e[o].min>r&&(e[o].min=r),e[o].maxr.avg){let c=(o-r.avg)/(r.max-r.avg);l.style.background="hsl("+(40-40*c)+", 100%, 65%)"}else{let c=0;r.avg!==r.min&&(c=(r.avg-o)/(r.avg-r.min)),l.style.background="hsl("+(40+80*c)+", 100%, 65%)"}}}};var U=Symbol(),h=class n{static#e=null;#t;#s=[];#i=new Set;static init(t){return n.#e??=new n(t,U),n.#e.#n(),n.#e.runOnLoad(n.#r),n.#e}get window(){return this.#t}constructor(t,e){if(U!==e)throw new Error("Kint constructor is private. Use Kint.init()");if(!(t instanceof Window))throw new Error("Invalid argument to Kint.init()");this.#t=t,this.runOnInit(this.#o.bind(this)),new C(this),new a(this),new y(this)}runOnLoad(t){if(this.#t.document.readyState==="complete")try{t()}catch{}else this.#t.addEventListener("load",t)}runOnInit(t){this.#s.push(t)}#n(){this.#t.document.currentScript&&(this.#i.add(x(window.document.currentScript)),window.document.currentScript.remove())}#o(){for(let t of this.#i.keys())for(let e of this.#t.document.querySelectorAll(t))e.remove()}static#r(){for(let t of n.#e.#s)t()}};window.Kint||(window.Kint=h);window.Kint.init(window);})(); diff --git a/resources/compiled/microtime.js b/resources/compiled/microtime.js deleted file mode 100644 index ce6920ed9..000000000 --- a/resources/compiled/microtime.js +++ /dev/null @@ -1 +0,0 @@ -void 0===window.kintMicrotimeInitialized&&(window.kintMicrotimeInitialized=1,window.addEventListener("load",function(){var a={},t=Array.prototype.slice.call(document.querySelectorAll("[data-kint-microtime-group]"),0);t.forEach(function(t){var i,e;t.querySelector(".kint-microtime-lap")&&(i=t.getAttribute("data-kint-microtime-group"),e=parseFloat(t.querySelector(".kint-microtime-lap").innerHTML),t=parseFloat(t.querySelector(".kint-microtime-avg").innerHTML),void 0===a[i]&&(a[i]={}),(void 0===a[i].min||a[i].min>e)&&(a[i].min=e),(void 0===a[i].max||a[i].maxdl dl{padding:0 0 0 12px}.kint-rich dt.kint-parent>nav,.kint-rich>footer>nav{background:url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAzMCAxNTAiPjxnIHN0cm9rZS13aWR0aD0iMiIgZmlsbD0iI0ZGRiI+PHBhdGggZD0iTTEgMWgyOHYyOEgxem01IDE0aDE4bS05IDlWNk0xIDYxaDI4djI4SDF6bTUgMTRoMTgiIHN0cm9rZT0iIzM3OSIvPjxwYXRoIGQ9Ik0xIDMxaDI4djI4SDF6bTUgMTRoMThtLTkgOVYzNk0xIDkxaDI4djI4SDF6bTUgMTRoMTgiIHN0cm9rZT0iIzVBMyIvPjxwYXRoIGQ9Ik0xIDEyMWgyOHYyOEgxem01IDVsMTggMThtLTE4IDBsMTgtMTgiIHN0cm9rZT0iI0NDQyIvPjwvZz48L3N2Zz4=") no-repeat scroll 0 0/15px 75px rgba(0,0,0,0);cursor:pointer;display:inline-block;height:15px;width:15px;margin-right:3px;vertical-align:middle}.kint-rich dt.kint-parent:hover>nav,.kint-rich>footer>nav:hover{background-position:0 25%}.kint-rich dt.kint-parent.kint-show>nav,.kint-rich>footer.kint-show>nav{background-position:0 50%}.kint-rich dt.kint-parent.kint-show:hover>nav,.kint-rich>footer.kint-show>nav:hover{background-position:0 75%}.kint-rich dt.kint-parent.kint-locked>nav{background-position:0 100%}.kint-rich dt.kint-parent+dd{display:none;border-left:1px dashed #b6cedb}.kint-rich dt.kint-parent.kint-show+dd{display:block}.kint-rich var,.kint-rich var a{color:#0092db;font-style:normal}.kint-rich dt:hover var,.kint-rich dt:hover var a{color:#5cb730}.kint-rich dfn{font-style:normal;font-family:monospace;color:#1d1e1e}.kint-rich pre{color:#1d1e1e;margin:0 0 0 12px;padding:5px;overflow-y:hidden;border-top:0;border:1px solid #b6cedb;background:#e0eaef;display:block;word-break:normal}.kint-rich .kint-popup-trigger,.kint-rich .kint-access-path-trigger,.kint-rich .kint-search-trigger{background:rgba(29,30,30,.8);border-radius:3px;height:16px;font-size:16px;margin-left:5px;font-weight:bold;width:16px;text-align:center;float:right !important;cursor:pointer;color:#e0eaef;position:relative;overflow:hidden;line-height:17.6px}.kint-rich .kint-popup-trigger:hover,.kint-rich .kint-access-path-trigger:hover,.kint-rich .kint-search-trigger:hover{color:#1d1e1e;background:#e0eaef}.kint-rich dt.kint-parent>.kint-popup-trigger{line-height:19.2px}.kint-rich .kint-search-trigger{font-size:20px}.kint-rich input.kint-search{display:none;border:1px solid #b6cedb;border-top-width:0;border-bottom-width:0;padding:4px;float:right !important;margin:-4px 0;color:#1d1e1e;background:#c1d4df;height:24px;width:160px;position:relative;z-index:100}.kint-rich input.kint-search.kint-show{display:block}.kint-rich .kint-search-root ul.kint-tabs>li:not(.kint-search-match){background:#d0d0d0;opacity:.5}.kint-rich .kint-search-root dl:not(.kint-search-match){opacity:.5}.kint-rich .kint-search-root dl:not(.kint-search-match)>dt{background:#e8e8e8}.kint-rich .kint-search-root dl:not(.kint-search-match) dl,.kint-rich .kint-search-root dl:not(.kint-search-match) ul.kint-tabs>li:not(.kint-search-match){opacity:1}.kint-rich div.access-path{background:#c1d4df;display:none;margin-top:5px;padding:4px;white-space:pre}.kint-rich div.access-path.kint-show{display:block}.kint-rich footer{padding:0 3px 3px;font-size:9px;background:rgba(0,0,0,0)}.kint-rich footer>.kint-popup-trigger{background:rgba(0,0,0,0);color:#1d1e1e}.kint-rich footer nav{height:10px;width:10px;background-size:10px 50px}.kint-rich footer>ol{display:none;margin-left:32px}.kint-rich footer.kint-show>ol{display:block}.kint-rich a{color:#1d1e1e;text-shadow:none;text-decoration:underline}.kint-rich a:hover{color:#1d1e1e;border-bottom:1px dotted #1d1e1e}.kint-rich ul{list-style:none;padding-left:12px}.kint-rich ul:not(.kint-tabs) li{border-left:1px dashed #b6cedb}.kint-rich ul:not(.kint-tabs) li>dl{border-left:none}.kint-rich ul.kint-tabs{margin:0 0 0 12px;padding-left:0;background:#e0eaef;border:1px solid #b6cedb;border-top:0}.kint-rich ul.kint-tabs>li{background:#c1d4df;border:1px solid #b6cedb;cursor:pointer;display:inline-block;height:24px;margin:2px;padding:0 12px;vertical-align:top}.kint-rich ul.kint-tabs>li:hover,.kint-rich ul.kint-tabs>li.kint-active-tab:hover{border-color:#0092db;color:#5cb730}.kint-rich ul.kint-tabs>li.kint-active-tab{background:#e0eaef;border-top:0;margin-top:-1px;height:27px;line-height:24px}.kint-rich ul.kint-tabs>li:not(.kint-active-tab){line-height:20px}.kint-rich ul.kint-tabs li+li{margin-left:0}.kint-rich ul.kint-tab-contents>li{display:none}.kint-rich ul.kint-tab-contents>li.kint-show{display:block}.kint-rich dt:hover+dd>ul>li.kint-active-tab{border-color:#0092db;color:#5cb730}.kint-rich dt>.kint-color-preview{width:16px;height:16px;display:inline-block;vertical-align:middle;margin-left:10px;border:1px solid #b6cedb;background-color:#ccc;background-image:url('data:image/svg+xml;utf8,');background-size:100%}.kint-rich dt>.kint-color-preview:hover{border-color:#0092db}.kint-rich dt>.kint-color-preview>div{width:100%;height:100%}.kint-rich table{border-collapse:collapse;empty-cells:show;border-spacing:0}.kint-rich table *{font-size:12px}.kint-rich table dt{background:none;padding:2px}.kint-rich table dt .kint-parent{min-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.kint-rich table td,.kint-rich table th{border:1px solid #b6cedb;padding:2px;vertical-align:center}.kint-rich table th{cursor:alias}.kint-rich table td:first-child,.kint-rich table th{font-weight:bold;background:#c1d4df;color:#1d1e1e}.kint-rich table td{background:#e0eaef;white-space:pre}.kint-rich table td>dl{padding:0}.kint-rich table pre{border-top:0;border-right:0}.kint-rich table thead th:first-child{background:none;border:0}.kint-rich table tr:hover>td{box-shadow:0 0 1px 0 #0092db inset}.kint-rich table tr:hover var{color:#5cb730}.kint-rich table ul.kint-tabs li.kint-active-tab{height:20px;line-height:17px}.kint-rich pre.kint-source{margin-left:-1px}.kint-rich pre.kint-source[data-kint-filename]:before{display:block;content:attr(data-kint-filename);margin-bottom:4px;padding-bottom:4px;border-bottom:1px solid #c1d4df}.kint-rich pre.kint-source>div:before{display:inline-block;content:counter(kint-l);counter-increment:kint-l;border-right:1px solid #0092db;padding-right:8px;margin-right:8px}.kint-rich pre.kint-source>div.kint-highlight{background:#c1d4df}.kint-rich .kint-microtime-lap{text-shadow:-1px 0 #0092db,0 1px #0092db,1px 0 #0092db,0 -1px #0092db;color:#e0eaef;font-weight:bold}input.kint-note-input{width:100%}.kint-rich>dl>dt{background:linear-gradient(to bottom, #e3ecf0 0, #c0d4df 100%)}.kint-rich ul.kint-tabs{background:linear-gradient(to bottom, #9dbed0 0px, #b2ccda 100%)}.kint-rich>dl:not(.kint-trace)>dd>ul.kint-tabs li{background:#e0eaef}.kint-rich>dl:not(.kint-trace)>dd>ul.kint-tabs li.kint-active-tab{background:#c1d4df}.kint-rich>dl.kint-trace>dt{background:linear-gradient(to bottom, #c0d4df 0px, #e3ecf0 100%)}.kint-rich .kint-source .kint-highlight{background:#f0eb96} +.kint-rich{font-size:13px;overflow-x:auto;white-space:nowrap;background:rgba(255,255,255,.9)}.kint-rich.kint-folder{position:fixed;bottom:0;left:0;right:0;z-index:999999;width:100%;margin:0;display:block}.kint-rich.kint-folder dd.kint-foldout{max-height:calc(100vh - 100px);padding-right:8px;overflow-y:scroll;display:none}.kint-rich.kint-folder dd.kint-foldout.kint-show{display:block}.kint-rich::selection,.kint-rich::-moz-selection,.kint-rich::-webkit-selection{background:#0092db;color:#1d1e1e}.kint-rich .kint-focused{box-shadow:0 0 3px 3px #5cb730}.kint-rich .kint-focused.kint-weak-focus{box-shadow:0 0 3px 1px rgba(92,183,48,.5)}.kint-rich,.kint-rich::before,.kint-rich::after,.kint-rich *,.kint-rich *::before,.kint-rich *::after{box-sizing:border-box;border-radius:0;color:#1d1e1e;float:none !important;font-family:Consolas,Menlo,Monaco,Lucida Console,Liberation Mono,DejaVu Sans Mono,Bitstream Vera Sans Mono,Courier New,monospace,serif;line-height:15px;margin:0;padding:0;text-align:left}.kint-rich{margin:8px 0}.kint-rich dt,.kint-rich dl{width:auto}.kint-rich dt,.kint-rich div.access-path{background:#e0eaef;border:1px solid #b6cedb;color:#1d1e1e;display:block;font-weight:bold;list-style:none outside none;overflow:auto;padding:4px}.kint-rich dt:hover,.kint-rich div.access-path:hover{border-color:#0092db}.kint-rich>dl dl{padding:0 0 0 12px}.kint-rich dt.kint-parent>nav,.kint-rich>footer>nav{background:url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAzMCAxNTAiPjxnIHN0cm9rZS13aWR0aD0iMiIgZmlsbD0iI0ZGRiI+PHBhdGggZD0iTTEgMWgyOHYyOEgxem01IDE0aDE4bS05IDlWNk0xIDYxaDI4djI4SDF6bTUgMTRoMTgiIHN0cm9rZT0iIzM3OSIvPjxwYXRoIGQ9Ik0xIDMxaDI4djI4SDF6bTUgMTRoMThtLTkgOVYzNk0xIDkxaDI4djI4SDF6bTUgMTRoMTgiIHN0cm9rZT0iIzVBMyIvPjxwYXRoIGQ9Ik0xIDEyMWgyOHYyOEgxem01IDVsMTggMThtLTE4IDBsMTgtMTgiIHN0cm9rZT0iI0NDQyIvPjwvZz48L3N2Zz4=") no-repeat scroll 0 0/15px 75px rgba(0,0,0,0);cursor:pointer;display:inline-block;height:15px;width:15px;margin-right:3px;vertical-align:middle}.kint-rich dt.kint-parent:hover>nav,.kint-rich>footer>nav:hover{background-position:0 25%}.kint-rich dt.kint-parent.kint-show>nav,.kint-rich>footer.kint-show>nav{background-position:0 50%}.kint-rich dt.kint-parent.kint-show:hover>nav,.kint-rich>footer.kint-show>nav:hover{background-position:0 75%}.kint-rich dt.kint-parent.kint-locked>nav{background-position:0 100%}.kint-rich dt.kint-parent+dd{display:none;border-left:1px dashed #b6cedb}.kint-rich dt.kint-parent.kint-show+dd{display:block}.kint-rich var,.kint-rich var a{color:#0092db;font-style:normal}.kint-rich dt:hover var,.kint-rich dt:hover var a{color:#5cb730}.kint-rich dfn{font-style:normal;font-family:monospace;color:#1d1e1e}.kint-rich pre{color:#1d1e1e;margin:0 0 0 12px;padding:5px;overflow-y:hidden;border-top:0;border:1px solid #b6cedb;background:#e0eaef;display:block;word-break:normal}.kint-rich .kint-access-path-trigger,.kint-rich .kint-search-trigger{background:rgba(29,30,30,.8);border-radius:3px;height:16px;font-size:16px;margin-left:5px;font-weight:bold;width:16px;text-align:center;float:right !important;cursor:pointer;color:#e0eaef;position:relative;overflow:hidden;line-height:17.6px}.kint-rich .kint-access-path-trigger:hover,.kint-rich .kint-search-trigger:hover{color:#1d1e1e;background:#e0eaef}.kint-rich .kint-search-trigger{font-size:20px}.kint-rich input.kint-search{display:none;border:1px solid #b6cedb;border-top-width:0;border-bottom-width:0;padding:4px;float:right !important;margin:-4px 0;color:#1d1e1e;background:#c1d4df;height:24px;width:160px;position:relative;z-index:100}.kint-rich input.kint-search.kint-show{display:block}.kint-rich .kint-search-root ul.kint-tabs>li:not(.kint-search-match){background:#d0d0d0;opacity:.5}.kint-rich .kint-search-root dl:not(.kint-search-match){opacity:.5}.kint-rich .kint-search-root dl:not(.kint-search-match)>dt{background:#e8e8e8}.kint-rich .kint-search-root dl:not(.kint-search-match) dl,.kint-rich .kint-search-root dl:not(.kint-search-match) ul.kint-tabs>li:not(.kint-search-match){opacity:1}.kint-rich div.access-path{background:#c1d4df;display:none;margin-top:5px;padding:4px;white-space:pre}.kint-rich div.access-path.kint-show{display:block}.kint-rich footer{padding:0 3px 3px;font-size:9px;background:rgba(0,0,0,0)}.kint-rich footer nav{height:10px;width:10px;background-size:10px 50px}.kint-rich footer>ol{display:none;margin-left:32px}.kint-rich footer.kint-show>ol{display:block}.kint-rich a{color:#1d1e1e;text-shadow:none;text-decoration:underline}.kint-rich a:hover{color:#1d1e1e;border-bottom:1px dotted #1d1e1e}.kint-rich ul{list-style:none;padding-left:12px}.kint-rich ul:not(.kint-tabs) li{border-left:1px dashed #b6cedb}.kint-rich ul:not(.kint-tabs) li>dl{border-left:none}.kint-rich ul.kint-tabs{margin:0 0 0 12px;padding-left:0;background:#e0eaef;border:1px solid #b6cedb;border-top:0}.kint-rich ul.kint-tabs>li{background:#c1d4df;border:1px solid #b6cedb;cursor:pointer;display:inline-block;height:24px;margin:2px;padding:0 12px;vertical-align:top}.kint-rich ul.kint-tabs>li:hover,.kint-rich ul.kint-tabs>li.kint-active-tab:hover{border-color:#0092db;color:#5cb730}.kint-rich ul.kint-tabs>li.kint-active-tab{background:#e0eaef;border-top:0;margin-top:-1px;height:27px;line-height:24px}.kint-rich ul.kint-tabs>li:not(.kint-active-tab){line-height:20px}.kint-rich ul.kint-tabs li+li{margin-left:0}.kint-rich ul.kint-tab-contents>li{display:none}.kint-rich ul.kint-tab-contents>li.kint-show{display:block}.kint-rich dt:hover+dd>ul>li.kint-active-tab{border-color:#0092db;color:#5cb730}.kint-rich dt>.kint-color-preview{width:16px;height:16px;display:inline-block;vertical-align:middle;margin-left:10px;border:1px solid #b6cedb;background-color:#ccc;background-image:url('data:image/svg+xml;utf8,');background-size:100%}.kint-rich dt>.kint-color-preview:hover{border-color:#0092db}.kint-rich dt>.kint-color-preview>div{width:100%;height:100%}.kint-rich table{border-collapse:collapse;empty-cells:show;border-spacing:0}.kint-rich table *{font-size:12px}.kint-rich table dt{background:none;padding:2px}.kint-rich table dt .kint-parent{min-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.kint-rich table td,.kint-rich table th{border:1px solid #b6cedb;padding:2px;vertical-align:center}.kint-rich table th{cursor:alias}.kint-rich table td:first-child,.kint-rich table th{font-weight:bold;background:#c1d4df;color:#1d1e1e}.kint-rich table td{background:#e0eaef;white-space:pre}.kint-rich table td>dl{padding:0}.kint-rich table pre{border-top:0;border-right:0}.kint-rich table thead th:first-child{background:none;border:0}.kint-rich table tr:hover>td{box-shadow:0 0 1px 0 #0092db inset}.kint-rich table tr:hover var{color:#5cb730}.kint-rich table ul.kint-tabs li.kint-active-tab{height:20px;line-height:17px}.kint-rich pre.kint-source{margin-left:-1px}.kint-rich pre.kint-source[data-kint-filename]:before{display:block;content:attr(data-kint-filename);margin-bottom:4px;padding-bottom:4px;border-bottom:1px solid #c1d4df}.kint-rich pre.kint-source>div:before{display:inline-block;content:counter(kint-l);counter-increment:kint-l;border-right:1px solid #0092db;padding-right:8px;margin-right:8px}.kint-rich pre.kint-source>div.kint-highlight{background:#c1d4df}.kint-rich .kint-microtime-js .kint-microtime-lap{text-shadow:-1px 0 #0092db,0 1px #0092db,1px 0 #0092db,0 -1px #0092db;color:#e0eaef;font-weight:bold}input.kint-note-input{width:100%}.kint-rich>dl>dt{background:linear-gradient(to bottom, #e3ecf0 0, #c0d4df 100%)}.kint-rich ul.kint-tabs{background:linear-gradient(to bottom, #9dbed0 0px, #b2ccda 100%)}.kint-rich>dl:not(.kint-trace)>dd>ul.kint-tabs li{background:#e0eaef}.kint-rich>dl:not(.kint-trace)>dd>ul.kint-tabs li.kint-active-tab{background:#c1d4df}.kint-rich>dl.kint-trace>dt{background:linear-gradient(to bottom, #c0d4df 0px, #e3ecf0 100%)}.kint-rich .kint-source .kint-highlight{background:#f0eb96} diff --git a/resources/compiled/plain.css b/resources/compiled/plain.css index 85a4e7394..076aced4f 100644 --- a/resources/compiled/plain.css +++ b/resources/compiled/plain.css @@ -1 +1 @@ -.kint-plain{background:rgba(255,255,255,.9);white-space:pre;display:block;font-family:monospace;color:#222}.kint-plain i{color:#d00;font-style:normal}.kint-plain u{color:#030;text-decoration:none;font-weight:bold}.kint-plain .kint-microtime-lap{font-weight:bold;text-shadow:1px 0 #fff,0 1px #fff,-1px 0 #fff,0 -1px #fff} +.kint-plain{background:rgba(255,255,255,.9);white-space:pre;display:block;font-family:monospace;color:#222}.kint-plain i{color:#d00;font-style:normal}.kint-plain u{color:#030;text-decoration:none;font-weight:bold}.kint-plain .kint-microtime-js .kint-microtime-lap{text-shadow:1px 0 #d00,0 1px #d00,-1px 0 #d00,0 -1px #d00;color:#fff;font-weight:bold} diff --git a/resources/compiled/plain.js b/resources/compiled/plain.js deleted file mode 100644 index 123bdcc81..000000000 --- a/resources/compiled/plain.js +++ /dev/null @@ -1 +0,0 @@ -void 0===window.kintPlain&&(window.kintPlain=function(){var i={initLoad:function(){i.style=window.kintShared.dedupe("style.kint-plain-style",i.style),i.script=window.kintShared.dedupe("script.kint-plain-script",i.script)},style:null,script:null};return i}()),window.kintShared.runOnce(window.kintPlain.initLoad); diff --git a/resources/compiled/rich.js b/resources/compiled/rich.js deleted file mode 100644 index faff87f15..000000000 --- a/resources/compiled/rich.js +++ /dev/null @@ -1 +0,0 @@ -void 0===window.kintRich&&(window.kintRich=function(){var l={selectText:function(e){var t=window.getSelection(),a=document.createRange();a.selectNodeContents(e),t.removeAllRanges(),t.addRange(a)},toggle:function(e,t){var a=l.getChildren(e);a&&(e.classList.toggle("kint-show",t),1===a.childNodes.length)&&(a=a.childNodes[0].childNodes[0])&&a.classList&&a.classList.contains("kint-parent")&&l.toggle(a,t)},toggleChildren:function(e,t){var a=l.getChildren(e);if(a){var o=a.getElementsByClassName("kint-parent"),s=o.length;for(void 0===t&&(t=e.classList.contains("kint-show"));s--;)l.toggle(o[s],t)}},switchTab:function(e){var t=e.previousSibling,a=0;for(e.parentNode.getElementsByClassName("kint-active-tab")[0].classList.remove("kint-active-tab"),e.classList.add("kint-active-tab");t;)1===t.nodeType&&a++,t=t.previousSibling;for(var o=e.parentNode.nextSibling.childNodes,s=0;s"},openInNewWindow:function(e){var t=window.open();t&&(t.document.open(),t.document.write(l.mktag("html")+l.mktag("head")+l.mktag("title")+"Kint ("+(new Date).toISOString()+")"+l.mktag("/title")+l.mktag('meta charset="utf-8"')+l.mktag('script class="kint-rich-script" nonce="'+l.script.nonce+'"')+l.script.innerHTML+l.mktag("/script")+l.mktag('style class="kint-rich-style" nonce="'+l.style.nonce+'"')+l.style.innerHTML+l.mktag("/style")+l.mktag("/head")+l.mktag("body")+'
'+e.parentNode.outerHTML+"
"+l.mktag("/body")),t.document.close())},sortTable:function(e,a){var t=e.tBodies[0];[].slice.call(e.tBodies[0].rows).sort(function(e,t){if(e=e.cells[a].textContent.trim().toLocaleLowerCase(),t=t.cells[a].textContent.trim().toLocaleLowerCase(),isNaN(e)||isNaN(t)){if(isNaN(e)&&!isNaN(t))return 1;if(isNaN(t)&&!isNaN(e))return-1}else e=parseFloat(e),t=parseFloat(t);return eli:not(.kint-active-tab)").forEach(function(e){l.isFolderOpen()&&!l.folder.contains(e)||0===e.offsetWidth&&0===e.offsetHeight||l.keyboardNav.targets.push(e)}),e&&-1!==l.keyboardNav.targets.indexOf(e)&&(l.keyboardNav.target=l.keyboardNav.targets.indexOf(e))},sync:function(e){var t=document.querySelector(".kint-focused");t&&t.classList.remove("kint-focused"),l.keyboardNav.active&&((t=l.keyboardNav.targets[l.keyboardNav.target]).classList.add("kint-focused"),e||l.keyboardNav.scroll(t))},scroll:function(e){var t,a;l.folder&&e===l.folder.querySelector("dt > nav")||(e=(t=function(e){return e.offsetTop+(e.offsetParent?t(e.offsetParent):0)})(e),l.isFolderOpen()?(a=l.folder.querySelector("dd.kint-foldout")).scrollTo(0,e-a.clientHeight/2):window.scrollTo(0,e-window.innerHeight/2))},moveCursor:function(e){for(l.keyboardNav.target+=e;l.keyboardNav.target<0;)l.keyboardNav.target+=l.keyboardNav.targets.length;for(;l.keyboardNav.target>=l.keyboardNav.targets.length;)l.keyboardNav.target-=l.keyboardNav.targets.length;l.keyboardNav.sync()},setCursor:function(e){if(!l.isFolderOpen()||l.folder.contains(e)){l.keyboardNav.fetchTargets();for(var t=0;tdl dl{padding:0 0 0 15px}.kint-rich dt.kint-parent>nav,.kint-rich>footer>nav{background:url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB2aWV3Qm94PSIwIDAgMzAgMTUwIj48ZGVmcz48cGF0aCBzdHJva2UtbGluZWpvaW49InJvdW5kIiBkPSJNNCAzYTI0IDMyIDAgMCAxIDAgMjQgNDAgMjAtMTAgMCAxIDIzLTEyQTQwIDIwIDEwIDAgMSA0IDN6IiBpZD0iYSIvPjwvZGVmcz48ZyBmaWxsPSIjOTNhMWExIiBzdHJva2U9IiM5M2ExYTEiPjx1c2UgeGxpbms6aHJlZj0iI2EiLz48dXNlIHhsaW5rOmhyZWY9IiNhIiB0cmFuc2Zvcm09InJvdGF0ZSg5MCAtMTUgNDUpIi8+PC9nPjxnIGZpbGw9IiM1ODZlNzUiIHN0cm9rZT0iIzU4NmU3NSIgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoMCAzMCkiPjx1c2UgeGxpbms6aHJlZj0iI2EiLz48dXNlIHhsaW5rOmhyZWY9IiNhIiB0cmFuc2Zvcm09InJvdGF0ZSg5MCAtMTUgNDUpIi8+PC9nPjxwYXRoIGQ9Ik02IDEyNmwxOCAxOG0tMTggMGwxOC0xOCIgc3Ryb2tlLXdpZHRoPSIyIiBzdHJva2U9IiM1ODZlNzUiLz48L3N2Zz4=") no-repeat scroll 0 0/15px 75px rgba(0,0,0,0);cursor:pointer;display:inline-block;height:15px;width:15px;margin-right:3px;vertical-align:middle}.kint-rich dt.kint-parent:hover>nav,.kint-rich>footer>nav:hover{background-position:0 25%}.kint-rich dt.kint-parent.kint-show>nav,.kint-rich>footer.kint-show>nav{background-position:0 50%}.kint-rich dt.kint-parent.kint-show:hover>nav,.kint-rich>footer.kint-show>nav:hover{background-position:0 75%}.kint-rich dt.kint-parent.kint-locked>nav{background-position:0 100%}.kint-rich dt.kint-parent+dd{display:none;border-left:1px dashed #586e75}.kint-rich dt.kint-parent.kint-show+dd{display:block}.kint-rich var,.kint-rich var a{color:#268bd2;font-style:normal}.kint-rich dt:hover var,.kint-rich dt:hover var a{color:#2aa198}.kint-rich dfn{font-style:normal;font-family:monospace;color:#93a1a1}.kint-rich pre{color:#839496;margin:0 0 0 15px;padding:5px;overflow-y:hidden;border-top:0;border:1px solid #586e75;background:#002b36;display:block;word-break:normal}.kint-rich .kint-popup-trigger,.kint-rich .kint-access-path-trigger,.kint-rich .kint-search-trigger{background:rgba(131,148,150,.8);border-radius:3px;height:16px;font-size:16px;margin-left:5px;font-weight:bold;width:16px;text-align:center;float:right !important;cursor:pointer;color:#002b36;position:relative;overflow:hidden;line-height:17.6px}.kint-rich .kint-popup-trigger:hover,.kint-rich .kint-access-path-trigger:hover,.kint-rich .kint-search-trigger:hover{color:#839496;background:#002b36}.kint-rich dt.kint-parent>.kint-popup-trigger{line-height:19.2px}.kint-rich .kint-search-trigger{font-size:20px}.kint-rich input.kint-search{display:none;border:1px solid #586e75;border-top-width:0;border-bottom-width:0;padding:5px;float:right !important;margin:-5px 0;color:#93a1a1;background:#073642;height:26px;width:160px;position:relative;z-index:100}.kint-rich input.kint-search.kint-show{display:block}.kint-rich .kint-search-root ul.kint-tabs>li:not(.kint-search-match){background:#252525;opacity:.5}.kint-rich .kint-search-root dl:not(.kint-search-match){opacity:.5}.kint-rich .kint-search-root dl:not(.kint-search-match)>dt{background:#1b1b1b}.kint-rich .kint-search-root dl:not(.kint-search-match) dl,.kint-rich .kint-search-root dl:not(.kint-search-match) ul.kint-tabs>li:not(.kint-search-match){opacity:1}.kint-rich div.access-path{background:#073642;display:none;margin-top:5px;padding:4px;white-space:pre}.kint-rich div.access-path.kint-show{display:block}.kint-rich footer{padding:0 3px 3px;font-size:9px;background:rgba(0,0,0,0)}.kint-rich footer>.kint-popup-trigger{background:rgba(0,0,0,0);color:#839496}.kint-rich footer nav{height:10px;width:10px;background-size:10px 50px}.kint-rich footer>ol{display:none;margin-left:32px}.kint-rich footer.kint-show>ol{display:block}.kint-rich a{color:#839496;text-shadow:none;text-decoration:underline}.kint-rich a:hover{color:#93a1a1;border-bottom:1px dotted #93a1a1}.kint-rich ul{list-style:none;padding-left:15px}.kint-rich ul:not(.kint-tabs) li{border-left:1px dashed #586e75}.kint-rich ul:not(.kint-tabs) li>dl{border-left:none}.kint-rich ul.kint-tabs{margin:0 0 0 15px;padding-left:0;background:#002b36;border:1px solid #586e75;border-top:0}.kint-rich ul.kint-tabs>li{background:#073642;border:1px solid #586e75;cursor:pointer;display:inline-block;height:30px;margin:3px;padding:0 15px;vertical-align:top}.kint-rich ul.kint-tabs>li:hover,.kint-rich ul.kint-tabs>li.kint-active-tab:hover{border-color:#268bd2;color:#2aa198}.kint-rich ul.kint-tabs>li.kint-active-tab{background:#002b36;border-top:0;margin-top:-1px;height:27px;line-height:24px}.kint-rich ul.kint-tabs>li:not(.kint-active-tab){line-height:25px}.kint-rich ul.kint-tabs li+li{margin-left:0}.kint-rich ul.kint-tab-contents>li{display:none}.kint-rich ul.kint-tab-contents>li.kint-show{display:block}.kint-rich dt:hover+dd>ul>li.kint-active-tab{border-color:#268bd2;color:#2aa198}.kint-rich dt>.kint-color-preview{width:16px;height:16px;display:inline-block;vertical-align:middle;margin-left:10px;border:1px solid #586e75;background-color:#ccc;background-image:url('data:image/svg+xml;utf8,');background-size:100%}.kint-rich dt>.kint-color-preview:hover{border-color:#268bd2}.kint-rich dt>.kint-color-preview>div{width:100%;height:100%}.kint-rich table{border-collapse:collapse;empty-cells:show;border-spacing:0}.kint-rich table *{font-size:12px}.kint-rich table dt{background:none;padding:2.5px}.kint-rich table dt .kint-parent{min-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.kint-rich table td,.kint-rich table th{border:1px solid #586e75;padding:2.5px;vertical-align:center}.kint-rich table th{cursor:alias}.kint-rich table td:first-child,.kint-rich table th{font-weight:bold;background:#073642;color:#93a1a1}.kint-rich table td{background:#002b36;white-space:pre}.kint-rich table td>dl{padding:0}.kint-rich table pre{border-top:0;border-right:0}.kint-rich table thead th:first-child{background:none;border:0}.kint-rich table tr:hover>td{box-shadow:0 0 1px 0 #268bd2 inset}.kint-rich table tr:hover var{color:#2aa198}.kint-rich table ul.kint-tabs li.kint-active-tab{height:20px;line-height:17px}.kint-rich pre.kint-source{margin-left:-1px}.kint-rich pre.kint-source[data-kint-filename]:before{display:block;content:attr(data-kint-filename);margin-bottom:5px;padding-bottom:5px;border-bottom:1px solid #073642}.kint-rich pre.kint-source>div:before{display:inline-block;content:counter(kint-l);counter-increment:kint-l;border-right:1px solid #268bd2;padding-right:10px;margin-right:10px}.kint-rich pre.kint-source>div.kint-highlight{background:#073642}.kint-rich .kint-microtime-lap{text-shadow:-1px 0 #268bd2,0 1px #268bd2,1px 0 #268bd2,0 -1px #268bd2;color:#002b36;font-weight:bold}input.kint-note-input{width:100%}.kint-rich .kint-focused{box-shadow:0 0 3px 2px #859900 inset;border-radius:7px}.kint-rich>dl>dt,.kint-rich ul.kint-tabs{box-shadow:4px 0 2px -3px #268bd2 inset}.kint-rich ul.kint-tabs li.kint-active-tab{padding-top:7px;height:34px}.kint-rich footer li{color:#ddd} +.kint-rich{font-size:13px;overflow-x:auto;white-space:nowrap;background:#073642}.kint-rich.kint-folder{position:fixed;bottom:0;left:0;right:0;z-index:999999;width:100%;margin:0;display:block}.kint-rich.kint-folder dd.kint-foldout{max-height:calc(100vh - 100px);padding-right:10px;overflow-y:scroll;display:none}.kint-rich.kint-folder dd.kint-foldout.kint-show{display:block}.kint-rich::selection,.kint-rich::-moz-selection,.kint-rich::-webkit-selection{background:#268bd2;color:#839496}.kint-rich .kint-focused{box-shadow:0 0 3px 3px #2aa198}.kint-rich .kint-focused.kint-weak-focus{box-shadow:0 0 3px 1px rgba(42,161,152,.5)}.kint-rich,.kint-rich::before,.kint-rich::after,.kint-rich *,.kint-rich *::before,.kint-rich *::after{box-sizing:border-box;border-radius:0;color:#839496;float:none !important;font-family:Consolas,Menlo,Monaco,Lucida Console,Liberation Mono,DejaVu Sans Mono,Bitstream Vera Sans Mono,Courier New,monospace,serif;line-height:15px;margin:0;padding:0;text-align:left}.kint-rich{margin:10px 0}.kint-rich dt,.kint-rich dl{width:auto}.kint-rich dt,.kint-rich div.access-path{background:#002b36;border:1px solid #586e75;color:#839496;display:block;font-weight:bold;list-style:none outside none;overflow:auto;padding:5px}.kint-rich dt:hover,.kint-rich div.access-path:hover{border-color:#268bd2}.kint-rich>dl dl{padding:0 0 0 15px}.kint-rich dt.kint-parent>nav,.kint-rich>footer>nav{background:url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB2aWV3Qm94PSIwIDAgMzAgMTUwIj48ZGVmcz48cGF0aCBzdHJva2UtbGluZWpvaW49InJvdW5kIiBkPSJNNCAzYTI0IDMyIDAgMCAxIDAgMjQgNDAgMjAtMTAgMCAxIDIzLTEyQTQwIDIwIDEwIDAgMSA0IDN6IiBpZD0iYSIvPjwvZGVmcz48ZyBmaWxsPSIjOTNhMWExIiBzdHJva2U9IiM5M2ExYTEiPjx1c2UgeGxpbms6aHJlZj0iI2EiLz48dXNlIHhsaW5rOmhyZWY9IiNhIiB0cmFuc2Zvcm09InJvdGF0ZSg5MCAtMTUgNDUpIi8+PC9nPjxnIGZpbGw9IiM1ODZlNzUiIHN0cm9rZT0iIzU4NmU3NSIgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoMCAzMCkiPjx1c2UgeGxpbms6aHJlZj0iI2EiLz48dXNlIHhsaW5rOmhyZWY9IiNhIiB0cmFuc2Zvcm09InJvdGF0ZSg5MCAtMTUgNDUpIi8+PC9nPjxwYXRoIGQ9Ik02IDEyNmwxOCAxOG0tMTggMGwxOC0xOCIgc3Ryb2tlLXdpZHRoPSIyIiBzdHJva2U9IiM1ODZlNzUiLz48L3N2Zz4=") no-repeat scroll 0 0/15px 75px rgba(0,0,0,0);cursor:pointer;display:inline-block;height:15px;width:15px;margin-right:3px;vertical-align:middle}.kint-rich dt.kint-parent:hover>nav,.kint-rich>footer>nav:hover{background-position:0 25%}.kint-rich dt.kint-parent.kint-show>nav,.kint-rich>footer.kint-show>nav{background-position:0 50%}.kint-rich dt.kint-parent.kint-show:hover>nav,.kint-rich>footer.kint-show>nav:hover{background-position:0 75%}.kint-rich dt.kint-parent.kint-locked>nav{background-position:0 100%}.kint-rich dt.kint-parent+dd{display:none;border-left:1px dashed #586e75}.kint-rich dt.kint-parent.kint-show+dd{display:block}.kint-rich var,.kint-rich var a{color:#268bd2;font-style:normal}.kint-rich dt:hover var,.kint-rich dt:hover var a{color:#2aa198}.kint-rich dfn{font-style:normal;font-family:monospace;color:#93a1a1}.kint-rich pre{color:#839496;margin:0 0 0 15px;padding:5px;overflow-y:hidden;border-top:0;border:1px solid #586e75;background:#002b36;display:block;word-break:normal}.kint-rich .kint-access-path-trigger,.kint-rich .kint-search-trigger{background:rgba(131,148,150,.8);border-radius:3px;height:16px;font-size:16px;margin-left:5px;font-weight:bold;width:16px;text-align:center;float:right !important;cursor:pointer;color:#002b36;position:relative;overflow:hidden;line-height:17.6px}.kint-rich .kint-access-path-trigger:hover,.kint-rich .kint-search-trigger:hover{color:#839496;background:#002b36}.kint-rich .kint-search-trigger{font-size:20px}.kint-rich input.kint-search{display:none;border:1px solid #586e75;border-top-width:0;border-bottom-width:0;padding:5px;float:right !important;margin:-5px 0;color:#93a1a1;background:#073642;height:26px;width:160px;position:relative;z-index:100}.kint-rich input.kint-search.kint-show{display:block}.kint-rich .kint-search-root ul.kint-tabs>li:not(.kint-search-match){background:#252525;opacity:.5}.kint-rich .kint-search-root dl:not(.kint-search-match){opacity:.5}.kint-rich .kint-search-root dl:not(.kint-search-match)>dt{background:#1b1b1b}.kint-rich .kint-search-root dl:not(.kint-search-match) dl,.kint-rich .kint-search-root dl:not(.kint-search-match) ul.kint-tabs>li:not(.kint-search-match){opacity:1}.kint-rich div.access-path{background:#073642;display:none;margin-top:5px;padding:4px;white-space:pre}.kint-rich div.access-path.kint-show{display:block}.kint-rich footer{padding:0 3px 3px;font-size:9px;background:rgba(0,0,0,0)}.kint-rich footer nav{height:10px;width:10px;background-size:10px 50px}.kint-rich footer>ol{display:none;margin-left:32px}.kint-rich footer.kint-show>ol{display:block}.kint-rich a{color:#839496;text-shadow:none;text-decoration:underline}.kint-rich a:hover{color:#93a1a1;border-bottom:1px dotted #93a1a1}.kint-rich ul{list-style:none;padding-left:15px}.kint-rich ul:not(.kint-tabs) li{border-left:1px dashed #586e75}.kint-rich ul:not(.kint-tabs) li>dl{border-left:none}.kint-rich ul.kint-tabs{margin:0 0 0 15px;padding-left:0;background:#002b36;border:1px solid #586e75;border-top:0}.kint-rich ul.kint-tabs>li{background:#073642;border:1px solid #586e75;cursor:pointer;display:inline-block;height:30px;margin:3px;padding:0 15px;vertical-align:top}.kint-rich ul.kint-tabs>li:hover,.kint-rich ul.kint-tabs>li.kint-active-tab:hover{border-color:#268bd2;color:#2aa198}.kint-rich ul.kint-tabs>li.kint-active-tab{background:#002b36;border-top:0;margin-top:-1px;height:27px;line-height:24px}.kint-rich ul.kint-tabs>li:not(.kint-active-tab){line-height:25px}.kint-rich ul.kint-tabs li+li{margin-left:0}.kint-rich ul.kint-tab-contents>li{display:none}.kint-rich ul.kint-tab-contents>li.kint-show{display:block}.kint-rich dt:hover+dd>ul>li.kint-active-tab{border-color:#268bd2;color:#2aa198}.kint-rich dt>.kint-color-preview{width:16px;height:16px;display:inline-block;vertical-align:middle;margin-left:10px;border:1px solid #586e75;background-color:#ccc;background-image:url('data:image/svg+xml;utf8,');background-size:100%}.kint-rich dt>.kint-color-preview:hover{border-color:#268bd2}.kint-rich dt>.kint-color-preview>div{width:100%;height:100%}.kint-rich table{border-collapse:collapse;empty-cells:show;border-spacing:0}.kint-rich table *{font-size:12px}.kint-rich table dt{background:none;padding:2.5px}.kint-rich table dt .kint-parent{min-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.kint-rich table td,.kint-rich table th{border:1px solid #586e75;padding:2.5px;vertical-align:center}.kint-rich table th{cursor:alias}.kint-rich table td:first-child,.kint-rich table th{font-weight:bold;background:#073642;color:#93a1a1}.kint-rich table td{background:#002b36;white-space:pre}.kint-rich table td>dl{padding:0}.kint-rich table pre{border-top:0;border-right:0}.kint-rich table thead th:first-child{background:none;border:0}.kint-rich table tr:hover>td{box-shadow:0 0 1px 0 #268bd2 inset}.kint-rich table tr:hover var{color:#2aa198}.kint-rich table ul.kint-tabs li.kint-active-tab{height:20px;line-height:17px}.kint-rich pre.kint-source{margin-left:-1px}.kint-rich pre.kint-source[data-kint-filename]:before{display:block;content:attr(data-kint-filename);margin-bottom:5px;padding-bottom:5px;border-bottom:1px solid #073642}.kint-rich pre.kint-source>div:before{display:inline-block;content:counter(kint-l);counter-increment:kint-l;border-right:1px solid #268bd2;padding-right:10px;margin-right:10px}.kint-rich pre.kint-source>div.kint-highlight{background:#073642}.kint-rich .kint-microtime-js .kint-microtime-lap{text-shadow:-1px 0 #268bd2,0 1px #268bd2,1px 0 #268bd2,0 -1px #268bd2;color:#002b36;font-weight:bold}input.kint-note-input{width:100%}.kint-rich .kint-focused{box-shadow:0 0 3px 2px #859900 inset;border-radius:7px}.kint-rich>dl>dt,.kint-rich ul.kint-tabs{box-shadow:4px 0 2px -3px #268bd2 inset}.kint-rich ul.kint-tabs li.kint-active-tab{padding-top:7px;height:34px}.kint-rich footer li{color:#ddd} diff --git a/resources/compiled/solarized.css b/resources/compiled/solarized.css index 8c1a67f08..12f61b9c0 100644 --- a/resources/compiled/solarized.css +++ b/resources/compiled/solarized.css @@ -1 +1 @@ -.kint-rich{font-size:13px;overflow-x:auto;white-space:nowrap;background:rgba(255,255,255,.9)}.kint-rich.kint-folder{position:fixed;bottom:0;left:0;right:0;z-index:999999;width:100%;margin:0;display:block}.kint-rich.kint-folder dd.kint-foldout{max-height:calc(100vh - 100px);padding-right:10px;overflow-y:scroll;display:none}.kint-rich.kint-folder dd.kint-foldout.kint-show{display:block}.kint-rich::selection,.kint-rich::-moz-selection,.kint-rich::-webkit-selection{background:#268bd2;color:#657b83}.kint-rich .kint-focused{box-shadow:0 0 3px 2px #2aa198}.kint-rich,.kint-rich::before,.kint-rich::after,.kint-rich *,.kint-rich *::before,.kint-rich *::after{box-sizing:border-box;border-radius:0;color:#657b83;float:none !important;font-family:Consolas,Menlo,Monaco,Lucida Console,Liberation Mono,DejaVu Sans Mono,Bitstream Vera Sans Mono,Courier New,monospace,serif;line-height:15px;margin:0;padding:0;text-align:left}.kint-rich{margin:10px 0}.kint-rich dt,.kint-rich dl{width:auto}.kint-rich dt,.kint-rich div.access-path{background:#fdf6e3;border:1px solid #93a1a1;color:#657b83;display:block;font-weight:bold;list-style:none outside none;overflow:auto;padding:5px}.kint-rich dt:hover,.kint-rich div.access-path:hover{border-color:#268bd2}.kint-rich>dl dl{padding:0 0 0 15px}.kint-rich dt.kint-parent>nav,.kint-rich>footer>nav{background:url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB2aWV3Qm94PSIwIDAgMzAgMTUwIj48ZGVmcz48cGF0aCBzdHJva2UtbGluZWpvaW49InJvdW5kIiBkPSJNNCAzYTI0IDMyIDAgMCAxIDAgMjQgNDAgMjAtMTAgMCAxIDIzLTEyQTQwIDIwIDEwIDAgMSA0IDN6IiBpZD0iYSIvPjwvZGVmcz48ZyBmaWxsPSIjOTNhMWExIiBzdHJva2U9IiM5M2ExYTEiPjx1c2UgeGxpbms6aHJlZj0iI2EiLz48dXNlIHhsaW5rOmhyZWY9IiNhIiB0cmFuc2Zvcm09InJvdGF0ZSg5MCAtMTUgNDUpIi8+PC9nPjxnIGZpbGw9IiM1ODZlNzUiIHN0cm9rZT0iIzU4NmU3NSIgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoMCAzMCkiPjx1c2UgeGxpbms6aHJlZj0iI2EiLz48dXNlIHhsaW5rOmhyZWY9IiNhIiB0cmFuc2Zvcm09InJvdGF0ZSg5MCAtMTUgNDUpIi8+PC9nPjxwYXRoIGQ9Ik02IDEyNmwxOCAxOG0tMTggMGwxOC0xOCIgc3Ryb2tlLXdpZHRoPSIyIiBzdHJva2U9IiM1ODZlNzUiLz48L3N2Zz4=") no-repeat scroll 0 0/15px 75px rgba(0,0,0,0);cursor:pointer;display:inline-block;height:15px;width:15px;margin-right:3px;vertical-align:middle}.kint-rich dt.kint-parent:hover>nav,.kint-rich>footer>nav:hover{background-position:0 25%}.kint-rich dt.kint-parent.kint-show>nav,.kint-rich>footer.kint-show>nav{background-position:0 50%}.kint-rich dt.kint-parent.kint-show:hover>nav,.kint-rich>footer.kint-show>nav:hover{background-position:0 75%}.kint-rich dt.kint-parent.kint-locked>nav{background-position:0 100%}.kint-rich dt.kint-parent+dd{display:none;border-left:1px dashed #93a1a1}.kint-rich dt.kint-parent.kint-show+dd{display:block}.kint-rich var,.kint-rich var a{color:#268bd2;font-style:normal}.kint-rich dt:hover var,.kint-rich dt:hover var a{color:#2aa198}.kint-rich dfn{font-style:normal;font-family:monospace;color:#586e75}.kint-rich pre{color:#657b83;margin:0 0 0 15px;padding:5px;overflow-y:hidden;border-top:0;border:1px solid #93a1a1;background:#fdf6e3;display:block;word-break:normal}.kint-rich .kint-popup-trigger,.kint-rich .kint-access-path-trigger,.kint-rich .kint-search-trigger{background:rgba(101,123,131,.8);border-radius:3px;height:16px;font-size:16px;margin-left:5px;font-weight:bold;width:16px;text-align:center;float:right !important;cursor:pointer;color:#fdf6e3;position:relative;overflow:hidden;line-height:17.6px}.kint-rich .kint-popup-trigger:hover,.kint-rich .kint-access-path-trigger:hover,.kint-rich .kint-search-trigger:hover{color:#657b83;background:#fdf6e3}.kint-rich dt.kint-parent>.kint-popup-trigger{line-height:19.2px}.kint-rich .kint-search-trigger{font-size:20px}.kint-rich input.kint-search{display:none;border:1px solid #93a1a1;border-top-width:0;border-bottom-width:0;padding:5px;float:right !important;margin:-5px 0;color:#586e75;background:#eee8d5;height:26px;width:160px;position:relative;z-index:100}.kint-rich input.kint-search.kint-show{display:block}.kint-rich .kint-search-root ul.kint-tabs>li:not(.kint-search-match){background:#e2e2e2;opacity:.5}.kint-rich .kint-search-root dl:not(.kint-search-match){opacity:.5}.kint-rich .kint-search-root dl:not(.kint-search-match)>dt{background:#f0f0f0}.kint-rich .kint-search-root dl:not(.kint-search-match) dl,.kint-rich .kint-search-root dl:not(.kint-search-match) ul.kint-tabs>li:not(.kint-search-match){opacity:1}.kint-rich div.access-path{background:#eee8d5;display:none;margin-top:5px;padding:4px;white-space:pre}.kint-rich div.access-path.kint-show{display:block}.kint-rich footer{padding:0 3px 3px;font-size:9px;background:rgba(0,0,0,0)}.kint-rich footer>.kint-popup-trigger{background:rgba(0,0,0,0);color:#657b83}.kint-rich footer nav{height:10px;width:10px;background-size:10px 50px}.kint-rich footer>ol{display:none;margin-left:32px}.kint-rich footer.kint-show>ol{display:block}.kint-rich a{color:#657b83;text-shadow:none;text-decoration:underline}.kint-rich a:hover{color:#586e75;border-bottom:1px dotted #586e75}.kint-rich ul{list-style:none;padding-left:15px}.kint-rich ul:not(.kint-tabs) li{border-left:1px dashed #93a1a1}.kint-rich ul:not(.kint-tabs) li>dl{border-left:none}.kint-rich ul.kint-tabs{margin:0 0 0 15px;padding-left:0;background:#fdf6e3;border:1px solid #93a1a1;border-top:0}.kint-rich ul.kint-tabs>li{background:#eee8d5;border:1px solid #93a1a1;cursor:pointer;display:inline-block;height:30px;margin:3px;padding:0 15px;vertical-align:top}.kint-rich ul.kint-tabs>li:hover,.kint-rich ul.kint-tabs>li.kint-active-tab:hover{border-color:#268bd2;color:#2aa198}.kint-rich ul.kint-tabs>li.kint-active-tab{background:#fdf6e3;border-top:0;margin-top:-1px;height:27px;line-height:24px}.kint-rich ul.kint-tabs>li:not(.kint-active-tab){line-height:25px}.kint-rich ul.kint-tabs li+li{margin-left:0}.kint-rich ul.kint-tab-contents>li{display:none}.kint-rich ul.kint-tab-contents>li.kint-show{display:block}.kint-rich dt:hover+dd>ul>li.kint-active-tab{border-color:#268bd2;color:#2aa198}.kint-rich dt>.kint-color-preview{width:16px;height:16px;display:inline-block;vertical-align:middle;margin-left:10px;border:1px solid #93a1a1;background-color:#ccc;background-image:url('data:image/svg+xml;utf8,');background-size:100%}.kint-rich dt>.kint-color-preview:hover{border-color:#268bd2}.kint-rich dt>.kint-color-preview>div{width:100%;height:100%}.kint-rich table{border-collapse:collapse;empty-cells:show;border-spacing:0}.kint-rich table *{font-size:12px}.kint-rich table dt{background:none;padding:2.5px}.kint-rich table dt .kint-parent{min-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.kint-rich table td,.kint-rich table th{border:1px solid #93a1a1;padding:2.5px;vertical-align:center}.kint-rich table th{cursor:alias}.kint-rich table td:first-child,.kint-rich table th{font-weight:bold;background:#eee8d5;color:#586e75}.kint-rich table td{background:#fdf6e3;white-space:pre}.kint-rich table td>dl{padding:0}.kint-rich table pre{border-top:0;border-right:0}.kint-rich table thead th:first-child{background:none;border:0}.kint-rich table tr:hover>td{box-shadow:0 0 1px 0 #268bd2 inset}.kint-rich table tr:hover var{color:#2aa198}.kint-rich table ul.kint-tabs li.kint-active-tab{height:20px;line-height:17px}.kint-rich pre.kint-source{margin-left:-1px}.kint-rich pre.kint-source[data-kint-filename]:before{display:block;content:attr(data-kint-filename);margin-bottom:5px;padding-bottom:5px;border-bottom:1px solid #eee8d5}.kint-rich pre.kint-source>div:before{display:inline-block;content:counter(kint-l);counter-increment:kint-l;border-right:1px solid #268bd2;padding-right:10px;margin-right:10px}.kint-rich pre.kint-source>div.kint-highlight{background:#eee8d5}.kint-rich .kint-microtime-lap{text-shadow:-1px 0 #268bd2,0 1px #268bd2,1px 0 #268bd2,0 -1px #268bd2;color:#fdf6e3;font-weight:bold}input.kint-note-input{width:100%}.kint-rich .kint-focused{box-shadow:0 0 3px 2px #859900 inset;border-radius:7px}.kint-rich>dl>dt,.kint-rich ul.kint-tabs{box-shadow:4px 0 2px -3px #268bd2 inset}.kint-rich ul.kint-tabs li.kint-active-tab{padding-top:7px;height:34px} +.kint-rich{font-size:13px;overflow-x:auto;white-space:nowrap;background:rgba(255,255,255,.9)}.kint-rich.kint-folder{position:fixed;bottom:0;left:0;right:0;z-index:999999;width:100%;margin:0;display:block}.kint-rich.kint-folder dd.kint-foldout{max-height:calc(100vh - 100px);padding-right:10px;overflow-y:scroll;display:none}.kint-rich.kint-folder dd.kint-foldout.kint-show{display:block}.kint-rich::selection,.kint-rich::-moz-selection,.kint-rich::-webkit-selection{background:#268bd2;color:#657b83}.kint-rich .kint-focused{box-shadow:0 0 3px 3px #2aa198}.kint-rich .kint-focused.kint-weak-focus{box-shadow:0 0 3px 1px rgba(42,161,152,.5)}.kint-rich,.kint-rich::before,.kint-rich::after,.kint-rich *,.kint-rich *::before,.kint-rich *::after{box-sizing:border-box;border-radius:0;color:#657b83;float:none !important;font-family:Consolas,Menlo,Monaco,Lucida Console,Liberation Mono,DejaVu Sans Mono,Bitstream Vera Sans Mono,Courier New,monospace,serif;line-height:15px;margin:0;padding:0;text-align:left}.kint-rich{margin:10px 0}.kint-rich dt,.kint-rich dl{width:auto}.kint-rich dt,.kint-rich div.access-path{background:#fdf6e3;border:1px solid #93a1a1;color:#657b83;display:block;font-weight:bold;list-style:none outside none;overflow:auto;padding:5px}.kint-rich dt:hover,.kint-rich div.access-path:hover{border-color:#268bd2}.kint-rich>dl dl{padding:0 0 0 15px}.kint-rich dt.kint-parent>nav,.kint-rich>footer>nav{background:url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB2aWV3Qm94PSIwIDAgMzAgMTUwIj48ZGVmcz48cGF0aCBzdHJva2UtbGluZWpvaW49InJvdW5kIiBkPSJNNCAzYTI0IDMyIDAgMCAxIDAgMjQgNDAgMjAtMTAgMCAxIDIzLTEyQTQwIDIwIDEwIDAgMSA0IDN6IiBpZD0iYSIvPjwvZGVmcz48ZyBmaWxsPSIjOTNhMWExIiBzdHJva2U9IiM5M2ExYTEiPjx1c2UgeGxpbms6aHJlZj0iI2EiLz48dXNlIHhsaW5rOmhyZWY9IiNhIiB0cmFuc2Zvcm09InJvdGF0ZSg5MCAtMTUgNDUpIi8+PC9nPjxnIGZpbGw9IiM1ODZlNzUiIHN0cm9rZT0iIzU4NmU3NSIgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoMCAzMCkiPjx1c2UgeGxpbms6aHJlZj0iI2EiLz48dXNlIHhsaW5rOmhyZWY9IiNhIiB0cmFuc2Zvcm09InJvdGF0ZSg5MCAtMTUgNDUpIi8+PC9nPjxwYXRoIGQ9Ik02IDEyNmwxOCAxOG0tMTggMGwxOC0xOCIgc3Ryb2tlLXdpZHRoPSIyIiBzdHJva2U9IiM1ODZlNzUiLz48L3N2Zz4=") no-repeat scroll 0 0/15px 75px rgba(0,0,0,0);cursor:pointer;display:inline-block;height:15px;width:15px;margin-right:3px;vertical-align:middle}.kint-rich dt.kint-parent:hover>nav,.kint-rich>footer>nav:hover{background-position:0 25%}.kint-rich dt.kint-parent.kint-show>nav,.kint-rich>footer.kint-show>nav{background-position:0 50%}.kint-rich dt.kint-parent.kint-show:hover>nav,.kint-rich>footer.kint-show>nav:hover{background-position:0 75%}.kint-rich dt.kint-parent.kint-locked>nav{background-position:0 100%}.kint-rich dt.kint-parent+dd{display:none;border-left:1px dashed #93a1a1}.kint-rich dt.kint-parent.kint-show+dd{display:block}.kint-rich var,.kint-rich var a{color:#268bd2;font-style:normal}.kint-rich dt:hover var,.kint-rich dt:hover var a{color:#2aa198}.kint-rich dfn{font-style:normal;font-family:monospace;color:#586e75}.kint-rich pre{color:#657b83;margin:0 0 0 15px;padding:5px;overflow-y:hidden;border-top:0;border:1px solid #93a1a1;background:#fdf6e3;display:block;word-break:normal}.kint-rich .kint-access-path-trigger,.kint-rich .kint-search-trigger{background:rgba(101,123,131,.8);border-radius:3px;height:16px;font-size:16px;margin-left:5px;font-weight:bold;width:16px;text-align:center;float:right !important;cursor:pointer;color:#fdf6e3;position:relative;overflow:hidden;line-height:17.6px}.kint-rich .kint-access-path-trigger:hover,.kint-rich .kint-search-trigger:hover{color:#657b83;background:#fdf6e3}.kint-rich .kint-search-trigger{font-size:20px}.kint-rich input.kint-search{display:none;border:1px solid #93a1a1;border-top-width:0;border-bottom-width:0;padding:5px;float:right !important;margin:-5px 0;color:#586e75;background:#eee8d5;height:26px;width:160px;position:relative;z-index:100}.kint-rich input.kint-search.kint-show{display:block}.kint-rich .kint-search-root ul.kint-tabs>li:not(.kint-search-match){background:#e2e2e2;opacity:.5}.kint-rich .kint-search-root dl:not(.kint-search-match){opacity:.5}.kint-rich .kint-search-root dl:not(.kint-search-match)>dt{background:#f0f0f0}.kint-rich .kint-search-root dl:not(.kint-search-match) dl,.kint-rich .kint-search-root dl:not(.kint-search-match) ul.kint-tabs>li:not(.kint-search-match){opacity:1}.kint-rich div.access-path{background:#eee8d5;display:none;margin-top:5px;padding:4px;white-space:pre}.kint-rich div.access-path.kint-show{display:block}.kint-rich footer{padding:0 3px 3px;font-size:9px;background:rgba(0,0,0,0)}.kint-rich footer nav{height:10px;width:10px;background-size:10px 50px}.kint-rich footer>ol{display:none;margin-left:32px}.kint-rich footer.kint-show>ol{display:block}.kint-rich a{color:#657b83;text-shadow:none;text-decoration:underline}.kint-rich a:hover{color:#586e75;border-bottom:1px dotted #586e75}.kint-rich ul{list-style:none;padding-left:15px}.kint-rich ul:not(.kint-tabs) li{border-left:1px dashed #93a1a1}.kint-rich ul:not(.kint-tabs) li>dl{border-left:none}.kint-rich ul.kint-tabs{margin:0 0 0 15px;padding-left:0;background:#fdf6e3;border:1px solid #93a1a1;border-top:0}.kint-rich ul.kint-tabs>li{background:#eee8d5;border:1px solid #93a1a1;cursor:pointer;display:inline-block;height:30px;margin:3px;padding:0 15px;vertical-align:top}.kint-rich ul.kint-tabs>li:hover,.kint-rich ul.kint-tabs>li.kint-active-tab:hover{border-color:#268bd2;color:#2aa198}.kint-rich ul.kint-tabs>li.kint-active-tab{background:#fdf6e3;border-top:0;margin-top:-1px;height:27px;line-height:24px}.kint-rich ul.kint-tabs>li:not(.kint-active-tab){line-height:25px}.kint-rich ul.kint-tabs li+li{margin-left:0}.kint-rich ul.kint-tab-contents>li{display:none}.kint-rich ul.kint-tab-contents>li.kint-show{display:block}.kint-rich dt:hover+dd>ul>li.kint-active-tab{border-color:#268bd2;color:#2aa198}.kint-rich dt>.kint-color-preview{width:16px;height:16px;display:inline-block;vertical-align:middle;margin-left:10px;border:1px solid #93a1a1;background-color:#ccc;background-image:url('data:image/svg+xml;utf8,');background-size:100%}.kint-rich dt>.kint-color-preview:hover{border-color:#268bd2}.kint-rich dt>.kint-color-preview>div{width:100%;height:100%}.kint-rich table{border-collapse:collapse;empty-cells:show;border-spacing:0}.kint-rich table *{font-size:12px}.kint-rich table dt{background:none;padding:2.5px}.kint-rich table dt .kint-parent{min-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.kint-rich table td,.kint-rich table th{border:1px solid #93a1a1;padding:2.5px;vertical-align:center}.kint-rich table th{cursor:alias}.kint-rich table td:first-child,.kint-rich table th{font-weight:bold;background:#eee8d5;color:#586e75}.kint-rich table td{background:#fdf6e3;white-space:pre}.kint-rich table td>dl{padding:0}.kint-rich table pre{border-top:0;border-right:0}.kint-rich table thead th:first-child{background:none;border:0}.kint-rich table tr:hover>td{box-shadow:0 0 1px 0 #268bd2 inset}.kint-rich table tr:hover var{color:#2aa198}.kint-rich table ul.kint-tabs li.kint-active-tab{height:20px;line-height:17px}.kint-rich pre.kint-source{margin-left:-1px}.kint-rich pre.kint-source[data-kint-filename]:before{display:block;content:attr(data-kint-filename);margin-bottom:5px;padding-bottom:5px;border-bottom:1px solid #eee8d5}.kint-rich pre.kint-source>div:before{display:inline-block;content:counter(kint-l);counter-increment:kint-l;border-right:1px solid #268bd2;padding-right:10px;margin-right:10px}.kint-rich pre.kint-source>div.kint-highlight{background:#eee8d5}.kint-rich .kint-microtime-js .kint-microtime-lap{text-shadow:-1px 0 #268bd2,0 1px #268bd2,1px 0 #268bd2,0 -1px #268bd2;color:#fdf6e3;font-weight:bold}input.kint-note-input{width:100%}.kint-rich .kint-focused{box-shadow:0 0 3px 2px #859900 inset;border-radius:7px}.kint-rich>dl>dt,.kint-rich ul.kint-tabs{box-shadow:4px 0 2px -3px #268bd2 inset}.kint-rich ul.kint-tabs li.kint-active-tab{padding-top:7px;height:34px} diff --git a/resources/js/kint.js b/resources/js/kint.js new file mode 100644 index 000000000..e9ada2d5a --- /dev/null +++ b/resources/js/kint.js @@ -0,0 +1,79 @@ +import { dedupeElement, elementIsInDom, buildClassSelector } from './utils.js'; +import Rich from './rich.js'; +import Plain from './plain.js'; +import Microtime from './microtime.js'; + +const constructor_key = Symbol(); + +export default class Kint { + static #instance = null; + + #window; + #inits = []; + #scriptSelectors = new Set(); + + static init(window) { + Kint.#instance ??= new Kint(window, constructor_key); + Kint.#instance.#removeThisScript(); + Kint.#instance.runOnLoad(Kint.#dispatchInits); + + return Kint.#instance; + } + + get window() { + return this.#window; + } + + constructor(window, key) { + if (constructor_key !== key) { + throw new Error('Kint constructor is private. Use Kint.init()'); + } + + if (!(window instanceof Window)) { + throw new Error('Invalid argument to Kint.init()'); + } + + this.#window = window; + this.runOnInit(this.#removeAllScripts.bind(this)); + + // Do we want to store submodules? That would be a circular reference... + new Plain(this); + new Rich(this); + new Microtime(this); + } + + runOnLoad(cb) { + if (this.#window.document.readyState === 'complete') { + try { + cb(); + } catch {} + } else { + this.#window.addEventListener('load', cb); + } + } + + runOnInit(cb) { + this.#inits.push(cb); + } + + #removeThisScript() { + if (this.#window.document.currentScript) { + this.#scriptSelectors.add(buildClassSelector(window.document.currentScript)); + window.document.currentScript.remove(); + } + } + + #removeAllScripts() { + for (const selector of this.#scriptSelectors.keys()) { + for (const elem of this.#window.document.querySelectorAll(selector)) { + elem.remove(); + } + } + } + + static #dispatchInits() { + for (const init of Kint.#instance.#inits) { + init(); + } + } +} diff --git a/resources/js/main.js b/resources/js/main.js new file mode 100644 index 000000000..e24f44674 --- /dev/null +++ b/resources/js/main.js @@ -0,0 +1,7 @@ +import Kint from './kint.js'; + +if (!window.Kint) { + window.Kint = Kint; +} + +window.Kint.init(window); diff --git a/resources/js/microtime.js b/resources/js/microtime.js index c9cfe5772..abc58fa2c 100644 --- a/resources/js/microtime.js +++ b/resources/js/microtime.js @@ -1,66 +1,74 @@ -if (typeof window.kintMicrotimeInitialized === 'undefined') { - window.kintMicrotimeInitialized = 1; - window.addEventListener('load', function () { - 'use strict'; +import Kint from './kint.js'; - var sums = {}; - var microtimes = Array.prototype.slice.call( - document.querySelectorAll('[data-kint-microtime-group]'), - 0 - ); +export default class Microtime { + constructor(kint) { + if (!(kint instanceof Kint)) { + throw new Error('Invalid argument to Plain.constructor()'); + } - microtimes.forEach(function (el) { - if (!el.querySelector('.kint-microtime-lap')) { - return; - } + // If we do microtime stuff for ajax loads the groups + // from the runs will conflate and we'll get bad numbers + kint.runOnLoad(Microtime.#setupMicrotimes.bind(null, kint.window)); + } + + static #setupMicrotimes(window) { + const sums = {}; - var group = el.getAttribute('data-kint-microtime-group'); - var lap = parseFloat(el.querySelector('.kint-microtime-lap').innerHTML); - var avg = parseFloat(el.querySelector('.kint-microtime-avg').innerHTML); + const elements = window.document.querySelectorAll('[data-kint-microtime-group]'); + for (const elem of elements) { + const el = elem.querySelector('.kint-microtime-lap'); - if (typeof sums[group] === 'undefined') { - sums[group] = {}; + if (!el) { + continue; } - if (typeof sums[group].min === 'undefined' || sums[group].min > lap) { + + const group = elem.getAttribute('data-kint-microtime-group'); + const lap = parseFloat(el.textContent); + const avg = parseFloat(elem.querySelector('.kint-microtime-avg').textContent); + + sums[group] ??= { + min: lap, + max: lap, + avg: avg, + }; + + if (sums[group].min > lap) { sums[group].min = lap; } - if (typeof sums[group].max === 'undefined' || sums[group].max < lap) { + if (sums[group].max < lap) { sums[group].max = lap; } sums[group].avg = avg; - }); + } - microtimes.forEach(function (microtime) { - var el = microtime.querySelector('.kint-microtime-lap'); + for (const elem of elements) { + const el = elem.querySelector('.kint-microtime-lap'); - if (el === null) { - return; + if (!el) { + continue; } - var value = parseFloat(el.textContent); - var group = microtime.dataset.kintMicrotimeGroup; - var avg = sums[group].avg; - var max = sums[group].max; - var min = sums[group].min; - var ratio; + const lap = parseFloat(el.textContent); + const group = sums[elem.dataset.kintMicrotimeGroup]; - microtime.querySelector('.kint-microtime-avg').textContent = avg; + elem.querySelector('.kint-microtime-avg').textContent = group.avg; - if (value === avg && value === min && value === max) { - return; // Only one result, no need to color + if (lap === group.min && lap === group.max) { + continue; // Only one result, no need to color } - if (value > avg) { - ratio = (value - avg) / (max - avg); + elem.classList.add('kint-microtime-js'); + + if (lap > group.avg) { + const ratio = (lap - group.avg) / (group.max - group.avg); el.style.background = 'hsl(' + (40 - 40 * ratio) + ', 100%, 65%)'; } else { - if (avg === min) { - ratio = 0; - } else { - ratio = (avg - value) / (avg - min); + let ratio = 0; + if (group.avg !== group.min) { + ratio = (group.avg - lap) / (group.avg - group.min); } el.style.background = 'hsl(' + (40 + 80 * ratio) + ', 100%, 65%)'; } - }); - }); + } + } } diff --git a/resources/js/plain.js b/resources/js/plain.js index 26e4189aa..5994a450f 100644 --- a/resources/js/plain.js +++ b/resources/js/plain.js @@ -1,25 +1,26 @@ -if (typeof window.kintPlain === 'undefined') { - window.kintPlain = (function () { - 'use strict'; +import { dedupeElement, elementIsInDom } from './utils.js'; +import Kint from './kint.js'; - var kintPlain = { - initLoad: function () { - kintPlain.style = window.kintShared.dedupe( - 'style.kint-plain-style', - kintPlain.style - ); - kintPlain.script = window.kintShared.dedupe( - 'script.kint-plain-script', - kintPlain.script - ); - }, +export default class Plain { + #window; + #style; - style: null, - script: null, - }; + constructor(kint) { + if (!(kint instanceof Kint)) { + throw new Error('Invalid argument to Plain.constructor()'); + } - return kintPlain; - })(); -} + this.#window = kint.window; + kint.runOnInit(this.#dedupePlainStyle.bind(this)); + } + + #dedupePlainStyle() { + if (!elementIsInDom(this.#style)) { + this.#style = this.#window.document.querySelector('style.kint-plain-style'); + } -window.kintShared.runOnce(window.kintPlain.initLoad); + if (this.#style) { + dedupeElement(this.#style); + } + } +} diff --git a/resources/js/rich.js b/resources/js/rich.js index 9f4d38104..ecce9063d 100644 --- a/resources/js/rich.js +++ b/resources/js/rich.js @@ -1,820 +1,656 @@ -if (typeof window.kintRich === 'undefined') { - window.kintRich = (function () { - 'use strict'; +import { dedupeElement, elementIsInDom, selectText, offsetTop } from './utils.js'; +import Kint from './kint.js'; +import Search from './search.js'; +import Table from './table.js'; - var kintRich = { - selectText: function (element) { - var selection = window.getSelection(); - var range = document.createRange(); +export default class Rich { + #kint; + #style; + #folder; - range.selectNodeContents(element); - selection.removeAllRanges(); - selection.addRange(range); - }, + constructor(kint) { + if (!(kint instanceof Kint)) { + throw new Error('Invalid argument to Rich.constructor()'); + } - toggle: function (element, show) { - var parent = kintRich.getChildren(element); + this.#kint = kint; + this.#kint.runOnInit(this.#dedupeRichStyleAndSetupFolder.bind(this)); - if (!parent) { - return; - } - - element.classList.toggle('kint-show', show); - - if (parent.childNodes.length === 1) { - parent = parent.childNodes[0].childNodes[0]; // reuse variable cause I can - - // Parent is checked for a class list in case of empty
-                    if (parent && parent.classList && parent.classList.contains('kint-parent')) {
-                        kintRich.toggle(parent, show);
-                    }
-                }
-            },
-
-            toggleChildren: function (element, show) {
-                var parent = kintRich.getChildren(element);
-
-                if (!parent) {
-                    return;
-                }
-
-                var nodes = parent.getElementsByClassName('kint-parent');
-                var i = nodes.length;
-
-                if (typeof show === 'undefined') {
-                    show = element.classList.contains('kint-show');
-                }
-
-                while (i--) {
-                    kintRich.toggle(nodes[i], show);
-                }
-            },
-
-            switchTab: function (target) {
-                var lis;
-                var el = target.previousSibling;
-                var index = 0;
-
-                target.parentNode
-                    .getElementsByClassName('kint-active-tab')[0]
-                    .classList.remove('kint-active-tab');
-                target.classList.add('kint-active-tab');
-
-                // take the index of clicked title tab and make the same n-th content tab visible
-                while (el) {
-                    if (el.nodeType === 1) {
-                        index++;
-                    }
-
-                    el = el.previousSibling;
-                }
-
-                lis = target.parentNode.nextSibling.childNodes;
-
-                for (var i = 0; i < lis.length; i++) {
-                    if (i === index) {
-                        lis[i].classList.add('kint-show');
-
-                        if (lis[i].childNodes.length === 1) {
-                            el = lis[i].childNodes[0].childNodes[0];
-
-                            if (el && el.classList && el.classList.contains('kint-parent')) {
-                                kintRich.toggle(el, true);
-                            }
-                        }
-                    } else {
-                        lis[i].classList.remove('kint-show');
-                    }
-                }
-            },
-
-            // Shitty people using shitty regex fuck up the JS when they see  or 
-            // so we have to write this obfuscation to make sure it works after minification
-            mktag: function (contents) {
-                return '<' + contents + '>';
-            },
-
-            openInNewWindow: function (kintContainer) {
-                var newWindow = window.open();
-
-                if (newWindow) {
-                    newWindow.document.open();
-                    newWindow.document.write(
-                        kintRich.mktag('html') +
-                            kintRich.mktag('head') +
-                            kintRich.mktag('title') +
-                            'Kint (' +
-                            new Date().toISOString() +
-                            ')' +
-                            kintRich.mktag('/title') +
-                            kintRich.mktag('meta charset="utf-8"') +
-                            /**
-                             * `tag.getAttribute('nonce')` doesn't work for security reasons.
-                             * See https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/nonce#accessing_nonces_and_nonce_hiding.
-                             */
-                            kintRich.mktag(
-                                'script class="kint-rich-script" nonce="' +
-                                    kintRich.script.nonce +
-                                    '"'
-                            ) +
-                            kintRich.script.innerHTML +
-                            kintRich.mktag('/script') +
-                            /**
-                             * `tag.getAttribute('nonce')` doesn't work for security reasons.
-                             * See https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/nonce#accessing_nonces_and_nonce_hiding.
-                             */
-                            kintRich.mktag(
-                                'style class="kint-rich-style" nonce="' + kintRich.style.nonce + '"'
-                            ) +
-                            kintRich.style.innerHTML +
-                            kintRich.mktag('/style') +
-                            kintRich.mktag('/head') +
-                            kintRich.mktag('body') +
-                            '' +
-                            '
' + - kintContainer.parentNode.outerHTML + - '
' + - kintRich.mktag('/body') - ); - newWindow.document.close(); - } - }, - - sortTable: function (table, column) { - var tbody = table.tBodies[0]; - - [].slice - .call(table.tBodies[0].rows) - .sort(function (a, b) { - a = a.cells[column].textContent.trim().toLocaleLowerCase(); - b = b.cells[column].textContent.trim().toLocaleLowerCase(); - - // In lieu of natsort we just sort all numbers before strings - if (!isNaN(a) && !isNaN(b)) { - a = parseFloat(a); - b = parseFloat(b); - } else if (isNaN(a) && !isNaN(b)) { - return 1; - } else if (isNaN(b) && !isNaN(a)) { - return -1; - } - - if (a < b) { - return -1; - } - if (a > b) { - return 1; - } - - return 0; - }) - .forEach(function (el) { - tbody.appendChild(el); - }); - }, - - showAccessPath: function (target) { - var nodes = target.childNodes; - - for (var i = 0; i < nodes.length; i++) { - if (nodes[i].classList && nodes[i].classList.contains('access-path')) { - nodes[i].classList.toggle('kint-show'); - if (nodes[i].classList.contains('kint-show')) { - kintRich.selectText(nodes[i]); - } - return; - } - } - }, - - showSearchBox: function (target) { - var input = target.querySelector('.kint-search'); - - if (!input) { - return; - } - - input.classList.toggle('kint-show'); - if (input.classList.contains('kint-show')) { - target.classList.add('kint-show'); - input.focus(); - input.select(); - kintRich.search(target.parentNode, input.value); - } else { - target.parentNode.classList.remove('kint-search-root'); - } - }, - - search: function (el, input) { - el.querySelectorAll('.kint-search-match').forEach(function (match) { - match.classList.remove('kint-search-match'); - }); - el.classList.remove('kint-search-match'); - - el.classList.toggle('kint-search-root', input.length); - if (input.length) { - kintRich.findMatches(el, input); - } - }, - - findMatches: function (el, term) { - var cleaned = el.cloneNode(true); - cleaned.querySelectorAll('.access-path').forEach(function (e) { - e.remove(); - }); + const ki = new KeyInput(this, kint); + new MouseInput(this, kint.window, ki); + } - if (cleaned.textContent.toUpperCase().indexOf(term.toUpperCase()) == -1) { - return; - } - - el.classList.add('kint-search-match'); - - var node; - - for (var index in el.childNodes) { - if (el.childNodes[index].tagName == 'DD') { - node = el.childNodes[index]; - break; - } - } - - if (!node) { - return; - } + #dedupeRichStyleAndSetupFolder() { + const document = this.#kint.window.document; - var tabs; - var tabcontents; - - [].forEach.call(node.childNodes, function (node) { - if (node.tagName == 'DL') { - kintRich.findMatches(node, term); - } else if (node.tagName == 'UL') { - if (node.classList.contains('kint-tabs')) { - tabs = node.childNodes; - } else if (node.classList.contains('kint-tab-contents')) { - tabcontents = node.childNodes; - } - } - }); - - if (!tabs || !tabcontents || tabs.length != tabcontents.length) { - return; - } - - for (var index = 0; index < tabs.length; index++) { - var matched = false; + if (!elementIsInDom(this.#style)) { + this.#style = document.querySelector('style.kint-rich-style'); + } - if (tabs[index].textContent.toUpperCase().indexOf(term.toUpperCase()) != -1) { - matched = true; - } else { - cleaned = tabcontents[index].cloneNode(true); - cleaned.querySelectorAll('.access-path').forEach(function (e) { - e.remove(); - }); + if (this.#style) { + dedupeElement(this.#style); + } - if (cleaned.textContent.toUpperCase().indexOf(term.toUpperCase()) != -1) { - matched = true; - } - } - - if (matched) { - tabs[index].classList.add('kint-search-match'); - - [].forEach.call(tabcontents[index].childNodes, function (node) { - if (node.tagName == 'DL') { - kintRich.findMatches(node, term); - } - }); - } - } - }, - - getParentByClass: function (el, className) { - for (;;) { - el = el.parentNode; - - if (!el || !el.classList || el === document) { - return null; - } - - if (el.classList.contains(className)) { - return el; - } - } - - return null; - }, - - getParentHeader: function (el, allowChildren) { - var nodeName = el.nodeName.toLowerCase(); - - while ( - nodeName !== 'dd' && - nodeName !== 'dt' && - kintRich.getParentByClass(el, 'kint-rich') - ) { - el = el.parentNode; - nodeName = el.nodeName.toLowerCase(); - } - - if (!kintRich.getParentByClass(el, 'kint-rich')) { - return null; - } - - if (nodeName === 'dd' && allowChildren) { - el = el.previousElementSibling; - } - - if ( - el && - el.nodeName.toLowerCase() === 'dt' && - el.classList.contains('kint-parent') - ) { - return el; - } - }, - - getChildren: function (element) { - do { - element = element.nextElementSibling; - } while (element && element.nodeName.toLowerCase() !== 'dd'); - return element; - }, - - isFolderOpen: function () { - if (!kintRich.folder || !kintRich.folder.querySelector('dd.kint-foldout')) { - return undefined; - } - - return kintRich.folder - .querySelector('dd.kint-foldout') - .previousSibling.classList.contains('kint-show'); - }, - - initLoad: function () { - kintRich.style = window.kintShared.dedupe('style.kint-rich-style', kintRich.style); - kintRich.script = window.kintShared.dedupe( - 'script.kint-rich-script', - kintRich.script - ); - kintRich.folder = window.kintShared.dedupe( - '.kint-rich.kint-folder', - kintRich.folder - ); - - var searchboxes = document.querySelectorAll('input.kint-search'); - - [].forEach.call(searchboxes, function (input) { - var timeout = null; - var value = null; - - var searchfunc = function (e) { - window.clearTimeout(timeout); - - if (input.value === value) { - return; - } - - timeout = window.setTimeout(function () { - value = input.value; - kintRich.search(input.parentNode.parentNode, value); - }, 500); - }; - - input.removeEventListener('keyup', searchfunc); - input.addEventListener('keyup', searchfunc); - }); - - if (!kintRich.folder) { - return; - } + if (!elementIsInDom(this.#folder)) { + this.#folder = document.querySelector('.kint-rich.kint-folder'); + } - var container = kintRich.folder.querySelector('dd'); + if (this.#folder) { + dedupeElement(this.#folder); - // Add kint dumps to folder - [].forEach.call(document.querySelectorAll('.kint-rich.kint-file'), function (elem) { - if (elem.parentNode === kintRich.folder) { - return; - } + const container = this.#folder.querySelector('dd.kint-foldout'); + for (const elem of document.querySelectorAll('.kint-rich.kint-file')) { + if (elem.parentNode !== container) { container.appendChild(elem); - }); - - document.body.appendChild(kintRich.folder); - - kintRich.folder.classList.add('kint-show'); - }, - - keyboardNav: { - targets: [], // all visible toggle carets - target: 0, // currently selected caret - active: false, - - fetchTargets: function () { - var selected = kintRich.keyboardNav.targets[kintRich.keyboardNav.target]; - - kintRich.keyboardNav.targets = []; - - document - .querySelectorAll('.kint-rich nav, .kint-tabs>li:not(.kint-active-tab)') - .forEach(function (el) { - // Don't add targets outside of folder if folder is open - if (kintRich.isFolderOpen() && !kintRich.folder.contains(el)) { - return; - } - - // Don't add hidden targets (Inside tabs, inside folder) - if (el.offsetWidth !== 0 || el.offsetHeight !== 0) { - kintRich.keyboardNav.targets.push(el); - } - }); - - if (selected && kintRich.keyboardNav.targets.indexOf(selected) !== -1) { - kintRich.keyboardNav.target = - kintRich.keyboardNav.targets.indexOf(selected); - } - }, - - sync: function (noscroll) { - var prevElement = document.querySelector('.kint-focused'); - if (prevElement) { - prevElement.classList.remove('kint-focused'); - } - - if (kintRich.keyboardNav.active) { - var el = kintRich.keyboardNav.targets[kintRich.keyboardNav.target]; - el.classList.add('kint-focused'); - - // Generally speaking keyboard navigation should result - // in a scroll and mouse navigation shouldn't - if (!noscroll) { - kintRich.keyboardNav.scroll(el); - } - } - }, - - scroll: function (el) { - if (kintRich.folder && el === kintRich.folder.querySelector('dt > nav')) { - return; - } - - var offsetTop = function (el) { - return el.offsetTop + (el.offsetParent ? offsetTop(el.offsetParent) : 0); - }; - - var top = offsetTop(el); - - if (kintRich.isFolderOpen()) { - var container = kintRich.folder.querySelector('dd.kint-foldout'); - container.scrollTo(0, top - container.clientHeight / 2); - } else { - window.scrollTo(0, top - window.innerHeight / 2); - } - }, - - moveCursor: function (diff) { - kintRich.keyboardNav.target += diff; - - while (kintRich.keyboardNav.target < 0) { - kintRich.keyboardNav.target += kintRich.keyboardNav.targets.length; - } - while (kintRich.keyboardNav.target >= kintRich.keyboardNav.targets.length) { - kintRich.keyboardNav.target -= kintRich.keyboardNav.targets.length; - } - - kintRich.keyboardNav.sync(); - }, - - setCursor: function (elem) { - // Refuse to set cursor outside of folder if folder is open - if (kintRich.isFolderOpen() && !kintRich.folder.contains(elem)) { - return false; - } - - kintRich.keyboardNav.fetchTargets(); - - for (var i = 0; i < kintRich.keyboardNav.targets.length; i++) { - if (elem === kintRich.keyboardNav.targets[i]) { - kintRich.keyboardNav.target = i; - return true; - } - } - - return false; - }, - }, - - mouseNav: { - lastClickTarget: null, - lastClickTimer: null, - lastClickCount: 0, - - renewLastClick: function () { - window.clearTimeout(kintRich.mouseNav.lastClickTimer); - kintRich.mouseNav.lastClickTimer = window.setTimeout(function () { - kintRich.mouseNav.lastClickTarget = null; - kintRich.mouseNav.lastClickTimer = null; - kintRich.mouseNav.lastClickCount = 0; - }, 250); - }, - }, - - style: null, - script: null, - folder: null, - }; - - window.addEventListener( - 'click', - function (e) { - var target = e.target; - - // Double/triple click to open children/all - if ( - kintRich.mouseNav.lastClickTarget && - kintRich.mouseNav.lastClickTimer && - kintRich.mouseNav.lastClickCount - ) { - target = kintRich.mouseNav.lastClickTarget; - - if (kintRich.mouseNav.lastClickCount === 1) { - kintRich.toggleChildren(target.parentNode); - kintRich.keyboardNav.setCursor(target); - kintRich.keyboardNav.sync(true); - kintRich.mouseNav.lastClickCount++; - - kintRich.mouseNav.renewLastClick(); - } else { - // Toggle all on page - var show = target.parentNode.classList.contains('kint-show'); - var elements = document.getElementsByClassName('kint-parent'); - var i = elements.length; - - while (i--) { - kintRich.toggle(elements[i], show); - } - - kintRich.keyboardNav.setCursor(target); - kintRich.keyboardNav.sync(true); - kintRich.keyboardNav.scroll(target); - - window.clearTimeout(kintRich.mouseNav.lastClickTimer); - kintRich.mouseNav.lastClickTarget = null; - kintRich.mouseNav.lastClickTarget = null; - kintRich.mouseNav.lastClickCount = 0; - } - - return; - } - - // Ignore clicks outside kint - if (!kintRich.getParentByClass(target, 'kint-rich')) { - return; - } - - var nodeName = target.nodeName.toLowerCase(); - - // auto-select name of variable - if (nodeName === 'dfn') { - kintRich.selectText(target); - } - - // Sort tables - if (nodeName === 'th') { - if (!e.ctrlKey) { - kintRich.sortTable( - target.parentNode.parentNode.parentNode, - target.cellIndex - ); - } - return; - } - - // Ensure the nav is selected for keyboard - target = kintRich.getParentHeader(target); - if (target) { - kintRich.keyboardNav.setCursor(target.querySelector('nav')); - kintRich.keyboardNav.sync(true); - } - - target = e.target; - - if (nodeName === 'li' && target.parentNode.className === 'kint-tabs') { - // switch tabs - if (target.className !== 'kint-active-tab') { - kintRich.switchTab(target); - } - target = kintRich.getParentHeader(target, true); - if (target) { - kintRich.keyboardNav.setCursor(target.querySelector('nav')); - kintRich.keyboardNav.sync(true); - } - } else if (nodeName === 'nav') { - // handle clicks on the navigation caret - if (target.parentNode.nodeName.toLowerCase() === 'footer') { - kintRich.keyboardNav.setCursor(target); - kintRich.keyboardNav.sync(true); - target = target.parentNode; - target.classList.toggle('kint-show'); - } else { - // ensure double/triple click has different behaviour, see above - kintRich.toggle(target.parentNode); - kintRich.keyboardNav.fetchTargets(); - kintRich.mouseNav.lastClickCount = 1; - kintRich.mouseNav.lastClickTarget = target; - kintRich.mouseNav.renewLastClick(); - } - } else if (target.classList.contains('kint-popup-trigger')) { - // Popup - var kintContainer = target.parentNode; - if (kintContainer.nodeName.toLowerCase() === 'footer') { - kintContainer = kintContainer.previousSibling; - } else { - while (kintContainer && !kintContainer.classList.contains('kint-parent')) { - kintContainer = kintContainer.parentNode; - } - } - - kintRich.openInNewWindow(kintContainer); - } else if (target.classList.contains('kint-access-path-trigger')) { - // Access path - kintRich.showAccessPath(target.parentNode); - } else if (target.classList.contains('kint-search-trigger')) { - // Search box - kintRich.showSearchBox(target.parentNode); - } else if (target.classList.contains('kint-search')) { - // Do nothing if you click the search input - } else if (nodeName === 'pre' && e.detail === 3) { - // Triple click pre to select it all - kintRich.selectText(target); - } else if (kintRich.getParentByClass(target, 'kint-source') && e.detail === 3) { - // Tripleclick source code to select it all - kintRich.selectText(kintRich.getParentByClass(target, 'kint-source')); - } else if (target.classList.contains('access-path')) { - // Select the access path - kintRich.selectText(target); - } else if (nodeName !== 'a') { - // If it's not a link at this point, we're probably clicking the bar, so toggle it - target = kintRich.getParentHeader(target); - if (target) { - kintRich.toggle(target); - kintRich.keyboardNav.fetchTargets(); - } - } - }, - true - ); - - // keyboard navigation - window.addEventListener( - 'keydown', - function (e) { - const key_a = 65; - const key_d = 68; - const key_h = 72; - const key_j = 74; - const key_k = 75; - const key_l = 76; - const key_tab = 9; - const key_enter = 13; - const key_esc = 27; - const key_space = 32; - const key_left = 37; - const key_up = 38; - const key_right = 39; - const key_down = 40; - - // do nothing if alt/ctrl key is pressed or if we're actually typing somewhere - if (e.target !== document.body || e.altKey || e.ctrlKey) { - return; } + } + + this.#folder.classList.add('kint-show'); + } + } + + get folder() { + if (!elementIsInDom(this.#folder)) { + this.#folder = this.#kint.window.document.querySelector('.kint-rich.kint-folder'); + + if (this.#folder) { + dedupeElement(this.#folder); + } + } + return this.#folder; + } + + isFolderOpen() { + const foldout = this.#folder?.querySelector('dd.kint-foldout'); + + if (!foldout) { + return undefined; + } + + return foldout.previousSibling.classList.contains('kint-show'); + } + + static getChildContainer(parent) { + let element = parent.nextElementSibling; + while (element && !element.matches('dd')) { + element = element.nextElementSibling; + } + + return element; + } + + static toggle(parent, show) { + const childContainer = Rich.getChildContainer(parent); + + if (!childContainer) { + return; + } + + show = parent.classList.toggle('kint-show', show); + Rich.#toggleCascade(childContainer, show); + } + + static switchTab(tab) { + tab.parentNode + .getElementsByClassName('kint-active-tab')[0] + .classList.remove('kint-active-tab'); + tab.classList.add('kint-active-tab'); + + // take the index of clicked title tab and make the same n-th content tab visible + let el = tab; + let index = 0; + while ((el = el.previousElementSibling)) { + index++; + } + + const tabContents = tab.parentNode.nextSibling.children; + for (let i = tabContents.length; i--; ) { + if (i === index) { + tabContents[i].classList.add('kint-show'); + Rich.#toggleCascade(tabContents[i], true); + } else { + tabContents[i].classList.remove('kint-show'); + } + } + } + + static toggleChildren(parent, show) { + const childContainer = Rich.getChildContainer(parent); + + if (!childContainer) { + return; + } + + if (show === undefined) { + show = parent.classList.contains('kint-show'); + } + + const nodes = childContainer.getElementsByClassName('kint-parent'); + for (const node of nodes) { + node.classList.toggle('kint-show', show); + } + } + + static toggleAccessPath(parent, show) { + const ap = parent.querySelector('.access-path'); + if (ap?.classList.toggle('kint-show', show)) { + selectText(ap); + } + } + + static #toggleCascade(childContainer, show) { + if ( + childContainer.children.length === 2 && + childContainer.lastElementChild.matches('ul.kint-tab-contents') + ) { + for (const li of childContainer.lastElementChild.children) { + if (li.matches('li.kint-show')) { + childContainer = li; + } + } + } + + if ( + childContainer.children.length === 1 && + childContainer.firstElementChild.matches('dl') + ) { + const parent = childContainer?.firstElementChild?.firstElementChild; + + // Parent is checked for a class list in case of empty
+            if (parent?.classList?.contains('kint-parent')) {
+                Rich.toggle(parent, show);
+            }
+        }
+    }
+}
 
-                if (e.keyCode === key_d) {
-                    // Toggles navigation on/off
-                    if (kintRich.keyboardNav.active) {
-                        kintRich.keyboardNav.active = false;
-                    } else {
-                        kintRich.keyboardNav.active = true;
-                        kintRich.keyboardNav.fetchTargets();
-
-                        if (kintRich.keyboardNav.targets.length === 0) {
-                            kintRich.keyboardNav.active = false;
-                            return;
-                        }
-                    }
+class MouseInput {
+    #rich;
+    #keyInput;
+    #window;
+    #lastClickTimer = null;
+    #lastClickTarget = null;
+    #lastClickCount = 0;
+
+    constructor(rich, window, keyInput) {
+        this.#rich = rich;
+        this.#keyInput = keyInput;
+        this.#window = window;
+        this.#window.addEventListener('click', this.#clickHandler.bind(this), true);
+    }
+
+    #renewClickTimeout() {
+        clearTimeout(this.#lastClickTimer);
+        this.#lastClickTimer = setTimeout(this.#resetClickTimeout.bind(this), 250);
+    }
+
+    #resetClickTimeout() {
+        clearTimeout(this.#lastClickTimer);
+        this.#lastClickTimer = null;
+        this.#lastClickTarget = null;
+        this.#lastClickCount = 0;
+    }
+
+    #handleMultiClicks() {
+        const target = this.#lastClickTarget;
+
+        if (!target.matches('.kint-parent > nav')) {
+            return;
+        }
+
+        const parent = target.parentNode;
+
+        if (this.#lastClickCount === 1) {
+            Rich.toggleChildren(parent);
+            this.#keyInput.onTreeChanged();
+
+            this.#renewClickTimeout();
+            this.#lastClickCount = 2;
+        } else if (this.#lastClickCount === 2) {
+            this.#resetClickTimeout();
+
+            const show = parent.classList.contains('kint-show');
+
+            const foldout = this.#rich.folder?.querySelector('.kint-parent');
+            const nodes = this.#window.document.getElementsByClassName('kint-parent');
+            for (const node of nodes) {
+                if (node !== foldout) {
+                    node.classList.toggle('kint-show', show);
+                }
+            }
+
+            this.#keyInput.onTreeChanged();
+            // When unfolding the entire page you frequently end up somewhere
+            // else. By scrolling to the thing you opened it's much easier to
+            // see where you are
+            this.#keyInput.scrollToFocus();
+        }
+
+        return;
+    }
+
+    #clickHandler(e) {
+        // Double/triple click to open children/all
+        if (this.#lastClickCount) {
+            this.#handleMultiClicks();
+            return;
+        }
+
+        const target = e.target;
+
+        // Ignore clicks outside kint
+        if (!target.closest('.kint-rich')) {
+            return;
+        }
+
+        // auto-select name of variable
+        if (target.tagName === 'DFN') {
+            selectText(target);
+        }
+
+        // Sort tables
+        if (target.tagName === 'TH') {
+            if (!e.ctrlKey) {
+                Table.sort(target.closest('table'), target.cellIndex);
+            }
+            return;
+        }
+
+        const parent = target.closest('.kint-parent');
+
+        if (target.tagName === 'LI' && target.parentNode.className === 'kint-tabs') {
+            // switch tabs
+            if (target.className !== 'kint-active-tab') {
+                const cursor = target.closest('dl')?.querySelector('.kint-parent > nav') ?? target;
+                this.#keyInput.setCursor(cursor);
+                Rich.switchTab(target);
+                this.#keyInput.onTreeChanged();
+            }
+
+            return;
+        }
+
+        if (target.tagName === 'NAV') {
+            // handle clicks on the nav
+            if (target.parentNode.tagName === 'FOOTER') {
+                this.#keyInput.setCursor(target);
+                target.parentNode.classList.toggle('kint-show');
+            } else if (parent) {
+                // ensure double/triple click has different behaviour, see above
+                Rich.toggle(parent);
+                this.#keyInput.setCursor(target);
+                this.#keyInput.onTreeChanged();
+                this.#renewClickTimeout();
+                this.#lastClickCount = 1;
+                this.#lastClickTarget = target;
+            }
+        } else if (target.classList.contains('kint-access-path-trigger')) {
+            // Access path
+            const bar = target.closest('.kint-rich dt');
+            if (bar) {
+                Rich.toggleAccessPath(bar);
+            }
+        } else if (target.classList.contains('kint-search-trigger')) {
+            // Search box
+            if (parent) {
+                Search.toggleSearchBox(parent);
+            }
+        } else if (target.classList.contains('kint-search')) {
+            // Do nothing if you click the search input
+        } else if (target.tagName === 'PRE' && e.detail === 3) {
+            // Triple click pre to select it all
+            selectText(target);
+        } else if (target.closest('.kint-source') && e.detail === 3) {
+            // Tripleclick source code to select it all
+            selectText(target.closest('.kint-source'));
+        } else if (target.classList.contains('access-path')) {
+            // Select the access path
+            selectText(target);
+        } else if (target.tagName !== 'A') {
+            // If it's not a link at this point, we're probably clicking the bar, so toggle it
+            if (parent) {
+                Rich.toggle(parent);
+                this.#keyInput.setCursor(parent.querySelector('nav'));
+                this.#keyInput.onTreeChanged();
+            }
+        }
+    }
+}
 
-                    kintRich.keyboardNav.sync();
-                    e.preventDefault();
-                    return;
-                } else if (!kintRich.keyboardNav.active) {
-                    return;
-                } else if (e.keyCode === key_tab) {
-                    // Moves up/down depending on shift key
-                    kintRich.keyboardNav.moveCursor(e.shiftKey ? -1 : 1);
-                    e.preventDefault();
+const key_a = 65;
+const key_d = 68;
+const key_h = 72;
+const key_j = 74;
+const key_k = 75;
+const key_l = 76;
+const key_s = 83;
+const key_tab = 9;
+const key_enter = 13;
+const key_esc = 27;
+const key_space = 32;
+const key_left = 37;
+const key_up = 38;
+const key_right = 39;
+const key_down = 40;
+
+class KeyInput {
+    #targets = []; // all visible toggle navs
+    #target = 0; // currently selected nav
+    #active = false;
+    #rich;
+    #window;
+
+    constructor(rich, kint) {
+        this.#rich = rich;
+        this.#window = kint.window;
+
+        this.#window.addEventListener('keydown', this.#handlePress.bind(this), true);
+
+        // Recalc tree on init so you don't have to leave
+        // keyboard control to fix the target list
+        kint.runOnInit(this.onTreeChanged.bind(this));
+    }
+
+    scrollToFocus() {
+        const el = this.#targets[this.#target];
+        if (!el) {
+            return;
+        }
+
+        const folder = this.#rich.folder;
+        if (el === folder?.querySelector('.kint-parent > nav')) {
+            return;
+        }
+
+        const top = offsetTop(el);
+        if (this.#rich.isFolderOpen()) {
+            const container = folder.querySelector('dd.kint-foldout');
+            container.scrollTo(0, top - container.clientHeight / 2);
+        } else {
+            this.#window.scrollTo(0, top - this.#window.innerHeight / 2);
+        }
+    }
+
+    onTreeChanged() {
+        const selected = this.#targets[this.#target];
+
+        this.#targets = [];
+
+        const folder = this.#rich.folder;
+        const folderNav = folder?.querySelector('.kint-parent > nav');
+
+        let container = this.#window.document;
+        if (this.#rich.isFolderOpen()) {
+            container = folder;
+            this.#targets.push(folderNav);
+        }
+
+        for (const el of container.querySelectorAll(
+            '.kint-rich nav, .kint-tabs>li:not(.kint-active-tab)'
+        )) {
+            // Don't add hidden targets (Inside tabs, inside folder)
+            //
+            // In my tests using selectors instead of offsetParent makes this
+            // process go much faster, but the reflow still has to happen and
+            // all you're doing is pushing it further down the road. Using
+            // offsetParent forces the reflow to happen here for the first time
+            // but that's ok because it has to happen anyway (And also for
+            // scrollToFocus) so you might as well get it over with now and
+            // simplify the code.
+            if (el.offsetParent !== null && el !== folderNav) {
+                this.#targets.push(el);
+            }
+        }
+
+        if (folderNav && !this.#rich.isFolderOpen()) {
+            this.#targets.push(folderNav);
+        }
+
+        if (this.#targets.length === 0) {
+            this.#active = false;
+            this.#onCursorChanged();
+            return;
+        }
+
+        if (selected && this.#targets.indexOf(selected) !== -1) {
+            this.#target = this.#targets.indexOf(selected);
+        } else {
+            // We leave the index as is if we can't find the element any more
+            // because at this point we're probably looking at a tab and we're
+            // fine with it switching to a neighbor when activated
+            this.#onCursorChanged();
+        }
+    }
+
+    setCursor(target) {
+        // Refuse to set cursor outside of folder if folder is open
+        if (this.#rich.isFolderOpen() && !this.#rich.folder.contains(target)) {
+            return false;
+        }
+
+        let i = this.#targets.indexOf(target);
+
+        // If we're still loading, refresh the tree to ensure the cursor is set
+        if (i === -1 && this.#window.document.readyState !== 'complete') {
+            this.onTreeChanged();
+            i = this.#targets.indexOf(target);
+        }
+
+        if (i !== -1) {
+            if (i !== this.#target) {
+                this.#target = i;
+                this.#onCursorChanged();
+                return true;
+            } else {
+                this.#targets[i]?.classList.remove('kint-weak-focus');
+            }
+        }
+
+        return false;
+    }
+
+    #moveCursor(diff) {
+        if (this.#targets.length === 0) {
+            this.#target = 0;
+            return null;
+        }
+
+        this.#target += diff;
+
+        while (this.#target < 0) {
+            this.#target += this.#targets.length;
+        }
+        while (this.#target >= this.#targets.length) {
+            this.#target -= this.#targets.length;
+        }
+
+        this.#onCursorChanged();
+
+        return this.#target;
+    }
+
+    #onCursorChanged() {
+        const prevElement = this.#window.document.querySelector('.kint-focused');
+        if (prevElement) {
+            prevElement.classList.remove('kint-focused');
+            prevElement.classList.remove('kint-weak-focus');
+        }
+
+        if (this.#active) {
+            this.#targets[this.#target]?.classList.add('kint-focused');
+        }
+    }
+
+    #handlePress(e) {
+        if (this.#active && e.keyCode === key_esc && e.target.matches('.kint-search')) {
+            e.target.blur();
+            this.#onCursorChanged();
+            return;
+        }
+
+        // do nothing if alt/ctrl key is pressed or if we're actually typing somewhere
+        if (e.target !== this.#window.document.body || e.altKey || e.ctrlKey) {
+            return;
+        }
+
+        // Activation logic
+        if (e.keyCode === key_d) {
+            // Toggles navigation on/off
+            if (this.#active) {
+                this.#active = false;
+            } else {
+                this.#active = true;
+                this.onTreeChanged();
+
+                if (this.#targets.length === 0) {
+                    this.#active = false;
                     return;
-                } else if (e.keyCode === key_up || e.keyCode === key_k) {
-                    // Moves up
-                    kintRich.keyboardNav.moveCursor(-1);
-                    e.preventDefault();
-                    return;
-                } else if (e.keyCode === key_down || e.keyCode === key_j) {
-                    // Moves down
-                    kintRich.keyboardNav.moveCursor(1);
-                    e.preventDefault();
-                    return;
-                }
-
-                var kintNode = kintRich.keyboardNav.targets[kintRich.keyboardNav.target];
-                if (kintNode.nodeName.toLowerCase() === 'li') {
-                    // When we're on a tab
-                    if (e.keyCode === key_space || e.keyCode === key_enter) {
-                        // Toggle to it
-                        kintRich.switchTab(kintNode);
-                        kintRich.keyboardNav.fetchTargets();
-                        kintRich.keyboardNav.sync();
-                        e.preventDefault();
-                        return;
-                    } else if (e.keyCode === key_right || e.keyCode === key_l) {
-                        // Move right
-                        kintRich.keyboardNav.moveCursor(1);
-                        e.preventDefault();
-                        return;
-                    } else if (e.keyCode === key_left || e.keyCode === key_h) {
-                        // Move left
-                        kintRich.keyboardNav.moveCursor(-1);
-                        e.preventDefault();
-                        return;
-                    }
                 }
 
-                // simple dump
-                kintNode = kintNode.parentNode;
-
-                if (e.keyCode === key_a) {
-                    // Toggles access path on/off
-                    kintRich.showAccessPath(kintNode);
-                    e.preventDefault();
+                this.scrollToFocus();
+            }
+
+            this.#onCursorChanged();
+            e.preventDefault();
+            return;
+        } else if (e.keyCode === key_esc) {
+            if (this.#active) {
+                this.#active = false;
+                this.#onCursorChanged();
+                e.preventDefault();
+            }
+            return;
+        } else if (!this.#active) {
+            return;
+        }
+
+        e.preventDefault();
+
+        const target = this.#targets[this.#target];
+
+        // If something detaches all the nodes we need to regenerate the tree
+        if (!elementIsInDom(target)) {
+            this.onTreeChanged();
+        }
+
+        // Basic movement logic
+        if ([key_tab, key_up, key_k, key_down, key_j].includes(e.keyCode)) {
+            if (e.keyCode === key_tab) {
+                // Moves up/down depending on shift key
+                this.#moveCursor(e.shiftKey ? -1 : 1);
+            } else if (e.keyCode === key_up || e.keyCode === key_k) {
+                // Moves up
+                this.#moveCursor(-1);
+            } else if (e.keyCode === key_down || e.keyCode === key_j) {
+                // Moves down
+                this.#moveCursor(1);
+            }
+
+            this.scrollToFocus();
+            return;
+        }
+
+        // Tab logic
+        if (
+            target.tagName === 'LI' &&
+            [key_space, key_enter, key_right, key_l, key_left, key_h].includes(e.keyCode)
+        ) {
+            // When we're on a tab
+            if (e.keyCode === key_space || e.keyCode === key_enter) {
+                // Toggle to it
+                Rich.switchTab(target);
+                this.onTreeChanged();
+            } else if (e.keyCode === key_right || e.keyCode === key_l) {
+                // Move right
+                this.#moveCursor(1);
+            } else if (e.keyCode === key_left || e.keyCode === key_h) {
+                // Move left
+                this.#moveCursor(-1);
+            }
+
+            this.scrollToFocus();
+            return;
+        }
+
+        const parent = target.closest('.kint-parent');
+        if (!parent) {
+            return;
+        }
+
+        if (e.keyCode === key_a) {
+            // Toggles access path on/off
+            Rich.toggleAccessPath(parent);
+            return;
+        }
+
+        if (e.keyCode === key_s) {
+            // Enables search
+            const topParent = parent
+                .closest('.kint-rich > dl')
+                ?.querySelector('.kint-search')
+                ?.closest('.kint-parent');
+
+            if (topParent) {
+                target.classList.add('kint-weak-focus');
+                Search.toggleSearchBox(topParent, true);
+                return;
+            }
+        }
+
+        if (target.parentNode.tagName === 'FOOTER' && target.closest('.kint-rich')) {
+            // Minitrace needs special class handling
+            if (e.keyCode === key_space || e.keyCode === key_enter) {
+                target.parentNode.classList.toggle('kint-show');
+            } else if (e.keyCode === key_left || e.keyCode === key_h) {
+                target.parentNode.classList.remove('kint-show');
+            } else if (e.keyCode === key_right || e.keyCode === key_l) {
+                target.parentNode.classList.add('kint-show');
+            }
+            return;
+        }
+
+        if (e.keyCode === key_space || e.keyCode === key_enter) {
+            // Toggle for normal nav
+            Rich.toggle(parent);
+            this.onTreeChanged();
+            return;
+        }
+
+        if ([key_right, key_l, key_left, key_h].includes(e.keyCode)) {
+            // Left hides, right opens
+            const show = e.keyCode === key_right || e.keyCode === key_l;
+            const isOpen = parent.classList.contains('kint-show');
+
+            if (show) {
+                // If the target is open
+                if (isOpen) {
+                    // Expand/collapse all children first
+                    Rich.toggleChildren(parent, show);
+                }
+                // Otherwise just expand the current one
+                Rich.toggle(parent, show);
+                this.onTreeChanged();
+                return;
+            } else {
+                if (isOpen) {
+                    // Close the target and all children
+                    Rich.toggleChildren(parent, show);
+                    Rich.toggle(parent, show);
+                    this.onTreeChanged();
                     return;
-                } else if (
-                    kintNode.nodeName.toLowerCase() === 'footer' &&
-                    kintNode.parentNode.classList.contains('kint-rich')
-                ) {
-                    // Minitrace needs special class handling
-                    if (e.keyCode === key_space || e.keyCode === key_enter) {
-                        kintNode.classList.toggle('kint-show');
-                        e.preventDefault();
-                    } else if (e.keyCode === key_left || e.keyCode === key_h) {
-                        kintNode.classList.remove('kint-show');
-                        e.preventDefault();
-                    } else if (e.keyCode === key_right || e.keyCode === key_l) {
-                        kintNode.classList.add('kint-show');
-                        e.preventDefault();
+                } else {
+                    // If it's already closed find the next highest parent
+                    const highTarget = parent
+                        .closest('.kint-rich .kint-parent ~ dd')
+                        ?.parentNode.querySelector('.kint-parent > nav');
+                    if (highTarget) {
+                        this.setCursor(highTarget);
+                        this.scrollToFocus();
                     }
                     return;
-                } else if (e.keyCode === key_space || e.keyCode === key_enter) {
-                    // Toggle for normal nav
-                    kintRich.toggle(kintNode);
-                    kintRich.keyboardNav.fetchTargets();
-                    e.preventDefault();
-                    return;
-                } else if (
-                    e.keyCode === key_right ||
-                    e.keyCode === key_l ||
-                    e.keyCode === key_left ||
-                    e.keyCode === key_h
-                ) {
-                    // Left hides, right opens
-                    var show = e.keyCode === key_right || e.keyCode === key_l;
-
-                    // If the target is open
-                    if (kintNode.classList.contains('kint-show')) {
-                        // Expand/collapse all children first
-                        kintRich.toggleChildren(kintNode, show);
-                    } else if (!show) {
-                        // If the target is already closed and we press left,
-                        // then traverse to parent and close it instead
-                        var parent = kintRich.getParentHeader(kintNode.parentNode.parentNode, true);
-
-                        if (parent) {
-                            kintNode = parent;
-                            kintRich.keyboardNav.setCursor(kintNode.querySelector('nav'));
-                            kintRich.keyboardNav.sync();
-                        }
-                    }
-
-                    kintRich.toggle(kintNode, show);
-
-                    kintRich.keyboardNav.fetchTargets();
-                    e.preventDefault();
-                    return;
                 }
-            },
-            true
-        );
-
-        return kintRich;
-    })();
+            }
+        }
+    }
 }
-
-window.kintShared.runOnce(window.kintRich.initLoad);
diff --git a/resources/js/search.js b/resources/js/search.js
new file mode 100644
index 000000000..e6045e2fc
--- /dev/null
+++ b/resources/js/search.js
@@ -0,0 +1,140 @@
+import { debounce } from './utils.js';
+import Rich from './rich.js';
+
+export default class Search {
+    static #hookedInputs = new Set();
+
+    static toggleSearchBox(parent, show) {
+        const input = parent.querySelector('.kint-search');
+        const root = parent.parentNode;
+
+        if (!input) {
+            return;
+        }
+
+        if (input.classList.toggle('kint-show', show)) {
+            input.focus();
+            input.select();
+
+            if (!Search.#hookedInputs.has(input)) {
+                // If it's a really big dump (eg. symfony container without
+                // depth limit) up the debounce time or it'll be unworkable
+                const subcount = root.querySelectorAll('dl').length;
+                let time = 200;
+                if (subcount > 10000) {
+                    time = 700;
+                }
+
+                input.addEventListener('keyup', debounce(Search.#search.bind(null, input), time));
+                Search.#hookedInputs.add(input);
+            }
+
+            Search.#search(input);
+        } else {
+            root.classList.remove('kint-search-root');
+        }
+    }
+
+    static #search(input) {
+        const root = input.closest('.kint-parent')?.parentNode;
+
+        if (!root) {
+            return;
+        }
+
+        if (input.classList.contains('kint-show') && input.value.length) {
+            const lastSearch = root.dataset.lastSearch;
+            root.classList.add('kint-search-root');
+
+            if (lastSearch !== input.value) {
+                root.dataset.lastSearch = input.value;
+
+                root.classList.remove('kint-search-match');
+                for (const element of root.querySelectorAll('.kint-search-match')) {
+                    element.classList.remove('kint-search-match');
+                }
+
+                Search.#findMatches(root, input.value.toUpperCase());
+            }
+        } else {
+            root.classList.remove('kint-search-root');
+        }
+    }
+
+    static #findMatches(container, term) {
+        const cleaned = container.cloneNode(true);
+        for (const ap of cleaned.querySelectorAll('.access-path')) {
+            ap.remove();
+        }
+
+        if (!cleaned.textContent.toUpperCase().includes(term)) {
+            return;
+        }
+
+        container.classList.add('kint-search-match');
+
+        let parent = container.firstElementChild;
+        while (parent && parent.tagName !== 'DT') {
+            parent = parent.nextElementSibling;
+        }
+
+        if (!parent) {
+            return;
+        }
+
+        const childContainer = Rich.getChildContainer(parent);
+        if (!childContainer) {
+            return;
+        }
+
+        let tabs;
+        let tabContents;
+
+        for (const child of childContainer.children) {
+            if (child.tagName === 'DL') {
+                Search.#findMatches(child, term);
+            } else if (child.tagName === 'UL') {
+                if (child.classList.contains('kint-tabs')) {
+                    tabs = child.childNodes;
+                } else if (child.classList.contains('kint-tab-contents')) {
+                    tabContents = child.childNodes;
+                }
+            }
+        }
+
+        if (!tabs || tabs.length !== tabContents?.length) {
+            return;
+        }
+
+        for (let index = tabs.length; index--; ) {
+            let matchedTab = false;
+            let matchedTabContents = false;
+
+            if (tabs[index].textContent.toUpperCase().includes(term)) {
+                matchedTab = true;
+            }
+
+            const cleaned = tabContents[index].cloneNode(true);
+            for (const ap of cleaned.querySelectorAll('.access-path')) {
+                ap.remove();
+            }
+
+            if (cleaned.textContent.toUpperCase().includes(term)) {
+                matchedTab = true;
+                matchedTabContents = true;
+            }
+
+            if (matchedTab) {
+                tabs[index].classList.add('kint-search-match');
+            }
+
+            if (matchedTabContents) {
+                for (const child of tabContents[index].children) {
+                    if (child.tagName === 'DL') {
+                        Search.#findMatches(child, term);
+                    }
+                }
+            }
+        }
+    }
+}
diff --git a/resources/js/shared.js b/resources/js/shared.js
deleted file mode 100644
index 46218683e..000000000
--- a/resources/js/shared.js
+++ /dev/null
@@ -1,43 +0,0 @@
-if (typeof window.kintShared === 'undefined') {
-    window.kintShared = (function () {
-        'use strict';
-
-        var kintShared = {
-            dedupe: function (selector, keep) {
-                [].forEach.call(document.querySelectorAll(selector), function (elem) {
-                    if (!keep || !keep.ownerDocument.contains(keep)) {
-                        keep = elem;
-                    }
-
-                    if (elem !== keep) {
-                        elem.parentNode.removeChild(elem);
-                    }
-                });
-
-                return keep;
-            },
-
-            runOnce: function (cb) {
-                if (document.readyState === 'complete') {
-                    cb();
-                } else {
-                    window.addEventListener('load', cb);
-                }
-            },
-        };
-
-        window.addEventListener('click', function (e) {
-            'use strict';
-
-            // add ajax call to contact editor but prevent link default action
-            if (e.target.classList.contains('kint-ide-link')) {
-                var ajax = new XMLHttpRequest();
-                ajax.open('GET', e.target.href);
-                ajax.send(null);
-                e.preventDefault();
-            }
-        });
-
-        return kintShared;
-    })();
-}
diff --git a/resources/js/table.js b/resources/js/table.js
new file mode 100644
index 000000000..fe402a0fd
--- /dev/null
+++ b/resources/js/table.js
@@ -0,0 +1,37 @@
+export default class Table {
+    static sort(table, column) {
+        const curSort = table.dataset.kintTableSort;
+        const order = parseInt(curSort) === column ? -1 : 1;
+        const tbody = table.tBodies[0];
+
+        [...tbody.rows]
+            .sort(function (a, b) {
+                a = a.cells[column].textContent.trim().toLocaleLowerCase();
+                b = b.cells[column].textContent.trim().toLocaleLowerCase();
+
+                let diff = 0;
+
+                // In lieu of natsort we just sort all numbers before strings
+                if (!isNaN(a) && !isNaN(b)) {
+                    a = parseFloat(a);
+                    b = parseFloat(b);
+                    diff = a - b;
+                } else if (isNaN(a) && !isNaN(b)) {
+                    diff = 1;
+                } else if (isNaN(b) && !isNaN(a)) {
+                    diff = -1;
+                } else {
+                    diff = ('' + a).localeCompare('' + b);
+                }
+
+                return diff * order;
+            })
+            .forEach((el) => tbody.appendChild(el));
+
+        if (order < 0) {
+            table.dataset.kintTableSort = null;
+        } else {
+            table.dataset.kintTableSort = column;
+        }
+    }
+}
diff --git a/resources/js/utils.js b/resources/js/utils.js
new file mode 100644
index 000000000..a93aaccfb
--- /dev/null
+++ b/resources/js/utils.js
@@ -0,0 +1,66 @@
+export function dedupeElement(element) {
+    if (!(element instanceof Element)) {
+        throw new Error('Invalid argument to dedupeElement()');
+    }
+
+    const document = element.ownerDocument;
+    const selector = buildClassSelector(element);
+
+    for (const elem of document.querySelectorAll(selector)) {
+        if (element !== elem) {
+            elem.parentNode.removeChild(elem);
+        }
+    }
+}
+
+// Why would we need this? Because if someone naively rewrites the dom
+// with something like `body.innerHTML += x` all our node references
+// will be detached and we'll need to reaquire them somehow
+export function elementIsInDom(element) {
+    if (!(element instanceof Element)) {
+        return false;
+    }
+
+    return element.ownerDocument.contains(element);
+}
+
+export function buildClassSelector(element) {
+    if (!(element instanceof Element)) {
+        throw new Error('Invalid argument to buildClassSelector()');
+    }
+
+    return [element.nodeName, ...element.classList].join('.');
+}
+
+export function selectText(element) {
+    if (!(element instanceof Element)) {
+        throw new Error('Invalid argument to selectText()');
+    }
+
+    const document = element.ownerDocument;
+    const selection = document.getSelection();
+    const range = document.createRange();
+
+    range.selectNodeContents(element);
+    selection.removeAllRanges();
+    selection.addRange(range);
+}
+
+export function debounce(cb, time) {
+    let timeout;
+    return function (...args) {
+        clearTimeout(timeout);
+
+        timeout = setTimeout(function () {
+            cb(...args);
+        }, time);
+    };
+}
+
+export function offsetTop(element) {
+    if (!(element instanceof Element)) {
+        throw new Error('Invalid argument to offsetTop()');
+    }
+
+    return element.offsetTop + (element.offsetParent ? offsetTop(element.offsetParent) : 0);
+}
diff --git a/resources/sass/_base.scss b/resources/sass/_base.scss
index 2f4416b4f..17f2caafc 100644
--- a/resources/sass/_base.scss
+++ b/resources/sass/_base.scss
@@ -58,7 +58,11 @@ $caret-image: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5
   }
 
   .kint-focused {
-    box-shadow: 0 0 3px 2px $variable-type-color-hover;
+    box-shadow: 0 0 3px 3px $variable-type-color-hover;
+
+    &.kint-weak-focus {
+      box-shadow: 0 0 3px 1px rgba($variable-type-color-hover, 0.5);
+    }
   }
 
   &,
@@ -187,7 +191,6 @@ $caret-image: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5
     word-break: normal;
   }
 
-  .kint-popup-trigger,
   .kint-access-path-trigger,
   .kint-search-trigger {
     background: rgba($text-color, 0.8);
@@ -213,12 +216,6 @@ $caret-image: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5
     }
   }
 
-  // The ⧉ icon is slightly higher than the ⇆ icon,
-  // so increase the line height to make it line out better
-  dt.kint-parent > .kint-popup-trigger {
-    line-height: $color_size * 1.2 * 1px;
-  }
-
   // The ⌕ icon is slightly smaller than the ⇆ icon,
   // so make it a bit bigger to line it out better
   .kint-search-trigger {
@@ -280,11 +277,6 @@ $caret-image: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5
     font-size: 9px;
     background: transparent;
 
-    > .kint-popup-trigger {
-      background: transparent;
-      color: $text-color;
-    }
-
     nav {
       height: 10px;
       width: 10px;
@@ -509,7 +501,7 @@ $caret-image: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5
   }
 
   // Microtime representation
-  .kint-microtime-lap {
+  .kint-microtime-js .kint-microtime-lap {
     text-shadow:
       -1px 0 $border-color-hover,
       0 1px $border-color-hover,
diff --git a/resources/sass/plain.scss b/resources/sass/plain.scss
index da6dcd49a..574263f77 100644
--- a/resources/sass/plain.scss
+++ b/resources/sass/plain.scss
@@ -16,12 +16,13 @@
     font-weight: bold;
   }
 
-  .kint-microtime-lap {
-    font-weight: bold;
+  .kint-microtime-js .kint-microtime-lap {
     text-shadow:
-      1px 0 #fff,
-      0 1px #fff,
-      -1px 0 #fff,
-      0 -1px #fff;
+      1px 0 #d00,
+      0 1px #d00,
+      -1px 0 #d00,
+      0 -1px #d00;
+    color: #fff;
+    font-weight: bold;
   }
 }
diff --git a/src/Renderer/PlainRenderer.php b/src/Renderer/PlainRenderer.php
index 09befebfe..f40441f01 100644
--- a/src/Renderer/PlainRenderer.php
+++ b/src/Renderer/PlainRenderer.php
@@ -28,7 +28,6 @@
 namespace Kint\Renderer;
 
 use Kint\Kint;
-use Kint\Renderer\Text\MicrotimePlugin;
 use Kint\Zval\BlobValue;
 use Kint\Zval\Value;
 
@@ -37,7 +36,6 @@ class PlainRenderer extends TextRenderer
     public static array $pre_render_sources = [
         'script' => [
             [self::class, 'renderJs'],
-            [MicrotimePlugin::class, 'renderJs'],
         ],
         'style' => [
             [self::class, 'renderCss'],
@@ -186,13 +184,7 @@ public function ideLink(string $file, int $line): string
             return $path;
         }
 
-        $class = '';
-
-        if (\preg_match('/https?:\\/\\//i', $ideLink)) {
-            $class = 'class="kint-ide-link" ';
-        }
-
-        return ''.$path.'';
+        return ''.$path.'';
     }
 
     public function escape(string $string, $encoding = false): string
@@ -228,7 +220,7 @@ protected function utf8ToHtmlentity(string $string): string
 
     protected static function renderJs(): string
     {
-        return \file_get_contents(KINT_DIR.'/resources/compiled/shared.js').\file_get_contents(KINT_DIR.'/resources/compiled/plain.js');
+        return \file_get_contents(KINT_DIR.'/resources/compiled/main.js');
     }
 
     protected static function renderCss(): string
diff --git a/src/Renderer/Rich/MicrotimePlugin.php b/src/Renderer/Rich/MicrotimePlugin.php
index 086e81447..66468772a 100644
--- a/src/Renderer/Rich/MicrotimePlugin.php
+++ b/src/Renderer/Rich/MicrotimePlugin.php
@@ -62,13 +62,4 @@ public function renderTab(Representation $r): ?string
 
         return '
'.$out.'
'; } - - public static function renderJs(): string - { - if (\is_string($out = \file_get_contents(KINT_DIR.'/resources/compiled/microtime.js'))) { - return $out; - } - - return ''; - } } diff --git a/src/Renderer/RichRenderer.php b/src/Renderer/RichRenderer.php index 1113a8147..cb0077ebb 100644 --- a/src/Renderer/RichRenderer.php +++ b/src/Renderer/RichRenderer.php @@ -78,7 +78,6 @@ class RichRenderer extends AbstractRenderer public static array $pre_render_sources = [ 'script' => [ [self::class, 'renderJs'], - [Rich\MicrotimePlugin::class, 'renderJs'], ], 'style' => [ [self::class, 'renderCss'], @@ -273,8 +272,6 @@ public function renderHeaderWrapper(Value $o, bool $has_children, string $conten } if ($has_children) { - $out .= ''; - if (0 === $o->depth) { $out .= ''; $out .= ''; @@ -463,8 +460,6 @@ public function postRender(): string } $output = '