Skip to content

Instantly share code, notes, and snippets.

Avatar

Chris Rebert cvrebert

View GitHub Profile
@cvrebert
cvrebert / survey.md
Last active Feb 18, 2021
Click and focus behavior across browsers & OSes
View survey.md

Test apparatus: http://jsfiddle.net/hRub4/

(Windows = Windows 8.1 desktop)

  • Windows Chrome 39
    • Button focuses on click and via keyboard tabbing
    • Anchor focuses on click and via keyboard tabbing
  • Windows Firefox 30.0
    • Button focuses on click and via keyboard tabbing
    • Anchor focuses on click and via keyboard tabbing
  • Windows Internet Explorer 11
@cvrebert
cvrebert / css_regression_testing.md
Last active Jan 8, 2021
Survey of screenshot-based CSS testing tools
View css_regression_testing.md

Currently considering https://github.com/webdriverio/webdrivercss


Core Goals:

  • Can test in up-to-date versions of all major browsers
  • Can test on up-to-date versions of all major OSes
  • Can test in IE9 (because Bootstrap v4 will support IE9+)
  • Don't want to have to setup/maintain our own cluster of VMs running all the necessary OSes (and all the versions of Windows)
  • Workflow for management of reference/baseline/norm screenshots
@cvrebert
cvrebert / wat.md
Last active Feb 11, 2016
HTML focus events
View wat.md
@cvrebert
cvrebert / build.log
Created Jan 5, 2016
HTML validator build log
View build.log
$ python ./build/build.py update dldeps build test
"git" submodule update --init
Submodule path 'jing-trang': checked out '35eb11b84a230ee4d7168f12f98a28bf40e940aa'
https://repo1.maven.org/maven2/com/ibm/icu/icu4j/54.1.1/icu4j-54.1.1.jar
https://repo1.maven.org/maven2/com/shapesecurity/salvation/1.0.3/salvation-1.0.3.jar
https://repo1.maven.org/maven2/commons-codec/commons-codec/1.10/commons-codec-1.10.jar
https://repo1.maven.org/maven2/commons-fileupload/commons-fileupload/1.3.1/commons-fileupload-1.3.1.jar
https://repo1.maven.org/maven2/commons-io/commons-io/2.4/commons-io-2.4.jar
https://repo1.maven.org/maven2/commons-logging/commons-logging/1.2/commons-logging-1.2.jar
https://repo1.maven.org/maven2/commons-logging/commons-logging/1.2/commons-logging-1.2-adapters.jar
View test.html
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="">
<meta name="author" content="">
<link rel="shortcut icon" href="../../assets/ico/favicon.ico">
@cvrebert
cvrebert / log.txt
Created Nov 7, 2015
Build transcript for libsass issue #1523
View log.txt
~/Downloads/tmp/sassc (master) $ make
/Applications/Xcode.app/Contents/Developer/usr/bin/make BUILD="static" -C /Users/chris/Downloads/tmp/libsass
mkdir lib
cc -Wall -O2 -DLIBSASS_VERSION="\"d188\"" -I /Users/chris/Downloads/tmp/libsass/include -stdlib=libc++ -fPIC -fPIC -c -o src/cencode.o src/cencode.c
c++ -Wall -O2 -DLIBSASS_VERSION="\"d188\"" -std=c++0x -I /Users/chris/Downloads/tmp/libsass/include -stdlib=libc++ -fPIC -fPIC -c -o src/ast.o src/ast.cpp
In file included from src/ast.cpp:1:
src/ast.hpp:2082:18: warning: expression with side effects will be evaluated despite being used as an operand to 'typeid' [-Wpotentially-evaluated-expression]
if (typeid(*(*this)[0]) == typeid(Type_Selector))
^
src/ast.hpp:2101:21: warning: expression with side effects will be evaluated despite being used as an operand to 'typeid' [-Wpotentially-evaluated-expression]
@cvrebert
cvrebert / bootstrapish.css
Created Oct 16, 2015
WebKit/Blink bug related to Bootstrap issue #17913
View bootstrapish.css
/*!
* Simplified from Bootstrap v3.3.5 (http://getbootstrap.com)
* Copyright 2011-2015 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
* normalize.css v3.0.3 | MIT License | github.com/necolas/normalize.css
*/
b,
strong {
font-weight: bold;
}
@cvrebert
cvrebert / pokecrack.py
Created Jan 19, 2012
So, I took CSE 127...
View pokecrack.py
#!/usr/bin/env python
# Background: http://cses.ucsd.edu/pokemon/ & http://cseweb.ucsd.edu/classes/fa11/cse127-a/
from urllib import urlopen, urlencode
url = "http://cses.ucsd.edu/pokemon/submitemail.php"
for n in range(1, 1000):
data = urlencode({"email":"YourUsernameHere@ucsd.edu", "pokemonid":str(n), "submit":"Catch!"})
f = urlopen(url, data)
result = f.read()
f.close()
print(result) # if you want
@cvrebert
cvrebert / balls_in_numbered_boxes_CVR.py
Created Sep 11, 2011
Refactored "recursive algorithm for balls in numbered boxes"
View balls_in_numbered_boxes_CVR.py
def balls_in_numbered_boxes(balls, box_sizes):
if not isinstance(balls, int):
raise TypeError("balls must be a non-negative integer.")
if balls < 0:
raise ValueError("balls must be a non-negative integer.")
box_sizes = list(box_sizes)
if not box_sizes:
raise ValueError("box_sizes must be a non-empty iterable.")
@cvrebert
cvrebert / gist:e453cf70678c7dce5a83
Created Aug 3, 2015
bootstrap-sass #941 counterexample
View gist:e453cf70678c7dce5a83
$ npm install bower grunt grunt-contrib-sass
<snipped successful installation>
$ ./node_modules/.bin/bower install bootstrap-sass
bower bootstrap-sass#* cached git://github.com/twbs/bootstrap-sass.git#3.3.4
bower bootstrap-sass#* validate 3.3.4 against git://github.com/twbs/bootstrap-sass.git#*
bower bootstrap-sass#* new version for git://github.com/twbs/bootstrap-sass.git#*
bower bootstrap-sass#* resolve git://github.com/twbs/bootstrap-sass.git#*
bower bootstrap-sass#* download https://github.com/twbs/bootstrap-sass/archive/v3.3.5.tar.gz
bower bootstrap-sass#* extract archive.tar.gz
bower bootstrap-sass#* resolved git://github.com/twbs/bootstrap-sass.git#3.3.5