@nlxai/touchpoint-ui 1.0.4-alpha.2 → 1.0.4

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.
@@ -0,0 +1,10 @@
1
+ import { FC, ReactNode } from 'react';
2
+ import { ColorMode, Theme } from './types';
3
+ /**
4
+ * @internal
5
+ */
6
+ export declare const Container: FC<{
7
+ children: ReactNode;
8
+ mode: ColorMode;
9
+ theme: Partial<Theme>;
10
+ }>;
package/lib/types.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { BotMessage } from '@nlxai/chat-core';
1
+ import { BotMessage, ConversationHandler } from '@nlxai/chat-core';
2
2
  import { FC } from 'react';
3
3
  /**
4
4
  * Window size configuration
@@ -8,10 +8,6 @@ export type WindowSize = "half" | "full";
8
8
  * Color mode configuration (light/dark modes)
9
9
  */
10
10
  export type ColorMode = "light" | "dark";
11
- /**
12
- * Logo URL if applicable. May be specified as a single image URL or as an object by color mode (light/dark)
13
- */
14
- export type LogoUrl = string | Record<ColorMode, string>;
15
11
  /**
16
12
  * Choice message with metadata
17
13
  */
@@ -38,6 +34,10 @@ export type CustomModalityComponent<Data> = FC<{
38
34
  * The payload of the Custom Modality. The schema is defined in Dialog Studio settings.
39
35
  */
40
36
  data: Data;
37
+ /**
38
+ * Conversation handler instance
39
+ */
40
+ conversationHandler: ConversationHandler;
41
41
  }>;
42
42
  /**
43
43
  * The full theme expressed as CSS custom properties
@@ -135,4 +135,12 @@ export interface Theme {
135
135
  * Secondary error color
136
136
  */
137
137
  errorSecondary: string;
138
+ /**
139
+ * Inner border radius: used for most buttons
140
+ */
141
+ innerBorderRadius: string;
142
+ /**
143
+ * Outer border radius: generally used for elements that contain buttons that have inner border radius. Also used by the launch button.
144
+ */
145
+ outerBorderRadius: string;
138
146
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nlxai/touchpoint-ui",
3
- "version": "1.0.4-alpha.2",
3
+ "version": "1.0.4",
4
4
  "description": "Web UI for Touchpoint",
5
5
  "type": "module",
6
6
  "main": "lib/index.js",
@@ -24,7 +24,7 @@
24
24
  "tsc": "tsc"
25
25
  },
26
26
  "dependencies": {
27
- "@nlxai/chat-core": "^1.0.4-alpha.0",
27
+ "@nlxai/chat-core": "^1.0.4",
28
28
  "@react-hookz/web": "^25.0.1",
29
29
  "@react-input/mask": "^2.0.4",
30
30
  "clsx": "^2.1.1",
@@ -50,11 +50,11 @@
50
50
  "postcss": "^8.4.38",
51
51
  "tailwindcss": "^3.4.3",
52
52
  "typescript": "^5.4.5",
53
- "vite": "^5.2.11",
53
+ "vite": "^4.5.6",
54
54
  "vite-plugin-dts": "^4.5.0"
55
55
  },
56
56
  "publishConfig": {
57
57
  "access": "public"
58
58
  },
59
- "gitHead": "127059e95fb42d2a6943d7f3ff87a57df73582b2"
59
+ "gitHead": "27ff05880575d5e4656c5d22dd85d29e9490d9d2"
60
60
  }
@@ -14,8 +14,8 @@ module.exports = {
14
14
  content: "608px",
15
15
  },
16
16
  borderRadius: {
17
- base: "12px",
18
- plus: "20px",
17
+ inner: "var(--inner-border-radius)",
18
+ outer: "var(--outer-border-radius)",
19
19
  },
20
20
  zIndex: {
21
21
  touchpoint: 1000,
@@ -1,12 +0,0 @@
1
- import { FC, Dispatch, SetStateAction } from 'react';
2
- import { ConversationHandler } from '@nlxai/chat-core';
3
- import { WindowSize } from '../types';
4
- interface ChatSettingsProps {
5
- onClose: () => void;
6
- handler: ConversationHandler;
7
- windowSize: WindowSize;
8
- setWindowSizeOverride: Dispatch<SetStateAction<WindowSize | null>>;
9
- className?: string;
10
- }
11
- export declare const ChatSettings: FC<ChatSettingsProps>;
12
- export {};
package/lib/context.d.ts DELETED
@@ -1,6 +0,0 @@
1
- import { ConversationHandler } from '@nlxai/chat-core';
2
- export interface ContextValue {
3
- handler: ConversationHandler | null;
4
- }
5
- export declare const Context: import('react').Context<ContextValue>;
6
- export declare const useTouchpointContext: () => ContextValue;