Skip to content

Commit dd1b267

Browse files
committed
Remove old and deprecated iOS only meta tags
Signed-off-by: Matt Friedman <maf675@gmail.com>
1 parent bd14f94 commit dd1b267

3 files changed

Lines changed: 5 additions & 1 deletion

File tree

event/listener.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -142,6 +142,7 @@ public function pwa_manifest()
142142
$this->template->assign_vars([
143143
'U_MANIFEST_URL' => $this->controller_helper->route('phpbb_webpushnotifications_manifest_controller'),
144144
'U_TOUCH_ICON' => $this->config['pwa_icon_small'],
145+
'SHORT_SITE_NAME' => $this->config['pwa_short_name'] ?: substr($this->config['sitename'], 0, 12),
145146
]);
146147
}
147148

styles/all/template/event/overall_header_head_append.html

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
<meta name="apple-mobile-web-app-capable" content="yes">
2+
<meta name="mobile-web-app-capable" content="yes">
23
<meta name="apple-mobile-web-app-status-bar-style" content="black-translucent">
3-
<meta name="apple-mobile-web-app-title" content="{{ SITENAME }}">
4+
<meta name="application-name" content="{{ SHORT_SITE_NAME }}">
45
<link rel="manifest" href="{{ U_MANIFEST_URL }}">
56
{% if U_TOUCH_ICON %}<link rel="apple-touch-icon" href="{{ T_ICONS_PATH ~ U_TOUCH_ICON }}">{% endif %}
67

tests/event/listener_test.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -262,6 +262,7 @@ public function test_load_template_data($user_id, $method_data, $subscriptions,
262262
public function test_pwa_manifest()
263263
{
264264
$this->config['pwa_icon_small'] = 'icon-192x192.png';
265+
$this->config['pwa_short_name'] = 'Test';
265266

266267
$this->set_listener();
267268

@@ -270,6 +271,7 @@ public function test_pwa_manifest()
270271
->with([
271272
'U_MANIFEST_URL' => $this->controller_helper->route('phpbb_webpushnotifications_manifest_controller'),
272273
'U_TOUCH_ICON' => 'icon-192x192.png',
274+
'SHORT_SITE_NAME' => 'Test',
273275
]);
274276

275277
$dispatcher = new \phpbb\event\dispatcher();

0 commit comments

Comments
 (0)