Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@hpcc-js/api

Package Overview
Dependencies
Maintainers
1
Versions
198
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@hpcc-js/api - npm Package Compare versions

Comparing version 0.0.70 to 0.0.71

2

dist/index.es6.js

@@ -139,3 +139,3 @@ function __$styleInject(css, returnValue) {

};
IInput.prototype.change = function (_w) {
IInput.prototype.change = function (_w, complete) {
};

@@ -142,0 +142,0 @@ IInput.prototype.resetValue = function (w) {

@@ -143,3 +143,3 @@ (function (global, factory) {

};
IInput.prototype.change = function (_w) {
IInput.prototype.change = function (_w, complete) {
};

@@ -146,0 +146,0 @@ IInput.prototype.resetValue = function (w) {

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

!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports,require("@hpcc-js/common")):"function"==typeof define&&define.amd?define(["exports","@hpcc-js/common"],e):e(t["@hpcc-js/api"]={},t["@hpcc-js/common"])}(this,function(t,e){"use strict";function n(){}function o(){}function r(){}function i(t,e){function n(){this.constructor=t}g(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}function l(){}function a(t,e){if((n=(t=e?t.toExponential(e-1):t.toExponential()).indexOf("e"))<0)return null;var n,o=t.slice(0,n);return[o.length>1?o[0]+o.slice(2):o,+t.slice(n+1)]}function s(t,e){var n=a(t,e);if(!n)return t+"";var o=n[0],r=n[1];return r<0?"0."+new Array(-r).join("0")+o:o.length>r+1?o.slice(0,r+1)+"."+o.slice(r+1):o+new Array(r-o.length+2).join("0")}function u(t){return new c(t)}function c(t){if(!(e=b.exec(t)))throw new Error("invalid format: "+t);var e,n=e[1]||" ",o=e[2]||">",r=e[3]||"-",i=e[4]||"",l=!!e[5],a=e[6]&&+e[6],s=!!e[7],u=e[8]&&+e[8].slice(1),c=e[9]||"";"n"===c?(s=!0,c="g"):x[c]||(c=""),(l||"0"===n&&"="===o)&&(l=!0,n="0",o="="),this.fill=n,this.align=o,this.sign=r,this.symbol=i,this.zero=l,this.width=a,this.comma=s,this.precision=u,this.type=c}function p(t){return t}function f(t){function e(t){function e(t){var e,o,l,u=v,p=b;if("c"===g)p=w(t)+p,t="";else{var x=(t=+t)<0;if(t=w(Math.abs(t),d),x&&0==+t&&(x=!1),u=(x?"("===c?c:"-":"-"===c||"("===c?"":c)+u,p=p+("s"===g?E[8+m/3]:"")+(x&&"("===c?")":""),k)for(e=-1,o=t.length;++e<o;)if(48>(l=t.charCodeAt(e))||l>57){p=(46===l?r+t.slice(e+1):t.slice(e))+p,t=t.slice(0,e);break}}y&&!f&&(t=n(t,1/0));var C=u.length+t.length+p.length,S=C<h?new Array(h-C+1).join(a):"";switch(y&&f&&(t=n(S+t,S.length?h-p.length:1/0),S=""),s){case"<":t=u+t+p+S;break;case"=":t=u+S+t+p;break;case"^":t=S.slice(0,C=S.length>>1)+u+t+p+S.slice(C);break;default:t=S+u+t+p}return i(t)}var a=(t=u(t)).fill,s=t.align,c=t.sign,p=t.symbol,f=t.zero,h=t.width,y=t.comma,d=t.precision,g=t.type,v="$"===p?o[0]:"#"===p&&/[boxX]/.test(g)?"0"+g.toLowerCase():"",b="$"===p?o[1]:/[%p]/.test(g)?l:"",w=x[g],k=!g||/[defgprs%]/.test(g);return d=null==d?g?6:12:/[gprs]/.test(g)?Math.max(1,Math.min(21,d)):Math.max(0,Math.min(20,d)),e.toString=function(){return t+""},e}var n=t.grouping&&t.thousands?function(t,e){return function(n,o){for(var r=n.length,i=[],l=0,a=t[0],s=0;r>0&&a>0&&(s+a+1>o&&(a=Math.max(1,o-s)),i.push(n.substring(r-=a,r+a)),!((s+=a+1)>o));)a=t[l=(l+1)%t.length];return i.reverse().join(e)}}(t.grouping,t.thousands):p,o=t.currency,r=t.decimal,i=t.numerals?function(t){return function(e){return e.replace(/[0-9]/g,function(e){return t[+e]})}}(t.numerals):p,l=t.percent||"%";return{format:e,formatPrefix:function(t,n){var o=e((t=u(t),t.type="f",t)),r=3*Math.max(-8,Math.min(8,Math.floor(function(t){return(t=a(Math.abs(t)))?t[1]:NaN}(n)/3))),i=Math.pow(10,-r),l=E[8+r/3];return function(t){return o(i*t)+l}}}}function h(){}function y(t,e){var n=new h;if(t instanceof h)t.each(function(t,e){n.set(e,t)});else if(Array.isArray(t)){var o,r=-1,i=t.length;if(null==e)for(;++r<i;)n.set(r,t[r]);else for(;++r<i;)n.set(e(o=t[r],r,t),o)}else if(t)for(var l in t)n.set(l,t[l]);return n}function d(){}n.prototype._palette=e.Palette.rainbow("default"),n.prototype.click=function(t,e,n){console.log("Click: "+JSON.stringify(t)+", "+e+", "+n)},n.prototype.dblclick=function(t,e,n){console.log("Double click: "+JSON.stringify(t)+", "+e+", "+n)},o.prototype._palette=e.Palette.ordinal("default"),o.prototype.click=function(t,e,n){console.log("Click: "+JSON.stringify(t)+", "+e+", "+n)},o.prototype.dblclick=function(t,e,n){console.log("Double click: "+JSON.stringify(t)+", "+e+", "+n)},r.prototype.vertex_click=function(t,e,n,o){o&&o.vertex&&console.log("Vertex click: "+o.vertex.id())},r.prototype.vertex_dblclick=function(t,e,n,o){o&&o.vertex&&console.log("Vertex double click: "+o.vertex.id())},r.prototype.edge_click=function(t,e,n,o){o&&o.edge&&console.log("Edge click: "+o.edge.id())},r.prototype.edge_dblclick=function(t,e,n,o){o&&o.edge&&console.log("Edge double click: "+o.edge.id())};var g=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},v=function(t){function e(){return t.call(this)||this}return i(e,t),e.prototype.isValid=function(){if(this.validate()){if(!new RegExp(this.validate()).test(this.value()))return!1}return!0},e.prototype.hasValue=function(){if("function"==typeof this.type){switch(this.type()){case"radio":case"checkbox":if(this.value()&&"false"!==this.value())return!0;break;default:if(this.value())return!0}return!1}return""!==this.value()},e.prototype.blur=function(t){},e.prototype.click=function(t){},e.prototype.dblclick=function(t){},e.prototype.change=function(t){},e.prototype.resetValue=function(t){t.value(t._inputElement[0].node().value)},e.prototype.disable=function(t){this._inputElement.forEach(function(e,n){e.attr("disabled",t?"disabled":null)})},e.prototype.setFocus=function(){this._inputElement.length&&this._inputElement[0].node().focus()},e}(e.Widget);v.prototype.publish("name","","string","HTML name for the input"),v.prototype.publish("label","","string","Descriptive label"),v.prototype.publish("value","","string","Input Current Value"),v.prototype.publish("validate",null,"string","Input Validation"),l.prototype._palette=e.Palette.ordinal("default"),l.prototype.click=function(t,e,n){console.log("Click: "+JSON.stringify(t)+", "+e+", "+n)},l.prototype.dblclick=function(t,e,n){console.log("Double click: "+JSON.stringify(t)+", "+e+", "+n)};var m,x={"":function(t,e){t:for(var n,o=(t=t.toPrecision(e)).length,r=1,i=-1;r<o;++r)switch(t[r]){case".":i=n=r;break;case"0":0===i&&(i=r),n=r;break;case"e":break t;default:i>0&&(i=0)}return i>0?t.slice(0,i)+t.slice(n+1):t},"%":function(t,e){return(100*t).toFixed(e)},b:function(t){return Math.round(t).toString(2)},c:function(t){return t+""},d:function(t){return Math.round(t).toString(10)},e:function(t,e){return t.toExponential(e)},f:function(t,e){return t.toFixed(e)},g:function(t,e){return t.toPrecision(e)},o:function(t){return Math.round(t).toString(8)},p:function(t,e){return s(100*t,e)},r:s,s:function(t,e){var n=a(t,e);if(!n)return t+"";var o=n[0],r=n[1],i=r-(m=3*Math.max(-8,Math.min(8,Math.floor(r/3))))+1,l=o.length;return i===l?o:i>l?o+new Array(i-l+1).join("0"):i>0?o.slice(0,i)+"."+o.slice(i):"0."+new Array(1-i).join("0")+a(t,Math.max(0,e+i-1))[0]},X:function(t){return Math.round(t).toString(16).toUpperCase()},x:function(t){return Math.round(t).toString(16)}},b=/^(?:(.)?([<>=^]))?([+\-\( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?([a-z%])?$/i;u.prototype=c.prototype,c.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(null==this.width?"":Math.max(1,0|this.width))+(this.comma?",":"")+(null==this.precision?"":"."+Math.max(0,0|this.precision))+this.type};var w,k,C,E=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];!function(t){w=f(t),k=w.format,C=w.formatPrefix}({decimal:".",thousands:",",grouping:[3],currency:["$",""]});h.prototype=y.prototype={constructor:h,has:function(t){return"$"+t in this},get:function(t){return this["$"+t]},set:function(t,e){return this["$"+t]=e,this},remove:function(t){var e="$"+t;return e in this&&delete this[e]},clear:function(){for(var t in this)"$"===t[0]&&delete this[t]},keys:function(){var t=[];for(var e in this)"$"===e[0]&&t.push(e.slice(1));return t},values:function(){var t=[];for(var e in this)"$"===e[0]&&t.push(this[e]);return t},entries:function(){var t=[];for(var e in this)"$"===e[0]&&t.push({key:e.slice(1),value:this[e]});return t},size:function(){var t=0;for(var e in this)"$"===e[0]&&++t;return t},empty:function(){for(var t in this)if("$"===t[0])return!1;return!0},each:function(t){for(var e in this)"$"===e[0]&&t(this[e],e.slice(1),this)}};var S=y.prototype;d.prototype=function(t,e){var n=new d;if(t instanceof d)t.each(function(t){n.add(t)});else if(t){var o=-1,r=t.length;if(null==e)for(;++o<r;)n.add(t[o]);else for(;++o<r;)n.add(e(t[o],o,t))}return n}.prototype={constructor:d,has:S.has,add:function(t){return t+="",this["$"+t]=t,this},remove:S.remove,clear:S.clear,values:S.keys,size:S.size,empty:S.empty,each:S.each},function(t,e){if("undefined"==typeof document)return e;t=t||"";var n=document.head||document.getElementsByTagName("head")[0],o=document.createElement("style");o.type="text/css",n.appendChild(o),o.styleSheet?o.styleSheet.cssText=t:o.appendChild(document.createTextNode(t))}('.d3-tip {\r\n line-height: 1;\r\n font-weight: bold;\r\n padding: 12px;\r\n background: rgba(0, 0, 0, 0.66);\r\n color: #fff;\r\n border-radius: 2px;\r\n pointer-events: none !important;\r\n z-index:10;\r\n}\r\n\r\n.d3-tip.hidden {\r\n visibility:hidden;\r\n}\r\n\r\n/* Creates a small triangle extender for the tooltip */\r\n.d3-tip:after {\r\n box-sizing: border-box;\r\n display: inline;\r\n font-size: 10px;\r\n width: 100%;\r\n line-height: 1;\r\n color: rgba(0, 0, 0, 0.66);\r\n position: absolute;\r\n pointer-events: none !important;\r\n}\r\n\r\n/* Northward tooltips */\r\n.d3-tip.n:after {\r\n content: "\\25BC";\r\n margin: -1px 0 0 0;\r\n top: 100%;\r\n left: 0;\r\n text-align: center;\r\n}\r\n\r\n/* Eastward tooltips */\r\n.d3-tip.e:after {\r\n content: "\\25C0";\r\n margin: -4px 0 0 0;\r\n top: 50%;\r\n left: -8px;\r\n}\r\n\r\n/* Southward tooltips */\r\n.d3-tip.s:after {\r\n content: "\\25B2";\r\n margin: 0 0 1px 0;\r\n top: -8px;\r\n left: 0;\r\n text-align: center;\r\n}\r\n\r\n/* Westward tooltips */\r\n.d3-tip.w:after {\r\n content: "\\25B6";\r\n margin: -4px 0 0 -1px;\r\n top: 50%;\r\n left: 100%;\r\n}\r\n\r\n.d3-tip.notick:after {\r\n content: "" !important;\r\n}\r\n\r\n.common_Widget .over {\r\n stroke: rgba(0, 0, 0, 0.66);\r\n opacity: 0.66;\r\n}\r\n',void 0);var M=function(t){function n(){var e=t.call(this)||this;if(e._valueFormatter=k(e.tooltipValueFormat()),e.layerEnter){var n=e.layerEnter;e.layerEnter=function(t,e,o){this.tooltipEnter(e),n.apply(this,arguments)};var o=e.layerUpdate;e.layerUpdate=function(t){o.apply(this,arguments),this.tooltipUpdate()};var r=e.layerExit;e.layerExit=function(t){r.apply(this,arguments),this.tooltipExit()}}else{var i=e.enter;e.enter=function(t,e){this.tooltipEnter(e),i.apply(this,arguments)};var l=e.update;e.update=function(t,e){l.apply(this,arguments),this.tooltipUpdate()};var a=e.exit;e.exit=function(t,e){a.apply(this,arguments),this.tooltipExit()}}return e}return i(n,t),n.prototype.tooltipEnter=function(t){var n=this;this.tooltip=function(){function t(t){(p=function(e){var n=t.node();return n?"svg"===n.tagName.toLowerCase()?n:n.ownerSVGElement:null}())&&(f=p.createSVGPoint(),u().appendChild(c))}function n(){var t=e.select(document.createElement("div"));return t.style("position","absolute").style("top",0).style("opacity",0).style("pointer-events","none").style("box-sizing","border-box"),t.node()}function o(){return null==c&&(c=n(),u().appendChild(c)),e.select(c)}function r(){for(var t=h||event.target;null==t.getScreenCTM&&null==t.parentNode;)t=t.parentNode;var e={},n=t.getScreenCTM(),o=t.getBBox(),r=o.width,i=o.height,l=o.x,a=o.y;return f.x=l,f.y=a,e.nw=f.matrixTransform(n),f.x+=r,e.ne=f.matrixTransform(n),f.y+=i,e.se=f.matrixTransform(n),f.x-=r,e.sw=f.matrixTransform(n),f.y-=i/2,e.w=f.matrixTransform(n),f.x+=r,e.e=f.matrixTransform(n),f.x-=r/2,f.y-=i/2,e.n=f.matrixTransform(n),f.y+=i,e.s=f.matrixTransform(n),e}function i(t){return"function"==typeof t?t:function(){return t}}var l=function(){return"n"},a=function(){return[0,0]},s=function(){return" "},u=i(document.body),c=n(),p=null,f=null,h=null;t.show=function(){var e=Array.prototype.slice.call(arguments);e[e.length-1]instanceof SVGElement&&(h=e.pop());var n,r=s.apply(this,e),i=a.apply(this,e),c=l.apply(this,e),p=o(),f=g.length,y=document.documentElement.scrollTop||u().scrollTop,v=document.documentElement.scrollLeft||u().scrollLeft;for(p.html(r).style("opacity",1).style("pointer-events","all");f--;)p.classed(g[f],!1);return n=d.get(c).apply(this),p.classed(c,!0).style("top",n.top+i[0]+y+"px").style("left",n.left+i[1]+v+"px"),t},t.hide=function(){return o().style("opacity",0).style("pointer-events","none"),t},t.attr=function(n,r){if(arguments.length<2&&"string"==typeof n)return o().attr(n);var i=Array.prototype.slice.call(arguments);return e.selection.prototype.attr.apply(o(),i),t},t.style=function(n,r){if(arguments.length<2&&"string"==typeof n)return o().style(n);var i=Array.prototype.slice.call(arguments);return e.selection.prototype.style.apply(o(),i),t},t.direction=function(e){return arguments.length?(l=null==e?e:i(e),t):l},t.offset=function(e){return arguments.length?(a=null==e?e:i(e),t):a},t.html=function(e){return arguments.length?(s=null==e?e:i(e),t):s},t.rootElement=function(e){return arguments.length?(u=null==e?e:i(e),t):u},t.destroy=function(){return c&&(o().remove(),c=null),t};var d=y({n:function(){var t=r();return{top:t.n.y-c.offsetHeight,left:t.n.x-c.offsetWidth/2}},s:function(){var t=r();return{top:t.s.y,left:t.s.x-c.offsetWidth/2}},e:function(){var t=r();return{top:t.e.y-c.offsetHeight/2,left:t.e.x}},w:function(){var t=r();return{top:t.w.y-c.offsetHeight/2,left:t.w.x-c.offsetWidth}},nw:function(){var t=r();return{top:t.nw.y-c.offsetHeight,left:t.nw.x-c.offsetWidth}},ne:function(){var t=r();return{top:t.ne.y-c.offsetHeight,left:t.ne.x}},sw:function(){var t=r();return{top:t.sw.y,left:t.sw.x-c.offsetWidth}},se:function(){var t=r();return{top:t.se.y,left:t.se.x}}}),g=d.keys();return t}().attr("class","d3-tip").offset(function(){switch(n.tooltip.direction()()){case"e":return[0,n.tooltipOffset()];default:return[-n.tooltipOffset(),0]}}),t.call(this.tooltip)},n.prototype.tooltipUpdate=function(){var t=this.tooltip.attr("class");t&&(t=t.split(" notick").join("")+(this.tooltipTick()?"":" notick")+("none"===this.tooltipStyle()?" hidden":""),this.tooltip.attr("class",t))},n.prototype.tooltipExit=function(){this.tooltip&&this.tooltip.destroy()},n.prototype._tooltipHTML=function(t){return t},n.prototype.tooltipHTML=function(t){return this.tooltip.html(t)},n.prototype.tooltipFormat=function(t){switch(t=t||{},t.label=void 0===t.label?"":t.label,t.series=t.series||"",t.value instanceof Date?t.value=t.value||"":t.value=this._valueFormatter(t.value)||"",this.tooltipStyle()){case"none":break;default:return t.series?"<span style='color:"+this.tooltipSeriesColor()+"'>"+t.series+"</span> / <span style='color:"+this.tooltipLabelColor()+"'>"+t.label+"</span>: <span style='color:"+this.tooltipValueColor()+"'>"+t.value+"</span>":"<span style='color:"+this.tooltipLabelColor()+"'>"+t.label+"</span>: <span style='color:"+this.tooltipValueColor()+"'>"+t.value+"</span>"}},n}(e.Widget);M.prototype.publish("tooltipStyle","default","set","Style",["default","none"],{}),M.prototype.publish("tooltipValueFormat",",.2f","string","Value Format",null,{}),M.prototype.publish("tooltipSeriesColor","#EAFFFF","html-color","Series Color",null,{}),M.prototype.publish("tooltipLabelColor","#CCFFFF","html-color","Label Color",null,{}),M.prototype.publish("tooltipValueColor","white","html-color","Value Color",null,{}),M.prototype.publish("tooltipTick",!0,"boolean","Show tooltip tick",null,{}),M.prototype.publish("tooltipOffset",8,"number","Offset from the cursor",null,{});var _=M.prototype.tooltipValueFormat;M.prototype.tooltipValueFormat=function(t){var e=_.apply(this,arguments);return arguments.length&&(this._valueFormatter=k(t)),e};var T=function(){function t(){}return t.prototype.click=function(t,e,n){console.log("Click: "+JSON.stringify(t)+", "+e+", "+n)},t.prototype.dblclick=function(t,e,n){console.log("Double click: "+JSON.stringify(t)+", "+e+", "+n)},t}();T.prototype._palette=e.Palette.ordinal("default"),t.I1DChart=n,t.I2DChart=o,t.IGraph=r,t.instanceOfIHighlight=function(t){return"function"==typeof t.highlightColumn},t.IInput=v,t.INDChart=l,t.ITooltip=M,t.ITree=T,Object.defineProperty(t,"__esModule",{value:!0})});
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports,require("@hpcc-js/common")):"function"==typeof define&&define.amd?define(["exports","@hpcc-js/common"],e):e(t["@hpcc-js/api"]={},t["@hpcc-js/common"])}(this,function(t,e){"use strict";function n(){}function o(){}function r(){}function i(t,e){function n(){this.constructor=t}g(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}function l(){}function a(t,e){if((n=(t=e?t.toExponential(e-1):t.toExponential()).indexOf("e"))<0)return null;var n,o=t.slice(0,n);return[o.length>1?o[0]+o.slice(2):o,+t.slice(n+1)]}function s(t,e){var n=a(t,e);if(!n)return t+"";var o=n[0],r=n[1];return r<0?"0."+new Array(-r).join("0")+o:o.length>r+1?o.slice(0,r+1)+"."+o.slice(r+1):o+new Array(r-o.length+2).join("0")}function u(t){return new c(t)}function c(t){if(!(e=b.exec(t)))throw new Error("invalid format: "+t);var e,n=e[1]||" ",o=e[2]||">",r=e[3]||"-",i=e[4]||"",l=!!e[5],a=e[6]&&+e[6],s=!!e[7],u=e[8]&&+e[8].slice(1),c=e[9]||"";"n"===c?(s=!0,c="g"):x[c]||(c=""),(l||"0"===n&&"="===o)&&(l=!0,n="0",o="="),this.fill=n,this.align=o,this.sign=r,this.symbol=i,this.zero=l,this.width=a,this.comma=s,this.precision=u,this.type=c}function p(t){return t}function f(t){function e(t){function e(t){var e,o,l,u=v,p=b;if("c"===g)p=w(t)+p,t="";else{var x=(t=+t)<0;if(t=w(Math.abs(t),d),x&&0==+t&&(x=!1),u=(x?"("===c?c:"-":"-"===c||"("===c?"":c)+u,p=p+("s"===g?E[8+m/3]:"")+(x&&"("===c?")":""),k)for(e=-1,o=t.length;++e<o;)if(48>(l=t.charCodeAt(e))||l>57){p=(46===l?r+t.slice(e+1):t.slice(e))+p,t=t.slice(0,e);break}}y&&!f&&(t=n(t,1/0));var C=u.length+t.length+p.length,S=C<h?new Array(h-C+1).join(a):"";switch(y&&f&&(t=n(S+t,S.length?h-p.length:1/0),S=""),s){case"<":t=u+t+p+S;break;case"=":t=u+S+t+p;break;case"^":t=S.slice(0,C=S.length>>1)+u+t+p+S.slice(C);break;default:t=S+u+t+p}return i(t)}var a=(t=u(t)).fill,s=t.align,c=t.sign,p=t.symbol,f=t.zero,h=t.width,y=t.comma,d=t.precision,g=t.type,v="$"===p?o[0]:"#"===p&&/[boxX]/.test(g)?"0"+g.toLowerCase():"",b="$"===p?o[1]:/[%p]/.test(g)?l:"",w=x[g],k=!g||/[defgprs%]/.test(g);return d=null==d?g?6:12:/[gprs]/.test(g)?Math.max(1,Math.min(21,d)):Math.max(0,Math.min(20,d)),e.toString=function(){return t+""},e}var n=t.grouping&&t.thousands?function(t,e){return function(n,o){for(var r=n.length,i=[],l=0,a=t[0],s=0;r>0&&a>0&&(s+a+1>o&&(a=Math.max(1,o-s)),i.push(n.substring(r-=a,r+a)),!((s+=a+1)>o));)a=t[l=(l+1)%t.length];return i.reverse().join(e)}}(t.grouping,t.thousands):p,o=t.currency,r=t.decimal,i=t.numerals?function(t){return function(e){return e.replace(/[0-9]/g,function(e){return t[+e]})}}(t.numerals):p,l=t.percent||"%";return{format:e,formatPrefix:function(t,n){var o=e((t=u(t),t.type="f",t)),r=3*Math.max(-8,Math.min(8,Math.floor(function(t){return(t=a(Math.abs(t)))?t[1]:NaN}(n)/3))),i=Math.pow(10,-r),l=E[8+r/3];return function(t){return o(i*t)+l}}}}function h(){}function y(t,e){var n=new h;if(t instanceof h)t.each(function(t,e){n.set(e,t)});else if(Array.isArray(t)){var o,r=-1,i=t.length;if(null==e)for(;++r<i;)n.set(r,t[r]);else for(;++r<i;)n.set(e(o=t[r],r,t),o)}else if(t)for(var l in t)n.set(l,t[l]);return n}function d(){}n.prototype._palette=e.Palette.rainbow("default"),n.prototype.click=function(t,e,n){console.log("Click: "+JSON.stringify(t)+", "+e+", "+n)},n.prototype.dblclick=function(t,e,n){console.log("Double click: "+JSON.stringify(t)+", "+e+", "+n)},o.prototype._palette=e.Palette.ordinal("default"),o.prototype.click=function(t,e,n){console.log("Click: "+JSON.stringify(t)+", "+e+", "+n)},o.prototype.dblclick=function(t,e,n){console.log("Double click: "+JSON.stringify(t)+", "+e+", "+n)},r.prototype.vertex_click=function(t,e,n,o){o&&o.vertex&&console.log("Vertex click: "+o.vertex.id())},r.prototype.vertex_dblclick=function(t,e,n,o){o&&o.vertex&&console.log("Vertex double click: "+o.vertex.id())},r.prototype.edge_click=function(t,e,n,o){o&&o.edge&&console.log("Edge click: "+o.edge.id())},r.prototype.edge_dblclick=function(t,e,n,o){o&&o.edge&&console.log("Edge double click: "+o.edge.id())};var g=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])},v=function(t){function e(){return t.call(this)||this}return i(e,t),e.prototype.isValid=function(){if(this.validate()){if(!new RegExp(this.validate()).test(this.value()))return!1}return!0},e.prototype.hasValue=function(){if("function"==typeof this.type){switch(this.type()){case"radio":case"checkbox":if(this.value()&&"false"!==this.value())return!0;break;default:if(this.value())return!0}return!1}return""!==this.value()},e.prototype.blur=function(t){},e.prototype.click=function(t){},e.prototype.dblclick=function(t){},e.prototype.change=function(t,e){},e.prototype.resetValue=function(t){t.value(t._inputElement[0].node().value)},e.prototype.disable=function(t){this._inputElement.forEach(function(e,n){e.attr("disabled",t?"disabled":null)})},e.prototype.setFocus=function(){this._inputElement.length&&this._inputElement[0].node().focus()},e}(e.Widget);v.prototype.publish("name","","string","HTML name for the input"),v.prototype.publish("label","","string","Descriptive label"),v.prototype.publish("value","","string","Input Current Value"),v.prototype.publish("validate",null,"string","Input Validation"),l.prototype._palette=e.Palette.ordinal("default"),l.prototype.click=function(t,e,n){console.log("Click: "+JSON.stringify(t)+", "+e+", "+n)},l.prototype.dblclick=function(t,e,n){console.log("Double click: "+JSON.stringify(t)+", "+e+", "+n)};var m,x={"":function(t,e){t:for(var n,o=(t=t.toPrecision(e)).length,r=1,i=-1;r<o;++r)switch(t[r]){case".":i=n=r;break;case"0":0===i&&(i=r),n=r;break;case"e":break t;default:i>0&&(i=0)}return i>0?t.slice(0,i)+t.slice(n+1):t},"%":function(t,e){return(100*t).toFixed(e)},b:function(t){return Math.round(t).toString(2)},c:function(t){return t+""},d:function(t){return Math.round(t).toString(10)},e:function(t,e){return t.toExponential(e)},f:function(t,e){return t.toFixed(e)},g:function(t,e){return t.toPrecision(e)},o:function(t){return Math.round(t).toString(8)},p:function(t,e){return s(100*t,e)},r:s,s:function(t,e){var n=a(t,e);if(!n)return t+"";var o=n[0],r=n[1],i=r-(m=3*Math.max(-8,Math.min(8,Math.floor(r/3))))+1,l=o.length;return i===l?o:i>l?o+new Array(i-l+1).join("0"):i>0?o.slice(0,i)+"."+o.slice(i):"0."+new Array(1-i).join("0")+a(t,Math.max(0,e+i-1))[0]},X:function(t){return Math.round(t).toString(16).toUpperCase()},x:function(t){return Math.round(t).toString(16)}},b=/^(?:(.)?([<>=^]))?([+\-\( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?([a-z%])?$/i;u.prototype=c.prototype,c.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(null==this.width?"":Math.max(1,0|this.width))+(this.comma?",":"")+(null==this.precision?"":"."+Math.max(0,0|this.precision))+this.type};var w,k,C,E=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];!function(t){w=f(t),k=w.format,C=w.formatPrefix}({decimal:".",thousands:",",grouping:[3],currency:["$",""]});h.prototype=y.prototype={constructor:h,has:function(t){return"$"+t in this},get:function(t){return this["$"+t]},set:function(t,e){return this["$"+t]=e,this},remove:function(t){var e="$"+t;return e in this&&delete this[e]},clear:function(){for(var t in this)"$"===t[0]&&delete this[t]},keys:function(){var t=[];for(var e in this)"$"===e[0]&&t.push(e.slice(1));return t},values:function(){var t=[];for(var e in this)"$"===e[0]&&t.push(this[e]);return t},entries:function(){var t=[];for(var e in this)"$"===e[0]&&t.push({key:e.slice(1),value:this[e]});return t},size:function(){var t=0;for(var e in this)"$"===e[0]&&++t;return t},empty:function(){for(var t in this)if("$"===t[0])return!1;return!0},each:function(t){for(var e in this)"$"===e[0]&&t(this[e],e.slice(1),this)}};var S=y.prototype;d.prototype=function(t,e){var n=new d;if(t instanceof d)t.each(function(t){n.add(t)});else if(t){var o=-1,r=t.length;if(null==e)for(;++o<r;)n.add(t[o]);else for(;++o<r;)n.add(e(t[o],o,t))}return n}.prototype={constructor:d,has:S.has,add:function(t){return t+="",this["$"+t]=t,this},remove:S.remove,clear:S.clear,values:S.keys,size:S.size,empty:S.empty,each:S.each},function(t,e){if("undefined"==typeof document)return e;t=t||"";var n=document.head||document.getElementsByTagName("head")[0],o=document.createElement("style");o.type="text/css",n.appendChild(o),o.styleSheet?o.styleSheet.cssText=t:o.appendChild(document.createTextNode(t))}('.d3-tip {\r\n line-height: 1;\r\n font-weight: bold;\r\n padding: 12px;\r\n background: rgba(0, 0, 0, 0.66);\r\n color: #fff;\r\n border-radius: 2px;\r\n pointer-events: none !important;\r\n z-index:10;\r\n}\r\n\r\n.d3-tip.hidden {\r\n visibility:hidden;\r\n}\r\n\r\n/* Creates a small triangle extender for the tooltip */\r\n.d3-tip:after {\r\n box-sizing: border-box;\r\n display: inline;\r\n font-size: 10px;\r\n width: 100%;\r\n line-height: 1;\r\n color: rgba(0, 0, 0, 0.66);\r\n position: absolute;\r\n pointer-events: none !important;\r\n}\r\n\r\n/* Northward tooltips */\r\n.d3-tip.n:after {\r\n content: "\\25BC";\r\n margin: -1px 0 0 0;\r\n top: 100%;\r\n left: 0;\r\n text-align: center;\r\n}\r\n\r\n/* Eastward tooltips */\r\n.d3-tip.e:after {\r\n content: "\\25C0";\r\n margin: -4px 0 0 0;\r\n top: 50%;\r\n left: -8px;\r\n}\r\n\r\n/* Southward tooltips */\r\n.d3-tip.s:after {\r\n content: "\\25B2";\r\n margin: 0 0 1px 0;\r\n top: -8px;\r\n left: 0;\r\n text-align: center;\r\n}\r\n\r\n/* Westward tooltips */\r\n.d3-tip.w:after {\r\n content: "\\25B6";\r\n margin: -4px 0 0 -1px;\r\n top: 50%;\r\n left: 100%;\r\n}\r\n\r\n.d3-tip.notick:after {\r\n content: "" !important;\r\n}\r\n\r\n.common_Widget .over {\r\n stroke: rgba(0, 0, 0, 0.66);\r\n opacity: 0.66;\r\n}\r\n',void 0);var M=function(t){function n(){var e=t.call(this)||this;if(e._valueFormatter=k(e.tooltipValueFormat()),e.layerEnter){var n=e.layerEnter;e.layerEnter=function(t,e,o){this.tooltipEnter(e),n.apply(this,arguments)};var o=e.layerUpdate;e.layerUpdate=function(t){o.apply(this,arguments),this.tooltipUpdate()};var r=e.layerExit;e.layerExit=function(t){r.apply(this,arguments),this.tooltipExit()}}else{var i=e.enter;e.enter=function(t,e){this.tooltipEnter(e),i.apply(this,arguments)};var l=e.update;e.update=function(t,e){l.apply(this,arguments),this.tooltipUpdate()};var a=e.exit;e.exit=function(t,e){a.apply(this,arguments),this.tooltipExit()}}return e}return i(n,t),n.prototype.tooltipEnter=function(t){var n=this;this.tooltip=function(){function t(t){(p=function(e){var n=t.node();return n?"svg"===n.tagName.toLowerCase()?n:n.ownerSVGElement:null}())&&(f=p.createSVGPoint(),u().appendChild(c))}function n(){var t=e.select(document.createElement("div"));return t.style("position","absolute").style("top",0).style("opacity",0).style("pointer-events","none").style("box-sizing","border-box"),t.node()}function o(){return null==c&&(c=n(),u().appendChild(c)),e.select(c)}function r(){for(var t=h||event.target;null==t.getScreenCTM&&null==t.parentNode;)t=t.parentNode;var e={},n=t.getScreenCTM(),o=t.getBBox(),r=o.width,i=o.height,l=o.x,a=o.y;return f.x=l,f.y=a,e.nw=f.matrixTransform(n),f.x+=r,e.ne=f.matrixTransform(n),f.y+=i,e.se=f.matrixTransform(n),f.x-=r,e.sw=f.matrixTransform(n),f.y-=i/2,e.w=f.matrixTransform(n),f.x+=r,e.e=f.matrixTransform(n),f.x-=r/2,f.y-=i/2,e.n=f.matrixTransform(n),f.y+=i,e.s=f.matrixTransform(n),e}function i(t){return"function"==typeof t?t:function(){return t}}var l=function(){return"n"},a=function(){return[0,0]},s=function(){return" "},u=i(document.body),c=n(),p=null,f=null,h=null;t.show=function(){var e=Array.prototype.slice.call(arguments);e[e.length-1]instanceof SVGElement&&(h=e.pop());var n,r=s.apply(this,e),i=a.apply(this,e),c=l.apply(this,e),p=o(),f=g.length,y=document.documentElement.scrollTop||u().scrollTop,v=document.documentElement.scrollLeft||u().scrollLeft;for(p.html(r).style("opacity",1).style("pointer-events","all");f--;)p.classed(g[f],!1);return n=d.get(c).apply(this),p.classed(c,!0).style("top",n.top+i[0]+y+"px").style("left",n.left+i[1]+v+"px"),t},t.hide=function(){return o().style("opacity",0).style("pointer-events","none"),t},t.attr=function(n,r){if(arguments.length<2&&"string"==typeof n)return o().attr(n);var i=Array.prototype.slice.call(arguments);return e.selection.prototype.attr.apply(o(),i),t},t.style=function(n,r){if(arguments.length<2&&"string"==typeof n)return o().style(n);var i=Array.prototype.slice.call(arguments);return e.selection.prototype.style.apply(o(),i),t},t.direction=function(e){return arguments.length?(l=null==e?e:i(e),t):l},t.offset=function(e){return arguments.length?(a=null==e?e:i(e),t):a},t.html=function(e){return arguments.length?(s=null==e?e:i(e),t):s},t.rootElement=function(e){return arguments.length?(u=null==e?e:i(e),t):u},t.destroy=function(){return c&&(o().remove(),c=null),t};var d=y({n:function(){var t=r();return{top:t.n.y-c.offsetHeight,left:t.n.x-c.offsetWidth/2}},s:function(){var t=r();return{top:t.s.y,left:t.s.x-c.offsetWidth/2}},e:function(){var t=r();return{top:t.e.y-c.offsetHeight/2,left:t.e.x}},w:function(){var t=r();return{top:t.w.y-c.offsetHeight/2,left:t.w.x-c.offsetWidth}},nw:function(){var t=r();return{top:t.nw.y-c.offsetHeight,left:t.nw.x-c.offsetWidth}},ne:function(){var t=r();return{top:t.ne.y-c.offsetHeight,left:t.ne.x}},sw:function(){var t=r();return{top:t.sw.y,left:t.sw.x-c.offsetWidth}},se:function(){var t=r();return{top:t.se.y,left:t.se.x}}}),g=d.keys();return t}().attr("class","d3-tip").offset(function(){switch(n.tooltip.direction()()){case"e":return[0,n.tooltipOffset()];default:return[-n.tooltipOffset(),0]}}),t.call(this.tooltip)},n.prototype.tooltipUpdate=function(){var t=this.tooltip.attr("class");t&&(t=t.split(" notick").join("")+(this.tooltipTick()?"":" notick")+("none"===this.tooltipStyle()?" hidden":""),this.tooltip.attr("class",t))},n.prototype.tooltipExit=function(){this.tooltip&&this.tooltip.destroy()},n.prototype._tooltipHTML=function(t){return t},n.prototype.tooltipHTML=function(t){return this.tooltip.html(t)},n.prototype.tooltipFormat=function(t){switch(t=t||{},t.label=void 0===t.label?"":t.label,t.series=t.series||"",t.value instanceof Date?t.value=t.value||"":t.value=this._valueFormatter(t.value)||"",this.tooltipStyle()){case"none":break;default:return t.series?"<span style='color:"+this.tooltipSeriesColor()+"'>"+t.series+"</span> / <span style='color:"+this.tooltipLabelColor()+"'>"+t.label+"</span>: <span style='color:"+this.tooltipValueColor()+"'>"+t.value+"</span>":"<span style='color:"+this.tooltipLabelColor()+"'>"+t.label+"</span>: <span style='color:"+this.tooltipValueColor()+"'>"+t.value+"</span>"}},n}(e.Widget);M.prototype.publish("tooltipStyle","default","set","Style",["default","none"],{}),M.prototype.publish("tooltipValueFormat",",.2f","string","Value Format",null,{}),M.prototype.publish("tooltipSeriesColor","#EAFFFF","html-color","Series Color",null,{}),M.prototype.publish("tooltipLabelColor","#CCFFFF","html-color","Label Color",null,{}),M.prototype.publish("tooltipValueColor","white","html-color","Value Color",null,{}),M.prototype.publish("tooltipTick",!0,"boolean","Show tooltip tick",null,{}),M.prototype.publish("tooltipOffset",8,"number","Offset from the cursor",null,{});var _=M.prototype.tooltipValueFormat;M.prototype.tooltipValueFormat=function(t){var e=_.apply(this,arguments);return arguments.length&&(this._valueFormatter=k(t)),e};var T=function(){function t(){}return t.prototype.click=function(t,e,n){console.log("Click: "+JSON.stringify(t)+", "+e+", "+n)},t.prototype.dblclick=function(t,e,n){console.log("Double click: "+JSON.stringify(t)+", "+e+", "+n)},t}();T.prototype._palette=e.Palette.ordinal("default"),t.I1DChart=n,t.I2DChart=o,t.IGraph=r,t.instanceOfIHighlight=function(t){return"function"==typeof t.highlightColumn},t.IInput=v,t.INDChart=l,t.ITooltip=M,t.ITree=T,Object.defineProperty(t,"__esModule",{value:!0})});
{
"name": "@hpcc-js/api",
"version": "0.0.70",
"version": "0.0.71",
"description": "hpcc-js - Viz api",

@@ -17,2 +17,3 @@ "main": "dist/index.js",

"compile-es6": "tsc --module es6 --outDir ./lib-es6",
"compile-es6-watch": "npm run compile-es6 -- -w",
"compile-umd": "tsc --module umd --outDir ./lib-umd",

@@ -23,3 +24,3 @@ "bundle": "rollup -c",

"build": "npm run compile-es6 && npm run bundle",
"watch": "concurrently --kill-others \"npm run compile-watch\" \"npm run bundle-watch\"",
"watch": "concurrently --kill-others \"npm run compile-es6-watch\" \"npm run bundle-watch\"",
"lint": "tslint --project . src/**/*.ts",

@@ -29,3 +30,3 @@ "docs": "typedoc --options tdoptions.json ."

"dependencies": {
"@hpcc-js/common": "^0.0.70"
"@hpcc-js/common": "^0.0.71"
},

@@ -32,0 +33,0 @@ "devDependencies": {

@@ -12,3 +12,3 @@ import { Widget } from "@hpcc-js/common";

dblclick(_w: any): void;
change(_w: any): void;
change(_w: any, complete: boolean): void;
resetValue(w: any): void;

@@ -15,0 +15,0 @@ disable(disable: any): void;

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