From f0cabc63ad0a6f8b508b0025b743556d97dd3b86 Mon Sep 17 00:00:00 2001 From: Nico Stapelbroek Date: Sun, 11 Feb 2018 21:04:16 +0100 Subject: [PATCH 1/3] Separate meta description for the incident, schedule and subscribe pages --- resources/lang/en/cachet.php | 11 ++++++++++- resources/views/layout/master.blade.php | 4 ++-- resources/views/single-incident.blade.php | 2 ++ resources/views/single-schedule.blade.php | 2 ++ resources/views/subscribe/subscribe.blade.php | 2 ++ 5 files changed, 18 insertions(+), 3 deletions(-) diff --git a/resources/lang/en/cachet.php b/resources/lang/en/cachet.php index 0c45fe00f..34b5eb59a 100644 --- a/resources/lang/en/cachet.php +++ b/resources/lang/en/cachet.php @@ -117,9 +117,18 @@ return [ ], ], + // Meta descriptions + 'meta' => [ + 'description' => [ + 'incident' => 'Details and updates about the :name incident that occurred on :date', + 'schedule' => 'Details about the scheduled maintenance period :name starting :startDate', + 'subscribe' => 'Subscribe to :app in order to receive updates of incidents and scheduled maintenance periods', + 'overview' => 'Stay up to date with the latest service updates from :app.', + ] + ], + // Other 'home' => 'Home', - 'description' => 'Stay up to date with the latest service updates from :app.', 'powered_by' => 'Powered by Cachet.', 'timezone' => 'Times are shown in :timezone.', 'about_this_site' => 'About This Site', diff --git a/resources/views/layout/master.blade.php b/resources/views/layout/master.blade.php index 5700e3aa4..413bfd343 100644 --- a/resources/views/layout/master.blade.php +++ b/resources/views/layout/master.blade.php @@ -15,12 +15,12 @@ - + - + diff --git a/resources/views/single-incident.blade.php b/resources/views/single-incident.blade.php index 519d5d83d..59d88dc10 100644 --- a/resources/views/single-incident.blade.php +++ b/resources/views/single-incident.blade.php @@ -2,6 +2,8 @@ @section('title', $incident->name.' | '.$site_title) +@section('description', trans('cachet.meta.description.incident', ['name' => $incident->name, 'date' => $incident->occurred_at_formatted])) + @section('bodyClass', 'no-padding') @section('outer-content') diff --git a/resources/views/single-schedule.blade.php b/resources/views/single-schedule.blade.php index cc3f7cbe6..1f20dfb21 100644 --- a/resources/views/single-schedule.blade.php +++ b/resources/views/single-schedule.blade.php @@ -2,6 +2,8 @@ @section('title', $schedule->name.' | '.$site_title) +@section('description', trans('cachet.meta.description.schedule', ['name' => $schedule->name, 'startDate' => $schedule->scheduled_at_formatted])) + @section('bodyClass', 'no-padding') @section('outer-content') diff --git a/resources/views/subscribe/subscribe.blade.php b/resources/views/subscribe/subscribe.blade.php index 0b9749c86..1d34834b3 100644 --- a/resources/views/subscribe/subscribe.blade.php +++ b/resources/views/subscribe/subscribe.blade.php @@ -1,5 +1,7 @@ @extends('layout.master') +@section('description', trans('cachet.meta.description.subscribe', ['app' => $site_title])) + @section('content')

From 716135a7962e6530723e0012ef020b191456ad06 Mon Sep 17 00:00:00 2001 From: Nico Stapelbroek Date: Sun, 11 Feb 2018 21:04:41 +0100 Subject: [PATCH 2/3] Configure a title for the subscribe page --- resources/views/subscribe/subscribe.blade.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/resources/views/subscribe/subscribe.blade.php b/resources/views/subscribe/subscribe.blade.php index 1d34834b3..fc7a1e8fd 100644 --- a/resources/views/subscribe/subscribe.blade.php +++ b/resources/views/subscribe/subscribe.blade.php @@ -1,5 +1,7 @@ @extends('layout.master') +@section('title', trans('cachet.subscriber.subscribe'). " | ". $site_title)) + @section('description', trans('cachet.meta.description.subscribe', ['app' => $site_title])) @section('content') From ce7437e96ae9ac4c60bae216cf49c6ef06f6a7e3 Mon Sep 17 00:00:00 2001 From: Nico Stapelbroek Date: Sun, 11 Feb 2018 21:13:39 +0100 Subject: [PATCH 3/3] Fix styleCI issues --- resources/lang/en/cachet.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/resources/lang/en/cachet.php b/resources/lang/en/cachet.php index 34b5eb59a..7b8099b5e 100644 --- a/resources/lang/en/cachet.php +++ b/resources/lang/en/cachet.php @@ -118,13 +118,13 @@ return [ ], // Meta descriptions - 'meta' => [ + 'meta' => [ 'description' => [ 'incident' => 'Details and updates about the :name incident that occurred on :date', 'schedule' => 'Details about the scheduled maintenance period :name starting :startDate', 'subscribe' => 'Subscribe to :app in order to receive updates of incidents and scheduled maintenance periods', 'overview' => 'Stay up to date with the latest service updates from :app.', - ] + ], ], // Other