@magic-ext/harmony 2.0.0 → 3.1.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 CHANGED
@@ -1,3 +1,51 @@
1
+ # v3.1.0 (Mon Mar 07 2022)
2
+
3
+ #### 🐛 Bug Fix
4
+
5
+ - Update READMEs with outdated context/hyperlinks ([@smithki](https://github.com/smithki))
6
+
7
+ #### 🏠 Internal
8
+
9
+ - Internal documentation updates (`BUILD_SYSTEM.md`) [#283](https://github.com/magiclabs/magic-js/pull/283) ([@smithki](https://github.com/smithki))
10
+
11
+ #### Authors: 1
12
+
13
+ - Ian K Smith ([@smithki](https://github.com/smithki))
14
+
15
+ ---
16
+
17
+ # v3.0.1 (Tue Jan 25 2022)
18
+
19
+ #### 🐛 Bug Fix
20
+
21
+ - Fix CDN build targets [#270](https://github.com/magiclabs/magic-js/pull/270) ([@smithki](https://github.com/smithki))
22
+ - Fix CDN issues related to ESBuild ([@smithki](https://github.com/smithki))
23
+
24
+ #### Authors: 1
25
+
26
+ - Ian K Smith ([@smithki](https://github.com/smithki))
27
+
28
+ ---
29
+
30
+ # v3.0.0 (Tue Jan 25 2022)
31
+
32
+ #### 💥 Breaking Change
33
+
34
+ - Switch from `microbundle` to `esbuild` [#220](https://github.com/magiclabs/magic-js/pull/220) ([@smithki](https://github.com/smithki))
35
+
36
+ #### 🐛 Bug Fix
37
+
38
+ - Merge with master ([@smithki](https://github.com/smithki))
39
+ - Merge branch 'master' into feat/faster-builds ([@smithki](https://github.com/smithki))
40
+ - Modify CDN default exports ([@smithki](https://github.com/smithki))
41
+ - Support newly added Magic JS extensions in ESBuild ([@smithki](https://github.com/smithki))
42
+
43
+ #### Authors: 1
44
+
45
+ - Ian K Smith ([@smithki](https://github.com/smithki))
46
+
47
+ ---
48
+
1
49
  # v1.0.0 (Thu Dec 09 2021)
2
50
 
3
51
  #### 💥 Breaking Change
package/README.md CHANGED
@@ -32,7 +32,7 @@ const magic = new Magic('YOUR_API_KEY', {
32
32
  ```
33
33
 
34
34
  ## Magic SDK
35
- See the [developer documentation](https://docs.magic.link) to learn how you can master the Magic SDK in a matter of minutes.
35
+ See the [developer documentation](https://magic.link/docs) to learn how you can master the Magic SDK in a matter of minutes.
36
36
 
37
37
 
38
38
  ## Usage
@@ -64,7 +64,7 @@ By passing transaction payload to `magic.harmony.sendTransaction()` method, it w
64
64
  ### Deploy Contract
65
65
  By passing deploy contract payload to `magic.harmony.sendTransaction()` method, it will automatically sign the transaction with current user and
66
66
  generate transaction object including signature, then send to Harmony node.
67
-
67
+
68
68
  ```js
69
69
  const bin = '608060405234801561001057600080fd5b5060c68061001f6000396000f3fe6080604052348015600f576000' +
70
70
  '80fd5b506004361060325760003560e01c80636057361d146037578063b05784b8146062575b600080fd5b6060600480' +
package/dist/cjs/index.js CHANGED
@@ -1,2 +1,2 @@
1
- var n,r=require("@magic-sdk/commons");function t(n,r){return(t=Object.setPrototypeOf||function(n,r){return n.__proto__=r,n})(n,r)}!function(n){n.HarmonySignTransaction="hmy_sendTransaction"}(n||(n={})),exports.HarmonyExtension=function(r){var o,e;function i(n){var t;return(t=r.call(this)||this).harmonyConfig=void 0,t.name="harmony",t.config={},t.harmonyConfig=n,t.config={rpcUrl:n.rpcUrl,chainType:"HARMONY",options:{chainId:n.chainId}},t}return e=r,(o=i).prototype=Object.create(e.prototype),o.prototype.constructor=o,t(o,e),i.prototype.sendTransaction=function(r){try{return Promise.resolve(this.request(this.utils.createJsonRpcRequestPayload(n.HarmonySignTransaction,r)))}catch(n){return Promise.reject(n)}},i}(r.Extension.Internal);
1
+ var e=Object.defineProperty;var l=Object.getOwnPropertyDescriptor;var u=Object.getOwnPropertyNames;var d=Object.prototype.hasOwnProperty;var f=r=>e(r,"__esModule",{value:!0});var H=(r,n)=>{for(var a in n)e(r,a,{get:n[a],enumerable:!0})},T=(r,n,a,t)=>{if(n&&typeof n=="object"||typeof n=="function")for(let i of u(n))!d.call(r,i)&&(a||i!=="default")&&e(r,i,{get:()=>n[i],enumerable:!(t=l(n,i))||t.enumerable});return r};var x=(r=>(n,a)=>r&&r.get(n)||(a=T(f({}),n,1),r&&r.set(n,a),a))(typeof WeakMap!="undefined"?new WeakMap:0);var p=(r,n,a)=>new Promise((t,i)=>{var h=o=>{try{s(a.next(o))}catch(c){i(c)}},g=o=>{try{s(a.throw(o))}catch(c){i(c)}},s=o=>o.done?t(o.value):Promise.resolve(o.value).then(h,g);s((a=a.apply(r,n)).next())});var I={};H(I,{HarmonyExtension:()=>m});var y=require("@magic-sdk/commons");var m=class extends y.Extension.Internal{constructor(n){super();this.harmonyConfig=n;this.name="harmony";this.config={};this.config={rpcUrl:n.rpcUrl,chainType:"HARMONY",options:{chainId:n.chainId}}}sendTransaction(n){return p(this,null,function*(){return this.request(this.utils.createJsonRpcRequestPayload("hmy_sendTransaction",n))})}};module.exports=x(I);
2
2
  //# sourceMappingURL=index.js.map
@@ -1 +1,7 @@
1
- {"version":3,"file":"index.js","sources":["../../src/types.ts","../../src/index.ts"],"sourcesContent":["export enum HarmonyPayloadMethod {\n HarmonySignTransaction = 'hmy_sendTransaction',\n}\n\nexport interface HarmonyConfig {\n rpcUrl: string;\n chainId: string;\n chainType: string;\n}\n","import { Extension } from '@magic-sdk/commons';\nimport { HarmonyPayloadMethod, HarmonyConfig } from './types';\n\nexport class HarmonyExtension extends Extension.Internal<'harmony', any> {\n name = 'harmony' as const;\n config: any = {};\n\n constructor(public harmonyConfig: HarmonyConfig) {\n super();\n\n this.config = {\n rpcUrl: harmonyConfig.rpcUrl,\n chainType: 'HARMONY',\n options: {\n chainId: harmonyConfig.chainId,\n },\n };\n }\n\n public async sendTransaction(params: any) {\n return this.request(this.utils.createJsonRpcRequestPayload(HarmonyPayloadMethod.HarmonySignTransaction, params));\n }\n}\n"],"names":["HarmonyPayloadMethod","harmonyConfig","_this","name","config","rpcUrl","chainType","options","chainId","sendTransaction","params","this","request","utils","createJsonRpcRequestPayload","HarmonySignTransaction","Extension","Internal"],"mappings":"IAAYA,+HAAZ,SAAYA,GACVA,+CADF,CAAYA,IAAAA,oDCOV,WAAmBC,gBACjBC,sBADiBD,uBAHnBE,KAAO,YACPC,OAAc,GAEKF,gBAAAD,EAGjBC,EAAKE,OAAS,CACZC,OAAQJ,EAAcI,OACtBC,UAAW,UACXC,QAAS,CACPC,QAASP,EAAcO,+GAKhBC,yBAAgBC,OAC3B,uBAAOC,KAAKC,QAALD,KAAkBE,MAAMC,4BAA4Bd,EAAqBe,uBAAwBL,KAjB5G,uCAAsCM,YAAUC"}
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../src/index.ts"],
4
+ "sourcesContent": ["import { Extension } from '@magic-sdk/commons';\nimport { HarmonyPayloadMethod, HarmonyConfig } from './types';\n\nexport class HarmonyExtension extends Extension.Internal<'harmony', any> {\n name = 'harmony' as const;\n config: any = {};\n\n constructor(public harmonyConfig: HarmonyConfig) {\n super();\n\n this.config = {\n rpcUrl: harmonyConfig.rpcUrl,\n chainType: 'HARMONY',\n options: {\n chainId: harmonyConfig.chainId,\n },\n };\n }\n\n public async sendTransaction(params: any) {\n return this.request(this.utils.createJsonRpcRequestPayload(HarmonyPayloadMethod.HarmonySignTransaction, params));\n }\n}\n"],
5
+ "mappings": "2tBAAA,6CAA0B,8BAGnB,mBAA+B,aAAU,QAAyB,CAIvE,YAAmB,EAA8B,CAC/C,QADiB,qBAHnB,UAAO,UACP,YAAc,GAKZ,KAAK,OAAS,CACZ,OAAQ,EAAc,OACtB,UAAW,UACX,QAAS,CACP,QAAS,EAAc,UAKhB,gBAAgB,EAAa,gCACxC,MAAO,MAAK,QAAQ,KAAK,MAAM,4BAA4B,sBAA6C",
6
+ "names": []
7
+ }
package/dist/es/index.js CHANGED
@@ -1,2 +1,2 @@
1
- import{Extension as n}from"@magic-sdk/commons";function r(n,t){return(r=Object.setPrototypeOf||function(n,r){return n.__proto__=r,n})(n,t)}var t;!function(n){n.HarmonySignTransaction="hmy_sendTransaction"}(t||(t={}));var o=function(n){var o,e;function c(r){var t;return(t=n.call(this)||this).harmonyConfig=void 0,t.name="harmony",t.config={},t.harmonyConfig=r,t.config={rpcUrl:r.rpcUrl,chainType:"HARMONY",options:{chainId:r.chainId}},t}return e=n,(o=c).prototype=Object.create(e.prototype),o.prototype.constructor=o,r(o,e),c.prototype.sendTransaction=function(n){try{return Promise.resolve(this.request(this.utils.createJsonRpcRequestPayload(t.HarmonySignTransaction,n)))}catch(n){return Promise.reject(n)}},c}(n.Internal);export{o as HarmonyExtension};
1
+ var c=(t,r,a)=>new Promise((e,s)=>{var p=n=>{try{i(a.next(n))}catch(o){s(o)}},y=n=>{try{i(a.throw(n))}catch(o){s(o)}},i=n=>n.done?e(n.value):Promise.resolve(n.value).then(p,y);i((a=a.apply(t,r)).next())});import{Extension as m}from"@magic-sdk/commons";var h=class extends m.Internal{constructor(r){super();this.harmonyConfig=r;this.name="harmony";this.config={};this.config={rpcUrl:r.rpcUrl,chainType:"HARMONY",options:{chainId:r.chainId}}}sendTransaction(r){return c(this,null,function*(){return this.request(this.utils.createJsonRpcRequestPayload("hmy_sendTransaction",r))})}};export{h as HarmonyExtension};
2
2
  //# sourceMappingURL=index.js.map
@@ -1 +1,7 @@
1
- {"version":3,"file":"index.js","sources":["../../src/types.ts","../../src/index.ts"],"sourcesContent":["export enum HarmonyPayloadMethod {\n HarmonySignTransaction = 'hmy_sendTransaction',\n}\n\nexport interface HarmonyConfig {\n rpcUrl: string;\n chainId: string;\n chainType: string;\n}\n","import { Extension } from '@magic-sdk/commons';\nimport { HarmonyPayloadMethod, HarmonyConfig } from './types';\n\nexport class HarmonyExtension extends Extension.Internal<'harmony', any> {\n name = 'harmony' as const;\n config: any = {};\n\n constructor(public harmonyConfig: HarmonyConfig) {\n super();\n\n this.config = {\n rpcUrl: harmonyConfig.rpcUrl,\n chainType: 'HARMONY',\n options: {\n chainId: harmonyConfig.chainId,\n },\n };\n }\n\n public async sendTransaction(params: any) {\n return this.request(this.utils.createJsonRpcRequestPayload(HarmonyPayloadMethod.HarmonySignTransaction, params));\n }\n}\n"],"names":["HarmonyPayloadMethod","HarmonyExtension","harmonyConfig","_this","name","config","rpcUrl","chainType","options","chainId","sendTransaction","params","this","request","utils","createJsonRpcRequestPayload","HarmonySignTransaction","Extension","Internal"],"mappings":"+IAAYA,GAAZ,SAAYA,GACVA,+CADF,CAAYA,IAAAA,OCGCC,IAAAA,sBAIX,WAAmBC,gBACjBC,sBADiBD,uBAHnBE,KAAO,YACPC,OAAc,GAEKF,gBAAAD,EAGjBC,EAAKE,OAAS,CACZC,OAAQJ,EAAcI,OACtBC,UAAW,UACXC,QAAS,CACPC,QAASP,EAAcO,+GAKhBC,yBAAgBC,OAC3B,uBAAOC,KAAKC,QAALD,KAAkBE,MAAMC,4BAA4Bf,EAAqBgB,uBAAwBL,KAjB5G,uCAAsCM,EAAUC"}
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../src/index.ts"],
4
+ "sourcesContent": ["import { Extension } from '@magic-sdk/commons';\nimport { HarmonyPayloadMethod, HarmonyConfig } from './types';\n\nexport class HarmonyExtension extends Extension.Internal<'harmony', any> {\n name = 'harmony' as const;\n config: any = {};\n\n constructor(public harmonyConfig: HarmonyConfig) {\n super();\n\n this.config = {\n rpcUrl: harmonyConfig.rpcUrl,\n chainType: 'HARMONY',\n options: {\n chainId: harmonyConfig.chainId,\n },\n };\n }\n\n public async sendTransaction(params: any) {\n return this.request(this.utils.createJsonRpcRequestPayload(HarmonyPayloadMethod.HarmonySignTransaction, params));\n }\n}\n"],
5
+ "mappings": "6MAAA,+CAGO,mBAA+B,GAAU,QAAyB,CAIvE,YAAmB,EAA8B,CAC/C,QADiB,qBAHnB,UAAO,UACP,YAAc,GAKZ,KAAK,OAAS,CACZ,OAAQ,EAAc,OACtB,UAAW,UACX,QAAS,CACP,QAAS,EAAc,UAKhB,gBAAgB,EAAa,gCACxC,MAAO,MAAK,QAAQ,KAAK,MAAM,4BAA4B,sBAA6C",
6
+ "names": []
7
+ }
package/dist/extension.js CHANGED
@@ -1 +1,2 @@
1
- var MagicHarmonyExtension=function(n){function t(n,r){return(t=Object.setPrototypeOf||function(n,t){return n.__proto__=t,n})(n,r)}var r;return function(n){n.HarmonySignTransaction="hmy_sendTransaction"}(r||(r={})),function(n){var o,e;function i(t){var r;return(r=n.call(this)||this).harmonyConfig=void 0,r.name="harmony",r.config={},r.harmonyConfig=t,r.config={rpcUrl:t.rpcUrl,chainType:"HARMONY",options:{chainId:t.chainId}},r}return e=n,(o=i).prototype=Object.create(e.prototype),o.prototype.constructor=o,t(o,e),i.prototype.sendTransaction=function(n){try{return Promise.resolve(this.request(this.utils.createJsonRpcRequestPayload(r.HarmonySignTransaction,n)))}catch(n){return Promise.reject(n)}},i}(n.Extension.Internal)}(Magic);
1
+ var MagicHarmonyExtension=(()=>{var x=Object.create;var s=Object.defineProperty;var H=Object.getOwnPropertyDescriptor;var T=Object.getOwnPropertyNames;var I=Object.getPrototypeOf,R=Object.prototype.hasOwnProperty;var m=r=>s(r,"__esModule",{value:!0});var U=(r,n)=>()=>(n||r((n={exports:{}}).exports,n),n.exports),b=(r,n)=>{for(var o in n)s(r,o,{get:n[o],enumerable:!0})},y=(r,n,o,i)=>{if(n&&typeof n=="object"||typeof n=="function")for(let a of T(n))!R.call(r,a)&&(o||a!=="default")&&s(r,a,{get:()=>n[a],enumerable:!(i=H(n,a))||i.enumerable});return r},q=(r,n)=>y(m(s(r!=null?x(I(r)):{},"default",!n&&r&&r.__esModule?{get:()=>r.default,enumerable:!0}:{value:r,enumerable:!0})),r),C=(r=>(n,o)=>r&&r.get(n)||(o=y(m({}),n,1),r&&r.set(n,o),o))(typeof WeakMap!="undefined"?new WeakMap:0);var g=(r,n,o)=>new Promise((i,a)=>{var f=t=>{try{e(o.next(t))}catch(c){a(c)}},d=t=>{try{e(o.throw(t))}catch(c){a(c)}},e=t=>t.done?i(t.value):Promise.resolve(t.value).then(f,d);e((o=o.apply(r,n)).next())});var l=U((A,h)=>{h.exports=Magic});var M={};b(M,{default:()=>E});var u=q(l());var p=class extends u.Extension.Internal{constructor(n){super();this.harmonyConfig=n;this.name="harmony";this.config={};this.config={rpcUrl:n.rpcUrl,chainType:"HARMONY",options:{chainId:n.chainId}}}sendTransaction(n){return g(this,null,function*(){return this.request(this.utils.createJsonRpcRequestPayload("hmy_sendTransaction",n))})}};var E=p;return C(M);})();
2
+ if (MagicHarmonyExtension && MagicHarmonyExtension.default != null) { MagicHarmonyExtension = Object.assign(MagicHarmonyExtension.default, MagicHarmonyExtension); delete MagicHarmonyExtension.default; }
@@ -1,2 +1,2 @@
1
- var n,r=require("@magic-sdk/commons");function t(n,r){return(t=Object.setPrototypeOf||function(n,r){return n.__proto__=r,n})(n,r)}!function(n){n.HarmonySignTransaction="hmy_sendTransaction"}(n||(n={})),exports.HarmonyExtension=function(r){var o,e;function i(n){var t;return(t=r.call(this)||this).harmonyConfig=void 0,t.name="harmony",t.config={},t.harmonyConfig=n,t.config={rpcUrl:n.rpcUrl,chainType:"HARMONY",options:{chainId:n.chainId}},t}return e=r,(o=i).prototype=Object.create(e.prototype),o.prototype.constructor=o,t(o,e),i.prototype.sendTransaction=function(r){try{return Promise.resolve(this.request(this.utils.createJsonRpcRequestPayload(n.HarmonySignTransaction,r)))}catch(n){return Promise.reject(n)}},i}(r.Extension.Internal);
1
+ var e=Object.defineProperty;var l=Object.getOwnPropertyDescriptor;var u=Object.getOwnPropertyNames;var f=Object.prototype.hasOwnProperty;var d=r=>e(r,"__esModule",{value:!0});var x=(r,n)=>{for(var a in n)e(r,a,{get:n[a],enumerable:!0})},H=(r,n,a,t)=>{if(n&&typeof n=="object"||typeof n=="function")for(let o of u(n))!f.call(r,o)&&(a||o!=="default")&&e(r,o,{get:()=>n[o],enumerable:!(t=l(n,o))||t.enumerable});return r};var T=(r=>(n,a)=>r&&r.get(n)||(a=H(d({}),n,1),r&&r.set(n,a),a))(typeof WeakMap!="undefined"?new WeakMap:0);var p=(r,n,a)=>new Promise((t,o)=>{var h=i=>{try{s(a.next(i))}catch(c){o(c)}},g=i=>{try{s(a.throw(i))}catch(c){o(c)}},s=i=>i.done?t(i.value):Promise.resolve(i.value).then(h,g);s((a=a.apply(r,n)).next())});var I={};x(I,{HarmonyExtension:()=>y});var m=require("@magic-sdk/commons");var y=class extends m.Extension.Internal{constructor(n){super();this.harmonyConfig=n;this.name="harmony";this.config={};this.config={rpcUrl:n.rpcUrl,chainType:"HARMONY",options:{chainId:n.chainId}}}sendTransaction(n){return p(this,null,function*(){return this.request(this.utils.createJsonRpcRequestPayload("hmy_sendTransaction",n))})}};module.exports=T(I);
2
2
  //# sourceMappingURL=index.native.js.map
@@ -1 +1,7 @@
1
- {"version":3,"file":"index.native.js","sources":["../../src/types.ts","../../src/index.ts"],"sourcesContent":["export enum HarmonyPayloadMethod {\n HarmonySignTransaction = 'hmy_sendTransaction',\n}\n\nexport interface HarmonyConfig {\n rpcUrl: string;\n chainId: string;\n chainType: string;\n}\n","import { Extension } from '@magic-sdk/commons';\nimport { HarmonyPayloadMethod, HarmonyConfig } from './types';\n\nexport class HarmonyExtension extends Extension.Internal<'harmony', any> {\n name = 'harmony' as const;\n config: any = {};\n\n constructor(public harmonyConfig: HarmonyConfig) {\n super();\n\n this.config = {\n rpcUrl: harmonyConfig.rpcUrl,\n chainType: 'HARMONY',\n options: {\n chainId: harmonyConfig.chainId,\n },\n };\n }\n\n public async sendTransaction(params: any) {\n return this.request(this.utils.createJsonRpcRequestPayload(HarmonyPayloadMethod.HarmonySignTransaction, params));\n }\n}\n"],"names":["HarmonyPayloadMethod","harmonyConfig","_this","name","config","rpcUrl","chainType","options","chainId","sendTransaction","params","this","request","utils","createJsonRpcRequestPayload","HarmonySignTransaction","Extension","Internal"],"mappings":"IAAYA,+HAAZ,SAAYA,GACVA,+CADF,CAAYA,IAAAA,oDCOV,WAAmBC,gBACjBC,sBADiBD,uBAHnBE,KAAO,YACPC,OAAc,GAEKF,gBAAAD,EAGjBC,EAAKE,OAAS,CACZC,OAAQJ,EAAcI,OACtBC,UAAW,UACXC,QAAS,CACPC,QAASP,EAAcO,+GAKhBC,yBAAgBC,OAC3B,uBAAOC,KAAKC,QAALD,KAAkBE,MAAMC,4BAA4Bd,EAAqBe,uBAAwBL,KAjB5G,uCAAsCM,YAAUC"}
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../src/index.native.ts", "../../src/index.ts"],
4
+ "sourcesContent": ["export * from './index';\n", "import { Extension } from '@magic-sdk/commons';\nimport { HarmonyPayloadMethod, HarmonyConfig } from './types';\n\nexport class HarmonyExtension extends Extension.Internal<'harmony', any> {\n name = 'harmony' as const;\n config: any = {};\n\n constructor(public harmonyConfig: HarmonyConfig) {\n super();\n\n this.config = {\n rpcUrl: harmonyConfig.rpcUrl,\n chainType: 'HARMONY',\n options: {\n chainId: harmonyConfig.chainId,\n },\n };\n }\n\n public async sendTransaction(params: any) {\n return this.request(this.utils.createJsonRpcRequestPayload(HarmonyPayloadMethod.HarmonySignTransaction, params));\n }\n}\n"],
5
+ "mappings": "2tBAAA,uCCAA,MAA0B,8BAGnB,mBAA+B,aAAU,QAAyB,CAIvE,YAAmB,EAA8B,CAC/C,QADiB,qBAHnB,UAAO,UACP,YAAc,GAKZ,KAAK,OAAS,CACZ,OAAQ,EAAc,OACtB,UAAW,UACX,QAAS,CACP,QAAS,EAAc,UAKhB,gBAAgB,EAAa,gCACxC,MAAO,MAAK,QAAQ,KAAK,MAAM,4BAA4B,sBAA6C",
6
+ "names": []
7
+ }
@@ -1,2 +1,2 @@
1
- import { HarmonyExtension } from './index';
2
- export { HarmonyExtension as default };
1
+ import { HarmonyExtension } from './index';
2
+ export default HarmonyExtension;
@@ -1,9 +1,9 @@
1
- import { Extension } from '@magic-sdk/commons';
2
- import { HarmonyConfig } from './types';
3
- export declare class HarmonyExtension extends Extension.Internal<'harmony', any> {
4
- harmonyConfig: HarmonyConfig;
5
- name: "harmony";
6
- config: any;
7
- constructor(harmonyConfig: HarmonyConfig);
8
- sendTransaction(params: any): Promise<any>;
9
- }
1
+ import { Extension } from '@magic-sdk/commons';
2
+ import { HarmonyConfig } from './types';
3
+ export declare class HarmonyExtension extends Extension.Internal<'harmony', any> {
4
+ harmonyConfig: HarmonyConfig;
5
+ name: "harmony";
6
+ config: any;
7
+ constructor(harmonyConfig: HarmonyConfig);
8
+ sendTransaction(params: any): Promise<any>;
9
+ }
@@ -0,0 +1 @@
1
+ export * from './index';
@@ -1,8 +1,8 @@
1
- export declare enum HarmonyPayloadMethod {
2
- HarmonySignTransaction = "hmy_sendTransaction"
3
- }
4
- export interface HarmonyConfig {
5
- rpcUrl: string;
6
- chainId: string;
7
- chainType: string;
8
- }
1
+ export declare enum HarmonyPayloadMethod {
2
+ HarmonySignTransaction = "hmy_sendTransaction"
3
+ }
4
+ export interface HarmonyConfig {
5
+ rpcUrl: string;
6
+ chainId: string;
7
+ chainType: string;
8
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@magic-ext/harmony",
3
- "version": "2.0.0",
3
+ "version": "3.1.0",
4
4
  "description": "magic harmony extension",
5
5
  "author": "Magic <hello@magic.link> (https://magic.link/)",
6
6
  "license": "MIT",
@@ -13,7 +13,7 @@
13
13
  "dist/**/*.js.map",
14
14
  "dist/**/*.d.ts"
15
15
  ],
16
- "target": "web",
16
+ "target": "neutral",
17
17
  "cdnGlobalName": "MagicHarmonyExtension",
18
18
  "main": "./dist/cjs/index.js",
19
19
  "module": "./dist/es/index.js",
@@ -21,7 +21,7 @@
21
21
  "jsdelivr": "./dist/extension.js",
22
22
  "react-native": "./dist/react-native/index.native.js",
23
23
  "exports": {
24
- "import": "./dist/modern/index.mjs",
24
+ "import": "./dist/es/index.mjs",
25
25
  "require": "./dist/cjs/index.js"
26
26
  },
27
27
  "externals": {
@@ -30,7 +30,7 @@
30
30
  ]
31
31
  },
32
32
  "devDependencies": {
33
- "@magic-sdk/commons": "^3.0.0"
33
+ "@magic-sdk/commons": "^4.1.0"
34
34
  },
35
- "gitHead": "a85f41892cbd7985ee1743764f7f905b89004eaa"
35
+ "gitHead": "6aa5a25b33865cfe27444ca6094efade16a82f9f"
36
36
  }