/*!
 * KoliBri - The accessible HTML-Standard
 */
import{h}from"./index-C_yiBYg2.js";import{c as clsx}from"./clsx-eK3rPvPS.js";const CustomSuggestionsOptionFc=({disabled:o,index:s,ref:e,selected:t,onClick:n,onMouseOver:i,onFocus:r,onKeyDown:u,option:l,searchTerm:c})=>h("li",{id:`option-${s}`,key:`-${s}`,ref:e,"data-index":s,tabIndex:-1,role:"option","aria-selected":t?"true":void 0,"aria-disabled":o?"true":void 0,onClick:n,onMouseOver:i,onFocus:r,class:clsx("kol-custom-suggestions-option",{"kol-custom-suggestions-option--disabled":o}),onKeyDown:u},((o,s)=>{if(!(null==s?void 0:s.trim()))return o;const e=new RegExp(`(${s.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")})`,"gi");return o.split(e).map((o,s)=>e.test(o)?h("mark",{key:s},o):o)})(String(l),c||"")),CustomSuggestionsOptionsGroupFc=({blockSuggestionMouseOver:o,onKeyDown:s,style:e},t)=>h("ul",{role:"listbox",style:e,class:clsx("kol-custom-suggestions-options-group",{"kol-custom-suggestions-options-group--cursor-hidden":o}),onKeyDown:s},t);export{CustomSuggestionsOptionsGroupFc as C,CustomSuggestionsOptionFc as a};