Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 18 additions & 15 deletions packages/ui/src/FormWidgets/Typeahead/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -182,23 +182,26 @@ export const Typeahead = <T extends Suggestion>({
};

return (
<div className={`dz-typeahead ${className}`.trimEnd()}>
<div className={`field ${className}`.trimEnd()}>
{label && <label htmlFor={name}>{label}</label>}
<div
className={`input-field-typeahead ${disabled ? "disabled" : ""}`}
aria-invalid={hasError}
>
<DebouncedInput
type={type}
defaultValue={inputValue}
debounceTime={debounceTime}
onInputChange={handleInputChange}
placeholder={placeholder}
disabled={disabled}
/>
{loading && <LoadingIcon color="#ccc" />}
<div className="dz-typeahead ">
<div
className={`input-field-typeahead ${disabled ? "disabled" : ""}`}
aria-invalid={hasError}
>
<DebouncedInput
name={name}
type={type}
defaultValue={inputValue}
debounceTime={debounceTime}
onInputChange={handleInputChange}
placeholder={placeholder}
disabled={disabled}
/>
{loading && <LoadingIcon color="#ccc" />}
</div>
{renderSuggestions()}
</div>
{renderSuggestions()}
{helperText && <span className="helper-text">{helperText}</span>}
{errorMessage && <span className="error-message">{errorMessage}</span>}
</div>
Expand Down