@staffbase/widget-sdk 3.8.0-beta.2 → 3.8.0
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/README.md +1 -1
- package/package.json +2 -7
- package/docs/.nojekyll +0 -1
- package/docs/BaseBlock.md +0 -5887
- package/docs/BlockAttributes.md +0 -21
- package/docs/BlockDefinition.md +0 -167
- package/docs/BlockElement.md +0 -103
- package/docs/ColorTheme.md +0 -97
- package/docs/ExternalBlockDefinition.md +0 -58
- package/docs/Home.md +0 -131
- package/docs/IntegrationInformation.md +0 -70
- package/docs/IntegrationToken.md +0 -30
- package/docs/SBColors.md +0 -639
- package/docs/SBFileType.md +0 -74
- package/docs/SBImageEntity.md +0 -74
- package/docs/SBUserAvatar.md +0 -52
- package/docs/SBUserProfile.md +0 -140
- package/docs/UserListItem.md +0 -52
- package/docs/UserListRequestQuery.md +0 -52
- package/docs/UserListResponse.md +0 -52
- package/docs/WidgetApi.md +0 -138
- package/docs/_Sidebar.md +0 -3
package/docs/BlockAttributes.md
DELETED
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
# Interface: BlockAttributes
|
|
2
|
-
|
|
3
|
-
## Indexable
|
|
4
|
-
|
|
5
|
-
▪ [key: `string`]: `number` \| `boolean` \| `string`
|
|
6
|
-
|
|
7
|
-
## Table of contents
|
|
8
|
-
|
|
9
|
-
### Properties
|
|
10
|
-
|
|
11
|
-
- [contentLanguage](../wiki/BlockAttributes#contentlanguage)
|
|
12
|
-
|
|
13
|
-
## Properties
|
|
14
|
-
|
|
15
|
-
### contentLanguage
|
|
16
|
-
|
|
17
|
-
• **contentLanguage**: `string`
|
|
18
|
-
|
|
19
|
-
#### Defined in
|
|
20
|
-
|
|
21
|
-
[lib/block-attributes.ts:15](https://github.com/Staffbase/widget-sdk/blob/beta/lib/block-attributes.ts#L15)
|
package/docs/BlockDefinition.md
DELETED
|
@@ -1,167 +0,0 @@
|
|
|
1
|
-
# Interface: BlockDefinition<Factory\>
|
|
2
|
-
|
|
3
|
-
## Type parameters
|
|
4
|
-
|
|
5
|
-
| Name | Type |
|
|
6
|
-
| :------ | :------ |
|
|
7
|
-
| `Factory` | [`BlockFactory`](../wiki/Home#blockfactory) |
|
|
8
|
-
|
|
9
|
-
## Table of contents
|
|
10
|
-
|
|
11
|
-
### Properties
|
|
12
|
-
|
|
13
|
-
- [attributes](../wiki/BlockDefinition#attributes)
|
|
14
|
-
- [blockLevel](../wiki/BlockDefinition#blocklevel)
|
|
15
|
-
- [configurationSchema](../wiki/BlockDefinition#configurationschema)
|
|
16
|
-
- [factory](../wiki/BlockDefinition#factory)
|
|
17
|
-
- [iconUrl](../wiki/BlockDefinition#iconurl)
|
|
18
|
-
- [label](../wiki/BlockDefinition#label)
|
|
19
|
-
- [name](../wiki/BlockDefinition#name)
|
|
20
|
-
- [options](../wiki/BlockDefinition#options)
|
|
21
|
-
- [uiSchema](../wiki/BlockDefinition#uischema)
|
|
22
|
-
|
|
23
|
-
## Properties
|
|
24
|
-
|
|
25
|
-
### attributes
|
|
26
|
-
|
|
27
|
-
• **attributes**: `string`[]
|
|
28
|
-
|
|
29
|
-
DOM attributes of the element, must be in kebab-case.
|
|
30
|
-
|
|
31
|
-
#### Defined in
|
|
32
|
-
|
|
33
|
-
[lib/block-definition.ts:40](https://github.com/Staffbase/widget-sdk/blob/beta/lib/block-definition.ts#L40)
|
|
34
|
-
|
|
35
|
-
___
|
|
36
|
-
|
|
37
|
-
### blockLevel
|
|
38
|
-
|
|
39
|
-
• `Optional` **blockLevel**: ``"block"`` \| ``"inline"``
|
|
40
|
-
|
|
41
|
-
Set to `inline` if you want the element to behave like a span element
|
|
42
|
-
rather than a div element if not specified, it defaults to `block`.
|
|
43
|
-
|
|
44
|
-
#### Defined in
|
|
45
|
-
|
|
46
|
-
[lib/block-definition.ts:46](https://github.com/Staffbase/widget-sdk/blob/beta/lib/block-definition.ts#L46)
|
|
47
|
-
|
|
48
|
-
___
|
|
49
|
-
|
|
50
|
-
### configurationSchema
|
|
51
|
-
|
|
52
|
-
• **configurationSchema**: `JSONSchema7`
|
|
53
|
-
|
|
54
|
-
Schema used for defining the configuration form.
|
|
55
|
-
|
|
56
|
-
**`example`**
|
|
57
|
-
```json
|
|
58
|
-
{
|
|
59
|
-
"type": "object",
|
|
60
|
-
"required": [
|
|
61
|
-
"firstName",
|
|
62
|
-
"lastName"
|
|
63
|
-
],
|
|
64
|
-
"properties": {
|
|
65
|
-
"firstName": {
|
|
66
|
-
"type": "string",
|
|
67
|
-
"title": "First name"
|
|
68
|
-
},
|
|
69
|
-
"lastName": {
|
|
70
|
-
"type": "string",
|
|
71
|
-
"title": "Last name"
|
|
72
|
-
}
|
|
73
|
-
}
|
|
74
|
-
}
|
|
75
|
-
```
|
|
76
|
-
|
|
77
|
-
**`see`** https://react-jsonschema-form.readthedocs.io/en/latest/
|
|
78
|
-
|
|
79
|
-
#### Defined in
|
|
80
|
-
|
|
81
|
-
[lib/block-definition.ts:73](https://github.com/Staffbase/widget-sdk/blob/beta/lib/block-definition.ts#L73)
|
|
82
|
-
|
|
83
|
-
___
|
|
84
|
-
|
|
85
|
-
### factory
|
|
86
|
-
|
|
87
|
-
• **factory**: `Factory`
|
|
88
|
-
|
|
89
|
-
The implementation of the web component.
|
|
90
|
-
|
|
91
|
-
#### Defined in
|
|
92
|
-
|
|
93
|
-
[lib/block-definition.ts:30](https://github.com/Staffbase/widget-sdk/blob/beta/lib/block-definition.ts#L30)
|
|
94
|
-
|
|
95
|
-
___
|
|
96
|
-
|
|
97
|
-
### iconUrl
|
|
98
|
-
|
|
99
|
-
• `Optional` **iconUrl**: `string`
|
|
100
|
-
|
|
101
|
-
Icon displayed on the widget installation page.
|
|
102
|
-
We recommend an icon with the dimensions 32x32 px.
|
|
103
|
-
|
|
104
|
-
#### Defined in
|
|
105
|
-
|
|
106
|
-
[lib/block-definition.ts:100](https://github.com/Staffbase/widget-sdk/blob/beta/lib/block-definition.ts#L100)
|
|
107
|
-
|
|
108
|
-
___
|
|
109
|
-
|
|
110
|
-
### label
|
|
111
|
-
|
|
112
|
-
• `Optional` **label**: `string`
|
|
113
|
-
|
|
114
|
-
Label displayed in the settings dialog and in the default widget preview.
|
|
115
|
-
|
|
116
|
-
#### Defined in
|
|
117
|
-
|
|
118
|
-
[lib/block-definition.ts:94](https://github.com/Staffbase/widget-sdk/blob/beta/lib/block-definition.ts#L94)
|
|
119
|
-
|
|
120
|
-
___
|
|
121
|
-
|
|
122
|
-
### name
|
|
123
|
-
|
|
124
|
-
• **name**: `string`
|
|
125
|
-
|
|
126
|
-
The tag name of the widget. It must be compatible with
|
|
127
|
-
webcomponent naming conventions.
|
|
128
|
-
|
|
129
|
-
**`see`** https://www.webcomponents.org/community/articles/how-should-i-name-my-element
|
|
130
|
-
|
|
131
|
-
#### Defined in
|
|
132
|
-
|
|
133
|
-
[lib/block-definition.ts:25](https://github.com/Staffbase/widget-sdk/blob/beta/lib/block-definition.ts#L25)
|
|
134
|
-
|
|
135
|
-
___
|
|
136
|
-
|
|
137
|
-
### options
|
|
138
|
-
|
|
139
|
-
• `Optional` **options**: `ElementDefinitionOptions`
|
|
140
|
-
|
|
141
|
-
Can be used for extending from a built-in element.
|
|
142
|
-
|
|
143
|
-
#### Defined in
|
|
144
|
-
|
|
145
|
-
[lib/block-definition.ts:35](https://github.com/Staffbase/widget-sdk/blob/beta/lib/block-definition.ts#L35)
|
|
146
|
-
|
|
147
|
-
___
|
|
148
|
-
|
|
149
|
-
### uiSchema
|
|
150
|
-
|
|
151
|
-
• `Optional` **uiSchema**: `UiSchema`
|
|
152
|
-
|
|
153
|
-
Schema to add more customization to the look and feel of the configuration form.
|
|
154
|
-
|
|
155
|
-
```json
|
|
156
|
-
{
|
|
157
|
-
"firstName": {
|
|
158
|
-
"ui:help": "Your first name."
|
|
159
|
-
}
|
|
160
|
-
}
|
|
161
|
-
```
|
|
162
|
-
|
|
163
|
-
**`see`** https://react-jsonschema-form.readthedocs.io/en/latest/api-reference/uiSchema/
|
|
164
|
-
|
|
165
|
-
#### Defined in
|
|
166
|
-
|
|
167
|
-
[lib/block-definition.ts:89](https://github.com/Staffbase/widget-sdk/blob/beta/lib/block-definition.ts#L89)
|
package/docs/BlockElement.md
DELETED
|
@@ -1,103 +0,0 @@
|
|
|
1
|
-
# Interface: BlockElement
|
|
2
|
-
|
|
3
|
-
## Table of contents
|
|
4
|
-
|
|
5
|
-
### Methods
|
|
6
|
-
|
|
7
|
-
- [adoptedCallback](../wiki/BlockElement#adoptedcallback)
|
|
8
|
-
- [attributeChangedCallback](../wiki/BlockElement#attributechangedcallback)
|
|
9
|
-
- [connectedCallback](../wiki/BlockElement#connectedcallback)
|
|
10
|
-
- [disconnectedCallback](../wiki/BlockElement#disconnectedcallback)
|
|
11
|
-
- [unmount](../wiki/BlockElement#unmount)
|
|
12
|
-
|
|
13
|
-
## Methods
|
|
14
|
-
|
|
15
|
-
### adoptedCallback
|
|
16
|
-
|
|
17
|
-
▸ **adoptedCallback**(): `void`
|
|
18
|
-
|
|
19
|
-
Invoked when the custom element is moved to a new document.
|
|
20
|
-
|
|
21
|
-
#### Returns
|
|
22
|
-
|
|
23
|
-
`void`
|
|
24
|
-
|
|
25
|
-
#### Defined in
|
|
26
|
-
|
|
27
|
-
[lib/block-element.ts:33](https://github.com/Staffbase/widget-sdk/blob/beta/lib/block-element.ts#L33)
|
|
28
|
-
|
|
29
|
-
___
|
|
30
|
-
|
|
31
|
-
### attributeChangedCallback
|
|
32
|
-
|
|
33
|
-
▸ **attributeChangedCallback**(`attrName`, `oldValue`, `newValue`): `void`
|
|
34
|
-
|
|
35
|
-
Invoked when one of the attributes of the custom element is added, removed, or changed.
|
|
36
|
-
|
|
37
|
-
Note that you have to statically register the observed values with the 'observedAttributes' static getter.
|
|
38
|
-
|
|
39
|
-
#### Parameters
|
|
40
|
-
|
|
41
|
-
| Name | Type | Description |
|
|
42
|
-
| :------ | :------ | :------ |
|
|
43
|
-
| `attrName` | `string` | The changed attributes name |
|
|
44
|
-
| `oldValue` | `undefined` \| `string` | The old value |
|
|
45
|
-
| `newValue` | `undefined` \| `string` | The new value |
|
|
46
|
-
|
|
47
|
-
#### Returns
|
|
48
|
-
|
|
49
|
-
`void`
|
|
50
|
-
|
|
51
|
-
#### Defined in
|
|
52
|
-
|
|
53
|
-
[lib/block-element.ts:44](https://github.com/Staffbase/widget-sdk/blob/beta/lib/block-element.ts#L44)
|
|
54
|
-
|
|
55
|
-
___
|
|
56
|
-
|
|
57
|
-
### connectedCallback
|
|
58
|
-
|
|
59
|
-
▸ **connectedCallback**(): `void`
|
|
60
|
-
|
|
61
|
-
Invoked when the custom element is first connected to the DOM.
|
|
62
|
-
|
|
63
|
-
#### Returns
|
|
64
|
-
|
|
65
|
-
`void`
|
|
66
|
-
|
|
67
|
-
#### Defined in
|
|
68
|
-
|
|
69
|
-
[lib/block-element.ts:23](https://github.com/Staffbase/widget-sdk/blob/beta/lib/block-element.ts#L23)
|
|
70
|
-
|
|
71
|
-
___
|
|
72
|
-
|
|
73
|
-
### disconnectedCallback
|
|
74
|
-
|
|
75
|
-
▸ **disconnectedCallback**(): `void`
|
|
76
|
-
|
|
77
|
-
Invoked when the custom element is disconnected from the DOM.
|
|
78
|
-
|
|
79
|
-
#### Returns
|
|
80
|
-
|
|
81
|
-
`void`
|
|
82
|
-
|
|
83
|
-
#### Defined in
|
|
84
|
-
|
|
85
|
-
[lib/block-element.ts:28](https://github.com/Staffbase/widget-sdk/blob/beta/lib/block-element.ts#L28)
|
|
86
|
-
|
|
87
|
-
___
|
|
88
|
-
|
|
89
|
-
### unmount
|
|
90
|
-
|
|
91
|
-
▸ **unmount**(): `void`
|
|
92
|
-
|
|
93
|
-
Method to unmount / revert any effects applied by rendering.
|
|
94
|
-
E.g. to be used in editor cases to remove any rendered content
|
|
95
|
-
and revert the block to its initial state.
|
|
96
|
-
|
|
97
|
-
#### Returns
|
|
98
|
-
|
|
99
|
-
`void`
|
|
100
|
-
|
|
101
|
-
#### Defined in
|
|
102
|
-
|
|
103
|
-
[lib/block-element.ts:55](https://github.com/Staffbase/widget-sdk/blob/beta/lib/block-element.ts#L55)
|
package/docs/ColorTheme.md
DELETED
|
@@ -1,97 +0,0 @@
|
|
|
1
|
-
# Interface: ColorTheme
|
|
2
|
-
|
|
3
|
-
The color theme allows the widget to mimic the look
|
|
4
|
-
and feel of the Staffbase ecosystem it was added to.
|
|
5
|
-
|
|
6
|
-
## Table of contents
|
|
7
|
-
|
|
8
|
-
### Properties
|
|
9
|
-
|
|
10
|
-
- [bgColor](../wiki/ColorTheme#bgcolor)
|
|
11
|
-
- [bgColorDarkened1](../wiki/ColorTheme#bgcolordarkened1)
|
|
12
|
-
- [bgColorDarkened2](../wiki/ColorTheme#bgcolordarkened2)
|
|
13
|
-
- [bgColorDarkened2Opaque](../wiki/ColorTheme#bgcolordarkened2opaque)
|
|
14
|
-
- [bgColorLum](../wiki/ColorTheme#bgcolorlum)
|
|
15
|
-
- [colors](../wiki/ColorTheme#colors)
|
|
16
|
-
- [outlineColor](../wiki/ColorTheme#outlinecolor)
|
|
17
|
-
- [textColor](../wiki/ColorTheme#textcolor)
|
|
18
|
-
|
|
19
|
-
## Properties
|
|
20
|
-
|
|
21
|
-
### bgColor
|
|
22
|
-
|
|
23
|
-
• **bgColor**: `string`
|
|
24
|
-
|
|
25
|
-
#### Defined in
|
|
26
|
-
|
|
27
|
-
[lib/widget-api-types.ts:103](https://github.com/Staffbase/widget-sdk/blob/beta/lib/widget-api-types.ts#L103)
|
|
28
|
-
|
|
29
|
-
___
|
|
30
|
-
|
|
31
|
-
### bgColorDarkened1
|
|
32
|
-
|
|
33
|
-
• `Optional` **bgColorDarkened1**: `string`
|
|
34
|
-
|
|
35
|
-
#### Defined in
|
|
36
|
-
|
|
37
|
-
[lib/widget-api-types.ts:106](https://github.com/Staffbase/widget-sdk/blob/beta/lib/widget-api-types.ts#L106)
|
|
38
|
-
|
|
39
|
-
___
|
|
40
|
-
|
|
41
|
-
### bgColorDarkened2
|
|
42
|
-
|
|
43
|
-
• `Optional` **bgColorDarkened2**: `string`
|
|
44
|
-
|
|
45
|
-
#### Defined in
|
|
46
|
-
|
|
47
|
-
[lib/widget-api-types.ts:107](https://github.com/Staffbase/widget-sdk/blob/beta/lib/widget-api-types.ts#L107)
|
|
48
|
-
|
|
49
|
-
___
|
|
50
|
-
|
|
51
|
-
### bgColorDarkened2Opaque
|
|
52
|
-
|
|
53
|
-
• `Optional` **bgColorDarkened2Opaque**: `string`
|
|
54
|
-
|
|
55
|
-
#### Defined in
|
|
56
|
-
|
|
57
|
-
[lib/widget-api-types.ts:108](https://github.com/Staffbase/widget-sdk/blob/beta/lib/widget-api-types.ts#L108)
|
|
58
|
-
|
|
59
|
-
___
|
|
60
|
-
|
|
61
|
-
### bgColorLum
|
|
62
|
-
|
|
63
|
-
• `Optional` **bgColorLum**: `string`
|
|
64
|
-
|
|
65
|
-
#### Defined in
|
|
66
|
-
|
|
67
|
-
[lib/widget-api-types.ts:109](https://github.com/Staffbase/widget-sdk/blob/beta/lib/widget-api-types.ts#L109)
|
|
68
|
-
|
|
69
|
-
___
|
|
70
|
-
|
|
71
|
-
### colors
|
|
72
|
-
|
|
73
|
-
• **colors**: [`SBColors`](../wiki/SBColors)
|
|
74
|
-
|
|
75
|
-
#### Defined in
|
|
76
|
-
|
|
77
|
-
[lib/widget-api-types.ts:105](https://github.com/Staffbase/widget-sdk/blob/beta/lib/widget-api-types.ts#L105)
|
|
78
|
-
|
|
79
|
-
___
|
|
80
|
-
|
|
81
|
-
### outlineColor
|
|
82
|
-
|
|
83
|
-
• `Optional` **outlineColor**: `string`
|
|
84
|
-
|
|
85
|
-
#### Defined in
|
|
86
|
-
|
|
87
|
-
[lib/widget-api-types.ts:110](https://github.com/Staffbase/widget-sdk/blob/beta/lib/widget-api-types.ts#L110)
|
|
88
|
-
|
|
89
|
-
___
|
|
90
|
-
|
|
91
|
-
### textColor
|
|
92
|
-
|
|
93
|
-
• **textColor**: `string`
|
|
94
|
-
|
|
95
|
-
#### Defined in
|
|
96
|
-
|
|
97
|
-
[lib/widget-api-types.ts:104](https://github.com/Staffbase/widget-sdk/blob/beta/lib/widget-api-types.ts#L104)
|
|
@@ -1,58 +0,0 @@
|
|
|
1
|
-
# Interface: ExternalBlockDefinition<Factory\>
|
|
2
|
-
|
|
3
|
-
Defintion of the Widget.
|
|
4
|
-
|
|
5
|
-
Includes the implementation of the BlockDefinition
|
|
6
|
-
and meta information (author and version of the widget).
|
|
7
|
-
|
|
8
|
-
## Type parameters
|
|
9
|
-
|
|
10
|
-
| Name | Type |
|
|
11
|
-
| :------ | :------ |
|
|
12
|
-
| `Factory` | [`BlockFactory`](../wiki/Home#blockfactory) |
|
|
13
|
-
|
|
14
|
-
## Table of contents
|
|
15
|
-
|
|
16
|
-
### Properties
|
|
17
|
-
|
|
18
|
-
- [author](../wiki/ExternalBlockDefinition#author)
|
|
19
|
-
- [blockDefinition](../wiki/ExternalBlockDefinition#blockdefinition)
|
|
20
|
-
- [version](../wiki/ExternalBlockDefinition#version)
|
|
21
|
-
|
|
22
|
-
## Properties
|
|
23
|
-
|
|
24
|
-
### author
|
|
25
|
-
|
|
26
|
-
• **author**: `string`
|
|
27
|
-
|
|
28
|
-
Name of the author.
|
|
29
|
-
|
|
30
|
-
#### Defined in
|
|
31
|
-
|
|
32
|
-
[lib/external-block-definition.ts:39](https://github.com/Staffbase/widget-sdk/blob/beta/lib/external-block-definition.ts#L39)
|
|
33
|
-
|
|
34
|
-
___
|
|
35
|
-
|
|
36
|
-
### blockDefinition
|
|
37
|
-
|
|
38
|
-
• **blockDefinition**: [`BlockDefinition`](../wiki/BlockDefinition)<`Factory`\>
|
|
39
|
-
|
|
40
|
-
Definition of the block.
|
|
41
|
-
|
|
42
|
-
Will be registered to the staffbase app.
|
|
43
|
-
|
|
44
|
-
#### Defined in
|
|
45
|
-
|
|
46
|
-
[lib/external-block-definition.ts:29](https://github.com/Staffbase/widget-sdk/blob/beta/lib/external-block-definition.ts#L29)
|
|
47
|
-
|
|
48
|
-
___
|
|
49
|
-
|
|
50
|
-
### version
|
|
51
|
-
|
|
52
|
-
• **version**: `string`
|
|
53
|
-
|
|
54
|
-
Current version of the widget.
|
|
55
|
-
|
|
56
|
-
#### Defined in
|
|
57
|
-
|
|
58
|
-
[lib/external-block-definition.ts:34](https://github.com/Staffbase/widget-sdk/blob/beta/lib/external-block-definition.ts#L34)
|
package/docs/Home.md
DELETED
|
@@ -1,131 +0,0 @@
|
|
|
1
|
-
# @staffbase/widget-sdk
|
|
2
|
-
|
|
3
|
-
## Table of contents
|
|
4
|
-
|
|
5
|
-
### Interfaces
|
|
6
|
-
|
|
7
|
-
- [BaseBlock](../wiki/BaseBlock)
|
|
8
|
-
- [BlockAttributes](../wiki/BlockAttributes)
|
|
9
|
-
- [BlockDefinition](../wiki/BlockDefinition)
|
|
10
|
-
- [BlockElement](../wiki/BlockElement)
|
|
11
|
-
- [ColorTheme](../wiki/ColorTheme)
|
|
12
|
-
- [ExternalBlockDefinition](../wiki/ExternalBlockDefinition)
|
|
13
|
-
- [IntegrationInformation](../wiki/IntegrationInformation)
|
|
14
|
-
- [IntegrationToken](../wiki/IntegrationToken)
|
|
15
|
-
- [SBColors](../wiki/SBColors)
|
|
16
|
-
- [SBFileType](../wiki/SBFileType)
|
|
17
|
-
- [SBImageEntity](../wiki/SBImageEntity)
|
|
18
|
-
- [SBUserAvatar](../wiki/SBUserAvatar)
|
|
19
|
-
- [SBUserProfile](../wiki/SBUserProfile)
|
|
20
|
-
- [UserListItem](../wiki/UserListItem)
|
|
21
|
-
- [UserListRequestQuery](../wiki/UserListRequestQuery)
|
|
22
|
-
- [UserListResponse](../wiki/UserListResponse)
|
|
23
|
-
- [WidgetApi](../wiki/WidgetApi)
|
|
24
|
-
|
|
25
|
-
### Type aliases
|
|
26
|
-
|
|
27
|
-
- [BlockFactory](../wiki/Home#blockfactory)
|
|
28
|
-
- [IntegrationState](../wiki/Home#integrationstate)
|
|
29
|
-
- [IntegrationType](../wiki/Home#integrationtype)
|
|
30
|
-
- [UserListSorting](../wiki/Home#userlistsorting)
|
|
31
|
-
|
|
32
|
-
### Variables
|
|
33
|
-
|
|
34
|
-
- [IntegrationStates](../wiki/Home#integrationstates)
|
|
35
|
-
|
|
36
|
-
## Type aliases
|
|
37
|
-
|
|
38
|
-
### BlockFactory
|
|
39
|
-
|
|
40
|
-
Ƭ **BlockFactory**: (`Base`: () => [`BaseBlock`](../wiki/BaseBlock), `widgetApi`: [`WidgetApi`](../wiki/WidgetApi)) => `CustomElementConstructor`
|
|
41
|
-
|
|
42
|
-
#### Type declaration
|
|
43
|
-
|
|
44
|
-
▸ (`Base`, `widgetApi`): `CustomElementConstructor`
|
|
45
|
-
|
|
46
|
-
Factory for the custom widgets.
|
|
47
|
-
|
|
48
|
-
**`example`**
|
|
49
|
-
const factory: BlockFactory = Base => {
|
|
50
|
-
|
|
51
|
-
return class CustomBlock extends Base {
|
|
52
|
-
constructor() {
|
|
53
|
-
super();
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
// widget implementation follows ...
|
|
57
|
-
}
|
|
58
|
-
};
|
|
59
|
-
|
|
60
|
-
##### Parameters
|
|
61
|
-
|
|
62
|
-
| Name | Type | Description |
|
|
63
|
-
| :------ | :------ | :------ |
|
|
64
|
-
| `Base` | () => [`BaseBlock`](../wiki/BaseBlock) | base class for the custom widgets to inherit from. The class itself is a subclass of `HTMLElement` of the relevant `window` object, with additional functionality. |
|
|
65
|
-
| `widgetApi` | [`WidgetApi`](../wiki/WidgetApi) | API providing methods for additional information by the Staffbase framework |
|
|
66
|
-
|
|
67
|
-
##### Returns
|
|
68
|
-
|
|
69
|
-
`CustomElementConstructor`
|
|
70
|
-
|
|
71
|
-
#### Defined in
|
|
72
|
-
|
|
73
|
-
[lib/block-factory.ts:38](https://github.com/Staffbase/widget-sdk/blob/beta/lib/block-factory.ts#L38)
|
|
74
|
-
|
|
75
|
-
___
|
|
76
|
-
|
|
77
|
-
### IntegrationState
|
|
78
|
-
|
|
79
|
-
Ƭ **IntegrationState**: typeof [`IntegrationStates`](../wiki/Home#integrationstates)[keyof typeof [`IntegrationStates`](../wiki/Home#integrationstates)]
|
|
80
|
-
|
|
81
|
-
#### Defined in
|
|
82
|
-
|
|
83
|
-
[lib/widget-api-types.ts:215](https://github.com/Staffbase/widget-sdk/blob/beta/lib/widget-api-types.ts#L215)
|
|
84
|
-
|
|
85
|
-
___
|
|
86
|
-
|
|
87
|
-
### IntegrationType
|
|
88
|
-
|
|
89
|
-
Ƭ **IntegrationType**: ``"ms365"``
|
|
90
|
-
|
|
91
|
-
#### Defined in
|
|
92
|
-
|
|
93
|
-
[lib/widget-api-types.ts:193](https://github.com/Staffbase/widget-sdk/blob/beta/lib/widget-api-types.ts#L193)
|
|
94
|
-
|
|
95
|
-
___
|
|
96
|
-
|
|
97
|
-
### UserListSorting
|
|
98
|
-
|
|
99
|
-
Ƭ **UserListSorting**: ``"lastname"`` \| ``"created"`` \| ``"updated"``
|
|
100
|
-
|
|
101
|
-
The sorting order of the user list.
|
|
102
|
-
|
|
103
|
-
**`param`** sort response by lastName_ASC_firstName_ASC (default)
|
|
104
|
-
|
|
105
|
-
**`param`** sort by date of creation descending
|
|
106
|
-
|
|
107
|
-
**`param`** sort by date of last update descending
|
|
108
|
-
|
|
109
|
-
#### Defined in
|
|
110
|
-
|
|
111
|
-
[lib/widget-api-types.ts:160](https://github.com/Staffbase/widget-sdk/blob/beta/lib/widget-api-types.ts#L160)
|
|
112
|
-
|
|
113
|
-
## Variables
|
|
114
|
-
|
|
115
|
-
### IntegrationStates
|
|
116
|
-
|
|
117
|
-
• **IntegrationStates**: `Object`
|
|
118
|
-
|
|
119
|
-
All available states the integration can take
|
|
120
|
-
|
|
121
|
-
#### Type declaration
|
|
122
|
-
|
|
123
|
-
| Name | Type |
|
|
124
|
-
| :------ | :------ |
|
|
125
|
-
| `AVAILABLE` | ``"available"`` |
|
|
126
|
-
| `LOGGED_OUT` | ``"loggedOut"`` |
|
|
127
|
-
| `UNAVAILABLE` | ``"unavailable"`` |
|
|
128
|
-
|
|
129
|
-
#### Defined in
|
|
130
|
-
|
|
131
|
-
[lib/widget-api-types.ts:209](https://github.com/Staffbase/widget-sdk/blob/beta/lib/widget-api-types.ts#L209)
|
|
@@ -1,70 +0,0 @@
|
|
|
1
|
-
# Interface: IntegrationInformation
|
|
2
|
-
|
|
3
|
-
Information about the requested Integration target
|
|
4
|
-
|
|
5
|
-
## Table of contents
|
|
6
|
-
|
|
7
|
-
### Properties
|
|
8
|
-
|
|
9
|
-
- [enabledFeatures](../wiki/IntegrationInformation#enabledfeatures)
|
|
10
|
-
- [status](../wiki/IntegrationInformation#status)
|
|
11
|
-
- [supportedFeatures](../wiki/IntegrationInformation#supportedfeatures)
|
|
12
|
-
- [token](../wiki/IntegrationInformation#token)
|
|
13
|
-
|
|
14
|
-
### Methods
|
|
15
|
-
|
|
16
|
-
- [signIn](../wiki/IntegrationInformation#signin)
|
|
17
|
-
|
|
18
|
-
## Properties
|
|
19
|
-
|
|
20
|
-
### enabledFeatures
|
|
21
|
-
|
|
22
|
-
• **enabledFeatures**: `string`[]
|
|
23
|
-
|
|
24
|
-
#### Defined in
|
|
25
|
-
|
|
26
|
-
[lib/widget-api-types.ts:224](https://github.com/Staffbase/widget-sdk/blob/beta/lib/widget-api-types.ts#L224)
|
|
27
|
-
|
|
28
|
-
___
|
|
29
|
-
|
|
30
|
-
### status
|
|
31
|
-
|
|
32
|
-
• **status**: [`IntegrationState`](../wiki/Home#integrationstate)
|
|
33
|
-
|
|
34
|
-
#### Defined in
|
|
35
|
-
|
|
36
|
-
[lib/widget-api-types.ts:222](https://github.com/Staffbase/widget-sdk/blob/beta/lib/widget-api-types.ts#L222)
|
|
37
|
-
|
|
38
|
-
___
|
|
39
|
-
|
|
40
|
-
### supportedFeatures
|
|
41
|
-
|
|
42
|
-
• **supportedFeatures**: `string`[]
|
|
43
|
-
|
|
44
|
-
#### Defined in
|
|
45
|
-
|
|
46
|
-
[lib/widget-api-types.ts:226](https://github.com/Staffbase/widget-sdk/blob/beta/lib/widget-api-types.ts#L226)
|
|
47
|
-
|
|
48
|
-
___
|
|
49
|
-
|
|
50
|
-
### token
|
|
51
|
-
|
|
52
|
-
• `Optional` **token**: [`IntegrationToken`](../wiki/IntegrationToken)
|
|
53
|
-
|
|
54
|
-
#### Defined in
|
|
55
|
-
|
|
56
|
-
[lib/widget-api-types.ts:228](https://github.com/Staffbase/widget-sdk/blob/beta/lib/widget-api-types.ts#L228)
|
|
57
|
-
|
|
58
|
-
## Methods
|
|
59
|
-
|
|
60
|
-
### signIn
|
|
61
|
-
|
|
62
|
-
▸ `Optional` **signIn**(): `void`
|
|
63
|
-
|
|
64
|
-
#### Returns
|
|
65
|
-
|
|
66
|
-
`void`
|
|
67
|
-
|
|
68
|
-
#### Defined in
|
|
69
|
-
|
|
70
|
-
[lib/widget-api-types.ts:230](https://github.com/Staffbase/widget-sdk/blob/beta/lib/widget-api-types.ts#L230)
|
package/docs/IntegrationToken.md
DELETED
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
# Interface: IntegrationToken
|
|
2
|
-
|
|
3
|
-
Integration Token including the expiration time
|
|
4
|
-
|
|
5
|
-
## Table of contents
|
|
6
|
-
|
|
7
|
-
### Properties
|
|
8
|
-
|
|
9
|
-
- [accessToken](../wiki/IntegrationToken#accesstoken)
|
|
10
|
-
- [accessTokenExpiresAt](../wiki/IntegrationToken#accesstokenexpiresat)
|
|
11
|
-
|
|
12
|
-
## Properties
|
|
13
|
-
|
|
14
|
-
### accessToken
|
|
15
|
-
|
|
16
|
-
• **accessToken**: `string`
|
|
17
|
-
|
|
18
|
-
#### Defined in
|
|
19
|
-
|
|
20
|
-
[lib/widget-api-types.ts:200](https://github.com/Staffbase/widget-sdk/blob/beta/lib/widget-api-types.ts#L200)
|
|
21
|
-
|
|
22
|
-
___
|
|
23
|
-
|
|
24
|
-
### accessTokenExpiresAt
|
|
25
|
-
|
|
26
|
-
• `Optional` **accessTokenExpiresAt**: `Date`
|
|
27
|
-
|
|
28
|
-
#### Defined in
|
|
29
|
-
|
|
30
|
-
[lib/widget-api-types.ts:203](https://github.com/Staffbase/widget-sdk/blob/beta/lib/widget-api-types.ts#L203)
|