Skip to content

Commit e3f6508

Browse files
committed
1 parent 620b373 commit e3f6508

File tree

2,558 files changed

+6423
-6406
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

2,558 files changed

+6423
-6406
lines changed
Lines changed: 3 additions & 0 deletions
Loading

snapshots/components/kook/index.html

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@
4646
</a>
4747
</div>
4848
<div class="library-version">
49-
4.0.0-beta2-SNAPSHOT </div>
49+
4.0.0-beta3-SNAPSHOT </div>
5050
</div>
5151
</div>
5252
<div class="navigation-controls">
@@ -63,7 +63,7 @@
6363
<div class="breadcrumbs"></div>
6464
<div class="cover ">
6565
<div class="cover ">
66-
<h1 class=""></h1>
66+
<h1 class=""> </h1>
6767
<!--suppress HtmlDeprecatedAttribute --><div align="center">
6868
<picture>
6969
<source media="(prefers-color-scheme: dark)" srcset=".simbot/logo-dark.svg">
@@ -97,7 +97,7 @@ <h2>
9797
<blockquote class="quotation">
9898
<p class="paragraph">!Note 下文中 <code class="lang-kotlin">Simple Robot v4</code> 简称为 <code class="lang-kotlin">simbot4</code></p>
9999
</blockquote>
100-
<h2 class=""> 文档与引导</h2>
100+
<h2 class="">文档与引导</h2>
101101
<ul>
102102
<li>
103103
<p class="paragraph">KOOK组件手册: <a href="https://component-kook.simbot.forte.love/">手册</a> (即当前仓库的 GitHub Pages)</p>
@@ -116,15 +116,15 @@ <h2 class=""> 文档与引导</h2>
116116
</li>
117117
</ul>
118118

119-
<h2 class=""> 支持列表</h2>
119+
<h2 class="">支持列表</h2>
120120
<p class="paragraph">前往 support-list.md 查看已经支持的API、尚未支持的API。 如果你迫切的希望支持某些API,而它们尚未被支持,请<a href="https://github.com/simple-robot/simbot-component-kook/issues">让我们知道</a>!</p>
121-
<h2 class=""> 贡献</h2>
121+
<h2 class="">贡献</h2>
122122
<p class="paragraph">前往 docs/CONTRIBUTING_CN.md 了解更多!</p>
123-
<h2 class=""> 快速开始</h2>
123+
<h2 class="">快速开始</h2>
124124
<p class="paragraph">前往 <a href="https://component-kook.simbot.forte.love/">组件手册</a> 阅读 <strong>快速开始</strong> 相关章节。</p>
125-
<h2 class=""> 法欧莉</h2>
125+
<h2 class="">法欧莉</h2>
126126
<p class="paragraph">如果你想看一看使用 KOOK组件实现的具体作品, 不妨添加我们亲爱的 <a href="https://www.kookapp.cn/app/oauth2/authorize?id=10250&amp;permissions=197958144&amp;client_id=jqdlyHK85xe1i5Bo&amp;redirect_uri=&amp;scope=bot">法欧莉斯卡雷特</a> 并使用 <code class="lang-kotlin">@法欧莉 今天的我</code> 来看看效果吧~</p>
127-
<h2 class=""> License</h2>
127+
<h2 class="">License</h2>
128128
<p class="paragraph"><code class="lang-kotlin">simbot-component-kook</code> 使用 <code class="lang-kotlin">LGPLv3</code> 许可证开源。</p>
129129
<div class="sample-container">
130130
<pre><code class="block lang-kotlin" theme="idea">This program is free software: you can redistribute it and/or modify it under the terms of <br>the GNU Lesser General Public License as published by the Free Software Foundation, either <br>version 3 of the License, or (at your option) any later version.<br><br>This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;<br>without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. <br>See the GNU Lesser General Public License for more details.<br><br>You should have received a copy of the GNU Lesser General Public License along with this <br>program. If not, see &lt;https://www.gnu.org/licenses/&gt;.</code></pre>

snapshots/components/kook/navigation.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3579,12 +3579,12 @@
35793579
</div>
35803580
<div class="sideMenuPart" id="simbot-component-kook-stdlib-nav-submenu-0-15" pageid="simbot-component-kook-stdlib::love.forte.simbot.kook.stdlib//processor/love.forte.simbot.kook.stdlib.Bot#kotlin.coroutines.SuspendFunction2[love.forte.simbot.kook.event.Event[TypeParam(bounds=[love.forte.simbot.kook.event.EventExtra])],kotlin.String,kotlin.Unit]/PointingToDeclaration//-2090471503">
35813581
<div class="overview">
3582-
<a href="simbot-component-kook-stdlib/love.forte.simbot.kook.stdlib/processor.html"><span class="nav-link-grid"><span class="nav-link-child nav-icon function"></span><span class="nav-link-child"> <strike><span><span>processor()</span></span></strike> </span></span></a>
3582+
<a href="simbot-component-kook-stdlib/love.forte.simbot.kook.stdlib/processor.html"><span class="nav-link-grid"><span class="nav-link-child nav-icon function"></span><span class="nav-link-child"> <strike class="strikethrough"><span><span>processor()</span></span></strike> </span></span></a>
35833583
</div>
35843584
</div>
35853585
<div class="sideMenuPart" id="simbot-component-kook-stdlib-nav-submenu-0-16" pageid="simbot-component-kook-stdlib::love.forte.simbot.kook.stdlib/ProcessorType///PointingToDeclaration//-2090471503">
35863586
<div class="overview">
3587-
<span class="navButton" onclick="document.getElementById(&quot;simbot-component-kook-stdlib-nav-submenu-0-16&quot;).classList.toggle(&quot;hidden&quot;);"><span class="navButtonContent"></span></span><a href="simbot-component-kook-stdlib/love.forte.simbot.kook.stdlib/-processor-type/index.html"><span class="nav-link-grid"><span class="nav-link-child nav-icon enum-class-kt"></span><span class="nav-link-child"> <strike><span>Processor</span><wbr><span><span>Type</span></span></strike> </span></span></a>
3587+
<span class="navButton" onclick="document.getElementById(&quot;simbot-component-kook-stdlib-nav-submenu-0-16&quot;).classList.toggle(&quot;hidden&quot;);"><span class="navButtonContent"></span></span><a href="simbot-component-kook-stdlib/love.forte.simbot.kook.stdlib/-processor-type/index.html"><span class="nav-link-grid"><span class="nav-link-child nav-icon enum-class-kt"></span><span class="nav-link-child"> <strike class="strikethrough"><span>Processor</span><wbr><span><span>Type</span></span></strike> </span></span></a>
35883588
</div>
35893589
<div class="sideMenuPart" id="simbot-component-kook-stdlib-nav-submenu-0-16-0" pageid="simbot-component-kook-stdlib::love.forte.simbot.kook.stdlib/ProcessorType.PREPARE///PointingToDeclaration/{&quot;org.jetbrains.dokka.links.EnumEntryDRIExtra&quot;:{&quot;key&quot;:&quot;org.jetbrains.dokka.links.EnumEntryDRIExtra&quot;}}/-2090471503">
35903590
<div class="overview">

snapshots/components/kook/scripts/pages.json

Lines changed: 1 addition & 1 deletion
Large diffs are not rendered by default.

snapshots/components/kook/scripts/platform-content-handler.js

Lines changed: 24 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,6 @@ const samplesLightThemeName = 'idea'
1818
window.addEventListener('load', () => {
1919
document.querySelectorAll("div[data-platform-hinted]")
2020
.forEach(elem => elem.addEventListener('click', (event) => togglePlatformDependent(event, elem)))
21-
document.querySelectorAll("div[tabs-section]")
22-
.forEach(elem => elem.addEventListener('click', (event) => toggleSectionsEventHandler(event)))
2321
const filterSection = document.getElementById('filter-section')
2422
if (filterSection) {
2523
filterSection.addEventListener('click', (event) => filterButtonHandler(event))
@@ -177,19 +175,30 @@ function handleAnchor() {
177175
}
178176

179177
function initTabs() {
180-
document.querySelectorAll("div[tabs-section]")
181-
.forEach(element => {
182-
showCorrespondingTabBody(element)
183-
element.addEventListener('click', (event) => toggleSectionsEventHandler(event))
184-
})
185-
let cached = localStorage.getItem("active-tab")
186-
if (cached) {
187-
let parsed = JSON.parse(cached)
188-
let tab = document.querySelector('div[tabs-section] > button[data-togglable="' + parsed + '"]')
189-
if (tab) {
190-
toggleSections(tab)
191-
}
192-
}
178+
// we could have only a single type of data - classlike or package
179+
const mainContent = document.querySelector('.main-content');
180+
const type = mainContent ? mainContent.getAttribute("data-page-type") : null;
181+
const localStorageKey = "active-tab-" + type;
182+
document.querySelectorAll('div[tabs-section]').forEach(element => {
183+
showCorrespondingTabBody(element);
184+
element.addEventListener('click', ({target}) => {
185+
const togglable = target ? target.getAttribute("data-togglable") : null;
186+
if (!togglable) return;
187+
188+
localStorage.setItem(localStorageKey, JSON.stringify(togglable));
189+
toggleSections(target);
190+
});
191+
});
192+
193+
const cached = localStorage.getItem(localStorageKey);
194+
if (!cached) return;
195+
196+
const tab = document.querySelector(
197+
'div[tabs-section] > button[data-togglable="' + JSON.parse(cached) + '"]'
198+
);
199+
if (!tab) return;
200+
201+
toggleSections(tab);
193202
}
194203

195204
function showCorrespondingTabBody(element) {
@@ -293,12 +302,6 @@ function toggleSections(target) {
293302
activateTabsBody("tabs-section-body")
294303
}
295304

296-
function toggleSectionsEventHandler(evt) {
297-
if (!evt.target.getAttribute("data-togglable")) return
298-
localStorage.setItem('active-tab', JSON.stringify(evt.target.getAttribute("data-togglable")))
299-
toggleSections(evt.target)
300-
}
301-
302305
function togglePlatformDependent(e, container) {
303306
let target = e.target
304307
if (target.tagName != 'BUTTON') return;

snapshots/components/kook/simbot-component-kook-api/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@
4141
<a class="library-name--link" href="../index.html">
4242
Simple Robot 组件 | KOOK
4343
</a> </div>
44-
<div class="library-version">4.0.0-beta2-SNAPSHOT
44+
<div class="library-version">4.0.0-beta3-SNAPSHOT
4545
</div>
4646
</div>
4747
<div class="filter-section" id="filter-section">

snapshots/components/kook/simbot-component-kook-api/love.forte.simbot.kook.api.asset/-asset/-asset.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@
4141
<a class="library-name--link" href="../../../index.html">
4242
Simple Robot 组件 | KOOK
4343
</a> </div>
44-
<div class="library-version">4.0.0-beta2-SNAPSHOT
44+
<div class="library-version">4.0.0-beta3-SNAPSHOT
4545
</div>
4646
</div>
4747
<div class="filter-section" id="filter-section">

snapshots/components/kook/simbot-component-kook-api/love.forte.simbot.kook.api.asset/-asset/index.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@
4141
<a class="library-name--link" href="../../../index.html">
4242
Simple Robot 组件 | KOOK
4343
</a> </div>
44-
<div class="library-version">4.0.0-beta2-SNAPSHOT
44+
<div class="library-version">4.0.0-beta3-SNAPSHOT
4545
</div>
4646
</div>
4747
<div class="filter-section" id="filter-section">
@@ -98,7 +98,7 @@ <h2 class="">Properties</h2>
9898
</span></span></div>
9999
<div>
100100
<div class="title">
101-
<div class="platform-hinted " data-platform-hinted="data-platform-hinted"><div class="content sourceset-dependent-content" data-active="" data-togglable=":simbot-component-kook-api:dokkaHtmlPartial/commonMain"><div class="symbol monospace"><span class="token keyword"></span><span class="token keyword">val </span><a href="url.html">url</a><span class="token operator">: </span><a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html">String</a></div><div class="brief "><p class="paragraph">资源的 url</p></div></div></div>
101+
<div class="platform-hinted " data-platform-hinted="data-platform-hinted"><div class="content sourceset-dependent-content" data-active="" data-togglable=":simbot-component-kook-api:dokkaHtmlPartial/commonMain"><div class="symbol monospace"><span class="token keyword">val </span><a href="url.html">url</a><span class="token operator">: </span><a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html">String</a></div><div class="brief "><p class="paragraph">资源的 url</p></div></div></div>
102102
</div>
103103
</div>
104104
</div>

snapshots/components/kook/simbot-component-kook-api/love.forte.simbot.kook.api.asset/-asset/url.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@
4141
<a class="library-name--link" href="../../../index.html">
4242
Simple Robot 组件 | KOOK
4343
</a> </div>
44-
<div class="library-version">4.0.0-beta2-SNAPSHOT
44+
<div class="library-version">4.0.0-beta3-SNAPSHOT
4545
</div>
4646
</div>
4747
<div class="filter-section" id="filter-section">
@@ -63,7 +63,7 @@
6363
<div class="cover ">
6464
<h1 class="cover"><span><span>url</span></span></h1>
6565
</div>
66-
<div class="platform-hinted " data-platform-hinted="data-platform-hinted"><div class="content sourceset-dependent-content" data-active="" data-togglable=":simbot-component-kook-api:dokkaHtmlPartial/commonMain"><div class="symbol monospace"><span class="token keyword"></span><span class="token keyword">val </span><a href="url.html">url</a><span class="token operator">: </span><a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html">String</a><span class="clearfix"><span class="floating-right">(<a href="https://github.com/simple-robot/simbot-component-kook/tree/main/simbot-component-kook-api/src//commonMain/kotlin/love/forte/simbot/kook/api/asset/CreateAssetApi.kt#L155">source</a>)</span></span></div></div></div>
66+
<div class="platform-hinted " data-platform-hinted="data-platform-hinted"><div class="content sourceset-dependent-content" data-active="" data-togglable=":simbot-component-kook-api:dokkaHtmlPartial/commonMain"><div class="symbol monospace"><span class="token keyword">val </span><a href="url.html">url</a><span class="token operator">: </span><a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html">String</a><span class="clearfix"><span class="floating-right">(<a href="https://github.com/simple-robot/simbot-component-kook/tree/main/simbot-component-kook-api/src//commonMain/kotlin/love/forte/simbot/kook/api/asset/CreateAssetApi.kt#L155">source</a>)</span></span></div></div></div>
6767
</div>
6868
<div class="footer">
6969
<span class="go-to-top-icon"><a href="#content" id="go-to-top-link"></a></span><span>© 2024 Copyright</span><span class="pull-right"><span>Generated by </span><a href="https://github.com/Kotlin/dokka"><span>dokka</span><span class="padded-icon"></span></a></span>

0 commit comments

Comments
 (0)