webogram-i2p/README.md

115 lines
4.6 KiB
Markdown
Raw Normal View History

2014-06-30 09:09:32 +00:00
[![Stories in Ready](https://badge.waffle.io/zhukov/webogram.png?label=ready&title=Ready)](https://waffle.io/zhukov/webogram)
2014-12-22 15:47:02 +00:00
## [Webogram](https://web.telegram.org) — Telegram Web App
2014-01-05 14:22:23 +00:00
2014-11-13 11:19:11 +00:00
Telegram offers great [apps for mobile communication](https://www.telegram.org). It is based on the [MTProto protocol](https://core.telegram.org/mtproto) and has an [Open API](https://core.telegram.org/api). I personally like Telegram for its speed and cloud-support (that makes a web app possible, unlike in the case of WA and others).
2014-01-05 16:07:11 +00:00
2014-11-13 11:19:11 +00:00
MTProto data can be carried over HTTP (SSL is also supported), so this project is my take at creating one.
2014-01-05 16:07:11 +00:00
That said, I'm using this app myself and I'd like to share its sources, so anyone can contribute to the development. Any help is welcome!
### Interface
Here are some screenshots of the interface:
2014-02-01 13:26:44 +00:00
![Sample screenshot 1](/app/img/screenshot1.png)
![Mobile screenshot 2](/app/img/screenshot2.png)
![Mobile screenshot 3](/app/img/screenshot3.png)
2014-02-01 13:26:44 +00:00
2014-01-05 16:07:11 +00:00
2014-03-03 11:43:57 +00:00
### Unsupported at the moment
* Secret chats
2014-12-15 05:55:03 +00:00
* Black list
2014-06-06 07:43:26 +00:00
* ...
2014-01-05 16:07:11 +00:00
### Maintained locations
| Description | URL | Type |
| ------------- |-------------| -----:|
2014-11-13 11:19:11 +00:00
| Online Web-version (hosted on Telegram servers) | https://web.telegram.org/ | hosted
| Online Web-version (hosted on GitHub pages) | https://zhukov.github.io/webogram | hosted
| Chrome Web Store | [https://chrome.google.com/webstore/detail/telegram/ clhhggbfdinjmjhajaheehoeibfljjno](https://chrome.google.com/webstore/detail/telegram/clhhggbfdinjmjhajaheehoeibfljjno) | packed
| Firefox & FirefoxOS Marketplace | https://marketplace.firefox.com/app/telegram | packed
2014-11-13 11:19:11 +00:00
**Hosted version**: the app is downloaded via HTTPS as a usual website. Will be available offline due to application cache.
2014-09-17 16:59:08 +00:00
2014-11-13 11:19:11 +00:00
**Packed version**: the app is downloaded at once in a package via HTTPS. The package is updated less frequently than the Web-version.
2015-10-25 16:44:52 +00:00
All of the apps above are submitted and maintained by [@zhukov](https://github.com/zhukov), so feel free to use them and report bugs [here](https://github.com/zhukov/webogram/issues). Please do not report bugs which are only reproducible in different locations.
2014-01-05 16:07:11 +00:00
## Technical details
2015-10-25 16:44:52 +00:00
The app is based on the AngularJS JavaScript framework, and written in pure JavaScript. jQuery is used for DOM manipulations, and Bootstrap as the CSS-framework.
2014-01-05 16:07:11 +00:00
### Running locally
2015-10-25 16:44:52 +00:00
The project repository is based on angularjs-seed and includes gulp tasks, so it's easy to launch the app locally on your desktop.
Install [node.js](http://nodejs.org/) and run the following commands in the project directory
```
sudo npm install -g gulp
2015-07-01 00:28:16 +00:00
npm install
```
This will install all the needed dependencies.
2014-01-05 16:07:11 +00:00
#### Running web-server
2015-10-25 16:44:52 +00:00
Just run `gulp watch` to start the web server and the livereload task.
Open http://localhost:8000/app/index.html in your browser.
2014-01-05 16:07:11 +00:00
#### Running as Chrome Packaged App
2015-10-25 16:44:52 +00:00
To run this application in Google Chrome as a packaged app, open this URL (in Chrome): `chrome://extensions/`, then tick "Developer mode" and press "Load unpacked extension...". Select the downloaded `app` folder and Webogram should appear in the list.
2015-10-25 16:44:52 +00:00
Run `gulp watch` to watch for file changes and automatically rebuild the app.
#### Running as Firefox OS App
2015-10-25 16:44:52 +00:00
To run this application in Firefox as a packaged app, open "Menu" -> "Developer" -> "WebIDE" (or hit `Shift + F8`). Choose "Open packaged app" from the Project menu and select the `app` folder.
2014-01-05 16:07:11 +00:00
2015-10-25 16:44:52 +00:00
Run `gulp watch` to watch for file changes and automatically rebuild the app.
#### Running in production
Run `gulp clean`, then `gulp publish` to build the minimized production version of the app. Copy `dist` folder contents to your web server. Don't forget to set `X-Frame-Options SAMEORIGIN` header ([docs](https://developer.mozilla.org/en-US/docs/Web/HTTP/X-Frame-Options)).
2014-01-05 16:07:11 +00:00
### Third party libraries
2015-10-25 16:44:52 +00:00
Besides the frameworks mentioned above, other libraries are used for protocol and UI needs. Here is the short list:
2014-01-05 16:07:11 +00:00
* [JSBN](http://www-cs-students.stanford.edu/~tjw/jsbn/)
* [CryptoJS](https://code.google.com/p/crypto-js/)
* [zlib.js](https://github.com/imaya/zlib.js)
* [UI Bootstrap](http://angular-ui.github.io/bootstrap/)
* [jQuery Emojiarea](https://github.com/diy/jquery-emojiarea)
* [nanoScrollerJS](https://github.com/jamesflorentino/nanoScrollerJS)
* [gemoji](https://github.com/github/gemoji)
* [emoji-data](https://github.com/iamcal/emoji-data)
2015-10-25 16:44:52 +00:00
Many thanks to all these libraries' authors and contributors. A detailed list with descriptions and licenses is available [here](/app/vendor).
2014-01-05 16:07:11 +00:00
### Licensing
The source code is licensed under GPL v3. License is available [here](/LICENSE).
2014-12-22 15:47:02 +00:00
### [Contribute](CONTRIBUTING.md)