amidesfahani / filament-tinyeditor

a TineMce editor for Laravel Filament Forms
MIT License
54 stars 18 forks source link

Implement link_class_list and link_rel_list #37

Open androideen opened 7 months ago

androideen commented 7 months ago

Missing guide to implement link plugin https://www.tiny.cloud/docs/tinymce/6/link/.

robinmalburn commented 3 months ago

I was looking for this functionality, too, but thankfully you can achieve it using the custom_configs support when defining profiles in config/filament-tinyeditor.php.

Here's an example configuration tested working with the latest release:

    'profiles' => [
        'default' => [
            'plugins' => 'accordion autoresize codesample directionality advlist link image lists preview pagebreak searchreplace wordcount code fullscreen insertdatetime media table emoticons',
            'toolbar' => 'undo redo removeformat | fontfamily fontsize fontsizeinput font_size_formats styles | bold italic underline | rtl ltr | alignjustify alignleft aligncenter alignright | numlist bullist outdent indent | forecolor backcolor | blockquote table toc hr | image link media codesample emoticons | wordcount fullscreen',
            'upload_directory' => null,
            'custom_configs' => [
                'link_class_list' => [
                    ['title' => 'Foo', 'value' => 'foo'],
                    ['title' => 'Bar', 'value' => 'bar'],
                ]
            ]
        ],