Commit graph

207 commits

Author SHA1 Message Date
dfff79baa7 Oops, fix broken clipboard reference due to namespace change. 2018-07-28 16:15:15 -07:00
89850497da Apply the squared 3d button css to all <button>. 2018-07-28 16:04:57 -07:00
9c354249c9 Rename variable editor -> ed to avoid conflicting with the module.
Even in cases that were not causing problems, for consistency.
2018-07-28 15:17:18 -07:00
977b47522d Add autocomplete to /clipboard. 2018-07-22 20:45:16 -07:00
c840845c7d Add namespacing to albums.js. 2018-07-22 20:21:00 -07:00
1bff642ca7 Add namespacing to hotkeys.js. 2018-07-22 20:21:00 -07:00
63a3ecfa88 Add namespacing to editor.js. 2018-07-22 20:21:00 -07:00
d7b9020585 Add namespacing to photoclipboard.js. 2018-07-22 20:21:00 -07:00
c7cce5a4e5 Add namespacing to common.js. 2018-07-22 20:21:00 -07:00
cf9b6d0725 Workaround autocomplete box sticking around after submitting. 2018-07-22 20:20:54 -07:00
5ec38a93b1 On the tag ancestors, don't display the current tag name.
I was finding it too confusing.
2018-07-22 20:19:05 -07:00
8a12a24e8e Add tag_autocomplete.js.
Instead of embedding the entire tag list in the search.html template
every single time, this script loads the tags from the new,
cache-enabled endpoint /all_tags.json. Then we can use html5
datalists to create autocomplete forms on the search and photo pages.
2018-07-22 20:19:05 -07:00
5ac3a8a121 Add caching.cached_endpoint decorator for 304'ing any url. 2018-07-22 20:19:05 -07:00
4c65ccaf68 Big! Liberate Groupables from strict heirarchy. Multiple parents.
I found that the strict heirarchy was not satisfying the situation
where one tag is the intersection of two others, but we can only
pick one as the parent

For example, does red_jacket belong under clothes.red_clothes or
clothes.jackets? A search for "red_clothes AND jackets" might
give us someone wearing red pants and a black jacket, so this
definitely needs to be a separate tag, but picking only one
parent for it is not sufficient. Now, a search for red_clothes
and a search for jackets will both find our red_jacket photo.

The change also applies to Albums because why not, and I'm sure
a similar case can be made.

Unfortunately this means tags no longer have one true qualname.
The concept of qualnames has not been completely phased out but
it's in progress.

This commit is very big because I was not sure for a long time
whether to go through with it, and so much stuff had to change
that I don't want to go back and figure out what could be grouped
together.
2018-07-20 13:09:06 -07:00
c2cfa99752 Alphabetize imports in endpoints files. 2018-07-18 18:37:21 -07:00
4987db4bd0 Switch to f-string formatting in many places. 2018-07-18 18:36:36 -07:00
5c97086df3 Improve hotkey framework by making own file & register function. 2018-07-14 14:19:13 -07:00
2901fefe65 Add more clipboard feature hotkeys. 2018-07-14 02:54:39 -07:00
984f6eb3c7 Add a clear button to the clipboard tray. 2018-07-14 02:49:45 -07:00
2f83bc2808 Add a simple docstring to the flask launch files. 2018-06-30 12:59:10 -07:00
4002cc660e Don't use shortlink for zoom url. It breaks caching. 2018-05-01 21:03:10 -07:00
8c356df6fd Add P_photos to batchify some api operations. 2018-05-01 18:09:35 -07:00
b19682d1a5 Replace Photo.sorted_tags with jinja filter. 2018-04-28 19:05:51 -07:00
50592f0ab4 Rework tab titles from "Album X" to "X | Albums" etc.
To prioritize the most unique and relevant piece of information.
2018-04-27 20:04:24 -07:00
bdec6cf4a3 Add filter to generate /file/ link with appropriate basename.
Because inlining the |urlencode every time is easy to forget.
2018-04-19 19:29:06 -07:00
bef91b3243 Allow /file/ to be accessed with a basename. 2018-04-19 19:23:10 -07:00
a12d8cada1 Don't capture ctrl+a if currently in a text field. 2018-04-17 18:35:32 -07:00
ed3b67bdb9 Split runner entrypoint from default local runner. 2018-04-15 20:34:03 -07:00
4434517c54 Rename config user.min_length -> min_username_length. 2018-04-15 14:36:07 -07:00
21bd211889 Give Users a display_name. 2018-04-15 14:23:24 -07:00
df211454bb Include username and password length requirements on form. 2018-04-15 13:20:08 -07:00
f77ab51b14 Add Album.has_any_photo and has_any_subalbum_photo. 2018-04-15 02:41:24 -07:00
0c9582598d Add arg --https even for non-443. 2018-04-15 01:00:37 -07:00
c1fd863999 Add jinja_filters.py with bytestring. 2018-04-15 00:59:54 -07:00
4fcb524211 Show number of photos in h3 on Album page 2018-04-06 21:50:13 -07:00
ac41598bb0 Add some more give_token.
I probably should just put it as a global pre-request hook.
2018-03-29 19:24:48 -07:00
cfa5d269d1 Add keybinds CTRL+A and +D to select/deselect all cards. 2018-03-23 11:58:39 -07:00
27885df64e Fix binding of the fallback handler. 2018-03-23 10:25:03 -07:00
abaeb2321f Oops, should be .remove instead of .pop for the cacheclass. 2018-03-23 00:35:56 -07:00
6ee86431e5 Add Album.normalize_title and _description. 2018-03-23 00:35:55 -07:00
0e3ae11610 Improve normalizers, use less None; Add author search box.
It was getting difficult to remember which of the normalizers
use None and which don't. So let's try to be a little more consistent
and just use empty sets, etc, so the caller can rely on receiving a
set instead of having to check for None.

Also renamed search parameter authors->author to be more in line
with the singular form of extension.
2018-03-22 21:09:21 -07:00
5be174d1b3 Completely rewrite search to use more SQL and less application.
In order to achieve tag_musts, we break each of the musts down
into separate EXISTS queries for each of the matchable children.
Then we INTERSECT those, and finally do other filtering and
ordering as usual.
2018-03-21 19:20:43 -07:00
7b4ae3045a Remove some excessive newlines from photo_card output. 2018-03-19 22:52:15 -07:00
b4cd4b6130 Fix body not filling vertical space. 2018-03-19 15:06:07 -07:00
45bd80caa4 Remove height:40px from plain_link. Only nice_link. 2018-03-19 15:03:53 -07:00
b90971813f Oops, fix broken click-to-join because of the qualname change. 2018-03-19 14:11:25 -07:00
b5274fefb9 Add caching.py to enable browser caching of files. 2018-03-18 21:42:31 -07:00
ea7401b4f2 Fix common.send_file to use pathclass. 2018-03-18 21:40:32 -07:00
0de755f138 Let the SessionManager use a cacheclass instead of plain dict. 2018-03-18 21:23:48 -07:00
a5aef63c6f Tags on this page should also display qualnames with maxlen. 2018-03-18 19:47:08 -07:00