dhre-ui-kit 0.0.63 → 0.0.64

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "dhre-ui-kit",
3
- "version": "0.0.63",
3
+ "version": "0.0.64",
4
4
  "main": "src/index.ts",
5
5
  "files": [
6
6
  "src",
@@ -23,6 +23,7 @@
23
23
  "prepare": "husky"
24
24
  },
25
25
  "dependencies": {
26
+ "@react-native-clipboard/clipboard": "^1.14.2",
26
27
  "@react-native-community/blur": "^4.4.1",
27
28
  "@testing-library/react-native": "^12.5.1",
28
29
  "lint-staged": "^15.2.7",
package/src/index.ts CHANGED
@@ -47,6 +47,7 @@ export {
47
47
  horizontalScale,
48
48
  moderateScale,
49
49
  } from './utils/stylehelper';
50
+ export {copyToClipboard} from './utils/deviceUtils';
50
51
 
51
52
  export {default} from './theme/themes';
52
53
  export {useToast} from './components/toast/ToastProvider';
@@ -1,4 +1,5 @@
1
1
  import {Platform} from 'react-native';
2
+ import Clipboard from '@react-native-clipboard/clipboard';
2
3
 
3
4
  export enum OS {
4
5
  ios = 'ios',
@@ -7,3 +8,7 @@ export enum OS {
7
8
 
8
9
  export const isIos = () => Platform.OS === OS.ios;
9
10
  export const isAndroid = () => Platform.OS === OS.android;
11
+
12
+ export const copyToClipboard = (textToCopy: string) => {
13
+ Clipboard.setString(textToCopy);
14
+ };