Skip to content

Instantly share code, notes, and snippets.

View korrio's full-sized avatar
👽

kOrriO korrio

👽
View GitHub Profile
@korrio
korrio / BOOKING-FLOWCHART.md
Created March 17, 2026 17:37
BOOKING-FLOWCHART.md

Court Booking Availability Flowchart

Overview

This document describes the complete flow of how the court booking system checks and manages court availability across single courts (DUNE, GLACIER) and combined courts (CONNECTED COURTS).

Architecture

┌─────────────────────────────────────────────────────────────────────────────┐
│                         AVAILABILITY CHECK FLOW                              │
@korrio
korrio / PLAN.md
Created January 13, 2026 09:37
LINE MINI App Planning Overview

LINE MINI App Planning Overview

Sportclub CNX Court Booking Platform

Document Version: 1.0 Date: January 2026 Status: Planning Document


Table of Contents

@korrio
korrio / undo-redo-miracle.md
Created December 17, 2025 14:27
undo-redo-miracle.md

Undo/Redo System Documentation

Overview

The Brand New 20-Step Undo/Redo System is a high-performance circular buffer implementation that replaces the previous 50-step system. It features automatic state saving, thumbnail generation, and an integrated visual history stack in the Layer drawer.


Core Files

1. /lib/hooks/useUndoRedo.ts

@korrio
korrio / ads-gone.js
Created October 7, 2025 05:36
ads-gone.js
// Hide images in ad containers
document.querySelectorAll('[class*="ad"], [id*="ad"], [class*="banner"], [id*="banner"]').forEach(el => {
el.querySelectorAll('img').forEach(img => {
img.style.display = 'none';
});
});
// Also hide images with ad-related attributes
document.querySelectorAll('img').forEach(img => {
const allText = (img.src + img.alt + img.className + img.id).toLowerCase();
@korrio
korrio / FoomFakApp.tsx
Created July 15, 2025 14:08
FoomFakApp.tsx (not yet typescriptify)
import React, { useState, useEffect } from 'react';
import { Play, Pause, Square, Clock, QrCode, User, Store, Gift, Star, Check, X, Menu, Home, History, Settings, Baby, BookOpen, Mic, Timer, Users, ShoppingCart, Camera, UserCheck } from 'lucide-react';
const FoomFakApp = () => {
const [currentUser, setCurrentUser] = useState<any>(null);
const [activeTab, setActiveTab] = useState('home');
const [showLogin, setShowLogin] = useState(false);
const [showRegister, setShowRegister] = useState(false);
const [showQRScanner, setShowQRScanner] = useState(false);
const [showStoryReader, setShowStoryReader] = useState(false);
@korrio
korrio / SelfSellingNFT.sol
Created July 12, 2025 06:07
SelfSellingNFT
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.19;
import "@openzeppelin/contracts/token/ERC721/ERC721.sol";
import "@openzeppelin/contracts/access/Ownable.sol";
import "@openzeppelin/contracts/security/ReentrancyGuard.sol";
contract SelfSellingNFT is ERC721, Ownable, ReentrancyGuard {
uint256 private _tokenIdCounter;
@korrio
korrio / optimize.js
Created June 11, 2025 04:25
Transaction size optimization techniques summary
const {
Connection,
PublicKey,
Keypair,
Transaction,
TransactionMessage,
VersionedTransaction,
AddressLookupTableAccount,
ComputeBudgetProgram,
SystemProgram,
@korrio
korrio / swap_meteora.js
Created June 11, 2025 04:05
swap at meteora dex on solana with lookup table
const {
Connection,
PublicKey,
Keypair,
Transaction,
TransactionMessage,
VersionedTransaction,
AddressLookupTableAccount,
ComputeBudgetProgram,
} = require('@solana/web3.js');
@korrio
korrio / kanit.js
Created April 26, 2025 06:15
kanit.js
// นำเข้า Google Font Kanit
let fontLink = document.createElement('link');
fontLink.href = 'https://fonts.googleapis.com/css2?family=Kanit:wght@300;400;500;700&display=swap';
fontLink.rel = 'stylesheet';
document.head.appendChild(fontLink);
// สร้าง style element ใหม่
let styleElement = document.createElement('style');
styleElement.textContent = `
* {
@korrio
korrio / main.py
Created April 18, 2025 04:56
main.py
# LangChain Blockchain Analysis MVP with Claude in Python
# This application analyzes blockchain transactions and provides natural language insights using LangChain with Claude
# Required dependencies
from langchain_anthropic import ChatAnthropic
from langchain.prompts import PromptTemplate
from langchain.chains import LLMChain
from langchain.tools import Tool
from langchain.agents import initialize_agent, AgentType
from web3 import Web3