@stacksjs/types 0.66.0 → 0.68.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/ai.d.ts +17 -14
- package/dist/analytics.d.ts +12 -14
- package/dist/api.d.ts +25 -66
- package/dist/app.d.ts +29 -134
- package/dist/auto-imports.d.ts +1 -1
- package/dist/binary.d.ts +7 -10
- package/dist/build.d.ts +2 -2
- package/dist/cache.d.ts +48 -61
- package/dist/cdn.d.ts +3 -15
- package/dist/chat.d.ts +2 -2
- package/dist/cli.d.ts +252 -238
- package/dist/cloud.d.ts +305 -68
- package/dist/components.d.ts +11 -59
- package/dist/configure.d.ts +11 -11
- package/dist/cron-jobs.d.ts +34 -41
- package/dist/database.d.ts +50 -45
- package/dist/dependencies.d.ts +15 -61
- package/dist/deploy.d.ts +10 -16
- package/dist/dns.d.ts +349 -167
- package/dist/docs.d.ts +20 -19
- package/dist/email.d.ts +15 -10
- package/dist/errors.d.ts +87 -69
- package/dist/events.d.ts +3 -30
- package/dist/exit-code.d.ts +4 -9
- package/dist/file-systems.d.ts +52 -56
- package/dist/git.d.ts +54 -126
- package/dist/hashing.d.ts +30 -97
- package/dist/helpers.d.ts +1 -1
- package/dist/i18n.d.ts +10 -18
- package/dist/index.d.ts +62 -61
- package/dist/index.js +1 -4
- package/dist/inspect.d.ts +3 -9
- package/dist/library.d.ts +798 -139
- package/dist/logging.d.ts +5 -27
- package/dist/manifest.d.ts +6 -9
- package/dist/model-names.d.ts +1 -1
- package/dist/model.d.ts +150 -130
- package/dist/notifications.d.ts +150 -105
- package/dist/pages.d.ts +10 -10
- package/dist/payments.d.ts +84 -55
- package/dist/ports.d.ts +13 -20
- package/dist/promise.d.ts +1 -1
- package/dist/push.d.ts +34 -30
- package/dist/pwa.d.ts +3 -7
- package/dist/queue.d.ts +36 -33
- package/dist/reactivity.d.ts +1 -1
- package/dist/request.d.ts +39 -26
- package/dist/router.d.ts +51 -51
- package/dist/saas.d.ts +32 -0
- package/dist/scheduler.d.ts +1 -1
- package/dist/search-engine.d.ts +85 -111
- package/dist/security.d.ts +18 -16
- package/dist/server.d.ts +16 -6
- package/dist/services.d.ts +34 -28
- package/dist/settings-config.d.ts +8 -8
- package/dist/ssg.d.ts +3 -2
- package/dist/stacks.d.ts +53 -203
- package/dist/storage.d.ts +29 -11
- package/dist/tables.d.ts +34 -52
- package/dist/team.d.ts +7 -8
- package/dist/ui.d.ts +39 -162
- package/dist/utils.d.ts +20 -30
- package/package.json +9 -10
- package/src/cache.ts +18 -0
- package/src/cli.ts +4 -0
- package/src/cloud.ts +16 -4
- package/src/errors.ts +8 -0
- package/src/index.ts +1 -0
- package/src/model-names.ts +1 -1
- package/src/model.ts +6 -0
- package/src/payments.ts +32 -0
- package/src/router.ts +1 -2
- package/src/saas.ts +33 -0
- package/src/stacks.ts +10 -0
- package/src/storage.ts +27 -0
- package/dist/env.d.ts +0 -0
- package/dist/index.js.map +0 -20
- package/dist/layout.d.ts +0 -0
- package/dist/native.d.ts +0 -0
- package/dist/sms.d.ts +0 -0
package/dist/search-engine.d.ts
CHANGED
|
@@ -1,114 +1,88 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
|
|
3
|
-
type
|
|
4
|
-
type
|
|
5
|
-
type
|
|
6
|
-
type
|
|
7
|
-
type
|
|
8
|
-
type
|
|
9
|
-
type
|
|
10
|
-
type
|
|
11
|
-
type
|
|
12
|
-
type
|
|
13
|
-
type
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
/**
|
|
32
|
-
* The number of hits to be returned per page.
|
|
33
|
-
*
|
|
34
|
-
* @default number 20
|
|
35
|
-
*/
|
|
36
|
-
perPage?: number;
|
|
1
|
+
import type { MaybePromise } from '.';
|
|
2
|
+
|
|
3
|
+
export type {;
|
|
4
|
+
declare type Search = any
|
|
5
|
+
type Page = any
|
|
6
|
+
type Pages = Page[]
|
|
7
|
+
type Filter = any
|
|
8
|
+
type Filters = Filter[]
|
|
9
|
+
type Result = any
|
|
10
|
+
type Results = Result[]
|
|
11
|
+
type SearchFilter = any
|
|
12
|
+
type SearchFilters = SearchFilter[]
|
|
13
|
+
type Sorts = any
|
|
14
|
+
type Sort = any
|
|
15
|
+
export declare interface SearchEngineOptions {
|
|
16
|
+
driver: 'opensearch'
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
opensearch?: {
|
|
20
|
+
host: string
|
|
21
|
+
protocol: number
|
|
22
|
+
port: number
|
|
23
|
+
auth: string
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
filters?: {
|
|
27
|
+
[key: string]: string
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
perPage?: number
|
|
37
31
|
}
|
|
38
|
-
export type SearchEngineConfig = Partial<SearchEngineOptions
|
|
39
|
-
export interface SearchEngineDriver {
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
32
|
+
export declare type SearchEngineConfig = Partial<SearchEngineOptions>
|
|
33
|
+
export declare interface SearchEngineDriver {
|
|
34
|
+
client: MeiliSearch
|
|
35
|
+
|
|
36
|
+
createIndex: (name: string, options?: IndexOptions) => MaybePromise<EnqueuedTask>
|
|
37
|
+
getIndex: (name: string) => MaybePromise<Index>
|
|
38
|
+
updateIndex: (name: string, options: IndexOptions) => MaybePromise<EnqueuedTask>
|
|
39
|
+
deleteIndex: (name: string) => MaybePromise<EnqueuedTask>
|
|
40
|
+
updateIndexSettings: (name: string, settings: SearchEngineOptions) => MaybePromise<EnqueuedTask>
|
|
41
|
+
listAllIndexes: () => MaybePromise<IndexesResults<Index[]>>
|
|
42
|
+
listAllIndices: () => MaybePromise<IndexesResults<Index[]>>
|
|
43
|
+
|
|
44
|
+
getRecord: (key: string) => MaybePromise<any>
|
|
45
|
+
getRecords: (key: string) => MaybePromise<RecordOptions>
|
|
46
|
+
createRecord: (record: any, indexName: string, options: RecordOptions) => MaybePromise<EnqueuedTask>
|
|
47
|
+
createRecords: (records: any, indexName: string, options: RecordOptions) => MaybePromise<EnqueuedTask>
|
|
48
|
+
createOrReplaceRecord: (record: any, indexName: string, options: RecordOptions) => MaybePromise<EnqueuedTask>
|
|
49
|
+
createOrUpdateRecord: (record: any, indexName: string, options: RecordOptions) => MaybePromise<EnqueuedTask>
|
|
50
|
+
deleteRecord: (recordId: string | number, indexName: string) => MaybePromise<EnqueuedTask>
|
|
51
|
+
deleteAllRecords: (indexName: string) => MaybePromise<EnqueuedTask>
|
|
52
|
+
batchDeleteRecords: (recordIds: string[] | number[], indexName: string) => MaybePromise<EnqueuedTask>
|
|
53
|
+
|
|
54
|
+
search: (query: string, indexName: string, options: SearchParams) => MaybePromise<Search>
|
|
55
|
+
|
|
56
|
+
calculatePagination: Pages
|
|
57
|
+
currentPage: Page
|
|
58
|
+
filterName: string
|
|
59
|
+
filters: Filters
|
|
60
|
+
goToNextPage: () => Page
|
|
61
|
+
goToPage: (pageNumber: number) => Page
|
|
62
|
+
goToPrevPage: () => Page
|
|
63
|
+
hits: Hits
|
|
64
|
+
index: Index
|
|
65
|
+
lastPage: Page
|
|
66
|
+
perPage: number
|
|
67
|
+
query: string
|
|
68
|
+
results: Results
|
|
69
|
+
searchFilters: SearchFilters
|
|
70
|
+
searchParams: SearchParams
|
|
71
|
+
setTotalHits: number
|
|
72
|
+
sort: Sort
|
|
73
|
+
sorts: Sorts
|
|
74
|
+
totalPages: number
|
|
77
75
|
}
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
* i.e. the type of table, like `users`, `posts`, `products`, etc.
|
|
85
|
-
*/
|
|
86
|
-
index?: string;
|
|
87
|
-
/**
|
|
88
|
-
* The search engine results object.
|
|
89
|
-
*/
|
|
90
|
-
results?: SearchResponse;
|
|
91
|
-
/**
|
|
92
|
-
* The search engine hits object.
|
|
93
|
-
*/
|
|
94
|
-
hits?: Hits;
|
|
95
|
-
/**
|
|
96
|
-
* The number of hits to be returned per page.
|
|
97
|
-
*
|
|
98
|
-
* @default number 20
|
|
99
|
-
*/
|
|
100
|
-
perPage: number;
|
|
101
|
-
/**
|
|
102
|
-
* The current page number.
|
|
103
|
-
*
|
|
104
|
-
* @default number 1
|
|
105
|
-
*/
|
|
106
|
-
currentPage: number;
|
|
76
|
+
export declare interface SearchEngineStorage {
|
|
77
|
+
index?: string
|
|
78
|
+
results?: SearchResponse
|
|
79
|
+
hits?: Hits
|
|
80
|
+
perPage: number
|
|
81
|
+
currentPage: number
|
|
107
82
|
}
|
|
108
|
-
export interface SearchOptions {
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
}
|
|
114
|
-
export type { EnqueuedTask, Hits, Index, IndexesResults, IndexOptions, MeiliSearch, MeilisearchOptions, RecordOptions, SearchParams, SearchResponse };
|
|
83
|
+
export declare interface SearchOptions {
|
|
84
|
+
searchable: string[]
|
|
85
|
+
sortable: string[]
|
|
86
|
+
filterable: string[]
|
|
87
|
+
options?: SearchEngineOptions
|
|
88
|
+
}
|
package/dist/security.d.ts
CHANGED
|
@@ -1,18 +1,20 @@
|
|
|
1
|
-
import type { CountryCode } from
|
|
2
|
-
import type { DeepPartial } from
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
1
|
+
import type { CountryCode } from './cloud';
|
|
2
|
+
import type { DeepPartial } from './utils';
|
|
3
|
+
|
|
4
|
+
export declare interface FirewallOptions {
|
|
5
|
+
enabled: boolean
|
|
6
|
+
countryCodes: CountryCode[]
|
|
7
|
+
ipAddresses: string[]
|
|
8
|
+
queryString: string[]
|
|
9
|
+
httpHeaders: string[]
|
|
10
|
+
rateLimitPerMinute: number
|
|
11
|
+
useIpReputationLists: boolean
|
|
12
|
+
useKnownBadInputsRuleSet: boolean
|
|
12
13
|
}
|
|
13
|
-
export type FirewallConfig = Partial<FirewallOptions
|
|
14
|
-
export interface SecurityOptions {
|
|
15
|
-
|
|
16
|
-
|
|
14
|
+
export declare type FirewallConfig = Partial<FirewallOptions>
|
|
15
|
+
export declare interface SecurityOptions {
|
|
16
|
+
driver: 'aws'
|
|
17
|
+
|
|
18
|
+
firewall: FirewallOptions
|
|
17
19
|
}
|
|
18
|
-
export type SecurityConfig = DeepPartial<SecurityOptions
|
|
20
|
+
export declare type SecurityConfig = DeepPartial<SecurityOptions>
|
package/dist/server.d.ts
CHANGED
|
@@ -1,6 +1,16 @@
|
|
|
1
|
-
export interface ServerOptions {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
1
|
+
export declare interface ServerOptions {
|
|
2
|
+
type?:
|
|
3
|
+
| 'frontend'
|
|
4
|
+
| 'backend'
|
|
5
|
+
| 'api'
|
|
6
|
+
| 'library'
|
|
7
|
+
| 'desktop'
|
|
8
|
+
| 'docs'
|
|
9
|
+
| 'email'
|
|
10
|
+
| 'admin'
|
|
11
|
+
| 'system-tray'
|
|
12
|
+
| 'database'
|
|
13
|
+
host?: string
|
|
14
|
+
port?: number
|
|
15
|
+
open?: boolean
|
|
16
|
+
}
|
package/dist/services.d.ts
CHANGED
|
@@ -1,29 +1,35 @@
|
|
|
1
|
-
export interface ServicesOptions {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
1
|
+
export declare interface ServicesOptions {
|
|
2
|
+
algolia?: {
|
|
3
|
+
appId: string
|
|
4
|
+
apiKey: string
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
godaddy?: {
|
|
8
|
+
apiKey: string
|
|
9
|
+
apiSecret: string
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
meilisearch?: {
|
|
13
|
+
appId: string
|
|
14
|
+
apiKey: string
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
lemonSqueezy?: {
|
|
18
|
+
appId: string
|
|
19
|
+
apiKey: string
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
stripe?: {
|
|
23
|
+
appId: string
|
|
24
|
+
apiKey: string
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
aws?: {
|
|
29
|
+
accountId: string
|
|
30
|
+
appId: string
|
|
31
|
+
apiKey: string
|
|
32
|
+
region: string
|
|
33
|
+
}
|
|
28
34
|
}
|
|
29
|
-
export type ServicesConfig = Partial<ServicesOptions
|
|
35
|
+
export declare type ServicesConfig = Partial<ServicesOptions>
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
export interface SettingsMenuOption {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
}
|
|
6
|
-
export interface MenuIcon {
|
|
7
|
-
name?: string;
|
|
8
|
-
source?: string;
|
|
1
|
+
export declare interface SettingsMenuOption {
|
|
2
|
+
label: string
|
|
3
|
+
path: string
|
|
4
|
+
icon?: MenuIcon
|
|
9
5
|
}
|
|
6
|
+
export declare interface MenuIcon {
|
|
7
|
+
name?: string
|
|
8
|
+
source?: string
|
|
9
|
+
}
|
package/dist/ssg.d.ts
CHANGED
|
@@ -1,2 +1,3 @@
|
|
|
1
|
-
import type { ViteSSGContext } from
|
|
2
|
-
|
|
1
|
+
import type { ViteSSGContext } from '.';
|
|
2
|
+
|
|
3
|
+
export declare type UserModule = (ctx: ViteSSGContext) => void
|
package/dist/stacks.d.ts
CHANGED
|
@@ -1,204 +1,54 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
*
|
|
54
|
-
* This configuration defines all of your Database options. Because Stacks is fully-typed, you
|
|
55
|
-
* may hover any of the options below and the definitions will be provided. In case you
|
|
56
|
-
* have any questions, feel free to reach out via Discord or GitHub Discussions.
|
|
57
|
-
*/
|
|
58
|
-
database: DatabaseConfig;
|
|
59
|
-
/**
|
|
60
|
-
* **DNS Options**
|
|
61
|
-
*
|
|
62
|
-
* This configuration defines all of your DNS options. Because Stacks is fully-typed, you
|
|
63
|
-
* may hover any of the options below and the definitions will be provided. In case you
|
|
64
|
-
* have any questions, feel free to reach out via Discord or GitHub Discussions.
|
|
65
|
-
*/
|
|
66
|
-
dns: DnsConfig;
|
|
67
|
-
/**
|
|
68
|
-
* **Docs Options**
|
|
69
|
-
*
|
|
70
|
-
* This configuration defines all of your Docs options. Because Stacks is fully-typed, you
|
|
71
|
-
* may hover any of the options below and the definitions will be provided. In case you
|
|
72
|
-
* have any questions, feel free to reach out via Discord or GitHub Discussions.
|
|
73
|
-
*/
|
|
74
|
-
docs: DocsConfig;
|
|
75
|
-
/**
|
|
76
|
-
* **Email Options**
|
|
77
|
-
*
|
|
78
|
-
* This configuration defines all of your Email options. Because Stacks is fully-typed, you
|
|
79
|
-
* may hover any of the options below and the definitions will be provided. In case you
|
|
80
|
-
* have any questions, feel free to reach out via Discord or GitHub Discussions.
|
|
81
|
-
*/
|
|
82
|
-
email: EmailConfig;
|
|
83
|
-
/**
|
|
84
|
-
* **Errors Options**
|
|
85
|
-
*
|
|
86
|
-
* This configuration defines all of your Errors options. Because Stacks is fully-typed, you
|
|
87
|
-
* may hover any of the options below and the definitions will be provided. In case you
|
|
88
|
-
* have any questions, feel free to reach out via Discord or GitHub Discussions.
|
|
89
|
-
*/
|
|
90
|
-
errors: ErrorConfig;
|
|
91
|
-
/**
|
|
92
|
-
* **Git Options**
|
|
93
|
-
*
|
|
94
|
-
* This configuration defines all of your Git options. Because Stacks is fully-typed, you
|
|
95
|
-
* may hover any of the options below and the definitions will be provided. In case you
|
|
96
|
-
* have any questions, feel free to reach out via Discord or GitHub Discussions.
|
|
97
|
-
*/
|
|
98
|
-
git: GitConfig;
|
|
99
|
-
/**
|
|
100
|
-
* **Hashing Options**
|
|
101
|
-
*
|
|
102
|
-
* This configuration defines all of your Hashing options. Because Stacks is fully-typed, you
|
|
103
|
-
* may hover any of the options below and the definitions will be provided. In case you
|
|
104
|
-
* have any questions, feel free to reach out via Discord or GitHub Discussions.
|
|
105
|
-
*/
|
|
106
|
-
hashing: HashingConfig;
|
|
107
|
-
/**
|
|
108
|
-
* **Library Options**
|
|
109
|
-
*
|
|
110
|
-
* This configuration defines all of your Library options. Because Stacks is fully-typed, you
|
|
111
|
-
* may hover any of the options below and the definitions will be provided. In case you
|
|
112
|
-
* have any questions, feel free to reach out via Discord or GitHub Discussions.
|
|
113
|
-
*/
|
|
114
|
-
library: LibraryConfig;
|
|
115
|
-
/**
|
|
116
|
-
* **Logging Options**
|
|
117
|
-
*
|
|
118
|
-
* This configuration defines all of your logging options. Because Stacks is fully-typed, you
|
|
119
|
-
* may hover any of the options below and the definitions will be provided. In case you
|
|
120
|
-
* have any questions, feel free to reach out via Discord or GitHub Discussions.
|
|
121
|
-
*/
|
|
122
|
-
logging: LoggingConfig;
|
|
123
|
-
/**
|
|
124
|
-
* **Notification Options**
|
|
125
|
-
*
|
|
126
|
-
* This configuration defines all of your Notification options. Because Stacks is fully-typed,
|
|
127
|
-
* you may hover any of the options below and the definitions will be provided. In case
|
|
128
|
-
* you have any questions, feel free to reach out via Discord or GitHub Discussions.
|
|
129
|
-
*/
|
|
130
|
-
notification: NotificationConfig;
|
|
131
|
-
/**
|
|
132
|
-
* **Payment Options**
|
|
133
|
-
*
|
|
134
|
-
* This configuration defines all of your Payment options. Because Stacks is fully-typed,
|
|
135
|
-
* you may hover any of the options below and the definitions will be provided. In case
|
|
136
|
-
* you have any questions, feel free to reach out via Discord or GitHub Discussions.
|
|
137
|
-
*/
|
|
138
|
-
payment: PaymentConfig;
|
|
139
|
-
/**
|
|
140
|
-
* **Ports**
|
|
141
|
-
*
|
|
142
|
-
* This configuration defines all of your Ports options. Because Stacks is fully-typed, you
|
|
143
|
-
* may hover any of the options below and the definitions will be provided. In case you
|
|
144
|
-
* have any questions, feel free to reach out via Discord or GitHub Discussions.
|
|
145
|
-
*/
|
|
146
|
-
ports: Ports;
|
|
147
|
-
/**
|
|
148
|
-
* **Queue Options**
|
|
149
|
-
*
|
|
150
|
-
* This configuration defines all of your Queue options. Because Stacks is fully-typed,
|
|
151
|
-
* you may hover any of the options below and the definitions will be provided. In case
|
|
152
|
-
* you have any questions, feel free to reach out via Discord or GitHub Discussions.
|
|
153
|
-
*/
|
|
154
|
-
queue: QueueConfig;
|
|
155
|
-
/**
|
|
156
|
-
* **Search Engine Options**
|
|
157
|
-
*
|
|
158
|
-
* This configuration defines all of your Search Engine options. Because Stacks is fully-typed,
|
|
159
|
-
* you may hover any of the options below and the definitions will be provided. In case
|
|
160
|
-
* you have any questions, feel free to reach out via Discord or GitHub Discussions.
|
|
161
|
-
*/
|
|
162
|
-
security: SecurityConfig;
|
|
163
|
-
/**
|
|
164
|
-
* **Search Engine Options**
|
|
165
|
-
*
|
|
166
|
-
* This configuration defines all of your Search Engine options. Because Stacks is fully-typed,
|
|
167
|
-
* you may hover any of the options below and the definitions will be provided. In case
|
|
168
|
-
* you have any questions, feel free to reach out via Discord or GitHub Discussions.
|
|
169
|
-
*/
|
|
170
|
-
searchEngine: SearchEngineConfig;
|
|
171
|
-
/**
|
|
172
|
-
* **Services Options**
|
|
173
|
-
*
|
|
174
|
-
* This configuration defines all of your Services options. Because Stacks is fully-typed,
|
|
175
|
-
* you may hover any of the options below and the definitions will be provided. In case
|
|
176
|
-
* you have any questions, feel free to reach out via Discord or GitHub Discussions.
|
|
177
|
-
*/
|
|
178
|
-
services: ServicesConfig;
|
|
179
|
-
/**
|
|
180
|
-
* **Storage Options**
|
|
181
|
-
*
|
|
182
|
-
* This configuration defines all of your Storage options. Because Stacks is fully-typed,
|
|
183
|
-
* you may hover any of the options below and the definitions will be provided. In case
|
|
184
|
-
* you have any questions, feel free to reach out via Discord or GitHub Discussions.
|
|
185
|
-
*/
|
|
186
|
-
storage: StorageConfig;
|
|
187
|
-
/**
|
|
188
|
-
* **Team Members**
|
|
189
|
-
*
|
|
190
|
-
* This configuration defines all of your Team members. Because Stacks is fully-typed, you
|
|
191
|
-
* may hover any of the options below and the definitions will be provided. In case you
|
|
192
|
-
* have any questions, feel free to reach out via Discord or GitHub Discussions.
|
|
193
|
-
*/
|
|
194
|
-
team: Team;
|
|
195
|
-
/**
|
|
196
|
-
* **UI Options**
|
|
197
|
-
*
|
|
198
|
-
* This configuration defines all of your UI options. Because Stacks is fully-typed, you
|
|
199
|
-
* may hover any of the options below and the definitions will be provided. In case you
|
|
200
|
-
* have any questions, feel free to reach out via Discord or GitHub Discussions.
|
|
201
|
-
*/
|
|
202
|
-
ui: UiConfig;
|
|
1
|
+
export declare interface StacksOptions {
|
|
2
|
+
ai: AiConfig
|
|
3
|
+
|
|
4
|
+
analytics: AnalyticsConfig
|
|
5
|
+
|
|
6
|
+
app: AppConfig
|
|
7
|
+
|
|
8
|
+
cache: CacheConfig
|
|
9
|
+
|
|
10
|
+
cli: BinaryConfig
|
|
11
|
+
|
|
12
|
+
cloud: CloudConfig
|
|
13
|
+
|
|
14
|
+
database: DatabaseConfig
|
|
15
|
+
|
|
16
|
+
dns: DnsConfig
|
|
17
|
+
|
|
18
|
+
docs: DocsConfig
|
|
19
|
+
|
|
20
|
+
email: EmailConfig
|
|
21
|
+
|
|
22
|
+
errors: ErrorConfig
|
|
23
|
+
|
|
24
|
+
git: GitConfig
|
|
25
|
+
|
|
26
|
+
hashing: HashingConfig
|
|
27
|
+
|
|
28
|
+
library: LibraryConfig
|
|
29
|
+
|
|
30
|
+
logging: LoggingConfig
|
|
31
|
+
|
|
32
|
+
notification: NotificationConfig
|
|
33
|
+
|
|
34
|
+
payment: PaymentConfig
|
|
35
|
+
|
|
36
|
+
ports: Ports
|
|
37
|
+
|
|
38
|
+
queue: QueueConfig
|
|
39
|
+
|
|
40
|
+
saas: SaasConfig
|
|
41
|
+
|
|
42
|
+
security: SecurityConfig
|
|
43
|
+
|
|
44
|
+
searchEngine: SearchEngineConfig
|
|
45
|
+
|
|
46
|
+
services: ServicesConfig
|
|
47
|
+
|
|
48
|
+
storage: StorageConfig
|
|
49
|
+
|
|
50
|
+
team: Team
|
|
51
|
+
|
|
52
|
+
ui: UiConfig
|
|
203
53
|
}
|
|
204
|
-
export type StacksConfig = Partial<StacksOptions
|
|
54
|
+
export declare type StacksConfig = Partial<StacksOptions>
|
package/dist/storage.d.ts
CHANGED
|
@@ -1,12 +1,30 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
*
|
|
7
|
-
* @default string 's3'
|
|
8
|
-
* @see https://stacksjs.org/docs/storage
|
|
9
|
-
*/
|
|
10
|
-
driver: "s3" | "efs" | "local";
|
|
1
|
+
import type { Buffer } from 'node:buffer';
|
|
2
|
+
import type { ChecksumOptions, DirectoryListing, FileContents, MimeTypeOptions, PublicUrlOptions, StatEntry, TemporaryUrlOptions } from '@flystorage/file-storage';
|
|
3
|
+
|
|
4
|
+
export declare interface StorageOptions {
|
|
5
|
+
driver: 's3' | 'efs' | 'local'
|
|
11
6
|
}
|
|
12
|
-
export type StorageConfig = Partial<StorageOptions
|
|
7
|
+
export declare type StorageConfig = Partial<StorageOptions>
|
|
8
|
+
export declare interface StorageDriver {
|
|
9
|
+
list: (path: string, options?: any) => DirectoryListing
|
|
10
|
+
changeVisibility: (path: string, visibility: string) => Promise<void>
|
|
11
|
+
visibility: (path: string) => Promise<string>
|
|
12
|
+
fileExists: (path: string) => Promise<boolean>
|
|
13
|
+
directoryExists: (path: string) => Promise<boolean>
|
|
14
|
+
publicUrl: (path: string, options: PublicUrlOptions) => Promise<string>
|
|
15
|
+
temporaryUrl: (path: string, options: TemporaryUrlOptions) => Promise<string>
|
|
16
|
+
checksum: (path: string, options: ChecksumOptions) => Promise<string>
|
|
17
|
+
mimeType: (path: string, options: MimeTypeOptions) => Promise<string>
|
|
18
|
+
lastModified: (path: string) => Promise<number>
|
|
19
|
+
fileSize: (path: string) => Promise<number>
|
|
20
|
+
read: (path: string) => Promise<FileContents>
|
|
21
|
+
readToString: (path: string) => Promise<string>
|
|
22
|
+
readToBuffer: (path: string) => Promise<Buffer>
|
|
23
|
+
readToUint8Array: (path: string) => Promise<Uint8Array>
|
|
24
|
+
deleteFile: (path: string) => Promise<void>
|
|
25
|
+
copyFile: (from: string, to: string) => Promise<void>
|
|
26
|
+
moveFile: (from: string, to: string) => Promise<void>
|
|
27
|
+
stat: (path: string) => Promise<StatEntry>
|
|
28
|
+
createDirectory: (path: string) => Promise<void>
|
|
29
|
+
write: (path: string, contents: FileContents) => Promise<void>
|
|
30
|
+
}
|