@staffbase/widget-sdk 3.3.4 → 3.3.5
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/.github/workflows/ci.yaml +1 -1
- package/CHANGELOG.md +24 -0
- package/docs/.nojekyll +1 -0
- package/docs/BaseBlock.md +4629 -0
- package/docs/BlockAttributes.md +17 -0
- package/docs/{Interface: BlockDefinition.md → BlockDefinition.md} +25 -11
- package/docs/BlockElement.md +83 -0
- package/docs/ColorTheme.md +65 -0
- package/docs/ExternalBlockDefinition.md +46 -0
- package/docs/Home.md +32 -31
- package/docs/SBColors.md +415 -0
- package/docs/SBFileType.md +50 -0
- package/docs/SBImageEntity.md +50 -0
- package/docs/SBUserAvatar.md +36 -0
- package/docs/SBUserProfile.md +64 -0
- package/docs/UserListItem.md +36 -0
- package/docs/UserListRequestQuery.md +36 -0
- package/docs/UserListResponse.md +36 -0
- package/docs/WidgetApi.md +92 -0
- package/docs/_Sidebar.md +2 -19
- package/package.json +15 -15
- package/docs/Interface: BaseBlock.md +0 -3226
- package/docs/Interface: BlockAttributes.md +0 -11
- package/docs/Interface: BlockElement.md +0 -89
- package/docs/Interface: ColorTheme.md +0 -52
- package/docs/Interface: ExternalBlockDefinition.md +0 -38
- package/docs/Interface: SBColors.md +0 -354
- package/docs/Interface: SBFileType.md +0 -39
- package/docs/Interface: SBImageEntity.md +0 -39
- package/docs/Interface: SBUserAvatar.md +0 -27
- package/docs/Interface: SBUserProfile.md +0 -51
- package/docs/Interface: UserListItem.md +0 -27
- package/docs/Interface: UserListRequestQuery.md +0 -27
- package/docs/Interface: UserListResponse.md +0 -27
- package/docs/Interface: WidgetApi.md +0 -75
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
# Interface: WidgetApi
|
|
2
|
+
|
|
3
|
+
Widget API class.
|
|
4
|
+
|
|
5
|
+
A class providing access to additional information about the Staffbase ecosystem for widgets.
|
|
6
|
+
|
|
7
|
+
## Table of contents
|
|
8
|
+
|
|
9
|
+
### Methods
|
|
10
|
+
|
|
11
|
+
- [getLegacyAppTheme](../wiki/WidgetApi#getlegacyapptheme)
|
|
12
|
+
- [getUserInformation](../wiki/WidgetApi#getuserinformation)
|
|
13
|
+
- [getUserInformationByExternalId](../wiki/WidgetApi#getuserinformationbyexternalid)
|
|
14
|
+
- [getUserList](../wiki/WidgetApi#getuserlist)
|
|
15
|
+
|
|
16
|
+
## Methods
|
|
17
|
+
|
|
18
|
+
### getLegacyAppTheme
|
|
19
|
+
|
|
20
|
+
▸ **getLegacyAppTheme**(): [`ColorTheme`](../wiki/ColorTheme)
|
|
21
|
+
|
|
22
|
+
Call to retrieve the color theme of the app. Since this theme definitions
|
|
23
|
+
are currently redesigned, this method is called legacy.
|
|
24
|
+
|
|
25
|
+
#### Returns
|
|
26
|
+
|
|
27
|
+
[`ColorTheme`](../wiki/ColorTheme)
|
|
28
|
+
|
|
29
|
+
An object containing the color theme data is returned.
|
|
30
|
+
|
|
31
|
+
___
|
|
32
|
+
|
|
33
|
+
### getUserInformation
|
|
34
|
+
|
|
35
|
+
▸ **getUserInformation**(`userId?`): `Promise`<[`SBUserProfile`](../wiki/SBUserProfile)\>
|
|
36
|
+
|
|
37
|
+
Call to retrieve the user profile of the current or a specific user.
|
|
38
|
+
|
|
39
|
+
#### Parameters
|
|
40
|
+
|
|
41
|
+
| Name | Type | Description |
|
|
42
|
+
| :------ | :------ | :------ |
|
|
43
|
+
| `userId?` | `string` | User ID to lookup for; leave blank to retrieve current user |
|
|
44
|
+
|
|
45
|
+
#### Returns
|
|
46
|
+
|
|
47
|
+
`Promise`<[`SBUserProfile`](../wiki/SBUserProfile)\>
|
|
48
|
+
|
|
49
|
+
A promise containing the SBUserProfile is returned. In case of an error,
|
|
50
|
+
the promise is rejected.
|
|
51
|
+
|
|
52
|
+
___
|
|
53
|
+
|
|
54
|
+
### getUserInformationByExternalId
|
|
55
|
+
|
|
56
|
+
▸ **getUserInformationByExternalId**(`externalId`): `Promise`<[`SBUserProfile`](../wiki/SBUserProfile)\>
|
|
57
|
+
|
|
58
|
+
Call to retrieve a user profile by its external ID.
|
|
59
|
+
|
|
60
|
+
#### Parameters
|
|
61
|
+
|
|
62
|
+
| Name | Type | Description |
|
|
63
|
+
| :------ | :------ | :------ |
|
|
64
|
+
| `externalId` | `string` | An external ID of the user that shall be returned |
|
|
65
|
+
|
|
66
|
+
#### Returns
|
|
67
|
+
|
|
68
|
+
`Promise`<[`SBUserProfile`](../wiki/SBUserProfile)\>
|
|
69
|
+
|
|
70
|
+
A promise containing the SBUserProfile is returned. In case of an error,
|
|
71
|
+
the promise is rejected.
|
|
72
|
+
|
|
73
|
+
___
|
|
74
|
+
|
|
75
|
+
### getUserList
|
|
76
|
+
|
|
77
|
+
▸ **getUserList**(`query`): `Promise`<[`UserListResponse`](../wiki/UserListResponse)\>
|
|
78
|
+
|
|
79
|
+
Call to retrieve a list of users determined by the query object.
|
|
80
|
+
|
|
81
|
+
#### Parameters
|
|
82
|
+
|
|
83
|
+
| Name | Type | Description |
|
|
84
|
+
| :------ | :------ | :------ |
|
|
85
|
+
| `query` | [`UserListRequestQuery`](../wiki/UserListRequestQuery) | Adjust limit, offset, filter, and sorting for the request |
|
|
86
|
+
|
|
87
|
+
#### Returns
|
|
88
|
+
|
|
89
|
+
`Promise`<[`UserListResponse`](../wiki/UserListResponse)\>
|
|
90
|
+
|
|
91
|
+
A promise containing the UserListResponse is returned. In case of an error,
|
|
92
|
+
the promise is rejected.
|
package/docs/_Sidebar.md
CHANGED
|
@@ -1,20 +1,3 @@
|
|
|
1
|
-
##
|
|
1
|
+
## @staffbase/widget-sdk
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
### Interfaces
|
|
5
|
-
|
|
6
|
-
- [BaseBlock](../wiki/Interface:%20BaseBlock)
|
|
7
|
-
- [BlockAttributes](../wiki/Interface:%20BlockAttributes)
|
|
8
|
-
- [BlockDefinition](../wiki/Interface:%20BlockDefinition)
|
|
9
|
-
- [BlockElement](../wiki/Interface:%20BlockElement)
|
|
10
|
-
- [ColorTheme](../wiki/Interface:%20ColorTheme)
|
|
11
|
-
- [ExternalBlockDefinition](../wiki/Interface:%20ExternalBlockDefinition)
|
|
12
|
-
- [SBColors](../wiki/Interface:%20SBColors)
|
|
13
|
-
- [SBFileType](../wiki/Interface:%20SBFileType)
|
|
14
|
-
- [SBImageEntity](../wiki/Interface:%20SBImageEntity)
|
|
15
|
-
- [SBUserAvatar](../wiki/Interface:%20SBUserAvatar)
|
|
16
|
-
- [SBUserProfile](../wiki/Interface:%20SBUserProfile)
|
|
17
|
-
- [UserListItem](../wiki/Interface:%20UserListItem)
|
|
18
|
-
- [UserListRequestQuery](../wiki/Interface:%20UserListRequestQuery)
|
|
19
|
-
- [UserListResponse](../wiki/Interface:%20UserListResponse)
|
|
20
|
-
- [WidgetApi](../wiki/Interface:%20WidgetApi)
|
|
3
|
+
- [Home](../wiki/Home)
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@staffbase/widget-sdk",
|
|
3
|
-
"version": "3.3.
|
|
3
|
+
"version": "3.3.5",
|
|
4
4
|
"description": "Staffbase SDK for Custom Widgets",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"web-components"
|
|
@@ -14,28 +14,28 @@
|
|
|
14
14
|
"license": "Apache-2.0",
|
|
15
15
|
"author": "Staffbase",
|
|
16
16
|
"dependencies": {
|
|
17
|
-
"@rjsf/core": "3.
|
|
18
|
-
"@types/json-schema": "^7.0.
|
|
17
|
+
"@rjsf/core": "^3.2.1",
|
|
18
|
+
"@types/json-schema": "^7.0.9"
|
|
19
19
|
},
|
|
20
20
|
"devDependencies": {
|
|
21
|
-
"@amanda-mitchell/semantic-release-npm-multiple": "2.
|
|
22
|
-
"@commitlint/cli": "
|
|
23
|
-
"@commitlint/config-conventional": "
|
|
21
|
+
"@amanda-mitchell/semantic-release-npm-multiple": "2.15.0",
|
|
22
|
+
"@commitlint/cli": "15.0.0",
|
|
23
|
+
"@commitlint/config-conventional": "15.0.0",
|
|
24
24
|
"@tmware/semantic-release-npm-github-publish": "1.4.4",
|
|
25
|
-
"@types/react": "^17.0.
|
|
26
|
-
"husky": "^7.0.
|
|
27
|
-
"semantic-release": "^17.4.
|
|
28
|
-
"typedoc": "0.
|
|
29
|
-
"typedoc-github-wiki-theme": "0.
|
|
30
|
-
"typedoc-plugin-markdown": "3.
|
|
31
|
-
"typescript": "^4.2
|
|
25
|
+
"@types/react": "^17.0.36",
|
|
26
|
+
"husky": "^7.0.4",
|
|
27
|
+
"semantic-release": "^17.4.7",
|
|
28
|
+
"typedoc": "0.22.9",
|
|
29
|
+
"typedoc-github-wiki-theme": "0.6.0",
|
|
30
|
+
"typedoc-plugin-markdown": "3.11.7",
|
|
31
|
+
"typescript": "^4.4.2"
|
|
32
32
|
},
|
|
33
33
|
"repository": {
|
|
34
34
|
"type": "git",
|
|
35
35
|
"url": "https://github.com/Staffbase/widget-sdk"
|
|
36
36
|
},
|
|
37
37
|
"engines": {
|
|
38
|
-
"node": ">=
|
|
39
|
-
"npm": ">=
|
|
38
|
+
"node": ">= 14",
|
|
39
|
+
"npm": ">= 7"
|
|
40
40
|
}
|
|
41
41
|
}
|