• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1/*
2 * Copyright (c) 2023 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 * @file
18 * @kit ArkUI
19 */
20
21/*** if arkts 1.2 */
22import { TextBackgroundStyle } from './span';
23import { AttributeModifier } from './common';
24/*** endif */
25
26/**
27 * Span container interface.
28 *
29 * @interface ContainerSpanInterface
30 * @syscap SystemCapability.ArkUI.ArkUI.Full
31 * @crossplatform
32 * @since 11
33 */
34/**
35 * Span container interface.
36 *
37 * @interface ContainerSpanInterface
38 * @syscap SystemCapability.ArkUI.ArkUI.Full
39 * @crossplatform
40 * @atomicservice
41 * @since arkts {'1.1':'12','1.2':'20'}
42 * @arkts 1.1&1.2
43 */
44interface ContainerSpanInterface {
45  /**
46   * Called when container is entered in span.
47   *
48   * @returns { ContainerSpanAttribute } The attribute of the container span.
49   * @syscap SystemCapability.ArkUI.ArkUI.Full
50   * @crossplatform
51   * @since 11
52   */
53  /**
54   * Called when container is entered in span.
55   *
56   * @returns { ContainerSpanAttribute } The attribute of the container span.
57   * @syscap SystemCapability.ArkUI.ArkUI.Full
58   * @crossplatform
59   * @atomicservice
60   * @since arkts {'1.1':'12','1.2':'20'}
61   * @arkts 1.1&1.2
62   */
63  (): ContainerSpanAttribute;
64}
65
66/**
67 * Define the ContainerSpan attribute functions.
68 *
69 * @syscap SystemCapability.ArkUI.ArkUI.Full
70 * @crossplatform
71 * @since 11
72 */
73/**
74 * Define the ContainerSpan attribute functions.
75 *
76 * @syscap SystemCapability.ArkUI.ArkUI.Full
77 * @crossplatform
78 * @atomicservice
79 * @since arkts {'1.1':'12','1.2':'20'}
80 * @arkts 1.1&1.2
81 */
82declare class ContainerSpanAttribute {
83  /**
84   * Span background style.
85   *
86   * @param { TextBackgroundStyle } style - The background style of span.
87   * @returns { ContainerSpanAttribute }
88   * @syscap SystemCapability.ArkUI.ArkUI.Full
89   * @crossplatform
90   * @since 11
91   */
92  /**
93   * Span background style.
94   *
95   * @param { TextBackgroundStyle } style - The background style of span.
96   * @returns { ContainerSpanAttribute }
97   * @syscap SystemCapability.ArkUI.ArkUI.Full
98   * @crossplatform
99   * @atomicservice
100   * @since arkts {'1.1':'12','1.2':'20'}
101   * @arkts 1.1&1.2
102   */
103  textBackgroundStyle(style: TextBackgroundStyle): ContainerSpanAttribute;
104
105  /**
106   * Sets the attribute modifier.
107   *
108   * @param { AttributeModifier<ContainerSpanAttribute> } modifier - The instance of contain span modifier.
109   * @returns { ContainerSpanAttribute } the attribute of the ContainerSpanAttribute.
110   * @syscap SystemCapability.ArkUI.ArkUI.Full
111   * @crossplatform
112   * @atomicservice
113   * @since arkts {'1.1':'12','1.2':'20'}
114   * @arkts 1.1&1.2
115   */
116  attributeModifier(modifier: AttributeModifier<ContainerSpanAttribute>): ContainerSpanAttribute;
117}
118
119/**
120 * Defines ContainerSpan Component instance.
121 *
122 * @syscap SystemCapability.ArkUI.ArkUI.Full
123 * @crossplatform
124 * @since 11
125 */
126/**
127 * Defines ContainerSpan Component instance.
128 *
129 * @syscap SystemCapability.ArkUI.ArkUI.Full
130 * @crossplatform
131 * @atomicservice
132 * @since 12
133 */
134declare const ContainerSpan: ContainerSpanInterface;
135
136/**
137 * Defines ContainerSpan Component.
138 *
139 * @syscap SystemCapability.ArkUI.ArkUI.Full
140 * @crossplatform
141 * @since 11
142 */
143/**
144 * Defines ContainerSpan Component.
145 *
146 * @syscap SystemCapability.ArkUI.ArkUI.Full
147 * @crossplatform
148 * @atomicservice
149 * @since 12
150 */
151declare const ContainerSpanInstance: ContainerSpanAttribute;
152