react-bwin 0.4.1 → 0.5.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/react-bwin.d.ts +11 -2
- package/dist/react-bwin.js +327 -290
- package/dist/react-bwin.umd.js +2 -2
- package/package.json +2 -2
package/dist/react-bwin.d.ts
CHANGED
|
@@ -3,8 +3,12 @@ declare module 'react-bwin' {
|
|
|
3
3
|
export const DEFAULT_GLASS_ACTIONS: Action[]
|
|
4
4
|
export const DEFAULT_DETACHED_GLASS_ACTIONS: Action[]
|
|
5
5
|
export const Window: React.ForwardRefExoticComponent<
|
|
6
|
-
WindowProps & React.RefAttributes<
|
|
6
|
+
WindowProps & React.RefAttributes<WindowApi>
|
|
7
7
|
>
|
|
8
|
+
export const WindowProvider: React.FunctionComponent<
|
|
9
|
+
React.PropsWithChildren<{}>
|
|
10
|
+
>
|
|
11
|
+
export function useWindow(): WindowApi
|
|
8
12
|
}
|
|
9
13
|
|
|
10
14
|
declare global {
|
|
@@ -87,13 +91,18 @@ declare global {
|
|
|
87
91
|
setTheme(theme: string): void
|
|
88
92
|
}
|
|
89
93
|
|
|
90
|
-
type
|
|
94
|
+
type WindowApi = {
|
|
91
95
|
addPane: (targetPaneId: string, fields: PaneFields) => void
|
|
92
96
|
removePane: (targetPaneId: string) => void
|
|
93
97
|
fit: () => void
|
|
94
98
|
setTheme: (theme: string) => void
|
|
95
99
|
}
|
|
96
100
|
|
|
101
|
+
/**
|
|
102
|
+
* @deprecated Use {@link WindowApi} instead.
|
|
103
|
+
*/
|
|
104
|
+
type WindowHandle = WindowApi
|
|
105
|
+
|
|
97
106
|
type WindowProps = Omit<ConfigRoot, 'children'> & {
|
|
98
107
|
panes?: ConfigNode[]
|
|
99
108
|
}
|