Socket
Socket
Sign inDemoInstall

@reach/combobox

Package Overview
Dependencies
Maintainers
4
Versions
63
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@reach/combobox - npm Package Compare versions

Comparing version 0.8.3 to 0.8.4

1

dist/combobox.cjs.development.js

@@ -902,3 +902,2 @@ 'use strict';

console.log(event);
var currentState = chart.states[state];

@@ -905,0 +904,0 @@ var nextState = currentState && currentState.on[event];

2

dist/combobox.cjs.production.min.js

@@ -1,2 +0,2 @@

"use strict";function e(e){return e&&"object"==typeof e&&"default"in e?e.default:e}Object.defineProperty(exports,"__esModule",{value:!0});var t=require("react"),n=e(t);require("prop-types");var o,a,r,u,i,l=require("@reach/utils"),c=require("@reach/descendants"),s=require("highlight-words-core"),v=e(require("escape-regexp")),E=require("@reach/auto-id"),f=require("@reach/popover"),d=e(f);function C(){return(C=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(e[o]=n[o])}return e}).apply(this,arguments)}function T(e,t){if(null==e)return{};var n,o,a={},r=Object.keys(e);for(o=0;o<r.length;o++)t.indexOf(n=r[o])>=0||(a[n]=e[n]);return a}var p="IDLE",I={initial:p,states:(i={},i.IDLE={on:(o={},o.BLUR=p,o.CLEAR=p,o.CHANGE="SUGGESTING",o.INITIAL_CHANGE=p,o.FOCUS="SUGGESTING",o.NAVIGATE="NAVIGATING",o.OPEN_WITH_BUTTON="SUGGESTING",o)},i.SUGGESTING={on:(a={},a.CHANGE="SUGGESTING",a.FOCUS="SUGGESTING",a.NAVIGATE="NAVIGATING",a.CLEAR=p,a.ESCAPE=p,a.BLUR=p,a.SELECT_WITH_CLICK=p,a.INTERACT="INTERACTING",a.CLOSE_WITH_BUTTON=p,a)},i.NAVIGATING={on:(r={},r.CHANGE="SUGGESTING",r.FOCUS="SUGGESTING",r.CLEAR=p,r.BLUR=p,r.ESCAPE=p,r.NAVIGATE="NAVIGATING",r.SELECT_WITH_CLICK=p,r.SELECT_WITH_KEYBOARD=p,r.CLOSE_WITH_BUTTON=p,r.INTERACT="INTERACTING",r)},i.INTERACTING={on:(u={},u.CHANGE="SUGGESTING",u.FOCUS="SUGGESTING",u.BLUR=p,u.ESCAPE=p,u.NAVIGATE="NAVIGATING",u.CLOSE_WITH_BUTTON=p,u.SELECT_WITH_CLICK=p,u)},i)},A=function(e,t){var n=C({},e,{lastEventType:t.type});switch(t.type){case"CHANGE":case"INITIAL_CHANGE":return C({},n,{navigationValue:null,value:t.value});case"NAVIGATE":case"OPEN_WITH_BUTTON":return C({},n,{navigationValue:G(n,t)});case"CLEAR":return C({},n,{value:"",navigationValue:null});case"BLUR":case"ESCAPE":return C({},n,{navigationValue:null});case"SELECT_WITH_CLICK":return t.callback(t.value),C({},n,{value:t.value,navigationValue:null});case"SELECT_WITH_KEYBOARD":return t.callback(e.navigationValue||null),C({},n,{value:e.navigationValue,navigationValue:null});case"CLOSE_WITH_BUTTON":return C({},n,{navigationValue:null});case"INTERACT":return n;case"FOCUS":return C({},n,{navigationValue:G(n,t)});default:return n}},N=["SUGGESTING","NAVIGATING","INTERACTING"],b=function(e){return N.includes(e)};function G(e,t){return t.value?t.value:t.persistSelection?e.value:null}var h=c.createDescendantContext("ComboboxDescendantContext"),S=l.createNamedContext("ComboboxContext",{}),x=l.createNamedContext("OptionContext",{}),R=l.forwardRefWithAs((function(e,o){var a=e.onSelect,r=e.openOnFocus,u=void 0!==r&&r,i=e.children,s=e.as,v=void 0===s?"div":s,f=T(e,["onSelect","openOnFocus","children","as"]),d=c.useDescendants(),p=d[0],N=d[1],G=t.useRef(),x=t.useRef(),R=t.useRef(),g=t.useRef(),m=t.useRef(),O=function(e,n,o){var a=t.useState(e.initial),r=a[0],u=a[1],i=t.useReducer(n,{value:"",navigationValue:null}),l=i[1];return[r,i[0],function(t,n){void 0===n&&(n={}),console.log(t);var o=e.states[r],a=o&&o.on[t];if(a)return l(C({type:t,state:r,nextState:r},n)),void u(a)}]}(I,A),_=O[0],L=O[1],V=O[2];!function(e,t){l.useIsomorphicLayoutEffect((function(){"NAVIGATE"!==e&&"ESCAPE"!==e&&"SELECT_WITH_CLICK"!==e&&"OPEN_WITH_BUTTON"!==e||t.current.focus()}),[t,e])}(L.lastEventType,G);var w=E.useId(f.id),U=w?l.makeId("listbox",w):"listbox",H={autocompletePropRef:g,buttonRef:R,data:L,inputRef:G,isVisible:b(_),listboxId:U,onSelect:a||l.noop,openOnFocus:u,persistSelectionRef:m,popoverRef:x,state:_,transition:V};return t.useEffect((function(){return l.checkStyles("combobox")}),[]),n.createElement(c.DescendantProvider,{context:h,items:p,set:N},n.createElement(S.Provider,{value:H},n.createElement(v,Object.assign({"aria-haspopup":"listbox","aria-owns":U,"aria-expanded":H.isVisible},f,{"data-reach-combobox":"",ref:o,role:"combobox"}),i)))})),g=l.forwardRefWithAs((function(e,o){var a=e.as,r=void 0===a?"input":a,u=e.selectOnClick,i=void 0!==u&&u,c=e.autocomplete,s=void 0===c||c,v=e.onClick,E=e.onChange,f=e.onKeyDown,d=e.onBlur,C=e.onFocus,p=e.value,I=T(e,["as","selectOnClick","autocomplete","onClick","onChange","onKeyDown","onBlur","onFocus","value"]),A=t.useRef(p).current,N=t.useRef(!1);l.useUpdateEffect((function(){N.current=!0}),[p]);var b=t.useContext(S),G=b.data,h=G.navigationValue,x=G.value,R=G.lastEventType,g=b.inputRef,m=b.state,O=b.transition,_=b.listboxId,L=b.autocompletePropRef,V=b.openOnFocus,k=l.useForkedRef(g,o),y=t.useRef(!1),B=w(),W=U(),D=null!=p;l.useIsomorphicLayoutEffect((function(){L.current=s}),[s,L]);var F=function(e){""===e.trim()?O("CLEAR"):O(e!==A||N.current?"CHANGE":"INITIAL_CHANGE",{value:e})};D&&p!==x&&F(p);var K=!s||"NAVIGATING"!==m&&"INTERACTING"!==m?p||x:h||p||x;return n.createElement(r,Object.assign({"aria-activedescendant":h?String(H(h)):void 0,"aria-autocomplete":"both","aria-controls":_},I,{"data-reach-combobox-input":"",ref:k,onBlur:l.wrapEvent(d,W),onChange:l.wrapEvent(E,(function(e){D||F(e.target.value)})),onClick:l.wrapEvent(v,(function(){y.current&&(y.current=!1,g.current.select())})),onFocus:l.wrapEvent(C,(function(){i&&(y.current=!0),V&&"SELECT_WITH_CLICK"!==R&&O("FOCUS")})),onKeyDown:l.wrapEvent(f,B),value:K||""}))})),m=t.forwardRef((function(e,o){var a=e.children,r=e.portal,u=void 0===r||r,i=e.onKeyDown,c=e.onBlur,s=T(e,["children","portal","onKeyDown","onBlur"]),v=t.useContext(S),E=v.inputRef,C=v.isVisible,p=l.useForkedRef(v.popoverRef,o),I=w(),A=U(),N={"data-reach-combobox-popover":"",onKeyDown:l.wrapEvent(i,I),onBlur:l.wrapEvent(c,A),hidden:!C,tabIndex:-1,children:a};return u?n.createElement(d,Object.assign({},s,{ref:p,position:f.positionMatchWidth,targetRef:E},N)):n.createElement("div",Object.assign({ref:p},s,N))})),O=l.forwardRefWithAs((function(e,o){var a=e.persistSelection,r=void 0!==a&&a,u=e.as,i=void 0===u?"ul":u,l=T(e,["persistSelection","as"]),c=t.useContext(S),s=c.listboxId;return r&&(c.persistSelectionRef.current=!0),n.createElement(i,Object.assign({},l,{ref:o,"data-reach-combobox-list":"",role:"listbox",id:s}))})),_=t.forwardRef((function(e,o){var a=e.children,r=e.value,u=e.onClick,i=T(e,["children","value","onClick"]),s=t.useContext(S),v=s.onSelect,E=s.data.navigationValue,f=s.transition,d=t.useRef(null),C=l.useForkedRef(o,d),p=c.useDescendant({context:h,element:d.current,value:r}),I=E===r;return n.createElement(x.Provider,{value:{value:r,index:p}},n.createElement("li",Object.assign({"aria-selected":I},i,{"data-reach-combobox-option":"",ref:C,id:String(H(r)),role:"option","data-highlighted":I?"":void 0,tabIndex:-1,onClick:l.wrapEvent(u,(function(){f("SELECT_WITH_CLICK",{value:r,callback:v})})),children:a||n.createElement(L,null)})))}));function L(){var e=t.useContext(x).value,o=t.useContext(S).data.value,a=t.useMemo((function(){return s.findAll({searchWords:v(o||"").split(/\s+/),textToHighlight:e})}),[o,e]);return n.createElement(n.Fragment,null,a.length?a.map((function(t,o){var a=e.slice(t.start,t.end);return n.createElement("span",{key:o,"data-user-value":!!t.highlight||void 0,"data-suggested-value":!t.highlight||void 0},a)})):e)}var V=l.forwardRefWithAs((function(e,o){var a=e.as,r=void 0===a?"button":a,u=e.onClick,i=e.onKeyDown,c=T(e,["as","onClick","onKeyDown"]),s=t.useContext(S),v=s.transition,E=s.state,f=s.listboxId,d=s.isVisible,C=l.useForkedRef(s.buttonRef,o),I=w();return n.createElement(r,Object.assign({"aria-controls":f,"aria-haspopup":"listbox","aria-expanded":d},c,{"data-reach-combobox-button":"",ref:C,onClick:l.wrapEvent(u,(function(){v(E===p?"OPEN_WITH_BUTTON":"CLOSE_WITH_BUTTON")})),onKeyDown:l.wrapEvent(i,I)}))}));function w(){var e=t.useContext(S),n=e.data.navigationValue,o=e.onSelect,a=e.state,r=e.transition,u=e.autocompletePropRef,i=e.persistSelectionRef,l=t.useContext(h).descendants;return function(e){switch(e.key){case"ArrowDown":if(e.preventDefault(),!l||0===l.length)return;if(a===p)r("NAVIGATE",{persistSelection:i.current});else{var t=l.findIndex((function(e){return e.value===n}));r("NAVIGATE",t===l.length-1?u.current?{value:null}:{value:l[0].value}:{value:l[(t+1)%l.length].value})}break;case"ArrowUp":if(e.preventDefault(),!l||0===l.length)return;if(a===p)r("NAVIGATE");else{var c=l.findIndex((function(e){return e.value===n}));r("NAVIGATE",0===c?u.current?{value:null}:{value:l[l.length-1].value}:-1===c?{value:l.length?l[l.length-1].value:null}:{value:l[(c-1+l.length)%l.length].value})}break;case"Escape":a!==p&&r("ESCAPE");break;case"Enter":"NAVIGATING"===a&&null!==n&&(e.preventDefault(),r("SELECT_WITH_KEYBOARD",{callback:o}))}}}function U(){var e=t.useContext(S),n=e.state,o=e.transition,a=e.popoverRef,r=e.inputRef,u=e.buttonRef;return function(){var e=l.getOwnerDocument(r.current)||document;requestAnimationFrame((function(){e.activeElement!==r.current&&e.activeElement!==u.current&&a.current&&(a.current.contains(e.activeElement)?"INTERACTING"!==n&&o("INTERACT"):o("BLUR"))}))}}var H=function(e){var t=0;if(0===e.length)return t;for(var n=0;n<e.length;n++)t=(t<<5)-t+e.charCodeAt(n),t&=t;return t};exports.Combobox=R,exports.ComboboxButton=V,exports.ComboboxInput=g,exports.ComboboxList=O,exports.ComboboxOption=_,exports.ComboboxOptionText=L,exports.ComboboxPopover=m;
"use strict";function e(e){return e&&"object"==typeof e&&"default"in e?e.default:e}Object.defineProperty(exports,"__esModule",{value:!0});var t=require("react"),n=e(t);require("prop-types");var a,o,r,u,i,l=require("@reach/utils"),c=require("@reach/descendants"),s=require("highlight-words-core"),v=e(require("escape-regexp")),E=require("@reach/auto-id"),f=require("@reach/popover"),d=e(f);function C(){return(C=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var a in n)Object.prototype.hasOwnProperty.call(n,a)&&(e[a]=n[a])}return e}).apply(this,arguments)}function T(e,t){if(null==e)return{};var n,a,o={},r=Object.keys(e);for(a=0;a<r.length;a++)t.indexOf(n=r[a])>=0||(o[n]=e[n]);return o}var p="IDLE",I={initial:p,states:(i={},i.IDLE={on:(a={},a.BLUR=p,a.CLEAR=p,a.CHANGE="SUGGESTING",a.INITIAL_CHANGE=p,a.FOCUS="SUGGESTING",a.NAVIGATE="NAVIGATING",a.OPEN_WITH_BUTTON="SUGGESTING",a)},i.SUGGESTING={on:(o={},o.CHANGE="SUGGESTING",o.FOCUS="SUGGESTING",o.NAVIGATE="NAVIGATING",o.CLEAR=p,o.ESCAPE=p,o.BLUR=p,o.SELECT_WITH_CLICK=p,o.INTERACT="INTERACTING",o.CLOSE_WITH_BUTTON=p,o)},i.NAVIGATING={on:(r={},r.CHANGE="SUGGESTING",r.FOCUS="SUGGESTING",r.CLEAR=p,r.BLUR=p,r.ESCAPE=p,r.NAVIGATE="NAVIGATING",r.SELECT_WITH_CLICK=p,r.SELECT_WITH_KEYBOARD=p,r.CLOSE_WITH_BUTTON=p,r.INTERACT="INTERACTING",r)},i.INTERACTING={on:(u={},u.CHANGE="SUGGESTING",u.FOCUS="SUGGESTING",u.BLUR=p,u.ESCAPE=p,u.NAVIGATE="NAVIGATING",u.CLOSE_WITH_BUTTON=p,u.SELECT_WITH_CLICK=p,u)},i)},A=function(e,t){var n=C({},e,{lastEventType:t.type});switch(t.type){case"CHANGE":case"INITIAL_CHANGE":return C({},n,{navigationValue:null,value:t.value});case"NAVIGATE":case"OPEN_WITH_BUTTON":return C({},n,{navigationValue:G(n,t)});case"CLEAR":return C({},n,{value:"",navigationValue:null});case"BLUR":case"ESCAPE":return C({},n,{navigationValue:null});case"SELECT_WITH_CLICK":return t.callback(t.value),C({},n,{value:t.value,navigationValue:null});case"SELECT_WITH_KEYBOARD":return t.callback(e.navigationValue||null),C({},n,{value:e.navigationValue,navigationValue:null});case"CLOSE_WITH_BUTTON":return C({},n,{navigationValue:null});case"INTERACT":return n;case"FOCUS":return C({},n,{navigationValue:G(n,t)});default:return n}},N=["SUGGESTING","NAVIGATING","INTERACTING"],b=function(e){return N.includes(e)};function G(e,t){return t.value?t.value:t.persistSelection?e.value:null}var h=c.createDescendantContext("ComboboxDescendantContext"),S=l.createNamedContext("ComboboxContext",{}),x=l.createNamedContext("OptionContext",{}),R=l.forwardRefWithAs((function(e,a){var o=e.onSelect,r=e.openOnFocus,u=void 0!==r&&r,i=e.children,s=e.as,v=void 0===s?"div":s,f=T(e,["onSelect","openOnFocus","children","as"]),d=c.useDescendants(),p=d[0],N=d[1],G=t.useRef(),x=t.useRef(),R=t.useRef(),g=t.useRef(),m=t.useRef(),O=function(e,n,a){var o=t.useState(e.initial),r=o[0],u=o[1],i=t.useReducer(n,{value:"",navigationValue:null}),l=i[1];return[r,i[0],function(t,n){void 0===n&&(n={});var a=e.states[r],o=a&&a.on[t];if(o)return l(C({type:t,state:r,nextState:r},n)),void u(o)}]}(I,A),_=O[0],L=O[1],V=O[2];!function(e,t){l.useIsomorphicLayoutEffect((function(){"NAVIGATE"!==e&&"ESCAPE"!==e&&"SELECT_WITH_CLICK"!==e&&"OPEN_WITH_BUTTON"!==e||t.current.focus()}),[t,e])}(L.lastEventType,G);var w=E.useId(f.id),U=w?l.makeId("listbox",w):"listbox",H={autocompletePropRef:g,buttonRef:R,data:L,inputRef:G,isVisible:b(_),listboxId:U,onSelect:o||l.noop,openOnFocus:u,persistSelectionRef:m,popoverRef:x,state:_,transition:V};return t.useEffect((function(){return l.checkStyles("combobox")}),[]),n.createElement(c.DescendantProvider,{context:h,items:p,set:N},n.createElement(S.Provider,{value:H},n.createElement(v,Object.assign({"aria-haspopup":"listbox","aria-owns":U,"aria-expanded":H.isVisible},f,{"data-reach-combobox":"",ref:a,role:"combobox"}),i)))})),g=l.forwardRefWithAs((function(e,a){var o=e.as,r=void 0===o?"input":o,u=e.selectOnClick,i=void 0!==u&&u,c=e.autocomplete,s=void 0===c||c,v=e.onClick,E=e.onChange,f=e.onKeyDown,d=e.onBlur,C=e.onFocus,p=e.value,I=T(e,["as","selectOnClick","autocomplete","onClick","onChange","onKeyDown","onBlur","onFocus","value"]),A=t.useRef(p).current,N=t.useRef(!1);l.useUpdateEffect((function(){N.current=!0}),[p]);var b=t.useContext(S),G=b.data,h=G.navigationValue,x=G.value,R=G.lastEventType,g=b.inputRef,m=b.state,O=b.transition,_=b.listboxId,L=b.autocompletePropRef,V=b.openOnFocus,k=l.useForkedRef(g,a),y=t.useRef(!1),B=w(),W=U(),D=null!=p;l.useIsomorphicLayoutEffect((function(){L.current=s}),[s,L]);var F=function(e){""===e.trim()?O("CLEAR"):O(e!==A||N.current?"CHANGE":"INITIAL_CHANGE",{value:e})};D&&p!==x&&F(p);var K=!s||"NAVIGATING"!==m&&"INTERACTING"!==m?p||x:h||p||x;return n.createElement(r,Object.assign({"aria-activedescendant":h?String(H(h)):void 0,"aria-autocomplete":"both","aria-controls":_},I,{"data-reach-combobox-input":"",ref:k,onBlur:l.wrapEvent(d,W),onChange:l.wrapEvent(E,(function(e){D||F(e.target.value)})),onClick:l.wrapEvent(v,(function(){y.current&&(y.current=!1,g.current.select())})),onFocus:l.wrapEvent(C,(function(){i&&(y.current=!0),V&&"SELECT_WITH_CLICK"!==R&&O("FOCUS")})),onKeyDown:l.wrapEvent(f,B),value:K||""}))})),m=t.forwardRef((function(e,a){var o=e.children,r=e.portal,u=void 0===r||r,i=e.onKeyDown,c=e.onBlur,s=T(e,["children","portal","onKeyDown","onBlur"]),v=t.useContext(S),E=v.inputRef,C=v.isVisible,p=l.useForkedRef(v.popoverRef,a),I=w(),A=U(),N={"data-reach-combobox-popover":"",onKeyDown:l.wrapEvent(i,I),onBlur:l.wrapEvent(c,A),hidden:!C,tabIndex:-1,children:o};return u?n.createElement(d,Object.assign({},s,{ref:p,position:f.positionMatchWidth,targetRef:E},N)):n.createElement("div",Object.assign({ref:p},s,N))})),O=l.forwardRefWithAs((function(e,a){var o=e.persistSelection,r=void 0!==o&&o,u=e.as,i=void 0===u?"ul":u,l=T(e,["persistSelection","as"]),c=t.useContext(S),s=c.listboxId;return r&&(c.persistSelectionRef.current=!0),n.createElement(i,Object.assign({},l,{ref:a,"data-reach-combobox-list":"",role:"listbox",id:s}))})),_=t.forwardRef((function(e,a){var o=e.children,r=e.value,u=e.onClick,i=T(e,["children","value","onClick"]),s=t.useContext(S),v=s.onSelect,E=s.data.navigationValue,f=s.transition,d=t.useRef(null),C=l.useForkedRef(a,d),p=c.useDescendant({context:h,element:d.current,value:r}),I=E===r;return n.createElement(x.Provider,{value:{value:r,index:p}},n.createElement("li",Object.assign({"aria-selected":I},i,{"data-reach-combobox-option":"",ref:C,id:String(H(r)),role:"option","data-highlighted":I?"":void 0,tabIndex:-1,onClick:l.wrapEvent(u,(function(){f("SELECT_WITH_CLICK",{value:r,callback:v})})),children:o||n.createElement(L,null)})))}));function L(){var e=t.useContext(x).value,a=t.useContext(S).data.value,o=t.useMemo((function(){return s.findAll({searchWords:v(a||"").split(/\s+/),textToHighlight:e})}),[a,e]);return n.createElement(n.Fragment,null,o.length?o.map((function(t,a){var o=e.slice(t.start,t.end);return n.createElement("span",{key:a,"data-user-value":!!t.highlight||void 0,"data-suggested-value":!t.highlight||void 0},o)})):e)}var V=l.forwardRefWithAs((function(e,a){var o=e.as,r=void 0===o?"button":o,u=e.onClick,i=e.onKeyDown,c=T(e,["as","onClick","onKeyDown"]),s=t.useContext(S),v=s.transition,E=s.state,f=s.listboxId,d=s.isVisible,C=l.useForkedRef(s.buttonRef,a),I=w();return n.createElement(r,Object.assign({"aria-controls":f,"aria-haspopup":"listbox","aria-expanded":d},c,{"data-reach-combobox-button":"",ref:C,onClick:l.wrapEvent(u,(function(){v(E===p?"OPEN_WITH_BUTTON":"CLOSE_WITH_BUTTON")})),onKeyDown:l.wrapEvent(i,I)}))}));function w(){var e=t.useContext(S),n=e.data.navigationValue,a=e.onSelect,o=e.state,r=e.transition,u=e.autocompletePropRef,i=e.persistSelectionRef,l=t.useContext(h).descendants;return function(e){switch(e.key){case"ArrowDown":if(e.preventDefault(),!l||0===l.length)return;if(o===p)r("NAVIGATE",{persistSelection:i.current});else{var t=l.findIndex((function(e){return e.value===n}));r("NAVIGATE",t===l.length-1?u.current?{value:null}:{value:l[0].value}:{value:l[(t+1)%l.length].value})}break;case"ArrowUp":if(e.preventDefault(),!l||0===l.length)return;if(o===p)r("NAVIGATE");else{var c=l.findIndex((function(e){return e.value===n}));r("NAVIGATE",0===c?u.current?{value:null}:{value:l[l.length-1].value}:-1===c?{value:l.length?l[l.length-1].value:null}:{value:l[(c-1+l.length)%l.length].value})}break;case"Escape":o!==p&&r("ESCAPE");break;case"Enter":"NAVIGATING"===o&&null!==n&&(e.preventDefault(),r("SELECT_WITH_KEYBOARD",{callback:a}))}}}function U(){var e=t.useContext(S),n=e.state,a=e.transition,o=e.popoverRef,r=e.inputRef,u=e.buttonRef;return function(){var e=l.getOwnerDocument(r.current)||document;requestAnimationFrame((function(){e.activeElement!==r.current&&e.activeElement!==u.current&&o.current&&(o.current.contains(e.activeElement)?"INTERACTING"!==n&&a("INTERACT"):a("BLUR"))}))}}var H=function(e){var t=0;if(0===e.length)return t;for(var n=0;n<e.length;n++)t=(t<<5)-t+e.charCodeAt(n),t&=t;return t};exports.Combobox=R,exports.ComboboxButton=V,exports.ComboboxInput=g,exports.ComboboxList=O,exports.ComboboxOption=_,exports.ComboboxOptionText=L,exports.ComboboxPopover=m;
//# sourceMappingURL=combobox.cjs.production.min.js.map

@@ -894,3 +894,2 @@ import React, { useRef, useEffect, useContext, forwardRef, useMemo, useState, useReducer } from 'react';

console.log(event);
var currentState = chart.states[state];

@@ -897,0 +896,0 @@ var nextState = currentState && currentState.on[event];

{
"name": "@reach/combobox",
"version": "0.8.3",
"version": "0.8.4",
"description": "Accessible React Combobox (Autocomplete).",

@@ -19,6 +19,6 @@ "author": "React Training <hello@reacttraining.com>",

"@reach/auto-id": "^0.8.2",
"@reach/descendants": "^0.8.3",
"@reach/popover": "^0.8.3",
"@reach/descendants": "^0.8.4",
"@reach/popover": "^0.8.4",
"@reach/portal": "^0.8.2",
"@reach/utils": "^0.8.3",
"@reach/utils": "^0.8.4",
"escape-regexp": "0.0.1",

@@ -41,3 +41,3 @@ "highlight-words-core": "1.2.2",

],
"gitHead": "5bf1ce48db867c6b3c88e19f1614a6a725e829a0"
"gitHead": "81f50310879a4d99f3eaeba3cd95a66303e0186c"
}

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc