@bluealba/pae-ui-react-core 4.0.1-develop-1260 → 4.0.1-develop-1291

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.
@@ -14,5 +14,7 @@ export type ApplicationMenuItem = {
14
14
  operations?: string[];
15
15
  items?: AplicationMenuSubItem[];
16
16
  canCollapse?: boolean;
17
+ externalUrl?: string;
18
+ target?: '_self' | '_blank';
17
19
  };
18
20
  export type ApplicationMenu = ApplicationMenuItem[];
@@ -1,6 +1,5 @@
1
- import { ApplicationMenu } from './ApplicationMenu';
2
1
  import { PlatformApplication } from './PlatformApplication';
3
- import { Operation } from '@bluealba/pae-core';
2
+ import { ApplicationMenu } from './ApplicationMenu';
4
3
 
5
4
  type UseApplicationMenuReturnType = {
6
5
  loading: boolean;
@@ -8,4 +7,3 @@ type UseApplicationMenuReturnType = {
8
7
  };
9
8
  export declare const useApplicationMenu: (application: PlatformApplication | undefined) => UseApplicationMenuReturnType;
10
9
  export default useApplicationMenu;
11
- export declare const hasAccess: (authorizedOperations: Operation[]) => (operations: string[]) => boolean;
@@ -0,0 +1,11 @@
1
+ import { Operation } from '@bluealba/pae-core';
2
+ import { ApplicationMenu } from './ApplicationMenu';
3
+ import { PlatformApplication } from './PlatformApplication';
4
+
5
+ type UseModuleMenuReturnType = {
6
+ loading: boolean;
7
+ menu: ApplicationMenu;
8
+ };
9
+ export declare const useModuleMenu: (application: PlatformApplication | undefined) => UseModuleMenuReturnType;
10
+ export default useModuleMenu;
11
+ export declare const hasAccess: (authorizedOperations: Operation[]) => (operations: string[]) => boolean;
@@ -12,6 +12,7 @@ export { useApplications } from './applications/useApplications';
12
12
  export { useUIApplications } from './useUIApplications';
13
13
  export { useApplicationUIModule } from './applications/useApplicationUIModule';
14
14
  export { useApplicationIcon } from './applications/useApplicationIcon';
15
+ export { useModuleMenu } from './applications/useModuleMenu';
15
16
  export { useApplicationMenu } from './applications/useApplicationMenu';
16
17
  export { useCurrentApplicationName } from './applications/useCurrentApplicationName';
17
18
  export { useApplicationJSModule } from './applications/useApplicationJSModule';
@@ -10,3 +10,4 @@ export { default as initializeMicroFrontend } from './utils/initializeMicroFront
10
10
  export * from './MicrofrontendProps';
11
11
  export { setupTestEnvironment } from './test-utils/setupTestEnvironment';
12
12
  export * from './feature-flags';
13
+ export * from './rooms';
@@ -0,0 +1,12 @@
1
+ import { default as React } from 'react';
2
+ import { RoomUser } from '../types/rooms.types';
3
+
4
+ export interface RoomAvatarsProps {
5
+ users: RoomUser[];
6
+ maxVisible?: number;
7
+ size?: 'sm' | 'md' | 'lg';
8
+ overlap?: boolean;
9
+ className?: string;
10
+ onUserClick?: (user: RoomUser) => void;
11
+ }
12
+ export declare const RoomAvatars: React.FC<RoomAvatarsProps>;
@@ -0,0 +1,9 @@
1
+ import { ConnectionStatus, RoomUser } from '../types/rooms.types';
2
+
3
+ export interface RoomsContextValue {
4
+ status: ConnectionStatus;
5
+ joinRoom: (roomId: string) => void;
6
+ leaveRoom: (roomId: string) => void;
7
+ getRoomUsers: (roomId: string) => RoomUser[];
8
+ }
9
+ export declare const RoomsContext: import('react').Context<RoomsContextValue | null>;
@@ -0,0 +1,6 @@
1
+ import { RoomUser } from '../types/rooms.types';
2
+
3
+ export interface UseRoomReturn {
4
+ users: RoomUser[];
5
+ }
6
+ export declare function useRoom(roomId: string): UseRoomReturn;
@@ -0,0 +1,5 @@
1
+ export * from './types/rooms.types';
2
+ export * from './providers/RoomsProvider';
3
+ export * from './hooks/useRoom';
4
+ export * from './components/RoomAvatars';
5
+ export * from './utils/user-color.utils';
@@ -0,0 +1,6 @@
1
+ import { default as React } from 'react';
2
+
3
+ export interface RoomsProviderProps {
4
+ children: React.ReactNode;
5
+ }
6
+ export declare const RoomsProvider: React.FC<RoomsProviderProps>;
@@ -0,0 +1,7 @@
1
+ export type ConnectionStatus = 'loading' | 'connected' | 'closed' | 'error';
2
+ export interface RoomUser {
3
+ username: string;
4
+ displayName: string;
5
+ rooms: string[];
6
+ color?: string;
7
+ }
@@ -0,0 +1,5 @@
1
+ export declare const ROOMS_EVENTS: {
2
+ JOIN_ROOM: string;
3
+ LEAVE_ROOM: string;
4
+ USER_LIST: string;
5
+ };
@@ -0,0 +1 @@
1
+ export declare function generateUserColor(userId: string): string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bluealba/pae-ui-react-core",
3
- "version": "4.0.1-develop-1260",
3
+ "version": "4.0.1-develop-1291",
4
4
  "type": "module",
5
5
  "main": "./dist/index.cjs.js",
6
6
  "module": "./dist/index.esm.js",