diff --git a/astal b/astal deleted file mode 120000 index ded1b32..0000000 --- a/astal +++ /dev/null @@ -1 +0,0 @@ -/usr/share/astal/gjs \ No newline at end of file diff --git a/src/components/bar/index.tsx b/src/components/bar/index.tsx index 9439727..aed8c48 100644 --- a/src/components/bar/index.tsx +++ b/src/components/bar/index.tsx @@ -28,7 +28,7 @@ import { import { WidgetContainer } from './shared/WidgetContainer'; import options from 'src/options'; -import { App, Gtk } from 'astal/gtk3/index'; +import { App, Gtk } from 'astal/gtk3'; import Astal from 'gi://Astal?version=3.0'; import { bind, Variable } from 'astal'; diff --git a/src/components/bar/modules/battery/index.tsx b/src/components/bar/modules/battery/index.tsx index 202d2fb..6ceabc1 100644 --- a/src/components/bar/modules/battery/index.tsx +++ b/src/components/bar/modules/battery/index.tsx @@ -5,7 +5,7 @@ import options from 'src/options'; import { BarBoxChild } from 'src/lib/types/bar.js'; import { runAsyncCommand, throttledScrollHandler } from 'src/components/bar/utils/helpers.js'; import Variable from 'astal/variable'; -import { bind } from 'astal/binding.js'; +import { bind } from 'astal'; import AstalBattery from 'gi://AstalBattery?version=0.1'; import { onMiddleClick, onPrimaryClick, onScroll, onSecondaryClick } from 'src/lib/shared/eventHandlers'; import { getBatteryIcon } from './helpers'; diff --git a/src/components/bar/modules/bluetooth/index.tsx b/src/components/bar/modules/bluetooth/index.tsx index a1287a6..473bddc 100644 --- a/src/components/bar/modules/bluetooth/index.tsx +++ b/src/components/bar/modules/bluetooth/index.tsx @@ -3,8 +3,7 @@ import options from 'src/options.js'; import { openMenu } from '../../utils/menu.js'; import { BarBoxChild } from 'src/lib/types/bar.js'; import { runAsyncCommand, throttledScrollHandler } from 'src/components/bar/utils/helpers.js'; -import { bind } from 'astal/binding.js'; -import Variable from 'astal/variable.js'; +import { Variable, bind } from 'astal'; import { onMiddleClick, onPrimaryClick, onScroll, onSecondaryClick } from 'src/lib/shared/eventHandlers.js'; import AstalBluetooth from 'gi://AstalBluetooth?version=0.1'; import { Astal } from 'astal/gtk3'; diff --git a/src/components/bar/modules/media/index.tsx b/src/components/bar/modules/media/index.tsx index 09fdfc9..7744943 100644 --- a/src/components/bar/modules/media/index.tsx +++ b/src/components/bar/modules/media/index.tsx @@ -3,9 +3,8 @@ import options from 'src/options.js'; import { runAsyncCommand, throttledScrollHandler } from 'src/components/bar/utils/helpers.js'; import { generateMediaLabel } from './helpers/index.js'; import { mprisService } from 'src/lib/constants/services.js'; -import Variable from 'astal/variable.js'; import { onMiddleClick, onPrimaryClick, onScroll, onSecondaryClick } from 'src/lib/shared/eventHandlers.js'; -import { bind } from 'astal/binding.js'; +import { bind, Variable } from 'astal'; import { BarBoxChild } from 'src/lib/types/bar.js'; import { Astal } from 'astal/gtk3'; import { activePlayer, mediaAlbum, mediaArtist, mediaTitle } from 'src/globals/media.js'; diff --git a/src/components/bar/modules/menu/index.tsx b/src/components/bar/modules/menu/index.tsx index 1278d51..5870579 100644 --- a/src/components/bar/modules/menu/index.tsx +++ b/src/components/bar/modules/menu/index.tsx @@ -2,8 +2,7 @@ import { runAsyncCommand, throttledScrollHandler } from '../../utils/helpers.js' import options from '../../../../options.js'; import { openMenu } from '../../utils/menu.js'; import { getDistroIcon } from '../../../../lib/utils.js'; -import { bind } from 'astal/binding.js'; -import Variable from 'astal/variable.js'; +import { Variable, bind } from 'astal'; import { onMiddleClick, onPrimaryClick, onScroll, onSecondaryClick } from 'src/lib/shared/eventHandlers.js'; import { BarBoxChild } from 'src/lib/types/bar.js'; import { Astal } from 'astal/gtk3'; diff --git a/src/components/bar/modules/systray/index.tsx b/src/components/bar/modules/systray/index.tsx index 2343f6d..f25e141 100644 --- a/src/components/bar/modules/systray/index.tsx +++ b/src/components/bar/modules/systray/index.tsx @@ -4,7 +4,6 @@ import AstalTray from 'gi://AstalTray?version=0.1'; import { bind, Gio, Variable } from 'astal'; import { BarBoxChild } from 'src/lib/types/bar'; import { Gdk, Gtk } from 'astal/gtk3'; -import { BindableChild } from 'astal/gtk3/astalify'; const systemtray = AstalTray.get_default(); const { ignore, customIcons } = options.bar.systray; @@ -137,7 +136,7 @@ interface MenuCustomIconProps { interface MenuEntryProps { item: AstalTray.TrayItem; - child?: BindableChild; + child?: JSX.Element; } export { SysTray }; diff --git a/src/components/bar/modules/volume/index.tsx b/src/components/bar/modules/volume/index.tsx index 96a8dad..db4a034 100644 --- a/src/components/bar/modules/volume/index.tsx +++ b/src/components/bar/modules/volume/index.tsx @@ -2,8 +2,7 @@ import { audioService } from 'src/lib/constants/services.js'; import { openMenu } from '../../utils/menu.js'; import options from 'src/options'; import { runAsyncCommand, throttledScrollHandler } from 'src/components/bar/utils/helpers.js'; -import Variable from 'astal/variable.js'; -import { bind } from 'astal/binding.js'; +import { bind, Variable } from 'astal'; import { onMiddleClick, onPrimaryClick, onScroll, onSecondaryClick } from 'src/lib/shared/eventHandlers.js'; import { getIcon } from './helpers/index.js'; import { BarBoxChild } from 'src/lib/types/bar.js'; diff --git a/src/components/bar/modules/workspaces/helpers/index.ts b/src/components/bar/modules/workspaces/helpers/index.ts index 5a3bc05..1e746ca 100644 --- a/src/components/bar/modules/workspaces/helpers/index.ts +++ b/src/components/bar/modules/workspaces/helpers/index.ts @@ -169,21 +169,14 @@ function isWorkspaceIgnored(ignoredWorkspacesVariable: Variable, workspa * @param onlyActiveWorkspaces - Whether to only include active (occupied) workspaces when navigating. * @param ignoredWorkspacesVariable - A Variable that contains the ignored workspaces pattern. */ -function navigateWorkspace( - direction: 'next' | 'prev', - currentMonitorWorkspacesVariable: Variable, - onlyActiveWorkspaces: boolean, - ignoredWorkspacesVariable: Variable, -): void { +function navigateWorkspace(direction: 'next' | 'prev', ignoredWorkspacesVariable: Variable): void { const allHyprlandWorkspaces = hyprlandService.get_workspaces() || []; const activeWorkspaceIds = allHyprlandWorkspaces .filter((workspaceInstance) => hyprlandService.focusedMonitor.id === workspaceInstance.monitor?.id) .map((workspaceInstance) => workspaceInstance.id); - const assignedOrOccupiedWorkspaces = onlyActiveWorkspaces - ? activeWorkspaceIds - : currentMonitorWorkspacesVariable.get() || Array.from({ length: workspaces.get() }, (_, index) => index + 1); + const assignedOrOccupiedWorkspaces = activeWorkspaceIds.sort((a, b) => a - b); if (assignedOrOccupiedWorkspaces.length === 0) { return; @@ -213,12 +206,8 @@ function navigateWorkspace( * @param onlyActiveWorkspaces - Whether to only navigate among active (occupied) workspaces. * @param ignoredWorkspacesVariable - A Variable that contains the ignored workspaces pattern. */ -export function goToNextWorkspace( - currentMonitorWorkspacesVariable: Variable, - onlyActiveWorkspaces: boolean, - ignoredWorkspacesVariable: Variable, -): void { - navigateWorkspace('next', currentMonitorWorkspacesVariable, onlyActiveWorkspaces, ignoredWorkspacesVariable); +export function goToNextWorkspace(ignoredWorkspacesVariable: Variable): void { + navigateWorkspace('next', ignoredWorkspacesVariable); } /** @@ -228,12 +217,8 @@ export function goToNextWorkspace( * @param onlyActiveWorkspaces - Whether to only navigate among active (occupied) workspaces. * @param ignoredWorkspacesVariable - A Variable that contains the ignored workspaces pattern. */ -export function goToPreviousWorkspace( - currentMonitorWorkspacesVariable: Variable, - onlyActiveWorkspaces: boolean, - ignoredWorkspacesVariable: Variable, -): void { - navigateWorkspace('prev', currentMonitorWorkspacesVariable, onlyActiveWorkspaces, ignoredWorkspacesVariable); +export function goToPreviousWorkspace(ignoredWorkspacesVariable: Variable): void { + navigateWorkspace('prev', ignoredWorkspacesVariable); } /** @@ -263,29 +248,24 @@ export function throttle void>(func: T, limit: * Creates throttled scroll handlers that navigate workspaces upon scrolling, respecting the configured scroll speed. * * @param scrollSpeed - The factor by which the scroll navigation is throttled. - * @param currentMonitorWorkspacesVariable - A Variable containing the current monitor's workspace numbers. * @param onlyActiveWorkspaces - Whether to only navigate among active (occupied) workspaces. * * @returns An object containing two functions (`throttledScrollUp` and `throttledScrollDown`), both throttled. */ -export function initThrottledScrollHandlers( - scrollSpeed: number, - currentMonitorWorkspacesVariable: Variable, - onlyActiveWorkspaces: boolean = true, -): ThrottledScrollHandlers { +export function initThrottledScrollHandlers(scrollSpeed: number): ThrottledScrollHandlers { const throttledScrollUp = throttle(() => { if (reverse_scroll.get()) { - goToPreviousWorkspace(currentMonitorWorkspacesVariable, onlyActiveWorkspaces, ignored); + goToPreviousWorkspace(ignored); } else { - goToNextWorkspace(currentMonitorWorkspacesVariable, onlyActiveWorkspaces, ignored); + goToNextWorkspace(ignored); } }, 200 / scrollSpeed); const throttledScrollDown = throttle(() => { if (reverse_scroll.get()) { - goToNextWorkspace(currentMonitorWorkspacesVariable, onlyActiveWorkspaces, ignored); + goToNextWorkspace(ignored); } else { - goToPreviousWorkspace(currentMonitorWorkspacesVariable, onlyActiveWorkspaces, ignored); + goToPreviousWorkspace(ignored); } }, 200 / scrollSpeed); diff --git a/src/components/bar/modules/workspaces/index.tsx b/src/components/bar/modules/workspaces/index.tsx index cf94135..0520097 100644 --- a/src/components/bar/modules/workspaces/index.tsx +++ b/src/components/bar/modules/workspaces/index.tsx @@ -1,5 +1,5 @@ import options from 'src/options'; -import { initThrottledScrollHandlers, getWorkspacesForMonitor } from './helpers'; +import { initThrottledScrollHandlers } from './helpers'; import { BarBoxChild } from 'src/lib/types/bar'; import { WorkspaceModule } from './workspaces'; import { bind, Variable } from 'astal'; @@ -7,15 +7,9 @@ import { GtkWidget } from 'src/lib/types/widget'; import { Astal, Gdk } from 'astal/gtk3'; import { isScrollDown, isScrollUp } from 'src/lib/utils'; -const { workspaces, scroll_speed } = options.bar.workspaces; +const { scroll_speed } = options.bar.workspaces; const Workspaces = (monitor = -1): BarBoxChild => { - const currentMonitorWorkspaces = Variable(getWorkspacesForMonitor(monitor)); - - workspaces.subscribe(() => { - currentMonitorWorkspaces.set(getWorkspacesForMonitor(monitor)); - }); - const component = ( @@ -35,18 +29,15 @@ const Workspaces = (monitor = -1): BarBoxChild => { self.disconnect(scrollHandlers); } - const { throttledScrollUp, throttledScrollDown } = initThrottledScrollHandlers( - scroll_speed, - currentMonitorWorkspaces, - ); + const { throttledScrollUp, throttledScrollDown } = initThrottledScrollHandlers(scroll_speed); scrollHandlers = self.connect('scroll-event', (_: GtkWidget, event: Gdk.Event) => { if (isScrollUp(event)) { - throttledScrollDown(); + throttledScrollUp(); } if (isScrollDown(event)) { - throttledScrollUp(); + throttledScrollDown(); } }); }); diff --git a/src/components/menus/audio/active/devices/index.tsx b/src/components/menus/audio/active/devices/index.tsx index 68c7689..8b5f981 100644 --- a/src/components/menus/audio/active/devices/index.tsx +++ b/src/components/menus/audio/active/devices/index.tsx @@ -1,4 +1,3 @@ -import { BindableChild } from 'astal/gtk3/astalify'; import { audioService } from 'src/lib/constants/services'; import { SliderItem } from '../sliderItem/SliderItem'; import { ActiveDeviceMenu } from '..'; @@ -21,5 +20,5 @@ export const ActiveDevices = (): JSX.Element => { }; interface ActiveDeviceContainerProps { - children?: BindableChild | BindableChild[]; + children?: JSX.Element[]; } diff --git a/src/components/menus/audio/active/index.tsx b/src/components/menus/audio/active/index.tsx index 470aba1..708429d 100644 --- a/src/components/menus/audio/active/index.tsx +++ b/src/components/menus/audio/active/index.tsx @@ -1,8 +1,7 @@ import { Gtk } from 'astal/gtk3'; import { ActiveDevices } from './devices/index.js'; -import Variable from 'astal/variable.js'; import { ActivePlaybacks } from './playbacks/index.js'; -import { bind } from 'astal/binding.js'; +import { bind, Variable } from 'astal'; import { isPrimaryClick } from 'src/lib/utils.js'; export enum ActiveDeviceMenu { diff --git a/src/components/menus/audio/available/InputDevices.tsx b/src/components/menus/audio/available/InputDevices.tsx index 4c38323..7385cb7 100644 --- a/src/components/menus/audio/available/InputDevices.tsx +++ b/src/components/menus/audio/available/InputDevices.tsx @@ -1,5 +1,5 @@ import { audioService } from 'src/lib/constants/services.js'; -import { bind } from 'astal/binding.js'; +import { bind } from 'astal'; import { AudioDevice } from './Device'; import { NotFoundButton } from './NotFoundButton'; diff --git a/src/components/menus/audio/available/PlaybackDevices.tsx b/src/components/menus/audio/available/PlaybackDevices.tsx index 361613b..48c3fce 100644 --- a/src/components/menus/audio/available/PlaybackDevices.tsx +++ b/src/components/menus/audio/available/PlaybackDevices.tsx @@ -1,5 +1,5 @@ import { audioService } from 'src/lib/constants/services.js'; -import { bind } from 'astal/binding.js'; +import { bind } from 'astal'; import { AudioDevice } from './Device'; import { NotFoundButton } from './NotFoundButton'; diff --git a/src/components/menus/audio/index.tsx b/src/components/menus/audio/index.tsx index 688bf44..50fa948 100644 --- a/src/components/menus/audio/index.tsx +++ b/src/components/menus/audio/index.tsx @@ -1,7 +1,7 @@ import DropdownMenu from '../shared/dropdown/index.js'; import { VolumeSliders } from './active/index.js'; import options from 'src/options.js'; -import { bind } from 'astal/binding.js'; +import { bind } from 'astal'; import { Gtk } from 'astal/gtk3'; import { AvailableDevices } from './available/index.js'; import { RevealerTransitionMap } from 'src/lib/constants/options.js'; diff --git a/src/components/menus/bluetooth/devices/index.tsx b/src/components/menus/bluetooth/devices/index.tsx index fbfb1e5..e84bc48 100644 --- a/src/components/menus/bluetooth/devices/index.tsx +++ b/src/components/menus/bluetooth/devices/index.tsx @@ -1,5 +1,4 @@ -import Variable from 'astal/variable.js'; -import { bind } from 'astal/binding.js'; +import { bind, Variable } from 'astal'; import { bluetoothService } from 'src/lib/constants/services.js'; import { getAvailableBluetoothDevices, getConnectedBluetoothDevices } from './helpers.js'; import { NoBluetoothDevices } from './NoBluetoothDevices.js'; diff --git a/src/components/menus/bluetooth/index.tsx b/src/components/menus/bluetooth/index.tsx index 5b48044..362d98c 100644 --- a/src/components/menus/bluetooth/index.tsx +++ b/src/components/menus/bluetooth/index.tsx @@ -2,7 +2,7 @@ import DropdownMenu from '../shared/dropdown/index.js'; import { BluetoothDevices } from './devices/index.js'; import { Header } from './header/index.js'; import options from 'src/options.js'; -import { bind } from 'astal/binding.js'; +import { bind } from 'astal'; import { Gtk } from 'astal/gtk3'; import { RevealerTransitionMap } from 'src/lib/constants/options.js'; diff --git a/src/components/menus/dashboard/directories/Sections.tsx b/src/components/menus/dashboard/directories/Sections.tsx index 83e1c7a..da7eb83 100644 --- a/src/components/menus/dashboard/directories/Sections.tsx +++ b/src/components/menus/dashboard/directories/Sections.tsx @@ -1,5 +1,3 @@ -import { BindableChild } from 'astal/gtk3/astalify'; - export const LeftSection = ({ children }: SectionProps): JSX.Element => { return ( @@ -17,5 +15,5 @@ export const RightSection = ({ children }: SectionProps): JSX.Element => { }; interface SectionProps { - children?: BindableChild | BindableChild[]; + children?: JSX.Element | JSX.Element[]; } diff --git a/src/components/menus/dashboard/index.tsx b/src/components/menus/dashboard/index.tsx index 1bbea0a..b03c576 100644 --- a/src/components/menus/dashboard/index.tsx +++ b/src/components/menus/dashboard/index.tsx @@ -5,8 +5,7 @@ import { Controls } from './controls/index.js'; import { Stats } from './stats/index.js'; import { Directories } from './directories/index.js'; import options from 'src/options.js'; -import { bind } from 'astal/binding.js'; -import Variable from 'astal/variable.js'; +import { bind, Variable } from 'astal'; import { RevealerTransitionMap } from 'src/lib/constants/options.js'; const { controls, shortcuts, stats, directories } = options.menus.dashboard; diff --git a/src/components/menus/dashboard/profile/helpers.ts b/src/components/menus/dashboard/profile/helpers.ts index 7260b60..d6d2c97 100644 --- a/src/components/menus/dashboard/profile/helpers.ts +++ b/src/components/menus/dashboard/profile/helpers.ts @@ -1,7 +1,7 @@ import { App } from 'astal/gtk3'; import powermenu from '../../power/helpers/actions.js'; import { PowerOptions } from 'src/lib/types/options.js'; -import { execAsync } from 'astal/process.js'; +import { execAsync } from 'astal'; const { confirmation, shutdown, logout, sleep, reboot } = options.menus.dashboard.powermenu; /** diff --git a/src/components/menus/dashboard/shortcuts/sections/Column.tsx b/src/components/menus/dashboard/shortcuts/sections/Column.tsx index b969eb5..71864a6 100644 --- a/src/components/menus/dashboard/shortcuts/sections/Column.tsx +++ b/src/components/menus/dashboard/shortcuts/sections/Column.tsx @@ -1,5 +1,3 @@ -import { BindableChild } from 'astal/gtk3/astalify'; - export const LeftColumn = ({ isVisible, children }: LeftColumnProps): JSX.Element => { return ( @@ -26,9 +24,9 @@ export const RightColumn = ({ children }: RightColumnProps): JSX.Element => { interface LeftColumnProps { isVisible?: boolean; - children?: BindableChild | BindableChild[]; + children?: JSX.Element | JSX.Element[]; } interface RightColumnProps { - children?: BindableChild | BindableChild[]; + children?: JSX.Element | JSX.Element[]; } diff --git a/src/components/menus/energy/index.tsx b/src/components/menus/energy/index.tsx index bd1381e..42bd098 100644 --- a/src/components/menus/energy/index.tsx +++ b/src/components/menus/energy/index.tsx @@ -2,7 +2,7 @@ import DropdownMenu from '../shared/dropdown/index.js'; import { EnergyProfiles } from './profiles/index.js'; import { Brightness } from './brightness/index.js'; import options from 'src/options.js'; -import { bind } from 'astal/binding.js'; +import { bind } from 'astal'; import { Gtk } from 'astal/gtk3'; import { RevealerTransitionMap } from 'src/lib/constants/options.js'; diff --git a/src/components/menus/media/components/MediaContainer.tsx b/src/components/menus/media/components/MediaContainer.tsx index e82ee99..336ce73 100644 --- a/src/components/menus/media/components/MediaContainer.tsx +++ b/src/components/menus/media/components/MediaContainer.tsx @@ -1,6 +1,5 @@ import { getBackground } from './helpers.js'; import { Gtk } from 'astal/gtk3'; -import { BindableChild } from 'astal/gtk3/astalify.js'; export const MediaContainer = ({ children }: MediaContainerProps): JSX.Element => { return ( @@ -19,5 +18,5 @@ export const MediaContainer = ({ children }: MediaContainerProps): JSX.Element = }; interface MediaContainerProps { - children?: BindableChild | BindableChild[]; + children?: JSX.Element | JSX.Element[]; } diff --git a/src/components/menus/media/index.tsx b/src/components/menus/media/index.tsx index ea03ed4..8745a04 100644 --- a/src/components/menus/media/index.tsx +++ b/src/components/menus/media/index.tsx @@ -1,4 +1,4 @@ -import { bind } from 'astal/binding.js'; +import { bind } from 'astal'; import DropdownMenu from '../shared/dropdown/index.js'; import options from 'src/options.js'; import { MediaContainer } from './components/MediaContainer.js'; diff --git a/src/components/menus/network/index.tsx b/src/components/menus/network/index.tsx index 1da4300..f70544c 100644 --- a/src/components/menus/network/index.tsx +++ b/src/components/menus/network/index.tsx @@ -2,7 +2,7 @@ import DropdownMenu from '../shared/dropdown/index.js'; import { Ethernet } from './ethernet/index.js'; import { Wifi } from './wifi/index.js'; import options from 'src/options.js'; -import { bind } from 'astal/binding.js'; +import { bind } from 'astal'; import { networkService } from 'src/lib/constants/services.js'; import { NoWifi } from './wifi/WirelessAPs/NoWifi.js'; import { RevealerTransitionMap } from 'src/lib/constants/options.js'; diff --git a/src/components/menus/notifications/index.tsx b/src/components/menus/notifications/index.tsx index 62ef4cb..bee12d2 100644 --- a/src/components/menus/notifications/index.tsx +++ b/src/components/menus/notifications/index.tsx @@ -3,9 +3,8 @@ import { Controls } from './controls/index.js'; import { NotificationsContainer } from './notification/index.js'; import { NotificationPager } from './pager/index.js'; import options from 'src/options.js'; -import Variable from 'astal/variable.js'; import { handlePageBoundaries } from './helpers.js'; -import { bind } from 'astal/binding.js'; +import { bind, Variable } from 'astal'; import { RevealerTransitionMap } from 'src/lib/constants/options.js'; const { transition } = options.menus; diff --git a/src/components/menus/notifications/notification/index.tsx b/src/components/menus/notifications/notification/index.tsx index f737b91..b8ce1bf 100644 --- a/src/components/menus/notifications/notification/index.tsx +++ b/src/components/menus/notifications/notification/index.tsx @@ -1,9 +1,8 @@ import options from 'src/options.js'; import { filterNotifications } from 'src/lib/shared/notifications.js'; import AstalNotifd from 'gi://AstalNotifd?version=0.1'; -import Variable from 'astal/variable.js'; import { Gtk } from 'astal/gtk3'; -import { bind } from 'astal/binding.js'; +import { bind, Variable } from 'astal'; import { notifdService } from 'src/lib/constants/services.js'; import { NotificationCard } from 'src/components/notifications/Notification.js'; import { Placeholder } from './Placeholder'; diff --git a/src/components/menus/power/index.tsx b/src/components/menus/power/index.tsx index 420044c..a3d6814 100644 --- a/src/components/menus/power/index.tsx +++ b/src/components/menus/power/index.tsx @@ -4,7 +4,7 @@ import powermenu from './helpers/actions.js'; import options from 'src/options.js'; import { isPrimaryClick } from 'src/lib/utils.js'; import icons from 'src/lib/icons/icons.js'; -import { bind } from 'astal/binding.js'; +import { bind } from 'astal'; import { Gtk } from 'astal/gtk3'; import { RevealerTransitionMap } from 'src/lib/constants/options.js'; diff --git a/src/components/menus/power/verification.tsx b/src/components/menus/power/verification.tsx index b6553be..30d717b 100644 --- a/src/components/menus/power/verification.tsx +++ b/src/components/menus/power/verification.tsx @@ -1,7 +1,7 @@ import PopupWindow from '../shared/popup/index.js'; import powermenu from './helpers/actions.js'; import { App, Gtk } from 'astal/gtk3'; -import { bind } from 'astal/binding.js'; +import { bind } from 'astal'; export default (): JSX.Element => ( diff --git a/src/components/menus/powerDropdown/index.tsx b/src/components/menus/powerDropdown/index.tsx index fb2b845..3b0e31a 100644 --- a/src/components/menus/powerDropdown/index.tsx +++ b/src/components/menus/powerDropdown/index.tsx @@ -1,4 +1,4 @@ -import { bind } from 'astal/binding.js'; +import { bind } from 'astal'; import DropdownMenu from '../shared/dropdown/index.js'; import { PowerButton } from './button.js'; import options from 'src/options.js'; diff --git a/src/components/notifications/Header.tsx b/src/components/notifications/Header.tsx index 11ce0dd..d915e18 100644 --- a/src/components/notifications/Header.tsx +++ b/src/components/notifications/Header.tsx @@ -1,6 +1,6 @@ import AstalNotifd from 'gi://AstalNotifd?version=0.1'; import options from 'src/options.js'; -import { GLib } from 'astal/gobject.js'; +import { GLib } from 'astal'; import { Gtk } from 'astal/gtk3'; import { getNotificationIcon } from 'src/globals/notification.js'; import { notifHasImg } from './helpers'; diff --git a/src/components/notifications/index.tsx b/src/components/notifications/index.tsx index 5e5f373..1f52839 100644 --- a/src/components/notifications/index.tsx +++ b/src/components/notifications/index.tsx @@ -1,8 +1,7 @@ import { hyprlandService } from 'src/lib/constants/services.js'; import options from 'src/options.js'; import { getPosition } from 'src/lib/utils.js'; -import Variable from 'astal/variable.js'; -import { bind } from 'astal/binding.js'; +import { bind, Variable } from 'astal'; import { trackActiveMonitor, trackAutoTimeout, trackPopupNotifications } from './helpers.js'; import { Astal } from 'astal/gtk3'; import { NotificationCard } from './Notification.js'; diff --git a/src/lib/types/dropdownmenu.d.ts b/src/lib/types/dropdownmenu.d.ts index 3e62347..2775fd6 100644 --- a/src/lib/types/dropdownmenu.d.ts +++ b/src/lib/types/dropdownmenu.d.ts @@ -3,11 +3,10 @@ import { Astal, Gtk } from 'astal/gtk3'; import { WindowProps } from 'astal/gtk3/widget'; import { Opt } from '../option'; import { Binding } from 'astal'; -import { BindableChild } from 'astal/gtk3/astalify'; export interface DropdownMenuProps extends WindowProps { name: string; - child?: BindableChild | BindableChild[]; + child?: JSX.Element | JSX.Element[]; layout?: string; transition?: Gtk.RevealerTransitionType | Binding; exclusivity?: Astal.Exclusivity; diff --git a/src/lib/types/popupwindow.d.ts b/src/lib/types/popupwindow.d.ts index d361f88..8ad22f6 100644 --- a/src/lib/types/popupwindow.d.ts +++ b/src/lib/types/popupwindow.d.ts @@ -5,7 +5,7 @@ import { Gtk } from 'astal/gtk3'; export type PopupWindowProps = { name: string; - child?: BindableChild | BindableChild[]; + child?: JSX.Element | JSX.Element[]; layout?: Layouts; transition?: Transition | Binding; exclusivity?: Exclusivity; diff --git a/tsconfig.json b/tsconfig.json index d076b0f..1e11809 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -14,7 +14,7 @@ "alwaysStrict": true, "noImplicitThis": true, "baseUrl": ".", - "typeRoots": ["types", "src/lib/types"], + "typeRoots": ["src/lib/types"], "skipLibCheck": true, "types": [], "experimentalDecorators": true,