1/* 2 * Copyright (c) 2021 Huawei Device Co., Ltd. 3 * Licensed under the Apache License, Version 2.0 (the "License"); 4 * you may not use this file except in compliance with the License. 5 * You may obtain a copy of the License at 6 * 7 * http://www.apache.org/licenses/LICENSE-2.0 8 * 9 * Unless required by applicable law or agreed to in writing, software 10 * distributed under the License is distributed on an "AS IS" BASIS, 11 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 * See the License for the specific language governing permissions and 13 * limitations under the License. 14 */ 15 16 17/** 18 * DataPanelType enum 19 * @since 8 20 */ 21declare enum DataPanelType { 22 /** 23 * Line Type 24 * @since 8 25 */ 26 Line, 27 28 /** 29 * Line Rainbow 30 * @since 8 31 */ 32 Circle, 33} 34 35/** 36 * Defines the options of DataPanel. 37 * @since 7 38 */ 39declare interface DataPanelOptions { 40 /** 41 * Current data value. the max length is 9. 42 * @since 7 43 */ 44 values: number[]; 45 46 /** 47 * Maximum value of the current data. 48 * @since 7 49 */ 50 max?: number; 51 52 /** 53 * DataPanel Type 54 * @since 8 55 */ 56 type?: DataPanelType; 57} 58 59/** 60 * Defines the DataPanel component. 61 * @since 7 62 */ 63interface DataPanelInterface { 64 /** 65 * Return a DataPanel. 66 * @since 7 67 */ 68 (options: DataPanelOptions): DataPanelAttribute; 69} 70 71/** 72 * Defines the DataPanel attribute functions. 73 * @since 7 74 */ 75declare class DataPanelAttribute extends CommonMethod<DataPanelAttribute> { 76 /** 77 * Disable the special effect of the data ratio chart. 78 * @since 7 79 */ 80 closeEffect(value: boolean): DataPanelAttribute; 81} 82 83declare const DataPanel: DataPanelInterface 84declare const DataPanelInstance: DataPanelAttribute; 85