@metamask/snaps-sdk
Version:
A library containing the core functionality for building MetaMask Snaps
21 lines • 980 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.AddressInput = void 0;
const component_1 = require("../../component.cjs");
const TYPE = 'AddressInput';
/**
* An input component for entering an address. Resolves the address to a display name and avatar.
*
* @param props - The props of the component.
* @param props.name - The name of the input field.
* @param props.value - The value of the input field.
* @param props.chainId - The CAIP-2 chain ID of the address.
* @param props.placeholder - The placeholder text of the input field.
* @param props.disabled - Whether the input field is disabled.
* @param props.displayAvatar - Whether to display the avatar of the address.
* @returns An input element.
* @example
* <AddressInput name="address" value="0x1234567890123456789012345678901234567890" chainId="eip155:1" />
*/
exports.AddressInput = (0, component_1.createSnapComponent)(TYPE);
//# sourceMappingURL=AddressInput.cjs.map