@webority/chat-react 0.128.0 → 0.133.0
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/chat-react.js +14 -11
- package/dist/types/ChatAgentTyping.d.ts +4 -0
- package/dist/types/ChatAuthorBadge.d.ts +4 -0
- package/dist/types/ChatComposer.d.ts +10 -0
- package/dist/types/ChatConversationActions.d.ts +7 -0
- package/dist/types/ChatEmbed.d.ts +5 -0
- package/dist/types/ChatExplain.d.ts +16 -0
- package/dist/types/ChatFooter.d.ts +8 -0
- package/dist/types/ChatFrame.d.ts +26 -0
- package/dist/types/ChatHistory.d.ts +9 -0
- package/dist/types/ChatLauncher.d.ts +5 -0
- package/dist/types/ChatLiveStatus.d.ts +4 -0
- package/dist/types/ChatMessageActions.d.ts +10 -0
- package/dist/types/ChatNudge.d.ts +10 -0
- package/dist/types/ChatOpenTickets.d.ts +9 -0
- package/dist/types/ChatPage.d.ts +49 -0
- package/dist/types/ChatPanel.d.ts +9 -0
- package/dist/types/ChatPastChats.d.ts +9 -0
- package/dist/types/ChatReadAloudButton.d.ts +8 -0
- package/dist/types/ChatShell.d.ts +32 -0
- package/dist/types/ChatStarters.d.ts +8 -0
- package/dist/types/ChatThread.d.ts +15 -0
- package/dist/types/chatLive.d.ts +5 -0
- package/dist/types/chatPrint.d.ts +5 -0
- package/dist/types/chatShared.d.ts +10 -0
- package/dist/types/dictationText.d.ts +31 -0
- package/dist/types/index.d.ts +20 -14
- package/dist/types/loaders/ChatLoader.d.ts +21 -0
- package/dist/types/loaders/OrbLoader.d.ts +11 -0
- package/dist/types/loaders/PhrasesLoader.d.ts +14 -0
- package/dist/types/loaders/SkeletonLoader.d.ts +11 -0
- package/dist/types/loaders/StepsLoader.d.ts +12 -0
- package/dist/types/loaders/TypingPill.d.ts +12 -0
- package/dist/types/renderers/ActionPart.d.ts +4 -0
- package/dist/types/renderers/ChartPart.d.ts +4 -0
- package/dist/types/renderers/ChatLinkContext.d.ts +8 -0
- package/dist/types/renderers/FigureText.d.ts +5 -0
- package/dist/types/renderers/FiguresPart.d.ts +4 -0
- package/dist/types/renderers/FilePart.d.ts +4 -0
- package/dist/types/renderers/HandoffPart.d.ts +4 -0
- package/dist/types/renderers/ImagePart.d.ts +4 -0
- package/dist/types/renderers/InputRequestPart.d.ts +5 -0
- package/dist/types/renderers/NoticePart.d.ts +3 -0
- package/dist/types/renderers/QuickRepliesPart.d.ts +4 -0
- package/dist/types/renderers/RecordCardPart.d.ts +4 -0
- package/dist/types/renderers/SourcesPart.d.ts +4 -0
- package/dist/types/renderers/TablePart.d.ts +4 -0
- package/dist/types/renderers/TextPart.d.ts +5 -0
- package/dist/types/renderers/TicketPart.d.ts +4 -0
- package/dist/types/renderers/VoiceClipPart.d.ts +7 -0
- package/dist/types/renderers/index.d.ts +32 -0
- package/dist/types/useAutoOpen.d.ts +11 -0
- package/dist/types/useChat.d.ts +34 -76
- package/dist/types/useChatDictation.d.ts +24 -0
- package/dist/types/useChatExplain.d.ts +57 -0
- package/dist/types/useChatHandoff.d.ts +19 -0
- package/dist/types/useChatReadAloud.d.ts +16 -0
- package/dist/types/useChatSound.d.ts +5 -0
- package/dist/types/useChatSpeech.d.ts +7 -0
- package/dist/types/useLauncherAvoid.d.ts +1 -0
- package/dist/types/useReducedMotion.d.ts +1 -0
- package/dist/types/useTranscriptActions.d.ts +12 -0
- package/package.json +18 -20
- package/README.md +0 -320
- package/dist/guidance.json +0 -216
- package/dist/types/ChatMarkdown.meta.d.ts +0 -31
- package/dist/types/components/ActionCard.d.ts +0 -27
- package/dist/types/components/ActionCard.meta.d.ts +0 -89
- package/dist/types/components/ChatComposer.d.ts +0 -38
- package/dist/types/components/ChatComposer.meta.d.ts +0 -56
- package/dist/types/components/ChatConversationList.d.ts +0 -20
- package/dist/types/components/ChatConversationList.meta.d.ts +0 -37
- package/dist/types/components/ChatLauncher.d.ts +0 -31
- package/dist/types/components/ChatLauncher.meta.d.ts +0 -50
- package/dist/types/components/ChatMessage.d.ts +0 -61
- package/dist/types/components/ChatMessage.meta.d.ts +0 -173
- package/dist/types/components/ChatPanel.d.ts +0 -74
- package/dist/types/components/ChatPanel.meta.d.ts +0 -228
- package/dist/types/components/ChatThread.d.ts +0 -54
- package/dist/types/components/ChatThread.meta.d.ts +0 -151
- package/dist/types/components/CitationChip.d.ts +0 -15
- package/dist/types/components/CitationChip.meta.d.ts +0 -48
- package/dist/types/components/ComposerAttachments.d.ts +0 -14
- package/dist/types/components/ConfirmCard.d.ts +0 -24
- package/dist/types/components/ConfirmCard.meta.d.ts +0 -43
- package/dist/types/components/ReplyRating.d.ts +0 -16
- package/dist/types/components/ReplyRating.meta.d.ts +0 -34
- package/dist/types/markdown.d.ts +0 -22
- /package/{LICENSE → LICENSE.txt} +0 -0
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Thumbs for one reply. Up saves at once. Down also saves at once, then offers an optional note
|
|
3
|
-
* that saves the same rating again with the note. Either choice can be changed.
|
|
4
|
-
*
|
|
5
|
-
* @param {object} props
|
|
6
|
-
* @param {"Up"|"Down"|null} [props.rating]
|
|
7
|
-
* @param {(rating: "Up"|"Down", note?: string) => Promise<unknown>} props.onRate Rejects on failure.
|
|
8
|
-
* @param {number} [props.noteMaxLength]
|
|
9
|
-
* @param {Partial<typeof import('@webority/markdown-core/chat').DEFAULT_CHAT_LABELS>} [props.labels]
|
|
10
|
-
*/
|
|
11
|
-
export default function ReplyRating({ rating, onRate, noteMaxLength, labels: labelOverrides }: {
|
|
12
|
-
rating?: "Up" | "Down" | null;
|
|
13
|
-
onRate: (rating: "Up" | "Down", note?: string) => Promise<unknown>;
|
|
14
|
-
noteMaxLength?: number;
|
|
15
|
-
labels?: Partial<typeof import('@webority/markdown-core/chat').DEFAULT_CHAT_LABELS>;
|
|
16
|
-
}): import("react").JSX.Element;
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
export declare const meta: {
|
|
2
|
-
readonly name: "ReplyRating";
|
|
3
|
-
readonly marker: null;
|
|
4
|
-
readonly platforms: readonly ["web"];
|
|
5
|
-
readonly acceptsChildren: false;
|
|
6
|
-
readonly props: {
|
|
7
|
-
readonly rating: {
|
|
8
|
-
readonly type: "enum";
|
|
9
|
-
readonly values: readonly ["Up", "Down"];
|
|
10
|
-
readonly description: "The rating already saved for the reply. Leave it out when the reply is not rated yet.";
|
|
11
|
-
};
|
|
12
|
-
readonly noteMaxLength: {
|
|
13
|
-
readonly type: "number";
|
|
14
|
-
readonly default: 1000;
|
|
15
|
-
readonly description: "The most characters the optional note after a not helpful rating takes.";
|
|
16
|
-
};
|
|
17
|
-
readonly labels: {
|
|
18
|
-
readonly type: "object";
|
|
19
|
-
readonly description: "Replaces any of the chat texts the rating buttons, the note field and the thank you line show.";
|
|
20
|
-
};
|
|
21
|
-
};
|
|
22
|
-
readonly examples: readonly [{
|
|
23
|
-
readonly id: "ReplyRating";
|
|
24
|
-
readonly title: "Default";
|
|
25
|
-
readonly props: {};
|
|
26
|
-
}];
|
|
27
|
-
readonly usage: {
|
|
28
|
-
readonly when: readonly ["A reply can be rated helpful or not helpful, with an optional note after a not helpful rating."];
|
|
29
|
-
readonly whenNot: readonly [];
|
|
30
|
-
readonly do: readonly [];
|
|
31
|
-
readonly dont: readonly [];
|
|
32
|
-
readonly a11y: readonly ["Both rating buttons are native buttons that expose their state through aria-pressed.", "The thank you line is a status message.", "The note field has a visible label and a hint, and the person can send the note or skip it."];
|
|
33
|
-
};
|
|
34
|
-
};
|
package/dist/types/markdown.d.ts
DELETED
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* A chat reply, drawn by `AppMarkdown` with the chat rules: a link opens only when `resolveLink`
|
|
3
|
-
* maps its `scheme:kind/id` href to an in-app route, and a heading draws as a bold line so a reply
|
|
4
|
-
* never changes the page outline. Any other link shows its label as text, and raw HTML shows as text.
|
|
5
|
-
*
|
|
6
|
-
* @param {object} props
|
|
7
|
-
* @param {string} props.text
|
|
8
|
-
* @param {(href: string) => string|null|undefined} [props.resolveLink] Maps `scheme:kind/id` to a
|
|
9
|
-
* route such as "/support?ticket=3f2a", or null to leave it as text.
|
|
10
|
-
* @param {import('react').ElementType} [props.linkComponent] A router link (it receives `to`).
|
|
11
|
-
* @param {(inner: string) => boolean} [props.isCitation] Which `[inner]` runs draw as citation chips.
|
|
12
|
-
* @param {(citation: string) => void} [props.onOpenCitation] Called with the citation when its chip is selected.
|
|
13
|
-
* @param {string} [props.className]
|
|
14
|
-
*/
|
|
15
|
-
export declare function ChatMarkdown({ text, resolveLink, linkComponent, isCitation, onOpenCitation, className }: {
|
|
16
|
-
text: string;
|
|
17
|
-
resolveLink?: (href: string) => string | null | undefined;
|
|
18
|
-
linkComponent?: import('react').ElementType;
|
|
19
|
-
isCitation?: (inner: string) => boolean;
|
|
20
|
-
onOpenCitation?: (citation: string) => void;
|
|
21
|
-
className?: string;
|
|
22
|
-
}): import("react").JSX.Element;
|
/package/{LICENSE → LICENSE.txt}
RENAMED
|
File without changes
|