anzorq commited on
Commit
3c77b11
1 Parent(s): 9273d53

Update share_btn.py

Browse files
Files changed (1) hide show
  1. share_btn.py +10 -9
share_btn.py CHANGED
@@ -58,19 +58,20 @@ share_js = """async () => {
58
  shareIconEl.style.display = 'none';
59
  loadingIconEl.style.removeProperty('display');
60
 
61
- const video = await getVideoFile(videoEl);
 
62
 
63
  const descriptionMd = `Prompt: ${title}
64
- Feel: ${feel}
65
- Seed: ${seed}
66
 
67
- #### Video:
68
 
69
- <video controls>
70
- <source src="${video}" type="video/mp4">
71
- Your browser does not support the video element.
72
- </video>
73
- `;
74
 
75
  const params = new URLSearchParams({
76
  title: title,
 
58
  shareIconEl.style.display = 'none';
59
  loadingIconEl.style.removeProperty('display');
60
 
61
+ const videoFile = await getVideoFile(videoEl);
62
+ const dataVideoFile = await uploadFile(videoFile);
63
 
64
  const descriptionMd = `Prompt: ${title}
65
+ Feel: ${feel}
66
+ Seed: ${seed}
67
 
68
+ #### Video:
69
 
70
+ <video controls>
71
+ <source src="${dataVideoFile}" type="video/mp4">
72
+ Your browser does not support the video element.
73
+ </video>
74
+ `;
75
 
76
  const params = new URLSearchParams({
77
  title: title,