@helpai/elements 0.59.2 → 0.59.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/configurator.mjs +10 -10
- package/elements-web-component.esm.js +17 -17
- package/elements-web-component.esm.js.map +3 -3
- package/elements.cjs.js +17 -17
- package/elements.cjs.js.map +3 -3
- package/elements.esm.js +17 -17
- package/elements.esm.js.map +3 -3
- package/elements.js +17 -17
- package/elements.js.map +3 -3
- package/index.d.ts +7 -7
- package/index.mjs +14 -15
- package/package.json +1 -1
- package/schema.d.ts +34 -34
- package/schema.json +30 -34
- package/schema.mjs +10 -10
- package/web-component.mjs +14 -15
package/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { A as Asset, B as BlocksConfig, C as ConnectionConfig, a as ConnectionConfigPartial, H as HandshakeResponse, L as Link, S as ServerConfig, b as SiteConfig, W as WidgetConfig, c as WidgetConfigPartial, d as WidgetSettings, e as WidgetSettingsPartial } from './deployment-
|
|
1
|
+
export { A as Asset, B as BlocksConfig, C as ConnectionConfig, a as ConnectionConfigPartial, H as HandshakeResponse, L as Link, S as ServerConfig, b as SiteConfig, W as WidgetConfig, c as WidgetConfigPartial, d as WidgetSettings, e as WidgetSettingsPartial } from './deployment-Crtq-vQg.js';
|
|
2
2
|
import 'zod';
|
|
3
3
|
|
|
4
4
|
/**
|
|
@@ -319,7 +319,7 @@ interface FeatureFlags {
|
|
|
319
319
|
* approve/reject controls for gated tools. Default `true`. Set `false` to
|
|
320
320
|
* suppress them (the wire still carries the signals; they just won't show).
|
|
321
321
|
*/
|
|
322
|
-
|
|
322
|
+
disableHumanInLoop?: boolean;
|
|
323
323
|
}
|
|
324
324
|
/**
|
|
325
325
|
* Client-side attachment limits. Server enforcement is still required —
|
|
@@ -697,11 +697,11 @@ interface ModuleStatus {
|
|
|
697
697
|
*/
|
|
698
698
|
interface HomeConfig {
|
|
699
699
|
brandName?: string;
|
|
700
|
-
|
|
700
|
+
hideGreeting?: boolean;
|
|
701
701
|
greetingText?: string;
|
|
702
702
|
userAvatars?: ModuleAvatar[];
|
|
703
|
-
|
|
704
|
-
|
|
703
|
+
hideSearchBar?: boolean;
|
|
704
|
+
hideRecentConversations?: boolean;
|
|
705
705
|
status?: ModuleStatus;
|
|
706
706
|
contentBlockTitle?: string;
|
|
707
707
|
}
|
|
@@ -849,8 +849,8 @@ interface BehaviorOptions {
|
|
|
849
849
|
showSources?: boolean;
|
|
850
850
|
/** Fade the message list at its scroll edges (gradient mask). Default `true`. */
|
|
851
851
|
scrollFade?: boolean;
|
|
852
|
-
/**
|
|
853
|
-
|
|
852
|
+
/** Turn OFF the 👍/👎 feedback controls on assistant replies. Unset/`false` = shown (default). */
|
|
853
|
+
disableMessageFeedback?: boolean;
|
|
854
854
|
}
|
|
855
855
|
/**
|
|
856
856
|
* Section: panel header actions — the enabled set (`history`/`close` buttons +
|
package/index.mjs
CHANGED
|
@@ -29,7 +29,7 @@ var BRAND = {
|
|
|
29
29
|
};
|
|
30
30
|
|
|
31
31
|
// src/core/version.ts
|
|
32
|
-
var ELEMENTS_VERSION = true ? "0.59.
|
|
32
|
+
var ELEMENTS_VERSION = true ? "0.59.3" : "0.0.0-dev";
|
|
33
33
|
var ELEMENTS_VERSION_PARAM = "_ev";
|
|
34
34
|
|
|
35
35
|
// src/i18n/strings.ts
|
|
@@ -1031,7 +1031,7 @@ var DEFAULT_ATTACHMENTS = {
|
|
|
1031
1031
|
var DEFAULT_FEATURES = {
|
|
1032
1032
|
files: true,
|
|
1033
1033
|
voice: "local",
|
|
1034
|
-
|
|
1034
|
+
disableHumanInLoop: false
|
|
1035
1035
|
};
|
|
1036
1036
|
var DEFAULT_FORMS = { list: [], byTrigger: {} };
|
|
1037
1037
|
var DEFAULT_TRACKING = {
|
|
@@ -1068,7 +1068,6 @@ var DEFAULT_HAPTICS = {
|
|
|
1068
1068
|
events: void 0
|
|
1069
1069
|
};
|
|
1070
1070
|
var DEFAULT_MODULES = [{ label: "tabConversations", layout: "chat" }];
|
|
1071
|
-
var DEFAULT_HOME_MODULE = { showSearchBar: true };
|
|
1072
1071
|
|
|
1073
1072
|
// src/core/config/resolve.ts
|
|
1074
1073
|
function resolveOptions(rawOpts) {
|
|
@@ -1108,11 +1107,11 @@ function resolveOptions(rawOpts) {
|
|
|
1108
1107
|
showToolCalls: behavior.showToolCalls ?? false,
|
|
1109
1108
|
showSources: behavior.showSources ?? false,
|
|
1110
1109
|
scrollFade: behavior.scrollFade ?? true,
|
|
1111
|
-
enableMessageFeedback: behavior.
|
|
1110
|
+
enableMessageFeedback: !(behavior.disableMessageFeedback ?? false),
|
|
1112
1111
|
features: {
|
|
1113
1112
|
files: opts.features?.files ?? DEFAULT_FEATURES.files,
|
|
1114
1113
|
voice: opts.features?.voice ?? DEFAULT_FEATURES.voice,
|
|
1115
|
-
|
|
1114
|
+
disableHumanInLoop: opts.features?.disableHumanInLoop ?? false,
|
|
1116
1115
|
tools: opts.features?.tools
|
|
1117
1116
|
},
|
|
1118
1117
|
forms: resolveForms(opts.forms, locale),
|
|
@@ -1226,9 +1225,9 @@ function resolveModules(overrides) {
|
|
|
1226
1225
|
if (m.layout === "home") {
|
|
1227
1226
|
resolved.brandName = m.brandName;
|
|
1228
1227
|
resolved.greetingText = m.greetingText;
|
|
1229
|
-
resolved.
|
|
1230
|
-
resolved.
|
|
1231
|
-
resolved.
|
|
1228
|
+
resolved.hideGreeting = m.hideGreeting ?? false;
|
|
1229
|
+
resolved.hideSearchBar = m.hideSearchBar ?? false;
|
|
1230
|
+
resolved.hideRecentConversations = m.hideRecentConversations ?? false;
|
|
1232
1231
|
if (m.userAvatars && m.userAvatars.length > 0) resolved.userAvatars = m.userAvatars;
|
|
1233
1232
|
if (m.status) resolved.status = m.status;
|
|
1234
1233
|
resolved.contentBlockTitle = m.contentBlockTitle;
|
|
@@ -1438,7 +1437,7 @@ var BEHAVIOR_ATTRS = [
|
|
|
1438
1437
|
["show-tool-calls", "showToolCalls", boolAttr],
|
|
1439
1438
|
["show-sources", "showSources", boolAttr],
|
|
1440
1439
|
["scroll-fade", "scrollFade", boolAttr],
|
|
1441
|
-
["
|
|
1440
|
+
["disable-message-feedback", "disableMessageFeedback", boolAttr]
|
|
1442
1441
|
];
|
|
1443
1442
|
var I18N_ATTRS = [["locale", "locale"]];
|
|
1444
1443
|
var ACTION_NAMES = new Set(ACTION_NAME_LITERALS);
|
|
@@ -7601,13 +7600,13 @@ function HomeRoot(props2) {
|
|
|
7601
7600
|
const [content, setContent] = useState12([]);
|
|
7602
7601
|
const tagsKey = config.contentTags?.join(",");
|
|
7603
7602
|
useEffect11(() => {
|
|
7604
|
-
if (
|
|
7603
|
+
if (config.hideRecentConversations) return;
|
|
7605
7604
|
let cancelled = false;
|
|
7606
7605
|
transport.listConversations({ limit: 1 }).then((res) => !cancelled && setRecent(res.conversations?.[0] ?? null)).catch((err) => !cancelled && log14.warn("listConversations (home) failed", { err }));
|
|
7607
7606
|
return () => {
|
|
7608
7607
|
cancelled = true;
|
|
7609
7608
|
};
|
|
7610
|
-
}, [transport, config.
|
|
7609
|
+
}, [transport, config.hideRecentConversations]);
|
|
7611
7610
|
useEffect11(() => {
|
|
7612
7611
|
if (!config.contentTags?.length) return;
|
|
7613
7612
|
let cancelled = false;
|
|
@@ -7635,13 +7634,13 @@ function HomeRoot(props2) {
|
|
|
7635
7634
|
/* @__PURE__ */ jsx32(HeaderActions, { panelProps, variant: "plain" })
|
|
7636
7635
|
] })
|
|
7637
7636
|
] }),
|
|
7638
|
-
config.
|
|
7637
|
+
!config.hideGreeting ? /* @__PURE__ */ jsxs26(Fragment7, { children: [
|
|
7639
7638
|
/* @__PURE__ */ jsx32("h1", { class: `${p28}-home-greeting`, "data-testid": TID.homeGreeting, children: greeting.title }),
|
|
7640
7639
|
greeting.subtitle ? /* @__PURE__ */ jsx32("p", { class: `${p28}-home-lead`, children: greeting.subtitle }) : null
|
|
7641
7640
|
] }) : null
|
|
7642
7641
|
] }),
|
|
7643
7642
|
/* @__PURE__ */ jsxs26("div", { class: `${p28}-home-cards`, children: [
|
|
7644
|
-
config.
|
|
7643
|
+
!config.hideSearchBar ? /* @__PURE__ */ jsx32(
|
|
7645
7644
|
HomeSearchButton,
|
|
7646
7645
|
{
|
|
7647
7646
|
placeholder: strings.homeSearchPlaceholder,
|
|
@@ -8794,12 +8793,12 @@ function App({ options, hostElement, bus }) {
|
|
|
8794
8793
|
);
|
|
8795
8794
|
const toolInteraction = useMemo3(
|
|
8796
8795
|
() => ({
|
|
8797
|
-
humanInLoop: options.features.
|
|
8796
|
+
humanInLoop: !options.features.disableHumanInLoop,
|
|
8798
8797
|
onResult: handleToolResult,
|
|
8799
8798
|
onDecision: handleToolDecision,
|
|
8800
8799
|
onEdit: handleToolEdit
|
|
8801
8800
|
}),
|
|
8802
|
-
[options.features.
|
|
8801
|
+
[options.features.disableHumanInLoop, handleToolResult, handleToolDecision, handleToolEdit]
|
|
8803
8802
|
);
|
|
8804
8803
|
const userMessageCount = () => messagesSig.value.reduce((n, m) => n + (m.role === "user" ? 1 : 0), 0);
|
|
8805
8804
|
const effectiveForms = options.forms.list.length > 0 ? options.forms : remoteForms ?? options.forms;
|
package/package.json
CHANGED
package/schema.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { A as Asset, B as BlocksConfig, C as ConnectionConfig, a as ConnectionConfigPartial, E as Endpoints, H as HandshakeResponse, L as Link, P as PAGE_AREA_SUGGESTIONS, f as PageContext, S as ServerConfig, b as SiteConfig, U as UserContext, W as WidgetConfig, c as WidgetConfigPartial, d as WidgetSettings, e as WidgetSettingsPartial, g as assetSchema, h as blocksConfigSchema, i as connectionConfigPartialSchema, j as connectionConfigSchema, k as cssColorSchema, l as cssLengthSchema, m as endpointsSchema, n as handshakeResponseSchema, o as linkSchema, p as localeSchema, q as pageContextSchema, s as serverConfigSchema, r as siteConfigSchema, u as userContextSchema, t as uuid7Schema, w as widgetConfigPartialSchema, v as widgetConfigSchema, x as widgetSettingsPartialSchema, y as widgetSettingsSchema } from './deployment-
|
|
1
|
+
export { A as Asset, B as BlocksConfig, C as ConnectionConfig, a as ConnectionConfigPartial, E as Endpoints, H as HandshakeResponse, L as Link, P as PAGE_AREA_SUGGESTIONS, f as PageContext, S as ServerConfig, b as SiteConfig, U as UserContext, W as WidgetConfig, c as WidgetConfigPartial, d as WidgetSettings, e as WidgetSettingsPartial, g as assetSchema, h as blocksConfigSchema, i as connectionConfigPartialSchema, j as connectionConfigSchema, k as cssColorSchema, l as cssLengthSchema, m as endpointsSchema, n as handshakeResponseSchema, o as linkSchema, p as localeSchema, q as pageContextSchema, s as serverConfigSchema, r as siteConfigSchema, u as userContextSchema, t as uuid7Schema, w as widgetConfigPartialSchema, v as widgetConfigSchema, x as widgetSettingsPartialSchema, y as widgetSettingsSchema } from './deployment-Crtq-vQg.js';
|
|
2
2
|
import { z } from 'zod';
|
|
3
3
|
|
|
4
4
|
/**
|
|
@@ -56,9 +56,9 @@ declare const presentationSchema: z.ZodObject<{
|
|
|
56
56
|
inset: z.ZodOptional<z.ZodString>;
|
|
57
57
|
initialSize: z.ZodDefault<z.ZodEnum<{
|
|
58
58
|
fullscreen: "fullscreen";
|
|
59
|
-
normal: "normal";
|
|
60
59
|
expanded: "expanded";
|
|
61
60
|
auto: "auto";
|
|
61
|
+
normal: "normal";
|
|
62
62
|
}>>;
|
|
63
63
|
autoSizeBreakpoint: z.ZodDefault<z.ZodNumber>;
|
|
64
64
|
}, z.core.$loose>>;
|
|
@@ -85,7 +85,7 @@ declare const behaviorSchema: z.ZodObject<{
|
|
|
85
85
|
showToolCalls: z.ZodDefault<z.ZodBoolean>;
|
|
86
86
|
showSources: z.ZodDefault<z.ZodBoolean>;
|
|
87
87
|
scrollFade: z.ZodDefault<z.ZodBoolean>;
|
|
88
|
-
|
|
88
|
+
disableMessageFeedback: z.ZodDefault<z.ZodBoolean>;
|
|
89
89
|
}, z.core.$loose>;
|
|
90
90
|
type Behavior = z.infer<typeof behaviorSchema>;
|
|
91
91
|
|
|
@@ -242,9 +242,9 @@ type LauncherOptions = z.infer<typeof launcherOptionsSchema>;
|
|
|
242
242
|
|
|
243
243
|
declare const initialSizeSchema: z.ZodEnum<{
|
|
244
244
|
fullscreen: "fullscreen";
|
|
245
|
-
normal: "normal";
|
|
246
245
|
expanded: "expanded";
|
|
247
246
|
auto: "auto";
|
|
247
|
+
normal: "normal";
|
|
248
248
|
}>;
|
|
249
249
|
declare const resizeOptionsSchema: z.ZodObject<{
|
|
250
250
|
enabled: z.ZodDefault<z.ZodBoolean>;
|
|
@@ -271,9 +271,9 @@ declare const sizeOptionsSchema: z.ZodObject<{
|
|
|
271
271
|
inset: z.ZodOptional<z.ZodString>;
|
|
272
272
|
initialSize: z.ZodDefault<z.ZodEnum<{
|
|
273
273
|
fullscreen: "fullscreen";
|
|
274
|
-
normal: "normal";
|
|
275
274
|
expanded: "expanded";
|
|
276
275
|
auto: "auto";
|
|
276
|
+
normal: "normal";
|
|
277
277
|
}>>;
|
|
278
278
|
autoSizeBreakpoint: z.ZodDefault<z.ZodNumber>;
|
|
279
279
|
}, z.core.$loose>;
|
|
@@ -308,7 +308,7 @@ declare const featureFlagsSchema: z.ZodObject<{
|
|
|
308
308
|
code: z.ZodString;
|
|
309
309
|
config: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
310
310
|
}, z.core.$loose>]>>>;
|
|
311
|
-
|
|
311
|
+
disableHumanInLoop: z.ZodDefault<z.ZodBoolean>;
|
|
312
312
|
}, z.core.$loose>;
|
|
313
313
|
type FeatureFlags = z.infer<typeof featureFlagsSchema>;
|
|
314
314
|
|
|
@@ -325,40 +325,40 @@ type FeatureFlags = z.infer<typeof featureFlagsSchema>;
|
|
|
325
325
|
*/
|
|
326
326
|
|
|
327
327
|
declare const actionNameSchema: z.ZodEnum<{
|
|
328
|
+
close: "close";
|
|
328
329
|
expand: "expand";
|
|
329
330
|
fullscreen: "fullscreen";
|
|
330
|
-
|
|
331
|
-
language: "language";
|
|
331
|
+
clear: "clear";
|
|
332
332
|
theme: "theme";
|
|
333
|
+
language: "language";
|
|
333
334
|
textSize: "textSize";
|
|
334
335
|
history: "history";
|
|
335
|
-
clear: "clear";
|
|
336
336
|
sound: "sound";
|
|
337
337
|
}>;
|
|
338
338
|
type ActionName = z.infer<typeof actionNameSchema>;
|
|
339
339
|
declare const headerActionsSchema: z.ZodArray<z.ZodEnum<{
|
|
340
|
+
close: "close";
|
|
340
341
|
expand: "expand";
|
|
341
342
|
fullscreen: "fullscreen";
|
|
342
|
-
|
|
343
|
-
language: "language";
|
|
343
|
+
clear: "clear";
|
|
344
344
|
theme: "theme";
|
|
345
|
+
language: "language";
|
|
345
346
|
textSize: "textSize";
|
|
346
347
|
history: "history";
|
|
347
|
-
clear: "clear";
|
|
348
348
|
sound: "sound";
|
|
349
349
|
}>>;
|
|
350
350
|
type HeaderActions = z.infer<typeof headerActionsSchema>;
|
|
351
351
|
/** Section wrapper — `actions` list wrapped under `header` in the dashboard form. */
|
|
352
352
|
declare const headerSchema: z.ZodObject<{
|
|
353
353
|
actions: z.ZodOptional<z.ZodArray<z.ZodEnum<{
|
|
354
|
+
close: "close";
|
|
354
355
|
expand: "expand";
|
|
355
356
|
fullscreen: "fullscreen";
|
|
356
|
-
|
|
357
|
-
language: "language";
|
|
357
|
+
clear: "clear";
|
|
358
358
|
theme: "theme";
|
|
359
|
+
language: "language";
|
|
359
360
|
textSize: "textSize";
|
|
360
361
|
history: "history";
|
|
361
|
-
clear: "clear";
|
|
362
362
|
sound: "sound";
|
|
363
363
|
}>>>;
|
|
364
364
|
}, z.core.$loose>;
|
|
@@ -374,33 +374,33 @@ type HeaderOptions = z.infer<typeof headerSchema>;
|
|
|
374
374
|
*/
|
|
375
375
|
|
|
376
376
|
declare const feedbackEventSchema: z.ZodEnum<{
|
|
377
|
+
voiceStart: "voiceStart";
|
|
378
|
+
voiceStop: "voiceStop";
|
|
377
379
|
error: "error";
|
|
378
380
|
messageReceived: "messageReceived";
|
|
379
381
|
messageSent: "messageSent";
|
|
380
|
-
voiceStart: "voiceStart";
|
|
381
|
-
voiceStop: "voiceStop";
|
|
382
382
|
}>;
|
|
383
383
|
type FeedbackEvent = z.infer<typeof feedbackEventSchema>;
|
|
384
384
|
declare const soundOptionsSchema: z.ZodObject<{
|
|
385
385
|
enabled: z.ZodDefault<z.ZodBoolean>;
|
|
386
386
|
volume: z.ZodDefault<z.ZodNumber>;
|
|
387
387
|
events: z.ZodOptional<z.ZodRecord<z.ZodEnum<{
|
|
388
|
+
voiceStart: "voiceStart";
|
|
389
|
+
voiceStop: "voiceStop";
|
|
388
390
|
error: "error";
|
|
389
391
|
messageReceived: "messageReceived";
|
|
390
392
|
messageSent: "messageSent";
|
|
391
|
-
voiceStart: "voiceStart";
|
|
392
|
-
voiceStop: "voiceStop";
|
|
393
393
|
}> & z.core.$partial, z.ZodUnion<readonly [z.ZodBoolean, z.ZodString]>>>;
|
|
394
394
|
}, z.core.$loose>;
|
|
395
395
|
type SoundOptions = z.infer<typeof soundOptionsSchema>;
|
|
396
396
|
declare const hapticsOptionsSchema: z.ZodObject<{
|
|
397
397
|
enabled: z.ZodDefault<z.ZodBoolean>;
|
|
398
398
|
events: z.ZodOptional<z.ZodRecord<z.ZodEnum<{
|
|
399
|
+
voiceStart: "voiceStart";
|
|
400
|
+
voiceStop: "voiceStop";
|
|
399
401
|
error: "error";
|
|
400
402
|
messageReceived: "messageReceived";
|
|
401
403
|
messageSent: "messageSent";
|
|
402
|
-
voiceStart: "voiceStart";
|
|
403
|
-
voiceStop: "voiceStop";
|
|
404
404
|
}> & z.core.$partial, z.ZodUnion<readonly [z.ZodBoolean, z.ZodNumber, z.ZodArray<z.ZodNumber>]>>>;
|
|
405
405
|
}, z.core.$loose>;
|
|
406
406
|
type HapticsOptions = z.infer<typeof hapticsOptionsSchema>;
|
|
@@ -409,21 +409,21 @@ declare const feedbackSchema: z.ZodObject<{
|
|
|
409
409
|
enabled: z.ZodDefault<z.ZodBoolean>;
|
|
410
410
|
volume: z.ZodDefault<z.ZodNumber>;
|
|
411
411
|
events: z.ZodOptional<z.ZodRecord<z.ZodEnum<{
|
|
412
|
+
voiceStart: "voiceStart";
|
|
413
|
+
voiceStop: "voiceStop";
|
|
412
414
|
error: "error";
|
|
413
415
|
messageReceived: "messageReceived";
|
|
414
416
|
messageSent: "messageSent";
|
|
415
|
-
voiceStart: "voiceStart";
|
|
416
|
-
voiceStop: "voiceStop";
|
|
417
417
|
}> & z.core.$partial, z.ZodUnion<readonly [z.ZodBoolean, z.ZodString]>>>;
|
|
418
418
|
}, z.core.$loose>>;
|
|
419
419
|
haptics: z.ZodOptional<z.ZodObject<{
|
|
420
420
|
enabled: z.ZodDefault<z.ZodBoolean>;
|
|
421
421
|
events: z.ZodOptional<z.ZodRecord<z.ZodEnum<{
|
|
422
|
+
voiceStart: "voiceStart";
|
|
423
|
+
voiceStop: "voiceStop";
|
|
422
424
|
error: "error";
|
|
423
425
|
messageReceived: "messageReceived";
|
|
424
426
|
messageSent: "messageSent";
|
|
425
|
-
voiceStart: "voiceStart";
|
|
426
|
-
voiceStop: "voiceStop";
|
|
427
427
|
}> & z.core.$partial, z.ZodUnion<readonly [z.ZodBoolean, z.ZodNumber, z.ZodArray<z.ZodNumber>]>>>;
|
|
428
428
|
}, z.core.$loose>>;
|
|
429
429
|
}, z.core.$loose>;
|
|
@@ -858,32 +858,32 @@ type I18nOptions = z.infer<typeof i18nSchema>;
|
|
|
858
858
|
*/
|
|
859
859
|
|
|
860
860
|
declare const moduleLayoutSchema: z.ZodEnum<{
|
|
861
|
+
home: "home";
|
|
861
862
|
chat: "chat";
|
|
862
863
|
help: "help";
|
|
863
|
-
home: "home";
|
|
864
864
|
news: "news";
|
|
865
865
|
}>;
|
|
866
866
|
type ModuleLayout = z.infer<typeof moduleLayoutSchema>;
|
|
867
867
|
declare const moduleSchema: z.ZodObject<{
|
|
868
868
|
label: z.ZodString;
|
|
869
869
|
layout: z.ZodEnum<{
|
|
870
|
+
home: "home";
|
|
870
871
|
chat: "chat";
|
|
871
872
|
help: "help";
|
|
872
|
-
home: "home";
|
|
873
873
|
news: "news";
|
|
874
874
|
}>;
|
|
875
875
|
contentTags: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
876
876
|
id: z.ZodOptional<z.ZodString>;
|
|
877
877
|
brandName: z.ZodOptional<z.ZodString>;
|
|
878
|
-
|
|
878
|
+
hideGreeting: z.ZodOptional<z.ZodBoolean>;
|
|
879
879
|
greetingText: z.ZodOptional<z.ZodString>;
|
|
880
880
|
userAvatars: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
881
881
|
name: z.ZodString;
|
|
882
882
|
avatar: z.ZodOptional<z.ZodString>;
|
|
883
883
|
role: z.ZodOptional<z.ZodString>;
|
|
884
884
|
}, z.core.$loose>>>;
|
|
885
|
-
|
|
886
|
-
|
|
885
|
+
hideSearchBar: z.ZodOptional<z.ZodBoolean>;
|
|
886
|
+
hideRecentConversations: z.ZodOptional<z.ZodBoolean>;
|
|
887
887
|
status: z.ZodOptional<z.ZodObject<{
|
|
888
888
|
text: z.ZodOptional<z.ZodString>;
|
|
889
889
|
level: z.ZodOptional<z.ZodString>;
|
|
@@ -895,23 +895,23 @@ type ModuleOptions = z.infer<typeof moduleSchema>;
|
|
|
895
895
|
declare const modulesSchema: z.ZodArray<z.ZodObject<{
|
|
896
896
|
label: z.ZodString;
|
|
897
897
|
layout: z.ZodEnum<{
|
|
898
|
+
home: "home";
|
|
898
899
|
chat: "chat";
|
|
899
900
|
help: "help";
|
|
900
|
-
home: "home";
|
|
901
901
|
news: "news";
|
|
902
902
|
}>;
|
|
903
903
|
contentTags: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
904
904
|
id: z.ZodOptional<z.ZodString>;
|
|
905
905
|
brandName: z.ZodOptional<z.ZodString>;
|
|
906
|
-
|
|
906
|
+
hideGreeting: z.ZodOptional<z.ZodBoolean>;
|
|
907
907
|
greetingText: z.ZodOptional<z.ZodString>;
|
|
908
908
|
userAvatars: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
909
909
|
name: z.ZodString;
|
|
910
910
|
avatar: z.ZodOptional<z.ZodString>;
|
|
911
911
|
role: z.ZodOptional<z.ZodString>;
|
|
912
912
|
}, z.core.$loose>>>;
|
|
913
|
-
|
|
914
|
-
|
|
913
|
+
hideSearchBar: z.ZodOptional<z.ZodBoolean>;
|
|
914
|
+
hideRecentConversations: z.ZodOptional<z.ZodBoolean>;
|
|
915
915
|
status: z.ZodOptional<z.ZodObject<{
|
|
916
916
|
text: z.ZodOptional<z.ZodString>;
|
|
917
917
|
level: z.ZodOptional<z.ZodString>;
|
package/schema.json
CHANGED
|
@@ -490,9 +490,9 @@
|
|
|
490
490
|
"description": "Fade the message list at its scroll edges with a soft gradient mask (the fade lifts at the very top/bottom). `true` (default) enables it; `false` shows hard edges.",
|
|
491
491
|
"type": "boolean"
|
|
492
492
|
},
|
|
493
|
-
"
|
|
494
|
-
"default":
|
|
495
|
-
"description": "
|
|
493
|
+
"disableMessageFeedback": {
|
|
494
|
+
"default": false,
|
|
495
|
+
"description": "Turn OFF the 👍/👎 feedback controls under each assistant reply. Unset/`false` = shown (default), `true` = hidden. A choice fires the `messageFeedback` event and is POSTed best-effort to `/pai/message-feedback`.",
|
|
496
496
|
"type": "boolean"
|
|
497
497
|
}
|
|
498
498
|
},
|
|
@@ -503,7 +503,7 @@
|
|
|
503
503
|
"showToolCalls",
|
|
504
504
|
"showSources",
|
|
505
505
|
"scrollFade",
|
|
506
|
-
"
|
|
506
|
+
"disableMessageFeedback"
|
|
507
507
|
],
|
|
508
508
|
"additionalProperties": {},
|
|
509
509
|
"description": "Conversation behaviour — lifecycle, streaming, and the transcript surface (scroll, feedback).",
|
|
@@ -516,7 +516,7 @@
|
|
|
516
516
|
"startMinimized": false,
|
|
517
517
|
"responseMode": "buffered",
|
|
518
518
|
"scrollFade": false,
|
|
519
|
-
"
|
|
519
|
+
"disableMessageFeedback": true
|
|
520
520
|
}
|
|
521
521
|
]
|
|
522
522
|
},
|
|
@@ -1309,16 +1309,16 @@
|
|
|
1309
1309
|
]
|
|
1310
1310
|
}
|
|
1311
1311
|
},
|
|
1312
|
-
"
|
|
1313
|
-
"default":
|
|
1314
|
-
"description": "
|
|
1312
|
+
"disableHumanInLoop": {
|
|
1313
|
+
"default": false,
|
|
1314
|
+
"description": "Turn OFF the human-in-the-loop tool UI — the inline ask-questions form + approve/reject controls for gated tools. Unset/`false` = shown (default), `true` = suppressed (the wire still carries the signals).",
|
|
1315
1315
|
"type": "boolean"
|
|
1316
1316
|
}
|
|
1317
1317
|
},
|
|
1318
1318
|
"required": [
|
|
1319
1319
|
"files",
|
|
1320
1320
|
"voice",
|
|
1321
|
-
"
|
|
1321
|
+
"disableHumanInLoop"
|
|
1322
1322
|
],
|
|
1323
1323
|
"additionalProperties": {},
|
|
1324
1324
|
"description": "Capability flags — file upload, voice mode, and the tools the assistant may invoke.",
|
|
@@ -1841,8 +1841,8 @@
|
|
|
1841
1841
|
"type": "string",
|
|
1842
1842
|
"maxLength": 80
|
|
1843
1843
|
},
|
|
1844
|
-
"
|
|
1845
|
-
"description": "`home` —
|
|
1844
|
+
"hideGreeting": {
|
|
1845
|
+
"description": "`home` — hide the greeting hero. Unset/`false` = shown (default), `true` = hidden.",
|
|
1846
1846
|
"type": "boolean"
|
|
1847
1847
|
},
|
|
1848
1848
|
"greetingText": {
|
|
@@ -1878,12 +1878,12 @@
|
|
|
1878
1878
|
"additionalProperties": {}
|
|
1879
1879
|
}
|
|
1880
1880
|
},
|
|
1881
|
-
"
|
|
1882
|
-
"description": "`home` —
|
|
1881
|
+
"hideSearchBar": {
|
|
1882
|
+
"description": "`home` — hide the 'Search for help' bar. Unset/`false` = shown (default), `true` = hidden.",
|
|
1883
1883
|
"type": "boolean"
|
|
1884
1884
|
},
|
|
1885
|
-
"
|
|
1886
|
-
"description": "`home` —
|
|
1885
|
+
"hideRecentConversations": {
|
|
1886
|
+
"description": "`home` — hide the visitor's most recent conversation card. Unset/`false` = shown (default), `true` = hidden.",
|
|
1887
1887
|
"type": "boolean"
|
|
1888
1888
|
},
|
|
1889
1889
|
"status": {
|
|
@@ -1939,8 +1939,6 @@
|
|
|
1939
1939
|
"label": "tabHome",
|
|
1940
1940
|
"layout": "home",
|
|
1941
1941
|
"brandName": "Acme",
|
|
1942
|
-
"showSearchBar": true,
|
|
1943
|
-
"showRecentConversations": true,
|
|
1944
1942
|
"contentBlockTitle": "Popular articles",
|
|
1945
1943
|
"contentTags": [
|
|
1946
1944
|
"popular"
|
|
@@ -2362,9 +2360,9 @@
|
|
|
2362
2360
|
"description": "Fade the message list at its scroll edges with a soft gradient mask (the fade lifts at the very top/bottom). `true` (default) enables it; `false` shows hard edges.",
|
|
2363
2361
|
"type": "boolean"
|
|
2364
2362
|
},
|
|
2365
|
-
"
|
|
2366
|
-
"default":
|
|
2367
|
-
"description": "
|
|
2363
|
+
"disableMessageFeedback": {
|
|
2364
|
+
"default": false,
|
|
2365
|
+
"description": "Turn OFF the 👍/👎 feedback controls under each assistant reply. Unset/`false` = shown (default), `true` = hidden. A choice fires the `messageFeedback` event and is POSTed best-effort to `/pai/message-feedback`.",
|
|
2368
2366
|
"type": "boolean"
|
|
2369
2367
|
}
|
|
2370
2368
|
},
|
|
@@ -2375,7 +2373,7 @@
|
|
|
2375
2373
|
"showToolCalls",
|
|
2376
2374
|
"showSources",
|
|
2377
2375
|
"scrollFade",
|
|
2378
|
-
"
|
|
2376
|
+
"disableMessageFeedback"
|
|
2379
2377
|
],
|
|
2380
2378
|
"additionalProperties": {},
|
|
2381
2379
|
"description": "Conversation behaviour — lifecycle, streaming, and the transcript surface (scroll, feedback).",
|
|
@@ -2388,7 +2386,7 @@
|
|
|
2388
2386
|
"startMinimized": false,
|
|
2389
2387
|
"responseMode": "buffered",
|
|
2390
2388
|
"scrollFade": false,
|
|
2391
|
-
"
|
|
2389
|
+
"disableMessageFeedback": true
|
|
2392
2390
|
}
|
|
2393
2391
|
]
|
|
2394
2392
|
},
|
|
@@ -3181,16 +3179,16 @@
|
|
|
3181
3179
|
]
|
|
3182
3180
|
}
|
|
3183
3181
|
},
|
|
3184
|
-
"
|
|
3185
|
-
"default":
|
|
3186
|
-
"description": "
|
|
3182
|
+
"disableHumanInLoop": {
|
|
3183
|
+
"default": false,
|
|
3184
|
+
"description": "Turn OFF the human-in-the-loop tool UI — the inline ask-questions form + approve/reject controls for gated tools. Unset/`false` = shown (default), `true` = suppressed (the wire still carries the signals).",
|
|
3187
3185
|
"type": "boolean"
|
|
3188
3186
|
}
|
|
3189
3187
|
},
|
|
3190
3188
|
"required": [
|
|
3191
3189
|
"files",
|
|
3192
3190
|
"voice",
|
|
3193
|
-
"
|
|
3191
|
+
"disableHumanInLoop"
|
|
3194
3192
|
],
|
|
3195
3193
|
"additionalProperties": {},
|
|
3196
3194
|
"description": "Capability flags — file upload, voice mode, and the tools the assistant may invoke.",
|
|
@@ -3253,8 +3251,8 @@
|
|
|
3253
3251
|
"type": "string",
|
|
3254
3252
|
"maxLength": 80
|
|
3255
3253
|
},
|
|
3256
|
-
"
|
|
3257
|
-
"description": "`home` —
|
|
3254
|
+
"hideGreeting": {
|
|
3255
|
+
"description": "`home` — hide the greeting hero. Unset/`false` = shown (default), `true` = hidden.",
|
|
3258
3256
|
"type": "boolean"
|
|
3259
3257
|
},
|
|
3260
3258
|
"greetingText": {
|
|
@@ -3290,12 +3288,12 @@
|
|
|
3290
3288
|
"additionalProperties": {}
|
|
3291
3289
|
}
|
|
3292
3290
|
},
|
|
3293
|
-
"
|
|
3294
|
-
"description": "`home` —
|
|
3291
|
+
"hideSearchBar": {
|
|
3292
|
+
"description": "`home` — hide the 'Search for help' bar. Unset/`false` = shown (default), `true` = hidden.",
|
|
3295
3293
|
"type": "boolean"
|
|
3296
3294
|
},
|
|
3297
|
-
"
|
|
3298
|
-
"description": "`home` —
|
|
3295
|
+
"hideRecentConversations": {
|
|
3296
|
+
"description": "`home` — hide the visitor's most recent conversation card. Unset/`false` = shown (default), `true` = hidden.",
|
|
3299
3297
|
"type": "boolean"
|
|
3300
3298
|
},
|
|
3301
3299
|
"status": {
|
|
@@ -3351,8 +3349,6 @@
|
|
|
3351
3349
|
"label": "tabHome",
|
|
3352
3350
|
"layout": "home",
|
|
3353
3351
|
"brandName": "Acme",
|
|
3354
|
-
"showSearchBar": true,
|
|
3355
|
-
"showRecentConversations": true,
|
|
3356
3352
|
"contentBlockTitle": "Popular articles",
|
|
3357
3353
|
"contentTags": [
|
|
3358
3354
|
"popular"
|
package/schema.mjs
CHANGED
|
@@ -134,13 +134,13 @@ var behaviorSchema = z4.object({
|
|
|
134
134
|
scrollFade: z4.boolean().default(true).describe(
|
|
135
135
|
"Fade the message list at its scroll edges with a soft gradient mask (the fade lifts at the very top/bottom). `true` (default) enables it; `false` shows hard edges."
|
|
136
136
|
),
|
|
137
|
-
|
|
138
|
-
"
|
|
137
|
+
disableMessageFeedback: z4.boolean().default(false).describe(
|
|
138
|
+
"Turn OFF the \u{1F44D}/\u{1F44E} feedback controls under each assistant reply. Unset/`false` = shown (default), `true` = hidden. A choice fires the `messageFeedback` event and is POSTed best-effort to `/pai/message-feedback`."
|
|
139
139
|
)
|
|
140
140
|
}).loose().describe("Conversation behaviour \u2014 lifecycle, streaming, and the transcript surface (scroll, feedback).").meta({
|
|
141
141
|
examples: [
|
|
142
142
|
{ startMinimized: true, responseMode: "streaming" },
|
|
143
|
-
{ startMinimized: false, responseMode: "buffered", scrollFade: false,
|
|
143
|
+
{ startMinimized: false, responseMode: "buffered", scrollFade: false, disableMessageFeedback: true }
|
|
144
144
|
]
|
|
145
145
|
});
|
|
146
146
|
|
|
@@ -231,8 +231,8 @@ var featureFlagsSchema = z7.object({
|
|
|
231
231
|
tools: z7.array(toolRefSchema).max(200).optional().describe(
|
|
232
232
|
"Backend tools the assistant may invoke. Bare codes (`'tool:send-money'`) or rich refs (`{ code, config }`)."
|
|
233
233
|
),
|
|
234
|
-
|
|
235
|
-
"
|
|
234
|
+
disableHumanInLoop: z7.boolean().default(false).describe(
|
|
235
|
+
"Turn OFF the human-in-the-loop tool UI \u2014 the inline ask-questions form + approve/reject controls for gated tools. Unset/`false` = shown (default), `true` = suppressed (the wire still carries the signals)."
|
|
236
236
|
)
|
|
237
237
|
}).loose().describe("Capability flags \u2014 file upload, voice mode, and the tools the assistant may invoke.").meta({
|
|
238
238
|
examples: [
|
|
@@ -551,7 +551,7 @@ var moduleSchema = z14.object({
|
|
|
551
551
|
),
|
|
552
552
|
// ── `home` layout config (flat feature flags — no block authoring) ──────
|
|
553
553
|
brandName: z14.string().max(80).optional().describe("`home` \u2014 hero wordmark (e.g. your company name)."),
|
|
554
|
-
|
|
554
|
+
hideGreeting: z14.boolean().optional().describe("`home` \u2014 hide the greeting hero. Unset/`false` = shown (default), `true` = hidden."),
|
|
555
555
|
greetingText: z14.string().max(280).optional().describe("`home` \u2014 override the greeting headline (default 'How can we help?'); supports a `{name}` token."),
|
|
556
556
|
userAvatars: z14.array(
|
|
557
557
|
z14.object({
|
|
@@ -560,8 +560,10 @@ var moduleSchema = z14.object({
|
|
|
560
560
|
role: z14.string().max(80).optional()
|
|
561
561
|
}).loose()
|
|
562
562
|
).max(10).optional().describe("`home` \u2014 team/agent avatars shown in the hero."),
|
|
563
|
-
|
|
564
|
-
|
|
563
|
+
hideSearchBar: z14.boolean().optional().describe("`home` \u2014 hide the 'Search for help' bar. Unset/`false` = shown (default), `true` = hidden."),
|
|
564
|
+
hideRecentConversations: z14.boolean().optional().describe(
|
|
565
|
+
"`home` \u2014 hide the visitor's most recent conversation card. Unset/`false` = shown (default), `true` = hidden."
|
|
566
|
+
),
|
|
565
567
|
status: z14.object({
|
|
566
568
|
text: z14.string().min(1).max(120).optional().describe(
|
|
567
569
|
"`home` \u2014 status line; an i18n key or a literal (resolved via `localizeText`). Omit to use the built-in generic `homeStatus` string (localized, no custom key needed)."
|
|
@@ -583,8 +585,6 @@ var modulesSchema = z14.array(moduleSchema).max(4).describe(
|
|
|
583
585
|
label: "tabHome",
|
|
584
586
|
layout: "home",
|
|
585
587
|
brandName: "Acme",
|
|
586
|
-
showSearchBar: true,
|
|
587
|
-
showRecentConversations: true,
|
|
588
588
|
contentBlockTitle: "Popular articles",
|
|
589
589
|
contentTags: ["popular"]
|
|
590
590
|
},
|