UNPKG

@dnb/eufemia

Version:

DNB Eufemia Design System UI Library

30 lines (29 loc) 1.46 kB
import { Props as FieldBlockProps } from '../../FieldBlock'; import { Props as StringFieldProps } from '../String'; import { CountryCode, Path } from '../../types'; import { HelpProps } from '../../../../components/help-button/HelpButtonInline'; export type Props = Pick<FieldBlockProps, 'error' | 'warning' | 'info' | 'width' | 'className'> & Partial<Record<'postalCode' | 'city', StringFieldProps>> & { /** * Defines which country the postal code and city is for. * Setting it to anything other than `no` will remove the default norwegian postal code pattern. * You can also use the value of another field to define the country, by using a path value i.e. `/myCountryPath`. * Default: `NO` */ /** * @deprecated – use countryCode instead. Will be removed in v11. */ country?: Path | string; /** * Defines which country the postal code and city is for. * Setting it to anything other than `no` will remove the default norwegian postal code pattern. * You can also use the value of another field to define the countryCode, by using a path value i.e. `/myCountryCodePath`. * Default: `NO` */ countryCode?: CountryCode; help?: HelpProps; } & Pick<StringFieldProps, 'size'>; declare function PostalCodeAndCity(props: Props): import("react/jsx-runtime").JSX.Element; declare namespace PostalCodeAndCity { var _supportsSpacingProps: boolean; } export default PostalCodeAndCity;