hivesigner 3.2.5 → 3.2.8

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/docs/index.html CHANGED
@@ -5,7 +5,7 @@
5
5
  <title>Hivesigner demo with Vue.js</title>
6
6
  <link rel="stylesheet" href="https://unpkg.com/primer-css@9.6.0/build/build.css" />
7
7
  <script src="https://unpkg.com/vue@latest/dist/vue.js"></script>
8
- <script src="https://unpkg.com/hivesigner@latest/dist/hivesigner.min.js"></script>
8
+ <script src="https://unpkg.com/hivesigner@latest/lib/hivesigner.min.js"></script>
9
9
  <!-- <script src="https://cdn.jsdelivr.net/npm/hivesigner@3.2.2"></script> -->
10
10
  <!-- <script src="../dist/hivesigner.min.js"></script> -->
11
11
  </head>
@@ -1,4 +1,4 @@
1
1
  import { Parameters } from 'hive-uri';
2
2
  import { CallbackFunction } from '../types';
3
3
  import { Operation } from '@hiveio/dhive';
4
- export declare function sendOperations(ops: Operation, params: Parameters, cb: CallbackFunction): string | void;
4
+ export declare function sendOperations(ops: Operation[], params: Parameters, cb: CallbackFunction): string | void;
package/package.json CHANGED
@@ -1,10 +1,9 @@
1
1
  {
2
2
  "name": "hivesigner",
3
- "version": "3.2.5",
3
+ "version": "3.2.8",
4
4
  "description": "Hivesigner SDK",
5
- "browser": "dist/hivesigner.min.js",
6
- "main": "lib/index.js",
7
- "types": "lib/index.d.ts",
5
+ "main": "./lib/index",
6
+ "types": "./lib/index",
8
7
  "scripts": {
9
8
  "build": "rimraf lib && webpack && rollup -c rollup.config.js && tsc --emitDeclarationOnly",
10
9
  "test": "npx jest",
@@ -28,7 +27,7 @@
28
27
  "@babel/plugin-transform-runtime": "^7.13.9",
29
28
  "@babel/preset-env": "^7.13.9",
30
29
  "@babel/preset-typescript": "^7.13.0",
31
- "@hiveio/dhive": "^0.14.12",
30
+ "@hiveio/dhive": "^1.2.2",
32
31
  "@types/bytebuffer": "^5.0.42",
33
32
  "@types/jest": "^26.0.20",
34
33
  "@types/node": "^14.14.28",
@@ -51,6 +50,6 @@
51
50
  "dependencies": {
52
51
  "@babel/runtime": "^7.13.9",
53
52
  "cross-fetch": "^3.0.6",
54
- "hive-uri": "^0.2.3"
53
+ "hive-uri": "^0.2.4"
55
54
  }
56
55
  }
@@ -9,14 +9,14 @@ jest.mock('../utilities')
9
9
  jest.mock('hive-uri')
10
10
 
11
11
  describe('Send operations method', function () {
12
- let ops: Operation
12
+ let ops: Operation[]
13
13
  let params: hive.Parameters
14
14
  let cb: CallbackFunction
15
15
  let encodeOpsMock: jest.Mock
16
16
  let isBrowserMock: jest.Mock
17
17
 
18
18
  beforeEach(() => {
19
- ops = {} as Operation
19
+ ops = [] as Operation[]
20
20
  params = {}
21
21
  cb = () => {}
22
22
  (window as { open: () => void }).open = jest.fn()
@@ -4,7 +4,7 @@ import { BETA_URL } from '../consts'
4
4
  import { CallbackFunction } from '../types'
5
5
  import { Operation } from '@hiveio/dhive'
6
6
 
7
- export function sendOperations(ops: Operation, params: Parameters, cb: CallbackFunction): string | void {
7
+ export function sendOperations(ops: Operation[], params: Parameters, cb: CallbackFunction): string | void {
8
8
  const uri = encodeOps(ops, params)
9
9
  const webUrl = uri.replace('hive://', `${BETA_URL}/`)
10
10
  if (cb && isBrowser()) {