@rabbitio/ui-kit 1.0.0-beta.10 → 1.0.0-beta.12
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 +0 -0
- package/README.md +14 -14
- package/dist/index.cjs +1483 -6
- package/dist/index.cjs.map +1 -1
- package/dist/index.modern.js +1199 -6
- package/dist/index.modern.js.map +1 -1
- package/dist/index.module.js +1473 -7
- package/dist/index.module.js.map +1 -1
- package/dist/index.umd.js +1486 -10
- package/dist/index.umd.js.map +1 -1
- package/package.json +1 -1
- package/src/common/models/blockchain.js +10 -0
- package/src/common/models/coin.js +157 -0
- package/src/common/models/protocol.js +5 -0
- package/src/common/utils/cache.js +268 -0
- package/src/common/utils/logging/logger.js +48 -0
- package/src/common/utils/logging/logsStorage.js +61 -0
- package/src/common/utils/safeStringify.js +50 -0
- package/src/components/atoms/AssetIcon/AssetIcon.jsx +5 -5
- package/src/index.js +15 -1
- package/src/swaps-lib/external-apis/swapProvider.js +169 -0
- package/src/swaps-lib/external-apis/swapspaceSwapProvider.js +798 -0
- package/src/swaps-lib/models/existingSwap.js +58 -0
package/CHANGELOG.md
ADDED
|
File without changes
|
package/README.md
CHANGED
|
@@ -1,30 +1,30 @@
|
|
|
1
1
|
# Installation
|
|
2
|
-
~~~
|
|
2
|
+
~~~bash
|
|
3
3
|
npm install --save @rabbitio/ui-kit
|
|
4
4
|
~~~
|
|
5
5
|
|
|
6
6
|
# Using library
|
|
7
|
-
1. To use components for web:
|
|
7
|
+
1. To use components or base modules for web:
|
|
8
8
|
* import the following way
|
|
9
|
-
~~~
|
|
10
|
-
import { Button } from "@rabbitio/ui-kit";
|
|
9
|
+
~~~javascript
|
|
10
|
+
import { Button, AmountUtils } from "@rabbitio/ui-kit";
|
|
11
11
|
~~~
|
|
12
12
|
* add top-level styles import
|
|
13
|
-
~~~
|
|
13
|
+
~~~javascript
|
|
14
14
|
import "@rabbitio/ui-kit/index.css";
|
|
15
15
|
~~~
|
|
16
|
-
2. To use components for next.js import the following way and add "@rabbitio/ui-kit" to transpilePackages inside your next.config.js:
|
|
16
|
+
2. To use components or base modules for next.js import the following way and add "@rabbitio/ui-kit" to transpilePackages inside your next.config.js:
|
|
17
17
|
|
|
18
|
-
|
|
19
|
-
~~~
|
|
18
|
+
~~~javascript
|
|
20
19
|
import { Button } from "@rabbitio/ui-kit/next";
|
|
20
|
+
import { AmountUtils } from "@rabbitio/ui-kit";
|
|
21
21
|
~~~
|
|
22
22
|
* add "@rabbitio/ui-kit" to transpilePackages in next.config.js
|
|
23
|
-
~~~
|
|
23
|
+
~~~javascript
|
|
24
24
|
transpilePackages: ["@rabbitio/ui-kit"],
|
|
25
25
|
~~~
|
|
26
26
|
* Import styles inside pages/_app.js
|
|
27
|
-
~~~
|
|
27
|
+
~~~javascript
|
|
28
28
|
import "@rabbitio/ui-kit/index.css";
|
|
29
29
|
~~~
|
|
30
30
|
|
|
@@ -32,22 +32,22 @@ import "@rabbitio/ui-kit/index.css";
|
|
|
32
32
|
1. Add a directory for component under the semantically corresponding subdirectory inside **./stories**
|
|
33
33
|
2. Under the component directory implement 3 files: **<Component>.js**, **<Component>.module.scss**, **<Component>.stories.js**
|
|
34
34
|
3. Add the implemented component import to barrel file **./stories/index.js**
|
|
35
|
-
~~~
|
|
35
|
+
~~~javascript
|
|
36
36
|
export { default as <Component> } from "./path/to/<Component>";
|
|
37
37
|
~~~
|
|
38
38
|
|
|
39
39
|
# Running storybook
|
|
40
|
-
~~~
|
|
40
|
+
~~~bash
|
|
41
41
|
sudo docker build -t storybook-app .
|
|
42
42
|
~~~
|
|
43
|
-
~~~
|
|
43
|
+
~~~bash
|
|
44
44
|
sudo docker run -d -p 6006:6006 storybook-app
|
|
45
45
|
~~~
|
|
46
46
|
|
|
47
47
|
# Publishing
|
|
48
48
|
1. Increase version number and commit
|
|
49
49
|
2. Run:
|
|
50
|
-
~~~
|
|
50
|
+
~~~bash
|
|
51
51
|
npm login
|
|
52
52
|
npm publish --access public
|
|
53
53
|
~~~
|