diff --git a/Gruntfile.js b/Gruntfile.js index a2ff41bde..44f882136 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -85,7 +85,7 @@ module.exports = function (grunt) { watch: { jsdoc2md: { files: ['<%= conf.src %>/**/*.js'], - tasks: ['build', 'jsdoc2md'] + tasks: ['build', 'jsdoc', 'jsdoc2md'] }, scripts: { files: ['<%= conf.src %>/**/*.js', '<%= conf.web %>/stock.js'], @@ -211,6 +211,16 @@ module.exports = function (grunt) { } } }, + jsdoc: { + dist: { + src: 'dc.js', + options: { + destination: 'web/docs/html', + template: 'node_modules/ink-docstrap/template', + configure: 'node_modules/ink-docstrap/template/jsdoc.conf.json' + } + } + }, jsdoc2md: { dist: { src: 'dc.js', @@ -374,7 +384,7 @@ module.exports = function (grunt) { // task aliases grunt.registerTask('build', ['concat', 'uglify', 'cssmin']); - grunt.registerTask('docs', ['build', 'copy', 'jsdoc2md', 'docco', 'fileindex']); + grunt.registerTask('docs', ['build', 'copy', 'jsdoc', 'jsdoc2md', 'docco', 'fileindex']); grunt.registerTask('web', ['docs', 'gh-pages']); grunt.registerTask('server', ['docs', 'fileindex', 'jasmine:specs:build', 'connect:server', 'watch:jasmine-docs']); grunt.registerTask('test', ['build', 'jasmine:specs']); @@ -384,7 +394,7 @@ module.exports = function (grunt) { grunt.registerTask('ci-pull', ['test', 'jasmine:specs:build', 'connect:server']); grunt.registerTask('lint', ['jshint', 'jscs']); grunt.registerTask('default', ['build', 'shell:hooks']); - grunt.registerTask('jsdoc', ['build', 'jsdoc2md', 'watch:jsdoc2md']); + grunt.registerTask('doc-debug', ['build', 'jsdoc', 'jsdoc2md', 'watch:jsdoc2md']); }; module.exports.jsFiles = [ diff --git a/package.json b/package.json index b9f0a443a..ce2c7c03c 100644 --- a/package.json +++ b/package.json @@ -45,12 +45,14 @@ "grunt-fileindex": "^0.1.0", "grunt-gh-pages": "~0.10.0", "grunt-jscs": "~2.1.0", + "grunt-jsdoc": "~1.1.0", "grunt-jsdoc-to-markdown": "~1.1.1", "grunt-lib-phantomjs": "~0.7.1", "grunt-markdown": "~0.7.0", "grunt-saucelabs": "~8.6.1", "grunt-shell": "~1.1.1", "grunt-template-jasmine-istanbul": "~0.3.2", + "ink-docstrap": "~1.1.0", "jsdifflib": "~1.1.0", "load-grunt-tasks": "~3.2.0", "marked": "~0.3.3", diff --git a/src/bar-chart.js b/src/bar-chart.js index fa0e6edaa..8f3a6c434 100644 --- a/src/bar-chart.js +++ b/src/bar-chart.js @@ -4,7 +4,7 @@ * Examples: * - {@link http://dc-js.github.com/dc.js/ Nasdaq 100 Index} * - {@link http://dc-js.github.com/dc.js/crime/index.html Canadian City Crime Stats} - * @name barChart + * @namespace barChart * @memberof dc * @mixes dc.stackMixin * @mixes dc.coordinateGridMixin @@ -227,7 +227,7 @@ dc.barChart = function (parent, chartGroup) { /** * Whether the bar chart will render each bar centered around the data position on the x-axis. - * @name centerBar + * @method centerBar * @memberof dc.barChart * @instance * @param {Boolean} [centerBar=false] @@ -251,7 +251,7 @@ dc.barChart = function (parent, chartGroup) { * Setting this value will also remove any previously set {@link #dc.barChart+gap gap}. See the * {@link https://github.com/mbostock/d3/wiki/Ordinal-Scales#wiki-ordinal_rangeBands d3 docs} * for a visual description of how the padding is applied. - * @name barPadding + * @method barPadding * @memberof dc.barChart * @instance * @param {Number} [barPadding=0] @@ -274,7 +274,7 @@ dc.barChart = function (parent, chartGroup) { /** * Get or set the outer padding on an ordinal bar chart. This setting has no effect on non-ordinal charts. * Will pad the width by `padding * barWidth` on each side of the chart. - * @name outerPadding + * @method outerPadding * @memberof dc.barChart * @instance * @param {Number} [padding=0.5] @@ -287,7 +287,7 @@ dc.barChart = function (parent, chartGroup) { * Manually set fixed gap (in px) between bars instead of relying on the default auto-generated * gap. By default the bar chart implementation will calculate and set the gap automatically * based on the number of data points and the length of the x axis. - * @name gap + * @method gap * @memberof dc.barChart * @instance * @param {Number} [gap=2] @@ -322,7 +322,7 @@ dc.barChart = function (parent, chartGroup) { * When using standard d3.js rounding methods, the brush often doesn't align correctly with * centered bars since the bars are offset. The rounding function must add an offset to * compensate, such as in the following example. - * @name alwaysUseRounding + * @method alwaysUseRounding * @memberof dc.barChart * @instance * @example diff --git a/src/base-mixin.js b/src/base-mixin.js index 3b989f56d..d756408dd 100644 --- a/src/base-mixin.js +++ b/src/base-mixin.js @@ -111,7 +111,7 @@ dc.baseMixin = function (_chart) { * anchor element. If that isn't possible it defaults to 200 (provided by the * {@link #dc.baseMixin+minHeight minHeight} property). Setting the value falsy will return * the chart to the default behavior. - * @name height + * @method height * @memberof dc.baseMixin * @instance * @see {@link #dc.baseMixin+minHeight minHeight} @@ -144,7 +144,7 @@ dc.baseMixin = function (_chart) { /** * Set or get the width attribute of a chart. - * @name width + * @method width * @memberof dc.baseMixin * @instance * @see {@link #dc.baseMixin+height height} @@ -175,7 +175,7 @@ dc.baseMixin = function (_chart) { /** * Set or get the minimum width attribute of a chart. This only has effect when used with the default * {@link #dc.baseMixin+width width} function. - * @name minWidth + * @method minWidth * @memberof dc.baseMixin * @instance * @see {@link #dc.baseMixin+width width} @@ -194,7 +194,7 @@ dc.baseMixin = function (_chart) { /** * Set or get the minimum height attribute of a chart. This only has effect when used with the default * {@link #dc.baseMixin+height height} function. - * @name minHeight + * @method minHeight * @memberof dc.baseMixin * @instance * @see {@link #dc.baseMixin+height height} @@ -218,7 +218,7 @@ dc.baseMixin = function (_chart) { * * If a value is given, then it will be used as the new dimension. If no value is specified then * the current dimension will be returned. - * @name dimension + * @method dimension * @memberof dc.baseMixin * @instance * @see {@link https://github.com/square/crossfilter/wiki/API-Reference#dimension crossfilter.dimension} @@ -244,7 +244,7 @@ dc.baseMixin = function (_chart) { * group and by default will return * {@link https://github.com/square/crossfilter/wiki/API-Reference#group_all group.all}. * This behavior may be modified to, for instance, return only the top 5 groups. - * @name data + * @method data * @memberof dc.baseMixin * @instance * @example @@ -275,7 +275,7 @@ dc.baseMixin = function (_chart) { * * If no value specified then the current group will be returned. * If `name` is specified then it will be used to generate legend label. - * @name group + * @method group * @memberof dc.baseMixin * @instance * @see {@link https://github.com/square/crossfilter/wiki/API-Reference#group-map-reduce crossfilter.group} @@ -303,7 +303,7 @@ dc.baseMixin = function (_chart) { * Get or set an accessor to order ordinal dimensions. This uses * {@link https://github.com/square/crossfilter/wiki/API-Reference#quicksort_by crossfilter.quicksort.by} as the * sort. - * @name ordering + * @method ordering * @memberof dc.baseMixin * @instance * @see {@link https://github.com/square/crossfilter/wiki/API-Reference#quicksort_by crossfilter.quicksort.by} @@ -342,7 +342,7 @@ dc.baseMixin = function (_chart) { * Clear all filters associated with this chart * * The same can be achieved by calling {@link #dc.baseMixin+filter chart.filter(null)}. - * @name filterAll + * @method filterAll * @memberof dc.baseMixin * @instance * @return {dc.baseMixin} @@ -357,7 +357,7 @@ dc.baseMixin = function (_chart) { * * This function is **not chainable** since it does not return a chart instance; however the d3 * selection result can be chained to d3 function calls. - * @name select + * @method select * @memberof dc.baseMixin * @instance * @see {@link https://github.com/mbostock/d3/wiki/Selections d3.selection} @@ -375,7 +375,7 @@ dc.baseMixin = function (_chart) { * * This function is **not chainable** since it does not return a chart instance; however the d3 * selection result can be chained to d3 function calls. - * @name selectAll + * @method selectAll * @memberof dc.baseMixin * @instance * @see {@link https://github.com/mbostock/d3/wiki/Selections d3.selection} @@ -394,7 +394,7 @@ dc.baseMixin = function (_chart) { * block element such as a div; or a dom element or d3 selection. Optionally registers the chart * within the chartGroup. This class is called internally on chart initialization, but be called * again to relocate the chart. However, it will orphan any previously created SVGElements. - * @name anchor + * @method anchor * @memberof dc.baseMixin * @instance * @param {anchorChart|anchorSelector|anchorNode} [parent] @@ -429,7 +429,7 @@ dc.baseMixin = function (_chart) { /** * Returns the DOM id for the chart's anchored location. - * @name anchorName + * @method anchorName * @memberof dc.baseMixin * @instance * @return {String} @@ -450,7 +450,7 @@ dc.baseMixin = function (_chart) { * the SVGElement was created. You can also pass in a new root element however this is usually handled by * dc internally. Resetting the root element on a chart outside of dc internals may have * unexpected consequences. - * @name root + * @method root * @memberof dc.baseMixin * @instance * @see {@link https://developer.mozilla.org/en-US/docs/Web/API/HTMLElement HTMLElement} @@ -470,7 +470,7 @@ dc.baseMixin = function (_chart) { * Returns the top SVGElement for this specific chart. You can also pass in a new SVGElement, * however this is usually handled by dc internally. Resetting the SVGElement on a chart outside * of dc internals may have unexpected consequences. - * @name svg + * @method svg * @memberof dc.baseMixin * @instance * @see {@link https://developer.mozilla.org/en-US/docs/Web/API/SVGElement SVGElement} @@ -488,7 +488,7 @@ dc.baseMixin = function (_chart) { /** * Remove the chart's SVGElements from the dom and recreate the container SVGElement. - * @name resetSvg + * @method resetSvg * @memberof dc.baseMixin * @instance * @see {@link https://developer.mozilla.org/en-US/docs/Web/API/SVGElement SVGElement} @@ -518,7 +518,7 @@ dc.baseMixin = function (_chart) { * friendly text for filter value(s) associated with the chart instance. By default dc charts use a * default filter printer `dc.printers.filter` that provides simple printing support for both * single value and ranged filters. - * @name filterPrinter + * @method filterPrinter * @memberof dc.baseMixin * @instance * @param {Function} [filterPrinterFunction=dc.printers.filter] @@ -536,7 +536,7 @@ dc.baseMixin = function (_chart) { /** * If set, use the `visibility` attribute instead of the `display` attribute for showing/hiding * chart reset and filter controls, for less disruption to the layout. - * @name controlsUseVisibility + * @method controlsUseVisibility * @memberof dc.baseMixin * @instance * @param {Boolean} [controlsUseVisibility=false] @@ -560,7 +560,7 @@ dc.baseMixin = function (_chart) { * * root.selectAll('.filter') elements are turned on if the chart has an active filter. The text * content of this element is then replaced with the current filter value using the filter printer * function. This type of element will be turned off automatically if the filter is cleared. - * @name turnOnControls + * @method turnOnControls * @memberof dc.baseMixin * @instance * @return {dc.baseMixin} @@ -576,7 +576,7 @@ dc.baseMixin = function (_chart) { /** * Turn off optional control elements within the root element. - * @name turnOffControls + * @method turnOffControls * @memberof dc.baseMixin * @see {@link #dc.baseMixin+turnOnControls turnOnControls} * @instance @@ -594,7 +594,7 @@ dc.baseMixin = function (_chart) { /** * Set or get the animation transition duration (in milliseconds) for this chart instance. - * @name transitionDuration + * @method transitionDuration * @memberof dc.baseMixin * @instance * @param {Number} [duration=750] @@ -629,7 +629,7 @@ dc.baseMixin = function (_chart) { * should only be used to render the chart for the first time on the page or if you want to make * sure everything is redrawn from scratch instead of relying on the default incremental redrawing * behaviour. - * @name render + * @method render * @memberof dc.baseMixin * @instance * @return {dc.baseMixin} @@ -679,7 +679,7 @@ dc.baseMixin = function (_chart) { * manually invoke this function if data is manipulated outside of dc's control (for example if * data is loaded in the background using * {@link https://github.com/square/crossfilter/wiki/API-Reference#crossfilter_add crossfilter.add}. - * @name redraw + * @method redraw * @memberof dc.baseMixin * @instance * @return {dc.baseMixin} @@ -707,7 +707,7 @@ dc.baseMixin = function (_chart) { * a flag indicating whether this is a render (true) or a redraw (false), and a callback to be * triggered once the commit is filtered. The callback has the standard node.js continuation signature * with error first and result second. - * @name commitHandler + * @method commitHandler * @memberof dc.baseMixin * @instance * @return {dc.baseMixin} @@ -724,7 +724,7 @@ dc.baseMixin = function (_chart) { * Redraws all charts in the same group as this chart, typically in reaction to a filter * change. If the chart has a {@link dc.baseMixin.commitFilter commitHandler}, it will * be executed and waited for. - * @name redrawGroup + * @method redrawGroup * @memberof dc.baseMixin * @instance * @return {dc.baseMixin} @@ -747,7 +747,7 @@ dc.baseMixin = function (_chart) { /** * Renders all charts in the same group as this chart. If the chart has a * {@link dc.baseMixin.commitFilter commitHandler}, it will be executed and waited for - * @name renderGroup + * @method renderGroup * @memberof dc.baseMixin * @instance * @return {dc.baseMixin} @@ -790,7 +790,7 @@ dc.baseMixin = function (_chart) { * Set or get the has filter handler. The has filter handler is a function that checks to see if * the chart's current filters include a specific filter. Using a custom has filter handler allows * you to change the way filters are checked for and replaced. - * @name hasFilterHandler + * @method hasFilterHandler * @memberof dc.baseMixin * @instance * @example @@ -823,7 +823,7 @@ dc.baseMixin = function (_chart) { /** * Check whether any active filter or a specific filter is associated with particular chart instance. * This function is **not chainable**. - * @name hasFilter + * @method hasFilter * @memberof dc.baseMixin * @instance * @see {@link #dc.baseMixin+hasFilterHandler hasFilterHandler} @@ -851,7 +851,7 @@ dc.baseMixin = function (_chart) { * using a filter server other than crossfilter. * * Any changes should modify the `filters` array argument and return that array. - * @name removeFilterHandler + * @method removeFilterHandler * @memberof dc.baseMixin * @instance * @example @@ -894,7 +894,7 @@ dc.baseMixin = function (_chart) { * than crossfilter. * * Any changes should modify the `filters` array argument and return that array. - * @name addFilterHandler + * @method addFilterHandler * @memberof dc.baseMixin * @instance * @example @@ -931,7 +931,7 @@ dc.baseMixin = function (_chart) { * e.g. when using a filter server other than crossfilter. * * This function should return an array. - * @name resetFilterHandler + * @method resetFilterHandler * @memberof dc.baseMixin * @instance * @example @@ -977,7 +977,7 @@ dc.baseMixin = function (_chart) { * * Once the filters array has been updated, the filters are applied to the crossfilter.dimension, using the * {@link #dc.baseMixin+filterHandler filterHandler}. - * @name filter + * @method filter * @memberof dc.baseMixin * @instance * @see {@link #dc.baseMixin+addFilterHandler addFilterHandler} @@ -1029,7 +1029,7 @@ dc.baseMixin = function (_chart) { * Returns all current filters. This method does not perform defensive cloning of the internal * filter array before returning, therefore any modification of the returned array will effect the * chart's internal filter storage. - * @name filters + * @method filters * @memberof dc.baseMixin * @instance * @return {Array<*>} @@ -1056,7 +1056,7 @@ dc.baseMixin = function (_chart) { /** * This function is passed to d3 as the onClick handler for each chart. The default behavior is to * filter on the clicked datum (passed to the callback) and redraw the chart group. - * @name onClick + * @method onClick * @memberof dc.baseMixin * @instance * @param {*} datum @@ -1073,7 +1073,7 @@ dc.baseMixin = function (_chart) { * Set or get the filter handler. The filter handler is a function that performs the filter action * on a specific dimension. Using a custom filter handler allows you to perform additional logic * before or after filtering. - * @name filterHandler + * @method filterHandler * @memberof dc.baseMixin * @instance * @see {@link https://github.com/square/crossfilter/wiki/API-Reference#dimension_filter crossfilter.dimension.filter} @@ -1154,7 +1154,7 @@ dc.baseMixin = function (_chart) { * Set or get the key accessor function. The key accessor function is used to retrieve the key * value from the crossfilter group. Key values are used differently in different charts, for * example keys correspond to slices in a pie chart and x axis positions in a grid coordinate chart. - * @name keyAccessor + * @method keyAccessor * @memberof dc.baseMixin * @instance * @example @@ -1179,7 +1179,7 @@ dc.baseMixin = function (_chart) { * value from the crossfilter group. Group values are used differently in different charts, for * example values correspond to slice sizes in a pie chart and y axis positions in a grid * coordinate chart. - * @name valueAccessor + * @method valueAccessor * @memberof dc.baseMixin * @instance * @example @@ -1204,7 +1204,7 @@ dc.baseMixin = function (_chart) { * child element in the chart, e.g. slices in a pie chart or bubbles in a bubble chart. Not every * chart supports the label function, for example line chart does not use this function * at all. By default, enables labels; pass false for the second parameter if this is not desired. - * @name label + * @method label * @memberof dc.baseMixin * @instance * @example @@ -1230,7 +1230,7 @@ dc.baseMixin = function (_chart) { /** * Turn on/off label rendering - * @name renderLabel + * @method renderLabel * @memberof dc.baseMixin * @instance * @param {Boolean} [renderLabel=false] @@ -1251,7 +1251,7 @@ dc.baseMixin = function (_chart) { * in a pie chart or a bubble in a bubble chart. Almost every chart supports the title function; * however in grid coordinate charts you need to turn off the brush in order to see titles, because * otherwise the brush layer will block tooltip triggering. - * @name title + * @method title * @memberof dc.baseMixin * @instance * @example @@ -1280,7 +1280,7 @@ dc.baseMixin = function (_chart) { /** * Turn on/off title rendering, or return the state of the render title flag if no arguments are * given. - * @name renderTitle + * @method renderTitle * @memberof dc.baseMixin * @instance * @param {Boolean} [renderTitle=true] @@ -1304,7 +1304,7 @@ dc.baseMixin = function (_chart) { * * Use {@link #dc.baseMixin+on on} with a 'renderlet' prefix. * Generates a random key for the renderlet, which makes it hard to remove. - * @name renderlet + * @method renderlet * @memberof dc.baseMixin * @instance * @deprecated @@ -1327,7 +1327,7 @@ dc.baseMixin = function (_chart) { /** * Get or set the chart group to which this chart belongs. Chart groups are rendered or redrawn * together since it is expected they share the same underlying crossfilter data set. - * @name chartGroup + * @method chartGroup * @memberof dc.baseMixin * @instance * @param {String} [chartGroup] @@ -1355,7 +1355,7 @@ dc.baseMixin = function (_chart) { * {@link https://github.com/square/crossfilter/wiki/API-Reference#crossfilter_add crossfilter.add} * function or reset group or dimension after rendering it is a good idea to * clear the cache to make sure charts are rendered properly. - * @name expireCache + * @method expireCache * @memberof dc.baseMixin * @instance * @return {dc.baseMixin} @@ -1368,7 +1368,7 @@ dc.baseMixin = function (_chart) { /** * Attach a dc.legend widget to this chart. The legend widget will automatically draw legend labels * based on the color setting and names associated with each group. - * @name legend + * @method legend * @memberof dc.baseMixin * @instance * @example @@ -1388,7 +1388,7 @@ dc.baseMixin = function (_chart) { /** * Returns the internal numeric ID of the chart. - * @name chartID + * @method chartID * @memberof dc.baseMixin * @instance * @return {String} @@ -1400,7 +1400,7 @@ dc.baseMixin = function (_chart) { /** * Set chart options using a configuration object. Each key in the object will cause the method of * the same name to be called with the value to set that attribute for the chart. - * @name options + * @method options * @memberof dc.baseMixin * @instance * @example @@ -1449,7 +1449,7 @@ dc.baseMixin = function (_chart) { * including all renderlets' logic. * * `filtered` - This listener function will be invoked after a filter is applied, added or removed. * * `zoomed` - This listener function will be invoked after a zoom is triggered. - * @name on + * @method on * @memberof dc.baseMixin * @instance * @see {@link https://github.com/mbostock/d3/wiki/Internals#dispatch_on d3.dispatch.on} diff --git a/src/box-plot.js b/src/box-plot.js index d22098ba6..f6878b423 100644 --- a/src/box-plot.js +++ b/src/box-plot.js @@ -3,7 +3,7 @@ * Examples: * - {@link http://dc-js.github.com/dc.js/ Nasdaq 100 Index} * - {@link http://dc-js.github.com/dc.js/crime/index.html Canadian City Crime Stats} - * @name boxPlot + * @namespace boxPlot * @memberof dc * @mixes dc.coordinateGridMixin * @example @@ -74,7 +74,7 @@ dc.boxPlot = function (parent, chartGroup) { * Get or set the spacing between boxes as a fraction of box size. Valid values are within 0-1. * See the {@link https://github.com/mbostock/d3/wiki/Ordinal-Scales#wiki-ordinal_rangeBands d3 docs} * for a visual description of how the padding is applied. - * @name boxPadding + * @method boxPadding * @memberof dc.boxPlot * @instance * @see {@link https://github.com/mbostock/d3/wiki/Ordinal-Scales#wiki-ordinal_rangeBands d3.scale.ordinal.rangeBands} @@ -89,7 +89,7 @@ dc.boxPlot = function (parent, chartGroup) { * Get or set the outer padding on an ordinal box chart. This setting has no effect on non-ordinal charts * or on charts with a custom {@link #dc.boxPlot+boxWidth .boxWidth}. Will pad the width by * `padding * barWidth` on each side of the chart. - * @name outerPadding + * @method outerPadding * @memberof dc.boxPlot * @instance * @param {Number} [padding=0.5] @@ -108,7 +108,7 @@ dc.boxPlot = function (parent, chartGroup) { * chart.boxWidth(10); * // Using function * chart.boxWidth((innerChartWidth, xUnits) { ... }); - * @name boxWidth + * @method boxWidth * @memberof dc.boxPlot * @instance * @param {Number|Function} [boxWidth=0.5] @@ -220,7 +220,7 @@ dc.boxPlot = function (parent, chartGroup) { * @example * // format ticks to 2 decimal places * chart.tickFormat(d3.format('.2f')); - * @name tickFormat + * @method tickFormat * @memberof dc.boxPlot * @instance * @param {Function} [tickFormat] diff --git a/src/bubble-chart.js b/src/bubble-chart.js index 3c15f18ff..0f2974649 100644 --- a/src/bubble-chart.js +++ b/src/bubble-chart.js @@ -8,7 +8,7 @@ * Examples: * - {@link http://dc-js.github.com/dc.js/ Nasdaq 100 Index} * - {@link http://dc-js.github.com/dc.js/vc/index.html US Venture Capital Landscape 2011} - * @name bubbleChart + * @namespace bubbleChart * @memberof dc * @mixes dc.bubbleMixin * @mixes dc.coordinateGridMixin @@ -39,7 +39,7 @@ dc.bubbleChart = function (parent, chartGroup) { /** * Turn on or off the elastic bubble radius feature, or return the value of the flag. If this * feature is turned on, then bubble radii will be automatically rescaled to fit the chart better. - * @name elasticRadius + * @method elasticRadius * @memberof dc.bubbleChart * @instance * @param {Boolean} [elasticRadius=false] @@ -57,7 +57,7 @@ dc.bubbleChart = function (parent, chartGroup) { /** * Turn on or off the bubble sorting feature, or return the value of the flag. If enabled, * bubbles will be sorted by their radius, with smaller bubbles in front. - * @name sortBubbleSize + * @method sortBubbleSize * @memberof dc.bubbleChart * @instance * @param {Boolean} [sortBubbleSize=false] diff --git a/src/bubble-mixin.js b/src/bubble-mixin.js index a87a8fc1a..1e30490fb 100644 --- a/src/bubble-mixin.js +++ b/src/bubble-mixin.js @@ -33,7 +33,7 @@ dc.bubbleMixin = function (_chart) { * Get or set the bubble radius scale. By default the bubble chart uses * {@link https://github.com/mbostock/d3/wiki/Quantitative-Scales#linear d3.scale.linear().domain([0, 100])} * as its radius scale. - * @name r + * @method r * @memberof dc.bubbleMixin * @instance * @see {@link http://github.com/mbostock/d3/wiki/Scales d3.scale} @@ -54,7 +54,7 @@ dc.bubbleMixin = function (_chart) { * be used to retrieve a data value for each bubble. The data retrieved then will be mapped using * the r scale to the actual bubble radius. This allows you to encode a data dimension using bubble * size. - * @name radiusValueAccessor + * @method radiusValueAccessor * @memberof dc.bubbleMixin * @instance * @param {Function} [radiusValueAccessor] @@ -160,7 +160,7 @@ dc.bubbleMixin = function (_chart) { /** * Get or set the minimum radius. This will be used to initialize the radius scale's range. - * @name minRadius + * @method minRadius * @memberof dc.bubbleMixin * @instance * @param {Number} [radius=10] @@ -178,7 +178,7 @@ dc.bubbleMixin = function (_chart) { /** * Get or set the minimum radius for label rendering. If a bubble's radius is less than this value * then no label will be rendered. - * @name minRadiusWithLabel + * @method minRadiusWithLabel * @memberof dc.bubbleMixin * @instance * @param {Number} [radius=10] @@ -197,7 +197,7 @@ dc.bubbleMixin = function (_chart) { /** * Get or set the maximum relative size of a bubble to the length of x axis. This value is useful * when the difference in radius between bubbles is too great. - * @name maxBubbleRelativeSize + * @method maxBubbleRelativeSize * @memberof dc.bubbleMixin * @instance * @param {Number} [relativeSize=0.3] diff --git a/src/bubble-overlay.js b/src/bubble-overlay.js index bf73f5ff9..768d149a1 100644 --- a/src/bubble-overlay.js +++ b/src/bubble-overlay.js @@ -5,7 +5,7 @@ * and coloring. * Examples: * - {@link http://dc-js.github.com/dc.js/crime/index.html Canadian City Crime Stats} - * @name bubbleOverlay + * @namespace bubbleOverlay * @memberof dc * @mixes dc.bubbleMixin * @mixes dc.baseMixin @@ -32,7 +32,7 @@ dc.bubbleOverlay = function (parent, chartGroup) { * Set the underlying svg image element. Unlike other dc charts this chart will not generate a svg * element; therefore the bubble overlay chart will not work if this function is not invoked. If the * underlying image is a bitmap, then an empty svg will need to be created on top of the image. - * @name svg + * @method svg * @memberof dc.bubbleOverlay * @instance * @example @@ -58,7 +58,7 @@ dc.bubbleOverlay = function (parent, chartGroup) { * data groups generated using keyAccessor. If a match is found (point name <-> data group key) * then a bubble will be generated at the position specified by the function. x and y * value specified here are relative to the underlying svg. - * @name point + * @method point * @memberof dc.bubbleOverlay * @instance * @param {String} name diff --git a/src/cap-mixin.js b/src/cap-mixin.js index 6b0a4272c..ae0e2a65a 100644 --- a/src/cap-mixin.js +++ b/src/cap-mixin.js @@ -61,7 +61,7 @@ dc.capMixin = function (_chart) { /** * Get or set the count of elements to that will be included in the cap. - * @name cap + * @method cap * @memberof dc.capMixin * @instance * @param {Number} [count=Infinity] @@ -78,7 +78,7 @@ dc.capMixin = function (_chart) { /** * Get or set the label for *Others* slice when slices cap is specified - * @name othersLabel + * @method othersLabel * @memberof dc.capMixin * @instance * @param {String} [label="Others"] @@ -97,7 +97,7 @@ dc.capMixin = function (_chart) { * Get or set the grouper function that will perform the insertion of data for the *Others* slice * if the slices cap is specified. If set to a falsy value, no others will be added. By default the * grouper function computes the sum of all values below the cap. - * @name othersGrouper + * @method othersGrouper * @memberof dc.capMixin * @instance * @example diff --git a/src/color-mixin.js b/src/color-mixin.js index c87110320..99eb34cdd 100644 --- a/src/color-mixin.js +++ b/src/color-mixin.js @@ -16,7 +16,7 @@ dc.colorMixin = function (_chart) { /** * Retrieve current color scale or set a new color scale. This methods accepts any function that * operates like a d3 scale. - * @name colors + * @method colors * @memberof dc.colorMixin * @instance * @see {@link http://github.com/mbostock/d3/wiki/Scales d3.scale} @@ -49,7 +49,7 @@ dc.colorMixin = function (_chart) { * Convenience method to set the color scale to * {@link https://github.com/mbostock/d3/wiki/Ordinal-Scales#ordinal d3.scale.ordinal} with * range `r`. - * @name ordinalColors + * @method ordinalColors * @memberof dc.colorMixin * @instance * @param {Array} r @@ -61,7 +61,7 @@ dc.colorMixin = function (_chart) { /** * Convenience method to set the color scale to an Hcl interpolated linear scale with range `r`. - * @name linearColors + * @method linearColors * @memberof dc.colorMixin * @instance * @param {Array} r @@ -77,7 +77,7 @@ dc.colorMixin = function (_chart) { * Set or the get color accessor function. This function will be used to map a data point in a * crossfilter group to a color value on the color scale. The default function uses the key * accessor. - * @name colorAccessor + * @method colorAccessor * @memberof dc.colorMixin * @instance * @example @@ -109,7 +109,7 @@ dc.colorMixin = function (_chart) { * * Note: previously this method accepted a callback function. Instead you may use a custom scale * set by {@link #dc.colorMixin+colors .colors}. - * @name colorDomain + * @method colorDomain * @memberof dc.colorMixin * @instance * @param {Array} [domain] @@ -127,7 +127,7 @@ dc.colorMixin = function (_chart) { /** * Set the domain by determining the min and max values as retrieved by * {@link #dc.colorMixin+colorAccessor .colorAccessor} over the chart's dataset. - * @name calculateColorDomain + * @method calculateColorDomain * @memberof dc.colorMixin * @instance * @return {dc.colorMixin} @@ -141,7 +141,7 @@ dc.colorMixin = function (_chart) { /** * Get the color for the datum d and counter i. This is used internally by charts to retrieve a color. - * @name getColor + * @method getColor * @memberof dc.colorMixin * @instance * @param {*} d @@ -154,7 +154,7 @@ dc.colorMixin = function (_chart) { /** * Get the color for the datum d and counter i. This is used internally by charts to retrieve a color. - * @name colorCalculator + * @method colorCalculator * @memberof dc.colorMixin * @instance * @param {*} [colorCalculator] diff --git a/src/composite-chart.js b/src/composite-chart.js index 531580f9b..fc321b13f 100644 --- a/src/composite-chart.js +++ b/src/composite-chart.js @@ -2,7 +2,7 @@ * Composite charts are a special kind of chart that render multiple charts on the same Coordinate * Grid. You can overlay (compose) different bar/line/area charts in a single composite chart to * achieve some quite flexible charting effects. - * @name compositeChart + * @namespace compositeChart * @memberof dc * @mixes dc.coordinateGridMixin * @example @@ -228,7 +228,7 @@ dc.compositeChart = function (parent, chartGroup) { * Get or set whether to draw gridlines from the right y axis. Drawing from the left y axis is the * default behavior. This option is only respected when subcharts with both left and right y-axes * are present. - * @name useRightAxisGridLines + * @method useRightAxisGridLines * @memberof dc.compositeChart * @instance * @param {Boolean} [useRightAxisGridLines=false] @@ -247,7 +247,7 @@ dc.compositeChart = function (parent, chartGroup) { /** * Get or set chart-specific options for all child charts. This is equivalent to calling * {@link #dc.baseMixin+options .options} on each child chart. - * @name childOptions + * @method childOptions * @memberof dc.compositeChart * @instance * @param {Object} [childOptions] @@ -275,7 +275,7 @@ dc.compositeChart = function (parent, chartGroup) { /** * Set or get the right y axis label. - * @name rightYAxisLabel + * @method rightYAxisLabel * @memberof dc.compositeChart * @instance * @param {String} [rightYAxisLabel] @@ -296,7 +296,7 @@ dc.compositeChart = function (parent, chartGroup) { /** * Combine the given charts into one single composite coordinate grid chart. - * @name compose + * @method compose * @memberof dc.compositeChart * @instance * @example @@ -338,7 +338,7 @@ dc.compositeChart = function (parent, chartGroup) { /** * Returns the child charts which are composed into the composite chart. - * @name children + * @method children * @memberof dc.compositeChart * @instance * @return {Array} @@ -352,7 +352,7 @@ dc.compositeChart = function (parent, chartGroup) { * will be shared with composed children. Additionally if the child chart implements * Stackable and has not set a custom .colorAccessor, then it will generate a color * specific to its order in the composition. - * @name shareColors + * @method shareColors * @memberof dc.compositeChart * @instance * @param {Boolean} [shareColors=false] @@ -370,7 +370,7 @@ dc.compositeChart = function (parent, chartGroup) { /** * Get or set title sharing for the chart. If set, the {@link #dc.baseMixin+title .title()} value from * this chart will be shared with composed children. - * @name shareTitle + * @method shareTitle * @memberof dc.compositeChart * @instance * @param {Boolean} [shareTitle=true] @@ -388,7 +388,7 @@ dc.compositeChart = function (parent, chartGroup) { /** * Get or set the y scale for the right axis. The right y scale is typically automatically * generated by the chart implementation. - * @name rightY + * @method rightY * @memberof dc.compositeChart * @instance * @see {@link https://github.com/mbostock/d3/wiki/Scales d3.scale} @@ -408,7 +408,7 @@ dc.compositeChart = function (parent, chartGroup) { /** * Get or set alignment between left and right y axes. A line connecting '0' on both y axis * will be parallel to x axis. - * @name alignYAxes + * @method alignYAxes * @memberof dc.compositeChart * @instance * @param {Boolean} [alignYAxes=false] @@ -519,7 +519,7 @@ dc.compositeChart = function (parent, chartGroup) { * object](https://github.com/mbostock/d3/wiki/SVG-Axes#wiki-_axis) therefore it supports any valid * d3 axis manipulation. **Caution**: The y axis is usually generated internally by dc; * resetting it may cause unexpected results. - * @name rightYAxis + * @method rightYAxis * @memberof dc.compositeChart * @instance * @see {@link https://github.com/mbostock/d3/wiki/SVG-Axes d3.svg.axis} diff --git a/src/coordinate-grid-mixin.js b/src/coordinate-grid-mixin.js index 1a65c76c1..600952960 100644 --- a/src/coordinate-grid-mixin.js +++ b/src/coordinate-grid-mixin.js @@ -109,7 +109,7 @@ dc.coordinateGridMixin = function (_chart) { * and redraw the axes. (`.rescale()` is called automatically when the x or y scale is replaced * with {@link #dc.coordinateGridMixin+x .x()} or {@link #dc.coordinateGridMixin+y .y()}, and has * no effect on elastic scales.) - * @name rescale + * @method rescale * @memberof dc.coordinateGridMixin * @instance * @return {dc.coordinateGridMixin} @@ -130,7 +130,7 @@ dc.coordinateGridMixin = function (_chart) { * zooms in. In return the given range chart will also automatically attach this chart as its focus * chart hence zoom in when range brush updates. See the [Nasdaq 100 * Index](http://dc-js.github.com/dc.js/) example for this effect in action. - * @name rangeChart + * @method rangeChart * @memberof dc.coordinateGridMixin * @instance * @param {dc.coordinateGridMixin} [rangeChart] @@ -147,7 +147,7 @@ dc.coordinateGridMixin = function (_chart) { /** * Get or set the scale extent for mouse zooms. - * @name zoomScale + * @method zoomScale * @memberof dc.coordinateGridMixin * @instance * @param {Array} [extent=[1, Infinity]] @@ -164,7 +164,7 @@ dc.coordinateGridMixin = function (_chart) { /** * Get or set the zoom restriction for the chart. If true limits the zoom to origional domain of the chart. - * @name zoomOutRestrict + * @method zoomOutRestrict * @memberof dc.coordinateGridMixin * @instance * @param {Boolean} [zoomOutRestrict=true] @@ -200,7 +200,7 @@ dc.coordinateGridMixin = function (_chart) { * Get or set the root g element. This method is usually used to retrieve the g element in order to * overlay custom svg drawing programatically. **Caution**: The root g element is usually generated * by dc.js internals, and resetting it might produce unpredictable result. - * @name g + * @method g * @memberof dc.coordinateGridMixin * @instance * @param {SVGElement} [gElement] @@ -219,7 +219,7 @@ dc.coordinateGridMixin = function (_chart) { * Set or get mouse zoom capability flag (default: false). When turned on the chart will be * zoomable using the mouse wheel. If the range selector chart is attached zooming will also update * the range selection brush on the associated range selector chart. - * @name mouseZoomable + * @method mouseZoomable * @memberof dc.coordinateGridMixin * @instance * @param {Boolean} [mouseZoomable=false] @@ -236,7 +236,7 @@ dc.coordinateGridMixin = function (_chart) { /** * Retrieve the svg group for the chart body. - * @name chartBodyG + * @method chartBodyG * @memberof dc.coordinateGridMixin * @instance * @param {SVGElement} [chartBodyG] @@ -256,7 +256,7 @@ dc.coordinateGridMixin = function (_chart) { * Get or set the x scale. The x scale can be any d3 * {@link https://github.com/mbostock/d3/wiki/Quantitative-Scales quantitive scale} or * {@link https://github.com/mbostock/d3/wiki/Ordinal-Scales ordinal scale}. - * @name x + * @method x * @memberof dc.coordinateGridMixin * @instance * @see {@link http://github.com/mbostock/d3/wiki/Scales d3.scale} @@ -292,7 +292,7 @@ dc.coordinateGridMixin = function (_chart) { * d3.time.years](https://github.com/mbostock/d3/wiki/Time-Intervals#aliases) are all valid xUnits * function. dc.js also provides a few units function, see the {@link #utilities Utilities} section for * a list of built-in units functions. The default xUnits function is dc.units.integers. - * @name xUnits + * @method xUnits * @memberof dc.coordinateGridMixin * @instance * @todo Add docs for utilities @@ -331,7 +331,7 @@ dc.coordinateGridMixin = function (_chart) { * axis object](https://github.com/mbostock/d3/wiki/SVG-Axes#wiki-axis); therefore it supports any * valid d3 axis manipulation. **Caution**: The x axis is usually generated internally by dc; * resetting it may cause unexpected results. - * @name xAxis + * @method xAxis * @memberof dc.coordinateGridMixin * @instance * @see {@link http://github.com/mbostock/d3/wiki/SVG-Axes d3.svg.axis} @@ -355,7 +355,7 @@ dc.coordinateGridMixin = function (_chart) { /** * Turn on/off elastic x axis behavior. If x axis elasticity is turned on, then the grid chart will * attempt to recalculate the x axis range whenever a redraw event is triggered. - * @name elasticX + * @method elasticX * @memberof dc.coordinateGridMixin * @instance * @param {Boolean} [elasticX=false] @@ -377,7 +377,7 @@ dc.coordinateGridMixin = function (_chart) { * padding can be an integer or percentage in string (e.g. '10%'). Padding can be applied to * number or date x axes. When padding a date axis, an integer represents number of days being padded * and a percentage string will be treated the same as an integer. - * @name xAxisPadding + * @method xAxisPadding * @memberof dc.coordinateGridMixin * @instance * @param {Number|String} [padding=0] @@ -395,7 +395,7 @@ dc.coordinateGridMixin = function (_chart) { /** * Returns the number of units displayed on the x axis using the unit measure configured by * .xUnits. - * @name xUnitCount + * @method xUnitCount * @memberof dc.coordinateGridMixin * @instance * @return {Number} @@ -418,7 +418,7 @@ dc.coordinateGridMixin = function (_chart) { * Gets or sets whether the chart should be drawn with a right axis instead of a left axis. When * used with a chart in a composite chart, allows both left and right Y axes to be shown on a * chart. - * @name useRightYAxis + * @method useRightYAxis * @memberof dc.coordinateGridMixin * @instance * @param {Boolean} [useRightYAxis=false] @@ -437,7 +437,7 @@ dc.coordinateGridMixin = function (_chart) { * Returns true if the chart is using ordinal xUnits ({@link #dc.units.ordinal dc.units.ordinal}, or false * otherwise. Most charts behave differently with ordinal data and use the result of this method to * trigger the appropriate logic. - * @name isOrdinal + * @method isOrdinal * @memberof dc.coordinateGridMixin * @instance * @return {Boolean} @@ -580,7 +580,7 @@ dc.coordinateGridMixin = function (_chart) { /** * Set or get the x axis label. If setting the label, you may optionally include additional padding to * the margin to make room for the label. By default the padded is set to 12 to accomodate the text height. - * @name xAxisLabel + * @method xAxisLabel * @memberof dc.coordinateGridMixin * @instance * @param {String} [labelText] @@ -714,7 +714,7 @@ dc.coordinateGridMixin = function (_chart) { * Set or get the y axis label. If setting the label, you may optionally include additional padding * to the margin to make room for the label. By default the padded is set to 12 to accomodate the * text height. - * @name yAxisLabel + * @method yAxisLabel * @memberof dc.coordinateGridMixin * @instance * @param {String} [labelText] @@ -735,7 +735,7 @@ dc.coordinateGridMixin = function (_chart) { /** * Get or set the y scale. The y scale is typically automatically determined by the chart implementation. - * @name y + * @method y * @memberof dc.coordinateGridMixin * @instance * @see {@link http://github.com/mbostock/d3/wiki/Scales d3.scale} @@ -758,7 +758,7 @@ dc.coordinateGridMixin = function (_chart) { * object](https://github.com/mbostock/d3/wiki/SVG-Axes#wiki-_axis); therefore it supports any * valid d3 axis manipulation. **Caution**: The y axis is usually generated internally by dc; * resetting it may cause unexpected results. - * @name yAxis + * @method yAxis * @memberof dc.coordinateGridMixin * @instance * @see {@link http://github.com/mbostock/d3/wiki/SVG-Axes d3.svg.axis} @@ -782,7 +782,7 @@ dc.coordinateGridMixin = function (_chart) { /** * Turn on/off elastic y axis behavior. If y axis elasticity is turned on, then the grid chart will * attempt to recalculate the y axis range whenever a redraw event is triggered. - * @name elasticY + * @method elasticY * @memberof dc.coordinateGridMixin * @instance * @param {Boolean} [elasticY=false] @@ -799,7 +799,7 @@ dc.coordinateGridMixin = function (_chart) { /** * Turn on/off horizontal grid lines. - * @name renderHorizontalGridLines + * @method renderHorizontalGridLines * @memberof dc.coordinateGridMixin * @instance * @param {Boolean} [renderHorizontalGridLines=false] @@ -816,7 +816,7 @@ dc.coordinateGridMixin = function (_chart) { /** * Turn on/off vertical grid lines. - * @name renderVerticalGridLines + * @method renderVerticalGridLines * @memberof dc.coordinateGridMixin * @instance * @param {Boolean} [renderVerticalGridLines=false] @@ -833,7 +833,7 @@ dc.coordinateGridMixin = function (_chart) { /** * Calculates the minimum x value to display in the chart. Includes xAxisPadding if set. - * @name xAxisMin + * @method xAxisMin * @memberof dc.coordinateGridMixin * @instance * @return {*} @@ -847,7 +847,7 @@ dc.coordinateGridMixin = function (_chart) { /** * Calculates the maximum x value to display in the chart. Includes xAxisPadding if set. - * @name xAxisMax + * @method xAxisMax * @memberof dc.coordinateGridMixin * @instance * @return {*} @@ -861,7 +861,7 @@ dc.coordinateGridMixin = function (_chart) { /** * Calculates the minimum y value to display in the chart. Includes yAxisPadding if set. - * @name yAxisMin + * @method yAxisMin * @memberof dc.coordinateGridMixin * @instance * @return {*} @@ -875,7 +875,7 @@ dc.coordinateGridMixin = function (_chart) { /** * Calculates the maximum y value to display in the chart. Includes yAxisPadding if set. - * @name yAxisMax + * @method yAxisMax * @memberof dc.coordinateGridMixin * @instance * @return {*} @@ -894,7 +894,7 @@ dc.coordinateGridMixin = function (_chart) { * padding can be an integer or percentage in string (e.g. '10%'). Padding can be applied to * number or date axes. When padding a date axis, an integer represents number of days being padded * and a percentage string will be treated the same as an integer. - * @name yAxisPadding + * @method yAxisPadding * @memberof dc.coordinateGridMixin * @instance * @param {Number|String} [padding=0] @@ -915,7 +915,7 @@ dc.coordinateGridMixin = function (_chart) { /** * Set or get the rounding function used to quantize the selection when brushing is enabled. - * @name round + * @method round * @memberof dc.coordinateGridMixin * @instance * @example @@ -1086,7 +1086,7 @@ dc.coordinateGridMixin = function (_chart) { * Get or set the padding in pixels for the clip path. Once set padding will be applied evenly to * the top, left, right, and bottom when the clip path is generated. If set to zero, the clip area * will be exactly the chart body area minus the margins. - * @name clipPadding + * @method clipPadding * @memberof dc.coordinateGridMixin * @instance * @param {Number} [padding=5] @@ -1202,7 +1202,7 @@ dc.coordinateGridMixin = function (_chart) { * 2 elements (`[start, end]`) defining a range in the x domain. If the range is not given or set * to null, then the zoom will be reset. _For focus to work elasticX has to be turned off; * otherwise focus will be ignored. - * @name focus + * @method focus * @memberof dc.coordinateGridMixin * @instance * @example @@ -1270,7 +1270,7 @@ dc.coordinateGridMixin = function (_chart) { * un-filter them. However turning on the brush filter will disable other interactive elements on * the chart such as highlighting, tool tips, and reference lines. Zooming will still be possible * if enabled, but only via scrolling (panning will be disabled.) - * @name brushOn + * @method brushOn * @memberof dc.coordinateGridMixin * @instance * @param {Boolean} [brushOn=true] diff --git a/src/core.js b/src/core.js index 1e6ddc599..fa3bba450 100644 --- a/src/core.js +++ b/src/core.js @@ -110,7 +110,7 @@ dc.deregisterAllCharts = function (group) { * Clear all filters on all charts within the given chart group. If the chart group is not given then * only charts that belong to the default chart group will be reset. * @memberof dc - * @name filterAll + * @method filterAll * @param {String} [group] */ dc.filterAll = function (group) { @@ -124,7 +124,7 @@ dc.filterAll = function (group) { * Reset zoom level / focus on all charts that belong to the given chart group. If the chart group is * not given then only charts that belong to the default chart group will be reset. * @memberof dc - * @name refocusAll + * @method refocusAll * @param {String} [group] */ dc.refocusAll = function (group) { @@ -140,7 +140,7 @@ dc.refocusAll = function (group) { * Re-render all charts belong to the given chart group. If the chart group is not given then only * charts that belong to the default chart group will be re-rendered. * @memberof dc - * @name renderAll + * @method renderAll * @param {String} [group] */ dc.renderAll = function (group) { @@ -160,7 +160,7 @@ dc.renderAll = function (group) { * when redrawing dc tries to update the graphic incrementally, using transitions, instead of starting * from scratch. * @memberof dc - * @name redrawAll + * @method redrawAll * @param {String} [group] */ dc.redrawAll = function (group) { @@ -230,7 +230,7 @@ dc.afterTransition = function (transition, callback) { }; /** - * @name units + * @namespace units * @memberof dc * @type {{}} */ @@ -241,7 +241,7 @@ dc.units = {}; * {@link #dc.coordinateGridMixin Coordinate Grid Chart} and should * be used when the x values are a sequence of integers. * It is a function that counts the number of integers in the range supplied in its start and end parameters. - * @name integers + * @method integers * @memberof dc.units * @see {@link #dc.coordinateGridMixin+xUnits coordinateGridMixin.xUnits} * @example @@ -260,7 +260,7 @@ dc.units.integers = function (start, end) { * {@link https://github.com/mbostock/d3/wiki/Ordinal-Scales d3.scale.ordinal} to * {@link #dc.coordinateGridMixin+x .x}. * It just returns the domain passed to it, which for ordinal charts is an array of all values. - * @name ordinal + * @method ordinal * @memberof dc.units * @see {@link https://github.com/mbostock/d3/wiki/Ordinal-Scales d3.scale.ordinal} * @see {@link #dc.coordinateGridMixin+xUnits coordinateGridMixin.xUnits} @@ -278,7 +278,7 @@ dc.units.ordinal = function (start, end, domain) { }; /** - * @name fp + * @namespace fp * @memberof dc.units * @type {{}} */ @@ -289,7 +289,7 @@ dc.units.fp = {}; * numbers with the given precision. * The returned function determines how many values at the given precision will fit into the range * supplied in its start and end parameters. - * @name precision + * @method precision * @memberof dc.units.fp * @see {@link #dc.coordinateGridMixin+xUnits coordinateGridMixin.xUnits} * @example diff --git a/src/data-count.js b/src/data-count.js index e93a0173a..42b5c2b1a 100644 --- a/src/data-count.js +++ b/src/data-count.js @@ -8,7 +8,7 @@ * * Examples: * - {@link http://dc-js.github.com/dc.js/ Nasdaq 100 Index} - * @name dataCount + * @namespace dataCount * @memberof dc * @mixes dc.baseMixin * @example @@ -36,7 +36,7 @@ dc.dataCount = function (parent, chartGroup) { * `%filter-count` will be replaced with the number of selected records. * - all: HTML template to use if all items are selected * - some: HTML template to use if not all items are selected - * @name html + * @method html * @memberof dc.dataCount * @instance * @example @@ -63,7 +63,7 @@ dc.dataCount = function (parent, chartGroup) { /** * Gets or sets an optional function to format the filter count and total count. - * @name formatNumber + * @method formatNumber * @memberof dc.dataCount * @instance * @see {@link https://github.com/mbostock/d3/wiki/Formatting d3.format} diff --git a/src/data-grid.js b/src/data-grid.js index d366fee8e..1d9efe216 100644 --- a/src/data-grid.js +++ b/src/data-grid.js @@ -8,7 +8,7 @@ * * Examples: * - {@link http://europarl.me/dc.js/web/ep/index.html List of members of the european parliament} - * @name dataGrid + * @namespace dataGrid * @memberof dc * @mixes dc.baseMixin * @param {String|node|d3.selection} parent - Any valid @@ -106,7 +106,7 @@ dc.dataGrid = function (parent, chartGroup) { /** * Get or set the index of the beginning slice which determines which entries get displayed by the widget. * Useful when implementing pagination. - * @name beginSlice + * @method beginSlice * @memberof dc.dataGrid * @instance * @param {Number} [beginSlice=0] @@ -124,7 +124,7 @@ dc.dataGrid = function (parent, chartGroup) { /** * Get or set the index of the end slice which determines which entries get displayed by the widget * Useful when implementing pagination. - * @name endSlice + * @method endSlice * @memberof dc.dataGrid * @instance * @param {Number} [endSlice] @@ -141,7 +141,7 @@ dc.dataGrid = function (parent, chartGroup) { /** * Get or set the grid size which determines the number of items displayed by the widget. - * @name size + * @method size * @memberof dc.dataGrid * @instance * @param {Number} [size=999] @@ -160,7 +160,7 @@ dc.dataGrid = function (parent, chartGroup) { * Get or set the function that formats an item. The data grid widget uses a * function to generate dynamic html. Use your favourite templating engine or * generate the string directly. - * @name html + * @method html * @memberof dc.dataGrid * @instance * @example @@ -179,7 +179,7 @@ dc.dataGrid = function (parent, chartGroup) { /** * Get or set the function that formats a group label. - * @name htmlGroup + * @method htmlGroup * @memberof dc.dataGrid * @instance * @example @@ -199,7 +199,7 @@ dc.dataGrid = function (parent, chartGroup) { /** * Get or set sort-by function. This function works as a value accessor at the item * level and returns a particular field to be sorted. - * @name sortBy + * @method sortBy * @memberof dc.dataGrid * @instance * @example @@ -220,7 +220,7 @@ dc.dataGrid = function (parent, chartGroup) { /** * Get or set sort order function. - * @name order + * @method order * @memberof dc.dataGrid * @instance * @see {@link https://github.com/mbostock/d3/wiki/Arrays#d3_ascending d3.ascending} diff --git a/src/data-table.js b/src/data-table.js index 53a212180..e5d426864 100644 --- a/src/data-table.js +++ b/src/data-table.js @@ -15,7 +15,7 @@ * - {@link http://dc-js.github.com/dc.js/ Nasdaq 100 Index} * - {@link http://dc-js.github.io/dc.js/examples/table-on-aggregated-data.html dataTable on a crossfilter group} * ({@link https://github.com/dc-js/dc.js/blob/develop/web/examples/table-on-aggregated-data.html source}) - * @name dataTable + * @namespace dataTable * @memberof dc * @mixes dc.baseMixin * @param {String|node|d3.selection} parent - Any valid @@ -204,7 +204,7 @@ dc.dataTable = function (parent, chartGroup) { /** * Get or set the table size which determines the number of rows displayed by the widget. - * @name size + * @method size * @memberof dc.dataTable * @instance * @param {Number} [size=25] @@ -227,7 +227,7 @@ dc.dataTable = function (parent, chartGroup) { * See the {@link http://dc-js.github.io/dc.js/examples/table-pagination.html table pagination example} * to see how to implement the pagination user interface using `beginSlice` and `endSlice`. - * @name beginSlice + * @method beginSlice * @memberof dc.dataTable * @instance * @param {Number} [beginSlice=0] @@ -245,7 +245,7 @@ dc.dataTable = function (parent, chartGroup) { /** * Get or set the index of the end slice which determines which entries get displayed by the * widget. Useful when implementing pagination. See {@link #dc.dataTable+beginSlice `beginSlice`} for more information. - * @name endSlice + * @method endSlice * @memberof dc.dataTable * @instance * @param {Number|undefined} [endSlice=undefined] @@ -333,7 +333,7 @@ dc.dataTable = function (parent, chartGroup) { * override `_chart._doColumnHeaderFormat` and `_chart._doColumnValueFormat` Be aware that * fields without numberFormat specification will be displayed just as they are stored in the * data, unformatted. - * @name columns + * @method columns * @memberof dc.dataTable * @instance * @param {Array} [columns=[]] @@ -351,7 +351,7 @@ dc.dataTable = function (parent, chartGroup) { /** * Get or set sort-by function. This function works as a value accessor at row level and returns a * particular field to be sorted by. Default value: identity function - * @name sortBy + * @method sortBy * @memberof dc.dataTable * @instance * @example @@ -373,7 +373,7 @@ dc.dataTable = function (parent, chartGroup) { /** * Get or set sort order. If the order is `d3.ascending`, the data table will use * `dimension().bottom()` to fetch the data; otherwise it will use `dimension().top()` - * @name order + * @method order * @memberof dc.dataTable * @instance * @see {@link https://github.com/mbostock/d3/wiki/Arrays#d3_ascending d3.ascending} @@ -396,7 +396,7 @@ dc.dataTable = function (parent, chartGroup) { * Get or set if group rows will be shown. * * The .group() getter-setter must be provided in either case. - * @name showGroups + * @method showGroups * @memberof dc.dataTable * @instance * @example diff --git a/src/filters.js b/src/filters.js index edcaec435..f47ee816b 100644 --- a/src/filters.js +++ b/src/filters.js @@ -14,7 +14,7 @@ * * Currently these filter objects are also arrays, but this is not a requirement. Custom filters * can be used as long as they have the properties above. - * @name filters + * @namespace filters * @memberof dc * @type {{}} */ diff --git a/src/geo-choropleth-chart.js b/src/geo-choropleth-chart.js index 1b26623af..46d11ba2b 100644 --- a/src/geo-choropleth-chart.js +++ b/src/geo-choropleth-chart.js @@ -5,7 +5,7 @@ * * Examples: * - {@link http://dc-js.github.com/dc.js/vc/index.html US Venture Capital Landscape 2011} - * @name geoChoroplethChart + * @namespace geoChoroplethChart * @memberof dc * @mixes dc.colorMixin * @mixes dc.baseMixin @@ -179,7 +179,7 @@ dc.geoChoroplethChart = function (parent, chartGroup) { * Use this function to insert a new GeoJson map layer. This function can be invoked multiple times * if you have multiple GeoJson data layers to render on top of each other. If you overlay multiple * layers with the same name the new overlay will override the existing one. - * @name overlayGeoJson + * @method overlayGeoJson * @memberof dc.geoChoroplethChart * @instance * @see {@link http://geojson.org/ GeoJSON} @@ -211,7 +211,7 @@ dc.geoChoroplethChart = function (parent, chartGroup) { /** * Set custom geo projection function. See the available [d3 geo projection * functions](https://github.com/mbostock/d3/wiki/Geo-Projections). - * @name projection + * @method projection * @memberof dc.geoChoroplethChart * @instance * @see {@link https://github.com/mbostock/d3/wiki/Geo-Projections d3.geo.projection} @@ -229,7 +229,7 @@ dc.geoChoroplethChart = function (parent, chartGroup) { * Returns all GeoJson layers currently registered with this chart. The returned array is a * reference to this chart's internal data structure, so any modification to this array will also * modify this chart's internal registration. - * @name geoJsons + * @method geoJsons * @memberof dc.geoChoroplethChart * @instance * @return {Array<{name:String, data: Object, accessor: Function}>} @@ -242,7 +242,7 @@ dc.geoChoroplethChart = function (parent, chartGroup) { * Returns the {@link https://github.com/mbostock/d3/wiki/Geo-Paths#path d3.geo.path} object used to * render the projection and features. Can be useful for figuring out the bounding box of the * feature set and thus a way to calculate scale and translation for the projection. - * @name geoPath + * @method geoPath * @memberof dc.geoChoroplethChart * @instance * @see {@link https://github.com/mbostock/d3/wiki/Geo-Paths#path d3.geo.path} @@ -254,7 +254,7 @@ dc.geoChoroplethChart = function (parent, chartGroup) { /** * Remove a GeoJson layer from this chart by name - * @name removeGeoJson + * @method removeGeoJson * @memberof dc.geoChoroplethChart * @instance * @param {String} name diff --git a/src/heatmap.js b/src/heatmap.js index 2f21b755f..50c653f47 100644 --- a/src/heatmap.js +++ b/src/heatmap.js @@ -1,6 +1,6 @@ /** * A heat map is matrix that represents the values of two dimensions of data using colors. - * @name heatMap + * @namespace heatMap * @memberof dc * @mixes dc.colorMixin * @mixes dc.marginMixin @@ -42,7 +42,7 @@ dc.heatMap = function (parent, chartGroup) { /** * Set or get the column label function. The chart class uses this function to render * column labels on the X axis. It is passed the column name. - * @name colsLabel + * @method colsLabel * @memberof dc.heatMap * @instance * @example @@ -63,7 +63,7 @@ dc.heatMap = function (parent, chartGroup) { /** * Set or get the row label function. The chart class uses this function to render * row labels on the Y axis. It is passed the row name. - * @name rowsLabel + * @method rowsLabel * @memberof dc.heatMap * @instance * @example @@ -128,7 +128,7 @@ dc.heatMap = function (parent, chartGroup) { * Gets or sets the values used to create the rows of the heatmap, as an array. By default, all * the values will be fetched from the data using the value accessor, and they will be sorted in * ascending order. - * @name rows + * @method rows * @memberof dc.heatMap * @instance * @param {Array} [rows] @@ -152,7 +152,7 @@ dc.heatMap = function (parent, chartGroup) { * Gets or sets the keys used to create the columns of the heatmap, as an array. By default, all * the values will be fetched from the data using the key accessor, and they will be sorted in * ascending order. - * @name cols + * @method cols * @memberof dc.heatMap * @instance * @param {Array} [cols] @@ -274,7 +274,7 @@ dc.heatMap = function (parent, chartGroup) { /** * Gets or sets the handler that fires when an individual cell is clicked in the heatmap. * By default, filtering of the cell will be toggled. - * @name boxOnClick + * @method boxOnClick * @memberof dc.heatMap * @instance * @example @@ -302,7 +302,7 @@ dc.heatMap = function (parent, chartGroup) { * Gets or sets the handler that fires when a column tick is clicked in the x axis. * By default, if any cells in the column are unselected, the whole column will be selected, * otherwise the whole column will be unselected. - * @name xAxisOnClick + * @method xAxisOnClick * @memberof dc.heatMap * @instance * @param {Function} [handler] @@ -321,7 +321,7 @@ dc.heatMap = function (parent, chartGroup) { * Gets or sets the handler that fires when a row tick is clicked in the y axis. * By default, if any cells in the row are unselected, the whole row will be selected, * otherwise the whole row will be unselected. - * @name yAxisOnClick + * @method yAxisOnClick * @memberof dc.heatMap * @instance * @param {Function} [handler] @@ -338,7 +338,7 @@ dc.heatMap = function (parent, chartGroup) { /** * Gets or sets the X border radius. Set to 0 to get full rectangles. - * @name xBorderRadius + * @method xBorderRadius * @memberof dc.heatMap * @instance * @param {Number} [xBorderRadius=6.75] @@ -355,7 +355,7 @@ dc.heatMap = function (parent, chartGroup) { /** * Gets or sets the Y border radius. Set to 0 to get full rectangles. - * @name yBorderRadius + * @method yBorderRadius * @memberof dc.heatMap * @instance * @param {Number} [yBorderRadius=6.75] diff --git a/src/legend.js b/src/legend.js index 0f708893b..aec6beca2 100644 --- a/src/legend.js +++ b/src/legend.js @@ -5,7 +5,7 @@ * Examples: * - {@link http://dc-js.github.com/dc.js/ Nasdaq 100 Index} * - {@link http://dc-js.github.com/dc.js/crime/index.html Canadian City Crime Stats} - * @name legend + * @namespace legend * @memberof dc * @example * chart.legend(dc.legend().x(400).y(10).itemHeight(13).gap(5)) @@ -114,7 +114,7 @@ dc.legend = function () { /** * Set or get x coordinate for legend widget. - * @name x + * @method x * @memberof dc.legend * @instance * @param {Number} [x=0] @@ -131,7 +131,7 @@ dc.legend = function () { /** * Set or get y coordinate for legend widget. - * @name y + * @method y * @memberof dc.legend * @instance * @param {Number} [y=0] @@ -148,7 +148,7 @@ dc.legend = function () { /** * Set or get gap between legend items. - * @name gap + * @method gap * @memberof dc.legend * @instance * @param {Number} [gap=5] @@ -165,7 +165,7 @@ dc.legend = function () { /** * Set or get legend item height. - * @name itemHeight + * @method itemHeight * @memberof dc.legend * @instance * @param {Number} [itemHeight=12] @@ -182,7 +182,7 @@ dc.legend = function () { /** * Position legend horizontally instead of vertically. - * @name horizontal + * @method horizontal * @memberof dc.legend * @instance * @param {Boolean} [horizontal=false] @@ -199,7 +199,7 @@ dc.legend = function () { /** * Maximum width for horizontal legend. - * @name legendWidth + * @method legendWidth * @memberof dc.legend * @instance * @param {Number} [legendWidth=500] @@ -216,7 +216,7 @@ dc.legend = function () { /** * legendItem width for horizontal legend. - * @name itemWidth + * @method itemWidth * @memberof dc.legend * @instance * @param {Number} [itemWidth=70] @@ -234,7 +234,7 @@ dc.legend = function () { /** * Turn automatic width for legend items on or off. If true, {@link #dc.legend+itemWidth itemWidth} is ignored. * This setting takes into account {@link #dc.legend+gap gap}. - * @name autoItemWidth + * @method autoItemWidth * @memberof dc.legend * @instance * @param {Boolean} [autoItemWidth=false] diff --git a/src/line-chart.js b/src/line-chart.js index 759e1732c..16bd5e75e 100644 --- a/src/line-chart.js +++ b/src/line-chart.js @@ -4,7 +4,7 @@ * Examples: * - {@link http://dc-js.github.com/dc.js/ Nasdaq 100 Index} * - {@link http://dc-js.github.com/dc.js/crime/index.html Canadian City Crime Stats} - * @name lineChart + * @namespace lineChart * @memberof dc * @mixes dc.stackMixin * @mixes dc.coordinateGridMixin @@ -77,7 +77,7 @@ dc.lineChart = function (parent, chartGroup) { * {@link https://github.com/mbostock/d3/wiki/SVG-Shapes#line_interpolate d3.svg.line.interpolate} and * {@link https://github.com/mbostock/d3/wiki/SVG-Shapes#area_interpolate d3.svg.area.interpolate}, * where you can find a complete list of valid arguments - * @name interpolate + * @method interpolate * @memberof dc.lineChart * @instance * @see {@link https://github.com/mbostock/d3/wiki/SVG-Shapes#line_interpolate d3.svg.line.interpolate} @@ -99,7 +99,7 @@ dc.lineChart = function (parent, chartGroup) { * This parameter further customizes the interpolation behavior. It is passed to * {@link https://github.com/mbostock/d3/wiki/SVG-Shapes#line_tension d3.svg.line.tension} and * {@link https://github.com/mbostock/d3/wiki/SVG-Shapes#area_tension d3.svg.area.tension}. - * @name tension + * @method tension * @memberof dc.lineChart * @instance * @see {@link https://github.com/mbostock/d3/wiki/SVG-Shapes#line_interpolate d3.svg.line.interpolate} @@ -125,7 +125,7 @@ dc.lineChart = function (parent, chartGroup) { * Note: crossfilter will sometimes coerce nulls to 0, so you may need to carefully write * custom reduce functions to get this to work, depending on your data. See * https://github.com/dc-js/dc.js/issues/615#issuecomment-49089248 - * @name defined + * @method defined * @memberof dc.lineChart * @instance * @see {@link https://github.com/mbostock/d3/wiki/SVG-Shapes#line_defined d3.svg.line.defined} @@ -144,7 +144,7 @@ dc.lineChart = function (parent, chartGroup) { /** * Set the line's d3 dashstyle. This value becomes the 'stroke-dasharray' of line. Defaults to empty * array (solid line). - * @name dashStyle + * @method dashStyle * @memberof dc.lineChart * @instance * @see {@link https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/stroke-dasharray stroke-dasharray} @@ -166,7 +166,7 @@ dc.lineChart = function (parent, chartGroup) { /** * Get or set render area flag. If the flag is set to true then the chart will render the area * beneath each line and the line chart effectively becomes an area chart. - * @name renderArea + * @method renderArea * @memberof dc.lineChart * @instance * @param {Boolean} [renderArea=false] @@ -362,7 +362,7 @@ dc.lineChart = function (parent, chartGroup) { * Turn on/off the mouseover behavior of an individual data point which renders a circle and x/y axis * dashed lines back to each respective axis. This is ignored if the chart * {@link #dc.coordinateGridMixin+brushOn brush} is on - * @name xyTipsOn + * @method xyTipsOn * @memberof dc.lineChart * @instance * @param {Boolean} [xyTipsOn=false] @@ -379,7 +379,7 @@ dc.lineChart = function (parent, chartGroup) { /** * Get or set the radius (in px) for dots displayed on the data points. - * @name dotRadius + * @method dotRadius * @memberof dc.lineChart * @instance * @param {Number} [dotRadius=5] @@ -399,7 +399,7 @@ dc.lineChart = function (parent, chartGroup) { * If `options` is falsy, it disables data point rendering. * * If no `options` are provided, the current `options` values are instead returned. - * @name renderDataPoints + * @method renderDataPoints * @memberof dc.lineChart * @instance * @example diff --git a/src/margin-mixin.js b/src/margin-mixin.js index 5cf6cc1a4..c3ca44791 100644 --- a/src/margin-mixin.js +++ b/src/margin-mixin.js @@ -13,7 +13,7 @@ dc.marginMixin = function (_chart) { /** * Get or set the margins for a particular coordinate grid chart instance. The margins is stored as * an associative Javascript array. - * @name margins + * @method margins * @memberof dc.marginMixin * @instance * @example diff --git a/src/number-display.js b/src/number-display.js index fdaac7a87..0aa351e83 100644 --- a/src/number-display.js +++ b/src/number-display.js @@ -2,7 +2,7 @@ * A display of a single numeric value. * Unlike other charts, you do not need to set a dimension. Instead a group object must be provided and * a valueAccessor that returns a single value. - * @name numberDisplay + * @namespace numberDisplay * @memberof dc * @mixes dc.baseMixin * @example @@ -30,7 +30,7 @@ dc.numberDisplay = function (parent, chartGroup) { * - one: HTML template to use if the number is 1 * - zero: HTML template to use if the number is 0 * - some: HTML template to use otherwise - * @name html + * @method html * @memberof dc.numberDisplay * @instance * @example @@ -68,7 +68,7 @@ dc.numberDisplay = function (parent, chartGroup) { /** * Calculate and return the underlying value of the display - * @name value + * @method value * @memberof dc.numberDisplay * @instance * @return {Number} @@ -121,7 +121,7 @@ dc.numberDisplay = function (parent, chartGroup) { /** * Get or set a function to format the value for the display. - * @name formatNumber + * @method formatNumber * @memberof dc.numberDisplay * @instance * @see {@link https://github.com/mbostock/d3/wiki/Formatting d3.format} diff --git a/src/pie-chart.js b/src/pie-chart.js index c8a5cfa75..6a54829c4 100644 --- a/src/pie-chart.js +++ b/src/pie-chart.js @@ -6,7 +6,7 @@ * * Examples: * - {@link http://dc-js.github.com/dc.js/ Nasdaq 100 Index} - * @name pieChart + * @namespace pieChart * @memberof dc * @mixes dc.capMixin * @mixes dc.colorMixin @@ -52,7 +52,7 @@ dc.pieChart = function (parent, chartGroup) { /** * Get or set the maximum number of slices the pie chart will generate. The top slices are determined by * value from high to low. Other slices exeeding the cap will be rolled up into one single *Others* slice. - * @name slicesCap + * @method slicesCap * @memberof dc.pieChart * @instance * @param {Number} [cap] @@ -290,7 +290,7 @@ dc.pieChart = function (parent, chartGroup) { /** * Get or set the external radius padding of the pie chart. This will force the radius of the * pie chart to become smaller or larger depending on the value. - * @name externalRadiusPadding + * @method externalRadiusPadding * @memberof dc.pieChart * @instance * @param {Number} [externalRadiusPadding=0] @@ -308,7 +308,7 @@ dc.pieChart = function (parent, chartGroup) { /** * Get or set the inner radius of the pie chart. If the inner radius is greater than 0px then the * pie chart will be rendered as a doughnut chart. - * @name innerRadius + * @method innerRadius * @memberof dc.pieChart * @instance * @param {Number} [innerRadius=0] @@ -326,7 +326,7 @@ dc.pieChart = function (parent, chartGroup) { /** * Get or set the outer radius. If the radius is not set, it will be half of the minimum of the * chart width and height. - * @name radius + * @method radius * @memberof dc.pieChart * @instance * @param {Number} [radius] @@ -343,7 +343,7 @@ dc.pieChart = function (parent, chartGroup) { /** * Get or set center x coordinate position. Default is center of svg. - * @name cx + * @method cx * @memberof dc.pieChart * @instance * @param {Number} [cx] @@ -360,7 +360,7 @@ dc.pieChart = function (parent, chartGroup) { /** * Get or set center y coordinate position. Default is center of svg. - * @name cy + * @method cy * @memberof dc.pieChart * @instance * @param {Number} [cy] @@ -393,7 +393,7 @@ dc.pieChart = function (parent, chartGroup) { /** * Get or set the minimal slice angle for label rendering. Any slice with a smaller angle will not * display a slice label. - * @name minAngleForLabel + * @method minAngleForLabel * @memberof dc.pieChart * @instance * @param {Number} [minAngleForLabel=0.5] @@ -458,7 +458,7 @@ dc.pieChart = function (parent, chartGroup) { /** * Title to use for the only slice when there is no data. - * @name emptyTitle + * @method emptyTitle * @memberof dc.pieChart * @instance * @param {String} [title] @@ -477,7 +477,7 @@ dc.pieChart = function (parent, chartGroup) { * Position slice labels offset from the outer edge of the chart * * The given argument sets the radial offset. - * @name externalLabels + * @method externalLabels * @memberof dc.pieChart * @instance * @param {Number} [externalLabelRadius] @@ -499,7 +499,7 @@ dc.pieChart = function (parent, chartGroup) { /** * Get or set whether to draw lines from pie slices to their labels. * - * @name drawPaths + * @method drawPaths * @memberof dc.pieChart * @instance * @param {Boolean} [drawPaths] diff --git a/src/row-chart.js b/src/row-chart.js index e575cc5f1..47bac4459 100644 --- a/src/row-chart.js +++ b/src/row-chart.js @@ -3,7 +3,7 @@ * * Examples: * - {@link http://dc-js.github.com/dc.js/ Nasdaq 100 Index} - * @name rowChart + * @namespace rowChart * @memberof dc * @mixes dc.capMixin * @mixes dc.marginMixin @@ -97,7 +97,7 @@ dc.rowChart = function (parent, chartGroup) { /** * Gets or sets the x scale. The x scale can be any d3 * {@link https://github.com/mbostock/d3/wiki/Quantitative-Scales quantitive scale} - * @name x + * @method x * @memberof dc.rowChart * @instance * @see {@link https://github.com/mbostock/d3/wiki/Quantitative-Scales quantitive scale} @@ -257,7 +257,7 @@ dc.rowChart = function (parent, chartGroup) { /** * Turn on/off Title label rendering (values) using SVG style of text-anchor 'end' - * @name renderTitleLabel + * @method renderTitleLabel * @memberof dc.rowChart * @instance * @param {Boolean} [renderTitleLabel=false] @@ -292,7 +292,7 @@ dc.rowChart = function (parent, chartGroup) { * Get the x axis for the row chart instance. Note: not settable for row charts. * See the {@link https://github.com/mbostock/d3/wiki/SVG-Axes#wiki-axis d3 axis object} * documention for more information. - * @name xAxis + * @method xAxis * @memberof dc.rowChart * @instance * @see {@link https://github.com/mbostock/d3/wiki/SVG-Axes#wiki-axis d3.svg.axis} @@ -312,7 +312,7 @@ dc.rowChart = function (parent, chartGroup) { * For example, if you want to fix the height for a specific number of bars (useful in TopN charts) * you could fix height as follows (where count = total number of bars in your TopN and gap is * your vertical gap space). - * @name fixedBarHeight + * @method fixedBarHeight * @memberof dc.rowChart * @instance * @example @@ -331,7 +331,7 @@ dc.rowChart = function (parent, chartGroup) { /** * Get or set the vertical gap space between rows on a particular row chart instance - * @name gap + * @method gap * @memberof dc.rowChart * @instance * @param {Number} [gap=5] @@ -349,7 +349,7 @@ dc.rowChart = function (parent, chartGroup) { /** * Get or set the elasticity on x axis. If this attribute is set to true, then the x axis will rescle to auto-fit the * data range when filtered. - * @name elasticX + * @method elasticX * @memberof dc.rowChart * @instance * @param {Boolean} [elasticX] @@ -366,7 +366,7 @@ dc.rowChart = function (parent, chartGroup) { /** * Get or set the x offset (horizontal space to the top left corner of a row) for labels on a particular row chart. - * @name labelOffsetX + * @method labelOffsetX * @memberof dc.rowChart * @instance * @param {Number} [labelOffsetX=10] @@ -383,7 +383,7 @@ dc.rowChart = function (parent, chartGroup) { /** * Get or set the y offset (vertical space to the top left corner of a row) for labels on a particular row chart. - * @name labelOffsetY + * @method labelOffsetY * @memberof dc.rowChart * @instance * @param {Number} [labelOffsety=15] @@ -401,7 +401,7 @@ dc.rowChart = function (parent, chartGroup) { /** * Get of set the x offset (horizontal space between right edge of row and right edge or text. - * @name titleLabelOffsetX + * @method titleLabelOffsetX * @memberof dc.rowChart * @instance * @param {Number} [titleLabelOffsetX=2] diff --git a/src/scatter-plot.js b/src/scatter-plot.js index 653f4a5aa..f03fc628f 100644 --- a/src/scatter-plot.js +++ b/src/scatter-plot.js @@ -4,7 +4,7 @@ * Examples: * - {@link http://dc-js.github.io/dc.js/examples/scatter.html Scatter Chart} * - {@link http://dc-js.github.io/dc.js/examples/multi-scatter.html Multi-Scatter Chart} - * @name scatterPlot + * @namespace scatterPlot * @memberof dc * @mixes dc.coordinateGridMixin * @example @@ -87,7 +87,7 @@ dc.scatterPlot = function (parent, chartGroup) { * opacity 1; if it does not exist, it is drawn with * {@link #dc.scatterPlot+hiddenSize hiddenSize} radius and opacity 0. By default, * the existence accessor checks if the reduced value is truthy. - * @name existenceAccessor + * @method existenceAccessor * @memberof dc.scatterPlot * @instance * @see {@link #dc.scatterPlot+symbolSize symbolSize} @@ -110,7 +110,7 @@ dc.scatterPlot = function (parent, chartGroup) { /** * Get or set the symbol type used for each point. By default the symbol is a circle. * Type can be a constant or an accessor. - * @name symbol + * @method symbol * @memberof dc.scatterPlot * @instance * @see {@link https://github.com/mbostock/d3/wiki/SVG-Shapes#symbol_type d3.svg.symbol().type()} @@ -133,7 +133,7 @@ dc.scatterPlot = function (parent, chartGroup) { /** * Set or get radius for symbols. - * @name symbolSize + * @method symbolSize * @memberof dc.scatterPlot * @instance * @see {@link https://github.com/mbostock/d3/wiki/SVG-Shapes#symbol_size d3.svg.symbol().size()} @@ -151,7 +151,7 @@ dc.scatterPlot = function (parent, chartGroup) { /** * Set or get radius for highlighted symbols. - * @name highlightedSize + * @method highlightedSize * @memberof dc.scatterPlot * @instance * @see {@link https://github.com/mbostock/d3/wiki/SVG-Shapes#symbol_size d3.svg.symbol().size()} @@ -169,7 +169,7 @@ dc.scatterPlot = function (parent, chartGroup) { /** * Set or get radius for symbols when the group is empty. - * @name hiddenSize + * @method hiddenSize * @memberof dc.scatterPlot * @instance * @see {@link https://github.com/mbostock/d3/wiki/SVG-Shapes#symbol_size d3.svg.symbol().size()} diff --git a/src/series-chart.js b/src/series-chart.js index e7e89f5d3..0f9837a68 100644 --- a/src/series-chart.js +++ b/src/series-chart.js @@ -5,7 +5,7 @@ * * Examples: * - {@link http://dc-js.github.io/dc.js/examples/series.html Series Chart} - * @name seriesChart + * @namespace seriesChart * @memberof dc * @mixes dc.compositeChart * @example @@ -90,7 +90,7 @@ dc.seriesChart = function (parent, chartGroup) { /** * Get or set the chart function, which generates the child charts. - * @name chart + * @method chart * @memberof dc.seriesChart * @instance * @example @@ -116,7 +116,7 @@ dc.seriesChart = function (parent, chartGroup) { * * Get or set accessor function for the displayed series. Given a datum, this function * should return the series that datum belongs to. - * @name seriesAccessor + * @method seriesAccessor * @memberof dc.seriesChart * @instance * @example @@ -137,7 +137,7 @@ dc.seriesChart = function (parent, chartGroup) { /** * Get or set a function to sort the list of series by, given series values. - * @name seriesSort + * @method seriesSort * @memberof dc.seriesChart * @instance * @see {@link https://github.com/mbostock/d3/wiki/Arrays#d3_ascending d3.ascending} @@ -161,7 +161,7 @@ dc.seriesChart = function (parent, chartGroup) { * Get or set a function to sort each series values by. By default this is the key accessor which, * for example, will ensure a lineChart series connects its points in increasing key/x order, * rather than haphazardly. - * @name valueSort + * @method valueSort * @memberof dc.seriesChart * @instance * @see {@link https://github.com/mbostock/d3/wiki/Arrays#d3_ascending d3.ascending} diff --git a/src/stack-mixin.js b/src/stack-mixin.js index 7781634a0..4fa06e505 100644 --- a/src/stack-mixin.js +++ b/src/stack-mixin.js @@ -61,7 +61,7 @@ dc.stackMixin = function (_chart) { * For example, in a stacked bar chart, the bars of each stack will be positioned using the same set * of keys on the x axis, while stacked vertically. If name is specified then it will be used to * generate the legend label. - * @name stack + * @method stack * @memberof dc.stackMixin * @instance * @see {@link https://github.com/square/crossfilter/wiki/API-Reference#group-map-reduce crossfilter.group} @@ -113,7 +113,7 @@ dc.stackMixin = function (_chart) { /** * Allow named stacks to be hidden or shown by clicking on legend items. * This does not affect the behavior of hideStack or showStack. - * @name hidableStacks + * @method hidableStacks * @memberof dc.stackMixin * @instance * @param {Boolean} [hidableStacks=false] @@ -136,7 +136,7 @@ dc.stackMixin = function (_chart) { /** * Hide all stacks on the chart with the given name. * The chart must be re-rendered for this change to appear. - * @name hideStack + * @method hideStack * @memberof dc.stackMixin * @instance * @param {String} stackName @@ -153,7 +153,7 @@ dc.stackMixin = function (_chart) { /** * Show all stacks on the chart with the given name. * The chart must be re-rendered for this change to appear. - * @name showStack + * @method showStack * @memberof dc.stackMixin * @instance * @param {String} stackName @@ -211,7 +211,7 @@ dc.stackMixin = function (_chart) { * * If the first argument is a stack name, the title function will get or set the title for that stack. If stackName * is not provided, the first stack is implied. - * @name title + * @method title * @memberof dc.stackMixin * @instance * @example @@ -248,7 +248,7 @@ dc.stackMixin = function (_chart) { /** * Gets or sets the stack layout algorithm, which computes a baseline for each stack and * propagates it to the next - * @name stackLayout + * @method stackLayout * @memberof dc.stackMixin * @instance * @see {@link http://github.com/mbostock/d3/wiki/Stack-Layout d3.layout.stack} diff --git a/src/utils.js b/src/utils.js index dc9ab27ea..00fbc0f35 100644 --- a/src/utils.js +++ b/src/utils.js @@ -8,7 +8,7 @@ dc.dateFormat = d3.time.format('%m/%d/%Y'); /** - * @name printers + * @namespace printers * @memberof dc * @type {{}} */ @@ -16,7 +16,7 @@ dc.printers = {}; /** * Converts a list of filters into a readable string - * @name filters + * @method filters * @memberof dc.printers * @param {Array} filters * @returns {String} @@ -36,7 +36,7 @@ dc.printers.filters = function (filters) { /** * Converts a filter into a readable string - * @name filter + * @method filter * @memberof dc.printers * @param {dc.filters|any|Array} filter * @returns {String} @@ -63,7 +63,7 @@ dc.printers.filter = function (filter) { * Returns a function that given a string property name, can be used to pluck the property off an object. A function * can be passed as the second argument to also alter the data being returned. This can be a useful shorthand method to create * accessor functions. - * @name pluck + * @method pluck * @memberof dc * @example * var xPluck = dc.pluck('x'); @@ -89,7 +89,7 @@ dc.pluck = function (n, f) { }; /** - * @name utils + * @namespace utils * @memberof dc * @type {{}} */ @@ -97,7 +97,7 @@ dc.utils = {}; /** * Print a single value filter - * @name printSingleValue + * @method printSingleValue * @memberof dc.utils * @param {any} filter * @returns {String} @@ -121,7 +121,7 @@ dc.utils.printSingleValue.fformat = d3.format('.2f'); /** * Arbitrary add one value to another. - * @name add + * @method add * @memberof dc.utils * @todo * These assume than any string r is a percentage (whether or not it includes %). @@ -153,7 +153,7 @@ dc.utils.add = function (l, r) { /** * Arbitrary subtract one value from another. - * @name subtract + * @method subtract * @memberof dc.utils * @todo * These assume than any string r is a percentage (whether or not it includes %). @@ -185,7 +185,7 @@ dc.utils.subtract = function (l, r) { /** * Is the value a number? - * @name isNumber + * @method isNumber * @memberof dc.utils * @param {any} n * @returns {Boolean} @@ -196,7 +196,7 @@ dc.utils.isNumber = function (n) { /** * Is the value a float? - * @name isFloat + * @method isFloat * @memberof dc.utils * @param {any} n * @returns {Boolean} @@ -207,7 +207,7 @@ dc.utils.isFloat = function (n) { /** * Is the value an integer? - * @name isInteger + * @method isInteger * @memberof dc.utils * @param {any} n * @returns {Boolean} @@ -218,7 +218,7 @@ dc.utils.isInteger = function (n) { /** * Is the value very close to zero? - * @name isNegligible + * @method isNegligible * @memberof dc.utils * @param {any} n * @returns {Boolean} @@ -229,7 +229,7 @@ dc.utils.isNegligible = function (n) { /** * Ensure the value is no greater or less than the min/max values. If it is return the boundary value. - * @name clamp + * @method clamp * @memberof dc.utils * @param {any} val * @param {any} min @@ -242,7 +242,7 @@ dc.utils.clamp = function (val, min, max) { /** * Using a simple static counter, provide a unique integer id. - * @name uniqueId + * @method uniqueId * @memberof dc.utils * @returns {Number} */ @@ -253,7 +253,7 @@ dc.utils.uniqueId = function () { /** * Convert a name to an ID. - * @name nameToId + * @method nameToId * @memberof dc.utils * @param {String} name * @returns {String} @@ -264,7 +264,7 @@ dc.utils.nameToId = function (name) { /** * Append or select an item on a parent element - * @name appendOrSelect + * @method appendOrSelect * @memberof dc.utils * @param {d3.selection} parent * @param {String} selector @@ -282,7 +282,7 @@ dc.utils.appendOrSelect = function (parent, selector, tag) { /** * Return the number if the value is a number; else 0. - * @name safeNumber + * @method safeNumber * @memberof dc.utils * @param {Number|any} n * @returns {Number}