@ichicraft/widgets-widget-base
v1.21.0
Published
Part of the Widget Development Kit for building widgets for Bloom Intranet
Readme
This package supports development of widgets built using the Widget Development Kit
This package is part of the Widget Development Kit, which is a collection of NPM packages that empower developers to create widgets for Bloom Intranet.
@ichicraft/widgets-widget-base
The contract a widget implements, and the shape of what the Widget Board hands it at runtime. A widget extends BaseWidget, receives a WidgetContext, and renders into a DOM element the board owns.
Features
- One base class — Extend
BaseWidget, implementinitandrender, and the board takes care of the rest - Opt-in capabilities — Buddy rendering, user and admin configuration, import and export are optional methods; implement only what the widget needs
- A scoped context —
WidgetContextexposes the SharePoint and Graph clients, the current user, the board's theme and the host environment, without handing over the web part - Dev server helpers —
lib/devbuilds a webpack dev-server configuration that resolves its own port, so several widgets can be debugged against one board at once
Installation
npm install @ichicraft/widgets-widget-baseUsage
A widget is a class extending BaseWidget. Only init and render are required.
import { BaseWidget, type WidgetContext } from '@ichicraft/widgets-widget-base';
export default class RssWidget extends BaseWidget {
private feed: FeedItem[] = [];
public async init(): Promise<void> {
// Called once before the first render. Fetch what the widget needs.
this.feed = await loadFeed(this.context.instance.data);
}
public render(domElement: HTMLDivElement): void {
// Called whenever the board wants the widget drawn.
ReactDOM.render(<Rss items={this.feed} context={this.context} />, domElement);
}
}this.context is the WidgetContext the board constructed for this widget instance.
Optional capabilities
Each of these is optional. Implementing one tells the board the widget supports that capability.
| Method | Purpose |
| --- | --- |
| renderBuddy(el, options?) | Draw the widget's buddy-bar entry. Return true when rendering it yourself. options.allowRichRendering says whether the slot has room for more than an icon button. |
| renderUserConfigurationForm(el) | Draw the per-user settings form. |
| validateUserConfigurationForm() | Return a ValidationResult before the form is saved. |
| getSerializedUserConfiguration() | Return the form's state as the string the board persists. |
| verifyPersistedUserConfiguration(config) | Check stored configuration before it is used. |
| renderAdminConfigurationForm(el) and its siblings | The same four methods for the admin-level configuration. |
| exportData() / importData(data) | Move the widget's stored data between boards. |
| updateDataAccess(from, to) | React to the widget's audience changing. |
| cleanupResources() | Release anything held when the widget is torn down. |
What is on the context
WidgetContext is broad; these are the parts most widgets reach for.
// SharePoint and Graph, already authenticated for this user
context.sp; // @pnp/sp SPFI
context.spHttpClient; // SPHttpClient
context.msGraphClient; // Graph client
context.aadHttpClientFactory; // for your own AAD-protected APIs
// Who is looking at it
context.userDisplayName;
context.userEmail;
context.spUserId;
context.userRoles; // 'administrator' | 'board-owner' | 'widget-administrator'
context.language;
// Where it is running
context.siteUrl;
context.tenantId;
context.inTeamsContext;
context.isMobileBrowser;
context.assetsBaseUrl; // the folder this widget's bundle was loaded from
// This placement and its configuration
context.instance; // this instance: id, parent board, deep links, notifications
context.instance.data; // user settings for this instance, as a string
context.variant.data; // board-wide settings for it, as a string
context.instance.cache; // a CacheManager scoped to this instance
context.variant.cache; // a CacheManager scoped to the variant
context.manifest; // what the widget declared about itself
context.design; // the board's theme coloursThe full set is in WidgetContext in lib/types; the interface is documented member by member.
Reading configuration
Configuration is persisted as a string. ConfigurationHelper parses it back.
import { ConfigurationHelper } from '@ichicraft/widgets-widget-base/lib/utils';
const config = ConfigurationHelper.parseConfiguration<RssConfig>(this.context.instance.data);parseConfiguration returns an empty object rather than throwing when the stored value is empty. instance.data holds the settings a user made for this placement; variant.data holds the board-wide ones an administrator configured.
Debugging against a live board
lib/dev builds the webpack dev-server configuration for a widget, resolving a free port first so the manifest url handed to the board always matches the port the server binds to. That is what allows several widgets to be debugged on one board at the same time.
// webpack.dev.ts
import { createWidgetDevServerConfig } from '@ichicraft/widgets-widget-base/lib/dev';
import serveConfig from './config/serve.config';
const { devServer, cssModuleLocalIdentName, manifestUrl, debugPageUrl } =
await createWidgetDevServerConfig({ projectPath: __dirname, serveConfig });serve.config.ts controls the session:
export default {
widgetsDebugPageUrl: 'https://contoso.sharepoint.com/sites/intranet/SitePages/Home.aspx',
debugPort: 8081, // optional; otherwise the first free port from 8080 up
openBrowser: false, // set false for the second and further widgets in a session
};cssModuleLocalIdentName is keyed by port, so two widgets served at once never collide on css module class names.
webpack and webpack-dev-server are optional peer dependencies. They are only needed for these helpers, which every widget project already has installed.
Changelog
All notable changes to this project will be documented here.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
Entries from 1.21.0 onwards are generated from pull request descriptions when a release is built.
1.21.0 - 2026-08-27
Changed
- The package now needs SharePoint Framework 1.23.2 or newer.
- The framework dependency accepts any 1.x from 1.23.2 upwards rather than one exact version.
- The package page on npm now explains how to write a widget: the base class, what the context carries, where configuration is stored, and the helpers for debugging against a live installation of Bloom Intranet.
1.20.0 - 2026-08-25
- Added
createWidgetDevServerConfigandfindAvailablePort, exported from@ichicraft/widgets-widget-base/lib/devfor use in a widget'swebpack.dev.ts. The helper resolves a free port before it builds the debug url, so the manifest url handed to the board always matches the port the dev server binds to. This is what allows several widgets to be served and debugged on the same board at the same time. - Added
cssModuleLocalIdentNameto the result ofcreateWidgetDevServerConfig. It is keyed by port, so css module class names stay unique between widgets that are served at the same time. - Added optional
debugPortproperty toWidgetDebugServeConfig, pinning a widget's dev server to a fixed port. When omitted, the first free port from 8080 upwards is used. - Added optional
openBrowserproperty toWidgetDebugServeConfig. Set it tofalsefor the second and further widgets in a multi-widget debug session, so they serve their bundle without opening a browser window of their own. - Added
webpackandwebpack-dev-serveras optional peer dependencies. They are only needed when using thelib/devhelpers, which every widget project already has installed. - Breaking: removed the
DebugComponentTypeenum and thedebugComponentTypeproperty ofWidgetDebugServeConfig. Opening the board on one specific component no longer makes sense now that several widgets can be debugged at once. Remove both from yourconfig/serve.config.ts.
1.19.0 - 2026-08-18
- Added optional
bloomGroupsprovider toWidgetContext, exposing afetchGroups()function that supplies the tenant's Bloom Group definitions. Widgets can pass it through to their people pickers so Bloom Groups can be offered as suggestions.
1.18.0 - 2026-08-17
- Added optional
assetsBaseUrlproperty to theWidgetContextinterface, containing the base URL of the folder the widget bundle was loaded from. This allows widgets to fetch files that are published alongside their bundle, such as per-language translation files.
1.17.0 - 2026-07-16
- Moved
UserHelper,ICPersona,ICPersonaType,ICSite,ICTeamandICTermto an internal package.
1.16.6 - 2026-06-03
- Replaced unused
design.header.activeTextColorwithdesign.header.subTextColor
1.16.5 - 2026-06-01
- Added
BuddyRenderOptionsinterface, passed by the host toBaseWidget.renderBuddyto describe the slot the widget is about to render into. - Added optional
optionsparameter toBaseWidget.renderBuddy, of typeBuddyRenderOptions. Contains anallowRichRenderingboolean that signals whether the slot has room for richer rendering than the standard buddy icon button — letting the widget decide synchronously between custom and default rendering.
1.16.4 - 2026-05-27
- Added
headerproperty toWidgetDesignContextinterface, exposing the header'stextColor,iconColor,activeTextColorandactiveIconColorfrom the user's theme. - Deprecated
defaultColorproperty onWidgetBuddyContextinterface in favor ofdesign.header.iconColor(anddesign.header.activeIconColorfor the hover/active state).
1.16.3 - 2026-05-08
- Added
whatsNewUrlproperty toWidgetManifestConfigto allow quick access to updates that the widget has received. - Added
aboutUrlproperty toWidgetManifestConfigto allow quick access to more information about the widget.
1.16.2 - 2026-03-25
- Fixed issue with using internal library
@ic/cachingby publishing caching library as public (@ichicraft/caching)
1.16.1 - 2026-03-19
- Addition of
notificationBadgeCountproperty toCommandBarItemPropsto allow for a number to be displayed in the badge
1.16.0 - 2026-03-09
- Addition of
cacheproperty toinstance,variantandmanifestlevel ofWidgetContextto centralize cache handling and functionality
1.15.4 - 2026-01-07
- Override version of deep dependency 'validator' to get rid of potential vulnerability
1.15.3 - 2025-12-09
- Added property
isIndeterminatetoICTerminterface, used to represent a term's indeterminate checkmark state.
1.15.2 - 2025-11-21
- Added new interface
ICTerm, used to represent a SharePoint Taxonomy Term object in code
1.15.1 - 2025-09-30
- Added new interface
ICTeam, used to represent a Microsoft Teams team object in code
1.15.0 - 2025-09-29
- Deprecated
msGraphClientFactoryin favor ofmsGraphClientin theWidgetManifestConfiginterface.
1.14.7 - 2025-08-21
- Added
parentIdproperty to theWidgetInstanceContextinterface, to support checking the ID of the parent of a widget instance.
1.14.6 - 2025-08-11
- Added
updateInstanceConfigurationproperty to theWidgetInstanceContextinterface, to support updating the instance configuration directly in a widget, instead of through the settings panel.
1.14.5 - 2025-08-07
- Added
imageUrlproperty to theCommandBarTabinterface, to support displaying images in widget header tabs.
1.14.4 - 2025-08-01
- Added
releaseTypeproperty to theWidgetManifestConfiginterface, to indicate the current stage of the release lifecycle a widget is in. - Added
registerOnBuddyClickproperty to theWidgetBuddyContextinterface, to allow overriding default onClick behavior when clicking on a buddy (by default, it opens the widget in a Callout).
1.14.3 - 2025-07-04
- Added
justificationstring property to widget manifest to describe the reasoning behind the need for certain API permisisons
1.14.2 - 2025-07-02
- Reverted
@microsoft/sp-httpdependency back to SPFx version1.18.2due to postponed upgrade - Added
isOptionalboolean to widget manifest to allow marking certain API permission requests as optional
1.14.1 - 2025-06-17
- Reverted module type 'commonjs' for backwards compatibility
1.14.0 - 2025-05-21
- Version bumped
@microsoft/sp-httpdependency to latest SPFx version1.21.1
1.13.2 - 2025-04-11
- Minor update in documentation of
WebApiPermissionRequestinterface
1.13.1 - 2025-03-11
- Added new interface
ICSite, used to represent a SharePoint site object in code
1.13.0 - 2025-02-17
- Fixed an issue with detecting external users in
UserHelper - Changed target JavaScript version to
ES6
1.12.0 - 2025-02-11
- Added
ColorOptioninterface. - Added
WidgetDesignContextinterface. - Added
designproperty of typeWidgetDesignContexttoWidgetContextinterface, to support UI settings within widgets. - Deprecated
elementBorderRadiusproperty which is renamed toborderRadiusand moved underdesignproperty inWidgetContextinterface.
1.11.6 - 2025-01-30
- Added
spServiceScopeproperty toWidgetContextinterface. - Added
loadComponentByIdfunction toWidgetContextinterface. - Deprecated
definitionproperty which is replaced byvariantproperty inWidgetContextinterface. - Deprecated
instance.publishNotificationfunction inWidgetContextinterface because feature is no longer available.
1.11.5 - 2025-01-21
- Added
defaultColorproperty toWidgetBuddyContextinterface.
1.11.4 - 2024-11-08
- Added
driveIdproperty toFilePickerFilePropsinterface.
1.11.3 - 2024-11-05
- Added
fileNameproperty toFilePickerFilePropsinterface.
1.11.2 - 2024-10-21
- Added optional
objectIdproperty to theICPersonainterface.
1.11.1 - 2024-10-17
- Made
buddyproperty of typeWidgetBuddyContextoptional.
1.11.0 - 2024-10-17
- Added
renderBuddyfunction to theBaseWidgetclass, to support rendering widgets as a buddy. - Added
buddyproperty of typeWidgetBuddyContextto theWidgetContextinterface, to support utility functions specifically for a widget buddy. - Added
setBadgePropertiesfunction to theWidgetBuddyContextinterface, to allow rendering a badge on top of the buddy.
1.10.8 - 2024-10-15
- Added
buddybarto theBoardTypetype, to support widgets that run in the scope of the upcoming buddy bar feature
1.10.7 - 2024-08-20
- Replaced
onInitfunction with a new asynchronousinitfunction in theBaseWidgetclass, to allow waiting until initialization is complete.
1.10.6 - 2024-08-19
- Added
userDisplayNameproperty to theWidgetContextinterface, to allow using the currently signed-in user's display name in widgets.
1.10.5 - 2024-08-07
- Added
onSearchproperty to theCommandBarSearchIteminterface, to allow executing a callback when the user presses enter in the search box.
1.10.4 - 2024-07-23
- Added
SearchBarvalue to theCommandBarItemTypeenum, to allow rendering a command bar item as a search bar. - Added
CommandBarSearchIteminterface, to allow passing extra search-related props to a CommandBarItem of typeSearchBar. - Added optional
overflowButtonIconNameandoverflowButtonTooltipproperties to theCommandBarTabOptionsinterface, to allow customization of the overflow menu button. - Added optional
itemCountproperty to theCommandBarTabinterface. - Added summaries to functions and interfaces related to widget command bar tabs.
1.10.3 - 2024-07-22
- Added override in package.json to use version
2.3.7instead of2.3.6ofrequirejsbecause the latter has vulnerability CVE-2024-38999
1.10.2 - 2024-07-19
- Added
registerTabsfunction to theWidgetInstanceContextinterface, to allow rendering of tabs in the widget header. - Added
setSelectedTabfunction to theWidgetInstanceContextinterface, to allow setting the current selected tab in the widget header. - Added
CommandBarTabinterface. - Added
CommandBarTabOptionsinterface.
1.10.1 - 2024-07-08
- Added
widget-administratorrole to theUserRoletype.
1.10.0 - 2024-06-25
- Added optional
updateDataAccess()function to theBaseWidgetclass, used to update access to widget-specific data. - Added
administratorsproperty to theWidgetVariantContextinterface.
1.9.14 - 2024-06-18
- Change import of
SPFItype to decrease bundle sizes in widgets.
1.9.13 - 2024-06-18
- Added
spHttpClientproperty toWidgetContextinterface, to perform REST calls against SharePoint. - Added
spHttpClientConfigurationproperty toWidgetContextinterface.
1.9.12 - 2024-06-17
- Added
spproperty toWidgetContextinterface, to allow using a centralized PnPjs version across all widgets. - Added
siteIdproperty toWidgetContextinterface. - Added
boardsInstanceIdproperty toWidgetContextinterface.
1.9.11 - 2024-06-14
- Fixed handling of null
ICPersonaTypevalues inisCurrentUserInScopefunction ofUserHelperclass.
1.9.10 - 2024-06-04
- Renamed
CustomCommandBarItemPropsinterface toCommandBarItemProps. - Merged
CommandBarIcon,CommandBarLinkandCommandBarItemBaseinterfaces into theCommandBarItemPropsinterface, to simplify adding custom command bar items. - Added
Overflowtype toCommandBarItemTypeenum, to allow rendering an item inside the overflow menu. - Added
highlightedproperty to theCommandBarItemPropsinterface, to allow rendering an item as if it is being hovered. - Added
cursorproperty to theCommandBarItemPropsinterface, to allow a different cursor when hovering over an item. - Added
disabledproperty to theCommandBarItemPropsinterface, to allow rendering an item in a disabled state.
1.9.9 - 2024-05-14
- Changed return type of
createDeepLinkfunction of the WidgetInstanceContext interface fromvoidtostring.
1.9.8 - 2024-05-13
- Added
createDeepLinkproperty to the WidgetInstanceContext interface, to allow creating a deep link URL based on the current board and a widget instance. - Added
setDeepLinkDataproperty to the WidgetInstanceContext interface, to allow setting deep link data related to a widget instance in the URL of the current page. - Added
getDeepLinkDataproperty to the WidgetInstanceContext interface, to allow getting deep link data related to a widget instance from the URL of the current page.
1.9.7 - 2024-04-19
- Added
hideSpHubNavproperty to the IFrameDialogOptions interface, to allow hiding the Hub navigation on SharePoint sites. - Added
hideSpSiteHeaderproperty to the IFrameDialogOptions interface, to allow hiding the site header on SharePoint sites. - Added
showHistoryButtonsproperty to the IFrameDialogOptions interface, to render back and forward buttons, allowing the user to navigate the browser history. - Added
showOpenInNewWindowproperty to the IFrameDialogOptions interface, to render an 'open in new window' button, allowing the user to open the iframe url in a new browser window.
1.9.6 - 2024-04-19
- Changed
onRenderHeaderIconproperty of the IFrameDialogOptions interface, to work similarly to the widget render functions.
1.9.5 - 2024-04-18
- Added
titleproperty to the IFrameDialogOptions interface, to allow rendering a title in the dialog header. - Added
titleUrlproperty to the IFrameDialogOptions interface, to allow making the dialog header title clickable. - Added
onRenderHeaderIconproperty to the IFrameDialogOptions interface, to allow rendering an icon in the dialog header. - Added
onLoadproperty to the IFrameDialogOptions interface, to support executing some code after the iframe finishes loading.
1.9.4 - 2024-04-11
- Reintroduced the following types:
AadHttpClient,AadHttpClientConfiguration,AadHttpClientFactory,AadHttpClientResponse,AadTokenProvider,AadTokenProviderFactory
1.9.2 - 2024-03-21
- Added
CommandBarIconinterface, to allow rendering aCustomCommandBarItemas a single icon or an icon button. - Added
CommandBarLinkinterface, to allow rendering aCustomCommandBarItemas a clickable link. - Added
CommandBarItemBaseinterface, to act as a base for different types ofCustomCommandBarItem. - Added
elementBorderRadiusproperty to theWidgetContextinterface, to allow styling widgets according to the configured design preferences. - Changed
CustomCommandBarItemPropstype to accept either aCommandBarIconor aCommandBarLink.
1.9.1 - 2023-10-20
- Added
WidgetInstanceContextinterface, to allow typing theinstanceproperty of theWidgetContextinterface. - Added
WidgetVariantContextinterface, to allow typing thedefinitionproperty of theWidgetContextinterface. - Added
WidgetManifestContextinterface, to allow typing themanifestproperty of theWidgetContextinterface.
1.9.0 - 2023-10-20
- Added optional
importData()function to theBaseWidgetclass, used to import widget-specific data. - Added optional
exportData()function to theBaseWidgetclass, used to export widget-specific data. - Added new exported
ExportDatatype.
1.8.17 - 2023-10-09
- Added
iconNameproperty to thedefinitionobject of theWidgetContextinterface, to support using an icon to represent a widget.
1.8.16 - 2023-09-26
- Added
Customvalue toICPersonaTypeenum, to support a custom ICPersona.
1.8.15 - 2023-09-01
- Added
thumbnailUrlproperty toWidgetManifestConfiginterface, as a non-translatable substitute of the newly deprecatedpreview_smallproperty fromWidgetImagesinterface. - Removed the deprecated
preview_smallproperty fromWidgetImagesinterface.
1.8.14 - 2023-09-01
- Added
iconNameproperty toWidgetManifestConfiginterface, to support using an icon to represent a widget, e.g. in the widget library or widget header. - Removed the deprecated
notificationIconproperty fromWidgetManifestConfiginterface.
1.8.13 - 2023-06-08
- Removed the deprecated
resolvedproperty fromICPersonainterface
1.8.12 - 2023-04-04
- Changed
openFilePickerfunction to return more details of the picked file in the shape ofFilePickerFileProps
1.8.11 - 2023-04-03
- Changed
openFilePickerfunction to return more details of the picked file in the shape ofFilePickerFileProps
1.8.10 - 2023-03-30
- Changed
openFilePickerfunction to acceptoptions, to support configuration of picker behavior
1.8.9 - 2023-03-06
- Added
registerCustomCommandBarItemsfunction to theinstanceobject of theWidgetContextinterface, to support multiple custom buttons in the widget header. - Added
unregisterCustomCommandBarItemsfunction to theinstanceobject of theWidgetContextinterface, to support removing all custom buttons in the widget header. - Added optional
idproperty to exportedCustomCommandBarItemPropstype, to support removing a custom command bar item by id. - Added optional
pinnedproperty to exportedCustomCommandBarItemPropstype, to support forcing the widget header to always be visible. - Added optional
showNotificationBadgeproperty to exportedCustomCommandBarItemPropstype, to support showing a red notification badge over the custom command bar item. - Added optional
orderproperty to exportedCustomCommandBarItemPropstype, to support changing the order of custom command bar items. - Changed
unregisterCustomCommandBarItemfunction of theinstanceobject of theWidgetContextinterface, to support removing a custom command bar item by id.
1.8.8 - 2023-02-16
- Removed all SharePoint and Teams dependencies.
1.8.7 - 2022-12-13
- Added
userRolesproperty to theWidgetContextinterface, to inform widgets of the roles of the current user. - Added new exported
UserRoletype.
1.8.6 - 2022-12-08
- Added
boardTypeproperty to theinstanceobject of theWidgetContextinterface, to inform widgets of the type of their board. - Added
allowedBoardTypesproperty to thedefinitionobject of theWidgetContextinterface, to inform widget variants of the types of boards it is allowed to be added to. - Added new exported
BoardTypetype.
1.8.5 - 2022-09-30
- Added
setWidgetTitleSuffix()function to theinstanceobject of theWidgetContextinterface, to support appending the title of the widget with additional text. - Added
setWidgetSubtitle()function to theinstanceobject of theWidgetContextinterface, to support overriding the subtitle of the widget. - Added
setUserConfigButtonVisibilty()function to theinstanceobject of theWidgetContextinterface, to support hiding the settings button from the widget header. - Fixed spelling of
setWidgetHeaderVisibilty()function. The function is now calledsetWidgetHeaderVisibility().
1.8.4 - 2022-09-05
- Added
openIFrameDialog()function to theWidgetContextinterface. This has the same functionality as theopenUrlInDialog()function of theinstanceobject, but adds more control over the dimensions of the dialog. The functionopenUrlInDialog()is now deprecated.
1.8.3 - 2022-08-16
- Added
openFilePicker()function to theWidgetContextinterface to support file selection from within a widget.
1.8.2 - 2022-07-06
- Added
subtitleproperty to theWidgetResourceinterface.
1.8.1 - 2022-06-17
- Added new section
analyticstoWidgetManifestConfiginterface to allow definition of time-based events that can be raised by a widget. - Added
raiseEvent(...)to theinstanceobject of theWidgetContentinterface, allowing widgets to raise an event.
1.7.11 - 2022-03-23
- Added
setWidgetHeaderVisibilty()function to theinstanceobject of theWidgetContextinterface, allowing widgets to render in full height.
1.7.9 - 2022-01-20
- Added
userAccountCreateddate/time to theWidgetContextinterface.
1.7.8 - 2022-01-18
Changed
- Added
initiateWidgetDeletion()function to theWidgetContextinterface.
1.7.7 - 2022-01-14
Changed
- Added
tenantIdproperty to theWidgetContextinterface.
1.7.6 - 2021-11-04
Changed
- Added
themeproperty to theWidgetContextinterface to give access to currently applied theme.
1.7.5 - 2021-10-26
Changed
- Added
userSecurityGroupsanduserSharePointGroupsproperties to theWidgetContextinterface to inform widgets of SharePoint and security group memberships of the current user.
1.7.4 - 2021-10-20
Changed
- Added
contentLanguagesproperty to theWidgetContextinterface to inform widgets of the available content languages as configured in Ichicraft Boards.
1.7.3 - 2021-10-04
Changed
- Added
manifestVersionproperty to theWidgetManifestConfiginterface to support multiple versions of the manifest. Current version is 2 which introduced this and theexternalsproperty. - Added
externalsproperty to theWidgetManifestConfiginterface to support libraries that can be loaded separately from the widget bundle. This reduces widget bundle size and improves overal performance of Ichicraft Boards.
1.6.1 - 2021-02-18
Changed
- Added
userEmailproperty to theWidgetContextinterface to provide current user's email address to widgets.
1.5.0 - 2021-02-16
Changed
- Added
teamsSdkproperty to theWidgetContextinterface to allow interaction with Teams in case widget board is running in Teams client. Will beundefinedif running in SharePoint.
1.4.0 - 2021-01-25
Changed
- Added several properties to the
WidgetContextinterface to identify the context in which the widget is shown (e.g. Team Browser hosted)
1.3.0 - 2021-01-15
Changed
registerCustomCommandBarItem()is added to theWidgetContextinterface as a function to call from within a widget instance to render an additional command bar item in the widget header.unregisterCustomCommandBarItem()is added to theWidgetContextinterface as a function to call from within a widget instance to remove a previously added command bar item from the widget header.
1.2.0 - 2021-01-15
Changed
loadScript()is added to theWidgetContextinterface as a function to call from within a widget in case an external script needs to be loaded. This allows the widget board to load external javascript.
1.1.0 - 2021-01-11
Changed
handleFatalError()is added to theWidgetContextinterface as a function to call from within a widget in case of an unhandled/unresolvable error. This allows the widget board to handle this situation gracefully.- deps: removed dependency ajv
<= 1.0.5 - 2020-12-07
No changelog was maintained for the earlier versions.
