From 58fa1ab9be7ee8fd4a8e96865121a54d613978cc Mon Sep 17 00:00:00 2001 From: Aylur Date: Sat, 25 May 2024 14:44:50 +0200 Subject: separate node and gjs into its own package --- gjs/src/widgets.ts | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) create mode 100644 gjs/src/widgets.ts (limited to 'gjs/src/widgets.ts') diff --git a/gjs/src/widgets.ts b/gjs/src/widgets.ts new file mode 100644 index 0000000..abfbba8 --- /dev/null +++ b/gjs/src/widgets.ts @@ -0,0 +1,36 @@ +/* eslint-disable max-len */ +import Gtk from "gi://Gtk" +import Astal from "gi://Astal" +import astalify, { type ConstructProps, type Widget } from "./astalify.js" + +export { astalify } + +// Label +export const Label = astalify(Gtk.Label) +export type LabelProps = ConstructProps + +// Icon +export const Icon = astalify(Astal.Icon) +export type IconProps = ConstructProps + +// Button +export const Button = astalify(Astal.Button) +export type ButtonProps = ConstructProps) => void +}> + +// Window +export const Window = astalify(Astal.Window) +export type WindowProps = ConstructProps + +// Box +export const Box = astalify(Astal.Box) +export type BoxProps = ConstructProps + +// CenterBox +export const CenterBox = astalify(Astal.CenterBox) +export type CenterBoxProps = ConstructProps + +// EventBox +export const EventBox = astalify(Astal.EventBox) +export type EventBoxProps = ConstructProps -- cgit v1.2.3