]> git.ipfire.org Git - thirdparty/Chart.js.git/commitdiff
Fix object notation border width barchart (#9800)
authorJacco van den Berg <39033624+LeeLenaleee@users.noreply.github.com>
Tue, 26 Oct 2021 12:50:07 +0000 (14:50 +0200)
committerGitHub <noreply@github.com>
Tue, 26 Oct 2021 12:50:07 +0000 (08:50 -0400)
* make object available for bar as border Radius

* override only the bar borderWidth prop

* spacing

types/index.esm.d.ts

index 9ae7132b459c1fe1063d316f8e80387b03b9faec..6e36c9ab4bdc37389448f3c7fb96129570057786 100644 (file)
@@ -1908,7 +1908,7 @@ export interface BarProps {
   height: number;
 }
 
-export interface BarOptions extends CommonElementOptions {
+export interface BarOptions extends Omit<CommonElementOptions, 'borderWidth'> {
   /**
    * The base value for the bar in data units along the value axis.
    */
@@ -1932,6 +1932,12 @@ export interface BarOptions extends CommonElementOptions {
    * @default 'auto'
    */
   inflateAmount: number | 'auto';
+
+  /**
+   * Width of the border, number for all sides, object to specify width for each side specifically
+   * @default 0
+   */
+  borderWidth: number | { top?: number, right?: number, bottom?: number, left?: number };
 }
 
 export interface BorderRadius {