diff --git a/README.md b/README.md index 874aebb..f55526c 100644 --- a/README.md +++ b/README.md @@ -144,18 +144,18 @@ class RegisterCookiesConsent // Register cookies related to the Facebook pixel CookiesConsent::register(new CookieGroupDefinition( key: 'marketing', - name: __('cookies-consent::translations.marketing.name'), - description: __('cookies-consent::translations.marketing.description'), + name: __('cookies-consent::cookies.marketing.name'), + description: __('cookies-consent::cookies.marketing.description'), items: [ new CookieDefinition( name: '_fbc', lifetime: CarbonInterval::years(2), - description: __('cookies-consent::translations._fbc.description') + description: __('cookies-consent::cookies._fbc.description') ), new CookieDefinition( name: '_fbp', lifetime: CarbonInterval::years(3), - description: __('cookies-consent::translations._fbp.description') + description: __('cookies-consent::cookies._fbp.description') ), ], onAccepted: function () { @@ -321,18 +321,18 @@ use Carbon\CarbonInterval; CookiesConsent::register(new CookieGroupDefinition( key: 'marketing', // customize this value if you want - name: __('cookies-consent::translations.marketing.name'), // customize this value if you want - description: __('cookies-consent::translations.marketing.description'), // customize this value if you want + name: __('cookies-consent::cookies.marketing.name'), // customize this value if you want + description: __('cookies-consent::cookies.marketing.description'), // customize this value if you want items: [ new CookieDefinition( name: '_fbc', lifetime: CarbonInterval::years(2), - description: __('cookies-consent::translations._fbc.description') + description: __('cookies-consent::cookies._fbc.description') ), new CookieDefinition( name: '_fbp', lifetime: CarbonInterval::years(3), - description: __('cookies-consent::translations._fbp.description') + description: __('cookies-consent::cookies._fbp.description') ), ], onAccepted: function () { diff --git a/resources/lang/en/translations.php b/resources/lang/en/cookies.php similarity index 100% rename from resources/lang/en/translations.php rename to resources/lang/en/cookies.php diff --git a/resources/lang/fr/translations.php b/resources/lang/fr/cookies.php similarity index 100% rename from resources/lang/fr/translations.php rename to resources/lang/fr/cookies.php diff --git a/resources/views/components/banner.blade.php b/resources/views/components/banner.blade.php index d96ba63..53a2e03 100644 --- a/resources/views/components/banner.blade.php +++ b/resources/views/components/banner.blade.php @@ -109,30 +109,30 @@

- {{ __('cookies-consent::translations.title') }} + {{ __('cookies-consent::cookies.title') }}

- {{ __('cookies-consent::translations.intro') }}
- {!! __('cookies-consent::translations.link', ['url' => route('privacy', ['locale' => 'fr'])]) !!} + {{ __('cookies-consent::cookies.intro') }}
+ {!! __('cookies-consent::cookies.link', ['url' => route('privacy', ['locale' => 'fr'])]) !!}

- {{ __('cookies-consent::translations.accept_required') }} + {{ __('cookies-consent::cookies.accept_required') }} - {{ __('cookies-consent::translations.accept_all') }} + {{ __('cookies-consent::cookies.accept_all') }} - {{ __('cookies-consent::translations.customize') }} + {{ __('cookies-consent::cookies.customize') }} - {{ __('cookies-consent::translations.save') }} + {{ __('cookies-consent::cookies.save') }}
@@ -157,10 +157,10 @@ class="col-span-2 justify-center rounded-md font-semibold" x-on:click="save"> @@ -182,7 +182,7 @@ class="col-span-2 justify-center rounded-md font-semibold" x-on:click="save">
- {{ __('cookies-consent::translations.save') }} + {{ __('cookies-consent::cookies.save') }}
diff --git a/src/CookiesConsent.php b/src/CookiesConsent.php index 7c68859..e6270d1 100755 --- a/src/CookiesConsent.php +++ b/src/CookiesConsent.php @@ -95,8 +95,8 @@ public function registerEssentials(): static return $this->register( new CookieGroupDefinition( key: 'essentials', - name: __('cookies-consent::translations.essentials.name'), - description: __('cookies-consent::translations.essentials.description'), + name: __('cookies-consent::cookies.essentials.name'), + description: __('cookies-consent::cookies.essentials.description'), required: true, items: [ new CookieDefinition(