radio
├── Radio.jsx
├── Radio.scss
├── RadioSpec.jsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Available variables: | |
// - Machine | |
// - interpret | |
// - assign | |
// - send | |
// - sendParent | |
// - spawn | |
// - raise | |
// - actions |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const loggedInState = { | |
initial: 'idle', | |
states: { | |
idle: { | |
on: { | |
load: 'loading' | |
} | |
}, | |
loading: { | |
invoke: { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const wizardStates = { | |
initial: "date", | |
states: { | |
date: { | |
on: { | |
NEXT: "flight" | |
} | |
}, | |
flight: { | |
on: { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Copy-Paste this Chart into the visualizer: https://statecharts.github.io/xstate-viz/ | |
// Available variables: | |
// Machine (machine factory function) | |
// XState (all XState exports) | |
const { assign } = XState.actions; | |
const fightStates = { | |
initial: "fightOrRun", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# This script helps to restore important files after someone acidentially | |
# ran `git reset --hard` before any commit have been made. `git reflog` | |
# can´t help you in such cases, because it needs at least one commit | |
# You can only restore files via this approach, if the files have been | |
# added with `git add` before the reset was executed! If that was not the | |
# case, then I have bad news for you: This won´t work :( |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const cssText = ` | |
[data-qa] { | |
outline: 1px solid #E91E63 !important; | |
} | |
[data-qa]:hover { | |
outline: 2px solid #E91E63 !important; | |
} | |
[data-qa]:hover:before { | |
display: block; | |
white-space: nowrap; |
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
See https://gist.github.com/kevin-smets/8568070
A good guide from github is here
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env ruby | |
# A script to create a review on crucible based on the current git branch | |
# | |
# To configure settings, create a file named .code-review in your home directory | |
# The format should be: | |
# ------------------------------------------------------------------------------ | |
# crucible: | |
# url: <crucible url> | |
# username: <username> | |
# password: <password> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import sys | |
if len(sys.argv) < 2: | |
print 'Usage: python {} webfont-file.svg'.format(sys.argv[0]) | |
sys.exit() | |
with open(sys.argv[1], 'r') as r: | |
lines = r.read().split('\n') | |
glyphs = [x for x in lines if '<glyph' in x] | |
# for every glyph element in the file | |
for i in range(0, len(glyphs)): |
NewerOlder