@brickset-api/types 0.0.7 → 0.0.8

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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # @brickset-api/types
2
2
 
3
+ ## 0.0.8
4
+
5
+ ### Patch Changes
6
+
7
+ - 8974e13: Update types
8
+
3
9
  ## 0.0.7
4
10
 
5
11
  ### Patch Changes
package/data/get-sets.ts CHANGED
@@ -1,5 +1,7 @@
1
1
  export type GetSets = GetSets_Response;
2
2
 
3
+ export type Item = ItemBase;
4
+
3
5
  export type GetSetsOptions = {
4
6
  setID?: number;
5
7
  query?: {
@@ -25,10 +27,10 @@ interface GetSets_Response {
25
27
  message?: string;
26
28
  status: string;
27
29
  matches?: number;
28
- sets?: GetSets_Base[];
30
+ sets?: ItemBase[];
29
31
  }
30
32
 
31
- interface GetSets_Base {
33
+ interface ItemBase {
32
34
  setID: number;
33
35
  number: string;
34
36
  numberVariant: string;
@@ -41,37 +43,15 @@ interface GetSets_Base {
41
43
  released: boolean;
42
44
  pieces: number;
43
45
  minifigs: number;
44
- image: {
45
- thumbnailURL: string;
46
- imageURL: string;
47
- };
46
+ image: Image;
48
47
  bricksetURL: string;
49
- collection: {}
50
- collections: {
51
- ownedBy: number;
52
- wantedBy: number;
53
- };
48
+ collection: Collection;
49
+ collections: Collections;
54
50
  LEGOCom: {
55
- US: {
56
- retailPrice: number;
57
- dateFirstAvailable: string;
58
- dateLastAvailable: string;
59
- };
60
- UK: {
61
- retailPrice: number;
62
- dateFirstAvailable: string;
63
- dateLastAvailable: string;
64
- };
65
- CA: {
66
- retailPrice: number;
67
- dateFirstAvailable: string;
68
- dateLastAvailable: string;
69
- };
70
- DE: {
71
- retailPrice: number;
72
- dateFirstAvailable: string;
73
- dateLastAvailable: string;
74
- };
51
+ US: LEGOComDetails;
52
+ UK: LEGOComDetails;
53
+ CA: LEGOComDetails;
54
+ DE: LEGOComDetails;
75
55
  };
76
56
  rating: number;
77
57
  reviewCount: number;
@@ -79,20 +59,56 @@ interface GetSets_Base {
79
59
  availability: string;
80
60
  instructionsCount: number;
81
61
  additionalImageCount: number;
82
- ageRange: {
83
- min: number;
84
- max: number;
85
- };
86
- dimensions: {
87
- height: number;
88
- width: number;
89
- depth: number;
90
- weight: number;
91
- };
92
- barcodes: {
93
- EAN: string;
94
- UPC: string;
95
- };
96
- extendedData: {};
62
+ ageRange: AgeRange;
63
+ dimensions: Dimensions;
64
+ barcodes: Barcodes;
65
+ extendedData: ExtendedData;
97
66
  lastUpdated: string;
98
67
  }
68
+
69
+ interface LEGOComDetails {
70
+ retailPrice?: number;
71
+ dateFirstAvailable?: string;
72
+ dateLastAvailable?: string;
73
+ }
74
+
75
+ interface Dimensions {
76
+ height?: number;
77
+ width?: number;
78
+ depth?: number;
79
+ weight?: number;
80
+ }
81
+
82
+ interface ExtendedData {
83
+ notes: string;
84
+ tags: string[];
85
+ description: string;
86
+ }
87
+
88
+ interface Collection {
89
+ owned?: boolean;
90
+ wanted?: boolean;
91
+ qtyOwned?: number;
92
+ rating?: number;
93
+ notes: string;
94
+ }
95
+
96
+ interface Collections {
97
+ ownedBy?: number;
98
+ wantedBy?: number;
99
+ }
100
+
101
+ interface Barcodes {
102
+ EAN: string;
103
+ UPC: string;
104
+ }
105
+
106
+ interface AgeRange {
107
+ min?: number;
108
+ max?: number;
109
+ }
110
+
111
+ interface Image {
112
+ thumbnailURL: string;
113
+ imageURL: string;
114
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@brickset-api/types",
3
- "version": "0.0.7",
3
+ "version": "0.0.8",
4
4
  "description": "TypeScript types for all datastructures used by the Brickset API",
5
5
  "license": "MIT",
6
6
  "repository": {