Skip to content

Instantly share code, notes, and snippets.

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

Vincent Tang vincentntang

💭
¯\_(ツ)_/¯
View GitHub Profile
@vincentntang
vincentntang / Canvas.js
Last active December 17, 2018 18:25
Part 1 of canvas
var canvas = document.querySelector("canvas");
canvas.width = window.innerWidth;
canvas.height = window.innerHeight;
canvas.width = 1600;
canvas.height = 800;
var ctx = canvas.getContext("2d");
@vincentntang
vincentntang / center-the-position.markdown
Created November 20, 2018 16:54
Center the position
@vincentntang
vincentntang / index.pug
Created October 26, 2018 03:15
Simple Pure CSS Mega Menu
.nav-wrapper
.nav
each val in [1, 2, 3, 4, "Good Bye"]
.dropdown
a Category
.megamenu
p= val
p Hello World
var myVar = setTimeout(myTimer, 2000);
function myTimer() {
// https://worldmap.harvard.edu/data/geonode:country_centroids_az8
console.log("Hello world123123");
var randomIndex = getRandomInt(193);
vtLong = jsonRandom[randomIndex].Longitude;
vtLat = jsonRandom[randomIndex].Latitude;
vtCountry = jsonRandom[randomIndex].country;
@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 +
/* 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 / flexbox-hide-overflow-child-elements-pt3.markdown
Last active July 11, 2018 17:50
Flexbox Hide Overflow Child Elements Pt3
@vincentntang
vincentntang / flexbox-hide-overflow-child-elements-pt2.markdown
Created July 11, 2018 17:28
Flexbox Hide Overflow Child Elements Pt2
@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 / 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.