nakabonne / pbgopy

Copy and paste between devices
MIT License
813 stars 30 forks source link

Support web UI #7

Open nakabonne opened 3 years ago

nakabonne commented 3 years ago

The pbgopy server is just an HTTP server, hence the client does not have to be a pbgopy command.

It would be nice to provide a simple web UI so that data can be shared even in environments where it is tough to install the pbgopy command, such as mobile devices. A page as simple as piping-server is ideal: image

faithfulnessalamu commented 3 years ago

This interests me. Please correct me if I'm wrong but when you say

a page as simple as piping-server

you are referring to this UI yeah?

nakabonne commented 3 years ago

Eventually we want to offer something that rich, but we want something as simple as this for the first one. See more: https://dev.to/nwtgck/data-streaming-with-every-device-over-httphttps-mo4

All we need to do is to send a request to the root path / and fix it to return a static page.

nakabonne commented 3 years ago

Currently, we use the root path for handling the clipboard, so we first have to change it to /clipboard. https://github.com/nakabonne/pbgopy/blob/b77c9c20c1657bde380269698a72733d24cdf768/commands/serve.go#L74

faithfulnessalamu commented 3 years ago

I'll make a PR changing the clipboard endpoint first

nakabonne commented 3 years ago

Yes, please.

nakabonne commented 3 years ago

On the second thought, changing the clipboard endpoint is a significant breaking change, so it would be nice to include the change in the patch supporting Web UI.