membershipworks: Fix layout/use wordpress blocks in upcoming-events

This commit is contained in:
Adam Goldsmith 2023-12-24 00:20:23 -05:00
parent 7b20c784d5
commit 9a0d6012b9

View File

@ -4,87 +4,109 @@
{% block title %}Upcoming Events{% endblock %} {% block title %}Upcoming Events{% endblock %}
{% block content %} {% block content %}
{% spaceless %}
<div id="preview"> <div id="preview">
<p> <!-- wp:image {"align":"center","id":2319} -->
<img class="aligncenter size-medium wp-image-2319" <figure class="wp-block-image aligncenter">
src="https://claremontmakerspace.org/wp-content/uploads/2019/03/CMS-Logo-b-y-g-300x168.png" <img src="https://claremontmakerspace.org/wp-content/uploads/2019/03/CMS-Logo-b-y-g-300x168.png"
alt=""
width="300" width="300"
height="168" /> height="168"
</p> alt="CMS Logo"
class="wp-image-2319" />
</figure>
<!-- /wp:image -->
<!-- wp:paragraph -->
<p>Greetings Upper Valley Makers:</p> <p>Greetings Upper Valley Makers:</p>
<!-- /wp:paragraph -->
<!-- wp:paragraph -->
<p>We have an exciting list of upcoming classes at the Claremont MakerSpace that we think might interest you.</p> <p>We have an exciting list of upcoming classes at the Claremont MakerSpace that we think might interest you.</p>
<div> <!-- /wp:paragraph -->
<strong>For most classes and events, CMS MEMBERSHIP IS NOT REQUIRED.</strong> That said, members receive a discount <!-- wp:paragraph -->
on registration and there are some classes/events that are for members only (this will be clearly noted in the event <p>
description). <strong>For most classes and events, CMS MEMBERSHIP IS NOT REQUIRED.</strong> That said, members receive a discount on registration and there are some classes/events that are for members only (this will be clearly noted in the event description).
</div> <br>
<div> <strong>Class policies</strong> (liability waiver, withdrawal, cancellation, etc.) can be found <a href="https://claremontmakerspace.org/class-policies/">here</a>.
<strong>Class policies</strong> (liability waiver, withdrawal, cancellation, etc.) can be found <a href="https://claremontmakerspace.org/class-policies/" <br>
data-wpel-link="internal">here</a>. <strong>Instructors:</strong> Interested in teaching a class at CMS? Please fill out our <a href="https://claremontmakerspace.org/cms-class-proposal-form/">Class Proposal Form</a>.
</div> <br>
<div>
<strong>Instructors:</strong> Interested in teaching a class at CMS? Please fill out our <a href="https://claremontmakerspace.org/cms-class-proposal-form/"
data-wpel-link="internal">Class Proposal Form</a>.
</div>
<div>
<strong>Tours:</strong> Want to see what the Claremont MakerSpace is all about? Tours are by appointment only. <strong>Tours:</strong> Want to see what the Claremont MakerSpace is all about? Tours are by appointment only.
</div> <br>
<a href="https://tickets.claremontmakerspace.org/open.php" <a data-wpel-link="external"
href="https://tickets.claremontmakerspace.org/open.php"
target="_blank" target="_blank"
rel="noreferrer noopener external" rel="noreferrer noopener external">Contact Us</a> to schedule your tour where you can learn about all the awesome tools that the CMS offers access to, as well as how membership, classes, and studio spaces work.
data-wpel-link="external">Contact Us</a> to schedule your tour where you can learn about all the awesome tools that </p>
the CMS offers access to, as well as how membership, classes, and studio spaces work. <!-- /wp:paragraph -->
<hr /> <!-- wp:separator {"className":"is-style-wide"} -->
<hr class="wp-block-separator has-alpha-channel-opacity is-style-wide" />
<!-- /wp:separator -->
{% for section in event_sections %} {% for section in event_sections %}
{% if section.events %} {% if section.events %}
<h1>{{ section.title }}</h1> <!-- wp:heading {"level":1} -->
<h4> <h1 class="wp-block-heading">{{ section.title }}</h1>
<!-- /wp:heading -->
<!-- wp:heading {"level":4} -->
<h4 class="wp-block-heading">
<i>{{ section.blurb }}</i> <i>{{ section.blurb }}</i>
</h4> </h4>
<!-- /wp:heading -->
{% for event in section.events %} {% for event in section.events %}
{% with url="https://claremontmakerspace.org/events/#!event/register/"|add:event.url %} {% with url="https://claremontmakerspace.org/events/#!event/register/"|add:event.url %}
{% spaceless %} <!-- wp:group {"tagName":"section","layout":{"type":"constrained"}} -->
<h2 style="text-align: center;"> <section class="wp-block-group">
<!-- wp:heading {"align":"center"} -->
<h2 class="wp-block-heading">
<a href="{{ url }}"> <a href="{{ url }}">
{# djlint:off H006,H013 #} {% if "lgo" in event %}
{% if "lgo" in event %}<img class="alignleft" width="400" src="{{ event.lgo.l }}">{% endif %} {# djlint:off H006 #}
<img class="{% cycle 'alignleft' 'alignright' %}"
width="400"
alt="Image for {{ event.ttl|bleach }}"
src="{{ event.lgo.l }}">
{# djlint:on #} {# djlint:on #}
{% endif %}
<span>{{ event.ttl|bleach }}</span> <span>{{ event.ttl|bleach }}</span>
</a> </a>
</h2> </h2>
{% endspaceless %} <!-- /wp:heading -->
{% spaceless %} <!-- wp:paragraph -->
<div> <p>
{# wordpress is very annoying with spacing here #} {# wordpress is very annoying with spacing here #}
{# djlint:off #}
<i>
{# TODO: different dates probably implies multiple instances. Should read RRULE or similar from the event notes #} {# TODO: different dates probably implies multiple instances. Should read RRULE or similar from the event notes #}
{{ event.sdp_dt|date }} {{ event.sdp_dt|time }} &mdash; {% if event.sdp_dt.date != event.edp_dt.date %}{{ event.edp_dt|date }}{% endif %} {{ event.edp_dt|time }} {# djlint:off #}
</i> <i>{{ event.sdp_dt|date }} {{ event.sdp_dt|time }} &mdash; {% if event.sdp_dt.date != event.edp_dt.date %}{{ event.edp_dt|date }}{% endif %} {{ event.edp_dt|time }}</i>
{# djlint:on #} {# djlint:on #}
</div> </p>
{% endspaceless %} <!-- /wp:paragraph -->
{% if not section.truncate %} {% if not section.truncate %}
<!-- wp:tadv/classic-paragraph -->
<div>{{ event.dtl|bleach:"a,abbr,acronym,b,blockquote,code,em,i,li,ol,strong,ul,p,span,br,div" }}</div> <div>{{ event.dtl|bleach:"a,abbr,acronym,b,blockquote,code,em,i,li,ol,strong,ul,p,span,br,div" }}</div>
<div> <!-- /wp:tadv/classic-paragraph -->
<!-- wp:paragraph -->
<p>
<a href="{{ url }}">Register for this class now!</a> <a href="{{ url }}">Register for this class now!</a>
</div> </p>
<!-- /wp:paragraph -->
{% endif %} {% endif %}
<hr /> </section>
<!-- /wp:group -->
<!-- wp:separator {"className":"is-style-wide"} -->
<hr class="wp-block-separator has-alpha-channel-opacity is-style-wide aligncenter" />
<!-- /wp:separator -->
{% endwith %} {% endwith %}
{% endfor %} {% endfor %}
{% endif %} {% endif %}
{% endfor %} {% endfor %}
<div style="clear: both;"> <!-- wp:paragraph -->
<div>Happy Makin!</div> <p style="clear: both;">Happy Makin!</p>
<div> <!-- /wp:paragraph -->
We are grateful for all of the public support that our 501(c)(3), non-profit organization receives. If youd <!-- wp:paragraph -->
like to make a donation,please visit the <a href="https://claremontmakerspace.org/support/"><strong>Support Us <p>
page</strong></a> of our website. We are grateful for all of the public support that our 501(c)(3), non-profit organization receives. If youd like to make a donation,please visit the <a href="https://claremontmakerspace.org/support/"><strong>Support Us page</strong></a> of our website.
</div> </p>
</div> <!-- /wp:paragraph -->
</div> </div>
{% endspaceless %}
<div class="position-fixed end-0 bottom-0"> <div class="position-fixed end-0 bottom-0">
<button id="copy-button" <button id="copy-button"
type="button" type="button"