@devries-cameron20 / composio Mirror · read-only / commits / c95b36454
Fork 0

Composio powers 1000+ toolkits, tool search, context management, authentication, and a sandboxed workbench to help you build AI agents that turn intent into action.

Mirrored from https://github.com/Camo67/composio.git

Synced Nov 22, 07:00 UTC

docs: add Ask AI button to page actions

Add an "Ask AI" button (opens Decimal widget) to the page actions bar, next to the existing Copy/Markdown/Feedback buttons. Also update the Feedback icon from MessageSquare to PenLine for visual distinction. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

Sushmithamallesh committed Feb 19, 2026 at 22:16 UTC c95b36454047e9e02c597437906aff7d17d09f4f
3 files changed +24 -4
docs/components/ask-ai-button.tsx
+1 -1
@@ -13,7 +13,7 @@ function getDecimal() {
13
14 let widgetOpen = false;
15
16 -function toggleDecimalWidget() {
16 +export function toggleDecimalWidget() {
17 const decimal = getDecimal();
18 if (!decimal) {
19 setTimeout(() => {
docs/components/feedback.tsx
+2 -2
@@ -1,7 +1,7 @@
1 'use client';
2
3 import { useState, useRef, useEffect } from 'react';
4 -import { MessageSquare, X, Loader2 } from 'lucide-react';
4 +import { PenLine, X, Loader2 } from 'lucide-react';
5
6 type Sentiment = 'positive' | 'neutral' | 'negative' | null;
7
@@ -91,7 +91,7 @@ export function Feedback({ page }: FeedbackProps) {
91 motion-reduce:transition-none motion-reduce:active:scale-100"
92 aria-label="Share feedback about this page"
93 >
94 - <MessageSquare className="size-3.5" aria-hidden="true" />
94 + <PenLine className="size-3.5" aria-hidden="true" />
95 <span>Feedback</span>
96 </button>
97
docs/components/page-actions.tsx
+21 -1
@@ -1,8 +1,9 @@
1 'use client';
2
3 import { useState, useCallback } from 'react';
4 -import { Copy, Check, Loader2, ExternalLink } from 'lucide-react';
4 +import { Copy, Check, Loader2, ExternalLink, BotMessageSquare } from 'lucide-react';
5 import { Feedback } from './feedback';
6 +import { toggleDecimalWidget } from './ask-ai-button';
7
8 interface PageActionsProps {
9 path: string;
@@ -133,6 +134,25 @@ export function PageActions({ path }: PageActionsProps) {
134 aria-orientation="vertical"
135 />
136
137 + {/* Ask AI */}
138 + <button
139 + type="button"
140 + onClick={toggleDecimalWidget}
141 + className="inline-flex items-center gap-1.5 px-3 py-2 sm:px-2.5 sm:py-1.5 text-xs font-medium
142 + text-fd-muted-foreground hover:text-fd-foreground
143 + bg-fd-secondary/50 hover:bg-fd-secondary
144 + rounded-md
145 + transition-all duration-150 ease-out
146 + focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-fd-ring focus-visible:ring-offset-2 focus-visible:ring-offset-fd-background
147 + active:scale-[0.98]
148 + touch-manipulation
149 + motion-reduce:transition-none motion-reduce:active:scale-100"
150 + aria-label="Ask AI"
151 + >
152 + <BotMessageSquare className="size-3.5" aria-hidden="true" />
153 + <span>Ask AI</span>
154 + </button>
155 +
156 {/* Feedback */}
157 <Feedback page={path} />
158 </div>