@arsedizioni/ars-utils 21.2.355 → 21.2.357

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@arsedizioni/ars-utils",
3
- "version": "21.2.355",
3
+ "version": "21.2.357",
4
4
  "author": {
5
5
  "email": "software@arsedizioni.it",
6
6
  "name": "Fabio Buscaroli, Alberto Doria"
@@ -1010,7 +1010,7 @@ interface BroadcastChannelMessageBag<T> {
1010
1010
  /** Unique identifier for the message type. */
1011
1011
  messageId: string;
1012
1012
  /** Identifier of the sender. */
1013
- sender: string;
1013
+ sender?: string;
1014
1014
  /** Optional typed data attached to the message. */
1015
1015
  data?: T;
1016
1016
  }
@@ -1115,7 +1115,7 @@ declare class BroadcastService implements OnDestroy {
1115
1115
  * Useful when a caller needs direct channel access outside the service.
1116
1116
  * @returns A new `BroadcastChannelManager` connected to `'ARS-CHANNEL'`.
1117
1117
  */
1118
- static GetChannel(): BroadcastChannelManager;
1118
+ static createChannel(): BroadcastChannelManager;
1119
1119
  ngOnDestroy(): void;
1120
1120
  /**
1121
1121
  * Publishes a message to the in-process subject, optionally after a delay.
@@ -1137,6 +1137,11 @@ declare class BroadcastService implements OnDestroy {
1137
1137
  * @param action - Callback invoked with the full `BroadcastChannelMessageBag` when a matching message arrives.
1138
1138
  */
1139
1139
  subscribeChannelMessage<T>(id: string, action: (bag: BroadcastChannelMessageBag<T>) => void): void;
1140
+ /**
1141
+ * Removes the channel subscription previously registered for the given `id`, if any.
1142
+ * @param id - The message type identifier whose subscription should be removed.
1143
+ */
1144
+ unsubscribeChannelMessage(id: string): void;
1140
1145
  /**
1141
1146
  * Returns an `Observable` that emits every in-process message published via `sendMessage`.
1142
1147
  * @returns An observable stream of `BroadcastMessageInfo` objects.