Kaynağa Gözat

chore: bump to 1.5.2 🎉

tags/v1.5.2
Shivam Mishra 4 yıl önce
ebeveyn
işleme
2572e317c7
13 değiştirilmiş dosya ile 42 ekleme ve 11 silme
  1. +23
    -0
      dist/frappe-charts.esm.js
  2. +1
    -1
      dist/frappe-charts.min.cjs.js
  3. +1
    -1
      dist/frappe-charts.min.cjs.js.map
  4. +1
    -1
      dist/frappe-charts.min.esm.js
  5. +1
    -1
      dist/frappe-charts.min.esm.js.map
  6. +1
    -1
      dist/frappe-charts.min.iife.js
  7. +1
    -1
      dist/frappe-charts.min.iife.js.map
  8. +1
    -1
      docs/assets/js/frappe-charts.min.js
  9. +1
    -1
      docs/assets/js/frappe-charts.min.js.map
  10. +8
    -0
      docs/assets/js/index.min.js
  11. +1
    -1
      docs/assets/js/index.min.js.map
  12. +1
    -1
      package.json
  13. +1
    -1
      src/js/index.js

+ 23
- 0
dist/frappe-charts.esm.js Dosyayı Görüntüle

@@ -364,6 +364,19 @@ function getPositionByAngle(angle, radius) {
};
}

/**
* Check if a number is valid for svg attributes
* @param {object} candidate Candidate to test
* @param {Boolean} nonNegative flag to treat negative number as invalid
*/
function isValidNumber(candidate, nonNegative=false) {
if (Number.isNaN(candidate)) return false;
else if (candidate === undefined) return false;
else if (!Number.isFinite(candidate)) return false;
else if (nonNegative && candidate < 0) return false;
else return true;
}

function getBarHeightAndYAttr(yTop, zeroLine) {
let height, y;
if (yTop <= zeroLine) {
@@ -864,6 +877,8 @@ function makeHoriLine(y, label, x1, x2, options={}) {
}

function yLine(y, label, width, options={}) {
if (!isValidNumber(y)) y = 0;

if(!options.pos) options.pos = 'left';
if(!options.offset) options.offset = 0;
if(!options.mode) options.mode = 'span';
@@ -892,6 +907,8 @@ function yLine(y, label, width, options={}) {
}

function xLine(x, label, height, options={}) {
if (!isValidNumber(x)) x = 0;

if(!options.pos) options.pos = 'bottom';
if(!options.offset) options.offset = 0;
if(!options.mode) options.mode = 'span';
@@ -1002,6 +1019,12 @@ function datasetBar(x, yTop, width, color, label='', index=0, offset=0, meta={})
y -= meta.minHeight;
}

// Preprocess numbers to avoid svg building errors
if (!isValidNumber(x)) x = 0;
if (!isValidNumber(y)) y = 0;
if (!isValidNumber(height, true)) height = 0;
if (!isValidNumber(width, true)) width = 0;

let rect = createSVG('rect', {
className: `bar mini`,
style: `fill: ${color}`,


+ 1
- 1
dist/frappe-charts.min.cjs.js
Dosya farkı çok büyük olduğundan ihmal edildi
Dosyayı Görüntüle


+ 1
- 1
dist/frappe-charts.min.cjs.js.map
Dosya farkı çok büyük olduğundan ihmal edildi
Dosyayı Görüntüle


+ 1
- 1
dist/frappe-charts.min.esm.js
Dosya farkı çok büyük olduğundan ihmal edildi
Dosyayı Görüntüle


+ 1
- 1
dist/frappe-charts.min.esm.js.map
Dosya farkı çok büyük olduğundan ihmal edildi
Dosyayı Görüntüle


+ 1
- 1
dist/frappe-charts.min.iife.js
Dosya farkı çok büyük olduğundan ihmal edildi
Dosyayı Görüntüle


+ 1
- 1
dist/frappe-charts.min.iife.js.map
Dosya farkı çok büyük olduğundan ihmal edildi
Dosyayı Görüntüle


+ 1
- 1
docs/assets/js/frappe-charts.min.js
Dosya farkı çok büyük olduğundan ihmal edildi
Dosyayı Görüntüle


+ 1
- 1
docs/assets/js/frappe-charts.min.js.map
Dosya farkı çok büyük olduğundan ihmal edildi
Dosyayı Görüntüle


+ 8
- 0
docs/assets/js/index.min.js Dosyayı Görüntüle

@@ -79,6 +79,14 @@ function getRandomBias(min, max, bias, influence) {
return rnd * (1 - mix) + biasValue * mix; // mix full range and bias
}



/**
* Check if a number is valid for svg attributes
* @param {object} candidate Candidate to test
* @param {Boolean} nonNegative flag to treat negative number as invalid
*/

// Playing around with dates




+ 1
- 1
docs/assets/js/index.min.js.map
Dosya farkı çok büyük olduğundan ihmal edildi
Dosyayı Görüntüle


+ 1
- 1
package.json Dosyayı Görüntüle

@@ -1,6 +1,6 @@
{
"name": "frappe-charts",
"version": "1.5.1",
"version": "1.5.2",
"description": "https://frappe.github.io/charts",
"main": "dist/frappe-charts.min.cjs.js",
"module": "dist/frappe-charts.min.esm.js",


+ 1
- 1
src/js/index.js Dosyayı Görüntüle

@@ -3,7 +3,7 @@ import * as Charts from './chart';
let frappe = { };

frappe.NAME = 'Frappe Charts';
frappe.VERSION = '1.5.1';
frappe.VERSION = '1.5.2';

frappe = Object.assign({ }, frappe, Charts);


Yükleniyor…
İptal
Kaydet