From cdb53ed0ba4db7478cf626ddb770d8daf5c224d2 Mon Sep 17 00:00:00 2001 From: Randi Mays Date: Mon, 18 Mar 2024 13:17:43 -0500 Subject: [PATCH 1/2] VACMS-17057 Events web component upgrades --- src/site/includes/social-share.drupal.liquid | 24 ++-- src/site/layouts/event.drupal.liquid | 115 ++++++++----------- src/site/teasers/event.drupal.liquid | 22 ++-- 3 files changed, 79 insertions(+), 82 deletions(-) diff --git a/src/site/includes/social-share.drupal.liquid b/src/site/includes/social-share.drupal.liquid index d4f78c2e97..a82f5caa5c 100644 --- a/src/site/includes/social-share.drupal.liquid +++ b/src/site/includes/social-share.drupal.liquid @@ -4,8 +4,8 @@ {% assign now = '' | currentTime %} {% assign mostRecentDate = mostRecentDate | deriveMostRecentDate: now %} - - - - Add to Calendar - + text="Add to Calendar" + />
  • - + Share on Facebook - +
  • - + Share on Twitter - +
  • diff --git a/src/site/layouts/event.drupal.liquid b/src/site/layouts/event.drupal.liquid index a9dd249642..f86ae4ca2f 100644 --- a/src/site/layouts/event.drupal.liquid +++ b/src/site/layouts/event.drupal.liquid @@ -73,9 +73,10 @@ {% assign fieldFacilityAddress = fieldFacilityLocation.entity.fieldAddress %}

    - - {{ fieldFacilityLocation.entity.title }} - +

    {{ fieldLocationHumanreadable }}

    {% if fieldFacilityAddress.addressLine1 != empty %} @@ -109,11 +110,9 @@ {% elsif fieldLocationType == "online" %}

    {% if fieldUrlOfAnOnlineEvent %} - - {% endif %} + + {% else %} This is an online event. - {% if fieldUrlOfAnOnlineEvent %} - {% endif %}

    {% else %} @@ -219,68 +218,54 @@ {% if fieldDatetimeRangeTimezone.length > 1 %} - -
    - - {% for recurringEventDatetimeRangeTimezone in fieldDatetimeRangeTimezone %} -
    -

    - {{ recurringEventDatetimeRangeTimezone | deriveFormattedTimestamp }} -

    - - - Add to Calendar - -
    - {% endfor %} - - - {% if fieldDatetimeRangeTimezone.length > 6 %} -
    - -
    - {% endif %} -
    + + + + {% for recurringEventDatetimeRangeTimezone in fieldDatetimeRangeTimezone %} +
    +

    + {{ recurringEventDatetimeRangeTimezone | deriveFormattedTimestamp }} +

    + +
    + {% endfor %} + + + {% if fieldDatetimeRangeTimezone.length > 6 %} +
    + +
    + {% endif %} +
    +
    {% endif %} - - See more events - - + onclick="recordEvent({ event: 'nav-secondary-button-click' });" + text="See more events" + /> {% include "src/site/includes/above-footer-elements.drupal.liquid" %}
    diff --git a/src/site/teasers/event.drupal.liquid b/src/site/teasers/event.drupal.liquid index 1387c91906..2c2361d497 100644 --- a/src/site/teasers/event.drupal.liquid +++ b/src/site/teasers/event.drupal.liquid @@ -6,7 +6,12 @@ {% endif %} {% assign isEventsPage = entityUrl.path | isPage: "events" %}
    - <{{ header }} class="vads-u-margin-top--0 vad-u-margin-bottom-1 vads-u-font-size--md medium-screen:vads-u-font-size--lg">{{ node.title }} + <{{ header }} class="vads-u-margin-top--0 vad-u-margin-bottom-1 vads-u-font-size--md medium-screen:vads-u-font-size--lg"> + +

    {{ node.fieldDescription | truncatewords: 60, "..." }}

    @@ -34,12 +39,15 @@ Where
    -

    - {{ node.fieldFacilityLocation.entity.title }} -

    - {% if node.fieldLocationHumanreadable != empty %} - {{ node.fieldLocationHumanreadable }} - {% endif %} +

    + +

    + {% if node.fieldLocationHumanreadable != empty %} + {{ node.fieldLocationHumanreadable }} + {% endif %}
    {% endif %} From d260a7896057e8d36a600299f0e8c356d00522d5 Mon Sep 17 00:00:00 2001 From: Randi Mays Date: Tue, 19 Mar 2024 15:33:50 -0500 Subject: [PATCH 2/2] Fix some component errors --- src/site/includes/social-share.drupal.liquid | 12 ++++++------ src/site/layouts/event.drupal.liquid | 8 ++++---- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/src/site/includes/social-share.drupal.liquid b/src/site/includes/social-share.drupal.liquid index a82f5caa5c..6410a4c61f 100644 --- a/src/site/includes/social-share.drupal.liquid +++ b/src/site/includes/social-share.drupal.liquid @@ -18,21 +18,21 @@
  • + - Share on Facebook - + text="Share on Facebook" + />
  • + - Share on Twitter - + text="Share on Twitter" + />
  • diff --git a/src/site/layouts/event.drupal.liquid b/src/site/layouts/event.drupal.liquid index f86ae4ca2f..11457ddb79 100644 --- a/src/site/layouts/event.drupal.liquid +++ b/src/site/layouts/event.drupal.liquid @@ -176,7 +176,7 @@ {% if fieldLink or fieldEventCta or fieldAdditionalInformationAbo %} -
    +
    {% if start_timestamp < current_timestamp %}

    This event already happened.

    {% else %} @@ -218,7 +218,7 @@ {% if fieldDatetimeRangeTimezone.length > 1 %} - + + > {% include "src/site/includes/above-footer-elements.drupal.liquid" %}