Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@metamask/approval-controller

Package Overview
Dependencies
Maintainers
12
Versions
32
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@metamask/approval-controller - npm Package Compare versions

Comparing version 5.0.0 to 5.1.0

7

CHANGELOG.md

@@ -9,2 +9,6 @@ # Changelog

## [5.1.0]
### Added
- Add `title` and `icon` options to `success` and `error` methods ([#3675](https://github.com/MetaMask/core/pull/3675))
## [5.0.0]

@@ -101,3 +105,4 @@ ### Changed

[Unreleased]: https://github.com/MetaMask/core/compare/@metamask/approval-controller@5.0.0...HEAD
[Unreleased]: https://github.com/MetaMask/core/compare/@metamask/approval-controller@5.1.0...HEAD
[5.1.0]: https://github.com/MetaMask/core/compare/@metamask/approval-controller@5.0.0...@metamask/approval-controller@5.1.0
[5.0.0]: https://github.com/MetaMask/core/compare/@metamask/approval-controller@4.1.0...@metamask/approval-controller@5.0.0

@@ -104,0 +109,0 @@ [4.1.0]: https://github.com/MetaMask/core/compare/@metamask/approval-controller@4.0.1...@metamask/approval-controller@4.1.0

@@ -18,2 +18,4 @@ import type { ControllerGetStateAction } from '@metamask/base-controller';

header?: (string | ResultComponent)[];
icon?: string | null;
title?: string | null;
};

@@ -418,2 +420,4 @@ export declare type ApprovalRequest<RequestData extends ApprovalRequestData> = {

* @param opts.flowToEnd - The ID of the approval flow to end once the success page is approved.
* @param opts.title - The title to display above the message. Shown by default but can be hidden with `null`.
* @param opts.icon - The icon to display in the page. Shown by default but can be hidden with `null`.
* @returns Empty object to support future additions.

@@ -429,2 +433,4 @@ */

* @param opts.flowToEnd - The ID of the approval flow to end once the error page is approved.
* @param opts.title - The title to display above the message. Shown by default but can be hidden with `null`.
* @param opts.icon - The icon to display in the page. Shown by default but can be hidden with `null`.
* @returns Empty object to support future additions.

@@ -431,0 +437,0 @@ */

10

dist/ApprovalController.js

@@ -288,3 +288,2 @@ "use strict";

this.update((draftState) => {
// Typecast: ts(2589)
draftState.pendingApprovals[opts.id].requestState =

@@ -357,2 +356,4 @@ opts.requestState;

* @param opts.flowToEnd - The ID of the approval flow to end once the success page is approved.
* @param opts.title - The title to display above the message. Shown by default but can be hidden with `null`.
* @param opts.icon - The icon to display in the page. Shown by default but can be hidden with `null`.
* @returns Empty object to support future additions.

@@ -365,2 +366,4 @@ */

header: opts.header,
title: opts.title,
icon: opts.icon,
});

@@ -377,2 +380,4 @@ return {};

* @param opts.flowToEnd - The ID of the approval flow to end once the error page is approved.
* @param opts.title - The title to display above the message. Shown by default but can be hidden with `null`.
* @param opts.icon - The icon to display in the page. Shown by default but can be hidden with `null`.
* @returns Empty object to support future additions.

@@ -385,2 +390,4 @@ */

header: opts.header,
title: opts.title,
icon: opts.icon,
});

@@ -448,3 +455,2 @@ return {};

this.update((draftState) => {
// Typecast: ts(2589)
draftState.pendingApprovals[id] = approval;

@@ -451,0 +457,0 @@ draftState.pendingApprovalCount = Object.keys(draftState.pendingApprovals).length;

{
"name": "@metamask/approval-controller",
"version": "5.0.0",
"version": "5.1.0",
"description": "Manages requests that require user approval",

@@ -5,0 +5,0 @@ "keywords": [

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc