• 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/**
22 * Controls the style types of GridObjectSortComponent.
23 * @enum { string }
24 * @syscap SystemCapability.ArkUI.ArkUI.Full
25 * @crossplatform
26 * @since 11
27 */
28 /**
29 * Controls the style types of GridObjectSortComponent.
30 * @enum { string }
31 * @syscap SystemCapability.ArkUI.ArkUI.Full
32 * @crossplatform
33 * @atomicservice
34 * @since 12
35 */
36export declare enum GridObjectSortComponentType {
37  /**
38   * The GridObjectSortComponent image text type.
39   * @syscap SystemCapability.ArkUI.ArkUI.Full
40   * @crossplatform
41   * @since 11
42   */
43   /**
44   * The GridObjectSortComponent image text type.
45   * @syscap SystemCapability.ArkUI.ArkUI.Full
46   * @crossplatform
47   * @atomicservice
48   * @since 12
49   */
50  IMAGE_TEXT = "image_text",
51
52  /**
53   * The GridObjectSortComponent text type.
54   * @syscap SystemCapability.ArkUI.ArkUI.Full
55   * @crossplatform
56   * @since 11
57   */
58   /**
59   * The GridObjectSortComponent text type.
60   * @syscap SystemCapability.ArkUI.ArkUI.Full
61   * @crossplatform
62   * @atomicservice
63   * @since 12
64   */
65  TEXT = "text"
66}
67
68/**
69 * Declaration of the GridObjectSortComponent item.
70 * @interface GridObjectSortComponentIteml
71 * @syscap SystemCapability.ArkUI.ArkUI.Full
72 * @crossplatform
73 * @since 11
74 */
75 /**
76 * Declaration of the GridObjectSortComponent item.
77 * @interface GridObjectSortComponentIteml
78 * @syscap SystemCapability.ArkUI.ArkUI.Full
79 * @crossplatform
80 * @atomicservice
81 * @since 12
82 */
83export interface GridObjectSortComponentItem {
84  /**
85   * id of GridObjectSortComponent item.
86   * @type { number | string }
87   * @syscap SystemCapability.ArkUI.ArkUI.Full
88   * @crossplatform
89   * @since 11
90   */
91   /**
92   * id of GridObjectSortComponent item.
93   * @type { number | string }
94   * @syscap SystemCapability.ArkUI.ArkUI.Full
95   * @crossplatform
96   * @atomicservice
97   * @since 12
98   */
99  id: number | string;
100
101  /**
102   * GridObjectSortComponent item text.
103   * @type { ResourceStr }
104   * @syscap SystemCapability.ArkUI.ArkUI.Full
105   * @crossplatform
106   * @since 11
107   */
108   /**
109   * GridObjectSortComponent item text.
110   * @type { ResourceStr }
111   * @syscap SystemCapability.ArkUI.ArkUI.Full
112   * @crossplatform
113   * @atomicservice
114   * @since 12
115   */
116  text: ResourceStr;
117
118  /**
119   * selected of GridObjectSortComponent item, true is show area, false is add area.
120   * @type { boolean }
121   * @syscap SystemCapability.ArkUI.ArkUI.Full
122   * @crossplatform
123   * @since 11
124   */
125   /**
126   * selected of GridObjectSortComponent item, true is show area, false is add area.
127   * @type { boolean }
128   * @syscap SystemCapability.ArkUI.ArkUI.Full
129   * @crossplatform
130   * @atomicservice
131   * @since 12
132   */
133  selected: boolean;
134
135  /**
136   * order of GridObjectSortComponentItem, Used for sorting dataList.
137   * @type { number }
138   * @syscap SystemCapability.ArkUI.ArkUI.Full
139   * @crossplatform
140   * @since 11
141   */
142   /**
143   * order of GridObjectSortComponentItem, Used for sorting dataList.
144   * @type { number }
145   * @syscap SystemCapability.ArkUI.ArkUI.Full
146   * @crossplatform
147   * @atomicservice
148   * @since 12
149   */
150  order: number;
151
152  /**
153   * image resource path of the GridObjectSortComponent item.
154   * @type { ?ResourceStr }
155   * @syscap SystemCapability.ArkUI.ArkUI.Full
156   * @crossplatform
157   * @since 11
158   */
159   /**
160   * image resource path of the GridObjectSortComponent item.
161   * @type { ?ResourceStr }
162   * @syscap SystemCapability.ArkUI.ArkUI.Full
163   * @crossplatform
164   * @atomicservice
165   * @since 12
166   */
167  url?: ResourceStr;
168
169  /**
170   * symbol of the GridObjectSortComponent item.
171   * @type { ?SymbolGlyphModifier }
172   * @syscap SystemCapability.ArkUI.ArkUI.Full
173   * @atomicservice
174   * @since 18
175   */
176  symbolStyle?: SymbolGlyphModifier;
177}
178
179/**
180 * GridObjectSortComponentOptions of GridObjectSortComponent.
181 * @interface GridEditOptions
182 * @syscap SystemCapability.ArkUI.ArkUI.Full
183 * @crossplatform
184 * @since 11
185 */
186 /**
187 * GridObjectSortComponentOptions of GridObjectSortComponent.
188 * @interface GridEditOptions
189 * @syscap SystemCapability.ArkUI.ArkUI.Full
190 * @crossplatform
191 * @atomicservice
192 * @since 12
193 */
194export interface GridObjectSortComponentOptions {
195  /**
196   * Configuration GridObjectSortComponent type.
197   * @type { GridObjectSortComponentType }
198   * @default GridObjectSortComponentType.TEXT
199   * @syscap SystemCapability.ArkUI.ArkUI.Full
200   * @crossplatform
201   * @since 11
202   */
203   /**
204   * Configuration GridObjectSortComponent type.
205   * @type { GridObjectSortComponentType }
206   * @default GridObjectSortComponentType.TEXT
207   * @syscap SystemCapability.ArkUI.ArkUI.Full
208   * @crossplatform
209   * @atomicservice
210   * @since 12
211   */
212  type?: GridObjectSortComponentType;
213
214  /**
215   * The size of the GridObjectSortComponent image.
216   * @type { ?number | ?Resource }
217   * @syscap SystemCapability.ArkUI.ArkUI.Full
218   * @crossplatform
219   * @since 11
220   */
221   /**
222   * The size of the GridObjectSortComponent image.
223   * @type { ?number | ?Resource }
224   * @syscap SystemCapability.ArkUI.ArkUI.Full
225   * @crossplatform
226   * @atomicservice
227   * @since 12
228   */
229  imageSize?: number | Resource;
230
231  /**
232   * The title displayed in the unedited state of the  GridObjectSortComponent.
233   * @type { ?ResourceStr }
234   * @syscap SystemCapability.ArkUI.ArkUI.Full
235   * @crossplatform
236   * @since 11
237   */
238   /**
239   * The title displayed in the unedited state of the  GridObjectSortComponent.
240   * @type { ?ResourceStr }
241   * @syscap SystemCapability.ArkUI.ArkUI.Full
242   * @crossplatform
243   * @atomicservice
244   * @since 12
245   */
246  normalTitle?: ResourceStr;
247
248  /**
249   * The title displayed in the GridObjectSortComponent edit state.
250   * @type { ?ResourceStr }
251   * @syscap SystemCapability.ArkUI.ArkUI.Full
252   * @crossplatform
253   * @since 11
254   */
255   /**
256   * The title displayed in the GridObjectSortComponent edit state.
257   * @type { ?ResourceStr }
258   * @syscap SystemCapability.ArkUI.ArkUI.Full
259   * @crossplatform
260   * @atomicservice
261   * @since 12
262   */
263  editTitle?: ResourceStr;
264
265  /**
266   * Display Area Title, First subtitle of the GridObjectSortComponent.
267   * @type { ?ResourceStr }
268   * @syscap SystemCapability.ArkUI.ArkUI.Full
269   * @crossplatform
270   * @since 11
271   */
272   /**
273   * Display Area Title, First subtitle of the GridObjectSortComponent.
274   * @type { ?ResourceStr }
275   * @syscap SystemCapability.ArkUI.ArkUI.Full
276   * @crossplatform
277   * @atomicservice
278   * @since 12
279   */
280  showAreaTitle?: ResourceStr;
281
282  /**
283   * Add Zone Title, second subtitle of the GridObjectSortComponent.
284   * @type { ?ResourceStr }
285   * @syscap SystemCapability.ArkUI.ArkUI.Full
286   * @crossplatform
287   * @since 11
288   */
289   /**
290   * Add Zone Title, second subtitle of the GridObjectSortComponent.
291   * @type { ?ResourceStr }
292   * @syscap SystemCapability.ArkUI.ArkUI.Full
293   * @crossplatform
294   * @atomicservice
295   * @since 12
296   */
297  addAreaTitle?: ResourceStr;
298}
299
300/**
301 * Declare struct GridObjectSortComponent.
302 * @struct { GridObjectSortComponent }
303 * @syscap SystemCapability.ArkUI.ArkUI.Full
304 * @crossplatform
305 * @since 11
306 */
307 /**
308 * Declare struct GridObjectSortComponent.
309 * @struct { GridObjectSortComponent }
310 * @syscap SystemCapability.ArkUI.ArkUI.Full
311 * @crossplatform
312 * @atomicservice
313 * @since 12
314 */
315@Component
316export declare struct GridObjectSortComponent {
317  /**
318   * Component types and parameters of the GridObjectSortComponent.
319   * @type { GridObjectSortComponentOptions }
320   * @syscap SystemCapability.ArkUI.ArkUI.Full
321   * @crossplatform
322   * @since 11
323   */
324   /**
325   * Component types and parameters of the GridObjectSortComponent.
326   * @type { GridObjectSortComponentOptions }
327   * @syscap SystemCapability.ArkUI.ArkUI.Full
328   * @crossplatform
329   * @atomicservice
330   * @since 12
331   */
332  @Prop
333  options: GridObjectSortComponentOptions;
334
335  /**
336   * Data list of GridObjectSortComponent.
337   * @type { Array<GridObjectSortComponentItem> }
338   * @syscap SystemCapability.ArkUI.ArkUI.Full
339   * @crossplatform
340   * @since 11
341   */
342   /**
343   * Data list of GridObjectSortComponent.
344   * @type { Array<GridObjectSortComponentItem> }
345   * @syscap SystemCapability.ArkUI.ArkUI.Full
346   * @crossplatform
347   * @atomicservice
348   * @since 12
349   */
350  dataList: Array<GridObjectSortComponentItem>;
351
352  /**
353   * Callback when Obtain edited data.
354   * @type { (select: Array<GridObjectSortComponentItem>, unselect: Array<GridObjectSortComponentItem>) => void }
355   * @syscap SystemCapability.ArkUI.ArkUI.Full
356   * @crossplatform
357   * @since 11
358   */
359   /**
360   * Callback when Obtain edited data.
361   * @type { (select: Array<GridObjectSortComponentItem>, unselect: Array<GridObjectSortComponentItem>) => void }
362   * @syscap SystemCapability.ArkUI.ArkUI.Full
363   * @crossplatform
364   * @atomicservice
365   * @since 12
366   */
367  onSave: (select: Array<GridObjectSortComponentItem>, unselect: Array<GridObjectSortComponentItem>) => void;
368
369  /**
370   * Cancel callback for saving data.
371   * @type { () => void }
372   * @syscap SystemCapability.ArkUI.ArkUI.Full
373   * @crossplatform
374   * @since 11
375   */
376   /**
377   * Cancel callback for saving data.
378   * @type { () => void }
379   * @syscap SystemCapability.ArkUI.ArkUI.Full
380   * @crossplatform
381   * @atomicservice
382   * @since 12
383   */
384  onCancel: () => void;
385
386  /**
387   * Build function of GridObjectSortComponent.
388   * @syscap SystemCapability.ArkUI.ArkUI.Full
389   * @crossplatform
390   * @since 11
391   */
392   /**
393   * Build function of GridObjectSortComponent.
394   * @syscap SystemCapability.ArkUI.ArkUI.Full
395   * @crossplatform
396   * @atomicservice
397   * @since 12
398   */
399  build(): void;
400}