Skip to content

Commit

Permalink
Merge pull request Andycko#7 from fortytwostudio/master
Browse files Browse the repository at this point in the history
CMS & Code Tidy
  • Loading branch information
rossthomson89 authored Nov 3, 2022
2 parents 1b8911f + ab9e806 commit 1330ff8
Show file tree
Hide file tree
Showing 15 changed files with 86 additions and 130 deletions.
2 changes: 1 addition & 1 deletion config/general.php
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
// Setup @webroot alias
'aliases' => [
'@web' => App::env('PRIMARY_SITE_URL')
],
]
],

'dev' => [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,15 +26,6 @@ fieldLayouts:
type: craft\fieldlayoutelements\EntryTitleField
warning: null
width: 100
-
fieldUid: 8d7e4ca7-1762-4215-b1e0-3022ed0176b3 # Transparent Nav
instructions: null
label: null
required: false
tip: null
type: craft\fieldlayoutelements\CustomField
warning: null
width: 100
-
fieldUid: d783368e-a494-4457-9e99-5a027ae72a18 # Page Header
instructions: null
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,15 +26,6 @@ fieldLayouts:
type: craft\fieldlayoutelements\EntryTitleField
warning: null
width: 100
-
fieldUid: 8d7e4ca7-1762-4215-b1e0-3022ed0176b3 # Transparent Nav
instructions: null
label: null
required: false
tip: null
type: craft\fieldlayoutelements\CustomField
warning: null
width: 100
-
fieldUid: d783368e-a494-4457-9e99-5a027ae72a18 # Page Header
instructions: null
Expand All @@ -44,6 +35,10 @@ fieldLayouts:
type: craft\fieldlayoutelements\CustomField
warning: null
width: 100
-
style: warning
tip: 'Any content blocks you add here will appear below the enquiry form'
type: craft\fieldlayoutelements\Tip
-
fieldUid: 1d1d5665-5674-4388-8d46-9b87e4dc65d3 # Content Builder
instructions: null
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,15 +26,6 @@ fieldLayouts:
type: craft\fieldlayoutelements\EntryTitleField
warning: null
width: 100
-
fieldUid: 8d7e4ca7-1762-4215-b1e0-3022ed0176b3 # Transparent Nav
instructions: null
label: null
required: false
tip: null
type: craft\fieldlayoutelements\CustomField
warning: null
width: 100
-
fieldUid: d783368e-a494-4457-9e99-5a027ae72a18 # Page Header
instructions: null
Expand All @@ -58,7 +49,7 @@ fieldLayouts:
-
elements:
-
fieldUid: 4184d945-e90d-4433-b1f3-727edf65107e # Summary Image
fieldUid: 39237593-ff51-4bd3-851a-a9dfac329c0b # Page Summary
instructions: null
label: null
required: false
Expand All @@ -67,7 +58,7 @@ fieldLayouts:
warning: null
width: 100
-
fieldUid: 39237593-ff51-4bd3-851a-a9dfac329c0b # Page Summary
fieldUid: 4184d945-e90d-4433-b1f3-727edf65107e # Summary Image
instructions: null
label: null
required: false
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,15 +26,6 @@ fieldLayouts:
type: craft\fieldlayoutelements\EntryTitleField
warning: null
width: 100
-
fieldUid: 8d7e4ca7-1762-4215-b1e0-3022ed0176b3 # Transparent Nav
instructions: null
label: null
required: false
tip: null
type: craft\fieldlayoutelements\CustomField
warning: null
width: 100
-
fieldUid: d783368e-a494-4457-9e99-5a027ae72a18 # Page Header
instructions: null
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,24 +26,6 @@ fieldLayouts:
type: craft\fieldlayoutelements\EntryTitleField
warning: null
width: 100
-
fieldUid: 8d7e4ca7-1762-4215-b1e0-3022ed0176b3 # Transparent Nav
instructions: null
label: null
required: false
tip: null
type: craft\fieldlayoutelements\CustomField
warning: null
width: 100
-
fieldUid: 2f64efd3-101a-4ed1-a31e-96657d6dc6e5 # Header
instructions: null
label: null
required: false
tip: null
type: craft\fieldlayoutelements\CustomField
warning: null
width: 100
-
fieldUid: 1d1c9f28-39de-4df6-b077-856d16c001ca # Copy
instructions: null
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ fieldLayouts:
warning: null
width: 100
-
fieldUid: 8d7e4ca7-1762-4215-b1e0-3022ed0176b3 # Transparent Nav
fieldUid: d783368e-a494-4457-9e99-5a027ae72a18 # Page Header
instructions: null
label: null
required: false
Expand All @@ -36,7 +36,11 @@ fieldLayouts:
warning: null
width: 100
-
fieldUid: d783368e-a494-4457-9e99-5a027ae72a18 # Page Header
style: warning
tip: 'Any content blocks you add here will appear below the articles'
type: craft\fieldlayoutelements\Tip
-
fieldUid: 1d1d5665-5674-4388-8d46-9b87e4dc65d3 # Content Builder
instructions: null
label: null
required: false
Expand Down
5 changes: 4 additions & 1 deletion config/project/project.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
dateModified: 1667316143
dateModified: 1667484997
email:
fromEmail: $ADMIN_EMAIL
fromName: $SITE_NAME
Expand Down Expand Up @@ -146,6 +146,7 @@ plugins:
freeform:
edition: lite
enabled: true
licenseKey: K6IIQSJNRK5VJ92Y9GNE6CTK
schemaVersion: 3.6.4
settings:
ajaxByDefault: true
Expand Down Expand Up @@ -216,10 +217,12 @@ plugins:
navigation:
edition: standard
enabled: true
licenseKey: Z9SM7RIIEEH0EBHEWCC835VA
schemaVersion: 1.0.21
neo:
edition: standard
enabled: true
licenseKey: GLCZR55H2CE18QT7Y5WC2G3L
schemaVersion: 2.13.0
oembed:
edition: standard
Expand Down
13 changes: 6 additions & 7 deletions public/.htaccess
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
# RewriteRule ^(.*)$ https://www.websitedomain.com/$1 [L,R=301,NC]

# Redirect www to non www
# RewriteCond %{HTTP_HOST} ^www.websitedomain.com [NC]
# RewriteRule ^(.*)$ https://websitedomain.com/$1 [L,R=301]
# RewriteCond %{HTTP_HOST} ^www.websitedomain.com [NC]
# RewriteRule ^(.*)$ https://websitedomain.com/$1 [L,R=301]

# Send would-be 404 requests to Craft
RewriteCond %{REQUEST_FILENAME} !-f
Expand All @@ -16,9 +16,9 @@
RewriteRule (.+) index.php?p=$1 [QSA,L]

# Remove trailing slash from URL
# RewriteCond %{REQUEST_FILENAME} !-d
# RewriteCond %{REQUEST_URI} (.+)/$
# RewriteRule ^ %1 [R=301,L]
# RewriteCond %{REQUEST_FILENAME} !-d
# RewriteCond %{REQUEST_URI} (.+)/$
# RewriteRule ^ %1 [R=301,L]
</IfModule>

<IfModule mod_headers.c>
Expand Down Expand Up @@ -216,5 +216,4 @@ FileETag None

ExpiresByType text/x-cross-domain-policy "access plus 1 week"

</IfModule>

</IfModule>
93 changes: 47 additions & 46 deletions storage/setup-boilerplate/default_db.sql

Large diffs are not rendered by default.

10 changes: 5 additions & 5 deletions templates/_includes/_content-builder/_blocks/video.twig
Original file line number Diff line number Diff line change
Expand Up @@ -13,16 +13,16 @@
{% if vid.video.media.type == 'video' %}
{{ vid.video.render({
params: {
autoplay: 1,
controls: 0,
loop: 1,
mute: 1,
autoplay: 0,
controls: 1,
loop: 0,
mute: 0,
}
}) }}
{% endif %}
{% else %}
{% if vid.video.one %}
<video src="{{ vid.video.url }}" alt="{{ vid.video }}"></video>
<video src="{{ vid.video.url }}" alt="{{ vid.video }}" controls playsinline></video>
{% else %}
<video autoplay loop>
<source src="./img/video_placeholder.mp4">
Expand Down
2 changes: 1 addition & 1 deletion templates/_layout.twig
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<!DOCTYPE html>
<html lang="en-US">
<html lang="en-GB">
<head>
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta charset="utf-8" />
Expand Down
12 changes: 6 additions & 6 deletions templates/contact/index.twig
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,6 @@
{% include '_includes/_page-headers/_' ~ header.type.handle %}
{% endif %}

{% if entry.contentBuilder %}
{% for block in entry.contentBuilder.all() %}
{% include '_includes/_content-builder/_blocks/' ~ block.type.handle %}
{% endfor %}
{% endif %}

<div class="container contact-form">
<div class="row">
<div class="col-8">
Expand All @@ -23,4 +17,10 @@
</div>
</div>

{% if entry.contentBuilder %}
{% for block in entry.contentBuilder.all() %}
{% include '_includes/_content-builder/_blocks/' ~ block.type.handle %}
{% endfor %}
{% endif %}

{% endblock %}
1 change: 0 additions & 1 deletion templates/latest/_entry.twig
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
</h1>
</div>
<div class="col-12">
<h2>{{ entry.header }}</h2>
<div class="copy">{{ entry.copy }}</div>
</div>
</div>
Expand Down
8 changes: 4 additions & 4 deletions templates/latest/index.twig
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
{% if pageInfo.totalPages > 1 %}
<div class="row justify-content-center pagination-links pb-5">
{% if craft.app.request.absoluteUrl == pageInfo.firstUrl %}
<span class="px-2 text-grey">First page</span>
<span class="px-2">First page</span>
{% else %}
<a href="{{ pageInfo.firstUrl }}" class="px-2">First Page</a>
{% endif %}
Expand All @@ -49,7 +49,7 @@
<a href="{{ url }}" class="px-2">{{ page }}</a>
{% endfor %}

<span class="current text-grey px-2">{{ pageInfo.currentPage }}</span>
<span class="current px-2">{{ pageInfo.currentPage }}</span>

{% for page, url in pageInfo.getNextUrls(5) %}
<a href="{{ url }}" class="px-2">{{ page }}</a>
Expand All @@ -58,9 +58,9 @@
{% if pageInfo.nextUrl %}<a href="{{ pageInfo.nextUrl }}" class="px-2">Next Page</a>{% endif %}

{% if craft.app.request.absoluteUrl == pageInfo.lastUrl %}
<span class="px-2 text-grey">Last page</span>
<span class="px-2">Last page</span>
{% else %}
<a href="{{ pageInfo.lastUrl }}" class="px-2 text-navy">Last Page</a>
<a href="{{ pageInfo.lastUrl }}" class="px-2">Last Page</a>
{% endif %}
</div>
{% endif %}
Expand Down

0 comments on commit 1330ff8

Please sign in to comment.