docs: fix right sidebar sponsors#1477
Conversation
Summary of ChangesHello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request addresses a minor but important consistency issue by fixing a recurring typo in the codebase. The change ensures that all references to the 'right sidebar' for sponsor display are correctly spelled, improving code readability and maintainability without altering functionality. Highlights
Changelog
Activity
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
|
Caution Review failedPull request was closed or merged during review 📝 WalkthroughWalkthroughThis PR renames sidebar sponsor property names from "ride" to "right" across two files and adds conditional rendering of a "Become a sponsor" link when fewer than 3 normal sponsors are displayed. Total 8 lines modified across the interface definition and component usage. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~8 minutes Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
📝 Coding Plan
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment Tip You can disable poems in the walkthrough.Disable the |
There was a problem hiding this comment.
Code Review
This pull request corrects a typo from rideSidebar to rightSidebar in sponsor-related properties. The fix is applied correctly across the component and the TypeScript interface. I've added a few suggestions to improve maintainability and robustness by avoiding magic strings and providing fallback links for sponsors.
| const normalSponsors = computed(() => sponsors.value.filter(s => s.rightSidebarSize === 'normal')) | ||
| const smallSponsors = computed(() => sponsors.value.filter(s => s.rightSidebarSize === 'small')) |
There was a problem hiding this comment.
Using string literals like 'normal' and 'small' for filtering can be error-prone and harder to maintain. Consider defining these values as constants or an enum in composables/sponsors.ts alongside the JSONSponsor interface and importing them here. This improves type safety and makes future changes easier.
|
|
||
| <div class="aside-sponsors-list"> | ||
| <a v-for="sponsor in normalSponsors" :key="sponsor.login" class="aside-sponsor" target="_blank" :href="sponsor.rideSidebarLink"> | ||
| <a v-for="sponsor in normalSponsors" :key="sponsor.login" class="aside-sponsor" target="_blank" :href="sponsor.rightSidebarLink"> |
There was a problem hiding this comment.
The rightSidebarLink property is optional. If it's missing, this <a> tag will not be a functional link. To provide a fallback, consider using the optional link property from the JSONSponsor interface as well.
<a v-for="sponsor in normalSponsors" :key="sponsor.login" class="aside-sponsor" target="_blank" :href="sponsor.rightSidebarLink || sponsor.link">
|
|
||
| <div class="aside-sponsors-small"> | ||
| <a v-for="sponsor in smallSponsors" :key="sponsor.login" class="aside-sponsor" target="_blank" :href="sponsor.rideSidebarLink"> | ||
| <a v-for="sponsor in smallSponsors" :key="sponsor.login" class="aside-sponsor" target="_blank" :href="sponsor.rightSidebarLink"> |
There was a problem hiding this comment.
More templates
@orpc/ai-sdk
@orpc/arktype
@orpc/client
@orpc/contract
@orpc/experimental-durable-iterator
@orpc/hey-api
@orpc/interop
@orpc/json-schema
@orpc/nest
@orpc/openapi
@orpc/openapi-client
@orpc/otel
@orpc/experimental-pino
@orpc/experimental-publisher
@orpc/experimental-publisher-durable-object
@orpc/experimental-ratelimit
@orpc/react
@orpc/react-query
@orpc/experimental-react-swr
@orpc/server
@orpc/shared
@orpc/solid-query
@orpc/standard-server
@orpc/standard-server-aws-lambda
@orpc/standard-server-fastify
@orpc/standard-server-fetch
@orpc/standard-server-node
@orpc/standard-server-peer
@orpc/svelte-query
@orpc/tanstack-query
@orpc/trpc
@orpc/valibot
@orpc/vue-colada
@orpc/vue-query
@orpc/zod
commit: |
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
Summary by CodeRabbit