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

[Bug]: Improve input description of dropdown input plugin #652

Open
AgentSmith0 opened this issue Nov 3, 2023 · 3 comments
Open

[Bug]: Improve input description of dropdown input plugin #652

AgentSmith0 opened this issue Nov 3, 2023 · 3 comments
Labels
bug Something isn't working

Comments

@AgentSmith0
Copy link

Bug description

The dropdown input doesn't have any description if the placeholder attribute of the select element isn't set.

Expected behavior

What about adding a default placeholder attribute to the input which shows something like 'Search options...'?

Steps to reproduce

  1. See example here: https://tom-select.js.org/plugins/dropdown-input/

Additional context

  • OS: Any
  • Browser Any
  • Version Any
  • Device: Any
@AgentSmith0 AgentSmith0 added the bug Something isn't working label Nov 3, 2023
@pvh-archifact
Copy link

For adding placeholder text to the 'search' input in the dropdown_input plugin you need to add the option to the plugin itself. It's not a bug but simply not an option for the dropdown_input plugin.
You can do something like this as a work around:

const TS = new TomSelect('#ex-dropdown-input',{
    plugins: ['dropdown_input'],
    onFocus: () =>{
        TS.control_input.setAttribute("placeholder","Search..."); 
    }  
});

Copy link

This issue has not been active in 120 days and has been marked "stale". Remove stale label or comment or this will be closed in 15 days

@github-actions github-actions bot added the stale No activity label Mar 21, 2024
@AgentSmith0
Copy link
Author

Any plans on fixing this issue?

@github-actions github-actions bot removed the stale No activity label Mar 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants