Custom Field Drop Down Styling

Home Forums Product Support Forums Ajax Search Pro for WordPress Support Custom Field Drop Down Styling

This topic contains 5 replies, has 2 voices, and was last updated by Ernest Marcinko Ernest Marcinko 3 years, 1 month ago.

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #26574
    jayme.welch48
    jayme.welch48
    Participant

    I set up a custom field drop down for filtering results and cannot seem to change the background from the default grey. I did follow the directions here: https://documentation.ajaxsearchpro.com/theme-options/settings-dropdown, cleared the cache and enabled inline styling.

    Rather than set the style for this one search, I actually prefer to set them in our child stylesheet so all search bars look the same. Can you just tell me what the style names are for the custom field drop downs? I was able to do this for the initial background color and selected item but can’t seem to track the drop-down box and option classes.

    With gratitude,

    Jayme

    Attachments:
    You must be logged in to view attached files.
    #26584
    Ernest Marcinko
    Ernest Marcinko
    Keymaster

    Hi,

    The only way to override that is via custom CSS. You can find the code to all the sections below, just override the colors to your needs:

    span.asp_select2-container--flat .asp_select2-results__option[aria-selected=true] {
        background: #777;
        color: #fff;
    }
    
    span.asp_select2-container--flat .asp_select2-results__option--highlighted[aria-selected] {
        background: #525252 !important;
        color: #fff;
    }
    
    span.asp_select2-container--open .asp_select2-dropdown--below,
    span.asp_select2-container--open .asp_select2-dropdown--above {
        background: #9c6a6a;
    }
    Best,
    Ernest Marcinko

    If you like my products, don't forget to rate them on codecanyon :)


    #26675
    jayme.welch48
    jayme.welch48
    Participant

    I’m so sorry I forgot to reply. This worked perfectly – thank you! The search itself is robust and easy to implement.

    Your Ajax search works great and I appreciate the extra thought put into the performance. If you are continuing development may I request that you have a developer version available where we can extend the layout of the results? It would be great to hook in a WP Bakery UI with your data for a really flexible search mechanism that can be used anywhere.

    With gratitude,

    Jayme

    #26693
    Ernest Marcinko
    Ernest Marcinko
    Keymaster

    Hi Jayme,

    Sure, thank you for your kind words.

    There are some interesting possibilites as of now, that might interest you:
    Results templating
    Filters templating
    Filters API
    Javascript API
    Theme integration functions

    Best,
    Ernest Marcinko

    If you like my products, don't forget to rate them on codecanyon :)


    #26719
    jayme.welch48
    jayme.welch48
    Participant

    Oh wow – this is fantastic! Thank you. I work in a variety of platforms – WordPress, Shopify, Hubspot, etc. and code in .NET, Web APIs, etc. I am truly impressed with the level of thought put into your plugin. For example, I was thrilled that I can create a search listing all therapists that provide support for ADHD while hiding the search bar itself.

    Thank you so much for taking the time to send me additional resources, it is greatly appreciated.

    With gratitude,

    Jayme

    #26732
    Ernest Marcinko
    Ernest Marcinko
    Keymaster
    You cannot access this content. Best,
    Ernest Marcinko

    If you like my products, don't forget to rate them on codecanyon :)


Viewing 6 posts - 1 through 6 (of 6 total)

You must be logged in to reply to this topic.