From 33a6b265e5d1d420d4c5b8d8346cd2eafbd356e0 Mon Sep 17 00:00:00 2001 From: kukixi Date: Mon, 27 Dec 2021 15:26:31 +0800 Subject: [PATCH] sync arkui 3.1beata api Signed-off-by: kukixi --- BUILD.gn | 9 - api/@internal/component/ets/canvas.d.ts | 8 +- api/@internal/component/ets/counter.d.ts | 12 +- api/@internal/component/ets/data_panel.d.ts | 2 +- api/@internal/component/ets/date_picker.d.ts | 136 -------------- api/@internal/component/ets/gauge.d.ts | 12 -- .../component/ets/loading_progress.d.ts | 76 -------- api/@internal/component/ets/piece.d.ts | 99 ---------- api/@internal/component/ets/radio.d.ts | 74 -------- api/@internal/component/ets/refresh.d.ts | 84 --------- api/@internal/component/ets/search.d.ts | 88 --------- api/@internal/component/ets/sheet.d.ts | 37 ---- api/@internal/component/ets/slider.d.ts | 6 - api/@internal/component/ets/swiper.d.ts | 18 -- api/@internal/component/ets/text_picker.d.ts | 91 --------- api/@internal/component/ets/video.d.ts | 173 ------------------ 16 files changed, 8 insertions(+), 917 deletions(-) delete mode 100644 api/@internal/component/ets/date_picker.d.ts delete mode 100644 api/@internal/component/ets/loading_progress.d.ts delete mode 100644 api/@internal/component/ets/piece.d.ts delete mode 100644 api/@internal/component/ets/radio.d.ts delete mode 100644 api/@internal/component/ets/refresh.d.ts delete mode 100644 api/@internal/component/ets/search.d.ts delete mode 100644 api/@internal/component/ets/sheet.d.ts delete mode 100644 api/@internal/component/ets/text_picker.d.ts delete mode 100644 api/@internal/component/ets/video.d.ts diff --git a/BUILD.gn b/BUILD.gn index 4c6cde1159..6c0059af09 100644 --- a/BUILD.gn +++ b/BUILD.gn @@ -44,7 +44,6 @@ ohos_copy("ets_component") { "api/@internal/component/ets/counter.d.ts", "api/@internal/component/ets/custom_dialog_controller.d.ts", "api/@internal/component/ets/data_panel.d.ts", - "api/@internal/component/ets/date_picker.d.ts", "api/@internal/component/ets/divider.d.ts", "api/@internal/component/ets/ellipse.d.ts", "api/@internal/component/ets/enums.d.ts", @@ -63,29 +62,23 @@ ohos_copy("ets_component") { "api/@internal/component/ets/line.d.ts", "api/@internal/component/ets/list.d.ts", "api/@internal/component/ets/listItem.d.ts", - "api/@internal/component/ets/loading_progress.d.ts", "api/@internal/component/ets/marquee.d.ts", "api/@internal/component/ets/navigation.d.ts", "api/@internal/component/ets/navigator.d.ts", "api/@internal/component/ets/pageTransition.d.ts", "api/@internal/component/ets/panel.d.ts", "api/@internal/component/ets/path.d.ts", - "api/@internal/component/ets/piece.d.ts", "api/@internal/component/ets/polygon.d.ts", "api/@internal/component/ets/polyline.d.ts", "api/@internal/component/ets/progress.d.ts", "api/@internal/component/ets/qrcode.d.ts", - "api/@internal/component/ets/radio.d.ts", "api/@internal/component/ets/rating.d.ts", "api/@internal/component/ets/rect.d.ts", - "api/@internal/component/ets/refresh.d.ts", "api/@internal/component/ets/row.d.ts", "api/@internal/component/ets/row_split.d.ts", "api/@internal/component/ets/scroll.d.ts", "api/@internal/component/ets/scroll_bar.d.ts", - "api/@internal/component/ets/search.d.ts", "api/@internal/component/ets/shape.d.ts", - "api/@internal/component/ets/sheet.d.ts", "api/@internal/component/ets/slider.d.ts", "api/@internal/component/ets/span.d.ts", "api/@internal/component/ets/stack.d.ts", @@ -98,10 +91,8 @@ ohos_copy("ets_component") { "api/@internal/component/ets/text.d.ts", "api/@internal/component/ets/text_area.d.ts", "api/@internal/component/ets/text_input.d.ts", - "api/@internal/component/ets/text_picker.d.ts", "api/@internal/component/ets/toggle.d.ts", "api/@internal/component/ets/units.d.ts", - "api/@internal/component/ets/video.d.ts", "api/@internal/component/ets/xcomponent.d.ts", ] outputs = [ target_out_dir + "/$target_name/{{source_file_part}}" ] diff --git a/api/@internal/component/ets/canvas.d.ts b/api/@internal/component/ets/canvas.d.ts index 87c0fdb6da..2cada7e51e 100644 --- a/api/@internal/component/ets/canvas.d.ts +++ b/api/@internal/component/ets/canvas.d.ts @@ -998,7 +998,7 @@ declare class CanvasRenderer extends CanvasPath { * Draw context object for the Canvas component. * @since 8 */ -export declare class RenderingContext extends CanvasRenderer { +export declare class CanvasRenderingContext2D extends CanvasRenderer { /** * The default value is 0, which is bound to the height of the specified canvas. The value is read-only. * @since 8 @@ -1032,7 +1032,7 @@ export declare class RenderingContext extends CanvasRenderer { * Draw context object for the OffscreenCanvas component. * @since 8 */ -export declare class OffscreenRenderingContext extends CanvasRenderer { +export declare class OffscreenCanvasRenderingContext2D extends CanvasRenderer { /** * Generate a character string in the data url format. * @param type Image format. The default value is image/png. @@ -1097,10 +1097,10 @@ export declare interface OffscreenCanvas extends CanvasRenderer { interface Canvas extends CanvasAttribute { /** * Construct a canvas component. - * @param context Canvas context object. For details, see {@link RenderingContext}. + * @param context Canvas context object. For details, see {@link CanvasRenderingContext2D}. * @since 8 */ - (context?: RenderingContext): Canvas; + (context?: CanvasRenderingContext2D): Canvas; } declare class CanvasAttribute extends CommonMethod { diff --git a/api/@internal/component/ets/counter.d.ts b/api/@internal/component/ets/counter.d.ts index b2ae935bbc..5a81ca001a 100644 --- a/api/@internal/component/ets/counter.d.ts +++ b/api/@internal/component/ets/counter.d.ts @@ -17,7 +17,7 @@ import { CommonMethod } from "./common"; /** * Counter component, which provides corresponding increment or decrement counting operations. - * @since 8 + * @since 7 */ interface Counter extends CounterAttribute { /** @@ -32,21 +32,15 @@ interface Counter extends CounterAttribute { * @since 8 */ declare class CounterAttribute extends CommonMethod { - /** - * Listens to the value change event. - * @since 8 - */ - onStateChange(event: () => void): T; - /** * Listen to the event that the value increases. - * @since 8 + * @since 7 */ onInc(event: () => void): T; /** * Listens to the number decrease event. - * @since 8 + * @since 7 */ onDec(event: () => void): T; } diff --git a/api/@internal/component/ets/data_panel.d.ts b/api/@internal/component/ets/data_panel.d.ts index 9441404e3a..bcecffdbaa 100644 --- a/api/@internal/component/ets/data_panel.d.ts +++ b/api/@internal/component/ets/data_panel.d.ts @@ -30,7 +30,7 @@ export declare enum DataPanelType { * Line Rainbow * @since 8 */ - Rainbow, + Circle, } /** diff --git a/api/@internal/component/ets/date_picker.d.ts b/api/@internal/component/ets/date_picker.d.ts deleted file mode 100644 index 5ea5d15c5b..0000000000 --- a/api/@internal/component/ets/date_picker.d.ts +++ /dev/null @@ -1,136 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import { CommonMethod } from "./common"; - -/** - * Defines the type of DatePicker. - * @since 8 - */ -export declare enum DatePickerType { - /** - * Application hour and second - * @since 8 - */ - Time, - - /** - * Application data - * @since 8 - */ - Date, -} - -export declare interface DatePickerResult { - /** - * Application year - * @since 8 - */ - year?: number; - - /** - * Application month - * @since 8 - */ - month?: number; - - /** - * Application day - * @since 8 - */ - day?: number; - - /** - * Application hour - * @since 8 - */ - hour?: number; - - /** - * Application minute - * @since 8 - */ - minute?: number; - - /** - * Application second - * @since 8 - */ - second?: number; -} - -/** - * Defines the option of DatePicker. - * @since 8 - */ -export declare interface DatePickerOption { - /** - * Specifies the start date of the date selector. - */ - start?: Date; - /** - * Specifies the end date for the date selector. - */ - end?: Date; - - /** - * Specifies the date selector check date or time selector check time. - */ - selected?: Date; - - /** - * Selector type, including date selector and time selector. By default, the date selector is used. - */ - type?: DatePickerType; -} - -/** - * Defines the DatePicker Component. - * @since 8 - */ -interface DatePicker extends DatePickerAttribute { - /** - * Defines the DatePicker constructor. - * @since 8 - */ - (options?: DatePickerOption): DatePicker; -} - -/** - * Defines the DatePicker attribute functions. - * @since 8 - */ -declare class DatePickerAttribute extends CommonMethod { - /** - * Date selector: true: displays the lunar calendar. false: The lunar calendar is not displayed. - * @since 8 - */ - lunar(value: boolean): T; - - /** - * Time Selector: indicates whether to display the 24-hour clock. - * @since 8 - */ - useMilitaryTime(value: boolean): T; - - /** - * This event is triggered when a DatePicker date or time is selected. - * @since 8 - */ - onChange(callback: (value: DatePickerResult) => void): T; -} - -export declare class DatePickerExtend extends DatePickerAttribute {} -export declare const DatePickerInterface: DatePicker; diff --git a/api/@internal/component/ets/gauge.d.ts b/api/@internal/component/ets/gauge.d.ts index 17f32b8e68..90c0b3a48f 100644 --- a/api/@internal/component/ets/gauge.d.ts +++ b/api/@internal/component/ets/gauge.d.ts @@ -63,18 +63,6 @@ declare class GaugeAttribute extends CommonMethod { * @since 8 */ strokeWidth(length: number): T; - - /** - * Mark points describe the content of the text. - * @since 8 - */ - labelTextConfig(markedLabelText: string): T; - - /** - * Color of the marker point description text. - * @since 8 - */ - labelColorConfig(markedLabelColor: Color): T; } export declare class GaugeExtend extends GaugeAttribute {} diff --git a/api/@internal/component/ets/loading_progress.d.ts b/api/@internal/component/ets/loading_progress.d.ts deleted file mode 100644 index da055d5485..0000000000 --- a/api/@internal/component/ets/loading_progress.d.ts +++ /dev/null @@ -1,76 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import { CommonMethod } from "./common"; -import { ResourceColor } from "./units"; - -/** - * Load style of progress bar. - * @since 8 - */ -export declare enum LoadingProgressStyle { - /** - * Default style. - * @since 8 - */ - Default, - - /** - * Announcement style. - * @since 8 - */ - Circular, - - /** - * The style of the track. - * @since 8 - */ - Orbital, -} - -/** - * Loading Progress Extensions on Declarative Classes - * @since 8 - */ -export declare class LoadingProgressExtend extends LoadingProgressAttribute {} - -/** - * Provides an interface for extending the loading progress. - * @since 8 - */ -interface LoadingProgress extends LoadingProgressAttribute { - /** - * Called when the progress bar progress is viewed. - * @since 8 - */ - (): LoadingProgress; -} - -/** - * Declare the progress bar being loaded - * @since 8 - */ -declare class LoadingProgressAttribute extends CommonMethod { - /** - * Load the color of the progress bar. - * @since 8 - */ - color(value: ResourceColor): T; -} - -/** - * @since 8 - */ -export declare const LoadingProgressInterface: LoadingProgress; diff --git a/api/@internal/component/ets/piece.d.ts b/api/@internal/component/ets/piece.d.ts deleted file mode 100644 index d0b3a25c2b..0000000000 --- a/api/@internal/component/ets/piece.d.ts +++ /dev/null @@ -1,99 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import { CommonMethod } from "./common"; -import { FontStyle, FontWeight } from "./enums"; -import { Length, ResourceColor, ResourceStr } from "./units"; - -/** - * Sets the relative position of icons and text. - * @since 8 - */ -export declare enum IconPosition { - /** - * The icon is at the beginning of the text. - * @since 8 - */ - Start, - - /** - * The icon is at the end of the text. - * @since 8 - */ - End, -} - -/** - * Provides text and icons for setting block entries. - * @since 8 - */ -interface Piece extends PieceAttribute { - /** - * Called when setting the position of a block entry. - * @since 8 - */ - (options?: { content: string; icon?: string }): Piece; -} - -/** - * @since 8 - */ -declare class PieceAttribute extends CommonMethod { - /** - * Called when the relative position of the icon and the text is set. - * @since 8 - */ - iconPosition(value: IconPosition): T; - /** - * Called when the value of Piece fontColor is set - * @since 8 - */ - fontColor(value: ResourceColor): T; - /** - * Called when the value of Piece fontSize is set - * @since 8 - */ - fontSize(value: Length): T; - /** - * Called when the value of Piece fontStyle is set - * @since 8 - */ - fontStyle(value: FontStyle): T; - /** - * Called when the value of Piece fontWeight is set - * @since 8 - */ - fontWeight(value: number | FontWeight | string): T; - /** - * Called when the value of Piece fontFamily is set - * @since 8 - */ - fontFamily(value: ResourceStr): T; - /** - * Called when the value of Piece showDelete is set - * @since 8 - */ - showDelete(value: boolean): T; - /** - * Default icon is invisible, - * Callback onClose function when icon is clicked - * @since 8 - */ - onClose(callback: () => void): T; -} - -export declare class PieceExtend extends PieceAttribute {} - -export declare const PieceInterface: Piece; diff --git a/api/@internal/component/ets/radio.d.ts b/api/@internal/component/ets/radio.d.ts deleted file mode 100644 index f8bc72d31a..0000000000 --- a/api/@internal/component/ets/radio.d.ts +++ /dev/null @@ -1,74 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import { CommonMethod } from "./common"; - -/** - * Input parameter for creating a radio box. - * @devices phone, tablet, car - * @since 8 - */ -export declare interface RadioOption { - /** - * Radio group name. - * @devices phone, tablet, car - * @since 8 - */ - group: string; - - /** - * Radio name. - * @devices phone, tablet, car - * @since 8 - */ - value: string; -} - -/** - * Provides an interface for creating a radio box. - * @devices phone, tablet, car - * @since 8 - */ -interface Radio extends RadioAttribute { - /** - * Called when a radio box is created. - * @devices phone, tablet, car - * @since 8 - */ - (options: RadioOption): Radio; -} - -/** - * @devices phone, tablet, car - * @since 8 - */ -declare class RadioAttribute extends CommonMethod { - /** - * Called when the radio box is selected. - * @devices phone, tablet, car - * @since 8 - */ - checked(value: boolean): T; - - /** - * Called when the radio box selection status changes. - * @devices phone, tablet, car - * @since 8 - */ - onChange(callback: (isChecked: boolean) => void): T; -} - -export declare class RadioExtend extends RadioAttribute {} -export declare const RadioInterface: Radio; diff --git a/api/@internal/component/ets/refresh.d.ts b/api/@internal/component/ets/refresh.d.ts deleted file mode 100644 index 8750e9f5f6..0000000000 --- a/api/@internal/component/ets/refresh.d.ts +++ /dev/null @@ -1,84 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import { CommonMethod } from "./common"; - -/** - * The refresh status of the drop-down refresh. - * @since 8 - */ -export declare enum RefreshStatus { - /** - * The refresh status of the drop-down refresh. - * @since 8 - */ - Inactive, - - /** - * Drop down, but the drop-down distance is less than the refresh distance. - * @since 8 - */ - Drag, - - /** - * The pull-down exceeds the refresh distance. - * @since 8 - */ - OverDrag, - - /** - * After the pull-down, it rebounds to the refresh distance and enters the refresh state. - * @since 8 - */ - Refresh, - - /** - * After refresh, return to the initial state. - * @since 8 - */ - Done, -} - -/** - * Provides a pull-down refresh interface. - * @since 8 - */ -interface Refresh extends RefreshAttribute { - /** - * Called when the drop-down refresh is set. - * @since 8 - */ - (value: { refreshing: boolean; offset?: number | string; friction?: number | string }): Refresh; -} - -/** - * @since 8 - */ -declare class RefreshAttribute extends CommonMethod { - /** - * Called when the refresh state changes. - * @since 8 - */ - onStateChange(callback: (state: RefreshStatus) => void): T; - - /** - * Called when the refresh state is entered. - * @since 8 - */ - onRefreshing(callback: () => void): T; -} - -export declare class RefreshExtend extends RefreshAttribute {} -export declare const RefreshInterface: Refresh; diff --git a/api/@internal/component/ets/search.d.ts b/api/@internal/component/ets/search.d.ts deleted file mode 100644 index fa36e0b07b..0000000000 --- a/api/@internal/component/ets/search.d.ts +++ /dev/null @@ -1,88 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import { CommonMethod } from "./common"; -import { ResourceColor, Font } from "./units"; - -/** - * The construct function of search - * @since 8 - */ -interface Search extends SearchAttribute { - (options?: { value?: string; placeholder?: string; icon?: string }): Search; -} - -/** - * The attribute function of search - * @since 8 - */ -declare class SearchAttribute extends CommonMethod { - /** - * Set the search button text - * @since 8 - */ - searchButton(value: string): T; - - /** - * Set the place hold text color - * @since 8 - */ - placeholderColor(value: ResourceColor): T; - - /** - * Set the font used for place holder text - * @since 8 - */ - placeholderFont(value?: Font): T; - - /** - * Set the font used for input text - * @since 8 - */ - textFont(value?: Font): T; - - /** - * Call the function when clicked the search button - * @since 8 - */ - onSubmit(callback: (value: string) => void): T; - - /** - * Call the function when editing the input text - * @since 8 - */ - onChange(callback: (value: string) => void): T; - - /** - * Called when using the Clipboard menu - * @since 8 - */ - onCopy(callback: (value: string) => void): T; - - /** - * Called when using the Clipboard menu - * @since 8 - */ - onCut(callback: (value: string) => void): T; - - /** - * Called when using the Clipboard menu - * @since 8 - */ - onPaste(callback: (value: string) => void): T; -} - -export declare class SearchExtend extends SearchAttribute {} -export declare const SearchInterface: Search; diff --git a/api/@internal/component/ets/sheet.d.ts b/api/@internal/component/ets/sheet.d.ts deleted file mode 100644 index e7381ae5c7..0000000000 --- a/api/@internal/component/ets/sheet.d.ts +++ /dev/null @@ -1,37 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import { CommonMethod } from "./common"; - -/** - * Provides the interface for the sheet attributes. - * @since 8 - */ -interface Sheet extends SheetAttribute { - /** - * Create sheet. - * @since 8 - */ - (): Sheet; -} - -/** - * Declares sheet properties. - * @since 8 - */ -declare class SheetAttribute extends CommonMethod {} - -export declare class SheetExtend extends SheetAttribute {} -export declare const SheetInterface: Sheet; diff --git a/api/@internal/component/ets/slider.d.ts b/api/@internal/component/ets/slider.d.ts index 0f877be218..38370eca59 100644 --- a/api/@internal/component/ets/slider.d.ts +++ b/api/@internal/component/ets/slider.d.ts @@ -33,12 +33,6 @@ export declare enum SliderStyle { * @since 7 */ InSet, - - /** - * Capsule style slider. - * @since 8 - */ - Capsule, } /** diff --git a/api/@internal/component/ets/swiper.d.ts b/api/@internal/component/ets/swiper.d.ts index 9958934639..f34b326422 100644 --- a/api/@internal/component/ets/swiper.d.ts +++ b/api/@internal/component/ets/swiper.d.ts @@ -128,30 +128,12 @@ declare class SwiperAttribute extends CommonMethod { */ itemSpace(value: number | string): T; - /** - * Called when setting the size of the swiper container on the spindle. - * @since 7 - */ - displayMode(value: SwiperDisplayMode): T; - /** * Called when setting the cached count of the swiper container one side. * @since 8 */ cachedCount(value: number): T; - /** - * This command is invoked when the number of subcomponents is set. - * @since 8 - */ - displayCount(value: number | string): T; - - /** - * Invoked when setting the sliding effect - * @since 8 - */ - effectMode(value: EdgeEffect): T; - /** * Called when sliding is disableSwipe * @since 8 diff --git a/api/@internal/component/ets/text_picker.d.ts b/api/@internal/component/ets/text_picker.d.ts deleted file mode 100644 index f5c4916b6f..0000000000 --- a/api/@internal/component/ets/text_picker.d.ts +++ /dev/null @@ -1,91 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import { CommonMethod } from "./common"; -import { Resource } from "./units"; - -/** - * Declare the type of selector - * @since 8 - */ -export declare enum PickerStyle { - /** - * Inside the line. - * @since 8 - */ - INLINE = 0, - - /** - * Block-level elements. - * @since 8 - */ - BLOCK, - - /** - * fade. - * @since 8 - */ - FADE, -} - -/** - * @since 8 - */ -interface TextPicker extends TextPickerAttribute { - /** - * Add the property of the selector value range. - * @since 8 - */ - (options?: { - range: string[] | Resource; - value?: string; - selected?: number; - loop?: boolean; - style?: PickerStyle; - }): TextPicker; -} - -/** - * Style the text selector. - * @since 8 - */ -declare class TextPickerAttribute extends CommonMethod { - /** - * Called when the default height of the selected element is set. - * @since 8 - */ - defaultPickerItemHeight(value: number | string): T; - - /** - * Called when the pop-up value is returned. - * @since 8 - */ - onAccept(callback: (value: string, index: number) => void): T; - - /** - * Called when the Cancel button in the pop-up window is clicked. - * @since 8 - */ - onCancel(callback: () => void): T; - - /** - * Called when the OK button in the pop-up window is clicked. - * @since 8 - */ - onChange(callback: (value: string, index: number) => void): T; -} - -export declare class TextPickerExtend extends TextPickerAttribute {} -export declare const TextPickerInterface: TextPicker; diff --git a/api/@internal/component/ets/video.d.ts b/api/@internal/component/ets/video.d.ts deleted file mode 100644 index 403359d854..0000000000 --- a/api/@internal/component/ets/video.d.ts +++ /dev/null @@ -1,173 +0,0 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import { CommonMethod } from "./common"; -import { ImageFit } from "./enums"; -import { Resource } from "./units"; - -/** - * @since 7 - */ -export declare class VideoController { - /** - * constructor. - * @since 7 - */ - constructor(); - - /** - * Provides events to play. - * @since 7 - */ - start(); - - /** - * Provides a pause event for playback. - * @since 7 - */ - pause(); - - /** - * Provides an event to stop playback. - * @since 6 - */ - stop(); - - /** - * Provide the progress method of video playback. - * @since 7 - */ - setCurrentTime(value: number); - - /** - * Provides a full screen playback method. - * @since 7 - */ - requestFullscreen(value: boolean); - - /** - * Provides a method to exit full screen playback. - * @since 7 - */ - exitFullscreen(); -} - -/** - * @since 7 - */ -interface Video extends VideoAttribute