dreaction-react-native 1.3.2 → 1.3.3

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.
@@ -39,7 +39,7 @@ const react_1 = __importStar(require("react"));
39
39
  const react_native_1 = require("react-native");
40
40
  const ConfigDialog_1 = require("./ConfigDialog");
41
41
  const dreaction_1 = require("../dreaction");
42
- const getHost_1 = require("../helpers/getHost");
42
+ const parseURL_1 = require("../helpers/parseURL");
43
43
  const { width: SCREEN_WIDTH, height: SCREEN_HEIGHT } = react_native_1.Dimensions.get('window');
44
44
  const BALL_SIZE = 60;
45
45
  const CLICK_THRESHOLD = 5;
@@ -63,7 +63,7 @@ exports.DraggableBall = react_1.default.memo(() => {
63
63
  }, []);
64
64
  const handleClick = (value) => {
65
65
  try {
66
- const host = (0, getHost_1.getHost)(value);
66
+ const host = (0, parseURL_1.getHostFromUrl)(value);
67
67
  dreaction_1.dreaction
68
68
  .configure({
69
69
  host,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "dreaction-react-native",
3
- "version": "1.3.2",
3
+ "version": "1.3.3",
4
4
  "private": false,
5
5
  "description": "",
6
6
  "main": "lib/index.js",
@@ -15,8 +15,8 @@
15
15
  "author": "moonrailgun <moonrailgun@gmail.com>",
16
16
  "license": "MIT",
17
17
  "dependencies": {
18
- "dreaction-protocol": "1.0.1",
19
- "dreaction-client-core": "1.1.2"
18
+ "dreaction-client-core": "1.1.3",
19
+ "dreaction-protocol": "1.0.1"
20
20
  },
21
21
  "devDependencies": {
22
22
  "@types/react-native": "^0.73.0",
@@ -9,7 +9,7 @@ import {
9
9
  } from 'react-native';
10
10
  import { ConfigDialog } from './ConfigDialog';
11
11
  import { dreaction } from '../dreaction';
12
- import { getHost } from '../helpers/getHost';
12
+ import { getHostFromUrl } from '../helpers/parseURL';
13
13
 
14
14
  const { width: SCREEN_WIDTH, height: SCREEN_HEIGHT } = Dimensions.get('window');
15
15
  const BALL_SIZE = 60;
@@ -39,7 +39,7 @@ export const DraggableBall: React.FC = React.memo(() => {
39
39
 
40
40
  const handleClick = (value: string) => {
41
41
  try {
42
- const host = getHost(value);
42
+ const host = getHostFromUrl(value);
43
43
 
44
44
  dreaction
45
45
  .configure({