{
  "version": 3,
  "sources": ["../../../src/hooks/use-debounced-input/index.ts"],
  "sourcesContent": ["/**\n * WordPress dependencies\n */\nimport { useEffect, useState } from '@wordpress/element';\n\n/**\n * Internal dependencies\n */\nimport useDebounce from '../use-debounce';\n\n/**\n * Helper hook for input fields that need to debounce the value before using it.\n *\n * @param defaultValue The default value to use.\n * @return The input value, the setter and the debounced input value.\n */\nexport default function useDebouncedInput(\n\tdefaultValue = ''\n): [ string, ( value: string ) => void, string ] {\n\tconst [ input, setInput ] = useState< string >( defaultValue );\n\tconst [ debouncedInput, setDebouncedState ] = useState( defaultValue );\n\n\tconst setDebouncedInput = useDebounce( setDebouncedState, 250 );\n\n\tuseEffect( () => {\n\t\tsetDebouncedInput( input );\n\t}, [ input, setDebouncedInput ] );\n\n\treturn [ input, setInput, debouncedInput ];\n}\n"],
  "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAGA,qBAAoC;AAKpC,0BAAwB;AAQT,SAAR,kBACN,eAAe,IACiC;AAChD,QAAM,CAAE,OAAO,QAAS,QAAI,yBAAoB,YAAa;AAC7D,QAAM,CAAE,gBAAgB,iBAAkB,QAAI,yBAAU,YAAa;AAErE,QAAM,wBAAoB,oBAAAA,SAAa,mBAAmB,GAAI;AAE9D,gCAAW,MAAM;AAChB,sBAAmB,KAAM;AAAA,EAC1B,GAAG,CAAE,OAAO,iBAAkB,CAAE;AAEhC,SAAO,CAAE,OAAO,UAAU,cAAe;AAC1C;",
  "names": ["useDebounce"]
}
