@keak/sdk 2.0.9 → 2.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.
Files changed (52) hide show
  1. package/dist/KeakToolbarShadow.d.ts +21 -0
  2. package/dist/KeakToolbarShadow.d.ts.map +1 -0
  3. package/dist/components/ui/card.d.ts +9 -0
  4. package/dist/components/ui/card.d.ts.map +1 -0
  5. package/dist/components/ui/html-preview.d.ts +9 -0
  6. package/dist/components/ui/html-preview.d.ts.map +1 -0
  7. package/dist/components/ui/simple-tabs.d.ts +26 -0
  8. package/dist/components/ui/simple-tabs.d.ts.map +1 -0
  9. package/dist/components/ui/spinner.d.ts +6 -0
  10. package/dist/components/ui/spinner.d.ts.map +1 -0
  11. package/dist/components/ui/tabs.d.ts +13 -0
  12. package/dist/components/ui/tabs.d.ts.map +1 -0
  13. package/dist/components/ui/textarea.d.ts +6 -0
  14. package/dist/components/ui/textarea.d.ts.map +1 -0
  15. package/dist/index.cjs.js +2 -198
  16. package/dist/index.cjs.js.map +1 -1
  17. package/dist/index.js +2 -198
  18. package/dist/index.js.map +1 -1
  19. package/dist/services/telemetry/index.d.ts +20 -0
  20. package/dist/services/telemetry/index.d.ts.map +1 -0
  21. package/dist/services/telemetry/telemetryService.d.ts +66 -0
  22. package/dist/services/telemetry/telemetryService.d.ts.map +1 -0
  23. package/dist/services/telemetry/types.d.ts +64 -0
  24. package/dist/services/telemetry/types.d.ts.map +1 -0
  25. package/dist/toolbar/AIPromptPanel.d.ts +9 -0
  26. package/dist/toolbar/AIPromptPanel.d.ts.map +1 -0
  27. package/dist/toolbar/ElementSelector.d.ts.map +1 -1
  28. package/dist/toolbar/ExperimentPanel.d.ts +9 -0
  29. package/dist/toolbar/ExperimentPanel.d.ts.map +1 -0
  30. package/dist/toolbar/KeakToolbar.d.ts.map +1 -1
  31. package/dist/toolbar/MetricsPanel.d.ts +7 -0
  32. package/dist/toolbar/MetricsPanel.d.ts.map +1 -0
  33. package/dist/toolbar/PageScanPanel.d.ts +15 -0
  34. package/dist/toolbar/PageScanPanel.d.ts.map +1 -0
  35. package/dist/toolbar/components/PrimaryButton.d.ts +12 -0
  36. package/dist/toolbar/components/PrimaryButton.d.ts.map +1 -0
  37. package/dist/toolbar/components/WarningButton.d.ts +12 -0
  38. package/dist/toolbar/components/WarningButton.d.ts.map +1 -0
  39. package/dist/toolbar/components/ui/Badge.d.ts +10 -0
  40. package/dist/toolbar/components/ui/Badge.d.ts.map +1 -0
  41. package/dist/toolbar/components/ui/Button.d.ts +12 -0
  42. package/dist/toolbar/components/ui/Button.d.ts.map +1 -0
  43. package/dist/toolbar/components/ui/Progress.d.ts +5 -0
  44. package/dist/toolbar/components/ui/Progress.d.ts.map +1 -0
  45. package/dist/toolbar/components/ui/Tabs.d.ts +44 -0
  46. package/dist/toolbar/components/ui/Tabs.d.ts.map +1 -0
  47. package/dist/toolbar/components/ui/dropdown-menu.d.ts +28 -0
  48. package/dist/toolbar/components/ui/dropdown-menu.d.ts.map +1 -0
  49. package/dist/toolbar.js +2 -198
  50. package/dist/toolbar.js.map +1 -1
  51. package/package.json +1 -1
  52. package/src/plugins/webpack-loader-babel/index.js +1 -6
@@ -0,0 +1,64 @@
1
+ export interface TelemetryConfig {
2
+ supabaseUrl: string;
3
+ supabaseKey: string;
4
+ enabled?: boolean;
5
+ }
6
+ export interface UserContext {
7
+ userId?: string;
8
+ metadata?: Record<string, any>;
9
+ }
10
+ export interface ChatStartEvent {
11
+ sessionId: string;
12
+ elementSelector: string;
13
+ originalCode: string;
14
+ }
15
+ export interface GenerationStartEvent {
16
+ chatId: string;
17
+ userPrompt: string;
18
+ generationType: GenerationType;
19
+ llmModel: string;
20
+ modelTier: string;
21
+ }
22
+ export interface GenerationCompleteEvent {
23
+ generationId: string;
24
+ durationMs: number;
25
+ inputTokens: number;
26
+ outputTokens: number;
27
+ variant: InitialVariantData;
28
+ complexity?: ComplexityScores;
29
+ }
30
+ export interface ComplexityScores {
31
+ overall: number;
32
+ structural: number;
33
+ content: number;
34
+ technical: number;
35
+ }
36
+ export interface InitialVariantData {
37
+ generationId: string;
38
+ chatId: string;
39
+ variantCode: string;
40
+ validationScore: number;
41
+ }
42
+ export declare enum GenerationType {
43
+ INITIAL = "INITIAL",
44
+ RETRY = "RETRY",
45
+ FOLLOWUP = "FOLLOWUP"
46
+ }
47
+ export declare enum VariantOutcome {
48
+ PENDING = "PENDING",
49
+ EDITED = "EDITED",
50
+ ACCEPTED = "ACCEPTED",
51
+ REPLACED = "REPLACED",// Retried
52
+ CLEARED = "CLEARED",
53
+ SKIPPED = "SKIPPED"
54
+ }
55
+ export interface VariantUpdates {
56
+ variant_code?: string;
57
+ validation_score?: number | null;
58
+ final_code?: string | null;
59
+ has_edits?: boolean;
60
+ outcome?: VariantOutcome;
61
+ preview_count?: number;
62
+ last_previewed_at?: string;
63
+ }
64
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/services/telemetry/types.ts"],"names":[],"mappings":"AAIA,MAAM,WAAW,eAAe;IAC5B,WAAW,EAAE,MAAM,CAAC;IACpB,WAAW,EAAE,MAAM,CAAC;IACpB,OAAO,CAAC,EAAE,OAAO,CAAC;CACrB;AAED,MAAM,WAAW,WAAW;IACxB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;CAClC;AAED,MAAM,WAAW,cAAc;IAC3B,SAAS,EAAE,MAAM,CAAC;IAClB,eAAe,EAAE,MAAM,CAAC;IACxB,YAAY,EAAE,MAAM,CAAC;CAExB;AAED,MAAM,WAAW,oBAAoB;IACjC,MAAM,EAAE,MAAM,CAAC;IACf,UAAU,EAAE,MAAM,CAAC;IACnB,cAAc,EAAE,cAAc,CAAC;IAC/B,QAAQ,EAAE,MAAM,CAAC;IACjB,SAAS,EAAE,MAAM,CAAC;CACrB;AAED,MAAM,WAAW,uBAAuB;IACpC,YAAY,EAAE,MAAM,CAAC;IACrB,UAAU,EAAE,MAAM,CAAC;IACnB,WAAW,EAAE,MAAM,CAAC;IACpB,YAAY,EAAE,MAAM,CAAC;IACrB,OAAO,EAAE,kBAAkB,CAAC;IAC5B,UAAU,CAAC,EAAE,gBAAgB,CAAC;CACjC;AAED,MAAM,WAAW,gBAAgB;IAC7B,OAAO,EAAE,MAAM,CAAC;IAChB,UAAU,EAAE,MAAM,CAAC;IACnB,OAAO,EAAE,MAAM,CAAC;IAChB,SAAS,EAAE,MAAM,CAAC;CACrB;AAED,MAAM,WAAW,kBAAkB;IAC/B,YAAY,EAAE,MAAM,CAAC;IACrB,MAAM,EAAE,MAAM,CAAC;IACf,WAAW,EAAE,MAAM,CAAC;IACpB,eAAe,EAAE,MAAM,CAAC;CAC3B;AAED,oBAAY,cAAc;IACtB,OAAO,YAAY;IACnB,KAAK,UAAU;IACf,QAAQ,aAAa;CACxB;AACD,oBAAY,cAAc;IACtB,OAAO,YAAY;IACnB,MAAM,WAAW;IACjB,QAAQ,aAAa;IACrB,QAAQ,aAAa,CAAE,UAAU;IACjC,OAAO,YAAY;IACnB,OAAO,YAAY;CACtB;AAED,MAAM,WAAW,cAAc;IAC3B,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,gBAAgB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACjC,UAAU,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC3B,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,OAAO,CAAC,EAAE,cAAc,CAAC;IACzB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,iBAAiB,CAAC,EAAE,MAAM,CAAC;CAC9B"}
@@ -0,0 +1,9 @@
1
+ import React from 'react';
2
+ interface AIPromptPanelProps {
3
+ selectedElement: HTMLElement | null;
4
+ aiModel: 'keak' | 'copilot' | 'cursor';
5
+ onClose: () => void;
6
+ }
7
+ export declare const AIPromptPanel: React.FC<AIPromptPanelProps>;
8
+ export {};
9
+ //# sourceMappingURL=AIPromptPanel.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"AIPromptPanel.d.ts","sourceRoot":"","sources":["../../src/toolbar/AIPromptPanel.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAsC,MAAM,OAAO,CAAC;AAU3D,UAAU,kBAAkB;IAC1B,eAAe,EAAE,WAAW,GAAG,IAAI,CAAC;IACpC,OAAO,EAAE,MAAM,GAAG,SAAS,GAAG,QAAQ,CAAC;IACvC,OAAO,EAAE,MAAM,IAAI,CAAC;CACrB;AAED,eAAO,MAAM,aAAa,EAAE,KAAK,CAAC,EAAE,CAAC,kBAAkB,CAy7CtD,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"ElementSelector.d.ts","sourceRoot":"","sources":["../../src/toolbar/ElementSelector.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAsC,MAAM,OAAO,CAAC;AAG3D,UAAU,oBAAoB;IAC5B,iBAAiB,EAAE,CAAC,OAAO,EAAE,WAAW,KAAK,IAAI,CAAC;IAClD,QAAQ,EAAE,MAAM,IAAI,CAAC;CACtB;AAED,eAAO,MAAM,eAAe,EAAE,KAAK,CAAC,EAAE,CAAC,oBAAoB,CAmf1D,CAAC"}
1
+ {"version":3,"file":"ElementSelector.d.ts","sourceRoot":"","sources":["../../src/toolbar/ElementSelector.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAsC,MAAM,OAAO,CAAC;AAG3D,UAAU,oBAAoB;IAC5B,iBAAiB,EAAE,CAAC,OAAO,EAAE,WAAW,KAAK,IAAI,CAAC;IAClD,QAAQ,EAAE,MAAM,IAAI,CAAC;CACtB;AAED,eAAO,MAAM,eAAe,EAAE,KAAK,CAAC,EAAE,CAAC,oBAAoB,CA8V1D,CAAC"}
@@ -0,0 +1,9 @@
1
+ import React from 'react';
2
+ interface ExperimentPanelProps {
3
+ selectedElement: HTMLElement | null;
4
+ onClose: () => void;
5
+ onSelectElement: () => void;
6
+ }
7
+ export declare const ExperimentPanel: React.FC<ExperimentPanelProps>;
8
+ export {};
9
+ //# sourceMappingURL=ExperimentPanel.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ExperimentPanel.d.ts","sourceRoot":"","sources":["../../src/toolbar/ExperimentPanel.tsx"],"names":[],"mappings":"AAEA,OAAO,KAA8B,MAAM,OAAO,CAAC;AAKnD,UAAU,oBAAoB;IAC5B,eAAe,EAAE,WAAW,GAAG,IAAI,CAAC;IACpC,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,eAAe,EAAE,MAAM,IAAI,CAAC;CAC7B;AAUD,eAAO,MAAM,eAAe,EAAE,KAAK,CAAC,EAAE,CAAC,oBAAoB,CAuP1D,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"KeakToolbar.d.ts","sourceRoot":"","sources":["../../src/toolbar/KeakToolbar.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAmD,MAAM,OAAO,CAAC;AAMxE,OAAO,eAAe,CAAC;AACvB,OAAO,sBAAsB,CAAC;AAgC9B,UAAU,gBAAgB;IACxB,QAAQ,CAAC,EAAE,YAAY,GAAG,WAAW,GAAG,UAAU,GAAG,cAAc,GAAG,aAAa,CAAC;IACpF,KAAK,CAAC,EAAE,OAAO,GAAG,MAAM,GAAG,MAAM,CAAC;CACnC;AAED,eAAO,MAAM,WAAW,EAAE,KAAK,CAAC,EAAE,CAAC,gBAAgB,CA8dlD,CAAC"}
1
+ {"version":3,"file":"KeakToolbar.d.ts","sourceRoot":"","sources":["../../src/toolbar/KeakToolbar.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAmD,MAAM,OAAO,CAAC;AAMxE,OAAO,eAAe,CAAC;AACvB,OAAO,sBAAsB,CAAC;AAgC9B,UAAU,gBAAgB;IACxB,QAAQ,CAAC,EAAE,YAAY,GAAG,WAAW,GAAG,UAAU,GAAG,cAAc,GAAG,aAAa,CAAC;IACpF,KAAK,CAAC,EAAE,OAAO,GAAG,MAAM,GAAG,MAAM,CAAC;CACnC;AAED,eAAO,MAAM,WAAW,EAAE,KAAK,CAAC,EAAE,CAAC,gBAAgB,CAgdlD,CAAC"}
@@ -0,0 +1,7 @@
1
+ import React from 'react';
2
+ interface MetricsPanelProps {
3
+ onClose: () => void;
4
+ }
5
+ export declare const MetricsPanel: React.FC<MetricsPanelProps>;
6
+ export {};
7
+ //# sourceMappingURL=MetricsPanel.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"MetricsPanel.d.ts","sourceRoot":"","sources":["../../src/toolbar/MetricsPanel.tsx"],"names":[],"mappings":"AAEA,OAAO,KAA8B,MAAM,OAAO,CAAC;AAMnD,UAAU,iBAAiB;IACzB,OAAO,EAAE,MAAM,IAAI,CAAC;CACrB;AA0BD,eAAO,MAAM,YAAY,EAAE,KAAK,CAAC,EAAE,CAAC,iBAAiB,CA4XpD,CAAC"}
@@ -0,0 +1,15 @@
1
+ import React from 'react';
2
+ interface PageScanPanelProps {
3
+ scannedElements: Array<{
4
+ element: HTMLElement;
5
+ suggestions: string[];
6
+ priority: number;
7
+ }>;
8
+ isScanning: boolean;
9
+ scanProgress?: number;
10
+ onNavigateToElement: (element: HTMLElement) => void;
11
+ onClose: () => void;
12
+ }
13
+ export declare const PageScanPanel: React.FC<PageScanPanelProps>;
14
+ export {};
15
+ //# sourceMappingURL=PageScanPanel.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PageScanPanel.d.ts","sourceRoot":"","sources":["../../src/toolbar/PageScanPanel.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,MAAM,OAAO,CAAC;AAI1B,UAAU,kBAAkB;IAC1B,eAAe,EAAE,KAAK,CAAC;QAAC,OAAO,EAAE,WAAW,CAAC;QAAC,WAAW,EAAE,MAAM,EAAE,CAAC;QAAC,QAAQ,EAAE,MAAM,CAAA;KAAC,CAAC,CAAC;IACxF,UAAU,EAAE,OAAO,CAAC;IACpB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,mBAAmB,EAAE,CAAC,OAAO,EAAE,WAAW,KAAK,IAAI,CAAC;IACpD,OAAO,EAAE,MAAM,IAAI,CAAC;CACrB;AAED,eAAO,MAAM,aAAa,EAAE,KAAK,CAAC,EAAE,CAAC,kBAAkB,CA0CtD,CAAC"}
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ interface PrimaryButtonProps {
3
+ onClick?: () => void;
4
+ children: React.ReactNode;
5
+ disabled?: boolean;
6
+ icon?: React.ReactNode;
7
+ fullWidth?: boolean;
8
+ type?: 'button' | 'submit' | 'reset';
9
+ }
10
+ export declare const PrimaryButton: React.FC<PrimaryButtonProps>;
11
+ export {};
12
+ //# sourceMappingURL=PrimaryButton.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PrimaryButton.d.ts","sourceRoot":"","sources":["../../../src/toolbar/components/PrimaryButton.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,UAAU,kBAAkB;IAC1B,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;IAC1B,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,IAAI,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACvB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,IAAI,CAAC,EAAE,QAAQ,GAAG,QAAQ,GAAG,OAAO,CAAC;CACtC;AAED,eAAO,MAAM,aAAa,EAAE,KAAK,CAAC,EAAE,CAAC,kBAAkB,CAuDtD,CAAC"}
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ interface WarningButtonProps {
3
+ onClick?: () => void;
4
+ children: React.ReactNode;
5
+ disabled?: boolean;
6
+ icon?: React.ReactNode;
7
+ fullWidth?: boolean;
8
+ type?: 'button' | 'submit' | 'reset';
9
+ }
10
+ export declare const WarningButton: React.FC<WarningButtonProps>;
11
+ export {};
12
+ //# sourceMappingURL=WarningButton.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"WarningButton.d.ts","sourceRoot":"","sources":["../../../src/toolbar/components/WarningButton.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,UAAU,kBAAkB;IAC1B,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;IAC1B,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,IAAI,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACvB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,IAAI,CAAC,EAAE,QAAQ,GAAG,QAAQ,GAAG,OAAO,CAAC;CACtC;AAED,eAAO,MAAM,aAAa,EAAE,KAAK,CAAC,EAAE,CAAC,kBAAkB,CAkDtD,CAAC"}
@@ -0,0 +1,10 @@
1
+ import * as React from "react";
2
+ import { type VariantProps } from "class-variance-authority";
3
+ declare const badgeVariants: (props?: ({
4
+ variant?: "default" | "secondary" | "destructive" | "outline" | null | undefined;
5
+ } & import("class-variance-authority/types").ClassProp) | undefined) => string;
6
+ export interface BadgeProps extends React.HTMLAttributes<HTMLDivElement>, VariantProps<typeof badgeVariants> {
7
+ }
8
+ declare function Badge({ className, variant, ...props }: BadgeProps): import("react/jsx-runtime").JSX.Element;
9
+ export { Badge, badgeVariants };
10
+ //# sourceMappingURL=Badge.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Badge.d.ts","sourceRoot":"","sources":["../../../../src/toolbar/components/ui/Badge.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,EAAO,KAAK,YAAY,EAAE,MAAM,0BAA0B,CAAA;AAIjE,QAAA,MAAM,aAAa;;8EAkBlB,CAAA;AAED,MAAM,WAAW,UACf,SAAQ,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC,EAC1C,YAAY,CAAC,OAAO,aAAa,CAAC;CAAG;AAEzC,iBAAS,KAAK,CAAC,EAAE,SAAS,EAAE,OAAO,EAAE,GAAG,KAAK,EAAE,EAAE,UAAU,2CAI1D;AAED,OAAO,EAAE,KAAK,EAAE,aAAa,EAAE,CAAA"}
@@ -0,0 +1,12 @@
1
+ import * as React from "react";
2
+ import { type VariantProps } from "class-variance-authority";
3
+ declare const buttonVariants: (props?: ({
4
+ variant?: "link" | "default" | "secondary" | "destructive" | "outline" | "ghost" | null | undefined;
5
+ size?: "default" | "icon" | "sm" | "lg" | null | undefined;
6
+ } & import("class-variance-authority/types").ClassProp) | undefined) => string;
7
+ export interface ButtonProps extends React.ButtonHTMLAttributes<HTMLButtonElement>, VariantProps<typeof buttonVariants> {
8
+ asChild?: boolean;
9
+ }
10
+ declare const Button: React.ForwardRefExoticComponent<ButtonProps & React.RefAttributes<HTMLButtonElement>>;
11
+ export { Button, buttonVariants };
12
+ //# sourceMappingURL=Button.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Button.d.ts","sourceRoot":"","sources":["../../../../src/toolbar/components/ui/Button.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAE9B,OAAO,EAAO,KAAK,YAAY,EAAE,MAAM,0BAA0B,CAAA;AAIjE,QAAA,MAAM,cAAc;;;8EA2BnB,CAAA;AAED,MAAM,WAAW,WACf,SAAQ,KAAK,CAAC,oBAAoB,CAAC,iBAAiB,CAAC,EACnD,YAAY,CAAC,OAAO,cAAc,CAAC;IACrC,OAAO,CAAC,EAAE,OAAO,CAAA;CAClB;AAED,QAAA,MAAM,MAAM,uFAWX,CAAA;AAGD,OAAO,EAAE,MAAM,EAAE,cAAc,EAAE,CAAA"}
@@ -0,0 +1,5 @@
1
+ import * as React from "react";
2
+ import * as ProgressPrimitive from "@radix-ui/react-progress";
3
+ declare function Progress({ className, value, ...props }: React.ComponentProps<typeof ProgressPrimitive.Root>): import("react/jsx-runtime").JSX.Element;
4
+ export { Progress };
5
+ //# sourceMappingURL=Progress.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Progress.d.ts","sourceRoot":"","sources":["../../../../src/toolbar/components/ui/Progress.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,KAAK,iBAAiB,MAAM,0BAA0B,CAAA;AAI7D,iBAAS,QAAQ,CAAC,EAChB,SAAS,EACT,KAAK,EACL,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,iBAAiB,CAAC,IAAI,CAAC,2CAiBrD;AAED,OAAO,EAAE,QAAQ,EAAE,CAAA"}
@@ -0,0 +1,44 @@
1
+ import * as React from 'react';
2
+ import { type HTMLMotionProps } from 'framer-motion';
3
+ type TabsContextType<T extends string> = {
4
+ activeValue: T;
5
+ handleValueChange: (value: T) => void;
6
+ registerTrigger: (value: T, node: HTMLElement | null) => void;
7
+ };
8
+ declare function useTabs<T extends string = string>(): TabsContextType<T>;
9
+ type BaseTabsProps = React.ComponentProps<'div'> & {
10
+ children: React.ReactNode;
11
+ };
12
+ type UnControlledTabsProps<T extends string = string> = BaseTabsProps & {
13
+ defaultValue?: T;
14
+ value?: never;
15
+ onValueChange?: never;
16
+ };
17
+ type ControlledTabsProps<T extends string = string> = BaseTabsProps & {
18
+ value: T;
19
+ onValueChange?: (value: T) => void;
20
+ defaultValue?: never;
21
+ };
22
+ type TabsProps<T extends string = string> = UnControlledTabsProps<T> | ControlledTabsProps<T>;
23
+ declare function Tabs<T extends string = string>({ defaultValue, value, onValueChange, children, className, ...props }: TabsProps<T>): import("react/jsx-runtime").JSX.Element;
24
+ type TabsListProps = React.ComponentProps<'div'> & {
25
+ children: React.ReactNode;
26
+ activeClassName?: string;
27
+ };
28
+ declare function TabsList({ children, className, activeClassName, ...props }: TabsListProps): import("react/jsx-runtime").JSX.Element;
29
+ type TabsTriggerProps = HTMLMotionProps<'button'> & {
30
+ value: string;
31
+ children: React.ReactNode;
32
+ };
33
+ declare function TabsTrigger({ ref, value, children, className, ...props }: TabsTriggerProps): import("react/jsx-runtime").JSX.Element;
34
+ type TabsContentsProps = React.ComponentProps<'div'> & {
35
+ children: React.ReactNode;
36
+ };
37
+ declare function TabsContents({ children, className, ...props }: TabsContentsProps): import("react/jsx-runtime").JSX.Element;
38
+ type TabsContentProps = HTMLMotionProps<'div'> & {
39
+ value: string;
40
+ children: React.ReactNode;
41
+ };
42
+ declare function TabsContent({ children, value, className, ...props }: TabsContentProps): import("react/jsx-runtime").JSX.Element;
43
+ export { Tabs, TabsList, TabsTrigger, TabsContents, TabsContent, useTabs, type TabsContextType, type TabsProps, type TabsListProps, type TabsTriggerProps, type TabsContentsProps, type TabsContentProps, };
44
+ //# sourceMappingURL=Tabs.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Tabs.d.ts","sourceRoot":"","sources":["../../../../src/toolbar/components/ui/Tabs.tsx"],"names":[],"mappings":"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"}
@@ -0,0 +1,28 @@
1
+ import * as React from "react";
2
+ import * as DropdownMenuPrimitive from "@radix-ui/react-dropdown-menu";
3
+ declare const DropdownMenu: React.FC<DropdownMenuPrimitive.DropdownMenuProps>;
4
+ declare const DropdownMenuTrigger: React.ForwardRefExoticComponent<DropdownMenuPrimitive.DropdownMenuTriggerProps & React.RefAttributes<HTMLButtonElement>>;
5
+ declare const DropdownMenuGroup: React.ForwardRefExoticComponent<DropdownMenuPrimitive.DropdownMenuGroupProps & React.RefAttributes<HTMLDivElement>>;
6
+ declare const DropdownMenuPortal: React.FC<DropdownMenuPrimitive.DropdownMenuPortalProps>;
7
+ declare const DropdownMenuSub: React.FC<DropdownMenuPrimitive.DropdownMenuSubProps>;
8
+ declare const DropdownMenuRadioGroup: React.ForwardRefExoticComponent<DropdownMenuPrimitive.DropdownMenuRadioGroupProps & React.RefAttributes<HTMLDivElement>>;
9
+ declare const DropdownMenuSubTrigger: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuSubTriggerProps & React.RefAttributes<HTMLDivElement>, "ref"> & {
10
+ inset?: boolean;
11
+ } & React.RefAttributes<HTMLDivElement>>;
12
+ declare const DropdownMenuSubContent: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuSubContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
13
+ declare const DropdownMenuContent: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
14
+ declare const DropdownMenuItem: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & {
15
+ inset?: boolean;
16
+ } & React.RefAttributes<HTMLDivElement>>;
17
+ declare const DropdownMenuCheckboxItem: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuCheckboxItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
18
+ declare const DropdownMenuRadioItem: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuRadioItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
19
+ declare const DropdownMenuLabel: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuLabelProps & React.RefAttributes<HTMLDivElement>, "ref"> & {
20
+ inset?: boolean;
21
+ } & React.RefAttributes<HTMLDivElement>>;
22
+ declare const DropdownMenuSeparator: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuSeparatorProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
23
+ declare const DropdownMenuShortcut: {
24
+ ({ className, ...props }: React.HTMLAttributes<HTMLSpanElement>): import("react/jsx-runtime").JSX.Element;
25
+ displayName: string;
26
+ };
27
+ export { DropdownMenu, DropdownMenuTrigger, DropdownMenuContent, DropdownMenuItem, DropdownMenuCheckboxItem, DropdownMenuRadioItem, DropdownMenuLabel, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuGroup, DropdownMenuPortal, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuRadioGroup, };
28
+ //# sourceMappingURL=dropdown-menu.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"dropdown-menu.d.ts","sourceRoot":"","sources":["../../../../src/toolbar/components/ui/dropdown-menu.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,KAAK,qBAAqB,MAAM,+BAA+B,CAAA;AAKtE,QAAA,MAAM,YAAY,mDAA6B,CAAA;AAE/C,QAAA,MAAM,mBAAmB,0HAAgC,CAAA;AAEzD,QAAA,MAAM,iBAAiB,qHAA8B,CAAA;AAErD,QAAA,MAAM,kBAAkB,yDAA+B,CAAA;AAEvD,QAAA,MAAM,eAAe,sDAA4B,CAAA;AAEjD,QAAA,MAAM,sBAAsB,0HAAmC,CAAA;AAE/D,QAAA,MAAM,sBAAsB;YAGhB,OAAO;wCAejB,CAAA;AAIF,QAAA,MAAM,sBAAsB,6KAY1B,CAAA;AAIF,QAAA,MAAM,mBAAmB,0KAevB,CAAA;AAGF,QAAA,MAAM,gBAAgB;YAGV,OAAO;wCAYjB,CAAA;AAGF,QAAA,MAAM,wBAAwB,+KAoB5B,CAAA;AAIF,QAAA,MAAM,qBAAqB,4KAmBzB,CAAA;AAGF,QAAA,MAAM,iBAAiB;YAGX,OAAO;wCAYjB,CAAA;AAGF,QAAA,MAAM,qBAAqB,4KASzB,CAAA;AAGF,QAAA,MAAM,oBAAoB;8BAGvB,KAAK,CAAC,cAAc,CAAC,eAAe,CAAC;;CAOvC,CAAA;AAGD,OAAO,EACL,YAAY,EACZ,mBAAmB,EACnB,mBAAmB,EACnB,gBAAgB,EAChB,wBAAwB,EACxB,qBAAqB,EACrB,iBAAiB,EACjB,qBAAqB,EACrB,oBAAoB,EACpB,iBAAiB,EACjB,kBAAkB,EAClB,eAAe,EACf,sBAAsB,EACtB,sBAAsB,EACtB,sBAAsB,GACvB,CAAA"}
package/dist/toolbar.js CHANGED
@@ -315,116 +315,9 @@ function getSourceConfidence(sourceInfo) {
315
315
  }
316
316
  return 'low';
317
317
  }
318
- /**
319
- * Check if an element is part of a dynamically generated list (.map(), .forEach(), etc.)
320
- *
321
- * Detection strategy:
322
- * 1. Check if multiple siblings share the same source location (primary method)
323
- * 2. This indicates they're generated from the same template (likely a map)
324
- * 3. Also check if the element is a descendant of an element that's in a map
325
- *
326
- * @param element The DOM element to check
327
- * @returns Object with isInMap (boolean) and reason (string) if detected
328
- */
329
- function isElementInDynamicList(element) {
330
- // First, check if the element itself is in a map
331
- const directCheck = checkElementForMapPattern(element);
332
- if (directCheck.isInMap) {
333
- return directCheck;
334
- }
335
- // If not, check if any ancestor is in a map
336
- let current = element.parentElement;
337
- let depth = 0;
338
- const maxDepth = 10; // Limit traversal depth to avoid performance issues
339
- while (current && depth < maxDepth) {
340
- const ancestorCheck = checkElementForMapPattern(current);
341
- if (ancestorCheck.isInMap) {
342
- return {
343
- isInMap: true,
344
- reason: `This element is a child of a dynamically generated list item. ${ancestorCheck.reason}`,
345
- siblingCount: ancestorCheck.siblingCount
346
- };
347
- }
348
- current = current.parentElement;
349
- depth++;
350
- }
351
- return { isInMap: false };
352
- }
353
- /**
354
- * Helper function to check if a specific element is part of a map pattern
355
- */
356
- function checkElementForMapPattern(element) {
357
- const parent = element.parentElement;
358
- if (!parent) {
359
- return { isInMap: false };
360
- }
361
- // Get all sibling elements (including the element itself)
362
- const siblings = Array.from(parent.children).filter((sibling) => sibling instanceof HTMLElement);
363
- // Need at least 2 siblings to detect a pattern
364
- if (siblings.length < 2) {
365
- return { isInMap: false };
366
- }
367
- // Get source location for the target element
368
- const elementSource = getReactFiberSource(element);
369
- // If we can't get source for the element, try data-keak-src attribute
370
- let elementSourceKey = null;
371
- if (elementSource) {
372
- elementSourceKey = `${elementSource.fileName}:${elementSource.lineNumber}`;
373
- }
374
- else {
375
- const keakSrc = element.getAttribute('data-keak-src');
376
- if (keakSrc) {
377
- // Format is "file:line:column", we use file:line as key
378
- const parts = keakSrc.split(':');
379
- if (parts.length >= 2) {
380
- const fileName = parts.slice(0, -2).join(':'); // Handle Windows paths
381
- const lineNumber = parts[parts.length - 2];
382
- elementSourceKey = `${fileName}:${lineNumber}`;
383
- }
384
- }
385
- }
386
- // If we don't have source info, we can't detect map patterns reliably
387
- if (!elementSourceKey) {
388
- return { isInMap: false };
389
- }
390
- // Check how many siblings share the same source location
391
- let matchingSiblings = 0;
392
- for (const sibling of siblings) {
393
- const siblingSource = getReactFiberSource(sibling);
394
- let siblingSourceKey = null;
395
- if (siblingSource) {
396
- siblingSourceKey = `${siblingSource.fileName}:${siblingSource.lineNumber}`;
397
- }
398
- else {
399
- const keakSrc = sibling.getAttribute('data-keak-src');
400
- if (keakSrc) {
401
- const parts = keakSrc.split(':');
402
- if (parts.length >= 2) {
403
- const fileName = parts.slice(0, -2).join(':');
404
- const lineNumber = parts[parts.length - 2];
405
- siblingSourceKey = `${fileName}:${lineNumber}`;
406
- }
407
- }
408
- }
409
- if (siblingSourceKey === elementSourceKey) {
410
- matchingSiblings++;
411
- }
412
- }
413
- // If 2+ siblings share the same source location, it's likely a map/forEach
414
- // We use >= 2 because the element itself counts as one
415
- if (matchingSiblings >= 2) {
416
- return {
417
- isInMap: true,
418
- reason: `Multiple elements (${matchingSiblings}) share the same source location, indicating they're generated from a .map() or similar dynamic list pattern`,
419
- siblingCount: matchingSiblings
420
- };
421
- }
422
- return { isInMap: false };
423
- }
424
318
 
425
319
  const ElementSelector = ({ onElementSelected, onCancel, }) => {
426
320
  const [hoveredElement, setHoveredElement] = useState(null);
427
- const [mapWarning, setMapWarning] = useState({ show: false, message: "" });
428
321
  const highlightRef = useRef(null);
429
322
  useEffect(() => {
430
323
  const handleMouseMove = (e) => {
@@ -449,27 +342,9 @@ const ElementSelector = ({ onElementSelected, onCancel, }) => {
449
342
  target.closest(".keak-toolbar") ||
450
343
  target.closest(".keak-selector-highlight") ||
451
344
  target.closest(".keak-selector-tooltip") ||
452
- target.closest(".keak-selector-instructions") ||
453
- target.closest(".keak-map-warning")) {
345
+ target.closest(".keak-selector-instructions")) {
454
346
  return;
455
347
  }
456
- // Check if element is inside a dynamic list (.map(), .forEach(), etc.)
457
- const mapCheck = isElementInDynamicList(target);
458
- if (mapCheck.isInMap) {
459
- // Show warning and prevent selection
460
- setMapWarning({
461
- show: true,
462
- message: mapCheck.reason || "Element is part of a dynamically generated list",
463
- siblingCount: mapCheck.siblingCount
464
- });
465
- // Auto-hide warning after 5 seconds
466
- setTimeout(() => {
467
- setMapWarning({ show: false, message: "" });
468
- }, 5000);
469
- return; // Prevent selection
470
- }
471
- // Clear any existing warning
472
- setMapWarning({ show: false, message: "" });
473
348
  onElementSelected(target);
474
349
  };
475
350
  const handleKeyDown = (e) => {
@@ -632,65 +507,7 @@ const ElementSelector = ({ onElementSelected, onCancel, }) => {
632
507
  return { selector, text, source, impact };
633
508
  };
634
509
  const elementInfo = hoveredElement ? getElementInfo(hoveredElement) : null;
635
- return (jsxs(Fragment, { children: [jsx("div", { ref: highlightRef, className: "keak-selector-highlight" }), mapWarning.show && (jsx("div", { className: "keak-map-warning", style: {
636
- position: "fixed",
637
- top: "140px",
638
- left: "50%",
639
- transform: "translateX(-50%)",
640
- maxWidth: "500px",
641
- background: "hsl(0 84.2% 60.2%)",
642
- border: "1px solid hsl(0 72.2% 50.6%)",
643
- borderRadius: "8px",
644
- padding: "16px 20px",
645
- boxShadow: "0 10px 30px 0 rgba(0, 0, 0, 0.3)",
646
- fontFamily: 'Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif',
647
- zIndex: 1000000,
648
- color: "white",
649
- animation: "slideDown 0.3s ease-out",
650
- }, children: jsxs("div", { style: { display: "flex", alignItems: "flex-start", gap: "12px" }, children: [jsx("div", { style: {
651
- fontSize: "20px",
652
- lineHeight: "1",
653
- marginTop: "2px",
654
- }, children: "\u26A0\uFE0F" }), jsxs("div", { style: { flex: 1 }, children: [jsx("div", { style: {
655
- fontSize: "15px",
656
- fontWeight: 600,
657
- marginBottom: "8px",
658
- }, children: "Cannot select element from dynamic list" }), jsx("div", { style: {
659
- fontSize: "13px",
660
- lineHeight: "1.5",
661
- opacity: 0.95,
662
- marginBottom: "12px",
663
- }, children: "This element is part of a dynamically generated list (.map(), .forEach(), etc.). Selecting individual items isn't supported because:" }), jsxs("ul", { style: {
664
- fontSize: "13px",
665
- lineHeight: "1.6",
666
- margin: "0 0 12px 0",
667
- paddingLeft: "20px",
668
- opacity: 0.95,
669
- listStyle: "none",
670
- }, children: [jsxs("li", { style: { position: "relative", paddingLeft: "16px" }, children: [jsx("span", { style: { position: "absolute", left: 0 }, children: "-" }), "The data might come from props or a database"] }), jsxs("li", { style: { position: "relative", paddingLeft: "16px" }, children: [jsx("span", { style: { position: "absolute", left: 0 }, children: "-" }), "Variants would affect all items, not just one"] })] }), jsx("div", { style: {
671
- fontSize: "13px",
672
- fontWeight: 600,
673
- marginTop: "12px",
674
- paddingTop: "12px",
675
- borderTop: "1px solid rgba(255, 255, 255, 0.2)",
676
- }, children: "\uD83D\uDCA1 Alternatives:" }), jsxs("ul", { style: {
677
- fontSize: "13px",
678
- lineHeight: "1.6",
679
- margin: "8px 0 0 0",
680
- paddingLeft: "20px",
681
- opacity: 0.95,
682
- listStyle: "none",
683
- }, children: [jsxs("li", { style: { position: "relative", paddingLeft: "16px" }, children: [jsx("span", { style: { position: "absolute", left: 0 }, children: "-" }), "Select the parent container to test the entire list"] }), jsxs("li", { style: { position: "relative", paddingLeft: "16px" }, children: [jsx("span", { style: { position: "absolute", left: 0 }, children: "-" }), "Extract list items into a separate component and wrap it in Experiment/Variant"] })] })] }), jsx("button", { onClick: () => setMapWarning({ show: false, message: "" }), style: {
684
- background: "transparent",
685
- border: "none",
686
- color: "white",
687
- cursor: "pointer",
688
- fontSize: "18px",
689
- lineHeight: "1",
690
- padding: "0",
691
- opacity: 0.8,
692
- transition: "opacity 0.2s",
693
- }, onMouseEnter: (e) => (e.currentTarget.style.opacity = "1"), onMouseLeave: (e) => (e.currentTarget.style.opacity = "0.8"), children: "\u00D7" })] }) })), hoveredElement && elementInfo && (jsxs("div", { className: "keak-selector-tooltip", style: {
510
+ return (jsxs(Fragment, { children: [jsx("div", { ref: highlightRef, className: "keak-selector-highlight" }), hoveredElement && elementInfo && (jsxs("div", { className: "keak-selector-tooltip", style: {
694
511
  position: "fixed",
695
512
  bottom: `${window.innerHeight -
696
513
  hoveredElement.getBoundingClientRect().top +
@@ -1340,19 +1157,6 @@ const KeakToolbar = ({ position = 'bottom-right', theme = 'auto' }) => {
1340
1157
  console.log('[Keak Toolbar] Tag:', element.tagName);
1341
1158
  console.log('[Keak Toolbar] HTML (first 300 chars):', element.outerHTML.substring(0, 300));
1342
1159
  console.log('[Keak Toolbar] All attributes:', Array.from(element.attributes).map(a => `${a.name}="${a.value}"`).join(', '));
1343
- // Check if element is inside a dynamic list (.map(), .forEach(), etc.)
1344
- const mapCheck = isElementInDynamicList(element);
1345
- if (mapCheck.isInMap) {
1346
- console.log('[Keak Toolbar] ⚠️ Element is part of a dynamic list, preventing selection');
1347
- console.log('[Keak Toolbar] Reason:', mapCheck.reason);
1348
- // Show a brief visual feedback
1349
- element.style.transition = 'all 0.3s';
1350
- element.style.outline = '3px solid #ef4444';
1351
- setTimeout(() => { element.style.outline = ''; }, 2000);
1352
- // Don't proceed with selection
1353
- setIsSelecting(false);
1354
- return;
1355
- }
1356
1160
  setSelectedElement(element);
1357
1161
  setIsSelecting(false);
1358
1162
  updateSelectedHighlight(element);