Skip to content

Instantly share code, notes, and snippets.

View ydrea's full-sized avatar
💭
innit :D

Andrija Vranic ydrea

💭
innit :D
View GitHub Profile
@ydrea
ydrea / thumbnailer.py
Created May 21, 2025 00:30 — forked from aarongundel/thumbnailer.py
Arches Simple Thumbnailer
from PIL import Image
import filetype
class SimpleThumbnailer(ThumbnailGenerator):
IMAGES = (
'png', 'jpg', 'jpeg', 'jpe', 'gif', 'bmp', 'dib', 'dcx',
'eps', 'ps', 'im', 'pcd', 'pcx', 'pbm', 'pbm', 'ppm',
'psd', 'tif', 'tiff', 'xbm', 'xpm',
)
def make_thumbnail(self, inputfile_path, outputfile_path, **kwargs):
@ydrea
ydrea / unimap.tsx
Created March 27, 2025 11:33
react-native-maps + @teovilla/react-native-web-maps
import React from 'react';
import { Platform, StyleProp, ViewStyle } from 'react-native';
// Native types
import type {
MapViewProps as NativeMapViewProps,
Marker as NativeMarker,
Region,
LatLng,
} from 'react-native-maps';
@ydrea
ydrea / L.TileLayer.BetterWMS.js
Created November 10, 2024 22:08
BetterWMS + HTML popups
//https://gist.github.com/rclark/6908938?permalink_comment_id=4749563#gistcomment-4749563
// with thumbs
showGetFeatureInfo: function (
err,
latlng,
content
// signaturaFromUrl
) {
if (err) {