#167 · Report content to administrators, who restrict it or dismiss the report
- timeline-app
- pull request
The first part of #115, following the plan decided there: - **1. Reports and the review queue:** this PR. - **2. Sensitive-content labels:** next. - **3. Policy and operator docs:** after that. Reports also feed #103's account standing, which comes after this. ## Reporting **Report** now appears on: - a timeline's page, beside Share (not for its owner); - a moment's or duration's details in the editor; - a pull request comment; - a published plugin or suite in the library (official ones can't be reported); - an account's profile. The dialog asks what is wrong: child abuse, other illegal content, sexually explicit, graphic violence, self-harm, harassment, spam, copyright, or other. Details are optional, up to 2,000 characters. | Rule | How | | --- | --- | | Signed-out readers can report | They answer the human-verification challenge first, when one is configured | | Limits | 10 reports a minute per account, or per address when signed out | | Reporting again | A signed-in reader's second report on the same thing replaces their first | | What can't be reported | Your own things, and things you can't see | | Anonymity | The owner never learns who reported | ## Review queue The queue is in **Site administration → Reports**. Reports about one thing gather in a **case**; a moment's or duration's report joins its timeline's case and names the moment or duration. - **Views:** *Awaiting a decision*, *Restricted* and *Closed*. Child abuse and other illegal content come first. - **Confirmation:** decisions need the usual admin confirmation (a recent sign-in, the password, and a code if MFA is on) and are recorded in `oc_admin_audit`. | Decision | Effect | | --- | --- | | **Dismiss** | Closes the case. The reason is kept only as a note; reporters are told no rule was broken. | | **Restrict** (reason required, sent to the owner) | **Timeline:** becomes private, and only its owner and administrators can open it (members lose access). Neither the owner nor an admin can make it public while restricted. The owner can still edit it and sees a notice on its page. **Comment:** shown as "Removed by moderators". **Plugin or suite:** leaves the library, and new versions are refused. **Account:** suspended, as in the Users view. | | **Keep / Lift** | The owner can ask once for a review, from **Account → Moderation decisions**. The admin keeps or lifts the restriction; lifting also works any time. Lifting restores the earlier visibility or reinstates the account. | **Emails** go only to confirmed addresses: - the owner hears of a restriction (with the reason and how to ask for a review), of the review's outcome, and of a lift; - signed-in reporters hear the outcome. ## Changes - **Schema:** `oc_moderation_cases` (at most one open or in-force case per thing) and `oc_reports`. - **New modules:** `server/moderation.mjs`, and `server/report-categories.mjs`, which the server and the dialog share. - **Routes:** - `POST /api/reports` - `GET /api/moderation` - `POST /api/moderation/ /appeal` - `GET /api/admin/reports?view=` - `PATCH /api/admin/reports/ ` - **Where restriction is enforced:** - `store.access`, `liveState` and comparison sources; - the account's own list and the dashboard (member access); - visibility changes, by the owner and in `/admin`; - comment reads; - plugin and suite search, lookup and publishing. Because restricted timelines are private, they also drop out of public browsing, search, the sitemap, embeds and previews. - **UI:** - `report-dialog.jsx` and `report-link.jsx`; - the queue card, `admin-reports.jsx`; - the account section, `moderation-decisions.jsx`; - the owner's notice on the timeline page; - the editor's moment and duration Report buttons, which post `openchronology:report` to the page. - **Docs:** `docs/moderation.md` covers reporting, reviewing, notices, the child-abuse procedure and the data. There are links from `docs/administration.md` and the README's rate-limit note. ## Tests - **New:** `test/moderation-postgres.mjs`…
Sources
Open #167 · Report content to administrators, who restrict it or dismiss the report in the timeline