@metamask/snaps-sdk 6.3.0 → 6.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +20 -1
- package/dist/error-wrappers.cjs +146 -0
- package/dist/error-wrappers.cjs.map +1 -0
- package/dist/error-wrappers.d.cts +830 -0
- package/dist/error-wrappers.d.cts.map +1 -0
- package/dist/{types/error-wrappers.d.ts → error-wrappers.d.mts} +193 -192
- package/dist/error-wrappers.d.mts.map +1 -0
- package/dist/error-wrappers.mjs +143 -0
- package/dist/error-wrappers.mjs.map +1 -0
- package/dist/errors.cjs +124 -0
- package/dist/errors.cjs.map +1 -0
- package/dist/{types/errors.d.ts → errors.d.cts} +3 -2
- package/dist/errors.d.cts.map +1 -0
- package/dist/errors.d.mts +87 -0
- package/dist/errors.d.mts.map +1 -0
- package/dist/errors.mjs +120 -0
- package/dist/errors.mjs.map +1 -0
- package/dist/images.cjs +91 -0
- package/dist/images.cjs.map +1 -0
- package/dist/{types/images.d.ts → images.d.cts} +2 -1
- package/dist/images.d.cts.map +1 -0
- package/dist/images.d.mts +70 -0
- package/dist/images.d.mts.map +1 -0
- package/dist/images.mjs +86 -0
- package/dist/images.mjs.map +1 -0
- package/dist/index.cjs +36 -0
- package/dist/index.cjs.map +1 -0
- package/dist/index.d.cts +10 -0
- package/dist/index.d.cts.map +1 -0
- package/dist/index.d.mts +10 -0
- package/dist/index.d.mts.map +1 -0
- package/dist/index.mjs +7 -1429
- package/dist/index.mjs.map +1 -1
- package/dist/internals/error-wrappers.cjs +44 -0
- package/dist/internals/error-wrappers.cjs.map +1 -0
- package/dist/internals/error-wrappers.d.cts +60 -0
- package/dist/internals/error-wrappers.d.cts.map +1 -0
- package/dist/{types/internals/error-wrappers.d.ts → internals/error-wrappers.d.mts} +15 -14
- package/dist/internals/error-wrappers.d.mts.map +1 -0
- package/dist/internals/error-wrappers.mjs +40 -0
- package/dist/internals/error-wrappers.mjs.map +1 -0
- package/dist/internals/errors.cjs +80 -0
- package/dist/internals/errors.cjs.map +1 -0
- package/dist/{types/internals/errors.d.ts → internals/errors.d.cts} +1 -0
- package/dist/internals/errors.d.cts.map +1 -0
- package/dist/internals/errors.d.mts +42 -0
- package/dist/internals/errors.d.mts.map +1 -0
- package/dist/internals/errors.mjs +73 -0
- package/dist/internals/errors.mjs.map +1 -0
- package/dist/internals/helpers.cjs +3 -0
- package/dist/internals/helpers.cjs.map +1 -0
- package/dist/{types/internals/helpers.d.ts → internals/helpers.d.cts} +2 -1
- package/dist/internals/helpers.d.cts.map +1 -0
- package/dist/internals/helpers.d.mts +37 -0
- package/dist/internals/helpers.d.mts.map +1 -0
- package/dist/internals/helpers.mjs +2 -0
- package/dist/internals/helpers.mjs.map +1 -0
- package/dist/internals/index.cjs +23 -0
- package/dist/internals/index.cjs.map +1 -0
- package/dist/internals/index.d.cts +7 -0
- package/dist/internals/index.d.cts.map +1 -0
- package/dist/internals/index.d.mts +7 -0
- package/dist/internals/index.d.mts.map +1 -0
- package/dist/internals/index.mjs +7 -0
- package/dist/internals/index.mjs.map +1 -0
- package/dist/internals/jsx.cjs +17 -0
- package/dist/internals/jsx.cjs.map +1 -0
- package/dist/{types/internals/jsx.d.ts → internals/jsx.d.cts} +3 -2
- package/dist/internals/jsx.d.cts.map +1 -0
- package/dist/internals/jsx.d.mts +31 -0
- package/dist/internals/jsx.d.mts.map +1 -0
- package/dist/internals/jsx.mjs +13 -0
- package/dist/internals/jsx.mjs.map +1 -0
- package/dist/internals/structs.cjs +161 -0
- package/dist/internals/structs.cjs.map +1 -0
- package/dist/{types/internals/structs.d.ts → internals/structs.d.cts} +13 -3
- package/dist/internals/structs.d.cts.map +1 -0
- package/dist/internals/structs.d.mts +69 -0
- package/dist/internals/structs.d.mts.map +1 -0
- package/dist/internals/structs.mjs +153 -0
- package/dist/internals/structs.mjs.map +1 -0
- package/dist/internals/svg.cjs +23 -0
- package/dist/internals/svg.cjs.map +1 -0
- package/dist/{types/internals/svg.d.ts → internals/svg.d.cts} +1 -0
- package/dist/internals/svg.d.cts.map +1 -0
- package/dist/internals/svg.d.mts +8 -0
- package/dist/internals/svg.d.mts.map +1 -0
- package/dist/internals/svg.mjs +19 -0
- package/dist/internals/svg.mjs.map +1 -0
- package/dist/jsx/component.cjs +32 -0
- package/dist/jsx/component.cjs.map +1 -0
- package/dist/{types/jsx/component.d.ts → jsx/component.d.cts} +2 -1
- package/dist/jsx/component.d.cts.map +1 -0
- package/dist/jsx/component.d.mts +74 -0
- package/dist/jsx/component.d.mts.map +1 -0
- package/dist/jsx/component.mjs +28 -0
- package/dist/jsx/component.mjs.map +1 -0
- package/dist/jsx/components/Address.cjs +23 -0
- package/dist/jsx/components/Address.cjs.map +1 -0
- package/dist/jsx/components/Address.d.cts +34 -0
- package/dist/jsx/components/Address.d.cts.map +1 -0
- package/dist/jsx/components/Address.d.mts +34 -0
- package/dist/jsx/components/Address.d.mts.map +1 -0
- package/dist/jsx/components/Address.mjs +20 -0
- package/dist/jsx/components/Address.mjs.map +1 -0
- package/dist/jsx/components/Box.cjs +18 -0
- package/dist/jsx/components/Box.cjs.map +1 -0
- package/dist/{types/jsx/components/Box.d.ts → jsx/components/Box.d.cts} +2 -1
- package/dist/jsx/components/Box.d.cts.map +1 -0
- package/dist/jsx/components/Box.d.mts +32 -0
- package/dist/jsx/components/Box.d.mts.map +1 -0
- package/dist/jsx/components/Box.mjs +15 -0
- package/dist/jsx/components/Box.mjs.map +1 -0
- package/dist/jsx/components/Card.cjs +20 -0
- package/dist/jsx/components/Card.cjs.map +1 -0
- package/dist/{types/jsx/components/Card.d.ts → jsx/components/Card.d.cts} +1 -0
- package/dist/jsx/components/Card.d.cts.map +1 -0
- package/dist/jsx/components/Card.d.mts +37 -0
- package/dist/jsx/components/Card.d.mts.map +1 -0
- package/dist/jsx/components/Card.mjs +17 -0
- package/dist/jsx/components/Card.mjs.map +1 -0
- package/dist/jsx/components/Container.cjs +24 -0
- package/dist/jsx/components/Container.cjs.map +1 -0
- package/dist/{types/jsx/components/Container.d.ts → jsx/components/Container.d.cts} +4 -3
- package/dist/jsx/components/Container.d.cts.map +1 -0
- package/dist/jsx/components/Container.d.mts +35 -0
- package/dist/jsx/components/Container.d.mts.map +1 -0
- package/dist/jsx/components/Container.mjs +21 -0
- package/dist/jsx/components/Container.mjs.map +1 -0
- package/dist/jsx/components/Copyable.cjs +20 -0
- package/dist/jsx/components/Copyable.cjs.map +1 -0
- package/dist/{types/jsx/components/Copyable.d.ts → jsx/components/Copyable.d.cts} +1 -0
- package/dist/jsx/components/Copyable.d.cts.map +1 -0
- package/dist/jsx/components/Copyable.d.mts +33 -0
- package/dist/jsx/components/Copyable.d.mts.map +1 -0
- package/dist/jsx/components/Copyable.mjs +17 -0
- package/dist/jsx/components/Copyable.mjs.map +1 -0
- package/dist/jsx/components/Divider.cjs +17 -0
- package/dist/jsx/components/Divider.cjs.map +1 -0
- package/dist/{types/jsx/components/Divider.d.ts → jsx/components/Divider.d.cts} +1 -0
- package/dist/jsx/components/Divider.d.cts.map +1 -0
- package/dist/jsx/components/Divider.d.mts +18 -0
- package/dist/jsx/components/Divider.d.mts.map +1 -0
- package/dist/jsx/components/Divider.mjs +14 -0
- package/dist/jsx/components/Divider.mjs.map +1 -0
- package/dist/jsx/components/Footer.cjs +19 -0
- package/dist/jsx/components/Footer.cjs.map +1 -0
- package/dist/{types/jsx/components/Footer.d.ts → jsx/components/Footer.d.cts} +2 -1
- package/dist/jsx/components/Footer.d.cts.map +1 -0
- package/dist/jsx/components/Footer.d.mts +29 -0
- package/dist/jsx/components/Footer.d.mts.map +1 -0
- package/dist/jsx/components/Footer.mjs +16 -0
- package/dist/jsx/components/Footer.mjs.map +1 -0
- package/dist/jsx/components/Heading.cjs +16 -0
- package/dist/jsx/components/Heading.cjs.map +1 -0
- package/dist/{types/jsx/components/Heading.d.ts → jsx/components/Heading.d.cts} +2 -1
- package/dist/jsx/components/Heading.d.cts.map +1 -0
- package/dist/jsx/components/Heading.d.mts +27 -0
- package/dist/jsx/components/Heading.d.mts.map +1 -0
- package/dist/jsx/components/Heading.mjs +13 -0
- package/dist/jsx/components/Heading.mjs.map +1 -0
- package/dist/jsx/components/Icon.cjs +180 -0
- package/dist/jsx/components/Icon.cjs.map +1 -0
- package/dist/{types/jsx/components/Icon.d.ts → jsx/components/Icon.d.cts} +1 -0
- package/dist/jsx/components/Icon.d.cts.map +1 -0
- package/dist/jsx/components/Icon.d.mts +190 -0
- package/dist/jsx/components/Icon.d.mts.map +1 -0
- package/dist/jsx/components/Icon.mjs +177 -0
- package/dist/jsx/components/Icon.mjs.map +1 -0
- package/dist/jsx/components/Image.cjs +22 -0
- package/dist/jsx/components/Image.cjs.map +1 -0
- package/dist/{types/jsx/components/Image.d.ts → jsx/components/Image.d.cts} +1 -0
- package/dist/jsx/components/Image.d.cts.map +1 -0
- package/dist/jsx/components/Image.d.mts +37 -0
- package/dist/jsx/components/Image.d.mts.map +1 -0
- package/dist/jsx/components/Image.mjs +19 -0
- package/dist/jsx/components/Image.mjs.map +1 -0
- package/dist/jsx/components/Link.cjs +18 -0
- package/dist/jsx/components/Link.cjs.map +1 -0
- package/dist/{types/jsx/components/Link.d.ts → jsx/components/Link.d.cts} +3 -2
- package/dist/jsx/components/Link.d.cts.map +1 -0
- package/dist/jsx/components/Link.d.mts +36 -0
- package/dist/jsx/components/Link.d.mts.map +1 -0
- package/dist/jsx/components/Link.mjs +15 -0
- package/dist/jsx/components/Link.mjs.map +1 -0
- package/dist/jsx/components/Row.cjs +22 -0
- package/dist/jsx/components/Row.cjs.map +1 -0
- package/dist/{types/jsx/components/Row.d.ts → jsx/components/Row.d.cts} +5 -4
- package/dist/jsx/components/Row.d.cts.map +1 -0
- package/dist/jsx/components/Row.d.mts +46 -0
- package/dist/jsx/components/Row.d.mts.map +1 -0
- package/dist/jsx/components/Row.mjs +19 -0
- package/dist/jsx/components/Row.mjs.map +1 -0
- package/dist/jsx/components/Section.cjs +26 -0
- package/dist/jsx/components/Section.cjs.map +1 -0
- package/dist/jsx/components/Section.d.cts +38 -0
- package/dist/jsx/components/Section.d.cts.map +1 -0
- package/dist/jsx/components/Section.d.mts +38 -0
- package/dist/jsx/components/Section.d.mts.map +1 -0
- package/dist/jsx/components/Section.mjs +23 -0
- package/dist/jsx/components/Section.mjs.map +1 -0
- package/dist/jsx/components/Spinner.cjs +17 -0
- package/dist/jsx/components/Spinner.cjs.map +1 -0
- package/dist/{types/jsx/components/Spinner.d.ts → jsx/components/Spinner.d.cts} +1 -0
- package/dist/jsx/components/Spinner.d.cts.map +1 -0
- package/dist/jsx/components/Spinner.d.mts +18 -0
- package/dist/jsx/components/Spinner.d.mts.map +1 -0
- package/dist/jsx/components/Spinner.mjs +14 -0
- package/dist/jsx/components/Spinner.mjs.map +1 -0
- package/dist/jsx/components/Text.cjs +22 -0
- package/dist/jsx/components/Text.cjs.map +1 -0
- package/dist/{types/jsx/components/Text.d.ts → jsx/components/Text.d.cts} +5 -4
- package/dist/jsx/components/Text.d.cts.map +1 -0
- package/dist/jsx/components/Text.d.mts +45 -0
- package/dist/jsx/components/Text.d.mts.map +1 -0
- package/dist/jsx/components/Text.mjs +19 -0
- package/dist/jsx/components/Text.mjs.map +1 -0
- package/dist/jsx/components/Tooltip.cjs +23 -0
- package/dist/jsx/components/Tooltip.cjs.map +1 -0
- package/dist/{types/jsx/components/Tooltip.d.ts → jsx/components/Tooltip.d.cts} +6 -5
- package/dist/jsx/components/Tooltip.d.cts.map +1 -0
- package/dist/jsx/components/Tooltip.d.mts +40 -0
- package/dist/jsx/components/Tooltip.d.mts.map +1 -0
- package/dist/jsx/components/Tooltip.mjs +20 -0
- package/dist/jsx/components/Tooltip.mjs.map +1 -0
- package/dist/jsx/components/Value.cjs +21 -0
- package/dist/jsx/components/Value.cjs.map +1 -0
- package/dist/{types/jsx/components/Value.d.ts → jsx/components/Value.d.cts} +1 -0
- package/dist/jsx/components/Value.d.cts.map +1 -0
- package/dist/jsx/components/Value.d.mts +32 -0
- package/dist/jsx/components/Value.d.mts.map +1 -0
- package/dist/jsx/components/Value.mjs +18 -0
- package/dist/jsx/components/Value.mjs.map +1 -0
- package/dist/jsx/components/form/Button.cjs +17 -0
- package/dist/jsx/components/form/Button.cjs.map +1 -0
- package/dist/{types/jsx/components/form/Button.d.ts → jsx/components/form/Button.d.cts} +4 -3
- package/dist/jsx/components/form/Button.d.cts.map +1 -0
- package/dist/jsx/components/form/Button.d.mts +40 -0
- package/dist/jsx/components/form/Button.d.mts.map +1 -0
- package/dist/jsx/components/form/Button.mjs +14 -0
- package/dist/jsx/components/form/Button.mjs.map +1 -0
- package/dist/jsx/components/form/Checkbox.cjs +20 -0
- package/dist/jsx/components/form/Checkbox.cjs.map +1 -0
- package/dist/{types/jsx/components/form/Checkbox.d.ts → jsx/components/form/Checkbox.d.cts} +1 -0
- package/dist/jsx/components/form/Checkbox.d.cts.map +1 -0
- package/dist/jsx/components/form/Checkbox.d.mts +36 -0
- package/dist/jsx/components/form/Checkbox.d.mts.map +1 -0
- package/dist/jsx/components/form/Checkbox.mjs +17 -0
- package/dist/jsx/components/form/Checkbox.mjs.map +1 -0
- package/dist/jsx/components/form/Dropdown.cjs +23 -0
- package/dist/jsx/components/form/Dropdown.cjs.map +1 -0
- package/dist/{types/jsx/components/form/Dropdown.d.ts → jsx/components/form/Dropdown.d.cts} +3 -2
- package/dist/jsx/components/form/Dropdown.d.cts.map +1 -0
- package/dist/jsx/components/form/Dropdown.d.mts +39 -0
- package/dist/jsx/components/form/Dropdown.d.mts.map +1 -0
- package/dist/jsx/components/form/Dropdown.mjs +20 -0
- package/dist/jsx/components/form/Dropdown.mjs.map +1 -0
- package/dist/jsx/components/form/Field.cjs +26 -0
- package/dist/jsx/components/form/Field.cjs.map +1 -0
- package/dist/{types/jsx/components/form/Field.d.ts → jsx/components/form/Field.d.cts} +9 -8
- package/dist/jsx/components/form/Field.d.cts.map +1 -0
- package/dist/jsx/components/form/Field.d.mts +46 -0
- package/dist/jsx/components/form/Field.d.mts.map +1 -0
- package/dist/jsx/components/form/Field.mjs +23 -0
- package/dist/jsx/components/form/Field.mjs.map +1 -0
- package/dist/jsx/components/form/FileInput.cjs +31 -0
- package/dist/jsx/components/form/FileInput.cjs.map +1 -0
- package/dist/{types/jsx/components/form/FileInput.d.ts → jsx/components/form/FileInput.d.cts} +1 -0
- package/dist/jsx/components/form/FileInput.d.cts.map +1 -0
- package/dist/jsx/components/form/FileInput.d.mts +48 -0
- package/dist/jsx/components/form/FileInput.d.mts.map +1 -0
- package/dist/jsx/components/form/FileInput.mjs +28 -0
- package/dist/jsx/components/form/FileInput.mjs.map +1 -0
- package/dist/jsx/components/form/Form.cjs +24 -0
- package/dist/jsx/components/form/Form.cjs.map +1 -0
- package/dist/{types/jsx/components/form/Form.d.ts → jsx/components/form/Form.d.cts} +2 -1
- package/dist/jsx/components/form/Form.d.cts.map +1 -0
- package/dist/jsx/components/form/Form.d.mts +37 -0
- package/dist/jsx/components/form/Form.d.mts.map +1 -0
- package/dist/jsx/components/form/Form.mjs +21 -0
- package/dist/jsx/components/form/Form.mjs.map +1 -0
- package/dist/jsx/components/form/Input.cjs +20 -0
- package/dist/jsx/components/form/Input.cjs.map +1 -0
- package/dist/{types/jsx/components/form/Input.d.ts → jsx/components/form/Input.d.cts} +1 -0
- package/dist/jsx/components/form/Input.d.cts.map +1 -0
- package/dist/jsx/components/form/Input.d.mts +36 -0
- package/dist/jsx/components/form/Input.d.mts.map +1 -0
- package/dist/jsx/components/form/Input.mjs +17 -0
- package/dist/jsx/components/form/Input.mjs.map +1 -0
- package/dist/jsx/components/form/Option.cjs +25 -0
- package/dist/jsx/components/form/Option.cjs.map +1 -0
- package/dist/{types/jsx/components/form/Option.d.ts → jsx/components/form/Option.d.cts} +1 -0
- package/dist/jsx/components/form/Option.d.cts.map +1 -0
- package/dist/jsx/components/form/Option.d.mts +36 -0
- package/dist/jsx/components/form/Option.d.mts.map +1 -0
- package/dist/jsx/components/form/Option.mjs +22 -0
- package/dist/jsx/components/form/Option.mjs.map +1 -0
- package/dist/jsx/components/form/Radio.cjs +23 -0
- package/dist/jsx/components/form/Radio.cjs.map +1 -0
- package/dist/{types/jsx/components/form/Radio.d.ts → jsx/components/form/Radio.d.cts} +1 -0
- package/dist/jsx/components/form/Radio.d.cts.map +1 -0
- package/dist/jsx/components/form/Radio.d.mts +36 -0
- package/dist/jsx/components/form/Radio.d.mts.map +1 -0
- package/dist/jsx/components/form/Radio.mjs +20 -0
- package/dist/jsx/components/form/Radio.mjs.map +1 -0
- package/dist/jsx/components/form/RadioGroup.cjs +14 -0
- package/dist/jsx/components/form/RadioGroup.cjs.map +1 -0
- package/dist/{types/jsx/components/form/RadioGroup.d.ts → jsx/components/form/RadioGroup.d.cts} +3 -2
- package/dist/jsx/components/form/RadioGroup.d.cts.map +1 -0
- package/dist/jsx/components/form/RadioGroup.d.mts +30 -0
- package/dist/jsx/components/form/RadioGroup.d.mts.map +1 -0
- package/dist/jsx/components/form/RadioGroup.mjs +11 -0
- package/dist/jsx/components/form/RadioGroup.mjs.map +1 -0
- package/dist/jsx/components/form/Selector.cjs +24 -0
- package/dist/jsx/components/form/Selector.cjs.map +1 -0
- package/dist/{types/jsx/components/form/Selector.d.ts → jsx/components/form/Selector.d.cts} +3 -2
- package/dist/jsx/components/form/Selector.d.cts.map +1 -0
- package/dist/jsx/components/form/Selector.d.mts +42 -0
- package/dist/jsx/components/form/Selector.d.mts.map +1 -0
- package/dist/jsx/components/form/Selector.mjs +21 -0
- package/dist/jsx/components/form/Selector.mjs.map +1 -0
- package/dist/jsx/components/form/SelectorOption.cjs +23 -0
- package/dist/jsx/components/form/SelectorOption.cjs.map +1 -0
- package/dist/{types/jsx/components/form/SelectorOption.d.ts → jsx/components/form/SelectorOption.d.cts} +2 -1
- package/dist/jsx/components/form/SelectorOption.d.cts.map +1 -0
- package/dist/jsx/components/form/SelectorOption.d.mts +36 -0
- package/dist/jsx/components/form/SelectorOption.d.mts.map +1 -0
- package/dist/jsx/components/form/SelectorOption.mjs +20 -0
- package/dist/jsx/components/form/SelectorOption.mjs.map +1 -0
- package/dist/jsx/components/form/index.cjs +29 -0
- package/dist/jsx/components/form/index.cjs.map +1 -0
- package/dist/jsx/components/form/index.d.cts +26 -0
- package/dist/jsx/components/form/index.d.cts.map +1 -0
- package/dist/jsx/components/form/index.d.mts +26 -0
- package/dist/jsx/components/form/index.d.mts.map +1 -0
- package/dist/jsx/components/form/index.mjs +13 -0
- package/dist/jsx/components/form/index.mjs.map +1 -0
- package/dist/jsx/components/formatting/Bold.cjs +21 -0
- package/dist/jsx/components/formatting/Bold.cjs.map +1 -0
- package/dist/{types/jsx/components/formatting/Bold.d.ts → jsx/components/formatting/Bold.d.cts} +2 -1
- package/dist/jsx/components/formatting/Bold.d.cts.map +1 -0
- package/dist/jsx/components/formatting/Bold.d.mts +33 -0
- package/dist/jsx/components/formatting/Bold.d.mts.map +1 -0
- package/dist/jsx/components/formatting/Bold.mjs +18 -0
- package/dist/jsx/components/formatting/Bold.mjs.map +1 -0
- package/dist/jsx/components/formatting/Italic.cjs +20 -0
- package/dist/jsx/components/formatting/Italic.cjs.map +1 -0
- package/dist/{types/jsx/components/formatting/Italic.d.ts → jsx/components/formatting/Italic.d.cts} +2 -1
- package/dist/jsx/components/formatting/Italic.d.cts.map +1 -0
- package/dist/jsx/components/formatting/Italic.d.mts +35 -0
- package/dist/jsx/components/formatting/Italic.d.mts.map +1 -0
- package/dist/jsx/components/formatting/Italic.mjs +17 -0
- package/dist/jsx/components/formatting/Italic.mjs.map +1 -0
- package/dist/jsx/components/formatting/index.cjs +19 -0
- package/dist/jsx/components/formatting/index.cjs.map +1 -0
- package/dist/jsx/components/formatting/index.d.cts +6 -0
- package/dist/jsx/components/formatting/index.d.cts.map +1 -0
- package/dist/jsx/components/formatting/index.d.mts +6 -0
- package/dist/jsx/components/formatting/index.d.mts.map +1 -0
- package/dist/jsx/components/formatting/index.mjs +3 -0
- package/dist/jsx/components/formatting/index.mjs.map +1 -0
- package/dist/jsx/components/index.cjs +36 -0
- package/dist/jsx/components/index.cjs.map +1 -0
- package/dist/jsx/components/index.d.cts +43 -0
- package/dist/jsx/components/index.d.cts.map +1 -0
- package/dist/jsx/components/index.d.mts +43 -0
- package/dist/jsx/components/index.d.mts.map +1 -0
- package/dist/jsx/components/index.mjs +20 -0
- package/dist/jsx/components/index.mjs.map +1 -0
- package/dist/jsx/index.cjs +31 -0
- package/dist/jsx/index.cjs.map +1 -0
- package/dist/jsx/index.d.cts +6 -0
- package/dist/jsx/index.d.cts.map +1 -0
- package/dist/jsx/index.d.mts +6 -0
- package/dist/jsx/index.d.mts.map +1 -0
- package/dist/jsx/index.mjs +5 -809
- package/dist/jsx/index.mjs.map +1 -1
- package/dist/jsx/jsx-dev-runtime.cjs +27 -0
- package/dist/jsx/jsx-dev-runtime.cjs.map +1 -0
- package/dist/{types/jsx/jsx-dev-runtime.d.ts → jsx/jsx-dev-runtime.d.cts} +2 -1
- package/dist/jsx/jsx-dev-runtime.d.cts.map +1 -0
- package/dist/jsx/jsx-dev-runtime.d.mts +18 -0
- package/dist/jsx/jsx-dev-runtime.d.mts.map +1 -0
- package/dist/jsx/jsx-dev-runtime.mjs +21 -642
- package/dist/jsx/jsx-dev-runtime.mjs.map +1 -1
- package/dist/jsx/jsx-runtime.cjs +54 -0
- package/dist/jsx/jsx-runtime.cjs.map +1 -0
- package/dist/{types/jsx/jsx-runtime.d.ts → jsx/jsx-runtime.d.cts} +2 -1
- package/dist/jsx/jsx-runtime.d.cts.map +1 -0
- package/dist/jsx/jsx-runtime.d.mts +36 -0
- package/dist/jsx/jsx-runtime.d.mts.map +1 -0
- package/dist/jsx/jsx-runtime.mjs +46 -21
- package/dist/jsx/jsx-runtime.mjs.map +1 -1
- package/dist/jsx/validation.cjs +577 -0
- package/dist/jsx/validation.cjs.map +1 -0
- package/dist/{types/jsx/validation.d.ts → jsx/validation.d.cts} +22 -17
- package/dist/jsx/validation.d.cts.map +1 -0
- package/dist/jsx/validation.d.mts +247 -0
- package/dist/jsx/validation.d.mts.map +1 -0
- package/dist/jsx/validation.mjs +571 -0
- package/dist/jsx/validation.mjs.map +1 -0
- package/dist/types/caip.cjs +3 -0
- package/dist/types/caip.cjs.map +1 -0
- package/dist/types/{types/caip.d.ts → caip.d.cts} +1 -0
- package/dist/types/caip.d.cts.map +1 -0
- package/dist/types/caip.d.mts +13 -0
- package/dist/types/caip.d.mts.map +1 -0
- package/dist/types/caip.mjs +2 -0
- package/dist/types/caip.mjs.map +1 -0
- package/dist/types/global.cjs +3 -0
- package/dist/types/global.cjs.map +1 -0
- package/dist/types/{types/global.d.ts → global.d.cts} +2 -1
- package/dist/types/global.d.cts.map +1 -0
- package/dist/types/global.d.mts +9 -0
- package/dist/types/global.d.mts.map +1 -0
- package/dist/types/global.mjs +2 -0
- package/dist/types/global.mjs.map +1 -0
- package/dist/types/handlers/cronjob.cjs +3 -0
- package/dist/types/handlers/cronjob.cjs.map +1 -0
- package/dist/types/{types/handlers/cronjob.d.ts → handlers/cronjob.d.cts} +2 -1
- package/dist/types/handlers/cronjob.d.cts.map +1 -0
- package/dist/types/handlers/cronjob.d.mts +15 -0
- package/dist/types/handlers/cronjob.d.mts.map +1 -0
- package/dist/types/handlers/cronjob.mjs +2 -0
- package/dist/types/handlers/cronjob.mjs.map +1 -0
- package/dist/types/handlers/home-page.cjs +3 -0
- package/dist/types/handlers/home-page.cjs.map +1 -0
- package/dist/types/{types/handlers/home-page.d.ts → handlers/home-page.d.cts} +2 -1
- package/dist/types/handlers/home-page.d.cts.map +1 -0
- package/dist/types/handlers/home-page.d.mts +23 -0
- package/dist/types/handlers/home-page.d.mts.map +1 -0
- package/dist/types/handlers/home-page.mjs +2 -0
- package/dist/types/handlers/home-page.mjs.map +1 -0
- package/dist/types/handlers/index.cjs +26 -0
- package/dist/types/handlers/index.cjs.map +1 -0
- package/dist/types/handlers/index.d.cts +10 -0
- package/dist/types/handlers/index.d.cts.map +1 -0
- package/dist/types/handlers/index.d.mts +10 -0
- package/dist/types/handlers/index.d.mts.map +1 -0
- package/dist/types/handlers/index.mjs +10 -0
- package/dist/types/handlers/index.mjs.map +1 -0
- package/dist/types/handlers/keyring.cjs +3 -0
- package/dist/types/handlers/keyring.cjs.map +1 -0
- package/dist/types/{types/handlers/keyring.d.ts → handlers/keyring.d.cts} +2 -1
- package/dist/types/handlers/keyring.d.cts.map +1 -0
- package/dist/types/handlers/keyring.d.mts +21 -0
- package/dist/types/handlers/keyring.d.mts.map +1 -0
- package/dist/types/handlers/keyring.mjs +2 -0
- package/dist/types/handlers/keyring.mjs.map +1 -0
- package/dist/types/handlers/lifecycle.cjs +3 -0
- package/dist/types/handlers/lifecycle.cjs.map +1 -0
- package/dist/types/{types/handlers/lifecycle.d.ts → handlers/lifecycle.d.cts} +1 -0
- package/dist/types/handlers/lifecycle.d.cts.map +1 -0
- package/dist/types/handlers/lifecycle.d.mts +38 -0
- package/dist/types/handlers/lifecycle.d.mts.map +1 -0
- package/dist/types/handlers/lifecycle.mjs +2 -0
- package/dist/types/handlers/lifecycle.mjs.map +1 -0
- package/dist/types/handlers/name-lookup.cjs +3 -0
- package/dist/types/handlers/name-lookup.cjs.map +1 -0
- package/dist/types/{types/handlers/name-lookup.d.ts → handlers/name-lookup.d.cts} +3 -2
- package/dist/types/handlers/name-lookup.d.cts.map +1 -0
- package/dist/types/handlers/name-lookup.d.mts +82 -0
- package/dist/types/handlers/name-lookup.d.mts.map +1 -0
- package/dist/types/handlers/name-lookup.mjs +2 -0
- package/dist/types/handlers/name-lookup.mjs.map +1 -0
- package/dist/types/handlers/rpc-request.cjs +3 -0
- package/dist/types/handlers/rpc-request.cjs.map +1 -0
- package/dist/types/{types/handlers/rpc-request.d.ts → handlers/rpc-request.d.cts} +2 -1
- package/dist/types/handlers/rpc-request.d.cts.map +1 -0
- package/dist/types/handlers/rpc-request.d.mts +22 -0
- package/dist/types/handlers/rpc-request.d.mts.map +1 -0
- package/dist/types/handlers/rpc-request.mjs +2 -0
- package/dist/types/handlers/rpc-request.mjs.map +1 -0
- package/dist/types/handlers/signature.cjs +3 -0
- package/dist/types/handlers/signature.cjs.map +1 -0
- package/dist/types/{types/handlers/signature.d.ts → handlers/signature.d.cts} +4 -3
- package/dist/types/handlers/signature.d.cts.map +1 -0
- package/dist/types/handlers/signature.d.mts +112 -0
- package/dist/types/handlers/signature.d.mts.map +1 -0
- package/dist/types/handlers/signature.mjs +2 -0
- package/dist/types/handlers/signature.mjs.map +1 -0
- package/dist/types/handlers/transaction.cjs +15 -0
- package/dist/types/handlers/transaction.cjs.map +1 -0
- package/dist/types/{types/handlers/transaction.d.ts → handlers/transaction.d.cts} +4 -3
- package/dist/types/handlers/transaction.d.cts.map +1 -0
- package/dist/types/handlers/transaction.d.mts +115 -0
- package/dist/types/handlers/transaction.d.mts.map +1 -0
- package/dist/types/handlers/transaction.mjs +12 -0
- package/dist/types/handlers/transaction.mjs.map +1 -0
- package/dist/types/handlers/user-input.cjs +56 -0
- package/dist/types/handlers/user-input.cjs.map +1 -0
- package/dist/types/{types/handlers/user-input.d.ts → handlers/user-input.d.cts} +11 -10
- package/dist/types/handlers/user-input.d.cts.map +1 -0
- package/dist/types/handlers/user-input.d.mts +196 -0
- package/dist/types/handlers/user-input.d.mts.map +1 -0
- package/dist/types/handlers/user-input.mjs +53 -0
- package/dist/types/handlers/user-input.mjs.map +1 -0
- package/dist/types/images.cjs +2 -0
- package/dist/types/images.cjs.map +1 -0
- package/dist/types/{types/images.d.ts → images.d.cts} +1 -0
- package/dist/types/images.d.cts.map +1 -0
- package/dist/types/images.d.mts +13 -0
- package/dist/types/images.d.mts.map +1 -0
- package/dist/types/images.mjs +2 -0
- package/dist/types/images.mjs.map +1 -0
- package/dist/types/index.cjs +29 -0
- package/dist/types/index.cjs.map +1 -0
- package/dist/types/index.d.cts +10 -0
- package/dist/types/index.d.cts.map +1 -0
- package/dist/types/index.d.mts +10 -0
- package/dist/types/index.d.mts.map +1 -0
- package/dist/types/index.mjs +13 -0
- package/dist/types/index.mjs.map +1 -0
- package/dist/types/interface.cjs +26 -0
- package/dist/types/interface.cjs.map +1 -0
- package/dist/types/{types/interface.d.ts → interface.d.cts} +22 -21
- package/dist/types/interface.d.cts.map +1 -0
- package/dist/types/interface.d.mts +120 -0
- package/dist/types/interface.d.mts.map +1 -0
- package/dist/types/interface.mjs +23 -0
- package/dist/types/interface.mjs.map +1 -0
- package/dist/types/methods/create-interface.cjs +3 -0
- package/dist/types/methods/create-interface.cjs.map +1 -0
- package/dist/types/{types/methods/create-interface.d.ts → methods/create-interface.d.cts} +2 -1
- package/dist/types/methods/create-interface.d.cts.map +1 -0
- package/dist/types/methods/create-interface.d.mts +15 -0
- package/dist/types/methods/create-interface.d.mts.map +1 -0
- package/dist/types/methods/create-interface.mjs +2 -0
- package/dist/types/methods/create-interface.mjs.map +1 -0
- package/dist/types/methods/dialog.cjs +18 -0
- package/dist/types/methods/dialog.cjs.map +1 -0
- package/dist/types/{types/methods/dialog.d.ts → methods/dialog.d.cts} +4 -3
- package/dist/types/methods/dialog.d.cts.map +1 -0
- package/dist/types/methods/dialog.d.mts +88 -0
- package/dist/types/methods/dialog.d.mts.map +1 -0
- package/dist/types/methods/dialog.mjs +15 -0
- package/dist/types/methods/dialog.mjs.map +1 -0
- package/dist/types/methods/get-bip32-entropy.cjs +3 -0
- package/dist/types/methods/get-bip32-entropy.cjs.map +1 -0
- package/dist/types/{types/methods/get-bip32-entropy.d.ts → methods/get-bip32-entropy.d.cts} +3 -2
- package/dist/types/methods/get-bip32-entropy.d.cts.map +1 -0
- package/dist/types/methods/get-bip32-entropy.d.mts +16 -0
- package/dist/types/methods/get-bip32-entropy.d.mts.map +1 -0
- package/dist/types/methods/get-bip32-entropy.mjs +2 -0
- package/dist/types/methods/get-bip32-entropy.mjs.map +1 -0
- package/dist/types/methods/get-bip32-public-key.cjs +3 -0
- package/dist/types/methods/get-bip32-public-key.cjs.map +1 -0
- package/dist/types/{types/methods/get-bip32-public-key.d.ts → methods/get-bip32-public-key.d.cts} +2 -1
- package/dist/types/methods/get-bip32-public-key.d.cts.map +1 -0
- package/dist/types/methods/get-bip32-public-key.d.mts +20 -0
- package/dist/types/methods/get-bip32-public-key.d.mts.map +1 -0
- package/dist/types/methods/get-bip32-public-key.mjs +2 -0
- package/dist/types/methods/get-bip32-public-key.mjs.map +1 -0
- package/dist/types/methods/get-bip44-entropy.cjs +3 -0
- package/dist/types/methods/get-bip44-entropy.cjs.map +1 -0
- package/dist/types/{types/methods/get-bip44-entropy.d.ts → methods/get-bip44-entropy.d.cts} +3 -2
- package/dist/types/methods/get-bip44-entropy.d.cts.map +1 -0
- package/dist/types/methods/get-bip44-entropy.d.mts +15 -0
- package/dist/types/methods/get-bip44-entropy.d.mts.map +1 -0
- package/dist/types/methods/get-bip44-entropy.mjs +2 -0
- package/dist/types/methods/get-bip44-entropy.mjs.map +1 -0
- package/dist/types/methods/get-client-status.cjs +3 -0
- package/dist/types/methods/get-client-status.cjs.map +1 -0
- package/dist/types/{types/methods/get-client-status.d.ts → methods/get-client-status.d.cts} +1 -0
- package/dist/types/methods/get-client-status.d.cts.map +1 -0
- package/dist/types/methods/get-client-status.d.mts +15 -0
- package/dist/types/methods/get-client-status.d.mts.map +1 -0
- package/dist/types/methods/get-client-status.mjs +2 -0
- package/dist/types/methods/get-client-status.mjs.map +1 -0
- package/dist/types/methods/get-entropy.cjs +3 -0
- package/dist/types/methods/get-entropy.cjs.map +1 -0
- package/dist/types/{types/methods/get-entropy.d.ts → methods/get-entropy.d.cts} +2 -1
- package/dist/types/methods/get-entropy.d.cts.map +1 -0
- package/dist/types/methods/get-entropy.d.mts +17 -0
- package/dist/types/methods/get-entropy.d.mts.map +1 -0
- package/dist/types/methods/get-entropy.mjs +2 -0
- package/dist/types/methods/get-entropy.mjs.map +1 -0
- package/dist/types/methods/get-file.cjs +13 -0
- package/dist/types/methods/get-file.cjs.map +1 -0
- package/dist/types/{types/methods/get-file.d.ts → methods/get-file.d.cts} +2 -1
- package/dist/types/methods/get-file.d.cts.map +1 -0
- package/dist/types/methods/get-file.d.mts +24 -0
- package/dist/types/methods/get-file.d.mts.map +1 -0
- package/dist/types/methods/get-file.mjs +10 -0
- package/dist/types/methods/get-file.mjs.map +1 -0
- package/dist/types/methods/get-interface-state.cjs +3 -0
- package/dist/types/methods/get-interface-state.cjs.map +1 -0
- package/dist/types/{types/methods/get-interface-state.d.ts → methods/get-interface-state.d.cts} +2 -1
- package/dist/types/methods/get-interface-state.d.cts.map +1 -0
- package/dist/types/methods/get-interface-state.d.mts +14 -0
- package/dist/types/methods/get-interface-state.d.mts.map +1 -0
- package/dist/types/methods/get-interface-state.mjs +2 -0
- package/dist/types/methods/get-interface-state.mjs.map +1 -0
- package/dist/types/methods/get-locale.cjs +3 -0
- package/dist/types/methods/get-locale.cjs.map +1 -0
- package/dist/types/{types/methods/get-locale.d.ts → methods/get-locale.d.cts} +1 -0
- package/dist/types/methods/get-locale.d.cts.map +1 -0
- package/dist/types/methods/get-locale.d.mts +13 -0
- package/dist/types/methods/get-locale.d.mts.map +1 -0
- package/dist/types/methods/get-locale.mjs +2 -0
- package/dist/types/methods/get-locale.mjs.map +1 -0
- package/dist/types/methods/get-preferences.cjs +3 -0
- package/dist/types/methods/get-preferences.cjs.map +1 -0
- package/dist/types/{types/methods/get-preferences.d.ts → methods/get-preferences.d.cts} +1 -0
- package/dist/types/methods/get-preferences.d.cts.map +1 -0
- package/dist/types/methods/get-preferences.d.mts +16 -0
- package/dist/types/methods/get-preferences.d.mts.map +1 -0
- package/dist/types/methods/get-preferences.mjs +2 -0
- package/dist/types/methods/get-preferences.mjs.map +1 -0
- package/dist/types/methods/get-snaps.cjs +3 -0
- package/dist/types/methods/get-snaps.cjs.map +1 -0
- package/dist/types/{types/methods/get-snaps.d.ts → methods/get-snaps.d.cts} +3 -2
- package/dist/types/methods/get-snaps.d.cts.map +1 -0
- package/dist/types/methods/get-snaps.d.mts +17 -0
- package/dist/types/methods/get-snaps.d.mts.map +1 -0
- package/dist/types/methods/get-snaps.mjs +2 -0
- package/dist/types/methods/get-snaps.mjs.map +1 -0
- package/dist/types/methods/index.cjs +38 -0
- package/dist/types/methods/index.cjs.map +1 -0
- package/dist/types/methods/index.d.cts +22 -0
- package/dist/types/methods/index.d.cts.map +1 -0
- package/dist/types/methods/index.d.mts +22 -0
- package/dist/types/methods/index.d.mts.map +1 -0
- package/dist/types/methods/index.mjs +22 -0
- package/dist/types/methods/index.mjs.map +1 -0
- package/dist/types/methods/invoke-keyring.cjs +3 -0
- package/dist/types/methods/invoke-keyring.cjs.map +1 -0
- package/dist/types/{types/methods/invoke-keyring.d.ts → methods/invoke-keyring.d.cts} +3 -2
- package/dist/types/methods/invoke-keyring.d.cts.map +1 -0
- package/dist/types/methods/invoke-keyring.d.mts +15 -0
- package/dist/types/methods/invoke-keyring.d.mts.map +1 -0
- package/dist/types/methods/invoke-keyring.mjs +2 -0
- package/dist/types/methods/invoke-keyring.mjs.map +1 -0
- package/dist/types/methods/invoke-snap.cjs +3 -0
- package/dist/types/methods/invoke-snap.cjs.map +1 -0
- package/dist/types/{types/methods/invoke-snap.d.ts → methods/invoke-snap.d.cts} +2 -1
- package/dist/types/methods/invoke-snap.d.cts.map +1 -0
- package/dist/types/methods/invoke-snap.d.mts +17 -0
- package/dist/types/methods/invoke-snap.d.mts.map +1 -0
- package/dist/types/methods/invoke-snap.mjs +2 -0
- package/dist/types/methods/invoke-snap.mjs.map +1 -0
- package/dist/types/methods/manage-accounts.cjs +3 -0
- package/dist/types/methods/manage-accounts.cjs.map +1 -0
- package/dist/types/{types/methods/manage-accounts.d.ts → methods/manage-accounts.d.cts} +2 -1
- package/dist/types/methods/manage-accounts.d.cts.map +1 -0
- package/dist/types/methods/manage-accounts.d.mts +19 -0
- package/dist/types/methods/manage-accounts.d.mts.map +1 -0
- package/dist/types/methods/manage-accounts.mjs +2 -0
- package/dist/types/methods/manage-accounts.mjs.map +1 -0
- package/dist/types/methods/manage-state.cjs +13 -0
- package/dist/types/methods/manage-state.cjs.map +1 -0
- package/dist/types/{types/methods/manage-state.d.ts → methods/manage-state.d.cts} +3 -2
- package/dist/types/methods/manage-state.d.cts.map +1 -0
- package/dist/types/methods/manage-state.d.mts +70 -0
- package/dist/types/methods/manage-state.d.mts.map +1 -0
- package/dist/types/methods/manage-state.mjs +10 -0
- package/dist/types/methods/manage-state.mjs.map +1 -0
- package/dist/types/methods/methods.cjs +3 -0
- package/dist/types/methods/methods.cjs.map +1 -0
- package/dist/types/{types/methods/methods.d.ts → methods/methods.d.cts} +22 -21
- package/dist/types/methods/methods.d.cts.map +1 -0
- package/dist/types/methods/methods.d.mts +75 -0
- package/dist/types/methods/methods.d.mts.map +1 -0
- package/dist/types/methods/methods.mjs +2 -0
- package/dist/types/methods/methods.mjs.map +1 -0
- package/dist/types/methods/notify.cjs +15 -0
- package/dist/types/methods/notify.cjs.map +1 -0
- package/dist/types/{types/methods/notify.d.ts → methods/notify.d.cts} +2 -1
- package/dist/types/methods/notify.d.cts.map +1 -0
- package/dist/types/methods/notify.d.mts +28 -0
- package/dist/types/methods/notify.d.mts.map +1 -0
- package/dist/types/methods/notify.mjs +12 -0
- package/dist/types/methods/notify.mjs.map +1 -0
- package/dist/types/methods/request-snaps.cjs +3 -0
- package/dist/types/methods/request-snaps.cjs.map +1 -0
- package/dist/types/{types/methods/request-snaps.d.ts → methods/request-snaps.d.cts} +3 -2
- package/dist/types/methods/request-snaps.d.cts.map +1 -0
- package/dist/types/methods/request-snaps.d.mts +19 -0
- package/dist/types/methods/request-snaps.d.mts.map +1 -0
- package/dist/types/methods/request-snaps.mjs +2 -0
- package/dist/types/methods/request-snaps.mjs.map +1 -0
- package/dist/types/methods/resolve-interface.cjs +3 -0
- package/dist/types/methods/resolve-interface.cjs.map +1 -0
- package/dist/types/{types/methods/resolve-interface.d.ts → methods/resolve-interface.d.cts} +2 -1
- package/dist/types/methods/resolve-interface.d.cts.map +1 -0
- package/dist/types/methods/resolve-interface.d.mts +16 -0
- package/dist/types/methods/resolve-interface.d.mts.map +1 -0
- package/dist/types/methods/resolve-interface.mjs +2 -0
- package/dist/types/methods/resolve-interface.mjs.map +1 -0
- package/dist/types/methods/update-interface.cjs +3 -0
- package/dist/types/methods/update-interface.cjs.map +1 -0
- package/dist/types/{types/methods/update-interface.d.ts → methods/update-interface.d.cts} +2 -1
- package/dist/types/methods/update-interface.d.cts.map +1 -0
- package/dist/types/methods/update-interface.d.mts +16 -0
- package/dist/types/methods/update-interface.d.mts.map +1 -0
- package/dist/types/methods/update-interface.mjs +2 -0
- package/dist/types/methods/update-interface.mjs.map +1 -0
- package/dist/types/permissions.cjs +3 -0
- package/dist/types/permissions.cjs.map +1 -0
- package/dist/types/{types/permissions.d.ts → permissions.d.cts} +4 -3
- package/dist/types/permissions.d.cts.map +1 -0
- package/dist/types/permissions.d.mts +75 -0
- package/dist/types/permissions.d.mts.map +1 -0
- package/dist/types/permissions.mjs +2 -0
- package/dist/types/permissions.mjs.map +1 -0
- package/dist/types/provider.cjs +3 -0
- package/dist/types/provider.cjs.map +1 -0
- package/dist/types/{types/provider.d.ts → provider.d.cts} +3 -2
- package/dist/types/provider.d.cts.map +1 -0
- package/dist/types/provider.d.mts +15 -0
- package/dist/types/provider.d.mts.map +1 -0
- package/dist/types/provider.mjs +2 -0
- package/dist/types/provider.mjs.map +1 -0
- package/dist/types/snap.cjs +3 -0
- package/dist/types/snap.cjs.map +1 -0
- package/dist/types/{types/snap.d.ts → snap.d.cts} +3 -2
- package/dist/types/snap.d.cts.map +1 -0
- package/dist/types/snap.d.mts +13 -0
- package/dist/types/snap.d.mts.map +1 -0
- package/dist/types/snap.mjs +2 -0
- package/dist/types/snap.mjs.map +1 -0
- package/dist/ui/builder.cjs +49 -0
- package/dist/ui/builder.cjs.map +1 -0
- package/dist/{types/ui/builder.d.ts → ui/builder.d.cts} +4 -3
- package/dist/ui/builder.d.cts.map +1 -0
- package/dist/ui/builder.d.mts +43 -0
- package/dist/ui/builder.d.mts.map +1 -0
- package/dist/ui/builder.mjs +45 -0
- package/dist/ui/builder.mjs.map +1 -0
- package/dist/ui/component.cjs +29 -0
- package/dist/ui/component.cjs.map +1 -0
- package/dist/{types/ui/component.d.ts → ui/component.d.cts} +2 -1
- package/dist/ui/component.d.cts.map +1 -0
- package/dist/ui/component.d.mts +18 -0
- package/dist/ui/component.d.mts.map +1 -0
- package/dist/ui/component.mjs +24 -0
- package/dist/ui/component.mjs.map +1 -0
- package/dist/ui/components/address.cjs +28 -0
- package/dist/ui/components/address.cjs.map +1 -0
- package/dist/{types/ui/components/address.d.ts → ui/components/address.d.cts} +6 -5
- package/dist/ui/components/address.d.cts.map +1 -0
- package/dist/ui/components/address.d.mts +37 -0
- package/dist/ui/components/address.d.mts.map +1 -0
- package/dist/ui/components/address.mjs +25 -0
- package/dist/ui/components/address.mjs.map +1 -0
- package/dist/ui/components/button.cjs +52 -0
- package/dist/ui/components/button.cjs.map +1 -0
- package/dist/{types/ui/components/button.d.ts → ui/components/button.d.cts} +9 -8
- package/dist/ui/components/button.d.cts.map +1 -0
- package/dist/ui/components/button.d.mts +65 -0
- package/dist/ui/components/button.d.mts.map +1 -0
- package/dist/ui/components/button.mjs +49 -0
- package/dist/ui/components/button.mjs.map +1 -0
- package/dist/ui/components/copyable.cjs +32 -0
- package/dist/ui/components/copyable.cjs.map +1 -0
- package/dist/{types/ui/components/copyable.d.ts → ui/components/copyable.d.cts} +6 -5
- package/dist/ui/components/copyable.d.cts.map +1 -0
- package/dist/ui/components/copyable.d.mts +49 -0
- package/dist/ui/components/copyable.d.mts.map +1 -0
- package/dist/ui/components/copyable.mjs +29 -0
- package/dist/ui/components/copyable.mjs.map +1 -0
- package/dist/ui/components/divider.cjs +20 -0
- package/dist/ui/components/divider.cjs.map +1 -0
- package/dist/{types/ui/components/divider.d.ts → ui/components/divider.d.cts} +3 -2
- package/dist/ui/components/divider.d.cts.map +1 -0
- package/dist/ui/components/divider.d.mts +24 -0
- package/dist/ui/components/divider.d.mts.map +1 -0
- package/dist/ui/components/divider.mjs +17 -0
- package/dist/ui/components/divider.mjs.map +1 -0
- package/dist/ui/components/form.cjs +41 -0
- package/dist/ui/components/form.cjs.map +1 -0
- package/dist/{types/ui/components/form.d.ts → ui/components/form.d.cts} +31 -30
- package/dist/ui/components/form.d.cts.map +1 -0
- package/dist/ui/components/form.d.mts +154 -0
- package/dist/ui/components/form.d.mts.map +1 -0
- package/dist/ui/components/form.mjs +38 -0
- package/dist/ui/components/form.mjs.map +1 -0
- package/dist/ui/components/heading.cjs +27 -0
- package/dist/ui/components/heading.cjs.map +1 -0
- package/dist/{types/ui/components/heading.d.ts → ui/components/heading.d.cts} +6 -5
- package/dist/ui/components/heading.d.cts.map +1 -0
- package/dist/ui/components/heading.d.mts +39 -0
- package/dist/ui/components/heading.d.mts.map +1 -0
- package/dist/ui/components/heading.mjs +24 -0
- package/dist/ui/components/heading.mjs.map +1 -0
- package/dist/ui/components/image.cjs +27 -0
- package/dist/ui/components/image.cjs.map +1 -0
- package/dist/{types/ui/components/image.d.ts → ui/components/image.d.cts} +6 -5
- package/dist/ui/components/image.d.cts.map +1 -0
- package/dist/ui/components/image.d.mts +38 -0
- package/dist/ui/components/image.d.mts.map +1 -0
- package/dist/ui/components/image.mjs +24 -0
- package/dist/ui/components/image.mjs.map +1 -0
- package/dist/ui/components/index.cjs +35 -0
- package/dist/ui/components/index.cjs.map +1 -0
- package/dist/ui/components/index.d.cts +15 -0
- package/dist/ui/components/index.d.cts.map +1 -0
- package/dist/ui/components/index.d.mts +15 -0
- package/dist/ui/components/index.d.mts.map +1 -0
- package/dist/ui/components/index.mjs +13 -0
- package/dist/ui/components/index.mjs.map +1 -0
- package/dist/ui/components/input.cjs +60 -0
- package/dist/ui/components/input.cjs.map +1 -0
- package/dist/{types/ui/components/input.d.ts → ui/components/input.d.cts} +9 -8
- package/dist/ui/components/input.d.cts.map +1 -0
- package/dist/ui/components/input.d.mts +78 -0
- package/dist/ui/components/input.d.mts.map +1 -0
- package/dist/ui/components/input.mjs +57 -0
- package/dist/ui/components/input.mjs.map +1 -0
- package/dist/ui/components/panel.cjs +72 -0
- package/dist/ui/components/panel.cjs.map +1 -0
- package/dist/{types/ui/components/panel.d.ts → ui/components/panel.d.cts} +88 -87
- package/dist/ui/components/panel.d.cts.map +1 -0
- package/dist/ui/components/panel.d.mts +406 -0
- package/dist/ui/components/panel.d.mts.map +1 -0
- package/dist/ui/components/panel.mjs +69 -0
- package/dist/ui/components/panel.mjs.map +1 -0
- package/dist/ui/components/row.cjs +51 -0
- package/dist/ui/components/row.cjs.map +1 -0
- package/dist/{types/ui/components/row.d.ts → ui/components/row.d.cts} +21 -20
- package/dist/ui/components/row.d.cts.map +1 -0
- package/dist/ui/components/row.d.mts +107 -0
- package/dist/ui/components/row.d.mts.map +1 -0
- package/dist/ui/components/row.mjs +48 -0
- package/dist/ui/components/row.mjs.map +1 -0
- package/dist/ui/components/spinner.cjs +20 -0
- package/dist/ui/components/spinner.cjs.map +1 -0
- package/dist/{types/ui/components/spinner.d.ts → ui/components/spinner.d.cts} +3 -2
- package/dist/ui/components/spinner.d.cts.map +1 -0
- package/dist/ui/components/spinner.d.mts +25 -0
- package/dist/ui/components/spinner.d.mts.map +1 -0
- package/dist/ui/components/spinner.mjs +17 -0
- package/dist/ui/components/spinner.mjs.map +1 -0
- package/dist/ui/components/text.cjs +34 -0
- package/dist/ui/components/text.cjs.map +1 -0
- package/dist/{types/ui/components/text.d.ts → ui/components/text.d.cts} +6 -5
- package/dist/ui/components/text.d.cts.map +1 -0
- package/dist/ui/components/text.d.mts +49 -0
- package/dist/ui/components/text.d.mts.map +1 -0
- package/dist/ui/components/text.mjs +31 -0
- package/dist/ui/components/text.mjs.map +1 -0
- package/dist/ui/index.cjs +22 -0
- package/dist/ui/index.cjs.map +1 -0
- package/dist/ui/index.d.cts +4 -0
- package/dist/ui/index.d.cts.map +1 -0
- package/dist/ui/index.d.mts +4 -0
- package/dist/ui/index.d.mts.map +1 -0
- package/dist/ui/index.mjs +4 -0
- package/dist/ui/index.mjs.map +1 -0
- package/dist/ui/nodes.cjs +38 -0
- package/dist/ui/nodes.cjs.map +1 -0
- package/dist/{types/ui/nodes.d.ts → ui/nodes.d.cts} +3 -2
- package/dist/ui/nodes.d.cts.map +1 -0
- package/dist/ui/nodes.d.mts +57 -0
- package/dist/ui/nodes.d.mts.map +1 -0
- package/dist/ui/nodes.mjs +35 -0
- package/dist/ui/nodes.mjs.map +1 -0
- package/jsx-dev-runtime.d.ts +3 -1
- package/jsx-dev-runtime.js +1 -1
- package/jsx-runtime.d.ts +3 -1
- package/jsx-runtime.js +1 -1
- package/jsx.d.ts +3 -1
- package/jsx.js +1 -1
- package/package.json +42 -27
- package/dist/index.js +0 -1370
- package/dist/index.js.map +0 -1
- package/dist/jsx/index.js +0 -810
- package/dist/jsx/index.js.map +0 -1
- package/dist/jsx/jsx-dev-runtime.js +0 -644
- package/dist/jsx/jsx-dev-runtime.js.map +0 -1
- package/dist/jsx/jsx-runtime.js +0 -45
- package/dist/jsx/jsx-runtime.js.map +0 -1
- package/dist/tsconfig.build.tsbuildinfo +0 -1
- package/dist/types/index.d.ts +0 -9
- package/dist/types/internals/index.d.ts +0 -6
- package/dist/types/jsx/components/Address.d.ts +0 -28
- package/dist/types/jsx/components/form/index.d.ts +0 -25
- package/dist/types/jsx/components/formatting/index.d.ts +0 -5
- package/dist/types/jsx/components/index.d.ts +0 -40
- package/dist/types/jsx/index.d.ts +0 -5
- package/dist/types/types/handlers/index.d.ts +0 -9
- package/dist/types/types/index.d.ts +0 -9
- package/dist/types/types/methods/index.d.ts +0 -21
- package/dist/types/ui/components/index.d.ts +0 -14
- package/dist/types/ui/index.d.ts +0 -3
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"caip.mjs","sourceRoot":"","sources":["../../src/types/caip.ts"],"names":[],"mappings":"","sourcesContent":["/**\n * A CAIP-2 chain ID, i.e., a human-readable namespace and reference.\n *\n * @see https://chainagnostic.org/CAIPs/caip-2\n */\nexport type ChainId = `${string}:${string}`;\n\n/**\n * A CAIP-10 account ID, i.e., a chain ID and an account address.\n *\n * @see https://chainagnostic.org/CAIPs/caip-10\n */\nexport type AccountId = `${ChainId}:${string}`;\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"global.cjs","sourceRoot":"","sources":["../../src/types/global.ts"],"names":[],"mappings":"","sourcesContent":["import type { SnapsEthereumProvider, SnapsProvider } from './provider';\n\n/**\n * Constants that are available globally in the Snap.\n */\ndeclare global {\n const ethereum: SnapsEthereumProvider;\n const snap: SnapsProvider;\n}\n"]}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { SnapsEthereumProvider, SnapsProvider } from
|
|
1
|
+
import type { SnapsEthereumProvider, SnapsProvider } from "./provider.cjs";
|
|
2
2
|
/**
|
|
3
3
|
* Constants that are available globally in the Snap.
|
|
4
4
|
*/
|
|
@@ -6,3 +6,4 @@ declare global {
|
|
|
6
6
|
const ethereum: SnapsEthereumProvider;
|
|
7
7
|
const snap: SnapsProvider;
|
|
8
8
|
}
|
|
9
|
+
//# sourceMappingURL=global.d.cts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"global.d.cts","sourceRoot":"","sources":["../../src/types/global.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,qBAAqB,EAAE,aAAa,EAAE,uBAAmB;AAEvE;;GAEG;AACH,OAAO,CAAC,MAAM,CAAC;IACb,MAAM,QAAQ,EAAE,qBAAqB,CAAC;IACtC,MAAM,IAAI,EAAE,aAAa,CAAC;CAC3B"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { SnapsEthereumProvider, SnapsProvider } from "./provider.mjs";
|
|
2
|
+
/**
|
|
3
|
+
* Constants that are available globally in the Snap.
|
|
4
|
+
*/
|
|
5
|
+
declare global {
|
|
6
|
+
const ethereum: SnapsEthereumProvider;
|
|
7
|
+
const snap: SnapsProvider;
|
|
8
|
+
}
|
|
9
|
+
//# sourceMappingURL=global.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"global.d.mts","sourceRoot":"","sources":["../../src/types/global.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,qBAAqB,EAAE,aAAa,EAAE,uBAAmB;AAEvE;;GAEG;AACH,OAAO,CAAC,MAAM,CAAC;IACb,MAAM,QAAQ,EAAE,qBAAqB,CAAC;IACtC,MAAM,IAAI,EAAE,aAAa,CAAC;CAC3B"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"global.mjs","sourceRoot":"","sources":["../../src/types/global.ts"],"names":[],"mappings":"","sourcesContent":["import type { SnapsEthereumProvider, SnapsProvider } from './provider';\n\n/**\n * Constants that are available globally in the Snap.\n */\ndeclare global {\n const ethereum: SnapsEthereumProvider;\n const snap: SnapsProvider;\n}\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"cronjob.cjs","sourceRoot":"","sources":["../../../src/types/handlers/cronjob.ts"],"names":[],"mappings":"","sourcesContent":["import type { JsonRpcParams, JsonRpcRequest } from '@metamask/utils';\n\n/**\n * The `onCronjob` handler. This is called on a regular interval, as defined by\n * the Snap's manifest.\n *\n * Note that using this handler requires the `endowment:cronjob` permission.\n *\n * @param args - The request arguments.\n * @param args.request - The JSON-RPC request sent to the snap. The parameters\n * are defined by the Snap's manifest.\n */\nexport type OnCronjobHandler<Params extends JsonRpcParams = JsonRpcParams> =\n (args: { request: JsonRpcRequest<Params> }) => Promise<unknown>;\n"]}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { JsonRpcParams, JsonRpcRequest } from
|
|
1
|
+
import type { JsonRpcParams, JsonRpcRequest } from "@metamask/utils";
|
|
2
2
|
/**
|
|
3
3
|
* The `onCronjob` handler. This is called on a regular interval, as defined by
|
|
4
4
|
* the Snap's manifest.
|
|
@@ -12,3 +12,4 @@ import type { JsonRpcParams, JsonRpcRequest } from '@metamask/utils';
|
|
|
12
12
|
export type OnCronjobHandler<Params extends JsonRpcParams = JsonRpcParams> = (args: {
|
|
13
13
|
request: JsonRpcRequest<Params>;
|
|
14
14
|
}) => Promise<unknown>;
|
|
15
|
+
//# sourceMappingURL=cronjob.d.cts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"cronjob.d.cts","sourceRoot":"","sources":["../../../src/types/handlers/cronjob.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,cAAc,EAAE,wBAAwB;AAErE;;;;;;;;;GASG;AACH,MAAM,MAAM,gBAAgB,CAAC,MAAM,SAAS,aAAa,GAAG,aAAa,IACvE,CAAC,IAAI,EAAE;IAAE,OAAO,EAAE,cAAc,CAAC,MAAM,CAAC,CAAA;CAAE,KAAK,OAAO,CAAC,OAAO,CAAC,CAAC"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import type { JsonRpcParams, JsonRpcRequest } from "@metamask/utils";
|
|
2
|
+
/**
|
|
3
|
+
* The `onCronjob` handler. This is called on a regular interval, as defined by
|
|
4
|
+
* the Snap's manifest.
|
|
5
|
+
*
|
|
6
|
+
* Note that using this handler requires the `endowment:cronjob` permission.
|
|
7
|
+
*
|
|
8
|
+
* @param args - The request arguments.
|
|
9
|
+
* @param args.request - The JSON-RPC request sent to the snap. The parameters
|
|
10
|
+
* are defined by the Snap's manifest.
|
|
11
|
+
*/
|
|
12
|
+
export type OnCronjobHandler<Params extends JsonRpcParams = JsonRpcParams> = (args: {
|
|
13
|
+
request: JsonRpcRequest<Params>;
|
|
14
|
+
}) => Promise<unknown>;
|
|
15
|
+
//# sourceMappingURL=cronjob.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"cronjob.d.mts","sourceRoot":"","sources":["../../../src/types/handlers/cronjob.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,cAAc,EAAE,wBAAwB;AAErE;;;;;;;;;GASG;AACH,MAAM,MAAM,gBAAgB,CAAC,MAAM,SAAS,aAAa,GAAG,aAAa,IACvE,CAAC,IAAI,EAAE;IAAE,OAAO,EAAE,cAAc,CAAC,MAAM,CAAC,CAAA;CAAE,KAAK,OAAO,CAAC,OAAO,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"cronjob.mjs","sourceRoot":"","sources":["../../../src/types/handlers/cronjob.ts"],"names":[],"mappings":"","sourcesContent":["import type { JsonRpcParams, JsonRpcRequest } from '@metamask/utils';\n\n/**\n * The `onCronjob` handler. This is called on a regular interval, as defined by\n * the Snap's manifest.\n *\n * Note that using this handler requires the `endowment:cronjob` permission.\n *\n * @param args - The request arguments.\n * @param args.request - The JSON-RPC request sent to the snap. The parameters\n * are defined by the Snap's manifest.\n */\nexport type OnCronjobHandler<Params extends JsonRpcParams = JsonRpcParams> =\n (args: { request: JsonRpcRequest<Params> }) => Promise<unknown>;\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"home-page.cjs","sourceRoot":"","sources":["../../../src/types/handlers/home-page.ts"],"names":[],"mappings":"","sourcesContent":["import type { ComponentOrElement } from '..';\n\n/**\n * The `onHomePage` handler. This is called when the user navigates to the\n * Snap's home page in the MetaMask UI.\n *\n * This function does not receive any arguments.\n *\n * @returns The content to display on the home page. See\n * {@link OnHomePageResponse}.\n */\nexport type OnHomePageHandler = () => Promise<OnHomePageResponse>;\n\n/**\n * The content to display on the home page.\n *\n * @property content - A custom UI component, that will be shown in MetaMask.\n * @property id - A custom UI interface ID, that will be shown in MetaMask.\n */\nexport type OnHomePageResponse =\n | {\n content: ComponentOrElement;\n }\n | { id: string };\n"]}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { ComponentOrElement } from
|
|
1
|
+
import type { ComponentOrElement } from "../index.cjs";
|
|
2
2
|
/**
|
|
3
3
|
* The `onHomePage` handler. This is called when the user navigates to the
|
|
4
4
|
* Snap's home page in the MetaMask UI.
|
|
@@ -20,3 +20,4 @@ export type OnHomePageResponse = {
|
|
|
20
20
|
} | {
|
|
21
21
|
id: string;
|
|
22
22
|
};
|
|
23
|
+
//# sourceMappingURL=home-page.d.cts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"home-page.d.cts","sourceRoot":"","sources":["../../../src/types/handlers/home-page.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,qBAAW;AAE7C;;;;;;;;GAQG;AACH,MAAM,MAAM,iBAAiB,GAAG,MAAM,OAAO,CAAC,kBAAkB,CAAC,CAAC;AAElE;;;;;GAKG;AACH,MAAM,MAAM,kBAAkB,GAC1B;IACE,OAAO,EAAE,kBAAkB,CAAC;CAC7B,GACD;IAAE,EAAE,EAAE,MAAM,CAAA;CAAE,CAAC"}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import type { ComponentOrElement } from "../index.mjs";
|
|
2
|
+
/**
|
|
3
|
+
* The `onHomePage` handler. This is called when the user navigates to the
|
|
4
|
+
* Snap's home page in the MetaMask UI.
|
|
5
|
+
*
|
|
6
|
+
* This function does not receive any arguments.
|
|
7
|
+
*
|
|
8
|
+
* @returns The content to display on the home page. See
|
|
9
|
+
* {@link OnHomePageResponse}.
|
|
10
|
+
*/
|
|
11
|
+
export type OnHomePageHandler = () => Promise<OnHomePageResponse>;
|
|
12
|
+
/**
|
|
13
|
+
* The content to display on the home page.
|
|
14
|
+
*
|
|
15
|
+
* @property content - A custom UI component, that will be shown in MetaMask.
|
|
16
|
+
* @property id - A custom UI interface ID, that will be shown in MetaMask.
|
|
17
|
+
*/
|
|
18
|
+
export type OnHomePageResponse = {
|
|
19
|
+
content: ComponentOrElement;
|
|
20
|
+
} | {
|
|
21
|
+
id: string;
|
|
22
|
+
};
|
|
23
|
+
//# sourceMappingURL=home-page.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"home-page.d.mts","sourceRoot":"","sources":["../../../src/types/handlers/home-page.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,qBAAW;AAE7C;;;;;;;;GAQG;AACH,MAAM,MAAM,iBAAiB,GAAG,MAAM,OAAO,CAAC,kBAAkB,CAAC,CAAC;AAElE;;;;;GAKG;AACH,MAAM,MAAM,kBAAkB,GAC1B;IACE,OAAO,EAAE,kBAAkB,CAAC;CAC7B,GACD;IAAE,EAAE,EAAE,MAAM,CAAA;CAAE,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"home-page.mjs","sourceRoot":"","sources":["../../../src/types/handlers/home-page.ts"],"names":[],"mappings":"","sourcesContent":["import type { ComponentOrElement } from '..';\n\n/**\n * The `onHomePage` handler. This is called when the user navigates to the\n * Snap's home page in the MetaMask UI.\n *\n * This function does not receive any arguments.\n *\n * @returns The content to display on the home page. See\n * {@link OnHomePageResponse}.\n */\nexport type OnHomePageHandler = () => Promise<OnHomePageResponse>;\n\n/**\n * The content to display on the home page.\n *\n * @property content - A custom UI component, that will be shown in MetaMask.\n * @property id - A custom UI interface ID, that will be shown in MetaMask.\n */\nexport type OnHomePageResponse =\n | {\n content: ComponentOrElement;\n }\n | { id: string };\n"]}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./cronjob.cjs"), exports);
|
|
18
|
+
__exportStar(require("./home-page.cjs"), exports);
|
|
19
|
+
__exportStar(require("./keyring.cjs"), exports);
|
|
20
|
+
__exportStar(require("./lifecycle.cjs"), exports);
|
|
21
|
+
__exportStar(require("./name-lookup.cjs"), exports);
|
|
22
|
+
__exportStar(require("./rpc-request.cjs"), exports);
|
|
23
|
+
__exportStar(require("./transaction.cjs"), exports);
|
|
24
|
+
__exportStar(require("./signature.cjs"), exports);
|
|
25
|
+
__exportStar(require("./user-input.cjs"), exports);
|
|
26
|
+
//# sourceMappingURL=index.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.cjs","sourceRoot":"","sources":["../../../src/types/handlers/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,gDAA0B;AAC1B,kDAA4B;AAC5B,gDAA0B;AAC1B,kDAA4B;AAC5B,oDAA8B;AAC9B,oDAA8B;AAC9B,oDAA8B;AAC9B,kDAA4B;AAC5B,mDAA6B","sourcesContent":["export * from './cronjob';\nexport * from './home-page';\nexport * from './keyring';\nexport * from './lifecycle';\nexport * from './name-lookup';\nexport * from './rpc-request';\nexport * from './transaction';\nexport * from './signature';\nexport * from './user-input';\n"]}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export * from "./cronjob.cjs";
|
|
2
|
+
export * from "./home-page.cjs";
|
|
3
|
+
export * from "./keyring.cjs";
|
|
4
|
+
export * from "./lifecycle.cjs";
|
|
5
|
+
export * from "./name-lookup.cjs";
|
|
6
|
+
export * from "./rpc-request.cjs";
|
|
7
|
+
export * from "./transaction.cjs";
|
|
8
|
+
export * from "./signature.cjs";
|
|
9
|
+
export * from "./user-input.cjs";
|
|
10
|
+
//# sourceMappingURL=index.d.cts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.cts","sourceRoot":"","sources":["../../../src/types/handlers/index.ts"],"names":[],"mappings":"AAAA,8BAA0B;AAC1B,gCAA4B;AAC5B,8BAA0B;AAC1B,gCAA4B;AAC5B,kCAA8B;AAC9B,kCAA8B;AAC9B,kCAA8B;AAC9B,gCAA4B;AAC5B,iCAA6B"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export * from "./cronjob.mjs";
|
|
2
|
+
export * from "./home-page.mjs";
|
|
3
|
+
export * from "./keyring.mjs";
|
|
4
|
+
export * from "./lifecycle.mjs";
|
|
5
|
+
export * from "./name-lookup.mjs";
|
|
6
|
+
export * from "./rpc-request.mjs";
|
|
7
|
+
export * from "./transaction.mjs";
|
|
8
|
+
export * from "./signature.mjs";
|
|
9
|
+
export * from "./user-input.mjs";
|
|
10
|
+
//# sourceMappingURL=index.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.mts","sourceRoot":"","sources":["../../../src/types/handlers/index.ts"],"names":[],"mappings":"AAAA,8BAA0B;AAC1B,gCAA4B;AAC5B,8BAA0B;AAC1B,gCAA4B;AAC5B,kCAA8B;AAC9B,kCAA8B;AAC9B,kCAA8B;AAC9B,gCAA4B;AAC5B,iCAA6B"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export * from "./cronjob.mjs";
|
|
2
|
+
export * from "./home-page.mjs";
|
|
3
|
+
export * from "./keyring.mjs";
|
|
4
|
+
export * from "./lifecycle.mjs";
|
|
5
|
+
export * from "./name-lookup.mjs";
|
|
6
|
+
export * from "./rpc-request.mjs";
|
|
7
|
+
export * from "./transaction.mjs";
|
|
8
|
+
export * from "./signature.mjs";
|
|
9
|
+
export * from "./user-input.mjs";
|
|
10
|
+
//# sourceMappingURL=index.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.mjs","sourceRoot":"","sources":["../../../src/types/handlers/index.ts"],"names":[],"mappings":"AAAA,8BAA0B;AAC1B,gCAA4B;AAC5B,8BAA0B;AAC1B,gCAA4B;AAC5B,kCAA8B;AAC9B,kCAA8B;AAC9B,kCAA8B;AAC9B,gCAA4B;AAC5B,iCAA6B","sourcesContent":["export * from './cronjob';\nexport * from './home-page';\nexport * from './keyring';\nexport * from './lifecycle';\nexport * from './name-lookup';\nexport * from './rpc-request';\nexport * from './transaction';\nexport * from './signature';\nexport * from './user-input';\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"keyring.cjs","sourceRoot":"","sources":["../../../src/types/handlers/keyring.ts"],"names":[],"mappings":"","sourcesContent":["import type { Json, JsonRpcParams, JsonRpcRequest } from '@metamask/utils';\n\n/**\n * The `onKeyringRequest` handler, which is called when a Snap receives a\n * keyring request.\n *\n * Note that using this handler requires the `endowment:keyring` permission.\n *\n * @param args - The request arguments.\n * @param args.origin - The origin of the request. This can be the ID of another\n * Snap, or the URL of a website.\n * @param args.request - The keyring request sent to the Snap. This includes\n * the method name and parameters.\n * @returns The response to the keyring request. This must be a\n * JSON-serializable value. In order to return an error, throw a `SnapError`\n * instead.\n */\nexport type OnKeyringRequestHandler<\n Params extends JsonRpcParams = JsonRpcParams,\n> = (args: {\n origin: string;\n request: JsonRpcRequest<Params>;\n}) => Promise<Json>;\n"]}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { Json, JsonRpcParams, JsonRpcRequest } from
|
|
1
|
+
import type { Json, JsonRpcParams, JsonRpcRequest } from "@metamask/utils";
|
|
2
2
|
/**
|
|
3
3
|
* The `onKeyringRequest` handler, which is called when a Snap receives a
|
|
4
4
|
* keyring request.
|
|
@@ -18,3 +18,4 @@ export type OnKeyringRequestHandler<Params extends JsonRpcParams = JsonRpcParams
|
|
|
18
18
|
origin: string;
|
|
19
19
|
request: JsonRpcRequest<Params>;
|
|
20
20
|
}) => Promise<Json>;
|
|
21
|
+
//# sourceMappingURL=keyring.d.cts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"keyring.d.cts","sourceRoot":"","sources":["../../../src/types/handlers/keyring.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,aAAa,EAAE,cAAc,EAAE,wBAAwB;AAE3E;;;;;;;;;;;;;;GAcG;AACH,MAAM,MAAM,uBAAuB,CACjC,MAAM,SAAS,aAAa,GAAG,aAAa,IAC1C,CAAC,IAAI,EAAE;IACT,MAAM,EAAE,MAAM,CAAC;IACf,OAAO,EAAE,cAAc,CAAC,MAAM,CAAC,CAAC;CACjC,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import type { Json, JsonRpcParams, JsonRpcRequest } from "@metamask/utils";
|
|
2
|
+
/**
|
|
3
|
+
* The `onKeyringRequest` handler, which is called when a Snap receives a
|
|
4
|
+
* keyring request.
|
|
5
|
+
*
|
|
6
|
+
* Note that using this handler requires the `endowment:keyring` permission.
|
|
7
|
+
*
|
|
8
|
+
* @param args - The request arguments.
|
|
9
|
+
* @param args.origin - The origin of the request. This can be the ID of another
|
|
10
|
+
* Snap, or the URL of a website.
|
|
11
|
+
* @param args.request - The keyring request sent to the Snap. This includes
|
|
12
|
+
* the method name and parameters.
|
|
13
|
+
* @returns The response to the keyring request. This must be a
|
|
14
|
+
* JSON-serializable value. In order to return an error, throw a `SnapError`
|
|
15
|
+
* instead.
|
|
16
|
+
*/
|
|
17
|
+
export type OnKeyringRequestHandler<Params extends JsonRpcParams = JsonRpcParams> = (args: {
|
|
18
|
+
origin: string;
|
|
19
|
+
request: JsonRpcRequest<Params>;
|
|
20
|
+
}) => Promise<Json>;
|
|
21
|
+
//# sourceMappingURL=keyring.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"keyring.d.mts","sourceRoot":"","sources":["../../../src/types/handlers/keyring.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,aAAa,EAAE,cAAc,EAAE,wBAAwB;AAE3E;;;;;;;;;;;;;;GAcG;AACH,MAAM,MAAM,uBAAuB,CACjC,MAAM,SAAS,aAAa,GAAG,aAAa,IAC1C,CAAC,IAAI,EAAE;IACT,MAAM,EAAE,MAAM,CAAC;IACf,OAAO,EAAE,cAAc,CAAC,MAAM,CAAC,CAAC;CACjC,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"keyring.mjs","sourceRoot":"","sources":["../../../src/types/handlers/keyring.ts"],"names":[],"mappings":"","sourcesContent":["import type { Json, JsonRpcParams, JsonRpcRequest } from '@metamask/utils';\n\n/**\n * The `onKeyringRequest` handler, which is called when a Snap receives a\n * keyring request.\n *\n * Note that using this handler requires the `endowment:keyring` permission.\n *\n * @param args - The request arguments.\n * @param args.origin - The origin of the request. This can be the ID of another\n * Snap, or the URL of a website.\n * @param args.request - The keyring request sent to the Snap. This includes\n * the method name and parameters.\n * @returns The response to the keyring request. This must be a\n * JSON-serializable value. In order to return an error, throw a `SnapError`\n * instead.\n */\nexport type OnKeyringRequestHandler<\n Params extends JsonRpcParams = JsonRpcParams,\n> = (args: {\n origin: string;\n request: JsonRpcRequest<Params>;\n}) => Promise<Json>;\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"lifecycle.cjs","sourceRoot":"","sources":["../../../src/types/handlers/lifecycle.ts"],"names":[],"mappings":"","sourcesContent":["/**\n * A lifecycle event handler. This is called whenever a lifecycle event occurs,\n * such as the Snap being installed or updated.\n *\n * Note that using this handler requires the `endowment:lifecycle-hooks`\n * permission.\n *\n * @param args - The request arguments.\n * @param args.origin - The origin that triggered the lifecycle event hook.\n */\nexport type LifecycleEventHandler = (args: {\n origin: string;\n}) => Promise<unknown>;\n\n/**\n * The `onInstall` handler. This is called after the Snap is installed.\n *\n * Note that using this handler requires the `endowment:lifecycle-hooks`\n * permission.\n *\n * This type is an alias for {@link LifecycleEventHandler}.\n *\n * @param args - The request arguments.\n * @param args.origin - The origin that triggered the lifecycle event hook.\n */\nexport type OnInstallHandler = LifecycleEventHandler;\n\n/**\n * The `onUpdate` handler. This is called after the Snap is updated.\n *\n * Note that using this handler requires the `endowment:lifecycle-hooks`\n * permission.\n *\n * This type is an alias for {@link LifecycleEventHandler}.\n *\n * @param args - The request arguments.\n * @param args.origin - The origin that triggered the lifecycle event hook.\n */\nexport type OnUpdateHandler = LifecycleEventHandler;\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"lifecycle.d.cts","sourceRoot":"","sources":["../../../src/types/handlers/lifecycle.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AACH,MAAM,MAAM,qBAAqB,GAAG,CAAC,IAAI,EAAE;IACzC,MAAM,EAAE,MAAM,CAAC;CAChB,KAAK,OAAO,CAAC,OAAO,CAAC,CAAC;AAEvB;;;;;;;;;;GAUG;AACH,MAAM,MAAM,gBAAgB,GAAG,qBAAqB,CAAC;AAErD;;;;;;;;;;GAUG;AACH,MAAM,MAAM,eAAe,GAAG,qBAAqB,CAAC"}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* A lifecycle event handler. This is called whenever a lifecycle event occurs,
|
|
3
|
+
* such as the Snap being installed or updated.
|
|
4
|
+
*
|
|
5
|
+
* Note that using this handler requires the `endowment:lifecycle-hooks`
|
|
6
|
+
* permission.
|
|
7
|
+
*
|
|
8
|
+
* @param args - The request arguments.
|
|
9
|
+
* @param args.origin - The origin that triggered the lifecycle event hook.
|
|
10
|
+
*/
|
|
11
|
+
export type LifecycleEventHandler = (args: {
|
|
12
|
+
origin: string;
|
|
13
|
+
}) => Promise<unknown>;
|
|
14
|
+
/**
|
|
15
|
+
* The `onInstall` handler. This is called after the Snap is installed.
|
|
16
|
+
*
|
|
17
|
+
* Note that using this handler requires the `endowment:lifecycle-hooks`
|
|
18
|
+
* permission.
|
|
19
|
+
*
|
|
20
|
+
* This type is an alias for {@link LifecycleEventHandler}.
|
|
21
|
+
*
|
|
22
|
+
* @param args - The request arguments.
|
|
23
|
+
* @param args.origin - The origin that triggered the lifecycle event hook.
|
|
24
|
+
*/
|
|
25
|
+
export type OnInstallHandler = LifecycleEventHandler;
|
|
26
|
+
/**
|
|
27
|
+
* The `onUpdate` handler. This is called after the Snap is updated.
|
|
28
|
+
*
|
|
29
|
+
* Note that using this handler requires the `endowment:lifecycle-hooks`
|
|
30
|
+
* permission.
|
|
31
|
+
*
|
|
32
|
+
* This type is an alias for {@link LifecycleEventHandler}.
|
|
33
|
+
*
|
|
34
|
+
* @param args - The request arguments.
|
|
35
|
+
* @param args.origin - The origin that triggered the lifecycle event hook.
|
|
36
|
+
*/
|
|
37
|
+
export type OnUpdateHandler = LifecycleEventHandler;
|
|
38
|
+
//# sourceMappingURL=lifecycle.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"lifecycle.d.mts","sourceRoot":"","sources":["../../../src/types/handlers/lifecycle.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AACH,MAAM,MAAM,qBAAqB,GAAG,CAAC,IAAI,EAAE;IACzC,MAAM,EAAE,MAAM,CAAC;CAChB,KAAK,OAAO,CAAC,OAAO,CAAC,CAAC;AAEvB;;;;;;;;;;GAUG;AACH,MAAM,MAAM,gBAAgB,GAAG,qBAAqB,CAAC;AAErD;;;;;;;;;;GAUG;AACH,MAAM,MAAM,eAAe,GAAG,qBAAqB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"lifecycle.mjs","sourceRoot":"","sources":["../../../src/types/handlers/lifecycle.ts"],"names":[],"mappings":"","sourcesContent":["/**\n * A lifecycle event handler. This is called whenever a lifecycle event occurs,\n * such as the Snap being installed or updated.\n *\n * Note that using this handler requires the `endowment:lifecycle-hooks`\n * permission.\n *\n * @param args - The request arguments.\n * @param args.origin - The origin that triggered the lifecycle event hook.\n */\nexport type LifecycleEventHandler = (args: {\n origin: string;\n}) => Promise<unknown>;\n\n/**\n * The `onInstall` handler. This is called after the Snap is installed.\n *\n * Note that using this handler requires the `endowment:lifecycle-hooks`\n * permission.\n *\n * This type is an alias for {@link LifecycleEventHandler}.\n *\n * @param args - The request arguments.\n * @param args.origin - The origin that triggered the lifecycle event hook.\n */\nexport type OnInstallHandler = LifecycleEventHandler;\n\n/**\n * The `onUpdate` handler. This is called after the Snap is updated.\n *\n * Note that using this handler requires the `endowment:lifecycle-hooks`\n * permission.\n *\n * This type is an alias for {@link LifecycleEventHandler}.\n *\n * @param args - The request arguments.\n * @param args.origin - The origin that triggered the lifecycle event hook.\n */\nexport type OnUpdateHandler = LifecycleEventHandler;\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"name-lookup.cjs","sourceRoot":"","sources":["../../../src/types/handlers/name-lookup.ts"],"names":[],"mappings":"","sourcesContent":["import type { NonEmptyArray } from '@metamask/utils';\n\nimport type { ChainId } from '../caip';\n\ntype BaseOnNameLookupArgs = {\n chainId: ChainId;\n};\n\n/**\n * The arguments for a domain lookup.\n *\n * @property domain - The human-readable domain name that is to be resolved.\n */\nexport type DomainLookupArgs = BaseOnNameLookupArgs & {\n domain: string;\n address?: never;\n};\n\n/**\n * The arguments for an address lookup.\n *\n * @property address - The address that is to be resolved.\n */\nexport type AddressLookupArgs = BaseOnNameLookupArgs & {\n address: string;\n domain?: never;\n};\n\n/**\n * The address resolution object.\n *\n * @property protocol - The protocol that resolved the domain.\n * @property resolvedAddress - The resolved address.\n */\nexport type AddressResolution = {\n protocol: string;\n resolvedAddress: string;\n domainName: string;\n};\n\n/**\n * The domain resolution object.\n *\n * @property protocol - The protocol that resolved the address.\n * @property resolvedDomain - The resolved domain.\n */\nexport type DomainResolution = {\n protocol: string;\n resolvedDomain: string;\n};\n\n/**\n * The result of a domain lookup.\n *\n * @property resolvedAddress - The resolved address.\n */\nexport type DomainLookupResult = {\n resolvedAddresses: NonEmptyArray<AddressResolution>;\n resolvedDomains?: never;\n};\n\n/**\n * The result of an address lookup.\n *\n * @property resolvedDomain - The resolved domain name.\n */\nexport type AddressLookupResult = {\n resolvedDomains: NonEmptyArray<DomainResolution>;\n resolvedAddresses?: never;\n};\n\n/**\n * The `onNameLookup` handler, which is called when MetaMask needs to resolve an\n * address or domain.\n *\n * Note that using this handler requires the `endowment:name-lookup` permission.\n *\n * @param args - The request arguments.\n * @param args.chainId - The CAIP-2 {@link ChainId} of the network the\n * transaction is being submitted to.\n * @param args.domain - The human-readable address that is to be resolved. This\n * is mutually exclusive with `args.address`.\n * @param args.address - The address that is to be resolved. This is mutually\n * exclusive with `args.domain`.\n * @returns The resolved domain or address from the lookup. Must be either\n * {@link AddressLookupResult}, {@link DomainLookupResult}, or `null` if the\n * address or domain could not be resolved.\n */\nexport type OnNameLookupHandler = (\n args: AddressLookupArgs | DomainLookupArgs,\n) => Promise<AddressLookupResult | DomainLookupResult | null>;\n"]}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { NonEmptyArray } from
|
|
2
|
-
import type { ChainId } from
|
|
1
|
+
import type { NonEmptyArray } from "@metamask/utils";
|
|
2
|
+
import type { ChainId } from "../caip.cjs";
|
|
3
3
|
type BaseOnNameLookupArgs = {
|
|
4
4
|
chainId: ChainId;
|
|
5
5
|
};
|
|
@@ -79,3 +79,4 @@ export type AddressLookupResult = {
|
|
|
79
79
|
*/
|
|
80
80
|
export type OnNameLookupHandler = (args: AddressLookupArgs | DomainLookupArgs) => Promise<AddressLookupResult | DomainLookupResult | null>;
|
|
81
81
|
export {};
|
|
82
|
+
//# sourceMappingURL=name-lookup.d.cts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"name-lookup.d.cts","sourceRoot":"","sources":["../../../src/types/handlers/name-lookup.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,wBAAwB;AAErD,OAAO,KAAK,EAAE,OAAO,EAAE,oBAAgB;AAEvC,KAAK,oBAAoB,GAAG;IAC1B,OAAO,EAAE,OAAO,CAAC;CAClB,CAAC;AAEF;;;;GAIG;AACH,MAAM,MAAM,gBAAgB,GAAG,oBAAoB,GAAG;IACpD,MAAM,EAAE,MAAM,CAAC;IACf,OAAO,CAAC,EAAE,KAAK,CAAC;CACjB,CAAC;AAEF;;;;GAIG;AACH,MAAM,MAAM,iBAAiB,GAAG,oBAAoB,GAAG;IACrD,OAAO,EAAE,MAAM,CAAC;IAChB,MAAM,CAAC,EAAE,KAAK,CAAC;CAChB,CAAC;AAEF;;;;;GAKG;AACH,MAAM,MAAM,iBAAiB,GAAG;IAC9B,QAAQ,EAAE,MAAM,CAAC;IACjB,eAAe,EAAE,MAAM,CAAC;IACxB,UAAU,EAAE,MAAM,CAAC;CACpB,CAAC;AAEF;;;;;GAKG;AACH,MAAM,MAAM,gBAAgB,GAAG;IAC7B,QAAQ,EAAE,MAAM,CAAC;IACjB,cAAc,EAAE,MAAM,CAAC;CACxB,CAAC;AAEF;;;;GAIG;AACH,MAAM,MAAM,kBAAkB,GAAG;IAC/B,iBAAiB,EAAE,aAAa,CAAC,iBAAiB,CAAC,CAAC;IACpD,eAAe,CAAC,EAAE,KAAK,CAAC;CACzB,CAAC;AAEF;;;;GAIG;AACH,MAAM,MAAM,mBAAmB,GAAG;IAChC,eAAe,EAAE,aAAa,CAAC,gBAAgB,CAAC,CAAC;IACjD,iBAAiB,CAAC,EAAE,KAAK,CAAC;CAC3B,CAAC;AAEF;;;;;;;;;;;;;;;;GAgBG;AACH,MAAM,MAAM,mBAAmB,GAAG,CAChC,IAAI,EAAE,iBAAiB,GAAG,gBAAgB,KACvC,OAAO,CAAC,mBAAmB,GAAG,kBAAkB,GAAG,IAAI,CAAC,CAAC"}
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
import type { NonEmptyArray } from "@metamask/utils";
|
|
2
|
+
import type { ChainId } from "../caip.mjs";
|
|
3
|
+
type BaseOnNameLookupArgs = {
|
|
4
|
+
chainId: ChainId;
|
|
5
|
+
};
|
|
6
|
+
/**
|
|
7
|
+
* The arguments for a domain lookup.
|
|
8
|
+
*
|
|
9
|
+
* @property domain - The human-readable domain name that is to be resolved.
|
|
10
|
+
*/
|
|
11
|
+
export type DomainLookupArgs = BaseOnNameLookupArgs & {
|
|
12
|
+
domain: string;
|
|
13
|
+
address?: never;
|
|
14
|
+
};
|
|
15
|
+
/**
|
|
16
|
+
* The arguments for an address lookup.
|
|
17
|
+
*
|
|
18
|
+
* @property address - The address that is to be resolved.
|
|
19
|
+
*/
|
|
20
|
+
export type AddressLookupArgs = BaseOnNameLookupArgs & {
|
|
21
|
+
address: string;
|
|
22
|
+
domain?: never;
|
|
23
|
+
};
|
|
24
|
+
/**
|
|
25
|
+
* The address resolution object.
|
|
26
|
+
*
|
|
27
|
+
* @property protocol - The protocol that resolved the domain.
|
|
28
|
+
* @property resolvedAddress - The resolved address.
|
|
29
|
+
*/
|
|
30
|
+
export type AddressResolution = {
|
|
31
|
+
protocol: string;
|
|
32
|
+
resolvedAddress: string;
|
|
33
|
+
domainName: string;
|
|
34
|
+
};
|
|
35
|
+
/**
|
|
36
|
+
* The domain resolution object.
|
|
37
|
+
*
|
|
38
|
+
* @property protocol - The protocol that resolved the address.
|
|
39
|
+
* @property resolvedDomain - The resolved domain.
|
|
40
|
+
*/
|
|
41
|
+
export type DomainResolution = {
|
|
42
|
+
protocol: string;
|
|
43
|
+
resolvedDomain: string;
|
|
44
|
+
};
|
|
45
|
+
/**
|
|
46
|
+
* The result of a domain lookup.
|
|
47
|
+
*
|
|
48
|
+
* @property resolvedAddress - The resolved address.
|
|
49
|
+
*/
|
|
50
|
+
export type DomainLookupResult = {
|
|
51
|
+
resolvedAddresses: NonEmptyArray<AddressResolution>;
|
|
52
|
+
resolvedDomains?: never;
|
|
53
|
+
};
|
|
54
|
+
/**
|
|
55
|
+
* The result of an address lookup.
|
|
56
|
+
*
|
|
57
|
+
* @property resolvedDomain - The resolved domain name.
|
|
58
|
+
*/
|
|
59
|
+
export type AddressLookupResult = {
|
|
60
|
+
resolvedDomains: NonEmptyArray<DomainResolution>;
|
|
61
|
+
resolvedAddresses?: never;
|
|
62
|
+
};
|
|
63
|
+
/**
|
|
64
|
+
* The `onNameLookup` handler, which is called when MetaMask needs to resolve an
|
|
65
|
+
* address or domain.
|
|
66
|
+
*
|
|
67
|
+
* Note that using this handler requires the `endowment:name-lookup` permission.
|
|
68
|
+
*
|
|
69
|
+
* @param args - The request arguments.
|
|
70
|
+
* @param args.chainId - The CAIP-2 {@link ChainId} of the network the
|
|
71
|
+
* transaction is being submitted to.
|
|
72
|
+
* @param args.domain - The human-readable address that is to be resolved. This
|
|
73
|
+
* is mutually exclusive with `args.address`.
|
|
74
|
+
* @param args.address - The address that is to be resolved. This is mutually
|
|
75
|
+
* exclusive with `args.domain`.
|
|
76
|
+
* @returns The resolved domain or address from the lookup. Must be either
|
|
77
|
+
* {@link AddressLookupResult}, {@link DomainLookupResult}, or `null` if the
|
|
78
|
+
* address or domain could not be resolved.
|
|
79
|
+
*/
|
|
80
|
+
export type OnNameLookupHandler = (args: AddressLookupArgs | DomainLookupArgs) => Promise<AddressLookupResult | DomainLookupResult | null>;
|
|
81
|
+
export {};
|
|
82
|
+
//# sourceMappingURL=name-lookup.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"name-lookup.d.mts","sourceRoot":"","sources":["../../../src/types/handlers/name-lookup.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,wBAAwB;AAErD,OAAO,KAAK,EAAE,OAAO,EAAE,oBAAgB;AAEvC,KAAK,oBAAoB,GAAG;IAC1B,OAAO,EAAE,OAAO,CAAC;CAClB,CAAC;AAEF;;;;GAIG;AACH,MAAM,MAAM,gBAAgB,GAAG,oBAAoB,GAAG;IACpD,MAAM,EAAE,MAAM,CAAC;IACf,OAAO,CAAC,EAAE,KAAK,CAAC;CACjB,CAAC;AAEF;;;;GAIG;AACH,MAAM,MAAM,iBAAiB,GAAG,oBAAoB,GAAG;IACrD,OAAO,EAAE,MAAM,CAAC;IAChB,MAAM,CAAC,EAAE,KAAK,CAAC;CAChB,CAAC;AAEF;;;;;GAKG;AACH,MAAM,MAAM,iBAAiB,GAAG;IAC9B,QAAQ,EAAE,MAAM,CAAC;IACjB,eAAe,EAAE,MAAM,CAAC;IACxB,UAAU,EAAE,MAAM,CAAC;CACpB,CAAC;AAEF;;;;;GAKG;AACH,MAAM,MAAM,gBAAgB,GAAG;IAC7B,QAAQ,EAAE,MAAM,CAAC;IACjB,cAAc,EAAE,MAAM,CAAC;CACxB,CAAC;AAEF;;;;GAIG;AACH,MAAM,MAAM,kBAAkB,GAAG;IAC/B,iBAAiB,EAAE,aAAa,CAAC,iBAAiB,CAAC,CAAC;IACpD,eAAe,CAAC,EAAE,KAAK,CAAC;CACzB,CAAC;AAEF;;;;GAIG;AACH,MAAM,MAAM,mBAAmB,GAAG;IAChC,eAAe,EAAE,aAAa,CAAC,gBAAgB,CAAC,CAAC;IACjD,iBAAiB,CAAC,EAAE,KAAK,CAAC;CAC3B,CAAC;AAEF;;;;;;;;;;;;;;;;GAgBG;AACH,MAAM,MAAM,mBAAmB,GAAG,CAChC,IAAI,EAAE,iBAAiB,GAAG,gBAAgB,KACvC,OAAO,CAAC,mBAAmB,GAAG,kBAAkB,GAAG,IAAI,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"name-lookup.mjs","sourceRoot":"","sources":["../../../src/types/handlers/name-lookup.ts"],"names":[],"mappings":"","sourcesContent":["import type { NonEmptyArray } from '@metamask/utils';\n\nimport type { ChainId } from '../caip';\n\ntype BaseOnNameLookupArgs = {\n chainId: ChainId;\n};\n\n/**\n * The arguments for a domain lookup.\n *\n * @property domain - The human-readable domain name that is to be resolved.\n */\nexport type DomainLookupArgs = BaseOnNameLookupArgs & {\n domain: string;\n address?: never;\n};\n\n/**\n * The arguments for an address lookup.\n *\n * @property address - The address that is to be resolved.\n */\nexport type AddressLookupArgs = BaseOnNameLookupArgs & {\n address: string;\n domain?: never;\n};\n\n/**\n * The address resolution object.\n *\n * @property protocol - The protocol that resolved the domain.\n * @property resolvedAddress - The resolved address.\n */\nexport type AddressResolution = {\n protocol: string;\n resolvedAddress: string;\n domainName: string;\n};\n\n/**\n * The domain resolution object.\n *\n * @property protocol - The protocol that resolved the address.\n * @property resolvedDomain - The resolved domain.\n */\nexport type DomainResolution = {\n protocol: string;\n resolvedDomain: string;\n};\n\n/**\n * The result of a domain lookup.\n *\n * @property resolvedAddress - The resolved address.\n */\nexport type DomainLookupResult = {\n resolvedAddresses: NonEmptyArray<AddressResolution>;\n resolvedDomains?: never;\n};\n\n/**\n * The result of an address lookup.\n *\n * @property resolvedDomain - The resolved domain name.\n */\nexport type AddressLookupResult = {\n resolvedDomains: NonEmptyArray<DomainResolution>;\n resolvedAddresses?: never;\n};\n\n/**\n * The `onNameLookup` handler, which is called when MetaMask needs to resolve an\n * address or domain.\n *\n * Note that using this handler requires the `endowment:name-lookup` permission.\n *\n * @param args - The request arguments.\n * @param args.chainId - The CAIP-2 {@link ChainId} of the network the\n * transaction is being submitted to.\n * @param args.domain - The human-readable address that is to be resolved. This\n * is mutually exclusive with `args.address`.\n * @param args.address - The address that is to be resolved. This is mutually\n * exclusive with `args.domain`.\n * @returns The resolved domain or address from the lookup. Must be either\n * {@link AddressLookupResult}, {@link DomainLookupResult}, or `null` if the\n * address or domain could not be resolved.\n */\nexport type OnNameLookupHandler = (\n args: AddressLookupArgs | DomainLookupArgs,\n) => Promise<AddressLookupResult | DomainLookupResult | null>;\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"rpc-request.cjs","sourceRoot":"","sources":["../../../src/types/handlers/rpc-request.ts"],"names":[],"mappings":"","sourcesContent":["import type { Json, JsonRpcParams, JsonRpcRequest } from '@metamask/utils';\n\n/**\n * The `onRpcRequest` handler, which is called when a Snap receives a JSON-RPC\n * request. This can be called from another Snap, or from a website, depending\n * on the Snap's `endowment:rpc` permission.\n *\n * Note that using this handler requires the `endowment:rpc` permission.\n *\n * @param args - The request arguments.\n * @param args.origin - The origin of the request. This can be the ID of another\n * Snap, or the URL of a website.\n * @param args.request - The JSON-RPC request sent to the snap. This includes\n * the method name and parameters.\n * @returns The response to the JSON-RPC request. This must be a\n * JSON-serializable value. In order to return an error, throw a `SnapError`\n * instead.\n */\nexport type OnRpcRequestHandler<Params extends JsonRpcParams = JsonRpcParams> =\n (args: { origin: string; request: JsonRpcRequest<Params> }) => Promise<Json>;\n"]}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { Json, JsonRpcParams, JsonRpcRequest } from
|
|
1
|
+
import type { Json, JsonRpcParams, JsonRpcRequest } from "@metamask/utils";
|
|
2
2
|
/**
|
|
3
3
|
* The `onRpcRequest` handler, which is called when a Snap receives a JSON-RPC
|
|
4
4
|
* request. This can be called from another Snap, or from a website, depending
|
|
@@ -19,3 +19,4 @@ export type OnRpcRequestHandler<Params extends JsonRpcParams = JsonRpcParams> =
|
|
|
19
19
|
origin: string;
|
|
20
20
|
request: JsonRpcRequest<Params>;
|
|
21
21
|
}) => Promise<Json>;
|
|
22
|
+
//# sourceMappingURL=rpc-request.d.cts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"rpc-request.d.cts","sourceRoot":"","sources":["../../../src/types/handlers/rpc-request.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,aAAa,EAAE,cAAc,EAAE,wBAAwB;AAE3E;;;;;;;;;;;;;;;GAeG;AACH,MAAM,MAAM,mBAAmB,CAAC,MAAM,SAAS,aAAa,GAAG,aAAa,IAC1E,CAAC,IAAI,EAAE;IAAE,MAAM,EAAE,MAAM,CAAC;IAAC,OAAO,EAAE,cAAc,CAAC,MAAM,CAAC,CAAA;CAAE,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import type { Json, JsonRpcParams, JsonRpcRequest } from "@metamask/utils";
|
|
2
|
+
/**
|
|
3
|
+
* The `onRpcRequest` handler, which is called when a Snap receives a JSON-RPC
|
|
4
|
+
* request. This can be called from another Snap, or from a website, depending
|
|
5
|
+
* on the Snap's `endowment:rpc` permission.
|
|
6
|
+
*
|
|
7
|
+
* Note that using this handler requires the `endowment:rpc` permission.
|
|
8
|
+
*
|
|
9
|
+
* @param args - The request arguments.
|
|
10
|
+
* @param args.origin - The origin of the request. This can be the ID of another
|
|
11
|
+
* Snap, or the URL of a website.
|
|
12
|
+
* @param args.request - The JSON-RPC request sent to the snap. This includes
|
|
13
|
+
* the method name and parameters.
|
|
14
|
+
* @returns The response to the JSON-RPC request. This must be a
|
|
15
|
+
* JSON-serializable value. In order to return an error, throw a `SnapError`
|
|
16
|
+
* instead.
|
|
17
|
+
*/
|
|
18
|
+
export type OnRpcRequestHandler<Params extends JsonRpcParams = JsonRpcParams> = (args: {
|
|
19
|
+
origin: string;
|
|
20
|
+
request: JsonRpcRequest<Params>;
|
|
21
|
+
}) => Promise<Json>;
|
|
22
|
+
//# sourceMappingURL=rpc-request.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"rpc-request.d.mts","sourceRoot":"","sources":["../../../src/types/handlers/rpc-request.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,aAAa,EAAE,cAAc,EAAE,wBAAwB;AAE3E;;;;;;;;;;;;;;;GAeG;AACH,MAAM,MAAM,mBAAmB,CAAC,MAAM,SAAS,aAAa,GAAG,aAAa,IAC1E,CAAC,IAAI,EAAE;IAAE,MAAM,EAAE,MAAM,CAAC;IAAC,OAAO,EAAE,cAAc,CAAC,MAAM,CAAC,CAAA;CAAE,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"rpc-request.mjs","sourceRoot":"","sources":["../../../src/types/handlers/rpc-request.ts"],"names":[],"mappings":"","sourcesContent":["import type { Json, JsonRpcParams, JsonRpcRequest } from '@metamask/utils';\n\n/**\n * The `onRpcRequest` handler, which is called when a Snap receives a JSON-RPC\n * request. This can be called from another Snap, or from a website, depending\n * on the Snap's `endowment:rpc` permission.\n *\n * Note that using this handler requires the `endowment:rpc` permission.\n *\n * @param args - The request arguments.\n * @param args.origin - The origin of the request. This can be the ID of another\n * Snap, or the URL of a website.\n * @param args.request - The JSON-RPC request sent to the snap. This includes\n * the method name and parameters.\n * @returns The response to the JSON-RPC request. This must be a\n * JSON-serializable value. In order to return an error, throw a `SnapError`\n * instead.\n */\nexport type OnRpcRequestHandler<Params extends JsonRpcParams = JsonRpcParams> =\n (args: { origin: string; request: JsonRpcRequest<Params> }) => Promise<Json>;\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"signature.cjs","sourceRoot":"","sources":["../../../src/types/handlers/signature.ts"],"names":[],"mappings":"","sourcesContent":["import type { EnumToUnion } from '../../internals';\nimport type { Component } from '../../ui';\nimport type { SeverityLevel } from './transaction';\n\n/**\n * An eth_sign signature object.\n *\n * @property from - The address the signature is being sent from.\n * @property data - The data (hex string) that is being signed.\n * @property signatureMethod - The signature method, which in this case is eth_sign\n */\nexport type EthSignature = {\n from: string;\n data: string;\n signatureMethod: 'eth_sign';\n};\n\n/**\n * A personal_sign signature object.\n *\n * @property from - The address the signature is being sent from.\n * @property data - The data (hex string) that is being signed.\n * @property signatureMethod - The signature method, which in this case is personal_sign\n */\nexport type PersonalSignature = {\n from: string;\n data: string;\n signatureMethod: 'personal_sign';\n};\n\n/**\n * An eth_signTypedData signature object.\n *\n * @property from - The address the signature is being sent from.\n * @property data - The data that is being signed.\n * @property signatureMethod - The signature method, which in this case is eth_signTypedData\n */\nexport type SignTypedDataSignature = {\n from: string;\n data: Record<string, any>[];\n signatureMethod: 'eth_signTypedData';\n};\n\n/**\n * An eth_signTypedData_v3 signature object.\n *\n * @property from - The address the signature is being sent from.\n * @property data - The data that is being signed.\n * @property signatureMethod - The signature method, which in this case is eth_signTypedData_v3\n */\nexport type SignTypedDataV3Signature = {\n from: string;\n data: Record<string, any>;\n signatureMethod: 'eth_signTypedData_v3';\n};\n\n/**\n * An eth_signTypedData_v4 signature object.\n *\n * @property from - The address the signature is being sent from.\n * @property data - The data that is being signed.\n * @property signatureMethod - The signature method, which in this case is eth_signTypedData_v4\n */\nexport type SignTypedDataV4Signature = {\n from: string;\n data: Record<string, any>;\n signatureMethod: 'eth_signTypedData_v4';\n};\n\n/**\n * A signature object. This can be one of the below signature methods.\n *\n * @see EthSignature\n * @see PersonalSignature\n * @see SignTypedDataSignature\n * @see SignTypedDataV3Signature\n * @see SignTypedDataV4Signature\n */\nexport type Signature =\n | EthSignature\n | PersonalSignature\n | SignTypedDataSignature\n | SignTypedDataV3Signature\n | SignTypedDataV4Signature;\n\n/**\n * The `onSignature` handler. This is called whenever a signature is\n * submitted to the snap. It can return insights about the signature, which\n * will be displayed to the user.\n *\n * Note that using this handler requires the `endowment:signature-insight`\n * permission.\n *\n * @param args - The request arguments.\n * @param args.signature - The signature object that contains the from address,\n * data and signature method.\n * @param args.signatureOrigin - The origin of the signature. This is the\n * URL of the website that submitted the signature. This is only available if\n * the Snap has enabled the `allowSignatureOrigin` option in the\n * `endowment:signature-insight` permission.\n * @returns An object containing insights about the signature. See\n * {@link OnSignatureResponse}. Can also return `null` if no insights are\n * available.\n */\nexport type OnSignatureHandler = (args: {\n signature: Signature;\n signatureOrigin?: string;\n}) => Promise<OnSignatureResponse | null>;\n\n/**\n * The response from a Snap's `onSignature` handler.\n *\n * @property component - A custom UI component, that will be shown in MetaMask.\n * @property id - A Snap interface ID.\n * @property severity - The severity level of the content. Currently only one\n * level is supported: `critical`.\n */\nexport type OnSignatureResponse =\n | {\n content: Component;\n severity?: EnumToUnion<SeverityLevel>;\n }\n | {\n id: string;\n severity?: EnumToUnion<SeverityLevel>;\n };\n"]}
|