delete extra files and pull into vendor file

This commit is contained in:
Nabeel Shahzad
2018-03-27 15:46:54 -05:00
parent 8ad83a5f9f
commit 30a8028827
15 changed files with 1242 additions and 9105 deletions

2158
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@@ -20,18 +20,19 @@
"icheck": "^1.0.2",
"jquery": "^3.3.1",
"jquery-pjax": "^2.0.1",
"laravel-mix": "^2.0",
"laravel-mix": "^2.1",
"leaflet": "^1.3.1",
"leaflet-ajax": "2.1.0",
"leaflet-rotatedmarker": "^0.2.0",
"lodash": "4.17.4",
"marked": "0.3.9",
"moment": "^2.21.0",
"paper-dashboard": "^1.1.0",
"pjax": "^0.2.5",
"popper.js": "^1.14.0",
"popper.js": "^1.14.1",
"rivets": "^0.9.6",
"select2": "^4.0.5",
"ssri": "^5.2.2",
"ssri": "^5.3.0",
"webpack": "^3.0",
"x-editable": "1.5.1"
},

File diff suppressed because it is too large Load Diff

View File

@@ -1,315 +0,0 @@
type = ['','info','success','warning','danger'];
demo = {
initPickColor: function(){
$('.pick-class-label').click(function(){
var new_class = $(this).attr('new-class');
var old_class = $('#display-buttons').attr('data-class');
var display_div = $('#display-buttons');
if(display_div.length) {
var display_buttons = display_div.find('.btn');
display_buttons.removeClass(old_class);
display_buttons.addClass(new_class);
display_div.attr('data-class', new_class);
}
});
},
initChartist: function(){
var dataSales = {
labels: ['9:00AM', '12:00AM', '3:00PM', '6:00PM', '9:00PM', '12:00PM', '3:00AM', '6:00AM'],
series: [
[287, 385, 490, 562, 594, 626, 698, 895, 952],
[67, 152, 193, 240, 387, 435, 535, 642, 744],
[23, 113, 67, 108, 190, 239, 307, 410, 410]
]
};
var optionsSales = {
lineSmooth: false,
low: 0,
high: 1000,
showArea: true,
height: "245px",
axisX: {
showGrid: false,
},
lineSmooth: Chartist.Interpolation.simple({
divisor: 3
}),
showLine: true,
showPoint: false,
};
var responsiveSales = [
['screen and (max-width: 640px)', {
axisX: {
labelInterpolationFnc: function (value) {
return value[0];
}
}
}]
];
Chartist.Line('#chartHours', dataSales, optionsSales, responsiveSales);
var data = {
labels: ['Jan', 'Feb', 'Mar', 'Apr', 'Mai', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'],
series: [
[542, 543, 520, 680, 653, 753, 326, 434, 568, 610, 756, 895],
[230, 293, 380, 480, 503, 553, 600, 664, 698, 710, 736, 795]
]
};
var options = {
seriesBarDistance: 10,
axisX: {
showGrid: false
},
height: "245px"
};
var responsiveOptions = [
['screen and (max-width: 640px)', {
seriesBarDistance: 5,
axisX: {
labelInterpolationFnc: function (value) {
return value[0];
}
}
}]
];
Chartist.Line('#chartActivity', data, options, responsiveOptions);
var dataPreferences = {
series: [
[25, 30, 20, 25]
]
};
var optionsPreferences = {
donut: true,
donutWidth: 40,
startAngle: 0,
total: 100,
showLabel: false,
axisX: {
showGrid: false
}
};
Chartist.Pie('#chartPreferences', dataPreferences, optionsPreferences);
Chartist.Pie('#chartPreferences', {
labels: ['62%','32%','6%'],
series: [62, 32, 6]
});
},
initGoogleMaps: function(){
var myLatlng = new google.maps.LatLng(40.748817, -73.985428);
var mapOptions = {
zoom: 13,
center: myLatlng,
scrollwheel: false, //we disable de scroll over the map, it is a really annoing when you scroll through page
styles: [{"featureType":"water","stylers":[{"saturation":43},{"lightness":-11},{"hue":"#0088ff"}]},{"featureType":"road","elementType":"geometry.fill","stylers":[{"hue":"#ff0000"},{"saturation":-100},{"lightness":99}]},{"featureType":"road","elementType":"geometry.stroke","stylers":[{"color":"#808080"},{"lightness":54}]},{"featureType":"landscape.man_made","elementType":"geometry.fill","stylers":[{"color":"#ece2d9"}]},{"featureType":"poi.park","elementType":"geometry.fill","stylers":[{"color":"#ccdca1"}]},{"featureType":"road","elementType":"labels.text.fill","stylers":[{"color":"#767676"}]},{"featureType":"road","elementType":"labels.text.stroke","stylers":[{"color":"#ffffff"}]},{"featureType":"poi","stylers":[{"visibility":"off"}]},{"featureType":"landscape.natural","elementType":"geometry.fill","stylers":[{"visibility":"on"},{"color":"#b8cb93"}]},{"featureType":"poi.park","stylers":[{"visibility":"on"}]},{"featureType":"poi.sports_complex","stylers":[{"visibility":"on"}]},{"featureType":"poi.medical","stylers":[{"visibility":"on"}]},{"featureType":"poi.business","stylers":[{"visibility":"simplified"}]}]
}
var map = new google.maps.Map(document.getElementById("map"), mapOptions);
var marker = new google.maps.Marker({
position: myLatlng,
title:"Hello World!"
});
// To add the marker to the map, call setMap();
marker.setMap(map);
},
showNotification: function(from, align){
color = Math.floor((Math.random() * 4) + 1);
$.notify({
icon: "ti-gift",
message: "Welcome to <b>Paper Dashboard</b> - a beautiful freebie for every web developer."
},{
type: type[color],
timer: 4000,
placement: {
from: from,
align: align
}
});
},
initDocumentationCharts: function(){
// init single simple line chart
var dataPerformance = {
labels: ['6pm','9pm','11pm', '2am', '4am', '8am', '2pm', '5pm', '8pm', '11pm', '4am'],
series: [
[1, 6, 8, 7, 4, 7, 8, 12, 16, 17, 14, 13]
]
};
var optionsPerformance = {
showPoint: false,
lineSmooth: true,
height: "200px",
axisX: {
showGrid: false,
showLabel: true
},
axisY: {
offset: 40,
},
low: 0,
high: 16,
height: "250px"
};
Chartist.Line('#chartPerformance', dataPerformance, optionsPerformance);
// init single line with points chart
var dataStock = {
labels: ['\'07','\'08','\'09', '\'10', '\'11', '\'12', '\'13', '\'14', '\'15'],
series: [
[22.20, 34.90, 42.28, 51.93, 62.21, 80.23, 62.21, 82.12, 102.50, 107.23]
]
};
var optionsStock = {
lineSmooth: false,
height: "200px",
axisY: {
offset: 40,
labelInterpolationFnc: function(value) {
return '$' + value;
}
},
low: 10,
height: "250px",
high: 110,
classNames: {
point: 'ct-point ct-green',
line: 'ct-line ct-green'
}
};
Chartist.Line('#chartStock', dataStock, optionsStock);
// init multiple lines chart
var dataSales = {
labels: ['9:00AM', '12:00AM', '3:00PM', '6:00PM', '9:00PM', '12:00PM', '3:00AM', '6:00AM'],
series: [
[287, 385, 490, 562, 594, 626, 698, 895, 952],
[67, 152, 193, 240, 387, 435, 535, 642, 744],
[23, 113, 67, 108, 190, 239, 307, 410, 410]
]
};
var optionsSales = {
lineSmooth: false,
low: 0,
high: 1000,
showArea: true,
height: "245px",
axisX: {
showGrid: false,
},
lineSmooth: Chartist.Interpolation.simple({
divisor: 3
}),
showLine: true,
showPoint: false,
};
var responsiveSales = [
['screen and (max-width: 640px)', {
axisX: {
labelInterpolationFnc: function (value) {
return value[0];
}
}
}]
];
Chartist.Line('#chartHours', dataSales, optionsSales, responsiveSales);
// pie chart
Chartist.Pie('#chartPreferences', {
labels: ['62%','32%','6%'],
series: [62, 32, 6]
});
// bar chart
var dataViews = {
labels: ['Jan', 'Feb', 'Mar', 'Apr', 'Mai', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'],
series: [
[542, 443, 320, 780, 553, 453, 326, 434, 568, 610, 756, 895]
]
};
var optionsViews = {
seriesBarDistance: 10,
classNames: {
bar: 'ct-bar'
},
axisX: {
showGrid: false,
},
height: "250px"
};
var responsiveOptionsViews = [
['screen and (max-width: 640px)', {
seriesBarDistance: 5,
axisX: {
labelInterpolationFnc: function (value) {
return value[0];
}
}
}]
];
Chartist.Bar('#chartViews', dataViews, optionsViews, responsiveOptionsViews);
// multiple bars chart
var data = {
labels: ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'],
series: [
[542, 543, 520, 680, 653, 753, 326, 434, 568, 610, 756, 895],
[230, 293, 380, 480, 503, 553, 600, 664, 698, 710, 736, 795]
]
};
var options = {
seriesBarDistance: 10,
axisX: {
showGrid: false
},
height: "245px"
};
var responsiveOptions = [
['screen and (max-width: 640px)', {
seriesBarDistance: 5,
axisX: {
labelInterpolationFnc: function (value) {
return value[0];
}
}
}]
];
Chartist.Line('#chartActivity', data, options, responsiveOptions);
}
}

View File

@@ -1,509 +0,0 @@
/*!
* iCheck v1.0.2, http://git.io/arlzeA
* ===================================
* Powerful jQuery and Zepto plugin for checkboxes and radio buttons customization
*
* (c) 2013 Damir Sultanov, http://fronteed.com
* MIT Licensed
*/
(function($) {
// Cached vars
var _iCheck = 'iCheck',
_iCheckHelper = _iCheck + '-helper',
_checkbox = 'checkbox',
_radio = 'radio',
_checked = 'checked',
_unchecked = 'un' + _checked,
_disabled = 'disabled',
_determinate = 'determinate',
_indeterminate = 'in' + _determinate,
_update = 'update',
_type = 'type',
_click = 'click',
_touch = 'touchbegin.i touchend.i',
_add = 'addClass',
_remove = 'removeClass',
_callback = 'trigger',
_label = 'label',
_cursor = 'cursor',
_mobile = /ipad|iphone|ipod|android|blackberry|windows phone|opera mini|silk/i.test(navigator.userAgent);
// Plugin init
$.fn[_iCheck] = function(options, fire) {
// Walker
var handle = 'input[type="' + _checkbox + '"], input[type="' + _radio + '"]',
stack = $(),
walker = function(object) {
object.each(function() {
var self = $(this);
if (self.is(handle)) {
stack = stack.add(self);
} else {
stack = stack.add(self.find(handle));
}
});
};
// Check if we should operate with some method
if (/^(check|uncheck|toggle|indeterminate|determinate|disable|enable|update|destroy)$/i.test(options)) {
// Normalize method's name
options = options.toLowerCase();
// Find checkboxes and radio buttons
walker(this);
return stack.each(function() {
var self = $(this);
if (options == 'destroy') {
tidy(self, 'ifDestroyed');
} else {
operate(self, true, options);
}
// Fire method's callback
if ($.isFunction(fire)) {
fire();
}
});
// Customization
} else if (typeof options == 'object' || !options) {
// Check if any options were passed
var settings = $.extend({
checkedClass: _checked,
disabledClass: _disabled,
indeterminateClass: _indeterminate,
labelHover: true
}, options),
selector = settings.handle,
hoverClass = settings.hoverClass || 'hover',
focusClass = settings.focusClass || 'focus',
activeClass = settings.activeClass || 'active',
labelHover = !!settings.labelHover,
labelHoverClass = settings.labelHoverClass || 'hover',
// Setup clickable area
area = ('' + settings.increaseArea).replace('%', '') | 0;
// Selector limit
if (selector == _checkbox || selector == _radio) {
handle = 'input[type="' + selector + '"]';
}
// Clickable area limit
if (area < -50) {
area = -50;
}
// Walk around the selector
walker(this);
return stack.each(function() {
var self = $(this);
// If already customized
tidy(self);
var node = this,
id = node.id,
// Layer styles
offset = -area + '%',
size = 100 + (area * 2) + '%',
layer = {
position: 'absolute',
top: offset,
left: offset,
display: 'block',
width: size,
height: size,
margin: 0,
padding: 0,
background: '#fff',
border: 0,
opacity: 0
},
// Choose how to hide input
hide = _mobile ? {
position: 'absolute',
visibility: 'hidden'
} : area ? layer : {
position: 'absolute',
opacity: 0
},
// Get proper class
className = node[_type] == _checkbox ? settings.checkboxClass || 'i' + _checkbox : settings.radioClass || 'i' + _radio,
// Find assigned labels
label = $(_label + '[for="' + id + '"]').add(self.closest(_label)),
// Check ARIA option
aria = !!settings.aria,
// Set ARIA placeholder
ariaID = _iCheck + '-' + Math.random().toString(36).substr(2,6),
// Parent & helper
parent = '<div class="' + className + '" ' + (aria ? 'role="' + node[_type] + '" ' : ''),
helper;
// Set ARIA "labelledby"
if (aria) {
label.each(function() {
parent += 'aria-labelledby="';
if (this.id) {
parent += this.id;
} else {
this.id = ariaID;
parent += ariaID;
}
parent += '"';
});
}
// Wrap input
parent = self.wrap(parent + '/>')[_callback]('ifCreated').parent().append(settings.insert);
// Layer addition
helper = $('<ins class="' + _iCheckHelper + '"/>').css(layer).appendTo(parent);
// Finalize customization
self.data(_iCheck, {o: settings, s: self.attr('style')}).css(hide);
!!settings.inheritClass && parent[_add](node.className || '');
!!settings.inheritID && id && parent.attr('id', _iCheck + '-' + id);
parent.css('position') == 'static' && parent.css('position', 'relative');
operate(self, true, _update);
// Label events
if (label.length) {
label.on(_click + '.i mouseover.i mouseout.i ' + _touch, function(event) {
var type = event[_type],
item = $(this);
// Do nothing if input is disabled
if (!node[_disabled]) {
// Click
if (type == _click) {
if ($(event.target).is('a')) {
return;
}
operate(self, false, true);
// Hover state
} else if (labelHover) {
// mouseout|touchend
if (/ut|nd/.test(type)) {
parent[_remove](hoverClass);
item[_remove](labelHoverClass);
} else {
parent[_add](hoverClass);
item[_add](labelHoverClass);
}
}
if (_mobile) {
event.stopPropagation();
} else {
return false;
}
}
});
}
// Input events
self.on(_click + '.i focus.i blur.i keyup.i keydown.i keypress.i', function(event) {
var type = event[_type],
key = event.keyCode;
// Click
if (type == _click) {
return false;
// Keydown
} else if (type == 'keydown' && key == 32) {
if (!(node[_type] == _radio && node[_checked])) {
if (node[_checked]) {
off(self, _checked);
} else {
on(self, _checked);
}
}
return false;
// Keyup
} else if (type == 'keyup' && node[_type] == _radio) {
!node[_checked] && on(self, _checked);
// Focus/blur
} else if (/us|ur/.test(type)) {
parent[type == 'blur' ? _remove : _add](focusClass);
}
});
// Helper events
helper.on(_click + ' mousedown mouseup mouseover mouseout ' + _touch, function(event) {
var type = event[_type],
// mousedown|mouseup
toggle = /wn|up/.test(type) ? activeClass : hoverClass;
// Do nothing if input is disabled
if (!node[_disabled]) {
// Click
if (type == _click) {
operate(self, false, true);
// Active and hover states
} else {
// State is on
if (/wn|er|in/.test(type)) {
// mousedown|mouseover|touchbegin
parent[_add](toggle);
// State is off
} else {
parent[_remove](toggle + ' ' + activeClass);
}
// Label hover
if (label.length && labelHover && toggle == hoverClass) {
// mouseout|touchend
label[/ut|nd/.test(type) ? _remove : _add](labelHoverClass);
}
}
if (_mobile) {
event.stopPropagation();
} else {
return false;
}
}
});
});
} else {
return this;
}
};
// Do something with inputs
function operate(input, direct, method) {
var node = input[0],
state = /er/.test(method) ? _indeterminate : /bl/.test(method) ? _disabled : _checked,
active = method == _update ? {
checked: node[_checked],
disabled: node[_disabled],
indeterminate: input.attr(_indeterminate) == 'true' || input.attr(_determinate) == 'false'
} : node[state];
// Check, disable or indeterminate
if (/^(ch|di|in)/.test(method) && !active) {
on(input, state);
// Uncheck, enable or determinate
} else if (/^(un|en|de)/.test(method) && active) {
off(input, state);
// Update
} else if (method == _update) {
// Handle states
for (var each in active) {
if (active[each]) {
on(input, each, true);
} else {
off(input, each, true);
}
}
} else if (!direct || method == 'toggle') {
// Helper or label was clicked
if (!direct) {
input[_callback]('ifClicked');
}
// Toggle checked state
if (active) {
if (node[_type] !== _radio) {
off(input, state);
}
} else {
on(input, state);
}
}
}
// Add checked, disabled or indeterminate state
function on(input, state, keep) {
var node = input[0],
parent = input.parent(),
checked = state == _checked,
indeterminate = state == _indeterminate,
disabled = state == _disabled,
callback = indeterminate ? _determinate : checked ? _unchecked : 'enabled',
regular = option(input, callback + capitalize(node[_type])),
specific = option(input, state + capitalize(node[_type]));
// Prevent unnecessary actions
if (node[state] !== true) {
// Toggle assigned radio buttons
if (!keep && state == _checked && node[_type] == _radio && node.name) {
var form = input.closest('form'),
inputs = 'input[name="' + node.name + '"]';
inputs = form.length ? form.find(inputs) : $(inputs);
inputs.each(function() {
if (this !== node && $(this).data(_iCheck)) {
off($(this), state);
}
});
}
// Indeterminate state
if (indeterminate) {
// Add indeterminate state
node[state] = true;
// Remove checked state
if (node[_checked]) {
off(input, _checked, 'force');
}
// Checked or disabled state
} else {
// Add checked or disabled state
if (!keep) {
node[state] = true;
}
// Remove indeterminate state
if (checked && node[_indeterminate]) {
off(input, _indeterminate, false);
}
}
// Trigger callbacks
callbacks(input, checked, state, keep);
}
// Add proper cursor
if (node[_disabled] && !!option(input, _cursor, true)) {
parent.find('.' + _iCheckHelper).css(_cursor, 'default');
}
// Add state class
parent[_add](specific || option(input, state) || '');
// Set ARIA attribute
if (!!parent.attr('role') && !indeterminate) {
parent.attr('aria-' + (disabled ? _disabled : _checked), 'true');
}
// Remove regular state class
parent[_remove](regular || option(input, callback) || '');
}
// Remove checked, disabled or indeterminate state
function off(input, state, keep) {
var node = input[0],
parent = input.parent(),
checked = state == _checked,
indeterminate = state == _indeterminate,
disabled = state == _disabled,
callback = indeterminate ? _determinate : checked ? _unchecked : 'enabled',
regular = option(input, callback + capitalize(node[_type])),
specific = option(input, state + capitalize(node[_type]));
// Prevent unnecessary actions
if (node[state] !== false) {
// Toggle state
if (indeterminate || !keep || keep == 'force') {
node[state] = false;
}
// Trigger callbacks
callbacks(input, checked, callback, keep);
}
// Add proper cursor
if (!node[_disabled] && !!option(input, _cursor, true)) {
parent.find('.' + _iCheckHelper).css(_cursor, 'pointer');
}
// Remove state class
parent[_remove](specific || option(input, state) || '');
// Set ARIA attribute
if (!!parent.attr('role') && !indeterminate) {
parent.attr('aria-' + (disabled ? _disabled : _checked), 'false');
}
// Add regular state class
parent[_add](regular || option(input, callback) || '');
}
// Remove all traces
function tidy(input, callback) {
if (input.data(_iCheck)) {
// Remove everything except input
input.parent().html(input.attr('style', input.data(_iCheck).s || ''));
// Callback
if (callback) {
input[_callback](callback);
}
// Unbind events
input.off('.i').unwrap();
$(_label + '[for="' + input[0].id + '"]').add(input.closest(_label)).off('.i');
}
}
// Get some option
function option(input, state, regular) {
if (input.data(_iCheck)) {
return input.data(_iCheck).o[state + (regular ? '' : 'Class')];
}
}
// Capitalize some string
function capitalize(string) {
return string.charAt(0).toUpperCase() + string.slice(1);
}
// Executable handlers
function callbacks(input, checked, callback, keep) {
if (!keep) {
if (checked) {
input[_callback]('ifToggled');
}
input[_callback]('ifChanged')[_callback]('if' + capitalize(callback));
}
}
})(window.jQuery || window.Zepto);

View File

@@ -1,157 +0,0 @@
/*!
=========================================================
* Paper Dashboard - v1.1.2
=========================================================
* Product Page: http://www.creative-tim.com/product/paper-dashboard
* Copyright 2017 Creative Tim (http://www.creative-tim.com)
* Licensed under MIT (https://github.com/creativetimofficial/paper-dashboard/blob/master/LICENSE.md)
=========================================================
* The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
*/
var fixedTop = false;
var transparent = true;
var navbar_initialized = false;
$(document).ready(function(){
window_width = $(window).width();
// Init navigation toggle for small screens
if(window_width <= 991){
pd.initRightMenu();
}
// Activate the tooltips
$('[rel="tooltip"]').tooltip();
});
// activate collapse right menu when the windows is resized
$(window).resize(function(){
if($(window).width() <= 991){
pd.initRightMenu();
}
});
pd = {
misc:{
navbar_menu_visible: 0
},
checkScrollForTransparentNavbar: debounce(function() {
if($(document).scrollTop() > 381 ) {
if(transparent) {
transparent = false;
$('.navbar-color-on-scroll').removeClass('navbar-transparent');
$('.navbar-title').removeClass('hidden');
}
} else {
if( !transparent ) {
transparent = true;
$('.navbar-color-on-scroll').addClass('navbar-transparent');
$('.navbar-title').addClass('hidden');
}
}
}),
initRightMenu: function(){
if(!navbar_initialized){
$off_canvas_sidebar = $('nav').find('.navbar-collapse').first().clone(true);
$sidebar = $('.sidebar');
sidebar_bg_color = $sidebar.data('background-color');
sidebar_active_color = $sidebar.data('active-color');
$logo = $sidebar.find('.logo').first();
logo_content = $logo[0].outerHTML;
ul_content = '';
// set the bg color and active color from the default sidebar to the off canvas sidebar;
$off_canvas_sidebar.attr('data-background-color',sidebar_bg_color);
$off_canvas_sidebar.attr('data-active-color',sidebar_active_color);
$off_canvas_sidebar.addClass('off-canvas-sidebar');
//add the content from the regular header to the right menu
$off_canvas_sidebar.children('ul').each(function(){
content_buff = $(this).html();
ul_content = ul_content + content_buff;
});
// add the content from the sidebar to the right menu
content_buff = $sidebar.find('.nav').html();
ul_content = ul_content + '<li class="divider"></li>'+ content_buff;
ul_content = '<ul class="nav navbar-nav">' + ul_content + '</ul>';
navbar_content = logo_content + ul_content;
navbar_content = '<div class="sidebar-wrapper">' + navbar_content + '</div>';
$off_canvas_sidebar.html(navbar_content);
$('body').append($off_canvas_sidebar);
$toggle = $('.navbar-toggle');
$off_canvas_sidebar.find('a').removeClass('btn btn-round btn-default');
$off_canvas_sidebar.find('button').removeClass('btn-round btn-fill btn-info btn-primary btn-success btn-danger btn-warning btn-neutral');
$off_canvas_sidebar.find('button').addClass('btn-simple btn-block');
$toggle.click(function (){
if(pd.misc.navbar_menu_visible == 1) {
$('html').removeClass('nav-open');
pd.misc.navbar_menu_visible = 0;
$('#bodyClick').remove();
setTimeout(function(){
$toggle.removeClass('toggled');
}, 400);
} else {
setTimeout(function(){
$toggle.addClass('toggled');
}, 430);
div = '<div id="bodyClick"></div>';
$(div).appendTo("body").click(function() {
$('html').removeClass('nav-open');
pd.misc.navbar_menu_visible = 0;
$('#bodyClick').remove();
setTimeout(function(){
$toggle.removeClass('toggled');
}, 400);
});
$('html').addClass('nav-open');
pd.misc.navbar_menu_visible = 1;
}
});
navbar_initialized = true;
}
}
}
// Returns a function, that, as long as it continues to be invoked, will not
// be triggered. The function will be called after it stops being called for
// N milliseconds. If `immediate` is passed, trigger the function on the
// leading edge, instead of the trailing.
function debounce(func, wait, immediate) {
var timeout;
return function() {
var context = this, args = arguments;
clearTimeout(timeout);
timeout = setTimeout(function() {
timeout = null;
if (!immediate) func.apply(context, args);
}, wait);
if (immediate && !timeout) func.apply(context, args);
};
};

View File

@@ -25829,7 +25829,7 @@ if (typeof jQuery === 'undefined') {
/**!
* @fileOverview Kickass library to create and place poppers near their reference elements.
* @version 1.14.0
* @version 1.14.1
* @license
* Copyright (c) 2016 Federico Zivolo and contributors
*
@@ -28349,7 +28349,7 @@ return Popper;
/**!
* @fileOverview Kickass library to create and place poppers near their reference elements.
* @version 1.14.0
* @version 1.14.1
* @license
* Copyright (c) 2016 Federico Zivolo and contributors
*

View File

@@ -216,14 +216,14 @@ eval("// shim for using process in browser\nvar process = module.exports = {};\n
/***/ "./public/assets/admin/vendor/sass/paper-dashboard.scss":
/***/ (function(module, exports) {
eval("// removed by extract-text-webpack-plugin//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly8vLi9wdWJsaWMvYXNzZXRzL2FkbWluL3ZlbmRvci9zYXNzL3BhcGVyLWRhc2hib2FyZC5zY3NzP2FkNzQiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEiLCJmaWxlIjoiLi9wdWJsaWMvYXNzZXRzL2FkbWluL3ZlbmRvci9zYXNzL3BhcGVyLWRhc2hib2FyZC5zY3NzLmpzIiwic291cmNlc0NvbnRlbnQiOlsiLy8gcmVtb3ZlZCBieSBleHRyYWN0LXRleHQtd2VicGFjay1wbHVnaW5cblxuXG4vLy8vLy8vLy8vLy8vLy8vLy9cbi8vIFdFQlBBQ0sgRk9PVEVSXG4vLyAuL3B1YmxpYy9hc3NldHMvYWRtaW4vdmVuZG9yL3Nhc3MvcGFwZXItZGFzaGJvYXJkLnNjc3Ncbi8vIG1vZHVsZSBpZCA9IC4vcHVibGljL2Fzc2V0cy9hZG1pbi92ZW5kb3Ivc2Fzcy9wYXBlci1kYXNoYm9hcmQuc2Nzc1xuLy8gbW9kdWxlIGNodW5rcyA9IDAiXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///./public/assets/admin/vendor/sass/paper-dashboard.scss\n");
eval("// removed by extract-text-webpack-plugin//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly8vLi9wdWJsaWMvYXNzZXRzL2FkbWluL3ZlbmRvci9zYXNzL3BhcGVyLWRhc2hib2FyZC5zY3NzP2M5ZDIiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEiLCJmaWxlIjoiLi9wdWJsaWMvYXNzZXRzL2FkbWluL3ZlbmRvci9zYXNzL3BhcGVyLWRhc2hib2FyZC5zY3NzLmpzIiwic291cmNlc0NvbnRlbnQiOlsiLy8gcmVtb3ZlZCBieSBleHRyYWN0LXRleHQtd2VicGFjay1wbHVnaW5cblxuXG4vLy8vLy8vLy8vLy8vLy8vLy9cbi8vIFdFQlBBQ0sgRk9PVEVSXG4vLyAuL3B1YmxpYy9hc3NldHMvYWRtaW4vdmVuZG9yL3Nhc3MvcGFwZXItZGFzaGJvYXJkLnNjc3Ncbi8vIG1vZHVsZSBpZCA9IC4vcHVibGljL2Fzc2V0cy9hZG1pbi92ZW5kb3Ivc2Fzcy9wYXBlci1kYXNoYm9hcmQuc2Nzc1xuLy8gbW9kdWxlIGNodW5rcyA9IDAiXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///./public/assets/admin/vendor/sass/paper-dashboard.scss\n");
/***/ }),
/***/ "./public/assets/frontend/sass/now-ui-kit.scss":
/***/ (function(module, exports) {
eval("// removed by extract-text-webpack-plugin//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly8vLi9wdWJsaWMvYXNzZXRzL2Zyb250ZW5kL3Nhc3Mvbm93LXVpLWtpdC5zY3NzPzY2YTciXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEiLCJmaWxlIjoiLi9wdWJsaWMvYXNzZXRzL2Zyb250ZW5kL3Nhc3Mvbm93LXVpLWtpdC5zY3NzLmpzIiwic291cmNlc0NvbnRlbnQiOlsiLy8gcmVtb3ZlZCBieSBleHRyYWN0LXRleHQtd2VicGFjay1wbHVnaW5cblxuXG4vLy8vLy8vLy8vLy8vLy8vLy9cbi8vIFdFQlBBQ0sgRk9PVEVSXG4vLyAuL3B1YmxpYy9hc3NldHMvZnJvbnRlbmQvc2Fzcy9ub3ctdWkta2l0LnNjc3Ncbi8vIG1vZHVsZSBpZCA9IC4vcHVibGljL2Fzc2V0cy9mcm9udGVuZC9zYXNzL25vdy11aS1raXQuc2Nzc1xuLy8gbW9kdWxlIGNodW5rcyA9IDAiXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///./public/assets/frontend/sass/now-ui-kit.scss\n");
eval("// removed by extract-text-webpack-plugin//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly8vLi9wdWJsaWMvYXNzZXRzL2Zyb250ZW5kL3Nhc3Mvbm93LXVpLWtpdC5zY3NzP2QxODMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEiLCJmaWxlIjoiLi9wdWJsaWMvYXNzZXRzL2Zyb250ZW5kL3Nhc3Mvbm93LXVpLWtpdC5zY3NzLmpzIiwic291cmNlc0NvbnRlbnQiOlsiLy8gcmVtb3ZlZCBieSBleHRyYWN0LXRleHQtd2VicGFjay1wbHVnaW5cblxuXG4vLy8vLy8vLy8vLy8vLy8vLy9cbi8vIFdFQlBBQ0sgRk9PVEVSXG4vLyAuL3B1YmxpYy9hc3NldHMvZnJvbnRlbmQvc2Fzcy9ub3ctdWkta2l0LnNjc3Ncbi8vIG1vZHVsZSBpZCA9IC4vcHVibGljL2Fzc2V0cy9mcm9udGVuZC9zYXNzL25vdy11aS1raXQuc2Nzc1xuLy8gbW9kdWxlIGNodW5rcyA9IDAiXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///./public/assets/frontend/sass/now-ui-kit.scss\n");
/***/ }),

View File

@@ -92,7 +92,7 @@
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
/******/
/******/ // __webpack_public_path__
/******/ __webpack_require__.p = "";
/******/ __webpack_require__.p = "/";
/******/
/******/ // on error function for async loading
/******/ __webpack_require__.oe = function(err) { console.error(err); throw err; };

File diff suppressed because one or more lines are too long

View File

@@ -1,349 +0,0 @@
/**
*
* @type {{render_airspace_map, render_live_map, render_route_map}}
*/
let phpvms = {};
phpvms.map = (function() {
const PLAN_ROUTE_COLOR = '#36b123';
const ACTUAL_ROUTE_COLOR = '#172aea';
const draw_base_map = (opts) => {
opts = _.defaults(opts, {
render_elem: 'map',
center: [29.98139, -95.33374],
zoom: 5,
maxZoom: 10,
layers: [],
set_marker: false,
});
let feature_groups = [];
/*var openaip_airspace_labels = new L.TileLayer.WMS(
"http://{s}.tile.maps.openaip.net/geowebcache/service/wms", {
maxZoom: 14,
minZoom: 12,
layers: 'openaip_approved_airspaces_labels',
tileSize: 1024,
detectRetina: true,
subdomains: '12',
format: 'image/png',
transparent: true
});
openaip_airspace_labels.addTo(map);*/
const opencyclemap_phys_osm = new L.TileLayer(
'http://{s}.tile.thunderforest.com/landscape/{z}/{x}/{y}.png?apikey=f09a38fa87514de4890fc96e7fe8ecb1', {
maxZoom: 14,
minZoom: 4,
format: 'image/png',
transparent: true
});
feature_groups.push(opencyclemap_phys_osm);
/*const openaip_cached_basemap = new L.TileLayer("http://{s}.tile.maps.openaip.net/geowebcache/service/tms/1.0.0/openaip_basemap@EPSG%3A900913@png/{z}/{x}/{y}.png", {
maxZoom: 14,
minZoom: 4,
tms: true,
detectRetina: true,
subdomains: '12',
format: 'image/png',
transparent: true
});
feature_groups.push(openaip_cached_basemap);
*/
const openaip_basemap_phys_osm = L.featureGroup(feature_groups);
let map = L.map('map', {
layers: [openaip_basemap_phys_osm],
center: opts.center,
zoom: opts.zoom,
scrollWheelZoom: false,
});
const attrib = L.control.attribution({position: 'bottomleft'});
attrib.addAttribution("<a href=\"https://www.thunderforest.com\" target=\"_blank\" style=\"\">Thunderforest</a>");
attrib.addAttribution("<a href=\"https://www.openaip.net\" target=\"_blank\" style=\"\">openAIP</a>");
attrib.addAttribution("<a href=\"https://www.openstreetmap.org/copyright\" target=\"_blank\" style=\"\">OpenStreetMap</a> contributors");
attrib.addAttribution("<a href=\"https://www.openweathermap.org\" target=\"_blank\" style=\"\">OpenWeatherMap</a>");
attrib.addTo(map);
return map;
};
/**
* Show some popup text when a feature is clicked on
* @param feature
* @param layer
*/
const onFeaturePointClick = (feature, layer) => {
let popup_html = "";
if (feature.properties && feature.properties.popup) {
popup_html += feature.properties.popup;
}
layer.bindPopup(popup_html);
};
/**
* Show each point as a marker
* @param feature
* @param latlng
* @returns {*}
*/
const pointToLayer = (feature, latlng) => {
return L.circleMarker(latlng, {
radius: 12,
fillColor: "#ff7800",
color: "#000",
weight: 1,
opacity: 1,
fillOpacity: 0.8
});
};
/**
*
* @param opts
* @private
*/
const _render_route_map = (opts) => {
opts = _.defaults(opts, {
route_points: null,
planned_route_line: null,
actual_route_points: null,
actual_route_line: null,
render_elem: 'map',
});
console.log(opts);
let map = draw_base_map(opts);
let geodesicLayer = L.geodesic([], {
weight: 7,
opacity: 0.9,
color: PLAN_ROUTE_COLOR,
steps: 50,
wrap: false,
}).addTo(map);
geodesicLayer.geoJson(opts.planned_route_line);
try {
map.fitBounds(geodesicLayer.getBounds());
} catch (e) { console.log(e); }
// Draw the route points after
if (opts.route_points !== null) {
let route_points = L.geoJSON(opts.route_points, {
onEachFeature: onFeaturePointClick,
pointToLayer: pointToLayer,
style: {
"color": PLAN_ROUTE_COLOR,
"weight": 5,
"opacity": 0.65,
},
});
route_points.addTo(map);
}
/**
* draw the actual route
*/
if (opts.actual_route_line !== null && opts.actual_route_line.features.length > 0) {
let geodesicLayer = L.geodesic([], {
weight: 7,
opacity: 0.9,
color: ACTUAL_ROUTE_COLOR,
steps: 50,
wrap: false,
}).addTo(map);
geodesicLayer.geoJson(opts.actual_route_line);
try {
map.fitBounds(geodesicLayer.getBounds());
} catch (e) {
console.log(e);
}
}
if (opts.actual_route_points !== null && opts.actual_route_points.features.length > 0) {
let route_points = L.geoJSON(opts.actual_route_points, {
onEachFeature: onFeaturePointClick,
pointToLayer: pointToLayer,
style: {
"color": ACTUAL_ROUTE_COLOR,
"weight": 5,
"opacity": 0.65,
},
});
route_points.addTo(map);
}
};
/**
* Render a map with the airspace, etc around a given set of coords
* e.g, the airport map
* @param opts
*/
const _render_airspace_map = (opts) => {
opts = _.defaults(opts, {
render_elem: 'map',
overlay_elem: '',
lat: 0,
lon: 0,
zoom: 12,
layers: [],
set_marker: false,
});
let map = draw_base_map(opts);
const coords = [opts.lat, opts.lon];
console.log('Applying coords', coords);
map.setView(coords, opts.zoom);
if (opts.set_marker === true) {
L.marker(coords).addTo(map);
}
return map;
};
/**
* Render the live map
* @param opts
* @private
*/
const _render_live_map = (opts) => {
opts = _.defaults(opts, {
update_uri: '/api/acars',
pirep_uri: '/api/pireps/{id}/acars',
positions: null,
render_elem: 'map',
aircraft_icon: '/assets/img/acars/aircraft.png',
});
const map = draw_base_map(opts);
const aircraftIcon = L.icon({
iconUrl: opts.aircraft_icon,
iconSize: [42, 42],
iconAnchor: [21, 21],
});
let layerFlights = null;
let layerSelFlight = null;
let layerSelFlightFeature = null;
let layerSelFlightLayer = null;
/**
* When a flight is clicked on, show the path, etc for that flight
* @param feature
* @param layer
*/
const onFlightClick = (feature, layer) => {
const uri = opts.pirep_uri.replace('{id}', feature.properties.pirep_id);
const flight_route = $.ajax({
url: uri,
dataType: "json",
error: console.log
});
$.when(flight_route).done((routeJson) => {
if(layerSelFlight !== null) {
map.removeLayer(layerSelFlight);
}
layerSelFlight = L.geodesic([], {
weight: 7,
opacity: 0.9,
color: ACTUAL_ROUTE_COLOR,
wrap: false,
}).addTo(map);
layerSelFlight.geoJson(routeJson.line);
layerSelFlightFeature = feature;
layerSelFlightLayer = layer;
//map.fitBounds(layerSelFlight.getBounds());
});
};
const updateMap = () => {
console.log('reloading flights from acars...');
/**
* AJAX UPDATE
*/
let flights = $.ajax({
url: opts.update_uri,
dataType: "json",
error: console.log
});
$.when(flights).done(function (flightGeoJson) {
if (layerFlights !== null) {
layerFlights.clearLayers();
}
layerFlights = L.geoJSON(flightGeoJson, {
onEachFeature: (feature, layer) => {
layer.on({
click: (e) => {
onFlightClick(feature, layer);
}
});
let popup_html = "";
if (feature.properties && feature.properties.popup) {
popup_html += feature.properties.popup;
}
layer.bindPopup(popup_html);
},
pointToLayer: function(feature, latlon) {
return L.marker(latlon, {
icon: aircraftIcon,
rotationAngle: feature.properties.heading
});
}
});
layerFlights.addTo(map);
if (layerSelFlight !== null) {
onFlightClick(layerSelFlightFeature, layerSelFlightLayer);
}
});
};
updateMap();
setInterval(updateMap, 10000);
};
return {
render_airspace_map: _render_airspace_map,
render_live_map: _render_live_map,
render_route_map: _render_route_map,
}
})();

View File

@@ -31415,7 +31415,7 @@ if (typeof jQuery === 'undefined') {
/**!
* @fileOverview Kickass library to create and place poppers near their reference elements.
* @version 1.14.0
* @version 1.14.1
* @license
* Copyright (c) 2016 Federico Zivolo and contributors
*
@@ -33935,7 +33935,7 @@ return Popper;
/**!
* @fileOverview Kickass library to create and place poppers near their reference elements.
* @version 1.14.0
* @version 1.14.1
* @license
* Copyright (c) 2016 Federico Zivolo and contributors
*

View File

@@ -1,22 +1,19 @@
{
"/assets/frontend/js/app.js": "/assets/frontend/js/app.js?id=3dade2872dd9c5f40690",
"/assets/frontend/js/app.js": "/assets/frontend/js/app.js?id=eecc1f2c64f432ce3c26",
"/assets/admin/vendor/paper-dashboard.css": "/assets/admin/vendor/paper-dashboard.css?id=1e97d08716e0c4630ae9",
"/assets/frontend/css/now-ui-kit.css": "/assets/frontend/css/now-ui-kit.css?id=9923ce002ceafb1d740a",
"/assets/frontend/js/vendor.js": "/assets/frontend/js/vendor.js?id=a6c163b9fbf4c3248a51",
"/assets/frontend/js/manifest.js": "/assets/frontend/js/manifest.js?id=8dc6cd78606fe58b6628",
"/assets/frontend/js/vendor.js": "/assets/frontend/js/vendor.js?id=4664ebb9eba378960b3a",
"/assets/frontend/js/manifest.js": "/assets/frontend/js/manifest.js?id=360cf4a2ac3af2c3da19",
"/assets/fonts/glyphicons-halflings-regular.woff2": "/assets/fonts/glyphicons-halflings-regular.woff2?id=b5b5055c6d812c0f9f0d",
"/assets/admin/fonts/glyphicons-halflings-regular.woff2": "/assets/admin/fonts/glyphicons-halflings-regular.woff2?id=b5b5055c6d812c0f9f0d",
"/assets/admin/js/icheck.js": "/assets/admin/js/icheck.js?id=14d0d9d9cae155580c5e",
"/assets/admin/js/bootstrap-editable.js": "/assets/admin/js/bootstrap-editable.js?id=48c6c28ec6f8b768f0d3",
"/assets/admin/js/bootstrap-editable.min.js": "/assets/admin/js/bootstrap-editable.min.js?id=3a6eeef3fbdb0d4cf5ba",
"/assets/admin/img/clear.png": "/assets/admin/img/clear.png?id=0e92f4c3efc6988a3c96",
"/assets/admin/img/loading.gif": "/assets/admin/img/loading.gif?id=90a4b76b4f11558691f6",
"/assets/admin/css/vendor.min.css": "/assets/admin/css/vendor.min.css?id=88e01e7683bc0807f1ba",
"/assets/admin/js/vendor.js": "/assets/admin/js/vendor.js?id=ffb4cf337de6d63b3ec6",
"/assets/admin/js/vendor.js": "/assets/admin/js/vendor.js?id=5a03d5e8f9ce3849e42c",
"/assets/admin/css/blue.png": "/assets/admin/css/blue.png?id=753a3c0dec86d3a38d9c",
"/assets/admin/css/blue@2x.png": "/assets/admin/css/blue@2x.png?id=97da23d47b838cbd4bef",
"/assets/system/js/jquery.js": "/assets/system/js/jquery.js?id=6a07da9fae934baf3f74",
"/assets/system/js/vendor.js": "/assets/system/js/vendor.js?id=0e6df5b264518fb37f48",
"/assets/system/js/vendor.js": "/assets/system/js/vendor.js?id=70b7294c8b1655b73a3c",
"/assets/system/css/vendor.min.css": "/assets/system/css/vendor.min.css?id=23451051c1ac99cae5fb",
"/assets/system/css/installer.css": "/assets/system/css/installer.css?id=1101b178b0383008aaa1",
"/assets/installer/js/vendor.js": "/assets/installer/js/vendor.js?id=efb330ef732d2f856623"

View File

@@ -99,10 +99,7 @@
</body>
<script defer src="https://use.fontawesome.com/releases/v5.0.6/js/all.js"></script>
{{--<script src="https://cdn.jsdelivr.net/npm/pjax@0.2.5/pjax.js"></script>--}}
<script src="{{ public_asset('/assets/admin/js/vendor.js') }}"></script>
<script src="{{ public_asset('/assets/system/js/phpvms.js') }}"></script>
<script src="{{ public_asset('/assets/admin/js/admin.js') }}"></script>
<script>

View File

@@ -22,8 +22,8 @@ mix.webpackConfig({
mix.copy('node_modules/bootstrap3/fonts/*.woff2', 'public/assets/fonts/')
mix.copy('node_modules/bootstrap3/fonts/*.woff2', 'public/assets/admin/fonts/')
mix.copy('node_modules/icheck/icheck.js', 'public/assets/admin/js/')
mix.copy('node_modules/x-editable/dist/bootstrap3-editable/js/*', 'public/assets/admin/js/')
//mix.copy('node_modules/icheck/icheck.js', 'public/assets/admin/js/')
//mix.copy('node_modules/x-editable/dist/bootstrap3-editable/js/*', 'public/assets/admin/js/')
mix.copy('node_modules/x-editable/dist/bootstrap3-editable/img/*', 'public/assets/admin/img/')
/**
@@ -59,16 +59,17 @@ mix.scripts([
'node_modules/x-editable/dist/bootstrap3-editable/js/bootstrap-editable.js',
'node_modules/eonasdan-bootstrap-datetimepicker/src/js/bootstrap-datetimepicker.js',
'node_modules/jquery-pjax/jquery.pjax.js',
], 'public/assets/admin/js/vendor.js')
'node_modues/paper-dashboard/assets/js/paper-dashboard.js',
], 'public/assets/admin/js/vendor.js');
mix.copy('node_modules/icheck/skins/square/blue*.png', 'public/assets/admin/css')
mix.copy('node_modules/icheck/skins/square/blue*.png', 'public/assets/admin/css');
/**
* SYSTEM REQUIRED AND GLOBAL VENDOR FILES
*/
mix.copy('node_modules/jquery/dist/jquery.js', 'public/assets/system/js/')
mix.copy('node_modules/flag-icon-css/flags/', 'public/assets/system/flags/')
mix.copy('node_modules/jquery/dist/jquery.js', 'public/assets/system/js/');
mix.copy('node_modules/flag-icon-css/flags/', 'public/assets/system/flags/');
mix.autoload({
'jquery': ['jQuery', '$'],