@sprucelabs/spruce-core-schemas 33.1.9 → 34.0.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/build/.spruce/schemas/core.schemas.types.d.ts +3 -3
- package/build/.spruce/schemas/spruce/v2020_07_22/role.schema.js +2 -2
- package/build/constants.d.ts +37 -5
- package/build/constants.js +12 -5
- package/build/esm/.spruce/schemas/core.schemas.types.d.ts +3 -3
- package/build/esm/.spruce/schemas/spruce/v2020_07_22/role.schema.js +2 -2
- package/build/esm/constants.d.ts +37 -5
- package/build/esm/constants.js +11 -4
- package/build/esm/schemas/v2020_07_22/role.builder.js +3 -3
- package/build/schemas/v2020_07_22/role.builder.js +2 -2
- package/package.json +1 -1
|
@@ -129,7 +129,7 @@ export declare namespace SpruceSchemas.Spruce.v2020_07_22 {
|
|
|
129
129
|
'id': string;
|
|
130
130
|
/** Name. */
|
|
131
131
|
'name': string;
|
|
132
|
-
/** Base.
|
|
132
|
+
/** Base. A best practices starting point for a role based on the generalized roles at a company. */
|
|
133
133
|
'base'?: ("owner" | "groupManager" | "manager" | "teammate" | "anonymous" | "loggedIn" | "guest") | undefined | null;
|
|
134
134
|
/** Description. */
|
|
135
135
|
'description'?: string | undefined | null;
|
|
@@ -161,11 +161,11 @@ export declare namespace SpruceSchemas.Spruce.v2020_07_22 {
|
|
|
161
161
|
isRequired: true;
|
|
162
162
|
options: undefined;
|
|
163
163
|
};
|
|
164
|
-
/** Base.
|
|
164
|
+
/** Base. A best practices starting point for a role based on the generalized roles at a company. */
|
|
165
165
|
'base': {
|
|
166
166
|
label: 'Base';
|
|
167
167
|
type: 'select';
|
|
168
|
-
hint: '
|
|
168
|
+
hint: 'A best practices starting point for a role based on the generalized roles at a company.';
|
|
169
169
|
options: {
|
|
170
170
|
choices: [{
|
|
171
171
|
"label": "Owner";
|
|
@@ -23,11 +23,11 @@ const roleSchema = {
|
|
|
23
23
|
isRequired: true,
|
|
24
24
|
options: undefined
|
|
25
25
|
},
|
|
26
|
-
/** Base.
|
|
26
|
+
/** Base. A best practices starting point for a role based on the generalized roles at a company. */
|
|
27
27
|
'base': {
|
|
28
28
|
label: 'Base',
|
|
29
29
|
type: 'select',
|
|
30
|
-
hint: '
|
|
30
|
+
hint: 'A best practices starting point for a role based on the generalized roles at a company.',
|
|
31
31
|
options: { choices: [{ "label": "Owner", "value": "owner" }, { "label": "Group manager", "value": "groupManager" }, { "label": "Manager", "value": "manager" }, { "label": "Teammate", "value": "teammate" }, { "label": "Anonymous", "value": "anonymous" }, { "label": "Logged in", "value": "loggedIn" }, { "label": "Guest", "value": "guest" }], }
|
|
32
32
|
},
|
|
33
33
|
/** Description. */
|
package/build/constants.d.ts
CHANGED
|
@@ -37,13 +37,29 @@ export declare const BASE_ROLES: readonly [{
|
|
|
37
37
|
}, {
|
|
38
38
|
readonly name: "Guest";
|
|
39
39
|
readonly slug: "guest";
|
|
40
|
-
}
|
|
40
|
+
}];
|
|
41
|
+
export declare const BASE_ROLES_WITH_META: ({
|
|
42
|
+
readonly name: "Owner";
|
|
43
|
+
readonly slug: "owner";
|
|
44
|
+
} | {
|
|
45
|
+
readonly name: "Group manager";
|
|
46
|
+
readonly slug: "groupManager";
|
|
47
|
+
} | {
|
|
48
|
+
readonly name: "Manager";
|
|
49
|
+
readonly slug: "manager";
|
|
50
|
+
} | {
|
|
51
|
+
readonly name: "Teammate";
|
|
52
|
+
readonly slug: "teammate";
|
|
53
|
+
} | {
|
|
54
|
+
readonly name: "Guest";
|
|
55
|
+
readonly slug: "guest";
|
|
56
|
+
} | {
|
|
41
57
|
readonly name: "Anonymous";
|
|
42
58
|
readonly slug: "anonymous";
|
|
43
|
-
}
|
|
59
|
+
} | {
|
|
44
60
|
readonly name: "Logged in";
|
|
45
61
|
readonly slug: "loggedIn";
|
|
46
|
-
}];
|
|
62
|
+
})[];
|
|
47
63
|
export declare const EMPLOYED_BASE_ROLE_CHOICES: readonly [{
|
|
48
64
|
readonly label: "Owner";
|
|
49
65
|
readonly value: "owner";
|
|
@@ -57,7 +73,7 @@ export declare const EMPLOYED_BASE_ROLE_CHOICES: readonly [{
|
|
|
57
73
|
readonly label: "Teammate";
|
|
58
74
|
readonly value: "teammate";
|
|
59
75
|
}];
|
|
60
|
-
export declare const
|
|
76
|
+
export declare const GUEST_BASE_ROLE_CHOICES: readonly [{
|
|
61
77
|
readonly label: "Guest";
|
|
62
78
|
readonly value: "guest";
|
|
63
79
|
}];
|
|
@@ -68,7 +84,23 @@ export declare const META_BASE_ROLE_CHOICES: readonly [{
|
|
|
68
84
|
readonly label: "Logged in";
|
|
69
85
|
readonly value: "loggedIn";
|
|
70
86
|
}];
|
|
71
|
-
export declare const
|
|
87
|
+
export declare const BASE_ROLE_CHOICES: readonly [{
|
|
88
|
+
readonly label: "Owner";
|
|
89
|
+
readonly value: "owner";
|
|
90
|
+
}, {
|
|
91
|
+
readonly label: "Group manager";
|
|
92
|
+
readonly value: "groupManager";
|
|
93
|
+
}, {
|
|
94
|
+
readonly label: "Manager";
|
|
95
|
+
readonly value: "manager";
|
|
96
|
+
}, {
|
|
97
|
+
readonly label: "Teammate";
|
|
98
|
+
readonly value: "teammate";
|
|
99
|
+
}, {
|
|
100
|
+
readonly label: "Guest";
|
|
101
|
+
readonly value: "guest";
|
|
102
|
+
}];
|
|
103
|
+
export declare const BASE_ROLE_CHOICES_WITH_META: readonly [{
|
|
72
104
|
readonly label: "Owner";
|
|
73
105
|
readonly value: "owner";
|
|
74
106
|
}, {
|
package/build/constants.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
3
|
+
exports.BASE_ROLE_CHOICES_WITH_META = exports.BASE_ROLE_CHOICES = exports.META_BASE_ROLE_CHOICES = exports.GUEST_BASE_ROLE_CHOICES = exports.EMPLOYED_BASE_ROLE_CHOICES = exports.BASE_ROLES_WITH_META = exports.BASE_ROLES = exports.META_BASE_ROLES = exports.GUEST_BASE_ROLES = exports.EMPLOYED_BASE_ROLES = void 0;
|
|
4
4
|
exports.EMPLOYED_BASE_ROLES = [
|
|
5
5
|
{ name: 'Owner', slug: 'owner' },
|
|
6
6
|
{ name: 'Group manager', slug: 'groupManager' },
|
|
@@ -12,7 +12,8 @@ exports.META_BASE_ROLES = [
|
|
|
12
12
|
{ name: 'Anonymous', slug: 'anonymous' },
|
|
13
13
|
{ name: 'Logged in', slug: 'loggedIn' },
|
|
14
14
|
];
|
|
15
|
-
exports.BASE_ROLES = [
|
|
15
|
+
exports.BASE_ROLES = [...exports.EMPLOYED_BASE_ROLES, ...exports.GUEST_BASE_ROLES];
|
|
16
|
+
exports.BASE_ROLES_WITH_META = [
|
|
16
17
|
...exports.EMPLOYED_BASE_ROLES,
|
|
17
18
|
...exports.GUEST_BASE_ROLES,
|
|
18
19
|
...exports.META_BASE_ROLES,
|
|
@@ -23,13 +24,19 @@ exports.EMPLOYED_BASE_ROLE_CHOICES = [
|
|
|
23
24
|
{ label: 'Manager', value: 'manager' },
|
|
24
25
|
{ label: 'Teammate', value: 'teammate' },
|
|
25
26
|
];
|
|
26
|
-
exports.
|
|
27
|
+
exports.GUEST_BASE_ROLE_CHOICES = [
|
|
28
|
+
{ label: 'Guest', value: 'guest' },
|
|
29
|
+
];
|
|
27
30
|
exports.META_BASE_ROLE_CHOICES = [
|
|
28
31
|
{ label: 'Anonymous', value: 'anonymous' },
|
|
29
32
|
{ label: 'Logged in', value: 'loggedIn' },
|
|
30
33
|
];
|
|
31
|
-
exports.
|
|
34
|
+
exports.BASE_ROLE_CHOICES = [
|
|
35
|
+
...exports.EMPLOYED_BASE_ROLE_CHOICES,
|
|
36
|
+
...exports.GUEST_BASE_ROLE_CHOICES,
|
|
37
|
+
];
|
|
38
|
+
exports.BASE_ROLE_CHOICES_WITH_META = [
|
|
32
39
|
...exports.EMPLOYED_BASE_ROLE_CHOICES,
|
|
33
40
|
...exports.META_BASE_ROLE_CHOICES,
|
|
34
|
-
...exports.
|
|
41
|
+
...exports.GUEST_BASE_ROLE_CHOICES,
|
|
35
42
|
];
|
|
@@ -129,7 +129,7 @@ export declare namespace SpruceSchemas.Spruce.v2020_07_22 {
|
|
|
129
129
|
'id': string;
|
|
130
130
|
/** Name. */
|
|
131
131
|
'name': string;
|
|
132
|
-
/** Base.
|
|
132
|
+
/** Base. A best practices starting point for a role based on the generalized roles at a company. */
|
|
133
133
|
'base'?: ("owner" | "groupManager" | "manager" | "teammate" | "anonymous" | "loggedIn" | "guest") | undefined | null;
|
|
134
134
|
/** Description. */
|
|
135
135
|
'description'?: string | undefined | null;
|
|
@@ -161,11 +161,11 @@ export declare namespace SpruceSchemas.Spruce.v2020_07_22 {
|
|
|
161
161
|
isRequired: true;
|
|
162
162
|
options: undefined;
|
|
163
163
|
};
|
|
164
|
-
/** Base.
|
|
164
|
+
/** Base. A best practices starting point for a role based on the generalized roles at a company. */
|
|
165
165
|
'base': {
|
|
166
166
|
label: 'Base';
|
|
167
167
|
type: 'select';
|
|
168
|
-
hint: '
|
|
168
|
+
hint: 'A best practices starting point for a role based on the generalized roles at a company.';
|
|
169
169
|
options: {
|
|
170
170
|
choices: [{
|
|
171
171
|
"label": "Owner";
|
|
@@ -21,11 +21,11 @@ const roleSchema = {
|
|
|
21
21
|
isRequired: true,
|
|
22
22
|
options: undefined
|
|
23
23
|
},
|
|
24
|
-
/** Base.
|
|
24
|
+
/** Base. A best practices starting point for a role based on the generalized roles at a company. */
|
|
25
25
|
'base': {
|
|
26
26
|
label: 'Base',
|
|
27
27
|
type: 'select',
|
|
28
|
-
hint: '
|
|
28
|
+
hint: 'A best practices starting point for a role based on the generalized roles at a company.',
|
|
29
29
|
options: { choices: [{ "label": "Owner", "value": "owner" }, { "label": "Group manager", "value": "groupManager" }, { "label": "Manager", "value": "manager" }, { "label": "Teammate", "value": "teammate" }, { "label": "Anonymous", "value": "anonymous" }, { "label": "Logged in", "value": "loggedIn" }, { "label": "Guest", "value": "guest" }], }
|
|
30
30
|
},
|
|
31
31
|
/** Description. */
|
package/build/esm/constants.d.ts
CHANGED
|
@@ -37,13 +37,29 @@ export declare const BASE_ROLES: readonly [{
|
|
|
37
37
|
}, {
|
|
38
38
|
readonly name: "Guest";
|
|
39
39
|
readonly slug: "guest";
|
|
40
|
-
}
|
|
40
|
+
}];
|
|
41
|
+
export declare const BASE_ROLES_WITH_META: ({
|
|
42
|
+
readonly name: "Owner";
|
|
43
|
+
readonly slug: "owner";
|
|
44
|
+
} | {
|
|
45
|
+
readonly name: "Group manager";
|
|
46
|
+
readonly slug: "groupManager";
|
|
47
|
+
} | {
|
|
48
|
+
readonly name: "Manager";
|
|
49
|
+
readonly slug: "manager";
|
|
50
|
+
} | {
|
|
51
|
+
readonly name: "Teammate";
|
|
52
|
+
readonly slug: "teammate";
|
|
53
|
+
} | {
|
|
54
|
+
readonly name: "Guest";
|
|
55
|
+
readonly slug: "guest";
|
|
56
|
+
} | {
|
|
41
57
|
readonly name: "Anonymous";
|
|
42
58
|
readonly slug: "anonymous";
|
|
43
|
-
}
|
|
59
|
+
} | {
|
|
44
60
|
readonly name: "Logged in";
|
|
45
61
|
readonly slug: "loggedIn";
|
|
46
|
-
}];
|
|
62
|
+
})[];
|
|
47
63
|
export declare const EMPLOYED_BASE_ROLE_CHOICES: readonly [{
|
|
48
64
|
readonly label: "Owner";
|
|
49
65
|
readonly value: "owner";
|
|
@@ -57,7 +73,7 @@ export declare const EMPLOYED_BASE_ROLE_CHOICES: readonly [{
|
|
|
57
73
|
readonly label: "Teammate";
|
|
58
74
|
readonly value: "teammate";
|
|
59
75
|
}];
|
|
60
|
-
export declare const
|
|
76
|
+
export declare const GUEST_BASE_ROLE_CHOICES: readonly [{
|
|
61
77
|
readonly label: "Guest";
|
|
62
78
|
readonly value: "guest";
|
|
63
79
|
}];
|
|
@@ -68,7 +84,23 @@ export declare const META_BASE_ROLE_CHOICES: readonly [{
|
|
|
68
84
|
readonly label: "Logged in";
|
|
69
85
|
readonly value: "loggedIn";
|
|
70
86
|
}];
|
|
71
|
-
export declare const
|
|
87
|
+
export declare const BASE_ROLE_CHOICES: readonly [{
|
|
88
|
+
readonly label: "Owner";
|
|
89
|
+
readonly value: "owner";
|
|
90
|
+
}, {
|
|
91
|
+
readonly label: "Group manager";
|
|
92
|
+
readonly value: "groupManager";
|
|
93
|
+
}, {
|
|
94
|
+
readonly label: "Manager";
|
|
95
|
+
readonly value: "manager";
|
|
96
|
+
}, {
|
|
97
|
+
readonly label: "Teammate";
|
|
98
|
+
readonly value: "teammate";
|
|
99
|
+
}, {
|
|
100
|
+
readonly label: "Guest";
|
|
101
|
+
readonly value: "guest";
|
|
102
|
+
}];
|
|
103
|
+
export declare const BASE_ROLE_CHOICES_WITH_META: readonly [{
|
|
72
104
|
readonly label: "Owner";
|
|
73
105
|
readonly value: "owner";
|
|
74
106
|
}, {
|
package/build/esm/constants.js
CHANGED
|
@@ -9,7 +9,8 @@ export const META_BASE_ROLES = [
|
|
|
9
9
|
{ name: 'Anonymous', slug: 'anonymous' },
|
|
10
10
|
{ name: 'Logged in', slug: 'loggedIn' },
|
|
11
11
|
];
|
|
12
|
-
export const BASE_ROLES = [
|
|
12
|
+
export const BASE_ROLES = [...EMPLOYED_BASE_ROLES, ...GUEST_BASE_ROLES];
|
|
13
|
+
export const BASE_ROLES_WITH_META = [
|
|
13
14
|
...EMPLOYED_BASE_ROLES,
|
|
14
15
|
...GUEST_BASE_ROLES,
|
|
15
16
|
...META_BASE_ROLES,
|
|
@@ -20,13 +21,19 @@ export const EMPLOYED_BASE_ROLE_CHOICES = [
|
|
|
20
21
|
{ label: 'Manager', value: 'manager' },
|
|
21
22
|
{ label: 'Teammate', value: 'teammate' },
|
|
22
23
|
];
|
|
23
|
-
export const
|
|
24
|
+
export const GUEST_BASE_ROLE_CHOICES = [
|
|
25
|
+
{ label: 'Guest', value: 'guest' },
|
|
26
|
+
];
|
|
24
27
|
export const META_BASE_ROLE_CHOICES = [
|
|
25
28
|
{ label: 'Anonymous', value: 'anonymous' },
|
|
26
29
|
{ label: 'Logged in', value: 'loggedIn' },
|
|
27
30
|
];
|
|
28
|
-
export const
|
|
31
|
+
export const BASE_ROLE_CHOICES = [
|
|
32
|
+
...EMPLOYED_BASE_ROLE_CHOICES,
|
|
33
|
+
...GUEST_BASE_ROLE_CHOICES,
|
|
34
|
+
];
|
|
35
|
+
export const BASE_ROLE_CHOICES_WITH_META = [
|
|
29
36
|
...EMPLOYED_BASE_ROLE_CHOICES,
|
|
30
37
|
...META_BASE_ROLE_CHOICES,
|
|
31
|
-
...
|
|
38
|
+
...GUEST_BASE_ROLE_CHOICES,
|
|
32
39
|
];
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { buildSchema } from '@sprucelabs/schema';
|
|
2
|
-
import {
|
|
2
|
+
import { BASE_ROLE_CHOICES_WITH_META } from '../../constants.js';
|
|
3
3
|
export default buildSchema({
|
|
4
4
|
id: 'role',
|
|
5
5
|
name: 'Role',
|
|
@@ -18,9 +18,9 @@ export default buildSchema({
|
|
|
18
18
|
base: {
|
|
19
19
|
label: 'Base',
|
|
20
20
|
type: 'select',
|
|
21
|
-
hint: '
|
|
21
|
+
hint: 'A best practices starting point for a role based on the generalized roles at a company.',
|
|
22
22
|
options: {
|
|
23
|
-
choices:
|
|
23
|
+
choices: BASE_ROLE_CHOICES_WITH_META,
|
|
24
24
|
},
|
|
25
25
|
},
|
|
26
26
|
description: {
|
|
@@ -20,9 +20,9 @@ exports.default = (0, schema_1.buildSchema)({
|
|
|
20
20
|
base: {
|
|
21
21
|
label: 'Base',
|
|
22
22
|
type: 'select',
|
|
23
|
-
hint: '
|
|
23
|
+
hint: 'A best practices starting point for a role based on the generalized roles at a company.',
|
|
24
24
|
options: {
|
|
25
|
-
choices: constants_1.
|
|
25
|
+
choices: constants_1.BASE_ROLE_CHOICES_WITH_META,
|
|
26
26
|
},
|
|
27
27
|
},
|
|
28
28
|
description: {
|