UNPKG

@metamask/snaps-sdk

Version:

A library containing the core functionality for building MetaMask Snaps

15 lines 775 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.FormStruct = exports.FormComponentStruct = void 0; const superstruct_1 = require("@metamask/superstruct"); const button_1 = require("./button.cjs"); const input_1 = require("./input.cjs"); const internals_1 = require("../../internals/index.cjs"); const nodes_1 = require("../nodes.cjs"); exports.FormComponentStruct = (0, superstruct_1.union)([input_1.InputStruct, button_1.ButtonStruct]); exports.FormStruct = (0, superstruct_1.assign)(nodes_1.NodeStruct, (0, superstruct_1.object)({ type: (0, internals_1.literal)(nodes_1.NodeType.Form), children: (0, superstruct_1.array)(exports.FormComponentStruct), name: (0, superstruct_1.string)(), })); //# sourceMappingURL=form.cjs.map