Skip to content

Instantly share code, notes, and snippets.

View SeePetulaCode's full-sized avatar
🎯
Focusing.... trying to? *lol*

Petula Pascall SeePetulaCode

🎯
Focusing.... trying to? *lol*
View GitHub Profile
@johnematias
johnematias / No Code Membership Demo Mark As Complete
Last active August 31, 2022 19:36 — forked from mackenziechild/No Code Membership Demo Mark As Complete
This will add meta data to the member profile in Memberstack which allows us to hide or show the mark as complete form.
<script src="https://api.memberstack.io/static/memberstack.js?webflow" data-memberstack-id="GET_FROM_MEMBERSTACK"></script>
<script>
MemberStack.onReady.then(async function(member) {
// Checks if member is logged in
if(member.loggedIn){
const metadata = await member.getMetaData();
// If no metadata.liked_topics exists, create it in MemberStack.
* {
background: #000 !important;
color: #0f0 !important;
outline: solid #f00 1px !important;
}
@Torthu
Torthu / svgGetAbsolutePosition.coffee
Created January 30, 2015 14:57
Get absolute position (from 0,0) for a SVG element
# Find the position of a SVG DOM element
getPosition = (element) ->
# We have a transform, that might contain a translate(x,y)
transform = element.getAttribute('transform')
if transform?
match = transform.match(/translate\(\s*(-?[\d.]*)\s*[,]\s*(-?[\d.]*)\s*/)
# We have translate(x,y)
if match?.length >= 2
@yckart
yckart / jquery.addrule.js
Last active December 29, 2022 12:16
Add css-rules to an existing stylesheet - http://stackoverflow.com/a/16507264/1250044
/*!
* jquery.addrule.js 0.0.2 - https://gist.github.com/yckart/5563717/
* Add css-rules to an existing stylesheet.
*
* @see http://stackoverflow.com/a/16507264/1250044
*
* Copyright (c) 2013 Yannick Albert (http://yckart.com)
* Licensed under the MIT license (http://www.opensource.org/licenses/mit-license.php).
* 2013/11/23
**/