triangle-types 1.0.270 → 1.0.272

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 (109) hide show
  1. package/dist/src/index.d.ts +6 -4
  2. package/dist/src/index.js +6 -4
  3. package/dist/src/types/ballotpedia/BallotpediaOffice.d.ts +1 -1
  4. package/dist/src/types/ballotpedia/BallotpediaOffice.js +1 -1
  5. package/dist/src/types/federal_census/FederalCensusBlock.d.ts +1 -1
  6. package/dist/src/types/federal_census/FederalCensusBlock.js +1 -1
  7. package/dist/src/types/federal_census/FederalCensusCounty.d.ts +1 -1
  8. package/dist/src/types/federal_census/FederalCensusCounty.js +1 -1
  9. package/dist/src/types/federal_census/FederalCensusMunicipality.d.ts +1 -1
  10. package/dist/src/types/federal_census/FederalCensusMunicipality.js +1 -1
  11. package/dist/src/types/federal_census/FederalCensusSchoolDistrict.d.ts +1 -1
  12. package/dist/src/types/federal_census/FederalCensusSchoolDistrict.js +1 -1
  13. package/dist/src/types/federal_census/FederalCensusTract.d.ts +1 -1
  14. package/dist/src/types/federal_census/FederalCensusTract.js +1 -1
  15. package/dist/src/types/federal_congress/FederalCongress.d.ts +1 -1
  16. package/dist/src/types/federal_congress/FederalCongress.js +1 -1
  17. package/dist/src/types/federal_congress/FederalCongressDistrict.d.ts +1 -1
  18. package/dist/src/types/federal_congress/FederalCongressDistrict.js +1 -1
  19. package/dist/src/types/federal_congress/FederalCongressMember.d.ts +1 -1
  20. package/dist/src/types/federal_congress/FederalCongressMember.js +1 -1
  21. package/dist/src/types/federal_elections/FederalElection.d.ts +1 -1
  22. package/dist/src/types/federal_elections/FederalElection.js +1 -1
  23. package/dist/src/types/federal_elections/FederalElectionCandidate.d.ts +1 -1
  24. package/dist/src/types/federal_elections/FederalElectionCandidate.js +1 -1
  25. package/dist/src/types/federal_elections/FederalElectionDonation.d.ts +1 -1
  26. package/dist/src/types/federal_elections/FederalElectionF2File.d.ts +1 -1
  27. package/dist/src/types/federal_elections/FederalElectionF2File.js +1 -1
  28. package/dist/src/types/jurisdictions/County.d.ts +18 -0
  29. package/dist/src/types/jurisdictions/County.js +44 -0
  30. package/dist/src/types/jurisdictions/JurisdictionMetric.d.ts +10 -0
  31. package/dist/src/types/jurisdictions/JurisdictionMetric.js +23 -0
  32. package/dist/src/types/jurisdictions/JurisdictionTypeID.d.ts +3 -0
  33. package/dist/src/types/jurisdictions/JurisdictionTypeID.js +4 -0
  34. package/dist/src/types/jurisdictions/Municipality.d.ts +17 -0
  35. package/dist/src/types/jurisdictions/Municipality.js +41 -0
  36. package/dist/src/types/jurisdictions/SchoolDistrict.d.ts +16 -0
  37. package/dist/src/types/jurisdictions/SchoolDistrict.js +38 -0
  38. package/dist/src/types/jurisdictions/State.d.ts +12 -0
  39. package/dist/src/types/jurisdictions/State.js +364 -0
  40. package/dist/src/types/lal/LALFile.d.ts +1 -1
  41. package/dist/src/types/lal/LALFile.js +1 -1
  42. package/dist/src/types/lal/LALFileVoter.d.ts +1 -1
  43. package/dist/src/types/lal/LALFileVoter.js +1 -1
  44. package/dist/src/types/prism/Prism.d.ts +4 -6
  45. package/dist/src/types/prism/Prism.js +8 -16
  46. package/dist/src/types/prism/StateVoter.d.ts +1 -1
  47. package/dist/src/types/prism/StateVoter.js +1 -1
  48. package/dist/src/types/prism/StateVoterFeature.d.ts +1 -1
  49. package/dist/src/types/prism/StateVoterFeature.js +1 -1
  50. package/dist/src/types/prism/StateVoterTarget.d.ts +1 -1
  51. package/dist/src/types/prism/StateVoterTarget.js +1 -1
  52. package/dist/src/types/prism/Voter.d.ts +1 -1
  53. package/dist/src/types/prism/Voter.js +1 -1
  54. package/dist/src/types/prism/VoterFeature.d.ts +1 -1
  55. package/dist/src/types/prism/VoterFeature.js +1 -1
  56. package/dist/src/types/prism/VoterTarget.d.ts +1 -1
  57. package/dist/src/types/prism/VoterTarget.js +1 -1
  58. package/dist/src/types/regions/SchoolDistrict.d.ts +7 -0
  59. package/dist/src/types/regions/SchoolDistrict.js +15 -0
  60. package/dist/src/types/state_legislature/StateLegislatureDistrict.d.ts +1 -1
  61. package/dist/src/types/state_legislature/StateLegislatureDistrict.js +1 -1
  62. package/dist/src/types/state_permits/StateFacility.d.ts +1 -1
  63. package/dist/src/types/state_permits/StateFacility.js +1 -1
  64. package/dist/src/types/state_permits/StatePermit.d.ts +1 -1
  65. package/dist/src/types/state_permits/StatePermit.js +1 -1
  66. package/dist/src/types/state_permits/StatePermitDocument.d.ts +1 -1
  67. package/dist/src/types/state_permits/StatePermitDocument.js +1 -1
  68. package/dist/src/types/state_permits/StatePermitDocumentSource.d.ts +1 -1
  69. package/dist/src/types/state_permits/StatePermitDocumentSource.js +1 -1
  70. package/dist/src/types/state_permits/StatePermitDocumentSourcePollutant.d.ts +1 -1
  71. package/dist/src/types/state_permits/StatePermitDocumentSourcePollutant.js +1 -1
  72. package/package.json +1 -1
  73. package/src/index.ts +7 -5
  74. package/src/types/ballotpedia/BallotpediaOffice.ts +1 -1
  75. package/src/types/federal_census/FederalCensusBlock.ts +1 -1
  76. package/src/types/federal_census/FederalCensusCounty.ts +1 -1
  77. package/src/types/federal_census/FederalCensusMunicipality.ts +1 -1
  78. package/src/types/federal_census/FederalCensusSchoolDistrict.ts +1 -1
  79. package/src/types/federal_census/FederalCensusTract.ts +1 -1
  80. package/src/types/federal_congress/FederalCongress.ts +1 -1
  81. package/src/types/federal_congress/FederalCongressDistrict.ts +1 -1
  82. package/src/types/federal_congress/FederalCongressMember.ts +1 -1
  83. package/src/types/federal_elections/FederalElection.ts +1 -1
  84. package/src/types/federal_elections/FederalElectionCandidate.ts +1 -1
  85. package/src/types/federal_elections/FederalElectionDonation.ts +1 -1
  86. package/src/types/federal_elections/FederalElectionF2File.ts +1 -1
  87. package/src/types/jurisdictions/JurisdictionMetric.ts +29 -0
  88. package/src/types/jurisdictions/JurisdictionTypeID.ts +7 -0
  89. package/src/types/{regions → jurisdictions}/SchoolDistrict.ts +22 -0
  90. package/src/types/lal/LALFile.ts +1 -1
  91. package/src/types/lal/LALFileVoter.ts +1 -1
  92. package/src/types/prism/Prism.ts +8 -16
  93. package/src/types/prism/StateVoter.ts +1 -1
  94. package/src/types/prism/StateVoterFeature.ts +1 -1
  95. package/src/types/prism/StateVoterTarget.ts +1 -1
  96. package/src/types/prism/TenantVoterTag.ts +1 -1
  97. package/src/types/prism/Voter.ts +1 -1
  98. package/src/types/prism/VoterFeature.ts +1 -1
  99. package/src/types/prism/VoterTarget.ts +1 -1
  100. package/src/types/state_legislature/StateLegislatureDistrict.ts +1 -1
  101. package/src/types/state_permits/KY/KYStateFacility.ts +1 -1
  102. package/src/types/state_permits/StateFacility.ts +1 -1
  103. package/src/types/state_permits/StatePermit.ts +1 -1
  104. package/src/types/state_permits/StatePermitDocument.ts +1 -1
  105. package/src/types/state_permits/StatePermitDocumentSource.ts +1 -1
  106. package/src/types/state_permits/StatePermitDocumentSourcePollutant.ts +1 -1
  107. /package/src/types/{regions → jurisdictions}/County.ts +0 -0
  108. /package/src/types/{regions → jurisdictions}/Municipality.ts +0 -0
  109. /package/src/types/{regions → jurisdictions}/State.ts +0 -0
@@ -0,0 +1,364 @@
1
+ export const state_ids = ["AL", "AK", "AZ", "AR", "CA", "CO", "CT", "DE", "FL", "GA", "HI", "ID", "IL", "IN", "IA", "KS", "KY", "LA", "ME", "MD", "MA", "MI", "MN", "MS", "MO", "MT", "NE", "NV", "NH", "NJ", "NM", "NY", "NC", "ND", "OH", "OK", "OR", "PA", "RI", "SC", "SD", "TN", "TX", "UT", "VT", "VA", "WA", "WV", "WI", "WY", "DC", "PR", "AS", "GU", "MP", "VI"];
2
+ export function is_state_id(state_id) {
3
+ return state_ids.includes(state_id);
4
+ }
5
+ export class State {
6
+ state_id;
7
+ name;
8
+ federal_census_state_id;
9
+ is_territory;
10
+ constructor(state) {
11
+ if (!State.is(state)) {
12
+ throw Error("Invalid input.");
13
+ }
14
+ this.state_id = state.state_id;
15
+ this.name = state.name;
16
+ this.federal_census_state_id = state.federal_census_state_id;
17
+ this.is_territory = state.is_territory;
18
+ }
19
+ static is(state) {
20
+ return (state !== undefined &&
21
+ is_state_id(state.state_id) &&
22
+ typeof state.name === "string" &&
23
+ typeof state.federal_census_state_id === "string" &&
24
+ typeof state.is_territory === "boolean");
25
+ }
26
+ }
27
+ export const states_by_state_id = {
28
+ AL: {
29
+ state_id: "AL",
30
+ name: "Alabama",
31
+ federal_census_state_id: "01",
32
+ is_territory: false
33
+ },
34
+ AK: {
35
+ state_id: "AK",
36
+ name: "Alaska",
37
+ federal_census_state_id: "02",
38
+ is_territory: false
39
+ },
40
+ AZ: {
41
+ state_id: "AZ",
42
+ name: "Arizona",
43
+ federal_census_state_id: "04",
44
+ is_territory: false
45
+ },
46
+ AR: {
47
+ state_id: "AR",
48
+ name: "Arkansas",
49
+ federal_census_state_id: "05",
50
+ is_territory: false
51
+ },
52
+ CA: {
53
+ state_id: "CA",
54
+ name: "California",
55
+ federal_census_state_id: "06",
56
+ is_territory: false
57
+ },
58
+ CO: {
59
+ state_id: "CO",
60
+ name: "Colorado",
61
+ federal_census_state_id: "08",
62
+ is_territory: false
63
+ },
64
+ CT: {
65
+ state_id: "CT",
66
+ name: "Connecticut",
67
+ federal_census_state_id: "09",
68
+ is_territory: false
69
+ },
70
+ DE: {
71
+ state_id: "DE",
72
+ name: "Delaware",
73
+ federal_census_state_id: "10",
74
+ is_territory: false
75
+ },
76
+ FL: {
77
+ state_id: "FL",
78
+ name: "Florida",
79
+ federal_census_state_id: "12",
80
+ is_territory: false
81
+ },
82
+ GA: {
83
+ state_id: "GA",
84
+ name: "Georgia",
85
+ federal_census_state_id: "13",
86
+ is_territory: false
87
+ },
88
+ HI: {
89
+ state_id: "HI",
90
+ name: "Hawaii",
91
+ federal_census_state_id: "15",
92
+ is_territory: false
93
+ },
94
+ ID: {
95
+ state_id: "ID",
96
+ name: "Idaho",
97
+ federal_census_state_id: "16",
98
+ is_territory: false
99
+ },
100
+ IL: {
101
+ state_id: "IL",
102
+ name: "Illinois",
103
+ federal_census_state_id: "17",
104
+ is_territory: false
105
+ },
106
+ IN: {
107
+ state_id: "IN",
108
+ name: "Indiana",
109
+ federal_census_state_id: "18",
110
+ is_territory: false
111
+ },
112
+ IA: {
113
+ state_id: "IA",
114
+ name: "Iowa",
115
+ federal_census_state_id: "19",
116
+ is_territory: false
117
+ },
118
+ KS: {
119
+ state_id: "KS",
120
+ name: "Kansas",
121
+ federal_census_state_id: "20",
122
+ is_territory: false
123
+ },
124
+ KY: {
125
+ state_id: "KY",
126
+ name: "Kentucky",
127
+ federal_census_state_id: "21",
128
+ is_territory: false
129
+ },
130
+ LA: {
131
+ state_id: "LA",
132
+ name: "Louisiana",
133
+ federal_census_state_id: "22",
134
+ is_territory: false
135
+ },
136
+ ME: {
137
+ state_id: "ME",
138
+ name: "Maine",
139
+ federal_census_state_id: "23",
140
+ is_territory: false
141
+ },
142
+ MD: {
143
+ state_id: "MD",
144
+ name: "Maryland",
145
+ federal_census_state_id: "24",
146
+ is_territory: false
147
+ },
148
+ MA: {
149
+ state_id: "MA",
150
+ name: "Massachusetts",
151
+ federal_census_state_id: "25",
152
+ is_territory: false
153
+ },
154
+ MI: {
155
+ state_id: "MI",
156
+ name: "Michigan",
157
+ federal_census_state_id: "26",
158
+ is_territory: false
159
+ },
160
+ MN: {
161
+ state_id: "MN",
162
+ name: "Minnesota",
163
+ federal_census_state_id: "27",
164
+ is_territory: false
165
+ },
166
+ MS: {
167
+ state_id: "MS",
168
+ name: "Mississippi",
169
+ federal_census_state_id: "28",
170
+ is_territory: false
171
+ },
172
+ MO: {
173
+ state_id: "MO",
174
+ name: "Missouri",
175
+ federal_census_state_id: "29",
176
+ is_territory: false
177
+ },
178
+ MT: {
179
+ state_id: "MT",
180
+ name: "Montana",
181
+ federal_census_state_id: "30",
182
+ is_territory: false
183
+ },
184
+ NE: {
185
+ state_id: "NE",
186
+ name: "Nebraska",
187
+ federal_census_state_id: "31",
188
+ is_territory: false
189
+ },
190
+ NV: {
191
+ state_id: "NV",
192
+ name: "Nevada",
193
+ federal_census_state_id: "32",
194
+ is_territory: false
195
+ },
196
+ NH: {
197
+ state_id: "NH",
198
+ name: "New Hampshire",
199
+ federal_census_state_id: "33",
200
+ is_territory: false
201
+ },
202
+ NJ: {
203
+ state_id: "NJ",
204
+ name: "New Jersey",
205
+ federal_census_state_id: "34",
206
+ is_territory: false
207
+ },
208
+ NM: {
209
+ state_id: "NM",
210
+ name: "New Mexico",
211
+ federal_census_state_id: "35",
212
+ is_territory: false
213
+ },
214
+ NY: {
215
+ state_id: "NY",
216
+ name: "New York",
217
+ federal_census_state_id: "36",
218
+ is_territory: false
219
+ },
220
+ NC: {
221
+ state_id: "NC",
222
+ name: "North Carolina",
223
+ federal_census_state_id: "37",
224
+ is_territory: false
225
+ },
226
+ ND: {
227
+ state_id: "ND",
228
+ name: "North Dakota",
229
+ federal_census_state_id: "38",
230
+ is_territory: false
231
+ },
232
+ OH: {
233
+ state_id: "OH",
234
+ name: "Ohio",
235
+ federal_census_state_id: "39",
236
+ is_territory: false
237
+ },
238
+ OK: {
239
+ state_id: "OK",
240
+ name: "Oklahoma",
241
+ federal_census_state_id: "40",
242
+ is_territory: false
243
+ },
244
+ OR: {
245
+ state_id: "OR",
246
+ name: "Oregon",
247
+ federal_census_state_id: "41",
248
+ is_territory: false
249
+ },
250
+ PA: {
251
+ state_id: "PA",
252
+ name: "Pennsylvania",
253
+ federal_census_state_id: "42",
254
+ is_territory: false
255
+ },
256
+ RI: {
257
+ state_id: "RI",
258
+ name: "Rhode Island",
259
+ federal_census_state_id: "44",
260
+ is_territory: false
261
+ },
262
+ SC: {
263
+ state_id: "SC",
264
+ name: "South Carolina",
265
+ federal_census_state_id: "45",
266
+ is_territory: false
267
+ },
268
+ SD: {
269
+ state_id: "SD",
270
+ name: "South Dakota",
271
+ federal_census_state_id: "46",
272
+ is_territory: false
273
+ },
274
+ TN: {
275
+ state_id: "TN",
276
+ name: "Tennessee",
277
+ federal_census_state_id: "47",
278
+ is_territory: false
279
+ },
280
+ TX: {
281
+ state_id: "TX",
282
+ name: "Texas",
283
+ federal_census_state_id: "48",
284
+ is_territory: false
285
+ },
286
+ UT: {
287
+ state_id: "UT",
288
+ name: "Utah",
289
+ federal_census_state_id: "49",
290
+ is_territory: false
291
+ },
292
+ VT: {
293
+ state_id: "VT",
294
+ name: "Vermont",
295
+ federal_census_state_id: "50",
296
+ is_territory: false
297
+ },
298
+ VA: {
299
+ state_id: "VA",
300
+ name: "Virginia",
301
+ federal_census_state_id: "51",
302
+ is_territory: false
303
+ },
304
+ WA: {
305
+ state_id: "WA",
306
+ name: "Washington",
307
+ federal_census_state_id: "53",
308
+ is_territory: false
309
+ },
310
+ WV: {
311
+ state_id: "WV",
312
+ name: "West Virginia",
313
+ federal_census_state_id: "54",
314
+ is_territory: false
315
+ },
316
+ WI: {
317
+ state_id: "WI",
318
+ name: "Wisconsin",
319
+ federal_census_state_id: "55",
320
+ is_territory: false
321
+ },
322
+ WY: {
323
+ state_id: "WY",
324
+ name: "Wyoming",
325
+ federal_census_state_id: "56",
326
+ is_territory: false
327
+ },
328
+ DC: {
329
+ state_id: "DC",
330
+ name: "Washington D.C.",
331
+ federal_census_state_id: "11",
332
+ is_territory: true
333
+ },
334
+ PR: {
335
+ state_id: "PR",
336
+ name: "Puerto Rico",
337
+ federal_census_state_id: "72",
338
+ is_territory: true
339
+ },
340
+ AS: {
341
+ state_id: "AS",
342
+ name: "American Samoa",
343
+ federal_census_state_id: "60",
344
+ is_territory: true
345
+ },
346
+ GU: {
347
+ state_id: "GU",
348
+ name: "Guam",
349
+ federal_census_state_id: "66",
350
+ is_territory: true
351
+ },
352
+ MP: {
353
+ state_id: "MP",
354
+ name: "Northern Mariana Islands",
355
+ federal_census_state_id: "69",
356
+ is_territory: true
357
+ },
358
+ VI: {
359
+ state_id: "VI",
360
+ name: "Virgin Islands",
361
+ federal_census_state_id: "78",
362
+ is_territory: true
363
+ }
364
+ };
@@ -1,4 +1,4 @@
1
- import { StateID } from "../regions/State.js";
1
+ import { StateID } from "../jurisdictions/State.js";
2
2
  export declare class LALFile {
3
3
  readonly lal_file_id: string;
4
4
  readonly state_id: StateID;
@@ -1,4 +1,4 @@
1
- import { is_state_id } from "../regions/State.js";
1
+ import { is_state_id } from "../jurisdictions/State.js";
2
2
  export class LALFile {
3
3
  lal_file_id;
4
4
  state_id;
@@ -1,5 +1,5 @@
1
1
  import { VoterPartyTypeID } from "../prism/Voter.js";
2
- import { StateID } from "../regions/State.js";
2
+ import { StateID } from "../jurisdictions/State.js";
3
3
  export declare class LALFileVoter {
4
4
  readonly lal_file_id: string;
5
5
  readonly lal_voter_id: string;
@@ -1,5 +1,5 @@
1
1
  import { is_voter_party_type_id } from "../prism/Voter.js";
2
- import { is_state_id } from "../regions/State.js";
2
+ import { is_state_id } from "../jurisdictions/State.js";
3
3
  export class LALFileVoter {
4
4
  lal_file_id;
5
5
  lal_voter_id;
@@ -1,14 +1,12 @@
1
- import { StateID } from "../regions/State.js";
1
+ import { JurisdictionTypeID } from "../jurisdictions/JurisdictionTypeID.js";
2
+ import { StateID } from "../jurisdictions/State.js";
2
3
  import { VoterPartyTypeID } from "./Voter.js";
3
4
  export declare class Prism {
4
5
  readonly prism_id: string;
5
6
  readonly state_id: StateID;
6
7
  readonly name: string;
7
- readonly federal_congress_district_id?: string;
8
- readonly state_legislature_house_district_id?: string;
9
- readonly state_legislature_senate_district_id?: string;
10
- readonly county_id?: string;
11
- readonly school_district_id?: string;
8
+ readonly jurisdiction_type_id: JurisdictionTypeID;
9
+ readonly jurisdiction_id: string;
12
10
  readonly party_type_ids?: VoterPartyTypeID[];
13
11
  readonly target_ids: string[];
14
12
  readonly [x: string]: any;
@@ -1,14 +1,12 @@
1
- import { is_state_id } from "../regions/State.js";
1
+ import { is_jurisdiction_type_id } from "../jurisdictions/JurisdictionTypeID.js";
2
+ import { is_state_id } from "../jurisdictions/State.js";
2
3
  import { is_voter_party_type_id } from "./Voter.js";
3
4
  export class Prism {
4
5
  prism_id;
5
6
  state_id;
6
7
  name;
7
- federal_congress_district_id;
8
- state_legislature_house_district_id;
9
- state_legislature_senate_district_id;
10
- county_id;
11
- school_district_id;
8
+ jurisdiction_type_id;
9
+ jurisdiction_id;
12
10
  party_type_ids;
13
11
  target_ids;
14
12
  constructor(prism) {
@@ -18,11 +16,8 @@ export class Prism {
18
16
  this.prism_id = prism.prism_id;
19
17
  this.state_id = prism.state_id;
20
18
  this.name = prism.name;
21
- this.federal_congress_district_id = prism.federal_congress_district_id;
22
- this.state_legislature_house_district_id = prism.state_legislature_house_district_id;
23
- this.state_legislature_senate_district_id = prism.state_legislature_senate_district_id;
24
- this.county_id = prism.county_id;
25
- this.school_district_id = prism.school_district_id;
19
+ this.jurisdiction_type_id = prism.jurisdiction_type_id;
20
+ this.jurisdiction_id = prism.jurisdiction_id;
26
21
  this.party_type_ids = prism.party_type_ids;
27
22
  this.target_ids = prism.target_ids;
28
23
  }
@@ -31,11 +26,8 @@ export class Prism {
31
26
  typeof prism.prism_id === "string" &&
32
27
  is_state_id(prism.state_id) &&
33
28
  typeof prism.name === "string" &&
34
- (prism.federal_congress_district_id === undefined || typeof prism.federal_congress_district_id === "string") &&
35
- (prism.state_legislature_house_district_id === undefined || typeof prism.state_legislature_house_district_id === "string") &&
36
- (prism.state_legislature_senate_district_id === undefined || typeof prism.state_legislature_senate_district_id === "string") &&
37
- (prism.county_id === undefined || typeof prism.county_id === "string") &&
38
- (prism.school_district_id === undefined || typeof prism.school_district_id === "string") &&
29
+ is_jurisdiction_type_id(prism.jurisdiction_type_id) &&
30
+ typeof prism.jurisdiction_id === "string" &&
39
31
  (prism.party_type_ids === undefined || Array.isArray(prism.party_type_ids) && prism.party_type_ids.every(is_voter_party_type_id)) &&
40
32
  Array.isArray(prism.target_ids) && prism.target_ids.every((target_id) => typeof target_id === "string"));
41
33
  }
@@ -1,5 +1,5 @@
1
1
  import { LALFileVoter } from "../lal/LALFileVoter.js";
2
- import { StateID } from "../regions/State.js";
2
+ import { StateID } from "../jurisdictions/State.js";
3
3
  import { StateVoterFeature } from "./StateVoterFeature.js";
4
4
  import { StateVoterTarget } from "./StateVoterTarget.js";
5
5
  import { VoterPartyTypeID } from "./Voter.js";
@@ -1,5 +1,5 @@
1
1
  import { LALFileVoter } from "../lal/LALFileVoter.js";
2
- import { is_state_id } from "../regions/State.js";
2
+ import { is_state_id } from "../jurisdictions/State.js";
3
3
  import { StateVoterFeature } from "./StateVoterFeature.js";
4
4
  import { StateVoterTarget } from "./StateVoterTarget.js";
5
5
  import { is_voter_party_type_id } from "./Voter.js";
@@ -1,4 +1,4 @@
1
- import { StateID } from "../regions/State.js";
1
+ import { StateID } from "../jurisdictions/State.js";
2
2
  export declare class StateVoterFeature {
3
3
  readonly state_id: StateID;
4
4
  readonly voter_id: string;
@@ -1,4 +1,4 @@
1
- import { is_state_id } from "../regions/State.js";
1
+ import { is_state_id } from "../jurisdictions/State.js";
2
2
  export class StateVoterFeature {
3
3
  state_id;
4
4
  voter_id;
@@ -1,4 +1,4 @@
1
- import { StateID } from "../regions/State.js";
1
+ import { StateID } from "../jurisdictions/State.js";
2
2
  export declare class StateVoterTarget {
3
3
  readonly state_id: StateID;
4
4
  readonly voter_id: string;
@@ -1,4 +1,4 @@
1
- import { is_state_id } from "../regions/State.js";
1
+ import { is_state_id } from "../jurisdictions/State.js";
2
2
  export class StateVoterTarget {
3
3
  state_id;
4
4
  voter_id;
@@ -1,4 +1,4 @@
1
- import { StateID } from "../regions/State.js";
1
+ import { StateID } from "../jurisdictions/State.js";
2
2
  import { VoterFeature } from "./VoterFeature.js";
3
3
  import { VoterTarget } from "./VoterTarget.js";
4
4
  export declare const voter_party_type_ids: readonly ["D", "R", "I"];
@@ -1,4 +1,4 @@
1
- import { is_state_id } from "../regions/State.js";
1
+ import { is_state_id } from "../jurisdictions/State.js";
2
2
  import { VoterFeature } from "./VoterFeature.js";
3
3
  import { VoterTarget } from "./VoterTarget.js";
4
4
  export const voter_party_type_ids = ["D", "R", "I"];
@@ -1,4 +1,4 @@
1
- import { StateID } from "../regions/State.js";
1
+ import { StateID } from "../jurisdictions/State.js";
2
2
  import { VoterPartyTypeID } from "./Voter.js";
3
3
  export declare class VoterFeature {
4
4
  readonly voter_feature_id: string;
@@ -1,4 +1,4 @@
1
- import { is_state_id } from "../regions/State.js";
1
+ import { is_state_id } from "../jurisdictions/State.js";
2
2
  import { is_voter_party_type_id } from "./Voter.js";
3
3
  export class VoterFeature {
4
4
  voter_feature_id;
@@ -1,4 +1,4 @@
1
- import { StateID } from "../regions/State.js";
1
+ import { StateID } from "../jurisdictions/State.js";
2
2
  import { VoterPartyTypeID } from "./Voter.js";
3
3
  export declare class VoterTarget {
4
4
  readonly voter_target_id: string;
@@ -1,4 +1,4 @@
1
- import { is_state_id } from "../regions/State.js";
1
+ import { is_state_id } from "../jurisdictions/State.js";
2
2
  import { is_voter_party_type_id } from "./Voter.js";
3
3
  export class VoterTarget {
4
4
  voter_target_id;
@@ -1,9 +1,16 @@
1
+ import { FederalCensusSchoolDistrict } from "../federal_census/FederalCensusSchoolDistrict.js";
1
2
  import { StateID } from "./State.js";
2
3
  export declare class SchoolDistrict {
3
4
  readonly school_district_id: string;
4
5
  readonly state_id: StateID;
5
6
  readonly name: string;
6
7
  readonly federal_census_school_district_id: string;
8
+ readonly [x: string]: any;
7
9
  constructor(school_district: any);
8
10
  static is(school_district: any): school_district is SchoolDistrict;
9
11
  }
12
+ export declare class SchoolDistrictAux extends SchoolDistrict {
13
+ readonly federal_census_school_district: FederalCensusSchoolDistrict;
14
+ constructor(school_district: SchoolDistrictAux);
15
+ static is(school_district: any): school_district is SchoolDistrictAux;
16
+ }
@@ -1,3 +1,4 @@
1
+ import { FederalCensusSchoolDistrict } from "../federal_census/FederalCensusSchoolDistrict.js";
1
2
  import { is_state_id } from "./State.js";
2
3
  export class SchoolDistrict {
3
4
  school_district_id;
@@ -21,3 +22,17 @@ export class SchoolDistrict {
21
22
  typeof school_district.federal_census_school_district_id === "string");
22
23
  }
23
24
  }
25
+ export class SchoolDistrictAux extends SchoolDistrict {
26
+ federal_census_school_district;
27
+ constructor(school_district) {
28
+ if (!SchoolDistrictAux.is(school_district)) {
29
+ throw Error("Invalid input.");
30
+ }
31
+ super(school_district);
32
+ this.federal_census_school_district = school_district.federal_census_school_district;
33
+ }
34
+ static is(school_district) {
35
+ return (SchoolDistrict.is(school_district) &&
36
+ FederalCensusSchoolDistrict.is(school_district.federal_census_school_district));
37
+ }
38
+ }
@@ -1,4 +1,4 @@
1
- import { StateID } from "../regions/State.js";
1
+ import { StateID } from "../jurisdictions/State.js";
2
2
  export declare class StateLegislatureDistrict {
3
3
  readonly state_legislature_district_id: string;
4
4
  readonly state_id: StateID;
@@ -1,4 +1,4 @@
1
- import { is_state_id } from "../regions/State.js";
1
+ import { is_state_id } from "../jurisdictions/State.js";
2
2
  export class StateLegislatureDistrict {
3
3
  state_legislature_district_id;
4
4
  state_id;
@@ -1,4 +1,4 @@
1
- import { StateID } from "../regions/State.js";
1
+ import { StateID } from "../jurisdictions/State.js";
2
2
  import { StatePermitAux } from "./StatePermit.js";
3
3
  export declare class StateFacility {
4
4
  readonly state_facility_id: string;
@@ -1,4 +1,4 @@
1
- import { is_state_id } from "../regions/State.js";
1
+ import { is_state_id } from "../jurisdictions/State.js";
2
2
  import { StatePermitAux } from "./StatePermit.js";
3
3
  export class StateFacility {
4
4
  state_facility_id;
@@ -1,4 +1,4 @@
1
- import { StateID } from "../regions/State.js";
1
+ import { StateID } from "../jurisdictions/State.js";
2
2
  import { StateFacility } from "./StateFacility.js";
3
3
  export declare class StatePermit {
4
4
  readonly state_permit_id: string;
@@ -1,4 +1,4 @@
1
- import { is_state_id } from "../regions/State.js";
1
+ import { is_state_id } from "../jurisdictions/State.js";
2
2
  import { StateFacility } from "./StateFacility.js";
3
3
  export class StatePermit {
4
4
  state_permit_id;
@@ -1,4 +1,4 @@
1
- import { StateID } from "../regions/State.js";
1
+ import { StateID } from "../jurisdictions/State.js";
2
2
  import { StatePermitDocumentSourceAux } from "./StatePermitDocumentSource.js";
3
3
  export declare class StatePermitComment {
4
4
  readonly comment_text: string;
@@ -1,4 +1,4 @@
1
- import { is_state_id } from "../regions/State.js";
1
+ import { is_state_id } from "../jurisdictions/State.js";
2
2
  import { StatePermitDocumentSourceAux } from "./StatePermitDocumentSource.js";
3
3
  export class StatePermitComment {
4
4
  comment_text;
@@ -1,4 +1,4 @@
1
- import { StateID } from "../regions/State.js";
1
+ import { StateID } from "../jurisdictions/State.js";
2
2
  import { StatePermitAux } from "./StatePermit.js";
3
3
  import { StatePermitDocument } from "./StatePermitDocument.js";
4
4
  import { StatePermitDocumentSourcePollutant } from "./StatePermitDocumentSourcePollutant.js";
@@ -1,4 +1,4 @@
1
- import { is_state_id } from "../regions/State.js";
1
+ import { is_state_id } from "../jurisdictions/State.js";
2
2
  import { StatePermitAux } from "./StatePermit.js";
3
3
  import { StatePermitDocument } from "./StatePermitDocument.js";
4
4
  import { StatePermitDocumentSourcePollutant } from "./StatePermitDocumentSourcePollutant.js";