@appsemble/types 0.21.2 → 0.22.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/README.md +3 -3
- package/action.d.ts +1 -1
- package/cli.d.ts +47 -0
- package/cli.js +2 -0
- package/index.d.ts +14 -3
- package/index.js +2 -0
- package/package.json +7 -1
- package/quota.d.ts +14 -0
- package/quota.js +2 -0
- package/vitest.config.d.ts +0 -2
package/README.md
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
#  Appsemble Types
|
|
2
2
|
|
|
3
3
|
> Reusable TypeScript types
|
|
4
4
|
|
|
5
5
|
[](https://www.npmjs.com/package/@appsemble/types)
|
|
6
|
-
[](https://gitlab.com/appsemble/appsemble/-/releases/0.22.0)
|
|
7
7
|
[](https://prettier.io)
|
|
8
8
|
|
|
9
9
|
## Table of Contents
|
|
@@ -26,5 +26,5 @@ not guaranteed.
|
|
|
26
26
|
|
|
27
27
|
## License
|
|
28
28
|
|
|
29
|
-
[LGPL-3.0-only](https://gitlab.com/appsemble/appsemble/-/blob/0.
|
|
29
|
+
[LGPL-3.0-only](https://gitlab.com/appsemble/appsemble/-/blob/0.22.0/LICENSE.md) ©
|
|
30
30
|
[Appsemble](https://appsemble.com)
|
package/action.d.ts
CHANGED
|
@@ -43,5 +43,5 @@ export type ResourcePatchAction = RequestLikeAction<'resource.patch'>;
|
|
|
43
43
|
/**
|
|
44
44
|
* An action that can be called from within a block.
|
|
45
45
|
*/
|
|
46
|
-
export type Action = BaseAction<'analytics'> | BaseAction<'condition'> | BaseAction<'dialog.error'> | BaseAction<'dialog.ok'> | BaseAction<'dialog'> | BaseAction<'download'> | BaseAction<'each'> | BaseAction<'email'> | BaseAction<'event'> | BaseAction<'flow.back'> | BaseAction<'flow.cancel'> | BaseAction<'flow.finish'> | BaseAction<'flow.next'> | BaseAction<'flow.to'> | BaseAction<'link.back'> | BaseAction<'link.next'> | BaseAction<'match'> | BaseAction<'message'> | BaseAction<'noop'> | BaseAction<'notify'> | BaseAction<'resource.subscription.status'> | BaseAction<'resource.subscription.subscribe'> | BaseAction<'resource.subscription.toggle'> | BaseAction<'resource.subscription.unsubscribe'> | BaseAction<'share'> | BaseAction<'static'> | BaseAction<'storage.append'> | BaseAction<'storage.delete'> | BaseAction<'storage.read'> | BaseAction<'storage.subtract'> | BaseAction<'storage.update'> | BaseAction<'storage.write'> | BaseAction<'team.invite'> | BaseAction<'team.join'> | BaseAction<'team.list'> | BaseAction<'team.members'> | BaseAction<'throw'> | BaseAction<'user.login'> | BaseAction<'user.register'> | BaseAction<'user.update'> | LinkAction | LogAction | RequestAction | ResourceCountAction | ResourceCreateAction | ResourceDeleteAction | ResourceGetAction | ResourcePatchAction | ResourceQueryAction | ResourceUpdateAction;
|
|
46
|
+
export type Action = BaseAction<'analytics'> | BaseAction<'condition'> | BaseAction<'dialog.error'> | BaseAction<'dialog.ok'> | BaseAction<'dialog'> | BaseAction<'download'> | BaseAction<'each'> | BaseAction<'email'> | BaseAction<'event'> | BaseAction<'flow.back'> | BaseAction<'flow.cancel'> | BaseAction<'flow.finish'> | BaseAction<'flow.next'> | BaseAction<'flow.to'> | BaseAction<'link.back'> | BaseAction<'link.next'> | BaseAction<'match'> | BaseAction<'message'> | BaseAction<'noop'> | BaseAction<'notify'> | BaseAction<'resource.subscription.status'> | BaseAction<'resource.subscription.subscribe'> | BaseAction<'resource.subscription.toggle'> | BaseAction<'resource.subscription.unsubscribe'> | BaseAction<'share'> | BaseAction<'static'> | BaseAction<'storage.append'> | BaseAction<'storage.delete'> | BaseAction<'storage.read'> | BaseAction<'storage.subtract'> | BaseAction<'storage.update'> | BaseAction<'storage.write'> | BaseAction<'team.invite'> | BaseAction<'team.join'> | BaseAction<'team.list'> | BaseAction<'team.members'> | BaseAction<'throw'> | BaseAction<'user.login'> | BaseAction<'user.logout'> | BaseAction<'user.register'> | BaseAction<'user.update'> | LinkAction | LogAction | RequestAction | ResourceCountAction | ResourceCreateAction | ResourceDeleteAction | ResourceGetAction | ResourcePatchAction | ResourceQueryAction | ResourceUpdateAction;
|
|
47
47
|
export {};
|
package/cli.d.ts
ADDED
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import { type AppVisibility } from './app.js';
|
|
2
|
+
export interface AppsembleContext {
|
|
3
|
+
/**
|
|
4
|
+
* If `remote` is specified, this will override `--remote` passed by the command line.
|
|
5
|
+
*/
|
|
6
|
+
remote?: string;
|
|
7
|
+
/**
|
|
8
|
+
* If `organization` is specified, this will override `--organization` passed by the command line
|
|
9
|
+
* when creating apps.
|
|
10
|
+
*/
|
|
11
|
+
organization?: string;
|
|
12
|
+
icon?: string;
|
|
13
|
+
iconBackground?: string;
|
|
14
|
+
maskableIcon?: string;
|
|
15
|
+
/**
|
|
16
|
+
* If `id` is specified, this will override `--id` passed by the command line when
|
|
17
|
+
* updating an app.
|
|
18
|
+
*/
|
|
19
|
+
id?: number;
|
|
20
|
+
/**
|
|
21
|
+
* The Google Analytics ID that should be used for the app.
|
|
22
|
+
*/
|
|
23
|
+
googleAnalyticsId?: string;
|
|
24
|
+
/**
|
|
25
|
+
* The custom Sentry DSN for the app.
|
|
26
|
+
*/
|
|
27
|
+
sentryDsn?: string;
|
|
28
|
+
/**
|
|
29
|
+
* The environment for the custom Sentry DSN for the app.
|
|
30
|
+
*/
|
|
31
|
+
sentryEnvironment?: string;
|
|
32
|
+
/**
|
|
33
|
+
* If `visibility` is specified, this will override `--visibility` passed on the command line.
|
|
34
|
+
*/
|
|
35
|
+
visibility?: AppVisibility;
|
|
36
|
+
/**
|
|
37
|
+
* If `template` is specified, this will override `--template` passed on the command line.
|
|
38
|
+
*/
|
|
39
|
+
template?: boolean;
|
|
40
|
+
}
|
|
41
|
+
export interface AppsembleRC {
|
|
42
|
+
/**
|
|
43
|
+
* The background color to use for maskable icons.
|
|
44
|
+
*/
|
|
45
|
+
iconBackground?: string;
|
|
46
|
+
context?: Record<string, AppsembleContext>;
|
|
47
|
+
}
|
package/cli.js
ADDED
package/index.d.ts
CHANGED
|
@@ -15,6 +15,7 @@ export * from './authentication.js';
|
|
|
15
15
|
export * from './author.js';
|
|
16
16
|
export * from './bulma.js';
|
|
17
17
|
export * from './http.js';
|
|
18
|
+
export * from './cli.js';
|
|
18
19
|
export * from './snapshot.js';
|
|
19
20
|
export * from './resource.js';
|
|
20
21
|
export * from './saml.js';
|
|
@@ -23,6 +24,7 @@ export * from './team.js';
|
|
|
23
24
|
export * from './template.js';
|
|
24
25
|
export * from './theme.js';
|
|
25
26
|
export * from './user.js';
|
|
27
|
+
export * from './quota.js';
|
|
26
28
|
/**
|
|
27
29
|
* A representation of a generated OAuth2 authorization code response.
|
|
28
30
|
*/
|
|
@@ -139,6 +141,10 @@ export interface UserInfo {
|
|
|
139
141
|
* The end-user’s time zone.
|
|
140
142
|
*/
|
|
141
143
|
zoneinfo?: string;
|
|
144
|
+
/**
|
|
145
|
+
* The end-user's additional properties
|
|
146
|
+
*/
|
|
147
|
+
properties?: Record<string, string>;
|
|
142
148
|
}
|
|
143
149
|
/**
|
|
144
150
|
* The payload stored in our JSON web tokens
|
|
@@ -255,9 +261,13 @@ export interface Remappers {
|
|
|
255
261
|
*/
|
|
256
262
|
'date.add': string;
|
|
257
263
|
/**
|
|
258
|
-
*
|
|
264
|
+
* Formats a date to an iso8601 / rfc3339 compatible string.
|
|
265
|
+
*
|
|
266
|
+
* An argument can also be specified to use a different output format.
|
|
267
|
+
*
|
|
268
|
+
* Please refer to https://date-fns.org/docs/format for the supported patterns.
|
|
259
269
|
*/
|
|
260
|
-
'date.format'
|
|
270
|
+
'date.format'?: string;
|
|
261
271
|
/**
|
|
262
272
|
* Compare all computed remapper values against each other.
|
|
263
273
|
*
|
|
@@ -1115,6 +1125,7 @@ export type ResourceQueryActionDefinition = ResourceActionDefinition<'resource.q
|
|
|
1115
1125
|
export type ResourceCountActionDefinition = ResourceActionDefinition<'resource.count'>;
|
|
1116
1126
|
export type ResourceUpdateActionDefinition = ResourceActionDefinition<'resource.update'>;
|
|
1117
1127
|
export type ResourcePatchActionDefinition = ResourceActionDefinition<'resource.patch'>;
|
|
1128
|
+
export type UserLogoutAction = BaseActionDefinition<'user.logout'>;
|
|
1118
1129
|
export interface BaseResourceSubscribeActionDefinition<T extends Action['type']> extends BaseActionDefinition<T> {
|
|
1119
1130
|
/**
|
|
1120
1131
|
* The name of the resource.
|
|
@@ -1179,7 +1190,7 @@ export type MessageActionDefinition = BaseActionDefinition<'message'> & BaseMess
|
|
|
1179
1190
|
*/
|
|
1180
1191
|
body: Remapper;
|
|
1181
1192
|
};
|
|
1182
|
-
export type ActionDefinition = AnalyticsAction | BaseActionDefinition<'dialog.error'> | BaseActionDefinition<'dialog.ok'> | BaseActionDefinition<'flow.back'> | BaseActionDefinition<'flow.cancel'> | BaseActionDefinition<'flow.finish'> | BaseActionDefinition<'flow.next'> | BaseActionDefinition<'link.back'> | BaseActionDefinition<'link.next'> | BaseActionDefinition<'noop'> | BaseActionDefinition<'team.join'> | BaseActionDefinition<'team.list'> | BaseActionDefinition<'throw'> | ConditionActionDefinition | DialogActionDefinition | DownloadActionDefinition | EachActionDefinition | EmailActionDefinition | EventActionDefinition | FlowToActionDefinition | LinkActionDefinition | LogActionDefinition | MatchActionDefinition | MessageActionDefinition | NotifyActionDefinition | RequestActionDefinition | ResourceCountActionDefinition | ResourceCreateActionDefinition | ResourceDeleteActionDefinition | ResourceGetActionDefinition | ResourcePatchActionDefinition | ResourceQueryActionDefinition | ResourceSubscriptionStatusActionDefinition | ResourceSubscriptionSubscribeActionDefinition | ResourceSubscriptionToggleActionDefinition | ResourceSubscriptionUnsubscribeActionDefinition | ResourceUpdateActionDefinition | ShareActionDefinition | StaticActionDefinition | StorageAppendActionDefinition | StorageDeleteActionDefinition | StorageReadActionDefinition | StorageSubtractActionDefinition | StorageUpdateActionDefinition | StorageWriteActionDefinition | TeamInviteActionDefinition | TeamMembersActionDefinition | UserLoginAction | UserRegisterAction | UserUpdateAction;
|
|
1193
|
+
export type ActionDefinition = AnalyticsAction | BaseActionDefinition<'dialog.error'> | BaseActionDefinition<'dialog.ok'> | BaseActionDefinition<'flow.back'> | BaseActionDefinition<'flow.cancel'> | BaseActionDefinition<'flow.finish'> | BaseActionDefinition<'flow.next'> | BaseActionDefinition<'link.back'> | BaseActionDefinition<'link.next'> | BaseActionDefinition<'noop'> | BaseActionDefinition<'team.join'> | BaseActionDefinition<'team.list'> | BaseActionDefinition<'throw'> | ConditionActionDefinition | DialogActionDefinition | DownloadActionDefinition | EachActionDefinition | EmailActionDefinition | EventActionDefinition | FlowToActionDefinition | LinkActionDefinition | LogActionDefinition | MatchActionDefinition | MessageActionDefinition | NotifyActionDefinition | RequestActionDefinition | ResourceCountActionDefinition | ResourceCreateActionDefinition | ResourceDeleteActionDefinition | ResourceGetActionDefinition | ResourcePatchActionDefinition | ResourceQueryActionDefinition | ResourceSubscriptionStatusActionDefinition | ResourceSubscriptionSubscribeActionDefinition | ResourceSubscriptionToggleActionDefinition | ResourceSubscriptionUnsubscribeActionDefinition | ResourceUpdateActionDefinition | ShareActionDefinition | StaticActionDefinition | StorageAppendActionDefinition | StorageDeleteActionDefinition | StorageReadActionDefinition | StorageSubtractActionDefinition | StorageUpdateActionDefinition | StorageWriteActionDefinition | TeamInviteActionDefinition | TeamMembersActionDefinition | UserLoginAction | UserLogoutAction | UserRegisterAction | UserUpdateAction;
|
|
1183
1194
|
export interface ActionType {
|
|
1184
1195
|
/**
|
|
1185
1196
|
* Whether or not app creators are required to define this action.
|
package/index.js
CHANGED
|
@@ -6,6 +6,7 @@ export * from './authentication.js';
|
|
|
6
6
|
export * from './author.js';
|
|
7
7
|
export * from './bulma.js';
|
|
8
8
|
export * from './http.js';
|
|
9
|
+
export * from './cli.js';
|
|
9
10
|
export * from './snapshot.js';
|
|
10
11
|
export * from './resource.js';
|
|
11
12
|
export * from './saml.js';
|
|
@@ -14,4 +15,5 @@ export * from './team.js';
|
|
|
14
15
|
export * from './template.js';
|
|
15
16
|
export * from './theme.js';
|
|
16
17
|
export * from './user.js';
|
|
18
|
+
export * from './quota.js';
|
|
17
19
|
//# sourceMappingURL=index.js.map
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@appsemble/types",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.22.0",
|
|
4
4
|
"description": "TypeScript definitions reused within Appsemble internally",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"app",
|
|
@@ -22,6 +22,12 @@
|
|
|
22
22
|
"author": "Appsemble <info@appsemble.com> (https://appsemble.com)",
|
|
23
23
|
"sideEffects": false,
|
|
24
24
|
"type": "module",
|
|
25
|
+
"exports": {
|
|
26
|
+
".": [
|
|
27
|
+
"./index.js",
|
|
28
|
+
"./index.ts"
|
|
29
|
+
]
|
|
30
|
+
},
|
|
25
31
|
"files": [
|
|
26
32
|
"**/*.d.ts",
|
|
27
33
|
"**/*.js",
|
package/quota.d.ts
ADDED
package/quota.js
ADDED
package/vitest.config.d.ts
DELETED