This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Snippet: [[SnippetName]] | |
| Chunk: [[$ChunkName]] | |
| System Setting: [[++SettingName]] | |
| TV: [[*fieldName/TvName]] | |
| Link tag: [[~PageId? ¶mName=`value`]] | |
| Placeholder: [[+PlaceholderName]] | |
| <?php |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* | |
| This .scss loop will create "margin helpers" and "padding helpers" for use in your web projects. | |
| It will generate several classes such as: | |
| .m-r-10 which gives margin-right 10 pixels. | |
| .m-r-15 gives MARGIN to the RIGHT 15 pixels. | |
| .m-t-15 gives MARGIN to the TOP 15 pixels and so on. | |
| .p-b-5 gives PADDING to the BOTTOM of 5 pixels | |
| .p-l-40 gives PADDING to the LEFT of 40 pixels |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/sh | |
| git --no-pager log -n 20 --graph --pretty=format:'%Cred%h%Creset %an: %s - %Creset %C(yellow)%d%Creset %Cgreen(%cr)%Creset' --abbrev-commit --date=relative |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Determine if an element is in the visible viewport | |
| function isInViewport(element) { | |
| var rect = element.getBoundingClientRect(); | |
| var html = document.documentElement; | |
| return ( | |
| rect.top >= 0 && | |
| rect.left >= 0 && | |
| rect.bottom <= (window.innerHeight || html.clientHeight) && | |
| rect.right <= (window.innerWidth || html.clientWidth) | |
| ); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // adds ios class to html tag | |
| jQuery(document).ready(function($){ | |
| var deviceAgent = navigator.userAgent.toLowerCase(); | |
| var agentID = deviceAgent.match(/(iphone|ipod|ipad)/); | |
| if (agentID) { | |
| $('html').addClass('ios'); | |
| } | |
| }); |