Commit graph

76 commits

Author SHA1 Message Date
da5c1ee008 Let PhotoTags have timestamps; use more js cards.
Tags on photos can now have timestamps, so that if you are tagging
a video or audio you can reference a specific moment with your tag.
In the interface, this means the tag is clickable and seeks to that
point in the media.

For the user interface, I am finding I need to move away from jinja
for the object cards because it is too much hassle to keep the code
for jinja-based cards for static rendering and the js-based cards
for dynamic rendering in sync. Rather than write the same cards in
two languages I can dump the JSON into the script and render the cards
on load. Which makes the static HTML worse but that's what the JSON
API is for anyway.
2023-09-17 14:07:22 -07:00
a68f76176f Move themes into one file, set by class on html element. 2023-07-22 17:32:39 -07:00
ef668c5d3b Add endpoint /batch/photos/generate_thumbnail. 2023-06-25 00:02:20 -07:00
e78a667ee3 Move the session into requests.session for universal access. 2023-02-01 22:04:44 -08:00
bd4c997780
Move "clipboard contains x items" to the side bar. 2022-11-05 23:25:06 -07:00
707d1ec829
Move http functions to new javascript file http.js. 2022-10-01 14:24:36 -07:00
a39e600619
Add favicon link to all HTML templates. 2022-05-28 16:21:23 -07:00
ebe6fcb07d
Rename spinner.js -> spinners.js.
It has been frustrating when I want to name a variable spinner.
2022-03-26 13:22:02 -07:00
e5f2f6992b
Fix DOCTYPE should just be "html". 2021-06-22 13:38:08 -07:00
9c13220ac3
Let pages opt in to the use of photo_clipboard's hotkeys. 2021-06-03 17:42:46 -07:00
e8cb183849
Add cards.js photos.create, render clipboard batches on client. 2021-05-29 08:46:25 -07:00
fabbbaf17f Rename photo_cards.css -> cards.css. All types welcome. 2021-01-08 13:40:34 -08:00
ea5a02f8b6 Use update_dynamic_elements for user name, clipboard count. 2021-01-07 20:18:07 -08:00
ede7734a81 Call photo_clipboard.apply_check_all after refreshing divs.
This was previously performed automatically deeper within clipboard.js,
but was optimized out recently.
2021-01-03 00:17:36 -08:00
7f2d463062 Hide the photo card holder when there are no photos.
I didn't like the narrow sliver of div that was left.
2020-12-26 12:14:42 -08:00
33b4799268 Only log "needed but not received" if there are any. 2020-12-26 12:13:54 -08:00
12ee2adedf Add alertresponse to a lot of callback functions. 2020-11-06 22:50:05 -08:00
99e64e358e Add missing semicolon. 2020-11-06 22:22:41 -08:00
d536974025 Add class=panel to /clipboard #left. 2020-11-04 16:57:41 -08:00
7e58c95f15 Mostly failed experiment: tag_autocomplete indexeddb.
The current system has bad performance when you've got 100,000+ tags.
I discovered that when the server returns 304, the browser gives the
ajax a 200 with the full response, and it's not clear to me if js can
know it got a 304. So, the tag set is being fully re-parsed from the
response on every page load. I was thinking that I should store that in
IndexedDB to avoid the parsing step, but... since the JSON.parse is
done by my common.get before it hits this function, it's meaningless.
Not to mention I still have to rebuild the datalist on every page since
of course that state isn't shared between tabs. Not worth the DB stuff.
We'll see what happens next.
2020-09-29 16:52:20 -07:00
adb1d0ef39 Replace all double blank lines with single, improve hash headers.
There was always some semblance that two blank lines has some kind of
meaning or structure that's different from single blank lines, but
in reality it was mostly arbitrary and I can't stand to look at it
any more.
2020-09-19 03:13:23 -07:00
3fb198f994 Add explicit @media queries for wide mode, not just default to override.
Any properties that are different in wide/narrow mode should be defined
in the correct media query. I got tired of having wide mode be the
default and then narrow mode having to unset/initial all the attributes
that aren't relevant to narrow.
2020-09-18 21:12:28 -07:00
9a29048ccf Split sticky_side functionality into _side, _bottom.
This makes the role of each css definition more clear, and could allow
for cases where the side is sticky in wide mode but not sticky in
narrow mode.
2020-09-18 20:37:40 -07:00
dd0ee7a72a Use more const. 2020-09-14 18:33:53 -07:00
139998172f Add spinner.BAIL for cancelling spinner without launching callback. 2020-09-04 11:25:11 -07:00
7f48c3e97c Add css/js classes entry_with_history, _with_tagname_replacements. 2020-09-04 11:20:51 -07:00
295c9b4956 Add return to all onclicks, and ; to other javascript hooks. 2020-09-04 10:37:04 -07:00
05b39c21fd Replace loop uses of var with let/const. 2020-09-03 15:33:37 -07:00
8af340e442 Replace non-global uses of var with let. 2020-09-03 15:31:47 -07:00
fe7b5de427 Replace many uses of forEach with for-of. 2020-09-03 14:18:05 -07:00
8dafe8c4f4 Synchronize Etiquette common.css and YCDL common.css. 2020-09-03 11:50:16 -07:00
bff4a12fcb Add various comments, docstrings, and console.log. 2020-09-03 11:46:26 -07:00
6b037e1120 Move several /batch functions into api.js. 2020-08-30 19:18:06 -07:00
8ae1086727 Remove var holder which is already on the global scope. 2020-08-29 18:58:19 -07:00
7c4229f1fa Use dot notation instead of subscript for response. 2020-06-28 17:54:16 -07:00
a56b5274c9 Read spinner button function from onclick instead of data-onclick.
I think my original reason for doing this was to prevent the button
from being operational until after the spinner initialization has
completed, so you don't get any weird half-functional spinner buttons.
However, in practice I'm finding that I constantly forget about this
and it adds tedium to creating spinner buttons.
Will review if any actual problems come up.
2020-06-17 14:04:27 -07:00
634f6f5188 Fix metadata spinner not closing when 0 items on clipboard. 2020-05-28 19:02:07 -07:00
d273adbf27 Move new #right:before to common.css. 2019-09-11 01:12:04 -07:00
4d235c427c Create #right:before on narrow screens to give a solid background. 2019-09-10 19:38:58 -07:00
14500080c8 Redo clipboard.html css to auto grid instead of specifying each. 2019-08-26 15:15:02 -07:00
5a1e4474a9 Remove unnecessary specifying #left grid-area: left. 2019-08-26 15:03:14 -07:00
d209445bd0 Remove unnecessary specifying #header grid-area: header. 2019-08-26 15:02:53 -07:00
d5c99b407d Set margin:0 for the inputs next to the buttons
Otherwise they've got odd spacing, and we have row-gaps anyway.
2019-08-25 17:36:05 -07:00
79ed0ee186 Various CSS for panels and margins. 2019-08-14 13:49:08 -07:00
b683413be0 Try different themes with the ?theme query. 2019-08-14 13:43:35 -07:00
802c12937b Replace bespoke spinner with new button_with_spinner. 2019-06-15 16:04:06 -07:00
26bcafcbb5 Add style for button:disabled instead of switching classes. 2019-06-15 13:26:39 -07:00
65605253bf Add spacers between these sections of code. 2019-04-27 16:55:47 -07:00
4ddf578d63 Add spinner text to clipboard refresh metadata button.
Also replace usage of own in_progress variable with simply
disabling the button.
2019-04-27 16:55:26 -07:00
707fdcc637 Add album cards and improve album pages.
- album card has placeholder for future thumbnail.
- replaced nested tree hierarchy lists with separate boxes.
- list/grid view also applies to the root listing.
- added a sticky right panel for all the tools. not pretty yet.
- mechanism for adding sticky panel changed. instead of applying
  it to the #right, you apply it to #content_body so that its
  grid layout can be updated properly.
2018-11-12 22:15:59 -08:00