Skip to content

Commit c40da45

Browse files
committed
Adding "experimental"
1 parent 14c8c37 commit c40da45

2 files changed

Lines changed: 20 additions & 0 deletions

File tree

src/backends/Authentication.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ import REST from '../REST';
1818
* @class Authentication
1919
* @category Backends
2020
* @hideconstructor
21+
* @experimental
2122
* @ignore
2223
*/
2324
class Authentication {

tools/documentation.js

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ const INDENT = '⠀';
1313
const ICON_MODEL = getIcon('Models.png');
1414
const ICON_BACKEND = getIcon('Backend.png');
1515
const ICON_ENUM = getIcon('Enumeration.png');
16+
const ICON_EXPERIMENTAL = getIcon('Experimental.png');
1617

1718
// Initialize project
1819
const project = new Project({
@@ -222,6 +223,7 @@ function generateClassDoc(cls, category = '') {
222223
const author = getJsDocTag(cls, 'author');
223224
const since = getJsDocTag(cls, 'since');
224225
const requires = getJsDocTag(cls, 'requires');
226+
const experimental = getJsDocTag(cls, 'experimental');
225227

226228
let clazz = false;
227229
let markdown = ''; //`# ${className}\n\n`;
@@ -231,6 +233,15 @@ function generateClassDoc(cls, category = '') {
231233
clazz = true;
232234
}
233235

236+
if(experimental) {
237+
markdown += '> [!CAUTION]\n';
238+
markdown += `> ${ICON_EXPERIMENTAL} This is **Experimental**!\n`;
239+
240+
if(item.includes('LABS')) {
241+
specials.push('LABS');
242+
}
243+
}
244+
234245
if(requires) {
235246
let list = requires.split(',');
236247

@@ -549,6 +560,10 @@ function generateSidebar(backends, models, enums) {
549560
if(backend.special.indexOf('VIP') !== -1) {
550561
sidebar += INDENT + INDENT + getIcon('VIP.png', 'Account requires VIP!');
551562
}
563+
564+
if(backend.special.indexOf('LABS') !== -1) {
565+
sidebar += INDENT + INDENT + getIcon('Experimental.png', 'This is an experimental feature!');
566+
}
552567
}
553568

554569
sidebar += '</p>';
@@ -631,6 +646,10 @@ function generateMain(backends, models, enums) {
631646
if(backend.special.indexOf('VIP') !== -1) {
632647
core += INDENT + INDENT + getIcon('VIP.png', 'Account requires VIP!');
633648
}
649+
650+
if(backend.special.indexOf('LABS') !== -1) {
651+
core += INDENT + INDENT + getIcon('Experimental.png', 'This is an experimental feature!');
652+
}
634653
}
635654

636655
core += '</p>';

0 commit comments

Comments
 (0)