You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/types.ts
+13-2
Original file line number
Diff line number
Diff line change
@@ -6,7 +6,11 @@ import type { Hits, SearchResponse } from 'meilisearch'
6
6
7
7
// the TableStore interface is primarily used with regards to how to persist the data to localStorage
8
8
exportinterfaceTableStore{
9
-
type: string// the Meilisearch index you would like to use for this table
9
+
/**
10
+
* The type of table, e.g. 'users', 'posts', 'products', etc.
11
+
* i.e. the Meilisearch index name
12
+
*/
13
+
index: string
10
14
columns: string[]// used as table heads/column titles
11
15
source?: string// optional: the Meilisearch host name/address (defaults: http://127.0.0.1:7700)
12
16
password?: string// optional: the Meilisearch password (defaults: '')
@@ -21,7 +25,14 @@ export interface TableStore {
21
25
actionable?: string|boolean// optional: determines whether the table displays any "action items" (defaults: true)
22
26
actions?: string|string[]// optional: the specific type of actions to be displayed/utilized in the table (defaults: 'Edit, Delete')
23
27
perPage: number// optional: the number of rows (items) to be displayed per page (defaults: 10)
24
-
currentPage: number// optional: the current page number (defaults: 1)
28
+
/**
29
+
* The current page number
30
+
* @default 1
31
+
* @type {number}
32
+
* @memberof TableStore
33
+
* @example 1
34
+
*/
35
+
currentPage: number
25
36
results?: SearchResponse<Record<string,any>>// optional: the Meilisearch search response (defaults: {})
26
37
hits?: Hits// optional: the Meilisearch hits (we could also name this "rows" as that would be more applicable to the "table domain" but choosing to stay in sync with Meilisearch right now until we implement for a second search engine driver)
27
38
selectable?: string|boolean// optional: determines whether the table displays the checkboxes (defaults: true)
0 commit comments