let { disabled, iconLeft, iconRight, inputNodeLeft, inputNodeRight, invalid, label, search, select, textarea, valid, value, ...forwardedProps } = props; const hasNoValue = !value; const Wrapper = styled.label` display: flex; flex-direction: column; align-items: flex-start; justify-content: flex-start; padding: 0px; gap: 0.45em; width: 100%; `; const Label = styled.span` font-style: normal; font-weight: 600; font-size: 0.95em; line-height: 1.25em; color: #344054; margin-top: 3%; `; const Input = styled.input` box-sizing: border-box; display: flex; flex-direction: row; align-items: center; padding: 0.5em 0.75em; width: 100%; gap: 0.5em; background: #ffffff; border: 1px solid #d0d5dd; box-shadow: 0px 1px 2px rgba(16, 24, 40, 0.05); border-radius: 4px; margin-top: 3px; `; return ( <Wrapper data-invalid={invalid} data-valid={valid} data-disabled={disabled} data-textarea={textarea} data-search={search} data-select={select} data-no-value={hasNoValue} > {label && <Label>{label}</Label>} <Input as="textarea" disabled={disabled} aria-invalid={invalid === true} ref="forwardedRef" value={value} {...forwardedProps} /> </Wrapper> );