When using the replicator and especially the DRY example by Jack (changed to fit my field)

{{ main_content }}
    {{ partial src="sets/{type}" }}
{{ /main_content }}

then I am wondering how it is possible to wrap 2 or more types in 1 div class?

Let us say I got 2 fields in my replicator called "text" and "list" and I add them in the CP like this: See image for example https://cl.ly/211e3I1R3z2Z
Text
List
List

I got 2 files in my sets folder called list.html and text.html The list partial contains this:

<h4>{{ title_above_list }}</h4>
{{ list | ul }}

How can I get this html output?

<div class="content">Content form the text field<div>
<div class="wrap">
  <h4>Title</h4>
  <ul>List</ul>
  <h4>Title</h4>
  <ul>List</ul>
</div>

Basically wherever I try to put my div class it gets wrap around every single type like this

<div class="content">Content form the text field<div>
<div class="wrap">
  <h4>Title</h4>
  <ul>List</ul>
</div>
<div class="wrap">
  <h4>Title</h4>
  <ul>List</ul>
</div>

Hopefully this makes sense. If not please let me know and I will rewrite it.

Thank you

Answered by Jack McDade! Go to answer.