@ttahub/common 1.10.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.
Files changed (3) hide show
  1. package/README.md +17 -0
  2. package/package.json +9 -0
  3. package/src/index.js +232 -0
package/README.md ADDED
@@ -0,0 +1,17 @@
1
+ # @ttahub/common
2
+
3
+ This is a CommonJS package and thus no build step is required. There are no dependencies and thus no installation step is required. These are deliberate choices to simplify usage both locally and in CI.
4
+
5
+ # Usage
6
+
7
+ Whenever changes to this package are made, you will need to:
8
+
9
+ - Bump the version in `package.json`.
10
+ - Run `yarn deps` in the repo root.
11
+
12
+ When the version is bumped, the `yarn install` (called by `yarn deps`) will see that this package's version is more recent than what currently exists in `node_modules`. It should then pull in the latest version to both projects.
13
+
14
+ Note: when running yarn deps the yarn.lock file might get updated to be
15
+ "@ttahub/common@file:./../packages/common":
16
+ in windows it SHOULD be set to
17
+ "@ttahub/common@file:../packages/common":
package/package.json ADDED
@@ -0,0 +1,9 @@
1
+ {
2
+ "name": "@ttahub/common",
3
+ "version": "1.10.0",
4
+ "description": "The purpose of this package is to reduce code duplication between the frontend and backend projects.",
5
+ "main": "src/index.js",
6
+ "author": "",
7
+ "license": "ISC",
8
+ "devDependencies": {}
9
+ }
package/src/index.js ADDED
@@ -0,0 +1,232 @@
1
+ Object.defineProperty(exports, '__esModule', { value: true });
2
+
3
+ const RECIPIENT_PARTICIPANTS = [
4
+ 'CEO / CFO / Executive',
5
+ 'Center Director / Site Director',
6
+ 'Coach',
7
+ 'Direct Service: Other',
8
+ 'Family Service Worker / Case Manager',
9
+ 'Fiscal Manager/Team',
10
+ 'Governing Body / Tribal Council / Policy Council',
11
+ 'Home Visitor',
12
+ 'Manager / Coordinator / Specialist',
13
+ 'Parent / Guardian',
14
+ 'Program Director (HS / EHS)',
15
+ 'Program Support / Administrative Assistant',
16
+ 'Teacher / Infant-Toddler Caregiver',
17
+ 'Volunteer',
18
+ ];
19
+ exports.RECIPIENT_PARTICIPANTS = RECIPIENT_PARTICIPANTS;
20
+
21
+ const OTHER_ENTITY_PARTICIPANTS = [
22
+ 'HSCO',
23
+ 'Local or State Agency',
24
+ 'OCC Regional Office',
25
+ 'OHS Regional Office',
26
+ 'Regional Head Start Association',
27
+ 'Regional TTA Team / Specialists',
28
+ 'State Early Learning System',
29
+ 'State Head Start Association',
30
+ 'Other',
31
+ ];
32
+ exports.OTHER_ENTITY_PARTICIPANTS = OTHER_ENTITY_PARTICIPANTS;
33
+
34
+ const ALL_PARTICIPANTS = [
35
+ ...RECIPIENT_PARTICIPANTS,
36
+ ...OTHER_ENTITY_PARTICIPANTS,
37
+ ];
38
+ exports.ALL_PARTICIPANTS = ALL_PARTICIPANTS;
39
+
40
+ const TOPICS = [
41
+ 'Behavioral / Mental Health / Trauma',
42
+ 'Child Screening and Assessment',
43
+ 'CLASS: Classroom Organization',
44
+ 'CLASS: Emotional Support',
45
+ 'CLASS: Instructional Support',
46
+ 'Coaching',
47
+ 'Communication',
48
+ 'Community and Self-Assessment',
49
+ 'Culture & Language',
50
+ 'Curriculum (Instructional or Parenting)',
51
+ 'Data and Evaluation',
52
+ 'Disabilities Services',
53
+ 'ERSEA',
54
+ 'Environmental Health and Safety / EPRR',
55
+ 'Equity',
56
+ 'Facilities',
57
+ 'Family Support Services',
58
+ 'Fiscal / Budget',
59
+ 'Five-Year Grant',
60
+ 'Home Visiting',
61
+ 'Human Resources',
62
+ 'Leadership / Governance',
63
+ 'Learning Environments',
64
+ 'Nutrition',
65
+ 'Ongoing Monitoring Management System',
66
+ 'Oral Health',
67
+ 'Parent and Family Engagement',
68
+ 'Partnerships and Community Engagement',
69
+ 'Physical Health and Screenings',
70
+ 'Pregnancy Services / Expectant Families',
71
+ 'Program Planning and Services',
72
+ 'Quality Improvement Plan / QIP',
73
+ 'Recordkeeping and Reporting',
74
+ 'Safety Practices',
75
+ 'Staff Wellness',
76
+ 'Teaching / Caregiving Practices',
77
+ 'Technology and Information Systems',
78
+ 'Training and Professional Development',
79
+ 'Transition Practices',
80
+ 'Transportation',
81
+ ];
82
+ exports.TOPICS = TOPICS;
83
+
84
+ const REASONS = [
85
+ 'Below Competitive Threshold (CLASS)',
86
+ 'Below Quality Threshold (CLASS)',
87
+ 'Change in Scope',
88
+ 'Child Incidents',
89
+ 'Complaint',
90
+ 'COVID-19 response',
91
+ 'Full Enrollment',
92
+ 'New Recipient',
93
+ 'New Director or Management',
94
+ 'New Program Option',
95
+ 'New Staff / Turnover',
96
+ 'Ongoing Quality Improvement',
97
+ 'Planning/Coordination (also TTA Plan Agreement)',
98
+ 'School Readiness Goals',
99
+ 'Monitoring | Area of Concern',
100
+ 'Monitoring | Noncompliance',
101
+ 'Monitoring | Deficiency',
102
+ ];
103
+ exports.REASONS = REASONS;
104
+
105
+ const REPORT_STATUSES = {
106
+ DRAFT: 'draft',
107
+ DELETED: 'deleted',
108
+ SUBMITTED: 'submitted',
109
+ APPROVED: 'approved',
110
+ NEEDS_ACTION: 'needs_action',
111
+ };
112
+ exports.REPORT_STATUSES = REPORT_STATUSES;
113
+
114
+ const TRAINING_REPORT_STATUSES = {
115
+ NOT_STARTED: 'not_started',
116
+ IN_PROGRESS: 'in_progress',
117
+ COMPLETE: 'complete',
118
+ };
119
+ exports.TRAINING_REPORT_STATUSES = TRAINING_REPORT_STATUSES;
120
+
121
+ const TARGET_POPULATIONS = [
122
+ 'Infants and Toddlers (ages birth to 3)',
123
+ 'Preschool (ages 3-5)',
124
+ 'Pregnant Women',
125
+ 'Affected by Child Welfare Involvement',
126
+ 'Affected by Disaster',
127
+ 'Affected by Substance Use',
128
+ 'Children Experiencing Homelessness',
129
+ 'Children with Disabilities',
130
+ 'Children with Special Health Care Needs',
131
+ 'Dual-Language Learners',
132
+ ];
133
+ exports.TARGET_POPULATIONS = TARGET_POPULATIONS;
134
+
135
+ const USER_ROLES = [
136
+ 'Central Office',
137
+ 'Other Federal Staff',
138
+ 'National Center',
139
+ 'Regional Program Manager',
140
+ 'COR',
141
+ 'Supervisory Program Specialist',
142
+ 'Program Specialist',
143
+ 'Grants Specialist',
144
+ 'Customer Service Contract',
145
+ 'TTAC',
146
+ 'Admin. Assistant',
147
+ 'Early Childhood Manager',
148
+ 'Early Childhood Specialist',
149
+ 'Family Engagement Specialist',
150
+ 'Grantee Specialist Manager',
151
+ 'Grantee Specialist',
152
+ 'Health Specialist',
153
+ 'System Specialist',
154
+ ];
155
+ exports.USER_ROLES = USER_ROLES;
156
+
157
+ const CLOSE_SUSPEND_REASONS = [
158
+ 'Duplicate goal',
159
+ 'Key staff turnover / vacancies',
160
+ 'Recipient is not responding',
161
+ 'Recipient request',
162
+ 'Regional Office request',
163
+ 'TTA complete',
164
+ ];
165
+
166
+ exports.CLOSE_SUSPEND_REASONS = CLOSE_SUSPEND_REASONS;
167
+
168
+ const GOAL_CLOSE_REASONS = [
169
+ 'Duplicate goal',
170
+ 'Recipient request',
171
+ 'Regional Office request',
172
+ 'TTA complete',
173
+ ];
174
+ exports.GOAL_CLOSE_REASONS = GOAL_CLOSE_REASONS;
175
+
176
+ const GOAL_SUSPEND_REASONS = [
177
+ 'Key staff turnover / vacancies',
178
+ 'Recipient request',
179
+ 'Recipient is not responding',
180
+ 'Regional Office request',
181
+ ];
182
+ exports.GOAL_SUSPEND_REASONS = GOAL_SUSPEND_REASONS;
183
+
184
+ const GOAL_SOURCES = [
185
+ 'Federal monitoring issues, including CLASS and RANs',
186
+ 'RTTAPA development',
187
+ 'Recipient request',
188
+ 'Regional office priority',
189
+ 'Training event follow-up',
190
+ ];
191
+
192
+ exports.GOAL_SOURCES = GOAL_SOURCES;
193
+
194
+ const APPROVER_STATUSES = {
195
+ APPROVED: 'approved',
196
+ NEEDS_ACTION: 'needs_action',
197
+ };
198
+ exports.APPROVER_STATUSES = APPROVER_STATUSES;
199
+
200
+ const SCOPE_IDS = {
201
+ SITE_ACCESS: 1,
202
+ ADMIN: 2,
203
+ READ_WRITE_ACTIVITY_REPORTS: 3,
204
+ READ_ACTIVITY_REPORTS: 4,
205
+ APPROVE_ACTIVITY_REPORTS: 5,
206
+ UNLOCK_APPROVED_REPORTS: 6,
207
+ READ_WRITE_TRAINING_REPORTS: 7,
208
+ READ_TRAINING_REPORTS: 8,
209
+ };
210
+ exports.SCOPE_IDS = SCOPE_IDS;
211
+
212
+ const DECIMAL_BASE = 10;
213
+ exports.DECIMAL_BASE = DECIMAL_BASE;
214
+
215
+ const ALERT_STATUSES = {
216
+ UNPUBLISHED: 'Unpublished',
217
+ PUBLISHED: 'Published'
218
+ };
219
+ exports.ALERT_STATUSES = ALERT_STATUSES;
220
+
221
+ const ALERT_VARIANTS = {
222
+ INFO: 'info',
223
+ EMERGENCY: 'emergency'
224
+ };
225
+ exports.ALERT_VARIANTS = ALERT_VARIANTS;
226
+
227
+ const ALERT_SIZES = {
228
+ STANDARD: 'standard',
229
+ SLIM: 'slim',
230
+ LARGE: 'large'
231
+ };
232
+ exports.ALERT_SIZES = ALERT_SIZES;