Skip to content

Instantly share code, notes, and snippets.

@cafe4it
cafe4it / background.js
Created May 2, 2023 14:59
background.js
function e(e, t) {
for (const o of e.requestHeaders) if (o.name === t) return o.value;
}
chrome.runtime.onInstalled.addListener(function () {
chrome.storage.sync.get(["SETTINGS"], function (e) {
e.SETTINGS ||
chrome.storage.sync.set({
SETTINGS: {
reviewPages: 1,
isDownloadReviewVideo: !1,
// {"framework" : "Rax"}
define("pages/index/index", function (e) {
! function (e) {
var t = {};
function r(n) {
if (t[n]) return t[n].exports;
var o = t[n] = {
i: n,
l: !1,
@cafe4it
cafe4it / w3.css
Created January 5, 2017 02:25
w3.css
/* W3.CSS 2.85 Jan 2017 by Jan Egil and Borge Refsnes */
html{box-sizing:border-box}*,*:before,*:after{box-sizing:inherit}
/* Extract from normalize.css by Nicolas Gallagher and Jonathan Neal git.io/normalize */
html{-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%}body{margin:0}
article,aside,details,figcaption,figure,footer,header,main,menu,nav,section,summary{display:block}
audio,canvas,progress,video{display:inline-block}progress{vertical-align:baseline}
audio:not([controls]){display:none;height:0}[hidden],template{display:none}
a{background-color:transparent;-webkit-text-decoration-skip:objects}
a:active,a:hover{outline-width:0}abbr[title]{border-bottom:none;text-decoration:underline;text-decoration:underline dotted}
dfn{font-style:italic}mark{background:#ff0;color:#000}
@cafe4it
cafe4it / code.txt
Created September 15, 2016 01:50
ga conversion
<!-- Google Code for Fair 09-2016 Conversion Page -->
<script type="text/javascript">
/* <![CDATA[ */
var google_conversion_id = 1017172282;
var google_conversion_language = "en";
var google_conversion_format = "3";
var google_conversion_color = "ffffff";
var google_conversion_label = "f4XPCPLbkWoQuqKD5QM";
var google_remarketing_only = false;
/* ]]> */
@cafe4it
cafe4it / cssParser.min.js
Created September 9, 2016 08:14
cssParser.min.js
function ParseURL(a){var b={};b.protocol="",b.user="",b.password="",b.host="",b.port="",b.path="",b.query="";for(var c="PROTOCOL",d=0,e=!1;d<a.length;)if("PROTOCOL"==c)":"==a.charAt(d)?(c="AFTER_PROTOCOL",d++):"/"==a.charAt(d)&&0==b.protocol.length()?c=PATH:b.protocol+=a.charAt(d++);else if("AFTER_PROTOCOL"==c){if("/"!=a.charAt(d))throw new ParseException("Protocol shell be separated with 2 slashes");e?(e=!1,c="USER"):e=!0,d++}else"USER"==c?"/"==a.charAt(d)?(b.host=b.user,b.user="",c="PATH"):"?"==a.charAt(d)?(b.host=b.user,b.user="",c="QUERY",d++):":"==a.charAt(d)?(c="PASSWORD",d++):"@"==a.charAt(d)?(c="HOST",d++):b.user+=a.charAt(d++):"PASSWORD"==c?"/"==a.charAt(d)?(b.host=b.user,b.port=b.password,b.user="",b.password="",c="PATH"):"?"==a.charAt(d)?(b.host=b.user,b.port=b.password,b.user="",b.password="",c="QUERY",d++):"@"==a.charAt(d)?(c="HOST",d++):b.password+=a.charAt(d++):"HOST"==c?"/"==a.charAt(d)?c="PATH":":"==a.charAt(d)?(c="PORT",d++):"?"==a.charAt(d)?(c="QUERY",d++):b.host+=a.charAt(d++):"PORT"==c?"/
@cafe4it
cafe4it / index.js
Last active October 14, 2022 14:16
[Bookmarklet] for Chrome Extension [Super Simple Highlighter] printing color
var importScript = (function(oHead) {
function loadError(oError) {
throw new URIError("The script " + oError.target.src + " is not accessible.");
}
return function(sSrc, fOnload) {
var oScript = document.createElement("script");
oScript.type = "text\/javascript";
oScript.onerror = loadError;
if (fOnload) {

Cô giáo thảo

Em cô giáo thuỷ

Chị cô giáo Lan

Xin chào các cô giáo

<!DOCTYPE html>
<html>
<head>
<title>Công Ty TNHH Xuất Nhập Khẩu Asian!</title>
<meta charset="UTF-8">
<style>
body {
width: 35em;
margin: 0 auto;
font-family: Tahoma, Verdana, Arial, sans-serif;
function throttle(fn, threshhold, scope) {
threshhold || (threshhold = 250);
var last,
deferTimer;
return function () {
var context = scope || this;
var now = +new Date,
args = arguments;
if (last && now < last + threshhold) {
@cafe4it
cafe4it / gist:0ccd19ddb566e690923a
Created August 27, 2015 18:46
Tumblr auto follow people
Requirement :
Chrome, firefox : addon : Jquerify
-------------------------------
Tumblr search window:
Open Chrome Console (Ctrl+Shift+I, tab Console)
Click Jquerify addon
Paste script bellow and enter.
$('a:not(.is-following).follow_link').each(function(i){$(this).delay(2000)[0].click()})