@aneuhold/core-ts-db-lib 1.0.85 → 1.0.87
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.
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
3
|
+
exports.getDefaultTaskListFilterSettings = getDefaultTaskListFilterSettings;
|
|
4
|
+
exports.validateFilterSettings = validateFilterSettings;
|
|
4
5
|
function getDefaultTaskListFilterSettings(userId) {
|
|
5
6
|
return {
|
|
6
7
|
userId,
|
|
@@ -10,7 +11,6 @@ function getDefaultTaskListFilterSettings(userId) {
|
|
|
10
11
|
tags: {}
|
|
11
12
|
};
|
|
12
13
|
}
|
|
13
|
-
exports.getDefaultTaskListFilterSettings = getDefaultTaskListFilterSettings;
|
|
14
14
|
function validateFilterSettings(validate, config) {
|
|
15
15
|
validate.object('taskListFilterSettings', {});
|
|
16
16
|
const categories = Object.keys(config.taskListFilterSettings);
|
|
@@ -28,4 +28,3 @@ function validateFilterSettings(validate, config) {
|
|
|
28
28
|
});
|
|
29
29
|
}
|
|
30
30
|
}
|
|
31
|
-
exports.validateFilterSettings = validateFilterSettings;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.RecurrenceEffect = exports.RecurrenceBasis = exports.RecurrenceFrequencyType =
|
|
3
|
+
exports.RecurrenceEffect = exports.RecurrenceBasis = exports.RecurrenceFrequencyType = void 0;
|
|
4
|
+
exports.validateRecurrenceInfo = validateRecurrenceInfo;
|
|
4
5
|
function validateRecurrenceInfo(task, errors) {
|
|
5
6
|
const recurrenceErrors = [];
|
|
6
7
|
if (!task.recurrenceInfo) {
|
|
@@ -22,7 +23,6 @@ function validateRecurrenceInfo(task, errors) {
|
|
|
22
23
|
}
|
|
23
24
|
errors.push(...recurrenceErrors);
|
|
24
25
|
}
|
|
25
|
-
exports.validateRecurrenceInfo = validateRecurrenceInfo;
|
|
26
26
|
var RecurrenceFrequencyType;
|
|
27
27
|
(function (RecurrenceFrequencyType) {
|
|
28
28
|
RecurrenceFrequencyType["everyXTimeUnit"] = "everyXTimeUnit";
|
|
@@ -1,13 +1,14 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.DashboardTaskSortDirection = exports.DashboardTaskSortBy =
|
|
3
|
+
exports.DashboardTaskSortDirection = exports.DashboardTaskSortBy = void 0;
|
|
4
|
+
exports.getDefaultTaskListSortSettings = getDefaultTaskListSortSettings;
|
|
5
|
+
exports.validateSortSettings = validateSortSettings;
|
|
4
6
|
function getDefaultTaskListSortSettings(userId) {
|
|
5
7
|
return {
|
|
6
8
|
userId,
|
|
7
9
|
sortList: []
|
|
8
10
|
};
|
|
9
11
|
}
|
|
10
|
-
exports.getDefaultTaskListSortSettings = getDefaultTaskListSortSettings;
|
|
11
12
|
function validateSortSettings(validate, config) {
|
|
12
13
|
validate.object('taskListSortSettings', {});
|
|
13
14
|
const categories = Object.keys(config.taskListSortSettings);
|
|
@@ -19,7 +20,6 @@ function validateSortSettings(validate, config) {
|
|
|
19
20
|
});
|
|
20
21
|
}
|
|
21
22
|
}
|
|
22
|
-
exports.validateSortSettings = validateSortSettings;
|
|
23
23
|
/**
|
|
24
24
|
* The sortBy options for a task list.
|
|
25
25
|
*/
|
|
@@ -1,23 +1,22 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
3
|
+
exports.isOptionalObject = isOptionalObject;
|
|
4
|
+
exports.isOptionalArray = isOptionalArray;
|
|
5
|
+
exports.isOptionalString = isOptionalString;
|
|
6
|
+
exports.isOptionalNumber = isOptionalNumber;
|
|
7
|
+
exports.isOptionalBoolean = isOptionalBoolean;
|
|
4
8
|
function isOptionalObject(value) {
|
|
5
9
|
return (value === undefined || (typeof value === 'object' && !Array.isArray(value)));
|
|
6
10
|
}
|
|
7
|
-
exports.isOptionalObject = isOptionalObject;
|
|
8
11
|
function isOptionalArray(value) {
|
|
9
12
|
return value === undefined || value === null || Array.isArray(value);
|
|
10
13
|
}
|
|
11
|
-
exports.isOptionalArray = isOptionalArray;
|
|
12
14
|
function isOptionalString(value) {
|
|
13
15
|
return value === undefined || value === null || typeof value === 'string';
|
|
14
16
|
}
|
|
15
|
-
exports.isOptionalString = isOptionalString;
|
|
16
17
|
function isOptionalNumber(value) {
|
|
17
18
|
return value === undefined || value === null || typeof value === 'number';
|
|
18
19
|
}
|
|
19
|
-
exports.isOptionalNumber = isOptionalNumber;
|
|
20
20
|
function isOptionalBoolean(value) {
|
|
21
21
|
return value === undefined || value === null || typeof value === 'boolean';
|
|
22
22
|
}
|
|
23
|
-
exports.isOptionalBoolean = isOptionalBoolean;
|
package/package.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aneuhold/core-ts-db-lib",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.87",
|
|
4
4
|
"description": "A core database library used for personal projects",
|
|
5
5
|
"main": "lib/index.js",
|
|
6
6
|
"types": "lib/index.d.ts",
|
|
7
7
|
"author": "Anton G Neuhold Jr <agneuhold@gmail.com>",
|
|
8
8
|
"license": "MIT",
|
|
9
|
-
"packageManager": "yarn@4.
|
|
9
|
+
"packageManager": "yarn@4.3.1",
|
|
10
10
|
"repository": {
|
|
11
11
|
"type": "git",
|
|
12
12
|
"url": "git+https://github.com/aneuhold/core-ts-db-lib.git"
|
|
@@ -36,19 +36,19 @@
|
|
|
36
36
|
"lint": "eslint"
|
|
37
37
|
},
|
|
38
38
|
"dependencies": {
|
|
39
|
-
"@aneuhold/core-ts-lib": "^1.1.
|
|
39
|
+
"@aneuhold/core-ts-lib": "^1.1.28",
|
|
40
40
|
"bson": "^6.2.0"
|
|
41
41
|
},
|
|
42
42
|
"devDependencies": {
|
|
43
|
-
"@aneuhold/eslint-config": "^1.0.
|
|
43
|
+
"@aneuhold/eslint-config": "^1.0.17",
|
|
44
44
|
"@types/jest": "^29.5.12",
|
|
45
|
-
"@types/node": "^20.14.
|
|
45
|
+
"@types/node": "^20.14.9",
|
|
46
46
|
"@types/node-fetch": "^2.6.11",
|
|
47
47
|
"eslint": "^9.5.0",
|
|
48
48
|
"jest": "^29.7.0",
|
|
49
49
|
"prettier": "^3.3.2",
|
|
50
|
-
"ts-jest": "^29.1.
|
|
50
|
+
"ts-jest": "^29.1.5",
|
|
51
51
|
"ts-node": "^10.9.2",
|
|
52
|
-
"typescript": "^5.
|
|
52
|
+
"typescript": "^5.5.2"
|
|
53
53
|
}
|
|
54
54
|
}
|