]> git.immae.eu Git - github/wallabag/wallabag.git/commitdiff
Merge pull request #427 from wallabag/dev 1.4.0
authorNicolas Lœuillet <nicolas@loeuillet.org>
Mon, 3 Feb 2014 18:03:41 +0000 (10:03 -0800)
committerNicolas Lœuillet <nicolas@loeuillet.org>
Mon, 3 Feb 2014 18:03:41 +0000 (10:03 -0800)
changelog 1.4

84 files changed:
CONTRIBUTING.md
CREDITS.md
INSTALL.md [deleted file]
TODO.md [deleted file]
inc/poche/Database.class.php
inc/poche/Poche.class.php
inc/poche/Tools.class.php
inc/poche/Url.class.php
inc/poche/User.class.php
inc/poche/config.inc.php.new
inc/poche/global.inc.php
inc/poche/pochePictures.php
index.php
install/mysql.sql
themes/README.md [deleted file]
themes/courgette/README.md [new file with mode: 0755]
themes/courgette/_head.twig [new file with mode: 0755]
themes/courgette/_menu.twig [new file with mode: 0755]
themes/courgette/_top.twig [new file with mode: 0755]
themes/courgette/config.twig [new file with mode: 0755]
themes/courgette/css/.DS_Store [new file with mode: 0644]
themes/courgette/css/font.css [new file with mode: 0755]
themes/courgette/css/knacss.css [new file with mode: 0755]
themes/courgette/css/messages.css [new file with mode: 0755]
themes/courgette/css/print.css [new file with mode: 0755]
themes/courgette/css/style-default.css [new file with mode: 0755]
themes/courgette/css/style.css [new file with mode: 0755]
themes/courgette/error.twig [new file with mode: 0755]
themes/courgette/font/fontello.eot [new file with mode: 0644]
themes/courgette/font/fontello.svg [new file with mode: 0644]
themes/courgette/font/fontello.ttf [new file with mode: 0644]
themes/courgette/font/fontello.woff [new file with mode: 0644]
themes/courgette/home.twig [new file with mode: 0755]
themes/courgette/img/apple-touch-icon-144x144-precomposed.png [new file with mode: 0755]
themes/courgette/img/apple-touch-icon-72x72-precomposed.png [new file with mode: 0755]
themes/courgette/img/apple-touch-icon.png [new file with mode: 0755]
themes/courgette/img/bg-select.png [new file with mode: 0644]
themes/courgette/img/default/backtotop.png [new file with mode: 0755]
themes/courgette/img/default/bad-display.png [new file with mode: 0755]
themes/courgette/img/default/checkmark-off.png [new file with mode: 0755]
themes/courgette/img/default/checkmark-on.png [new file with mode: 0755]
themes/courgette/img/default/clock.png [new file with mode: 0755]
themes/courgette/img/default/down.png [new file with mode: 0755]
themes/courgette/img/default/envelop.png [new file with mode: 0755]
themes/courgette/img/default/flattr.png [new file with mode: 0755]
themes/courgette/img/default/left.png [new file with mode: 0755]
themes/courgette/img/default/link.png [new file with mode: 0755]
themes/courgette/img/default/remove.png [new file with mode: 0755]
themes/courgette/img/default/shaarli.png [new file with mode: 0755]
themes/courgette/img/default/star-off.png [new file with mode: 0755]
themes/courgette/img/default/star-on.png [new file with mode: 0755]
themes/courgette/img/default/top.png [new file with mode: 0755]
themes/courgette/img/default/twitter.png [new file with mode: 0755]
themes/courgette/img/favicon.ico [new file with mode: 0755]
themes/courgette/img/logo.png [new file with mode: 0755]
themes/courgette/img/logo.svg [new file with mode: 0644]
themes/courgette/img/messages/close.png [new file with mode: 0755]
themes/courgette/img/messages/cross.png [new file with mode: 0755]
themes/courgette/img/messages/help.png [new file with mode: 0755]
themes/courgette/img/messages/tick.png [new file with mode: 0755]
themes/courgette/img/messages/warning.png [new file with mode: 0755]
themes/courgette/js/init.js [new file with mode: 0755]
themes/courgette/js/restoreScroll.js [new file with mode: 0755]
themes/courgette/layout.twig [new file with mode: 0755]
themes/courgette/login.twig [new file with mode: 0755]
themes/courgette/screenshot.jpg [new file with mode: 0755]
themes/courgette/theme.ini [new file with mode: 0644]
themes/courgette/view.twig [new file with mode: 0755]
themes/dark/theme.ini [new file with mode: 0644]
themes/default/_bookmarklet.twig
themes/default/_footer.twig
themes/default/config.twig
themes/default/error.twig
themes/default/install.twig
themes/default/layout.twig
themes/default/login.twig
themes/default/theme.ini [new file with mode: 0644]
themes/default/view.twig
themes/dmagenta/theme.ini [new file with mode: 0644]
themes/solarized-dark/css/style-solarized-dark.css
themes/solarized-dark/theme.ini [new file with mode: 0644]
themes/solarized/css/style-solarized.css
themes/solarized/theme.ini [new file with mode: 0644]
wallabag_compatibility_test.php [moved from poche_compatibility_test.php with 98% similarity]

index c89411f38de9a194934ca80231b4eca4c5abf6e7..7fdca652bb538355d62869c83d07bdaa6ad8166d 100644 (file)
@@ -1,11 +1,11 @@
 # How contributing
 
 ## You found a bug
-Please [open a new issue](https://github.com/inthepoche/poche/issues/new).
+Please [open a new issue](https://github.com/wallabag/demo.wallabag.org/issues/new).
 
 To fix the bug quickly, we need some infos:
-* your poche version (in ./inc/poche/myconfig.inc.php)
-* the link you want to poche and which causes problem
+* your demo.wallabag.org version (in ./index.php)
+* the link you want to save and which causes problem
 
 ## You want to fix a bug or to add a feature
-Please fork poche and work with **the dev branch** only. Do not work on master branch.
+Please fork wallabag and work with **the dev branch** only. **Do not work on master branch**.
\ No newline at end of file
index 6046a6aacdaaa3ac68c0017cdcabd500e71eeef9..391f53c537f03f965274ac2fff48dc14f9214490 100644 (file)
@@ -1,4 +1,4 @@
-poche is based on :
+wallabag is based on :
 * PHP Readability https://bitbucket.org/fivefilters/php-readability
 * Full Text RSS http://code.fivefilters.org/full-text-rss/src
 * Encoding https://github.com/neitanod/forceutf8
@@ -10,6 +10,6 @@ poche is based on :
 * Flash messages https://github.com/plasticbrain/PHP-Flash-Messages
 * Pagination https://github.com/daveismyname/pagination
 
-poche is developed by Nicolas Lœuillet under the Do What the Fuck You Want to Public License
+wallabag is developed by Nicolas Lœuillet under the Do What the Fuck You Want to Public License
 
-Contributors : https://github.com/inthepoche/poche/graphs/contributors
\ No newline at end of file
+Contributors : https://github.com/wallabag/wallabag/graphs/contributors
\ No newline at end of file
diff --git a/INSTALL.md b/INSTALL.md
deleted file mode 100644 (file)
index df245ff..0000000
+++ /dev/null
@@ -1,3 +0,0 @@
-# Installing poche
-
-Read the full documentation here: http://doc.inthepoche.com/doku.php?id=users:begin:install
diff --git a/TODO.md b/TODO.md
deleted file mode 100644 (file)
index fdba2a5..0000000
--- a/TODO.md
+++ /dev/null
@@ -1,9 +0,0 @@
-# TODO
-
-* pouvoir annuler la suppression
-* conventions codage ? phing ? vérifier error_log qui trainent
-* phpDocumentor
-* minifier css 
-* barre fixe d'admin sur la page d'un billet ? 
-* revoir export (export vers pocket &cie ? )
-* raccourcis clavier 
\ No newline at end of file
index 04731821fb3311a6cd0e6180bfe5d8bc4ec9ebdb..0457af6913ada9a34a56fa9903384c5eab1ff4f5 100644 (file)
@@ -1,9 +1,9 @@
 <?php
 /**
- * poche, a read it later open source system
+ * wallabag, self hostable application allowing you to not miss any content anymore
  *
- * @category   poche
- * @author     Nicolas Lœuillet <support@inthepoche.com>
+ * @category   wallabag
+ * @author     Nicolas Lœuillet <nicolas@loeuillet.org>
  * @copyright  2013
  * @license    http://www.wtfpl.net/ see COPYING file
  */
@@ -165,9 +165,14 @@ class Database {
         }
     }
 
-    public function login($username, $password) {
-        $sql = "SELECT * FROM users WHERE username=? AND password=?";
-        $query = $this->executeQuery($sql, array($username, $password));
+    public function login($username, $password, $isauthenticated=false) {
+        if ($isauthenticated) {
+          $sql = "SELECT * FROM users WHERE username=?";
+          $query = $this->executeQuery($sql, array($username));
+        } else {
+          $sql = "SELECT * FROM users WHERE username=? AND password=?";
+          $query = $this->executeQuery($sql, array($username, $password));
+        }
         $login = $query->fetchAll();
 
         $user = array();
@@ -193,7 +198,7 @@ class Database {
     public function updateUserConfig($userId, $key, $value) {
         $config = $this->getConfigUser($userId);
         
-        if (!isset ($user_config[$key])) {
+        if (! isset($config[$key])) {
             $sql = "INSERT INTO users_config (value, user_id, name) VALUES (?, ?, ?)";
         }
         else {
index 76a73be2b88e188500c3ad7affd11468e2a7dead..4df90067d042ade1f82c0f64eeb9ac4ea4c38ecf 100644 (file)
@@ -1,9 +1,9 @@
 <?php
 /**
- * poche, a read it later open source system
+ * wallabag, self hostable application allowing you to not miss any content anymore
  *
- * @category   poche
- * @author     Nicolas Lœuillet <support@inthepoche.com>
+ * @category   wallabag
+ * @author     Nicolas Lœuillet <nicolas@loeuillet.org>
  * @copyright  2013
  * @license    http://www.wtfpl.net/ see COPYING file
  */
@@ -22,15 +22,6 @@ class Poche
     private $currentTheme = '';
     private $currentLanguage = '';
     private $notInstalledMessage = array();
-    
-    # @todo make this dynamic (actually install themes and save them in the database including author information et cetera)
-    private $installedThemes = array(
-        'default' => array('requires' => array()),
-        'dark' => array('requires' => array('default')),
-        'dmagenta' => array('requires' => array('default')),
-        'solarized' => array('requires' => array('default')),
-        'solarized-dark' => array('requires' => array('default'))
-    );
 
     public function __construct()
     {
@@ -110,7 +101,7 @@ class Poche
         $passTheme = TRUE;
         # Twig is an absolute requirement for Poche to function. Abort immediately if the Composer installer hasn't been run yet
         if (! self::$canRenderTemplates) {
-            $this->notInstalledMessage[] = 'Twig does not seem to be installed. Please initialize the Composer installation to automatically fetch dependencies. Have a look at <a href="http://doc.inthepoche.com/doku.php?id=users:begin:install">the documentation.</a>';
+            $this->notInstalledMessage[] = 'Twig does not seem to be installed. Please initialize the Composer installation to automatically fetch dependencies. Have a look at <a href="http://doc.wallabag.org/doku.php?id=users:begin:install">the documentation.</a>';
             $passTheme = FALSE;
         }
 
@@ -123,21 +114,26 @@ class Poche
         } 
         
         # Check if the selected theme and its requirements are present
-        if ($this->getTheme() != '' && ! is_dir(THEME . '/' . $this->getTheme())) {
-            $this->notInstalledMessage[] = 'The currently selected theme (' . $this->getTheme() . ') does not seem to be properly installed (Missing directory: ' . THEME . '/' . $this->getTheme() . ')';
+        $theme = $this->getTheme();
+
+        if ($theme != '' && ! is_dir(THEME . '/' . $theme)) {
+            $this->notInstalledMessage[] = 'The currently selected theme (' . $theme . ') does not seem to be properly installed (Missing directory: ' . THEME . '/' . $theme . ')';
             
             self::$canRenderTemplates = false;
             
             $passTheme = FALSE;
         }
         
-        foreach ($this->installedThemes[$this->getTheme()]['requires'] as $requiredTheme) {
-            if (! is_dir(THEME . '/' . $requiredTheme)) {
-                $this->notInstalledMessage[] = 'The required "' . $requiredTheme . '" theme is missing for the current theme (' . $this->getTheme() . ')';
+        $themeInfo = $this->getThemeInfo($theme);
+        if (isset($themeInfo['requirements']) && is_array($themeInfo['requirements'])) {
+            foreach ($themeInfo['requirements'] as $requiredTheme) {
+                if (! is_dir(THEME . '/' . $requiredTheme)) {
+                    $this->notInstalledMessage[] = 'The required "' . $requiredTheme . '" theme is missing for the current theme (' . $theme . ')';
                 
-                self::$canRenderTemplates = false;
+                    self::$canRenderTemplates = false;
                 
-                $passTheme = FALSE;
+                    $passTheme = FALSE;
+                }
             }
         }
 
@@ -193,32 +189,36 @@ class Poche
     private function initTpl()
     {
         $loaderChain = new Twig_Loader_Chain();
+        $theme = $this->getTheme();
        
         # add the current theme as first to the loader chain so Twig will look there first for overridden template files
         try {
-            $loaderChain->addLoader(new Twig_Loader_Filesystem(THEME . '/' . $this->getTheme()));
+            $loaderChain->addLoader(new Twig_Loader_Filesystem(THEME . '/' . $theme));
         } catch (Twig_Error_Loader $e) {
             # @todo isInstalled() should catch this, inject Twig later
-            die('The currently selected theme (' . $this->getTheme() . ') does not seem to be properly installed (' . THEME . '/' . $this->getTheme() .' is missing)');
+            die('The currently selected theme (' . $theme . ') does not seem to be properly installed (' . THEME . '/' . $theme .' is missing)');
         }
         
         # add all required themes to the loader chain
-        foreach ($this->installedThemes[$this->getTheme()]['requires'] as $requiredTheme) {
-            try {
-                $loaderChain->addLoader(new Twig_Loader_Filesystem(THEME . '/' . DEFAULT_THEME));
-            } catch (Twig_Error_Loader $e) {
-                # @todo isInstalled() should catch this, inject Twig later
-                die('The required "' . $requiredTheme . '" theme is missing for the current theme (' . $this->getTheme() . ')');
+        $themeInfo = $this->getThemeInfo($theme);
+        if (isset($themeInfo['requirements']) && is_array($themeInfo['requirements'])) {
+            foreach ($themeInfo['requirements'] as $requiredTheme) {
+                try {
+                    $loaderChain->addLoader(new Twig_Loader_Filesystem(THEME . '/' . $requiredTheme));
+                } catch (Twig_Error_Loader $e) {
+                    # @todo isInstalled() should catch this, inject Twig later
+                    die('The required "' . $requiredTheme . '" theme is missing for the current theme (' . $theme . ')');
+                }
             }
         }
         
         if (DEBUG_POCHE) {
-            $twig_params = array();
+            $twigParams = array();
         } else {
-            $twig_params = array('cache' => CACHE);
+            $twigParams = array('cache' => CACHE);
         }
         
-        $this->tpl = new Twig_Environment($loaderChain, $twig_params);
+        $this->tpl = new Twig_Environment($loaderChain, $twigParams);
         $this->tpl->addExtension(new Twig_Extensions_Extension_I18n());
         
         # filter to display domain name of an url
@@ -234,7 +234,7 @@ class Poche
         $this->tpl->addFilter($filter);
     }
 
-    private function install() 
+    private function install()
     {
         Tools::logm('poche still not installed');
         echo $this->tpl->render('install.twig', array(
@@ -265,34 +265,59 @@ class Poche
         return $this->currentTheme;
     }
 
-    public function getLanguage() {
-        return $this->currentLanguage;
+    /**
+     * Provides theme information by parsing theme.ini file if present in the theme's root directory.
+     * In all cases, the following data will be returned:
+     * - name: theme's name, or key if the theme is unnamed,
+     * - current: boolean informing if the theme is the current user theme.
+     *
+     * @param string $theme Theme key (directory name)
+     * @return array|boolean Theme information, or false if the theme doesn't exist.
+     */
+    public function getThemeInfo($theme) {
+        if (!is_dir(THEME . '/' . $theme)) {
+            return false;
+        }
+
+        $themeIniFile = THEME . '/' . $theme . '/theme.ini';
+        $themeInfo = array();
+
+        if (is_file($themeIniFile) && is_readable($themeIniFile)) {
+            $themeInfo = parse_ini_file($themeIniFile);
+        }
+        
+        if ($themeInfo === false) {
+            $themeInfo = array();
+        }
+        if (!isset($themeInfo['name'])) {
+            $themeInfo['name'] = $theme;
+        }
+        $themeInfo['current'] = ($theme === $this->getTheme());
+
+        return $themeInfo;
     }
     
     public function getInstalledThemes() {
         $handle = opendir(THEME);
         $themes = array();
-        
+
         while (($theme = readdir($handle)) !== false) {
             # Themes are stored in a directory, so all directory names are themes
             # @todo move theme installation data to database
-            if (! is_dir(THEME . '/' . $theme) || in_array($theme, array('..', '.'))) {
+            if (!is_dir(THEME . '/' . $theme) || in_array($theme, array('.', '..'))) {
                 continue;
             }
-            
-            $current = false;
-            
-            if ($theme === $this->getTheme()) {
-                $current = true;
-            }
-            
-            $themes[] = array('name' => $theme, 'current' => $current);
+
+            $themes[$theme] = $this->getThemeInfo($theme);
         }
-        
-        sort($themes);
+
         return $themes;
     }
 
+    public function getLanguage() {
+        return $this->currentLanguage;
+    }
+
     public function getInstalledLanguages() {
         $handle = opendir(LOCALE);
         $languages = array();
@@ -325,6 +350,22 @@ class Poche
         );
     }
 
+    protected function getPageContent(Url $url)
+    {
+        $options = array('http' => array('user_agent' => 'poche'));
+        if (isset($_SERVER['AUTH_TYPE']) && "basic" === strtolower($_SERVER['AUTH_TYPE'])) {
+            $options['http']['header'] = sprintf(
+                "Authorization: Basic %s", 
+                base64_encode(
+                    sprintf('%s:%s', $_SERVER['PHP_AUTH_USER'], $_SERVER['PHP_AUTH_PW'])
+                )
+            );
+        }
+        $context = stream_context_create($options);
+        $json = file_get_contents(Tools::getPocheUrl() . '/inc/3rdparty/makefulltextfeed.php?url='.urlencode($url->getUrl()).'&max=5&links=preserve&exc=&format=json&submit=Create+Feed', false, $context);
+        return json_decode($json, true);
+    }
+
     /**
      * Call action (mark as fav, archive, delete, etc.)
      */
@@ -333,11 +374,8 @@ class Poche
         switch ($action)
         {
             case 'add':
-                $options = array('http' => array('user_agent' => 'poche'));
-                $context = stream_context_create($options);
-                $json = file_get_contents(Tools::getPocheUrl() . '/inc/3rdparty/makefulltextfeed.php?url='.urlencode($url->getUrl()).'&max=5&links=preserve&exc=&format=json&submit=Create+Feed', false, $context);
-                $content = json_decode($json, true);
-                $title = $content['rss']['channel']['item']['title'];
+                $content = $this->getPageContent($url);
+                $title = ($content['rss']['channel']['item']['title'] != '') ? $content['rss']['channel']['item']['title'] : _('Untitled');
                 $body = $content['rss']['channel']['item']['description'];
 
                 if ($this->store->add($url->getUrl(), $title, $body, $this->user->getId())) {
@@ -586,8 +624,8 @@ class Poche
         $themes = $this->getInstalledThemes();
         $actualTheme = false;
         
-        foreach ($themes as $theme) {
-            if ($theme['name'] == $_POST['theme']) {
+        foreach (array_keys($themes) as $theme) {
+            if ($theme == $_POST['theme']) {
                 $actualTheme = true;
                 break;
             }
@@ -654,17 +692,17 @@ class Poche
      */
     private function credentials() {
         if(isset($_SERVER['PHP_AUTH_USER'])) {
-            return array($_SERVER['PHP_AUTH_USER'],'php_auth');
+            return array($_SERVER['PHP_AUTH_USER'],'php_auth',true);
         }
         if(!empty($_POST['login']) && !empty($_POST['password'])) {
-            return array($_POST['login'],$_POST['password']);
+            return array($_POST['login'],$_POST['password'],false);
         }
         if(isset($_SERVER['REMOTE_USER'])) {
-            return array($_SERVER['REMOTE_USER'],'http_auth');
+            return array($_SERVER['REMOTE_USER'],'http_auth',true);
         }
 
-        return array(false,false);
-     }
+        return array(false,false,false);
+    }
 
     /**
      * checks if login & password are correct and save the user in session.
@@ -675,18 +713,19 @@ class Poche
      */
     public function login($referer)
     {
-        list($login,$password)=$this->credentials();
+        list($login,$password,$isauthenticated)=$this->credentials();
         if($login === false || $password === false) {
             $this->messages->add('e', _('login failed: you have to fill all fields'));
             Tools::logm('login failed');
             Tools::redirect();
         }
         if (!empty($login) && !empty($password)) {
-            $user = $this->store->login($login, Tools::encodeString($password . $login));
+            $user = $this->store->login($login, Tools::encodeString($password . $login), $isauthenticated);
             if ($user != array()) {
                 # Save login into Session
-               $longlastingsession = isset($_POST['longlastingsession']);
-                Session::login($user['username'], $user['password'], $login, Tools::encodeString($password . $login), $longlastingsession, array('poche_user' => new User($user)));
+                $longlastingsession = isset($_POST['longlastingsession']);
+                $passwordTest = ($isauthenticated) ? $user['password'] : Tools::encodeString($password . $login);
+                Session::login($user['username'], $user['password'], $login, $passwordTest, $longlastingsession, array('poche_user' => new User($user)));
                 $this->messages->add('s', _('welcome to your poche'));
                 Tools::logm('login successful');
                 Tools::redirect($referer);
@@ -847,6 +886,52 @@ class Poche
         Tools::redirect();
     }
 
+    /**
+     * import from Poche exported file
+     * @param string $targetFile the file used for importing
+     * @return boolean 
+     */
+    private function importFromPoche($targetFile)
+    {
+        $str_data = file_get_contents($targetFile);
+        $data = json_decode($str_data,true);
+        Tools::logm('starting import from Poche');
+
+
+        $sequence = '';
+        if (STORAGE == 'postgres') {
+            $sequence = 'entries_id_seq';
+        }
+
+        $count = 0;
+        foreach ($data as $value) {
+
+            $url = new Url(base64_encode($value['url']));
+            $favorite = ($value['is_fav'] == -1);
+            $archive = ($value['is_read'] == -1);
+    
+            # we can add the url
+            if (!is_null($url) && $url->isCorrect()) {
+                
+                $this->action('add', $url, 0, TRUE);
+                
+                $count++;
+                if ($favorite) {
+                    $last_id = $this->store->getLastId($sequence);
+                    $this->action('toggle_fav', $url, $last_id, TRUE);
+                }
+                if ($archive) {
+                    $last_id = $this->store->getLastId($sequence);
+                    $this->action('toggle_archive', $url, $last_id, TRUE);
+                }
+            }
+            
+        }
+        $this->messages->add('s', _('import from Poche completed. ' . $count . ' new links.'));
+        Tools::logm('import from Poche completed');
+        Tools::redirect();
+    }
+
     /**
      * import datas into your poche
      * @param  string $from name of the service to import : pocket, instapaper or readability
@@ -858,7 +943,8 @@ class Poche
         $providers = array(
             'pocket' => 'importFromPocket',
             'readability' => 'importFromReadability',
-            'instapaper' => 'importFromInstapaper'
+            'instapaper' => 'importFromInstapaper',
+            'poche' => 'importFromPoche',
         );
         
         if (! isset($providers[$from])) {
@@ -908,7 +994,7 @@ class Poche
         if (file_exists($cache_file) && (filemtime($cache_file) > (time() - 86400 ))) {
            $version = file_get_contents($cache_file);
         } else {
-           $version = file_get_contents('http://static.inthepoche.com/versions/' . $which);
+           $version = file_get_contents('http://static.wallabag.org/versions/' . $which);
            file_put_contents($cache_file, $version, LOCK_EX);
         }
         return $version;
index 6391658259bea3aeecd3e18c15fa0a157233a605..515a08aac294567e2e5b223a7b7bd81205b51d2b 100644 (file)
@@ -1,9 +1,9 @@
 <?php
 /**
- * poche, a read it later open source system
+ * wallabag, self hostable application allowing you to not miss any content anymore
  *
- * @category   poche
- * @author     Nicolas Lœuillet <support@inthepoche.com>
+ * @category   wallabag
+ * @author     Nicolas Lœuillet <nicolas@loeuillet.org>
  * @copyright  2013
  * @license    http://www.wtfpl.net/ see COPYING file
  */
@@ -43,7 +43,9 @@ class Tools
             || (isset($_SERVER["SERVER_PORT"])
                     && $_SERVER["SERVER_PORT"] == '443') // HTTPS detection.
             || (isset($_SERVER["SERVER_PORT"]) //Custom HTTPS port detection 
-                    && $_SERVER["SERVER_PORT"] == SSL_PORT);
+                    && $_SERVER["SERVER_PORT"] == SSL_PORT)
+             || (isset($_SERVER['HTTP_X_FORWARDED_PROTO'])
+                    && $_SERVER['HTTP_X_FORWARDED_PROTO'] == 'https');
 
         $serverport = (!isset($_SERVER["SERVER_PORT"])
             || $_SERVER["SERVER_PORT"] == '80'
index 8b3468c3a2eff28adeeb39495f4d043a0db0fa32..aba236fa5b57f24bf8d6b479fa532730ffef7dea 100644 (file)
@@ -1,9 +1,9 @@
 <?php
 /**
- * poche, a read it later open source system
+ * wallabag, self hostable application allowing you to not miss any content anymore
  *
- * @category   poche
- * @author     Nicolas Lœuillet <support@inthepoche.com>
+ * @category   wallabag
+ * @author     Nicolas Lœuillet <nicolas@loeuillet.org>
  * @copyright  2013
  * @license    http://www.wtfpl.net/ see COPYING file
  */
index 6dac7839719472e952b7ae6e356d3da1d310f3fa..cc8bec650d44dc182006d805b20b81f154ef9fb1 100644 (file)
@@ -1,9 +1,9 @@
 <?php
 /**
- * poche, a read it later open source system
+ * wallabag, self hostable application allowing you to not miss any content anymore
  *
- * @category   poche
- * @author     Nicolas Lœuillet <support@inthepoche.com>
+ * @category   wallabag
+ * @author     Nicolas Lœuillet <nicolas@loeuillet.org>
  * @copyright  2013
  * @license    http://www.wtfpl.net/ see COPYING file
  */
index c60d4f80040f2872309345080aee40d75a7ed43c..39cb2f2f2ae74d91a817ed7077fbf1d57c12b93c 100755 (executable)
@@ -1,9 +1,9 @@
 <?php
 /**
- * poche, a read it later open source system
+ * wallabag, self hostable application allowing you to not miss any content anymore
  *
- * @category   poche
- * @author     Nicolas Lœuillet <support@inthepoche.com>
+ * @category   wallabag
+ * @author     Nicolas Lœuillet <nicolas@loeuillet.org>
  * @copyright  2013
  * @license    http://www.wtfpl.net/ see COPYING file
  */
@@ -55,7 +55,9 @@ define ('PAGINATION', '10');
 define ('POCKET_FILE', '/ril_export.html');
 define ('READABILITY_FILE', '/readability');
 define ('INSTAPAPER_FILE', '/instapaper-export.html');
+define ('POCHE_FILE', '/poche-export');
 
 define ('IMPORT_POCKET_FILE', ROOT . POCKET_FILE);
 define ('IMPORT_READABILITY_FILE', ROOT . READABILITY_FILE);
 define ('IMPORT_INSTAPAPER_FILE', ROOT . INSTAPAPER_FILE);
+define ('IMPORT_POCHE_FILE', ROOT . POCHE_FILE);
\ No newline at end of file
index 846699d3f73404b38aa506d0f75720ed55a578ac..e2beade1f2c3904c35daef0fba3f18d5c3a53055 100644 (file)
@@ -1,9 +1,9 @@
 <?php
 /**
- * poche, a read it later open source system
+ * wallabag, self hostable application allowing you to not miss any content anymore
  *
- * @category   poche
- * @author     Nicolas Lœuillet <support@inthepoche.com>
+ * @category   wallabag
+ * @author     Nicolas Lœuillet <nicolas@loeuillet.org>
  * @copyright  2013
  * @license    http://www.wtfpl.net/ see COPYING file
  */
index b0cfb9df84934f657fd44e664750ec3956edbea8..e4b0b1608843b0ec8d0a81642a44fb8c2e55d161 100644 (file)
@@ -1,9 +1,9 @@
 <?php
 /**
- * poche, a read it later open source system
+ * wallabag, self hostable application allowing you to not miss any content anymore
  *
- * @category   poche
- * @author     Nicolas Lœuillet <support@inthepoche.com>
+ * @category   wallabag
+ * @author     Nicolas Lœuillet <nicolas@loeuillet.org>
  * @copyright  2013
  * @license    http://www.wtfpl.net/ see COPYING file
  */
index 4e86fe11d5a9709a684910e7a0b38403b99f766d..9113f1932255ed71657fa24b8559f2be8c3d6bc3 100644 (file)
--- a/index.php
+++ b/index.php
@@ -1,14 +1,14 @@
 <?php
 /**
- * poche, a read it later open source system
+ * wallabag, self hostable application allowing you to not miss any content anymore
  *
- * @category   poche
- * @author     Nicolas Lœuillet <support@inthepoche.com>
+ * @category   wallabag
+ * @author     Nicolas Lœuillet <nicolas@loeuillet.org>
  * @copyright  2013
  * @license    http://www.wtfpl.net/ see COPYING file
  */
 
-define ('POCHE', '1.3.0');
+define ('POCHE', '1.4.0');
 require_once 'inc/poche/global.inc.php';
 session_start(); 
 
index d16381d83b3df33fcff5ddfd6cd8cbd869831472..de5640e4a6e13b63b8c61dd4e289ee7750177399 100644 (file)
@@ -9,8 +9,8 @@ CREATE TABLE IF NOT EXISTS `entries` (
   `id` int(11) NOT NULL AUTO_INCREMENT,
   `title` varchar(255) NOT NULL,
   `url` varchar(255) NOT NULL,
-  `is_read` tinyint(1) NOT NULL,
-  `is_fav` tinyint(1) NOT NULL,
+  `is_read` tinyint(1) NOT NULL DEFAULT 0,
+  `is_fav` tinyint(1) NOT NULL DEFAULT 0,
   `content` blob NOT NULL,
   `user_id` int(11) NOT NULL,
   PRIMARY KEY (`id`)
@@ -20,7 +20,7 @@ CREATE TABLE IF NOT EXISTS `users` (
   `id` int(11) NOT NULL AUTO_INCREMENT,
   `username` varchar(255) NOT NULL,
   `password` varchar(255) NOT NULL,
-  `name` int(255) NOT NULL,
+  `name` varchar(255) NOT NULL,
   `email` varchar(255) NOT NULL,
   PRIMARY KEY (`id`)
 ) ENGINE=InnoDB  DEFAULT CHARSET=utf8;
diff --git a/themes/README.md b/themes/README.md
deleted file mode 100644 (file)
index b5d925b..0000000
+++ /dev/null
@@ -1,31 +0,0 @@
-# poche-themes
-
-themes created by poche users
-
-## list of themes
-
-* dark ([preview](https://raw.github.com/inthepoche/poche/master/themes/dark/screenshot.jpg))
-* dmagenta ([preview](https://raw.github.com/inthepoche/poche/master/themes/dmagenta/screenshot.jpg))
-* solarized ([preview](https://raw.github.com/inthepoche/poche/master/themes/solarized/screenshot.jpg))
-* solarized-dark ([preview](https://raw.github.com/inthepoche/poche/master/themes/solarized-dark/screenshot.jpg))
-
-## installation
-
-In your poche folder:
-
-```
-git submodule init
-git submodule update
-```
-
-Then, in your config screen, select your favorite theme. 
-
-That's all ! 
-
-## create a theme
-
-Just have a look to this short documentation : http://doc.inthepoche.com/doku.php?id=designers:creating_theme
-
-## send a theme
-
-Send your theme by email at support@inthepoche.com.
diff --git a/themes/courgette/README.md b/themes/courgette/README.md
new file mode 100755 (executable)
index 0000000..e13d390
--- /dev/null
@@ -0,0 +1,3 @@
+# Courgette Theme
+
+theme created by Thomas LEBEAU alias Courgette http://thomaslebeau.fr/
\ No newline at end of file
diff --git a/themes/courgette/_head.twig b/themes/courgette/_head.twig
new file mode 100755 (executable)
index 0000000..57b40f4
--- /dev/null
@@ -0,0 +1,11 @@
+        <link rel="shortcut icon" type="image/x-icon" href="{{ poche_url }}/themes/{{theme}}/img/favicon.ico" />
+        <link rel="apple-touch-icon-precomposed" sizes="144x144" href="{{ poche_url }}/themes/{{theme}}/img/apple-touch-icon-144x144-precomposed.png">
+        <link rel="apple-touch-icon-precomposed" sizes="72x72" href="{{ poche_url }}/themes/{{theme}}/img/apple-touch-icon-72x72-precomposed.png">
+        <link rel="apple-touch-icon-precomposed" href="{{ poche_url }}/themes/{{theme}}/img/apple-touch-icon-precomposed.png">
+        <link rel="stylesheet" href="{{ poche_url }}/themes/{{theme}}/css/font.css" media="all">
+        <link rel="stylesheet" href="{{ poche_url }}/themes/{{theme}}/css/style.css" media="all">
+        <link rel="stylesheet" href="{{ poche_url }}/themes/{{theme}}/css/messages.css" media="all">
+        <link rel="stylesheet" href="{{ poche_url }}/themes/{{theme}}/css/print.css" media="print">
+        <link href='//fonts.googleapis.com/css?family=Roboto' rel='stylesheet' type='text/css'>
+        <script src="//codeorigin.jquery.com/jquery-2.0.3.min.js"></script>
+        <script src="{{ poche_url }}/themes/{{theme}}/js/init.js"></script>
diff --git a/themes/courgette/_menu.twig b/themes/courgette/_menu.twig
new file mode 100755 (executable)
index 0000000..85487f7
--- /dev/null
@@ -0,0 +1,9 @@
+            <div id="menuContainer">
+              <ul id="links">
+                  <li><a href="./" {% if view == 'home' %}class="current"{% endif %}>{% trans "home" %}</a></li>
+                  <li><a href="./?view=fav" {% if view == 'fav' %}class="current"{% endif %}>{% trans "favorites" %}</a></li>
+                  <li><a href="./?view=archive" {% if view == 'archive' %}class="current"{% endif %}>{% trans "archive" %}</a></li>
+                  <li><a href="./?view=config" {% if view == 'config' %}class="current"{% endif %}>{% trans "config" %}</a></li>
+                  <li><a href="./?logout" title="{% trans "logout" %}">{% trans "logout" %}</a></li>
+              </ul>
+            </div>
\ No newline at end of file
diff --git a/themes/courgette/_top.twig b/themes/courgette/_top.twig
new file mode 100755 (executable)
index 0000000..792687c
--- /dev/null
@@ -0,0 +1,9 @@
+        <header>
+            <h1>
+                {% if view == 'home' %}{% block logo %}<img src="{{ poche_url }}/themes/{{ constant('DEFAULT_THEME') }}/img/logo.svg" alt="logo poche" />{% endblock %}
+                {% elseif view == 'fav' %}<a href="./" title="{% trans "back to home" %}" >{{ block('logo') }} <span>Favoris</span></a>
+                {% elseif view == 'archive' %}<a href="./" title="{% trans "back to home" %}" >{{ block('logo') }} <span>Archive</span></a>
+                {% else %}<a href="./" title="{% trans "back to home" %}" >{{ block('logo') }}</a>
+                {% endif %}
+            </h1>
+        </header>
\ No newline at end of file
diff --git a/themes/courgette/config.twig b/themes/courgette/config.twig
new file mode 100755 (executable)
index 0000000..26da728
--- /dev/null
@@ -0,0 +1,82 @@
+{% extends "layout.twig" %}
+
+{% block title %}{% trans "config" %}{% endblock %}
+{% block menu %}
+{% include '_menu.twig' %}
+{% endblock %}
+{% block content %}
+        <div id="config">
+            <h2>{% trans "Poching a link" %}</h2>
+            <p>{% trans "You can poche a link by several methods:" %} (<a class="special" href="http://doc.wallabag.org" title="{% trans "read the documentation" %}">?</a>)</p>
+            <ul>
+                <li>firefox: <a href="https://bitbucket.org/jogaulupeau/poche/downloads/poche.xpi" title="download the firefox extension">{% trans "download the extension" %}</a></li>
+                <li>chrome: <a href="https://bitbucket.org/jogaulupeau/poche/downloads/poche.crx" title="download the chrome extension">{% trans "download the extension" %}</a></li>
+                <li>android: <a href="https://bitbucket.org/jogaulupeau/poche/downloads/Poche.apk" title="download the application">{% trans "download the application" %}</a></li>
+                <li>
+                    <form method="get" action="index.php">
+                        <label class="addurl" for="plainurl">{% trans "by filling this field" %}:</label>
+                        <input required placeholder="Ex:mywebsite.com/article" class="addurl" id="plainurl" name="plainurl" type="url" />
+                        <input type="submit" value="{% trans "poche it!" %}" />
+                    </form>
+                </li>
+                <li>{% trans "bookmarklet: drag & drop this link to your bookmarks bar" %} <a id="bookmarklet" ondragend="this.click();" title="i am a bookmarklet, use me !" href="javascript:if(top['bookmarklet-url@wallabag.org']){top['bookmarklet-url@wallabag.org'];}else{(function(){var%20url%20=%20location.href%20||%20url;window.open('{{ poche_url }}?action=add&url='%20+%20btoa(url),'_self');})();void(0);}">{% trans "poche it!" %}</a></li>
+            </ul>
+
+            <h2>{% trans "Updating poche" %}</h2>
+            <ul>
+                <li>{% trans "your version" %} : <strong>{{ constant('POCHE') }}</strong></li>
+                <li>{% trans "latest stable version" %} : {{ prod }}. {% if compare_prod == -1 %}<strong><a href="http://wallabag.org/">{% trans "a more recent stable version is available." %}</a></strong>{% else %}{% trans "you are up to date." %}{% endif %}</li>
+                {% if constant('DEBUG_POCHE') == 1 %}<li>{% trans "latest dev version" %} : {{ dev }}. {% if compare_dev == -1 %}<strong><a href="http://wallabag.org/">{% trans "a more recent development version is available." %}</a></strong>{% else %}{% trans "you are up to date." %}{% endif %}</li>{% endif %}
+            </ul>
+            
+            <h2>{% trans "Change your theme" %}</h2>
+            <form method="post" action="?updatetheme" name="changethemeform">
+                <fieldset class="w500p">
+                    <div class="row">
+                        <label class="col w150p" for="theme">{% trans "Theme:" %}</label>
+                        <select class="col" id="theme" name="theme">
+                            {% for key, theme in themes %}
+                            <option value="{{ key }}" {{ theme.current ? 'selected' : '' }}>{{ theme.name }}</option>
+                            {% endfor %}
+                        </select>
+                    </div>
+                    <div class="row mts txtcenter">
+                        <button class="bouton" type="submit" tabindex="4">{% trans "Update" %}</button>
+                    </div>
+                </fieldset>
+                <input type="hidden" name="returnurl" value="{{ referer }}">
+                <input type="hidden" name="token" value="{{ token }}">
+            </form>
+
+            <h2>{% trans "Change your password" %}</h2>
+            <form method="post" action="?config" name="loginform">
+                <fieldset class="w500p">
+                    <div class="row">
+                        <label class="col w150p" for="password">{% trans "New password:" %}</label>
+                        <input class="col" type="password" id="password" name="password" placeholder="{% trans "Password" %}" tabindex="2">
+                    </div>
+                    <div class="row">
+                        <label class="col w150p" for="password_repeat">{% trans "Repeat your new password:" %}</label>
+                        <input class="col" type="password" id="password_repeat" name="password_repeat" placeholder="{% trans "Password" %}" tabindex="3">
+                    </div>
+                    <div class="row mts txtcenter">
+                        <button class="bouton" type="submit" tabindex="4">{% trans "Update" %}</button>
+                    </div>
+                </fieldset>
+                <input type="hidden" name="returnurl" value="{{ referer }}">
+                <input type="hidden" name="token" value="{{ token }}">
+            </form>
+
+            <h2>{% trans "Import" %}</h2>
+            <p>{% trans "Please execute the import script locally, it can take a very long time." %}</p>
+            <p>{% trans "More infos in the official doc:" %} <a href="http://doc.wallabag.org">wallabag.org</a></p>
+            <ul>
+                <li><a href="./?import&amp;from=pocket">{% trans "import from Pocket" %}</a> {{ '(you must have a %s file on your server)'|trans|format(constant('POCKET_FILE')) }}</li>
+            <li><a href="./?import&amp;from=readability">{% trans "import from Readability" %}</a> {{ '(you must have a %s file on your server)'|trans|format(constant('READABILITY_FILE')) }}</li>
+            <li><a href="./?import&amp;from=instapaper">{% trans "import from Instapaper" %}</a> {{ '(you must have a %s file on your server)'|trans|format(constant('INSTAPAPER_FILE')) }}</li>
+            </ul>
+
+            <h2>{% trans "Export your poche datas" %}</h2>
+            <p><a href="./?export" target="_blank">{% trans "Click here" %}</a> {% trans "to export your poche datas." %}</p>
+        </div>
+{% endblock %}
\ No newline at end of file
diff --git a/themes/courgette/css/.DS_Store b/themes/courgette/css/.DS_Store
new file mode 100644 (file)
index 0000000..c788a09
Binary files /dev/null and b/themes/courgette/css/.DS_Store differ
diff --git a/themes/courgette/css/font.css b/themes/courgette/css/font.css
new file mode 100755 (executable)
index 0000000..7c16cce
--- /dev/null
@@ -0,0 +1,10 @@
+@font-face {
+  font-family: 'fontello';
+  src: url('../font/fontello.eot?97381924');
+  src: url('../font/fontello.eot?97381924#iefix') format('embedded-opentype'),
+       url('../font/fontello.woff?97381924') format('woff'),
+       url('../font/fontello.ttf?97381924') format('truetype'),
+       url('../font/fontello.svg?97381924#fontello') format('svg');
+  font-weight: normal;
+  font-style: normal;
+}
\ No newline at end of file
diff --git a/themes/courgette/css/knacss.css b/themes/courgette/css/knacss.css
new file mode 100755 (executable)
index 0000000..e69de29
diff --git a/themes/courgette/css/messages.css b/themes/courgette/css/messages.css
new file mode 100755 (executable)
index 0000000..fe6fbbe
--- /dev/null
@@ -0,0 +1,75 @@
+.messages {
+    display: block;
+    clear: both;
+    width: 400px;
+    margin: 10px auto 10px;
+    padding: 10px 0;
+    -moz-border-radius: 4px;
+    border-radius: 4px;
+}
+
+.messages a.closeMessage {
+    display: none;
+    float: right;
+    width: 16px;
+    height: 16px;
+    margin: -14px -8px 0 0;
+    background: url(../img/messages/close.png) no-repeat;
+}
+
+/*.messages:hover a.closeMessage { visibility:visible; }*/
+
+.messages p {
+    margin: 3px 0 3px 10px !important;
+    padding: 0 10px 0 23px !important;
+    font-size: 14px;
+    line-height: 16px;
+}
+
+.messages.error {
+    border: 1px solid #c42608;
+    color: #c00 !important;
+    background: #fff0ef;
+}
+
+.messages.error p {
+    color: #c00 !important;
+    background: url(../img/messages/cross.png) no-repeat 0 50%;
+}
+
+.messages.success {
+    border: 1px solid #6dc70c;
+    background: #e0fbcc;
+}
+
+.messages.success p {
+    color: #2b6301 !important;
+    background: url(../img/messages/tick.png) no-repeat 0 50%;
+}
+
+.messages.warning {
+    border: 1px solid #ebcd41;
+    color: #000;
+    background: #fffcd3;
+}
+
+.messages.warning p {
+    color: #5f4e01;
+    background: url(../img/messages/warning.png) no-repeat 0 50%;
+}
+
+.messages.information,
+.messages.info {
+    border: 1px solid #82aee7;
+    background: #dfebfb;
+}
+
+.messages.information p,
+.messages.info p {
+    color: #064393;
+    background: url(../img/messages/help.png) no-repeat 0 50%;
+}
+
+.messages.information a {
+    text-decoration: underline;
+}
\ No newline at end of file
diff --git a/themes/courgette/css/print.css b/themes/courgette/css/print.css
new file mode 100755 (executable)
index 0000000..9aefa77
--- /dev/null
@@ -0,0 +1,48 @@
+/* ### Layout ### */
+
+body {
+    font-family: Serif;
+    background-color: #fff;
+}
+
+@page {
+    margin: 1cm;
+}
+
+img {
+    max-width: 100% !important;
+}
+
+/* ### Content ### */
+
+/* Hide useless blocks */
+body > header,
+#links,
+#sort,
+body > footer,
+.top_link,
+div.tools,
+header div,
+.messages,
+.entrie + .results {
+    display: none !important;
+}
+
+article {
+    border: none !important;
+}
+
+/* Add URL after links */
+.vieworiginal a:after {
+    content: " (" attr(href) ")";
+}
+
+/* Add explanation after abbr */
+abbr[title]:after {
+    content: " (" attr(title) ")";
+}
+
+/* Change border on current pager item */
+.pagination span.current {
+    border-style: dashed;
+}
diff --git a/themes/courgette/css/style-default.css b/themes/courgette/css/style-default.css
new file mode 100755 (executable)
index 0000000..3377a75
--- /dev/null
@@ -0,0 +1,59 @@
+a.back span {
+    background-image: url('../img/default/left.png');
+}
+
+a.top span {
+    background-image: url('../img/default/top.png');
+}
+
+a.fav span,
+a.fav-off span:hover {
+    background-image: url('../img/default/star-on.png');
+}
+
+a.fav span:hover,
+a.fav-off span {
+    background-image: url('../img/default/star-off.png');
+}
+
+a.archive span,
+a.archive-off span:hover {
+    background-image: url('../img/default/checkmark-on.png');
+}
+
+a.archive span:hover,
+a.archive-off span {
+    background-image: url('../img/default/checkmark-off.png');
+}
+
+a.twitter span {
+    background-image: url('../img/default/twitter.png');
+}
+
+a.shaarli span {
+    background-image: url('../img/default/shaarli.png');
+}
+
+a.flattr span {
+    background-image: url('../img/default/flattr.png');
+}
+
+a.email span {
+    background-image: url('../img/default/envelop.png');
+}
+
+a.delete span {
+    background-image: url('../img/default/remove.png');
+}
+
+a.link span {
+    background-image: url('../img/default/link.png');
+}
+
+a.bad-display span {
+    background-image: url('../img/default/bad-display.png');
+}
+
+a.reading-time span {
+    background-image: url('../img/default/clock.png');
+}
diff --git a/themes/courgette/css/style.css b/themes/courgette/css/style.css
new file mode 100755 (executable)
index 0000000..2ba16b7
--- /dev/null
@@ -0,0 +1,620 @@
+* {
+  -webkit-box-sizing: border-box;
+  -moz-box-sizing: border-box;
+  box-sizing: border-box;
+}
+
+body {
+  margin: 10px;
+  font-family: 'Roboto',Verdana,Geneva,sans-serif;
+  font-size: 16px;
+  color: #000;
+}
+
+h1 span {
+  color #FFF;
+  background: #000;
+  display: inline-block;
+  padding: 0.2em 1em 0.2em 1.2em;
+  font-size: 0.7em;
+  position: relative;
+  top: -1em;
+  left: -1em;
+}
+
+h1 a {
+  color: #FFF;
+  text-decoration: none;
+}
+
+#menu {
+  font-family: 'fontello';
+  position:fixed;
+  z-index: 11;
+  top: 0.7em;
+  right: 0.5em;
+  border:0;
+  font-size: 2em;
+  background: #000;
+  color:#FFF;
+  height: 58px;
+  width: 58px;
+  line-height:58px;
+  border-radius:120px;
+}
+
+#menu:hover, #menu:focus {
+  background: #FFF;
+  color:#000;
+  cursor: pointer;
+}
+
+#menu span {
+  position: absolute;
+  top: -99999px;
+}
+
+#menuContainer ul, #article_toolbar ul {
+  position:fixed;
+  top: 0;
+  left:0;
+  width: 100%;
+  padding: 0;
+  margin: 0;
+  text-align:center;
+  height:80px;
+}
+
+/*Inspired by http://tympanus.net/Tutorials/AnimatedBorderMenus/index.html */
+
+#menuContainer, #article_toolbar {
+  position: fixed;
+  top: 0;
+  left:0;
+  width: 100%;
+  height: 0;
+  overflow: hidden;
+  border-width:0;
+  border-style: solid;
+  border-color:#000;
+  background-color: transparent;
+  -webkit-transition: border-width 0.3s, background-color 0.3s, height 0s 0.3s;
+  -moz-transition: border-width 0.3s, background-color 0.3s, height 0s 0.3s;
+  transition: border-width 0.3s, background-color 0.3s, height 0s 0.3s;
+}
+
+#article_toolbar ul {
+  padding: 1.7em;
+}
+
+#menuContainer.open, #article_toolbar.open {
+  border-width:80px;
+  height: 100%;
+  background: rgba(0,0,0,0.5);
+  -webkit-transition: border-width 0.3s, background-color 0.3s;
+  -moz-transition: border-width 0.3s, background-color 0.3s;
+  transition: border-width 0.3s, background-color 0.3s;
+  z-index: 1;
+}
+
+#links li, #article_toolbar li {
+  list-style: none;
+  display: inline-block;
+}
+
+#links li a, #article_toolbar a {
+  color:#FFF;
+  display: block;
+  position:relative;
+  top: -200px;
+  -webkit-transition: top 0.3s ease;
+  -moz-transition: top 0.3s ease;
+  transition: top 0.3s ease;
+  padding:1.85em 1em;
+}
+
+#links li a {
+  text-decoration:none;
+  text-transform:uppercase;
+}
+
+#links li a:hover, #links li a:focus {
+  background: #FFF;
+  color:#000;
+}
+
+#menuContainer.open li a, #article_toolbar.open a {
+  top: 0;
+  -webkit-transition: top 0.3s ease;
+  -moz-transition: top 0.3s ease;
+  transition: top 0.3s ease;
+  -webkit-transition-delay:0.25ms;
+  -moz-transition-delay:0.25ms;
+  transition-delay:0.25ms;
+}
+
+#menuContainer.open li:nth-child(2) a {
+  -webkit-transition-delay:0.50ms;
+  -moz-transition-delay:0.50ms;
+  transition-delay:0.50ms;
+}
+
+#menuContainer.open li:nth-child(3) a {
+  -webkit-transition-delay:1ms;
+  -moz-transition-delay:1ms;
+  transition-delay:1ms;
+}
+
+#menuContainer.open li:nth-child(4) a {
+  -webkit-transition-delay:1.25ms;
+  -moz-transition-delay:1.25ms;
+  transition-delay:1.25ms;
+}
+
+#menuContainer.open li:nth-child(5) a {
+  -webkit-transition-delay:1.55ms;
+  -moz-transition-delay:1.55ms;
+  transition-delay:1.55ms;
+}
+
+#menu:before {
+  content: "\e801";
+  display: block;
+  text-indent: 0;
+}
+
+body > header {
+  position: fixed;
+  top: 0;
+  left: 1em;
+  z-index: 10;
+}
+
+#main {
+  padding:6em;
+}
+
+/* ==========================================================================
+   entrie
+   ========================================================================== */
+
+.entrie, #article {
+  width: 45em;
+  margin: auto;
+  position:relative;
+  padding: 0 0 1em 0;
+  margin-bottom: 1.5em;
+}
+
+#article a {
+  text-decoration: underline;
+  color:#000;
+}
+
+#article a:hover, #article a:focus {
+  text-decoration: none;
+}
+
+.entrie:after {
+  content:"";
+  position: absolute;
+  width: 100%;
+  height: 4px;
+  background: #000;
+  bottom:0;
+  left: -1em;
+}
+
+.entrie p {
+  padding:0 0 0 1.5em;
+}
+
+.entrie:before {
+  content:'';
+  position: absolute;
+  top: 0;
+  left: -1em;
+  width: 4px;
+  height: 100%;
+  background: #000;
+}
+
+.entrie h2:after {
+  content:"";
+  display: block;
+  width: 0;
+  height: 0;
+  border-color: #000;
+  border-width:7px;
+  border-color:transparent transparent transparent #000;
+  border-style: solid;
+  position: absolute;
+  top: 0.8em;
+  right: -0.58em;
+}
+
+.entrie h2 {
+  margin:0;
+  display: inline-block;
+  position: relative;
+  max-width: 78%;
+}
+
+.entrie h2 a {
+  color:#000;
+  text-decoration:none;
+  display: block;
+  background: #000;
+  padding: 0.4em 1em;
+  color:#FFF;
+  margin-left: -0.5em;
+  -webkit-transition: all 0.3s ease-out;
+  -moz-transition: all 0.3s ease-out;
+  transition: all 0.3s ease-out;
+}
+
+.entrie h2 a:hover, .entrie h2 a:focus {
+  padding:0.4em 1em 0.4em 2em;
+}
+
+ul {
+  padding:0;
+  margin:0;
+}
+
+ul li {
+  list-style: none;
+}
+
+.tools {
+  display: inline-block;
+  margin-left: 1em;
+  vertical-align: top;
+  padding-top: 1em;
+}
+
+.tools a span {
+  position:absolute;
+  top: -99999px;
+}
+
+.tools li {
+  display: inline-block;
+}
+
+.tools a {
+  display: block;
+  color:#FFF;
+  background: #000;
+  text-decoration:none;
+  height: 1.5em;
+  width: 1.5em;
+  text-align: center;
+  line-height:1.5em;
+  border-radius: 90px;
+}
+
+.tools a:hover, .tools a:focus {
+  background: #FFF;
+  color:#000;
+}
+
+.tools a:before { display: block; font-family: 'fontello'; }
+
+
+.fav-off:before, .fav:before { content: '\e805'; } /* '' */
+.archive-off:before, .archive:before { content: '\e804'; } /* '' */
+.tools .archive, .tools .fav {
+  background: #FFF;
+  color:#000;
+}
+.link:before { content: '\e800'; } /* '' */
+.delete:before { content: '\e803'; } /* '' */
+.reading-time:before { content: '\e802'; } /* '' */
+
+#article_toolbar a:before {
+  display: block;
+  font-family: 'fontello'; 
+}
+
+#article_toolbar a {
+  display: block;
+  color:#000;
+  background: #FFF;
+  text-decoration:none;
+  height: 1.5em;
+  width: 1.5em;
+  text-align: center;
+  line-height:1.5em;
+  border-radius: 90px;
+  padding: 0;
+}
+
+#article_toolbar a:hover, #article_toolbar a:focus {
+  background: #000;
+  color:#FFF;
+}
+
+#article_toolbar span {
+  position: absolute;
+  top: -99999px;
+}
+
+.email:before { content: '\e80a'; } /* '' */
+.icon-check:before { content: '\e804'; } /* '' */
+.back:before { content: '\e806'; } /* '' */
+.bad-display:before { content: '\e808'; } /* '' */
+.twitter:before { content: '\e807'; } /* '' */
+
+#article_toolbar .flattrli {
+  display: none;
+}
+
+#article_toolbar li {
+  margin: 0 0 0 1em;
+}
+
+
+footer {
+  position: fixed;
+  bottom: 0;
+  width: 100%;
+  padding: 0 2%;
+  left: 0;
+  text-align:right;
+  font-size: 0.8em;
+  font-style: italic;
+  background: rgba(255,255,255,0.5);
+}
+
+footer a {
+  color:#000;
+}
+
+footer a:hover,footer a:focus {
+  text-decoration: none;
+}
+
+footer p:first-child {
+  float:left;
+}
+
+#loginForm fieldset {
+  border:5px solid #000;
+  padding: 1.5em;
+}
+
+fieldset {
+  border:0;
+  padding: 0;
+}
+
+#loginForm {
+  max-width: 25em;
+  margin: auto;
+}
+
+#loginForm .row {
+  margin-bottom: 0.5em;
+}
+
+form h2 {
+  margin-top: 0;
+}
+
+form label {
+  width: 40%;
+  display: inline-block;
+}
+
+form input[type="text"], form input[type="password"], form input[type='url'], form select {
+  border:1px solid #000;
+  padding:0.5em 1em;
+}
+
+@media screen and (-webkit-min-device-pixel-ratio:0){
+  form select{
+    -webkit-appearance: none;
+    background: url(../img/bg-select.png) no-repeat right center;
+    padding-right: 2.2em;
+    border-radius: 0;
+  }
+}
+
+form button, form input[type="submit"] {
+  background: #000;
+  color:#FFF;
+  border:0;
+  font-size:1em;
+  padding:0.5em 1em;
+  margin-top: 1em;
+  cursor: pointer;
+}
+
+form button:hover, form button:focus, form input[type="submit"]:hover, form input[type="submit"]:focus {
+  background: #FFF;
+  color: #000;
+}
+
+/* ==========================================================================
+   Config
+   ========================================================================== */
+
+#config {
+  max-width: 60%;
+  margin: auto;
+}
+
+#config a {
+  background: #000;
+  text-decoration: none;
+  color:#FFF;
+  padding: 0.2em 1em;
+}
+
+#config .special {
+  background: none;
+  padding:0;
+  color: #000;
+}
+
+#config a:hover, #config a:focus {
+  background: #FFF;
+  color:#000;
+}
+
+#config li {
+  margin-bottom: 1em;
+}
+
+#plainurl {
+  font-size: 1em;
+}
+
+#config label {
+  width: 20%;
+}
+
+.results {
+  max-width: 62.5%;
+  font-style:italic;
+  margin: 1em auto 2.5em;
+}
+
+#sort {
+  max-width: 62.5%;
+  margin: 0 auto -2.5em;
+  text-align: right;
+  border-bottom:1px dotted #000;
+}
+
+#sort li {
+  display: inline-block;
+  vertical-align: top;
+  position: relative;
+  top: -0.1em;
+  margin-left: 1em;
+}
+
+#sort li img {
+  display: none;
+}
+
+#sort a {
+  display: inline-block;
+  font-family: 'fontello'; 
+  color:#000;
+  text-decoration: none;
+}
+
+#sort a:hover, #sort a:focus {
+  text-decoration: underline;
+}
+
+#sort a:before {
+  display: block;
+}
+
+#sort li a:first-child:before {
+  content: '\e809';
+}
+
+#sort li a:first-child + a:before {
+  content: '\e80b';
+}
+
+@media screen and (max-width: 860px) {
+  .entrie, #article {
+    width: 30em;
+  }
+}
+
+@media screen and (max-width: 650px) {
+  #menuContainer ul, #article_toolbar ul {
+    width: 120px;
+    height: 100%;
+  }
+
+  body > header {
+    position: static;
+  }
+
+  #main {
+    padding: 0 0.5em 6em;
+  }
+
+  #menu {
+    display: none;
+  }
+
+  #main:before {
+    content:none;
+  }
+
+  #menuContainer, #article_toolbar, #menuContainer ul, #article_toolbar ul {
+    position: static;
+    width: 100%;
+    height: auto;
+  }
+
+  #links li a, #article_toolbar a {
+    position: static;
+    color: #000;
+  }
+
+  #links li a {
+    padding: 1em;
+    min-width: 120px;
+    text-align: left;
+  }
+
+  #article_toolbar li {
+    margin-bottom: 1em;
+    margin-left: 0.5em;
+  }
+
+}
+
+@media screen and (max-width: 500px) {
+  .entrie, #article {
+    width: 17em;
+  } 
+  .entrie h2 {
+    width: 100%;
+    max-width: none;
+  }
+  .entrie h2 a:hover, .entrie h2 a:focus {
+    padding-left: 1em;
+    background: #FFF;
+    color: #000;
+  }
+  .entrie h2:after {
+    content:none;
+  }
+
+  .messages {
+    width: 100%!important;
+  }
+
+  #sort {
+    margin: 3em auto 0;
+    max-width: none;
+    text-align: center;
+  }
+  #config {
+    margin: 7em auto 0;
+    max-width: none;
+  }
+  #config label { width: 100%; }
+  .results {
+    max-width: none;
+    margin-bottom: 1em;
+  }
+
+  footer p:first-child {
+    float: none;
+  }
+  footer {
+    position:static;
+  }
+}
diff --git a/themes/courgette/error.twig b/themes/courgette/error.twig
new file mode 100755 (executable)
index 0000000..4d4db1f
--- /dev/null
@@ -0,0 +1,6 @@
+{% extends "layout.twig" %}
+{% block title %}{% trans "plop" %}{% endblock %}
+{% block content %}
+        {{ msg|raw }}
+        <p>Don't forget <a href="http://doc.wallabag.org">the documentation</a>.</p>
+{% endblock %}
\ No newline at end of file
diff --git a/themes/courgette/font/fontello.eot b/themes/courgette/font/fontello.eot
new file mode 100644 (file)
index 0000000..3c5603d
Binary files /dev/null and b/themes/courgette/font/fontello.eot differ
diff --git a/themes/courgette/font/fontello.svg b/themes/courgette/font/fontello.svg
new file mode 100644 (file)
index 0000000..0e0118e
--- /dev/null
@@ -0,0 +1,23 @@
+<?xml version="1.0" standalone="no"?>
+<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
+<svg xmlns="http://www.w3.org/2000/svg">
+<metadata>Copyright (C) 2013 by original authors @ fontello.com</metadata>
+<defs>
+<font id="fontello" horiz-adv-x="1000" >
+<font-face font-family="fontello" font-weight="400" font-stretch="normal" units-per-em="1000" ascent="850" descent="-150" />
+<missing-glyph horiz-adv-x="1000" />
+<glyph glyph-name="mail" unicode="&#xe80a;" d="m929 11v428q-18-20-39-37q-149-114-238-188q-28-24-46-38t-48-27t-57-13h-2q-26 0-57 13t-48 27t-46 38q-88 74-238 188q-21 17-39 37v-428q0-8 6-13t12-5h822q7 0 12 5t6 13z m0 586v14t-1 7t-1 7t-3 5t-5 4t-8 2h-822q-7 0-12-6t-6-12q0-94 82-159q108-85 224-177q4-2 20-16t25-21t25-18t28-15t24-5h2q11 0 24 5t28 15t25 18t25 21t20 16q116 92 224 177q30 24 56 65t26 73z m71 21v-607q0-37-26-63t-63-27h-822q-36 0-63 27t-26 63v607q0 37 26 63t63 26h822q37 0 63-26t26-63z" horiz-adv-x="1000" />
+<glyph glyph-name="up-open" unicode="&#xe80b;" d="m0 174l352 352l148 148l148-148l352-352l-148-148l-352 351l-352-351z" horiz-adv-x="1000" />
+<glyph glyph-name="star" unicode="&#xe805;" d="m440 790l120-336l320 0l-262-196l94-348l-272 208l-272-208l94 348l-262 196l320 0z" horiz-adv-x="880" />
+<glyph glyph-name="check" unicode="&#xe804;" d="m249 0q-34 0-56 28l-180 236q-16 24-12 52t26 46t51 14t47-28l118-154l296 474q16 24 43 30t53-8q24-16 30-43t-8-53l-350-560q-20-32-56-32z" horiz-adv-x="667" />
+<glyph glyph-name="link" unicode="&#xe800;" d="m294 116q14 14 34 14t36-14q32-34 0-70l-42-40q-56-56-132-56q-78 0-134 56t-56 132q0 78 56 134l148 148q70 68 144 77t128-43q16-16 16-36t-16-36q-36-32-70 0q-50 48-132-34l-148-146q-26-26-26-64t26-62q26-26 63-26t63 26z m450 574q56-56 56-132q0-78-56-134l-158-158q-74-72-150-72q-62 0-112 50q-14 14-14 34t14 36q14 14 35 14t35-14q50-48 122 24l158 156q28 28 28 64q0 38-28 62q-24 26-56 31t-60-21l-50-50q-16-14-36-14t-34 14q-34 34 0 70l50 50q54 54 127 51t129-61z" horiz-adv-x="800" />
+<glyph glyph-name="reply" unicode="&#xe806;" d="m900 10q-86 152-208 197t-330 45l0-218l-362 334l362 322l0-192q90 0 168-27t131-70t96-95t69-104t44-95t24-69z" horiz-adv-x="900" />
+<glyph glyph-name="menu" unicode="&#xe801;" d="m857 100v-71q0-15-10-25t-26-11h-785q-15 0-25 11t-11 25v71q0 15 11 25t25 11h785q15 0 26-11t10-25z m0 286v-72q0-14-10-25t-26-10h-785q-15 0-25 10t-11 25v72q0 14 11 25t25 10h785q15 0 26-10t10-25z m0 285v-71q0-15-10-25t-26-11h-785q-15 0-25 11t-11 25v71q0 15 11 26t25 10h785q15 0 26-10t10-26z" horiz-adv-x="857.1" />
+<glyph glyph-name="clock" unicode="&#xe802;" d="m460 810q190 0 325-135t135-325t-135-325t-325-135t-325 135t-135 325t135 325t325 135z m0-820q150 0 255 106t105 254q0 150-105 255t-255 105q-148 0-254-105t-106-255q0-148 106-254t254-106z m36 620l0-244l150-150l-50-50l-170 170l0 274l70 0z" horiz-adv-x="920" />
+<glyph glyph-name="block" unicode="&#xe808;" d="m480 830q200 0 340-140t140-340q0-198-140-339t-340-141q-198 0-339 141t-141 339q0 200 141 340t339 140z m258-220z m-622-260q0-132 82-230l514 514q-100 82-232 82q-152 0-258-107t-106-259z m106-258z m258-106q152 0 259 107t107 257q0 130-82 232l-514-514q98-82 230-82z" horiz-adv-x="960" />
+<glyph glyph-name="twitter" unicode="&#xe807;" d="m920 636q-36-54-94-98l0-24q0-130-60-250t-186-203t-290-83q-160 0-290 84q14-2 46-2q132 0 234 80q-62 2-110 38t-66 94q10-4 34-4q26 0 50 6q-66 14-108 66t-42 120l0 2q36-20 84-24q-84 58-84 158q0 48 26 94q154-188 390-196q-6 18-6 42q0 78 55 133t135 55q82 0 136-58q60 12 120 44q-20-66-82-104q56 8 108 30z" horiz-adv-x="920" />
+<glyph glyph-name="down-open" unicode="&#xe809;" d="m0 526l148 148l352-351l352 351l148-148l-352-352l-148-148l-148 148z" horiz-adv-x="1000" />
+<glyph glyph-name="trash" unicode="&#xe803;" d="m50 458q122-70 330-70t330 70l-54-486q-2-14-35-36t-100-43t-141-21t-140 21t-100 43t-36 36z m488 300q94-18 158-55t64-71l0-10q0-58-112-99t-268-41t-268 41t-112 99l0 10q0 34 64 71t158 55l42 48q22 26 70 26l92 0q52 0 70-26z m-54-112l84 0q-92 110-104 126q-14 16-32 16l-102 0q-22 0-32-16l-106-126l84 0l64 66l82 0z" horiz-adv-x="760" />
+</font>
+</defs>
+</svg>
\ No newline at end of file
diff --git a/themes/courgette/font/fontello.ttf b/themes/courgette/font/fontello.ttf
new file mode 100644 (file)
index 0000000..1967dfa
Binary files /dev/null and b/themes/courgette/font/fontello.ttf differ
diff --git a/themes/courgette/font/fontello.woff b/themes/courgette/font/fontello.woff
new file mode 100644 (file)
index 0000000..c62afa5
Binary files /dev/null and b/themes/courgette/font/fontello.woff differ
diff --git a/themes/courgette/home.twig b/themes/courgette/home.twig
new file mode 100755 (executable)
index 0000000..1367ebe
--- /dev/null
@@ -0,0 +1,49 @@
+{% extends "layout.twig" %}
+{% block title %}
+{% if view == 'fav' %}
+{% trans "favoris" %}
+{% elseif view == 'archive' %}
+{% trans "archive" %}
+{% else %}
+{% trans "unread" %}
+{% endif %}
+{% endblock %}
+{% block menu %}
+{% include '_menu.twig' %}
+{% endblock %}
+{% block precontent %}
+            {% if entries|length > 1 %}
+            <ul id="sort">
+                <li><a href="./?sort=ia&amp;view={{ view }}"><img src="{{ poche_url }}/themes/{{ theme }}/img/{{ theme }}/top.png" alt="{% trans "by date asc" %}" title="{% trans "by date asc" %}" /></a> {% trans "by date" %} <a href="./?sort=id&amp;view={{ view }}"><img src="{{ poche_url }}/themes/{{ theme }}/img/{{ theme }}/down.png" alt="{% trans "by date desc" %}" title="{% trans "by date desc" %}" /></a></li>
+                <li><a href="./?sort=ta&amp;view={{ view }}"><img src="{{ poche_url }}/themes/{{ theme }}/img/{{ theme }}/top.png" alt="{% trans "by title asc" %}" title="{% trans "by title asc" %}" /></a> {% trans "by title" %} <a href="./?sort=td&amp;view={{ view }}"><img src="{{ poche_url }}/themes/{{ theme }}/img/{{ theme }}/down.png" alt="{% trans "by title desc" %}" title="{% trans "by title desc" %}" /></a></li>
+            </ul>
+            {% endif %}
+{% endblock %}
+{% block content %}
+            {% if entries is empty %}
+            <div class="messages warning"><p>{% trans "No link available here!" %}</p></div>
+            {% else %}
+                {% block pager %}
+                    {% if nb_results > 1 %}
+                <div class="results">
+                    <div class="nb-results">{{ nb_results }} {% trans "results" %}</div>
+                        {{ page_links | raw }}
+                </div>
+                    {% endif %}
+                {% endblock %}
+                {% for entry in entries %}
+            <div id="entry-{{ entry.id|e }}" class="entrie">
+                <h2><a href="index.php?view=view&amp;id={{ entry.id|e }}">{{ entry.title|raw }}</a></h2>
+                <ul class="tools">
+                    <li><a title="{% trans "toggle mark as read" %}" class="tool {% if entry.is_read == 0 %}archive-off{% else %}archive{% endif %}" href="./?action=toggle_archive&amp;id={{ entry.id|e }}"><span>{% trans "toggle mark as read" %}</span></a></li>
+                    <li><a title="{% trans "toggle favorite" %}" class="tool {% if entry.is_fav == 0 %}fav-off{% else %}fav{% endif %}" href="./?action=toggle_fav&amp;id={{ entry.id|e }}"><span>{% trans "toggle favorite" %}</span></a></li>
+                    <li><a title="{% trans "delete" %}" class="tool delete" href="./?action=delete&amp;id={{ entry.id|e }}"><span>{% trans "delete" %}</span></a></li>
+                    <li><a href="{{ entry.url|e }}" target="_blank" title="{% trans "original" %} : {{ entry.title|e }}" class="tool link"><span>{{ entry.url | e | getDomain }}</span></a></li>
+                    <li><a target="_blank" title="{% trans "estimated reading time:" %} {{ entry.content| getReadingTime }} min" class="tool reading-time"><span>{{ entry.content| getReadingTime }} min</span></a></li>
+                </ul>
+                <p>{{ entry.content|striptags|slice(0, 300) }}...</p>
+            </div>
+                {% endfor %}
+            {% endif %}
+            {{ block('pager') }}
+{% endblock %}
\ No newline at end of file
diff --git a/themes/courgette/img/apple-touch-icon-144x144-precomposed.png b/themes/courgette/img/apple-touch-icon-144x144-precomposed.png
new file mode 100755 (executable)
index 0000000..557b479
Binary files /dev/null and b/themes/courgette/img/apple-touch-icon-144x144-precomposed.png differ
diff --git a/themes/courgette/img/apple-touch-icon-72x72-precomposed.png b/themes/courgette/img/apple-touch-icon-72x72-precomposed.png
new file mode 100755 (executable)
index 0000000..e167d3a
Binary files /dev/null and b/themes/courgette/img/apple-touch-icon-72x72-precomposed.png differ
diff --git a/themes/courgette/img/apple-touch-icon.png b/themes/courgette/img/apple-touch-icon.png
new file mode 100755 (executable)
index 0000000..4d222fb
Binary files /dev/null and b/themes/courgette/img/apple-touch-icon.png differ
diff --git a/themes/courgette/img/bg-select.png b/themes/courgette/img/bg-select.png
new file mode 100644 (file)
index 0000000..3a77d0e
Binary files /dev/null and b/themes/courgette/img/bg-select.png differ
diff --git a/themes/courgette/img/default/backtotop.png b/themes/courgette/img/default/backtotop.png
new file mode 100755 (executable)
index 0000000..051238e
Binary files /dev/null and b/themes/courgette/img/default/backtotop.png differ
diff --git a/themes/courgette/img/default/bad-display.png b/themes/courgette/img/default/bad-display.png
new file mode 100755 (executable)
index 0000000..6866799
Binary files /dev/null and b/themes/courgette/img/default/bad-display.png differ
diff --git a/themes/courgette/img/default/checkmark-off.png b/themes/courgette/img/default/checkmark-off.png
new file mode 100755 (executable)
index 0000000..3db5a06
Binary files /dev/null and b/themes/courgette/img/default/checkmark-off.png differ
diff --git a/themes/courgette/img/default/checkmark-on.png b/themes/courgette/img/default/checkmark-on.png
new file mode 100755 (executable)
index 0000000..cd3abb2
Binary files /dev/null and b/themes/courgette/img/default/checkmark-on.png differ
diff --git a/themes/courgette/img/default/clock.png b/themes/courgette/img/default/clock.png
new file mode 100755 (executable)
index 0000000..6164e92
Binary files /dev/null and b/themes/courgette/img/default/clock.png differ
diff --git a/themes/courgette/img/default/down.png b/themes/courgette/img/default/down.png
new file mode 100755 (executable)
index 0000000..b9d536a
Binary files /dev/null and b/themes/courgette/img/default/down.png differ
diff --git a/themes/courgette/img/default/envelop.png b/themes/courgette/img/default/envelop.png
new file mode 100755 (executable)
index 0000000..6be1c88
Binary files /dev/null and b/themes/courgette/img/default/envelop.png differ
diff --git a/themes/courgette/img/default/flattr.png b/themes/courgette/img/default/flattr.png
new file mode 100755 (executable)
index 0000000..0404aae
Binary files /dev/null and b/themes/courgette/img/default/flattr.png differ
diff --git a/themes/courgette/img/default/left.png b/themes/courgette/img/default/left.png
new file mode 100755 (executable)
index 0000000..a0a5363
Binary files /dev/null and b/themes/courgette/img/default/left.png differ
diff --git a/themes/courgette/img/default/link.png b/themes/courgette/img/default/link.png
new file mode 100755 (executable)
index 0000000..db62819
Binary files /dev/null and b/themes/courgette/img/default/link.png differ
diff --git a/themes/courgette/img/default/remove.png b/themes/courgette/img/default/remove.png
new file mode 100755 (executable)
index 0000000..f8ad56a
Binary files /dev/null and b/themes/courgette/img/default/remove.png differ
diff --git a/themes/courgette/img/default/shaarli.png b/themes/courgette/img/default/shaarli.png
new file mode 100755 (executable)
index 0000000..1eb30f6
Binary files /dev/null and b/themes/courgette/img/default/shaarli.png differ
diff --git a/themes/courgette/img/default/star-off.png b/themes/courgette/img/default/star-off.png
new file mode 100755 (executable)
index 0000000..6a0133a
Binary files /dev/null and b/themes/courgette/img/default/star-off.png differ
diff --git a/themes/courgette/img/default/star-on.png b/themes/courgette/img/default/star-on.png
new file mode 100755 (executable)
index 0000000..a9f96ea
Binary files /dev/null and b/themes/courgette/img/default/star-on.png differ
diff --git a/themes/courgette/img/default/top.png b/themes/courgette/img/default/top.png
new file mode 100755 (executable)
index 0000000..954a8c0
Binary files /dev/null and b/themes/courgette/img/default/top.png differ
diff --git a/themes/courgette/img/default/twitter.png b/themes/courgette/img/default/twitter.png
new file mode 100755 (executable)
index 0000000..cfcfe41
Binary files /dev/null and b/themes/courgette/img/default/twitter.png differ
diff --git a/themes/courgette/img/favicon.ico b/themes/courgette/img/favicon.ico
new file mode 100755 (executable)
index 0000000..0e9ff77
Binary files /dev/null and b/themes/courgette/img/favicon.ico differ
diff --git a/themes/courgette/img/logo.png b/themes/courgette/img/logo.png
new file mode 100755 (executable)
index 0000000..5305c77
Binary files /dev/null and b/themes/courgette/img/logo.png differ
diff --git a/themes/courgette/img/logo.svg b/themes/courgette/img/logo.svg
new file mode 100644 (file)
index 0000000..865da44
--- /dev/null
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" version="1.1" width="64" height="64">
+    <circle cx="32" cy="32" r="29.5" style="fill:#000" />
+    <path d="m 16,18 33,0 0,26 -16.5,6 -16.5,-6 z" fill="#fff" />
+    <rect width="9" height="2.5" x="17.5" y="24.5" fill="#000" />
+    <rect width="9" height="2.5" x="28" y="24.5" fill="#000" />
+    <rect width="9" height="2.5" x="38.5" y="24.5" fill="#000" />
+</svg>
diff --git a/themes/courgette/img/messages/close.png b/themes/courgette/img/messages/close.png
new file mode 100755 (executable)
index 0000000..731aa01
Binary files /dev/null and b/themes/courgette/img/messages/close.png differ
diff --git a/themes/courgette/img/messages/cross.png b/themes/courgette/img/messages/cross.png
new file mode 100755 (executable)
index 0000000..1514d51
Binary files /dev/null and b/themes/courgette/img/messages/cross.png differ
diff --git a/themes/courgette/img/messages/help.png b/themes/courgette/img/messages/help.png
new file mode 100755 (executable)
index 0000000..5c87017
Binary files /dev/null and b/themes/courgette/img/messages/help.png differ
diff --git a/themes/courgette/img/messages/tick.png b/themes/courgette/img/messages/tick.png
new file mode 100755 (executable)
index 0000000..a9925a0
Binary files /dev/null and b/themes/courgette/img/messages/tick.png differ
diff --git a/themes/courgette/img/messages/warning.png b/themes/courgette/img/messages/warning.png
new file mode 100755 (executable)
index 0000000..628cf2d
Binary files /dev/null and b/themes/courgette/img/messages/warning.png differ
diff --git a/themes/courgette/js/init.js b/themes/courgette/js/init.js
new file mode 100755 (executable)
index 0000000..dca8390
--- /dev/null
@@ -0,0 +1,6 @@
+$.fn.ready(function () {
+  $('#menu').on('click', function(){
+    $('body').toggleClass('menuOpen');
+    $('#menuContainer, #article_toolbar').toggleClass('open');
+  });
+})
\ No newline at end of file
diff --git a/themes/courgette/js/restoreScroll.js b/themes/courgette/js/restoreScroll.js
new file mode 100755 (executable)
index 0000000..331c9e1
--- /dev/null
@@ -0,0 +1,25 @@
+function supportsLocalStorage() {
+    try {
+        return 'localStorage' in window && window['localStorage'] !== null;
+    } catch (e) {
+        return false;
+    }
+}
+
+function savePercent(id, percent) {
+    if (!supportsLocalStorage()) { return false; }
+    localStorage["poche.article." + id + ".percent"] = percent;
+    return true;
+}
+
+function retrievePercent(id) {
+    if (!supportsLocalStorage()) { return false; }
+
+    var bheight = $(document).height();
+    var percent = localStorage["poche.article." + id + ".percent"];
+    var scroll = bheight * percent;
+
+    $('html,body').animate({scrollTop: scroll}, 'fast');
+
+    return true;
+}
\ No newline at end of file
diff --git a/themes/courgette/layout.twig b/themes/courgette/layout.twig
new file mode 100755 (executable)
index 0000000..57c2cc9
--- /dev/null
@@ -0,0 +1,32 @@
+<!DOCTYPE html>
+<!--[if lte IE 6]><html class="no-js ie6 ie67 ie678" lang="{{ lang }}"><![endif]-->
+<!--[if lte IE 7]><html class="no-js ie7 ie67 ie678" lang="{{ lang }}"><![endif]-->
+<!--[if IE 8]><html class="no-js ie8 ie678" lang="{{ lang }}"><![endif]-->
+<!--[if gt IE 8]><html class="no-js" lang="{{ lang }}"><![endif]-->
+<html lang="{{ lang }}">
+    <head>
+        <meta name="viewport" content="initial-scale=1.0">
+        <meta charset="utf-8">
+        <!--[if IE]>
+        <meta http-equiv="X-UA-Compatible" content="IE=10">
+        <![endif]-->
+        <title>{% block title %}{% endblock %} - wallabag</title>
+{% include '_head.twig' %}
+{% include '_bookmarklet.twig' %}
+    </head>
+    <body>
+        {% include '_top.twig' %}
+        <div id="main">
+            <button id="menu"><span>Menu</span></button>
+            {% block menu %}{% endblock %}
+            {% block precontent %}{% endblock %}
+            {% block messages %}
+            {% include '_messages.twig' %}
+            {% endblock %}
+            <div id="content" class="w600p center">
+            {% block content %}{% endblock %}
+            </div>
+        </div>
+{% include '_footer.twig' %}
+    </body>
+</html>
\ No newline at end of file
diff --git a/themes/courgette/login.twig b/themes/courgette/login.twig
new file mode 100755 (executable)
index 0000000..1fec0fc
--- /dev/null
@@ -0,0 +1,32 @@
+{% extends "layout.twig" %}
+
+{% block title %}{% trans "login to your wallabag" %}{% endblock %}
+{% block content %}
+            <form method="post" action="?login" name="loginform" id="loginForm">
+                <fieldset class="w500p center">
+                    <h2 class="mbs txtcenter">{% trans "login to your wallabag" %}</h2>
+                    {% if constant('MODE_DEMO') == 1 %}<p>{% trans "you are in demo mode, some features may be disabled." %}</p>{% endif %}
+                                       <div class="row">
+                                               <label class="col w150p" for="login">{% trans "Login" %}</label>
+                                               <input class="col" type="text" id="login" name="login" placeholder="Login" tabindex="1" autofocus {% if constant('MODE_DEMO') == 1 %}value="poche"{% endif %} />
+                                       </div>
+
+                                       <div class="row">
+                                               <label class="col w150p" for="password">{% trans "Password" %}</label>
+                                               <input class="col" type="password" id="password" name="password" placeholder="Password" tabindex="2" {% if constant('MODE_DEMO') == 1 %}value="poche"{% endif %} />
+                                       </div>
+                                       <div class="row">
+                                               <label class="col w150p" for="longlastingsession">{% trans "Stay signed in" %}</label>
+                                               <div class="col">
+                                                       <input type="checkbox" id="longlastingsession" name="longlastingsession" tabindex="3">
+                                                       <small class="inbl">{% trans "(Do not check on public computers)" %}</small>
+                                               </div>
+                                       </div>
+                                       <div class="row mts txtcenter">
+                                               <button class="bouton" type="submit" tabindex="4">{% trans "Login" %}</button>
+                                       </div>
+                </fieldset>
+                <input type="hidden" name="returnurl" value="{{ referer }}">
+                <input type="hidden" name="token" value="{{ token }}">
+            </form>
+{% endblock %}
\ No newline at end of file
diff --git a/themes/courgette/screenshot.jpg b/themes/courgette/screenshot.jpg
new file mode 100755 (executable)
index 0000000..44ee4b6
Binary files /dev/null and b/themes/courgette/screenshot.jpg differ
diff --git a/themes/courgette/theme.ini b/themes/courgette/theme.ini
new file mode 100644 (file)
index 0000000..996d171
--- /dev/null
@@ -0,0 +1,3 @@
+name = Courgette
+description = Responsive black and white theme especially adapted to smartphones.
+requirements[] = default
diff --git a/themes/courgette/view.twig b/themes/courgette/view.twig
new file mode 100755 (executable)
index 0000000..e80829e
--- /dev/null
@@ -0,0 +1,45 @@
+{% extends "layout.twig" %}
+{% block title %}{{ entry.title|raw }} ({{ entry.url | e | getDomain }}){% endblock %}
+{% block content %}
+        <div id="article_toolbar">
+            <ul>
+                <li><a href="./" title="{% trans "back to home" %}" class="tool back"><span>{% trans "back to home" %}</span></a></li>
+                <li><a href="{{ entry.url|e }}" target="_blank" title="{% trans "original" %} : {{ entry.title|e }}" class="tool link"><span>{{ entry.url | e | getDomain }}</span></a></li>
+                <li><a title="{% trans "toggle mark as read" %}" class="tool {% if entry.is_read == 0 %}archive-off{% else %}archive{% endif %}" href="./?action=toggle_archive&amp;id={{ entry.id|e }}"><span>{% trans "toggle mark as read" %}</span></a></li>
+                <li><a title="{% trans "toggle favorite" %}" class="tool {% if entry.is_fav == 0 %}fav-off{% else %}fav{% endif %}" href="./?action=toggle_fav&amp;id={{ entry.id|e }}"><span>{% trans "toggle favorite" %}</span></a></li>
+                <li><a title="{% trans "delete" %}" class="tool delete" href="./?action=delete&amp;id={{ entry.id|e }}"><span>{% trans "delete" %}</span></a></li>
+                {% if constant('SHARE_TWITTER') == 1 %}<li><a href="https://twitter.com/home?status={{entry.title|url_encode}}%20{{ entry.url|url_encode }}%20via%20@wallabagapp" target="_blank" class="tool twitter" title="{% trans "tweet" %}"><span>{% trans "tweet" %}</span></a></li>{% endif %}
+                {% if constant('SHARE_MAIL') == 1 %}<li><a href="mailto:?subject={{ entry.title|url_encode }}&amp;body={{ entry.url|url_encode }}%20via%20@wallabagapp" class="tool email" title="{% trans "email" %}"><span>{% trans "email" %}</span></a></li>{% endif %}
+                {% if constant('SHARE_SHAARLI') == 1 %}<li><a href="{{ constant('SHAARLI_URL') }}/index.php?post={{ entry.url|url_encode }}&amp;title={{ entry.title|url_encode }}" target="_blank" class="tool shaarli" title="{% trans "shaarli" %}"><span>{% trans "shaarli" %}</span></a></li>{% endif %}
+                {% if constant('FLATTR') == 1 %}{% if flattr.status == constant('FLATTRABLE') %}<li class="flattrli"><a href="http://flattr.com/submit/auto?url={{ entry.url }}" class="tool flattr" target="_blank" title="{% trans "flattr" %}"><span>{% trans "flattr" %}</span></a></li>{% elseif flattr.status == constant('FLATTRED') %}<li><a href="{{ flattr.flattrItemURL }}" class="tool flattr" target="_blank" title="{% trans "flattr" %}"><span>{% trans "flattr" %}</span>{{ flattr.numflattrs }}</a></li>{% endif %}{% endif %}
+                <li><a href="mailto:hello@wallabag.org?subject=Wrong%20display%20in%20wallabag&amp;body={{ entry.url|url_encode }}" title="{% trans "this article appears wrong?" %}" class="tool bad-display"><span>{% trans "this article appears wrong?" %}</span></a></li>
+            </ul>
+        </div>
+        <div id="article">
+            <header class="mbm">
+                <h1>{{ entry.title|raw }}</h1>
+            </header>
+            <article>
+                {{ content | raw }}
+            </article>
+        </div>
+        <script src="{{ poche_url }}/themes/{{ constant('DEFAULT_THEME') }}/js/restoreScroll.js"></script>
+        <script type="text/javascript">
+        $(document).ready(function() {
+
+            $(window).scroll(function(e){
+                var scrollTop = $(window).scrollTop();
+                var docHeight = $(document).height();
+                var scrollPercent = (scrollTop) / (docHeight);
+                var scrollPercentRounded = Math.round(scrollPercent*100)/100;
+                savePercent({{ entry.id|e }}, scrollPercentRounded);
+            });
+
+            retrievePercent({{ entry.id|e }});
+
+            $(window).resize(function(){
+                retrievePercent({{ entry.id|e }});
+            });
+        });
+        </script> 
+{% endblock %}
\ No newline at end of file
diff --git a/themes/dark/theme.ini b/themes/dark/theme.ini
new file mode 100644 (file)
index 0000000..4b020d3
--- /dev/null
@@ -0,0 +1,2 @@
+name = Dark
+requirements[] = default
index 2f3b2d1654beedd9af7d13ec2ac731628ff8c15a..2e3071ad60b0bcbcd0f890ff3d2169c02878c4ef 100644 (file)
@@ -1,3 +1,3 @@
         <script type="text/javascript">
-          top["bookmarklet-url@inthepoche.com"]=""+"<!DOCTYPE html>"+"<html>"+"<head>"+"<title>poche it !</title>"+'<link rel="icon" href="{{poche_url}}tpl/img/favicon.ico" />'+"</head>"+"<body>"+"<script>"+"window.onload=function(){"+"window.setTimeout(function(){"+"history.back();"+"},250);"+"};"+"</scr"+"ipt>"+"</body>"+"</html>"
+          top["bookmarklet-url@wallabag.org"]=""+"<!DOCTYPE html>"+"<html>"+"<head>"+"<title>poche it !</title>"+'<link rel="icon" href="{{poche_url}}tpl/img/favicon.ico" />'+"</head>"+"<body>"+"<script>"+"window.onload=function(){"+"window.setTimeout(function(){"+"history.back();"+"},250);"+"};"+"</scr"+"ipt>"+"</body>"+"</html>"
         </script>
\ No newline at end of file
index 06148a57c5dc6f49f180811cb363502ee41a7b00..f837ae38e5c82887ced9d480ed6ec36c1b49f4ec 100644 (file)
@@ -1,4 +1,4 @@
         <footer class="w600p center mt3 mb3 smaller txtright">
-            <p>{% trans "powered by" %} <a href="http://inthepoche.com">poche</a></p>
+            <p>{% trans "powered by" %} <a href="http://wallabag.org">wallabag</a></p>
             {% if constant('DEBUG_POCHE') == 1 %}<p><strong>{% trans "debug mode is on so cache is off." %} {% trans "your poche version:" %}{{constant('POCHE')}}. {% trans "storage:" %} {{constant('STORAGE')}}</strong></p>{% endif %}
         </footer>
\ No newline at end of file
index 10df726e07f47cc8c38ca617e87e815dee5aaf07..df62520a706ab7d0c2c1601e2be90445427235ac 100644 (file)
@@ -6,10 +6,10 @@
 {% endblock %}
 {% block content %}
             <h2>{% trans "Poching links" %}</h2>
-            <p>{% trans "There are several ways to poche a link:" %} (<a href="http://doc.inthepoche.com/" title="{% trans "read the documentation" %}">?</a>)</p>
+            <p>{% trans "There are several ways to poche a link:" %} (<a href="http://doc.wallabag.org/" title="{% trans "read the documentation" %}">?</a>)</p>
             <ul>
                 <li>Firefox: <a href="https://addons.mozilla.org/firefox/addon/poche/" title="download the firefox extension">{% trans "download the extension" %}</a></li>
-                <li>Chrome: <a href="http://doc.inthepoche.com/doku.php?id=users:chrome_extension" title="download the chrome extension">{% trans "download the extension" %}</a></li>
+                <li>Chrome: <a href="http://doc.wallabag.org/doku.php?id=users:chrome_extension" title="download the chrome extension">{% trans "download the extension" %}</a></li>
                 <li>Android: <a href="https://f-droid.org/repository/browse/?fdid=fr.gaulupeau.apps.Poche" title="download the application">{% trans "via F-Droid" %}</a> {% trans " or " %} <a href="https://play.google.com/store/apps/details?id=fr.gaulupeau.apps.InThePoche" title="download the application">{% trans "via Google Play" %}</a></li>
                 <li>Windows Phone: <a href="https://www.windowsphone.com/en-us/store/app/poche/334de2f0-51b5-4826-8549-a3d805a37e83" title="download the window phone application">{% trans "download the application" %}</a></li>
                 <li>
                         <input type="submit" value="{% trans "poche it!" %}" />
                     </form>
                 </li>
-                <li>{% trans "Bookmarklet: drag & drop this link to your bookmarks bar" %} <a id="bookmarklet" ondragend="this.click();" title="i am a bookmarklet, use me !" href="javascript:if(top['bookmarklet-url@inthepoche.com']){top['bookmarklet-url@inthepoche.com'];}else{(function(){var%20url%20=%20location.href%20||%20url;window.open('{{ poche_url }}?action=add&url='%20+%20btoa(url),'_self');})();void(0);}">{% trans "poche it!" %}</a></li>
+                <li>{% trans "Bookmarklet: drag & drop this link to your bookmarks bar" %} <a id="bookmarklet" ondragend="this.click();" title="i am a bookmarklet, use me !" href="javascript:if(top['bookmarklet-url@wallabag.org']){top['bookmarklet-url@wallabag.org'];}else{(function(){var%20url%20=%20location.href%20||%20url;window.open('{{ poche_url }}?action=add&url='%20+%20btoa(url),'_self');})();void(0);}">{% trans "poche it!" %}</a></li>
             </ul>
 
             <h2>{% trans "Updating poche" %}</h2>
             <ul>
                 <li>{% trans "Installed version" %} : <strong>{{ constant('POCHE') }}</strong></li>
-                <li>{% trans "Latest stable version" %} : {{ prod }}. {% if compare_prod == -1 %}<strong><a href="http://inthepoche.com/">{% trans "A more recent stable version is available." %}</a></strong>{% else %}{% trans "You are up to date." %}{% endif %}</li>
-                {% if constant('DEBUG_POCHE') == 1 %}<li>{% trans "latest dev version" %} : {{ dev }}. {% if compare_dev == -1 %}<strong><a href="http://inthepoche.com/">{% trans "a more recent development version is available." %}</a></strong>{% else %}{% trans "you are up to date." %}{% endif %}</li>{% endif %}
+                <li>{% trans "Latest stable version" %} : {{ prod }}. {% if compare_prod == -1 %}<strong><a href="http://wallabag.org/">{% trans "A more recent stable version is available." %}</a></strong>{% else %}{% trans "You are up to date." %}{% endif %}</li>
+                {% if constant('DEBUG_POCHE') == 1 %}<li>{% trans "latest dev version" %} : {{ dev }}. {% if compare_dev == -1 %}<strong><a href="http://wallabag.org/">{% trans "a more recent development version is available." %}</a></strong>{% else %}{% trans "you are up to date." %}{% endif %}</li>{% endif %}
             </ul>
 
             <h2>{% trans "Feeds" %}</h2>
@@ -38,6 +38,8 @@
                 <li><a href="?feed&amp;type=fav&amp;user_id={{ user_id }}&amp;token={{ token }}" target="_blank">{% trans "Favorites feed" %}</a></li>
                 <li><a href="?feed&amp;type=archive&amp;user_id={{ user_id }}&amp;token={{ token }}" target="_blank">{% trans "Archive feed" %}</a></li>
             </ul>
+            <p>{% trans "Your token:" %} <strong>{{token}}</strong></p>
+            <p>{% trans "Your user id:" %} <strong>{{user_id}}</strong></p>
             <p>{% trans "You can regenerate your token: <a href='?feed&amp;action=generate'>generate!</a>." %}</p>
             {% endif %}
             
@@ -47,8 +49,8 @@
                     <div class="row">
                         <label class="col w150p" for="theme">{% trans "Theme:" %}</label>
                         <select class="col" id="theme" name="theme">
-                            {% for theme in themes %}
-                            <option value="{{ theme.name }}" {{ theme.current ? 'selected' : '' }}>{{ theme.name }}</option>
+                            {% for key, theme in themes %}
+                            <option value="{{ key }}" {{ theme.current ? 'selected' : '' }}>{{ theme.name }}</option>
                             {% endfor %}
                         </select>
                     </div>
 
             <h2>{% trans "Import" %}</h2>
             <p>{% trans "Please execute the import script locally as it can take a very long time." %}</p>
-            <p>{% trans "More info in the official docs:" %} <a href="http://doc.inthepoche.com/doku.php?id=users:migrate">inthepoche.com</a></p>
+            <p>{% trans "More info in the official docs:" %} <a href="http://doc.wallabag.org/doku.php?id=users:migrate">wallabag.org</a></p>
             <ul>
                 <li><a href="./?import&amp;from=pocket">{% trans "Import from Pocket" %}</a> {{ '(you must have a %s file on your server)'|trans|format(constant('POCKET_FILE')) }}</li>
-            <li><a href="./?import&amp;from=readability">{% trans "Import from Readability" %}</a> {{ '(you must have a %s file on your server)'|trans|format(constant('READABILITY_FILE')) }}</li>
-            <li><a href="./?import&amp;from=instapaper">{% trans "Import from Instapaper" %}</a> {{ '(you must have a %s file on your server)'|trans|format(constant('INSTAPAPER_FILE')) }}</li>
+                <li><a href="./?import&amp;from=readability">{% trans "Import from Readability" %}</a> {{ '(you must have a %s file on your server)'|trans|format(constant('READABILITY_FILE')) }}</li>
+                <li><a href="./?import&amp;from=instapaper">{% trans "Import from Instapaper" %}</a> {{ '(you must have a %s file on your server)'|trans|format(constant('INSTAPAPER_FILE')) }}</li>
+                <li><a href="./?import&amp;from=poche">{% trans "Import from poche" %}</a> {{ '(you must have a %s file on your server)'|trans|format(constant('POCHE_FILE')) }}</li>
             </ul>
 
             <h2>{% trans "Export your poche data" %}</h2>
index 4cfc482401c223ae0f80a28baf3bc8b25371fcc1..528a0985866737f0066c494d94b07f0f694d4273 100644 (file)
@@ -7,5 +7,8 @@
             <li>{{message}}</li>
         {% endfor %}
     </ol>
-    <p>Don't forget <a href="http://doc.inthepoche.com/">the documentation</a>.</p>
+    <p>Don't forget <a href="http://doc.wallabag.org/">the documentation</a>.</p>
+    <p>
+        {% trans "You can <a href='wallabag_compatibility_test.php'>check your configuration here</a>." %}
+    </p>
 {% endblock %}
index c4da0954884dcb08dd7c12a6b2592bff76b1b3ec..c89c7e47eaa049d296f8d99e7f66e1b296dfb7f7 100644 (file)
@@ -3,9 +3,9 @@
 {% block content %}
         <form method="post" action="?install" name="loginform">
             <fieldset class="w500p center">
-                <h2 class="mbs txtcenter">{% trans "install your poche" %}</h2>
+                <h2 class="mbs txtcenter">{% trans "install your wallabag" %}</h2>
                 <p>
-                    {% trans "Poche is still not installed. Please fill the below form to install it. Don't hesitate to <a href='http://doc.inthepoche.com/'>read the documentation on poche website</a>." %}
+                    {% trans "wallabag is still not installed. Please fill the below form to install it. Don't hesitate to <a href='http://doc.wallabag.org/'>read the documentation on wallabag website</a>." %}
                 </p>
                 <p class="row">
                     <label class="col w150p" for="login">{% trans "Login" %}</label>
index fec7054abc76346e75886ab73b513308cd99fef4..dfebc3eacff6abe6538968fd995f3e3011c9eee2 100644 (file)
@@ -10,7 +10,7 @@
         <!--[if IE]>
         <meta http-equiv="X-UA-Compatible" content="IE=10">
         <![endif]-->
-        <title>{% block title %}{% endblock %} - poche</title>
+        <title>{% block title %}{% endblock %} - wallabag</title>
 {% include '_head.twig' %}
 {% include '_bookmarklet.twig' %}
     </head>
index e2a9a9f520e808550517847515caa30727c84c38..bf685240618fb5068f928b90e677b9e420a6b69a 100644 (file)
@@ -1,11 +1,11 @@
 {% extends "layout.twig" %}
 
-{% block title %}{% trans "login to your poche" %}{% endblock %}
+{% block title %}{% trans "login to your wallabag" %}{% endblock %}
 {% block content %}
     {% if http_auth == 0 %}
             <form method="post" action="?login" name="loginform">
                 <fieldset class="w500p center">
-                    <h2 class="mbs txtcenter">{% trans "Login to poche" %}</h2>
+                    <h2 class="mbs txtcenter">{% trans "Login to wallabag" %}</h2>
                     {% if constant('MODE_DEMO') == 1 %}<p>{% trans "you are in demo mode, some features may be disabled." %}</p>{% endif %}
                                        <div class="row">
                                                <label class="col w150p" for="login">{% trans "Username" %}</label>
diff --git a/themes/default/theme.ini b/themes/default/theme.ini
new file mode 100644 (file)
index 0000000..9f3cfb6
--- /dev/null
@@ -0,0 +1 @@
+name = Default
\ No newline at end of file
index e4a2fe744344f451ce33367f8d3a83cf3f47efe8..d09977a801b2149cd5f438022214be923af0c53e 100644 (file)
@@ -9,11 +9,11 @@
                 <li><a title="{% trans "Mark as read" %}" class="tool {% if entry.is_read == 0 %}archive-off{% else %}archive{% endif %}" href="./?action=toggle_archive&amp;id={{ entry.id|e }}"><span>{% trans "Toggle mark as read" %}</span></a></li>
                 <li><a title="{% trans "Favorite" %}" class="tool {% if entry.is_fav == 0 %}fav-off{% else %}fav{% endif %}" href="./?action=toggle_fav&amp;id={{ entry.id|e }}"><span>{% trans "Toggle favorite" %}</span></a></li>
                 <li><a title="{% trans "Delete" %}" class="tool delete" href="./?action=delete&amp;id={{ entry.id|e }}"><span>{% trans "Delete" %}</span></a></li>
-                {% if constant('SHARE_TWITTER') == 1 %}<li><a href="https://twitter.com/home?status={{entry.title|url_encode}}%20{{ entry.url|url_encode }}%20via%20@getpoche" target="_blank" class="tool twitter" title="{% trans "Tweet" %}"><span>{% trans "Tweet" %}</span></a></li>{% endif %}
-                {% if constant('SHARE_MAIL') == 1 %}<li><a href="mailto:?subject={{ entry.title|url_encode }}&amp;body={{ entry.url|url_encode }}%20via%20@getpoche" class="tool email" title="{% trans "Email" %}"><span>{% trans "Email" %}</span></a></li>{% endif %}
+                {% if constant('SHARE_TWITTER') == 1 %}<li><a href="https://twitter.com/home?status={{entry.title|url_encode}}%20{{ entry.url|url_encode }}%20via%20@wallabagapp" target="_blank" class="tool twitter" title="{% trans "Tweet" %}"><span>{% trans "Tweet" %}</span></a></li>{% endif %}
+                {% if constant('SHARE_MAIL') == 1 %}<li><a href="mailto:?subject={{ entry.title|url_encode }}&amp;body={{ entry.url|url_encode }}%20via%20@wallabagapp" class="tool email" title="{% trans "Email" %}"><span>{% trans "Email" %}</span></a></li>{% endif %}
                 {% if constant('SHARE_SHAARLI') == 1 %}<li><a href="{{ constant('SHAARLI_URL') }}/index.php?post={{ entry.url|url_encode }}&amp;title={{ entry.title|url_encode }}" target="_blank" class="tool shaarli" title="{% trans "shaarli" %}"><span>{% trans "shaarli" %}</span></a></li>{% endif %}
                 {% if constant('FLATTR') == 1 %}{% if flattr.status == constant('FLATTRABLE') %}<li><a href="http://flattr.com/submit/auto?url={{ entry.url }}" class="tool flattr" target="_blank" title="{% trans "flattr" %}"><span>{% trans "flattr" %}</span></a></li>{% elseif flattr.status == constant('FLATTRED') %}<li><a href="{{ flattr.flattrItemURL }}" class="tool flattr" target="_blank" title="{% trans "flattr" %}"><span>{% trans "flattr" %}</span>{{ flattr.numflattrs }}</a></li>{% endif %}{% endif %}
-                <li><a href="mailto:support@inthepoche.com?subject=Wrong%20display%20in%20poche&amp;body={{ entry.url|url_encode }}" title="{% trans "Does this article appear wrong?" %}" class="tool bad-display"><span>{% trans "Does this article appear wrong?" %}</span></a></li>
+                <li><a href="mailto:hello@wallabag.org?subject=Wrong%20display%20in%20wallabag&amp;body={{ entry.url|url_encode }}" title="{% trans "Does this article appear wrong?" %}" class="tool bad-display"><span>{% trans "Does this article appear wrong?" %}</span></a></li>
             </ul>
         </div>
         <div id="article">
diff --git a/themes/dmagenta/theme.ini b/themes/dmagenta/theme.ini
new file mode 100644 (file)
index 0000000..24ff3c4
--- /dev/null
@@ -0,0 +1,2 @@
+name = Dark Magenta
+requirements[] = default
index 7ce8a5633e0ba7b1b99df1641d723e26b0247d81..3b0feb2a562b2e8144a29fb94d2a0cf0767f34ff 100644 (file)
@@ -42,7 +42,8 @@ body,
 body,
 a,
 a:hover,
-a:visited {
+a:visited,
+td {
     color: #839496;
 }
 
diff --git a/themes/solarized-dark/theme.ini b/themes/solarized-dark/theme.ini
new file mode 100644 (file)
index 0000000..7b6b341
--- /dev/null
@@ -0,0 +1,2 @@
+name = Dark Solarized
+requirements[] = default
index 9286c75078569872502b3056b76a4bdaf1f95654..6058d056372e9827b3257abe1869fab48fe686f2 100644 (file)
@@ -42,7 +42,8 @@ body,
 body,
 a,
 a:hover,
-a:visited {
+a:visited,
+td {
     color: #657b83;
 }
 
diff --git a/themes/solarized/theme.ini b/themes/solarized/theme.ini
new file mode 100644 (file)
index 0000000..703997b
--- /dev/null
@@ -0,0 +1,2 @@
+name = Solarized
+requirements[] = default
similarity index 98%
rename from poche_compatibility_test.php
rename to wallabag_compatibility_test.php
index 42faaa2ce705f996a6b5992e774bce81edc0d564..fd2850420d0d0b794ad484c3a75127231a6fb536 100644 (file)
@@ -1,5 +1,5 @@
 <?php
-$app_name = 'poche 1.3';
+$app_name = 'wallabag 1';
 
 $php_ok = (function_exists('version_compare') && version_compare(phpversion(), '5.3.3', '>='));
 $pcre_ok = extension_loaded('pcre');
@@ -313,13 +313,13 @@ div.chunk {
                        <?php if ($php_ok && $xml_ok && $pcre_ok && $filter_ok && $allow_url_fopen_ok) { ?>
                                <h3>Bottom Line: Yes, you can!</h3>
                                <p><em>Your webhost has its act together!</em></p>
-                               <p>You can download the latest version of <?php echo $app_name; ?> from <a href="http://inthepoche.com/download">inthepoche.com</a>.</p>
+                               <p>You can download the latest version of <?php echo $app_name; ?> from <a href="http://wallabag.org/download">wallabag.org</a>.</p>
                                <p><strong>Note</strong>: Passing this test does not guarantee that <?php echo $app_name; ?> will run on your webhost &mdash; it only ensures that the basic requirements have been addressed. If you experience any problems, please let us know.</p>
                        <?php //} else if ($php_ok && $xml_ok && $pcre_ok && $mbstring_ok && $allow_url_fopen_ok && $filter_ok) { ?>
                        <?php } else if ($php_ok && $xml_ok && $pcre_ok && $allow_url_fopen_ok && $filter_ok) { ?>
                                <h3>Bottom Line: Yes, you can!</h3>
                                <p><em>For most feeds, it'll run with no problems.</em> There are certain languages that you might have a hard time with though.</p>
-                               <p>You can download the latest version of <?php echo $app_name; ?> from <a href="http://inthepoche.com/download">inthepoche.com</a>.</p>
+                               <p>You can download the latest version of <?php echo $app_name; ?> from <a href="http://wallabag.org/download">wallabag.org</a>.</p>
                                <p><strong>Note</strong>: Passing this test does not guarantee that <?php echo $app_name; ?> will run on your webhost &mdash; it only ensures that the basic requirements have been addressed. If you experience any problems, please let us know.</p>
                        <?php } else { ?>
                                <h3>Bottom Line: We're sorry…</h3>