@artisan-commerce/types 0.14.0-canary.11 → 0.14.0-canary.13
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/CHANGELOG.md +16 -0
- package/build/types/app.types.d.ts +60 -35
- package/build/types/app.types.js +1 -1
- package/build/types/app.types.js.map +1 -1
- package/build/types/artisnDB.types.d.ts +9 -8
- package/build/types/artisnDB.types.js +0 -1
- package/build/types/artisnDB.types.js.map +1 -1
- package/package.json +5 -2
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,22 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
## [0.14.0-canary.13](https://bitbucket.org/tradesystem/artisn_sdk/compare/@artisan-commerce/types@0.14.0-canary.12...@artisan-commerce/types@0.14.0-canary.13) (2021-09-30)
|
|
7
|
+
|
|
8
|
+
**Note:** Version bump only for package @artisan-commerce/types
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
## [0.14.0-canary.12](https://bitbucket.org/tradesystem/artisn_sdk/compare/@artisan-commerce/types@0.14.0-canary.11...@artisan-commerce/types@0.14.0-canary.12) (2021-09-30)
|
|
15
|
+
|
|
16
|
+
**Note:** Version bump only for package @artisan-commerce/types
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
|
|
6
22
|
## [0.14.0-canary.11](https://bitbucket.org/tradesystem/artisn_sdk/compare/@artisan-commerce/types@0.14.0-canary.10...@artisan-commerce/types@0.14.0-canary.11) (2021-09-23)
|
|
7
23
|
|
|
8
24
|
|
|
@@ -1,16 +1,20 @@
|
|
|
1
1
|
import firebase from "firebase";
|
|
2
|
+
import { ReactNativeFirebase } from "@react-native-firebase/app";
|
|
3
|
+
import authRN, { FirebaseAuthTypes } from "@react-native-firebase/auth";
|
|
4
|
+
import "@react-native-firebase/firestore";
|
|
2
5
|
/**
|
|
3
6
|
* The ArtisnApp controls the app connection with the DBs and its settings.
|
|
4
7
|
*
|
|
5
8
|
* @typedef ArtisnApp
|
|
6
|
-
* @since 0.
|
|
9
|
+
* @since 0.1.0
|
|
7
10
|
*/
|
|
8
11
|
export declare type ArtisnApp = ArtisnAppWeb | ArtisnAppRN;
|
|
9
12
|
/**
|
|
10
|
-
* The ArtisnAppWeb orchestrate the connections of the app with the DB, server
|
|
13
|
+
* The ArtisnAppWeb orchestrate the connections of the app with the DB, server
|
|
14
|
+
* and its settings.
|
|
11
15
|
*
|
|
12
16
|
* @interface ArtisnAppWeb
|
|
13
|
-
* @since 0.
|
|
17
|
+
* @since 0.1.0
|
|
14
18
|
*/
|
|
15
19
|
export interface ArtisnAppWeb {
|
|
16
20
|
/** App's name */
|
|
@@ -19,46 +23,35 @@ export interface ArtisnAppWeb {
|
|
|
19
23
|
apiURL: string;
|
|
20
24
|
/** Artisn app settings configuration, see {@link ArtisnSettings} */
|
|
21
25
|
settings: ArtisnSettings;
|
|
22
|
-
/** Internal configuration of App and databases
|
|
26
|
+
/** Internal configuration of App and databases */
|
|
23
27
|
__internals__: firebase.app.App;
|
|
24
28
|
/** ArtisnApp object internal instance */
|
|
25
29
|
__instance__: typeof firebase;
|
|
26
30
|
}
|
|
27
31
|
/**
|
|
28
|
-
* The ArtisnAppRN orchestrate the connections of the app with the DB, server
|
|
32
|
+
* The ArtisnAppRN orchestrate the connections of the app with the DB, server
|
|
33
|
+
* and its settings.
|
|
29
34
|
*
|
|
30
35
|
* @interface ArtisnAppRN
|
|
31
|
-
* @since 0.
|
|
36
|
+
* @since 0.1.0
|
|
32
37
|
*/
|
|
33
38
|
export interface ArtisnAppRN {
|
|
39
|
+
/** App's name */
|
|
40
|
+
name: ReactNativeFirebase.FirebaseApp["name"];
|
|
34
41
|
/** Artisn's account API URL */
|
|
35
42
|
apiURL: string;
|
|
43
|
+
/** Artisn app settings configuration, see {@link ArtisnSettings} */
|
|
44
|
+
settings: ArtisnSettingsRN;
|
|
36
45
|
/** Internal configuration of App and databases */
|
|
37
|
-
__internals__:
|
|
46
|
+
__internals__: ReactNativeFirebase.FirebaseApp;
|
|
38
47
|
/** ArtisnApp object internal instance */
|
|
39
|
-
__instance__:
|
|
40
|
-
/** Artisn app settings configuration, see {@link ArtisnSettings} */
|
|
41
|
-
settings: ArtisnSettings;
|
|
42
|
-
/** App's name */
|
|
43
|
-
name: string;
|
|
44
|
-
}
|
|
45
|
-
/**
|
|
46
|
-
* Settings to configure the Firebase Instance.
|
|
47
|
-
*
|
|
48
|
-
* @interface RNFirebaseInstance
|
|
49
|
-
* @since 0.5.14
|
|
50
|
-
*/
|
|
51
|
-
export interface RNFirebaseInstance {
|
|
52
|
-
/** Auth package from react-native-auth */
|
|
53
|
-
auth: any;
|
|
54
|
-
/** Firestore package from react-native-auth */
|
|
55
|
-
firestore: any;
|
|
48
|
+
__instance__: ReactNativeFirebase.Module;
|
|
56
49
|
}
|
|
57
50
|
/**
|
|
58
51
|
* Settings to configure the Artisn app.
|
|
59
52
|
*
|
|
60
53
|
* @interface ArtisnSettings
|
|
61
|
-
* @since 0.
|
|
54
|
+
* @since 0.1.0
|
|
62
55
|
*/
|
|
63
56
|
export interface ArtisnSettings {
|
|
64
57
|
/** Artisn's account unique identifier */
|
|
@@ -78,7 +71,7 @@ export interface ArtisnSettings {
|
|
|
78
71
|
* Settings to configure the Artisn app react-native.
|
|
79
72
|
*
|
|
80
73
|
* @interface ArtisnSettingsRN
|
|
81
|
-
* @since 0.
|
|
74
|
+
* @since 0.1.0
|
|
82
75
|
*/
|
|
83
76
|
export interface ArtisnSettingsRN {
|
|
84
77
|
/** Platform where the app is running, see {@link ArtisnPlatform} */
|
|
@@ -90,29 +83,61 @@ export interface ArtisnSettingsRN {
|
|
|
90
83
|
* Artisn app's allowed platforms to run on.
|
|
91
84
|
*
|
|
92
85
|
* @typedef ArtisnPlatform
|
|
93
|
-
* @since 0.
|
|
86
|
+
* @since 0.1.0
|
|
94
87
|
*/
|
|
95
88
|
export declare type ArtisnPlatform = "web" | "ios" | "android" | "windows" | "macos" | "call center";
|
|
96
89
|
/**
|
|
97
90
|
* Artisn's auth instance is the instance of the internal auth object.
|
|
98
91
|
*
|
|
99
|
-
* @typedef
|
|
100
|
-
* @since 0.
|
|
92
|
+
* @typedef ArtisnAuthInstance
|
|
93
|
+
* @since 0.1.0
|
|
101
94
|
*/
|
|
102
|
-
export declare type
|
|
95
|
+
export declare type ArtisnAuthInstance = ArtisnAuthInstanceWeb | ArtisnAuthInstanceRN;
|
|
96
|
+
/**
|
|
97
|
+
* Artisn's auth instance is the instance of the internal auth object.
|
|
98
|
+
*
|
|
99
|
+
* @typedef ArtisnAuthInstanceWeb
|
|
100
|
+
* @since 0.1.0
|
|
101
|
+
*/
|
|
102
|
+
export declare type ArtisnAuthInstanceWeb = typeof firebase.auth;
|
|
103
|
+
/**
|
|
104
|
+
* Artisn's auth instance is the instance of the internal auth object for react
|
|
105
|
+
* native.
|
|
106
|
+
*
|
|
107
|
+
* @typedef ArtisnAuthInstanceRN
|
|
108
|
+
* @since 0.1.0
|
|
109
|
+
*/
|
|
110
|
+
export declare type ArtisnAuthInstanceRN = typeof authRN;
|
|
103
111
|
/**
|
|
104
112
|
* Artisn's auth object to handle providers authentication.
|
|
105
113
|
*
|
|
106
114
|
* @typedef ArtisnAuth
|
|
107
|
-
* @since 0.
|
|
115
|
+
* @since 0.1.0
|
|
116
|
+
*/
|
|
117
|
+
export declare type ArtisnAuth = ArtisnAuthWeb | ArtisnAuthRN;
|
|
118
|
+
/**
|
|
119
|
+
* Artisn's auth object to handle providers authentication.
|
|
120
|
+
*
|
|
121
|
+
* @interface ArtisnAuthWeb
|
|
122
|
+
* @since 0.1.0
|
|
123
|
+
* @extends {{@link firebase.auth.Auth}
|
|
124
|
+
*/
|
|
125
|
+
export interface ArtisnAuthWeb extends firebase.auth.Auth {
|
|
126
|
+
}
|
|
127
|
+
/**
|
|
128
|
+
* Artisn's auth object to handle providers authentication for react native.
|
|
129
|
+
*
|
|
130
|
+
* @interface ArtisnAuthRN
|
|
131
|
+
* @since 0.1.0
|
|
132
|
+
* @extends {{@link FirebaseAuthTypes.Module}
|
|
108
133
|
*/
|
|
109
|
-
export interface
|
|
134
|
+
export interface ArtisnAuthRN extends FirebaseAuthTypes.Module {
|
|
110
135
|
}
|
|
111
136
|
/**
|
|
112
137
|
* Main artisn commerce filters.
|
|
113
138
|
*
|
|
114
139
|
* @interface ArtisnHints
|
|
115
|
-
* @since 0.
|
|
140
|
+
* @since 0.1.0
|
|
116
141
|
*/
|
|
117
142
|
export interface ArtisnHints {
|
|
118
143
|
/** Artisn's account unique identifier */
|
|
@@ -132,7 +157,7 @@ export interface ArtisnHints {
|
|
|
132
157
|
* Unrestricted allowed Artisn SDK rest api headers.
|
|
133
158
|
*
|
|
134
159
|
* @interface ArtisnHeaders
|
|
135
|
-
* @since 0.
|
|
160
|
+
* @since 0.1.0
|
|
136
161
|
*/
|
|
137
162
|
export interface ArtisnHeaders {
|
|
138
163
|
/** Platform where the app is running, see {@link ArtisnPlatform} */
|
|
@@ -144,7 +169,7 @@ export interface ArtisnHeaders {
|
|
|
144
169
|
* Restricted allowed Artisn SDK rest api headers.
|
|
145
170
|
*
|
|
146
171
|
* @interface ArtisnRestrictedHeaders
|
|
147
|
-
* @since 0.
|
|
172
|
+
* @since 0.1.0
|
|
148
173
|
* @extends {{@link ArtisnHeaders}
|
|
149
174
|
*/
|
|
150
175
|
export interface ArtisnRestrictedHeaders extends ArtisnHeaders {
|
package/build/types/app.types.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"app.types.js","sourceRoot":"","sources":["../../src/types/app.types.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"app.types.js","sourceRoot":"","sources":["../../src/types/app.types.ts"],"names":[],"mappings":";;AAIA,4CAA0C"}
|
|
@@ -1,29 +1,30 @@
|
|
|
1
1
|
import firebase from "firebase";
|
|
2
|
+
import { FirebaseFirestoreTypes } from "@react-native-firebase/firestore";
|
|
2
3
|
/**
|
|
3
4
|
* Artisn database object.
|
|
4
5
|
*
|
|
5
6
|
* @typedef ArtisnDB
|
|
6
|
-
* @since 0.
|
|
7
|
+
* @since 0.1.0
|
|
7
8
|
*/
|
|
8
|
-
export declare type ArtisnDB = firebase.firestore.Firestore;
|
|
9
|
+
export declare type ArtisnDB = firebase.firestore.Firestore | FirebaseFirestoreTypes.Module;
|
|
9
10
|
/**
|
|
10
11
|
* Artisn database document data object.
|
|
11
12
|
*
|
|
12
13
|
* @typedef ArtisnDBDocumentData
|
|
13
|
-
* @since 0.
|
|
14
|
+
* @since 0.1.0
|
|
14
15
|
*/
|
|
15
|
-
export declare type ArtisnDBDocumentData = firebase.firestore.DocumentData;
|
|
16
|
+
export declare type ArtisnDBDocumentData = firebase.firestore.DocumentData | FirebaseFirestoreTypes.DocumentData;
|
|
16
17
|
/**
|
|
17
18
|
* The current state of a node from the Artisn DB.
|
|
18
19
|
*
|
|
19
20
|
* @typedef ArtisnDBQueryDocumentSnapshot
|
|
20
|
-
* @since 0.
|
|
21
|
+
* @since 0.1.0
|
|
21
22
|
*/
|
|
22
|
-
export declare type ArtisnDBQueryDocumentSnapshot<T = ArtisnDBDocumentData> = firebase.firestore.QueryDocumentSnapshot<T>;
|
|
23
|
+
export declare type ArtisnDBQueryDocumentSnapshot<T = ArtisnDBDocumentData> = firebase.firestore.QueryDocumentSnapshot<T> | FirebaseFirestoreTypes.QueryDocumentSnapshot<T>;
|
|
23
24
|
/**
|
|
24
25
|
* An Artisn DB collection of nodes.
|
|
25
26
|
*
|
|
26
27
|
* @typedef ArtisnDBCollectionReference
|
|
27
|
-
* @since 0.
|
|
28
|
+
* @since 0.1.0
|
|
28
29
|
*/
|
|
29
|
-
export declare type ArtisnDBCollectionReference<T = ArtisnDBDocumentData> = firebase.firestore.CollectionReference<T>;
|
|
30
|
+
export declare type ArtisnDBCollectionReference<T = ArtisnDBDocumentData> = firebase.firestore.CollectionReference<T> | FirebaseFirestoreTypes.CollectionReference<T>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"artisnDB.types.js","sourceRoot":"","sources":["../../src/types/artisnDB.types.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"artisnDB.types.js","sourceRoot":"","sources":["../../src/types/artisnDB.types.ts"],"names":[],"mappings":""}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@artisan-commerce/types",
|
|
3
3
|
"description": "Artisn's types and interfaces library",
|
|
4
|
-
"version": "0.14.0-canary.
|
|
4
|
+
"version": "0.14.0-canary.13",
|
|
5
5
|
"main": "./build/index.js",
|
|
6
6
|
"types": "./build/index.d.ts",
|
|
7
7
|
"files": [
|
|
@@ -23,6 +23,9 @@
|
|
|
23
23
|
"author": "Luis Eduardo Andrade",
|
|
24
24
|
"license": "MIT",
|
|
25
25
|
"devDependencies": {
|
|
26
|
+
"@react-native-firebase/app": "^12.8.0",
|
|
27
|
+
"@react-native-firebase/auth": "^12.8.0",
|
|
28
|
+
"@react-native-firebase/firestore": "^12.8.0",
|
|
26
29
|
"@types/node": "^14.0.24",
|
|
27
30
|
"@typescript-eslint/eslint-plugin": "^3.7.0",
|
|
28
31
|
"@typescript-eslint/parser": "^3.7.0",
|
|
@@ -42,5 +45,5 @@
|
|
|
42
45
|
"prettier": "^2.1.2",
|
|
43
46
|
"webpack-bundle-analyzer": "^3.9.0"
|
|
44
47
|
},
|
|
45
|
-
"gitHead": "
|
|
48
|
+
"gitHead": "8156f9f4ae00ef214142c0e1be802f7c77b436ec"
|
|
46
49
|
}
|