Conversation
- Remove unused MiroApi - Update package.json publish command - Remove owner - Add owner - Add command to list recent boards - Initial commit
|
Thank you for your contribution! 🎉 🔔 @felixhaeberle @mathieudutour you might want to have a look. You can use this guide to learn how to check out the Pull Request locally in order to test it. Due to our current reduced availability, the initial review may take up to 10-15 business days |
There was a problem hiding this comment.
PR Summary
This PR adds a new "Recent Boards" command to the Miro extension and reorganizes the board listing functionality with improved component structure.
- The changelog entry for "Add command to show recent boards" should use
{PR_MERGE_DATE}instead of "2025-03-10" - The command name change from
list-boardstolist-my-boardsin package.json may affect users' saved preferences - consider keeping the old name authorize()calls inlist-my-boards.tsxandlist-recent-boards.tsxshould be wrapped in try-catch blocks- Could simplify error toast handling in
list-boards.tsxby usingshowFailureToastfrom@raycast/utils - Since there are multiple commands, consider adding subtitles with "Miro" to differentiate them in the root search
💡 (1/5) You can manually trigger the bot by mentioning @greptileai in a comment!
6 file(s) reviewed, 7 comment(s)
Edit PR Review Bot Settings | Greptile
| { | ||
| "name": "list-recent-boards", | ||
| "title": "Recent Boards", | ||
| "description": "Search & Open recent Miro boards in seconds", | ||
| "mode": "view" | ||
| } |
There was a problem hiding this comment.
style: Consider adding a subtitle with 'Miro' to distinguish commands when multiple extensions are shown together
There was a problem hiding this comment.
I followed the previous structure of descriptions.
| toast.style = Toast.Style.Success; | ||
| } catch (err) { | ||
| console.error(err); | ||
| toast.title = "Could not remove member."; |
There was a problem hiding this comment.
logic: Error message 'Could not remove member' is incorrect for board deletion operation
| toast.title = "Could not remove member."; | |
| toast.title = "Could not delete board."; |
There was a problem hiding this comment.
Did not touch this implementation, only moved it.
| const toast = await showToast({ style: Toast.Style.Animated, title: "Deleting board..." }); | ||
| try { | ||
| await mutate(miro.deleteBoard(item.id), { | ||
| optimisticUpdate(data) { | ||
| return data.filter((x) => x.id !== item.id); | ||
| }, | ||
| }); | ||
| toast.title = "🎉 Board deleted!"; | ||
| toast.style = Toast.Style.Success; | ||
| } catch (err) { | ||
| console.error(err); | ||
| toast.title = "Could not remove member."; | ||
| toast.message = String(err); | ||
| toast.style = Toast.Style.Failure; | ||
| } |
There was a problem hiding this comment.
style: Could be simplified using showFailureToast from @raycast/utils
There was a problem hiding this comment.
Did not touch this implementation, only moved it.
| async () => { | ||
| await miro.authorize(); | ||
| return await miro.fetchRecentItems(); | ||
| }, |
There was a problem hiding this comment.
logic: API calls should be wrapped in try-catch to handle potential auth and network errors gracefully
| async () => { | |
| await miro.authorize(); | |
| return await miro.fetchRecentItems(); | |
| }, | |
| async () => { | |
| try { | |
| await miro.authorize(); | |
| return await miro.fetchRecentItems(); | |
| } catch (error) { | |
| showFailureToast(error instanceof Error ? error.message : "Failed to fetch recent boards"); | |
| return []; | |
| } | |
| }, |
There was a problem hiding this comment.
Copied the implementation from list-boards.tsx and adapted it for recent boards. Did not do any refactoring.
| async function fetchItems(url: RequestInfo): Promise<Board[]> { | ||
| const response = await fetch(url, { |
There was a problem hiding this comment.
logic: fetchItems should call authorize() first to ensure valid auth token
| async function fetchItems(url: RequestInfo): Promise<Board[]> { | |
| const response = await fetch(url, { | |
| async function fetchItems(url: RequestInfo): Promise<Board[]> { | |
| await authorize(); | |
| const response = await fetch(url, { |
There was a problem hiding this comment.
Did not touch this implementation, only moved it.
|
Looks good to me, @felixhaeberle do you want to check this? |
|
@pernielsentikaer would you consider approving, or do you think we should wait a bit longer? |
|
THANKS @Silv-1 for taking this over <3 |
pernielsentikaer
left a comment
There was a problem hiding this comment.
Hi 👋
Looks good to me, approved 🔥
|
Published to the Raycast Store: |
|
🎉 🎉 🎉 We've rewarded your Raycast account with some credits. You will soon be able to exchange them for some swag. |
Description
Screencast
Checklist
npm run buildand tested this distribution build in Raycastassetsfolder are used by the extension itselfREADMEare placed outside of themetadatafolder