Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature REquest : copy dl link in clipboard / .mkv video support in video player #271

Open
kirtapix opened this issue Jan 17, 2020 · 8 comments

Comments

@kirtapix
Copy link

kirtapix commented Jan 17, 2020

Hi coderaiser,

Is it possible to add a "copy download link to clipboard" in the Menu ?
I'm not able to preview mkv file, do you is it possible to add it in the video player ? For now cloudcmd see it like a binary file.

Thanks in advance.

Kirtapix

By the way : Happy new year 😀

@kirtapix kirtapix changed the title Feature REquest : copy dl link in clipboard Feature REquest : copy dl link in clipboard / .mkv video support in video player Jan 17, 2020
@coderaiser
Copy link
Owner

Hi Kirtapix,

Copying download link - it's a very good idea for a Pull Request :). About mkv, it doesn't supported by browsers, so it's not possible for now.

Happy New year :)!

@coderaiser
Copy link
Owner

Could you please tell me why don't you use Download menu item?

@kirtapix
Copy link
Author

I use download Menu item, but if I want to share a link with a friend, I have to start download with Download menu item, and copy the url from the address bar to give it to him.

@piratetub
Copy link

About mkv, it doesn't supported by browsers, so it's not possible for now.

@coderaiser It's actually just Firefox that can't play MKV files. Chromium and Edge native both support playing MKV files by declaring a "video/webm" MIME type.

@coderaiser
Copy link
Owner

@coderaiser It's actually just Firefox that can't play MKV files. Chromium and Edge native both support playing MKV files by declaring a "video/webm" MIME type.

In this case mkv video should just work in Chrome and Edge :)

@I-Want-ToBelieve
Copy link

I-Want-ToBelieve commented Nov 21, 2020

copy the download link to the clipboard. This menu item is also useful for video player that support streaming.
https://github.com/sudodoki/copy-to-clipboard

'Copy File Path': () => {
    const filePath = `${window.location.href}${window.encodeURI(document.querySelector('.current-file > [data-name=js-name] > a').text)}`
    console.log(filePath)
},

@coderaiser
Copy link
Owner

coderaiser commented Nov 22, 2020

@doublethinkio you can also use:

export default {
    'F6 - Copy URL to Current File': async ({DOM}) => {
        const {path} = DOM.CurrentInfo;
        const url = `${window.location.href}${path}`;
        const {default: clipboard}  = await import('https://cdn.skypack.dev/@cloudcmd/clipboard');
        
        await clipboard.writeText(url); 
    }
}

Just added to wiki.

@I-Want-ToBelieve
Copy link

@coderaiser Wow it looks great, thank you

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants