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

Searchable select described by vs labelled by #584

Merged
merged 1 commit into from
Oct 1, 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
2 changes: 1 addition & 1 deletion packages/core/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@viamrobotics/prime-core",
"version": "0.0.156",
"version": "0.0.157",
"repository": {
"type": "git",
"url": "https://github.com/viamrobotics/prime.git",
Expand Down
6 changes: 3 additions & 3 deletions packages/core/src/lib/select/searchable-select.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -73,8 +73,8 @@ export let otherOptionPrefix = '';
/** Error message ID, if any. */
export let errorID = '';

/** ID of the element that labels the SearchableSelect. */
export let labelledBy: string | undefined = undefined;
/** ID of the element that describes the SearchableSelect. */
export let describedBy: string | undefined = undefined;
Comment on lines -76 to +77
Copy link
Member

@mcous mcous Sep 30, 2024

Choose a reason for hiding this comment

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

Let's keep both! JK, I just remembered <label for={inputID}>


/**
* Notify the parent of a value change, after Enter key or blur.
Expand Down Expand Up @@ -331,7 +331,7 @@ const handleKeydown = createHandleKey({
aria-multiselectable={multiple}
aria-activedescendant={activeID}
aria-errormessage={errorID}
aria-labelledby={labelledBy}
aria-describedby={describedBy}
on:focus={handleFocus}
on:blur={handleBlur}
on:keydown={handleKeydown}
Expand Down
Loading