@nethesis/chat-island 0.1.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 +41 -0
- package/dist/ChatIsland.d.ts +20 -0
- package/dist/api.d.ts +6 -0
- package/dist/chat-island-sw.js +18 -0
- package/dist/components/Avatar.d.ts +18 -0
- package/dist/components/Button.d.ts +23 -0
- package/dist/components/ChatWindow.d.ts +15 -0
- package/dist/components/Composer.d.ts +6 -0
- package/dist/components/Dock.d.ts +6 -0
- package/dist/components/EmojiPicker.d.ts +6 -0
- package/dist/components/MessageList.d.ts +22 -0
- package/dist/components/NewChat.d.ts +4 -0
- package/dist/drag.d.ts +10 -0
- package/dist/events.d.ts +34 -0
- package/dist/index.css +2 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +4887 -0
- package/dist/ogg.d.ts +4 -0
- package/dist/push.d.ts +6 -0
- package/dist/shortcodes-table.d.ts +2 -0
- package/dist/shortcodes.d.ts +2 -0
- package/dist/sound.d.ts +2 -0
- package/dist/store.d.ts +42 -0
- package/dist/types.d.ts +67 -0
- package/dist/xmpp.d.ts +96 -0
- package/dist-widget/chat-island-sw.js +18 -0
- package/dist-widget/index.widget.css +2 -0
- package/dist-widget/index.widget.js +9 -0
- package/package.json +49 -0
package/README.md
ADDED
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
# chat-island
|
|
2
|
+
|
|
3
|
+
NethVoice chat widget (XMPP) for nethvoice-cti, NethLink and any web page.
|
|
4
|
+
|
|
5
|
+
```tsx
|
|
6
|
+
import { ChatIsland } from '@nethesis/chat-island'
|
|
7
|
+
import '@nethesis/chat-island/dist/index.css'
|
|
8
|
+
|
|
9
|
+
<ChatIsland dataConfig={btoa(`${ctiHost}:${username}:${jwt}`)} serviceWorker="/chat-island-sw.js" />
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
Serve `dist/chat-island-sw.js` from the host for notifications with the tab closed.
|
|
13
|
+
|
|
14
|
+
## Events
|
|
15
|
+
|
|
16
|
+
| Event | Direction | Detail |
|
|
17
|
+
| --- | --- | --- |
|
|
18
|
+
| `chat-island-open` | in | `{ username }` colleague or group address |
|
|
19
|
+
| `chat-island-close` | in | |
|
|
20
|
+
| `chat-island-new` | in | open the new chat panel |
|
|
21
|
+
| `chat-island-delete` | in | `{ username }` purge a conversation, leave or destroy a group |
|
|
22
|
+
| `chat-island-contacts` | in | `{ contacts }` names, avatars, presence, number |
|
|
23
|
+
| `chat-island-conversations-request` | in | ask for the list |
|
|
24
|
+
| `chat-island-conversations` | out | `{ conversations }` newest first |
|
|
25
|
+
| `chat-island-unread` | out | `{ total }` |
|
|
26
|
+
| `chat-island-message` | out | every new message |
|
|
27
|
+
| `chat-island-status` | out | `{ status }` connecting, online, offline, error, unauthorized |
|
|
28
|
+
| `chat-island-error` | out | `{ scope, message }` |
|
|
29
|
+
| `chat-island-push` | out | `{ enabled }` |
|
|
30
|
+
| `chat-island-call` | out | `{ username, number }` |
|
|
31
|
+
| `chat-island-notify` | out | `{ peer, name, body }` message not in view |
|
|
32
|
+
|
|
33
|
+
## Develop
|
|
34
|
+
|
|
35
|
+
```sh
|
|
36
|
+
npm install
|
|
37
|
+
npm run dev
|
|
38
|
+
npm run build && npm run build:widget
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
A tag publishes the package to npm.
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import './index.css';
|
|
2
|
+
export interface ChatIslandProps {
|
|
3
|
+
/** Base64 of "<cti_host>:<cti_username>:<cti_token>", the same shape phone-island uses. */
|
|
4
|
+
dataConfig: string;
|
|
5
|
+
/** Where the island sits; default bottom-right. */
|
|
6
|
+
position?: 'bottom-right' | 'bottom-left';
|
|
7
|
+
/** Force dark theme; by default follows a `dark` class on <html>. */
|
|
8
|
+
dark?: boolean;
|
|
9
|
+
/** URL of chat-island-sw.js served by the host app; enables notifications when the tab is closed. */
|
|
10
|
+
serviceWorker?: string;
|
|
11
|
+
/** How many chat heads the dock keeps; older ones drop off. Default 5. */
|
|
12
|
+
maxHeads?: number;
|
|
13
|
+
/** Show the "new chat" button with the colleague picker. Off when the host has its own list. Default true. */
|
|
14
|
+
newChatButton?: boolean;
|
|
15
|
+
/** Notification permission: 'auto' asks once online, 'click' waits for the bell. Default 'click'. */
|
|
16
|
+
notifications?: 'auto' | 'click';
|
|
17
|
+
/** Play a short chime when a message arrives and its window is not in view (default true). */
|
|
18
|
+
sound?: boolean;
|
|
19
|
+
}
|
|
20
|
+
export declare function ChatIsland({ dataConfig, position, dark, serviceWorker, maxHeads, newChatButton, notifications, sound }: ChatIslandProps): import("react").JSX.Element | null;
|
package/dist/api.d.ts
ADDED
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import type { Contact } from './types';
|
|
2
|
+
export declare function fetchContacts(host: string, token: string, me: string): Promise<Contact[]>;
|
|
3
|
+
/** Colleagues with the mobile app registered for push: a message reaches their phone even when they are not in the chat. */
|
|
4
|
+
export declare function fetchMobile(host: string, token: string): Promise<string[]>;
|
|
5
|
+
/** Forget a conversation on the server: my archive with that colleague or group is purged. */
|
|
6
|
+
export declare function deleteHistory(host: string, token: string, peer: string): Promise<void>;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
// chat-island service worker: shows chat Web Push notifications, opens the conversation on click.
|
|
2
|
+
self.addEventListener('push', (event) => {
|
|
3
|
+
let data = {}
|
|
4
|
+
try { data = event.data ? event.data.json() : {} } catch { data = { body: event.data && event.data.text() } }
|
|
5
|
+
const title = data.name || data.from || 'New message'
|
|
6
|
+
event.waitUntil(self.registration.showNotification(title, { body: data.body || '', tag: 'chat-' + (data.from || ''), renotify: true, data }))
|
|
7
|
+
})
|
|
8
|
+
self.addEventListener('notificationclick', (event) => {
|
|
9
|
+
event.notification.close()
|
|
10
|
+
const from = event.notification.data && event.notification.data.from
|
|
11
|
+
// The app's own tab, the one under this worker's scope, not any window of the site.
|
|
12
|
+
const scope = self.registration.scope
|
|
13
|
+
event.waitUntil(self.clients.matchAll({ type: 'window', includeUncontrolled: true }).then((list) => {
|
|
14
|
+
const target = list.find((c) => c.url.startsWith(scope)) || list[0]
|
|
15
|
+
if (target) { target.focus(); target.postMessage({ type: 'chat-island-open', username: from }) }
|
|
16
|
+
else self.clients.openWindow(scope)
|
|
17
|
+
}))
|
|
18
|
+
})
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import type { Contact } from '../types';
|
|
2
|
+
export declare function Avatar({ contact, username, size }: {
|
|
3
|
+
contact?: Contact;
|
|
4
|
+
username: string;
|
|
5
|
+
size?: number;
|
|
6
|
+
}): import("react").JSX.Element;
|
|
7
|
+
/** Green: connected to the chat. Red: the CTI says busy or do-not-disturb. Green as well when only the mobile app is registered: the text says Mobile. Grey: not reachable. */
|
|
8
|
+
export declare function PresenceDot({ online, presence, mobile }: {
|
|
9
|
+
online?: boolean;
|
|
10
|
+
presence?: string;
|
|
11
|
+
mobile?: boolean;
|
|
12
|
+
}): import("react").JSX.Element;
|
|
13
|
+
/** A group: its initials on the island's accent colour, so it never looks like a person. */
|
|
14
|
+
export declare function GroupAvatar({ name, size, avatar }: {
|
|
15
|
+
name: string;
|
|
16
|
+
size?: number;
|
|
17
|
+
avatar?: string;
|
|
18
|
+
}): import("react").JSX.Element;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import type { ComponentPropsWithRef, ReactNode } from 'react';
|
|
2
|
+
/** The phone-island button, verbatim classes with the ci- prefix, so the two islands look alike. */
|
|
3
|
+
type Variant = 'default' | 'green' | 'red' | 'neutral' | 'transparent' | 'small' | 'call';
|
|
4
|
+
export declare function Button({ variant, className, children, ...props }: ComponentPropsWithRef<'button'> & {
|
|
5
|
+
variant: Variant;
|
|
6
|
+
children: ReactNode;
|
|
7
|
+
}): import("react").JSX.Element;
|
|
8
|
+
export declare const Icon: {
|
|
9
|
+
chat: import("react").JSX.Element;
|
|
10
|
+
bell: import("react").JSX.Element;
|
|
11
|
+
clip: import("react").JSX.Element;
|
|
12
|
+
send: import("react").JSX.Element;
|
|
13
|
+
phone: import("react").JSX.Element;
|
|
14
|
+
mic: import("react").JSX.Element;
|
|
15
|
+
camera: import("react").JSX.Element;
|
|
16
|
+
trash: import("react").JSX.Element;
|
|
17
|
+
minus: import("react").JSX.Element;
|
|
18
|
+
close: import("react").JSX.Element;
|
|
19
|
+
smile: import("react").JSX.Element;
|
|
20
|
+
react: import("react").JSX.Element;
|
|
21
|
+
search: import("react").JSX.Element;
|
|
22
|
+
};
|
|
23
|
+
export {};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export interface WindowActions {
|
|
2
|
+
send: (peer: string, text: string) => Promise<void>;
|
|
3
|
+
createGroup: (name: string, members: string[], avatar?: string) => Promise<void>;
|
|
4
|
+
typing: (peer: string, composing: boolean) => void;
|
|
5
|
+
upload: (peer: string, file: File) => void;
|
|
6
|
+
loadOlder: (peer: string) => void;
|
|
7
|
+
remove: (peer: string) => Promise<void>;
|
|
8
|
+
react: (peer: string, target: string, emoji: string) => Promise<void>;
|
|
9
|
+
}
|
|
10
|
+
/** The floating conversation: phone-island surface, radius and buttons. */
|
|
11
|
+
export declare function ChatWindow({ peer, actions, onDragStart }: {
|
|
12
|
+
peer: string;
|
|
13
|
+
actions: WindowActions;
|
|
14
|
+
onDragStart?: (e: React.PointerEvent) => void;
|
|
15
|
+
}): import("react").JSX.Element | null;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/** Messenger-style chat heads: one round avatar per conversation, plus the phone-island style buttons. */
|
|
2
|
+
/** pushButton: offer the bell to enable notifications; off when the host asks at start-up like phone-island does for the microphone. */
|
|
3
|
+
export declare function Dock({ onDragStart, pushButton }: {
|
|
4
|
+
onDragStart?: (e: React.PointerEvent) => void;
|
|
5
|
+
pushButton?: boolean;
|
|
6
|
+
}): import("react").JSX.Element;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import type { Message } from '../types';
|
|
2
|
+
/** The name at the end of a URL; a malformed escape (a%E0%A4) must not take the window down. */
|
|
3
|
+
export declare const fileName: (url: string) => string;
|
|
4
|
+
/** Attachments come from other people: only an https URL becomes a link, an image or a player. */
|
|
5
|
+
export declare const safeUrl: (url: string) => boolean;
|
|
6
|
+
/** Old Acrobits attachment JSON kept in the archive: encrypted on Acrobits, not viewable here. */
|
|
7
|
+
export declare const appAttachment: (body: string) => {
|
|
8
|
+
text?: string;
|
|
9
|
+
count: number;
|
|
10
|
+
} | null;
|
|
11
|
+
type Reactions = Record<string, Record<string, string[]>>;
|
|
12
|
+
export declare function MessageList({ messages, typing, onLoadOlder, hasOlder, group, reactions, me, onReact, }: {
|
|
13
|
+
messages: Message[];
|
|
14
|
+
typing: boolean;
|
|
15
|
+
hasOlder: boolean;
|
|
16
|
+
onLoadOlder: () => void;
|
|
17
|
+
group?: boolean;
|
|
18
|
+
reactions?: Reactions;
|
|
19
|
+
me?: string;
|
|
20
|
+
onReact?: (target: string, emoji: string) => void;
|
|
21
|
+
}): import("react").JSX.Element;
|
|
22
|
+
export {};
|
package/dist/drag.d.ts
ADDED
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/** Drag the island by its bottom-right anchor; the offset is kept per user, a tiny move is a click. */
|
|
2
|
+
export interface Anchor {
|
|
3
|
+
right: number;
|
|
4
|
+
bottom: number;
|
|
5
|
+
}
|
|
6
|
+
export declare function useDrag(rootRef: React.RefObject<HTMLElement | null>, storageKey: string): {
|
|
7
|
+
anchor: Anchor | null;
|
|
8
|
+
start: (e: React.PointerEvent) => void;
|
|
9
|
+
onClickCapture: (e: React.MouseEvent) => void;
|
|
10
|
+
};
|
package/dist/events.d.ts
ADDED
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import type { Contact, ConversationSummary, Message, Status } from './types';
|
|
2
|
+
export declare function emit(name: 'chat-island-unread', detail: {
|
|
3
|
+
total: number;
|
|
4
|
+
}): void;
|
|
5
|
+
export declare function emit(name: 'chat-island-message', detail: Message & {
|
|
6
|
+
peer: string;
|
|
7
|
+
}): void;
|
|
8
|
+
export declare function emit(name: 'chat-island-status', detail: {
|
|
9
|
+
status: Status;
|
|
10
|
+
error?: string;
|
|
11
|
+
}): void;
|
|
12
|
+
export declare function emit(name: 'chat-island-error', detail: {
|
|
13
|
+
scope: string;
|
|
14
|
+
message: string;
|
|
15
|
+
}): void;
|
|
16
|
+
export declare function emit(name: 'chat-island-push', detail: {
|
|
17
|
+
enabled: boolean;
|
|
18
|
+
}): void;
|
|
19
|
+
export declare function emit(name: 'chat-island-conversations', detail: {
|
|
20
|
+
conversations: ConversationSummary[];
|
|
21
|
+
}): void;
|
|
22
|
+
export declare function emit(name: 'chat-island-call', detail: {
|
|
23
|
+
username: string;
|
|
24
|
+
number: string;
|
|
25
|
+
}): void;
|
|
26
|
+
export declare function emit(name: 'chat-island-notify', detail: {
|
|
27
|
+
peer: string;
|
|
28
|
+
name: string;
|
|
29
|
+
body: string;
|
|
30
|
+
}): void;
|
|
31
|
+
export declare function listen<T>(name: string, handler: (detail: T) => void): () => void;
|
|
32
|
+
export type ContactsEvent = {
|
|
33
|
+
contacts: Contact[];
|
|
34
|
+
};
|
package/dist/index.css
ADDED
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
.chat-island-root,.chat-island-root *,.chat-island-root :before,.chat-island-root :after,.chat-island-root ::backdrop{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:#3b82f680;--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }.ci-fixed{position:fixed}.ci-absolute{position:absolute}.ci-relative{position:relative}.ci--left-1{left:-.25rem}.ci--right-1{right:-.25rem}.ci--right-1\.5{right:-.375rem}.ci--top-1{top:-.25rem}.ci-bottom-0{bottom:0}.ci-bottom-1{bottom:.25rem}.ci-bottom-2{bottom:.5rem}.ci-bottom-5{bottom:1.25rem}.ci-bottom-full{bottom:100%}.ci-left-0{left:0}.ci-left-1\/2{left:50%}.ci-left-2{left:.5rem}.ci-left-3{left:.75rem}.ci-left-4{left:1rem}.ci-right-0{right:0}.ci-right-3{right:.75rem}.ci-right-4{right:1rem}.ci-top-16{top:4rem}.ci-z-10{z-index:10}.ci-z-20{z-index:20}.ci-z-30{z-index:30}.ci-z-\[1\]{z-index:1}.ci-z-\[9999\]{z-index:9999}.ci-m-0{margin:0}.ci-my-1{margin-top:.25rem;margin-bottom:.25rem}.ci--mt-1\.5{margin-top:-.375rem}.ci-mb-1{margin-bottom:.25rem}.ci-mb-3{margin-bottom:.75rem}.ci-mt-0\.5{margin-top:.125rem}.ci-mt-1{margin-top:.25rem}.ci-mt-2{margin-top:.5rem}.ci-block{display:block}.ci-flex{display:flex}.ci-grid{display:grid}.ci-hidden{display:none}.ci-h-10{height:2.5rem}.ci-h-12{height:3rem}.ci-h-2\.5{height:.625rem}.ci-h-3{height:.75rem}.ci-h-5{height:1.25rem}.ci-h-6{height:1.5rem}.ci-h-64{height:16rem}.ci-h-7{height:1.75rem}.ci-h-8{height:2rem}.ci-h-9{height:2.25rem}.ci-h-\[30rem\]{height:30rem}.ci-h-full{height:100%}.ci-max-h-32{max-height:8rem}.ci-max-h-60{max-height:15rem}.ci-max-h-64{max-height:16rem}.ci-max-h-\[30rem\]{max-height:30rem}.ci-min-h-0{min-height:0}.ci-w-0{width:0}.ci-w-10{width:2.5rem}.ci-w-12{width:3rem}.ci-w-2\.5{width:.625rem}.ci-w-3{width:.75rem}.ci-w-5{width:1.25rem}.ci-w-7{width:1.75rem}.ci-w-8{width:2rem}.ci-w-9{width:2.25rem}.ci-w-\[21rem\]{width:21rem}.ci-w-\[22rem\]{width:22rem}.ci-w-auto{width:auto}.ci-w-full{width:100%}.ci-min-w-0{min-width:0}.ci-min-w-5{min-width:1.25rem}.ci-max-w-\[80\%\]{max-width:80%}.ci-max-w-full{max-width:100%}.ci-flex-1{flex:1}.ci-shrink-0{flex-shrink:0}.ci--translate-x-1\/2{--tw-translate-x:-50%;transform:translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.ci-rotate-45{--tw-rotate:45deg;transform:translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.ci-transform{transform:translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}@keyframes ci-pulse{50%{opacity:.5}}.ci-animate-pulse{animation:2s cubic-bezier(.4,0,.6,1) infinite ci-pulse}.ci-cursor-grab{cursor:grab}.ci-cursor-pointer{cursor:pointer}.ci-cursor-text{cursor:text}.ci-touch-none{touch-action:none}.ci-select-none{-webkit-user-select:none;user-select:none}.ci-select-text{-webkit-user-select:text;user-select:text}.ci-resize-none{resize:none}.ci-list-none{list-style-type:none}.ci-grid-cols-7{grid-template-columns:repeat(7,minmax(0,1fr))}.ci-flex-col{flex-direction:column}.ci-flex-col-reverse{flex-direction:column-reverse}.ci-flex-wrap{flex-wrap:wrap}.ci-content-center{align-content:center}.ci-items-start{align-items:flex-start}.ci-items-end{align-items:flex-end}.ci-items-center{align-items:center}.ci-justify-start{justify-content:flex-start}.ci-justify-end{justify-content:flex-end}.ci-justify-center{justify-content:center}.ci-gap-0\.5{gap:.125rem}.ci-gap-1{gap:.25rem}.ci-gap-1\.5{gap:.375rem}.ci-gap-2{gap:.5rem}.ci-gap-3{gap:.75rem}.ci-space-y-1>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0;margin-top:calc(.25rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.25rem * var(--tw-space-y-reverse))}.ci-self-center{align-self:center}.ci-overflow-hidden{overflow:hidden}.ci-overflow-x-auto{overflow-x:auto}.ci-overflow-y-auto{overflow-y:auto}.ci-truncate{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.ci-whitespace-nowrap{white-space:nowrap}.ci-whitespace-pre{white-space:pre}.ci-whitespace-pre-wrap{white-space:pre-wrap}.ci-break-words{overflow-wrap:break-word}.ci-break-all{word-break:break-all}.ci-rounded{border-radius:.25rem}.ci-rounded-2xl{border-radius:1rem}.ci-rounded-3xl{border-radius:1.5rem}.ci-rounded-full{border-radius:9999px}.ci-rounded-lg{border-radius:.5rem}.ci-rounded-xl{border-radius:.75rem}.ci-rounded-b-3xl{border-bottom-right-radius:1.5rem;border-bottom-left-radius:1.5rem}.ci-rounded-t-3xl{border-top-left-radius:1.5rem;border-top-right-radius:1.5rem}.ci-rounded-bl-lg{border-bottom-left-radius:.5rem}.ci-rounded-br-lg{border-bottom-right-radius:.5rem}.ci-border{border-width:1px}.ci-border-0{border-width:0}.ci-border-b{border-bottom-width:1px}.ci-border-b-2{border-bottom-width:2px}.ci-border-t{border-top-width:1px}.ci-border-solid{border-style:solid}.ci-border-emerald-400{--tw-border-opacity:1;border-color:rgb(52 211 153/var(--tw-border-opacity,1))}.ci-border-gray-300{--tw-border-opacity:1;border-color:rgb(209 213 219/var(--tw-border-opacity,1))}.ci-border-gray-400{--tw-border-opacity:1;border-color:rgb(156 163 175/var(--tw-border-opacity,1))}.ci-border-gray-700{--tw-border-opacity:1;border-color:rgb(55 65 81/var(--tw-border-opacity,1))}.ci-border-iconSecondary{--tw-border-opacity:1;border-color:rgb(67 56 202/var(--tw-border-opacity,1))}.ci-border-transparent{border-color:#0000}.ci-bg-black\/10{background-color:#0000001a}.ci-bg-elevationL2{--tw-bg-opacity:1;background-color:rgb(243 244 246/var(--tw-bg-opacity,1))}.ci-bg-emerald-50{--tw-bg-opacity:1;background-color:rgb(236 253 245/var(--tw-bg-opacity,1))}.ci-bg-gray-200{--tw-bg-opacity:1;background-color:rgb(229 231 235/var(--tw-bg-opacity,1))}.ci-bg-gray-400{--tw-bg-opacity:1;background-color:rgb(156 163 175/var(--tw-bg-opacity,1))}.ci-bg-gray-50{--tw-bg-opacity:1;background-color:rgb(249 250 251/var(--tw-bg-opacity,1))}.ci-bg-gray-700{--tw-bg-opacity:1;background-color:rgb(55 65 81/var(--tw-bg-opacity,1))}.ci-bg-iconSecondary{--tw-bg-opacity:1;background-color:rgb(67 56 202/var(--tw-bg-opacity,1))}.ci-bg-phoneIslandActive{--tw-bg-opacity:1;background-color:rgb(55 65 81/var(--tw-bg-opacity,1))}.ci-bg-phoneIslandCall{--tw-bg-opacity:1;background-color:rgb(21 128 61/var(--tw-bg-opacity,1))}.ci-bg-phoneIslandClose{--tw-bg-opacity:1;background-color:rgb(185 28 28/var(--tw-bg-opacity,1))}.ci-bg-transparent{background-color:#0000}.ci-object-cover{-o-object-fit:cover;object-fit:cover}.ci-p-0{padding:0}.ci-p-1{padding:.25rem}.ci-p-2{padding:.5rem}.ci-px-1{padding-left:.25rem;padding-right:.25rem}.ci-px-1\.5{padding-left:.375rem;padding-right:.375rem}.ci-px-2{padding-left:.5rem;padding-right:.5rem}.ci-px-3{padding-left:.75rem;padding-right:.75rem}.ci-px-3\.5{padding-left:.875rem;padding-right:.875rem}.ci-px-4{padding-left:1rem;padding-right:1rem}.ci-px-5{padding-left:1.25rem;padding-right:1.25rem}.ci-py-0\.5{padding-top:.125rem;padding-bottom:.125rem}.ci-py-1{padding-top:.25rem;padding-bottom:.25rem}.ci-py-1\.5{padding-top:.375rem;padding-bottom:.375rem}.ci-py-2{padding-top:.5rem;padding-bottom:.5rem}.ci-py-2\.5{padding-top:.625rem;padding-bottom:.625rem}.ci-py-3{padding-top:.75rem;padding-bottom:.75rem}.ci-py-6{padding-top:1.5rem;padding-bottom:1.5rem}.ci-pb-1\.5{padding-bottom:.375rem}.ci-pb-2{padding-bottom:.5rem}.ci-pl-11{padding-left:2.75rem}.ci-pl-2{padding-left:.5rem}.ci-pl-2\.5{padding-left:.625rem}.ci-pr-1\.5{padding-right:.375rem}.ci-pr-2{padding-right:.5rem}.ci-pr-4{padding-right:1rem}.ci-pt-2{padding-top:.5rem}.ci-text-left{text-align:left}.ci-text-center{text-align:center}.ci-text-right{text-align:right}.ci-font-mono{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}.ci-font-sans{font-family:Poppins,Inter,system-ui,sans-serif}.ci-text-\[0\.85em\]{font-size:.85em}.ci-text-\[10px\]{font-size:10px}.ci-text-lg{font-size:1.125rem;line-height:1.75rem}.ci-text-sm{font-size:.875rem;line-height:1.25rem}.ci-text-xs{font-size:.75rem;line-height:1rem}.ci-font-light{font-weight:300}.ci-font-medium{font-weight:500}.ci-italic{font-style:italic}.ci-not-italic{font-style:normal}.ci-leading-4{line-height:1rem}.ci-leading-none{line-height:1}.ci-tracking-wide{letter-spacing:.025em}.ci-text-gray-50{--tw-text-opacity:1;color:rgb(249 250 251/var(--tw-text-opacity,1))}.ci-text-gray-500{--tw-text-opacity:1;color:rgb(107 114 128/var(--tw-text-opacity,1))}.ci-text-gray-700{--tw-text-opacity:1;color:rgb(55 65 81/var(--tw-text-opacity,1))}.ci-text-gray-900{--tw-text-opacity:1;color:rgb(17 24 39/var(--tw-text-opacity,1))}.ci-text-inherit{color:inherit}.ci-text-primaryInvert{--tw-text-opacity:1;color:rgb(249 250 251/var(--tw-text-opacity,1))}.ci-text-secondaryNeutral{--tw-text-opacity:1;color:rgb(55 65 81/var(--tw-text-opacity,1))}.ci-text-white{--tw-text-opacity:1;color:rgb(255 255 255/var(--tw-text-opacity,1))}.ci-underline{text-decoration-line:underline}.ci-opacity-0{opacity:0}.ci-opacity-100{opacity:1}.ci-opacity-60{opacity:.6}.ci-opacity-80{opacity:.8}.ci-shadow-2xl{--tw-shadow:0 25px 50px -12px #00000040;--tw-shadow-colored:0 25px 50px -12px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000), var(--tw-ring-shadow,0 0 #0000), var(--tw-shadow)}.ci-shadow-lg{--tw-shadow:0 10px 15px -3px #0000001a, 0 4px 6px -4px #0000001a;--tw-shadow-colored:0 10px 15px -3px var(--tw-shadow-color), 0 4px 6px -4px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000), var(--tw-ring-shadow,0 0 #0000), var(--tw-shadow)}.ci-shadow-sm{--tw-shadow:0 1px 2px 0 #0000000d;--tw-shadow-colored:0 1px 2px 0 var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000), var(--tw-ring-shadow,0 0 #0000), var(--tw-shadow)}.ci-shadow-xl{--tw-shadow:0 20px 25px -5px #0000001a, 0 8px 10px -6px #0000001a;--tw-shadow-colored:0 20px 25px -5px var(--tw-shadow-color), 0 8px 10px -6px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000), var(--tw-ring-shadow,0 0 #0000), var(--tw-shadow)}.ci-outline-none{outline-offset:2px;outline:2px solid #0000}.ci-ring-1{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow,0 0 #0000)}.ci-ring-2{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow,0 0 #0000)}.ci-ring-gray-300{--tw-ring-opacity:1;--tw-ring-color:rgb(209 213 219/var(--tw-ring-opacity,1))}.ci-ring-gray-50{--tw-ring-opacity:1;--tw-ring-color:rgb(249 250 251/var(--tw-ring-opacity,1))}.ci-ring-iconSecondary{--tw-ring-opacity:1;--tw-ring-color:rgb(67 56 202/var(--tw-ring-opacity,1))}.ci-transition-all{transition-property:all;transition-duration:.15s;transition-timing-function:cubic-bezier(.4,0,.2,1)}.ci-transition-colors{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-duration:.15s;transition-timing-function:cubic-bezier(.4,0,.2,1)}.ci-transition-transform{transition-property:transform;transition-duration:.15s;transition-timing-function:cubic-bezier(.4,0,.2,1)}.ci-duration-200{transition-duration:.2s}.chat-island-root,.chat-island-root *{box-sizing:border-box}.chat-island-root{font-family:Poppins,Inter,system-ui,sans-serif;font-size:14px;line-height:1.4}.chat-island-root button{font:inherit;cursor:pointer}.chat-island-root textarea,.chat-island-root input{font:inherit}.chat-island-root ::-webkit-scrollbar{width:6px}.chat-island-root ::-webkit-scrollbar-thumb{background:#9ca3af80;border-radius:9999px}.placeholder\:ci-text-gray-500::placeholder{--tw-text-opacity:1;color:rgb(107 114 128/var(--tw-text-opacity,1))}.hover\:ci-scale-105:hover{--tw-scale-x:1.05;--tw-scale-y:1.05;transform:translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.hover\:ci-scale-125:hover{--tw-scale-x:1.25;--tw-scale-y:1.25;transform:translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.hover\:ci-bg-gray-200:hover{--tw-bg-opacity:1;background-color:rgb(229 231 235/var(--tw-bg-opacity,1))}.hover\:ci-bg-gray-300:hover{--tw-bg-opacity:1;background-color:rgb(209 213 219/var(--tw-bg-opacity,1))}.hover\:ci-bg-gray-300\/70:hover{background-color:#d1d5dbb3}.hover\:ci-bg-gray-500:hover{--tw-bg-opacity:1;background-color:rgb(107 114 128/var(--tw-bg-opacity,1))}.hover\:ci-bg-phoneIslandCallHover:hover{--tw-bg-opacity:1;background-color:rgb(22 101 52/var(--tw-bg-opacity,1))}.hover\:ci-bg-phoneIslandCloseHover:hover{--tw-bg-opacity:1;background-color:rgb(153 27 27/var(--tw-bg-opacity,1))}.hover\:ci-opacity-100:hover{opacity:1}.focus\:ci-z-20:focus{z-index:20}.focus\:ci-opacity-100:focus{opacity:1}.focus\:ci-ring-0:focus{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(0px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow,0 0 #0000)}.focus\:ci-ring-2:focus{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow,0 0 #0000)}.focus\:ci-ring-emerald-500:focus{--tw-ring-opacity:1;--tw-ring-color:rgb(16 185 129/var(--tw-ring-opacity,1))}.focus\:ci-ring-gray-400:focus{--tw-ring-opacity:1;--tw-ring-color:rgb(156 163 175/var(--tw-ring-opacity,1))}.focus\:ci-ring-green-500:focus{--tw-ring-opacity:1;--tw-ring-color:rgb(34 197 94/var(--tw-ring-opacity,1))}.focus\:ci-ring-offset-2:focus{--tw-ring-offset-width:2px}.focus\:ci-ring-offset-white:focus{--tw-ring-offset-color:#fff}.active\:ci-cursor-grabbing:active{cursor:grabbing}.enabled\:hover\:ci-border-gray-500:hover:enabled{--tw-border-opacity:1;border-color:rgb(107 114 128/var(--tw-border-opacity,1))}.enabled\:hover\:ci-bg-gray-300\/70:hover:enabled{background-color:#d1d5dbb3}.enabled\:hover\:ci-bg-gray-500:hover:enabled{--tw-bg-opacity:1;background-color:rgb(107 114 128/var(--tw-bg-opacity,1))}.disabled\:ci-cursor-not-allowed:disabled{cursor:not-allowed}.disabled\:ci-opacity-40:disabled{opacity:.4}.ci-group:focus-within .group-focus-within\:ci-flex,.ci-group:hover .group-hover\:ci-flex{display:flex}.ci-group:hover .group-hover\:ci-opacity-100{opacity:1}.dark\:ci-border-emerald-600:is(.ci-dark *){--tw-border-opacity:1;border-color:rgb(5 150 105/var(--tw-border-opacity,1))}.dark\:ci-border-gray-600:is(.ci-dark *){--tw-border-opacity:1;border-color:rgb(75 85 99/var(--tw-border-opacity,1))}.dark\:ci-border-gray-700:is(.ci-dark *){--tw-border-opacity:1;border-color:rgb(55 65 81/var(--tw-border-opacity,1))}.dark\:ci-border-iconSecondaryDark:is(.ci-dark *){--tw-border-opacity:1;border-color:rgb(99 102 241/var(--tw-border-opacity,1))}.dark\:ci-bg-elevationL2Dark:is(.ci-dark *){--tw-bg-opacity:1;background-color:rgb(31 41 55/var(--tw-bg-opacity,1))}.dark\:ci-bg-emerald-950:is(.ci-dark *){--tw-bg-opacity:1;background-color:rgb(2 44 34/var(--tw-bg-opacity,1))}.dark\:ci-bg-gray-300:is(.ci-dark *){--tw-bg-opacity:1;background-color:rgb(209 213 219/var(--tw-bg-opacity,1))}.dark\:ci-bg-gray-600:is(.ci-dark *){--tw-bg-opacity:1;background-color:rgb(75 85 99/var(--tw-bg-opacity,1))}.dark\:ci-bg-gray-800:is(.ci-dark *){--tw-bg-opacity:1;background-color:rgb(31 41 55/var(--tw-bg-opacity,1))}.dark\:ci-bg-gray-900:is(.ci-dark *){--tw-bg-opacity:1;background-color:rgb(17 24 39/var(--tw-bg-opacity,1))}.dark\:ci-bg-gray-950:is(.ci-dark *){--tw-bg-opacity:1;background-color:rgb(3 7 18/var(--tw-bg-opacity,1))}.dark\:ci-bg-iconSecondaryDark:is(.ci-dark *){--tw-bg-opacity:1;background-color:rgb(99 102 241/var(--tw-bg-opacity,1))}.dark\:ci-bg-phoneIslandActiveDark:is(.ci-dark *){--tw-bg-opacity:1;background-color:rgb(209 213 219/var(--tw-bg-opacity,1))}.dark\:ci-bg-phoneIslandCallDark:is(.ci-dark *){--tw-bg-opacity:1;background-color:rgb(34 197 94/var(--tw-bg-opacity,1))}.dark\:ci-bg-phoneIslandCloseDark:is(.ci-dark *){--tw-bg-opacity:1;background-color:rgb(239 68 68/var(--tw-bg-opacity,1))}.dark\:ci-bg-white\/10:is(.ci-dark *){background-color:#ffffff1a}.dark\:ci-text-gray-200:is(.ci-dark *){--tw-text-opacity:1;color:rgb(229 231 235/var(--tw-text-opacity,1))}.dark\:ci-text-gray-400:is(.ci-dark *){--tw-text-opacity:1;color:rgb(156 163 175/var(--tw-text-opacity,1))}.dark\:ci-text-gray-900:is(.ci-dark *){--tw-text-opacity:1;color:rgb(17 24 39/var(--tw-text-opacity,1))}.dark\:ci-text-gray-950:is(.ci-dark *){--tw-text-opacity:1;color:rgb(3 7 18/var(--tw-text-opacity,1))}.dark\:ci-text-primaryInvertDark:is(.ci-dark *){--tw-text-opacity:1;color:rgb(17 24 39/var(--tw-text-opacity,1))}.dark\:ci-text-secondaryNeutralDark:is(.ci-dark *){--tw-text-opacity:1;color:rgb(229 231 235/var(--tw-text-opacity,1))}.dark\:ci-text-white:is(.ci-dark *){--tw-text-opacity:1;color:rgb(255 255 255/var(--tw-text-opacity,1))}.dark\:ci-ring-gray-700:is(.ci-dark *){--tw-ring-opacity:1;--tw-ring-color:rgb(55 65 81/var(--tw-ring-opacity,1))}.dark\:ci-ring-gray-950:is(.ci-dark *){--tw-ring-opacity:1;--tw-ring-color:rgb(3 7 18/var(--tw-ring-opacity,1))}.dark\:ci-ring-iconSecondaryDark:is(.ci-dark *){--tw-ring-opacity:1;--tw-ring-color:rgb(99 102 241/var(--tw-ring-opacity,1))}.dark\:placeholder\:ci-text-gray-400:is(.ci-dark *)::-moz-placeholder{--tw-text-opacity:1;color:rgb(156 163 175/var(--tw-text-opacity,1))}.dark\:placeholder\:ci-text-gray-400:is(.ci-dark *)::placeholder{--tw-text-opacity:1;color:rgb(156 163 175/var(--tw-text-opacity,1))}.dark\:hover\:ci-bg-gray-50:hover:is(.ci-dark *){--tw-bg-opacity:1;background-color:rgb(249 250 251/var(--tw-bg-opacity,1))}.dark\:hover\:ci-bg-gray-600:hover:is(.ci-dark *){--tw-bg-opacity:1;background-color:rgb(75 85 99/var(--tw-bg-opacity,1))}.dark\:hover\:ci-bg-gray-700\/30:hover:is(.ci-dark *){background-color:#3741514d}.dark\:hover\:ci-bg-gray-800:hover:is(.ci-dark *){--tw-bg-opacity:1;background-color:rgb(31 41 55/var(--tw-bg-opacity,1))}.dark\:hover\:ci-bg-phoneIslandCallHoverDark:hover:is(.ci-dark *){--tw-bg-opacity:1;background-color:rgb(134 239 172/var(--tw-bg-opacity,1))}.dark\:hover\:ci-bg-phoneIslandCloseHoverDark:hover:is(.ci-dark *){--tw-bg-opacity:1;background-color:rgb(252 165 165/var(--tw-bg-opacity,1))}.dark\:focus\:ci-ring-emerald-300:focus:is(.ci-dark *){--tw-ring-opacity:1;--tw-ring-color:rgb(110 231 183/var(--tw-ring-opacity,1))}.dark\:focus\:ci-ring-gray-500:focus:is(.ci-dark *){--tw-ring-opacity:1;--tw-ring-color:rgb(107 114 128/var(--tw-ring-opacity,1))}.dark\:focus\:ci-ring-offset-black:focus:is(.ci-dark *){--tw-ring-offset-color:#000}.dark\:enabled\:hover\:ci-bg-gray-700\/30:hover:enabled:is(.ci-dark *){background-color:#3741514d}
|
|
2
|
+
/*$vite$:1*/
|
package/dist/index.d.ts
ADDED