Skip to content

Instantly share code, notes, and snippets.

View vincentntang's full-sized avatar
💭
¯\_(ツ)_/¯

Vincent Tang vincentntang

💭
¯\_(ツ)_/¯
View GitHub Profile
@vincentntang
vincentntang / script.js
Created June 23, 2018 03:41
Tamperscript Injection Pt2
// INJECTING THE HTML
document.querySelector('body').innerHTML += '<div id="injection">Hello World</div>';
// CSS INJECTION FUNCTION
//https://stackoverflow.com/questions/707565/how-do-you-add-css-with-javascript
function insertCss( code ) {
var style = document.createElement('style');
style.type = 'text/css';
if (style.styleSheet) {
// IE
@vincentntang
vincentntang / css-mega-menu-dropdown-navigation-responsive-pt4.markdown
Last active July 19, 2018 20:21
CSS Mega Menu Dropdown Navigation Responsive Pt4

CSS Mega Menu Dropdown Navigation Responsive Pt4

Megadropdown menu with selfexplanatory CSS Used in corporate and ecommerce sites normally Explained as simply as possible with as few styles and HTML markup. Uses flexbox

Based on https://designmodo.com/create-css3-mega-menu/

@vincentntang
vincentntang / hamburger-menu-css-with-animation.markdown
Last active September 17, 2018 23:29
Hamburger Menu CSS with Animation
@vincentntang
vincentntang / css-hamburger-drawer-menu-jquery-jade-variant.markdown
Created July 5, 2018 03:26
CSS Hamburger Drawer Menu - Jquery/Jade Variant
@vincentntang
vincentntang / hover-textbox-overflow.markdown
Last active July 9, 2018 20:00
Hover Textbox Overflow

Hover Textbox Overflow

A demonstration of how to overflow box grid layouts

Hover over a rubberducky box to see the results

Uses a combination of hover, :before pseudoselectors, specific right and bottom borders.

A Pen by Vincent Tang on CodePen.

@vincentntang
vincentntang / hover-textbox-overflow-pt2.markdown
Last active July 9, 2018 21:02
Hover Textbox Overflow Pt2

Hover Textbox Overflow Pt2

A demonstration of how to overflow box layouts

Pt2 demonstrates how you can overclip a partial text to resize the entire box

Uses a combination of hover, :before pseudoselectors, specific right and bottom borders.

A Pen by Vincent Tang on CodePen.

@vincentntang
vincentntang / flexbox-hide-overflow-child-elements-pt2.markdown
Created July 11, 2018 17:28
Flexbox Hide Overflow Child Elements Pt2
@vincentntang
vincentntang / flexbox-hide-overflow-child-elements-pt3.markdown
Last active July 11, 2018 17:50
Flexbox Hide Overflow Child Elements Pt3
/* Remove all Vertical lines except first 1 in current view */
.Node.is-currentRoot .Node .Node > .Node-children {
border-left: 0px !important;
}
/* Make Remaining Lines Green */
.Node.is-currentRoot .Node .Node-children {
border-left: 1px dotted green !important;
}
/* Hide All Bulletpoints (1st and 2nd in current view) */
@vincentntang
vincentntang / index.pug
Created August 4, 2018 17:20
Multiple Button Counters
- for (var x = 0; x < 13; x++)
.qty-holder
button.qty-dec -
input(type="number" value="1").qty-adj
button.qty-inc +