@nx-ddd/notion 19.0.0-preview.9 → 19.1.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/fesm2022/nx-ddd-notion.mjs +540 -0
- package/fesm2022/nx-ddd-notion.mjs.map +1 -0
- package/index.d.ts +593 -6
- package/package.json +18 -12
- package/README.md +0 -11
- package/_testing/entity.d.ts +0 -20
- package/_testing/entity.js +0 -44
- package/_testing/entity.js.map +0 -1
- package/_testing/index.d.ts +0 -1
- package/_testing/index.js +0 -5
- package/_testing/index.js.map +0 -1
- package/converter/converter.d.ts +0 -7
- package/converter/converter.js +0 -37
- package/converter/converter.js.map +0 -1
- package/converter/index.d.ts +0 -1
- package/converter/index.js +0 -5
- package/converter/index.js.map +0 -1
- package/decorators/decorators.d.ts +0 -50
- package/decorators/decorators.js +0 -58
- package/decorators/decorators.js.map +0 -1
- package/decorators/index.d.ts +0 -1
- package/decorators/index.js +0 -5
- package/decorators/index.js.map +0 -1
- package/index.js +0 -10
- package/index.js.map +0 -1
- package/notion/index.d.ts +0 -1
- package/notion/index.js +0 -5
- package/notion/index.js.map +0 -1
- package/notion/notion.service.d.ts +0 -8
- package/notion/notion.service.impl.d.ts +0 -30
- package/notion/notion.service.impl.js +0 -142
- package/notion/notion.service.impl.js.map +0 -1
- package/notion/notion.service.js +0 -12
- package/notion/notion.service.js.map +0 -1
- package/query/index.d.ts +0 -1
- package/query/index.js +0 -5
- package/query/index.js.map +0 -1
- package/query/query.d.ts +0 -168
- package/query/query.js +0 -122
- package/query/query.js.map +0 -1
- package/query-builder/index.d.ts +0 -1
- package/query-builder/index.js +0 -5
- package/query-builder/index.js.map +0 -1
- package/query-builder/query-builder.d.ts +0 -27
- package/query-builder/query-builder.js +0 -30
- package/query-builder/query-builder.js.map +0 -1
- package/repository/index.d.ts +0 -1
- package/repository/index.js +0 -5
- package/repository/index.js.map +0 -1
- package/repository/repository.d.ts +0 -48
- package/repository/repository.js +0 -112
- package/repository/repository.js.map +0 -1
- package/utils.d.ts +0 -252
- package/utils.js +0 -184
- package/utils.js.map +0 -1
package/query/query.d.ts
DELETED
|
@@ -1,168 +0,0 @@
|
|
|
1
|
-
type Evaluation = '==' | '>' | '>=' | '<' | '<=' | '!=' | 'in';
|
|
2
|
-
export declare class N {
|
|
3
|
-
static RollupPropQuery(property: string, evaluation: Evaluation, value: string | number): {
|
|
4
|
-
property: string;
|
|
5
|
-
rollup: {
|
|
6
|
-
every: {
|
|
7
|
-
rich_text: {
|
|
8
|
-
equals: string | number;
|
|
9
|
-
};
|
|
10
|
-
};
|
|
11
|
-
};
|
|
12
|
-
};
|
|
13
|
-
static FormulaQuery(property: string, evaluation: Evaluation, value: string | number): {
|
|
14
|
-
property: string;
|
|
15
|
-
formula: {};
|
|
16
|
-
};
|
|
17
|
-
static LastEditedTime(property: string, evaluation: Evaluation, value: string | number): {
|
|
18
|
-
timestamp: string;
|
|
19
|
-
last_edited_time: {
|
|
20
|
-
[x: string]: string | number;
|
|
21
|
-
};
|
|
22
|
-
};
|
|
23
|
-
static Timestamp(property: string, evaluation: Evaluation, value: string): {
|
|
24
|
-
property: string;
|
|
25
|
-
timestamp: {
|
|
26
|
-
[x: string]: string;
|
|
27
|
-
};
|
|
28
|
-
};
|
|
29
|
-
static Status(property: string, evaluation: Evaluation, value: string): {
|
|
30
|
-
property: string;
|
|
31
|
-
status: {
|
|
32
|
-
[x: string]: string;
|
|
33
|
-
};
|
|
34
|
-
};
|
|
35
|
-
static Relation(property: string, evaluation: Evaluation, value: string): {
|
|
36
|
-
property: string;
|
|
37
|
-
relation: {
|
|
38
|
-
[x: string]: string;
|
|
39
|
-
};
|
|
40
|
-
};
|
|
41
|
-
}
|
|
42
|
-
export declare abstract class NotionBaseQuery {
|
|
43
|
-
type: 'and' | 'or' | 'filter' | 'sort';
|
|
44
|
-
abstract build(): any;
|
|
45
|
-
}
|
|
46
|
-
export declare class NotionFilter extends NotionBaseQuery {
|
|
47
|
-
propertyType: any;
|
|
48
|
-
propertyName: string;
|
|
49
|
-
evaluation: Evaluation;
|
|
50
|
-
value: string | number;
|
|
51
|
-
readonly type: 'filter';
|
|
52
|
-
constructor(propertyType: any, propertyName: string, evaluation: Evaluation, value: string | number);
|
|
53
|
-
build(): {
|
|
54
|
-
property: string;
|
|
55
|
-
rollup: {
|
|
56
|
-
every: {
|
|
57
|
-
rich_text: {
|
|
58
|
-
equals: string | number;
|
|
59
|
-
};
|
|
60
|
-
};
|
|
61
|
-
};
|
|
62
|
-
} | {
|
|
63
|
-
property: string;
|
|
64
|
-
formula: {};
|
|
65
|
-
} | {
|
|
66
|
-
timestamp: string;
|
|
67
|
-
last_edited_time: {
|
|
68
|
-
[x: string]: string | number;
|
|
69
|
-
};
|
|
70
|
-
} | {
|
|
71
|
-
property: string;
|
|
72
|
-
status: {
|
|
73
|
-
[x: string]: string;
|
|
74
|
-
};
|
|
75
|
-
} | {
|
|
76
|
-
property: string;
|
|
77
|
-
relation: {
|
|
78
|
-
[x: string]: string;
|
|
79
|
-
};
|
|
80
|
-
};
|
|
81
|
-
}
|
|
82
|
-
export declare class NotionSort extends NotionBaseQuery {
|
|
83
|
-
property: string;
|
|
84
|
-
direction: 'asc' | 'desc';
|
|
85
|
-
readonly type: 'sort';
|
|
86
|
-
constructor(property: string, direction?: 'asc' | 'desc');
|
|
87
|
-
build(): {
|
|
88
|
-
property: string;
|
|
89
|
-
direction: string;
|
|
90
|
-
};
|
|
91
|
-
}
|
|
92
|
-
export declare class NotionAnd extends NotionBaseQuery {
|
|
93
|
-
readonly type: 'and';
|
|
94
|
-
arr: NotionFilter[];
|
|
95
|
-
constructor(...filters: NotionFilter[]);
|
|
96
|
-
build(): {
|
|
97
|
-
and: ({
|
|
98
|
-
property: string;
|
|
99
|
-
rollup: {
|
|
100
|
-
every: {
|
|
101
|
-
rich_text: {
|
|
102
|
-
equals: string | number;
|
|
103
|
-
};
|
|
104
|
-
};
|
|
105
|
-
};
|
|
106
|
-
} | {
|
|
107
|
-
property: string;
|
|
108
|
-
formula: {};
|
|
109
|
-
} | {
|
|
110
|
-
timestamp: string;
|
|
111
|
-
last_edited_time: {
|
|
112
|
-
[x: string]: string | number;
|
|
113
|
-
};
|
|
114
|
-
} | {
|
|
115
|
-
property: string;
|
|
116
|
-
status: {
|
|
117
|
-
[x: string]: string;
|
|
118
|
-
};
|
|
119
|
-
} | {
|
|
120
|
-
property: string;
|
|
121
|
-
relation: {
|
|
122
|
-
[x: string]: string;
|
|
123
|
-
};
|
|
124
|
-
})[];
|
|
125
|
-
};
|
|
126
|
-
}
|
|
127
|
-
export declare class NotionOr extends NotionBaseQuery {
|
|
128
|
-
readonly type: 'or';
|
|
129
|
-
arr: NotionFilter[];
|
|
130
|
-
constructor(...filters: NotionFilter[]);
|
|
131
|
-
build(): {
|
|
132
|
-
or: ({
|
|
133
|
-
property: string;
|
|
134
|
-
rollup: {
|
|
135
|
-
every: {
|
|
136
|
-
rich_text: {
|
|
137
|
-
equals: string | number;
|
|
138
|
-
};
|
|
139
|
-
};
|
|
140
|
-
};
|
|
141
|
-
} | {
|
|
142
|
-
property: string;
|
|
143
|
-
formula: {};
|
|
144
|
-
} | {
|
|
145
|
-
timestamp: string;
|
|
146
|
-
last_edited_time: {
|
|
147
|
-
[x: string]: string | number;
|
|
148
|
-
};
|
|
149
|
-
} | {
|
|
150
|
-
property: string;
|
|
151
|
-
status: {
|
|
152
|
-
[x: string]: string;
|
|
153
|
-
};
|
|
154
|
-
} | {
|
|
155
|
-
property: string;
|
|
156
|
-
relation: {
|
|
157
|
-
[x: string]: string;
|
|
158
|
-
};
|
|
159
|
-
})[];
|
|
160
|
-
};
|
|
161
|
-
}
|
|
162
|
-
export declare const Query: <E = any>(Entity: E) => {
|
|
163
|
-
Filter: (_propName: string, evaluation: Evaluation, value: string | number) => NotionFilter;
|
|
164
|
-
OrderBy: (_propName: string, direction: "asc" | "desc") => NotionSort;
|
|
165
|
-
And: (...args: NotionFilter[]) => NotionAnd;
|
|
166
|
-
Or: (...args: NotionFilter[]) => NotionOr;
|
|
167
|
-
};
|
|
168
|
-
export {};
|
package/query/query.js
DELETED
|
@@ -1,122 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.Query = exports.NotionOr = exports.NotionAnd = exports.NotionSort = exports.NotionFilter = exports.NotionBaseQuery = exports.N = void 0;
|
|
4
|
-
const decorators_1 = require("../decorators");
|
|
5
|
-
class N {
|
|
6
|
-
static RollupPropQuery(property, evaluation, value) {
|
|
7
|
-
return { property, rollup: { every: { rich_text: { equals: value } } } };
|
|
8
|
-
}
|
|
9
|
-
static FormulaQuery(property, evaluation, value) {
|
|
10
|
-
return { property, formula: {} };
|
|
11
|
-
}
|
|
12
|
-
static LastEditedTime(property, evaluation, value) {
|
|
13
|
-
const query = evaluation === '>' ? 'after'
|
|
14
|
-
: evaluation === '<' ? 'before'
|
|
15
|
-
: evaluation === '==' ? 'equals'
|
|
16
|
-
: evaluation === '<=' ? 'on_or_before'
|
|
17
|
-
: evaluation === '>=' ? 'on_or_after'
|
|
18
|
-
: evaluation === '!=' ? '' : '';
|
|
19
|
-
return { timestamp: 'last_edited_time', last_edited_time: { [query]: value } };
|
|
20
|
-
}
|
|
21
|
-
static Timestamp(property, evaluation, value) {
|
|
22
|
-
const query = evaluation === '>' ? 'after'
|
|
23
|
-
: evaluation === '<' ? 'before'
|
|
24
|
-
: evaluation === '==' ? 'equals'
|
|
25
|
-
: evaluation === '<=' ? 'on_or_before'
|
|
26
|
-
: evaluation === '>=' ? 'on_or_after'
|
|
27
|
-
: evaluation === '!=' ? '' : '';
|
|
28
|
-
return { property, timestamp: { [query]: value } };
|
|
29
|
-
}
|
|
30
|
-
static Status(property, evaluation, value) {
|
|
31
|
-
const query = evaluation === '==' ? 'equals' : '';
|
|
32
|
-
// TODO(nontangent): 'ステータス'を修正
|
|
33
|
-
return { property: 'ステータス', status: { [query]: value } };
|
|
34
|
-
}
|
|
35
|
-
static Relation(property, evaluation, value) {
|
|
36
|
-
const query = evaluation === 'in' ? 'contains' : '';
|
|
37
|
-
return { property, relation: { [query]: value } };
|
|
38
|
-
}
|
|
39
|
-
}
|
|
40
|
-
exports.N = N;
|
|
41
|
-
class NotionBaseQuery {
|
|
42
|
-
}
|
|
43
|
-
exports.NotionBaseQuery = NotionBaseQuery;
|
|
44
|
-
class NotionFilter extends NotionBaseQuery {
|
|
45
|
-
constructor(propertyType, propertyName, evaluation, value) {
|
|
46
|
-
super();
|
|
47
|
-
this.propertyType = propertyType;
|
|
48
|
-
this.propertyName = propertyName;
|
|
49
|
-
this.evaluation = evaluation;
|
|
50
|
-
this.value = value;
|
|
51
|
-
this.type = 'filter';
|
|
52
|
-
}
|
|
53
|
-
build() {
|
|
54
|
-
switch (this.propertyName) {
|
|
55
|
-
case 'last_edited_time': return N.LastEditedTime(this.propertyName, this.evaluation, this.value);
|
|
56
|
-
}
|
|
57
|
-
switch (this.propertyType) {
|
|
58
|
-
case 'rollup': return N.RollupPropQuery(this.propertyName, this.evaluation, this.value);
|
|
59
|
-
case 'formula': return N.FormulaQuery(this.propertyName, this.evaluation, this.value);
|
|
60
|
-
case 'status': return N.Status(this.propertyName, this.evaluation, this.value);
|
|
61
|
-
case 'relation': return N.Relation(this.propertyName, this.evaluation, this.value);
|
|
62
|
-
}
|
|
63
|
-
}
|
|
64
|
-
}
|
|
65
|
-
exports.NotionFilter = NotionFilter;
|
|
66
|
-
class NotionSort extends NotionBaseQuery {
|
|
67
|
-
constructor(property, direction = 'asc') {
|
|
68
|
-
super();
|
|
69
|
-
this.property = property;
|
|
70
|
-
this.direction = direction;
|
|
71
|
-
this.type = 'sort';
|
|
72
|
-
}
|
|
73
|
-
build() {
|
|
74
|
-
return {
|
|
75
|
-
property: this.property,
|
|
76
|
-
direction: this.direction === 'asc' ? 'ascending' : 'descending',
|
|
77
|
-
};
|
|
78
|
-
}
|
|
79
|
-
}
|
|
80
|
-
exports.NotionSort = NotionSort;
|
|
81
|
-
class NotionAnd extends NotionBaseQuery {
|
|
82
|
-
constructor(...filters) {
|
|
83
|
-
super();
|
|
84
|
-
this.type = 'and';
|
|
85
|
-
this.arr = filters;
|
|
86
|
-
}
|
|
87
|
-
build() {
|
|
88
|
-
return { and: this.arr.map(filter => filter.build()) };
|
|
89
|
-
}
|
|
90
|
-
}
|
|
91
|
-
exports.NotionAnd = NotionAnd;
|
|
92
|
-
class NotionOr extends NotionBaseQuery {
|
|
93
|
-
constructor(...filters) {
|
|
94
|
-
super();
|
|
95
|
-
this.type = 'or';
|
|
96
|
-
this.arr = filters;
|
|
97
|
-
}
|
|
98
|
-
build() {
|
|
99
|
-
return { or: this.arr.map(filter => filter.build()) };
|
|
100
|
-
}
|
|
101
|
-
}
|
|
102
|
-
exports.NotionOr = NotionOr;
|
|
103
|
-
const Query = (Entity) => {
|
|
104
|
-
const Filter = (_propName, evaluation, value) => {
|
|
105
|
-
var _a;
|
|
106
|
-
const annotation = Entity[decorators_1.NOTION_ANNOTATIONS].find(({ propName }) => propName === _propName);
|
|
107
|
-
// if(!annotation) {
|
|
108
|
-
// throw new Error(`NotionFilter: ${Entity} does not have ${_propName}.`);
|
|
109
|
-
// }
|
|
110
|
-
return new NotionFilter(annotation === null || annotation === void 0 ? void 0 : annotation.type, (_a = annotation === null || annotation === void 0 ? void 0 : annotation.fieldName) !== null && _a !== void 0 ? _a : _propName, evaluation, value);
|
|
111
|
-
};
|
|
112
|
-
const OrderBy = (_propName, direction) => {
|
|
113
|
-
var _a;
|
|
114
|
-
const annotation = Entity[decorators_1.NOTION_ANNOTATIONS].find(({ propName }) => propName === _propName);
|
|
115
|
-
return new NotionSort((_a = annotation === null || annotation === void 0 ? void 0 : annotation.fieldName) !== null && _a !== void 0 ? _a : _propName, direction);
|
|
116
|
-
};
|
|
117
|
-
const And = (...args) => new NotionAnd(...args);
|
|
118
|
-
const Or = (...args) => new NotionOr(...args);
|
|
119
|
-
return { Filter, OrderBy, And, Or };
|
|
120
|
-
};
|
|
121
|
-
exports.Query = Query;
|
|
122
|
-
//# sourceMappingURL=query.js.map
|
package/query/query.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"query.js","sourceRoot":"","sources":["../../../../../packages/@nx-ddd/notion/src/lib/query/query.ts"],"names":[],"mappings":";;;AAAA,8CAAqE;AAKrE,MAAa,CAAC;IACZ,MAAM,CAAC,eAAe,CAAC,QAAgB,EAAE,UAAsB,EAAE,KAAsB;QACrF,OAAO,EAAE,QAAQ,EAAE,MAAM,EAAE,EAAE,KAAK,EAAE,EAAE,SAAS,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE,EAAE,EAAE,EAAE,CAAC;IAC3E,CAAC;IAED,MAAM,CAAC,YAAY,CAAC,QAAgB,EAAE,UAAsB,EAAE,KAAsB;QAClF,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,EAAE,EAAC,CAAC;IAClC,CAAC;IAED,MAAM,CAAC,cAAc,CAAC,QAAgB,EAAE,UAAsB,EAAE,KAAsB;QACpF,MAAM,KAAK,GAAG,UAAU,KAAK,GAAG,CAAC,CAAC,CAAC,OAAO;YACxC,CAAC,CAAC,UAAU,KAAK,GAAG,CAAC,CAAC,CAAC,QAAQ;gBAC/B,CAAC,CAAC,UAAU,KAAK,IAAI,CAAC,CAAC,CAAC,QAAQ;oBAChC,CAAC,CAAC,UAAU,KAAK,IAAI,CAAC,CAAC,CAAC,cAAc;wBACtC,CAAC,CAAC,UAAU,KAAK,IAAI,CAAC,CAAC,CAAC,aAAa;4BACrC,CAAC,CAAC,UAAU,KAAK,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;QAClC,OAAO,EAAE,SAAS,EAAE,kBAAkB,EAAE,gBAAgB,EAAE,EAAC,CAAC,KAAK,CAAC,EAAE,KAAK,EAAC,EAAE,CAAC;IAC/E,CAAC;IAED,MAAM,CAAC,SAAS,CAAC,QAAgB,EAAE,UAA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AAI,YAAY,CAAC,UAAU,aAAV,UAAU,uBAAV,UAAU,CAAE,IAAI,EAAE,MAAA,UAAU,aAAV,UAAU,uBAAV,UAAU,CAAE,SAAS,mCAAI,SAAS,EAAE,UAAU,EAAE,KAAK,CAAC,CAAC;IACnG,CAAC,CAAC;IACF,MAAM,OAAO,GAAG,CAAC,SAAiB,EAAE,SAAyB,EAAc,EAAE;;QAC3E,MAAM,UAAU,GAAqB,MAAM,CAAC,+BAAkB,CAAC,CAAC,IAAI,CAAC,CAAC,EAAC,QAAQ,EAAC,EAAE,EAAE,CAAC,QAAQ,KAAK,SAAS,CAAC,CAAC;QAC7G,OAAO,IAAI,UAAU,CAAC,MAAA,UAAU,aAAV,UAAU,uBAAV,UAAU,CAAE,SAAS,mCAAI,SAAS,EAAE,SAAS,CAAC,CAAC;IACvE,CAAC,CAAC;IAEF,MAAM,GAAG,GAAG,CAAC,GAAG,IAAoB,EAAa,EAAE,CAAC,IAAI,SAAS,CAAC,GAAG,IAAI,CAAC,CAAC;IAC3E,MAAM,EAAE,GAAG,CAAC,GAAG,IAAoB,EAAY,EAAE,CAAC,IAAI,QAAQ,CAAC,GAAG,IAAI,CAAC,CAAC;IAExE,OAAO,EAAC,MAAM,EAAE,OAAO,EAAE,GAAG,EAAE,EAAE,EAAC,CAAC;AACpC,CAAC,CAAA;AAnBY,QAAA,KAAK,SAmBjB"}
|
package/query-builder/index.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './query-builder';
|
package/query-builder/index.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../packages/@nx-ddd/notion/src/lib/query-builder/index.ts"],"names":[],"mappings":";;;AAAA,0DAAgC"}
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
import { NotionBaseQuery } from "../query";
|
|
2
|
-
export declare class NotionQueryBuilder {
|
|
3
|
-
constructor();
|
|
4
|
-
build(filterQuery?: NotionBaseQuery, sortQuery?: NotionBaseQuery): {
|
|
5
|
-
sorts: any[];
|
|
6
|
-
filter: any;
|
|
7
|
-
} | {
|
|
8
|
-
sorts?: undefined;
|
|
9
|
-
filter: any;
|
|
10
|
-
} | {
|
|
11
|
-
sorts: any[];
|
|
12
|
-
filter?: undefined;
|
|
13
|
-
} | {
|
|
14
|
-
sorts?: undefined;
|
|
15
|
-
filter?: undefined;
|
|
16
|
-
};
|
|
17
|
-
protected buildSortQuery(query: NotionBaseQuery): {
|
|
18
|
-
sorts: any[];
|
|
19
|
-
} | {
|
|
20
|
-
sorts?: undefined;
|
|
21
|
-
};
|
|
22
|
-
protected buildFilterQuery(query: NotionBaseQuery): {
|
|
23
|
-
filter: any;
|
|
24
|
-
} | {
|
|
25
|
-
filter?: undefined;
|
|
26
|
-
};
|
|
27
|
-
}
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.NotionQueryBuilder = void 0;
|
|
4
|
-
class NotionQueryBuilder {
|
|
5
|
-
constructor() { }
|
|
6
|
-
build(filterQuery, sortQuery) {
|
|
7
|
-
return Object.assign(Object.assign({}, (filterQuery ? this.buildFilterQuery(filterQuery) : {})), (sortQuery ? this.buildSortQuery(sortQuery) : {}));
|
|
8
|
-
}
|
|
9
|
-
buildSortQuery(query) {
|
|
10
|
-
if (query.type === 'sort') {
|
|
11
|
-
return { sorts: [query.build()] };
|
|
12
|
-
}
|
|
13
|
-
else {
|
|
14
|
-
return {};
|
|
15
|
-
}
|
|
16
|
-
}
|
|
17
|
-
buildFilterQuery(query) {
|
|
18
|
-
if (query.type === 'filter') {
|
|
19
|
-
return { filter: { and: [query.build()] } };
|
|
20
|
-
}
|
|
21
|
-
else if (['and', 'or'].includes(query.type)) {
|
|
22
|
-
return { filter: query.build() };
|
|
23
|
-
}
|
|
24
|
-
else {
|
|
25
|
-
return {};
|
|
26
|
-
}
|
|
27
|
-
}
|
|
28
|
-
}
|
|
29
|
-
exports.NotionQueryBuilder = NotionQueryBuilder;
|
|
30
|
-
//# sourceMappingURL=query-builder.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"query-builder.js","sourceRoot":"","sources":["../../../../../packages/@nx-ddd/notion/src/lib/query-builder/query-builder.ts"],"names":[],"mappings":";;;AAEA,MAAa,kBAAkB;IAC7B,gBAAgB,CAAC;IAEjB,KAAK,CAAC,WAA6B,EAAE,SAA2B;QAC9D,uCACK,CAAC,WAAW,CAAC,CAAC,CAAC,IAAI,CAAC,gBAAgB,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,GACvD,CAAC,SAAS,CAAC,CAAC,CAAC,IAAI,CAAC,cAAc,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,EACrD;IACH,CAAC;IAES,cAAc,CAAC,KAAsB;QAC7C,IAAI,KAAK,CAAC,IAAI,KAAK,MAAM,EAAE,CAAC;YAC1B,OAAO,EAAE,KAAK,EAAE,CAAC,KAAK,CAAC,KAAK,EAAE,CAAC,EAAC,CAAC;QACnC,CAAC;aAAM,CAAC;YACN,OAAO,EAAE,CAAC;QACZ,CAAC;IACH,CAAC;IAES,gBAAgB,CAAC,KAAsB;QAC/C,IAAI,KAAK,CAAC,IAAI,KAAK,QAAQ,EAAE,CAAC;YAC5B,OAAO,EAAE,MAAM,EAAE,EAAE,GAAG,EAAE,CAAC,KAAK,CAAC,KAAK,EAAE,CAAC,EAAE,EAAE,CAAC;QAC9C,CAAC;aAAM,IAAI,CAAC,KAAK,EAAE,IAAI,CAAC,CAAC,QAAQ,CAAC,KAAK,CAAC,IAAI,CAAC,EAAE,CAAC;YAC9C,OAAO,EAAE,MAAM,EAAE,KAAK,CAAC,KAAK,EAAE,EAAE,CAAC;QACnC,CAAC;aAAM,CAAC;YACN,OAAO,EAAE,CAAC;QACZ,CAAC;IACH,CAAC;CACF;AA3BD,gDA2BC"}
|
package/repository/index.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './repository';
|
package/repository/index.js
DELETED
package/repository/index.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../packages/@nx-ddd/notion/src/lib/repository/index.ts"],"names":[],"mappings":";;;AAAA,uDAA6B"}
|
|
@@ -1,48 +0,0 @@
|
|
|
1
|
-
import { Client } from '@notionhq/client';
|
|
2
|
-
import { Entity } from '@nx-ddd/common/domain/models';
|
|
3
|
-
import { Repository } from '@nx-ddd/common/domain/repository';
|
|
4
|
-
import { InjectionToken } from '@angular/core';
|
|
5
|
-
import { NotionConverter } from '../converter';
|
|
6
|
-
import { NotionBaseQuery } from '../query';
|
|
7
|
-
import { NotionQueryBuilder } from '../query-builder';
|
|
8
|
-
export declare const NOTION_ACCESS_TOKEN: InjectionToken<string>;
|
|
9
|
-
export declare const NOTION_DATABASE_ID: InjectionToken<unknown>;
|
|
10
|
-
export declare function provideNotionConfig(config: {
|
|
11
|
-
accessToken: string;
|
|
12
|
-
}): {
|
|
13
|
-
provide: InjectionToken<string>;
|
|
14
|
-
useValue: string;
|
|
15
|
-
};
|
|
16
|
-
export declare abstract class NotionRepository<E extends Entity> extends Repository<E> {
|
|
17
|
-
protected token: string;
|
|
18
|
-
protected abstract databaseId: string;
|
|
19
|
-
protected abstract converter: NotionConverter<E>;
|
|
20
|
-
protected client: Client;
|
|
21
|
-
protected queryBuilder: NotionQueryBuilder;
|
|
22
|
-
protected get parent(): {
|
|
23
|
-
type: 'database_id';
|
|
24
|
-
database_id: string;
|
|
25
|
-
};
|
|
26
|
-
constructor(token: string);
|
|
27
|
-
query(filterQuery?: NotionBaseQuery, sortQuery?: NotionBaseQuery, startCursor?: string, pageSize?: number): Promise<{
|
|
28
|
-
results: E[];
|
|
29
|
-
nextCursor: string;
|
|
30
|
-
hasMore: boolean;
|
|
31
|
-
}>;
|
|
32
|
-
queryV2(args?: any): Promise<{
|
|
33
|
-
results: E[];
|
|
34
|
-
nextCursor: string;
|
|
35
|
-
hasMore: boolean;
|
|
36
|
-
}>;
|
|
37
|
-
list({ batchSize, }?: {
|
|
38
|
-
batchSize?: number;
|
|
39
|
-
}): Promise<E[]>;
|
|
40
|
-
get({ id }: {
|
|
41
|
-
id: string;
|
|
42
|
-
}): Promise<E>;
|
|
43
|
-
create(entity: Partial<E>): Promise<E>;
|
|
44
|
-
update(entity: Partial<E>): Promise<void>;
|
|
45
|
-
delete({ id }: {
|
|
46
|
-
id: string;
|
|
47
|
-
}): Promise<void>;
|
|
48
|
-
}
|
package/repository/repository.js
DELETED
|
@@ -1,112 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.NotionRepository = exports.NOTION_DATABASE_ID = exports.NOTION_ACCESS_TOKEN = void 0;
|
|
4
|
-
exports.provideNotionConfig = provideNotionConfig;
|
|
5
|
-
const tslib_1 = require("tslib");
|
|
6
|
-
const client_1 = require("@notionhq/client");
|
|
7
|
-
const repository_1 = require("@nx-ddd/common/domain/repository");
|
|
8
|
-
const core_1 = require("@angular/core");
|
|
9
|
-
const query_builder_1 = require("../query-builder");
|
|
10
|
-
exports.NOTION_ACCESS_TOKEN = new core_1.InjectionToken('[@nx-ddd/notion] Notion Access Token');
|
|
11
|
-
exports.NOTION_DATABASE_ID = new core_1.InjectionToken('[@nx-ddd/notion] Notion Database Id');
|
|
12
|
-
function provideNotionConfig(config) {
|
|
13
|
-
return { provide: exports.NOTION_ACCESS_TOKEN, useValue: config.accessToken };
|
|
14
|
-
}
|
|
15
|
-
let NotionRepository = class NotionRepository extends repository_1.Repository {
|
|
16
|
-
get parent() {
|
|
17
|
-
return { type: 'database_id', database_id: this.databaseId };
|
|
18
|
-
}
|
|
19
|
-
constructor(token) {
|
|
20
|
-
super();
|
|
21
|
-
this.token = token;
|
|
22
|
-
this.client = new client_1.Client({ auth: this.token });
|
|
23
|
-
this.queryBuilder = new query_builder_1.NotionQueryBuilder();
|
|
24
|
-
}
|
|
25
|
-
query(filterQuery, sortQuery, startCursor, pageSize) {
|
|
26
|
-
return tslib_1.__awaiter(this, void 0, void 0, function* () {
|
|
27
|
-
try {
|
|
28
|
-
const obj = this.queryBuilder.build(filterQuery, sortQuery);
|
|
29
|
-
const res = yield this.client.databases.query(Object.assign(Object.assign({ database_id: this.databaseId }, obj), { start_cursor: startCursor, page_size: pageSize }));
|
|
30
|
-
return {
|
|
31
|
-
results: res.results.map(result => this.converter.fromNotion(result)),
|
|
32
|
-
nextCursor: res.next_cursor,
|
|
33
|
-
hasMore: res.has_more,
|
|
34
|
-
};
|
|
35
|
-
}
|
|
36
|
-
catch (error) {
|
|
37
|
-
throw error;
|
|
38
|
-
}
|
|
39
|
-
});
|
|
40
|
-
}
|
|
41
|
-
queryV2(args) {
|
|
42
|
-
return tslib_1.__awaiter(this, void 0, void 0, function* () {
|
|
43
|
-
try {
|
|
44
|
-
const res = yield this.client.databases.query(Object.assign({ database_id: this.databaseId }, (args !== null && args !== void 0 ? args : {})));
|
|
45
|
-
return {
|
|
46
|
-
results: res.results.map(result => this.converter.fromNotion(result)),
|
|
47
|
-
nextCursor: res.next_cursor,
|
|
48
|
-
hasMore: res.has_more,
|
|
49
|
-
};
|
|
50
|
-
}
|
|
51
|
-
catch (error) {
|
|
52
|
-
throw error;
|
|
53
|
-
}
|
|
54
|
-
});
|
|
55
|
-
}
|
|
56
|
-
list() {
|
|
57
|
-
return tslib_1.__awaiter(this, arguments, void 0, function* ({ batchSize = 100, } = {}) {
|
|
58
|
-
const orders = [];
|
|
59
|
-
let nextCursor;
|
|
60
|
-
while (true) {
|
|
61
|
-
const res = yield this.query(undefined, undefined, nextCursor, batchSize);
|
|
62
|
-
console.debug(res.nextCursor);
|
|
63
|
-
orders.push(...res.results);
|
|
64
|
-
nextCursor = res.nextCursor;
|
|
65
|
-
if (!res.hasMore)
|
|
66
|
-
break;
|
|
67
|
-
}
|
|
68
|
-
return orders;
|
|
69
|
-
});
|
|
70
|
-
}
|
|
71
|
-
get(_a) {
|
|
72
|
-
return tslib_1.__awaiter(this, arguments, void 0, function* ({ id }) {
|
|
73
|
-
const data = yield this.client.pages.retrieve({ page_id: id });
|
|
74
|
-
return this.converter.fromNotion(data);
|
|
75
|
-
});
|
|
76
|
-
}
|
|
77
|
-
create(entity) {
|
|
78
|
-
return tslib_1.__awaiter(this, void 0, void 0, function* () {
|
|
79
|
-
try {
|
|
80
|
-
const res = yield this.client.pages.create({
|
|
81
|
-
parent: this.parent,
|
|
82
|
-
properties: Object.assign({}, this.converter.toNotion(entity)),
|
|
83
|
-
});
|
|
84
|
-
return this.converter.fromNotion(res);
|
|
85
|
-
}
|
|
86
|
-
catch (error) {
|
|
87
|
-
throw error;
|
|
88
|
-
}
|
|
89
|
-
});
|
|
90
|
-
}
|
|
91
|
-
update(entity) {
|
|
92
|
-
return tslib_1.__awaiter(this, void 0, void 0, function* () {
|
|
93
|
-
const data = {
|
|
94
|
-
page_id: entity.id,
|
|
95
|
-
properties: Object.assign({}, this.converter.toNotion(entity)),
|
|
96
|
-
};
|
|
97
|
-
yield this.client.pages.update(data);
|
|
98
|
-
});
|
|
99
|
-
}
|
|
100
|
-
delete(_a) {
|
|
101
|
-
return tslib_1.__awaiter(this, arguments, void 0, function* ({ id }) {
|
|
102
|
-
throw new Error('NotionRepository.delete() is not implemented');
|
|
103
|
-
});
|
|
104
|
-
}
|
|
105
|
-
};
|
|
106
|
-
exports.NotionRepository = NotionRepository;
|
|
107
|
-
exports.NotionRepository = NotionRepository = tslib_1.__decorate([
|
|
108
|
-
(0, core_1.Injectable)(),
|
|
109
|
-
tslib_1.__param(0, (0, core_1.Inject)(exports.NOTION_ACCESS_TOKEN)),
|
|
110
|
-
tslib_1.__metadata("design:paramtypes", [String])
|
|
111
|
-
], NotionRepository);
|
|
112
|
-
//# sourceMappingURL=repository.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-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