@tasks-timeline/components 0.4.3 → 0.4.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,11 @@
1
+ import type { ProviderConfig } from "../types";
2
+ import type { AIProviderResponse, ChatMessage, IAIProvider, TestResult, ToolDefinition, ToolResult } from "./types";
3
+ export type AISDKProviderType = "gemini" | "openai" | "anthropic" | "openai-compatible";
4
+ export declare class AISDKProvider implements IAIProvider {
5
+ private readonly type;
6
+ private readonly config;
7
+ constructor(type: AISDKProviderType, config: ProviderConfig);
8
+ chat(systemPrompt: string, prompt: string, tools: ToolDefinition[], toolResults?: ToolResult[], history?: ChatMessage[]): Promise<AIProviderResponse>;
9
+ test(): Promise<TestResult>;
10
+ }
11
+ //# sourceMappingURL=ai-sdk-provider.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ai-sdk-provider.d.ts","sourceRoot":"","sources":["../../src/providers/ai-sdk-provider.ts"],"names":[],"mappings":"AAWA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,UAAU,CAAC;AAC/C,OAAO,KAAK,EACV,kBAAkB,EAClB,WAAW,EACX,WAAW,EACX,UAAU,EACV,cAAc,EACd,UAAU,EACX,MAAM,SAAS,CAAC;AAEjB,MAAM,MAAM,iBAAiB,GACzB,QAAQ,GACR,QAAQ,GACR,WAAW,GACX,mBAAmB,CAAC;AAkMxB,qBAAa,aAAc,YAAW,WAAW;IAC/C,OAAO,CAAC,QAAQ,CAAC,IAAI,CAAoB;IACzC,OAAO,CAAC,QAAQ,CAAC,MAAM,CAAiB;gBAE5B,IAAI,EAAE,iBAAiB,EAAE,MAAM,EAAE,cAAc;IAKrD,IAAI,CACR,YAAY,EAAE,MAAM,EACpB,MAAM,EAAE,MAAM,EACd,KAAK,EAAE,cAAc,EAAE,EACvB,WAAW,CAAC,EAAE,UAAU,EAAE,EAC1B,OAAO,CAAC,EAAE,WAAW,EAAE,GACtB,OAAO,CAAC,kBAAkB,CAAC;IAgCxB,IAAI,IAAI,OAAO,CAAC,UAAU,CAAC;CAmBlC"}
@@ -1,10 +1,6 @@
1
- import type { IAIProvider, AIProviderResponse, ToolDefinition, ToolResult, ChatMessage, TestResult } from "./types";
2
1
  import type { ProviderConfig } from "../types";
3
- export declare class AnthropicProvider implements IAIProvider {
4
- private readonly config;
2
+ import { AISDKProvider } from "./ai-sdk-provider";
3
+ export declare class AnthropicProvider extends AISDKProvider {
5
4
  constructor(config: ProviderConfig);
6
- private getClient;
7
- chat(systemPrompt: string, prompt: string, tools: ToolDefinition[], toolResults?: ToolResult[], history?: ChatMessage[]): Promise<AIProviderResponse>;
8
- test(): Promise<TestResult>;
9
5
  }
10
6
  //# sourceMappingURL=anthropic-provider.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"anthropic-provider.d.ts","sourceRoot":"","sources":["../../src/providers/anthropic-provider.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,WAAW,EACX,kBAAkB,EAClB,cAAc,EACd,UAAU,EACV,WAAW,EACX,UAAU,EACX,MAAM,SAAS,CAAC;AACjB,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,UAAU,CAAC;AAE/C,qBAAa,iBAAkB,YAAW,WAAW;IACnD,OAAO,CAAC,QAAQ,CAAC,MAAM,CAAiB;gBAE5B,MAAM,EAAE,cAAc;YAIpB,SAAS;IAkBjB,IAAI,CACR,YAAY,EAAE,MAAM,EACpB,MAAM,EAAE,MAAM,EACd,KAAK,EAAE,cAAc,EAAE,EACvB,WAAW,CAAC,EAAE,UAAU,EAAE,EAC1B,OAAO,CAAC,EAAE,WAAW,EAAE,GACtB,OAAO,CAAC,kBAAkB,CAAC;IAuHxB,IAAI,IAAI,OAAO,CAAC,UAAU,CAAC;CAuBlC"}
1
+ {"version":3,"file":"anthropic-provider.d.ts","sourceRoot":"","sources":["../../src/providers/anthropic-provider.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,UAAU,CAAC;AAC/C,OAAO,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAC;AAElD,qBAAa,iBAAkB,SAAQ,aAAa;gBACtC,MAAM,EAAE,cAAc;CAGnC"}
@@ -1,9 +1,6 @@
1
- import type { IAIProvider, AIProviderResponse, ToolDefinition, ToolResult, ChatMessage, TestResult } from "./types";
2
1
  import type { ProviderConfig } from "../types";
3
- export declare class GeminiProvider implements IAIProvider {
4
- private readonly config;
2
+ import { AISDKProvider } from "./ai-sdk-provider";
3
+ export declare class GeminiProvider extends AISDKProvider {
5
4
  constructor(config: ProviderConfig);
6
- chat(systemPrompt: string, prompt: string, tools: ToolDefinition[], toolResults?: ToolResult[], history?: ChatMessage[]): Promise<AIProviderResponse>;
7
- test(): Promise<TestResult>;
8
5
  }
9
6
  //# sourceMappingURL=gemini-provider.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"gemini-provider.d.ts","sourceRoot":"","sources":["../../src/providers/gemini-provider.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,WAAW,EACX,kBAAkB,EAClB,cAAc,EACd,UAAU,EACV,WAAW,EACX,UAAU,EAEX,MAAM,SAAS,CAAC;AACjB,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,UAAU,CAAC;AA2E/C,qBAAa,cAAe,YAAW,WAAW;IAChD,OAAO,CAAC,QAAQ,CAAC,MAAM,CAAiB;gBAE5B,MAAM,EAAE,cAAc;IAI5B,IAAI,CACR,YAAY,EAAE,MAAM,EACpB,MAAM,EAAE,MAAM,EACd,KAAK,EAAE,cAAc,EAAE,EACvB,WAAW,CAAC,EAAE,UAAU,EAAE,EAC1B,OAAO,CAAC,EAAE,WAAW,EAAE,GACtB,OAAO,CAAC,kBAAkB,CAAC;IAoGxB,IAAI,IAAI,OAAO,CAAC,UAAU,CAAC;CAmBlC"}
1
+ {"version":3,"file":"gemini-provider.d.ts","sourceRoot":"","sources":["../../src/providers/gemini-provider.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,UAAU,CAAC;AAC/C,OAAO,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAC;AAElD,qBAAa,cAAe,SAAQ,aAAa;gBACnC,MAAM,EAAE,cAAc;CAGnC"}
@@ -1,10 +1,9 @@
1
- import type { IAIProvider, AIProviderResponse, ToolDefinition, ToolResult, ChatMessage, TestResult } from "./types";
2
1
  import type { ProviderConfig } from "../types";
3
- export declare class OpenAIProvider implements IAIProvider {
4
- private readonly config;
2
+ import { AISDKProvider } from "./ai-sdk-provider";
3
+ export declare class OpenAIProvider extends AISDKProvider {
4
+ constructor(config: ProviderConfig);
5
+ }
6
+ export declare class OpenAICompatibleProvider extends AISDKProvider {
5
7
  constructor(config: ProviderConfig);
6
- private getClient;
7
- chat(systemPrompt: string, prompt: string, tools: ToolDefinition[], toolResults?: ToolResult[], history?: ChatMessage[]): Promise<AIProviderResponse>;
8
- test(): Promise<TestResult>;
9
8
  }
10
9
  //# sourceMappingURL=openai-provider.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"openai-provider.d.ts","sourceRoot":"","sources":["../../src/providers/openai-provider.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,WAAW,EACX,kBAAkB,EAClB,cAAc,EACd,UAAU,EACV,WAAW,EACX,UAAU,EACX,MAAM,SAAS,CAAC;AACjB,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,UAAU,CAAC;AAE/C,qBAAa,cAAe,YAAW,WAAW;IAChD,OAAO,CAAC,QAAQ,CAAC,MAAM,CAAiB;gBAE5B,MAAM,EAAE,cAAc;YAIpB,SAAS;IAkBjB,IAAI,CACR,YAAY,EAAE,MAAM,EACpB,MAAM,EAAE,MAAM,EACd,KAAK,EAAE,cAAc,EAAE,EACvB,WAAW,CAAC,EAAE,UAAU,EAAE,EAC1B,OAAO,CAAC,EAAE,WAAW,EAAE,GACtB,OAAO,CAAC,kBAAkB,CAAC;IAkHxB,IAAI,IAAI,OAAO,CAAC,UAAU,CAAC;CAoBlC"}
1
+ {"version":3,"file":"openai-provider.d.ts","sourceRoot":"","sources":["../../src/providers/openai-provider.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,UAAU,CAAC;AAC/C,OAAO,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAC;AAElD,qBAAa,cAAe,SAAQ,aAAa;gBACnC,MAAM,EAAE,cAAc;CAGnC;AAED,qBAAa,wBAAyB,SAAQ,aAAa;gBAC7C,MAAM,EAAE,cAAc;CAGnC"}
@@ -0,0 +1,5 @@
1
+ type ExpressionValue = string | number | boolean | null | undefined;
2
+ type Scope = Record<string, unknown>;
3
+ export declare function compileSafeExpression(source: string): (scope: Scope) => ExpressionValue;
4
+ export {};
5
+ //# sourceMappingURL=safe-expression.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"safe-expression.d.ts","sourceRoot":"","sources":["../../src/utils/safe-expression.ts"],"names":[],"mappings":"AAAA,KAAK,eAAe,GAAG,MAAM,GAAG,MAAM,GAAG,OAAO,GAAG,IAAI,GAAG,SAAS,CAAC;AACpE,KAAK,KAAK,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;AAsfrC,wBAAgB,qBAAqB,CACnC,MAAM,EAAE,MAAM,GACb,CAAC,KAAK,EAAE,KAAK,KAAK,eAAe,CAGnC"}
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@tasks-timeline/components",
3
3
  "description": "A comprehensive React component library for task management and timeline visualization",
4
4
  "private": false,
5
- "version": "0.4.3",
5
+ "version": "0.4.4",
6
6
  "type": "module",
7
7
  "license": "MIT",
8
8
  "author": "Leonezz <zhwuenqa@outlook.com>",
@@ -61,16 +61,19 @@
61
61
  "examples/app"
62
62
  ],
63
63
  "dependencies": {
64
+ "@ai-sdk/anthropic": "^3.0.84",
65
+ "@ai-sdk/google": "^3.0.82",
66
+ "@ai-sdk/openai": "^3.0.71",
64
67
  "@radix-ui/react-collapsible": "^1.1.11",
65
68
  "@radix-ui/react-dialog": "^1.1.15",
66
69
  "@radix-ui/react-dropdown-menu": "^2.1.16",
67
70
  "@radix-ui/react-popover": "^1.1.15",
68
71
  "@radix-ui/react-portal": "^1.1.8",
69
72
  "@radix-ui/react-slot": "^1.2.4",
73
+ "ai": "^6.0.204",
70
74
  "class-variance-authority": "^0.7.1",
71
75
  "clsx": "^2.1.1",
72
76
  "date-fns": "^4.1.0",
73
- "expr-eval": "^2.0.2",
74
77
  "framer-motion": "12.23.26",
75
78
  "lucide-react": "^0.330.0",
76
79
  "luxon": "3.4.4",
@@ -81,23 +84,9 @@
81
84
  "tailwind-merge": "^3.4.0"
82
85
  },
83
86
  "peerDependencies": {
84
- "@anthropic-ai/sdk": ">=0.30.0",
85
- "@google/genai": ">=1.0.0",
86
- "openai": ">=4.0.0",
87
87
  "react": "^19.2.3",
88
88
  "react-dom": "^19.2.3"
89
89
  },
90
- "peerDependenciesMeta": {
91
- "@google/genai": {
92
- "optional": true
93
- },
94
- "openai": {
95
- "optional": true
96
- },
97
- "@anthropic-ai/sdk": {
98
- "optional": true
99
- }
100
- },
101
90
  "devDependencies": {
102
91
  "@chromatic-com/storybook": "^4.1.3",
103
92
  "@eslint/js": "^9.39.1",