@ichicraft/widgets-widget-base 1.11.0 → 1.11.1
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 +4 -0
- package/lib/types/index.d.ts +7 -7
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -9,6 +9,10 @@ All notable changes to this project will be documented here.
|
|
|
9
9
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
|
10
10
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
11
11
|
|
|
12
|
+
## 1.11.1 - 2024-10-17
|
|
13
|
+
|
|
14
|
+
- Made `buddy` property of type `WidgetBuddyContext` optional.
|
|
15
|
+
|
|
12
16
|
## 1.11.0 - 2024-10-17
|
|
13
17
|
|
|
14
18
|
- Added `renderBuddy` function to the `BaseWidget` class, to support rendering widgets as a buddy.
|
package/lib/types/index.d.ts
CHANGED
|
@@ -7,16 +7,15 @@ export type { AadTokenProviderFactory, AadTokenProvider, AadHttpClientFactory, A
|
|
|
7
7
|
export interface WidgetContext {
|
|
8
8
|
/**
|
|
9
9
|
* Metadata and functions in the context of a widget instance. A widget instance
|
|
10
|
-
* is a single and specific widget that a user has on
|
|
10
|
+
* is a single and specific widget that a user has on their board. It has its own
|
|
11
11
|
* unique ID and possibly configuration data if the widget is configurable by the user
|
|
12
12
|
*/
|
|
13
13
|
instance: WidgetInstanceContext;
|
|
14
14
|
/**
|
|
15
|
-
* Metadata and functions in the context of a widget
|
|
16
|
-
* is a single and specific widget that a user has
|
|
17
|
-
* unique ID and possibly configuration data if the widget is configurable by the user
|
|
15
|
+
* Metadata and functions in the context of a widget buddy. A widget buddy
|
|
16
|
+
* is a single and specific widget instance that a user has in their buddy bar.
|
|
18
17
|
*/
|
|
19
|
-
buddy
|
|
18
|
+
buddy?: WidgetBuddyContext;
|
|
20
19
|
/**
|
|
21
20
|
* Metadata and functions in the context of a widget's variant (fka definition). A widget variant is
|
|
22
21
|
* a widget that's been installed by an administrator from within the board administration.
|
|
@@ -357,9 +356,10 @@ export interface WidgetInstanceContext {
|
|
|
357
356
|
}
|
|
358
357
|
export interface WidgetBuddyContext {
|
|
359
358
|
/**
|
|
360
|
-
* Allows
|
|
359
|
+
* Allows updating the badge properties of the buddy, e.g. its visibility, count or color.
|
|
360
|
+
* This will only override the provided properties.
|
|
361
361
|
*/
|
|
362
|
-
|
|
362
|
+
updateBadgeProperties: (props: Partial<BadgeProperties>) => void;
|
|
363
363
|
}
|
|
364
364
|
/**
|
|
365
365
|
* Widget variant context providing metadata and functionality offered by the widget board. A widget variant is
|
package/package.json
CHANGED