triangle-types 1.0.297 → 1.0.299

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.
@@ -2,11 +2,10 @@ declare const federal_congress_bill_type_ids: readonly ["HR", "S", "HJRES", "SJR
2
2
  export type FederalCongressBillTypeID = typeof federal_congress_bill_type_ids[number];
3
3
  export declare function is_federal_congress_bill_type_id(federal_congress_bill_type_id: any): federal_congress_bill_type_id is FederalCongressBillTypeID;
4
4
  export declare class FederalCongressBill {
5
- readonly federal_congress_bill_id: string;
6
5
  readonly federal_congress_id: number;
6
+ readonly bill_id: string;
7
7
  readonly bill_type_id: FederalCongressBillTypeID;
8
8
  readonly number: number;
9
- readonly bill_id: string;
10
9
  readonly title: string;
11
10
  readonly modify_time: string;
12
11
  readonly intro_date: string;
@@ -3,11 +3,10 @@ export function is_federal_congress_bill_type_id(federal_congress_bill_type_id)
3
3
  return federal_congress_bill_type_ids.includes(federal_congress_bill_type_id);
4
4
  }
5
5
  export class FederalCongressBill {
6
- federal_congress_bill_id;
7
6
  federal_congress_id;
7
+ bill_id;
8
8
  bill_type_id;
9
9
  number;
10
- bill_id;
11
10
  title;
12
11
  modify_time;
13
12
  intro_date;
@@ -17,11 +16,10 @@ export class FederalCongressBill {
17
16
  if (!FederalCongressBill.is(federal_congress_bill)) {
18
17
  throw Error("Invalid input.");
19
18
  }
20
- this.federal_congress_bill_id = federal_congress_bill.federal_congress_bill_id;
21
19
  this.federal_congress_id = federal_congress_bill.federal_congress_id;
20
+ this.bill_id = federal_congress_bill.bill_id;
22
21
  this.bill_type_id = federal_congress_bill.bill_type_id;
23
22
  this.number = federal_congress_bill.number;
24
- this.bill_id = federal_congress_bill.bill_id;
25
23
  this.title = federal_congress_bill.title;
26
24
  this.modify_time = federal_congress_bill.modify_time;
27
25
  this.intro_date = federal_congress_bill.intro_date;
@@ -30,11 +28,10 @@ export class FederalCongressBill {
30
28
  }
31
29
  static is(federal_congress_bill) {
32
30
  return (federal_congress_bill !== undefined &&
33
- typeof federal_congress_bill.federal_congress_bill_id === "string" &&
34
31
  typeof federal_congress_bill.federal_congress_id === "number" &&
32
+ typeof federal_congress_bill.bill_id === "string" &&
35
33
  is_federal_congress_bill_type_id(federal_congress_bill.bill_type_id) &&
36
34
  typeof federal_congress_bill.number === "number" &&
37
- typeof federal_congress_bill.bill_id === "string" &&
38
35
  typeof federal_congress_bill.title === "string" &&
39
36
  typeof federal_congress_bill.modify_time === "string" &&
40
37
  typeof federal_congress_bill.intro_date === "string" &&
@@ -2,11 +2,9 @@ declare const federal_congress_bill_action_type_ids: readonly ["COMMITTEE", "CAL
2
2
  export type FederalCongressBillActionTypeID = typeof federal_congress_bill_action_type_ids[number];
3
3
  export declare function is_federal_congress_bill_action_type_id(federal_congress_bill_action_type_id: any): federal_congress_bill_action_type_id is FederalCongressBillActionTypeID;
4
4
  export declare class FederalCongressBillAction {
5
- readonly federal_congress_bill_action_id: string;
6
5
  readonly federal_congress_id: number;
7
6
  readonly bill_id: string;
8
7
  readonly action_id: number;
9
- readonly federal_congress_bill_id: string;
10
8
  readonly bill_action_type_id?: FederalCongressBillActionTypeID;
11
9
  readonly date: string;
12
10
  readonly description: string;
@@ -14,11 +14,9 @@ export function is_federal_congress_bill_action_type_id(federal_congress_bill_ac
14
14
  return federal_congress_bill_action_type_ids.includes(federal_congress_bill_action_type_id);
15
15
  }
16
16
  export class FederalCongressBillAction {
17
- federal_congress_bill_action_id;
18
17
  federal_congress_id;
19
18
  bill_id;
20
19
  action_id;
21
- federal_congress_bill_id;
22
20
  bill_action_type_id;
23
21
  date;
24
22
  description;
@@ -28,11 +26,9 @@ export class FederalCongressBillAction {
28
26
  if (!FederalCongressBillAction.is(federal_congress_bill_action)) {
29
27
  throw Error("Invalid input.");
30
28
  }
31
- this.federal_congress_bill_action_id = federal_congress_bill_action.federal_congress_bill_action_id;
32
29
  this.federal_congress_id = federal_congress_bill_action.federal_congress_id;
33
30
  this.bill_id = federal_congress_bill_action.bill_id;
34
31
  this.action_id = federal_congress_bill_action.action_id;
35
- this.federal_congress_bill_id = federal_congress_bill_action.federal_congress_bill_id;
36
32
  this.bill_action_type_id = federal_congress_bill_action.bill_action_type_id;
37
33
  this.date = federal_congress_bill_action.date;
38
34
  this.description = federal_congress_bill_action.description;
@@ -41,11 +37,9 @@ export class FederalCongressBillAction {
41
37
  }
42
38
  static is(federal_congress_bill_action) {
43
39
  return (federal_congress_bill_action !== undefined &&
44
- typeof federal_congress_bill_action.federal_congress_bill_action_id === "string" &&
45
40
  typeof federal_congress_bill_action.federal_congress_id === "number" &&
46
41
  typeof federal_congress_bill_action.bill_id === "string" &&
47
42
  typeof federal_congress_bill_action.action_id === "number" &&
48
- typeof federal_congress_bill_action.federal_congress_bill_id === "string" &&
49
43
  (federal_congress_bill_action.bill_action_type_id === undefined || is_federal_congress_bill_action_type_id(federal_congress_bill_action.bill_action_type_id)) &&
50
44
  typeof federal_congress_bill_action.date === "string" &&
51
45
  typeof federal_congress_bill_action.description === "string" &&
@@ -3,11 +3,9 @@ declare const federal_congress_bill_document_type_ids: readonly ["AS", "ASH", "A
3
3
  export type FederalCongressBillDocumentTypeID = typeof federal_congress_bill_document_type_ids[number];
4
4
  export declare function is_federal_congress_bill_document_type_id(federal_congress_bill_document_type_id: any): federal_congress_bill_document_type_id is FederalCongressBillDocumentTypeID;
5
5
  export declare class FederalCongressBillDocument {
6
- readonly federal_congress_bill_document_id: string;
7
- readonly federal_congress_bill_id: string;
8
- readonly document_id: string;
9
6
  readonly federal_congress_id: number;
10
7
  readonly bill_id: string;
8
+ readonly document_id: string;
11
9
  readonly bill_type_id: FederalCongressBillTypeID;
12
10
  readonly number: number;
13
11
  readonly bill_document_type_id: FederalCongressBillDocumentTypeID;
@@ -5,11 +5,9 @@ export function is_federal_congress_bill_document_type_id(federal_congress_bill_
5
5
  return federal_congress_bill_document_type_ids.includes(federal_congress_bill_document_type_id);
6
6
  }
7
7
  export class FederalCongressBillDocument {
8
- federal_congress_bill_document_id;
9
- federal_congress_bill_id;
10
- document_id;
11
8
  federal_congress_id;
12
9
  bill_id;
10
+ document_id;
13
11
  bill_type_id;
14
12
  number;
15
13
  bill_document_type_id;
@@ -21,13 +19,11 @@ export class FederalCongressBillDocument {
21
19
  if (!FederalCongressBillDocument.is(federal_congress_bill_document)) {
22
20
  throw Error("Invalid input.");
23
21
  }
24
- this.federal_congress_bill_document_id = federal_congress_bill_document.federal_congress_bill_document_id;
25
- this.federal_congress_bill_id = federal_congress_bill_document.federal_congress_bill_id;
26
22
  this.federal_congress_id = federal_congress_bill_document.federal_congress_id;
27
23
  this.bill_id = federal_congress_bill_document.bill_id;
24
+ this.document_id = federal_congress_bill_document.document_id;
28
25
  this.bill_type_id = federal_congress_bill_document.bill_type_id;
29
26
  this.number = federal_congress_bill_document.number;
30
- this.document_id = federal_congress_bill_document.document_id;
31
27
  this.bill_document_type_id = federal_congress_bill_document.bill_document_type_id;
32
28
  this.format_id = federal_congress_bill_document.format_id;
33
29
  this.publish_time = federal_congress_bill_document.publish_time;
@@ -36,13 +32,11 @@ export class FederalCongressBillDocument {
36
32
  }
37
33
  static is(federal_congress_bill_document) {
38
34
  return (federal_congress_bill_document !== undefined &&
39
- typeof federal_congress_bill_document.federal_congress_bill_document_id === "string" &&
40
- typeof federal_congress_bill_document.federal_congress_bill_id === "string" &&
41
35
  typeof federal_congress_bill_document.federal_congress_id === "number" &&
42
36
  typeof federal_congress_bill_document.bill_id === "string" &&
37
+ typeof federal_congress_bill_document.document_id === "string" &&
43
38
  typeof federal_congress_bill_document.bill_type_id === "string" &&
44
39
  typeof federal_congress_bill_document.number === "number" &&
45
- typeof federal_congress_bill_document.document_id === "string" &&
46
40
  is_federal_congress_bill_document_type_id(federal_congress_bill_document.bill_document_type_id) &&
47
41
  typeof federal_congress_bill_document.format_id === "string" &&
48
42
  (federal_congress_bill_document.publish_time === undefined || typeof federal_congress_bill_document.publish_time === "string") &&
@@ -1,4 +1,3 @@
1
- import { LALFileVoter } from "../lal/LALFileVoter.js";
2
1
  import { StateID } from "../jurisdictions/State.js";
3
2
  import { StateVoterTarget } from "./StateVoterTarget.js";
4
3
  import { VoterPartyTypeID } from "./Voter.js";
@@ -29,7 +28,6 @@ export declare class StateVoter {
29
28
  static is(state_voter: any): state_voter is StateVoter;
30
29
  }
31
30
  export declare class StateVoterAux extends StateVoter {
32
- readonly lal_file_voter: LALFileVoter;
33
31
  readonly targets: StateVoterTarget[];
34
32
  constructor(state_voter: any);
35
33
  static is(state_voter: any): state_voter is StateVoter;
@@ -1,4 +1,3 @@
1
- import { LALFileVoter } from "../lal/LALFileVoter.js";
2
1
  import { is_state_id } from "../jurisdictions/State.js";
3
2
  import { StateVoterTarget } from "./StateVoterTarget.js";
4
3
  import { is_voter_party_type_id } from "./Voter.js";
@@ -74,19 +73,16 @@ export class StateVoter {
74
73
  }
75
74
  }
76
75
  export class StateVoterAux extends StateVoter {
77
- lal_file_voter;
78
76
  targets;
79
77
  constructor(state_voter) {
80
78
  if (!StateVoterAux.is(state_voter)) {
81
79
  throw Error("Invalid input.");
82
80
  }
83
81
  super(state_voter);
84
- this.lal_file_voter = state_voter.lal_file_voter;
85
82
  this.targets = state_voter.targets;
86
83
  }
87
84
  static is(state_voter) {
88
85
  return (StateVoter.is(state_voter) &&
89
- LALFileVoter.is(state_voter.lal_file_voter) &&
90
86
  Array.isArray(state_voter.targets) && state_voter.targets.every(StateVoterTarget.is));
91
87
  }
92
88
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "triangle-types",
3
- "version": "1.0.297",
3
+ "version": "1.0.299",
4
4
  "main": "dist/src/index.js",
5
5
  "types": "dist/src/index.d.ts",
6
6
  "scripts": {
@@ -7,11 +7,10 @@ export function is_federal_congress_bill_type_id(federal_congress_bill_type_id :
7
7
  }
8
8
 
9
9
  export class FederalCongressBill {
10
- readonly federal_congress_bill_id : string
11
10
  readonly federal_congress_id : number
11
+ readonly bill_id : string
12
12
  readonly bill_type_id : FederalCongressBillTypeID
13
13
  readonly number : number
14
- readonly bill_id : string
15
14
  readonly title : string
16
15
  readonly modify_time : string
17
16
  readonly intro_date : string
@@ -22,11 +21,10 @@ export class FederalCongressBill {
22
21
  if (!FederalCongressBill.is(federal_congress_bill)) {
23
22
  throw Error("Invalid input.")
24
23
  }
25
- this.federal_congress_bill_id = federal_congress_bill.federal_congress_bill_id
26
24
  this.federal_congress_id = federal_congress_bill.federal_congress_id
25
+ this.bill_id = federal_congress_bill.bill_id
27
26
  this.bill_type_id = federal_congress_bill.bill_type_id
28
27
  this.number = federal_congress_bill.number
29
- this.bill_id = federal_congress_bill.bill_id
30
28
  this.title = federal_congress_bill.title
31
29
  this.modify_time = federal_congress_bill.modify_time
32
30
  this.intro_date = federal_congress_bill.intro_date
@@ -37,11 +35,10 @@ export class FederalCongressBill {
37
35
  static is(federal_congress_bill : any) : federal_congress_bill is FederalCongressBill {
38
36
  return (
39
37
  federal_congress_bill !== undefined &&
40
- typeof federal_congress_bill.federal_congress_bill_id === "string" &&
41
38
  typeof federal_congress_bill.federal_congress_id === "number" &&
39
+ typeof federal_congress_bill.bill_id === "string" &&
42
40
  is_federal_congress_bill_type_id(federal_congress_bill.bill_type_id) &&
43
41
  typeof federal_congress_bill.number === "number" &&
44
- typeof federal_congress_bill.bill_id === "string" &&
45
42
  typeof federal_congress_bill.title === "string" &&
46
43
  typeof federal_congress_bill.modify_time === "string" &&
47
44
  typeof federal_congress_bill.intro_date === "string" &&
@@ -20,11 +20,9 @@ export function is_federal_congress_bill_action_type_id(federal_congress_bill_ac
20
20
  }
21
21
 
22
22
  export class FederalCongressBillAction {
23
- readonly federal_congress_bill_action_id : string
24
23
  readonly federal_congress_id : number
25
24
  readonly bill_id : string
26
25
  readonly action_id : number
27
- readonly federal_congress_bill_id : string
28
26
  readonly bill_action_type_id? : FederalCongressBillActionTypeID
29
27
  readonly date : string
30
28
  readonly description : string
@@ -35,11 +33,9 @@ export class FederalCongressBillAction {
35
33
  if (!FederalCongressBillAction.is(federal_congress_bill_action)) {
36
34
  throw Error("Invalid input.")
37
35
  }
38
- this.federal_congress_bill_action_id = federal_congress_bill_action.federal_congress_bill_action_id
39
36
  this.federal_congress_id = federal_congress_bill_action.federal_congress_id
40
37
  this.bill_id = federal_congress_bill_action.bill_id
41
38
  this.action_id = federal_congress_bill_action.action_id
42
- this.federal_congress_bill_id = federal_congress_bill_action.federal_congress_bill_id
43
39
  this.bill_action_type_id = federal_congress_bill_action.bill_action_type_id
44
40
  this.date = federal_congress_bill_action.date
45
41
  this.description = federal_congress_bill_action.description
@@ -50,11 +46,9 @@ export class FederalCongressBillAction {
50
46
  static is(federal_congress_bill_action : any) : federal_congress_bill_action is FederalCongressBillAction {
51
47
  return (
52
48
  federal_congress_bill_action !== undefined &&
53
- typeof federal_congress_bill_action.federal_congress_bill_action_id === "string" &&
54
49
  typeof federal_congress_bill_action.federal_congress_id === "number" &&
55
50
  typeof federal_congress_bill_action.bill_id === "string" &&
56
51
  typeof federal_congress_bill_action.action_id === "number" &&
57
- typeof federal_congress_bill_action.federal_congress_bill_id === "string" &&
58
52
  (federal_congress_bill_action.bill_action_type_id === undefined || is_federal_congress_bill_action_type_id(federal_congress_bill_action.bill_action_type_id)) &&
59
53
  typeof federal_congress_bill_action.date === "string" &&
60
54
  typeof federal_congress_bill_action.description === "string" &&
@@ -11,11 +11,9 @@ export function is_federal_congress_bill_document_type_id(federal_congress_bill_
11
11
  }
12
12
 
13
13
  export class FederalCongressBillDocument {
14
- readonly federal_congress_bill_document_id : string
15
- readonly federal_congress_bill_id : string
16
- readonly document_id : string
17
14
  readonly federal_congress_id : number
18
15
  readonly bill_id : string
16
+ readonly document_id : string
19
17
  readonly bill_type_id : FederalCongressBillTypeID
20
18
  readonly number : number
21
19
  readonly bill_document_type_id : FederalCongressBillDocumentTypeID
@@ -28,13 +26,11 @@ export class FederalCongressBillDocument {
28
26
  if (!FederalCongressBillDocument.is(federal_congress_bill_document)) {
29
27
  throw Error("Invalid input.")
30
28
  }
31
- this.federal_congress_bill_document_id = federal_congress_bill_document.federal_congress_bill_document_id
32
- this.federal_congress_bill_id = federal_congress_bill_document.federal_congress_bill_id
33
29
  this.federal_congress_id = federal_congress_bill_document.federal_congress_id
34
30
  this.bill_id = federal_congress_bill_document.bill_id
31
+ this.document_id = federal_congress_bill_document.document_id
35
32
  this.bill_type_id = federal_congress_bill_document.bill_type_id
36
33
  this.number = federal_congress_bill_document.number
37
- this.document_id = federal_congress_bill_document.document_id
38
34
  this.bill_document_type_id = federal_congress_bill_document.bill_document_type_id
39
35
  this.format_id = federal_congress_bill_document.format_id
40
36
  this.publish_time = federal_congress_bill_document.publish_time
@@ -45,13 +41,11 @@ export class FederalCongressBillDocument {
45
41
  static is(federal_congress_bill_document : any) : federal_congress_bill_document is FederalCongressBillDocument {
46
42
  return (
47
43
  federal_congress_bill_document !== undefined &&
48
- typeof federal_congress_bill_document.federal_congress_bill_document_id === "string" &&
49
- typeof federal_congress_bill_document.federal_congress_bill_id === "string" &&
50
44
  typeof federal_congress_bill_document.federal_congress_id === "number" &&
51
45
  typeof federal_congress_bill_document.bill_id === "string" &&
46
+ typeof federal_congress_bill_document.document_id === "string" &&
52
47
  typeof federal_congress_bill_document.bill_type_id === "string" &&
53
48
  typeof federal_congress_bill_document.number === "number" &&
54
- typeof federal_congress_bill_document.document_id === "string" &&
55
49
  is_federal_congress_bill_document_type_id(federal_congress_bill_document.bill_document_type_id) &&
56
50
  typeof federal_congress_bill_document.format_id === "string" &&
57
51
  (federal_congress_bill_document.publish_time === undefined || typeof federal_congress_bill_document.publish_time === "string") &&
@@ -81,7 +81,6 @@ export class StateVoter {
81
81
  }
82
82
 
83
83
  export class StateVoterAux extends StateVoter {
84
- readonly lal_file_voter : LALFileVoter
85
84
  readonly targets : StateVoterTarget[]
86
85
 
87
86
  constructor(state_voter : any) {
@@ -89,14 +88,12 @@ export class StateVoterAux extends StateVoter {
89
88
  throw Error("Invalid input.")
90
89
  }
91
90
  super(state_voter)
92
- this.lal_file_voter = state_voter.lal_file_voter
93
91
  this.targets = state_voter.targets
94
92
  }
95
93
 
96
94
  static is(state_voter : any) : state_voter is StateVoter {
97
95
  return (
98
96
  StateVoter.is(state_voter) &&
99
- LALFileVoter.is(state_voter.lal_file_voter) &&
100
97
  Array.isArray(state_voter.targets) && state_voter.targets.every(StateVoterTarget.is)
101
98
  )
102
99
  }