diff --git a/resources/lang/de/settings.php b/resources/lang/de/settings.php
index b0cd782b..fe411a6f 100644
--- a/resources/lang/de/settings.php
+++ b/resources/lang/de/settings.php
@@ -5,6 +5,7 @@
'site_name_label' => 'Seitenname',
'about_this_site_label' => 'Über diese Seite',
'timezone_label' => 'Zeitzone',
+ 'timezone_other' => 'Andere',
'incident_days_label' => 'Vorfalltage',
'major_outage_threshold_label' => 'Schwellenwert für schwere Ausfälle',
'refresh_rate_label' => 'Automatisch Seite neuladen',
diff --git a/resources/lang/de_AT/settings.php b/resources/lang/de_AT/settings.php
index b0cd782b..fe411a6f 100644
--- a/resources/lang/de_AT/settings.php
+++ b/resources/lang/de_AT/settings.php
@@ -5,6 +5,7 @@
'site_name_label' => 'Seitenname',
'about_this_site_label' => 'Über diese Seite',
'timezone_label' => 'Zeitzone',
+ 'timezone_other' => 'Andere',
'incident_days_label' => 'Vorfalltage',
'major_outage_threshold_label' => 'Schwellenwert für schwere Ausfälle',
'refresh_rate_label' => 'Automatisch Seite neuladen',
diff --git a/resources/lang/de_CH/settings.php b/resources/lang/de_CH/settings.php
index b0cd782b..fe411a6f 100644
--- a/resources/lang/de_CH/settings.php
+++ b/resources/lang/de_CH/settings.php
@@ -5,6 +5,7 @@
'site_name_label' => 'Seitenname',
'about_this_site_label' => 'Über diese Seite',
'timezone_label' => 'Zeitzone',
+ 'timezone_other' => 'Andere',
'incident_days_label' => 'Vorfalltage',
'major_outage_threshold_label' => 'Schwellenwert für schwere Ausfälle',
'refresh_rate_label' => 'Automatisch Seite neuladen',
diff --git a/resources/lang/en/settings.php b/resources/lang/en/settings.php
index 007f17f8..ec3a5cc2 100644
--- a/resources/lang/en/settings.php
+++ b/resources/lang/en/settings.php
@@ -4,6 +4,9 @@
'manage_cachet' => [
'site_name_label' => 'Site Name',
'about_this_site_label' => 'About This Site',
+ 'timezone_label' => 'Timezone',
+ 'timezone_other' => 'Other',
+ 'browser_default' => 'Browser Default',
'incident_days_label' => 'Incident Days',
'major_outage_threshold_label' => 'Major Outage Threshold',
'refresh_rate_label' => 'Automatically Refresh Page',
@@ -29,7 +32,7 @@
'locale_label' => 'Locale',
'timezone_label' => 'Timezone',
'toggles' => [
- 'show_timezone' => 'Show Timezone',
+ 'show_timezone' => 'Show timezone on status page',
],
],
'manage_theme' => [
diff --git a/resources/lang/nl/settings.php b/resources/lang/nl/settings.php
index f7049d67..936b2c8b 100644
--- a/resources/lang/nl/settings.php
+++ b/resources/lang/nl/settings.php
@@ -5,6 +5,8 @@
'site_name_label' => 'Pagina naam',
'about_this_site_label' => 'Over deze site',
'timezone_label' => 'Tijdzone',
+ 'timezone_other' => 'Overig',
+ 'browser_default' => 'Gebruik browserstandaard',
'incident_days_label' => 'Incidentendagen',
'major_outage_threshold_label' => 'Drempel voor ernstige storingen',
'refresh_rate_label' => 'Pagina automatisch opnieuw laden',
diff --git a/resources/lang/ph/settings.php b/resources/lang/ph/settings.php
index 7b77da60..386b3d67 100644
--- a/resources/lang/ph/settings.php
+++ b/resources/lang/ph/settings.php
@@ -5,6 +5,7 @@
'site_name_label' => 'Pangalan ng Site',
'about_this_site_label' => 'Tungkol sa Site na Ito',
'timezone_label' => 'Oras na Rehiyon',
+ 'timezone_other' => 'Iba pang mga oras',
'incident_days_label' => 'Mga Araw ng Insidente',
'major_outage_threshold_label' => 'Limitasyon ng Malaking Pagka-aberya',
'refresh_rate_label' => 'Awtomatikong I-refresh ang Pahina',
diff --git a/resources/lang/pt_BR/settings.php b/resources/lang/pt_BR/settings.php
index 52a2212f..791cad39 100644
--- a/resources/lang/pt_BR/settings.php
+++ b/resources/lang/pt_BR/settings.php
@@ -5,6 +5,7 @@
'site_name_label' => 'Nome do Site',
'about_this_site_label' => 'Sobre Este Site',
'timezone_label' => 'Fuso Horário',
+ 'timezone_other' => 'Outro',
'incident_days_label' => 'Dias de Incidentes',
'major_outage_threshold_label' => 'Limite de Indisponibilidade Total',
'refresh_rate_label' => 'Atualizar Página Automaticamente',
diff --git a/resources/views/components/footer.blade.php b/resources/views/components/footer.blade.php
index 960d14c2..6212ea8f 100644
--- a/resources/views/components/footer.blade.php
+++ b/resources/views/components/footer.blade.php
@@ -11,13 +11,21 @@
@endif
@if($showTimezone)
-
- {!! preg_replace(
+
+
@endif
@endif
diff --git a/resources/views/components/incident.blade.php b/resources/views/components/incident.blade.php
index 8b2e0389..6fabf53b 100644
--- a/resources/views/components/incident.blade.php
+++ b/resources/views/components/incident.blade.php
@@ -6,7 +6,7 @@
{{ \Cachet\Facades\CachetView::renderHook(\Cachet\View\RenderHook::STATUS_PAGE_INCIDENTS_BEFORE) }}
-
+
@forelse($incidents as $incident)
- {{ $incident->timestamp->diffForHumans() }} —
+ {{ $incident->timestamp->diffForHumans() }} —
@@ -53,7 +53,7 @@
{{ $update->status->getLabel() }}
- {{ $update->created_at->diffForHumans() }} —
+ {{ $update->created_at->diffForHumans() }} —
{!! $update->formattedMessage() !!}
@@ -62,7 +62,7 @@
- {{ $incident->timestamp->diffForHumans() }} —
+ {{ $incident->timestamp->diffForHumans() }} —
{!! $incident->formattedMessage() !!}
diff --git a/resources/views/components/schedule.blade.php b/resources/views/components/schedule.blade.php
index 6664b886..b6b92f45 100644
--- a/resources/views/components/schedule.blade.php
+++ b/resources/views/components/schedule.blade.php
@@ -11,7 +11,7 @@
- {{ $schedule->scheduled_at->diffForHumans() }} —
+ {{ $schedule->scheduled_at->diffForHumans() }} —
@@ -30,7 +30,7 @@
@foreach ($schedule->updates as $update)
- {{ $update->created_at->diffForHumans() }} —
+ {{ $update->created_at->diffForHumans() }} —
{!! $update->formattedMessage() !!}
diff --git a/src/CachetCoreServiceProvider.php b/src/CachetCoreServiceProvider.php
index d736d717..9427fb77 100644
--- a/src/CachetCoreServiceProvider.php
+++ b/src/CachetCoreServiceProvider.php
@@ -164,6 +164,7 @@ private function registerPublishing(): void
*/
private function registerBladeComponents(): void
{
+ view()->share('appSettings', app(AppSettings::class));
Blade::componentNamespace('Cachet\\View\\Components', 'cachet');
$this->callAfterResolving(Factory::class, function (Factory $factory) {
diff --git a/src/Filament/Pages/Settings/ManageCachet.php b/src/Filament/Pages/Settings/ManageCachet.php
index 1c3c3917..4a468134 100644
--- a/src/Filament/Pages/Settings/ManageCachet.php
+++ b/src/Filament/Pages/Settings/ManageCachet.php
@@ -40,21 +40,9 @@ public function form(Schema $schema): Schema
MarkdownEditor::make('about')
->label(__('cachet::settings.manage_cachet.about_this_site_label'))
->columnSpanFull(),
+ ]),
- Select::make('timezone')
- ->label(__('cachet::settings.manage_cachet.timezone_label'))
- ->options(fn () => collect(timezone_identifiers_list())
- ->mapToGroups(
- fn ($timezone) => [
- Str::of($timezone)
- ->before('/')
- ->toString() => [$timezone => $timezone],
- ]
- )
- ->map(fn ($group) => $group->collapse()))
- ->searchable()
- ->suffixIcon('heroicon-o-globe-alt'),
-
+ Section::make()->columns(3)->schema([
TextInput::make('incident_days')
->numeric()
->label(__('cachet::settings.manage_cachet.incident_days_label'))
@@ -78,13 +66,7 @@ public function form(Schema $schema): Schema
->step(1)
->suffix(__('cachet::settings.manage_cachet.refresh_rate_label_input_suffix_seconds')),
- Toggle::make('show_timezone')
- ->label(__('cachet::settings.manage_cachet.toggles.show_timezone')),
- Toggle::make('only_disrupted_days')
- ->label(__('cachet::settings.manage_cachet.toggles.only_show_disrupted_days')),
- Toggle::make('dashboard_login_link')
- ->label(__('cachet::settings.manage_cachet.toggles.show_dashboard_link')),
- Grid::make(2)
+ Grid::make(1)
->schema([
Toggle::make('recent_incidents_only')
->label(__('cachet::settings.manage_cachet.toggles.recent_incidents_only'))
@@ -99,14 +81,19 @@ public function form(Schema $schema): Schema
->hidden(fn (Get $get) => $get('recent_incidents_only') !== true),
]),
]),
+
Section::make(__('cachet::settings.manage_cachet.display_settings_title'))
->schema([
+ Toggle::make('dashboard_login_link')
+ ->label(__('cachet::settings.manage_cachet.toggles.show_dashboard_link')),
Toggle::make('show_support')
->label(__('cachet::settings.manage_cachet.toggles.support_cachet')),
Toggle::make('display_graphs')
->label(__('cachet::settings.manage_cachet.toggles.display_graphs')),
Toggle::make('enable_external_dependencies')
->label(__('cachet::settings.manage_cachet.toggles.enable_external_dependencies')),
+ Toggle::make('only_disrupted_days')
+ ->label(__('cachet::settings.manage_cachet.toggles.only_show_disrupted_days')),
]),
]);
}
diff --git a/src/Filament/Pages/Settings/ManageLocalization.php b/src/Filament/Pages/Settings/ManageLocalization.php
index 8d91cb24..09cef55e 100644
--- a/src/Filament/Pages/Settings/ManageLocalization.php
+++ b/src/Filament/Pages/Settings/ManageLocalization.php
@@ -48,6 +48,7 @@ public function form(Schema $schema): Schema
]
)
->map(fn ($group) => $group->collapse()))
+ ->required()
->searchable()
->suffixIcon('heroicon-o-globe-alt'),
diff --git a/src/Settings/AppSettings.php b/src/Settings/AppSettings.php
index cc4a1929..bd6ab701 100644
--- a/src/Settings/AppSettings.php
+++ b/src/Settings/AppSettings.php
@@ -2,6 +2,8 @@
namespace Cachet\Settings;
+use Cachet\Enums\IncidentStatusEnum;
+use Cachet\Enums\MetricTypeEnum;
use Spatie\LaravelSettings\Settings;
class AppSettings extends Settings