We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 13c6f74 commit b563683Copy full SHA for b563683
live-view.js
@@ -61,13 +61,26 @@ function addBottomSwipeListener() {
61
62
const shareData = {
63
title: 'Share live view',
64
- content: window.location.origin
+ content: 'Open ' + selectedFile.name + ' with Codeit: ' +
65
+ window.location.origin + '/?q=' + encodeURIComponent(treeLoc.join(',') + '+' + selectedFile.name + ',' + selectedFile.sha)
66
}
67
- try {
68
- navigator.share(shareData);
69
- } catch(e) {
70
- console.info('[Share API] Couldn\'t share.');
+ if (isMobile) {
+
+ try {
71
72
+ navigator.share(shareData);
73
74
+ } catch(e) {
75
76
+ copy(shareData.content);
77
78
+ }
79
80
+ } else {
81
82
83
84
85
86
0 commit comments