From 52240b6b4e85e92a339bfe576f3d8ab88990448c Mon Sep 17 00:00:00 2001 From: James Harley <27085725+JKHarley@users.noreply.github.com> Date: Sun, 12 Mar 2023 13:55:24 +0000 Subject: [PATCH] Upgrade for Laravel 10 compatibility (#5) * Upgrade for Laravel 10 compatibility --- CHANGELOG.md | 5 +++++ composer.json | 4 ++-- resources/views/trumbowyg.blade.php | 29 +++++++++++++++++++++-------- 3 files changed, 28 insertions(+), 10 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 6be4a77..a1fc811 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,11 @@ All notable changes to `filament-trumbowyg` will be documented in this file. +## 2.0.0 - 2023-04-12 +- Adds support for Laravel 10 +- Fix an issue accessing the editor data through `livewire.data` +- Fixes an issue with double worded fields + ## 1.0.0 - 2022-11-30 - Fixes an issue with styling of page overwriting the styling of the wysiwyg diff --git a/composer.json b/composer.json index 1537888..373219c 100644 --- a/composer.json +++ b/composer.json @@ -19,13 +19,13 @@ "php": "^8.0", "filament/filament": "^2.0", "spatie/laravel-package-tools": "^1.13.5", - "illuminate/contracts": "^9.0" + "illuminate/contracts": "^9.0|^10.0" }, "require-dev": { "laravel/pint": "^1.0", "nunomaduro/collision": "^6.0", "nunomaduro/larastan": "^2.0.1", - "orchestra/testbench": "^7.0", + "orchestra/testbench": "^7.0|^8.0", "pestphp/pest": "^1.21", "pestphp/pest-plugin-laravel": "^1.1", "pestphp/pest-plugin-livewire": "^1.0", diff --git a/resources/views/trumbowyg.blade.php b/resources/views/trumbowyg.blade.php index eb8b2d9..1db699b 100644 --- a/resources/views/trumbowyg.blade.php +++ b/resources/views/trumbowyg.blade.php @@ -1,3 +1,8 @@ +@php +// Label is used to assign an id to the editor as $getId() causes issues +$editorId = strtolower(str_replace(' ', '-', $getLabel())); +@endphp +