Commit inicial - WordPress Análisis de Precios Unitarios

- WordPress core y plugins
- Tema Twenty Twenty-Four configurado
- Plugin allow-unfiltered-html.php simplificado
- .gitignore configurado para excluir wp-config.php y uploads

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
root
2025-11-03 21:04:30 -06:00
commit a22573bf0b
24068 changed files with 4993111 additions and 0 deletions

View File

@@ -0,0 +1,207 @@
/*!
* Chart.BarFunnel.js
* http://chartjs.org/
* Version: 0.1.0
*
* Copyright 2016 Jorge Conde
* Released under the MIT license
* https://github.com/chartjs/Chart.Zoom.js/blob/master/LICENSE.md
*/
(function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){
(function(Chart) {
var helpers = Chart.helpers;
Chart.defaults.barFunnel = {
hover: {
mode: "label"
},
region: {
display: true,
borderColor: "#F6C85F",
backgroundColor: "rgba(246, 200, 95, 0.2)"
},
elements: {
rectangle: {
stepLabel: {
display: true,
fontSize: 20
// color: "red"
}
}
},
scales: {
xAxes: [{
type: "category",
// Specific to Bar Controller
categoryPercentage: 0.8,
barPercentage: 0.7,
// grid line settings
gridLines: {
offsetGridLines: true
}
}],
yAxes: [{
type: "linear"
}]
}
};
Chart.controllers.barFunnel = Chart.controllers.bar.extend({
updateElement: function updateElement(rectangle, index, reset, numBars) {
var meta = this.getMeta();
var xScale = this.getScaleForId(meta.xAxisID);
var yScale = this.getScaleForId(meta.yAxisID);
var yScalePoint;
if (yScale.min < 0 && yScale.max < 0) {
// all less than 0. use the top
yScalePoint = yScale.getPixelForValue(yScale.max);
} else if (yScale.min > 0 && yScale.max > 0) {
yScalePoint = yScale.getPixelForValue(yScale.min);
} else {
yScalePoint = yScale.getPixelForValue(0);
}
var chartOptions = this.chart.options;
var rectangleElementOptions = this.chart.options.elements.rectangle;
var custom = rectangle.custom || {};
var dataset = this.getDataset();
var ruler = this.getRuler(this.index);
helpers.extend(rectangle, {
// Utility
_chart: this.chart.chart,
_xScale: xScale,
_yScale: yScale,
_datasetIndex: this.index,
_index: index,
// Desired view properties
_model: {
x: this.calculateBarX(index, this.index, ruler),
y: reset ? yScalePoint : this.calculateBarY(index, this.index),
// Tooltip
label: this.chart.data.labels[index],
datasetLabel: dataset.label,
// Appearance
base: reset ? yScalePoint : this.calculateBarBase(this.index, index),
width: this.calculateBarWidth(ruler),
backgroundColor: custom.backgroundColor ? custom.backgroundColor : helpers.getValueAtIndexOrDefault(dataset.backgroundColor, index, rectangleElementOptions.backgroundColor),
borderSkipped: custom.borderSkipped ? custom.borderSkipped : rectangleElementOptions.borderSkipped,
borderColor: custom.borderColor ? custom.borderColor : helpers.getValueAtIndexOrDefault(dataset.borderColor, index, rectangleElementOptions.borderColor),
borderWidth: custom.borderWidth ? custom.borderWidth : helpers.getValueAtIndexOrDefault(dataset.borderWidth, index, rectangleElementOptions.borderWidth),
stepLabelColor: rectangleElementOptions.stepLabel.color ? rectangleElementOptions.stepLabel.color : helpers.getValueAtIndexOrDefault(dataset.borderColor, index, rectangleElementOptions.borderColor),
stepLabelFontSize: rectangleElementOptions.stepLabel.fontSize ? rectangleElementOptions.stepLabel.fontSize : chartOptions.defaultFontSize
},
draw: function () {
var ctx = this._chart.ctx;
var vm = this._view;
var options = this._chart.config.options;
var halfWidth = vm.width / 2,
leftX = vm.x - halfWidth,
rightX = vm.x + halfWidth,
top = vm.base - (vm.base - vm.y),
halfStroke = vm.borderWidth / 2;
// Canvas doesn't allow us to stroke inside the width so we can
// adjust the sizes to fit if we're setting a stroke on the line
if (vm.borderWidth) {
leftX += halfStroke;
rightX -= halfStroke;
top += halfStroke;
}
ctx.beginPath();
ctx.fillStyle = vm.backgroundColor;
ctx.strokeStyle = vm.borderColor;
ctx.lineWidth = vm.borderWidth;
// Corner points, from bottom-left to bottom-right clockwise
// | 1 2 |
// | 0 3 |
var corners = [
[leftX, vm.base],
[leftX, top],
[rightX, top],
[rightX, vm.base]
];
// Find first (starting) corner with fallback to 'bottom'
var borders = ['bottom', 'left', 'top', 'right'];
var startCorner = borders.indexOf(vm.borderSkipped, 0);
if (startCorner === -1)
startCorner = 0;
function cornerAt(index) {
return corners[(startCorner + index) % 4];
}
// Draw rectangle from 'startCorner'
ctx.moveTo.apply(ctx, cornerAt(0));
for (var i = 1; i < 4; i++)
ctx.lineTo.apply(ctx, cornerAt(i));
ctx.fill();
if (vm.borderWidth) {
ctx.stroke();
}
if(rectangleElementOptions.stepLabel.display && (index != 0)) {
var label = (dataset.data[index] / dataset.data[0]) * 100;
if (dataset.data[index] > 0) {
// Draw Step Label
ctx.font = vm.stepLabelFontSize + "px " + options.defaultFontFamily;
ctx.fillStyle = vm.stepLabelColor;
ctx.textAlign = "center";
ctx.fillText(label.toFixed(0) + "%", vm.x, vm.y - vm.stepLabelFontSize);
}
}
if (chartOptions.region.display && (index < meta.data.length - 1)) {
var nextVm = meta.data[index + 1]._view;
var regionCorners = [
[vm.x + halfWidth, top],
[nextVm.x - halfWidth, nextVm.base - (nextVm.base - nextVm.y - 1)],
[nextVm.x - halfWidth, nextVm.base],
[vm.x + halfWidth, vm.base]
];
ctx.beginPath();
ctx.strokeStyle = chartOptions.region.borderColor;
ctx.moveTo.apply(ctx, regionCorners[0]);
ctx.lineTo.apply(ctx, regionCorners[1]);
ctx.stroke();
ctx.beginPath();
ctx.strokeStyle = "transparent";
ctx.fillStyle = chartOptions.region.backgroundColor;
ctx.moveTo.apply(ctx, regionCorners[1]);
ctx.lineTo.apply(ctx, regionCorners[2]);
ctx.lineTo.apply(ctx, regionCorners[3]);
ctx.lineTo.apply(ctx, regionCorners[0]);
ctx.fill();
ctx.stroke();
}
}
});
rectangle.pivot();
}
});
}).call(this, Chart);
},{}]},{},[1]);

View File

@@ -0,0 +1,10 @@
/*!
* Chart.BarFunnel.js
* http://chartjs.org/
* Version: 0.1.0
*
* Copyright 2016 Jorge Conde
* Released under the MIT license
* https://github.com/chartjs/Chart.Zoom.js/blob/master/LICENSE.md
*/
!function e(t,r,o){function a(i,n){if(!r[i]){if(!t[i]){var d="function"==typeof require&&require;if(!n&&d)return d(i,!0);if(l)return l(i,!0);var s=new Error("Cannot find module '"+i+"'");throw s.code="MODULE_NOT_FOUND",s}var b=r[i]={exports:{}};t[i][0].call(b.exports,function(e){var r=t[i][1][e];return a(r?r:e)},b,b.exports,e,t,r,o)}return r[i].exports}for(var l="function"==typeof require&&require,i=0;i<o.length;i++)a(o[i]);return a}({1:[function(e,t,r){(function(e){var t=e.helpers;e.defaults.barFunnel={hover:{mode:"label"},region:{display:!0,borderColor:"#F6C85F",backgroundColor:"rgba(246, 200, 95, 0.2)"},elements:{rectangle:{stepLabel:{display:!0,fontSize:20}}},scales:{xAxes:[{type:"category",categoryPercentage:.8,barPercentage:.7,gridLines:{offsetGridLines:!0}}],yAxes:[{type:"linear"}]}},e.controllers.barFunnel=e.controllers.bar.extend({updateElement:function(e,r,o,a){var l,i=this.getMeta(),n=this.getScaleForId(i.xAxisID),d=this.getScaleForId(i.yAxisID);l=d.min<0&&d.max<0?d.getPixelForValue(d.max):d.min>0&&d.max>0?d.getPixelForValue(d.min):d.getPixelForValue(0);var s=this.chart.options,b=this.chart.options.elements.rectangle,p=e.custom||{},c=this.getDataset(),h=this.getRuler(this.index);t.extend(e,{_chart:this.chart.chart,_xScale:n,_yScale:d,_datasetIndex:this.index,_index:r,_model:{x:this.calculateBarX(r,this.index,h),y:o?l:this.calculateBarY(r,this.index),label:this.chart.data.labels[r],datasetLabel:c.label,base:o?l:this.calculateBarBase(this.index,r),width:this.calculateBarWidth(h),backgroundColor:p.backgroundColor?p.backgroundColor:t.getValueAtIndexOrDefault(c.backgroundColor,r,b.backgroundColor),borderSkipped:p.borderSkipped?p.borderSkipped:b.borderSkipped,borderColor:p.borderColor?p.borderColor:t.getValueAtIndexOrDefault(c.borderColor,r,b.borderColor),borderWidth:p.borderWidth?p.borderWidth:t.getValueAtIndexOrDefault(c.borderWidth,r,b.borderWidth),stepLabelColor:b.stepLabel.color?b.stepLabel.color:t.getValueAtIndexOrDefault(c.borderColor,r,b.borderColor),stepLabelFontSize:b.stepLabel.fontSize?b.stepLabel.fontSize:s.defaultFontSize},draw:function(){function e(e){return u[(f+e)%4]}var t=this._chart.ctx,o=this._view,a=this._chart.config.options,l=o.width/2,n=o.x-l,d=o.x+l,p=o.base-(o.base-o.y),h=o.borderWidth/2;o.borderWidth&&(n+=h,d-=h,p+=h),t.beginPath(),t.fillStyle=o.backgroundColor,t.strokeStyle=o.borderColor,t.lineWidth=o.borderWidth;var u=[[n,o.base],[n,p],[d,p],[d,o.base]],x=["bottom","left","top","right"],f=x.indexOf(o.borderSkipped,0);f===-1&&(f=0),t.moveTo.apply(t,e(0));for(var g=1;g<4;g++)t.lineTo.apply(t,e(g));if(t.fill(),o.borderWidth&&t.stroke(),b.stepLabel.display&&0!=r){var y=c.data[r]/c.data[0]*100;c.data[r]>0&&(t.font=o.stepLabelFontSize+"px "+a.defaultFontFamily,t.fillStyle=o.stepLabelColor,t.textAlign="center",t.fillText(y.toFixed(0)+"%",o.x,o.y-o.stepLabelFontSize))}if(s.region.display&&r<i.data.length-1){var C=i.data[r+1]._view,S=[[o.x+l,p],[C.x-l,C.base-(C.base-C.y-1)],[C.x-l,C.base],[o.x+l,o.base]];t.beginPath(),t.strokeStyle=s.region.borderColor,t.moveTo.apply(t,S[0]),t.lineTo.apply(t,S[1]),t.stroke(),t.beginPath(),t.strokeStyle="transparent",t.fillStyle=s.region.backgroundColor,t.moveTo.apply(t,S[1]),t.lineTo.apply(t,S[2]),t.lineTo.apply(t,S[3]),t.lineTo.apply(t,S[0]),t.fill(),t.stroke()}}}),e.pivot()}})}).call(this,Chart)},{}]},{},[1]);

File diff suppressed because it is too large Load Diff

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1 @@
<?php // silence is golden

View File

@@ -0,0 +1,342 @@
(function webpackUniversalModuleDefinition(root, factory) {
if(typeof exports === 'object' && typeof module === 'object')
module.exports = factory(require("chart.js"));
else if(typeof define === 'function' && define.amd)
define("VueChartJs", ["chart.js"], factory);
else if(typeof exports === 'object')
exports["VueChartJs"] = factory(require("chart.js"));
else
root["VueChartJs"] = factory(root["Chart"]);
})(typeof self !== 'undefined' ? self : this, function(__WEBPACK_EXTERNAL_MODULE_3__) {
return /******/ (function(modules) { // webpackBootstrap
/******/ // The module cache
/******/ var installedModules = {};
/******/
/******/ // The require function
/******/ function __webpack_require__(moduleId) {
/******/
/******/ // Check if module is in cache
/******/ if(installedModules[moduleId]) {
/******/ return installedModules[moduleId].exports;
/******/ }
/******/ // Create a new module (and put it into the cache)
/******/ var module = installedModules[moduleId] = {
/******/ i: moduleId,
/******/ l: false,
/******/ exports: {}
/******/ };
/******/
/******/ // Execute the module function
/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
/******/
/******/ // Flag the module as loaded
/******/ module.l = true;
/******/
/******/ // Return the exports of the module
/******/ return module.exports;
/******/ }
/******/
/******/
/******/ // expose the modules object (__webpack_modules__)
/******/ __webpack_require__.m = modules;
/******/
/******/ // expose the module cache
/******/ __webpack_require__.c = installedModules;
/******/
/******/ // define getter function for harmony exports
/******/ __webpack_require__.d = function(exports, name, getter) {
/******/ if(!__webpack_require__.o(exports, name)) {
/******/ Object.defineProperty(exports, name, {
/******/ configurable: false,
/******/ enumerable: true,
/******/ get: getter
/******/ });
/******/ }
/******/ };
/******/
/******/ // getDefaultExport function for compatibility with non-harmony modules
/******/ __webpack_require__.n = function(module) {
/******/ var getter = module && module.__esModule ?
/******/ function getDefault() { return module['default']; } :
/******/ function getModuleExports() { return module; };
/******/ __webpack_require__.d(getter, 'a', getter);
/******/ return getter;
/******/ };
/******/
/******/ // Object.prototype.hasOwnProperty.call
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
/******/
/******/ // __webpack_public_path__
/******/ __webpack_require__.p = "";
/******/
/******/ // Load entry module and return exports
/******/ return __webpack_require__(__webpack_require__.s = 0);
/******/ })
/************************************************************************/
/******/ ([
/* 0 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
Object.defineProperty(__webpack_exports__, "__esModule", { value: true });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "VueCharts", function() { return VueCharts; });
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__mixins_index_js__ = __webpack_require__(1);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__BaseCharts__ = __webpack_require__(2);
/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "Bar", function() { return __WEBPACK_IMPORTED_MODULE_1__BaseCharts__["a"]; });
/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "HorizontalBar", function() { return __WEBPACK_IMPORTED_MODULE_1__BaseCharts__["d"]; });
/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "Doughnut", function() { return __WEBPACK_IMPORTED_MODULE_1__BaseCharts__["c"]; });
/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "Line", function() { return __WEBPACK_IMPORTED_MODULE_1__BaseCharts__["e"]; });
/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "Pie", function() { return __WEBPACK_IMPORTED_MODULE_1__BaseCharts__["f"]; });
/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "PolarArea", function() { return __WEBPACK_IMPORTED_MODULE_1__BaseCharts__["g"]; });
/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "Radar", function() { return __WEBPACK_IMPORTED_MODULE_1__BaseCharts__["h"]; });
/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "Bubble", function() { return __WEBPACK_IMPORTED_MODULE_1__BaseCharts__["b"]; });
/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "Scatter", function() { return __WEBPACK_IMPORTED_MODULE_1__BaseCharts__["i"]; });
/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "mixins", function() { return __WEBPACK_IMPORTED_MODULE_0__mixins_index_js__["a"]; });
/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "generateChart", function() { return __WEBPACK_IMPORTED_MODULE_1__BaseCharts__["j"]; });
var VueCharts = {
Bar: __WEBPACK_IMPORTED_MODULE_1__BaseCharts__["a" /* Bar */],
HorizontalBar: __WEBPACK_IMPORTED_MODULE_1__BaseCharts__["d" /* HorizontalBar */],
Doughnut: __WEBPACK_IMPORTED_MODULE_1__BaseCharts__["c" /* Doughnut */],
Line: __WEBPACK_IMPORTED_MODULE_1__BaseCharts__["e" /* Line */],
Pie: __WEBPACK_IMPORTED_MODULE_1__BaseCharts__["f" /* Pie */],
PolarArea: __WEBPACK_IMPORTED_MODULE_1__BaseCharts__["g" /* PolarArea */],
Radar: __WEBPACK_IMPORTED_MODULE_1__BaseCharts__["h" /* Radar */],
Bubble: __WEBPACK_IMPORTED_MODULE_1__BaseCharts__["b" /* Bubble */],
Scatter: __WEBPACK_IMPORTED_MODULE_1__BaseCharts__["i" /* Scatter */],
mixins: __WEBPACK_IMPORTED_MODULE_0__mixins_index_js__["a" /* default */],
generateChart: __WEBPACK_IMPORTED_MODULE_1__BaseCharts__["j" /* generateChart */],
render: function render() {
return console.error('[vue-chartjs]: This is not a vue component. It is the whole object containing all vue components. Please import the named export or access the components over the dot notation. For more info visit https://vue-chartjs.org/#/home?id=quick-start');
}
};
/* harmony default export */ __webpack_exports__["default"] = (VueCharts);
/***/ }),
/* 1 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
/* unused harmony export reactiveData */
/* unused harmony export reactiveProp */
function dataHandler(newData, oldData) {
if (oldData) {
var chart = this.$data._chart;
var newDatasetLabels = newData.datasets.map(function (dataset) {
return dataset.label;
});
var oldDatasetLabels = oldData.datasets.map(function (dataset) {
return dataset.label;
});
var oldLabels = JSON.stringify(oldDatasetLabels);
var newLabels = JSON.stringify(newDatasetLabels);
if (newLabels === oldLabels && oldData.datasets.length === newData.datasets.length) {
newData.datasets.forEach(function (dataset, i) {
var oldDatasetKeys = Object.keys(oldData.datasets[i]);
var newDatasetKeys = Object.keys(dataset);
var deletionKeys = oldDatasetKeys.filter(function (key) {
return key !== '_meta' && newDatasetKeys.indexOf(key) === -1;
});
deletionKeys.forEach(function (deletionKey) {
delete chart.data.datasets[i][deletionKey];
});
for (var attribute in dataset) {
if (dataset.hasOwnProperty(attribute)) {
chart.data.datasets[i][attribute] = dataset[attribute];
}
}
});
if (newData.hasOwnProperty('labels')) {
chart.data.labels = newData.labels;
this.$emit('labels:update');
}
if (newData.hasOwnProperty('xLabels')) {
chart.data.xLabels = newData.xLabels;
this.$emit('xlabels:update');
}
if (newData.hasOwnProperty('yLabels')) {
chart.data.yLabels = newData.yLabels;
this.$emit('ylabels:update');
}
chart.update();
this.$emit('chart:update');
} else {
if (chart) {
chart.destroy();
this.$emit('chart:destroy');
}
this.renderChart(this.chartData, this.options);
this.$emit('chart:render');
}
} else {
if (this.$data._chart) {
this.$data._chart.destroy();
this.$emit('chart:destroy');
}
this.renderChart(this.chartData, this.options);
this.$emit('chart:render');
}
}
var reactiveData = {
data: function data() {
return {
chartData: null
};
},
watch: {
'chartData': dataHandler
}
};
var reactiveProp = {
props: {
chartData: {
type: Object,
required: true,
default: function _default() {}
}
},
watch: {
'chartData': dataHandler
}
};
/* harmony default export */ __webpack_exports__["a"] = ({
reactiveData: reactiveData,
reactiveProp: reactiveProp
});
/***/ }),
/* 2 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
/* harmony export (immutable) */ __webpack_exports__["j"] = generateChart;
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return Bar; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "d", function() { return HorizontalBar; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "c", function() { return Doughnut; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "e", function() { return Line; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "f", function() { return Pie; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "g", function() { return PolarArea; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "h", function() { return Radar; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return Bubble; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "i", function() { return Scatter; });
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_chart_js__ = __webpack_require__(3);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_chart_js___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_chart_js__);
function generateChart(chartId, chartType) {
return {
render: function render(createElement) {
return createElement('div', {
style: this.styles,
class: this.cssClasses
}, [createElement('canvas', {
attrs: {
id: this.chartId,
width: this.width,
height: this.height
},
ref: 'canvas'
})]);
},
props: {
chartId: {
default: chartId,
type: String
},
width: {
default: 400,
type: Number
},
height: {
default: 400,
type: Number
},
cssClasses: {
type: String,
default: ''
},
styles: {
type: Object
},
plugins: {
type: Array,
default: function _default() {
return [];
}
}
},
data: function data() {
return {
_chart: null,
_plugins: this.plugins
};
},
methods: {
addPlugin: function addPlugin(plugin) {
this.$data._plugins.push(plugin);
},
generateLegend: function generateLegend() {
if (this.$data._chart) {
return this.$data._chart.generateLegend();
}
},
renderChart: function renderChart(data, options) {
if (this.$data._chart) this.$data._chart.destroy();
if (!this.$refs.canvas) throw new Error('Please remove the <template></template> tags from your chart component. See https://vue-chartjs.org/guide/#vue-single-file-components');
this.$data._chart = new __WEBPACK_IMPORTED_MODULE_0_chart_js___default.a(this.$refs.canvas.getContext('2d'), {
type: chartType,
data: data,
options: options,
plugins: this.$data._plugins
});
}
},
beforeDestroy: function beforeDestroy() {
if (this.$data._chart) {
this.$data._chart.destroy();
}
}
};
}
var Bar = generateChart('bar-chart', 'bar');
var HorizontalBar = generateChart('horizontalbar-chart', 'horizontalBar');
var Doughnut = generateChart('doughnut-chart', 'doughnut');
var Line = generateChart('line-chart', 'line');
var Pie = generateChart('pie-chart', 'pie');
var PolarArea = generateChart('polar-chart', 'polarArea');
var Radar = generateChart('radar-chart', 'radar');
var Bubble = generateChart('bubble-chart', 'bubble');
var Scatter = generateChart('scatter-chart', 'scatter');
/* unused harmony default export */ var _unused_webpack_default_export = ({
Bar: Bar,
HorizontalBar: HorizontalBar,
Doughnut: Doughnut,
Line: Line,
Pie: Pie,
PolarArea: PolarArea,
Radar: Radar,
Bubble: Bubble,
Scatter: Scatter
});
/***/ }),
/* 3 */
/***/ (function(module, exports) {
module.exports = __WEBPACK_EXTERNAL_MODULE_3__;
/***/ })
/******/ ]);
});
//# sourceMappingURL=vue-chartjs.js.map

View File

@@ -0,0 +1 @@
!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e(require("chart.js")):"function"==typeof define&&define.amd?define("VueChartJs",["chart.js"],e):"object"==typeof exports?exports.VueChartJs=e(require("chart.js")):t.VueChartJs=e(t.Chart)}("undefined"!=typeof self?self:this,function(t){return function(t){function e(a){if(r[a])return r[a].exports;var n=r[a]={i:a,l:!1,exports:{}};return t[a].call(n.exports,n,n.exports,e),n.l=!0,n.exports}var r={};return e.m=t,e.c=r,e.d=function(t,r,a){e.o(t,r)||Object.defineProperty(t,r,{configurable:!1,enumerable:!0,get:a})},e.n=function(t){var r=t&&t.__esModule?function(){return t.default}:function(){return t};return e.d(r,"a",r),r},e.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},e.p="",e(e.s=0)}([function(t,e,r){"use strict";function a(t,e){if(e){var r=this.$data._chart,a=t.datasets.map(function(t){return t.label}),n=e.datasets.map(function(t){return t.label}),s=JSON.stringify(n);JSON.stringify(a)===s&&e.datasets.length===t.datasets.length?(t.datasets.forEach(function(t,a){var n=Object.keys(e.datasets[a]),s=Object.keys(t);n.filter(function(t){return"_meta"!==t&&-1===s.indexOf(t)}).forEach(function(t){delete r.data.datasets[a][t]});for(var i in t)t.hasOwnProperty(i)&&(r.data.datasets[a][i]=t[i])}),t.hasOwnProperty("labels")&&(r.data.labels=t.labels,this.$emit("labels:update")),t.hasOwnProperty("xLabels")&&(r.data.xLabels=t.xLabels,this.$emit("xlabels:update")),t.hasOwnProperty("yLabels")&&(r.data.yLabels=t.yLabels,this.$emit("ylabels:update")),r.update(),this.$emit("chart:update")):(r&&(r.destroy(),this.$emit("chart:destroy")),this.renderChart(this.chartData,this.options),this.$emit("chart:render"))}else this.$data._chart&&(this.$data._chart.destroy(),this.$emit("chart:destroy")),this.renderChart(this.chartData,this.options),this.$emit("chart:render")}function n(t,e){return{render:function(t){return t("div",{style:this.styles,class:this.cssClasses},[t("canvas",{attrs:{id:this.chartId,width:this.width,height:this.height},ref:"canvas"})])},props:{chartId:{default:t,type:String},width:{default:400,type:Number},height:{default:400,type:Number},cssClasses:{type:String,default:""},styles:{type:Object},plugins:{type:Array,default:function(){return[]}}},data:function(){return{_chart:null,_plugins:this.plugins}},methods:{addPlugin:function(t){this.$data._plugins.push(t)},generateLegend:function(){if(this.$data._chart)return this.$data._chart.generateLegend()},renderChart:function(t,r){if(this.$data._chart&&this.$data._chart.destroy(),!this.$refs.canvas)throw new Error("Please remove the <template></template> tags from your chart component. See https://vue-chartjs.org/guide/#vue-single-file-components");this.$data._chart=new c.a(this.$refs.canvas.getContext("2d"),{type:e,data:t,options:r,plugins:this.$data._plugins})}},beforeDestroy:function(){this.$data._chart&&this.$data._chart.destroy()}}}Object.defineProperty(e,"__esModule",{value:!0});var s={data:function(){return{chartData:null}},watch:{chartData:a}},i={props:{chartData:{type:Object,required:!0,default:function(){}}},watch:{chartData:a}},o={reactiveData:s,reactiveProp:i},u=r(1),c=r.n(u),h=n("bar-chart","bar"),d=n("horizontalbar-chart","horizontalBar"),l=n("doughnut-chart","doughnut"),f=n("line-chart","line"),p=n("pie-chart","pie"),b=n("polar-chart","polarArea"),y=n("radar-chart","radar"),g=n("bubble-chart","bubble"),m=n("scatter-chart","scatter");r.d(e,"VueCharts",function(){return v}),r.d(e,"Bar",function(){return h}),r.d(e,"HorizontalBar",function(){return d}),r.d(e,"Doughnut",function(){return l}),r.d(e,"Line",function(){return f}),r.d(e,"Pie",function(){return p}),r.d(e,"PolarArea",function(){return b}),r.d(e,"Radar",function(){return y}),r.d(e,"Bubble",function(){return g}),r.d(e,"Scatter",function(){return m}),r.d(e,"mixins",function(){return o}),r.d(e,"generateChart",function(){return n});var v={Bar:h,HorizontalBar:d,Doughnut:l,Line:f,Pie:p,PolarArea:b,Radar:y,Bubble:g,Scatter:m,mixins:o,generateChart:n,render:function(){return console.error("[vue-chartjs]: This is not a vue component. It is the whole object containing all vue components. Please import the named export or access the components over the dot notation. For more info visit https://vue-chartjs.org/#/home?id=quick-start")}};e.default=v},function(e,r){e.exports=t}])});

View File

@@ -0,0 +1 @@
<?php // silence is golden

View File

@@ -0,0 +1 @@
<?php // silence is golden

File diff suppressed because it is too large Load Diff

File diff suppressed because one or more lines are too long