@evelan/jexity-widget 0.28.1 → 0.30.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/README.md +7 -0
- package/dist/index.mjs +4637 -3353
- package/dist/index.mjs.map +1 -1
- package/dist/loader.js +6 -6
- package/dist/loader.js.map +1 -1
- package/dist/react.mjs +5050 -3715
- package/dist/react.mjs.map +1 -1
- package/dist/types/entries/esm.d.ts +6 -0
- package/dist/types/entries/esm.d.ts.map +1 -1
- package/dist/types/entries/react.d.ts +10 -0
- package/dist/types/entries/react.d.ts.map +1 -1
- package/dist/types/features/chat/components/ChatScreen.d.ts.map +1 -1
- package/dist/types/features/chat/components/EscalationFormScreen.d.ts.map +1 -1
- package/dist/types/features/chat/components/FormMessage.d.ts.map +1 -1
- package/dist/types/features/chat/components/MessageList.d.ts.map +1 -1
- package/dist/types/features/chat/components/SourcesRow.d.ts +4 -3
- package/dist/types/features/chat/components/SourcesRow.d.ts.map +1 -1
- package/dist/types/features/chat/composer/components/SessionErrorNotice.d.ts.map +1 -1
- package/dist/types/features/chat/composer/hooks/useAttachmentUpload.d.ts.map +1 -1
- package/dist/types/features/chat/composer/hooks/useSendMessage.d.ts.map +1 -1
- package/dist/types/features/chat/hooks/useConversation.d.ts.map +1 -1
- package/dist/types/features/chat/hooks/useConvexSession.d.ts.map +1 -1
- package/dist/types/features/chat/hooks/useEscalation.d.ts +8 -10
- package/dist/types/features/chat/hooks/useEscalation.d.ts.map +1 -1
- package/dist/types/features/chat/hooks/useSignedInContact.d.ts +12 -0
- package/dist/types/features/chat/hooks/useSignedInContact.d.ts.map +1 -0
- package/dist/types/features/chat/lib/chatOfAnotherUser.d.ts +14 -0
- package/dist/types/features/chat/lib/chatOfAnotherUser.d.ts.map +1 -0
- package/dist/types/features/chat/state/session-error.d.ts +5 -1
- package/dist/types/features/chat/state/session-error.d.ts.map +1 -1
- package/dist/types/features/home/components/ChatList.d.ts +18 -0
- package/dist/types/features/home/components/ChatList.d.ts.map +1 -0
- package/dist/types/features/home/components/DeleteChatsSheet.d.ts +20 -0
- package/dist/types/features/home/components/DeleteChatsSheet.d.ts.map +1 -0
- package/dist/types/features/home/components/HomeScreen.d.ts +7 -1
- package/dist/types/features/home/components/HomeScreen.d.ts.map +1 -1
- package/dist/types/i18n/index.d.ts +6 -0
- package/dist/types/i18n/index.d.ts.map +1 -1
- package/dist/types/i18n/locales/de-formal.d.ts +293 -0
- package/dist/types/i18n/locales/de-formal.d.ts.map +1 -0
- package/dist/types/i18n/locales/de.d.ts +30 -1
- package/dist/types/i18n/locales/de.d.ts.map +1 -1
- package/dist/types/i18n/locales/en.d.ts +62 -1
- package/dist/types/i18n/locales/en.d.ts.map +1 -1
- package/dist/types/lib/refreshBootstrap.d.ts +1 -1
- package/dist/types/lib/refreshBootstrap.d.ts.map +1 -1
- package/dist/types/lib/userToken.d.ts +49 -0
- package/dist/types/lib/userToken.d.ts.map +1 -0
- package/dist/types/lib/widget-config.d.ts +19 -1
- package/dist/types/lib/widget-config.d.ts.map +1 -1
- package/dist/types/lib/widgetBootstrap.d.ts +19 -2
- package/dist/types/lib/widgetBootstrap.d.ts.map +1 -1
- package/dist/types/module/screens/ScreenRouter.d.ts +5 -1
- package/dist/types/module/screens/ScreenRouter.d.ts.map +1 -1
- package/dist/types/module/screens/screens.state.d.ts +5 -1
- package/dist/types/module/screens/screens.state.d.ts.map +1 -1
- package/dist/types/module/shell/WidgetShell.d.ts.map +1 -1
- package/dist/types/module/shell/hooks/useBootstrap.d.ts +3 -1
- package/dist/types/module/shell/hooks/useBootstrap.d.ts.map +1 -1
- package/dist/types/module/shell/mount.d.ts.map +1 -1
- package/dist/types/module/shell/shell.state.d.ts +18 -1
- package/dist/types/module/shell/shell.state.d.ts.map +1 -1
- package/dist/types/module/shell/widget-instance.d.ts.map +1 -1
- package/dist/types/module/visitor/idle-lock.d.ts +6 -0
- package/dist/types/module/visitor/idle-lock.d.ts.map +1 -1
- package/dist/types/module/visitor/visitor.state.d.ts +17 -0
- package/dist/types/module/visitor/visitor.state.d.ts.map +1 -1
- package/dist/types/types.d.ts +25 -0
- package/dist/types/types.d.ts.map +1 -1
- package/dist/widget.js +38 -38
- package/dist/widget.js.map +1 -1
- package/package.json +3 -3
|
@@ -1,4 +1,10 @@
|
|
|
1
1
|
import type { JexityChatOptions, JexityChatInstance } from '../types';
|
|
2
2
|
export type { JexityChatOptions, JexityChatInstance };
|
|
3
3
|
export declare function JexityChat(options: JexityChatOptions): JexityChatInstance;
|
|
4
|
+
/**
|
|
5
|
+
* Call when your user signs out: forgets this tab's chats, like
|
|
6
|
+
* `instance.logout()`, but also before `JexityChat()` ran on this page load
|
|
7
|
+
* (after a reload, the stored chats are all there is).
|
|
8
|
+
*/
|
|
9
|
+
export declare function logout(): void;
|
|
4
10
|
//# sourceMappingURL=esm.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"esm.d.ts","sourceRoot":"","sources":["../../../src/entries/esm.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"esm.d.ts","sourceRoot":"","sources":["../../../src/entries/esm.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,iBAAiB,EAAE,kBAAkB,EAAE,MAAM,UAAU,CAAA;AAErE,YAAY,EAAE,iBAAiB,EAAE,kBAAkB,EAAE,CAAA;AAIrD,wBAAgB,UAAU,CAAC,OAAO,EAAE,iBAAiB,GAAG,kBAAkB,CA0BzE;AAED;;;;GAIG;AACH,wBAAgB,MAAM,IAAI,IAAI,CAG7B"}
|
|
@@ -4,8 +4,18 @@ interface JexityChatContextValue {
|
|
|
4
4
|
open: () => void;
|
|
5
5
|
close: () => void;
|
|
6
6
|
toggle: () => void;
|
|
7
|
+
/** Opens the chat and sends `text` as the visitor's message. */
|
|
8
|
+
ask: (text: string) => void;
|
|
9
|
+
/** Call when the signed-in user signs out: forgets this tab's chats and starts over with the current `userToken`. The chat stays available. */
|
|
10
|
+
logout: () => void;
|
|
7
11
|
isOpen: boolean;
|
|
8
12
|
}
|
|
13
|
+
/**
|
|
14
|
+
* Call when your user signs out: forgets this tab's chats, like
|
|
15
|
+
* `useJexityChat().logout()`, but from anywhere, also while no
|
|
16
|
+
* `JexityChatProvider` is mounted (a closed column) or the chat has not loaded.
|
|
17
|
+
*/
|
|
18
|
+
export declare function logout(): void;
|
|
9
19
|
export interface JexityChatProviderProps extends JexityChatOptions {
|
|
10
20
|
children?: ReactNode;
|
|
11
21
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"react.d.ts","sourceRoot":"","sources":["../../../src/entries/react.tsx"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AACtC,OAAO,KAAK,EAAE,iBAAiB,EAAsB,MAAM,UAAU,CAAA;
|
|
1
|
+
{"version":3,"file":"react.d.ts","sourceRoot":"","sources":["../../../src/entries/react.tsx"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AACtC,OAAO,KAAK,EAAE,iBAAiB,EAAsB,MAAM,UAAU,CAAA;AAIrE,UAAU,sBAAsB;IAC9B,IAAI,EAAE,MAAM,IAAI,CAAA;IAChB,KAAK,EAAE,MAAM,IAAI,CAAA;IACjB,MAAM,EAAE,MAAM,IAAI,CAAA;IAClB,gEAAgE;IAChE,GAAG,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAA;IAC3B,+IAA+I;IAC/I,MAAM,EAAE,MAAM,IAAI,CAAA;IAClB,MAAM,EAAE,OAAO,CAAA;CAChB;AAgBD;;;;GAIG;AACH,wBAAgB,MAAM,IAAI,IAAI,CAE7B;AAID,MAAM,WAAW,uBAAwB,SAAQ,iBAAiB;IAChE,QAAQ,CAAC,EAAE,SAAS,CAAA;CACrB;AAED,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,uBAAuB,0GAqIhE;AAED,wBAAgB,aAAa,IAAI,sBAAsB,CAMtD"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ChatScreen.d.ts","sourceRoot":"","sources":["../../../../../src/features/chat/components/ChatScreen.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,2CAA2C,CAAA;
|
|
1
|
+
{"version":3,"file":"ChatScreen.d.ts","sourceRoot":"","sources":["../../../../../src/features/chat/components/ChatScreen.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,2CAA2C,CAAA;AAenE,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,2BAA2B,CAAA;AAE9D,UAAU,eAAe;IACvB,QAAQ,EAAE,MAAM,CAAA;IAChB,qFAAqF;IACrF,OAAO,EAAE,MAAM,CAAA;IACf,wEAAwE;IACxE,gBAAgB,EAAE,MAAM,EAAE,CAAA;IAE1B,SAAS,EAAE,EAAE,CAAC,iBAAiB,CAAC,GAAG,IAAI,CAAA;IACvC,SAAS,EAAE,MAAM,GAAG,IAAI,CAAA;IACxB,SAAS,EAAE,OAAO,CAAA;IAClB,eAAe,EAAE,OAAO,CAAA;IACxB,YAAY,EAAE,OAAO,CAAA;IACrB,YAAY,EAAE,OAAO,CAAA;IACrB,aAAa,EAAE,MAAM,OAAO,CAAC,aAAa,GAAG,IAAI,CAAC,CAAA;IAClD,UAAU,EAAE,MAAM,OAAO,CAAC,aAAa,GAAG,IAAI,CAAC,CAAA;IAC/C,kFAAkF;IAClF,WAAW,EAAE,OAAO,CAAA;CACrB;AAED;;;;;;;;;GASG;AACH,wBAAgB,UAAU,CAAC,EAAE,QAAQ,EAAE,OAAO,EAAE,gBAAgB,EAAE,SAAS,EAAE,SAAS,EAAE,SAAS,EAAE,eAAe,EAAE,YAAY,EAAE,YAAY,EAAE,aAAa,EAAE,UAAU,EAAE,WAAW,EAAE,EAAE,eAAe,gCAuKxM"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"EscalationFormScreen.d.ts","sourceRoot":"","sources":["../../../../../src/features/chat/components/EscalationFormScreen.tsx"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,0BAA0B,CAAA;
|
|
1
|
+
{"version":3,"file":"EscalationFormScreen.d.ts","sourceRoot":"","sources":["../../../../../src/features/chat/components/EscalationFormScreen.tsx"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,0BAA0B,CAAA;AAG5D,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,2CAA2C,CAAA;AAEnE,UAAU,yBAAyB;IACjC,aAAa,EAAE,EAAE,CAAC,eAAe,CAAC,CAAA;IAClC,SAAS,EAAE,EAAE,CAAC,iBAAiB,CAAC,CAAA;IAChC,SAAS,EAAE,MAAM,CAAA;IACjB,+EAA+E;IAC/E,YAAY,CAAC,EAAE,YAAY,CAAA;IAC3B,YAAY,EAAE,MAAM,CAAA;CACrB;AAED;;;;GAIG;AACH,wBAAgB,oBAAoB,CAAC,EAAE,aAAa,EAAE,SAAS,EAAE,SAAS,EAAE,YAAY,EAAE,EAAE,yBAAyB,gCAqFpH"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FormMessage.d.ts","sourceRoot":"","sources":["../../../../../src/features/chat/components/FormMessage.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"FormMessage.d.ts","sourceRoot":"","sources":["../../../../../src/features/chat/components/FormMessage.tsx"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAE,GAAG,EAAE,EAAE,EAAE,MAAM,2CAA2C,CAAA;AAExE,UAAU,gBAAgB;IACxB,OAAO,EAAE,GAAG,CAAC,eAAe,CAAC,CAAA;IAC7B,SAAS,EAAE,EAAE,CAAC,iBAAiB,CAAC,CAAA;IAChC,SAAS,EAAE,MAAM,CAAA;IACjB,YAAY,EAAE,MAAM,CAAA;CACrB;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,WAAW,CAAC,EAAE,OAAO,EAAE,SAAS,EAAE,SAAS,EAAE,YAAY,EAAE,EAAE,gBAAgB,gCA6B5F"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MessageList.d.ts","sourceRoot":"","sources":["../../../../../src/features/chat/components/MessageList.tsx"],"names":[],"mappings":"AAUA,OAAO,EAAsB,KAAK,aAAa,EAAE,MAAM,sBAAsB,CAAA;AAM7E,OAAO,KAAK,EAAE,GAAG,EAAE,EAAE,EAAE,MAAM,2CAA2C,CAAA;AA+ExE,UAAU,gBAAgB;IACxB,aAAa,EAAE,GAAG,CAAC,eAAe,CAAC,EAAE,GAAG,SAAS,CAAA;IACjD,2EAA2E;IAC3E,WAAW,CAAC,EAAE,SAAS,aAAa,EAAE,CAAA;IACtC,QAAQ,EAAE,MAAM,CAAA;IAChB,8EAA8E;IAC9E,OAAO,EAAE,MAAM,CAAA;IACf,wEAAwE;IACxE,gBAAgB,EAAE,MAAM,EAAE,CAAA;IAC1B,kEAAkE;IAClE,aAAa,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAA;IACrC,8DAA8D;IAC9D,eAAe,CAAC,EAAE,OAAO,CAAA;IACzB,oEAAoE;IACpE,YAAY,CAAC,EAAE,OAAO,CAAA;IACtB,8DAA8D;IAC9D,YAAY,CAAC,EAAE,MAAM,IAAI,CAAA;IACzB,iDAAiD;IACjD,SAAS,EAAE,EAAE,CAAC,iBAAiB,CAAC,GAAG,IAAI,CAAA;IACvC,iDAAiD;IACjD,SAAS,EAAE,MAAM,GAAG,IAAI,CAAA;CACzB;AAaD,gFAAgF;AAChF,wBAAgB,WAAW,CAAC,EAAE,aAAa,EAAE,WAAW,EAAE,QAAQ,EAAE,OAAO,EAAE,gBAAgB,EAAE,aAAa,EAAE,eAAe,EAAE,YAAY,EAAE,YAAY,EAAE,SAAS,EAAE,SAAS,EAAE,EAAE,gBAAgB,
|
|
1
|
+
{"version":3,"file":"MessageList.d.ts","sourceRoot":"","sources":["../../../../../src/features/chat/components/MessageList.tsx"],"names":[],"mappings":"AAUA,OAAO,EAAsB,KAAK,aAAa,EAAE,MAAM,sBAAsB,CAAA;AAM7E,OAAO,KAAK,EAAE,GAAG,EAAE,EAAE,EAAE,MAAM,2CAA2C,CAAA;AA+ExE,UAAU,gBAAgB;IACxB,aAAa,EAAE,GAAG,CAAC,eAAe,CAAC,EAAE,GAAG,SAAS,CAAA;IACjD,2EAA2E;IAC3E,WAAW,CAAC,EAAE,SAAS,aAAa,EAAE,CAAA;IACtC,QAAQ,EAAE,MAAM,CAAA;IAChB,8EAA8E;IAC9E,OAAO,EAAE,MAAM,CAAA;IACf,wEAAwE;IACxE,gBAAgB,EAAE,MAAM,EAAE,CAAA;IAC1B,kEAAkE;IAClE,aAAa,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAA;IACrC,8DAA8D;IAC9D,eAAe,CAAC,EAAE,OAAO,CAAA;IACzB,oEAAoE;IACpE,YAAY,CAAC,EAAE,OAAO,CAAA;IACtB,8DAA8D;IAC9D,YAAY,CAAC,EAAE,MAAM,IAAI,CAAA;IACzB,iDAAiD;IACjD,SAAS,EAAE,EAAE,CAAC,iBAAiB,CAAC,GAAG,IAAI,CAAA;IACvC,iDAAiD;IACjD,SAAS,EAAE,MAAM,GAAG,IAAI,CAAA;CACzB;AAaD,gFAAgF;AAChF,wBAAgB,WAAW,CAAC,EAAE,aAAa,EAAE,WAAW,EAAE,QAAQ,EAAE,OAAO,EAAE,gBAAgB,EAAE,aAAa,EAAE,eAAe,EAAE,YAAY,EAAE,YAAY,EAAE,SAAS,EAAE,SAAS,EAAE,EAAE,gBAAgB,gCAkRlM"}
|
|
@@ -9,9 +9,10 @@ interface SourcesRowProps {
|
|
|
9
9
|
* already trimmed the sources array before it reached the widget — this
|
|
10
10
|
* component just renders whatever survived. If the array is empty, no row.
|
|
11
11
|
*
|
|
12
|
-
*
|
|
13
|
-
*
|
|
14
|
-
*
|
|
12
|
+
* A pill with a `url` (a page, or a file with a source address) is a direct
|
|
13
|
+
* anchor link to it (visitor sees what we cited). The rest (file without an
|
|
14
|
+
* address / snippet / qa) show as static badges since we don't expose
|
|
15
|
+
* deep-links to the org Knowledge admin from the visitor side.
|
|
15
16
|
*/
|
|
16
17
|
export declare function SourcesRow({ sources }: SourcesRowProps): import("preact").JSX.Element | null;
|
|
17
18
|
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SourcesRow.d.ts","sourceRoot":"","sources":["../../../../../src/features/chat/components/SourcesRow.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,2CAA2C,CAAA;AAGpE,KAAK,MAAM,GAAG,WAAW,CAAC,GAAG,CAAC,eAAe,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,MAAM,CAAC,CAAA;AAElE,UAAU,eAAe;IACvB,OAAO,EAAE,MAAM,EAAE,CAAA;CAClB;AASD
|
|
1
|
+
{"version":3,"file":"SourcesRow.d.ts","sourceRoot":"","sources":["../../../../../src/features/chat/components/SourcesRow.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,2CAA2C,CAAA;AAGpE,KAAK,MAAM,GAAG,WAAW,CAAC,GAAG,CAAC,eAAe,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,MAAM,CAAC,CAAA;AAElE,UAAU,eAAe;IACvB,OAAO,EAAE,MAAM,EAAE,CAAA;CAClB;AASD;;;;;;;;;;GAUG;AACH,wBAAgB,UAAU,CAAC,EAAE,OAAO,EAAE,EAAE,eAAe,uCAqEtD"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SessionErrorNotice.d.ts","sourceRoot":"","sources":["../../../../../../src/features/chat/composer/components/SessionErrorNotice.tsx"],"names":[],"mappings":"AACA,OAAO,EAAgB,KAAK,kBAAkB,EAAE,MAAM,aAAa,CAAA;AAEnE;;;;;;GAMG;AACH,wBAAgB,yBAAyB,CACvC,MAAM,EAAE,kBAAkB,GAAG,IAAI,EACjC,WAAW,EAAE,OAAO,GACnB,kBAAkB,GAAG,IAAI,CAE3B;AAED,UAAU,uBAAuB;IAC/B,0FAA0F;IAC1F,WAAW,CAAC,EAAE,OAAO,CAAA;CACtB;AAED;;;;;;;;GAQG;AACH,wBAAgB,kBAAkB,CAAC,EAAE,WAAmB,EAAE,GAAE,uBAA4B,
|
|
1
|
+
{"version":3,"file":"SessionErrorNotice.d.ts","sourceRoot":"","sources":["../../../../../../src/features/chat/composer/components/SessionErrorNotice.tsx"],"names":[],"mappings":"AACA,OAAO,EAAgB,KAAK,kBAAkB,EAAE,MAAM,aAAa,CAAA;AAEnE;;;;;;GAMG;AACH,wBAAgB,yBAAyB,CACvC,MAAM,EAAE,kBAAkB,GAAG,IAAI,EACjC,WAAW,EAAE,OAAO,GACnB,kBAAkB,GAAG,IAAI,CAE3B;AAED,UAAU,uBAAuB;IAC/B,0FAA0F;IAC1F,WAAW,CAAC,EAAE,OAAO,CAAA;CACtB;AAED;;;;;;;;GAQG;AACH,wBAAgB,kBAAkB,CAAC,EAAE,WAAmB,EAAE,GAAE,uBAA4B,uCAmBvF"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useAttachmentUpload.d.ts","sourceRoot":"","sources":["../../../../../../src/features/chat/composer/hooks/useAttachmentUpload.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,2CAA2C,CAAA;AAEnE,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,6BAA6B,CAAA;
|
|
1
|
+
{"version":3,"file":"useAttachmentUpload.d.ts","sourceRoot":"","sources":["../../../../../../src/features/chat/composer/hooks/useAttachmentUpload.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,2CAA2C,CAAA;AAEnE,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,6BAA6B,CAAA;AAIhE,UAAU,uBAAuB;IAC/B,SAAS,EAAE,EAAE,CAAC,iBAAiB,CAAC,GAAG,IAAI,CAAA;IACvC,SAAS,EAAE,MAAM,GAAG,IAAI,CAAA;CACzB;AAED;;;;;;;GAOG;AACH,wBAAgB,mBAAmB,CAAC,EAAE,SAAS,EAAE,SAAS,EAAE,EAAE,uBAAuB,GAAG;IACtF,QAAQ,EAAE,CAAC,KAAK,EAAE,IAAI,EAAE,KAAK,MAAM,CAAA;CACpC,CAuDA;AAED,yDAAyD;AACzD,wBAAgB,mBAAmB,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,EAAE,CAAC,EAAE,aAAa,GAAG,MAAM,CAmBjF"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useSendMessage.d.ts","sourceRoot":"","sources":["../../../../../../src/features/chat/composer/hooks/useSendMessage.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,2CAA2C,CAAA;
|
|
1
|
+
{"version":3,"file":"useSendMessage.d.ts","sourceRoot":"","sources":["../../../../../../src/features/chat/composer/hooks/useSendMessage.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,2CAA2C,CAAA;AAoBnE,UAAU,kBAAkB;IAC1B,SAAS,EAAE,EAAE,CAAC,iBAAiB,CAAC,GAAG,IAAI,CAAA;IACvC,SAAS,EAAE,MAAM,GAAG,IAAI,CAAA;IACxB,aAAa,EAAE,MAAM,OAAO,CAAC;QAAE,SAAS,EAAE,EAAE,CAAC,iBAAiB,CAAC,CAAC;QAAC,SAAS,EAAE,MAAM,CAAA;KAAE,GAAG,IAAI,CAAC,CAAA;CAC7F;AAED;;;;;;;;;;;;;;;;GAgBG;AACH,wBAAgB,cAAc,CAAC,EAAE,SAAS,EAAE,SAAS,EAAE,aAAa,EAAE,EAAE,kBAAkB,aAK7C,MAAM,KAAG,OAAO,CAAC,IAAI,CAAC,CAiHlE"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useConversation.d.ts","sourceRoot":"","sources":["../../../../../src/features/chat/hooks/useConversation.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,eAAe,CAAA;AACvD,OAAO,EAAE,GAAG,EAAE,MAAM,qCAAqC,CAAA;AACzD,OAAO,KAAK,EAAE,GAAG,EAAE,EAAE,EAAE,MAAM,2CAA2C,CAAA;
|
|
1
|
+
{"version":3,"file":"useConversation.d.ts","sourceRoot":"","sources":["../../../../../src/features/chat/hooks/useConversation.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,eAAe,CAAA;AACvD,OAAO,EAAE,GAAG,EAAE,MAAM,qCAAqC,CAAA;AACzD,OAAO,KAAK,EAAE,GAAG,EAAE,EAAE,EAAE,MAAM,2CAA2C,CAAA;AAGxE,UAAU,mBAAmB;IAC3B,SAAS,EAAE,EAAE,CAAC,iBAAiB,CAAC,GAAG,IAAI,CAAA;IACvC,SAAS,EAAE,MAAM,GAAG,IAAI,CAAA;CACzB;AAKD,MAAM,MAAM,iBAAiB,GAAG,QAAQ,GAAG,WAAW,GAAG,UAAU,GAAG,UAAU,GAAG,aAAa,CAAA;AAEhG,UAAU,qBAAqB;IAC7B,4EAA4E;IAC5E,aAAa,EAAE,GAAG,CAAC,eAAe,CAAC,EAAE,GAAG,SAAS,CAAA;IACjD,8EAA8E;IAC9E,aAAa,EAAE,iBAAiB,GAAG,IAAI,CAAA;IACvC,2EAA2E;IAC3E,SAAS,EAAE,OAAO,CAAA;IAClB,sDAAsD;IACtD,WAAW,EAAE,OAAO,CAAA;IACpB,iFAAiF;IACjF,WAAW,EAAE,kBAAkB,CAAC,OAAO,GAAG,CAAC,uBAAuB,CAAC,OAAO,CAAC,IAAI,CAAC,GAAG,SAAS,CAAA;CAC7F;AAED;;;;;;;GAOG;AACH,wBAAgB,eAAe,CAAC,EAAE,SAAS,EAAE,SAAS,EAAE,EAAE,mBAAmB,GAAG,qBAAqB,CA2BpG"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useConvexSession.d.ts","sourceRoot":"","sources":["../../../../../src/features/chat/hooks/useConvexSession.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,2CAA2C,CAAA;
|
|
1
|
+
{"version":3,"file":"useConvexSession.d.ts","sourceRoot":"","sources":["../../../../../src/features/chat/hooks/useConvexSession.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,2CAA2C,CAAA;AAoEnE,KAAK,aAAa,GAAG,QAAQ,GAAG,WAAW,GAAG,UAAU,GAAG,UAAU,GAAG,aAAa,GAAG,IAAI,CAAA;AAE5F,MAAM,WAAW,aAAa;IAC5B,SAAS,EAAE,EAAE,CAAC,iBAAiB,CAAC,CAAA;IAChC,SAAS,EAAE,MAAM,CAAA;CAClB;AAED,UAAU,aAAa;IACrB,SAAS,EAAE,EAAE,CAAC,iBAAiB,CAAC,GAAG,IAAI,CAAA;IACvC,SAAS,EAAE,MAAM,GAAG,IAAI,CAAA;IACxB,SAAS,EAAE,OAAO,CAAA;IAClB,kFAAkF;IAClF,eAAe,EAAE,OAAO,CAAA;IACxB,0EAA0E;IAC1E,YAAY,EAAE,OAAO,CAAA;IACrB,8CAA8C;IAC9C,aAAa,EAAE,aAAa,CAAA;IAC5B,wFAAwF;IACxF,YAAY,EAAE,OAAO,CAAA;IACrB,4EAA4E;IAC5E,aAAa,EAAE,MAAM,OAAO,CAAC,aAAa,GAAG,IAAI,CAAC,CAAA;IAClD,iEAAiE;IACjE,UAAU,EAAE,MAAM,OAAO,CAAC,aAAa,GAAG,IAAI,CAAC,CAAA;IAC/C;8EAC0E;IAC1E,YAAY,EAAE,MAAM,IAAI,CAAA;CACzB;AAED;;;;;;GAMG;AACH,wBAAgB,gBAAgB,CAAC,OAAO,EAAE,MAAM,EAAE,QAAQ,CAAC,EAAE,MAAM,GAAG,aAAa,CAmLlF"}
|
|
@@ -1,3 +1,6 @@
|
|
|
1
|
+
import type { FunctionArgs } from 'convex/server';
|
|
2
|
+
import { api } from '@repo/backend/convex/_generated/api';
|
|
3
|
+
type SubmitArgs = Omit<FunctionArgs<typeof api.escalations.public.submitEscalation>, 'bootstrapToken'>;
|
|
1
4
|
/**
|
|
2
5
|
* Escalation submit hook — single touch point for the
|
|
3
6
|
* `submitEscalation` mutation.
|
|
@@ -11,16 +14,11 @@
|
|
|
11
14
|
* Components that want error UI must catch the rejection themselves;
|
|
12
15
|
* this hook intentionally does not encapsulate error state because
|
|
13
16
|
* the two consumers render error differently (inline alert vs.
|
|
14
|
-
* silent log + form-reset).
|
|
17
|
+
* silent log + form-reset). It adds the bootstrap token, and starts a new
|
|
18
|
+
* chat when the server says the chat is another signed-in user's.
|
|
15
19
|
*/
|
|
16
|
-
export declare function useEscalation():
|
|
17
|
-
formMessageId: import("convex/values").GenericId<"conversations">;
|
|
18
|
-
locale?: "de" | "en" | undefined;
|
|
19
|
-
sessionId: import("convex/values").GenericId<"contactSessions">;
|
|
20
|
-
visitorEmail: string;
|
|
21
|
-
visitorId: string;
|
|
22
|
-
visitorName: string;
|
|
23
|
-
}, {
|
|
20
|
+
export declare function useEscalation(): (args: SubmitArgs) => Promise<{
|
|
24
21
|
ticketRef: string;
|
|
25
|
-
}
|
|
22
|
+
}>;
|
|
23
|
+
export {};
|
|
26
24
|
//# sourceMappingURL=useEscalation.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useEscalation.d.ts","sourceRoot":"","sources":["../../../../../src/features/chat/hooks/useEscalation.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"useEscalation.d.ts","sourceRoot":"","sources":["../../../../../src/features/chat/hooks/useEscalation.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,eAAe,CAAA;AACjD,OAAO,EAAE,GAAG,EAAE,MAAM,qCAAqC,CAAA;AAGzD,KAAK,UAAU,GAAG,IAAI,CAAC,YAAY,CAAC,OAAO,GAAG,CAAC,WAAW,CAAC,MAAM,CAAC,gBAAgB,CAAC,EAAE,gBAAgB,CAAC,CAAA;AAEtG;;;;;;;;;;;;;;;GAeG;AACH,wBAAgB,aAAa,WAEP,UAAU;;GAQ/B"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import type { Id } from '@repo/backend/convex/_generated/dataModel';
|
|
2
|
+
/**
|
|
3
|
+
* A signed-in user's name and email, from their verified pass, for the
|
|
4
|
+
* handover form to show read-only instead of asking. `null` for anonymous
|
|
5
|
+
* visitors (the form asks as usual); `undefined` while loading. The server
|
|
6
|
+
* uses the verified values on submit whatever the form sends.
|
|
7
|
+
*/
|
|
8
|
+
export declare function useSignedInContact(sessionId: Id<'contactSessions'>, visitorId: string): {
|
|
9
|
+
name: string;
|
|
10
|
+
email: string;
|
|
11
|
+
} | null | undefined;
|
|
12
|
+
//# sourceMappingURL=useSignedInContact.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useSignedInContact.d.ts","sourceRoot":"","sources":["../../../../../src/features/chat/hooks/useSignedInContact.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,2CAA2C,CAAA;AAGnE;;;;;GAKG;AACH,wBAAgB,kBAAkB,CAAC,SAAS,EAAE,EAAE,CAAC,iBAAiB,CAAC,EAAE,SAAS,EAAE,MAAM;;;qBAErF"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { Id } from '@repo/backend/convex/_generated/dataModel';
|
|
2
|
+
/**
|
|
3
|
+
* The bootstrap token rides on every call of a chat (messages, status, files, the handover
|
|
4
|
+
* form): the server shows and accepts a signed-in user's chat only for a token of that
|
|
5
|
+
* user, so the next person in the tab never reads or writes the previous person's chat.
|
|
6
|
+
*/
|
|
7
|
+
export declare function chatTokenArg(): {
|
|
8
|
+
bootstrapToken?: Id<'widgetBootstrapTokens'>;
|
|
9
|
+
};
|
|
10
|
+
/** The server refused a call because the chat belongs to another signed-in user. */
|
|
11
|
+
export declare function isChatOfAnotherUserError(err: unknown): boolean;
|
|
12
|
+
/** As logout(): forget this tab's chats; the next message starts a new chat for whoever is on the page. */
|
|
13
|
+
export declare function startOverForAnotherUser(): void;
|
|
14
|
+
//# sourceMappingURL=chatOfAnotherUser.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"chatOfAnotherUser.d.ts","sourceRoot":"","sources":["../../../../../src/features/chat/lib/chatOfAnotherUser.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,2CAA2C,CAAA;AAInE;;;;GAIG;AACH,wBAAgB,YAAY,IAAI;IAAE,cAAc,CAAC,EAAE,EAAE,CAAC,uBAAuB,CAAC,CAAA;CAAE,CAG/E;AAED,oFAAoF;AACpF,wBAAgB,wBAAwB,CAAC,GAAG,EAAE,OAAO,GAAG,OAAO,CAI9D;AAED,2GAA2G;AAC3G,wBAAgB,uBAAuB,IAAI,IAAI,CAE9C"}
|
|
@@ -12,8 +12,12 @@
|
|
|
12
12
|
* - 'maintenance' the deployment is frozen for writes (a restore or a
|
|
13
13
|
* migration is in progress). Reads still work, so the
|
|
14
14
|
* visitor keeps their history; only sending is refused.
|
|
15
|
+
* - 'signed-out' the signed-in user's pass was refused on the hourly
|
|
16
|
+
* refresh (expired, or the host's userToken() failed)
|
|
17
|
+
* - 'unavailable' the chat is off for now (signed-in users are paused
|
|
18
|
+
* platform-wide); nothing the visitor can fix
|
|
15
19
|
* - 'unknown' any other thrown error
|
|
16
20
|
*/
|
|
17
|
-
export type SessionErrorReason = 'no-token' | 'unauthorized' | 'network' | 'maintenance' | 'unknown';
|
|
21
|
+
export type SessionErrorReason = 'no-token' | 'unauthorized' | 'signed-out' | 'unavailable' | 'network' | 'maintenance' | 'unknown';
|
|
18
22
|
export declare const sessionError: import("@preact/signals").Signal<SessionErrorReason | null>;
|
|
19
23
|
//# sourceMappingURL=session-error.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"session-error.d.ts","sourceRoot":"","sources":["../../../../../src/features/chat/state/session-error.ts"],"names":[],"mappings":"AAEA
|
|
1
|
+
{"version":3,"file":"session-error.d.ts","sourceRoot":"","sources":["../../../../../src/features/chat/state/session-error.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;;;;;;;;;;GAmBG;AACH,MAAM,MAAM,kBAAkB,GAC1B,UAAU,GACV,cAAc,GACd,YAAY,GACZ,aAAa,GACb,SAAS,GACT,aAAa,GACb,SAAS,CAAA;AAEb,eAAO,MAAM,YAAY,6DAA0C,CAAA"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import type { SessionHistoryEntry } from '../../../module/visitor/visitor.state';
|
|
2
|
+
interface ChatListProps {
|
|
3
|
+
/** This tab's chats, newest first. */
|
|
4
|
+
entries: SessionHistoryEntry[];
|
|
5
|
+
/** False when Widget Studio switched deleting chats off: only Copy reference stays. */
|
|
6
|
+
canDelete: boolean;
|
|
7
|
+
maintenance: boolean;
|
|
8
|
+
selecting: boolean;
|
|
9
|
+
onSelectingChange: (selecting: boolean) => void;
|
|
10
|
+
onOpen: (ref: string) => void;
|
|
11
|
+
onCopy: (ref: string) => void;
|
|
12
|
+
/** `returnFocus`: where focus goes back to when the confirm sheet closes. */
|
|
13
|
+
onDelete: (refs: string[], returnFocus: HTMLElement | null) => void;
|
|
14
|
+
}
|
|
15
|
+
/** "Pick up where you left off": each chat opens on tap, ⋯ copies or deletes it, Select deletes several. */
|
|
16
|
+
export declare function ChatList({ entries, canDelete, maintenance, selecting, onSelectingChange, onOpen, onCopy, onDelete }: ChatListProps): import("preact").JSX.Element;
|
|
17
|
+
export {};
|
|
18
|
+
//# sourceMappingURL=ChatList.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ChatList.d.ts","sourceRoot":"","sources":["../../../../../src/features/home/components/ChatList.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,uCAAuC,CAAA;AAKhF,UAAU,aAAa;IACrB,sCAAsC;IACtC,OAAO,EAAE,mBAAmB,EAAE,CAAA;IAC9B,uFAAuF;IACvF,SAAS,EAAE,OAAO,CAAA;IAClB,WAAW,EAAE,OAAO,CAAA;IACpB,SAAS,EAAE,OAAO,CAAA;IAClB,iBAAiB,EAAE,CAAC,SAAS,EAAE,OAAO,KAAK,IAAI,CAAA;IAC/C,MAAM,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,IAAI,CAAA;IAC7B,MAAM,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,IAAI,CAAA;IAC7B,6EAA6E;IAC7E,QAAQ,EAAE,CAAC,IAAI,EAAE,MAAM,EAAE,EAAE,WAAW,EAAE,WAAW,GAAG,IAAI,KAAK,IAAI,CAAA;CACpE;AAED,4GAA4G;AAC5G,wBAAgB,QAAQ,CAAC,EAAE,OAAO,EAAE,SAAS,EAAE,WAAW,EAAE,SAAS,EAAE,iBAAiB,EAAE,MAAM,EAAE,MAAM,EAAE,QAAQ,EAAE,EAAE,aAAa,gCA6LlI"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import type { SessionHistoryEntry } from '../../../module/visitor/visitor.state';
|
|
2
|
+
export type DeleteOutcome = {
|
|
3
|
+
kind: 'done';
|
|
4
|
+
requested: string[];
|
|
5
|
+
kept: string[];
|
|
6
|
+
} | {
|
|
7
|
+
kind: 'off';
|
|
8
|
+
};
|
|
9
|
+
interface DeleteChatsSheetProps {
|
|
10
|
+
/** The chats to delete, in list order. */
|
|
11
|
+
entries: SessionHistoryEntry[];
|
|
12
|
+
/** Write freeze: Delete stays disabled with a hint. */
|
|
13
|
+
maintenance: boolean;
|
|
14
|
+
onCancel: () => void;
|
|
15
|
+
onDone: (outcome: DeleteOutcome) => void;
|
|
16
|
+
}
|
|
17
|
+
/** "Delete this chat?" / "Delete 3 chats?" — one bottom sheet inside the widget. */
|
|
18
|
+
export declare function DeleteChatsSheet({ entries, maintenance, onCancel, onDone }: DeleteChatsSheetProps): import("preact").JSX.Element;
|
|
19
|
+
export {};
|
|
20
|
+
//# sourceMappingURL=DeleteChatsSheet.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"DeleteChatsSheet.d.ts","sourceRoot":"","sources":["../../../../../src/features/home/components/DeleteChatsSheet.tsx"],"names":[],"mappings":"AASA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,uCAAuC,CAAA;AAEhF,MAAM,MAAM,aAAa,GACrB;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,SAAS,EAAE,MAAM,EAAE,CAAC;IAAC,IAAI,EAAE,MAAM,EAAE,CAAA;CAAE,GACrD;IAAE,IAAI,EAAE,KAAK,CAAA;CAAE,CAAA;AAEnB,UAAU,qBAAqB;IAC7B,0CAA0C;IAC1C,OAAO,EAAE,mBAAmB,EAAE,CAAA;IAC9B,uDAAuD;IACvD,WAAW,EAAE,OAAO,CAAA;IACpB,QAAQ,EAAE,MAAM,IAAI,CAAA;IACpB,MAAM,EAAE,CAAC,OAAO,EAAE,aAAa,KAAK,IAAI,CAAA;CACzC;AAOD,oFAAoF;AACpF,wBAAgB,gBAAgB,CAAC,EAAE,OAAO,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,EAAE,EAAE,qBAAqB,gCAmGjG"}
|
|
@@ -4,6 +4,12 @@ interface HomeScreenProps {
|
|
|
4
4
|
botName: string;
|
|
5
5
|
/** Live org availability — same source as the chat header's presence dot. */
|
|
6
6
|
availability?: Availability;
|
|
7
|
+
/** Widget Studio hid the "Talk to a person" button: the card shows only the name. */
|
|
8
|
+
hidePersonButton: boolean;
|
|
9
|
+
/** Widget Studio switched off deleting chats: no delete controls. */
|
|
10
|
+
visitorChatDeletionOff: boolean;
|
|
11
|
+
/** Write freeze: deleting is disabled with a hint. */
|
|
12
|
+
maintenance: boolean;
|
|
7
13
|
onResetSession: () => void;
|
|
8
14
|
}
|
|
9
15
|
/**
|
|
@@ -13,6 +19,6 @@ interface HomeScreenProps {
|
|
|
13
19
|
* - sessionHistory has entries → show multi-entry history list
|
|
14
20
|
* - No history (new tab / after close) → show start chat + optional reference lookup
|
|
15
21
|
*/
|
|
16
|
-
export declare function HomeScreen({ botName, availability, onResetSession }: HomeScreenProps): import("preact").JSX.Element;
|
|
22
|
+
export declare function HomeScreen({ botName, availability, hidePersonButton, visitorChatDeletionOff, maintenance, onResetSession }: HomeScreenProps): import("preact").JSX.Element;
|
|
17
23
|
export {};
|
|
18
24
|
//# sourceMappingURL=HomeScreen.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"HomeScreen.d.ts","sourceRoot":"","sources":["../../../../../src/features/home/components/HomeScreen.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"HomeScreen.d.ts","sourceRoot":"","sources":["../../../../../src/features/home/components/HomeScreen.tsx"],"names":[],"mappings":"AAQA,OAAO,EAAoB,KAAK,YAAY,EAAE,MAAM,YAAY,CAAA;AAOhE,UAAU,eAAe;IACvB,6DAA6D;IAC7D,OAAO,EAAE,MAAM,CAAA;IACf,6EAA6E;IAC7E,YAAY,CAAC,EAAE,YAAY,CAAA;IAC3B,qFAAqF;IACrF,gBAAgB,EAAE,OAAO,CAAA;IACzB,qEAAqE;IACrE,sBAAsB,EAAE,OAAO,CAAA;IAC/B,sDAAsD;IACtD,WAAW,EAAE,OAAO,CAAA;IAEpB,cAAc,EAAE,MAAM,IAAI,CAAA;CAC3B;AAED;;;;;;GAMG;AACH,wBAAgB,UAAU,CAAC,EAAE,OAAO,EAAE,YAAY,EAAE,gBAAgB,EAAE,sBAAsB,EAAE,WAAW,EAAE,cAAc,EAAE,EAAE,eAAe,gCAiN3I"}
|
|
@@ -6,6 +6,12 @@ export { type WidgetLocale, SUPPORTED_LOCALES as WIDGET_LOCALES, WIDGET_DEFAULT_
|
|
|
6
6
|
* Initialised to 'de' (default); overridden in WidgetShell on mount via resolveWidgetLocale.
|
|
7
7
|
*/
|
|
8
8
|
export declare const locale: import("@preact/signals").Signal<"de" | "en">;
|
|
9
|
+
/** Du or Sie for the fixed German texts. English has one form. */
|
|
10
|
+
export type WidgetAddressForm = 'informal' | 'formal';
|
|
11
|
+
/** The widget's address form; set from the resolved config in WidgetShell. */
|
|
12
|
+
export declare const addressForm: import("@preact/signals").Signal<WidgetAddressForm>;
|
|
13
|
+
/** The catalogue for a locale and an address form; only German has a formal one. */
|
|
14
|
+
export declare function stringsFor(localeKey: 'en' | 'de', form: WidgetAddressForm): WidgetStrings;
|
|
9
15
|
/**
|
|
10
16
|
* Returns the current locale's string dictionary.
|
|
11
17
|
* Reactive — components that call this re-render when locale changes.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/i18n/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAM,KAAK,aAAa,EAAE,MAAM,cAAc,CAAA;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/i18n/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAM,KAAK,aAAa,EAAE,MAAM,cAAc,CAAA;AAKrD,YAAY,EAAE,aAAa,EAAE,CAAA;AAC7B,OAAO,EACL,KAAK,YAAY,EACjB,iBAAiB,IAAI,cAAc,EACnC,qBAAqB,EACrB,kBAAkB,GACnB,MAAM,UAAU,CAAA;AAEjB;;;GAGG;AACH,eAAO,MAAM,MAAM,+CAA4B,CAAA;AAI/C,kEAAkE;AAClE,MAAM,MAAM,iBAAiB,GAAG,UAAU,GAAG,QAAQ,CAAA;AAErD,8EAA8E;AAC9E,eAAO,MAAM,WAAW,qDAAwC,CAAA;AAEhE,oFAAoF;AACpF,wBAAgB,UAAU,CAAC,SAAS,EAAE,IAAI,GAAG,IAAI,EAAE,IAAI,EAAE,iBAAiB,GAAG,aAAa,CAEzF;AAED;;;;;;;GAOG;AACH,wBAAgB,SAAS,IAAI,aAAa,CAGzC;AAED;;;GAGG;AACH,wBAAgB,SAAS,CAAC,IAAI,EAAE,IAAI,GAAG,IAAI,GAAG,IAAI,CAOjD"}
|