sage-grids/laravel-site-settings

Reusable site settings and brand settings for Laravel applications using Spatie Laravel Settings

Installs: 0

Dependents: 0

Suggesters: 0

Security: 0

Stars: 0

Watchers: 0

Forks: 0

Open Issues: 0

pkg:composer/sage-grids/laravel-site-settings

v0.0.1 2026-02-16 12:21 UTC

This package is auto-updated.

Last update: 2026-02-16 17:28:13 UTC


README

Reusable site settings and brand settings for Laravel applications, powered by spatie/laravel-settings.

Installation

composer require sage-grids/laravel-site-settings

The service provider is auto-discovered by Laravel.

Publish & Run Migrations

php artisan vendor:publish --tag=site-settings-settings
php artisan migrate

Settings Classes

SiteSettings (group: site)

General site identity, footer, and analytics settings:

  • Identity: site_name, site_description, site_logo, site_logo_dark, site_favicon, support_email, maintenance_mode, default_theme, default_landing_page
  • Footer: company_name, company_address, facebook_url, twitter_url, linkedin_url, instagram_url, youtube_url, github_url, tiktok_url, privacy_policy_url, terms_of_service_url
  • Analytics: google_analytics_id, facebook_pixel_id, google_tag_manager_id

BrandSettings (group: brand)

Brand identity and voice settings:

  • brand_name (string)
  • tagline (string)
  • target_audience (array of one-line descriptions)
  • value_proposition (string)
  • elevator_pitch (string)
  • color_palette (array, e.g. ['primary' => '#000', 'secondary' => '#fff'])
  • typography (array, e.g. ['heading' => 'Playfair Display', 'body' => 'Inter'])

Usage

use SageGrids\SiteSettings\Settings\SiteSettings;
use SageGrids\SiteSettings\Settings\BrandSettings;

// Read
$siteName = app(SiteSettings::class)->site_name;
$brandName = app(BrandSettings::class)->brand_name;

// Write
$settings = app(SiteSettings::class);
$settings->site_name = 'My Site';
$settings->save();

Migrating from GeneralSettings

If you previously used App\Settings\GeneralSettings with the general group, create a one-time migration in your app that copies general.* values to site.* in the settings table, then remove the old general.* keys. See database/settings/2026_02_16_000000_migrate_general_to_site_settings.php in the host app for an example.