triangle-types 1.0.300 → 1.0.302
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,4 +1,4 @@
|
|
|
1
|
-
declare const federal_congress_bill_type_ids: readonly ["HR", "S", "HJRES", "SJRES", "HCONRES", "SCONRES", "HRES", "SRES"];
|
|
1
|
+
export declare const federal_congress_bill_type_ids: readonly ["HR", "S", "HJRES", "SJRES", "HCONRES", "SCONRES", "HRES", "SRES"];
|
|
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 {
|
|
@@ -10,8 +10,7 @@ export declare class FederalCongressBill {
|
|
|
10
10
|
readonly modify_time: string;
|
|
11
11
|
readonly intro_date: string;
|
|
12
12
|
readonly policy_domain_id?: string;
|
|
13
|
-
readonly
|
|
13
|
+
readonly federal_congress_member_ids?: string[];
|
|
14
14
|
constructor(federal_congress_bill: any);
|
|
15
15
|
static is(federal_congress_bill: any): federal_congress_bill is FederalCongressBill;
|
|
16
16
|
}
|
|
17
|
-
export {};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const federal_congress_bill_type_ids = ["HR", "S", "HJRES", "SJRES", "HCONRES", "SCONRES", "HRES", "SRES"];
|
|
1
|
+
export const federal_congress_bill_type_ids = ["HR", "S", "HJRES", "SJRES", "HCONRES", "SCONRES", "HRES", "SRES"];
|
|
2
2
|
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
|
}
|
|
@@ -11,7 +11,7 @@ export class FederalCongressBill {
|
|
|
11
11
|
modify_time;
|
|
12
12
|
intro_date;
|
|
13
13
|
policy_domain_id;
|
|
14
|
-
|
|
14
|
+
federal_congress_member_ids;
|
|
15
15
|
constructor(federal_congress_bill) {
|
|
16
16
|
if (!FederalCongressBill.is(federal_congress_bill)) {
|
|
17
17
|
throw Error("Invalid input.");
|
|
@@ -24,7 +24,7 @@ export class FederalCongressBill {
|
|
|
24
24
|
this.modify_time = federal_congress_bill.modify_time;
|
|
25
25
|
this.intro_date = federal_congress_bill.intro_date;
|
|
26
26
|
this.policy_domain_id = federal_congress_bill.policy_domain_id;
|
|
27
|
-
this.
|
|
27
|
+
this.federal_congress_member_ids = federal_congress_bill.federal_congress_member_ids;
|
|
28
28
|
}
|
|
29
29
|
static is(federal_congress_bill) {
|
|
30
30
|
return (federal_congress_bill !== undefined &&
|
|
@@ -36,6 +36,6 @@ export class FederalCongressBill {
|
|
|
36
36
|
typeof federal_congress_bill.modify_time === "string" &&
|
|
37
37
|
typeof federal_congress_bill.intro_date === "string" &&
|
|
38
38
|
(federal_congress_bill.policy_domain_id === undefined || typeof federal_congress_bill.policy_domain_id === "string") &&
|
|
39
|
-
(federal_congress_bill.
|
|
39
|
+
(federal_congress_bill.federal_congress_member_ids === undefined || Array.isArray(federal_congress_bill.federal_congress_member_ids) && federal_congress_bill.federal_congress_member_ids.map((federal_congress_member_id) => typeof federal_congress_member_id === "string")));
|
|
40
40
|
}
|
|
41
41
|
}
|
package/package.json
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const federal_congress_bill_type_ids = ["HR", "S", "HJRES", "SJRES", "HCONRES", "SCONRES", "HRES", "SRES"] as const
|
|
1
|
+
export const federal_congress_bill_type_ids = ["HR", "S", "HJRES", "SJRES", "HCONRES", "SCONRES", "HRES", "SRES"] as const
|
|
2
2
|
|
|
3
3
|
export type FederalCongressBillTypeID = typeof federal_congress_bill_type_ids[number]
|
|
4
4
|
|
|
@@ -15,7 +15,7 @@ export class FederalCongressBill {
|
|
|
15
15
|
readonly modify_time : string
|
|
16
16
|
readonly intro_date : string
|
|
17
17
|
readonly policy_domain_id? : string
|
|
18
|
-
readonly
|
|
18
|
+
readonly federal_congress_member_ids? : string[]
|
|
19
19
|
|
|
20
20
|
constructor(federal_congress_bill : any) {
|
|
21
21
|
if (!FederalCongressBill.is(federal_congress_bill)) {
|
|
@@ -29,7 +29,7 @@ export class FederalCongressBill {
|
|
|
29
29
|
this.modify_time = federal_congress_bill.modify_time
|
|
30
30
|
this.intro_date = federal_congress_bill.intro_date
|
|
31
31
|
this.policy_domain_id = federal_congress_bill.policy_domain_id
|
|
32
|
-
this.
|
|
32
|
+
this.federal_congress_member_ids = federal_congress_bill.federal_congress_member_ids
|
|
33
33
|
}
|
|
34
34
|
|
|
35
35
|
static is(federal_congress_bill : any) : federal_congress_bill is FederalCongressBill {
|
|
@@ -43,7 +43,7 @@ export class FederalCongressBill {
|
|
|
43
43
|
typeof federal_congress_bill.modify_time === "string" &&
|
|
44
44
|
typeof federal_congress_bill.intro_date === "string" &&
|
|
45
45
|
(federal_congress_bill.policy_domain_id === undefined || typeof federal_congress_bill.policy_domain_id === "string") &&
|
|
46
|
-
(federal_congress_bill.
|
|
46
|
+
(federal_congress_bill.federal_congress_member_ids === undefined || Array.isArray(federal_congress_bill.federal_congress_member_ids) && federal_congress_bill.federal_congress_member_ids.map((federal_congress_member_id : any) => typeof federal_congress_member_id === "string"))
|
|
47
47
|
)
|
|
48
48
|
}
|
|
49
49
|
|