Skip to content

Instantly share code, notes, and snippets.

View topherfangio's full-sized avatar

Topher Fangio topherfangio

View GitHub Profile
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
mainPane: SC.MainPane.design({
childViews: [ 'thescrollview' ],
thescrollview: SC.ScrollView.extend({
hasHorizontalScroller: NO,
hasVerticalScroller: YES,
contentView: SC.View.extend({
@topherfangio
topherfangio / branch-analyzer.rb
Last active November 25, 2015 15:34
Quick GitHub branch/issue analyzer
#!/usr/bin/env ruby
############
# OVERVIEW #
############
#
# This (very rudimentary) script will show you the status of issues that your
# branches are tied to.
#
# To use, install it with the instructions below, and make sure to include the
@topherfangio
topherfangio / proposed_template_approach.js
Created September 26, 2014 21:09
Proposed SC.TemplateView Approach
MyApp.MyView = SC.EasySimpleTemplateView.extend({
template: [
"<div class='background' style='position: absolute; top: 0px; left: 0px; width: {{layout.width}}px; height: {{layout.height}}px'></div>",
"<div style='position: absolute; top: 0px; left: 0px; width: {{layout.width}}px; height: {{layout.height}}px'>",
" <div class='title'>{{title}}</div>",
" <img class='icon' src='{{icon}}' />",
" <div class='description'>{{description}}</div>",
"</div>",
(p.new_count > 0 ? "<div class='badge' style='position: absolute; top: 5px; right: 5px;'>{{new_count}}</div>"
@topherfangio
topherfangio / common_view_pattern.js
Created September 26, 2014 21:02
Common SC View Pattern
MyApp.MyView = SC.View.extend({
render: function(context) {
context.push(this._renderHtml());
},
update: function(jQuery) {
jQuery.html(this._renderHtml());
},
@topherfangio
topherfangio / scui2.js
Created June 5, 2014 06:28
Double Autocomplete view with new BT
/* begin of file /Users/topher/Documents/Development/profoundry/colla/frameworks/scui2/views/autocomplete.js */
SC.AutocompleteInputView = SC.TextFieldView.extend({
layout: { width: 200, height: 24 },
hint: 'Type here...',
valueBinding: 'Craft.testController.someValue',
isEditable: YES,
beginEditing: function() {
# my_project/sc_config
var craft = BT.AppBuilder.create({
path: 'apps/craft',
frameworks: ['firecore', 'core'],
theme: 'scimple_theme',
indexHtml: function () {
return this.renderIndexHtml(this).replace("<head>", "<head><link href='//netdna.bootstrapcdn.com/font-awesome/4.1.0/css/font-awesome.min.css' rel='stylesheet'>");
}.property()
@topherfangio
topherfangio / output.js
Created May 9, 2014 21:41
Random Abbot Output
(function() {
var styles = [];
if (window.devicePixelRatio == 2 || window.location.search.indexOf("2x") > -1) {
styles = ["/static/sproutcore/testing/en/current/source/resources/additions.css?1381979730","/static/sproutcore/testing/en/current/source/resources/runner.css?1381979730","/static/sproutcore/testing/en/current/source/resources/testsuite.css?1381979730","/static/sproutcore/yuireset/en/current/source/resources/base.css?1381979730","/static/sproutcore/yuireset/en/current/source/resources/core.css?1381979730","/static/sproutcore/yuireset/en/current/source/resources/fonts.css?1381979730","/static/sproutcore/yuireset/en/current/source/resources/reset.css?1381979730","/static/sproutcore/yuireset/en/current/source/resources/view.css?1381979730","/static/sproutcore/foundation/en/current/source/debug/test-image.png?1381979730","/static/sproutcore/foundation/en/current/source/resources/benchmark.css?1381979730","/static/sproutcore/foundation/en/current/source/resources/blank.gif?1
@topherfangio
topherfangio / error.txt
Last active August 29, 2015 14:01
Another Node SC BT Error
> [email protected] install /Users/topher/Documents/Development/profoundry/collaborate/node_modules/sproutcore
> node post_install.js
SC.browser.experimentalNameFor(): target, [object Object], does not have property `animation` or `undefinedAnimation`.
SC.browser.experimentalNameFor(): target, [object Object], does not have property `transition` or `undefinedTransition`.
SC.browser.experimentalNameFor(): target, [object Object], does not have property `transform` or `undefinedTransform`.
SC.browser.experimentalNameFor(): target, [object Object], does not have property `perspective` or `undefinedPerspective`.
5 May 16:13:29 - Installing sproutcore as global dependency...
/Users/topher/Documents/Development/profoundry/collaborate/node_modules/sproutcore/index.js:81
@topherfangio
topherfangio / error.txt
Last active August 29, 2015 14:00
SproutCore Node Build Tools - Error on Windows7
Sproutcore NodeJS BuildTools v0.0.1
Adding app todos_one
Adding app todos_two
Adding app todos_three
Starting development server...
Server started on http://localhost:4020
module.js:356
Module._extensions[extension](this, filename);