fix: address input (#8352)

pull/8385/head
Nafees Nazik 2023-04-19 18:32:26 +05:30 committed by GitHub
parent ea0b59d7c0
commit 88cf535c8e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 7 additions and 5 deletions

View File

@ -1,4 +1,6 @@
import { Input } from "../components/form/inputs/Input";
import cx from "@calcom/lib/classNames";
import { Input } from "../components/form";
import { MapPin } from "../components/icon";
export type AddressInputProps = {
@ -10,17 +12,17 @@ export type AddressInputProps = {
className?: string;
};
function AddressInput({ className = "", value, onChange, ...rest }: AddressInputProps) {
function AddressInput({ value, onChange, ...rest }: AddressInputProps) {
return (
<div className="relative ">
<MapPin className="text-emphasis absolute top-1/2 left-0.5 ml-3 h-4 -translate-y-1/2" />
<div className="relative flex items-center">
<MapPin className="text-muted absolute left-0.5 ml-3 h-4 w-4 -translate-y-1/2" style={{ top: "44%" }} />
<Input
{...rest}
value={value}
onChange={(e) => {
onChange(e.target.value);
}}
className={`${className} py-px pl-10`}
className={cx("pl-10", rest?.className)}
/>
</div>
);