Commit graph

110 commits

Author SHA1 Message Date
57f1b80442
Use SQL generated columns for area, aspectratio, basename, bitrate. 2022-08-13 18:08:45 -07:00
f8b1cd9178
Rename hyphen_range to dotdot_range a..b so we can have negatives.
Hyphen range doesn't allow negative numbers. The dot-dot syntax
is used by git, ruby, and others so I think it's a good pick.
2022-08-04 06:10:43 -07:00
4001f6f371
Use datetime objects instead of timestamps in object model.
Trying to make better use of objects in this object oriented language.
2022-07-20 19:03:26 -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
4da25c1d9e
Replace get_author with @property author. 2021-10-23 18:48:14 -07:00
7e0c3e2626
Use /userid/ links instead of /user/username. 2021-10-23 17:20:14 -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
89205ac24a
Add interface for copying tags from other photos. 2021-04-29 13:12:37 -07:00
bc5a9f2116
Remove unused variable action. 2021-04-29 13:04:27 -07:00
400c255aea
Add "Show in folder" button to photos, albums. 2021-02-25 18:57:41 -08:00
5e7b90cbe4
Combine all card templates into cards.html. 2021-01-20 18:26:42 -08:00
20a3828dbf Move .tag_card to cards.css. 2021-01-08 14:16:59 -08:00
7f9c7085f0 Rename tag_object -> tag_card. 2021-01-08 13:57:27 -08:00
2dd71a002b Fix word-wrap should be word-break. 2021-01-07 19:10:28 -08:00
29774f2524 Add the clipboard checkbox on pageload, not in server response.
With the recent addition of search_embed iframes on other pages, we
had photo cards appearing but the photo_clipboard module was not
imported thus the checkboxes did nothing. I don't want to import
photo_clipboard onto every single page, I'd rather they click through
to the full search UI. Otherwise every single page will have the tray
and often not a good enough reason for it.
So, since the functionality of the checkbox is completely reliant on
the photo_clipboard.js module anyway, there's no reason not to have it
generated by that module.
2021-01-05 01:24:03 -08:00
7c62c064cb Rename photo_card_selector_checkbox photo_clipboard_selector_checkbox. 2021-01-04 23:31:41 -08:00
b8290d884e Add html id to the clipboard checkbox here. 2021-01-04 23:29:25 -08:00
12ee2adedf Add alertresponse to a lot of callback functions. 2020-11-06 22:50:05 -08:00
68b27fced2 Add refresh_or_alert so errors aren't missed. 2020-11-06 21:42:28 -08:00
387a9e7b81 Fix vertical centering of wide videos on narrowish viewport. 2020-11-04 17:21:19 -08:00
41b03f46b9 Use more class=panel throughout ui. 2020-11-03 16:25:04 -08:00
615242c680 Remove unnecessary "event" from generate_thumbnail form. 2020-11-03 16:08:15 -08:00
0fccfc562a Rearrange some functions and add headers. 2020-11-03 15:49:50 -08:00
1c0f50a4a6 Move refresh metadata button above the download links. 2020-11-03 15:34:41 -08:00
9e23aacae7 Add id=photo_filename to the h3. 2020-11-03 15:34:28 -08:00
cc8053f8fd Alert response if set searchhidden fails. 2020-11-03 15:33:59 -08:00
272bd471ff Fix positioning of photo_viewer under the new CSS rules. 2020-11-03 00:05:21 -08:00
af4f2bcdaa Link tags on photo page to the /tag/info url. 2020-10-13 10:41:47 -07:00
ee16d02324 In narrow mode, let #right be absolute to achieve similar effect.
It's not perfect yet, and 95vh is purely empirical.
2020-09-29 17:18:20 -07:00
1d6464b79b Let #right be fixed.
Previously, then the tags list was very long and dominated the scroll
height of the page, the #right and thus the photo would be floating
halfway down the page. By making it sticky, the photo always occupies
the correct position in the viewport no matter how long #left gets.
2020-09-29 17:13:03 -07: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
f56da72881 Return more sets from backend, do sorting on frontend.
It's better semantically for these items coming out of the backend
to be sets. Sorted lists are only relevant to human consumption at the
frontend.
2020-09-20 13:16:52 -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
83d22d2736 Remove unnecessary declarations of grid-area: left, right. 2020-09-18 21:01:38 -07:00
8da18ba502 Add --narrow, --wide to common.css, is_wide_mode to common.js. 2020-09-18 20:57:35 -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
4c9668c920 Instead of anti-autofocusing, use a pageload that calls focus(). 2020-09-17 18:17:08 -07:00
f9e4bac186 Use more _form functions instead of inline api.js calls. 2020-09-17 18:14:07 -07:00
2a379919e0 Use grid instead of flexbox for message_area for better gaps. 2020-09-15 15:03:40 -07:00
dd0ee7a72a Use more const. 2020-09-14 18:33:53 -07:00
c11fb12069 Sort tags as they are added to photo. 2020-09-12 16:52:46 -07:00
bbadd15129 Put the callbacks next to their respective form functions. 2020-09-12 11:59:03 -07:00
d00d7b4acf Refocus add_tag_box after removing a tag. 2020-09-12 01:19:16 -07:00
30c9efc043 Rename generate_thumbnail_for_video -> _form. 2020-09-11 17:06:50 -07:00
ad26f09ee0 On photo.html, add and remove tag lis dynamically.
Instead of requiring a page refresh to see the new tags. They
just won't be sorted.
Slight bummer, the datalist dropdown pretty much obscures the
whole thing anyway.
2020-09-11 15:57:06 -07:00
4b76bc0628 Don't access response.data.tagname until we know it's not an error.
This wasn't causing any issues, because it was just setting itself
to undefined, but I realized I should move it.
2020-09-10 06:48:56 -07:00
8d2af3255b Add endpoints set_searchhidden, unset_searchhidden and checkbox. 2020-09-09 20:51:15 -07:00