@uxland/primary-shell 7.15.0 → 7.15.2
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/dist/{component-RL8LM9a9.js → component-DXLFP7Cq.js} +2 -2
- package/dist/{component-RL8LM9a9.js.map → component-DXLFP7Cq.js.map} +1 -1
- package/dist/{index-cueNwNYW.js → index-CHxcmbqZ.js} +741 -755
- package/dist/index-CHxcmbqZ.js.map +1 -0
- package/dist/index.js +1 -1
- package/dist/index.umd.cjs +18 -18
- package/dist/index.umd.cjs.map +1 -1
- package/dist/primary/shell/src/api/broker/broker-events.d.ts +8 -0
- package/dist/primary/shell/src/api/broker/primaria-broker.d.ts +2 -0
- package/package.json +1 -1
- package/src/UI/components/primaria-shell/shell-header/styles.css +0 -3
- package/src/UI/components/primaria-shell/styles.css +0 -4
- package/src/api/broker/broker-events.ts +9 -0
- package/src/api/broker/factory.ts +2 -0
- package/src/api/broker/primaria-broker.ts +4 -1
- package/dist/index-cueNwNYW.js.map +0 -1
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Diccionari centralitzat d'events del broker.
|
|
3
|
+
*/
|
|
4
|
+
export declare const BROKER_EVENTS: {
|
|
5
|
+
readonly refreshHistoryDataRequested: "refresh_history_data_requested";
|
|
6
|
+
readonly errorLoadingActivityHistoryData: "error_loading_activity_history_data";
|
|
7
|
+
};
|
|
8
|
+
export type BrokerEvents = typeof BROKER_EVENTS;
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import { HarmonixBroker } from '@uxland/harmonix';
|
|
2
|
+
import { BrokerEvents } from './broker-events';
|
|
2
3
|
export interface PrimariaBroker extends HarmonixBroker {
|
|
4
|
+
events: BrokerEvents;
|
|
3
5
|
}
|
|
4
6
|
export type { HarmonixBroker, IEvent, IEventClass, IRequest, IRequestClass, } from '@uxland/harmonix';
|
|
5
7
|
export type { BrokerDisposableHandler } from '@uxland/harmonix';
|
package/package.json
CHANGED
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Diccionari centralitzat d'events del broker.
|
|
3
|
+
*/
|
|
4
|
+
export const BROKER_EVENTS = {
|
|
5
|
+
refreshHistoryDataRequested: "refresh_history_data_requested",
|
|
6
|
+
errorLoadingActivityHistoryData: "error_loading_activity_history_data",
|
|
7
|
+
} as const;
|
|
8
|
+
|
|
9
|
+
export type BrokerEvents = typeof BROKER_EVENTS;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { IEvent, IEventClass, IRequest, IRequestClass } from "@uxland/harmonix";
|
|
2
2
|
import { Mediator, mediatorSettings, notificationHandler, requestHandler } from "mediatr-ts";
|
|
3
|
+
import { BROKER_EVENTS } from "./broker-events";
|
|
3
4
|
import { type PrimariaBroker, type BrokerDisposableHandler } from "./primaria-broker";
|
|
4
5
|
|
|
5
6
|
type messageHandler = (payload: unknown) => unknown | Promise<unknown>;
|
|
@@ -17,6 +18,7 @@ const disposableFactory = (handler: any) => {
|
|
|
17
18
|
};
|
|
18
19
|
};
|
|
19
20
|
class Broker implements PrimariaBroker {
|
|
21
|
+
public readonly events = BROKER_EVENTS;
|
|
20
22
|
private mediator: Mediator;
|
|
21
23
|
constructor() {
|
|
22
24
|
this.mediator = new Mediator();
|
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
import { HarmonixBroker } from "@uxland/harmonix";
|
|
2
|
+
import { type BrokerEvents } from "./broker-events";
|
|
2
3
|
|
|
3
|
-
export interface PrimariaBroker extends HarmonixBroker {
|
|
4
|
+
export interface PrimariaBroker extends HarmonixBroker {
|
|
5
|
+
events: BrokerEvents;
|
|
6
|
+
}
|
|
4
7
|
|
|
5
8
|
export type {
|
|
6
9
|
HarmonixBroker,
|