Skip to content

Instantly share code, notes, and snippets.

View KogaNoodle's full-sized avatar
🏠
Working from home

Marcos Vinícius Koga e Silva KogaNoodle

🏠
Working from home
View GitHub Profile
@KogaNoodle
KogaNoodle / FuralityFriendsCompactMode.css
Last active June 8, 2025 20:24
Furality Friends Compact Mode CSS override
.container > div > div:nth-child(2) {
--gap-size: 1rem;
display: flex;
gap: var(--gap-size);
flex-wrap: wrap;
}
.container .card {
flex-basis: calc(33.333% - var(--gap-size));
@KogaNoodle
KogaNoodle / flashbang.js
Last active July 14, 2022 03:36
Flashbang HTML Overlay
// Get config from import params
const url = new URL(import.meta.url);
const config = {
rewardTitle: url.searchParams.get('rewardTitle'),
// imageUrl: url.searchParams.get('imageUrl'),
seconds: Number(url.searchParams.get('seconds')) || 5 // default to 5 seconds
}
// Will subscribe to these events, mapped directly to the websocket subscription request.
window.streamerbot.subscribeTo({
@KogaNoodle
KogaNoodle / NXsmoothScroll.ts
Last active June 15, 2018 19:35
Smooth scroll with fragments on Angular 5
constructor(public router: Router) {
this.router.events.subscribe(event => {
if (event instanceof NavigationEnd) {
const fragment = router.parseUrl(router.url).fragment;
if (fragment) {
const element = document.getElementById(fragment);
if (element) {
element.scrollIntoView({
behavior: 'smooth',
block: 'start',

Keybase proof

I hereby claim:

To claim this, I am signing this object:

@KogaNoodle
KogaNoodle / CardFlip.scss
Created October 29, 2013 17:52
Style for a 3D flipping card
/*
* Card
*/
.card {
position: relative;
display: inline-block;
width: 100px;
height: 75px;
-webkit-perspective: 800px;
@KogaNoodle
KogaNoodle / chart.js
Created February 14, 2013 15:57
RaphaëlJS custom box element. (plugin) WIP
(function() {
Raphael.fn.entityBox = function ( text, position, size ) {
text = text.trim()
var textElement = this.text(0, 0, text).attr({
'fill': 'transparent',
'stroke': 'transparent',
'font-family': 'Verdana',
'font-size': '14pt'
@KogaNoodle
KogaNoodle / strFormatter.js
Last active December 11, 2015 10:18
String formatter
jQuery.fn.format = function( str, element ) {
/* ======================================================================= *
* Format a string: Merge the STR with the ELEMENT, replacing the
* placeholders with the values in the array.
*
* Parameters:
*
* - STR: Array of values to be inserted on the result string
* - ELEMENT: The string template with placeholders
@KogaNoodle
KogaNoodle / syncDropboxFiles.py
Created September 26, 2012 16:54
Sync files from a shared link to a local folder [WIP]
import urllib2, re
print( 'Getting data...' )
data = urllib2.urlopen( 'https://www.dropbox.com/sh/8lrs3pausdpk1ic/w22Hb-Mgc2' )
rOlPattern = re.compile(r'<a href="https://www.dropbox.com/sh/[A-z0-9:/%\?\-\.\_ ]+?\..{3}" target="_top" class="filename-link".+?/a>', re.M | re.I )
rUrlPattern = re.compile( r'https://www.dropbox.com/sh/[A-z0-9:/%\?\-\.\_ ]+?\..{3}' )
print( 'Parsing data...' )
rTitlePattern = re.compile( r'[A-z 0-9\-\=\+\.\?\$\%]+?' )
@KogaNoodle
KogaNoodle / HTMLgenerator.js
Created August 23, 2012 17:32
A simple html generator from some XML file
$.ajax({
type: 'GET',
url: //SomeXML
dataType: 'xml',
success: function(xml) {
ContentRenderer($(xml).find('main > content'), $("#content"))
},
error: function(data) {
console.debug("Fail:"+data.status)
console.debug("Fail:"+data.statusText)