Markdown in accordion

We installed kirby plugin accordion. https://github.com/Klickmeister/kirby-panel-accordion
There is summary and detailed text.
I need the detailed text to be in markdown.
I changed somewhere in the code but it did nothing. :frowning_with_open_mouth:

Hey, welcome to our forum.

I’m missing some context. What accordion are you referring to? What did you change and where?

We installed kirby plugin accordion. https://github.com/Klickmeister/kirby-panel-accordion

That’s a very old plugin that was created for Kirby 2 and is not compatible with Kirby 3, which I assume you are using?

3.6.0-rc.2
But it is working quite well. I only need markdown instead of text…

Question 2: is there something similar instead of Accordion in Kirby 3?

I don’t see how that field could possibly work in Kirby 3, it wouldn’t even load because it doesn’t have the obligatory index.php file. And I don’t understand what that field has got to to with markdown, since the whole purpose of this field was to hide/show other fields on click.

Not that I know of, instead of grouping by headlines, you can use tabs in the Panel.

Maybe our previous programmer was the good one :slight_smile:
Ok, is here somebody who is familiar with the good old Accordion?

In the YML file, field types are defined, e.g:
type: writer
type: text
I would like to have type: markdown
but it is not working :frowning:

Markdown is not a built-in field type. You can either use the textarea field (which is a markdown field) or you can install the markdown field plugin which comes with more options.

I already have that plugin. I can use markdown when writing an article.
But I want to use it in accordion, too.

Maybe you can provide your blueprint for reference, it’s not really clear without code what you are trying to do and where it might go wrong.

the textarea could be a solution for me, but it does not allow DIV tag.
Can I somehow allow it somewhere?

I’m really sorry, but if you don’t answer my questions, it’s hard to be of any help.

name: Accordion
wysiwyg: true
fields:
  accordion:
    type: structure
    columns:
      summary:
          width: 1/4
      details:
          width: 2/4
      toggle:
          text: false
    fields:
      summary:
        type: text
        width: 3/4
        placeholder: Add title here
      toggle:
        label: Open on load?
        type: toggle
        default: true
        text:
          - "No"
          - "Yes"
        width: 1/4
      details:
        **type: textarea**
        placeholder: Add hidden text here
        required: true

Now I used type: textarea
that is almost ok if only it allowed DIV tag

Ok, so you are using a custom block called accordion and not this old plugin you posted above. Completely different story. That’s why it helps to provide all necessary information.

I don’t see any reason why you shouldn’t be able to use the markdown field in that context though. What exactly is the issue?

I just tested this and works for me, but you probably have to clear the media folder first.

There are 2 options:

  • textarea - works for me almost OK, if only it allowed DIV tag
  • markdown - does not work, see the previous image

Thank you, but what does this screenshot mean?
What is this answer to?