├── .gitignore
├── README.md
├── app
├── autoload.php
├── bash
│ ├── chown.php
│ ├── composer.php
│ ├── install
│ ├── install.php
│ ├── locale.php
│ ├── restart.php
│ ├── update.php
│ └── utils.php
├── css
│ ├── font-awesome
│ │ ├── HELP-US-OUT.txt
│ │ ├── css
│ │ │ ├── font-awesome.css
│ │ │ └── font-awesome.min.css
│ │ ├── fonts
│ │ │ ├── FontAwesome.otf
│ │ │ ├── fontawesome-webfont.eot
│ │ │ ├── fontawesome-webfont.svg
│ │ │ ├── fontawesome-webfont.ttf
│ │ │ ├── fontawesome-webfont.woff
│ │ │ └── fontawesome-webfont.woff2
│ │ ├── less
│ │ │ ├── animated.less
│ │ │ ├── bordered-pulled.less
│ │ │ ├── core.less
│ │ │ ├── fixed-width.less
│ │ │ ├── font-awesome.less
│ │ │ ├── icons.less
│ │ │ ├── larger.less
│ │ │ ├── list.less
│ │ │ ├── mixins.less
│ │ │ ├── path.less
│ │ │ ├── rotated-flipped.less
│ │ │ ├── screen-reader.less
│ │ │ ├── stacked.less
│ │ │ └── variables.less
│ │ └── scss
│ │ │ ├── _animated.scss
│ │ │ ├── _bordered-pulled.scss
│ │ │ ├── _core.scss
│ │ │ ├── _fixed-width.scss
│ │ │ ├── _icons.scss
│ │ │ ├── _larger.scss
│ │ │ ├── _list.scss
│ │ │ ├── _mixins.scss
│ │ │ ├── _path.scss
│ │ │ ├── _rotated-flipped.scss
│ │ │ ├── _screen-reader.scss
│ │ │ ├── _stacked.scss
│ │ │ ├── _variables.scss
│ │ │ └── font-awesome.scss
│ ├── frame.css
│ └── style.css
├── frame.php
├── images
│ ├── backgrounds
│ │ ├── default-01.jpg
│ │ ├── default-02.jpg
│ │ ├── default-03.jpg
│ │ ├── default-04.jpg
│ │ ├── default-05.jpg
│ │ └── default-06.jpg
│ ├── logo-text.svg
│ ├── logo.svg
│ └── readme_header.png
├── index.php
├── js
│ ├── anime.min.js
│ ├── frame.js
│ ├── index.js
│ ├── index.loop.js
│ ├── moment-with-locales.js
│ ├── navigo.min.js
│ └── pace.min.js
├── locale
│ ├── de
│ │ └── LC_MESSAGES
│ │ │ └── steemPi.po
│ ├── en
│ │ └── LC_MESSAGES
│ │ │ └── steemPi.po
│ └── nl
│ │ └── LC_MESSAGES
│ │ └── steemPi.po
├── src
│ └── SteemPi
│ │ ├── Config.php
│ │ ├── Exception.php
│ │ ├── GPIO.php
│ │ ├── LEDS.php
│ │ ├── Menu
│ │ └── Item.php
│ │ ├── Modules
│ │ ├── Handler.php
│ │ └── Module.php
│ │ └── SteemPi.php
└── tests
│ ├── gpio.php
│ ├── ledtest.php
│ └── run.php
├── case (3d models)
├── full case
│ └── by lextenebris
│ │ └── 2018 01
│ │ ├── Standard
│ │ ├── .gitattributes
│ │ ├── .gitignore
│ │ ├── SteemPi Bottom Case.step
│ │ ├── SteemPi Bottom Plate.stl
│ │ ├── SteemPi Top Case.step
│ │ ├── SteemPi Top Plate.stl
│ │ ├── SteemPi_Top_Case_un-VESA%27d_2017-Dec-19_06-02-13PM-000_CustomizedView27519844442.png
│ │ ├── SteemPi_Top_Case_un-VESA%27d_2017-Dec-19_06-13-05PM-000_CustomizedView22353338303.png
│ │ ├── SteemPi_Top_Case_un-VESA%27d_2017-Dec-19_06-25-33PM-000_CustomizedView15145494748.png
│ │ ├── SteemPi_Top_Case_un-VESA%27d_2017-Dec-19_07-02-47PM-000_CustomizedView22613793973.png
│ │ ├── SteemPi_Top_Case_un-VESA%27d_2017-Dec-19_07-28-53PM-000_CustomizedView28240694750.png
│ │ └── SteemPi_Top_Case_un-VESA%27d_2017-Dec-19_07-36-11PM-000_CustomizedView15712030720.png
│ │ └── Vertical
│ │ ├── SteemPi Bottom Case Standing.f3d
│ │ ├── SteemPi Bottom Case Standing.step
│ │ ├── SteemPi Bottom Case Standing.stl
│ │ ├── SteemPi Top Case Standing.f3d
│ │ ├── SteemPi Top Case Standing.step
│ │ ├── SteemPi Top Case Standing.stl
│ │ ├── SteemPi_Case_%28Standing%29_2018-Jan-02_03-54-12PM-000_CustomizedView14738632598.png
│ │ ├── SteemPi_Case_%28Standing%29_2018-Jan-02_04-08-18PM-000_CustomizedView3218308360.png
│ │ ├── SteemPi_Case_%28Standing%29_2018-Jan-02_04-11-14PM-000_CustomizedView10689853559.png
│ │ ├── SteemPi_Case_%28Standing%29_2018-Jan-02_05-35-22PM-000_CustomizedView183663004.png
│ │ ├── SteemPi_Case_%28Standing%29_2018-Jan-02_05-45-42PM-000_CustomizedView22939140683.png
│ │ ├── SteemPi_Case_%28Standing%29_2018-Jan-02_05-50-39PM-000_CustomizedView7317596350.png
│ │ └── SteemPi_Case_%28Standing%29_2018-Jan-02_09-09-16AM-000_CustomizedView27585120167.png
└── side panel
│ ├── by lextenebris
│ └── 2017 12 12
│ │ ├── SteemPi Side Panel Body (SquidVer).step
│ │ ├── SteemPi Side Panel Body (SquidVer).stl
│ │ ├── SteemPi Side Panel Body.step
│ │ ├── sp16.png
│ │ ├── sp17.png
│ │ └── sp18.png
│ └── giveaway
│ ├── SidePanelSteemPi
│ ├── 2D SteemPi Side Panel for plastic case - Linedrawing (vector).ai
│ ├── 2D SteemPi Side Panel for plastic case - Linedrawing.jpg
│ ├── 3D SteemPi Side Panel for plastic case - Steem logo cutout.skp
│ └── 3D SteemPi Side Panel for plastic case - Steem logo cutout.stl
│ ├── index.html
│ ├── index.js
│ └── index.png
├── composer.json
├── composer.lock
├── favicon.ico
├── index.php
├── install
├── js
└── index.js
├── ledscript
├── ledscript-orangepi-h3soc.sh
├── ledscript.sh
├── new.html
└── old.html
├── modules
├── MontereyBayAquarium
│ ├── images
│ │ ├── icon.svg
│ │ └── menu.svg
│ ├── index.php
│ └── module.json
├── Steemitpond
│ ├── images
│ │ ├── icon.svg
│ │ └── menu.svg
│ ├── index.php
│ └── module.json
├── WhaleSonar
│ ├── images
│ │ ├── icon.svg
│ │ └── menu.svg
│ ├── index.php
│ └── module.json
├── bitcoinexplorer
│ ├── images
│ │ ├── icon.svg
│ │ └── menu.svg
│ ├── index.php
│ └── module.json
├── discord
│ ├── images
│ │ ├── icon.svg
│ │ └── menu.svg
│ ├── index.php
│ └── module.json
├── dtube
│ ├── images
│ │ ├── icon.svg
│ │ └── menu.svg
│ ├── index.php
│ └── module.json
├── duckduckgo
│ ├── images
│ │ ├── icon.svg
│ │ └── menu.svg
│ ├── index.php
│ └── module.json
├── feed
│ ├── css
│ │ ├── feed.css
│ │ ├── gutenberg.css
│ │ ├── post.css
│ │ └── style.css
│ ├── images
│ │ ├── icon.svg
│ │ └── menu.svg
│ ├── index.php
│ ├── js
│ │ ├── feed.js
│ │ ├── fetch.js
│ │ └── post.js
│ ├── locale
│ │ ├── de
│ │ │ └── LC_MESSAGES
│ │ │ │ ├── feed.mo
│ │ │ │ └── feed.po
│ │ └── en
│ │ │ └── LC_MESSAGES
│ │ │ ├── feed.mo
│ │ │ └── feed.po
│ ├── markdown.php
│ ├── module.json
│ ├── post.php
│ └── utils.php
├── issLive
│ ├── images
│ │ ├── icon.svg
│ │ └── menu.svg
│ ├── index.php
│ └── module.json
├── openhab
│ ├── images
│ │ ├── icon.svg
│ │ └── menu.svg
│ ├── index.php
│ └── module.json
├── raspberrypiorg
│ ├── images
│ │ ├── icon.svg
│ │ └── menu.svg
│ ├── index.php
│ └── module.json
├── settings
│ ├── compile.php
│ ├── css
│ │ └── style.css
│ ├── images
│ │ ├── ledblue.svg
│ │ ├── ledgreen.svg
│ │ └── ledpurple.svg
│ ├── index.php
│ ├── javascript
│ │ └── settings.js
│ ├── locale
│ │ ├── de
│ │ │ └── LC_MESSAGES
│ │ │ │ ├── settings.mo
│ │ │ │ └── settings.po
│ │ ├── en
│ │ │ └── LC_MESSAGES
│ │ │ │ ├── settings.mo
│ │ │ │ └── settings.po
│ │ └── nl
│ │ │ └── LC_MESSAGES
│ │ │ ├── settings.mo
│ │ │ └── settings.po
│ ├── module.json
│ └── save.php
├── spectacles
│ ├── images
│ │ ├── icon.svg
│ │ └── menu.svg
│ ├── index.php
│ └── module.json
├── stats
│ ├── css
│ │ └── style.css
│ ├── images
│ │ ├── icon.svg
│ │ └── menu.svg
│ ├── index.php
│ ├── locale
│ │ ├── de
│ │ │ └── LC_MESSAGES
│ │ │ │ ├── stats.mo
│ │ │ │ └── stats.po
│ │ └── en
│ │ │ └── LC_MESSAGES
│ │ │ ├── stats.mo
│ │ │ └── stats.po
│ └── module.json
├── steemstream
│ ├── images
│ │ ├── icon.svg
│ │ └── menu.svg
│ ├── index.php
│ └── module.json
├── steemsupply
│ ├── images
│ │ ├── icon.svg
│ │ └── menu.svg
│ ├── index.php
│ └── module.json
└── tedcom
│ ├── images
│ ├── icon.svg
│ └── menu.svg
│ ├── index.php
│ └── module.json
└── steempi
/.gitignore:
--------------------------------------------------------------------------------
1 | conf/
2 | vendor/
3 | .idea/
4 | etc/
5 | /backgrounds/
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | SteemPi
2 | ======
3 |
4 |
5 |
6 | 
7 |
8 |
9 |
10 | STEEMPI V2.0 | Steemit LED light notifications and web interface for Raspberry Pi
11 | and other Raspberry Pi clones that uses the Wirringpi GPIO library.
12 |
13 | SteemPi shows its interface on a connected TV (HDMI),
14 | but you can also view the interface with a web browser on mobile devices, laptops, pc, game consoles, smartwatches
15 | and other devices that are capable of browsing web pages.
16 |
17 | SteemPi is made by:
18 |
19 | - @techtek - https://steemit.com/@techtek
20 | - @dehenne - https://steemit.com/@dehenne
21 |
22 |
23 | Installation - How to make your Pi, Steem?
24 | ------
25 |
26 |
27 | ### Step 1: Operating system
28 |
29 | Install the latest version of Raspbian on your SD card
30 | `https://www.raspberrypi.org/downloads/raspbian/`
31 |
32 | - Boot up the system and connect to your home network and the internet (Wifi or cable)
33 | - Enable SSH `Start > Preferences > Raspberry Pi Configuration > Interfaces > Enable ssh`
34 | - Login in via SSH
35 |
36 |
37 | ### Step 2: SteemPi Installation
38 |
39 | - `sudo su`
40 | - `mkdir /var/www/html -p`
41 | - `apt-get update`
42 | - `apt-get install git -y`
43 | - `cd /var/www/html`
44 | - `git clone https://github.com/techtek/steempi.git .`
45 |
46 | *If you want to install the dev version*
47 |
48 | - `git checkout dev`
49 |
50 | *You only have to start the installation :-)*
51 |
52 | - `./install`
53 |
54 |
55 | *It take a while*
56 | *The script installs SteemPi and keep your system up to date*
57 | *I recommend you to get a coffee*
58 | *;-)*
59 |
60 |
61 | ### Step 3: Steemit LED light notifications
62 |
63 | - Connect a LED to GPIO17 of the Pi
64 | (and you shoud solder the correct resistor to the LED. it works without one,
65 | no problems so far but you may damage the pi without one.
66 |
67 | - Make ledscript.sh executable, `cd /var/www/html/ledscript/` and use the command `sudo chmod u+x ledscript.sh`
68 |
69 | - To run the script manualy: `cd /var/www/html/ledscript/` and to run it, `sudo ./ledscript.sh`
70 | The LED should blink one time because it detected change.
71 |
72 | You can test if it is working by making a reply on my Steemit account `http://steemit.com/@techtek`
73 | This way you can test if your LED lights up, and it's a way to let me know you installed SteemPi.
74 |
75 | If the LED lights up, change `@techtek` in the script,
76 | to watch your account for updates to do this, use the commands:
77 |
78 | `cd /var/www/html/ledscript/` and to edit use the command
79 | `sudo nano ledscript.sh` edit the username in the URL and exit and save with, ctrl+x
80 |
81 | To make ledscript.sh boot on startup,
82 | `sudo nano /etc/rc.local` add in this file before exit 0 this line `/var/www/html/ledscript/./ledscript.sh`
83 | and exit and save with, ctrl+x
84 |
85 |
86 | Everything is now ready to use!
87 | ------
88 |
89 | If you make changes to the SteemPi project,
90 | please do share them back to the SteemPi project so others can use those functionalities as well.
91 |
92 | - https://github.com/techtek/steempi
93 | - https://steemit.com/@techtek
94 | - https://steemit.com/@dehenne
95 |
96 | Please support the makers of the services that are integrated into SteemPi.
97 |
98 | If you have a service or functionality you want to integrate,
99 | you could help by writing a custom code for your service that can be implemented in the SteemPi web interface.
100 |
101 |
102 |
--------------------------------------------------------------------------------
/app/autoload.php:
--------------------------------------------------------------------------------
1 | setPsr4('SteemPi\\', __DIR__.'/src/SteemPi/');
8 |
9 | /**
10 | * Localization
11 | *
12 | * msgfmt xxx.po -o xxx.mo
13 | */
14 |
15 | \SteemPi\SteemPi::loadLanguage();
16 |
--------------------------------------------------------------------------------
/app/bash/chown.php:
--------------------------------------------------------------------------------
1 | /dev/null 2>&1 || {
14 | echo "";
15 | echo "No PHP is installed. I will install php7 for you.";
16 | echo "";
17 |
18 | command echo "deb http://httpredir.debian.org/debian stretch main contrib non-free" | tee /etc/apt/sources.list.d/debian-stretch.list
19 |
20 | command gpg --keyserver pgpkeys.mit.edu --recv-key 8B48AD6246925553
21 | command gpg -a --export 8B48AD6246925553 | sudo apt-key add -
22 |
23 | command apt-key update
24 | command apt-get update -y --allow-unauthenticated
25 | command apt-get install php7.0 php7.0-fpm php7.0-mbstring -t stretch -y --allow-unauthenticated
26 |
27 | command rm /etc/apt/sources.list.d/debian-stretch.list
28 | command apt-get update -y --allow-unauthenticated
29 | }
30 |
31 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
32 | command php ${DIR}/install.php
--------------------------------------------------------------------------------
/app/bash/install.php:
--------------------------------------------------------------------------------
1 | /dev/null < ((
37 | "socket" => "/var/run/php/php7.0-fpm.sock"
38 | )))
39 | EOF'
40 | );
41 |
42 | system('lighttpd-enable-mod fastcgi');
43 | system('/etc/init.d/lighttpd force-reload');
44 | }
45 |
46 | if (!command_exist('gpio')) {
47 | echo PHP_EOL;
48 | echo "No GPIO connection is installed. I will install wiringpi for you.".PHP_EOL;
49 | system('apt-get install wiringpi -y');
50 |
51 | }
52 |
53 | if (!function_exists('mb_substr()')) {
54 | system('apt-get php7.0-mbstring -y');
55 | }
56 |
57 | // SteemPi
58 | echo "Now i will install SteemPi for you.".PHP_EOL;
59 |
60 | chdir($dir);
61 |
62 | if (file_exists('/var/www/html/index.lighttpd.html')) {
63 | unlink('/var/www/html/index.lighttpd.html');
64 | }
65 |
66 | system('apt-get update -y');
67 | system('git clone https://github.com/techtek/steempi.git .');
68 |
69 | // checkout dev
70 | system('git checkout -b dev origin/dev');
71 |
72 | // composer
73 | include 'composer.php';
74 |
75 | // create etc folder
76 | if (!is_dir($dir.'/etc/')) {
77 | mkdir($dir.'/etc/');
78 |
79 | $conf = '
80 | ;
81 |
82 | [steempi]
83 | language = "en_EN"
84 | modulesOrder = "feed,dtube,spectacles,steemstream,steemsupply,discord,WhaleSonar,Steemitpond,stats,issLive,bitcoinexplorer,duckduckgo,MontereyBayAquarium,openhab,raspberrypiorg,tedcom,settings"
85 |
86 | [steemit]
87 | username = ""
88 |
89 | [modules]
90 | feed = 1
91 | issLive = 0
92 | settings = 1
93 | stats = 1
94 | Steemitpond = 1
95 | WhaleSonar = 1
96 | discord = 1
97 | bitcoinexplorer = 0
98 | dtube = 1
99 | duckduckgo = 0
100 | MontereyBayAquarium = 0
101 | openhab = 0
102 | raspberrypiorg = 0
103 | spectacles = 1
104 | steemstream = 1
105 | steemsupply = 1
106 | tedcom = 0
107 |
108 | ';
109 |
110 | file_put_contents($dir.'/etc/conf.ini.php', $conf);
111 | }
112 |
113 | if (!class_exists('\Locale')) {
114 | if (version_compare(PHP_VERSION, '7.0.0') >= 0) {
115 | system('apt-get install php7.0-intl -y');
116 | } else {
117 | system('apt-get install php5-intl -y');
118 | }
119 | }
120 |
121 | $dir = dirname(dirname(dirname(__FILE__)));
122 |
123 | system($dir.'/steempi update');
124 |
--------------------------------------------------------------------------------
/app/bash/locale.php:
--------------------------------------------------------------------------------
1 | = 0) {
52 | system('apt-get install php7.0-intl -y');
53 | } else {
54 | system('apt-get install php5-intl -y');
55 | }
56 | }
57 |
58 | \cli\Colors::enable();
59 | \cli\line('%CGenerate locale%n', true);
60 | \cli\Colors::disable();
61 | include dirname(__FILE__).'/locale.php';
62 |
63 |
64 | \cli\Colors::enable();
65 | \cli\line('%CUpdate PHP libraries%n', true);
66 | \cli\Colors::disable();
67 | include dirname(__FILE__).'/composer.php';
68 |
69 | \cli\Colors::enable();
70 | \cli\line('%CSet folder permissions%n', true);
71 | \cli\Colors::disable();
72 | include dirname(__FILE__).'/chown.php';
73 |
74 | \cli\Colors::enable();
75 | \cli\line('%CRestart services%n', true);
76 | \cli\Colors::disable();
77 | include dirname(__FILE__).'/restart.php';
78 |
79 | echo PHP_EOL;
80 | echo PHP_EOL;
81 | echo "I am done. We wish you a lot of fun with SteemPi - @dehenne and @Techtek";
82 | echo PHP_EOL;
83 |
--------------------------------------------------------------------------------
/app/bash/utils.php:
--------------------------------------------------------------------------------
1 | li { position: relative; }
9 | }
10 | .@{fa-css-prefix}-li {
11 | position: absolute;
12 | left: -@fa-li-width;
13 | width: @fa-li-width;
14 | top: (2em / 14);
15 | text-align: center;
16 | &.@{fa-css-prefix}-lg {
17 | left: (-@fa-li-width + (4em / 14));
18 | }
19 | }
20 |
--------------------------------------------------------------------------------
/app/css/font-awesome/less/mixins.less:
--------------------------------------------------------------------------------
1 | // Mixins
2 | // --------------------------
3 |
4 | .fa-icon() {
5 | display: inline-block;
6 | font: normal normal normal @fa-font-size-base/@fa-line-height-base FontAwesome; // shortening font declaration
7 | font-size: inherit; // can't have font-size inherit on line above, so need to override
8 | text-rendering: auto; // optimizelegibility throws things off #1094
9 | -webkit-font-smoothing: antialiased;
10 | -moz-osx-font-smoothing: grayscale;
11 |
12 | }
13 |
14 | .fa-icon-rotate(@degrees, @rotation) {
15 | -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=@{rotation})";
16 | -webkit-transform: rotate(@degrees);
17 | -ms-transform: rotate(@degrees);
18 | transform: rotate(@degrees);
19 | }
20 |
21 | .fa-icon-flip(@horiz, @vert, @rotation) {
22 | -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=@{rotation}, mirror=1)";
23 | -webkit-transform: scale(@horiz, @vert);
24 | -ms-transform: scale(@horiz, @vert);
25 | transform: scale(@horiz, @vert);
26 | }
27 |
28 |
29 | // Only display content to screen readers. A la Bootstrap 4.
30 | //
31 | // See: http://a11yproject.com/posts/how-to-hide-content/
32 |
33 | .sr-only() {
34 | position: absolute;
35 | width: 1px;
36 | height: 1px;
37 | padding: 0;
38 | margin: -1px;
39 | overflow: hidden;
40 | clip: rect(0,0,0,0);
41 | border: 0;
42 | }
43 |
44 | // Use in conjunction with .sr-only to only display content when it's focused.
45 | //
46 | // Useful for "Skip to main content" links; see http://www.w3.org/TR/2013/NOTE-WCAG20-TECHS-20130905/G1
47 | //
48 | // Credit: HTML5 Boilerplate
49 |
50 | .sr-only-focusable() {
51 | &:active,
52 | &:focus {
53 | position: static;
54 | width: auto;
55 | height: auto;
56 | margin: 0;
57 | overflow: visible;
58 | clip: auto;
59 | }
60 | }
61 |
--------------------------------------------------------------------------------
/app/css/font-awesome/less/path.less:
--------------------------------------------------------------------------------
1 | /* FONT PATH
2 | * -------------------------- */
3 |
4 | @font-face {
5 | font-family: 'FontAwesome';
6 | src: url('@{fa-font-path}/fontawesome-webfont.eot?v=@{fa-version}');
7 | src: url('@{fa-font-path}/fontawesome-webfont.eot?#iefix&v=@{fa-version}') format('embedded-opentype'),
8 | url('@{fa-font-path}/fontawesome-webfont.woff2?v=@{fa-version}') format('woff2'),
9 | url('@{fa-font-path}/fontawesome-webfont.woff?v=@{fa-version}') format('woff'),
10 | url('@{fa-font-path}/fontawesome-webfont.ttf?v=@{fa-version}') format('truetype'),
11 | url('@{fa-font-path}/fontawesome-webfont.svg?v=@{fa-version}#fontawesomeregular') format('svg');
12 | // src: url('@{fa-font-path}/FontAwesome.otf') format('opentype'); // used when developing fonts
13 | font-weight: normal;
14 | font-style: normal;
15 | }
16 |
--------------------------------------------------------------------------------
/app/css/font-awesome/less/rotated-flipped.less:
--------------------------------------------------------------------------------
1 | // Rotated & Flipped Icons
2 | // -------------------------
3 |
4 | .@{fa-css-prefix}-rotate-90 { .fa-icon-rotate(90deg, 1); }
5 | .@{fa-css-prefix}-rotate-180 { .fa-icon-rotate(180deg, 2); }
6 | .@{fa-css-prefix}-rotate-270 { .fa-icon-rotate(270deg, 3); }
7 |
8 | .@{fa-css-prefix}-flip-horizontal { .fa-icon-flip(-1, 1, 0); }
9 | .@{fa-css-prefix}-flip-vertical { .fa-icon-flip(1, -1, 2); }
10 |
11 | // Hook for IE8-9
12 | // -------------------------
13 |
14 | :root .@{fa-css-prefix}-rotate-90,
15 | :root .@{fa-css-prefix}-rotate-180,
16 | :root .@{fa-css-prefix}-rotate-270,
17 | :root .@{fa-css-prefix}-flip-horizontal,
18 | :root .@{fa-css-prefix}-flip-vertical {
19 | filter: none;
20 | }
21 |
--------------------------------------------------------------------------------
/app/css/font-awesome/less/screen-reader.less:
--------------------------------------------------------------------------------
1 | // Screen Readers
2 | // -------------------------
3 |
4 | .sr-only { .sr-only(); }
5 | .sr-only-focusable { .sr-only-focusable(); }
6 |
--------------------------------------------------------------------------------
/app/css/font-awesome/less/stacked.less:
--------------------------------------------------------------------------------
1 | // Stacked Icons
2 | // -------------------------
3 |
4 | .@{fa-css-prefix}-stack {
5 | position: relative;
6 | display: inline-block;
7 | width: 2em;
8 | height: 2em;
9 | line-height: 2em;
10 | vertical-align: middle;
11 | }
12 | .@{fa-css-prefix}-stack-1x, .@{fa-css-prefix}-stack-2x {
13 | position: absolute;
14 | left: 0;
15 | width: 100%;
16 | text-align: center;
17 | }
18 | .@{fa-css-prefix}-stack-1x { line-height: inherit; }
19 | .@{fa-css-prefix}-stack-2x { font-size: 2em; }
20 | .@{fa-css-prefix}-inverse { color: @fa-inverse; }
21 |
--------------------------------------------------------------------------------
/app/css/font-awesome/scss/_animated.scss:
--------------------------------------------------------------------------------
1 | // Spinning Icons
2 | // --------------------------
3 |
4 | .#{$fa-css-prefix}-spin {
5 | -webkit-animation: fa-spin 2s infinite linear;
6 | animation: fa-spin 2s infinite linear;
7 | }
8 |
9 | .#{$fa-css-prefix}-pulse {
10 | -webkit-animation: fa-spin 1s infinite steps(8);
11 | animation: fa-spin 1s infinite steps(8);
12 | }
13 |
14 | @-webkit-keyframes fa-spin {
15 | 0% {
16 | -webkit-transform: rotate(0deg);
17 | transform: rotate(0deg);
18 | }
19 | 100% {
20 | -webkit-transform: rotate(359deg);
21 | transform: rotate(359deg);
22 | }
23 | }
24 |
25 | @keyframes fa-spin {
26 | 0% {
27 | -webkit-transform: rotate(0deg);
28 | transform: rotate(0deg);
29 | }
30 | 100% {
31 | -webkit-transform: rotate(359deg);
32 | transform: rotate(359deg);
33 | }
34 | }
35 |
--------------------------------------------------------------------------------
/app/css/font-awesome/scss/_bordered-pulled.scss:
--------------------------------------------------------------------------------
1 | // Bordered & Pulled
2 | // -------------------------
3 |
4 | .#{$fa-css-prefix}-border {
5 | padding: .2em .25em .15em;
6 | border: solid .08em $fa-border-color;
7 | border-radius: .1em;
8 | }
9 |
10 | .#{$fa-css-prefix}-pull-left { float: left; }
11 | .#{$fa-css-prefix}-pull-right { float: right; }
12 |
13 | .#{$fa-css-prefix} {
14 | &.#{$fa-css-prefix}-pull-left { margin-right: .3em; }
15 | &.#{$fa-css-prefix}-pull-right { margin-left: .3em; }
16 | }
17 |
18 | /* Deprecated as of 4.4.0 */
19 | .pull-right { float: right; }
20 | .pull-left { float: left; }
21 |
22 | .#{$fa-css-prefix} {
23 | &.pull-left { margin-right: .3em; }
24 | &.pull-right { margin-left: .3em; }
25 | }
26 |
--------------------------------------------------------------------------------
/app/css/font-awesome/scss/_core.scss:
--------------------------------------------------------------------------------
1 | // Base Class Definition
2 | // -------------------------
3 |
4 | .#{$fa-css-prefix} {
5 | display: inline-block;
6 | font: normal normal normal #{$fa-font-size-base}/#{$fa-line-height-base} FontAwesome; // shortening font declaration
7 | font-size: inherit; // can't have font-size inherit on line above, so need to override
8 | text-rendering: auto; // optimizelegibility throws things off #1094
9 | -webkit-font-smoothing: antialiased;
10 | -moz-osx-font-smoothing: grayscale;
11 |
12 | }
13 |
--------------------------------------------------------------------------------
/app/css/font-awesome/scss/_fixed-width.scss:
--------------------------------------------------------------------------------
1 | // Fixed Width Icons
2 | // -------------------------
3 | .#{$fa-css-prefix}-fw {
4 | width: (18em / 14);
5 | text-align: center;
6 | }
7 |
--------------------------------------------------------------------------------
/app/css/font-awesome/scss/_larger.scss:
--------------------------------------------------------------------------------
1 | // Icon Sizes
2 | // -------------------------
3 |
4 | /* makes the font 33% larger relative to the icon container */
5 | .#{$fa-css-prefix}-lg {
6 | font-size: (4em / 3);
7 | line-height: (3em / 4);
8 | vertical-align: -15%;
9 | }
10 | .#{$fa-css-prefix}-2x { font-size: 2em; }
11 | .#{$fa-css-prefix}-3x { font-size: 3em; }
12 | .#{$fa-css-prefix}-4x { font-size: 4em; }
13 | .#{$fa-css-prefix}-5x { font-size: 5em; }
14 |
--------------------------------------------------------------------------------
/app/css/font-awesome/scss/_list.scss:
--------------------------------------------------------------------------------
1 | // List Icons
2 | // -------------------------
3 |
4 | .#{$fa-css-prefix}-ul {
5 | padding-left: 0;
6 | margin-left: $fa-li-width;
7 | list-style-type: none;
8 | > li { position: relative; }
9 | }
10 | .#{$fa-css-prefix}-li {
11 | position: absolute;
12 | left: -$fa-li-width;
13 | width: $fa-li-width;
14 | top: (2em / 14);
15 | text-align: center;
16 | &.#{$fa-css-prefix}-lg {
17 | left: -$fa-li-width + (4em / 14);
18 | }
19 | }
20 |
--------------------------------------------------------------------------------
/app/css/font-awesome/scss/_mixins.scss:
--------------------------------------------------------------------------------
1 | // Mixins
2 | // --------------------------
3 |
4 | @mixin fa-icon() {
5 | display: inline-block;
6 | font: normal normal normal #{$fa-font-size-base}/#{$fa-line-height-base} FontAwesome; // shortening font declaration
7 | font-size: inherit; // can't have font-size inherit on line above, so need to override
8 | text-rendering: auto; // optimizelegibility throws things off #1094
9 | -webkit-font-smoothing: antialiased;
10 | -moz-osx-font-smoothing: grayscale;
11 |
12 | }
13 |
14 | @mixin fa-icon-rotate($degrees, $rotation) {
15 | -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=#{$rotation})";
16 | -webkit-transform: rotate($degrees);
17 | -ms-transform: rotate($degrees);
18 | transform: rotate($degrees);
19 | }
20 |
21 | @mixin fa-icon-flip($horiz, $vert, $rotation) {
22 | -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=#{$rotation}, mirror=1)";
23 | -webkit-transform: scale($horiz, $vert);
24 | -ms-transform: scale($horiz, $vert);
25 | transform: scale($horiz, $vert);
26 | }
27 |
28 |
29 | // Only display content to screen readers. A la Bootstrap 4.
30 | //
31 | // See: http://a11yproject.com/posts/how-to-hide-content/
32 |
33 | @mixin sr-only {
34 | position: absolute;
35 | width: 1px;
36 | height: 1px;
37 | padding: 0;
38 | margin: -1px;
39 | overflow: hidden;
40 | clip: rect(0,0,0,0);
41 | border: 0;
42 | }
43 |
44 | // Use in conjunction with .sr-only to only display content when it's focused.
45 | //
46 | // Useful for "Skip to main content" links; see http://www.w3.org/TR/2013/NOTE-WCAG20-TECHS-20130905/G1
47 | //
48 | // Credit: HTML5 Boilerplate
49 |
50 | @mixin sr-only-focusable {
51 | &:active,
52 | &:focus {
53 | position: static;
54 | width: auto;
55 | height: auto;
56 | margin: 0;
57 | overflow: visible;
58 | clip: auto;
59 | }
60 | }
61 |
--------------------------------------------------------------------------------
/app/css/font-awesome/scss/_path.scss:
--------------------------------------------------------------------------------
1 | /* FONT PATH
2 | * -------------------------- */
3 |
4 | @font-face {
5 | font-family: 'FontAwesome';
6 | src: url('#{$fa-font-path}/fontawesome-webfont.eot?v=#{$fa-version}');
7 | src: url('#{$fa-font-path}/fontawesome-webfont.eot?#iefix&v=#{$fa-version}') format('embedded-opentype'),
8 | url('#{$fa-font-path}/fontawesome-webfont.woff2?v=#{$fa-version}') format('woff2'),
9 | url('#{$fa-font-path}/fontawesome-webfont.woff?v=#{$fa-version}') format('woff'),
10 | url('#{$fa-font-path}/fontawesome-webfont.ttf?v=#{$fa-version}') format('truetype'),
11 | url('#{$fa-font-path}/fontawesome-webfont.svg?v=#{$fa-version}#fontawesomeregular') format('svg');
12 | // src: url('#{$fa-font-path}/FontAwesome.otf') format('opentype'); // used when developing fonts
13 | font-weight: normal;
14 | font-style: normal;
15 | }
16 |
--------------------------------------------------------------------------------
/app/css/font-awesome/scss/_rotated-flipped.scss:
--------------------------------------------------------------------------------
1 | // Rotated & Flipped Icons
2 | // -------------------------
3 |
4 | .#{$fa-css-prefix}-rotate-90 { @include fa-icon-rotate(90deg, 1); }
5 | .#{$fa-css-prefix}-rotate-180 { @include fa-icon-rotate(180deg, 2); }
6 | .#{$fa-css-prefix}-rotate-270 { @include fa-icon-rotate(270deg, 3); }
7 |
8 | .#{$fa-css-prefix}-flip-horizontal { @include fa-icon-flip(-1, 1, 0); }
9 | .#{$fa-css-prefix}-flip-vertical { @include fa-icon-flip(1, -1, 2); }
10 |
11 | // Hook for IE8-9
12 | // -------------------------
13 |
14 | :root .#{$fa-css-prefix}-rotate-90,
15 | :root .#{$fa-css-prefix}-rotate-180,
16 | :root .#{$fa-css-prefix}-rotate-270,
17 | :root .#{$fa-css-prefix}-flip-horizontal,
18 | :root .#{$fa-css-prefix}-flip-vertical {
19 | filter: none;
20 | }
21 |
--------------------------------------------------------------------------------
/app/css/font-awesome/scss/_screen-reader.scss:
--------------------------------------------------------------------------------
1 | // Screen Readers
2 | // -------------------------
3 |
4 | .sr-only { @include sr-only(); }
5 | .sr-only-focusable { @include sr-only-focusable(); }
6 |
--------------------------------------------------------------------------------
/app/css/font-awesome/scss/_stacked.scss:
--------------------------------------------------------------------------------
1 | // Stacked Icons
2 | // -------------------------
3 |
4 | .#{$fa-css-prefix}-stack {
5 | position: relative;
6 | display: inline-block;
7 | width: 2em;
8 | height: 2em;
9 | line-height: 2em;
10 | vertical-align: middle;
11 | }
12 | .#{$fa-css-prefix}-stack-1x, .#{$fa-css-prefix}-stack-2x {
13 | position: absolute;
14 | left: 0;
15 | width: 100%;
16 | text-align: center;
17 | }
18 | .#{$fa-css-prefix}-stack-1x { line-height: inherit; }
19 | .#{$fa-css-prefix}-stack-2x { font-size: 2em; }
20 | .#{$fa-css-prefix}-inverse { color: $fa-inverse; }
21 |
--------------------------------------------------------------------------------
/app/css/font-awesome/scss/font-awesome.scss:
--------------------------------------------------------------------------------
1 | /*!
2 | * Font Awesome 4.7.0 by @davegandy - http://fontawesome.io - @fontawesome
3 | * License - http://fontawesome.io/license (Font: SIL OFL 1.1, CSS: MIT License)
4 | */
5 |
6 | @import "variables";
7 | @import "mixins";
8 | @import "path";
9 | @import "core";
10 | @import "larger";
11 | @import "fixed-width";
12 | @import "list";
13 | @import "bordered-pulled";
14 | @import "animated";
15 | @import "rotated-flipped";
16 | @import "stacked";
17 | @import "icons";
18 | @import "screen-reader";
19 |
--------------------------------------------------------------------------------
/app/css/frame.css:
--------------------------------------------------------------------------------
1 | * {
2 | margin: 0;
3 | padding: 0;
4 |
5 | box-sizing: border-box;
6 | -moz-box-sizing: border-box;
7 | -webkit-box-sizing: border-box;
8 | }
9 |
10 | html {
11 | height: 100%;
12 | width: 100%;
13 | }
14 |
15 | body {
16 | background: transparent;
17 | background-size: cover;
18 | color: #18191b;
19 | float: left;
20 | font-family: "Open Sans", sans-serif;
21 | font-weight: 400;
22 | font-size: 15px;
23 | height: 100%;
24 | width: 100%;
25 | }
26 |
27 | header {
28 | float: left;
29 | max-width: 100%;
30 | padding: 30px 0 20px 60px;
31 | position: relative;
32 | width: 100%;
33 | }
34 |
35 | header img {
36 | float: left;
37 | height: 100px;
38 | max-width: 100%;
39 | }
40 |
41 | header .logo {
42 | float: left;
43 | height: 70px;
44 | left: -70px;
45 | position: relative;
46 | top: 18px;
47 | }
48 |
49 | header time {
50 | color: #ffffff;
51 | opacity: 0;
52 | position: absolute;
53 | right: 70px;
54 | text-shadow: 1px 1px 5px #333333;
55 | top: 50px;
56 | }
57 |
58 | header time .time {
59 | display: block;
60 | font-size: 2.5em;
61 | text-align: right;
62 | }
63 |
64 | header time .date {
65 | clear: both;
66 | display: block;
67 | font-size: 1em;
68 | text-align: right;
69 | }
70 |
71 | /** Content
72 | =============================================== */
73 |
74 | .content {
75 | clear: both;
76 | height: calc(100% - 500px);
77 | padding: 0 40px;
78 | width: 100%;
79 | }
80 |
81 | .content .feed-tile {
82 | max-width: 360px;
83 | }
84 |
85 | .content .feed-tile header {
86 | padding: 0;
87 | }
88 |
89 | /** Module listing
90 | =============================================== */
91 |
92 | .modules {
93 | float: left;
94 | padding: 30px 60px 20px 60px;
95 | width: 100%;
96 | }
97 |
98 | .modules-module {
99 | cursor: pointer;
100 | float: left;
101 | overflow: hidden;
102 | margin: 2px;
103 | opacity: 0;
104 | position: relative;
105 | top: 20px;
106 | transition: box-shadow .1s ease-out, transform .1s ease-out;
107 | transition-delay: .1s;
108 | width: calc(100% / 7);
109 | }
110 |
111 | .modules-module:hover {
112 | /*box-shadow: rgba(32, 32, 32, 0.05) 0 16px 16px;*/
113 | /*outline: 1px solid #DEDEDE;*/
114 | transform: translate(0, -4px);
115 | }
116 |
117 | .modules-module:after {
118 | display: block;
119 | content: '';
120 | padding-top: 56.25%;
121 | }
122 |
123 | .modules-module img {
124 | background: #fff;
125 | max-height: 100%;
126 | position: absolute;
127 | width: 100%;
128 | }
129 |
130 | @media (max-width: 1400px) {
131 | .modules-module {
132 | width: calc(100% / 6);
133 | }
134 | }
135 |
136 | @media (max-width: 1100px) {
137 | .modules-module {
138 | width: calc(100% / 4 - 4px);
139 | }
140 | }
141 |
142 | @media (max-width: 900px) {
143 | .modules-module {
144 | width: calc(100% / 3 - 4px);
145 | }
146 | }
147 |
148 | @media (max-width: 480px) {
149 | .modules {
150 | padding: 30px 10px 20px 10px;
151 | }
152 |
153 | .modules-module {
154 | width: calc(100% / 2 - 4px);
155 | }
156 | }
157 |
158 | @media (max-width: 660px) {
159 | header time {
160 | display: none;
161 | }
162 | }
163 |
--------------------------------------------------------------------------------
/app/css/style.css:
--------------------------------------------------------------------------------
1 | * {
2 | margin: 0;
3 | padding: 0;
4 |
5 | box-sizing: border-box;
6 | -moz-box-sizing: border-box;
7 | -webkit-box-sizing: border-box;
8 | }
9 |
10 | html {
11 | height: 100%;
12 | width: 100%;
13 | }
14 |
15 | body {
16 | background-color: #f5f5f5;
17 | background-position: center center;
18 | background-repeat: no-repeat;
19 | background-size: cover;
20 | color: #18191b;
21 | font-family: "Open Sans", sans-serif;
22 | font-weight: 400;
23 | font-size: 15px;
24 | height: 100%;
25 | }
26 |
27 | /** Navigation
28 | =============================================== */
29 |
30 | header {
31 | background: rgba(255, 255, 255, 0.5);
32 | border-bottom: 1px solid #dedede;
33 | color: #fff;
34 | padding-left: 60px;
35 | position: fixed;
36 | top: 0;
37 | height: 60px;
38 | width: 100%;
39 | z-index: 90;
40 | }
41 |
42 | .header-buttons {
43 | text-align: right;
44 | }
45 |
46 | .header-buttons-button {
47 | display: inline-block;
48 | color: #18191b;
49 | cursor: pointer;
50 | font-size: 16px;
51 | line-height: 60px;
52 | padding: 0 20px;
53 | text-decoration: none;
54 | }
55 |
56 | .header-buttons-button.active {
57 | background: #bbbbbb;
58 | }
59 |
60 | .header-buttons-button:hover {
61 | background: #dedede;
62 | color: #18191b;
63 | }
64 |
65 | /** Header Navigation
66 | =============================================== */
67 |
68 | .header-menu {
69 | cursor: pointer;
70 | left: 0;
71 | outline: none;
72 | position: absolute;
73 | width: 60px;
74 | }
75 |
76 | .header-menu img {
77 | margin: 16px 0 0 10px;
78 | width: 40px;
79 | }
80 |
81 | /** Navigation
82 | =============================================== */
83 |
84 | nav {
85 | background: rgba(255, 255, 255, 0.5);
86 | border-right: 1px solid #dedede;
87 | height: 100%;
88 | left: 0;
89 | outline: none;
90 | overflow: hidden;
91 | position: fixed;
92 | top: 0;
93 | width: 60px;
94 | will-change: transition;
95 | z-index: 100;
96 |
97 | transition: width .2s, box-shadow 0.1s linear 0.1s;
98 | -webkit-transition: width .2s, box-shadow .1s linear .1s;
99 | }
100 |
101 | .nav-opened {
102 | background: #f5f5f5;
103 | box-shadow: 3px 0 20px rgba(0, 0, 0, 0.2);
104 | width: 300px;
105 | will-change: width;
106 |
107 | transition: width .2s, box-shadow 0.1s linear .1s;
108 | -webkit-transition: width .2s, box-shadow .1s linear .1s;
109 | }
110 |
111 | nav .steemPi-logo {
112 | color: #999;
113 | display: inline-block;
114 | font-size: 30px;
115 | line-height: 60px;
116 | height: 56px;
117 | text-align: center;
118 | width: 300px;
119 | }
120 |
121 | nav .steemPi-logo img.logo {
122 | float: left;
123 | margin: 16px 0 0 10px;
124 | width: 40px;
125 | }
126 |
127 | nav .steemPi-logo img.logo-text {
128 | float: left;
129 | margin: 14px 0 0 8px;
130 | width: 140px;
131 | }
132 |
133 | .navigation {
134 | border-top: 1px solid #dedede;
135 | height: calc(100% - 60px);
136 | margin: 0;
137 | overflow: hidden;
138 | overflow-y: auto;
139 | padding: 0;
140 | width: 300px;
141 | }
142 |
143 | .navigation li {
144 | list-style: none;
145 | }
146 |
147 | .navigation-entry a {
148 | display: inline-block;
149 | color: #666666;
150 | padding: 15px 0;
151 | width: 100%;
152 | }
153 |
154 | .navigation-entry a:hover {
155 | background: #dedede;
156 | }
157 |
158 | .navigation-entry .menuItem-icon {
159 | display: inline-block;
160 | float: left;
161 | font-size: 28px;
162 | line-height: 30px;
163 | text-align: center;
164 | width: 60px;
165 | }
166 |
167 | .navigation-entry .menuItem-icon img {
168 | border: 0;
169 | height: 100%;
170 | object-position: center;
171 | object-fit: cover;
172 | width: calc(100% - 30px);
173 | }
174 |
175 | .navigation-entry .menuItem-text {
176 | display: inline-block;
177 | line-height: 30px;
178 | float: left;
179 | width: calc(100% - 60px);
180 | }
181 |
182 | main {
183 | height: 100%;
184 | left: 0;
185 | padding: 60px 0 0 0;
186 | position: fixed;
187 | top: 0;
188 | width: 100%;
189 | z-index: 10;
190 | }
191 |
192 | main iframe {
193 | border: none;
194 | height: 100%;
195 | width: 100%
196 | }
197 |
198 | /** Pace - Loader Bar
199 | =============================================== */
200 |
201 | .pace {
202 | -webkit-pointer-events: none;
203 | pointer-events: none;
204 |
205 | -webkit-user-select: none;
206 | -moz-user-select: none;
207 | user-select: none;
208 | }
209 |
210 | .pace-inactive {
211 | display: none;
212 | }
213 |
214 | .pace .pace-progress {
215 | background: #ee3148;
216 | position: fixed;
217 | z-index: 2000;
218 | top: 0;
219 | right: 100%;
220 | width: 100%;
221 | height: 2px;
222 | }
--------------------------------------------------------------------------------
/app/frame.php:
--------------------------------------------------------------------------------
1 | getModules();
11 |
12 | $Response = getFeed(4);
13 | $result = json_decode($Response->getBody(), true);
14 | $feed = $result['results'];
15 |
16 | if (count($feed) > 4) {
17 | $feed = array_slice($feed, 0, 4);
18 | }
19 |
20 | ?>
21 |
22 |
23 |
24 | STEEMPI | A system for Steemit
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
52 |
53 |
54 | isActive()) {
58 | continue;
59 | }
60 |
61 | if ($Module->getName() === 'settings') {
62 | continue;
63 | }
64 |
65 | ?>
66 |
67 | getIcon(); ?>
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |
76 |
--------------------------------------------------------------------------------
/app/images/backgrounds/default-01.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/techtek/steempi/7ff3f649ed502a23d363ab33ea07c7a9a89c7281/app/images/backgrounds/default-01.jpg
--------------------------------------------------------------------------------
/app/images/backgrounds/default-02.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/techtek/steempi/7ff3f649ed502a23d363ab33ea07c7a9a89c7281/app/images/backgrounds/default-02.jpg
--------------------------------------------------------------------------------
/app/images/backgrounds/default-03.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/techtek/steempi/7ff3f649ed502a23d363ab33ea07c7a9a89c7281/app/images/backgrounds/default-03.jpg
--------------------------------------------------------------------------------
/app/images/backgrounds/default-04.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/techtek/steempi/7ff3f649ed502a23d363ab33ea07c7a9a89c7281/app/images/backgrounds/default-04.jpg
--------------------------------------------------------------------------------
/app/images/backgrounds/default-05.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/techtek/steempi/7ff3f649ed502a23d363ab33ea07c7a9a89c7281/app/images/backgrounds/default-05.jpg
--------------------------------------------------------------------------------
/app/images/backgrounds/default-06.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/techtek/steempi/7ff3f649ed502a23d363ab33ea07c7a9a89c7281/app/images/backgrounds/default-06.jpg
--------------------------------------------------------------------------------
/app/images/logo-text.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
40 |
--------------------------------------------------------------------------------
/app/images/logo.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
18 |
--------------------------------------------------------------------------------
/app/images/readme_header.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/techtek/steempi/7ff3f649ed502a23d363ab33ea07c7a9a89c7281/app/images/readme_header.png
--------------------------------------------------------------------------------
/app/index.php:
--------------------------------------------------------------------------------
1 | getModules();
10 | $background = SteemPi\SteemPi::getBackground();
11 |
12 | ?>
13 |
14 |
15 |
16 |
17 |
18 |
19 | STEEMPI | A system for Steemit
20 |
21 |
22 |
23 |
24 |
25 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
64 |
65 |
93 |
94 |
95 |
96 |
97 |
98 |
99 |
100 |
101 |
102 |
103 |
104 |
105 |
106 |
--------------------------------------------------------------------------------
/app/js/frame.js:
--------------------------------------------------------------------------------
1 | // animations
2 | (function () {
3 | document.body.style.float = 'left';
4 | document.body.style.overflow = 'hidden';
5 | document.body.style.width = '100%';
6 |
7 | var modules = document.getElementsByClassName('modules-module');
8 |
9 | for (var i = 0, len = modules.length; i < len; i++) {
10 | modules[i].addEventListener('click', function (event) {
11 | var Target = event.target;
12 |
13 | if (!Target.classList.contains('modules-module')) {
14 | Target = Target.parentNode;
15 | }
16 |
17 | window.parent.location = '/#!' + Target.getAttribute('data-module');
18 | });
19 |
20 | anime({
21 | targets: modules[i],
22 | opacity: 1,
23 | top : 0,
24 | delay : i * 100,
25 | easing : 'easeInOutQuart'
26 | });
27 | }
28 |
29 | // time
30 | var Time = document.querySelector('header time');
31 | var setTime = function () {
32 | var html = '';
33 |
34 | moment.locale(locale_code);
35 |
36 | html = html + '' + moment().format('HH:mm') + '';
37 | html = html + '' + moment().format('dddd, MMMM Do') + '';
38 |
39 | Time.innerHTML = html;
40 |
41 | document.body.style.overflow = '';
42 | };
43 |
44 | setInterval(setTime, 10000);
45 | setTime();
46 |
47 | anime({
48 | targets: Time,
49 | opacity: 1,
50 | easing : 'easeInOutQuart'
51 | });
52 | })();
53 |
54 | // feed
55 | (function () {
56 |
57 | // build articles
58 | var articles = document.getElementsByClassName('feed-tile');
59 |
60 | var goToArticle = function () {
61 | console.warn(this.getAttribute('data-link'));
62 | window.parent.Router.navigate('#!feed');
63 | };
64 |
65 | for (var i = 0, len = articles.length; i < len; i++) {
66 | articles[i].addEventListener('click', goToArticle.bind(articles[i]));
67 |
68 | anime({
69 | targets: articles[i],
70 | opacity: 1,
71 | top : 0,
72 | delay : i * 100,
73 | easing : 'easeInOutQuart'
74 | });
75 | }
76 | })();
--------------------------------------------------------------------------------
/app/js/index.js:
--------------------------------------------------------------------------------
1 | window.Router = new Navigo(null, true, '#!');
2 | window.SteemPi = {};
3 |
4 | // history api
5 | (function () {
6 | var Frame = document.getElementById('module');
7 |
8 | var openModule = function () {
9 | if (window.location.hash === '') {
10 | Frame.src = '/app/frame.php';
11 | return;
12 | }
13 |
14 | var hash = window.location.hash.replace('\!', '').replace('\#', '');
15 |
16 | if (hash === '') {
17 | Frame.src = '/app/frame.php';
18 | return;
19 | }
20 |
21 | Frame.src = '/modules/' + hash + '/index.php';
22 | };
23 |
24 | Router.on('*', openModule);
25 | openModule();
26 | })();
27 |
28 | // navigation events
29 | (function () {
30 | var Main = document.querySelector('main');
31 | var Nav = document.querySelector('nav');
32 | var HeaderNav = document.querySelector('.header-menu');
33 |
34 | document.querySelector('.steemPi-logo').addEventListener('mousedown', function (event) {
35 | event.preventDefault();
36 | });
37 |
38 | document.querySelector('.steemPi-logo').addEventListener('click', function (event) {
39 | event.preventDefault();
40 | Router.navigate('');
41 | });
42 |
43 | var showMenu = function () {
44 | anime({
45 | targets : Nav,
46 | left : 0,
47 | easing : 'easeInOutQuart',
48 | duration: 200,
49 | complete: function () {
50 | Nav.classList.add('nav-opened');
51 | }
52 | });
53 | };
54 |
55 | var hideMenu = function () {
56 | Nav.classList.remove('nav-opened');
57 |
58 | anime({
59 | targets : Nav,
60 | left : -60,
61 | easing : 'easeInOutQuart',
62 | duration: 500
63 | });
64 | };
65 |
66 | var focusNav = function () {
67 | Nav.focus();
68 | };
69 |
70 | setTimeout(hideMenu, 2000);
71 |
72 | HeaderNav.tabIndex = -1;
73 | Nav.tabIndex = -1;
74 |
75 | // HeaderNav.addEventListener('focus', focusNav, false);
76 | HeaderNav.addEventListener('click', focusNav, false);
77 |
78 | HeaderNav.addEventListener("touchstart", function (event) {
79 | event.preventDefault();
80 | focusNav();
81 | }, false);
82 |
83 |
84 | Nav.addEventListener('focus', showMenu, false);
85 | Nav.addEventListener('blur', hideMenu, false);
86 |
87 | var entries = Nav.querySelectorAll('li a');
88 |
89 | for (var i = 0, len = entries.length; i < len; i++) {
90 | entries[i].addEventListener('mouseup', hideMenu);
91 | }
92 | })();
--------------------------------------------------------------------------------
/app/js/index.loop.js:
--------------------------------------------------------------------------------
1 | window.SteemPi.moduleLoop = false;
2 |
3 | (function () {
4 | var LoopTimeput = null;
5 | var timer = 10000;
6 |
7 | var Button = document.querySelector('.header-buttons .module-loop');
8 | var Navigation = document.querySelector('nav .navigation');
9 | var modules = [].slice.call(Navigation.querySelectorAll('li'));
10 |
11 | modules = modules.map(function (Node) {
12 | return Node.getAttribute('data-module');
13 | });
14 |
15 | /**
16 | * Return the next module
17 | *
18 | * @param module
19 | * @return {String}
20 | */
21 | var getNextModule = function (module) {
22 | var index = modules.indexOf(module);
23 |
24 | if (index === -1) {
25 | return modules[0];
26 | }
27 |
28 | if (typeof modules[index + 1] !== 'undefined') {
29 | return modules[index + 1];
30 | }
31 |
32 | return modules[0];
33 | };
34 |
35 | /**
36 | * Return the current module
37 | *
38 | * @return {String}
39 | */
40 | var getCurrent = function () {
41 | var hash = window.location.hash;
42 |
43 | if (hash === '' || hash === '#!') {
44 | return modules[0];
45 | }
46 |
47 | return hash.replace('#', '').replace('\!', '');
48 | };
49 |
50 | /**
51 | * Loops the module
52 | */
53 | var loop = function () {
54 | if (!window.SteemPi.moduleLoop) {
55 | return;
56 | }
57 |
58 | var PaceNode = document.querySelector('.pace');
59 |
60 | if (PaceNode) {
61 | var Progress = PaceNode.querySelector('.pace-progress');
62 |
63 | Progress.style.transform = 'translate3d(0, 0px, 0px)';
64 | Progress.style.transitionDuration = (timer / 1000) + 's';
65 | PaceNode.className = 'pace';
66 |
67 | setTimeout(function () {
68 | Progress.style.transform = 'translate3d(100%, 0px, 0px)';
69 | }, 10);
70 |
71 | }
72 |
73 | LoopTimeput = setTimeout(function () {
74 | var next = getNextModule(getCurrent());
75 |
76 | if (PaceNode) {
77 | var Progress = PaceNode.querySelector('.pace-progress');
78 |
79 | Progress.style.transitionDuration = '0s';
80 | Progress.style.transform = 'translate3d(0, 0px, 0px)';
81 | PaceNode.classList.add('pace-inactive');
82 | }
83 |
84 | Router.navigate(next);
85 | setTimeout(loop, 200);
86 | }, timer);
87 | };
88 |
89 | // remove events -> workaround
90 | Button.addEventListener('click', function () {
91 | if (window.SteemPi.moduleLoop) {
92 | window.SteemPi.moduleLoop = false;
93 |
94 | if (LoopTimeput) {
95 | clearTimeout(LoopTimeput);
96 | }
97 |
98 | Button.classList.remove('active');
99 |
100 | var PaceNode = document.querySelector('.pace');
101 |
102 | if (PaceNode) {
103 | PaceNode.classList.add('pace-inactive');
104 | }
105 |
106 | return;
107 | }
108 |
109 | Button.classList.add('active');
110 | window.SteemPi.moduleLoop = true;
111 |
112 | loop();
113 | });
114 | })();
--------------------------------------------------------------------------------
/app/locale/de/LC_MESSAGES/steemPi.po:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/techtek/steempi/7ff3f649ed502a23d363ab33ea07c7a9a89c7281/app/locale/de/LC_MESSAGES/steemPi.po
--------------------------------------------------------------------------------
/app/locale/en/LC_MESSAGES/steemPi.po:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/techtek/steempi/7ff3f649ed502a23d363ab33ea07c7a9a89c7281/app/locale/en/LC_MESSAGES/steemPi.po
--------------------------------------------------------------------------------
/app/locale/nl/LC_MESSAGES/steemPi.po:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/techtek/steempi/7ff3f649ed502a23d363ab33ea07c7a9a89c7281/app/locale/nl/LC_MESSAGES/steemPi.po
--------------------------------------------------------------------------------
/app/src/SteemPi/Config.php:
--------------------------------------------------------------------------------
1 | file = $file;
43 | $this->config = $Reader->readFile($file);
44 | }
45 |
46 | /**
47 | * Return a init file
48 | *
49 | * @param string $group
50 | * @param string|bool $name - optional
51 | * @return mixed|null
52 | */
53 | public function get($group, $name = false)
54 | {
55 | if ($name === false) {
56 | if (isset($this->config[$group])) {
57 | return $this->config[$group];
58 | }
59 |
60 | return null;
61 | }
62 |
63 | if (isset($this->config[$group][$name])) {
64 | return $this->config[$group][$name];
65 | }
66 |
67 | return null;
68 | }
69 |
70 | /**
71 | * @param string $group - name of the ini group
72 | * @param string|bool $name - optional
73 | * @param string|integer|float $value
74 | */
75 | public function set($group, $name, $value)
76 | {
77 | if ($name === false) {
78 | $this->config[$group] = $value;
79 |
80 | return;
81 | }
82 |
83 | $this->config[$group][$name] = $value;
84 | }
85 |
86 | /**
87 | * Write the data to the config file
88 | */
89 | public function save()
90 | {
91 | $Writer = new IniWriter();
92 | $config = $Writer->writeToString($this->config);
93 |
94 | $result = ';'.PHP_EOL.PHP_EOL;
95 | $result .= $config;
96 |
97 | file_put_contents($this->file, $result);
98 | }
99 | }
100 |
--------------------------------------------------------------------------------
/app/src/SteemPi/Exception.php:
--------------------------------------------------------------------------------
1 | false,
29 | 'text' => false,
30 | 'color' => false
31 | );
32 |
33 | /**
34 | * @var array
35 | */
36 | protected $cssClasses = array();
37 |
38 | /**
39 | * Menu constructor.
40 | *
41 | * @param array $params
42 | * @param null|Module $Module
43 | */
44 | public function __construct($params = array(), $Module = null)
45 | {
46 | if (isset($params['icon'])) {
47 | $this->attributes['icon'] = $params['icon'];
48 | }
49 |
50 | if (isset($params['text'])) {
51 | $this->attributes['text'] = $params['text'];
52 | }
53 |
54 | if (isset($params['color'])) {
55 | $this->attributes['color'] = $params['color'];
56 | }
57 |
58 | if ($Module instanceof Module) {
59 | $this->Module = $Module;
60 | }
61 | }
62 |
63 | /**
64 | * @param Module $Module
65 | */
66 | public function setModule(Module $Module)
67 | {
68 | $this->Module = $Module;
69 | }
70 |
71 | /**
72 | * @param $class
73 | */
74 | public function addClass($class)
75 | {
76 | $this->cssClasses[] = $class;
77 | }
78 |
79 | /**
80 | * @return string
81 | */
82 | public function getIcon()
83 | {
84 | if (!isset($this->attributes['icon'])) {
85 | return '';
86 | }
87 |
88 | $name = htmlspecialchars($this->Module->getName());
89 | $icon = htmlspecialchars($this->attributes['icon']);
90 | $color = '';
91 |
92 | if (strpos($icon, 'fa-') === false) {
93 | $path = '/modules/'.$name.'/'.$icon;
94 | $html = '
';
95 | } else {
96 | $html = '';
97 | }
98 |
99 | if (isset($this->attributes['color'])) {
100 | $color = htmlspecialchars($this->attributes['color']);
101 | }
102 |
103 | return '
104 |
107 | ';
108 | }
109 |
110 | /**
111 | * Return the HTML Title
112 | *
113 | * @return string
114 | */
115 | public function getText()
116 | {
117 | if (!isset($this->attributes['text'])) {
118 | return '';
119 | }
120 |
121 | $text = htmlspecialchars($this->attributes['text']);
122 | $text = dgettext($this->Module->getName(), $text);
123 |
124 | return '
125 |
128 | ';
129 | }
130 |
131 | /**
132 | * Return the rendered HTML
133 | *
134 | * @return string
135 | */
136 | public function create()
137 | {
138 | $icon = $this->getIcon();
139 | $title = $this->getText();
140 |
141 | $module = '';
142 | $classes = '';
143 |
144 | if ($this->Module) {
145 | $module = $this->Module->getName();
146 | }
147 |
148 | if (!empty($this->cssClasses)) {
149 | $classes = ' class="'.implode('', $this->cssClasses).'"';
150 | }
151 |
152 | return '
153 | '.$icon.'
154 | '.$title.'
155 | ';
156 | }
157 | }
158 |
--------------------------------------------------------------------------------
/app/src/SteemPi/Modules/Handler.php:
--------------------------------------------------------------------------------
1 | getModules());
38 | }
39 |
40 | /**
41 | * Return the module list
42 | *
43 | * @return array
44 | */
45 | public function getModules()
46 | {
47 | $path = $this->getBaseDir().'modules/';
48 | $folders = scandir($path);
49 |
50 | $result = array();
51 | $modules = array();
52 |
53 | // get the order
54 | $order = SteemPi::getConfig()->get('steempi', 'modulesOrder');
55 |
56 | if (empty($order)) {
57 | $order = array();
58 | } else {
59 | $order = explode(',', $order);
60 | }
61 |
62 | // read modules
63 | foreach ($folders as $folder) {
64 | if ($folder == '.' || $folder == '..') {
65 | continue;
66 | }
67 |
68 | if (!file_exists($path.$folder.'/module.json')) {
69 | continue;
70 | }
71 |
72 | $modules[] = new Module($path.$folder.'/module.json');
73 | }
74 |
75 | // order it
76 | $missingCheck = array();
77 |
78 | foreach ($order as $moduleName) {
79 | if (file_exists($path.$moduleName.'/module.json')) {
80 | $Module = new Module($path.$moduleName.'/module.json');
81 | $result[] = $Module;
82 |
83 | $missingCheck[$Module->getName()] = true;
84 | }
85 | }
86 |
87 | /* @var $Module Module */
88 | foreach ($modules as $Module) {
89 | if (!isset($missingCheck[$Module->getName()])) {
90 | $result[] = $Module;
91 | }
92 | }
93 |
94 | return $result;
95 | }
96 |
97 | /**
98 | * Return a specific module
99 | *
100 | * @param $moduleName
101 | * @return Module
102 | */
103 | public function getModule($moduleName)
104 | {
105 | $path = $this->getBaseDir().'modules/';
106 | $Module = new Module($path.$moduleName.'/module.json');
107 |
108 | return $Module;
109 | }
110 | }
--------------------------------------------------------------------------------
/app/src/SteemPi/SteemPi.php:
--------------------------------------------------------------------------------
1 | get('steempi', 'background');
76 |
77 | if (empty($background)) {
78 | $background = '/app/images/backgrounds/default-06.jpg';
79 | }
80 |
81 | $realPath = self::getRootPath().$background;
82 |
83 | if (!file_exists($realPath)) {
84 | $background = '/app/images/backgrounds/default-06.jpg';
85 | }
86 |
87 | return $background;
88 | }
89 |
90 | /**
91 | * Return a list of all available backgrounds
92 | *
93 | * @return array
94 | */
95 | public static function getBackgrounds()
96 | {
97 | $images = array();
98 |
99 | // default folder
100 | $dir = self::getRootPath().'/app/images/backgrounds/';
101 | $handle = opendir($dir);
102 |
103 | while (false !== ($image = readdir($handle))) {
104 | if ($image == '.' || $image == '..') {
105 | continue;
106 | }
107 |
108 | $images[] = '/app/images/backgrounds/'.$image;
109 | }
110 |
111 | // custom folder
112 | $dir = self::getRootPath().'/backgrounds/';
113 |
114 | if (is_dir($dir)) {
115 |
116 | $handle = opendir($dir);
117 |
118 | while (false !== ($image = readdir($handle))) {
119 | if ($image == '.' || $image == '..') {
120 | continue;
121 | }
122 |
123 | $images[] = '/backgrounds/'.$image;
124 | }
125 | }
126 |
127 | return $images;
128 | }
129 |
130 | /**
131 | * Load the current localization
132 | */
133 | public static function loadLanguage()
134 | {
135 | $lang = self::getConfig()->get('steempi', 'language');
136 |
137 | if (!$lang) {
138 | $lang = 'en_GB';
139 | }
140 |
141 | switch ($lang) {
142 | case 'en_EN':
143 | $lang = 'en_GB';
144 | break;
145 | }
146 |
147 | setlocale(
148 | 6,
149 | $lang.".UTF-8",
150 | $lang.".utf8",
151 | $lang.".UTF8",
152 | $lang.".utf-8",
153 | $lang
154 | );
155 |
156 | putenv("LANG=".$lang.'.utf8');
157 |
158 | bindtextdomain('steemPi', './locale');
159 | bind_textdomain_codeset('steemPi', 'UTF-8');
160 |
161 | $modules = self::getModuleHandler()->getModules();
162 |
163 | /* @var $Module Modules\Module */
164 | foreach ($modules as $Module) {
165 | $localeDir = $Module->getDir().'locale';
166 |
167 | if (is_dir($localeDir)) {
168 | bindtextdomain($Module->getName(), $localeDir);
169 | bind_textdomain_codeset($Module->getName(), 'UTF-8');
170 | }
171 | }
172 |
173 | textdomain('steemPi');
174 |
175 | \Locale::setDefault(str_replace('_', '-', $lang));
176 | }
177 | }
178 |
--------------------------------------------------------------------------------
/app/tests/gpio.php:
--------------------------------------------------------------------------------
1 |
2 |
3 |
58 |
59 |
60 |
61 |
62 |
63 |
64 |
65 |
78 |
79 |
80 |
81 |
82 |
83 |
84 |
85 |