Compare commits

..
83 Commits
Author SHA1 Message Date
github-actions[bot] f6a46f2d33 [CI Skip] release/stable 0.87.1
skip-checks: true
2021-11-28 05:23:43 +00:00
Jaco 2b71f0164c Bump common (#547)
* Bump common

* 0.87.1
2021-11-28 07:21:18 +02:00
Github Actions 6381e571cf [CI Skip] release/beta 0.86.8-0
skip-checks: true
2021-11-24 14:59:58 +00:00
Jaco d5bbee2bad Adjust stale schedule (#546) 2021-11-24 16:57:26 +02:00
Github Actions e8df066f50 [CI Skip] release/stable 0.86.7
skip-checks: true
2021-11-22 05:27:30 +00:00
Jaco b3bef159dd 0.86.7 (#545) 2021-11-22 07:25:20 +02:00
Github Actions 2f28f04b22 [CI Skip] release/stable 0.86.6
skip-checks: true
2021-11-21 06:43:01 +00:00
Jaco 0a96372186 0.86.6 (#544) 2021-11-21 08:40:38 +02:00
Github Actions 41edf711ec [CI Skip] release/beta 0.86.6-0
skip-checks: true
2021-11-18 12:46:10 +00:00
Jaco d38a8dfd96 Bump deps (#543) 2021-11-18 14:43:31 +02:00
Github Actions 465152698d [CI Skip] release/stable 0.86.5
skip-checks: true
2021-11-07 07:42:47 +00:00
Jaco 84a18f3c0b 0.86.5 (#540) 2021-11-07 09:40:23 +02:00
Github Actions f222cbb6c0 [CI Skip] release/stable 0.86.4
skip-checks: true
2021-11-06 12:00:07 +00:00
Jaco 6ceb397c87 0.86.4 (#539) 2021-11-06 13:57:13 +02:00
Github Actions bd7fa3db34 [CI Skip] release/beta 0.86.4-1
skip-checks: true
2021-11-05 04:29:57 +00:00
Jaco f6e6c83950 Use objectSpread as applicable (#538)
* Use objectSpread as applicable

* Updates

* Add objectSpread import
2021-11-05 06:27:07 +02:00
Github Actions 2910128399 [CI Skip] release/beta 0.86.4-0
skip-checks: true
2021-11-03 16:16:42 +00:00
Jaco 58ad6efadb Correct Qr signature type (#537) 2021-11-03 18:13:33 +02:00
Github Actions 5c0f70a4a2 [CI Skip] release/stable 0.86.3
skip-checks: true
2021-11-01 11:39:31 +00:00
Jaco 921bb0a4a0 0.86.3 (#536) 2021-11-01 13:37:11 +02:00
Github Actions 10450a350b [CI Skip] release/beta 0.86.3-3
skip-checks: true
2021-10-26 11:29:54 +00:00
Jaco 60bce7c0fa Add .skip-npm for examples 2021-10-26 14:26:51 +03:00
Github Actions aa36e56ff6 [CI Skip] release/beta 0.86.3-2
skip-checks: true
2021-10-26 11:16:09 +00:00
Jaco 653a4a8f39 Bump dev (#535) 2021-10-26 14:13:40 +03:00
Github Actions 9b9fa77bc8 [CI Skip] release/beta 0.86.3-1
skip-checks: true
2021-10-25 11:31:41 +00:00
Jaco 0427f8e2af Bump dev (#534) 2021-10-25 14:28:54 +03:00
Github Actions 7b45a86daa [CI Skip] release/beta 0.86.3-0
skip-checks: true
2021-10-25 09:34:02 +00:00
Jaco c94427d150 Reorder package.json fields (#533) 2021-10-25 12:31:38 +03:00
Github Actions b9179a391e [CI Skip] release/stable 0.86.2
skip-checks: true
2021-10-24 17:37:13 +00:00
Jaco ade03fcc7e 0.86.2 (#532) 2021-10-24 20:34:35 +03:00
Github Actions dc2c83d21c [CI Skip] release/beta 0.86.2-1
skip-checks: true
2021-10-19 05:06:57 +00:00
Jaco 9c012e02d2 Bump deps (#531) 2021-10-19 08:04:18 +03:00
Github Actions 47576d50e0 [CI Skip] release/beta 0.86.2-0
skip-checks: true
2021-10-18 04:23:33 +00:00
Jaco 782f87fc17 Bump dev (w/ eslint 8 & fixes) (#530) 2021-10-18 07:21:06 +03:00
Github Actions bc4b5090b4 [CI Skip] release/stable 0.86.1
skip-checks: true
2021-10-16 06:46:49 +00:00
Jaco 24dc52741b 0.86.1 (#525) 2021-10-16 09:44:31 +03:00
Github Actions 725feb2528 [CI Skip] release/beta 0.85.6-0
skip-checks: true
2021-10-13 15:41:53 +00:00
Nikos Kontakis 196e851fa3 Fix undefined process error that may appear when using ui (#524) 2021-10-13 18:38:49 +03:00
Github Actions 633ca5fd2e [CI Skip] release/stable 0.85.5
skip-checks: true
2021-10-10 06:57:50 +00:00
Jaco 5f0c9889c5 0.85.5 (#523)
* 0.85.5

* Bump
2021-10-10 09:55:19 +03:00
Github Actions 1e95898bd5 [CI Skip] release/stable 0.85.4
skip-checks: true
2021-09-17 14:43:02 +00:00
Jaco f069f4997a 0.85.4 (#521) 2021-09-17 16:40:33 +02:00
Github Actions 4451c5e984 [CI Skip] release/beta 0.85.4-3
skip-checks: true
2021-09-14 11:51:26 +00:00
Jaco 1830a32e77 Bump deps (#520) 2021-09-14 13:48:33 +02:00
Github Actions b910a2e335 [CI Skip] release/beta 0.85.4-2
skip-checks: true
2021-09-05 08:24:41 +00:00
Jaco 4ae5d9495f Bump deps (#519) 2021-09-05 10:22:23 +02:00
Github Actions 2aa64b62a9 [CI Skip] release/beta 0.85.4-1
skip-checks: true
2021-09-01 16:45:48 +00:00
Jaco c8f2f119f0 Jest config cleanup (#518)
* Jest config cleanup

* Bump
2021-09-01 18:43:01 +02:00
Github Actions eeca1f8f50 [CI Skip] release/stable 0.85.3
skip-checks: true
2021-08-29 20:53:34 +00:00
Jaco b74034a809 0.85.3 (#517)
* 0.85.3

* CHANGELOG
2021-08-29 22:50:42 +02:00
Github Actions b356f26e08 [CI Skip] release/stable 0.85.2
skip-checks: true
2021-08-28 06:46:45 +00:00
Jaco c9c3011441 0.85.2 (#515) 2021-08-28 08:43:52 +02:00
Github Actions d2fcebd84a [CI Skip] release/beta 0.85.2-1
skip-checks: true
2021-08-26 08:32:22 +00:00
Jaco 9c47628233 Bump dev (w/ jsx linting) (#514) 2021-08-26 10:29:23 +02:00
Github Actions 28956664cc [CI Skip] release/beta 0.85.2-0
skip-checks: true
2021-08-17 07:41:09 +00:00
Jaco 994f303064 Bump dev (#513) 2021-08-17 09:38:23 +02:00
Github Actions 52a09f4364 [CI Skip] release/stable 0.85.1
skip-checks: true
2021-08-15 11:01:23 +00:00
Jaco 6abb0f79b6 0.85.1 (#512) 2021-08-15 12:58:46 +02:00
Github Actions 2afd941483 [CI Skip] release/beta 0.84.4-2
skip-checks: true
2021-08-13 11:52:10 +00:00
Jaco Greeff fd43c16853 bump berry 2021-08-13 14:49:13 +03:00
Github Actions c27f971878 [CI Skip] release/beta 0.84.4-1
skip-checks: true
2021-08-13 11:19:06 +00:00
Jaco e48115c557 Bump dev (#511)
* Bump dev

* CHANGELOG

* Bump common
2021-08-13 13:15:45 +02:00
Nantian 3f0c2d82e8 fix bigint type (#510) 2021-08-13 13:08:59 +02:00
Github Actions 544fbb5e6d [CI Skip] release/beta 0.84.4-0
skip-checks: true
2021-08-10 09:36:20 +00:00
Jaco dfde4d7989 Bump deps (#509) 2021-08-10 11:33:42 +02:00
Github Actions d80f0ce906 [CI Skip] release/stable 0.84.3
skip-checks: true
2021-08-02 09:24:07 +00:00
Jaco 6a6a247b1f 0.84.3 (#507) 2021-08-02 11:21:03 +02:00
Github Actions b7c5a9a509 [CI Skip] release/stable 0.84.2
skip-checks: true
2021-07-26 07:00:30 +00:00
Jaco 8694cb45e3 0.84.2 (#506) 2021-07-26 08:57:35 +02:00
Github Actions c075950e93 [CI Skip] release/stable 0.84.1
skip-checks: true
2021-07-11 10:28:38 +00:00
Jaco 3e555546cd 0.84 (#505) 2021-07-11 12:25:29 +02:00
Github Actions 63440d051f [CI Skip] release/beta 0.83.2-5
skip-checks: true
2021-07-09 15:22:27 +00:00
Jaco 0cd16ee2d7 Bundle adjust (#504)
* Bundle adjust

* Bumps
2021-07-09 17:19:48 +02:00
Github Actions 3803286251 [CI Skip] release/beta 0.83.2-4
skip-checks: true
2021-07-09 13:32:55 +00:00
Jaco 2d801b535e Browser bundle build (incomplete) (#503)
* Browser bundle build (incomplete)

* globals
2021-07-09 15:30:05 +02:00
Github Actions f2189f3780 [CI Skip] release/beta 0.83.2-3
skip-checks: true
2021-07-09 12:47:08 +00:00
Jaco be251919d6 Add bundle.ts files for browser bundling (#502) 2021-07-09 14:44:16 +02:00
Github Actions bdec479885 [CI Skip] release/beta 0.83.2-2
skip-checks: true
2021-07-09 12:37:29 +00:00
Jaco ed56f21bcb Bump common (#501) 2021-07-09 14:34:42 +02:00
Github Actions 76e1248c5f [CI Skip] release/beta 0.83.2-1
skip-checks: true
2021-07-07 07:40:29 +00:00
Jaco Greeff b6f12ba822 Bump common 2021-07-07 10:37:54 +03:00
Github Actions 0892532f5c [CI Skip] release/beta 0.83.2-0
skip-checks: true
2021-07-07 07:29:00 +00:00
Jaco 99ea536891 Bump common (#500)
* Bump common

* CHANGELOG

* Direct rxjs import
2021-07-07 09:26:09 +02:00
64 changed files with 3719 additions and 3207 deletions
+13
View File
@@ -4,3 +4,16 @@
0.66.3
0.71.2
0.71.3
0.84.2
0.84.3
0.85.2
0.85.3
0.85.4
0.85.5
0.86.2
0.86.3
0.86.4
0.86.5
0.86.6
0.86.7
+1 -1
View File
@@ -2,7 +2,7 @@ name: 'Lock Threads'
on:
schedule:
- cron: '30 1/2 * * *'
- cron: '25 2 * * *'
jobs:
lock:
+1 -1
View File
@@ -1,7 +1,7 @@
name: 'Close stale issues and PRs'
on:
schedule:
- cron: '30 2/2 * * *'
- cron: '2 40 * * *'
jobs:
stale:
File diff suppressed because one or more lines are too long
+631
View File
File diff suppressed because one or more lines are too long
+1 -1
View File
@@ -10,4 +10,4 @@ plugins:
- path: .yarn/plugins/@yarnpkg/plugin-version.cjs
spec: "@yarnpkg/plugin-version"
yarnPath: .yarn/releases/yarn-3.0.0-rc.2.cjs
yarnPath: .yarn/releases/yarn-3.0.1.cjs
+128 -5
View File
@@ -1,6 +1,129 @@
# CHANGELOG
## 0.83.1, Jul 5, 2021
## 0.87.1 Nov 28, 2021
Changes:
- Updated to `@polkadot/{hw-ledger, keyring, util, util-crypto}` 8.0.2
## 0.86.7 Nov 22, 2021
Changes:
- Updated to `@polkadot/{hw-ledger, keyring, util, util-crypto}` 7.9.2
## 0.86.6 Nov 21, 2021
Changes:
- Updated to `@polkadot/{hw-ledger, keyring, util, util-crypto}` 7.9.1
## 0.86.5 Nov 6, 2021
Changes:
- Updated to `@polkadot/{hw-ledger, keyring, util, util-crypto}` 7.8.2
## 0.86.4 Nov 6, 2021
Changes:
- Updated to `@polkadot/{hw-ledger, keyring, util, util-crypto}` 7.8.1
## 0.86.3 Nov 1, 2021
Changes:
- Add publish skip to all examples
- Updated to `@polkadot/{hw-ledger, keyring, util, util-crypto}` 7.7.1
## 0.86.2 Oct 24, 2021
Changes:
- Updated to `@polkadot/{hw-ledger, keyring, util, util-crypto}` 7.6.1
## 0.86.1 Oct 16, 2021
Contributed:
- Check for existence of `process` before using (Thanks to https://github.com/wirednkod)
Changes:
- Updated to `@polkadot/{hw-ledger, keyring, util, util-crypto}` 7.5.1
## 0.85.5 Oct 10, 2021
Changes:
- Update rxjs to 7.4 (aligning with use in API)
## 0.85.4 Sep 17, 2021
Changes:
- Updated to `@polkadot/{hw-ledger, keyring, util, util-crypto}` 7.4.1
## 0.85.3 Aug 29, 2021
Changes:
- Revert color bump to 4.0.1, keep at 3.2.1 (numeric separators on Vue & react-native)
## 0.85.2 Aug 28, 2021
Changes:
- Updated to `@polkadot/{hw-ledger, keyring, util, util-crypto}` 7.3.1
## 0.85.1 Aug 15, 2021
Contributed:
- Always use `bigint` type to indicate instance (Thanks to https://github.com/ntduan)
Changes:
- Updated to `@polkadot/{hw-ledger, keyring, util, util-crypto}` 7.2.1
## 0.84.3 Aug 2, 2021
Changes:
- Updated to `@polkadot/{hw-ledger, keyring, util, util-crypto}` 7.1.1
## 0.84.2 Jul 26, 2021
Changes:
- Updated to `@polkadot/{hw-ledger, keyring, util, util-crypto}` 7.0.3
## 0.84.1 Jul 11, 2021
Changes:
- Internal RxJs usage has been bumped to the 7.2 version
- Allow building as a completely stand-alone browser bundle (experimental)
- Updated to `@polkadot/{hw-ledger, keyring, util, util-crypto}` 7.0.1
## 0.83.1 Jul 5, 2021
Contributed:
@@ -11,7 +134,7 @@ Changes:
- Updated to `@polkadot/{hw-ledger, keyring, util, util-crypto}` 6.11.1
## 0.82.1, Jun 26, 2021
## 0.82.1 Jun 26, 2021
Contributed:
@@ -24,7 +147,7 @@ Changes:
- Updated to `@polkadot/{hw-ledger, keyring, util, util-crypto}` 6.10.1
## 0.81.1, Jun 20, 2021
## 0.81.1 Jun 20, 2021
Contributed:
@@ -37,14 +160,14 @@ Changes:
- Fix webpack demo import locations
## 0.80.1, Jun 14, 2021
## 0.80.1 Jun 14, 2021
Changes:
- Updated to `@polkadot/{hw-ledger, keyring, util, util-crypto}` 6.8.1
## 0.79.1, Jun 6, 2021
## 0.79.1 Jun 6, 2021
Changes:
+1 -15
View File
@@ -12,19 +12,5 @@ module.exports = {
'\\.(css|less)$': 'empty/object',
'\\.(jpg|jpeg|png|gif|eot|otf|webp|svg|ttf|woff|woff2|mp4|webm|wav|mp3|m4a|aac|oga)$': 'empty/object'
},
modulePathIgnorePatterns: [
'<rootDir>/packages/example-react/build',
'<rootDir>/packages/example-vue/build',
'<rootDir>/packages/exampleReactNative/build',
'<rootDir>/packages/react-identicon/build',
'<rootDir>/packages/react-qr/build',
'<rootDir>/packages/reactnative-identicon/build',
'<rootDir>/packages/ui-assets/build',
'<rootDir>/packages/ui-keyring/build',
'<rootDir>/packages/ui-settings/build',
'<rootDir>/packages/ui-shared/build',
'<rootDir>/packages/vue-identicon/build'
],
testEnvironment: 'jsdom',
transformIgnorePatterns: ['/node_modules/(?!@polkadot|@babel/runtime/helpers/esm/)']
testEnvironment: 'jsdom'
};
+24 -16
View File
@@ -1,47 +1,55 @@
{
"repository": "https://github.com/polkadot-js/ui",
"author": "Jaco Greeff <jacogr@gmail.com>",
"bugs": "https://github.com/polkadot-js/ui/issues",
"homepage": "https://github.com/polkadot-js/ui#readme",
"license": "Apache-2",
"packageManager": "yarn@3.0.1",
"private": true,
"homepage": ".",
"repository": {
"type": "git",
"url": "https://github.com/polkadot-js/ui.git"
},
"sideEffects": false,
"version": "0.87.1",
"workspaces": [
"packages/*"
],
"resolutions": {
"typescript": "^4.3.5"
},
"scripts": {
"build": "polkadot-dev-build-ts",
"build:release": "polkadot-ci-ghact-build",
"lint": "polkadot-dev-run-lint",
"build:rollup": "polkadot-exec-rollup --config",
"clean": "polkadot-dev-clean-build",
"demo:identicon:react": "yarn build && webpack-serve --config packages/react-identicon/webpack.config.js --content packages/react-identicon --port 8080",
"demo:identicon:vue": "yarn build && webpack-serve --config packages/vue-identicon/webpack.config.js --content packages/vue-identicon --port 8080",
"example:rn:packager": "yarn build && cd packages/exampleReactNative && yarn copy-workspace-packages && yarn start",
"example:rn:ios": "cd packages/exampleReactNative && cd ios && pod install && cd .. && yarn ios",
"example:rn:android": "cd packages/exampleReactNative && yarn android",
"example:react": "yarn build && cd packages/example-react && webpack --config webpack.config.js",
"example:rn:android": "cd packages/exampleReactNative && yarn android",
"example:rn:ios": "cd packages/exampleReactNative && cd ios && pod install && cd .. && yarn ios",
"example:rn:packager": "yarn build && cd packages/exampleReactNative && yarn copy-workspace-packages && yarn start",
"example:vue": "yarn build && cd packages/example-vue && webpack --config webpack.config.js",
"lint": "polkadot-dev-run-lint",
"postinstall": "polkadot-dev-yarn-only",
"test": "polkadot-dev-run-test --coverage --runInBand",
"test:one": "polkadot-dev-run-test"
},
"devDependencies": {
"@babel/core": "^7.14.6",
"@babel/runtime": "^7.14.6",
"@polkadot/dev": "^0.62.44",
"@polkadot/ts": "^0.4.2",
"@types/jest": "^26.0.23",
"@babel/core": "^7.16.0",
"@babel/runtime": "^7.16.3",
"@polkadot/dev": "^0.63.33",
"@polkadot/ts": "^0.4.15",
"@polkadot/x-bundle": "^8.0.2",
"@types/jest": "^27.0.3",
"babel-plugin-transform-vue-template": "^0.4.2",
"empty": "^0.10.1",
"react": "^17.0.2",
"react-dom": "^17.0.2",
"react-is": "^17.0.2",
"react-native": "^0.64.2",
"react-native": "^0.66.3",
"vue-template-compiler": "^2.6.14",
"webpack": "^4.46.0",
"webpack-cli": "^3.3.12",
"webpack-serve": "^3.2.0"
},
"version": "0.83.1"
"resolutions": {
"typescript": "^4.5.2"
}
}
View File
+16 -6
View File
@@ -1,12 +1,22 @@
{
"name": "@polkadot/example-react",
"version": "0.83.1",
"description": "A very basic example with ui-* & react-* packages",
"main": "index.js",
"author": "Jaco Greeff <jacogr@gmail.com>",
"maintainers": [],
"bugs": "https://github.com/polkadot-js/ui/issues",
"contributors": [],
"description": "A very basic example with ui-* & react-* packages",
"homepage": "https://github.com/polkadot-js/ui/tree/master/packages/example-react#readme",
"license": "Apache-2.0",
"maintainers": [],
"name": "@polkadot/example-react",
"private": true,
"repository": {
"directory": "packages/example-react",
"type": "git",
"url": "https://github.com/polkadot-js/ui.git"
},
"sideEffects": false,
"version": "0.87.1",
"main": "index.js",
"dependencies": {
"@babel/runtime": "^7.14.6"
"@babel/runtime": "^7.16.3"
}
}
+1 -1
View File
@@ -3,4 +3,4 @@
// Auto-generated by @polkadot/dev, do not edit
export const packageInfo = { name: '@polkadot/example-react', version: '0.83.1' };
export const packageInfo = { name: '@polkadot/example-react', version: '0.87.1' };
View File
+16 -6
View File
@@ -1,12 +1,22 @@
{
"name": "@polkadot/example-vue",
"version": "0.83.1",
"description": "A very basic example with ui-* & vue-* packages",
"main": "index.js",
"author": "Jaco Greeff <jacogr@gmail.com>",
"maintainers": [],
"bugs": "https://github.com/polkadot-js/ui/issues",
"contributors": [],
"description": "A very basic example with ui-* & vue-* packages",
"homepage": "https://github.com/polkadot-js/ui/tree/master/packages/example-vue#readme",
"license": "Apache-2.0",
"maintainers": [],
"name": "@polkadot/example-vue",
"private": true,
"repository": {
"directory": "packages/example-vue",
"type": "git",
"url": "https://github.com/polkadot-js/ui.git"
},
"sideEffects": false,
"version": "0.87.1",
"main": "index.js",
"dependencies": {
"@babel/runtime": "^7.14.6"
"@babel/runtime": "^7.16.3"
}
}
+1 -1
View File
@@ -3,4 +3,4 @@
// Auto-generated by @polkadot/dev, do not edit
export const packageInfo = { name: '@polkadot/example-vue', version: '0.83.1' };
export const packageInfo = { name: '@polkadot/example-vue', version: '0.87.1' };
+18 -12
View File
@@ -1,7 +1,7 @@
// Copyright 2017-2021 @polkadot/example-react authors & contributors
// SPDX-License-Identifier: Apache-2.0
import React, { useEffect, useState } from 'react';
import React, { useCallback, useEffect, useState } from 'react';
import { Button, SafeAreaView, ScrollView, StatusBar, StyleSheet, Text, View } from 'react-native';
import { Colors } from 'react-native/Libraries/NewAppScreen';
@@ -57,17 +57,22 @@ export default function App (): React.ReactElement | null {
const [phrase, setPhrase] = useState<string | null>(null);
const [ss58Format, setSS58Format] = useState(42);
const _onClickNew = (): void => {
const phrase = mnemonicGenerate(12);
const { address } = keyring.createFromUri(phrase);
const _onClickNew = useCallback(
(): void => {
const phrase = mnemonicGenerate(12);
const { address } = keyring.createFromUri(phrase);
setAddress(keyring.encodeAddress(address, ss58Format));
setPhrase(phrase);
};
setAddress(keyring.encodeAddress(address, ss58Format));
setPhrase(phrase);
},
[ss58Format]
);
const _onChangeSS58Format = (value: string): void => {
setSS58Format(parseInt(value, 10));
};
const _onChangeSS58Format = useCallback(
(value: string) =>
() => setSS58Format(parseInt(value, 10)),
[]
);
useEffect((): void => {
isReady && _onClickNew();
@@ -108,7 +113,8 @@ export default function App (): React.ReactElement | null {
<SafeAreaView>
<ScrollView
contentInsetAdjustmentBehavior='automatic'
style={styles.scrollView}>
style={styles.scrollView}
>
<View style={styles.body}>
<View style={styles.sectionContainer}>
<Text style={styles.mainTitle}>React-Native Example</Text>
@@ -144,7 +150,7 @@ export default function App (): React.ReactElement | null {
.map(({ text, value }): React.ReactNode => (
<Button
key={value}
onPress={(): void => _onChangeSS58Format(value.toString())}
onPress={_onChangeSS58Format(value.toString())}
title={text}
/>
))
@@ -21,27 +21,27 @@ class Storage {
this.loading = false;
return [...data];
}
};
getItem = (key) => {
return this.dataMap.get(key);
}
};
setItem = (key, value) => {
this.dataMap.set(key, value);
return AsyncStorage.setItem(key, value);
}
};
remove = (key) => {
this.dataMap.delete(key);
return AsyncStorage.removeItem(key);
}
};
saveItem = (item) => {
this.dataMap.set(item[0], item[1]);
}
};
}
// Set global process variable expected by some classes.
+22 -13
View File
@@ -1,6 +1,7 @@
{
"name": "exampleReactNative",
"version": "0.83.1",
"version": "0.87.1",
"license": "Apache-2.0",
"private": true,
"scripts": {
"copy-workspace-packages": "yarn copy-identicon && yarn copy-ui-shared",
@@ -11,31 +12,39 @@
"start": "NODE_OPTIONS=--max_old_space_size=8192 react-native start",
"test": "jest"
},
"bugs": "https://github.com/polkadot-js/ui/issues",
"homepage": "https://github.com/polkadot-js/ui#readme",
"repository": {
"type": "git",
"url": "https://github.com/polkadot-js/ui.git",
"directory": "packages/exampleReactNative"
},
"sideEffects": false,
"dependencies": {
"@polkadot/keyring": "^6.11.1",
"@polkadot/reactnative-identicon": "0.83.1",
"@polkadot/ui-keyring": "0.83.1",
"@polkadot/ui-settings": "0.83.1",
"@polkadot/util": "^6.11.1",
"@polkadot/util-crypto": "^6.11.1",
"@polkadot/keyring": "^8.0.2",
"@polkadot/reactnative-identicon": "0.87.1",
"@polkadot/ui-keyring": "0.87.1",
"@polkadot/ui-settings": "0.87.1",
"@polkadot/util": "^8.0.2",
"@polkadot/util-crypto": "^8.0.2",
"@react-native-community/async-storage": "^1.12.1",
"fast-text-encoding": "^1.0.3",
"get-yarn-workspaces": "^1.0.2",
"os-browserify": "^0.3.0",
"process": "^0.11.10",
"react": "^17.0.2",
"react-native": "^0.64.2",
"react-native": "^0.66.3",
"react-native-crypto": "^2.2.0",
"react-native-randombytes": "^3.6.1",
"stream-http": "^3.2.0"
},
"devDependencies": {
"@babel/core": "^7.14.6",
"@babel/runtime": "^7.14.6",
"@react-native-community/cli-platform-ios": "^5.0.1",
"@babel/core": "^7.16.0",
"@babel/runtime": "^7.16.3",
"@react-native-community/cli-platform-ios": "^6.2.0",
"@types/react-test-renderer": "17.0.1",
"babel-jest": "^27.0.6",
"metro-react-native-babel-preset": "^0.66.0",
"babel-jest": "^27.3.1",
"metro-react-native-babel-preset": "^0.66.2",
"react-test-renderer": "17.0.2"
},
"jest": {
+32 -24
View File
@@ -1,28 +1,43 @@
{
"name": "@polkadot/react-identicon",
"version": "0.83.1",
"type": "module",
"author": "Jaco Greeff <jacogr@gmail.com>",
"bugs": "https://github.com/polkadot-js/ui/issues",
"contributors": [],
"description": "Renders an SVG picture representing an address",
"main": "index.js",
"homepage": "https://github.com/polkadot-js/ui/tree/master/packages/react-identicon#readme",
"license": "Apache-2.0",
"maintainers": [],
"name": "@polkadot/react-identicon",
"repository": {
"directory": "packages/react-identicon",
"type": "git",
"url": "https://github.com/polkadot-js/ui.git"
},
"sideEffects": [
"./detectPackage.js",
"./detectPackage.cjs"
],
"author": "Jaco Greeff <jacogr@gmail.com>",
"maintainers": [],
"license": "Apache-2.0",
"type": "module",
"version": "0.87.1",
"main": "index.js",
"dependencies": {
"@babel/runtime": "^7.14.6",
"@polkadot/keyring": "^6.11.1",
"@polkadot/ui-settings": "0.83.1",
"@polkadot/ui-shared": "0.83.1",
"@polkadot/util": "^6.11.1",
"@polkadot/util-crypto": "^6.11.1",
"color": "^3.1.3",
"@babel/runtime": "^7.16.3",
"@polkadot/keyring": "^8.0.2",
"@polkadot/ui-settings": "0.87.1",
"@polkadot/ui-shared": "0.87.1",
"@polkadot/util": "^8.0.2",
"@polkadot/util-crypto": "^8.0.2",
"color": "^3.2.1",
"ethereum-blockies-base64": "^1.0.2",
"jdenticon": "3.1.0",
"react-copy-to-clipboard": "^5.0.3",
"styled-components": "^5.3.0"
"jdenticon": "3.1.1",
"react-copy-to-clipboard": "^5.0.4",
"styled-components": "^5.3.3"
},
"devDependencies": {
"@types/react-copy-to-clipboard": "^5.0.2",
"@types/react-dom": "^17.0.11",
"@types/styled-components": "^5.1.15",
"styled-components": "^5.3.3",
"xmlserializer": "^0.6.1"
},
"peerDependencies": {
"@polkadot/keyring": "*",
@@ -32,12 +47,5 @@
"react-dom": "*",
"react-is": "*",
"styled-components": "*"
},
"devDependencies": {
"@types/react-copy-to-clipboard": "^5.0.0",
"@types/react-dom": "^17.0.8",
"@types/styled-components": "^5.1.11",
"styled-components": "^5.3.0",
"xmlserializer": "^0.6.1"
}
}
+1 -1
View File
@@ -144,7 +144,7 @@ class BaseIcon extends React.PureComponent<Props, State> {
if (address && onCopy) {
onCopy(address);
}
}
};
}
function Icon (props: Props): React.ReactElement<Props> {
+7
View File
@@ -0,0 +1,7 @@
// Copyright 2017-2021 @polkadot/react-identicon authors & contributors
// SPDX-License-Identifier: Apache-2.0
export * from './icons';
export { Identicon } from './Identicon';
export { packageInfo } from './packageInfo';
+2 -5
View File
@@ -3,11 +3,8 @@
import './detectPackage';
import { Identicon } from './Identicon';
import { Identicon } from './bundle';
export * from './icons';
export { packageInfo } from './packageInfo';
export { Identicon };
export * from './bundle';
export default Identicon;
+1 -1
View File
@@ -3,4 +3,4 @@
// Auto-generated by @polkadot/dev, do not edit
export const packageInfo = { name: '@polkadot/react-identicon', version: '0.83.1' };
export const packageInfo = { name: '@polkadot/react-identicon', version: '0.87.1' };
+21 -13
View File
@@ -1,24 +1,32 @@
{
"name": "@polkadot/react-qr",
"version": "0.83.1",
"type": "module",
"description": "Generates and reads QR codes",
"main": "index.js",
"sideEffects": false,
"author": "Jaco Greeff <jacogr@gmail.com>",
"maintainers": [],
"bugs": "https://github.com/polkadot-js/ui/issues",
"contributors": [],
"description": "Generates and reads QR codes",
"homepage": "https://github.com/polkadot-js/ui/tree/master/packages/react-qr#readme",
"license": "Apache-2.0",
"maintainers": [],
"name": "@polkadot/react-qr",
"repository": {
"directory": "packages/react-qr",
"type": "git",
"url": "https://github.com/polkadot-js/ui.git"
},
"sideEffects": false,
"type": "module",
"version": "0.87.1",
"main": "index.js",
"dependencies": {
"@babel/runtime": "^7.14.6",
"@polkadot/util": "^6.11.1",
"@polkadot/util-crypto": "^6.11.1",
"@babel/runtime": "^7.16.3",
"@polkadot/util": "^8.0.2",
"@polkadot/util-crypto": "^8.0.2",
"qrcode-generator": "^1.4.4",
"react-qr-reader": "^2.2.1",
"styled-components": "^5.3.0"
"styled-components": "^5.3.3"
},
"devDependencies": {
"@types/react-qr-reader": "^2.1.3",
"@types/styled-components": "^5.1.11"
"@types/react-qr-reader": "^2.1.4",
"@types/styled-components": "^5.1.15"
},
"peerDependencies": {
"@polkadot/util": "*",
+4 -5
View File
@@ -4,6 +4,7 @@
import React, { useEffect, useMemo, useRef, useState } from 'react';
import styled from 'styled-components';
import { objectSpread } from '@polkadot/util';
import { xxhashAsHex } from '@polkadot/util-crypto';
import { qrcode } from './qrcode';
@@ -37,8 +38,7 @@ function getDataUrl (value: Uint8Array): string {
// HACK See our qrcode stringToBytes override as used internally. This
// will only work for the case where we actually pass `Bytes` in here
// eslint-disable-next-line @typescript-eslint/no-explicit-any
qr.addData(value as any, 'Byte');
qr.addData(value as unknown as string, 'Byte');
qr.make();
return qr.createDataURL(16, 0);
@@ -74,11 +74,10 @@ function Display ({ className, size, skipEncoding, style, value }: Props): React
// only encode the frames on demand, not above as part of the
// state derivation - in the case of large payloads, this should
// be slightly more responsive on initial load
return {
...state,
return objectSpread({}, state, {
frameIdx,
image: getDataUrl(state.frames[frameIdx])
};
});
});
timerRef.current.timerId = window.setTimeout(nextFrame, FRAME_DELAY);
+3 -1
View File
@@ -1,12 +1,14 @@
// Copyright 2017-2021 @polkadot/react-qr authors & contributors
// SPDX-License-Identifier: Apache-2.0
import type { HexString } from '@polkadot/util/types';
import React, { useCallback } from 'react';
import { QrScan } from './Scan';
interface ScanType {
signature: string;
signature: HexString;
}
interface Props {
+1 -1
View File
@@ -3,4 +3,4 @@
// Auto-generated by @polkadot/dev, do not edit
export const packageInfo = { name: '@polkadot/react-qr', version: '0.83.1' };
export const packageInfo = { name: '@polkadot/react-qr', version: '0.87.1' };
+23 -15
View File
@@ -1,30 +1,38 @@
{
"name": "@polkadot/reactnative-identicon",
"version": "0.83.1",
"type": "module",
"author": "Jaco Greeff <jacogr@gmail.com>",
"bugs": "https://github.com/polkadot-js/ui/issues",
"contributors": [],
"description": "Renders an SVG picture representing an address",
"main": "index.js",
"homepage": "https://github.com/polkadot-js/ui/tree/master/packages/reactnative-identicon#readme",
"license": "Apache-2.0",
"maintainers": [],
"name": "@polkadot/reactnative-identicon",
"repository": {
"directory": "packages/reactnative-identicon",
"type": "git",
"url": "https://github.com/polkadot-js/ui.git"
},
"sideEffects": [
"./detectPackage.js",
"./detectPackage.cjs"
],
"author": "Jaco Greeff <jacogr@gmail.com>",
"maintainers": [],
"license": "Apache-2.0",
"type": "module",
"version": "0.87.1",
"main": "index.js",
"dependencies": {
"@babel/runtime": "^7.14.6",
"@polkadot/ui-shared": "0.83.1",
"@polkadot/util": "^6.11.1",
"@polkadot/util-crypto": "^6.11.1",
"react-native-svg": "^12.1.1"
"@babel/runtime": "^7.16.3",
"@polkadot/ui-shared": "0.87.1",
"@polkadot/util": "^8.0.2",
"@polkadot/util-crypto": "^8.0.2",
"react-native-svg": "^12.2.0"
},
"devDependencies": {
"@types/react-native": "^0.66.6"
},
"peerDependencies": {
"@polkadot/util": "*",
"@polkadot/util-crypto": "*",
"react": "*",
"react-native": "*"
},
"devDependencies": {
"@types/react-native": "^0.64.10"
}
}
@@ -3,4 +3,4 @@
// Auto-generated by @polkadot/dev, do not edit
export const packageInfo = { name: '@polkadot/reactnative-identicon', version: '0.83.1' };
export const packageInfo = { name: '@polkadot/reactnative-identicon', version: '0.87.1' };
+15 -6
View File
@@ -1,12 +1,21 @@
{
"name": "@polkadot/ui-assets",
"version": "0.83.1",
"description": "Static assets shared accross projects",
"main": "index.js",
"author": "Jaco Greeff <jacogr@gmail.com>",
"maintainers": [],
"bugs": "https://github.com/polkadot-js/ui/issues",
"contributors": [],
"description": "Static assets shared accross projects",
"homepage": "https://github.com/polkadot-js/ui/tree/master/packages/ui-assets#readme",
"license": "Apache-2.0",
"maintainers": [],
"name": "@polkadot/ui-assets",
"repository": {
"directory": "packages/ui-assets",
"type": "git",
"url": "https://github.com/polkadot-js/ui.git"
},
"sideEffects": false,
"version": "0.87.1",
"main": "index.js",
"dependencies": {
"@babel/runtime": "^7.14.6"
"@babel/runtime": "^7.16.3"
}
}
+1 -1
View File
@@ -3,4 +3,4 @@
// Auto-generated by @polkadot/dev, do not edit
export const packageInfo = { name: '@polkadot/ui-assets', version: '0.83.1' };
export const packageInfo = { name: '@polkadot/ui-assets', version: '0.87.1' };
+1 -1
View File
@@ -40,7 +40,7 @@ import accountObservable from '@polkadot/ui-keyring/observable/accounts';
import { SingleAddress, SubjectInfo } from '@polkadot/ui-keyring/observable/types';
import React from 'react';
import { Subscribe } from 'react-with-observable';
import { map } from 'rxjs/operators';
import { map } from 'rxjs';
class MyReactComponent extends React.PureComponent {
render () {
+21 -15
View File
@@ -1,29 +1,35 @@
{
"author": "Jaco Greeff <jacogr@gmail.com>",
"bugs": "https://github.com/polkadot-js/ui/issues",
"contributors": [],
"homepage": "https://github.com/polkadot-js/ui/tree/master/packages/ui-keyring#readme",
"license": "Apache-2.0",
"maintainers": [],
"name": "@polkadot/ui-keyring",
"version": "0.83.1",
"type": "module",
"main": "index.js",
"repository": {
"directory": "packages/ui-keyring",
"type": "git",
"url": "https://github.com/polkadot-js/ui.git"
},
"sideEffects": [
"./detectPackage.js",
"./detectPackage.cjs"
],
"repository": "github:polkadot-js/apps",
"author": "Jaco Greeff <jacogr@gmail.com>",
"maintainers": [],
"contributors": [],
"license": "Apache-2.0",
"type": "module",
"version": "0.87.1",
"main": "index.js",
"dependencies": {
"@babel/runtime": "^7.14.6",
"@polkadot/hw-ledger": "^6.11.1",
"@polkadot/keyring": "^6.11.1",
"@polkadot/ui-settings": "0.83.1",
"@polkadot/util": "^6.11.1",
"@polkadot/x-rxjs": "^6.11.1",
"@babel/runtime": "^7.16.3",
"@polkadot/hw-ledger": "^8.0.2",
"@polkadot/keyring": "^8.0.2",
"@polkadot/ui-settings": "0.87.1",
"@polkadot/util": "^8.0.2",
"mkdirp": "^1.0.4",
"rxjs": "^7.4.0",
"store": "^2.0.12"
},
"devDependencies": {
"@types/mkdirp": "^1.0.1",
"@types/mkdirp": "^1.0.2",
"@types/store": "^2.0.2"
},
"peerDependencies": {
+3 -3
View File
@@ -6,7 +6,7 @@ import type { Prefix } from '@polkadot/util-crypto/address/types';
import type { AddressSubject } from './observable/types';
import type { KeyringOptions, KeyringStore } from './types';
import { createTestKeyring } from '@polkadot/keyring/testing';
import { createTestKeyring } from '@polkadot/keyring';
import { isBoolean, isNumber, isString } from '@polkadot/util';
import { accounts } from './observable/accounts';
@@ -61,11 +61,11 @@ export class Base {
public decodeAddress = (key: string | Uint8Array, ignoreChecksum?: boolean, ss58Format?: Prefix): Uint8Array => {
return this.keyring.decodeAddress(key, ignoreChecksum, ss58Format);
}
};
public encodeAddress = (key: string | Uint8Array, ss58Format?: Prefix): string => {
return this.keyring.encodeAddress(key, ss58Format);
}
};
public getPair (address: string | Uint8Array): KeyringPair {
return this.keyring.getPair(address);
+15 -15
View File
@@ -8,9 +8,9 @@ import type { KeypairType } from '@polkadot/util-crypto/types';
import type { AddressSubject, SingleAddress } from './observable/types';
import type { CreateResult, KeyringAddress, KeyringAddressType, KeyringItemType, KeyringJson, KeyringJson$Meta, KeyringOptions, KeyringPairs$Json, KeyringStruct } from './types';
import { createPair } from '@polkadot/keyring/pair';
import { chains } from '@polkadot/ui-settings/defaults/chains';
import { bnToBn, hexToU8a, isHex, isString, stringToU8a, u8aSorted, u8aToString } from '@polkadot/util';
import { createPair } from '@polkadot/keyring';
import { chains } from '@polkadot/ui-settings';
import { bnToBn, hexToU8a, isHex, isString, objectSpread, stringToU8a, u8aSorted, u8aToString } from '@polkadot/util';
import { base64Decode, createKeyMulti, jsonDecrypt, jsonEncrypt } from '@polkadot/util-crypto';
import { env } from './observable/env';
@@ -33,7 +33,7 @@ export class Keyring extends Base implements KeyringStruct {
};
public addExternal (address: string | Uint8Array, meta: KeyringPair$Meta = {}): CreateResult {
const pair = this.keyring.addFromAddress(address, { ...meta, isExternal: true }, null);
const pair = this.keyring.addFromAddress(address, objectSpread<KeyringJson$Meta>({}, meta, { isExternal: true }), null);
return {
json: this.saveAccount(pair),
@@ -42,16 +42,16 @@ export class Keyring extends Base implements KeyringStruct {
}
public addHardware (address: string | Uint8Array, hardwareType: string, meta: KeyringPair$Meta = {}): CreateResult {
return this.addExternal(address, { ...meta, hardwareType, isHardware: true });
return this.addExternal(address, objectSpread<KeyringPair$Meta>({}, meta, { hardwareType, isHardware: true }));
}
public addMultisig (addresses: (string | Uint8Array)[], threshold: BigInt | BN | number, meta: KeyringPair$Meta = {}): CreateResult {
public addMultisig (addresses: (string | Uint8Array)[], threshold: bigint | BN | number, meta: KeyringPair$Meta = {}): CreateResult {
const address = createKeyMulti(addresses, threshold);
// we could use `sortAddresses`, but rather use internal encode/decode so we are 100%
const who = u8aSorted(addresses.map((who) => this.decodeAddress(who))).map((who) => this.encodeAddress(who));
return this.addExternal(address, { ...meta, isMultisig: true, threshold: bnToBn(threshold).toNumber(), who });
return this.addExternal(address, objectSpread<KeyringPair$Meta>({}, meta, { isMultisig: true, threshold: bnToBn(threshold).toNumber(), who }));
}
public addPair (pair: KeyringPair, password: string): CreateResult {
@@ -91,17 +91,20 @@ export class Keyring extends Base implements KeyringStruct {
const accounts = await Promise.all(accountPromises);
return {
...jsonEncrypt(stringToU8a(JSON.stringify(accounts)), ['batch-pkcs8'], password),
return objectSpread({}, jsonEncrypt(stringToU8a(JSON.stringify(accounts)), ['batch-pkcs8'], password), {
accounts: accounts.map((account) => ({
address: account.address,
meta: account.meta
}))
};
});
}
public createFromJson (json: KeyringPair$Json, meta: KeyringPair$Meta = {}): KeyringPair {
return this.keyring.createFromJson({ ...json, meta: { ...(json.meta || {}), meta } });
return this.keyring.createFromJson(
objectSpread({}, json, {
meta: objectSpread({}, json.meta, meta)
})
);
}
public createFromUri (suri: string, meta: KeyringPair$Meta = {}, type?: KeypairType): KeyringPair {
@@ -249,10 +252,7 @@ export class Keyring extends Base implements KeyringStruct {
private loadInjected (address: string, meta: KeyringJson$Meta, type?: KeypairType): void {
const json = {
address,
meta: {
...meta,
isInjected: true
}
meta: objectSpread<KeyringJson$Meta>({}, meta, { isInjected: true })
};
const pair = this.keyring.addFromAddress(address, json.meta, null, type);
+11
View File
@@ -0,0 +1,11 @@
// Copyright 2017-2021 @polkadot/ui-keyring authors & contributors
// SPDX-License-Identifier: Apache-2.0
import { Keyring } from './Keyring';
export { Ledger } from '@polkadot/hw-ledger';
export { packageInfo } from './packageInfo';
const keyring = new Keyring();
export { Keyring, keyring };
+2 -7
View File
@@ -3,13 +3,8 @@
import './detectPackage';
import { Keyring } from './Keyring';
import { keyring } from './bundle';
export { Ledger } from '@polkadot/hw-ledger';
export { packageInfo } from './packageInfo';
const keyring = new Keyring();
export { Keyring, keyring };
export * from './bundle';
export default keyring;
+1 -1
View File
@@ -1,7 +1,7 @@
// Copyright 2017-2021 @polkadot/ui-keyring authors & contributors
// SPDX-License-Identifier: Apache-2.0
import { BehaviorSubject } from '@polkadot/x-rxjs';
import { BehaviorSubject } from 'rxjs';
const subject = new BehaviorSubject(false);
@@ -5,7 +5,9 @@ import type { KeypairType } from '@polkadot/util-crypto/types';
import type { KeyringJson, KeyringStore } from '../types';
import type { AddressSubject, SingleAddress, SubjectInfo } from './types';
import { BehaviorSubject } from '@polkadot/x-rxjs';
import { BehaviorSubject } from 'rxjs';
import { objectCopy, objectSpread } from '@polkadot/util';
import { createOptionItem } from '../options/item';
import { env } from './env';
@@ -34,10 +36,10 @@ export function genericSubject (keyCreator: (address: string) => string, withTes
return {
add: (store: KeyringStore, address: string, json: KeyringJson, type?: KeypairType): SingleAddress => {
current = { ...current };
current = objectCopy(current);
current[address] = {
json: { ...json, address },
json: objectSpread({}, json, { address }),
option: createOptionItem(address, json.meta.name),
type
};
@@ -52,7 +54,7 @@ export function genericSubject (keyCreator: (address: string) => string, withTes
return current[address];
},
remove: (store: KeyringStore, address: string): void => {
current = { ...current };
current = objectCopy(current);
delete current[address];
+3 -4
View File
@@ -3,8 +3,7 @@
import type { SubjectInfo } from './types';
import { combineLatest } from '@polkadot/x-rxjs';
import { map } from '@polkadot/x-rxjs/operators';
import { combineLatest, map } from 'rxjs';
import { accounts } from './accounts';
import { addresses } from './addresses';
@@ -16,11 +15,11 @@ interface Result {
contracts: SubjectInfo;
}
export const obervableAll = combineLatest(
export const obervableAll = combineLatest([
accounts.subject,
addresses.subject,
contracts.subject
).pipe(
]).pipe(
map(([accounts, addresses, contracts]): Result => ({
accounts,
addresses,
+1 -1
View File
@@ -1,8 +1,8 @@
// Copyright 2017-2021 @polkadot/ui-keyring authors & contributors
// SPDX-License-Identifier: Apache-2.0
import type { BehaviorSubject } from 'rxjs';
import type { KeypairType } from '@polkadot/util-crypto/types';
import type { BehaviorSubject } from '@polkadot/x-rxjs';
import type { KeyringSectionOption } from '../options/types';
import type { KeyringJson, KeyringStore } from '../types';
+2 -1
View File
@@ -5,8 +5,9 @@ import type { SingleAddress } from '../observable/types';
import type { KeyringStruct } from '../types';
import type { KeyringOptionInstance, KeyringOptions, KeyringSectionOption, KeyringSectionOptions } from './types';
import { BehaviorSubject } from 'rxjs';
import { assert } from '@polkadot/util';
import { BehaviorSubject } from '@polkadot/x-rxjs';
import { obervableAll } from '../observable';
+1 -1
View File
@@ -3,4 +3,4 @@
// Auto-generated by @polkadot/dev, do not edit
export const packageInfo = { name: '@polkadot/ui-keyring', version: '0.83.1' };
export const packageInfo = { name: '@polkadot/ui-keyring', version: '0.87.1' };
+2 -1
View File
@@ -13,7 +13,8 @@ export class BrowserStore implements KeyringStore {
}
public get (key: string, cb: (value: KeyringJson) => void): void {
cb(store.get(key));
// eslint-disable-next-line node/no-callback-literal
cb(store.get(key) as KeyringJson);
}
public remove (key: string, cb?: () => void): void {
+18 -10
View File
@@ -1,17 +1,25 @@
{
"name": "@polkadot/ui-settings",
"version": "0.83.1",
"type": "module",
"description": "Manages app settings",
"main": "index.js",
"sideEffects": false,
"author": "Jaco Greeff <jacogr@gmail.com>",
"maintainers": [],
"bugs": "https://github.com/polkadot-js/ui/issues",
"contributors": [],
"description": "Manages app settings",
"homepage": "https://github.com/polkadot-js/ui/tree/master/packages/ui-settings#readme",
"license": "Apache-2.0",
"maintainers": [],
"name": "@polkadot/ui-settings",
"repository": {
"directory": "packages/ui-settings",
"type": "git",
"url": "https://github.com/polkadot-js/ui.git"
},
"sideEffects": false,
"type": "module",
"version": "0.87.1",
"main": "index.js",
"dependencies": {
"@babel/runtime": "^7.14.6",
"@polkadot/networks": "^6.11.1",
"@polkadot/util": "^6.11.1",
"@babel/runtime": "^7.16.3",
"@polkadot/networks": "^8.0.2",
"@polkadot/util": "^8.0.2",
"eventemitter3": "^4.0.7",
"store": "^2.0.12"
},
+1 -1
View File
@@ -53,7 +53,7 @@ export class Settings implements SettingsStruct {
this.#emitter = new EventEmitter();
// will become deprecated for supporting substrate connect light clients. apiType structure should be used instead
this.#apiUrl = (typeof settings.apiUrl === 'string' && settings.apiUrl) || process.env.WS_URL || (ENDPOINT_DEFAULT.value as string);
this.#apiUrl = (typeof settings.apiUrl === 'string' && settings.apiUrl) || (process && process.env && process.env.WS_URL) || (ENDPOINT_DEFAULT.value as string);
this.#apiType = { param: this.#apiUrl, type: 'json-rpc' as EndpointType };
this.#camera = withDefault(CAMERA, settings.camera, CAMERA_DEFAULT);
this.#ledgerConn = withDefault(LEDGER_CONN, settings.ledgerConn, LEDGER_CONN_DEFAULT);
+10
View File
@@ -0,0 +1,10 @@
// Copyright 2017-2021 @polkadot/ui-settings authors & contributors
// SPDX-License-Identifier: Apache-2.0
import { Settings, settings } from './Settings';
export { ENDPOINT_DEFAULT, ICON_DEFAULT, ICON_DEFAULT_HOST, LANGUAGE_DEFAULT, LOCKING_DEFAULT, PREFIX_DEFAULT, UIMODE_DEFAULT, UITHEME_DEFAULT } from './defaults';
export { chains } from './defaults/chains';
export { packageInfo } from './packageInfo';
export { settings, Settings };
+4 -3
View File
@@ -1,12 +1,13 @@
// Copyright 2017-2021 @polkadot/ui-settings authors & contributors
// SPDX-License-Identifier: Apache-2.0
import known from '@polkadot/networks';
import { selectableNetworks } from '@polkadot/networks';
import { objectSpread } from '@polkadot/util';
type ChainDef = string[];
const chains: Record <string, ChainDef> = known
const chains: Record <string, ChainDef> = selectableNetworks
.filter((n) => n.genesisHash.length)
.reduce((chains, { genesisHash, network }) => ({ ...chains, [network]: genesisHash }), {});
.reduce((chains, { genesisHash, network }) => objectSpread(chains, { [network]: genesisHash }), {});
export { chains };
+2 -2
View File
@@ -3,7 +3,7 @@
import type { Option } from '../types';
import { available } from '@polkadot/networks';
import { availableNetworks } from '@polkadot/networks';
export const PREFIX_DEFAULT = -1;
@@ -13,7 +13,7 @@ const defaultNetwork: Option = {
value: -1
};
const networks = available.map(({ displayName, network, prefix }) => ({
const networks = availableNetworks.map(({ displayName, network, prefix }) => ({
info: network,
text: displayName,
value: prefix
+2 -5
View File
@@ -1,11 +1,8 @@
// Copyright 2017-2021 @polkadot/ui-settings authors & contributors
// SPDX-License-Identifier: Apache-2.0
import { Settings, settings } from './Settings';
import { settings } from './bundle';
export { ENDPOINT_DEFAULT, ICON_DEFAULT, ICON_DEFAULT_HOST, LANGUAGE_DEFAULT, LOCKING_DEFAULT, PREFIX_DEFAULT, UIMODE_DEFAULT, UITHEME_DEFAULT } from './defaults';
export { packageInfo } from './packageInfo';
export { settings, Settings };
export * from './bundle';
export default settings;
+1 -1
View File
@@ -3,4 +3,4 @@
// Auto-generated by @polkadot/dev, do not edit
export const packageInfo = { name: '@polkadot/ui-settings', version: '0.83.1' };
export const packageInfo = { name: '@polkadot/ui-settings', version: '0.87.1' };
+23 -15
View File
@@ -1,25 +1,33 @@
{
"name": "@polkadot/ui-shared",
"version": "0.83.1",
"type": "module",
"description": "Shared logic that is usable accross all frameworks-specific areas",
"main": "index.js",
"sideEffects": false,
"author": "Jaco Greeff <jacogr@gmail.com>",
"maintainers": [],
"bugs": "https://github.com/polkadot-js/ui/issues",
"contributors": [],
"description": "Shared logic that is usable accross all frameworks-specific areas",
"homepage": "https://github.com/polkadot-js/ui/tree/master/packages/ui-shared#readme",
"license": "Apache-2.0",
"maintainers": [],
"name": "@polkadot/ui-shared",
"repository": {
"directory": "packages/ui-shared",
"type": "git",
"url": "https://github.com/polkadot-js/ui.git"
},
"sideEffects": false,
"type": "module",
"version": "0.87.1",
"main": "index.js",
"dependencies": {
"@babel/runtime": "^7.14.6",
"color": "^3.1.3"
"@babel/runtime": "^7.16.3",
"color": "^3.2.1"
},
"devDependencies": {
"@polkadot/util": "^8.0.2",
"@polkadot/util-crypto": "^8.0.2",
"@types/color": "^3.0.2",
"@types/xmlserializer": "^0.6.2"
},
"peerDependencies": {
"@polkadot/util": "*",
"@polkadot/util-crypto": "*"
},
"devDependencies": {
"@polkadot/util": "^6.11.1",
"@polkadot/util-crypto": "^6.11.1",
"@types/color": "^3.0.1",
"@types/xmlserializer": "^0.6.2"
}
}
+1 -1
View File
@@ -3,4 +3,4 @@
// Auto-generated by @polkadot/dev, do not edit
export const packageInfo = { name: '@polkadot/ui-shared', version: '0.83.1' };
export const packageInfo = { name: '@polkadot/ui-shared', version: '0.87.1' };
+22 -14
View File
@@ -1,29 +1,37 @@
{
"name": "@polkadot/vue-identicon",
"version": "0.83.1",
"type": "module",
"description": "Renders an SVG picture representing an address",
"author": "Jaco Greeff <jacogr@gmail.com>",
"bugs": "https://github.com/polkadot-js/ui/issues",
"contributors": [],
"description": "Renders an SVG picture representing an address",
"homepage": "https://github.com/polkadot-js/ui/tree/master/packages/vue-identicon#readme",
"license": "Apache-2.0",
"maintainers": [],
"main": "index.js",
"name": "@polkadot/vue-identicon",
"repository": {
"directory": "packages/vue-identicon",
"type": "git",
"url": "https://github.com/polkadot-js/ui.git"
},
"sideEffects": [
"./detectPackage.js",
"./detectPackage.cjs"
],
"license": "Apache-2.0",
"type": "module",
"version": "0.87.1",
"main": "index.js",
"dependencies": {
"@babel/runtime": "^7.14.6",
"@polkadot/ui-shared": "0.83.1",
"@polkadot/util": "^6.11.1",
"@polkadot/util-crypto": "^6.11.1",
"jdenticon": "3.1.0"
"@babel/runtime": "^7.16.3",
"@polkadot/ui-shared": "0.87.1",
"@polkadot/util": "^8.0.2",
"@polkadot/util-crypto": "^8.0.2",
"jdenticon": "3.1.1"
},
"devDependencies": {
"vue": "^2.6.14"
},
"peerDependencies": {
"@polkadot/util": "*",
"@polkadot/util-crypto": "*",
"vue": "*"
},
"devDependencies": {
"vue": "^2.6.14"
}
}
+1 -1
View File
@@ -71,7 +71,7 @@ export const Identicon = Vue.extend({
this.recodeAddress();
},
recodeAddress: function (): void {
const { address, publicKey } = encodeAccount(this.value);
const { address, publicKey } = encodeAccount(this.value as string);
this.address = address;
this.publicKey = publicKey;
+6
View File
@@ -0,0 +1,6 @@
// Copyright 2017-2021 @polkadot/vue-identicon authors & contributors
// SPDX-License-Identifier: Apache-2.0
export { Identicon } from './Identicon';
export { packageInfo } from './packageInfo';
@@ -1,6 +1,8 @@
// Copyright 2017-2021 @polkadot/vue-identicon authors & contributors
// SPDX-License-Identifier: Apache-2.0
import type { Options } from '@polkadot/ui-shared/icons/types';
import Vue from 'vue';
import { beachballIcon } from '@polkadot/ui-shared';
@@ -25,7 +27,7 @@ export const Beachball = Vue.extend({
},
methods: {
createHtml: function (): void {
this.html = beachballIcon(this.address, this.size).outerHTML;
this.html = beachballIcon(this.address as string, this.size as Options).outerHTML;
}
},
props: ['address', 'size'],
@@ -24,7 +24,7 @@ export const Jdenticon = Vue.extend({
},
methods: {
createSvgHtml: function (): void {
this.svgHtml = jdenticon.toSvg((this.publicKey as string).substr(2), this.size);
this.svgHtml = jdenticon.toSvg((this.publicKey as string).substr(2), this.size as number);
}
},
props: ['publicKey', 'size'],
+1 -1
View File
@@ -30,7 +30,7 @@ export const Polkadot = Vue.extend({
},
methods: {
createSvgHtml: function (): void {
const circles = polkadotIcon(this.address, { isAlternative: (this as This).isAlternative || false }).map(({ cx, cy, fill, r }) =>
const circles = polkadotIcon(this.address as string, { isAlternative: (this as This).isAlternative || false }).map(({ cx, cy, fill, r }) =>
`<circle cx=${cx} cy=${cy} fill="${fill}" r=${r} />`
).join('');
+2 -2
View File
@@ -3,8 +3,8 @@
import './detectPackage';
import { Identicon } from './Identicon';
import { Identicon } from './bundle';
export { packageInfo } from './packageInfo';
export * from './bundle';
export default Identicon;
+1 -1
View File
@@ -3,4 +3,4 @@
// Auto-generated by @polkadot/dev, do not edit
export const packageInfo = { name: '@polkadot/vue-identicon', version: '0.83.1' };
export const packageInfo = { name: '@polkadot/vue-identicon', version: '0.87.1' };
+58
View File
@@ -0,0 +1,58 @@
// Copyright 2017-2021 @polkadot/ui authors & contributors
// SPDX-License-Identifier: Apache-2.0
import path from 'path';
import { createBundle } from '@polkadot/dev/config/rollup';
const pkgs = [
'@polkadot/react-identicon',
'@polkadot/react-qr',
'@polkadot/ui-keyring',
'@polkadot/ui-settings',
'@polkadot/vue-identicon'
];
const external = [
...pkgs,
'@polkadot/hw-ledger',
'@polkadot/keyring',
'@polkadot/util',
'@polkadot/util-crypto',
'react',
'react-dom',
'vue',
'vue-router'
];
const globals = {
react: 'React',
'react-dom': 'ReactDOM',
vue: 'Vue',
'vue-router': 'VueRouter'
};
const entries = ['ui-shared'].reduce((all, p) => ({
...all,
[`@polkadot/${p}`]: path.resolve(process.cwd(), `packages/${p}/build`)
}), {
// re-exported in @polkadot/util-crypto, map directly
'@polkadot/networks': '@polkadot/util-crypto'
});
const overrides = {};
export default pkgs.map((pkg) => {
const override = (overrides[pkg] || {});
return createBundle({
external,
globals,
pkg,
...override,
entries: {
...entries,
...(override.entries || {})
}
});
});
+2502 -2346
View File
File diff suppressed because it is too large Load Diff