-
Notifications
You must be signed in to change notification settings - Fork 1
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
feature/hit-10388-add-search-placeholde #849
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
WalkthroughThe changes introduce a new property called Changes
Possibly related PRs
Suggested reviewers
Poem
🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
🧹 Outside diff range and nitpick comments (1)
packages/vue/src/Form/Select/OcSelect.vue (1)
337-337
: Add JSDoc comments to clarify placeholder propsThe component now has two placeholder-related props:
placeholder
andsearchPlaceholder
. Consider adding JSDoc comments to clarify their distinct purposes.Add documentation above the props:
const props = defineProps({ + /** + * Placeholder text shown when no option is selected + */ placeholder: { type: String, default: 'Placeholder' }, + /** + * Placeholder text shown in the search input fields + */ searchPlaceholder: { type: String, default: 'Search' },
searchPlaceholder: { | ||
type: String, | ||
default: 'Search' | ||
}, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ensure consistent usage of searchPlaceholder across all search inputs
The new searchPlaceholder
prop is well-defined, but it's not consistently applied. While it's used in the inline search input, the dropdown search input still uses a hardcoded "Search" placeholder.
Apply this change to ensure consistency:
<Input
ref="searchInputRef"
v-model="query"
icon="search"
- placeholder="Search"
+ :placeholder="searchPlaceholder"
@update:model-value="$emit('onSearchKeywords', query)"
>
Committable suggestion skipped: line range outside the PR's diff.
Summary by CodeRabbit
New Features
OcSelect
component, allowing users to see a dynamic placeholder text instead of a static one.Improvements
searchPlaceholder
property.