Commit Graph
71 Commits
Author SHA1 Message Date
evazion 6a84d33409 Fix #4770: Allow flaggers to update flag reason. 2021-03-23 01:27:16 -05:00
evazion 1b30b71a07 posts: refactor post previews to use ViewComponent.
Refactor the post preview html to use the ViewComponent framework. This
lets us encapsulate all the HTML, CSS, and helper methods for a UI
component in a single place.

See https://viewcomponent.org.
2021-01-14 21:17:57 -06:00
evazion 317cfe19b4 flags: only show current flag on flagged posts.
* Only show the current pending flag on flagged posts. Don't show old flags.

* Don't show both the "This post was flagged for review" and the "This
  post was flagged and is pending" notices.
2020-08-16 14:31:47 -05:00
evazion 3a17b5a13e flags/appeals: replace is_resolved flag with statuses.
Replace references to the `is_resolved` field with the `status` field.
Post flags were marked as resolved when a post was approved (but not
when the post was deleted because it went unapproved). The status field
supercedes the resolved field.
2020-08-07 19:24:57 -05:00
evazion 883856d4af simple form: refactor DText form fields to use SimpleForm.
* Refactors DText form fields to use a custom SimpleForm input instead
  of manually generated html. This fixes it so that DText fields use the
  same markup as normal SimpleForm fields, which lets us apply browser
  maxlength validations to DText input fields.

* Fixes autocomplete for @-mentions only working in comments and forum posts.
  Now @-mention autocomplete works in all DText fields, including dmails.
  Known bug: it applies in artist commentary fields when it shouldn't.
2020-06-25 16:28:09 -05:00
evazion 33d81d0d1b pundit: convert post flags to pundit. 2020-03-20 18:03:01 -05:00
evazion 95e11e0ffc Fix #4318: Flags and appeals should reload page. 2020-03-03 23:01:34 -06:00
evazion 72e56d8856 PostPresenter.preview: standardize on show_deleted: true.
Standardize on using `show_deleted: true` instead of `tags: "status:any"`
when rendering thumbnails and we want to show deleted thumbnails.

Also fixes it so that deleted thumbnails are shown when reordering pools
and favorite groups.
2020-02-18 19:22:57 -06:00
evazion 9c6ef424ef post_flags/index: remove banned and duplicate search options.
Remove options for searching for "Artist requested removal" and
"duplicate" flag reasons. These were legacy flag reasons that haven't
been used for a long time.
2020-02-17 02:13:34 -06:00
evazion 588280c8cc views: add embed_wiki helper.
Also remove options to configure names of wiki notice pages. These names
generally don't need to be changed and we already hardcode links to wiki
pages in other places anyway.
2020-01-27 17:14:38 -06:00
BrokenEagle 63203d24cc Standardize use of column width parameter 2020-01-13 21:21:14 +00:00
evazion c86c61c9a4 Fix #4162: Remove browser autocomplete from most inputs. 2020-01-10 16:08:34 -06:00
evazion f1528e0fae table builder: add 'striped' css class by default. 2020-01-06 02:12:04 -06:00
BrokenEagle 4b904dff5a Convert classes to use data attributes
- Remote resolved classes on post flags since they were unused
2020-01-04 22:02:45 +00:00
BrokenEagle 043944e1dd Convert index tables to using table builder 2020-01-04 22:02:43 +00:00
evazion 27c797f5c6 Fix #4230: Inconsistency between DText preview and DText renders of inline DText. 2019-12-28 13:28:45 -06:00
evazion a2ea2a65a1 db: drop IP addresses from certain tables.
Don't track IP addresses for post appeals, post flags, tag aliases, tag
implications, or user feedbacks. These things are already tightly
limited. We don't need IPs from them to detect sockpuppets.
2019-11-17 02:45:28 -06:00
evazion 77d2260576 css: clean up <ul> css.
* Remove `list-style-type: none` rules (this is the default).
* Add `list-bulleted` and `list-inline` utility classes.
* Wrap terms of service and user deletion pages in dtext `.prose` class
  so we don't have to redefine basic list styles on these pages.
2019-09-23 19:10:40 -05:00
evazion 312adb772d views: refactor post flag and appeal reasons.
* Prefer partials over helpers.
* Add css classes to flag/appeal reason lists.
* Wrap dtext in span.prose container.
2019-09-18 03:20:26 -05:00
evazion 73a4d675c0 css: ensure dtext is always wrapped in .prose container.
Ensure dtext is always wrapped in a `<div class="prose">` or
`<span class="prose">` (for inline dtext) container so that dtext css is
properly applied.
2019-09-17 00:28:41 -05:00
evazion 1743f3797f views: factor out search_form_for helper.
Refactor search forms to use `search_form_for` so that we can set common
options on all search forms, such as autocomplete="off" (#4162).
2019-09-10 14:31:19 -05:00
evazion f151285038 views: standardize page titles. 2019-08-24 22:55:35 -05:00
evazion 8d07ad7390 js: clean up notice/error messaging. 2019-08-14 01:46:44 -05:00
evazion fa19047220 autocomplete: add username autocompletion sitewide. 2019-08-11 15:38:39 -05:00
evazion f886f2fdb3 posts/show: load flag/appeal/replacement dialogs via ajax (#3922). 2018-09-26 20:01:14 -05:00
evazion 3ae913a707 html: convert html comments to erb comments.
Avoid emitting useless comments in the html.
2018-08-17 18:55:21 -05:00
Albert Yi 6fa0ae2cf1 Migrate assets to use Webpacker 2018-07-27 15:24:05 -07:00
BrokenEagle 5b4ab8d80e Disallow a user from seeing flagger's name on own uploads 2017-11-08 00:37:16 -08:00
evazion 7cb7c2fbab Remove ruby DText implementation (#3206). 2017-07-19 16:48:42 -05:00
Albert Yi f780b32012 Merge pull request #3145 from r888888888/flagger_metatag
Add "flagger:" and "appealer:" metatags (fixes #3142)
2017-06-14 11:02:08 -07:00
Type-kun 1375cc5307 Added privilege check for seeing flagger usernames
Also reworked all places dealing with flagger names to use said privilege
2017-06-14 20:43:25 +05:00
r888888888 d9ea925f4e add support for searching for dup-related flags 2017-06-12 15:25:07 -07:00
evazion 4631262374 Fix broken tag autocomplete on multiple pages.
Mark all tag <input>s with a `data-autocomplete` attribute, instead of
hardcoding a list of html IDs to autocomplete in javascript.

This way should be less error prone. It fixes autocomplete in several places:

* Autocomplete for the search box on /posts didn't work in the
  responsive layout. This was because /posts has two search boxes that
  both have the id `tags`: one in the normal sidebar, and one in the
  responsive tag list. $("#tags") only initialized autocomplete on the
  first one.

* Autocomplete didn't work on the aliases or implications pages. This
  was due to selecting the wrong html ids.
2017-04-22 15:24:03 -05:00
Albert Yi e639be60e5 Merge pull request #2977 from evazion/feat-flag-reason-search
Add full text search for flag/appeal reasons
2017-04-17 13:10:28 -07:00
evazion 54b4a2e0c5 /post_{flags,appeals}: default to fulltext search for reason field. 2017-04-16 21:15:23 -05:00
evazion 87b295b632 Fix exception on /post_flags/new, /post_appeals/new. 2017-04-15 23:15:17 -05:00
evazion c90614272a /posts/:id - add dtext preview to flag/appeal dialogs. 2017-04-13 15:17:55 -05:00
evazion 8d45bb6d52 /post_{flags,appeals}: allow searching by tags. 2017-04-07 19:37:26 -05:00
evazion f5e22ea235 /post_{flags,appeals}: convert search forms to simple form. 2017-04-07 19:37:26 -05:00
evazion 652e251040 /post_{flags,appeals}: add uploader, approver, flag/appeal count columns.
Also include '»' links next to uploader/approver names for drilling down
the search by a given user.
2017-04-07 19:37:26 -05:00
Albert Yi 87bcc07fae enable ragel parser for remaining dtext endpoints 2017-01-10 15:12:37 -08:00
evazion 961fb94adf Pull flag notice from help:flag_notice wiki page (fix #2767). 2016-11-21 01:30:01 -06:00
r888888888 4cd6dfe884 enable ragel parser in more places 2016-07-25 13:42:04 -07:00
Toks 184313e3d7 Update ToS and common flag reasons 2015-07-30 11:10:26 -04:00
r888888888 1d9596d7f2 fixes #2417 2015-06-29 18:17:59 -07:00
Toks 38f51306a8 fix #2314 and appeals 2014-11-30 16:10:17 -05:00
Toks 1fffc2977f fixes #2121 2014-10-31 20:24:38 -04:00
Toks f4596830c4 Partial fix for #1520 2014-01-08 15:54:27 -05:00
Toks 2d39ed5ebc Clean up flag/appeal/pool partials html
The new flag and appeal partials both had a duplicate #a-index dom id.
2013-08-14 13:19:44 -04:00
Toks 7c11fd440b Add pseudo-category search for flags
fixes #1915
2013-08-04 11:44:17 -04:00