Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update claude extension #15705

Merged
merged 2 commits into from
Dec 9, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions extensions/claude/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Claude Changelog

## [Update] - 2024-12-09

- Feature: Added copy question actions

## [Update] - 2024-11-05

- Feature: Added new [Claude 3.5 Haiku](https://www.anthropic.com/news/3-5-models-and-computer-use)
Expand Down
3 changes: 2 additions & 1 deletion extensions/claude/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@
"contributors": [
"alextlopez11",
"FelixII",
"midnite"
"midnite",
"ridemountainpig"
],
"categories": [
"Productivity",
Expand Down
60 changes: 35 additions & 25 deletions extensions/claude/src/views/chat.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { ActionPanel, clearSearchBar, Icon, List } from "@raycast/api";
import { Action, ActionPanel, clearSearchBar, Icon, List } from "@raycast/api";
import { v4 as uuidv4 } from "uuid";
import { DestructiveAction, PrimaryAction } from "../actions";
import { CopyActionSection } from "../actions/copy";
Expand Down Expand Up @@ -43,30 +43,40 @@ export const ChatView = ({
onModelChange={onModelChange}
/>
{use.chats.data.length > 0 && (
<ActionPanel.Section title="Restart">
<DestructiveAction
title="Start New Conversation"
icon={Icon.RotateAntiClockwise}
dialog={{
title: "Are you sure you want to start a new conversation?",
primaryButton: "Start New",
}}
onAction={() => {
setConversation({
id: uuidv4(),
chats: [],
model: model,
pinned: false,
updated_at: "",
created_at: new Date().toISOString(),
});
use.chats.clear();
clearSearchBar();
use.chats.setLoading(false);
}}
shortcut={{ modifiers: ["cmd", "shift"], key: "n" }}
/>
</ActionPanel.Section>
<>
<ActionPanel.Section title="Question">
<Action.CopyToClipboard
title="Copy Question"
icon={Icon.CopyClipboard}
content={selectedChat.question}
shortcut={{ modifiers: ["cmd"], key: "c" }}
/>
</ActionPanel.Section>
<ActionPanel.Section title="Restart">
<DestructiveAction
title="Start New Conversation"
icon={Icon.RotateAntiClockwise}
dialog={{
title: "Are you sure you want to start a new conversation?",
primaryButton: "Start New",
}}
onAction={() => {
setConversation({
id: uuidv4(),
chats: [],
model: model,
pinned: false,
updated_at: "",
created_at: new Date().toISOString(),
});
use.chats.clear();
clearSearchBar();
use.chats.setLoading(false);
}}
shortcut={{ modifiers: ["cmd", "shift"], key: "n" }}
/>
</ActionPanel.Section>
</>
)}
<PreferencesActionSection />
</ActionPanel>
Expand Down