New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@asymmetrik/angular2-sentio

Package Overview
Dependencies
Maintainers
1
Versions
19
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@asymmetrik/angular2-sentio - npm Package Compare versions

Comparing version 2.0.8 to 2.0.10

config/tslint.config.js

7

config/webpack.config.js

@@ -43,3 +43,3 @@ 'use strict';

wpConfig.output.path = path.resolve('./public');
wpConfig.output.publicPath = 'http://localhost:9000';
wpConfig.output.publicPath = 'http://localhost:9000/';
wpConfig.output.filename = '[name].js';

@@ -56,2 +56,3 @@ wpConfig.output.chunkFilename = '[name].js';

'.woff', '.woff2', '.ttf', '.eot', '.svg',
'.gif', '.jpg', '.jpeg', '.png',
'.css', '.scss',

@@ -76,3 +77,3 @@ '.html'

options: {
configFileName: path.resolve('./config/tsconfig-dev.json')
configFileName: path.resolve('./tsconfig-dev.json')
}

@@ -94,3 +95,3 @@ },

{ test: /\.png$/, loader: 'url-loader?limit=10000&mimetype=image/png' },
{ test: /\.(gif|jpg|jpeg)$/, loader: 'file-loader' },
{ test: /\.(gif|jpg|jpeg)$/, loader: 'url-loader?limit=10000' },

@@ -97,0 +98,0 @@ // Font file loader (mostly for bootstrap/font-awesome)

@@ -1,2 +0,2 @@

/*! @asymmetrik/angular2-sentio-2.0.8 - Copyright Asymmetrik, Ltd. 2007-2017 - All Rights Reserved.*/
/*! @asymmetrik/angular2-sentio-2.0.10 - Copyright Asymmetrik, Ltd. 2007-2017 - All Rights Reserved.*/
(function (global, factory) {

@@ -8,3 +8,3 @@ typeof exports === 'object' && typeof module !== 'undefined' ? factory() :

var sentio_module_1 = require('./angular2-sentio/sentio.module');
var sentio_module_1 = require('./sentio/sentio.module');
exports.SentioModule = sentio_module_1.SentioModule;

@@ -11,0 +11,0 @@

@@ -1,2 +0,2 @@

/*! @asymmetrik/angular2-sentio-2.0.8 - Copyright Asymmetrik, Ltd. 2007-2017 - All Rights Reserved.*/
!function(e,o){"object"==typeof exports&&"undefined"!=typeof module?o():"function"==typeof define&&define.amd?define(o):o()}(this,function(){"use strict";var e=require("./angular2-sentio/sentio.module");exports.SentioModule=e.SentioModule});
/*! @asymmetrik/angular2-sentio-2.0.10 - Copyright Asymmetrik, Ltd. 2007-2017 - All Rights Reserved.*/
!function(e,o){"object"==typeof exports&&"undefined"!=typeof module?o():"function"==typeof define&&define.amd?define(o):o()}(this,function(){"use strict";var e=require("./sentio/sentio.module");exports.SentioModule=e.SentioModule});

@@ -1,1 +0,1 @@

export { SentioModule } from './angular2-sentio/sentio.module';
export { SentioModule } from './sentio/sentio.module';
"use strict";
var sentio_module_1 = require('./angular2-sentio/sentio.module');
var sentio_module_1 = require('./sentio/sentio.module');
exports.SentioModule = sentio_module_1.SentioModule;
//# sourceMappingURL=index.js.map

@@ -23,3 +23,11 @@ 'use strict';

/**
* ENV Tasks
*/
let BUILD = false;
gulp.task('env:BUILD', () => {
BUILD = true;
});
/**

@@ -32,3 +40,3 @@ * Validation Tasks

// Grab the tslint config
var config = require(path.resolve('./config/tslint.conf.js'));
var config = require(path.resolve('./config/tslint.config.js'));
config.formatter = 'prose';

@@ -41,3 +49,3 @@

summarizeFailureOutput: true,
emitError: true
emitError: BUILD
}));

@@ -53,3 +61,3 @@

// Build JS from the TS source
var tsProject = plugins.typescript.createProject('./config/tsconfig.json');
var tsProject = plugins.typescript.createProject(path.resolve('./tsconfig.json'));
gulp.task('build-ts', () => {

@@ -114,3 +122,10 @@

new webpackDevServer(compiler, {
stats: { colors: true, chunks: false }
stats: {
colors: true,
chunks: false
},
watchOptions: {
aggregateTimeout: 300,
poll: 1000
},
}).listen(9000, 'localhost', (err) => {

@@ -124,2 +139,6 @@ if(err) throw new plugins.util.PluginError('webpack', err);

gulp.task('watch-ts', () => {
gulp.watch(assets.src.allTs, ['validate-ts']);
});
/**

@@ -131,7 +150,7 @@ * --------------------------

gulp.task('develop', [ 'webpack-dev-server' ]);
gulp.task('dev', (done) => { runSequence('validate-ts', [ 'webpack-dev-server', 'watch-ts' ], done); } );
gulp.task('build', (done) => { runSequence('validate-ts', 'build-ts', 'build-js', done); } );
gulp.task('build', (done) => { runSequence('env:BUILD', 'validate-ts', 'build-ts', 'build-js', done); } );
// Default task builds
gulp.task('default', [ 'build' ]);

@@ -5,3 +5,3 @@ {

"description": "Angular 2 components for Sentio",
"version": "2.0.8",
"version": "2.0.10",
"author": "Asymmetrik, Ltd.",

@@ -8,0 +8,0 @@ "copyright": "Copyright Asymmetrik, Ltd. 2007-2017 - All Rights Reserved.",

@@ -1,17 +0,40 @@

# Angular2 Sentio #
# @asymmetrik/angular2-sentio
[![Build Status][travis-image]][travis-url]
## What is it? ##
Angular 2 Sentio is a package containing components for integrating Sentio with Angular 2
> Angular2 Components for Sentio
> Provides directives for all Sentio visualization components. Supports D3 v4
## Getting Started ##
To install this package, use npm:
## Table of Contents
- [Install](#install)
- [Usage](#usage)
- [API](#api)
- [Contribute](#contribute)
- [License](#license)
```npm install @asymmetrik/angular2-sentio```
This project contains several Angular 2 components that expose Sentio data visualizations.
## Install
Install the package via npm:
```
npm install @asymmetrik/angular2-sentio
```
[travis-url]: https://travis-ci.org/Asymmetrik/angular2-sentio/
[travis-image]: https://travis-ci.org/Asymmetrik/angular2-sentio.svg
## Usage
TODO: Add usage examples
## API
TODO: Add full details of directives
## Contribute
PRs accepted. If you are part of Asymmetrik, please make contributions on feature branches off of the ```develop``` branch. If you are outside of Asymmetrik, please fork our repo to make contributions.
## License
See LICENSE in repository for details.
[travis-url]: https://travis-ci.org/Asymmetrik/angular2-template/
[travis-image]: https://travis-ci.org/Asymmetrik/angular2-template.svg

@@ -1,4 +0,2 @@

import { Component, HostListener } from '@angular/core';
import * as d3 from 'd3';
import * as sentio from '@asymmetrik/sentio';
import { Component } from '@angular/core';

@@ -9,188 +7,2 @@ @Component({

})
export class AppComponent {
// Donut Chart Configuration
private donut: any = {
resize: true,
model: [],
configure: (chart: any) => {
chart.color(d3.scaleOrdinal().range(['#a6cee3', '#1f78b4', '#b2df8a', '#33a02c']));
chart.label(function(d: any) { return d.key + ' (' + d.value + ')'; });
},
update: () => {
let samples = 5;
let newModel: Object[] = [];
for (let i: number = 0; i < samples; i++) {
newModel.push({
key: `key: ${i}`,
value: Math.floor(Math.random() * samples)
});
}
this.donut.model = newModel;
},
init: () => {
this.donut.update();
}
};
// Bar Chart Configuration
private bars: any = {
resize: true,
model: [],
configure: (chart: any) => {
chart.label(function(d: any) { return d.key + '&lrm; (' + d.value + ')'; });
},
update: () => {
let newData: Object[] = [];
let samples = 20;
for (let i: number = 0; i < samples; i++) {
newData.push({
key: `key: ${i}`,
value: Math.floor(Math.random() * 100)
});
}
this.bars.model = newData
.sort((a: any, b: any) => { return b.value - a.value; })
.slice(0, 12);
},
init: () => {
this.bars.update();
}
};
// Matrix Chart Configuration
private matrix: any = {
model: [],
configure: (chart: any) => {
chart.key(function(d: any, i: number) { return i; })
.value(function(d: any) { return d; })
.margin({ top: 20, right: 2, bottom: 2, left: 80 });
},
update: () => {
let data: number[] = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
let series: any[] = [];
series.push({ key: 'increasing', label: 'Increasing', values: data.map((d: any, i: number) => { return i; }) });
series.push({ key: 'decreasing', label: 'Decreasing', values: data.map((d: any, i: number, arr: any[]) => { return arr.length - i - 1; }) });
series.push({ key: 'upAndDown', label: 'Up and Down', values: data.map((d: any, i: number, arr: any[]) => { return arr.length / 2 - Math.abs(-i + arr.length / 2); }) });
series.push({ key: 'flatHigh', label: 'Flat High', values: data.map((d: any, i: number) => { return 19; })});
series.push({ key: 'flatLow', label: 'Flat Low', values: data.map((d: any, i: number) => { return 0; }) });
series.push({ key: 'flatMid', label: 'Flat Mid', values: data.map((d: any, i: number) => { return 10; }) });
series.push({ key: 'spikeHigh', label: 'Spike High', values: data.map((d: any, i: number) => { return (Math.random() > 0.1) ? 1 : 19; }) });
series.push({ key: 'spikeLow', label: 'Spike Low', values: data.map((d: any, i: number) => { return (Math.random() > 0.1) ? 19 : 1; }) });
series.push({ key: 'random', label: 'random', values: data.map((d: any, i: number) => { return Math.random() * 19; }) });
// Remove a couple things
series.splice(Math.floor(Math.random() * series.length), 1);
series.splice(Math.floor(Math.random() * series.length), 1);
// Swap a couple things
let swap = (i: number, j: number, arr: any[]) => {
let t = arr[j];
arr[j] = arr[i];
arr[i] = t;
};
swap(Math.floor(Math.random() * series.length), Math.floor(Math.random() * series.length), series);
swap(Math.floor(Math.random() * series.length), Math.floor(Math.random() * series.length), series);
this.matrix.model = series;
},
init: () => {
this.matrix.update();
}
};
// Timeline Line Chart Configuration
private timeline: any = {
model: [],
filterEnabled: true,
filter: null,
interval: 60000,
binSize: 1000,
hwm: Date.now(),
configure: (chart: any) => {},
eventHandler: (msg: string, event: any) => {
console.log({ msg: msg, event: event });
},
update: () => {
this.timeline.hwm = Date.now();
let newModel: any[] = [];
['series1', 'series2'].forEach((s) => {
let k = s;
let d: any[] = [];
for (let i = 0; i < this.timeline.interval / this.timeline.binSize; i++) {
d.push([ this.timeline.hwm + (i * this.timeline.binSize), Math.random() * 10 ]);
}
newModel.push({ key: k, data: d });
});
this.timeline.model = newModel;
},
init: () => {
this.timeline.update();
}
};
// Timeline Line Chart Configuration
private rtTimeline: any = {
chart: null,
model: [],
bins: sentio.controller.rtBins({ binCount: 60, binSize: 1000 }),
markers: [],
hwm: Date.now(),
configure: (chart: any) => {
chart.margin({ top: 16, right: 10, bottom: 20, left: 40 }).resize();
this.rtTimeline.chart = chart;
this.rtTimeline.play();
},
eventHandler: (msg: string, event: any) => {
console.log({ msg: msg, event: event });
},
play: () => {
this.rtTimeline.chart.start();
},
pause: () => {
this.rtTimeline.chart.stop();
},
init: () => {
this.rtTimeline.bins.model()
.updateBin((bin: any[], d: number) => { bin[1] += 1; })
.createSeed(() => { return 0; });
this.rtTimeline.model = [
{ key: 'series1', data: this.rtTimeline.bins.bins() }
];
}
};
@HostListener('mouseup', ['$event'])
onMouseUp(event: MouseEvent) {
this.rtTimeline.markers.push([Date.now(), 'Click']);
// Remove old markers
let markers = this.rtTimeline.markers;
let hwm = this.rtTimeline.bins.model().hwm();
let binCount = this.rtTimeline.bins.model().count();
let binSize = this.rtTimeline.bins.model().size();
while (markers.length > 0 && markers[0][0] < hwm - (binCount * binSize)) {
this.rtTimeline.markers.shift();
}
};
@HostListener('mousemove', ['$event'])
onMouseMove(event: MouseEvent) {
this.rtTimeline.bins.add([Date.now()]);
}
ngOnInit() {
this.donut.init();
this.bars.init();
this.matrix.init();
this.timeline.init();
this.rtTimeline.init();
}
}
export class AppComponent { }
import { NgModule } from '@angular/core';
import { BrowserModule } from '@angular/platform-browser';
import { SentioModule } from '../../angular2-sentio/sentio.module';
import { SentioDemoModule } from './sentio-demo/sentio-demo.module';
import { AppComponent } from './app.component';

@@ -10,3 +10,3 @@

BrowserModule,
SentioModule
SentioDemoModule
],

@@ -13,0 +13,0 @@ declarations: [

@@ -35,2 +35,4 @@ /**

// Angular2 Third-Party
// Other Dependencies

@@ -42,1 +44,5 @@ import 'd3';

import '@asymmetrik/sentio';
// Other Dependencies
import 'rxjs';

@@ -1,1 +0,1 @@

export { SentioModule } from './angular2-sentio/sentio.module';
export { SentioModule } from './sentio/sentio.module';

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc