mirror of
https://github.com/Chocobozzz/PeerTube.git
synced 2025-10-04 10:19:35 +02:00
Implement auto tag on comments and videos
* Comments and videos can be automatically tagged using core rules or watched word lists * These tags can be used to automatically filter videos and comments * Introduce a new video comment policy where comments must be approved first * Comments may have to be approved if the user auto block them using core rules or watched word lists * Implement FEP-5624 to federate reply control policies
This commit is contained in:
parent
b3e39df59e
commit
29329d6c45
241 changed files with 8090 additions and 1399 deletions
|
@ -49,7 +49,7 @@ export async function getApplicationActorOfHost (host: string) {
|
|||
return found?.href || undefined
|
||||
}
|
||||
|
||||
export function getAPPublicValue () {
|
||||
export function getAPPublicValue (): 'https://www.w3.org/ns/activitystreams#Public' {
|
||||
return 'https://www.w3.org/ns/activitystreams#Public'
|
||||
}
|
||||
|
||||
|
@ -137,10 +137,19 @@ const contextStore: { [ id in ContextType ]: (string | { [ id: string ]: string
|
|||
'@type': 'sc:Number',
|
||||
'@id': 'pt:fps'
|
||||
},
|
||||
|
||||
// Keep for federation compatibility
|
||||
commentsEnabled: {
|
||||
'@type': 'sc:Boolean',
|
||||
'@id': 'pt:commentsEnabled'
|
||||
},
|
||||
|
||||
canReply: 'pt:canReply',
|
||||
commentsPolicy: {
|
||||
'@type': 'sc:Number',
|
||||
'@id': 'pt:commentsPolicy'
|
||||
},
|
||||
|
||||
downloadEnabled: {
|
||||
'@type': 'sc:Boolean',
|
||||
'@id': 'pt:downloadEnabled'
|
||||
|
@ -261,10 +270,21 @@ const contextStore: { [ id in ContextType ]: (string | { [ id: string ]: string
|
|||
Reject: buildContext(),
|
||||
Accept: buildContext(),
|
||||
Announce: buildContext(),
|
||||
Comment: buildContext(),
|
||||
|
||||
Comment: buildContext({
|
||||
replyApproval: 'pt:replyApproval'
|
||||
}),
|
||||
|
||||
Delete: buildContext(),
|
||||
Rate: buildContext(),
|
||||
|
||||
ApproveReply: buildContext({
|
||||
ApproveReply: 'pt:ApproveReply'
|
||||
}),
|
||||
RejectReply: buildContext({
|
||||
RejectReply: 'pt:RejectReply'
|
||||
}),
|
||||
|
||||
Chapters: buildContext({
|
||||
hasPart: 'sc:hasPart',
|
||||
endOffset: 'sc:endOffset',
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue