Skip to content

Instantly share code, notes, and snippets.

@devatrox
devatrox / README.md
Last active August 21, 2022 05:13
Scriptable Store Availability Checker

Scriptable Store Availability Checker

This Scriptable Widget checks regularly if a product in different stores is available and displays it in the Widget

Change productName, urls and search strings in the array below to fit your needs. The searchString is the text to look for if the product is NOT available! Unfortunately this doesn't work if the searched element is dynamically generated on load because the script does not execute Javascript

@devatrox
devatrox / state.scss
Created April 4, 2018 06:53
Useful Sass mixins
@mixin state($states...) {
$list: ();
$selectors: ();
$FULL_STATES: (
'none': (''),
'active': (':active', '.active'),
'hover': (':hover'),
'focus': (':focus', '.focus'),
'visited': (':visited'),
$.fn.clickToggle = function(a,b){
return this.each(function(){
var clicked = false;
$(this).bind('click',function(){
if (clicked) {
clicked = false;
return b.apply(this,arguments);
}
clicked = true;
return a.apply(this,arguments);
@devatrox
devatrox / selection.scss
Last active January 4, 2016 08:39
::selection prefix mixin
@mixin selection {
::-moz-selection {
@content;
}
::selection {
@content;
}
}