Skip to content

Commit fe78d77

Browse files
author
Rafael Grigorian
committed
Fixed #73
1 parent e041fbd commit fe78d77

File tree

8 files changed

+97
-1
lines changed

8 files changed

+97
-1
lines changed

etc/csp_whitelist.xml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
<?xml version="1.0" ?>
2+
3+
<csp_whitelist
4+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
5+
xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Csp:etc/csp_whitelist.xsd" >
6+
<policies>
7+
<policy id="frame-src">
8+
<values>
9+
<value id="jetrails" type="host" >magento-cloudflare.jetrails.com</value>
10+
<value id="youtube" type="host" >www.youtube.com</value>
11+
</values>
12+
</policy>
13+
<policy id="img-src">
14+
<values>
15+
<value id="youtube-cdn" type="host" >*.ytimg.com</value>
16+
</values>
17+
</policy>
18+
</policies>
19+
</csp_whitelist>

view/adminhtml/templates/dashboard.phtml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,8 +63,15 @@
6363
<span>&#xF013;</span><span>Scrape Shield</span>
6464
</li>
6565
<?php endif ?>
66+
<li data-tab="hosting" >
67+
<svg viewBox="100 100 300 300"><defs/><g fill="#FFF"><path d="M102 209.2v-15.7a2 2 0 012.8-2L205.5 240c.8.4 1.2 1 1.2 2v17.5c0 .8-.4 1.4-1.2 1.8l-100.7 48.4a2 2 0 01-2.8-1.8V292c0-.8.4-1.4 1.2-1.8l79.4-37.6a2 2 0 000-3.6l-79.4-38a2 2 0 01-1.2-2.1v.2zM255 311v-98.6c0-1.2-.8-2-2-2H229a2 2 0 01-2-2v-16.1c0-1.2.8-2 2-2h44.3c1.2 0 2 .8 2 2V311a40.4 40.4 0 01-40.3 40.2h-26.2a2 2 0 01-2-2v-16c0-1.3.8-2 2-2H235c11.1 0 20.1-9.1 20.1-20.2zm0-161h18.2c1.2 0 2 .8 2 2v16.1c0 1.2-.8 2-2 2H255a2 2 0 01-2-2v-16c0-1.3.8-2.1 2-2.1zM400 293v16c0 1.3-.8 2-2 2H297.3a2 2 0 01-2-2v-16c0-1.3.8-2 2-2H398c1.2 0 2 .7 2 2z"/></g></svg>
68+
<span>Magento Hosting</span>
69+
</li>
6670
</ul>
6771
<div class="content-wrapper" >
72+
<div class="content" data-target="hosting" >
73+
<?php echo $block->getTabContent ("hosting") ?>
74+
</div>
6875
<div class="content" data-target="overview" >
6976
<?php echo $block->getTabContent ("overview") ?>
7077
</div>
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
<h1 class="tab-content" >Magento Hosting</h1>
2+
<h2 class="tab-content" >Single Tenant Magento Environment Architected For Your Store</h2>
3+
<?php
4+
5+
echo $block->renderSections ( "hosting", array ( "main", "cta-tom", "cta-robert" ) );
6+
7+
?>
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
<section
2+
class="cloudflare hosting cta-robert"
3+
data-endpoint="<?php echo $block->getApiEndpoint () ?>"
4+
data-form-key="<?php echo $block->getFormKey () ?>"
5+
data-tab-name="hosting"
6+
data-section-name="cta-robert" >
7+
<div class="row" >
8+
<div class="wrapper_left" >
9+
<span class="section_title" >Schedule A Meeting With <u>Robert</u>!</span>
10+
<p>Discuss partnership opportunities.</p>
11+
</div>
12+
<div class="wrapper_right" >
13+
<div>
14+
<input type="button" value="Schedule Meeting" onClick="window.open ('https://meetings.hubspot.com/robert-r','_blank')" />
15+
</div>
16+
</div>
17+
</div>
18+
</section>
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
<section
2+
class="cloudflare hosting cta-tom"
3+
data-endpoint="<?php echo $block->getApiEndpoint () ?>"
4+
data-form-key="<?php echo $block->getFormKey () ?>"
5+
data-tab-name="hosting"
6+
data-section-name="cta-tom" >
7+
<div class="row" >
8+
<div class="wrapper_left" >
9+
<span class="section_title" >Schedule A Meeting With <u>Tom</u>!</span>
10+
<p>Discuss your Magento hosting challenges with an expert.</p>
11+
</div>
12+
<div class="wrapper_right" >
13+
<div>
14+
<input type="button" value="Schedule Meeting" onClick="window.open ('https://calendly.com/tom-p','_blank')" />
15+
</div>
16+
</div>
17+
</div>
18+
</section>
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
<section
2+
class="cloudflare hosting main"
3+
data-endpoint="<?php echo $block->getApiEndpoint () ?>"
4+
data-form-key="<?php echo $block->getFormKey () ?>"
5+
data-tab-name="hosting"
6+
data-section-name="main" >
7+
<div class="row" >
8+
<div class="wrapper_left" >
9+
<span class="section_title" >Ready For Better Magento Hosting?</span>
10+
<p>Did you know that JetRails can configure, optimize, monitor, and manage, your Cloudflare account, along with malware scanners, intrusion detection systems, off-server backups, caching layers, and more! It’s all part of JetRails mission-critical hosting services!</p>
11+
<center>
12+
<iframe width="95%" height="400" src="https://magento-cloudflare.jetrails.com" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>
13+
</center>
14+
</div>
15+
</div>
16+
</section>

view/adminhtml/web/bundle/scss/index.css

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

view/adminhtml/web/scss/core/dashboard.scss

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -129,6 +129,17 @@ div.cloudflare-dashboard {
129129
cursor: pointer;
130130
background: #FFF;
131131
transition: all 200ms;
132+
svg:nth-child( 1 ) {
133+
margin: 7.5px 20px;
134+
height: 50px;
135+
width: 50px;
136+
background: #2c7cb0;
137+
border-radius: 5px;
138+
line-height: 50px;
139+
text-align: center;
140+
padding: 8px;
141+
box-sizing: border-box;
142+
}
132143
span:nth-child( 1 ) {
133144
font-family: "cloudflare-font", sans-serif;
134145
font-style: normal;

0 commit comments

Comments
 (0)