Skip to content

Use trigger for collapsible in other DOM location #274

@wichert

Description

@wichert

It would be nice if the collapsible pattern could support a trigger for collapsible content that is in another location. For example:

<button class="pat-collapsible" 
    data-pat-collapsible="content: #status">Show status</button>
...
<aside id="status">
  ...
</aside>

After initialisation the markup will look like this:

<button class="pat-collapsible closed" 
    data-pat-collapsible="content: #status">Show status</button>
...
<div class="panel-content closed">
  <aside id="status">
    ...
  </aside>
</div>

@cornae: is this generated markup correct?

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions