···11# Peek
2233-Please meet Peek, a web user agent application designed for using the web where, when and how you want it.
33+Peek is a web user agent application designed for using the web where, when and how you want.
4455-** WARNING: THIS IS VACATIONWARE **
55+Today's browsers are one-size-fits-all applications, cramming the vast universe of user needs across an unimaginably large web into in an unmodifiable tabbed-window design.
6677-- Peek is not a web browser! Yet! And likely never will be a browser as you would expect from browsers to date. There are no tabs, and no windows in the tabbed-browser-like sense of them. If that's what you're looking for, there are a few decent browsers for you to choose from.
88-- Peek is not safe for general use yet! It is a crude proof of concept I whipped up while on vacation. While I have thoughts on security model and user interface, I have not written it up into a proper security model yet.
77+Peek is a web user agent that is a workbench for experimenting with task alignment - making it easy to create new user interface shapes for the web which fit our need in the moment.
981010-<img width="969" alt="CleanShot 2023-04-03 at 18 50 22@2x" src="https://user-images.githubusercontent.com/50103/229501558-7084d66e-962a-4c0f-a10e-11787ef3ce68.png">
99+We often use the web with a specific goal in mind - that goal should drive the design of the interface of the web user agent.
11101212-## Design
1111+<img width="969" alt="settings screenshot" src="settings-screenshot.png">
13121414-Many user tasks on the web are either transient, chained or persistent, data oriented, or some mix of those. The document-oriented web does not meet those needs. Major browser vendors can't meet those needs well, for many reasons.
1313+## Important notes
1414+1515+___PEEK IS NOT A WEB BROWSER___
1616+1717+Peek is not a web browser, and will never be a browser in the way you are probably familiar with: There are no tabs, and no windows in the tabbed-browser-like sense of them. Peek likely does not have many other of many details we are used to in web browsers, but do not notice until they are missing. Peek may be most useful to you if you view it as an entirely different type of application than a traditional web browser.
15181616-- transient
1717-- chained
1818-- persistent
1919-- data oriented
1919+___PEEK IS A CONCEPT PREVIEW___
20202121-About this space:
2222-- Embrace the app-ness aspect of the web platform, less about the document-ness
2323-- Javascript is ok here
2424-- Decouple html+js+css from http+dns+ssl - not entirely, but that trust+security model is not a required starting point
2121+Peek is not safe for daily use yet! It is a proof of concept. Do not use it for anything critical. Peek does not have the same security approach as traditional web browsers, and its security model and security user interface have not yet been determined. Peek has not had a security audit.
25222623## Features
27242825You can use Peek in a few ways, with more coming:
29263030-- Peeks - Keyboard activated modal chromeless web pages
3131-- Slides - Keyboard or gesture activated modal chromeless web pages which slide in from any screen edges
3232-- Scripts - Scripts periodically executed against a web page in the background which extract data and notify on changes
2727+- Peeks - Keyboard-activated modal chromeless web pages for quickly glancing at or interacting with pages
2828+- Slides - Keyboard- or gesture-activated modal chromeless web pages which slide in from any screen edges
2929+- Scripts - Scripts periodically executed against a web page in the background which extract data for you to route to other pages or applications, or to aggregate, store and process later
33303434-In progress:
3535-- Commands
3636-- Groups
3131+In progress, or thinking about:
37323838-Thinking about:
3939-- "native" web apps
3333+- Commands - a graphical command entry palette (GCLI) for opening pages or executing commands against them
3434+- Groups - a way to categorize, recall and interact with groups of pages
3535+- "native" web apps - using Peek as a way to "install" web pages on the local device, as separate applications instead of just separate processes
3636+3737+### Usage
3838+3939+- Settings
4040+ * In app, `Cmd/Ctrl+r,` or launch app to open settings, or click tray icon
4141+ * Configure Peeks/Slides/Scripts in settings
4242+- Peeks
4343+ * `Opt+0-9` to open Peeks
4444+- Slides
4545+ * `Opt+←→↑↓` to open Slides
40464147### Peeks
4248···52585359Ok, so not really "scripts" yet. But safe and effective enough for now.
54605555-## Why
6161+## Design
6262+6363+Many user tasks on the web are either transient, chained or persistent, data oriented, or some mix of those. Neither the document-oriented nor application-centric web meets those needs. Traditional browser makers can't meet those needs well, for many reasons.
6464+6565+- transient
6666+- chained
6767+- persistent
6868+- data oriented
56695770Some thoughts driving the design of Peek:
5871···6073- Windows and tabs should have died a long time ago, a mixed metaphor constraining the ability of the web to grow/thrive/change and meet user needs
6174- Security user interface must be a clear articulation of risks and trade-offs, and users should own the decisions
62756363-## User values
7676+### Escape IZUI
7777+7878+TODO: articulate the escape-to-leave aspect, eg you can peek from *other* applications and ESC to go back to exactly where you were without breaking the task flow.
64796565-- users can move, resize, change to their requirements
6666- - eg, browsers restrict minheight of a window, but i should be able make as short as i like
8080+Escape is an inverted zooming user interface (IZUI) design for a flexibl window manager that makes possible a web user agent application than can have multiple entry points and a heterogeneous windowing ecosystem.
67816868-## Design patterns
8282+IZUI vs ZUI
69837070-Escape IZUI
7171-* IZUI: inverse zooming user interface
7272-* ZUIs navigate by starting from a known root and user navigates by zooming ever further in
7373-* Escape starts anywhere, and instead of navigating by zooming in, all interfaces can zoom out to reset
7474-* allows unbounded and diverse entry points with predictable behavior
7575-* consistent path to familiar ground
8484+* ZUIs navigate by starting from a known root and user navigates by zooming ever further in, and then back out
8585+* Escape can enter a window stack at any point, and via a variety of methods, often from outside the application
8686+* Instead of navigating by zooming in, all interfaces can zoom out to go back, using the Escape key
8787+* This design allows unbounded and diverse entry points, but with predictable behavior
8888+* Regardless of the entry point, the user always has a consistent path to familiar ground
76897790Escape navigation model
7891* navigation base can start at any level in stack
7992* forward navigations are added on top of stack
8080-* backwards navigations walk the stack in reverse
9393+* backwards navigations walk the stack in reverse up the tree to the root
81948295## Architecture / Implementation
83969797+About this space:
9898+9999+- Web pages can themselves be navigators of the web
100100+- Embrace the app-ness of the web platform, as a way to efficiently access the document-ness
101101+- Decouple html+js+css from http+dns+ssl - not entirely, but that trust+security model is not a required starting point
102102+- Javascript is ok here
103103+84104Peek is designed to be modular and configurable around the idea that parts of it
85105can run in different environments.
8610687107For example:
8888-- Definitely planning on a mobile app which syncs and runs your peeks/slides/scripts
108108+- Planning on a mobile app which syncs and runs your peeks/slides/scripts
89109- I'd like to have a decentralized compute option for running your scripts outside of your clients and syncing the data
90110- Want cloud storage for all config and data, esp infinite history, so can do fun things with it
9111192112### "features" == privileged web apps
113113+114114+NOTE: This was rolled back for now. Added complexity not yet required for validating the end user value proposition of the core features.
9311594116The core features are web apps loaded over a custom protocol:
95117- currently with a scheme of `peek`
···122144TODO
123145- Need to look at whether could library-ize some of what Agregore implemented for non-HTTP protocol support.
124146- Min browser might be interesting as a forkable base to work from and contribute to, if they're open to it. At least, should look more at the architecture.
125125-126126-### Usage
127127-128128-- Settings
129129- * In app, `cmd/ctl+r,` or launch app to open settings, or click tray
130130- * Configure Peeks/Slides/Scripts in settings
131131-- Peeks
132132- * `Opt+0-9` to open Peeks
133133-- Slides
134134- * `Opt+←→↑↓` to open Slides
135147136148### Mobile
137149···265277- [x] close other windows of feature, not just background window
266278267279Feature re-init/reload when toggled
268268-- [x] main: track shortcuts by source, remove when unloaded
269269-- [x] main: track window sources
270270-- [x] main: close child windows when (before) closing source window
280280+- [ ] track shortcuts by source, remove when unloaded
281281+- [ ] main: track window sources
282282+- [ ] main: close child windows when (before) closing source window
271283272284Shortcut lifecycle
273285- [x] main process should handle multiple registrations correctly
274286- [x] send/track feature id/origin w/ each registration
275275-- [x] unreg shortcuts on unload
287287+- [ ] unreg shortcuts on unload
276288277289Window features
278290- [ ] add back in window features to window.open
···282294- [ ] add draggable as pref
283295284296Features clean themselves up for lifecycle events
285285-- [ ] determine if new web-native windowing approach resolves this
286297- [ ] load/unload peeks when enabled/disabled
287298- [ ] load/unload slides when enabled/disabled
288299- [ ] load/unload scripts when enabled/disabled
···293304- [ ] unreg shortcuts and close windows on slides un/configure
294305295306Cmd
296296-- [x] fix it
307307+- [ ] update to latest Cmd extension code
297308- [ ] app-scoped multi-window pages open
298309299310Settings
···316327- [ ] icons
317328- [ ] about page
318329319319-Demo scenario
330330+Demo reel
320331- [ ] Peeks: translate, calendar, ai chat, currency conversion, everytimezone, tldraw
321332- [ ] Slides: soundcloud, crypto prices, notepad, todo list
322333- [ ] Scripts: eth price, weather change
···436447- and seeing output of content scripts, or ability to re-run locally on demand
437448- needs some sync facility (inevitable anyway)
438449439439-## Resources
450450+## Demo reel
451451+452452+Demo reel
453453+- [ ] Peeks: translate, calendar, ai chat, currency conversion, everytimezone, tldraw
454454+- [ ] Slides: soundcloud, stock prices, notepad, todo list
455455+- [ ] Scripts: eth price, weather change
456456+- [ ] Cmd: address something in the above to switch between, to pipe from/to?
457457+458458+- author web content
459459+- pull in bits from the web
460460+- share preview for feedback
461461+- publish (or at least get output)
462462+463463+writing the recap of the web track at ipfs thing 2023
464464+465465+- make a new markdown doc
466466+- sections titled for each video title
467467+- each video's embed code in each section
468468+- navigate around the document for review and updates
469469+- need to easily preview rendered content
470470+- share preview link
471471+- publish somewhere
472472+473473+## Unfiled
474474+475475+Small examples of agency
476476+477477+- users can move, resize, change things to their requirements
478478+ - eg, browsers restrict min-height of a window, but i should be able make as short as i like
479479+480480+481481+## Browser architecture references
440482441483Agregore ext protocol impl
442484- where all are registered: https://github.com/AgregoreWeb/agregore-browser/blob/master/app/protocols/index.js#L74
···447489- Min browser architecture - https://github.com/minbrowser/min/wiki/Architecture
448490- Dot browser https://www.dothq.org/en-US
449491450450-Misc
451451-- https://github.com/Rajaniraiyn/awesome-electron-browsers
452452-- https://github.com/mawie81/electron-window-state
453453-- https://antonfisher.com/posts/2020/12/27/how-to-animate-native-electron-window/
454454-- https://stackoverflow.com/questions/44818508/how-do-i-move-a-frameless-window-in-electron-without-using-webkit-app-region
455455-456492## History
457493458494In working on Firefox and related things at Mozilla from 2006 - 2019, there were a few specific initiatives which best aligned with my needs as a user on the web:
···480516481517482518483483-## Testcase: Authoring Flows
484484-485485-- author web content
486486-- pull in bits from the web
487487-- share preview for feedback
488488-- publish (or at least get output)
489489-490490-writing the recap of the web track at ipfs thing 2023
491491-492492-- make a new markdown doc
493493-- sections titled for each video title
494494-- each video's embed code in each section
495495-- navigate around the document for review and updates
496496-- need to easily preview rendered content
497497-- share preview link
498498-- publish somewhere