@gtkx/react 0.1.48 → 0.1.50
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 +7 -12
- package/dist/codegen/jsx-generator.d.ts +12 -2
- package/dist/codegen/jsx-generator.js +40 -42
- package/dist/container-interfaces.d.ts +51 -0
- package/dist/container-interfaces.js +5 -0
- package/dist/factory.d.ts +1 -1
- package/dist/factory.js +17 -3
- package/dist/generated/internal.d.ts +7 -0
- package/dist/generated/internal.js +7818 -0
- package/dist/generated/jsx.d.ts +31 -22
- package/dist/generated/jsx.js +0 -7817
- package/dist/node.d.ts +4 -4
- package/dist/node.js +8 -7
- package/dist/nodes/about-dialog.d.ts +9 -0
- package/dist/nodes/about-dialog.js +14 -0
- package/dist/nodes/action-bar.d.ts +9 -0
- package/dist/nodes/action-bar.js +15 -0
- package/dist/nodes/column-view.d.ts +5 -4
- package/dist/nodes/column-view.js +28 -29
- package/dist/nodes/dropdown.d.ts +7 -17
- package/dist/nodes/dropdown.js +17 -10
- package/dist/nodes/flow-box.d.ts +9 -0
- package/dist/nodes/flow-box.js +25 -0
- package/dist/nodes/grid.d.ts +6 -3
- package/dist/nodes/grid.js +28 -26
- package/dist/nodes/list-box.d.ts +9 -0
- package/dist/nodes/list-box.js +21 -0
- package/dist/nodes/list.d.ts +4 -3
- package/dist/nodes/list.js +8 -7
- package/dist/nodes/notebook.d.ts +7 -3
- package/dist/nodes/notebook.js +31 -14
- package/dist/nodes/overlay.d.ts +2 -1
- package/dist/nodes/root.d.ts +2 -3
- package/dist/nodes/root.js +3 -3
- package/dist/nodes/slot.d.ts +1 -2
- package/dist/nodes/slot.js +2 -2
- package/dist/nodes/text-view.d.ts +2 -7
- package/dist/nodes/text-view.js +10 -49
- package/dist/nodes/widget.d.ts +6 -5
- package/dist/nodes/widget.js +9 -149
- package/dist/nodes/window.d.ts +11 -0
- package/dist/nodes/window.js +37 -0
- package/dist/props.d.ts +5 -0
- package/dist/props.js +10 -0
- package/dist/reconciler.d.ts +4 -1
- package/dist/reconciler.js +8 -6
- package/dist/types.d.ts +4 -4
- package/package.json +3 -3
package/dist/generated/jsx.d.ts
CHANGED
|
@@ -1861,9 +1861,9 @@ export interface DropDownProps extends WidgetProps {
|
|
|
1861
1861
|
*/
|
|
1862
1862
|
onActivate?: (self: Gtk.DropDown) => void;
|
|
1863
1863
|
/** Function to convert item to display label */
|
|
1864
|
-
itemLabel?: (item:
|
|
1864
|
+
itemLabel?: (item: unknown) => string;
|
|
1865
1865
|
/** Called when selection changes */
|
|
1866
|
-
onSelectionChanged?: (item:
|
|
1866
|
+
onSelectionChanged?: (item: unknown, index: number) => void;
|
|
1867
1867
|
ref?: Ref<Gtk.DropDown>;
|
|
1868
1868
|
}
|
|
1869
1869
|
/** Props for the {@link EditableLabel} widget. */
|
|
@@ -2917,7 +2917,7 @@ export interface GridViewProps extends ListBaseProps {
|
|
|
2917
2917
|
* Render function for list items.
|
|
2918
2918
|
* Called with null during setup (for loading state) and with the actual item during bind.
|
|
2919
2919
|
*/
|
|
2920
|
-
renderItem: (item:
|
|
2920
|
+
renderItem: (item: unknown) => import("react").ReactElement;
|
|
2921
2921
|
ref?: Ref<Gtk.GridView>;
|
|
2922
2922
|
}
|
|
2923
2923
|
/** Props for the {@link HeaderBar} widget. */
|
|
@@ -3735,7 +3735,7 @@ export interface ListViewProps extends ListBaseProps {
|
|
|
3735
3735
|
* Render function for list items.
|
|
3736
3736
|
* Called with null during setup (for loading state) and with the actual item during bind.
|
|
3737
3737
|
*/
|
|
3738
|
-
renderItem: (item:
|
|
3738
|
+
renderItem: (item: unknown) => import("react").ReactElement;
|
|
3739
3739
|
ref?: Ref<Gtk.ListView>;
|
|
3740
3740
|
}
|
|
3741
3741
|
/** Props for the {@link LockButton} widget. */
|
|
@@ -5684,10 +5684,6 @@ export interface TextViewProps extends WidgetProps {
|
|
|
5684
5684
|
* The default binding for this signal is `Insert`.
|
|
5685
5685
|
*/
|
|
5686
5686
|
onToggleOverwrite?: (self: Gtk.TextView) => void;
|
|
5687
|
-
/** The contents of the text buffer. */
|
|
5688
|
-
text?: string;
|
|
5689
|
-
/** Called when the text buffer content changes */
|
|
5690
|
-
onChanged?: (text: string) => void;
|
|
5691
5687
|
ref?: Ref<Gtk.TextView>;
|
|
5692
5688
|
}
|
|
5693
5689
|
/** Props for the {@link ToggleButton} widget. */
|
|
@@ -5929,12 +5925,6 @@ export interface WindowControlsProps extends WidgetProps {
|
|
|
5929
5925
|
export interface WindowHandleProps extends WidgetProps {
|
|
5930
5926
|
ref?: Ref<Gtk.WindowHandle>;
|
|
5931
5927
|
}
|
|
5932
|
-
export declare const CONSTRUCTOR_PARAMS: Record<string, {
|
|
5933
|
-
name: string;
|
|
5934
|
-
hasDefault: boolean;
|
|
5935
|
-
}[]>;
|
|
5936
|
-
export declare const PROP_SETTERS: Record<string, Record<string, string>>;
|
|
5937
|
-
export declare const SETTER_GETTERS: Record<string, Record<string, string>>;
|
|
5938
5928
|
/**
|
|
5939
5929
|
* The base class for all widgets.
|
|
5940
5930
|
*
|
|
@@ -7075,13 +7065,20 @@ export declare const ColorChooserWidget: "ColorChooserWidget";
|
|
|
7075
7065
|
* it gets the .color style class.
|
|
7076
7066
|
*/
|
|
7077
7067
|
export declare const ColorDialogButton: "ColorDialogButton";
|
|
7078
|
-
|
|
7079
|
-
|
|
7080
|
-
|
|
7068
|
+
/**
|
|
7069
|
+
* Props for the ColumnView.Root component with type-safe item and column rendering.
|
|
7070
|
+
* @typeParam T - The type of items in the column view.
|
|
7071
|
+
* @typeParam C - The union type of column IDs for type-safe sorting.
|
|
7072
|
+
*/
|
|
7073
|
+
interface ColumnViewRootPropsExtended<T = unknown, C extends string = string> extends ColumnViewProps, ColumnViewRootProps<T, C> {
|
|
7081
7074
|
}
|
|
7082
7075
|
declare function ColumnViewRoot<T = unknown, C extends string = string>(props: ColumnViewRootPropsExtended<T, C>): import("react").ReactElement;
|
|
7076
|
+
/**
|
|
7077
|
+
* Props for ColumnView.Column with type-safe cell rendering.
|
|
7078
|
+
* @typeParam T - The type of items passed to the renderCell function.
|
|
7079
|
+
*/
|
|
7083
7080
|
interface ColumnViewGenericColumnProps<T> extends Omit<ColumnViewColumnProps, "renderCell"> {
|
|
7084
|
-
/** Render function for column cells. Called with null during setup. */
|
|
7081
|
+
/** Render function for column cells. Called with null during setup (for loading state). */
|
|
7085
7082
|
renderCell: (item: T | null) => import("react").ReactElement;
|
|
7086
7083
|
}
|
|
7087
7084
|
declare function ColumnViewColumn<T>(props: ColumnViewGenericColumnProps<T>): import("react").ReactElement;
|
|
@@ -7497,10 +7494,14 @@ export declare const DragIcon: "DragIcon";
|
|
|
7497
7494
|
* creating your own `GtkWidget` subclass.
|
|
7498
7495
|
*/
|
|
7499
7496
|
export declare const DrawingArea: "DrawingArea";
|
|
7497
|
+
/**
|
|
7498
|
+
* Props for the DropDown.Root component with type-safe item handling.
|
|
7499
|
+
* @typeParam T - The type of items in the dropdown.
|
|
7500
|
+
*/
|
|
7500
7501
|
interface DropDownRootProps<T> extends Omit<DropDownProps, "itemLabel" | "onSelectionChanged"> {
|
|
7501
|
-
/** Function to convert item to display label */
|
|
7502
|
+
/** Function to convert an item to its display label. */
|
|
7502
7503
|
itemLabel?: (item: T) => string;
|
|
7503
|
-
/** Called when
|
|
7504
|
+
/** Called when the selected item changes. */
|
|
7504
7505
|
onSelectionChanged?: (item: T, index: number) => void;
|
|
7505
7506
|
}
|
|
7506
7507
|
declare function DropDownRoot<T>(props: DropDownRootProps<T>): import("react").ReactElement;
|
|
@@ -8523,8 +8524,12 @@ export declare const Grid: {
|
|
|
8523
8524
|
Root: "Grid.Root";
|
|
8524
8525
|
Child: "Grid.Child";
|
|
8525
8526
|
};
|
|
8527
|
+
/**
|
|
8528
|
+
* Props for the GridView.Root component with type-safe item rendering.
|
|
8529
|
+
* @typeParam T - The type of items in the list.
|
|
8530
|
+
*/
|
|
8526
8531
|
interface GridViewRootProps<T> extends Omit<GridViewProps, "renderItem"> {
|
|
8527
|
-
/** Render function for list items. Called with null during setup. */
|
|
8532
|
+
/** Render function for list items. Called with null during setup (for loading state). */
|
|
8528
8533
|
renderItem: (item: T | null) => import("react").ReactElement;
|
|
8529
8534
|
}
|
|
8530
8535
|
declare function GridViewRoot<T>(props: GridViewRootProps<T>): import("react").ReactElement;
|
|
@@ -9301,8 +9306,12 @@ export declare const ListBox: "ListBox";
|
|
|
9301
9306
|
* when necessary.
|
|
9302
9307
|
*/
|
|
9303
9308
|
export declare const ListBoxRow: "ListBoxRow";
|
|
9309
|
+
/**
|
|
9310
|
+
* Props for the ListView.Root component with type-safe item rendering.
|
|
9311
|
+
* @typeParam T - The type of items in the list.
|
|
9312
|
+
*/
|
|
9304
9313
|
interface ListViewRootProps<T> extends Omit<ListViewProps, "renderItem"> {
|
|
9305
|
-
/** Render function for list items. Called with null during setup. */
|
|
9314
|
+
/** Render function for list items. Called with null during setup (for loading state). */
|
|
9306
9315
|
renderItem: (item: T | null) => import("react").ReactElement;
|
|
9307
9316
|
}
|
|
9308
9317
|
declare function ListViewRoot<T>(props: ListViewRootProps<T>): import("react").ReactElement;
|