Skip to content

Releases: scify/laravel-cookies-consent

v3.1.2 - Fixes for Bootstrap-based apps

05 Feb 10:01
Compare
Choose a tag to compare
v3.1.3

v3.1.3 - Fixes for Bootstrap-based apps

v3.1.2 - UI improvements in smaller screens

05 Feb 09:50
Compare
Choose a tag to compare
v3.1.2 - UI improvements in smaller screens

v3.1.1 - UI improvements in smaller screens

05 Feb 08:10
Compare
Choose a tag to compare
v3.1.1 - UI fixes in smaller screens

v3.1.0 - UI improvements and simplification of front-end assets.

31 Jan 08:18
Compare
Choose a tag to compare

v3.1.0 - Changes in assets files in the public - 2025-01-31

In order to simplify the installation process and avoid potential conflicts with existing assets, the front-end assets
are now included directly in the package and loaded from the vendor/scify/laravel-cookies-consent/ directory.

This means that the public/vendor/cookies_consent directory should be deleted, and the assets should be published again:

In order to update to the new version, you need to remove the public/vendor/cookies_consent directory and run the
asset publishing command:

rm -rf public/vendor/cookies_consent

And then:

php artisan vendor:publish \
--provider="SciFY\LaravelCookiesConsent\LaravelCookiesConsentServiceProvider" \
--tag="cookies-consent-public"

v3.0.1 - New features & bugfixes

30 Jan 12:20
Compare
Choose a tag to compare

Minor bugfixing & UI/UX improvements over the v3.0.0 version.

v3.0.0 - Introducing a new JSON-format for the cookies

30 Jan 08:53
Compare
Choose a tag to compare

v3.0.0 - Major Release - JSON Cookie Storage & Configuration Changes - 2025-01-30

Breaking Changes

  • JSON Cookie Storage: Cookies are now stored in a JSON object under a single key with the prefix specified in the
    configuration file. This change improves the structure and management of cookies.

  • Configuration File Changes: The configuration file format has been updated to reflect the new JSON cookie storage
    method. The cookie_prefix is now used to store cookies in a JSON object.

Migration Guide

  1. Update the configuration file to reflect the new JSON cookie storage method:
  • Ensure the cookie_prefix is set in the config/cookies_consent.php file.
  • Update the name field of each cookie in the cookies array to reflect the new JSON storage format.

Example:

'cookie_prefix' => 'my_app_',
'cookies' => [
    'strictly_necessary' => [
        [
            'name' => 'my_app_cookies_consent',
            'description' => 'This cookie is set by the GDPR Cookie Consent plugin and is used to store whether or not user has consented to the use of cookies. It does not store any personal data.',
            'duration' => '2 years',
            'policy_external_link' => null,
        ],
        // other cookies...
    ],
    'targeting' => [
        // cookies...
    ],
],
  1. Update Blade Files
  • Update the Blade files to reflect the new JSON cookie storage method. The cookie helper function is used to set and
    retrieve cookies from the JSON object.

Example:

@if(isset($_COOKIE[config('cookies_consent.cookie_prefix') . 'cookies_consent']))
    @php
        $cookiesConsent = json_decode($_COOKIE[config('cookies_consent.cookie_prefix') . 'cookies_consent'], true);
    @endphp
    @if(isset($cookiesConsent['targeting']) && $cookiesConsent['targeting'] && config('app.google_analytics_id'))
        <!-- Google Analytics -->
        <script defer async>
            (function (i, s, o, g, r, a, m) {
                i['GoogleAnalyticsObject'] = r;
                i[r] = i[r] || function () {
                    (i[r].q = i[r].q || []).push(arguments)
                }, i[r].l = 1 * new Date();
                a = s.createElement(o),
                    m = s.getElementsByTagName(o)[0];
                a.async = 1;
                a.src = g;
                m.parentNode.insertBefore(a, m)
            })(window, document, 'script', 'https://www.google-analytics.com/analytics.js', 'ga');

            window.ga('create', '{{ config('app.google_analytics_id') }}', 'auto');
            window.ga('set', 'anonymizeIp', true);
            window.ga('send', 'pageview');
        </script>
    @endif
@endif
  1. Publish the front-end assets
  • Run the following command to publish the updated assets:
    php artisan vendor:publish --provider="SciFY\LaravelCookiesConsent\LaravelCookiesConsentServiceProvider" --tag=" cookies-consent-assets" --force
  1. Test your application
  • Ensure that the cookies consent functionality works as expected with the new JSON storage format.
  • Verify that the cookies are correctly set and retrieved in the browser.

v2.0.8 - UI Fixes for languages with big texts

27 Jan 17:34
Compare
Choose a tag to compare

v2.0.8 - UI Fixes for languages with big texts

v2.0.7 - UI Fixes for languages with big texts

27 Jan 17:25
Compare
Choose a tag to compare

v2.0.7 - UI Fixes for languages with big texts (smaller font sizes and paddings)

v2.0.6 - UI Fixes for languages with big texts

27 Jan 17:16
Compare
Choose a tag to compare

v2.0.6 - UI Fixes for languages with big texts

v2.0.5 - UI Fixes for languages with big texts

27 Jan 16:57
Compare
Choose a tag to compare

UI Fixes for languages with big texts (smaller paddings and font sizes)