@girs/mtk-13 13.0.0-3.2.9 → 13.0.0-4.0.0-beta.1

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/README.md CHANGED
@@ -5,7 +5,7 @@
5
5
  ![downloads/week](https://img.shields.io/npm/dw/@girs/mtk-13)
6
6
 
7
7
 
8
- GJS TypeScript type definitions for Mtk-13, generated from library version 13.0.0 using [ts-for-gir](https://github.com/gjsify/ts-for-gir) v3.2.9.
8
+ GJS TypeScript type definitions for Mtk-13, generated from library version 13.0.0 using [ts-for-gir](https://github.com/gjsify/ts-for-gir) v4.0.0-beta.1.
9
9
 
10
10
 
11
11
  ## Install
@@ -1,12 +1,8 @@
1
1
 
2
2
  declare module 'gi://Mtk?version=13' {
3
- import Mtk13 from '@girs/mtk-13';
4
- export default Mtk13;
3
+ import Mtk from '@girs/mtk-13';
4
+ export default Mtk;
5
5
  }
6
6
 
7
- declare module 'gi://Mtk' {
8
- import Mtk13 from '@girs/mtk-13';
9
- export default Mtk13;
10
- }
11
7
 
12
8
 
@@ -1,12 +1,2 @@
1
-
2
- import Mtk13 from '@girs/mtk-13';
3
-
4
- declare global {
5
- export interface GjsGiImports {
6
- Mtk: typeof Mtk13;
7
- }
8
- }
9
-
10
- export default GjsGiImports;
11
-
1
+ // Module import type definition not generated, otherwise this would cause a type conflict, this is because several GIR modules were generated with the same namespace: "Mtk"
12
2
 
package/mtk-13.d.ts CHANGED
@@ -1,4 +1,3 @@
1
-
2
1
  /*
3
2
  * Type Definitions for Gjs (https://gjs.guide/)
4
3
  *
@@ -7,7 +6,9 @@
7
6
  */
8
7
 
9
8
  import './mtk-13-ambient.d.ts';
9
+
10
10
  import './mtk-13-import.d.ts';
11
+
11
12
  /**
12
13
  * Mtk-13
13
14
  */
@@ -18,125 +19,98 @@ import type GLib from '@girs/glib-2.0';
18
19
  import type Graphene from '@girs/graphene-1.0';
19
20
 
20
21
  export namespace Mtk {
21
-
22
- enum RoundingStrategy {
23
- SHRINK,
24
- GROW,
25
- ROUND,
26
- }
27
- function rectangle_from_graphene_rect(rect: Graphene.Rect, rounding_strategy: RoundingStrategy): /* dest */ Rectangle
28
- function x11_errors_deinit(): void
29
- interface Rectangle {
30
-
31
- // Own fields of Mtk-13.Mtk.Rectangle
32
-
33
- /**
34
- * X coordinate of the top-left corner
35
- * @field
36
- */
37
- x: number
38
- /**
39
- * Y coordinate of the top-left corner
40
- * @field
41
- */
42
- y: number
43
- /**
44
- * Width of the rectangle
45
- * @field
46
- */
47
- width: number
48
- /**
49
- * Height of the rectangle
50
- * @field
51
- */
52
- height: number
53
-
54
- // Owm methods of Mtk-13.Mtk.Rectangle
55
-
56
- area(): number
57
- contains_rect(inner_rect: Rectangle): boolean
58
- copy(): Rectangle
59
- could_fit_rect(inner_rect: Rectangle): boolean
60
- /**
61
- * Compares the two rectangles
62
- * @param src2 The second rectangle
63
- * @returns Whether the two rectangles are equal
64
- */
65
- equal(src2: Rectangle): boolean
66
- free(): void
67
- /**
68
- * Similar to [method`Rectangle`.overlap] but ignores the vertical location.
69
- * @param rect2 The second rectangle
70
- * @returns Whether the two rectangles overlap horizontally
71
- */
72
- horiz_overlap(rect2: Rectangle): boolean
73
- /**
74
- * Find the intersection between the two rectangles
75
- * @param src2 another #MtkRectangle
76
- * @returns TRUE is some intersection exists and is not degenerate, FALSE otherwise.
77
- */
78
- intersect(src2: Rectangle): [ /* returnType */ boolean, /* dest */ Rectangle ]
79
- /**
80
- * Similar to [method`Rectangle`.intersect] but doesn't provide
81
- * the location of the intersection.
82
- * @param rect2 The second rectangle
83
- * @returns Whether the two rectangles overlap
84
- */
85
- overlap(rect2: Rectangle): boolean
86
- to_graphene_rect(): Graphene.Rect
87
- /**
88
- * Computes the union of the two rectangles
89
- * @param rect2 another #MtkRectangle
90
- */
91
- union(rect2: Rectangle): /* dest */ Rectangle
92
- /**
93
- * Similar to [method`Rectangle`.overlap] but ignores the horizontal location.
94
- * @param rect2 The second rectangle
95
- * @returns Whether the two rectangles overlap vertically
96
- */
97
- vert_overlap(rect2: Rectangle): boolean
98
- }
99
-
100
- class Rectangle {
101
-
102
- // Own properties of Mtk-13.Mtk.Rectangle
103
-
104
- static name: string
105
-
106
- // Constructors of Mtk-13.Mtk.Rectangle
22
+ enum RoundingStrategy {
23
+ SHRINK,
24
+ GROW,
25
+ ROUND,
26
+ }
27
+ function rectangle_from_graphene_rect(rect: Graphene.Rect, rounding_strategy: RoundingStrategy): Rectangle;
28
+ function x11_errors_deinit(): void;
29
+ class Rectangle {
30
+ static $gtype: GObject.GType<Rectangle>;
31
+
32
+ // Own fields of Mtk.Rectangle
33
+
34
+ x: number;
35
+ y: number;
36
+ width: number;
37
+ height: number;
38
+
39
+ // Constructors of Mtk.Rectangle
40
+
41
+ constructor(
42
+ properties?: Partial<{
43
+ x: number;
44
+ y: number;
45
+ width: number;
46
+ height: number;
47
+ }>,
48
+ );
49
+ _init(...args: any[]): void;
50
+
51
+ static ['new'](x: number, y: number, width: number, height: number): Rectangle;
52
+
53
+ // Own static methods of Mtk.Rectangle
54
+
55
+ static from_graphene_rect(rect: Graphene.Rect, rounding_strategy: RoundingStrategy): Rectangle;
56
+
57
+ // Own methods of Mtk.Rectangle
58
+
59
+ area(): number;
60
+ contains_rect(inner_rect: Rectangle): boolean;
61
+ copy(): Rectangle;
62
+ could_fit_rect(inner_rect: Rectangle): boolean;
63
+ /**
64
+ * Compares the two rectangles
65
+ * @param src2 The second rectangle
66
+ * @returns Whether the two rectangles are equal
67
+ */
68
+ equal(src2: Rectangle): boolean;
69
+ free(): void;
70
+ /**
71
+ * Similar to [method`Rectangle`.overlap] but ignores the vertical location.
72
+ * @param rect2 The second rectangle
73
+ * @returns Whether the two rectangles overlap horizontally
74
+ */
75
+ horiz_overlap(rect2: Rectangle): boolean;
76
+ /**
77
+ * Find the intersection between the two rectangles
78
+ * @param src2 another #MtkRectangle
79
+ * @returns TRUE is some intersection exists and is not degenerate, FALSE otherwise.
80
+ */
81
+ intersect(src2: Rectangle): [boolean, Rectangle];
82
+ /**
83
+ * Similar to [method`Rectangle`.intersect] but doesn't provide
84
+ * the location of the intersection.
85
+ * @param rect2 The second rectangle
86
+ * @returns Whether the two rectangles overlap
87
+ */
88
+ overlap(rect2: Rectangle): boolean;
89
+ to_graphene_rect(): Graphene.Rect;
90
+ /**
91
+ * Computes the union of the two rectangles
92
+ * @param rect2 another #MtkRectangle
93
+ */
94
+ union(rect2: Rectangle): Rectangle;
95
+ /**
96
+ * Similar to [method`Rectangle`.overlap] but ignores the horizontal location.
97
+ * @param rect2 The second rectangle
98
+ * @returns Whether the two rectangles overlap vertically
99
+ */
100
+ vert_overlap(rect2: Rectangle): boolean;
101
+ }
107
102
 
108
103
  /**
109
- * Creates a new rectangle
110
- * @constructor
111
- * @param x X coordinate of the top left corner
112
- * @param y Y coordinate of the top left corner
113
- * @param width Width of the rectangle
114
- * @param height Height of the rectangle
104
+ * Name of the imported GIR library
105
+ * `see` https://gitlab.gnome.org/GNOME/gjs/-/blob/master/gi/ns.cpp#L188
115
106
  */
116
- constructor(x: number, y: number, width: number, height: number)
107
+ const __name__: string;
117
108
  /**
118
- * Creates a new rectangle
119
- * @constructor
120
- * @param x X coordinate of the top left corner
121
- * @param y Y coordinate of the top left corner
122
- * @param width Width of the rectangle
123
- * @param height Height of the rectangle
109
+ * Version of the imported GIR library
110
+ * `see` https://gitlab.gnome.org/GNOME/gjs/-/blob/master/gi/ns.cpp#L189
124
111
  */
125
- static new(x: number, y: number, width: number, height: number): Rectangle
126
- static from_graphene_rect(rect: Graphene.Rect, rounding_strategy: RoundingStrategy): /* dest */ Rectangle
127
- }
128
-
129
- /**
130
- * Name of the imported GIR library
131
- * @see https://gitlab.gnome.org/GNOME/gjs/-/blob/master/gi/ns.cpp#L188
132
- */
133
- const __name__: string
134
- /**
135
- * Version of the imported GIR library
136
- * @see https://gitlab.gnome.org/GNOME/gjs/-/blob/master/gi/ns.cpp#L189
137
- */
138
- const __version__: string
112
+ const __version__: string;
139
113
  }
140
114
 
141
115
  export default Mtk;
142
- // END
116
+ // END
package/mtk-13.js CHANGED
@@ -1,10 +1,6 @@
1
1
 
2
-
3
2
  // @ts-expect-error
4
3
  import Mtk from 'gi://Mtk?version=13';
5
4
  export { Mtk };
6
5
  export default Mtk;
7
6
 
8
-
9
-
10
-
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@girs/mtk-13",
3
- "version": "13.0.0-3.2.9",
3
+ "version": "13.0.0-4.0.0-beta.1",
4
4
  "description": "GJS TypeScript type definitions for Mtk-13, generated from library version 13.0.0",
5
5
  "type": "module",
6
6
  "module": "mtk-13.js",
@@ -8,34 +8,29 @@
8
8
  "exports": {
9
9
  "./ambient": {
10
10
  "types": "./mtk-13-ambient.d.ts",
11
+ "import": "./mtk-13-ambient.js",
11
12
  "default": "./mtk-13-ambient.js"
12
13
  },
13
14
  "./import": {
14
15
  "types": "./mtk-13-import.d.ts",
16
+ "import": "./mtk-13-import.js",
15
17
  "default": "./mtk-13-import.js"
16
18
  },
17
19
  ".": {
18
- "import": {
19
- "types": "./mtk-13.d.ts",
20
- "default": "./mtk-13.js"
21
- },
22
- "require": {
23
- "types": "./mtk-13.d.cts",
24
- "default": "./mtk-13.cjs"
25
- }
20
+ "types": "./mtk-13.d.ts",
21
+ "import": "./mtk-13.js",
22
+ "default": "./mtk-13.js"
26
23
  }
27
24
  },
28
25
  "scripts": {
29
- "test": "yarn test:esm && yarn test:cjs",
30
- "test:esm": "NODE_OPTIONS=--max_old_space_size=9216 tsc --noEmit mtk-13.d.ts",
31
- "test:cjs": "NODE_OPTIONS=--max_old_space_size=9216 tsc --noEmit mtk-13.d.cts"
26
+ "test": "NODE_OPTIONS=--max_old_space_size=9216 tsc --noEmit mtk-13.d.ts"
32
27
  },
33
28
  "dependencies": {
34
- "@girs/cairo-1.0": "^1.0.0-3.2.9",
35
- "@girs/gjs": "^3.2.9",
36
- "@girs/glib-2.0": "^2.78.0-3.2.9",
37
- "@girs/gobject-2.0": "^2.78.0-3.2.9",
38
- "@girs/graphene-1.0": "^1.0.0-3.2.9"
29
+ "@girs/cairo-1.0": "^1.0.0-4.0.0-beta.1",
30
+ "@girs/gjs": "^4.0.0-beta.1",
31
+ "@girs/glib-2.0": "^2.77.0-4.0.0-beta.1",
32
+ "@girs/gobject-2.0": "^2.77.0-4.0.0-beta.1",
33
+ "@girs/graphene-1.0": "^1.0.0-4.0.0-beta.1"
39
34
  },
40
35
  "devDependencies": {
41
36
  "typescript": "*"
package/mtk-13.cjs DELETED
@@ -1,11 +0,0 @@
1
-
2
-
3
- imports.gi.versions.Mtk = '13'
4
- const Mtk = imports.gi.Mtk;
5
-
6
- module.exports = Mtk;
7
-
8
-
9
-
10
-
11
-
package/mtk-13.d.cts DELETED
@@ -1,137 +0,0 @@
1
-
2
- /*
3
- * Type Definitions for Gjs (https://gjs.guide/)
4
- *
5
- * These type definitions are automatically generated, do not edit them by hand.
6
- * If you found a bug fix it in `ts-for-gir` or create a bug report on https://github.com/gjsify/ts-for-gir
7
- */
8
-
9
- import './mtk-13-ambient.d.ts';
10
- import './mtk-13-import.d.ts';
11
- /**
12
- * Mtk-13
13
- */
14
-
15
- import type cairo from '@girs/cairo-1.0';
16
- import type GObject from '@girs/gobject-2.0';
17
- import type GLib from '@girs/glib-2.0';
18
- import type Graphene from '@girs/graphene-1.0';
19
-
20
- export enum RoundingStrategy {
21
- SHRINK,
22
- GROW,
23
- ROUND,
24
- }
25
- export function rectangle_from_graphene_rect(rect: Graphene.Rect, rounding_strategy: RoundingStrategy): /* dest */ Rectangle
26
- export function x11_errors_deinit(): void
27
- export interface Rectangle {
28
-
29
- // Own fields of Mtk-13.Mtk.Rectangle
30
-
31
- /**
32
- * X coordinate of the top-left corner
33
- * @field
34
- */
35
- x: number
36
- /**
37
- * Y coordinate of the top-left corner
38
- * @field
39
- */
40
- y: number
41
- /**
42
- * Width of the rectangle
43
- * @field
44
- */
45
- width: number
46
- /**
47
- * Height of the rectangle
48
- * @field
49
- */
50
- height: number
51
-
52
- // Owm methods of Mtk-13.Mtk.Rectangle
53
-
54
- area(): number
55
- contains_rect(inner_rect: Rectangle): boolean
56
- copy(): Rectangle
57
- could_fit_rect(inner_rect: Rectangle): boolean
58
- /**
59
- * Compares the two rectangles
60
- * @param src2 The second rectangle
61
- * @returns Whether the two rectangles are equal
62
- */
63
- equal(src2: Rectangle): boolean
64
- free(): void
65
- /**
66
- * Similar to [method`Rectangle`.overlap] but ignores the vertical location.
67
- * @param rect2 The second rectangle
68
- * @returns Whether the two rectangles overlap horizontally
69
- */
70
- horiz_overlap(rect2: Rectangle): boolean
71
- /**
72
- * Find the intersection between the two rectangles
73
- * @param src2 another #MtkRectangle
74
- * @returns TRUE is some intersection exists and is not degenerate, FALSE otherwise.
75
- */
76
- intersect(src2: Rectangle): [ /* returnType */ boolean, /* dest */ Rectangle ]
77
- /**
78
- * Similar to [method`Rectangle`.intersect] but doesn't provide
79
- * the location of the intersection.
80
- * @param rect2 The second rectangle
81
- * @returns Whether the two rectangles overlap
82
- */
83
- overlap(rect2: Rectangle): boolean
84
- to_graphene_rect(): Graphene.Rect
85
- /**
86
- * Computes the union of the two rectangles
87
- * @param rect2 another #MtkRectangle
88
- */
89
- union(rect2: Rectangle): /* dest */ Rectangle
90
- /**
91
- * Similar to [method`Rectangle`.overlap] but ignores the horizontal location.
92
- * @param rect2 The second rectangle
93
- * @returns Whether the two rectangles overlap vertically
94
- */
95
- vert_overlap(rect2: Rectangle): boolean
96
- }
97
-
98
- export class Rectangle {
99
-
100
- // Own properties of Mtk-13.Mtk.Rectangle
101
-
102
- static name: string
103
-
104
- // Constructors of Mtk-13.Mtk.Rectangle
105
-
106
- /**
107
- * Creates a new rectangle
108
- * @constructor
109
- * @param x X coordinate of the top left corner
110
- * @param y Y coordinate of the top left corner
111
- * @param width Width of the rectangle
112
- * @param height Height of the rectangle
113
- */
114
- constructor(x: number, y: number, width: number, height: number)
115
- /**
116
- * Creates a new rectangle
117
- * @constructor
118
- * @param x X coordinate of the top left corner
119
- * @param y Y coordinate of the top left corner
120
- * @param width Width of the rectangle
121
- * @param height Height of the rectangle
122
- */
123
- static new(x: number, y: number, width: number, height: number): Rectangle
124
- static from_graphene_rect(rect: Graphene.Rect, rounding_strategy: RoundingStrategy): /* dest */ Rectangle
125
- }
126
-
127
- /**
128
- * Name of the imported GIR library
129
- * @see https://gitlab.gnome.org/GNOME/gjs/-/blob/master/gi/ns.cpp#L188
130
- */
131
- export const __name__: string
132
- /**
133
- * Version of the imported GIR library
134
- * @see https://gitlab.gnome.org/GNOME/gjs/-/blob/master/gi/ns.cpp#L189
135
- */
136
- export const __version__: string
137
- // END