Mac OSX app that displays window previews when hovering over app icon on the Dock.

Related tags

SwiftUI App macos
Overview

Dock Window Preview

License Twitter

Adds window preview functionality on hover for Mac Dock, an open-source alternative.

This is very early in development and it will be buggy. Use at your own risk.

Image

Motivation

A long-time Windows user here, and I recently had to start using a Macbook, which has been a frustrating experience. Thankfully, most of my needs as a Windows user are satisfied thanks to AltTab, Rectangle and Karabiner, but I noticed there didn't appear to be any viable option for window previewing on the dock. The only options seemed to be old paid closed source applications (eg. HyperDock), with no guarantee they were going to work properly at all and didn't seem well supported. So after a lot of research, I decided to give it a try myself and to give it away for free.

Getting Started (Quick)

  • Run this command in the terminal: /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/PepsRyuu/dock-window-preview/master/install.sh)"
  • Run the application, grant the permissions.
  • Hover over the dock to see window previews.

Getting Started

  • Ensure you have NodeJS installed.
  • If Node is not installed, run brew install nvm then run nvm install 16 and nvm use 16.
  • Clone the repository using git clone https://github.com/PepsRyuu/dock-window-preview.git
  • Change into the directory using cd dock-window-preview
  • Run npm install, and then npm run build.
  • App will be compiled to out directory.
  • Run the app, grant the requested permissions.

For developers

  • For permissions, grant the same permissions to Terminal.
  • Use npm start to run, this will use yode instead of node.
  • For context, I mostly write front-end applications, so I prefer to work with JavaScript where possible.
  • My knowledge of Objective-C is incredibly basic, so the code could be better.
  • This approach of mostly JavaScript will make it easier for others to contribute.

Configuration

  • Config file is located in $HOME/.dock-window-preview/config.json.
  • aliases allows mapping apps on the dock to their actual name. If a thumbnail isn't showing, see what it's called in the dock, and use Activity Monitor to find it's real name.
  • theme provides customisation to the visual appearance of the preview using hexadecimal colours in the format #AARRGGBB.

Troubleshooting

  • If you rebuild the app, force quit the app using the Activity Monitor, and wipe out the permissions entirely, then run the app again.

Acknowledgements

Known Limitations

  • Only shows windows in the current space / desktop.
  • Compatibility will vary from app to app.

Task List

  • Figure out how to show windows from other spaces and how to focus on them.
  • Minimize and close windows from the previews.
  • Keyboard Controls.
  • Once there's a great user experience, investigate how to contribute to brew.
  • Support auto-hiding dock and dock in alternate locations.
  • Ensure preview does not appear outside of the monitor's area
  • If clicking on a dock icon, hide the preview
  • Test further different apps for unusual windows like invisible windows.
  • Gather window data asynchronously, and don't show outdated previews if the mouse has moved off that dock icon.
You might also like...
‪‪An app that stores and displays the information entered by the user‬‬

To do list :‬‬ ‪‪An app that stores and displays the information entered by the user‬‬ ‪‪The user can : Add, delete one or clear all , Edit, Show the

Reverie is a work-in-progress iOS app that displays your Last.fm scrobbles for each past year, for the current date.
Reverie is a work-in-progress iOS app that displays your Last.fm scrobbles for each past year, for the current date.

Reverie is a work-in-progress iOS app that displays your Last.fm scrobbles for each past year, for the current date.

LiveWeatherApp - Live Weather App - Displays Live Weather Data with OpenWeather API
LiveWeatherApp - Live Weather App - Displays Live Weather Data with OpenWeather API

Live Weather App - Displays Live Weather Data with OpenWeather API Learned about

WeatherApp-weatherbit.io- - App, that displays the weather in defined cities
WeatherApp-weatherbit.io- - App, that displays the weather in defined cities

WeatherApp-weatherbit.io- App, that displays the weather in defined cities This

LocationsWikipedia - a simple App that fetches a list of locations and displays it at UITableView
LocationsWikipedia - a simple App that fetches a list of locations and displays it at UITableView

Fetching a list of locations or Adding a new location and displaying the list inside a Table View when the user press one of them it will open Wikipedia app and display it inside a Map View.

A tiny SwiftUI app that displays Albums of Kanye West and a brief info about the artist.

West Day Ever It's a small SwiftUI app, that displays Albums of Kanye West and a brief info about the artist. Technical notes Low level packages that

VTuber Cam, macOS app that displays an avatar using a virtual camera.
VTuber Cam, macOS app that displays an avatar using a virtual camera.

日本語 VCam macOS app that displays an avatar using a virtual camera. You can display a virtual avatar on Zoom or Google Meet, or etc. This is useful for

Native iOS app built in SwiftUI, displays a collection of user's books.

Native iOS app built in SwiftUI, displays a collection of user's books.

Simple and minimalist weather app that displays the current conditions.
Simple and minimalist weather app that displays the current conditions.

Minimalistic Weather App Project Description In this project, I have developed a simple and minimalist weather app, where I use the Current Weather Da

Comments
  • Tried compiling app using script and manual process. Getting this error when trying to build (M1 Pro MacBook Pro)

    Tried compiling app using script and manual process. Getting this error when trying to build (M1 Pro MacBook Pro)

    Hi, tried compiling app using script and manual process. Getting this error when trying to build (M1 Pro MacBook Pro)

    > [email protected] build
    > yackage build out/
    
    TypeError [ERR_INVALID_ARG_TYPE]: The "path" argument must be of type string. Received undefined
        at new NodeError (node:internal/errors:372:5)
        at validateString (node:internal/validators:120:11)
        at Object.basename (node:path:1309:5)
        at packageApp (/Users/username/dock-window-preview/node_modules/yackage/lib/main.js:184:49)
        at async packageCleanApp (/Users/username/dock-window-preview/node_modules/yackage/lib/main.js:227:12)
        at async Command.build (/Users/username/dock-window-preview/node_modules/yackage/bin/yackage.js:32:3) {
      code: 'ERR_INVALID_ARG_TYPE'
    }
    
    
    opened by apotenza92 45
  • Not able to install or build app, yackage throws error

    Not able to install or build app, yackage throws error

    Either running npm run build or using the install command in the wiki lets me build the app. Instead, I am given this error:

    > [email protected] build
    > yackage build out/
    
    out/dock-window-preview: internal error in Code Signing subsystem
    Error: child exited with code 1
        at ChildProcess.<anonymous> (/Users/me/Documents/git_clones/dock-window-preview/node_modules/await-spawn/index.js:28:21)
        at ChildProcess.emit (node:events:527:28)
        at maybeClose (node:internal/child_process:1092:16)
        at Process.ChildProcess._handle.onexit (node:internal/child_process:302:5) {
      code: 1,
      stderr: '',
      stdout: ''
    }
    
    opened by CurtisTD 5
Owner
Paul Sweeney
Paul Sweeney
Demonstration of using UIWindowScene and SwiftUI to provide a native-looking Mac preferences window in Catalyst

CatalystPrefsWindow Ever wondered how to create a more Mac-like preferences window for Catalyst? Perhaps Settings Bundles are too limiting for the kin

Steven Troughton-Smith 148 Dec 27, 2022
A swift package(SPM) with iOS UI component that loads and displays images from remote urls or local assets and displays in a slide-show form with auto scroll feature.

MDBannersView A swift package with an iOS UI component that loads and displays images from remote urls, local assets and displays in a slide-show form

Madhav Deva 2 Feb 5, 2022
A small macOS menubar app designed to hide the dock on selected spaces.

HideMyDock A small macOS menubar app designed to hide the dock on selected spaces. Installation Manually You can download the latest version of .dmg f

Alexander Ushaev 42 Jan 2, 2023
A realistic reflective shimmer to SwiftUI Views that uses device orientation. Position any View relative to device orientation to appear as if through a window or reflected by the screen.

A 3d rotation effect that uses Core Motion to allow SwiftUI views to appear projected in a specific direction and distance relative to the device in r

Ryan Lintott 235 Dec 30, 2022
Mac-asksec - Test Mac Permissions from the Terminal

asksec A simple CLI to test permissions from any macOS terminal app. Building ru

Christian Zangl 1 Jan 18, 2022
Added Splash Page, App Icon, and Animations when interacting with the flash cards.

flashcards-app Lab 4 App Description Added Splash Page, App Icon, and Animations when interacting with the flash cards. App Walk-though Required User

juan guillermo 1 Apr 12, 2022
Fast Multi-store Redux-like architecture for iOS/OSX applications

Highway Highway is implementation of Redux-like architecture pattern using Swift. If you were looking for a something like this: TEA (The Elm Architec

Dmitrii Cooler 14 Dec 9, 2022
An app that composes text over an image in SwiftUI

MemeMaker MemeMaker is a little app using SwiftUI that shows a few things: Main list uses a generic type constrained to View to pass destination view

James Dempsey 99 Aug 15, 2022
Proof concept of modularized app with SwiftPackages built over MVI + Combine + SwiftUI in a single repo

PKDex-iOS Proof concept of modularized app with SwiftPackages built over MVI + Combine + SwiftUI in a single repo Introduction This project is a proof

Miguel Angel Zapata 13 Nov 22, 2022
A SwiftUI App that displays information about the planets in our solar system.

MySpaceApp Created by Noman Ahmad Current Version : 1.0 Description: MySpaceApp is a simple ios app designed for space enthusiasts. With this app, you

Noman Ahmad 1 Nov 2, 2021