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 { Component, PropTypes } from 'react' | |
import { connect } from 'react-redux' | |
import { transitionTo } from 'redux-react-router' | |
const NEXT_URL = 'REDIRECTOR(NEXT_URL)' | |
const CLEAR_NEXT_URL = 'REDIRECTOR(CLEAR_NEXT_URL)' | |
export const transitionNext = url => ({ type: NEXT_URL, payload: url }) | |
export const clearNextUrl = () => ({ type: CLEAR_NEXT_URL }) |
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
<% if @note %> | |
<form action="/<%= @note.id %>" method="post" id="edit"> | |
<input type="hidden" name="_method" value="put"> | |
<textarea name="content"><%=h @note.content %></textarea> | |
<input type="checkbox" name="complete" <%= "checked" if @note.complete %>> | |
<input type="submit"> | |
</form> | |
<p><a href="/<%= @note.id %>/delete">Delete</a></p> | |
<% else %> | |
<p>Note not found.</p> |
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
Handlebars.registerHelper('if_task_active', function(options) { | |
var state = this.model.state_id; | |
if (state == 300) { | |
return options.fn(this); | |
} | |
return options.inverse(this); | |
}); |
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
Handlebars.registerHelper('if_task_state', function(options) { | |
var states = options.hash.is.split(',') | |
, r = false | |
; | |
_.each(states, function(state) { | |
if (state == this.model.state) | |
r = true; | |
}, this); |
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
<?php | |
public static function __callStatic($method, $arguments) | |
{ | |
return call_user_func_array(array(self::$_instance, $method), $arguments); | |
} |
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
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="UTF-8"> | |
<title>Simple Styled Radio Inputs · CodePen</title> | |
<!-- | |
Copyright (c) 2012 Dan Harper, http://codepen.io/danharper | |
Permission is hereby granted, free of charge, to any person obtaining |
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
on run {input, parameters} | |
tell application "System Events" | |
set activeApp to name of first process whose frontmost is true | |
end tell | |
set _timestamp to (input as string) | |
tell application activeApp | |
set realDate to ((do shell script "date -r " & _timestamp) as string) |
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
function unblockuson() { | |
sudo networksetup -setdnsservers "Wi-Fi" 208.122.23.22 208.122.23.23 | |
sudo networksetup -setairportpower "en1" "off" | |
sudo networksetup -setairportpower "en1" "on" | |
echo "Unblock-Us: ENABLED" | |
} | |
function unblockusoff() { | |
sudo networksetup -setdnsservers "Wi-Fi" "empty" | |
sudo networksetup -setairportpower "en1" "off" |
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
@page { | |
margin: .312in .312in .322in; | |
} | |
@media print { | |
html { | |
margin: 0 .1in; | |
} | |
} |
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
@usingPerRow(4) | |
@foreach ($images as $image) | |
@incrementPerRow() | |
@whenStartOfRow | |
<tr> | |
@closeStartOfRow | |
<td><img src="{{ $image->url }}"></td> |