@unisphere/genie-types 1.37.1 → 1.38.3

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/index.esm.js CHANGED
@@ -1515,6 +1515,11 @@ const chatCustomizationSchema = {
1515
1515
  type: 'primitive',
1516
1516
  value: 'boolean',
1517
1517
  optional: true
1518
+ },
1519
+ linkTarget: {
1520
+ type: 'primitive',
1521
+ value: 'string',
1522
+ optional: true
1518
1523
  }
1519
1524
  }
1520
1525
  },
@@ -1637,6 +1642,33 @@ const chatCustomizationSchema = {
1637
1642
  }
1638
1643
  }
1639
1644
  },
1645
+ uiControls: {
1646
+ type: 'object',
1647
+ optional: true,
1648
+ allowUnknownProperties: true,
1649
+ properties: {
1650
+ modalSelector: {
1651
+ type: 'object',
1652
+ optional: true,
1653
+ properties: {
1654
+ visible: {
1655
+ type: 'primitive',
1656
+ value: 'boolean'
1657
+ }
1658
+ }
1659
+ },
1660
+ contextSelector: {
1661
+ type: 'object',
1662
+ optional: true,
1663
+ properties: {
1664
+ visible: {
1665
+ type: 'primitive',
1666
+ value: 'boolean'
1667
+ }
1668
+ }
1669
+ }
1670
+ }
1671
+ },
1640
1672
  thread: {
1641
1673
  type: 'object',
1642
1674
  optional: true,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@unisphere/genie-types",
3
- "version": "1.37.1",
3
+ "version": "1.38.3",
4
4
  "author": "kaltura",
5
5
  "license": "AGPL-3.0",
6
6
  "repository": {
@@ -3,6 +3,7 @@ import { UnisphereRuntimeBaseType } from '@unisphere/runtime';
3
3
  import { widgetName } from '../widget-types';
4
4
  import { ChatContext, GenieCapabilities } from '../chat-runtime/shared-settings';
5
5
  import { AgentScreenShareInfo, AgentTapToTalkInfo, AvatarConnectionStatus, CaptionConfig, CaptionState } from './shared-types';
6
+ import { ChatEntry } from './chat-types';
6
7
  /** Runtime name constant for avatar experiences */
7
8
  export declare const AvatarRuntimeName: "avatar";
8
9
  export interface Captions {
@@ -78,6 +79,8 @@ export type AvatarRuntime = UnisphereRuntimeBaseType<AvatarRuntimeSettings> & {
78
79
  setThreadId(id: string | null): void;
79
80
  /** Sync preview mode flag from the chat customization settings */
80
81
  setIsPreviewMode(value: boolean): void;
82
+ /** Sync context selector visibility from the chat customization settings */
83
+ setContextSelectorVisible(value: boolean): void;
81
84
  /** Observable mute state */
82
85
  isMuted: TinyDataStoreConsumer<boolean>;
83
86
  /** Mute the avatar audio */
@@ -88,6 +91,8 @@ export type AvatarRuntime = UnisphereRuntimeBaseType<AvatarRuntimeSettings> & {
88
91
  askViaText(question: string): void;
89
92
  /** Update dynamic variables */
90
93
  updateDynamicVariables(variables: Record<string, unknown>): void;
94
+ /** Observable chat log entries */
95
+ chatLog: TinyDataStoreConsumer<ChatEntry[]>;
91
96
  };
92
97
  /** Event emitted when the avatar brain invokes a tool call */
93
98
  export interface AvatarToolCallEvent {
@@ -410,6 +410,9 @@ export interface AvatarClientManagerType {
410
410
  /** Observable preview mode flag */
411
411
  readonly isPreviewMode: TinyDataStoreConsumer<boolean>;
412
412
  setIsPreviewMode(value: boolean): void;
413
+ /** Observable context selector visibility */
414
+ readonly contextSelectorVisible: TinyDataStoreConsumer<boolean>;
415
+ setContextSelectorVisible(value: boolean): void;
413
416
  /** Observable feature flags from runtime settings */
414
417
  readonly features: TinyDataStoreConsumer<{
415
418
  screenShare?: boolean;
@@ -46,6 +46,8 @@ export interface ChatCustomization {
46
46
  useExternalPlayer?: boolean;
47
47
  /** Indicates genie is embedded inside Kaltura Studio (preview mode) */
48
48
  isPreviewMode?: boolean;
49
+ /** Target attribute for links rendered in markdown content (defaults to '_blank') */
50
+ linkTarget?: string;
49
51
  };
50
52
  /** New conversation thread settings
51
53
  * @deprecated
@@ -83,6 +85,17 @@ export interface ChatCustomization {
83
85
  } | {
84
86
  stage: 'fullscreen';
85
87
  };
88
+ /** UI controls visibility */
89
+ uiControls?: {
90
+ /** Show/hide the AI model selector (Fast/Smart). Default: true */
91
+ modalSelector?: {
92
+ visible: boolean;
93
+ };
94
+ /** Show/hide the context selector chip and add-context button. Default: true */
95
+ contextSelector?: {
96
+ visible: boolean;
97
+ };
98
+ };
86
99
  /** thread configuration */
87
100
  thread?: {
88
101
  /** enabled by default */
@@ -151,7 +151,10 @@ export interface GlobalChatSettings {
151
151
  type?: 'entry';
152
152
  entryId: string;
153
153
  startTime?: number;
154
- }) => string;
154
+ }) => string | {
155
+ url: string;
156
+ target: string;
157
+ };
155
158
  /** Configuration for conversation sharing */
156
159
  shareUrl?: {
157
160
  /** Query parameter name for message ID in shared URLs */
@@ -16,5 +16,8 @@ export interface ChatThreadServiceType extends UnisphereService {
16
16
  type?: 'entry';
17
17
  entryId: string;
18
18
  startTime?: number;
19
- }) => string;
19
+ }) => string | {
20
+ url: string;
21
+ target: string;
22
+ };
20
23
  }
@@ -38,7 +38,10 @@ export interface GenieChatServiceType extends UnisphereService {
38
38
  /** Generate poster/thumbnail URL for video clip */
39
39
  getClipPlayerPosterUrl: (source: ClassGenieGetClipPlayerPosterUrlData) => string;
40
40
  /** Generate source URL for media entry with optional start time */
41
- getEntrySourceUrl: (entryId: string, startTime?: number) => string;
41
+ getEntrySourceUrl: (entryId: string, startTime?: number) => string | {
42
+ url: string;
43
+ target: string;
44
+ };
42
45
  /** Observable for submitting questions and getting AI answers */
43
46
  getAnswer: TinyPubSub<{
44
47
  /** Question text to ask */