Compare commits
1
Commits
2f440ffaef
..
main
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
cde5a4d58f |
No files matched your search
Vendored
+12
-10
@@ -1,11 +1,13 @@
|
|||||||
import "@girs/gjs";
|
import "@girs/gjs/ambient";
|
||||||
import "@girs/gjs/dom";
|
import "@girs/gjs/dom";
|
||||||
import "@girs/gnome-shell/ambient";
|
import "@girs/glib-2.0/ambient";
|
||||||
import "@girs/gnome-shell/extensions/global";
|
import "@girs/gio-2.0/ambient";
|
||||||
|
import "@girs/gobject-2.0/ambient";
|
||||||
// Extend Meta.Window with our custom property
|
import "@girs/gtk-4.0/ambient";
|
||||||
declare namespace Meta {
|
import "@girs/gdk-4.0/ambient";
|
||||||
interface Window {
|
import "@girs/adw-1/ambient";
|
||||||
_aerospikeData?: any;
|
import "@girs/pango-1.0/ambient";
|
||||||
}
|
import "@girs/clutter-51/ambient";
|
||||||
}
|
import "@girs/st-51/ambient";
|
||||||
|
import "@girs/meta-51/ambient";
|
||||||
|
import "@girs/shell-51/ambient";
|
||||||
+2
-1
@@ -6,7 +6,8 @@
|
|||||||
"shell-version": [
|
"shell-version": [
|
||||||
"48",
|
"48",
|
||||||
"49",
|
"49",
|
||||||
"50"
|
"50",
|
||||||
|
"51"
|
||||||
],
|
],
|
||||||
"gettext-domain": "aerospike@lucaso.io",
|
"gettext-domain": "aerospike@lucaso.io",
|
||||||
"url": "https://github.com/lucasoskorep/aerospike-gnome"
|
"url": "https://github.com/lucasoskorep/aerospike-gnome"
|
||||||
|
|||||||
+20
-13
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "aerospike",
|
"name": "aerospike",
|
||||||
"version": "0.2.4",
|
"version": "0.2.5",
|
||||||
"description": "Simple, Opinionated Tiling Window Manager for Gnome written in Typescript",
|
"description": "Simple, Opinionated Tiling Window Manager for Gnome written in Typescript",
|
||||||
"packageManager": "pnpm@12.3.4",
|
"packageManager": "pnpm@12.3.4",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
@@ -26,18 +26,25 @@
|
|||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@eslint/js": "^10.0.1",
|
"@eslint/js": "^10.0.1",
|
||||||
"@girs/gjs": "^4.7.0",
|
"@girs/adw-1": "^5.5.0",
|
||||||
"@girs/gnome-shell": "^50.0.4",
|
"@girs/clutter-51": "^5.5.0",
|
||||||
"@jest/globals": "^30.5.1",
|
"@girs/gio-2.0": "^5.5.0",
|
||||||
|
"@girs/gjs": "^5.5.0",
|
||||||
|
"@girs/glib-2.0": "^5.5.0",
|
||||||
|
"@girs/gobject-2.0": "^5.5.0",
|
||||||
|
"@girs/gdk-4.0": "^5.5.0",
|
||||||
|
"@girs/gtk-4.0": "^5.5.0",
|
||||||
|
"@girs/meta-51": "^5.5.0",
|
||||||
|
"@girs/pango-1.0": "^5.5.0",
|
||||||
|
"@girs/shell-51": "^5.5.0",
|
||||||
|
"@girs/st-51": "^5.5.0",
|
||||||
|
"@jest/globals": "^30.5.2",
|
||||||
"@types/jest": "^30.0.0",
|
"@types/jest": "^30.0.0",
|
||||||
"eslint": "^10.10.0",
|
"eslint": "^10.12.0",
|
||||||
"eslint-plugin-jsdoc": "^64.3.6",
|
"eslint-plugin-jsdoc": "^65.3.4",
|
||||||
"jest": "^30.5.1",
|
"jest": "^30.5.2",
|
||||||
"ts-jest": "^29.4.12",
|
"ts-jest": "^29.4.14",
|
||||||
"typescript": "^5.9.3",
|
"typescript": "^6.0.3",
|
||||||
"typescript-eslint": "^8.69.0"
|
"typescript-eslint": "^8.71.2"
|
||||||
},
|
|
||||||
"dependencies": {
|
|
||||||
"@girs/mtk-17": "17.0.0-4.0.4"
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Generated
+726
-798
File diff suppressed because it is too large.
Load diff
@@ -1,3 +1,5 @@
|
|||||||
allowBuilds:
|
allowBuilds:
|
||||||
'@parcel/watcher': true
|
'@parcel/watcher': true
|
||||||
unrs-resolver: true
|
unrs-resolver: true
|
||||||
|
minimumReleaseAgeExclude:
|
||||||
|
- eslint-plugin-jsdoc@65.3.4
|
||||||
+3
-1
@@ -21,7 +21,9 @@ export class TabBar {
|
|||||||
this._onTabClicked = onTabClicked;
|
this._onTabClicked = onTabClicked;
|
||||||
this._bar = new St.BoxLayout({
|
this._bar = new St.BoxLayout({
|
||||||
style_class: 'aerospike-tab-bar',
|
style_class: 'aerospike-tab-bar',
|
||||||
vertical: false,
|
// `vertical` was removed from St widgets in GNOME Shell 51 (deprecated
|
||||||
|
// in 48); `orientation` is its replacement and exists in 48 and later.
|
||||||
|
orientation: Clutter.Orientation.HORIZONTAL,
|
||||||
reactive: true,
|
reactive: true,
|
||||||
can_focus: false,
|
can_focus: false,
|
||||||
track_hover: false,
|
track_hover: false,
|
||||||
|
|||||||
+3
-2
@@ -10,14 +10,15 @@
|
|||||||
"target": "ES2022",
|
"target": "ES2022",
|
||||||
"lib": [
|
"lib": [
|
||||||
"ES2022"
|
"ES2022"
|
||||||
],
|
]
|
||||||
},
|
},
|
||||||
"include": [
|
"include": [
|
||||||
"ambient.d.ts",
|
"ambient.d.ts",
|
||||||
|
"types/**/*.d.ts",
|
||||||
"prefs.ts",
|
"prefs.ts",
|
||||||
"src/**/*"
|
"src/**/*"
|
||||||
],
|
],
|
||||||
"files": [
|
"files": [
|
||||||
"extension.ts"
|
"extension.ts"
|
||||||
],
|
]
|
||||||
}
|
}
|
||||||
Vendored
+20
@@ -0,0 +1,20 @@
|
|||||||
|
/**
|
||||||
|
* GNOME Shell runtime globals.
|
||||||
|
*
|
||||||
|
* The `global` object is created by the shell before an extension is loaded and
|
||||||
|
* has no `.gir`, so it is not covered by the generated `@girs/*-51` packages.
|
||||||
|
* Upstream ships these in `@girs/gnome-shell`, but its GNOME 51 build
|
||||||
|
* (51.0.0-alpha.1) is unpublished, and v50 pulls St-18/Meta-18 types that
|
||||||
|
* collide with the -51 packages. Declaring the few symbols we use keeps the
|
||||||
|
* project on GNOME 51 types and installable from the registry.
|
||||||
|
*
|
||||||
|
* @see https://gitlab.gnome.org/GNOME/gnome-shell/-/blob/main/js/ui/environment.js
|
||||||
|
*/
|
||||||
|
import type Shell from "@girs/shell-51";
|
||||||
|
|
||||||
|
declare global {
|
||||||
|
/** Global shell object created by GNOME Shell on startup. */
|
||||||
|
const global: Shell.Global;
|
||||||
|
}
|
||||||
|
|
||||||
|
export {};
|
||||||
Vendored
+131
@@ -0,0 +1,131 @@
|
|||||||
|
/**
|
||||||
|
* Ambient declarations for the GNOME Shell JavaScript modules this extension
|
||||||
|
* imports.
|
||||||
|
*
|
||||||
|
* Shell's JavaScript API has no `.gir`, so generated `@girs/*` types do not
|
||||||
|
* cover it. Upstream maintains those types in `@girs/gnome-shell`, but its
|
||||||
|
* GNOME 51 support (51.0.0-alpha.1) is unpublished on npm, and v50 depends on
|
||||||
|
* St-18/Meta-18 types that conflict with the -51 packages this project uses.
|
||||||
|
* Only the symbols actually imported here are declared; extend as needed.
|
||||||
|
*
|
||||||
|
* @see https://gitlab.gnome.org/GNOME/gnome-shell/-/tree/main/js/ui
|
||||||
|
*/
|
||||||
|
|
||||||
|
declare module "resource:///org/gnome/shell/extensions/extension.js" {
|
||||||
|
import type Gio from "@girs/gio-2.0";
|
||||||
|
|
||||||
|
/** Parsed contents of the extension's `metadata.json`. */
|
||||||
|
export interface ExtensionMetadata {
|
||||||
|
uuid: string;
|
||||||
|
name: string;
|
||||||
|
description: string;
|
||||||
|
"shell-version"?: string[];
|
||||||
|
"settings-schema"?: string;
|
||||||
|
"gettext-domain"?: string;
|
||||||
|
url?: string;
|
||||||
|
[key: string]: unknown;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Base class for an extension's `extension.js` default export.
|
||||||
|
*
|
||||||
|
* GNOME Shell 51 requires `disable()` to stay synchronous; returning a
|
||||||
|
* promise now throws.
|
||||||
|
*/
|
||||||
|
export class Extension {
|
||||||
|
constructor(metadata: ExtensionMetadata);
|
||||||
|
|
||||||
|
readonly metadata: ExtensionMetadata;
|
||||||
|
readonly uuid: string;
|
||||||
|
readonly path: string;
|
||||||
|
|
||||||
|
/** Returns a {@link Gio.Settings} for the extension's schema. */
|
||||||
|
getSettings(schema?: string | null, subdir?: string | null): Gio.Settings;
|
||||||
|
|
||||||
|
/** Marks the extension's settings as translatable. */
|
||||||
|
translateConfig(): void;
|
||||||
|
|
||||||
|
/** Opens the extension's preferences dialog, if it has one. */
|
||||||
|
openPreferences(): void;
|
||||||
|
|
||||||
|
enable(): void;
|
||||||
|
disable(): void;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
declare module "resource:///org/gnome/Shell/Extensions/js/extensions/prefs.js" {
|
||||||
|
import type Gio from "@girs/gio-2.0";
|
||||||
|
import type Adw from "@girs/adw-1";
|
||||||
|
|
||||||
|
/** Marks a string for translation and returns the translation. */
|
||||||
|
export function gettext(str: string): string;
|
||||||
|
|
||||||
|
/** Pluralised form of {@link gettext}. */
|
||||||
|
export function ngettext(fid: string, fidPlural: string, n: number): string;
|
||||||
|
|
||||||
|
/** Context-sensitive form of {@link gettext}. */
|
||||||
|
export function pgettext(context: string, str: string): string;
|
||||||
|
|
||||||
|
/** Base class for an extension's `prefs.js` default export. */
|
||||||
|
export class ExtensionPreferences {
|
||||||
|
readonly metadata: Record<string, unknown>;
|
||||||
|
readonly uuid: string;
|
||||||
|
readonly path: string;
|
||||||
|
|
||||||
|
/** Returns a {@link Gio.Settings} for the extension's schema. */
|
||||||
|
getSettings(schema?: string | null, subdir?: string | null): Gio.Settings;
|
||||||
|
|
||||||
|
/** Marks the extension's settings as translatable. */
|
||||||
|
translateConfig(): void;
|
||||||
|
|
||||||
|
/** Called by the shell to populate the preferences window. */
|
||||||
|
fillPreferencesWindow(window: Adw.PreferencesWindow): Promise<void> | void;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
declare module "resource:///org/gnome/shell/ui/main.js" {
|
||||||
|
import type Gio from "@girs/gio-2.0";
|
||||||
|
import type Meta from "@girs/meta-51";
|
||||||
|
import type Shell from "@girs/shell-51";
|
||||||
|
import type St from "@girs/st-51";
|
||||||
|
|
||||||
|
/** Window management helpers exposed to extensions. */
|
||||||
|
export interface ShellWM {
|
||||||
|
/**
|
||||||
|
* Registers a keybinding from an extension's schema and returns its id.
|
||||||
|
*/
|
||||||
|
addKeybinding(
|
||||||
|
name: string,
|
||||||
|
settings: Gio.Settings,
|
||||||
|
flags: Meta.KeyBindingFlags,
|
||||||
|
mode: Shell.ActionMode,
|
||||||
|
handler: () => void,
|
||||||
|
): number;
|
||||||
|
|
||||||
|
/** Removes a keybinding previously added by this extension. */
|
||||||
|
removeKeybinding(name: string): boolean;
|
||||||
|
}
|
||||||
|
|
||||||
|
/** The shell's layout manager. */
|
||||||
|
export interface LayoutManager {
|
||||||
|
/** Actor holding all non-window UI. */
|
||||||
|
readonly uiGroup: St.Widget;
|
||||||
|
/** Actor holding the window group. */
|
||||||
|
readonly windowGroup: St.Widget;
|
||||||
|
readonly panelBox: St.BoxLayout;
|
||||||
|
readonly monitorManager: Meta.MonitorManager;
|
||||||
|
readonly nMonitors: number;
|
||||||
|
}
|
||||||
|
|
||||||
|
/** The overview (window overview + search). */
|
||||||
|
export interface Overview extends St.Widget {
|
||||||
|
connect(signal: "showing" | "hiding" | "show-overview", callback: () => void): number;
|
||||||
|
}
|
||||||
|
|
||||||
|
export const wm: ShellWM;
|
||||||
|
export const layoutManager: LayoutManager;
|
||||||
|
export const overview: Overview;
|
||||||
|
|
||||||
|
/** Shows a notification in the message tray. */
|
||||||
|
export function notify(message: string): void;
|
||||||
|
}
|
||||||
Reference in new issue
Block a user