Skip to content

Instantly share code, notes, and snippets.

View jkeen's full-sized avatar

Jeff Keen jkeen

View GitHub Profile
@jkeen
jkeen / transition.scss
Created November 11, 2015 05:05
Excellent Transition Mixin
@mixin trans-prefix($value, $prefix: "") {
$slice: str-slice(inspect($value), 0, 9);
@if $slice == "transform" {
#{$prefix}transition: #{$prefix}#{$value};
} @else {
#{$prefix}transition: $value;
}
}
@mixin transition($properties...) {
@if length($properties) > 1 {
@jkeen
jkeen / chat.sql
Created November 30, 2015 05:26
iMessage chat.db deciphering
SELECT
m.rowid as message_id,
(SELECT chat_id FROM chat_message_join WHERE chat_message_join.message_id = m.rowid) as message_group,
CASE p.participant_count
WHEN 0 THEN "???"
WHEN 1 THEN "Individual"
ELSE "Group"
END AS chat_type,
DATETIME(date +978307200, 'unixepoch', 'localtime') AS date,
CASE is_from_me

Keybase proof

I hereby claim:

  • I am jkeen on github.
  • I am jeffkeen (https://keybase.io/jeffkeen) on keybase.
  • I have a public key whose fingerprint is B58B FD90 CB49 CA73 6488 C621 42B6 03F6 5AAB 4CDA

To claim this, I am signing this object:

@jkeen
jkeen / components.content-for.js
Created January 27, 2017 14:18
Ember Content For
import Ember from 'ember';
import computed from 'ember-computed';
import layout from '../templates/components/content-for';
let ContentFor = Ember.Component.extend({
layout,
tagName: '',
hasContentForYield: computed('contentName', 'yieldName', function() {
return (this.get('contentName') === this.get('yieldName'));
import Controller from '@ember/controller';
export default class ApplicationController extends Controller {
appName = 'Ember Twiddle';
}
import Component from '@glimmer/component';
import { tracked } from '@glimmer/tracking';
import { action } from '@ember/object';
export default class extends Component {
@action
handleChange(e) {
this.args.changeset.set(this.args.name, e.target.value);
}
}
import Component from '@glimmer/component';
export default class CalendarGrid extends Component {
get cells() {
if (this.args.span == 'week') {
return [1,2,3,4,5,6,7];
}
else {
return [1];
}
import Component from '@glimmer/component';
export default class extends Component {
}