@gjsify/example-dom-three-geometry-teapot 0.53.0 → 0.55.0
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/dist/browser.js +8101 -3065
- package/dist/gjs.js +31 -31
- package/dist/gjs.node.mjs +32 -32
- package/package.json +7 -7
- package/src/gjs/teapot-window.d.blp.ts +51 -0
- package/src/gjs/teapot-window.ts +5 -27
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gjsify/example-dom-three-geometry-teapot",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.55.0",
|
|
4
4
|
"description": "Three.js geometry teapot example ported from refs/three/examples/webgl_geometry_teapot.html with Adwaita controls",
|
|
5
5
|
"main": "dist/gjs.js",
|
|
6
6
|
"type": "module",
|
|
@@ -27,7 +27,7 @@
|
|
|
27
27
|
"build:assets": "gjsify copy src/browser/index.html src/browser/webgl.css src/assets dist/"
|
|
28
28
|
},
|
|
29
29
|
"dependencies": {
|
|
30
|
-
"@gjsify/webgl": "^0.
|
|
30
|
+
"@gjsify/webgl": "^0.55.0"
|
|
31
31
|
},
|
|
32
32
|
"devDependencies": {
|
|
33
33
|
"@girs/adw-1": "5.4.0",
|
|
@@ -35,12 +35,12 @@
|
|
|
35
35
|
"@girs/gjs": "5.4.0",
|
|
36
36
|
"@girs/gobject-2.0": "5.4.0",
|
|
37
37
|
"@girs/gtk-4.0": "5.4.0",
|
|
38
|
-
"@gjsify/adwaita-icons": "^0.
|
|
39
|
-
"@gjsify/adwaita-web": "^0.
|
|
40
|
-
"@gjsify/cli": "^0.
|
|
41
|
-
"@gjsify/devtools": "^0.
|
|
38
|
+
"@gjsify/adwaita-icons": "^0.55.0",
|
|
39
|
+
"@gjsify/adwaita-web": "^0.55.0",
|
|
40
|
+
"@gjsify/cli": "^0.55.0",
|
|
41
|
+
"@gjsify/devtools": "^0.55.0",
|
|
42
42
|
"@gjsify/node-gi": "file:../../../packages/node-gi/node-gi",
|
|
43
|
-
"@gjsify/vite-plugin-blueprint": "^0.
|
|
43
|
+
"@gjsify/vite-plugin-blueprint": "^0.55.0",
|
|
44
44
|
"@types/node": "^25.9.2",
|
|
45
45
|
"@types/three": "^0.185.0",
|
|
46
46
|
"http-server": "^14.1.1",
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
// GENERATED from teapot-window.blp — do not edit. ADR 0088 says what these exports mean.
|
|
2
|
+
// Regenerate with `gjsify blueprint types`; `scripts/check-blueprint-sidecars.mjs` holds it.
|
|
3
|
+
|
|
4
|
+
import type Adw from 'gi://Adw?version=1';
|
|
5
|
+
import type Gtk from 'gi://Gtk?version=4.0';
|
|
6
|
+
|
|
7
|
+
/** The GtkBuilder XML this `.blp` compiles to. */
|
|
8
|
+
declare const xml: string;
|
|
9
|
+
export default xml;
|
|
10
|
+
|
|
11
|
+
/** The class `template $TeapotWindow` defines. */
|
|
12
|
+
export declare const GTypeName: 'TeapotWindow';
|
|
13
|
+
|
|
14
|
+
/**
|
|
15
|
+
* Every id inside the template, in source order — what `registerClass` is given.
|
|
16
|
+
*
|
|
17
|
+
* A MUTABLE tuple, and the `readonly` is missing for a reason that is not ours: `@girs`
|
|
18
|
+
* declares `GObject.MetaInfo['InternalChildren']` as `string[]`, so a `readonly` tuple is
|
|
19
|
+
* refused at the call site with TS4104 and the consumer would have to spread it — the
|
|
20
|
+
* boilerplate ADR 0088 exists to remove. The tuple still pins the exact ids and arity,
|
|
21
|
+
* which is the property that matters. `status/open-todos/blueprint.md` carries the
|
|
22
|
+
* upstream half.
|
|
23
|
+
*/
|
|
24
|
+
export declare const InternalChildren: [
|
|
25
|
+
'sidebarToggleButton',
|
|
26
|
+
'pauseButton',
|
|
27
|
+
'splitView',
|
|
28
|
+
'tessRow',
|
|
29
|
+
'lidRow',
|
|
30
|
+
'bodyRow',
|
|
31
|
+
'bottomRow',
|
|
32
|
+
'fitLidRow',
|
|
33
|
+
'nonblinnRow',
|
|
34
|
+
'shadingRow',
|
|
35
|
+
'glAreaContainer',
|
|
36
|
+
];
|
|
37
|
+
|
|
38
|
+
/** The `_`-prefixed members GJS installs for them. Merge it into the class interface. */
|
|
39
|
+
export interface Children {
|
|
40
|
+
_sidebarToggleButton: Gtk.ToggleButton;
|
|
41
|
+
_pauseButton: Gtk.Button;
|
|
42
|
+
_splitView: Adw.OverlaySplitView;
|
|
43
|
+
_tessRow: Adw.ComboRow;
|
|
44
|
+
_lidRow: Adw.SwitchRow;
|
|
45
|
+
_bodyRow: Adw.SwitchRow;
|
|
46
|
+
_bottomRow: Adw.SwitchRow;
|
|
47
|
+
_fitLidRow: Adw.SwitchRow;
|
|
48
|
+
_nonblinnRow: Adw.SwitchRow;
|
|
49
|
+
_shadingRow: Adw.ComboRow;
|
|
50
|
+
_glAreaContainer: Gtk.Box;
|
|
51
|
+
}
|
package/src/gjs/teapot-window.ts
CHANGED
|
@@ -13,42 +13,20 @@ import {
|
|
|
13
13
|
DEFAULT_SHADING_INDEX,
|
|
14
14
|
type TeapotDemo,
|
|
15
15
|
} from '../three-demo.js';
|
|
16
|
-
import Template from './teapot-window.blp';
|
|
16
|
+
import Template, { type Children, GTypeName, InternalChildren } from './teapot-window.blp';
|
|
17
17
|
|
|
18
|
+
// oxlint-disable-next-line no-unsafe-declaration-merging -- intentional: GJS installs the internal children (ADR 0088)
|
|
19
|
+
export interface TeapotWindow extends Children {}
|
|
18
20
|
export class TeapotWindow extends Adw.ApplicationWindow {
|
|
19
|
-
declare private _glAreaContainer: Gtk.Box;
|
|
20
|
-
declare private _tessRow: Adw.ComboRow;
|
|
21
|
-
declare private _lidRow: Adw.SwitchRow;
|
|
22
|
-
declare private _bodyRow: Adw.SwitchRow;
|
|
23
|
-
declare private _bottomRow: Adw.SwitchRow;
|
|
24
|
-
declare private _fitLidRow: Adw.SwitchRow;
|
|
25
|
-
declare private _nonblinnRow: Adw.SwitchRow;
|
|
26
|
-
declare private _shadingRow: Adw.ComboRow;
|
|
27
|
-
declare private _splitView: Adw.OverlaySplitView;
|
|
28
|
-
declare private _sidebarToggleButton: Gtk.ToggleButton;
|
|
29
|
-
declare private _pauseButton: Gtk.Button;
|
|
30
|
-
|
|
31
21
|
/** Live demo reference; set once the WebGLBridge is ready. */
|
|
32
22
|
private _demo: TeapotDemo | null = null;
|
|
33
23
|
|
|
34
24
|
static {
|
|
35
25
|
GObject.registerClass(
|
|
36
26
|
{
|
|
37
|
-
GTypeName
|
|
27
|
+
GTypeName,
|
|
38
28
|
Template,
|
|
39
|
-
InternalChildren
|
|
40
|
-
'glAreaContainer',
|
|
41
|
-
'tessRow',
|
|
42
|
-
'lidRow',
|
|
43
|
-
'bodyRow',
|
|
44
|
-
'bottomRow',
|
|
45
|
-
'fitLidRow',
|
|
46
|
-
'nonblinnRow',
|
|
47
|
-
'shadingRow',
|
|
48
|
-
'splitView',
|
|
49
|
-
'sidebarToggleButton',
|
|
50
|
-
'pauseButton',
|
|
51
|
-
],
|
|
29
|
+
InternalChildren,
|
|
52
30
|
},
|
|
53
31
|
this,
|
|
54
32
|
);
|