aboutsummaryrefslogtreecommitdiffhomepage
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/Wallabag/CoreBundle/Helper/DownloadImages.php11
-rw-r--r--src/Wallabag/CoreBundle/Resources/translations/messages.en.yml2
-rw-r--r--src/Wallabag/CoreBundle/Resources/views/themes/common/Entry/share.html.twig2
-rw-r--r--src/Wallabag/CoreBundle/Resources/views/themes/material/Exception/error.html.twig2
-rw-r--r--src/Wallabag/CoreBundle/Resources/views/themes/material/layout.html.twig2
-rw-r--r--src/Wallabag/UserBundle/Resources/views/Security/login.html.twig2
-rw-r--r--src/Wallabag/UserBundle/Resources/views/layout.html.twig2
7 files changed, 14 insertions, 9 deletions
diff --git a/src/Wallabag/CoreBundle/Helper/DownloadImages.php b/src/Wallabag/CoreBundle/Helper/DownloadImages.php
index f91cdf5e..487a3a23 100644
--- a/src/Wallabag/CoreBundle/Helper/DownloadImages.php
+++ b/src/Wallabag/CoreBundle/Helper/DownloadImages.php
@@ -185,7 +185,7 @@ class DownloadImages
185 * 185 *
186 * @return array An array of urls 186 * @return array An array of urls
187 */ 187 */
188 protected function getSrcsetUrls(Crawler $imagesCrawler) 188 private function getSrcsetUrls(Crawler $imagesCrawler)
189 { 189 {
190 $urls = []; 190 $urls = [];
191 $iterator = $imagesCrawler 191 $iterator = $imagesCrawler
@@ -193,9 +193,14 @@ class DownloadImages
193 while ($iterator->valid()) { 193 while ($iterator->valid()) {
194 $srcsetAttribute = $iterator->current()->getAttribute('srcset'); 194 $srcsetAttribute = $iterator->current()->getAttribute('srcset');
195 if ('' !== $srcsetAttribute) { 195 if ('' !== $srcsetAttribute) {
196 $srcset = array_map('trim', explode(',', $srcsetAttribute)); 196 // Couldn't start with " OR ' OR a white space
197 // Could be one or more white space
198 // Must be one or more digits followed by w OR x
199 $pattern = "/(?:[^\"'\s]+\s*(?:\d+[wx])+)/";
200 preg_match_all($pattern, $srcsetAttribute, $matches);
201 $srcset = call_user_func_array('array_merge', $matches);
197 $srcsetUrls = array_map(function ($src) { 202 $srcsetUrls = array_map(function ($src) {
198 return explode(' ', $src)[0]; 203 return trim(explode(' ', $src, 2)[0]);
199 }, $srcset); 204 }, $srcset);
200 $urls = array_merge($srcsetUrls, $urls); 205 $urls = array_merge($srcsetUrls, $urls);
201 } 206 }
diff --git a/src/Wallabag/CoreBundle/Resources/translations/messages.en.yml b/src/Wallabag/CoreBundle/Resources/translations/messages.en.yml
index 88517c82..bd81c72f 100644
--- a/src/Wallabag/CoreBundle/Resources/translations/messages.en.yml
+++ b/src/Wallabag/CoreBundle/Resources/translations/messages.en.yml
@@ -116,7 +116,7 @@ config:
116 archived: Remove ALL archived entries 116 archived: Remove ALL archived entries
117 confirm: Are you really sure? (THIS CAN'T BE UNDONE) 117 confirm: Are you really sure? (THIS CAN'T BE UNDONE)
118 form_password: 118 form_password:
119 description: "You can change your password here. Your new password should by at least 8 characters long." 119 description: "You can change your password here. Your new password should be at least 8 characters long."
120 old_password_label: 'Current password' 120 old_password_label: 'Current password'
121 new_password_label: 'New password' 121 new_password_label: 'New password'
122 repeat_new_password_label: 'Repeat new password' 122 repeat_new_password_label: 'Repeat new password'
diff --git a/src/Wallabag/CoreBundle/Resources/views/themes/common/Entry/share.html.twig b/src/Wallabag/CoreBundle/Resources/views/themes/common/Entry/share.html.twig
index 9b0503d6..b9fcc005 100644
--- a/src/Wallabag/CoreBundle/Resources/views/themes/common/Entry/share.html.twig
+++ b/src/Wallabag/CoreBundle/Resources/views/themes/common/Entry/share.html.twig
@@ -7,7 +7,7 @@
7 <meta property="og:title" content="{{ entry.title|e|raw }}" /> 7 <meta property="og:title" content="{{ entry.title|e|raw }}" />
8 <meta property="og:type" content="article" /> 8 <meta property="og:type" content="article" />
9 <meta property="og:url" content="{{ app.request.uri }}" /> 9 <meta property="og:url" content="{{ app.request.uri }}" />
10 {% set picturePath = app.request.schemeAndHttpHost ~ asset('wallassets/themes/_global/img/logo-other_themes.png') %} 10 {% set picturePath = app.request.schemeAndHttpHost ~ asset('wallassets/themes/_global/img/logo-wallabag.svg') %}
11 {% if entry.previewPicture is not null %} 11 {% if entry.previewPicture is not null %}
12 {% set picturePath = entry.previewPicture %} 12 {% set picturePath = entry.previewPicture %}
13 {% endif %} 13 {% endif %}
diff --git a/src/Wallabag/CoreBundle/Resources/views/themes/material/Exception/error.html.twig b/src/Wallabag/CoreBundle/Resources/views/themes/material/Exception/error.html.twig
index b5db40f5..741795aa 100644
--- a/src/Wallabag/CoreBundle/Resources/views/themes/material/Exception/error.html.twig
+++ b/src/Wallabag/CoreBundle/Resources/views/themes/material/Exception/error.html.twig
@@ -11,7 +11,7 @@
11<main class="valign-wrapper"> 11<main class="valign-wrapper">
12 <div class="valign row"> 12 <div class="valign row">
13 <div class="card sw"> 13 <div class="card sw">
14 <div class="center"><img src="{{ asset('wallassets/themes/_global/img/logo-other_themes.png') }}" alt="wallabag logo" /></div> 14 <div class="center"><img src="{{ asset('wallassets/themes/_global/img/logo-wallabag.svg') }}" alt="wallabag logo" class="typo-logo" /></div>
15 <div class="card-content"> 15 <div class="card-content">
16 <div class="row"> 16 <div class="row">
17 <h5>{{ status_code }}: {{ status_text }}</h5> 17 <h5>{{ status_code }}: {{ status_text }}</h5>
diff --git a/src/Wallabag/CoreBundle/Resources/views/themes/material/layout.html.twig b/src/Wallabag/CoreBundle/Resources/views/themes/material/layout.html.twig
index 6472d182..f0012ad9 100644
--- a/src/Wallabag/CoreBundle/Resources/views/themes/material/layout.html.twig
+++ b/src/Wallabag/CoreBundle/Resources/views/themes/material/layout.html.twig
@@ -29,7 +29,7 @@
29 {% block logo %} 29 {% block logo %}
30 <li class="logo border-bottom"> 30 <li class="logo border-bottom">
31 <a title="{{ 'menu.left.back_to_unread'|trans }}" href="{{ path('unread') }}"> 31 <a title="{{ 'menu.left.back_to_unread'|trans }}" href="{{ path('unread') }}">
32 <img src="{{ asset('wallassets/themes/_global/img/logo-square.png') }}" alt="wallabag logo" /> 32 <img src="{{ asset('wallassets/themes/_global/img/logo-square.svg') }}" alt="wallabag logo" />
33 </a> 33 </a>
34 </li> 34 </li>
35 {% endblock %} 35 {% endblock %}
diff --git a/src/Wallabag/UserBundle/Resources/views/Security/login.html.twig b/src/Wallabag/UserBundle/Resources/views/Security/login.html.twig
index 32984c84..3dd98fb6 100644
--- a/src/Wallabag/UserBundle/Resources/views/Security/login.html.twig
+++ b/src/Wallabag/UserBundle/Resources/views/Security/login.html.twig
@@ -16,7 +16,7 @@
16 16
17 <div class="input-field col s12"> 17 <div class="input-field col s12">
18 <label for="username">{{ 'security.login.username'|trans }}</label> 18 <label for="username">{{ 'security.login.username'|trans }}</label>
19 <input type="text" id="username" name="_username" value="{{ last_username }}" /> 19 <input type="text" id="username" name="_username" value="{{ last_username }}" autofocus />
20 </div> 20 </div>
21 21
22 <div class="input-field col s12"> 22 <div class="input-field col s12">
diff --git a/src/Wallabag/UserBundle/Resources/views/layout.html.twig b/src/Wallabag/UserBundle/Resources/views/layout.html.twig
index eada1829..99bf7dfd 100644
--- a/src/Wallabag/UserBundle/Resources/views/layout.html.twig
+++ b/src/Wallabag/UserBundle/Resources/views/layout.html.twig
@@ -11,7 +11,7 @@
11<main class="valign-wrapper"> 11<main class="valign-wrapper">
12 <div class="valign row"> 12 <div class="valign row">
13 <div class="card sw"> 13 <div class="card sw">
14 <div class="center"><img src="{{ asset('wallassets/themes/_global/img/logo-other_themes.png') }}" alt="wallabag logo" /></div> 14 <div class="center"><img src="{{ asset('wallassets/themes/_global/img/logo-wallabag.svg') }}" alt="wallabag logo" class="typo-logo" /></div>
15 {% block fos_user_content %} 15 {% block fos_user_content %}
16 {% endblock fos_user_content %} 16 {% endblock fos_user_content %}
17 </div> 17 </div>