triangle-types 1.0.221 → 1.0.223

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,11 @@ import { YoutubeChannel } from "./YoutubeChannel.js";
2
2
  export declare class YoutubeVideo {
3
3
  readonly youtube_video_id: string;
4
4
  readonly youtube_channel_id: string;
5
- readonly publish_time: string;
5
+ readonly time: string;
6
6
  readonly title: string;
7
7
  readonly description: string;
8
8
  readonly duration?: number;
9
- readonly s3_id?: string;
9
+ readonly s3_id_json?: string;
10
10
  readonly [x: string]: any;
11
11
  constructor(youtube_video: YoutubeVideo);
12
12
  static is(youtube_video: any): youtube_video is YoutubeVideo;
@@ -2,32 +2,32 @@ import { YoutubeChannel } from "./YoutubeChannel.js";
2
2
  export class YoutubeVideo {
3
3
  youtube_video_id;
4
4
  youtube_channel_id;
5
- publish_time;
5
+ time;
6
6
  title;
7
7
  description;
8
8
  duration;
9
- s3_id;
9
+ s3_id_json;
10
10
  constructor(youtube_video) {
11
11
  if (!YoutubeVideo.is(youtube_video)) {
12
12
  throw Error("Invalid input.");
13
13
  }
14
14
  this.youtube_video_id = youtube_video.youtube_video_id;
15
15
  this.youtube_channel_id = youtube_video.youtube_channel_id;
16
- this.publish_time = youtube_video.publish_time;
16
+ this.time = youtube_video.time;
17
17
  this.title = youtube_video.title;
18
18
  this.description = youtube_video.description;
19
19
  this.duration = youtube_video.duration;
20
- this.s3_id = youtube_video.s3_id;
20
+ this.s3_id_json = youtube_video.s3_id_json;
21
21
  }
22
22
  static is(youtube_video) {
23
23
  return (youtube_video !== undefined &&
24
24
  typeof youtube_video.youtube_video_id === "string" &&
25
25
  typeof youtube_video.youtube_channel_id === "string" &&
26
- typeof youtube_video.publish_time === "string" &&
26
+ typeof youtube_video.time === "string" &&
27
27
  typeof youtube_video.title === "string" &&
28
28
  typeof youtube_video.description === "string" &&
29
29
  (youtube_video.duration === undefined || typeof youtube_video.duration === "number" && !isNaN(youtube_video.duration)) &&
30
- (youtube_video.s3_id === undefined || typeof youtube_video.s3_id === "string"));
30
+ (youtube_video.s3_id_json === undefined || typeof youtube_video.s3_id_json === "string"));
31
31
  }
32
32
  }
33
33
  export class YoutubeVideoAux extends YoutubeVideo {
@@ -2,8 +2,8 @@ import { YoutubeVideoAux } from "./YoutubeVideo.js";
2
2
  export declare class YoutubeVideoTag {
3
3
  readonly youtube_video_id: string;
4
4
  readonly tag_id: string;
5
- readonly publish_time: string;
6
- readonly relevance?: string;
5
+ readonly time: string;
6
+ readonly is_relevant?: boolean;
7
7
  readonly [x: string]: any;
8
8
  constructor(youtube_video_tag: YoutubeVideoTag);
9
9
  static is(youtube_video_tag: any): youtube_video_tag is YoutubeVideoTag;
@@ -2,23 +2,23 @@ import { YoutubeVideoAux } from "./YoutubeVideo.js";
2
2
  export class YoutubeVideoTag {
3
3
  youtube_video_id;
4
4
  tag_id;
5
- publish_time;
6
- relevance;
5
+ time;
6
+ is_relevant;
7
7
  constructor(youtube_video_tag) {
8
8
  if (!YoutubeVideoTag.is(youtube_video_tag)) {
9
9
  throw Error("Invalid input.");
10
10
  }
11
11
  this.youtube_video_id = youtube_video_tag.youtube_video_id;
12
12
  this.tag_id = youtube_video_tag.tag_id;
13
- this.publish_time = youtube_video_tag.publish_time;
14
- this.relevance = youtube_video_tag.relevance;
13
+ this.time = youtube_video_tag.time;
14
+ this.is_relevant = youtube_video_tag.is_relevant;
15
15
  }
16
16
  static is(youtube_video_tag) {
17
17
  return (youtube_video_tag !== undefined &&
18
18
  typeof youtube_video_tag.youtube_video_id === "string" &&
19
19
  typeof youtube_video_tag.tag_id === "string" &&
20
20
  typeof youtube_video_tag.publish_time === "string" &&
21
- (youtube_video_tag.relevance === undefined || typeof youtube_video_tag.relevance === "string"));
21
+ (youtube_video_tag.is_relevant === undefined || typeof youtube_video_tag.relevance === "boolean"));
22
22
  }
23
23
  }
24
24
  export class YoutubeVideoTagAux extends YoutubeVideoTag {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "triangle-types",
3
- "version": "1.0.221",
3
+ "version": "1.0.223",
4
4
  "main": "dist/src/index.js",
5
5
  "types": "dist/src/index.d.ts",
6
6
  "scripts": {
@@ -3,11 +3,11 @@ import { YoutubeChannel } from "./YoutubeChannel"
3
3
  export class YoutubeVideo {
4
4
  readonly youtube_video_id : string
5
5
  readonly youtube_channel_id : string
6
- readonly publish_time : string
6
+ readonly time : string
7
7
  readonly title : string
8
8
  readonly description : string
9
9
  readonly duration? : number
10
- readonly s3_id? : string
10
+ readonly s3_id_json? : string
11
11
  readonly [x : string] : any
12
12
 
13
13
  constructor(youtube_video : YoutubeVideo) {
@@ -16,11 +16,11 @@ export class YoutubeVideo {
16
16
  }
17
17
  this.youtube_video_id = youtube_video.youtube_video_id
18
18
  this.youtube_channel_id = youtube_video.youtube_channel_id
19
- this.publish_time = youtube_video.publish_time
19
+ this.time = youtube_video.time
20
20
  this.title = youtube_video.title
21
21
  this.description = youtube_video.description
22
22
  this.duration = youtube_video.duration
23
- this.s3_id = youtube_video.s3_id
23
+ this.s3_id_json = youtube_video.s3_id_json
24
24
  }
25
25
 
26
26
  static is(youtube_video : any) : youtube_video is YoutubeVideo {
@@ -28,11 +28,11 @@ export class YoutubeVideo {
28
28
  youtube_video !== undefined &&
29
29
  typeof youtube_video.youtube_video_id === "string" &&
30
30
  typeof youtube_video.youtube_channel_id === "string" &&
31
- typeof youtube_video.publish_time === "string" &&
31
+ typeof youtube_video.time === "string" &&
32
32
  typeof youtube_video.title === "string" &&
33
33
  typeof youtube_video.description === "string" &&
34
34
  (youtube_video.duration === undefined || typeof youtube_video.duration === "number" && !isNaN(youtube_video.duration)) &&
35
- (youtube_video.s3_id === undefined || typeof youtube_video.s3_id === "string")
35
+ (youtube_video.s3_id_json === undefined || typeof youtube_video.s3_id_json === "string")
36
36
  )
37
37
  }
38
38
  }
@@ -3,8 +3,8 @@ import { YoutubeVideoAux } from "./YoutubeVideo"
3
3
  export class YoutubeVideoTag {
4
4
  readonly youtube_video_id : string
5
5
  readonly tag_id : string
6
- readonly publish_time : string
7
- readonly relevance? : string
6
+ readonly time : string
7
+ readonly is_relevant? : boolean
8
8
  readonly [x : string] : any
9
9
 
10
10
  constructor(youtube_video_tag : YoutubeVideoTag) {
@@ -13,8 +13,8 @@ export class YoutubeVideoTag {
13
13
  }
14
14
  this.youtube_video_id = youtube_video_tag.youtube_video_id
15
15
  this.tag_id = youtube_video_tag.tag_id
16
- this.publish_time = youtube_video_tag.publish_time
17
- this.relevance = youtube_video_tag.relevance
16
+ this.time = youtube_video_tag.time
17
+ this.is_relevant = youtube_video_tag.is_relevant
18
18
  }
19
19
 
20
20
  static is(youtube_video_tag : any) : youtube_video_tag is YoutubeVideoTag {
@@ -23,7 +23,7 @@ export class YoutubeVideoTag {
23
23
  typeof youtube_video_tag.youtube_video_id === "string" &&
24
24
  typeof youtube_video_tag.tag_id === "string" &&
25
25
  typeof youtube_video_tag.publish_time === "string" &&
26
- (youtube_video_tag.relevance === undefined || typeof youtube_video_tag.relevance === "string")
26
+ (youtube_video_tag.is_relevant === undefined || typeof youtube_video_tag.relevance === "boolean")
27
27
  )
28
28
  }
29
29
  }