Skip to content

Instantly share code, notes, and snippets.

View nbering's full-sized avatar

Nicholas Bering nbering

View GitHub Profile

Keybase proof

I hereby claim:

  • I am nbering on github.
  • I am nbering (https://keybase.io/nbering) on keybase.
  • I have a public key ASD__G9vus4Uvyo2M4BbjsMKGas4vnnyN8Ndzipw5rFj-Qo

To claim this, I am signing this object:

@nbering
nbering / setup.md
Last active September 6, 2015 00:53
How I like any editor set up...

About

I just started this document as a place to record the little things I like to change in any editor... and what I change them to.

Fonts

Line Numbering

Yes.

@nbering
nbering / googlechart.smiffy.js
Created May 11, 2015 11:41
Google-chart directives for Smiffy6969
(function(){
angular.module('googlechart.smiffy', ['googlechart'])
.directive('onPage', onPageDirective)
.directive('onSort', onSortDirective)
.directive('smiffySelect', smiffySelectDirective)
.directive('smiffyDeselect', smiffyDeselectDirective);
/* Example:
<div google-chart chart="myChart" on-page="myPageHandler(page)"></div>
*/
/******************
* Code originally written by Ben Jacobs (benmj)
* Modified by Weston Siegenthaler (Wsiengenthaler) and Nicholas Bering (Balrog30)
* Of GitHub Community.
******************/
/*global angular: true, google: true, _ : true */
'use strict';
@nbering
nbering / app.js
Created August 16, 2014 19:17
Angular-Google-Chart Hide Series Example
angular.module('myApp', ['googlechart'])
.controller('myController', function($scope) {
var chart1 = {};
chart1.type = "LineChart";
chart1.displayed = false;
chart1.data = {
"cols": [
{ id: "month", label: "Month", type: "string"},
{ id: "laptop-id", label: "Laptop", type: "number"},
{ id: "desktop-id", label: "Desktop", type: "number"},
@nbering
nbering / app.js
Created August 14, 2014 17:28
Basic Angular-Google-Chart Example
angular.module('myApp', ['googlechart'])
.controller('myController', function($scope) {
var chart1 = {};
chart1.type = "AreaChart";
chart1.displayed = false;
chart1.data = {
"cols": [{
id: "month",
label: "Month",
type: "string"
@nbering
nbering / angular-google-chart-hide-series-example.js
Last active August 29, 2015 14:02
Using chart select event to hide a selected chart series using angular-google-charts.
/*
#########
Notes:
#########
- $scope.saleschart is the chart object passed to the directive.
- $scope.saleschart.data is and instance of google.visualization.DataTable, giving it access to that class's member functions.
I also discovered that being an instance of the Chart API class allows access to the functions, but results in and field or
property being obfuscated. Calling .toJSON() gives a JSON object of the DataTable, which helps in debugging... but I just
don't trust any names other than functions.
- $scope.saleschart.view.columns starts as an array like [0,1,2,3,4,5]. Having fewer values than the number of columns would