import { IgrHorizontalAnchoredCategorySeries } from "./igr-horizontal-anchored-category-series";
import { WaterfallSeries } from "./WaterfallSeries";
import { brushToString, stringToBrush, toPoint, fromRect } from "igniteui-react-core/ES2015/componentUtil";
/**
 * Represents a IgxDataChartComponent waterfall column series.
*/
export class IgrWaterfallSeries extends IgrHorizontalAnchoredCategorySeries {
    createImplementation() {
        return new WaterfallSeries();
    }
    get i() {
        return this._implementation;
    }
    constructor(props) {
        super(props);
    }
    get isNegativeColorSupported() {
        return this.i.cy;
    }
    /**
     * Gets or sets the brush to use for negative portions of the series.
    */
    get negativeBrush() {
        return brushToString(this.i.qh);
    }
    set negativeBrush(v) {
        this.i.qh = stringToBrush(v);
    }
    /**
     * Gets or sets the x-radius of the ellipse that is used to round the corners of the column.
    */
    get radiusX() {
        return this.i.p7;
    }
    set radiusX(v) {
        this.i.p7 = +v;
    }
    /**
     * Gets or sets the y-radius of the ellipse that is used to round the corners of the column.
    */
    get radiusY() {
        return this.i.p8;
    }
    set radiusY(v) {
        this.i.p8 = +v;
    }
    /**
     * Brush to use for outlining negative elements in the waterfall series.
    */
    get negativeOutline() {
        return brushToString(this.i.qi);
    }
    set negativeOutline(v) {
        this.i.qi = stringToBrush(v);
    }
    setNegativeColors(negativeBrush, negativeOutline) {
        this.i.i6(stringToBrush(negativeBrush), stringToBrush(negativeOutline));
    }
    /**
     * If possible, will return the best available value bounding box within the series that has the best value match for the world position provided.
    
    * @param world  * The world coordinate for which to get a value bounding box for
    */
    getSeriesValueBoundingBox(world) {
        let iv = this.i.li(toPoint(world));
        return fromRect(iv);
    }
    /**
     * For a category plotted series, returns the current width of the items within the categories. This only returns a value if the items have some form of width (e.g. columns, bars, etc.) otherwise 0 is returned.
    
    */
    getItemSpan() {
        let iv = this.i.eb();
        return (iv);
    }
}
