@things-factory/board-ui 6.2.96 → 6.2.102
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/client/pages/board-modeller-page.ts +1 -1
- package/client/pages/board-player-page.ts +1 -1
- package/client/pages/board-viewer-page.ts +2 -4
- package/client/setting-let/board-view-setting-let.ts +2 -6
- package/package.json +4 -4
- package/translations/en.json +1 -0
- package/translations/ja.json +1 -0
- package/translations/ko.json +1 -0
- package/translations/ms.json +1 -1
- package/translations/zh.json +5 -4
- package/dist-client/apptools/favorite-tool.d.ts +0 -26
- package/dist-client/apptools/favorite-tool.js +0 -129
- package/dist-client/apptools/favorite-tool.js.map +0 -1
- package/dist-client/board-list/board-importer.d.ts +0 -6
- package/dist-client/board-list/board-importer.js +0 -112
- package/dist-client/board-list/board-importer.js.map +0 -1
- package/dist-client/board-list/board-tile-list.d.ts +0 -22
- package/dist-client/board-list/board-tile-list.js +0 -264
- package/dist-client/board-list/board-tile-list.js.map +0 -1
- package/dist-client/board-list/group-bar.d.ts +0 -14
- package/dist-client/board-list/group-bar.js +0 -145
- package/dist-client/board-list/group-bar.js.map +0 -1
- package/dist-client/board-list/play-group-bar.d.ts +0 -21
- package/dist-client/board-list/play-group-bar.js +0 -142
- package/dist-client/board-list/play-group-bar.js.map +0 -1
- package/dist-client/board-provider.d.ts +0 -3
- package/dist-client/board-provider.js +0 -77
- package/dist-client/board-provider.js.map +0 -1
- package/dist-client/bootstrap.d.ts +0 -2
- package/dist-client/bootstrap.js +0 -30
- package/dist-client/bootstrap.js.map +0 -1
- package/dist-client/data-grist/board-editor.d.ts +0 -14
- package/dist-client/data-grist/board-editor.js +0 -110
- package/dist-client/data-grist/board-editor.js.map +0 -1
- package/dist-client/data-grist/board-renderer.d.ts +0 -2
- package/dist-client/data-grist/board-renderer.js +0 -134
- package/dist-client/data-grist/board-renderer.js.map +0 -1
- package/dist-client/data-grist/color-map-editor.d.ts +0 -4
- package/dist-client/data-grist/color-map-editor.js +0 -15
- package/dist-client/data-grist/color-map-editor.js.map +0 -1
- package/dist-client/data-grist/color-ranges-editor.d.ts +0 -4
- package/dist-client/data-grist/color-ranges-editor.js +0 -15
- package/dist-client/data-grist/color-ranges-editor.js.map +0 -1
- package/dist-client/graphql/board-template.d.ts +0 -5
- package/dist-client/graphql/board-template.js +0 -128
- package/dist-client/graphql/board-template.js.map +0 -1
- package/dist-client/graphql/board.d.ts +0 -19
- package/dist-client/graphql/board.js +0 -231
- package/dist-client/graphql/board.js.map +0 -1
- package/dist-client/graphql/favorite-board.d.ts +0 -1
- package/dist-client/graphql/favorite-board.js +0 -24
- package/dist-client/graphql/favorite-board.js.map +0 -1
- package/dist-client/graphql/group.d.ts +0 -6
- package/dist-client/graphql/group.js +0 -125
- package/dist-client/graphql/group.js.map +0 -1
- package/dist-client/graphql/index.d.ts +0 -6
- package/dist-client/graphql/index.js +0 -7
- package/dist-client/graphql/index.js.map +0 -1
- package/dist-client/graphql/my-board.d.ts +0 -1
- package/dist-client/graphql/my-board.js +0 -24
- package/dist-client/graphql/my-board.js.map +0 -1
- package/dist-client/graphql/play-group.d.ts +0 -7
- package/dist-client/graphql/play-group.js +0 -173
- package/dist-client/graphql/play-group.js.map +0 -1
- package/dist-client/index.d.ts +0 -8
- package/dist-client/index.js +0 -9
- package/dist-client/index.js.map +0 -1
- package/dist-client/pages/attachment-list-page.d.ts +0 -30
- package/dist-client/pages/attachment-list-page.js +0 -128
- package/dist-client/pages/attachment-list-page.js.map +0 -1
- package/dist-client/pages/board-list-page.d.ts +0 -109
- package/dist-client/pages/board-list-page.js +0 -532
- package/dist-client/pages/board-list-page.js.map +0 -1
- package/dist-client/pages/board-modeller-page.d.ts +0 -49
- package/dist-client/pages/board-modeller-page.js +0 -309
- package/dist-client/pages/board-modeller-page.js.map +0 -1
- package/dist-client/pages/board-player-by-name-page.d.ts +0 -4
- package/dist-client/pages/board-player-by-name-page.js +0 -32
- package/dist-client/pages/board-player-by-name-page.js.map +0 -1
- package/dist-client/pages/board-player-page.d.ts +0 -42
- package/dist-client/pages/board-player-page.js +0 -230
- package/dist-client/pages/board-player-page.js.map +0 -1
- package/dist-client/pages/board-template/board-template-list-page.d.ts +0 -37
- package/dist-client/pages/board-template/board-template-list-page.js +0 -226
- package/dist-client/pages/board-template/board-template-list-page.js.map +0 -1
- package/dist-client/pages/board-viewer-by-name-page.d.ts +0 -4
- package/dist-client/pages/board-viewer-by-name-page.js +0 -27
- package/dist-client/pages/board-viewer-by-name-page.js.map +0 -1
- package/dist-client/pages/board-viewer-page.d.ts +0 -41
- package/dist-client/pages/board-viewer-page.js +0 -247
- package/dist-client/pages/board-viewer-page.js.map +0 -1
- package/dist-client/pages/font-list-page.d.ts +0 -9
- package/dist-client/pages/font-list-page.js +0 -31
- package/dist-client/pages/font-list-page.js.map +0 -1
- package/dist-client/pages/play-list-page.d.ts +0 -58
- package/dist-client/pages/play-list-page.js +0 -364
- package/dist-client/pages/play-list-page.js.map +0 -1
- package/dist-client/pages/printable-board-viewer-page.d.ts +0 -11
- package/dist-client/pages/printable-board-viewer-page.js +0 -43
- package/dist-client/pages/printable-board-viewer-page.js.map +0 -1
- package/dist-client/pages/theme/theme-editors.d.ts +0 -5
- package/dist-client/pages/theme/theme-editors.js +0 -53
- package/dist-client/pages/theme/theme-editors.js.map +0 -1
- package/dist-client/pages/theme/theme-list-page.d.ts +0 -49
- package/dist-client/pages/theme/theme-list-page.js +0 -318
- package/dist-client/pages/theme/theme-list-page.js.map +0 -1
- package/dist-client/pages/things-scene-components-with-tools.import +0 -0
- package/dist-client/pages/things-scene-components.import +0 -0
- package/dist-client/route.d.ts +0 -1
- package/dist-client/route.js +0 -41
- package/dist-client/route.js.map +0 -1
- package/dist-client/setting-let/board-view-setting-let.d.ts +0 -14
- package/dist-client/setting-let/board-view-setting-let.js +0 -70
- package/dist-client/setting-let/board-view-setting-let.js.map +0 -1
- package/dist-client/themes/board-theme.css +0 -76
- package/dist-client/tsconfig.tsbuildinfo +0 -1
- package/dist-client/viewparts/board-basic-info.d.ts +0 -47
- package/dist-client/viewparts/board-basic-info.js +0 -641
- package/dist-client/viewparts/board-basic-info.js.map +0 -1
- package/dist-client/viewparts/board-info-link.d.ts +0 -12
- package/dist-client/viewparts/board-info-link.js +0 -59
- package/dist-client/viewparts/board-info-link.js.map +0 -1
- package/dist-client/viewparts/board-info.d.ts +0 -14
- package/dist-client/viewparts/board-info.js +0 -94
- package/dist-client/viewparts/board-info.js.map +0 -1
- package/dist-client/viewparts/board-template-builder.d.ts +0 -16
- package/dist-client/viewparts/board-template-builder.js +0 -145
- package/dist-client/viewparts/board-template-builder.js.map +0 -1
- package/dist-client/viewparts/board-versions.d.ts +0 -12
- package/dist-client/viewparts/board-versions.js +0 -157
- package/dist-client/viewparts/board-versions.js.map +0 -1
- package/dist-client/viewparts/group-info-basic.d.ts +0 -16
- package/dist-client/viewparts/group-info-basic.js +0 -247
- package/dist-client/viewparts/group-info-basic.js.map +0 -1
- package/dist-client/viewparts/group-info-import.d.ts +0 -15
- package/dist-client/viewparts/group-info-import.js +0 -137
- package/dist-client/viewparts/group-info-import.js.map +0 -1
- package/dist-client/viewparts/group-info.d.ts +0 -10
- package/dist-client/viewparts/group-info.js +0 -92
- package/dist-client/viewparts/group-info.js.map +0 -1
- package/dist-client/viewparts/index.d.ts +0 -3
- package/dist-client/viewparts/index.js +0 -4
- package/dist-client/viewparts/index.js.map +0 -1
- package/dist-client/viewparts/link-builder.d.ts +0 -22
- package/dist-client/viewparts/link-builder.js +0 -217
- package/dist-client/viewparts/link-builder.js.map +0 -1
- package/dist-client/viewparts/play-group-info-basic.d.ts +0 -16
- package/dist-client/viewparts/play-group-info-basic.js +0 -249
- package/dist-client/viewparts/play-group-info-basic.js.map +0 -1
- package/dist-client/viewparts/play-group-info-link.d.ts +0 -10
- package/dist-client/viewparts/play-group-info-link.js +0 -48
- package/dist-client/viewparts/play-group-info-link.js.map +0 -1
- package/dist-client/viewparts/play-group-info.d.ts +0 -13
- package/dist-client/viewparts/play-group-info.js +0 -90
- package/dist-client/viewparts/play-group-info.js.map +0 -1
- package/dist-server/index.js +0 -5
- package/dist-server/index.js.map +0 -1
- package/dist-server/migrations/index.js +0 -12
- package/dist-server/migrations/index.js.map +0 -1
- package/dist-server/tsconfig.tsbuildinfo +0 -1
package/dist-client/index.js
DELETED
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
export * from './board-provider';
|
|
2
|
-
export * from './pages/board-viewer-page';
|
|
3
|
-
export * from './pages/board-player-page';
|
|
4
|
-
export * from './pages/board-modeller-page';
|
|
5
|
-
export * from './setting-let/board-view-setting-let';
|
|
6
|
-
export * from './apptools/favorite-tool';
|
|
7
|
-
export * from './graphql';
|
|
8
|
-
export * from './viewparts';
|
|
9
|
-
//# sourceMappingURL=index.js.map
|
package/dist-client/index.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../client/index.ts"],"names":[],"mappings":"AAAA,cAAc,kBAAkB,CAAA;AAEhC,cAAc,2BAA2B,CAAA;AACzC,cAAc,2BAA2B,CAAA;AACzC,cAAc,6BAA6B,CAAA;AAE3C,cAAc,sCAAsC,CAAA;AACpD,cAAc,0BAA0B,CAAA;AACxC,cAAc,WAAW,CAAA;AACzB,cAAc,aAAa,CAAA","sourcesContent":["export * from './board-provider'\n\nexport * from './pages/board-viewer-page'\nexport * from './pages/board-player-page'\nexport * from './pages/board-modeller-page'\n\nexport * from './setting-let/board-view-setting-let'\nexport * from './apptools/favorite-tool'\nexport * from './graphql'\nexport * from './viewparts'\n"]}
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
import '@operato/attachment/ox-attachment-list.js';
|
|
2
|
-
import { PageView } from '@operato/shell';
|
|
3
|
-
import { OxAttachmentList } from '@operato/attachment/ox-attachment-list.js';
|
|
4
|
-
declare const AttachmentListPage_base: (new (...args: any[]) => import("lit").LitElement) & typeof PageView;
|
|
5
|
-
export declare class AttachmentListPage extends AttachmentListPage_base {
|
|
6
|
-
static styles: import("lit").CSSResult[];
|
|
7
|
-
attachmentList: OxAttachmentList;
|
|
8
|
-
get context(): {
|
|
9
|
-
title: string;
|
|
10
|
-
search: {
|
|
11
|
-
handler: (search: any) => void;
|
|
12
|
-
value: string;
|
|
13
|
-
};
|
|
14
|
-
board_topmenu: boolean;
|
|
15
|
-
exportable: {
|
|
16
|
-
name: string;
|
|
17
|
-
data: () => Promise<any>;
|
|
18
|
-
};
|
|
19
|
-
importable: {
|
|
20
|
-
handler: (data: any, file: any) => Promise<void>;
|
|
21
|
-
};
|
|
22
|
-
};
|
|
23
|
-
render(): import("lit-html").TemplateResult<1>;
|
|
24
|
-
get grist(): import("@operato/data-grist").DataGrist;
|
|
25
|
-
languageUpdated(i18next: any): void;
|
|
26
|
-
pageInitialized(): Promise<void>;
|
|
27
|
-
exportHandler(): Promise<any>;
|
|
28
|
-
importHandler(data: any, file: any): Promise<void>;
|
|
29
|
-
}
|
|
30
|
-
export {};
|
|
@@ -1,128 +0,0 @@
|
|
|
1
|
-
import { __decorate, __metadata } from "tslib";
|
|
2
|
-
import '@operato/attachment/ox-attachment-list.js';
|
|
3
|
-
import { css, html } from 'lit';
|
|
4
|
-
import { customElement, query } from 'lit/decorators.js';
|
|
5
|
-
import gql from 'graphql-tag';
|
|
6
|
-
import { i18next, localize } from '@operato/i18n';
|
|
7
|
-
import { PageView } from '@operato/shell';
|
|
8
|
-
import { OxAttachmentList } from '@operato/attachment/ox-attachment-list.js';
|
|
9
|
-
import { client } from '@operato/graphql';
|
|
10
|
-
async function fetchDataFromURL(fileURL) {
|
|
11
|
-
try {
|
|
12
|
-
const response = await fetch(fileURL);
|
|
13
|
-
if (!response.ok) {
|
|
14
|
-
throw new Error('Network response was not ok');
|
|
15
|
-
}
|
|
16
|
-
const blob = await response.blob(); // 파일 데이터를 Blob으로 변환
|
|
17
|
-
if (blob.size === 0) {
|
|
18
|
-
throw new Error('Content is empty'); // Content가 비어 있으면 예외
|
|
19
|
-
}
|
|
20
|
-
return new Promise((resolve, reject) => {
|
|
21
|
-
const reader = new FileReader();
|
|
22
|
-
reader.onload = (event) => {
|
|
23
|
-
const dataURL = event.target.result;
|
|
24
|
-
resolve(dataURL);
|
|
25
|
-
};
|
|
26
|
-
reader.onerror = (event) => {
|
|
27
|
-
reject(event.error);
|
|
28
|
-
};
|
|
29
|
-
reader.readAsDataURL(blob); // Blob을 Data URL로 읽기
|
|
30
|
-
});
|
|
31
|
-
}
|
|
32
|
-
catch (error) {
|
|
33
|
-
throw error;
|
|
34
|
-
}
|
|
35
|
-
}
|
|
36
|
-
let AttachmentListPage = class AttachmentListPage extends localize(i18next)(PageView) {
|
|
37
|
-
get context() {
|
|
38
|
-
var _a;
|
|
39
|
-
return {
|
|
40
|
-
title: i18next.t('title.attachment list'),
|
|
41
|
-
search: {
|
|
42
|
-
handler: search => {
|
|
43
|
-
this.grist.searchText = search;
|
|
44
|
-
},
|
|
45
|
-
value: ((_a = this.grist) === null || _a === void 0 ? void 0 : _a.searchText) || ''
|
|
46
|
-
},
|
|
47
|
-
board_topmenu: true,
|
|
48
|
-
exportable: {
|
|
49
|
-
name: i18next.t('title.attachment list'),
|
|
50
|
-
data: this.exportHandler.bind(this)
|
|
51
|
-
},
|
|
52
|
-
importable: {
|
|
53
|
-
handler: this.importHandler.bind(this)
|
|
54
|
-
}
|
|
55
|
-
};
|
|
56
|
-
}
|
|
57
|
-
render() {
|
|
58
|
-
return html ` <ox-attachment-list .creatable=${true} without-search></ox-attachment-list> `;
|
|
59
|
-
}
|
|
60
|
-
get grist() {
|
|
61
|
-
return this.attachmentList.grist;
|
|
62
|
-
}
|
|
63
|
-
languageUpdated(i18next) {
|
|
64
|
-
this.attachmentList.requestUpdate();
|
|
65
|
-
}
|
|
66
|
-
async pageInitialized() {
|
|
67
|
-
await this.updateComplete;
|
|
68
|
-
this.attachmentList.refreshAttachments();
|
|
69
|
-
}
|
|
70
|
-
async exportHandler() {
|
|
71
|
-
const records = this.grist.data.records;
|
|
72
|
-
const data = {};
|
|
73
|
-
for (const record of records) {
|
|
74
|
-
const { id, name, mimetype, encoding, category, fullpath } = record;
|
|
75
|
-
try {
|
|
76
|
-
const dataURL = await fetchDataFromURL(fullpath);
|
|
77
|
-
id &&
|
|
78
|
-
(data[id] = {
|
|
79
|
-
id,
|
|
80
|
-
name,
|
|
81
|
-
mimetype,
|
|
82
|
-
encoding,
|
|
83
|
-
category,
|
|
84
|
-
contents: dataURL
|
|
85
|
-
});
|
|
86
|
-
}
|
|
87
|
-
catch (err) {
|
|
88
|
-
console.log(name, err);
|
|
89
|
-
}
|
|
90
|
-
}
|
|
91
|
-
return data;
|
|
92
|
-
}
|
|
93
|
-
async importHandler(data, file) {
|
|
94
|
-
await client.mutate({
|
|
95
|
-
mutation: gql `
|
|
96
|
-
mutation importAttachments($file: Upload!) {
|
|
97
|
-
importAttachments(file: $file) {
|
|
98
|
-
id
|
|
99
|
-
name
|
|
100
|
-
description
|
|
101
|
-
path
|
|
102
|
-
}
|
|
103
|
-
}
|
|
104
|
-
`,
|
|
105
|
-
variables: {
|
|
106
|
-
file
|
|
107
|
-
},
|
|
108
|
-
context: { hasUpload: true }
|
|
109
|
-
});
|
|
110
|
-
this.grist.fetch();
|
|
111
|
-
}
|
|
112
|
-
};
|
|
113
|
-
AttachmentListPage.styles = [
|
|
114
|
-
css `
|
|
115
|
-
:host {
|
|
116
|
-
display: flex;
|
|
117
|
-
}
|
|
118
|
-
`
|
|
119
|
-
];
|
|
120
|
-
__decorate([
|
|
121
|
-
query('ox-attachment-list'),
|
|
122
|
-
__metadata("design:type", OxAttachmentList)
|
|
123
|
-
], AttachmentListPage.prototype, "attachmentList", void 0);
|
|
124
|
-
AttachmentListPage = __decorate([
|
|
125
|
-
customElement('attachment-list-page')
|
|
126
|
-
], AttachmentListPage);
|
|
127
|
-
export { AttachmentListPage };
|
|
128
|
-
//# sourceMappingURL=attachment-list-page.js.map
|
|
@@ -1 +0,0 @@
|
|
|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html } from 'lit'\nimport { customElement, query } from 'lit/decorators.js'\nimport gql from 'graphql-tag'\n\nimport { i18next, localize } from '@operato/i18n'\nimport { PageView } from '@operato/shell'\nimport { OxAttachmentList } from '@operato/attachment/ox-attachment-list.js'\nimport { client } from '@operato/graphql'\n\nasync function fetchDataFromURL(fileURL: string) {\n try {\n const response = await fetch(fileURL)\n\n if (!response.ok) {\n throw new Error('Network response was not ok')\n }\n\n const blob = await response.blob() // 파일 데이터를 Blob으로 변환\n\n if (blob.size === 0) {\n throw new Error('Content is empty') // Content가 비어 있으면 예외\n }\n\n return new Promise((resolve, reject) => {\n const reader = new FileReader()\n\n reader.onload = (event: any) => {\n const dataURL = event.target.result\n resolve(dataURL)\n }\n\n reader.onerror = (event: any) => {\n reject(event.error)\n }\n\n reader.readAsDataURL(blob) // Blob을 Data URL로 읽기\n })\n } catch (error) {\n throw error\n }\n}\n\n@customElement('attachment-list-page')\nexport class AttachmentListPage extends localize(i18next)(PageView) {\n static styles = [\n css`\n :host {\n display: flex;\n }\n `\n ]\n\n @query('ox-attachment-list') attachmentList!: OxAttachmentList\n\n get context() {\n return {\n title: i18next.t('title.attachment list'),\n search: {\n handler: search => {\n this.grist.searchText = search\n },\n value: this.grist?.searchText || ''\n },\n board_topmenu: true,\n exportable: {\n name: i18next.t('title.attachment list'),\n data: this.exportHandler.bind(this)\n },\n importable: {\n handler: this.importHandler.bind(this)\n }\n }\n }\n\n render() {\n return html` <ox-attachment-list .creatable=${true} without-search></ox-attachment-list> `\n }\n\n get grist() {\n return this.attachmentList.grist\n }\n\n languageUpdated(i18next) {\n this.attachmentList.requestUpdate()\n }\n\n async pageInitialized() {\n await this.updateComplete\n\n this.attachmentList.refreshAttachments()\n }\n\n async exportHandler() {\n const records = this.grist.data.records\n const data = {} as any\n\n for (const record of records) {\n const { id, name, mimetype, encoding, category, fullpath } = record\n\n try {\n const dataURL = await fetchDataFromURL(fullpath)\n\n id &&\n (data[id!] = {\n id,\n name,\n mimetype,\n encoding,\n category,\n contents: dataURL\n })\n } catch (err) {\n console.log(name, err)\n }\n }\n\n return data\n }\n\n async importHandler(data, file) {\n await client.mutate({\n mutation: gql`\n mutation importAttachments($file: Upload!) {\n importAttachments(file: $file) {\n id\n name\n description\n path\n }\n }\n `,\n variables: {\n file\n },\n context: { hasUpload: true }\n })\n\n this.grist.fetch()\n }\n}\n"]}
|
|
@@ -1,109 +0,0 @@
|
|
|
1
|
-
import '@material/mwc-icon';
|
|
2
|
-
import '../viewparts/board-info';
|
|
3
|
-
import '../viewparts/group-info';
|
|
4
|
-
import '../board-list/board-tile-list';
|
|
5
|
-
import '../board-list/group-bar';
|
|
6
|
-
import { PageView } from '@operato/shell';
|
|
7
|
-
declare const BoardListPage_base: (new (...args: any[]) => import("lit").LitElement) & (new (...args: any[]) => {
|
|
8
|
-
_storeUnsubscribe: import("redux").Unsubscribe;
|
|
9
|
-
connectedCallback(): void;
|
|
10
|
-
disconnectedCallback(): void;
|
|
11
|
-
stateChanged(_state: unknown): void;
|
|
12
|
-
readonly isConnected: boolean;
|
|
13
|
-
}) & (new (...args: any[]) => {
|
|
14
|
-
_infiniteScrollOptions: {
|
|
15
|
-
threshold: number;
|
|
16
|
-
limit: number;
|
|
17
|
-
totalProp: string;
|
|
18
|
-
pageProp: string;
|
|
19
|
-
};
|
|
20
|
-
onScroll: import("lodash").DebouncedFunc<(e: any) => void>;
|
|
21
|
-
scrollAction(): Promise<void>;
|
|
22
|
-
}) & typeof PageView;
|
|
23
|
-
export declare class BoardListPage extends BoardListPage_base {
|
|
24
|
-
static styles: import("lit").CSSResult[];
|
|
25
|
-
groupId?: string;
|
|
26
|
-
groups: any[];
|
|
27
|
-
boards: any[];
|
|
28
|
-
favorites: any[];
|
|
29
|
-
searchText: string;
|
|
30
|
-
scrollTargetEl: HTMLElement;
|
|
31
|
-
private _page;
|
|
32
|
-
private _total;
|
|
33
|
-
private page?;
|
|
34
|
-
get context(): {
|
|
35
|
-
title: {
|
|
36
|
-
icon: string;
|
|
37
|
-
text: string;
|
|
38
|
-
};
|
|
39
|
-
search: {
|
|
40
|
-
handler: (search: any) => void;
|
|
41
|
-
value: string;
|
|
42
|
-
};
|
|
43
|
-
board_topmenu: boolean;
|
|
44
|
-
};
|
|
45
|
-
constructor();
|
|
46
|
-
render(): import("lit-html").TemplateResult<1>;
|
|
47
|
-
refresh(): Promise<void>;
|
|
48
|
-
getBoards({ page, limit }?: {
|
|
49
|
-
page?: number | undefined;
|
|
50
|
-
limit?: number | undefined;
|
|
51
|
-
}): Promise<any>;
|
|
52
|
-
getFavoriteBoards({ page, limit }?: {
|
|
53
|
-
page?: number | undefined;
|
|
54
|
-
limit?: number | undefined;
|
|
55
|
-
}): Promise<any>;
|
|
56
|
-
getMyBoards({ page, limit }?: {
|
|
57
|
-
page?: number | undefined;
|
|
58
|
-
limit?: number | undefined;
|
|
59
|
-
}): Promise<any>;
|
|
60
|
-
refreshBoards(): Promise<void>;
|
|
61
|
-
appendBoards(): Promise<void>;
|
|
62
|
-
scrollAction(): Promise<void>;
|
|
63
|
-
pageInitialized(): Promise<void>;
|
|
64
|
-
pageUpdated(changes: any, lifecycle: any): Promise<void>;
|
|
65
|
-
stateChanged(state: any): void;
|
|
66
|
-
firstUpdated(): void;
|
|
67
|
-
onInfoBoard(board: any): Promise<void>;
|
|
68
|
-
onInfoGroup(groupId: any): Promise<void>;
|
|
69
|
-
onCreateGroup(group: any): Promise<void>;
|
|
70
|
-
onUpdateGroup(group: any): Promise<void>;
|
|
71
|
-
onDeleteGroup(group: any): Promise<void>;
|
|
72
|
-
onImportBoards({ group, files, overwrite }: {
|
|
73
|
-
group: any;
|
|
74
|
-
files: any;
|
|
75
|
-
overwrite: any;
|
|
76
|
-
}): Promise<void>;
|
|
77
|
-
onCreateBoard(board: any): Promise<void>;
|
|
78
|
-
onCloneBoard({ id, name, description, targetSubdomain, targetGroupId }: {
|
|
79
|
-
id: any;
|
|
80
|
-
name: any;
|
|
81
|
-
description: any;
|
|
82
|
-
targetSubdomain: any;
|
|
83
|
-
targetGroupId: any;
|
|
84
|
-
}): Promise<void>;
|
|
85
|
-
onReleaseBoard(board: any): Promise<void>;
|
|
86
|
-
onRevertBoardVersion({ id, version }: {
|
|
87
|
-
id: any;
|
|
88
|
-
version: any;
|
|
89
|
-
}): Promise<void>;
|
|
90
|
-
onUpdateBoard(board: any): Promise<void>;
|
|
91
|
-
onDeleteBoard(board: any): Promise<void>;
|
|
92
|
-
onJoinPlayGroup({ board, playGroup }: {
|
|
93
|
-
board: any;
|
|
94
|
-
playGroup: any;
|
|
95
|
-
}): Promise<void>;
|
|
96
|
-
onLeavePlayGroup({ board, playGroup }: {
|
|
97
|
-
board: any;
|
|
98
|
-
playGroup: any;
|
|
99
|
-
}): Promise<void>;
|
|
100
|
-
onRegisterTemplate({ id, name, description, visibility }: {
|
|
101
|
-
id: any;
|
|
102
|
-
name: any;
|
|
103
|
-
description: any;
|
|
104
|
-
visibility: any;
|
|
105
|
-
}): Promise<void>;
|
|
106
|
-
refreshFavorites(): Promise<void>;
|
|
107
|
-
_notify(level: 'info' | 'error' | 'warn', message: any, ex?: any): void;
|
|
108
|
-
}
|
|
109
|
-
export {};
|