JavaScript preprocessors can help make authoring JavaScript easier and more convenient. For instance, CoffeeScript can help prevent easy-to-make mistakes and offer a cleaner syntax and Babel can bring ECMAScript 6 features to browsers that only support ECMAScript 5.
Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.
You can apply a script from anywhere on the web to your Pen. Just put a URL to it here and we'll add it, in the order you have them, before the JavaScript in the Pen itself.
If the script you link to has the file extension of a preprocessor, we'll attempt to process it before applying.
You can also link to another Pen here, and we'll pull the JavaScript from that Pen and include it. If it's using a matching preprocessor, we'll combine the code before preprocessing, so you can use the linked Pen as a true dependency.
HTML Settings
Here you can Sed posuere consectetur est at lobortis. Donec ullamcorper nulla non metus auctor fringilla. Maecenas sed diam eget risus varius blandit sit amet non magna. Donec id elit non mi porta gravida at eget metus. Praesent commodo cursus magna, vel scelerisque nisl consectetur et.
<a href="javascript:void(0)" id="shareModalBtn">Share this article</a>
<div class="container">
<div class="shareModal socialShare modal">
<div class=" [ col--lap-10 col--desk-10 ]">
<div class="modal-content">
<span class="close">×</span>
<h2 class="title-xl mb-s">Share this article</h2>
<p class="m">Have you read something you think others need to know?<br>
<span class="s">Simply use the buttons below to share on your social network.</span>
</p>
<a id="twitterShareIEFF" style="display:inline-block" onclick="ga('send', 'event', 'Share', 'article-footer-social-twi', window.location.href);" href="#" data-modal-title="Modal Title" data-modal-description="Modal Description" data-twitter-label="Share on Twitter" data-twitter-text=""></a>
<iframe id="twitter-widget-0" scrolling="no" frameborder="0" allowtransparency="true" class="twitter-share-button twitter-share-button-rendered twitter-tweet-button" title="Twitter Tweet Button" src="https://platform.twitter.com/widgets/tweet_button.36c0c29c73929bf937f4c70adb1a29e4.en.html#dnt=false&id=twitter-widget-0&lang=en&original_referer=https%3A%2F%2Fmental-health-and-money.s1.umbraco.io%2Fen%2Fadvice-topics%2Fmental-health-care-treatment%2Fwhere-can-i-get-support-for-my-mental-health%2Foverview%2F&size=l&text=Overview%20%3A%20Mental%20Health%20%26%20Money%20Advice&time=1518695143649&type=share&url=https%3A%2F%2Fwww.mentalhealthandmoneyadvice.org%2Fen%2Fadvice-topics%2Fmental-health-care-treatment%2Fwhere-can-i-get-support-for-my-mental-health%2Foverview%2F" style="position: static; visibility: visible; width: 76px; height: 28px;"></iframe>
<script>window.twttr = (function(d, s, id) {
var js, fjs = d.getElementsByTagName(s)[0],
t = window.twttr || {};
if (d.getElementById(id)) return t;
js = d.createElement(s);
js.id = id;
js.src = "https://platform.twitter.com/widgets.js";
fjs.parentNode.insertBefore(js, fjs);
t._e = [];
t.ready = function(f) {
t._e.push(f);
};
return t;
}(document, "script", "twitter-wjs"));</script>
<p>Share this article on Twitter</p>
</div>
</div>
</div>
</div>
.modal {
display: none; /* Hidden by default */
position: fixed; /* Stay in place */
z-index: 100; /* Sit on top */
left: 0;
top: 0;
width: 100%; /* Full width */
height: 100%; /* Full height */
overflow: auto; /* Enable scroll if needed */
background-color: rgba($color-primary, 0.85); /* Black w/ opacity */
}
var shareModalBtn = $('#shareModalBtn');
var shareModal = $('.shareModal');
$(shareModalBtn).on( "click", function() {
shareModal.show();
});
Also see: Tab Triggers