Commit Graph

11570 Commits

Author SHA1 Message Date
evazion
ea92cbff4e user upgrades: update upgrade page text. 2022-06-02 14:40:42 -05:00
evazion
fec92d765a users: change default blacklist to furry -rating:g. 2022-06-02 00:06:34 -05:00
evazion
b02dbf1a43 Fix broken Docker build.
terser-webpack-plugin 5.3.2 was a bad release, which broke the Docker build.
2022-06-01 21:26:20 -05:00
evazion
2e249103e1 Update Ruby gems and Yarn packages. 2022-06-01 20:20:12 -05:00
evazion
572c58d115 Merge pull request #5187 from Hyozen1/patch-1
Allow background-clip and -webkit-background-clip properties in notes
2022-06-01 19:26:06 -05:00
evazion
cc2285ed6f Merge pull request #5188 from nonamethanks/fix-deviantart
Fix deviantart strategy to get biggest available size
2022-06-01 18:39:43 -05:00
evazion
434e44ba8b Merge pull request #5197 from nonamethanks/fix-bur-links
BURs: don't allow edits to approved scripts
2022-06-01 18:37:09 -05:00
evazion
173e43b192 user upgrades: add upgrade code system.
Add a system for upgrading accounts using upgrade codes. Users purchase
an upgrade code off-site then redeem it on-site to upgrade their account
to Gold. Upgrade codes are randomly pre-generated and are one time use
only. Codes have enough randomness that guessing a code is infeasible.
2022-06-01 18:31:46 -05:00
Hyozen1
547af83af8 Add background-clip and -webkit complementar properties to notes 2022-06-01 18:55:18 -03:00
nonamethanks
5932d8d3a3 BURs: don't allow edits to approved scripts
Also fix bad formatting for non-admins in BUR index
2022-06-01 14:07:30 +02:00
nonamethanks
3a0a32b98a Fix deviantart strategy to get biggest available size 2022-05-27 17:07:22 +02:00
evazion
7786fbaca6 Fix #5181: Old post versions have null ratings which causes a KeyError. 2022-05-22 23:50:45 -05:00
evazion
81bd86d202 posts: add "general" rating; rename "safe" rating to "sensitive".
* Add "general" rating.
* Rename "safe" rating to "sensitive".
* Change safe mode to include both rating:s and rating:g.
* Treat rating:safe as a synonym for rating:sensitive.
* Link "howto:rate" in the post edit form.
2022-05-22 13:38:45 -05:00
evazion
d346adabc9 Revert "posts: fix rounding errors in ratio: metatag."
This reverts commit 80ced3e418.

This turned out to be intentional. Rounding the aspect ratio to 2
decimal places is so that searches for exact ratios like `ratio:16:9` or
`ratio:1.78` work even when the ratio doesn't exactly match. Rounding to
2 decimal places means that the ratio: metatag has a 1% error tolerance.
2022-05-22 12:37:26 -05:00
evazion
c6b5be1c9f Update Danbooru logo. 2022-05-22 02:53:22 -05:00
evazion
ed1629bc7d Update Danbooru logo. 2022-05-21 23:26:46 -05:00
evazion
276850d2b1 Update Danbooru logo. 2022-05-21 21:39:44 -05:00
evazion
e7c507b7fc css: adjust spacing around header on mobile. 2022-05-21 14:57:49 -05:00
evazion
80ced3e418 posts: fix rounding errors in ratio: metatag.
Fix the ratio: metatag sometimes including wrong results due to rounding
errors. For example, searching for `ratio:>=4.0` would include post
3220414, which has an aspect ratio of 3.99879. This would get rounded up
to 2 decimal places to 4.00.
2022-05-21 14:08:50 -05:00
evazion
e53e8da3a1 Fix #5171: Don't allow wide_image and tall_image to be manually tagged. 2022-05-21 14:01:31 -05:00
evazion
d89db73c2f Add site logo to header. 2022-05-21 13:30:21 -05:00
evazion
1bcf93b816 Fix #5178: Add received bans to user includes. 2022-05-20 23:03:22 -05:00
evazion
9867514a78 Fix #5177: ordfav with commentary search raises exception. 2022-05-20 22:59:02 -05:00
evazion
0fe9356bf6 tests: fix broken tests. 2022-05-20 22:51:02 -05:00
evazion
1e78b97eb8 Add config options to disable comments and the forum.
Add options to disable comments, the forum, and autocomplete. This is
for personal boorus and potentially for safe mode. Note that disabling
the forum may cause difficulties with creating and approving BURs.

Disabling comments and the forum merely hides them from most areas,
rather than completely removing them.
2022-05-18 14:45:40 -05:00
evazion
2fe38c1c07 Fix #5168: Disable rate limits on testbooru/non-prod environments.
Add a `rate_limits_enabled?` config option for disabling rate limits.
2022-05-18 14:16:06 -05:00
evazion
25f0b01d50 posts: optimize has: metatag.
Use EXISTS queries instead of `id IN (?)` subqueries because they're
faster, especially when negated.
2022-05-18 13:59:04 -05:00
evazion
181639368c posts: add is: and has: metatags.
Add the following metatags:

* is:parent
* is:child
* is:safe
* is:questionable
* is:explicit
* is:sfw (same as -rating:q,e)
* is:nsfw (same as rating:q,e)
* is:active
* is:deleted
* is:pending
* is:flagged
* is:appealed
* is:banned
* is:modqueue
* is:unmoderated
* is:jpg
* is:png
* is:gif
* is:mp4
* is:webm
* is:swf
* is:zip
* has:parent
* has:children
* has:source
* has:appeals
* has:flags
* has:replacements
* has:comments
* has:commentary
* has:notes
* has:pools

All of these searches were already possible with other metatags, but these might be more convenient.
2022-05-18 13:04:15 -05:00
evazion
141044d352 posts: refactor hardcoded ratings.
Refactor ratings to not be hardcoded in various places. Make it so
all ratings are defined in Post::RATINGS.

Also make it so that you can search multiple ratings at once with `rating:q,e`.
2022-05-18 13:04:15 -05:00
evazion
af8ef8b277 uploads: address "Failed to replace upload_media_assets..." error
Sometimes uploads fail with this error:

    Failed to replace upload_media_assets because one or more of the new
    records could not be saved.

Change it so that media assets are saved individually, so that if saving
any of them fails we get a better error message.
2022-05-17 18:28:13 -05:00
evazion
06b38a19af posts: don't show nsfw tags in sidebar in safe mode.
Fix the post index page to not show nsfw tags in the sidebar in safe
mode. Instead of showing the most popular tags on the front page, or the
most similar tags to the current search, show only frequent tags (the
top 25 tags from posts on the current page).
2022-05-17 04:04:09 -05:00
evazion
ce18c866d9 Fix #4582: Safebooru should not block "censored" tag
* Remove the default list of blocked tags in safe mode.
* Change it so that tags that are blocked in safe mode are filtered out
  at the database level rather than at the html level.
2022-05-17 02:24:16 -05:00
evazion
8239a1b551 upgrades: fix Danbooru.config.user_upgrades_enabled? setting
* Fix it so that if upgrades are disabled, only the payment button is disabled instead of the whole page.
* Fix it so that disabling upgrades with DANBOORU_USER_UPGRADES_ENABLED="false" works.
2022-05-17 01:24:38 -05:00
evazion
3dbe6ea842 Merge pull request #5166 from NamelessContributor/notes-text-stroke
Notes: allow using -webkit-text-stroke and related
2022-05-16 15:13:15 -05:00
evazion
6b54415c47 Merge pull request #5170 from nonamethanks/fix-fc2-bad-source
Fc2: don't mark valid blog page sources as bad_source
2022-05-16 15:12:07 -05:00
evazion
1ea76624c8 Merge pull request #5172 from nonamethanks/sort-relationships
Tags: sort list of relationships alphabetically
2022-05-16 15:11:58 -05:00
nonamethanks
c97dd8958f Tags: sort list of relationships alphabetically 2022-05-16 13:08:11 +02:00
nonamethanks
dcbb2216aa Fc2: don't mark valid blog page sources as bad_source 2022-05-15 18:46:50 +02:00
evazion
1eb15da7c5 upgrades: add authorize.net integration.
Add integration for accepting payments with Authorize.net.

https://developer.authorize.net/hello_world.html
2022-05-15 01:47:45 -05:00
evazion
4b65e96abc upgrades: rename stripe_id to transaction_id
* Rename the stripe_id column to transaction_id.
* Add a new payment_processor column to identity the processor used for
  this transaction (and hence, which backend system the transaction_id is for).
2022-05-15 01:05:24 -05:00
evazion
6de527f064 upgrades: show login and create account links for anon users. 2022-05-15 01:05:21 -05:00
NamelessContributor
c909555da8 Notes: allow using -webkit-text-stroke and related
These properties are widely supported: https://caniuse.com/text-stroke
Currently some notes use multiple text-shadows as a workaround:
https://danbooru.donmai.us/notes?search[body_matches]=text-shadow
2022-05-14 07:24:03 +02:00
evazion
39a9c7efa0 Merge pull request #5164 from nonamethanks/tag-deprecation-edit-form
Tags: show better message in edit form if tag lacks wiki
2022-05-11 21:00:26 -05:00
evazion
c5d906e93f Merge pull request #5163 from NamelessContributor/footer-commit-hash
Add back current commit hash to site footer.
2022-05-11 20:59:58 -05:00
nonamethanks
4eb579ebe4 Tags: show better message in edit form if tag lacks wiki 2022-05-11 20:52:55 +02:00
NamelessContributor
f668cfdbac Add back current commit hash to site footer.
The commit hash is shown when hovering over the app name in the footer.
2022-05-11 14:56:13 +02:00
evazion
c73ff4fbd9 Update Ruby gems and Yarn packages. 2022-05-11 00:23:53 -05:00
evazion
bb461d82b6 Fix #5162: NoMethodError in MastodonApiClient#commentary without credentials set 2022-05-11 00:17:49 -05:00
evazion
7573c6dfc9 Merge pull request #5160 from NamelessContributor/feat-data-is-deprecated
Add data-is-deprecated attribute to tags
2022-05-11 00:10:13 -05:00
evazion
4360573af0 upgrades: update text. 2022-05-10 12:20:11 -05:00