diff --git a/docs/latest/images/anchor-copy-button.svg b/docs/latest/images/anchor-copy-button.svg index bab9d747ff..19c1fa3f4d 100644 --- a/docs/latest/images/anchor-copy-button.svg +++ b/docs/latest/images/anchor-copy-button.svg @@ -1,4 +1,8 @@ + + - \ No newline at end of file + diff --git a/docs/latest/images/arrow_down.svg b/docs/latest/images/arrow_down.svg index c0388dee2c..639aaf12cf 100644 --- a/docs/latest/images/arrow_down.svg +++ b/docs/latest/images/arrow_down.svg @@ -1,3 +1,7 @@ + + - \ No newline at end of file + diff --git a/docs/latest/images/burger.svg b/docs/latest/images/burger.svg index d6dcefccbd..fcca732b77 100644 --- a/docs/latest/images/burger.svg +++ b/docs/latest/images/burger.svg @@ -1,5 +1,9 @@ + + - \ No newline at end of file + diff --git a/docs/latest/images/copy-icon.svg b/docs/latest/images/copy-icon.svg index 61440f0a40..2cb02ec6e7 100644 --- a/docs/latest/images/copy-icon.svg +++ b/docs/latest/images/copy-icon.svg @@ -1,3 +1,7 @@ + + - \ No newline at end of file + diff --git a/docs/latest/images/copy-successful-icon.svg b/docs/latest/images/copy-successful-icon.svg index 1865f739b0..c4b95383de 100644 --- a/docs/latest/images/copy-successful-icon.svg +++ b/docs/latest/images/copy-successful-icon.svg @@ -1,3 +1,7 @@ + + - \ No newline at end of file + diff --git a/docs/latest/images/footer-go-to-link.svg b/docs/latest/images/footer-go-to-link.svg index 0137e22313..a87add7a33 100644 --- a/docs/latest/images/footer-go-to-link.svg +++ b/docs/latest/images/footer-go-to-link.svg @@ -1,3 +1,7 @@ + + - \ No newline at end of file + diff --git a/docs/latest/images/go-to-top-icon.svg b/docs/latest/images/go-to-top-icon.svg index d987f3eadc..abc3d1cef7 100644 --- a/docs/latest/images/go-to-top-icon.svg +++ b/docs/latest/images/go-to-top-icon.svg @@ -1,4 +1,8 @@ + + - \ No newline at end of file + diff --git a/docs/latest/images/logo-icon.svg b/docs/latest/images/logo-icon.svg index 1fea08773f..e42f9570cf 100644 --- a/docs/latest/images/logo-icon.svg +++ b/docs/latest/images/logo-icon.svg @@ -1,3 +1,7 @@ + + @@ -7,4 +11,4 @@ - \ No newline at end of file + diff --git a/docs/latest/images/nav-icons/abstract-class-kotlin.svg b/docs/latest/images/nav-icons/abstract-class-kotlin.svg index a2069b8fb7..19d6148ca6 100644 --- a/docs/latest/images/nav-icons/abstract-class-kotlin.svg +++ b/docs/latest/images/nav-icons/abstract-class-kotlin.svg @@ -1,3 +1,7 @@ + + diff --git a/docs/latest/images/nav-icons/annotation-kotlin.svg b/docs/latest/images/nav-icons/annotation-kotlin.svg index 932f1d3de4..b90f508c47 100644 --- a/docs/latest/images/nav-icons/annotation-kotlin.svg +++ b/docs/latest/images/nav-icons/annotation-kotlin.svg @@ -1,3 +1,7 @@ + + diff --git a/docs/latest/images/nav-icons/class-kotlin.svg b/docs/latest/images/nav-icons/class-kotlin.svg index 46a21f65a0..797a2423cd 100644 --- a/docs/latest/images/nav-icons/class-kotlin.svg +++ b/docs/latest/images/nav-icons/class-kotlin.svg @@ -1,3 +1,7 @@ + + diff --git a/docs/latest/images/nav-icons/enum-kotlin.svg b/docs/latest/images/nav-icons/enum-kotlin.svg index 4a85459683..775a7cc90c 100644 --- a/docs/latest/images/nav-icons/enum-kotlin.svg +++ b/docs/latest/images/nav-icons/enum-kotlin.svg @@ -1,3 +1,7 @@ + + diff --git a/docs/latest/images/nav-icons/field-value.svg b/docs/latest/images/nav-icons/field-value.svg index 20449c9475..2771ee56cb 100644 --- a/docs/latest/images/nav-icons/field-value.svg +++ b/docs/latest/images/nav-icons/field-value.svg @@ -1,3 +1,7 @@ + + diff --git a/docs/latest/images/nav-icons/field-variable.svg b/docs/latest/images/nav-icons/field-variable.svg index 3b0745007f..e2d2bbd015 100644 --- a/docs/latest/images/nav-icons/field-variable.svg +++ b/docs/latest/images/nav-icons/field-variable.svg @@ -1,3 +1,7 @@ + + diff --git a/docs/latest/images/nav-icons/interface-kotlin.svg b/docs/latest/images/nav-icons/interface-kotlin.svg index bf07a1488e..5e163260e1 100644 --- a/docs/latest/images/nav-icons/interface-kotlin.svg +++ b/docs/latest/images/nav-icons/interface-kotlin.svg @@ -1,3 +1,7 @@ + + diff --git a/docs/latest/images/nav-icons/object.svg b/docs/latest/images/nav-icons/object.svg index 9f427de413..31f0ee3e6b 100644 --- a/docs/latest/images/nav-icons/object.svg +++ b/docs/latest/images/nav-icons/object.svg @@ -1,3 +1,7 @@ + + diff --git a/docs/latest/images/nav-icons/typealias-kotlin.svg b/docs/latest/images/nav-icons/typealias-kotlin.svg index 4795069b26..f4bb238b5b 100644 --- a/docs/latest/images/nav-icons/typealias-kotlin.svg +++ b/docs/latest/images/nav-icons/typealias-kotlin.svg @@ -1,3 +1,7 @@ + + diff --git a/docs/latest/images/theme-toggle.svg b/docs/latest/images/theme-toggle.svg index dad3ff2a2c..df86202bb9 100644 --- a/docs/latest/images/theme-toggle.svg +++ b/docs/latest/images/theme-toggle.svg @@ -1,3 +1,7 @@ + + - \ No newline at end of file + diff --git a/docs/latest/scripts/clipboard.js b/docs/latest/scripts/clipboard.js index b00ce246ef..7a4f33c598 100644 --- a/docs/latest/scripts/clipboard.js +++ b/docs/latest/scripts/clipboard.js @@ -1,3 +1,7 @@ +/* + * Copyright 2014-2023 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license. + */ + window.addEventListener('load', () => { document.querySelectorAll('span.copy-icon').forEach(element => { element.addEventListener('click', (el) => copyElementsContentToClipboard(element)); diff --git a/docs/latest/scripts/navigation-loader.js b/docs/latest/scripts/navigation-loader.js index 92464911c6..3df7ac8ccb 100644 --- a/docs/latest/scripts/navigation-loader.js +++ b/docs/latest/scripts/navigation-loader.js @@ -1,3 +1,7 @@ +/* + * Copyright 2014-2023 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license. + */ + navigationPageText = fetch(pathToRoot + "navigation.html").then(response => response.text()) displayNavigationFromPage = () => { diff --git a/docs/latest/scripts/platform-content-handler.js b/docs/latest/scripts/platform-content-handler.js index 7c5e8af73d..8c4ca53830 100644 --- a/docs/latest/scripts/platform-content-handler.js +++ b/docs/latest/scripts/platform-content-handler.js @@ -1,3 +1,7 @@ +/* + * Copyright 2014-2023 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license. + */ + filteringContext = { dependencies: {}, restrictedDependencies: [], diff --git a/docs/latest/scripts/sourceset_dependencies.js b/docs/latest/scripts/sourceset_dependencies.js index 5eb40f013a..29a75f7c84 100644 --- a/docs/latest/scripts/sourceset_dependencies.js +++ b/docs/latest/scripts/sourceset_dependencies.js @@ -1 +1 @@ -sourceset_dependencies = '{":zipline-gradle-plugin:dokkaHtmlPartial/main":[],":zipline-loader:dokkaHtmlPartial/androidDebug":[":zipline-loader:dokkaHtmlPartial/commonMain"],":zipline-loader:dokkaHtmlPartial/androidMain":[":zipline-loader:dokkaHtmlPartial/jniMain",":zipline-loader:dokkaHtmlPartial/commonMain"],":zipline-loader:dokkaHtmlPartial/androidRelease":[":zipline-loader:dokkaHtmlPartial/commonMain"],":zipline-loader:dokkaHtmlPartial/commonMain":[],":zipline-loader:dokkaHtmlPartial/iosArm64Main":[":zipline-loader:dokkaHtmlPartial/nativeMain",":zipline-loader:dokkaHtmlPartial/commonMain"],":zipline-loader:dokkaHtmlPartial/iosSimulatorArm64Main":[":zipline-loader:dokkaHtmlPartial/nativeMain",":zipline-loader:dokkaHtmlPartial/commonMain"],":zipline-loader:dokkaHtmlPartial/iosX64Main":[":zipline-loader:dokkaHtmlPartial/nativeMain",":zipline-loader:dokkaHtmlPartial/commonMain"],":zipline-loader:dokkaHtmlPartial/jniMain":[":zipline-loader:dokkaHtmlPartial/commonMain"],":zipline-loader:dokkaHtmlPartial/jvmMain":[":zipline-loader:dokkaHtmlPartial/jniMain",":zipline-loader:dokkaHtmlPartial/commonMain"],":zipline-loader:dokkaHtmlPartial/macosArm64Main":[":zipline-loader:dokkaHtmlPartial/nativeMain",":zipline-loader:dokkaHtmlPartial/commonMain"],":zipline-loader:dokkaHtmlPartial/macosX64Main":[":zipline-loader:dokkaHtmlPartial/nativeMain",":zipline-loader:dokkaHtmlPartial/commonMain"],":zipline-loader:dokkaHtmlPartial/nativeMain":[":zipline-loader:dokkaHtmlPartial/commonMain"],":zipline-loader:dokkaHtmlPartial/tvosArm64Main":[":zipline-loader:dokkaHtmlPartial/nativeMain",":zipline-loader:dokkaHtmlPartial/commonMain"],":zipline-loader:dokkaHtmlPartial/tvosSimulatorArm64Main":[":zipline-loader:dokkaHtmlPartial/nativeMain",":zipline-loader:dokkaHtmlPartial/commonMain"],":zipline-loader:dokkaHtmlPartial/tvosX64Main":[":zipline-loader:dokkaHtmlPartial/nativeMain",":zipline-loader:dokkaHtmlPartial/commonMain"],":zipline:dokkaHtmlPartial/androidDebug":[":zipline:dokkaHtmlPartial/commonMain"],":zipline:dokkaHtmlPartial/androidMain":[":zipline:dokkaHtmlPartial/jniMain",":zipline:dokkaHtmlPartial/commonMain"],":zipline:dokkaHtmlPartial/androidRelease":[":zipline:dokkaHtmlPartial/commonMain"],":zipline:dokkaHtmlPartial/commonMain":[],":zipline:dokkaHtmlPartial/hostMain":[":zipline:dokkaHtmlPartial/commonMain"],":zipline:dokkaHtmlPartial/iosArm64Main":[":zipline:dokkaHtmlPartial/commonMain",":zipline:dokkaHtmlPartial/nativeMain"],":zipline:dokkaHtmlPartial/iosSimulatorArm64Main":[":zipline:dokkaHtmlPartial/commonMain",":zipline:dokkaHtmlPartial/nativeMain"],":zipline:dokkaHtmlPartial/iosX64Main":[":zipline:dokkaHtmlPartial/commonMain",":zipline:dokkaHtmlPartial/nativeMain"],":zipline:dokkaHtmlPartial/jniMain":[":zipline:dokkaHtmlPartial/hostMain"],":zipline:dokkaHtmlPartial/jsMain":[":zipline:dokkaHtmlPartial/commonMain"],":zipline:dokkaHtmlPartial/jvmMain":[":zipline:dokkaHtmlPartial/jniMain",":zipline:dokkaHtmlPartial/commonMain"],":zipline:dokkaHtmlPartial/linuxX64Main":[":zipline:dokkaHtmlPartial/commonMain",":zipline:dokkaHtmlPartial/nativeMain"],":zipline:dokkaHtmlPartial/macosArm64Main":[":zipline:dokkaHtmlPartial/commonMain",":zipline:dokkaHtmlPartial/nativeMain"],":zipline:dokkaHtmlPartial/macosX64Main":[":zipline:dokkaHtmlPartial/commonMain",":zipline:dokkaHtmlPartial/nativeMain"],":zipline:dokkaHtmlPartial/nativeMain":[":zipline:dokkaHtmlPartial/hostMain"],":zipline:dokkaHtmlPartial/tvosArm64Main":[":zipline:dokkaHtmlPartial/commonMain",":zipline:dokkaHtmlPartial/nativeMain"],":zipline:dokkaHtmlPartial/tvosSimulatorArm64Main":[":zipline:dokkaHtmlPartial/commonMain",":zipline:dokkaHtmlPartial/nativeMain"],":zipline:dokkaHtmlPartial/tvosX64Main":[":zipline:dokkaHtmlPartial/commonMain",":zipline:dokkaHtmlPartial/nativeMain"],":zipline-profiler:dokkaHtmlPartial/commonMain":[],":zipline-profiler:dokkaHtmlPartial/iosArm64Main":[":zipline-profiler:dokkaHtmlPartial/nativeMain",":zipline-profiler:dokkaHtmlPartial/commonMain"],":zipline-profiler:dokkaHtmlPartial/iosSimulatorArm64Main":[":zipline-profiler:dokkaHtmlPartial/nativeMain",":zipline-profiler:dokkaHtmlPartial/commonMain"],":zipline-profiler:dokkaHtmlPartial/iosX64Main":[":zipline-profiler:dokkaHtmlPartial/nativeMain",":zipline-profiler:dokkaHtmlPartial/commonMain"],":zipline-profiler:dokkaHtmlPartial/jvmMain":[":zipline-profiler:dokkaHtmlPartial/commonMain"],":zipline-profiler:dokkaHtmlPartial/linuxX64Main":[":zipline-profiler:dokkaHtmlPartial/nativeMain",":zipline-profiler:dokkaHtmlPartial/commonMain"],":zipline-profiler:dokkaHtmlPartial/macosArm64Main":[":zipline-profiler:dokkaHtmlPartial/nativeMain",":zipline-profiler:dokkaHtmlPartial/commonMain"],":zipline-profiler:dokkaHtmlPartial/macosX64Main":[":zipline-profiler:dokkaHtmlPartial/nativeMain",":zipline-profiler:dokkaHtmlPartial/commonMain"],":zipline-profiler:dokkaHtmlPartial/nativeMain":[":zipline-profiler:dokkaHtmlPartial/commonMain"],":zipline-profiler:dokkaHtmlPartial/tvosArm64Main":[":zipline-profiler:dokkaHtmlPartial/nativeMain",":zipline-profiler:dokkaHtmlPartial/commonMain"],":zipline-profiler:dokkaHtmlPartial/tvosSimulatorArm64Main":[":zipline-profiler:dokkaHtmlPartial/nativeMain",":zipline-profiler:dokkaHtmlPartial/commonMain"],":zipline-profiler:dokkaHtmlPartial/tvosX64Main":[":zipline-profiler:dokkaHtmlPartial/nativeMain",":zipline-profiler:dokkaHtmlPartial/commonMain"]}' \ No newline at end of file +sourceset_dependencies = '{":zipline-gradle-plugin:dokkaHtmlPartial/main":[],":zipline-loader:dokkaHtmlPartial/androidDebug":[":zipline-loader:dokkaHtmlPartial/commonMain"],":zipline-loader:dokkaHtmlPartial/androidMain":[":zipline-loader:dokkaHtmlPartial/jniMain",":zipline-loader:dokkaHtmlPartial/commonMain"],":zipline-loader:dokkaHtmlPartial/androidRelease":[":zipline-loader:dokkaHtmlPartial/commonMain"],":zipline-loader:dokkaHtmlPartial/commonMain":[],":zipline-loader:dokkaHtmlPartial/iosArm64Main":[":zipline-loader:dokkaHtmlPartial/nativeMain",":zipline-loader:dokkaHtmlPartial/commonMain"],":zipline-loader:dokkaHtmlPartial/iosSimulatorArm64Main":[":zipline-loader:dokkaHtmlPartial/nativeMain",":zipline-loader:dokkaHtmlPartial/commonMain"],":zipline-loader:dokkaHtmlPartial/iosX64Main":[":zipline-loader:dokkaHtmlPartial/nativeMain",":zipline-loader:dokkaHtmlPartial/commonMain"],":zipline-loader:dokkaHtmlPartial/jniMain":[":zipline-loader:dokkaHtmlPartial/commonMain"],":zipline-loader:dokkaHtmlPartial/jvmMain":[":zipline-loader:dokkaHtmlPartial/jniMain",":zipline-loader:dokkaHtmlPartial/commonMain"],":zipline-loader:dokkaHtmlPartial/macosArm64Main":[":zipline-loader:dokkaHtmlPartial/nativeMain",":zipline-loader:dokkaHtmlPartial/commonMain"],":zipline-loader:dokkaHtmlPartial/macosX64Main":[":zipline-loader:dokkaHtmlPartial/nativeMain",":zipline-loader:dokkaHtmlPartial/commonMain"],":zipline-loader:dokkaHtmlPartial/nativeMain":[":zipline-loader:dokkaHtmlPartial/commonMain"],":zipline-loader:dokkaHtmlPartial/tvosArm64Main":[":zipline-loader:dokkaHtmlPartial/nativeMain",":zipline-loader:dokkaHtmlPartial/commonMain"],":zipline-loader:dokkaHtmlPartial/tvosSimulatorArm64Main":[":zipline-loader:dokkaHtmlPartial/nativeMain",":zipline-loader:dokkaHtmlPartial/commonMain"],":zipline-loader:dokkaHtmlPartial/tvosX64Main":[":zipline-loader:dokkaHtmlPartial/nativeMain",":zipline-loader:dokkaHtmlPartial/commonMain"],":zipline:dokkaHtmlPartial/androidDebug":[":zipline:dokkaHtmlPartial/commonMain"],":zipline:dokkaHtmlPartial/androidMain":[":zipline:dokkaHtmlPartial/jniMain",":zipline:dokkaHtmlPartial/commonMain"],":zipline:dokkaHtmlPartial/androidRelease":[":zipline:dokkaHtmlPartial/commonMain"],":zipline:dokkaHtmlPartial/commonMain":[],":zipline:dokkaHtmlPartial/hostMain":[":zipline:dokkaHtmlPartial/commonMain"],":zipline:dokkaHtmlPartial/iosArm64Main":[":zipline:dokkaHtmlPartial/nativeMain",":zipline:dokkaHtmlPartial/commonMain"],":zipline:dokkaHtmlPartial/iosSimulatorArm64Main":[":zipline:dokkaHtmlPartial/nativeMain",":zipline:dokkaHtmlPartial/commonMain"],":zipline:dokkaHtmlPartial/iosX64Main":[":zipline:dokkaHtmlPartial/nativeMain",":zipline:dokkaHtmlPartial/commonMain"],":zipline:dokkaHtmlPartial/jniMain":[":zipline:dokkaHtmlPartial/hostMain"],":zipline:dokkaHtmlPartial/jsMain":[":zipline:dokkaHtmlPartial/commonMain"],":zipline:dokkaHtmlPartial/jvmMain":[":zipline:dokkaHtmlPartial/jniMain",":zipline:dokkaHtmlPartial/commonMain"],":zipline:dokkaHtmlPartial/linuxX64Main":[":zipline:dokkaHtmlPartial/nativeMain",":zipline:dokkaHtmlPartial/commonMain"],":zipline:dokkaHtmlPartial/macosArm64Main":[":zipline:dokkaHtmlPartial/nativeMain",":zipline:dokkaHtmlPartial/commonMain"],":zipline:dokkaHtmlPartial/macosX64Main":[":zipline:dokkaHtmlPartial/nativeMain",":zipline:dokkaHtmlPartial/commonMain"],":zipline:dokkaHtmlPartial/nativeMain":[":zipline:dokkaHtmlPartial/hostMain"],":zipline:dokkaHtmlPartial/tvosArm64Main":[":zipline:dokkaHtmlPartial/nativeMain",":zipline:dokkaHtmlPartial/commonMain"],":zipline:dokkaHtmlPartial/tvosSimulatorArm64Main":[":zipline:dokkaHtmlPartial/nativeMain",":zipline:dokkaHtmlPartial/commonMain"],":zipline:dokkaHtmlPartial/tvosX64Main":[":zipline:dokkaHtmlPartial/nativeMain",":zipline:dokkaHtmlPartial/commonMain"],":zipline-profiler:dokkaHtmlPartial/commonMain":[],":zipline-profiler:dokkaHtmlPartial/iosArm64Main":[":zipline-profiler:dokkaHtmlPartial/nativeMain",":zipline-profiler:dokkaHtmlPartial/commonMain"],":zipline-profiler:dokkaHtmlPartial/iosSimulatorArm64Main":[":zipline-profiler:dokkaHtmlPartial/nativeMain",":zipline-profiler:dokkaHtmlPartial/commonMain"],":zipline-profiler:dokkaHtmlPartial/iosX64Main":[":zipline-profiler:dokkaHtmlPartial/nativeMain",":zipline-profiler:dokkaHtmlPartial/commonMain"],":zipline-profiler:dokkaHtmlPartial/jvmMain":[":zipline-profiler:dokkaHtmlPartial/commonMain"],":zipline-profiler:dokkaHtmlPartial/linuxX64Main":[":zipline-profiler:dokkaHtmlPartial/nativeMain",":zipline-profiler:dokkaHtmlPartial/commonMain"],":zipline-profiler:dokkaHtmlPartial/macosArm64Main":[":zipline-profiler:dokkaHtmlPartial/nativeMain",":zipline-profiler:dokkaHtmlPartial/commonMain"],":zipline-profiler:dokkaHtmlPartial/macosX64Main":[":zipline-profiler:dokkaHtmlPartial/nativeMain",":zipline-profiler:dokkaHtmlPartial/commonMain"],":zipline-profiler:dokkaHtmlPartial/nativeMain":[":zipline-profiler:dokkaHtmlPartial/commonMain"],":zipline-profiler:dokkaHtmlPartial/tvosArm64Main":[":zipline-profiler:dokkaHtmlPartial/nativeMain",":zipline-profiler:dokkaHtmlPartial/commonMain"],":zipline-profiler:dokkaHtmlPartial/tvosSimulatorArm64Main":[":zipline-profiler:dokkaHtmlPartial/nativeMain",":zipline-profiler:dokkaHtmlPartial/commonMain"],":zipline-profiler:dokkaHtmlPartial/tvosX64Main":[":zipline-profiler:dokkaHtmlPartial/nativeMain",":zipline-profiler:dokkaHtmlPartial/commonMain"]}' \ No newline at end of file diff --git a/docs/latest/scripts/symbol-parameters-wrapper_deferred.js b/docs/latest/scripts/symbol-parameters-wrapper_deferred.js index 248d0ab033..7ecae7a6ae 100644 --- a/docs/latest/scripts/symbol-parameters-wrapper_deferred.js +++ b/docs/latest/scripts/symbol-parameters-wrapper_deferred.js @@ -1,83 +1,64 @@ +/* + * Copyright 2014-2023 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license. + */ + // helps with some corner cases where starts working already, // but the signature is not yet long enough to be wrapped -const leftPaddingPx = 60 - -const symbolResizeObserver = new ResizeObserver(entries => { - entries.forEach(entry => { - const symbolElement = entry.target - symbolResizeObserver.unobserve(symbolElement) // only need it once, otherwise will be executed multiple times - wrapSymbolParameters(symbolElement); - }) -}); - -const wrapAllSymbolParameters = () => { - document.querySelectorAll("div.symbol").forEach(symbol => wrapSymbolParameters(symbol)) -} +(function() { + const leftPaddingPx = 60; -const wrapSymbolParameters = (symbol) => { - let parametersBlock = symbol.querySelector("span.parameters") - if (parametersBlock == null) { - return // nothing to wrap + function createNbspIndent() { + let indent = document.createElement("span"); + indent.append(document.createTextNode("\u00A0\u00A0\u00A0\u00A0")); + indent.classList.add("nbsp-indent"); + return indent; } - let symbolBlockWidth = symbol.clientWidth + function wrapSymbolParameters(entry) { + const symbol = entry.target; + const symbolBlockWidth = entry.borderBoxSize && entry.borderBoxSize[0] && entry.borderBoxSize[0].inlineSize; - // Even though the script is marked as `defer` and we wait for `DOMContentLoaded` event, - // it can happen that `symbolBlockWidth` is 0, indicating that something hasn't been loaded. - // In this case, just retry once all styles have been applied and it has been resized correctly. - if (symbolBlockWidth === 0) { - symbolResizeObserver.observe(symbol) - return - } + // Even though the script is marked as `defer` and we wait for `DOMContentLoaded` event, + // or if this block is a part of hidden tab, it can happen that `symbolBlockWidth` is 0, + // indicating that something hasn't been loaded. + // In this case, observer will be triggered onсe again when it will be ready. + if (symbolBlockWidth > 0) { + const node = symbol.querySelector(".parameters"); - let innerTextWidth = Array.from(symbol.children) - .filter(it => !it.classList.contains("block")) // blocks are usually on their own (like annotations), so ignore it - .map(it => it.getBoundingClientRect().width).reduce((a, b) => a + b, 0) + if (node) { + // if window resize happened and observer was triggered, reset previously wrapped + // parameters as they might not need wrapping anymore, and check again + node.classList.remove("wrapped"); + node.querySelectorAll(".parameter .nbsp-indent") + .forEach(indent => indent.remove()); - // if signature text takes up more than a single line, wrap params for readability - let shouldWrapParams = innerTextWidth > (symbolBlockWidth - leftPaddingPx) - if (shouldWrapParams) { - parametersBlock.classList.add("wrapped") - parametersBlock.querySelectorAll("span.parameter").forEach(param => { - // has to be a physical indent so that it can be copied. styles like - // paddings and `::before { content: " " }` do not work for that - param.prepend(createNbspIndent()) - }) - } -} + const innerTextWidth = Array.from(symbol.children) + .filter(it => !it.classList.contains("block")) // blocks are usually on their own (like annotations), so ignore it + .map(it => it.getBoundingClientRect().width) + .reduce((a, b) => a + b, 0); -const createNbspIndent = () => { - let indent = document.createElement("span") - indent.append(document.createTextNode("\u00A0\u00A0\u00A0\u00A0")) - indent.classList.add("nbsp-indent") - return indent -} + // if signature text takes up more than a single line, wrap params for readability + if (innerTextWidth > (symbolBlockWidth - leftPaddingPx)) { + node.classList.add("wrapped"); + node.querySelectorAll(".parameter").forEach(param => { + // has to be a physical indent so that it can be copied. styles like + // paddings and `::before { content: " " }` do not work for that + param.prepend(createNbspIndent()); + }); + } + } + } + } -const resetAllSymbolParametersWrapping = () => { - document.querySelectorAll("div.symbol").forEach(symbol => resetSymbolParametersWrapping(symbol)) -} + const symbolsObserver = new ResizeObserver(entries => entries.forEach(wrapSymbolParameters)); -const resetSymbolParametersWrapping = (symbol) => { - let parameters = symbol.querySelector("span.parameters") - if (parameters != null) { - parameters.classList.remove("wrapped") - parameters.querySelectorAll("span.parameter").forEach(param => { - let indent = param.querySelector("span.nbsp-indent") - if (indent != null) indent.remove() - }) + function initHandlers() { + document.querySelectorAll("div.symbol").forEach(symbol => symbolsObserver.observe(symbol)); } -} -if (document.readyState === 'loading') { - window.addEventListener('DOMContentLoaded', () => { - wrapAllSymbolParameters() - }) -} else { - wrapAllSymbolParameters() -} + if (document.readyState === 'loading') window.addEventListener('DOMContentLoaded', initHandlers); + else initHandlers(); -window.onresize = event => { - // need to re-calculate if params need to be wrapped after resize - resetAllSymbolParametersWrapping() - wrapAllSymbolParameters() -} + // ToDo: Add `unobserve` if dokka will be SPA-like: + // https://github.com/w3c/csswg-drafts/issues/5155 +})(); diff --git a/docs/latest/styles/font-jb-sans-auto.css b/docs/latest/styles/font-jb-sans-auto.css index 95d8ef8334..bdc68723af 100644 --- a/docs/latest/styles/font-jb-sans-auto.css +++ b/docs/latest/styles/font-jb-sans-auto.css @@ -1,3 +1,7 @@ +/* + * Copyright 2014-2023 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license. + */ + /* Light weight */ @font-face { font-family: 'JetBrains Sans'; diff --git a/docs/latest/styles/logo-styles.css b/docs/latest/styles/logo-styles.css index f3846e8219..69804e4688 100644 --- a/docs/latest/styles/logo-styles.css +++ b/docs/latest/styles/logo-styles.css @@ -1,3 +1,7 @@ +/* + * Copyright 2014-2023 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license. + */ + :root { --dokka-logo-image-url: url('../images/logo-icon.svg'); --dokka-logo-height: 50px; diff --git a/docs/latest/styles/main.css b/docs/latest/styles/main.css index 5aa04a4969..ebe1ce12f0 100644 --- a/docs/latest/styles/main.css +++ b/docs/latest/styles/main.css @@ -1,4 +1,6 @@ -#pages-search{cursor:pointer;border:none;border-radius:50%;background:transparent;fill:#fff;fill:var(--dark-mode-and-search-icon-color)}#pages-search:focus{outline:none}#pages-search:hover{background:var(--white-10)}.search,.search [data-test=ring-select],.search [data-test=ring-tooltip],.search [data-test=ring-select_focus],.search #pages-search{display:inline-block;padding:0;margin:0;font-size:0;line-height:0}.search-hotkey-popup{background-color:var(--background-color) !important;padding:4px}.popup-wrapper{min-width:calc(100% - 322px) !important;border:1px solid rgba(255,255,255,.2) !important;background-color:#27282c !important}.popup-wrapper [class^=filterWrapper]{border-bottom:1px solid rgba(255,255,255,.2)}.popup-wrapper input{color:rgba(255,255,255,.8) !important;font-weight:normal !important}.popup-wrapper span[data-test-custom=ring-select-popup-filter-icon]{color:#fff}.popup-wrapper button[data-test=ring-input-clear]{color:#fff !important}@media screen and (max-width: 759px){.popup-wrapper{min-width:100% !important}}.template-wrapper{display:grid;height:32px;grid-template-columns:auto auto}.template-wrapper strong{color:rgba(255,255,255,.8)}.template-wrapper span{color:rgba(255,255,255,.8);line-height:32px}.template-wrapper span.template-description{color:rgba(255,255,255,.6);justify-self:end}@media screen and (max-width: 759px){.template-wrapper{display:flex;flex-direction:column;height:auto}.template-wrapper span{line-height:unset}}.template-name{justify-self:start}[class^=fade]{display:none}[class*=hover]{background-color:rgba(255,255,255,.1) !important} +/*! + * Copyright 2014-2023 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license. + */#pages-search{cursor:pointer;border:none;border-radius:50%;background:transparent;fill:#fff;fill:var(--dark-mode-and-search-icon-color)}#pages-search:focus{outline:none}#pages-search:hover{background:var(--white-10)}.search,.search [data-test=ring-select],.search [data-test=ring-tooltip],.search [data-test=ring-select_focus],.search #pages-search{display:inline-block;padding:0;margin:0;font-size:0;line-height:0}.search-hotkey-popup{background-color:var(--background-color) !important;padding:4px}.popup-wrapper{min-width:calc(100% - 322px) !important;border:1px solid rgba(255,255,255,.2) !important;background-color:#27282c !important}.popup-wrapper [class^=filterWrapper]{border-bottom:1px solid rgba(255,255,255,.2)}.popup-wrapper input{color:rgba(255,255,255,.8) !important;font-weight:normal !important}.popup-wrapper span[data-test-custom=ring-select-popup-filter-icon]{color:#fff}.popup-wrapper button[data-test=ring-input-clear]{color:#fff !important}@media screen and (max-width: 759px){.popup-wrapper{min-width:100% !important}}.template-wrapper{display:grid;height:32px;grid-template-columns:auto auto}.template-wrapper strong{color:rgba(255,255,255,.8)}.template-wrapper span{color:rgba(255,255,255,.8);line-height:32px}.template-wrapper span.template-description{color:rgba(255,255,255,.6);justify-self:end}@media screen and (max-width: 759px){.template-wrapper{display:flex;flex-direction:column;height:auto}.template-wrapper span{line-height:unset}}.template-name{justify-self:start}[class^=fade]{display:none}[class*=hover]{background-color:rgba(255,255,255,.1) !important} /* stylelint-disable color-no-hex */ :root { @@ -113,6 +115,10 @@ --ring-alert-z-index: 6; } -html,.app-root{height:100%}.search-root{margin:0;padding:0;background:var(--ring-content-background-color);font-family:var(--ring-font-family);font-size:var(--ring-font-size);line-height:var(--ring-line-height)}.search-content{z-index:8} +/*! + * Copyright 2014-2023 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license. + *//*! + * Copyright 2014-2023 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license. + */html,.app-root{height:100%}.search-root{margin:0;padding:0;background:var(--ring-content-background-color);font-family:var(--ring-font-family);font-size:var(--ring-font-size);line-height:var(--ring-line-height)}.search-content{z-index:8} /*# sourceMappingURL=main.css.map*/ \ No newline at end of file diff --git a/docs/latest/styles/prism.css b/docs/latest/styles/prism.css index 4287f6d123..2d3a091e45 100644 --- a/docs/latest/styles/prism.css +++ b/docs/latest/styles/prism.css @@ -1,3 +1,7 @@ +/* + * Copyright 2014-2023 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license. + */ + /* * Custom Dokka styles */ diff --git a/docs/latest/styles/style.css b/docs/latest/styles/style.css index 7f6e4b0dc8..67a899a594 100644 --- a/docs/latest/styles/style.css +++ b/docs/latest/styles/style.css @@ -1,3 +1,7 @@ +/* + * Copyright 2014-2023 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license. + */ + @import url('./font-jb-sans-auto.css'); @import url('https://fonts.googleapis.com/css?family=JetBrains+Mono'); @@ -1476,4 +1480,4 @@ has only one header, and the header text is the same as the tab name, so no poin */ .main-content[data-page-type="package"] .tabs-section-body h2 { display: none; -} \ No newline at end of file +}