ttc-ai-client
Version:
TypeScript client sdk for TTC AI services with decorators and schema validation.
68 lines • 2.91 kB
JavaScript
;
/**
* TTC RPC Client Library
*
* Complete Theme Configuration Example:
*
* ```typescript
* initTTCChatWidget({
* appId: 'your-app-id',
* rpcBaseUrl: 'https://your-api.com',
* ui: {
* title: 'Chat Assistant',
* placeholder: 'Type a message...',
*
* // Complete theme customization
* theme: {
* // Primary colors
* primary: '#3b82f6', // Main accent color
* primaryHover: '#2563eb', // Hover state color
*
* // Background colors
* background: '#ffffff', // Main panel background
* messagesBackground: '#f9fafb', // Chat messages area
* headerBackground: '#3b82f6', // Header background (defaults to primary)
* footerBackground: '#ffffff', // Footer/input area background
*
* // Text colors
* textColor: '#1f2937', // Main text color
* headerTextColor: '#ffffff', // Header text color
* userBubbleColor: '#3b82f6', // User message bubble (defaults to primary)
* aiBubbleColor: '#e5e7eb', // AI message bubble
* userBubbleTextColor: '#ffffff', // User message text
* aiBubbleTextColor: '#1f2937', // AI message text
* statusTextColor: '#6b7280', // Status message text
*
* // Border and UI colors
* borderColor: '#e5e7eb', // General borders
* scrollbarColor: '#d1d5db', // Scrollbar color
* focusColor: '#3b82f6', // Focus outline (defaults to primary)
*
* // Layout and styling
* borderRadius: '14px', // Corner rounding
* shadow: '0 8px 32px rgba(0,0,0,0.15)', // Drop shadow
* fontFamily: 'system-ui, sans-serif', // Font stack
*
* // Bot-specific styling
* botBorderColor: '#3b82f6', // Bot button border (defaults to primary)
* botBackgroundColor: '#ffffff', // Bot button background
* botEyeColor: '#3b82f6', // Bot eye color (defaults to primary)
* botAntennaColor: '#3b82f6' // Bot antenna color (defaults to primary)
* }
* }
* })
* ```
*
* Legacy Support:
* You can also use `ui.themeColor` for simple primary color customization.
*/
Object.defineProperty(exports, "__esModule", { value: true });
exports.widgetStyles = exports.initTTCChatWidget = exports.ttc = void 0;
// Main exports for the ttc-rpc package
var core_1 = require("./core");
Object.defineProperty(exports, "ttc", { enumerable: true, get: function () { return core_1.ttc; } });
var index_1 = require("./widget/index");
Object.defineProperty(exports, "initTTCChatWidget", { enumerable: true, get: function () { return index_1.initTTCChatWidget; } });
var styles_1 = require("./widget/styles");
Object.defineProperty(exports, "widgetStyles", { enumerable: true, get: function () { return styles_1.widgetStyles; } });
//# sourceMappingURL=index.js.map