laravel-splade icon indicating copy to clipboard operation
laravel-splade copied to clipboard

Feature request TapTap editor

Open thewebartisan7 opened this issue 3 years ago • 2 comments

A few suggestions and feature request.

Would be good to have a rich textarea with https://www.taptap.io/

Also there is already a Discord channel or similar?

Thanks!

thewebartisan7 avatar Aug 31 '22 12:08 thewebartisan7

Tiptap maybe? https://tiptap.dev/

rodrigopedra avatar Sep 10 '22 11:09 rodrigopedra

Ops yes right tiptap.dev )) Updated, thanks.

thewebartisan7 avatar Sep 10 '22 12:09 thewebartisan7

It would be great if we had a component for a popular rich text editor like CKEditor, TinyMCE etc...

boranbar avatar Nov 08 '22 21:11 boranbar

We're using Quill in one of our projects, and I like it. However, it has been over three years since there has been a new release which worries me. They're working hard on the next version, though! Native support for tables and uploads in the editor are very welcome.

pascalbaljet avatar Dec 22 '22 09:12 pascalbaljet

Vuequill could be added very quickly

npm install @vueup/vue-quill@latest --save

Then in app.js add Quill.

import { QuillEditor } from '@vueup/vue-quill'
import '@vueup/vue-quill/dist/vue-quill.snow.css';
createApp({
    render: renderSpladeApp({ el })
})
    .use(SpladePlugin, {
        "max_keep_alive": 10,
        "transform_anchors": false,
        "progress_bar": true,
        "components": {
            QuillEditor
        }
    })
    .mount(el);

How are you adding it to your blade? I've been wracking my brain and just cant get it to render on my splade form for the life of me. I looked at the doco and they just seems to use a

but this wont render in the component. (apologies, I'm still learning so I'm pretty stupid)

My simple splade comp:

<x-layout>
  <x-panel>
    <x-splade-lazy>
       <x-splade-form :default="$experiment">
         <div id="editor"></div>
         // also tried <x-splade-textarea name="notes" label="Notes" id="editor" />
       </x-splade-form>
        </x-splade-lazy>
    </x-panel>
</x-layout>

It just refuses to render.

uqjohart avatar Jan 03 '23 01:01 uqjohart

Anyone familiar with Jodit? https://xdsoft.net/jodit/

pascalbaljet avatar Jan 11 '23 15:01 pascalbaljet

following the response from @HUGE-D1CK-10-INCHES , it was important for me to use v-model:content instead of :value to make the data submission work properly in the form and avoid null request. I used a syntax similar to the example.

  <div class="rounded-md border border-gray-300 shadow-sm">
      <quill-editor name="description" v-model:component="form.description" componentType="html" toolbar="full" />
      <x-splade-input type="hidden" name="description" />
  </div>

MichInf avatar Mar 06 '23 18:03 MichInf

v-model:component="form.description"

Like this i get no errors:

<div class="rounded-md border border-gray-300 shadow-sm">
       <quill-editor name="descrip" v-model="form.descrip"  toolbar="full" />
</div>

But i cant get the value on $request.. Thanks for your time!

hipoagencia avatar May 04 '23 21:05 hipoagencia

:content

using v-model:content="form.description"

i could achive this:

image

The complete code:

<quill-editor name="descrip" v-model:content="form.description" componentType="html" toolbar="full" />
<x-splade-input type="hidden" name="description" />

hipoagencia avatar May 04 '23 21:05 hipoagencia

Anyone familiar with Jodit? https://xdsoft.net/jodit/

Do you pretend to make a tutorial with how we can implement this? It will be awesome.

hipoagencia avatar May 05 '23 01:05 hipoagencia

Thanks to great work by @J87NL, Splade now supports the Jodit editor as of v1.4.10:

<x-splade-form>
    <x-splade-wysiwyg name="body" />
</x-splade-form>

Because Jodit's stylesheet is quite large, I decided not to include it in the default style.css, so you need to manually add it to the main app.js file:

import "@protonemedia/laravel-splade/dist/style.css";
+ import "@protonemedia/laravel-splade/dist/jodit.css";
import { renderSpladeApp, SpladePlugin } from "@protonemedia/laravel-splade";

I'll soon add this to the docs!

pascalbaljet avatar May 18 '23 21:05 pascalbaljet