Skip to content

Update raycast-explorer extension#17374

Merged
samuelkraft merged 3 commits intoraycast:mainfrom
zayadur:ext/raycast-explorer
Feb 27, 2025
Merged

Update raycast-explorer extension#17374
samuelkraft merged 3 commits intoraycast:mainfrom
zayadur:ext/raycast-explorer

Conversation

@zayadur
Copy link
Contributor

@zayadur zayadur commented Feb 26, 2025

Description

  • Fixed React warning "Encountered two children with the same key, nagauta" in themes dropdown by using composite keys (author_${username}_${name}) to handle authors with same username but different display names
  • Added proper handling for undefined creativity values in presets and prompts components to prevent "Cannot read properties of undefined (reading 'charAt')" errors
  • Implemented fallback values (preset.creativity || "unspecified") and null checks for creativity properties to ensure consistent display and search functionality

Screencast

Screenshot 2025-02-26 at 6 40 19 PM
TypeError: Cannot read properties of undefined (reading 'charAt')

a4:explore-presets.tsx:13:76

---
10: const baseUrl = "https://ray.so/presets";
11: 
12: export default function ExplorePresets() {
13:   const { data: aiModels, isLoading: isAiModelsLoading } = useCachedPromise(getAvailableAiModels);
14:   const { data: categories, isLoading } = useFetch<PresetCategory[]>(`https://ray.so/api/presets`);
15:   const [selectedCategory, setSelectedCategory] = useState("");
16: 
---

_r:index.js:8:2593
    at ray-navigation-stack
No:index.js:8:2094

Checklist

- cleanup
- fix: use composite keys for author lookup, handle undefined creativity value
- Initial commit
@raycastbot raycastbot added extension fix / improvement Label for PRs with extension's fix improvements extension: raycast-explorer Issues related to the raycast-explorer extension labels Feb 26, 2025
@raycastbot
Copy link
Collaborator

raycastbot commented Feb 26, 2025

Thank you for your contribution! 🎉

🔔 @thomaslombart @EvanZhouDev @mil3na @xilopaint @samuelkraft @abnershang 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

Copy link
Contributor

@samuelkraft samuelkraft left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks @zayadur

@samuelkraft samuelkraft merged commit 7d2ee3f into raycast:main Feb 27, 2025
9 checks passed
@github-actions
Copy link
Contributor

Published to the Raycast Store:
https://raycast.com/raycast/raycast-explorer

@raycastbot
Copy link
Collaborator

🎉 🎉 🎉

We've rewarded your Raycast account with some credits. You will soon be able to exchange them for some swag.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

extension fix / improvement Label for PRs with extension's fix improvements extension: raycast-explorer Issues related to the raycast-explorer extension

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants