UNPKG

@metamask/snaps-sdk

Version:

A library containing the core functionality for building MetaMask Snaps

23 lines 942 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.Image = void 0; const component_1 = require("../component.cjs"); const TYPE = 'Image'; /** * An image component, which is used to display an image. * * This component does not accept any children. * * @param props - The props of the component. * @param props.src - The URL of the image to display. This should be an SVG * string, and other formats such as PNG and JPEG are not supported directly. * You can use the `data:` URL scheme to embed images inside the SVG. * @param props.alt - The alternative text of the image, which describes the * image for users who cannot see it. * @param props.borderRadius - The border radius applied to the image. * @returns An image element. * @example * <Image src="<svg>...</svg>" alt="An example image" /> */ exports.Image = (0, component_1.createSnapComponent)(TYPE); //# sourceMappingURL=Image.cjs.map