Skip to content
This repository has been archived by the owner on Dec 1, 2024. It is now read-only.

Commit

Permalink
v2.2.2: upgrade dependencies and fix polygon rpc
Browse files Browse the repository at this point in the history
  • Loading branch information
0xNe0x1 committed Feb 15, 2024
1 parent 6d3cc55 commit 504b8e6
Show file tree
Hide file tree
Showing 8 changed files with 56 additions and 27 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,6 @@ https://web3wordpress.xyz/
In order to release the plugins simply push a git tag:

```
git tag v2.2.1
git push origin v2.2.1
git tag v2.2.2
git push origin v2.2.2
```
2 changes: 1 addition & 1 deletion block.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"category": "widgets",
"description": "Web3 donations directly into your own wallet. A Block-enabled WordPress plugin for P2P crypto donations with on-the-fly conversion.",
"keywords": [ "donations", "cryptocurrency", "p2p", "web3", "depay" ],
"version": "2.2.1",
"version": "2.2.2",
"textdomain": "depay-donations",
"example": {},
"editorScript": "depay-donations-script",
Expand Down
6 changes: 3 additions & 3 deletions core/includes/assets/js/blockchains.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

35 changes: 30 additions & 5 deletions core/includes/assets/js/buttons.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,20 @@
var DePayWidgets__default = /*#__PURE__*/_interopDefaultLegacy(DePayWidgets);
var m__default = /*#__PURE__*/_interopDefaultLegacy(m);

function _defineProperty(obj, key, value) {
if (key in obj) {
Object.defineProperty(obj, key, {
value: value,
enumerable: true,
configurable: true,
writable: true
});
} else {
obj[key] = value;
}
return obj;
}

function _arrayLikeToArray(arr, len) {
if (len == null || len > arr.length) len = arr.length;
for (var i = 0, arr2 = new Array(len); i < len; i++) {
Expand Down Expand Up @@ -45,11 +59,15 @@
}

var Button = (function (props) {
var blockchains = props.blockchains ? JSON.parse(props.blockchains).map(function (name) {
var _props$configuration, _props$configuration2;

var blockchains = typeof props.blockchains === 'string' ? JSON.parse(props.blockchains).map(function (name) {
return Blockchains__default['default'][name];
}) : [];
}) : (props.blockchains || []).map(function (name) {
return Blockchains__default['default'][name];
});

if (!blockchains || blockchains.length === 0) {
if ((!blockchains || blockchains.length === 0) && (props !== null && props !== void 0 && (_props$configuration = props.configuration) !== null && _props$configuration !== void 0 && _props$configuration.accept || props !== null && props !== void 0 && (_props$configuration2 = props.configuration) !== null && _props$configuration2 !== void 0 && _props$configuration2.sell)) {
switch (props.widget) {
case 'Payment':
case 'Donation':
Expand Down Expand Up @@ -92,6 +110,9 @@

var outsideStyle = "\n text-align: center;\n";

function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }

function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
var DePayButton = (function (props) {
var element = React.useRef(null);
var widget = props.widget ? props.widget : 'Payment';
Expand All @@ -107,7 +128,8 @@
label: label,
onClick: onclickHandler,
widget: widget,
configuration: props.configuration
configuration: props.configuration || {},
blockchains: props.blockchains
}),
outsideStyle: outsideStyle,
insideStyle: insideStyle + " " + props.css
Expand All @@ -122,7 +144,10 @@
}, [element, props]);

var onclickHandler = function onclickHandler() {
DePayWidgets__default['default'][widget](props.configuration);
DePayWidgets__default['default'][widget](_objectSpread(_objectSpread({}, props.configuration), {}, {
integration: props.integration,
payload: props.payload
}));
};

return /*#__PURE__*/React__default['default'].createElement("div", {
Expand Down
24 changes: 12 additions & 12 deletions core/includes/assets/js/widgets.bundle.js

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions depay-donations.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
* Plugin Name: DePay Donations
* Plugin URI: https://depay.com/plugins/wordpress
* Description: Web3 donations directly into your own wallet. Block-enabled Wordpress plugin for P2P cryptocurrency donations on multiple blockchains, with on-the-fly token conversion.
* Version: 2.2.1
* Version: 2.2.2
* License: GPL-2.0+
* License URI: http://www.gnu.org/licenses/gpl-2.0.txt
* Author: DePay
Expand All @@ -29,7 +29,7 @@
define( 'DEPAYDONATIONS_NAME', 'DePay Donations' );

// Plugin version
define( 'DEPAYDONATIONS_VERSION', '2.2.1' );
define( 'DEPAYDONATIONS_VERSION', '2.2.2' );

// Plugin Root File
define( 'DEPAYDONATIONS_PLUGIN_FILE', __FILE__ );
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@depay/web3-wordpress-depay-donations",
"moduleName": "WordpressDePayDonations",
"version": "2.2.1",
"version": "2.2.2",
"description": "Web3 donations directly into your own wallet. A Block-enabled WordPress plugin for P2P cryptocurrency donations on multiple blockchains.",
"main": "./dist/umd/index.js",
"module": "./dist/esm/index.js",
Expand Down
6 changes: 5 additions & 1 deletion readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Contributors: depayfi
Tags: donations, cryptocurrency, p2p, web3, depay
Requires at least: 5.0
Tested up to: 6.4
Stable tag: 2.2.1
Stable tag: 2.2.2
Requires PHP: 5.6
License: GPLv2
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Expand Down Expand Up @@ -90,6 +90,10 @@ Building on the idea that "Web3" is the next generation of a blockchain-based an

== Changelog ==

= 2.2.2 =
* upgrade dependencies
* fix polygon rpc

= 2.2.1 =
* upgrade widgets

Expand Down

0 comments on commit 504b8e6

Please sign in to comment.