Skip to main content

add some architecture notes

ID
5f24a25
date
2023-05-14 15:33:30+00:00
author
Alex Chan <alex@alexwlchan.net>
parent
c1e01de
message
add some architecture notes
changed files
3 files, 36 additions

Changed files

LICENSE.md (0) → LICENSE.md (1053)

diff --git a/LICENSE.md b/LICENSE.md
new file mode 100644
index 0000000..0a1813d
--- /dev/null
+++ b/LICENSE.md
@@ -0,0 +1,19 @@
+Copyright (c) 2023 Alex Chan
+
+Permission is hereby granted, free of charge, to any person obtaining a
+copy of this software and associated documentation files (the "Software"),
+to deal in the Software without restriction, including without limitation
+the rights to use, copy, modify, merge, publish, distribute, sublicense,
+and/or sell copies of the Software, and to permit persons to whom the Software
+is furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
+THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR
+OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
+ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+OTHER DEALINGS IN THE SOFTWARE.

README.md (1548) → README.md (2253)

diff --git a/README.md b/README.md
index 491b161..fba413d 100644
--- a/README.md
+++ b/README.md
@@ -29,3 +29,20 @@ This app is my replacement for the reviewing portion of Darkroom – I can switc
 
 [Darkroom]: https://darkroom.co/
 [Flag & Reject workflow]: https://medium.com/@jasperhauser/manage-your-growing-darkroom-photo-library-with-flag-reject-77c9e1816ef2
+
+## How it works
+
+<img src="architecture.png">
+
+The UI is rendered by a Python web server.
+On the rendered page, I capture keyboard input with the [`document.keydown` event][event], and this sends appropriate messages to the web server.
+
+The web server runs scripts in a mixture of Swift/AppleScript, which update my photos in Photos.app as appropriate.
+Most of the heavy lifting is done with the [PhotoKit framework].
+
+If you're interested in the details of how I'm talking to Photos.app, you might want to look in the [actions folder](./actions).
+
+[event]: https://developer.mozilla.org/en-US/docs/Web/API/Element/keydown_event
+[PhotoKit framework]: https://developer.apple.com/documentation/photokit
+
+

architecture.png (0) → architecture.png (125168)

diff --git a/architecture.png b/architecture.png
new file mode 100644
index 0000000..0fca800
Binary files /dev/null and b/architecture.png differ