amirandev / openadmin-summernote
Integrate Summernote editor into open-admin
Requires
- php: >=7.0.0
- laravel/framework: >=7.0
- open-admin-org/open-admin: ~1.0
Requires (Dev)
- laravel/laravel: ~9.0
- phpunit/phpunit: ~6.0
README
Here’s a polished, ready-to-use README description for your package based on what you provided, with clean formatting and slight improvements for clarity:
Integrate Summernote into Open-Admin
This is an open-admin extension that integrates the Summernote WYSIWYG editor into the open-admin form system.
Screenshot
Installation
Run the following command to install the package via Composer:
composer require amirandev/open-admin-summernote
Then publish the package assets:
php artisan vendor:publish --tag=open-admin-summernote
Configuration
In your config/admin.php
file, add the summernote
extension configuration under the extensions
section:
'extensions' => [ 'summernote' => [ // Set to false to disable this extension 'enable' => true, // Editor configuration options 'config' => [ // See Summernote docs for available options ], ], ],
Example configuration (customize as needed):
'config' => [ 'language' => 'de', 'height' => 500, 'contentsCss' => '/css/frontend-body-content.css', ]
For more configuration options, see the official Summernote Documentation.
Usage
Use the Summernote editor in your OpenAdmin form like this:
$form->summernote('content');
Or with custom options:
$form->summernote('content')->options([ 'lang' => 'fr', 'height' => 500, 'contentsCss' => '/css/frontend-body-content.css', ]);
Troubleshooting
If Summernote does not load or you see errors about missing files, try clearing your application cache:
php artisan optimize:clear
License
This package is licensed under the MIT License.
If you want, I can help you prepare the actual README.md file content ready to copy-paste! Would you like that?